/* =============================================
   CALCULADORA DE PENSIÓN - ESTILOS HOMOLOGADOS
   ============================================= */

/* Sección principal */
.calculadora-section {
    background: var(--color-fondo, #f8fafc);
    padding: 3em 0;
}

.calculadora-header {
    text-align: center;
    margin-bottom: 2.5em;
}

.calculadora-header h1 {
    font-size: 2rem;
    color: var(--color-primario, #1e3c72);
    margin-bottom: 0.5em;
}

.calculadora-header p {
    font-size: 1.1rem;
    color: var(--color-texto-secundario, #666);
    max-width: 700px;
    margin: 0 auto;
}

/* Wrapper principal */
.calculadora-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* Formulario */
.formulario-pension {
    padding: 2rem;
    background: #ffffff;
    border-bottom: 1px solid #e0e0e0;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-texto-principal, #1b263b);
    font-size: 0.9rem;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 0.8rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s;
    font-family: inherit;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--color-acento-claro, #D90416);
    box-shadow: 0 0 0 3px rgba(217, 4, 22, 0.1);
}

.input-group small {
    display: block;
    color: var(--color-texto-secundario, #52759c);
    font-size: 0.7rem;
    margin-top: 0.3rem;
}

/* Radio buttons */
.radio-group {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    margin-top: 0.5rem;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: normal;
    cursor: pointer;
    margin-bottom: 0;
}

.radio-group input {
    width: auto;
    margin: 0;
}

/* Info row (UMA) */
.info-row {
    background: #e8f0fe;
    padding: 0.8rem 1rem;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: var(--color-texto-principal, #1b263b);
}

.info-row strong {
    color: var(--color-primario, #073673);
}

/* Botones */
.button-group {
    display: flex;
    gap: 1rem;
}

.btn-calcular,
.btn-imprimir {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    flex: 1;
}

.btn-calcular {
    background: var(--color-acento-claro, #D90416);
    color: white;
}

.btn-calcular:hover {
    background: var(--color-acento, #A61731);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(166, 23, 49, 0.3);
}

.btn-imprimir {
    background: var(--color-secundario, #14548C);
    color: white;
}

.btn-imprimir:hover {
    background: var(--color-primario, #073673);
    transform: translateY(-2px);
}

/* Resultados */
.resultados-pension {
    padding: 2rem;
    background: #f9f9f9;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Tarjeta principal */
.resultado-principal {
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
    padding: 1.5rem;
    border-radius: 16px;
    text-align: center;
    margin-bottom: 1.5rem;
}

.resultado-principal h3 {
    color: #2e7d32;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.pension-monto {
    font-size: 2rem;
    font-weight: bold;
    color: #1b5e20;
    margin-bottom: 0.3rem;
}

.pension-mensual {
    font-size: 1.1rem;
    color: #2e7d32;
}

/* Info adicional */
.info-adicional {
    background: #fff3e0;
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.info-item {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    font-size: 0.85rem;
}

.info-item span {
    color: var(--color-texto-secundario, #52759c);
}

.info-item strong {
    color: #ed6c02;
}

/* Tabla de resultados */
.tabla-resultados {
    overflow-x: auto;
}

.tabla-resultados table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.tabla-resultados th,
.tabla-resultados td {
    padding: 0.8rem;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.tabla-resultados th {
    background: var(--color-fondo-topbar, #e9eef4);
    font-weight: 700;
    color: var(--color-texto-principal, #1b263b);
}

.tabla-resultados td:last-child,
.tabla-resultados th:last-child {
    text-align: right;
}

.tabla-resultados .subtotal td {
    background: var(--color-fondo-topbar, #e9eef4);
    font-weight: 700;
    border-top: 1px solid #ddd;
    border-bottom: 1px solid #ddd;
}

.tabla-resultados .total td {
    background: #e8f0fe;
    font-weight: bold;
    border-top: 2px solid var(--color-primario, #073673);
}

.tabla-resultados .total td:first-child {
    color: var(--color-primario, #073673);
}

/* Descargo de responsabilidad */
.disclaimer {
    padding: 1.5rem;
    background: #fff8e1;
    border-top: 1px solid #ffe0a3;
    font-size: 0.75rem;
    color: #666;
    line-height: 1.5;
}

.disclaimer p {
    margin-bottom: 0.8rem;
}

.disclaimer strong {
    color: #856404;
}

.disclaimer-small {
    font-size: 0.7rem;
    color: #999;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    border-top: 1px solid #ffe0a3;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
    .calculadora-section {
        padding: 2em 0;
    }
    
    .formulario-pension,
    .resultados-pension {
        padding: 1.5rem;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .info-adicional {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .calculadora-header h1 {
        font-size: 1.5rem;
    }
    
    .tabla-resultados {
        font-size: 0.7rem;
    }
    
    .tabla-resultados th,
    .tabla-resultados td {
        padding: 0.5rem;
    }
}

@media (max-width: 600px) {
    .resultado-principal {
        padding: 1rem;
    }
    
    .pension-monto {
        font-size: 1.5rem;
    }
    
    .pension-mensual {
        font-size: 0.9rem;
    }
}

@media print {
    .calculadora-section {
        padding: 0;
        background: white;
    }
    
    .button-group,
    .btn-calcular,
    .btn-imprimir,
    .whatsapp-bubble,
    .cta-section,
    #topbar,
    #header,
    #footer,
    .disclaimer {
        display: none !important;
    }
    
    .calculadora-wrapper {
        box-shadow: none;
        margin: 0;
        padding: 0;
    }
    
    .resultados-pension {
        padding: 0;
        background: white;
    }
}