/* Estilos generales */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: white;
    line-height: 1.6;
}

/* Header (Encabezado) */
.header {
    background-color: #fff;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.logo img {
    height: 50px;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: bold;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #007bff;
}

.nav-toggle {
    display: none;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
}

.hamburger {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    position: relative;
    transition: background-color 0.3s ease;
}

.hamburger::before,
.hamburger::after {
    content: '';
    display: block;
    width: 100%;
    height: 3px;
    background-color: #333;
    position: absolute;
    transition: transform 0.3s ease;
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

/* Estilo para el banner de ancho completo */
.banner-container {
    width: 100%;
    overflow: hidden;
    margin-bottom: 2rem;
}

.banner-image {
    width: 100%;
    height: auto;
    display: block;
}

/* Contenedor principal de cada grupo de sección (título + tarjetas) */
.section-group {
    max-width: 1200px;
    margin: 0 auto 3rem auto;
    padding: 0 1rem;
}

/* Estilo para el título de la sección */
.title-container {
    text-align: left;
    padding: 2rem 0 1rem;
}

.main-title-image {
    max-width: 300px;
    height: auto;
    display: block;
    margin-left: 1rem;
}

/* Contenido Principal (Tarjetas) */
.main-content {
    padding: 2rem 0;
}

.card-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 1.5rem;
    max-width: 100%;
    margin-left: 1rem;
}

.card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    width: 350px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.card-image {
    width: 100%;
    height: auto;
    display: block;
}

/* Footer (Pie de página) */
.footer {
    background-color: #003366;
    color: #fff;
    text-align: center;
    padding: 0.05rem 0; /* ¡Ajustado! El valor es más pequeño para reducir el alto */
    position: relative;
    bottom: 0;
    width: 100%;
}

/* Media Queries para responsividad */
@media (max-width: 768px) {
    .nav {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 60px;
        left: 0;
        background-color: #fff;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
        z-index: 10;
    }
    
    .nav.active {
        display: flex;
    }

    .nav-menu {
        flex-direction: column;
        gap: 0;
    }

    .nav-link {
        padding: 1rem;
        border-bottom: 1px solid #eee;
        display: block;
    }

    .nav-toggle {
        display: block;
    }

    .header {
        position: relative;
    }

    .main-title-image {
        max-width: 90%;
        margin-left: 0.5rem;
    }

    .card-container {
        justify-content: center;
        margin-left: 0;
    }

    .card {
        width: 90%;
    }

    .section-group {
        padding: 0 0.5rem;
    }
}