/* ==========================================================================
   Calculadora de Ley de Ohm - ElectroWeb
   ========================================================================== */

* {
    box-sizing: border-box;
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background: #f4f7fc;
    padding: 20px;
}

.calculator-card {
    max-width: 550px;
    width: 100%;
    background: white;
    border-radius: 24px;
    box-shadow: 0 20px 40px -12px rgba(0,0,0,0.2);
    padding: 2rem 2rem 2.5rem;
    transition: 0.2s;
}

.logo {
    text-align: center;
    margin-bottom: 20px;
}

.logo img {
    max-width: 180px;
    height: auto;
}

h1 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #0b1a33;
    margin-top: 0;
    margin-bottom: 0.25rem;
    letter-spacing: -0.02em;
}

.subhead {
    color: #3d4e6b;
    font-size: 0.95rem;
    margin-top: -0.2rem;
    margin-bottom: 2rem;
    border-left: 4px solid #0066ff;
    padding-left: 1rem;
    background: #f0f5ff;
    border-radius: 0 8px 8px 0;
    line-height: 1.4;
}

.input-grid {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.input-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.input-row label {
    min-width: 100px;
    font-weight: 500;
    color: #1a2b44;
    font-size: 1rem;
}

.input-row input {
    flex: 1;
    min-width: 140px;
    padding: 12px 16px;
    border: 1.5px solid #d9e0e9;
    border-radius: 14px;
    font-size: 1rem;
    background: white;
    transition: 0.15s;
    color: #0b1a33;
    font-weight: 500;
}

.input-row input:focus {
    outline: none;
    border-color: #0066ff;
    box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.15);
}

.input-row input::placeholder {
    color: #9aabbf;
    font-weight: 400;
    font-size: 0.9rem;
}

.input-row .unit {
    min-width: 40px;
    font-weight: 600;
    color: #3d5a78;
    font-size: 1rem;
}

.button-group {
    display: flex;
    gap: 1rem;
    margin: 1.5rem 0 1rem;
    flex-wrap: wrap;
}

.btn {
    flex: 1;
    min-width: 120px;
    padding: 14px 12px;
    border: none;
    border-radius: 40px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
    background: #eef2f7;
    color: #1a2b44;
    letter-spacing: 0.3px;
}

.btn-primary {
    background: #0066ff;
    color: white;
    box-shadow: 0 6px 14px rgba(0, 102, 255, 0.25);
}

.btn-primary:hover {
    background: #0052cc;
    transform: scale(0.98);
    box-shadow: 0 4px 10px rgba(0, 102, 255, 0.3);
}

.btn-secondary {
    background: #eef2f7;
}

.btn-secondary:hover {
    background: #dce3ed;
}

.btn:active {
    transform: scale(0.96);
}

.info-box {
    margin-top: 2rem;
    padding: 1rem 1.2rem;
    background: #f8faff;
    border-radius: 18px;
    border: 1px solid #e6edf6;
    font-size: 0.95rem;
    color: #1f334f;
}

.info-box strong {
    color: #0066ff;
}

.info-box .formula {
    font-family: 'Courier New', monospace;
    background: #eef2f7;
    padding: 0.2rem 0.6rem;
    border-radius: 8px;
    font-weight: 600;
}

.footer-note {
    text-align: center;
    font-size: 0.8rem;
    color: #6b7f9b;
    margin-top: 1.8rem;
    border-top: 1px solid #e6edf6;
    padding-top: 1.5rem;
}

@media (max-width: 480px) {
    .calculator-card { padding: 1.5rem; }
    .input-row { flex-wrap: wrap; }
    .input-row label { min-width: 80px; }
    .input-row input { min-width: 120px; }
    .button-group { flex-direction: column; }
    .btn { min-width: unset; }
}
