@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&display=swap');


body {
    font-family: sans-serif;
    margin: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #f4f4f4;
}
header { 
    height: 5rem; 
    background-color: #f8f9fa; 
    color: black; 
    padding: 0.5rem 1rem; 
    text-align: center; 
    box-shadow: 0 2px 5px rgba(0,0,0,0.1); 
    box-sizing: border-box;
    container-type: size;
}

main {
    flex: 1;
    flex-wrap: wrap;
    padding: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

footer { background-color: #333; color: white; text-align: center; padding: 1rem; margin-top: auto; }



/* Contenedor del logo y el texto */
.logo {
    display: flex; /* Activa Flexbox para alinear los elementos hijos */
    align-items: center; /* Centra verticalmente la imagen y el texto */
    height: 100%; /* Hace que el div ocupe toda la altura del header */
    gap: 15px; /* Crea un espacio de 15px entre la imagen y el texto */
}

/* Estilo para la imagen del logo */
.logo img {
    /* La imagen ocupará el 100% de la altura de su contenedor (.logo) */
    height: 100%; 
    width: auto; /* El ancho se ajustará automáticamente para mantener la proporción */
    border-radius: 1rem;
}

/* Estilo para el texto */
.logo span {
    font-size: 40cqh; 
    font-weight: 600; 
    color: #333;
}

.contenedor-main { 
    background-color: white; 
    padding: 2rem;
    border-radius: 8px; 
    box-shadow: 0 0 10px rgba(0,0,0,0.1); 
    width: 100%; 
    max-width: 500px; 
}

h2 { text-align: center; margin-bottom: 1.5rem; }
.campo { margin-bottom: 1.5rem; }
.campo label { display: block; margin-bottom: 0.5rem; font-weight: bold; }
.campo input[type="number"] { width: 100%; padding: 0.75rem; border: 1px solid #ccc; border-radius: 4px; box-sizing: border-box; }

.boton-principal { width: 100%; padding: 0.75rem; color: white; border: none; border-radius: 4px; font-size: 1rem; cursor: pointer; margin-top: 1rem; font-weight: bold;}
.boton-action { background-color: #5cb85c; }
.boton-action:hover { background-color: #4cae4c; }

.boton-descargar { background-color: #5b7ace; }
.boton-descargar:hover { background-color: #4061bb; }

.boton-descargar:before {
    content: "";
    width: 24px;
    height: 24px;
    display: inline-block;
    margin-right: 5px;
    vertical-align: text-top;
    background-color: transparent;
    background-position: center center;
    background-repeat: no-repeat;
    background-image: url(../img/excel_b.png);
    margin-top: -3px;
}

/* Estilos para el campo de plazo */
.campo-radio-container { display: flex; align-items: center; gap: 10px; }

.campo-radio-container .input-with-radio {
    width: 40%;
    flex-grow: 1;
}

.campo-radio-container .radio-group {
    width: 60%;
}

.radio-group { display: flex; align-items: center; border-radius: 4px; padding: 0.5rem 0.5rem; }
.radio-group label { margin: 0; font-weight: normal; display: inline-flex; align-items: center; cursor: pointer; }


/* --- NUEVOS ESTILOS PARA RADIO BUTTONS PERSONALIZADOS --- */

/* 1. Ocultar el radio button por defecto */
input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    margin: 0;
}

/* 2. Crear el círculo personalizado (estado no seleccionado) */
.radio-group label::before {
    content: '';
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 4px;
    border: 1px solid #aaa; /* Borde delgado y gris */
    border-radius: 50%;
    transition: all 0.2s ease;
}

/* 3. Definir el estilo del círculo cuando está seleccionado */
input[type="radio"]:checked + label::before {
    background-color: #4CAF50; /* Fondo verde */
    border: 1px solid #4CAF50; /* Mismo borde delgado, ahora verde */
}

/* 4. Efecto de enfoque para accesibilidad */
input[type="radio"]:focus + label::before {
    box-shadow: 0 0 0 2px rgba(92, 184, 92, 0.5); /* Anillo de enfoque suave */
}

.campo-resultado {
    display: flex;
    gap: 15px;
}

.campo-resultado span {
    font-size: 1.2rem;
    font-weight: bold;
    color: #5cb85c;
    margin-bottom: -0.2rem;
}


.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: none; /* Oculto por defecto */
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.modal.activo {
    display: flex; /* Se muestra al agregar la clase 'activo' */
}
.modal-contenido {
    background-color: white;
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    position: relative;
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ddd;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}
.modal-header h2 {
    margin: 0;
}
.modal-cerrar {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}
.modal-cuerpo {
    overflow-y: auto; /* Permite scroll si la tabla es muy larga */
}
.tabla-cronograma {
    width: 100%;
    border-collapse: collapse;
}
.tabla-cronograma th, .tabla-cronograma td {
    padding: 8px 12px;
    border: 1px solid #ccc;
    text-align: right;
}

.tabla-cronograma th, .tabla-cronograma tfoot td {
    position: sticky; /* La propiedad clave para la magia */
    background-color: #ddd; /* Fondo sólido para que el contenido no se vea a través */
    z-index: 1; /* Asegura que se mantenga por encima del tbody */
}

.modal-footer {
    display: flex;
    justify-content: flex-end; /* Alinea los botones a la derecha */
    padding-top: 1rem;
    margin-top: 1rem;
    border-top: 1px solid #ccc;
}

.tabla-cronograma thead th {
    top: 0; /* Pega el encabezado a la parte superior */
}

.tabla-cronograma tfoot td {
    bottom: 0; /* Pega el pie de tabla a la parte inferior */
    font-weight: bold; /* Opcional: Totales en negrita */
}

.tabla-cronograma tfoot th, .tabla-cronograma tfoot td {
    border-top: 3px solid #333;
}




header { 
    height: 5rem; 
    background-color: #f8f9fa; 
    color: black; 
    padding: 0.5rem 1rem; 
    text-align: center; 
    box-shadow: 0 2px 5px rgba(0,0,0,0.1); 
    box-sizing: border-box;
    container-type: size;

    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    top: 0;
    z-index: 100;
}

/* --- Estilos del Menú de Navegación (Móvil por defecto) --- */
.header-nav {
    display: none; /* Oculto por defecto en móviles */
    flex-direction: column;
    position: absolute;
    top: 70px; /* Justo debajo del header */
    left: 0;
    width: 100%;
    background-color: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Clase que se añade con JS para mostrar el menú */
.header-nav.nav-visible {
    display: flex;
}

.header-nav a {
    color: #333;
    text-decoration: none;
    font-weight: 600;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f0f0f0;
    text-align: center;
}

.header-nav a:last-child {
    border-bottom: none;
}

.header-nav a.active {
    color: #5cb85c;
}

/* --- Estilos del Botón de Hamburguesa --- */
.header-toggle {
    display: flex; /* Visible en móviles */
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

.header-toggle span {
    width: 30px;
    height: 3px;
    background-color: #333;
    border-radius: 5px;
    transition: all 0.3s ease;
}

/* Animación del botón a una 'X' cuando está activo */
.header-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}
.header-toggle.active span:nth-child(2) {
    opacity: 0;
}
.header-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}


.faq-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.faq-container h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.faq-item {
    background-color: #fff;
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    overflow: hidden; /* Clave para la animación */
}

.faq-pregunta {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
}

.faq-respuesta {
    max-height: 0; /* Oculta la respuesta por defecto */
    overflow: hidden;
    transition: max-height 0.4s ease-out, padding 0.4s ease-out;
}

.faq-respuesta p {
    padding: 0 1.5rem 1.5rem;
    margin: 0;
    line-height: 1.6;
    color: #555;
}

/* --- Estilos para el ícono (+/-) --- */
.faq-icono {
    position: relative;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-left: 1rem;
}
.faq-icono::before, .faq-icono::after {
    content: '';
    position: absolute;
    background-color: #5cb85c;
    border-radius: 2px;
    transition: transform 0.3s ease-out;
}
.faq-icono::before { /* Línea vertical */
    top: 0;
    left: 50%;
    width: 2px;
    height: 100%;
    transform: translateX(-50%);
}
.faq-icono::after { /* Línea horizontal */
    top: 50%;
    left: 0;
    width: 100%;
    height: 2px;
    transform: translateY(-50%);
}

/* --- Estilos para el estado activo --- */
.faq-item.active .faq-respuesta {
    max-height: 300px; /* Un valor suficientemente grande para mostrar el contenido */
    padding-top: 0;
}

.faq-item.active .faq-icono::before { /* La línea vertical desaparece */
    transform: translateX(-50%) rotate(90deg);
}
.faq-item.active .faq-icono::after { /* La línea horizontal se mantiene */
    transform: translateY(-50%) rotate(180deg);
}

.content-container {
    background-color: white; 
    padding: 2.5rem;
    border-radius: 8px; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.08); 
    width: 90%; 
    max-width: 1200px;
    margin: 2rem auto;
    font-family: 'Montserrat', sans-serif;
}

/* --- Tipografía y Títulos --- */
.content-container h1, .guia-container h2, .guia-container h3 {
    color: #333; /* Color principal para títulos */
    font-weight: 700;
}

.content-container h1 {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #5cb85c; /* Borde con el color de tu marca */
}

.content-container h2 {
    font-size: 1.8rem;
    margin-top: 3rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee; /* Borde sutil */
}

.content-container h3 {
    font-size: 1.3rem;
    color: #444;
    margin-top: 2rem;
    font-weight: 600;
}

/* --- Contenido de Texto --- */
.content-container p, .content-container li {
    color: #555;
    line-height: 1.7; /* Mejora la legibilidad */
    font-size: 1rem;
}

.content-container strong {
    color: #333;
    font-weight: 600;
}

/* --- Listas Personalizadas --- */
.content-container ul {
    list-style: none; /* Quitamos los puntos por defecto */
    padding-left: 0;
}

.content-container li {
    padding-left: 1.8rem; /* Espacio para el ícono */
    position: relative;
    margin-bottom: 1rem;
}

.content-container li::before {
    content: '✔'; /* Ícono de check */
    position: absolute;
    left: 0;
    top: 2px;
    color: #5cb85c; /* Color verde de la marca */
    font-weight: bold;
    font-size: 1.1rem;
}

/* --- Separador Moderno --- */
.content-container hr {
    border: 0;
    border-top: 1px solid #eee;
    margin: 3rem 0;
}

/* --- Estilos para Pantallas Grandes (Desktop) --- */
@media (min-width: 768px) {
    .header-toggle {
        display: none; /* Oculta el botón de hamburguesa */
    }

    .header-nav {
        display: flex; /* Muestra los enlaces */
        flex-direction: row; /* Los pone en horizontal */
        position: static; /* Quita el posicionamiento absoluto */
        width: auto;
        background-color: transparent;
        box-shadow: none;
    }

    .header-nav a {
        padding: 8px 0;
        border-bottom: none; /* Quita el borde inferior de la lista móvil */
        margin-left: 1.5rem;
        position: relative; /* Para la animación de la línea */
    }
    
    .header-nav a::after { /* Animación de línea inferior */
        content: '';
        position: absolute;
        width: 100%;
        height: 2px;
        bottom: 0;
        left: 0;
        background-color: #5cb85c;
        transform: scaleX(0);
        transition: transform 0.3s ease-out;
    }

    .header-nav a:hover::after {
        transform: scaleX(1);
    }

    .header-nav a.active::after {
        transform: scaleX(1);
    }
}


