/* =========================================
   VARIABLES DE COLOR (MANTENER CONSISTENCIA)
   ========================================= */
:root {
    --primary-blue: #0b2341; 
    --accent-gold: #e5b869; 
    --text-white: #ffffff;
    --text-dark: #333333;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #f4f4f4;
}

/* =========================================
   BARRA DE NAVEGACIÓN (HEADER)
   ========================================= */
.navbar {
    background-color: var(--primary-blue);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 3rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo-container .logo {
    height: 50px;
    border-radius: 4px; 
}

/* Menú Hamburguesa (Oculto en PC) */
.menu-toggle {
    display: none; 
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.menu-toggle .bar {
    width: 25px;
    height: 3px;
    background-color: var(--text-white);
    transition: all 0.3s ease;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-item {
    color: var(--text-white);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.nav-item:hover {
    color: var(--accent-gold);
}

.btn-login {
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
}

.btn-login:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: var(--text-white);
}

/* =========================================
   CARRUSEL PRINCIPAL (HERO) - ESCRITORIO
   ========================================= */
.hero-carousel-container {
    position: relative;
    height: 80vh; 
    display: flex;
    align-items: center;
    padding: 0 5rem;
    overflow: hidden;
    background-color: var(--primary-blue); 
}

.carousel-slides {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

/* Filtro oscuro sobre las imágenes para que el texto sea legible */
.slide::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(11, 35, 65, 0.7), rgba(11, 35, 65, 0.4));
}

.slide.active {
    opacity: 1;
}

/* Contenido de texto sobre el carrusel */
.hero-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    color: var(--text-white);
}

.hero-content h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1rem;
    color: var(--accent-gold);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    font-weight: 300;
}

.cta-button {
    background-color: var(--accent-gold);
    color: var(--primary-blue);
    border: none;
    padding: 0.8rem 2rem;
    font-size: 1rem;
    font-weight: 700;
    border-radius: 4px;
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s;
}

.cta-button:hover {
    transform: scale(1.05);
    background-color: #d4a758;
}

/* =========================================
   MEDIA QUERIES (TABLETS Y PANTALLAS MEDIANAS)
   ========================================= */
@media (max-width: 992px) {
    .menu-toggle {
        display: flex; 
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--primary-blue);
        flex-direction: column;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out; 
        box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        max-height: 500px; 
        padding: 1rem 0;
    }

    .nav-item {
        width: 100%;
        text-align: center;
        padding: 1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .btn-login {
        border: none;
        border-radius: 0;
        color: var(--accent-gold);
    }

    .hero-carousel-container {
        height: 60vh; 
        padding: 0 3rem; 
        justify-content: flex-start;
        text-align: left;
    }

    .hero-content h1 {
        font-size: 3rem; 
    }
}

/* =========================================
   MEDIA QUERIES (TELÉFONOS MÓVILES - SMARTPHONES)
   ========================================= */
@media (max-width: 576px) {
    .navbar {
        padding: 1rem 1.5rem; 
    }

    .hero-carousel-container {
        /* Reducimos la altura para imitar la proporción de la imagen y que se vea completa */
        height: 20vh; 
        min-height: 220px; /* Garantiza que siempre haya espacio mínimo para el texto */
        padding: 0 1.2rem; 
        display: flex;
        align-items: center;
        justify-content: flex-start; 
        text-align: left; 
    }

    .slide {
        /* Al ser un contenedor más bajo, 'cover' mostrará casi la totalidad de la imagen sin recortar los lados */
        background-size: cover; 
        background-position: center;
    }

    .slide::after {
        background: linear-gradient(rgba(11, 35, 65, 0.6), rgba(11, 35, 65, 0.7));
    }

    .hero-content {
        width: 100%;
        max-width: 250px; /* Mantiene el contenido anclado a la izquierda */
    }

    .hero-content h1 {
        font-size: 1.3rem; /* Tamaño muy reducido para encajar en el carrusel bajo */
        margin-bottom: 0.4rem;
    }

    .hero-content p {
        font-size: 0.75rem; /* Letra más pequeña y fina para móviles */
        margin-bottom: 0.8rem;
        line-height: 1.3;
    }

    .cta-button {
        padding: 0.5rem 1rem; /* Botón más compacto */
        font-size: 0.8rem; 
    }
}

/* =========================================
   SOLUCIÓN DEFINITIVA: MENÚ CASCADA Y CAPAS
   ========================================= */

/* 1. ELEVAR TODA LA BARRA DE NAVEGACIÓN POR ENCIMA DEL CARRUSEL */
.navbar {
    position: relative !important; 
    z-index: 99999 !important; /* Capa extrema para superar al carrusel */
    overflow: visible !important; 
}

/* 2. Evitar que la lista de enlaces corte el menú (SOLO EN PC) */
@media (min-width: 993px) {
    .nav-links {
        overflow: visible !important;
    }
}

/* 6. Ajustes perfectos del submenú desplegable para vista de Celular */
@media (max-width: 992px) {
    .dropdown-content {
        position: relative !important; /* Permite que empuje los demás botones hacia abajo */
        box-shadow: none !important;
        background-color: rgba(0, 0, 0, 0.15) !important; /* Fondo azul un poco más oscuro */
        border-top: none;
    }
    
    .dropdown-content a {
        color: #ffffff !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
        padding: 12px 20px 12px 40px !important; /* Sangría a la izquierda para distinguirlo */
    }

    .dropdown-content a:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }
    
    .nav-links.active {
        max-height: 800px !important; /* Aumentamos el espacio por si el menú se expande mucho */
    }
}

/* 3. Contenedor del botón Escuela */
.dropdown {
    position: relative;
    display: inline-block;
}

/* 4. La caja blanca del menú desplegable */
.dropdown-content {
    display: none; /* Oculto por defecto */
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #ffffff;
    min-width: 250px;
    box-shadow: 0px 15px 35px rgba(0,0,0,0.4) !important;
    border-radius: 4px;
    border-top: 4px solid var(--primary-blue); 
    z-index: 999999 !important; /* Nivel altísimo garantizado */
}

/* 5. NUEVO: Mostrar el menú al pasar el ratón (Hover) */
.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-content a {
    color: #333333;
    padding: 15px 20px;
    text-decoration: none;
    display: block;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s;
}

.dropdown-content a:hover {
    background-color: #f4f6f9;
    color: var(--accent-gold);
    padding-left: 25px; /* Efecto dinámico al pasar el mouse */
}

/* =========================================
   ESTILOS DEL CONTENIDO DE LA ESCUELA (PEI)
   ========================================= */

/* Animación Profesional de Entrada */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.info-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 5% 40px 5%;
    font-family: 'Inter', sans-serif;
    color: #333;
}

/* Espaciados Verticales Unificados para Evitar Huecos */
.info-section {
    padding: 20px 0;
}

/* Bloques Destacados Rebalanceados */
.bg-light {
    background-color: #f8fafc; /* Gris azulado sutil y moderno */
    padding: 35px 4%;
    border-radius: 12px;
    margin: 12px 0; /* Reducido drásticamente para evitar baches visuales */
    border: 1px solid rgba(11, 35, 65, 0.04);
}

.section-title {
    color: var(--primary-blue);
    font-family: 'Montserrat', sans-serif;
    font-size: 1.85rem;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 700;
    position: relative;
    animation: fadeInUp 0.5s ease both;
}

/* Grids Limpios y Proporcionales */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px; /* Separación balanceada entre tarjetas */
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
}

/* Tarjetas Informativas y Cajas de Iconos Unificadas con Animación */
.info-card, .icon-box {
    background: #ffffff;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(11, 35, 65, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.03);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.4s ease, 
                border-color 0.4s ease;
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Efecto Hover Fluido e Interactivo */
.info-card:hover, .icon-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(11, 35, 65, 0.08);
    border-color: rgba(229, 184, 105, 0.4); /* Resaltado dorado suave */
}

/* Retardo de Animación Escalonado para un Efecto Premium (PC) */
.grid-2 > :nth-child(1) { animation-delay: 0.1s; }
.grid-2 > :nth-child(2) { animation-delay: 0.2s; }

.grid-3 > :nth-child(1) { animation-delay: 0.05s; }
.grid-3 > :nth-child(2) { animation-delay: 0.1s; }
.grid-3 > :nth-child(3) { animation-delay: 0.15s; }
.grid-3 > :nth-child(4) { animation-delay: 0.2s; }
.grid-3 > :nth-child(5) { animation-delay: 0.25s; }
.grid-3 > :nth-child(6) { animation-delay: 0.3s; }

.info-card h2, .info-card h3 {
    color: var(--primary-blue);
    font-family: 'Montserrat', sans-serif;
    margin-bottom: 12px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.border-gold {
    border-left: 4px solid var(--accent-gold); 
}

/* Cajas de Iconos (Filosofía) */
.icon-box {
    text-align: center;
}

.icon-box i {
    font-size: 2.2rem;
    color: var(--accent-gold); 
    margin-bottom: 12px;
    transition: transform 0.3s ease;
}

.icon-box:hover i {
    transform: scale(1.1) rotate(3deg); /* Micro-animación en el icono al pasar el mouse */
}

.icon-box h3 {
    color: var(--primary-blue);
    margin-bottom: 8px;
    font-size: 1.15rem;
    font-family: 'Montserrat', sans-serif;
}

.icon-box p {
    font-size: 0.92rem;
    color: #555;
    line-height: 1.5;
}

/* Acordeón de Valores Compacto y Profesional */
.accordion-container {
    max-width: 850px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 8px; /* Control estricto de espacios mutuos */
}

.accordion {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
    animation: fadeInUp 0.5s ease both;
}

.accordion[open] {
    box-shadow: 0 4px 15px rgba(11, 35, 65, 0.05);
    border-color: rgba(11, 35, 65, 0.2);
}

.accordion summary {
    padding: 14px 20px;
    font-weight: 600;
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-blue);
    cursor: pointer;
    background: #f8fafc;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s ease;
}

.accordion summary:hover {
    background: #edf2f7;
}

.accordion summary::-webkit-details-marker {
    display: none;
}

.accordion summary::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--primary-blue);
    font-size: 0.85rem;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.accordion[open] summary::after {
    transform: rotate(180deg);
    color: var(--accent-gold);
}

.accordion-content {
    padding: 18px 20px;
    border-top: 1px solid #edf2f7;
    color: #4a5568;
    line-height: 1.6;
    background: #ffffff;
    font-size: 0.95rem;
}

/* =========================================
   MEDIA QUERIES (OPTIMIZACIÓN TOTAL MÓVIL)
   ========================================= */
@media (max-width: 768px) {
    .info-container {
        padding: 10px 4% 30px 4%;
    }
    
    .info-section {
        padding: 10px 0; /* Espaciado ultra-ajustado en celulares */
    }
    
    .bg-light {
        padding: 22px 5%;
        margin: 8px 0;
    }
    
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 18px;
    }
    
    .grid-2, .grid-3 {
        gap: 14px; /* Las tarjetas se apilan más cerca en móviles */
    }
    
    .info-card, .icon-box {
        padding: 20px; /* Más compacto para pantallas pequeñas */
    }
    
    .accordion summary {
        padding: 12px 16px;
        font-size: 0.95rem;
    }
}

/* =========================================
   VARIABLES Y BASE
   ========================================= */
:root {
    --primary-blue: #0b2341;
    --accent-gold: #e5b869;
    --bg-light: #f8fafc;
    --text-dark: #333333;
    --white: #ffffff;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background-color: var(--white);
    overflow-x: hidden;
}

.container {
    max-width: 1200px; /* Aquí controlamos la proporción en computadores */
    margin: 0 auto;
    padding: 0 20px;
}

.section-title {
    text-align: center;
    color: var(--primary-blue);
    font-size: 2.2rem;
    margin-bottom: 3rem;
    font-weight: 700;
}

/* =========================================
   BARRA DE NAVEGACIÓN
   ========================================= */
.main-nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--primary-blue);
    padding: 15px 0;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.logo {
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-links {
    display: flex;
    gap: 20px;
    align-items: center;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--accent-gold);
}

.portal-btn {
    background: var(--accent-gold);
    color: var(--primary-blue) !important;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.portal-btn:hover {
    background: #d4a758;
    transform: translateY(-2px);
}

/* Opcional: Si quieres diferenciar el botón de estudiante con un tono más suave */
.portal-btn.student {
    background: rgba(255, 255, 255, 0.15);
    color: var(--white) !important;
    border: 1px solid rgba(255, 255, 255, 0.3);
}
.portal-btn.student:hover {
    background: var(--white);
    color: var(--primary-blue) !important;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
}

/* =========================================
   HERO SECTION (CARRUSEL 100%)
   ========================================= */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 60px; /* Espacio para el nav */
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(11,35,65,0.9) 0%, rgba(11,35,65,0.4) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 1200px;
    width: 100%;
    padding: 0 20px;
    color: var(--white);
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    max-width: 700px;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 600px;
    color: #e2e8f0;
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

.btn-primary-hero {
    background: var(--accent-gold);
    color: var(--primary-blue);
    padding: 14px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    transition: 0.3s;
}

.btn-secondary-hero {
    background: transparent;
    color: var(--white);
    padding: 14px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    border: 2px solid var(--white);
    transition: 0.3s;
}

.btn-primary-hero:hover { background: #d4a758; transform: translateY(-3px); }
.btn-secondary-hero:hover { background: var(--white); color: var(--primary-blue); transform: translateY(-3px); }

/* =========================================
   CARACTERÍSTICAS
   ========================================= */
.features-section {
    padding: 80px 0;
    background: var(--bg-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.feature-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s;
    border-bottom: 4px solid var(--accent-gold);
}

.feature-card:hover {
    transform: translateY(-10px);
}

.feature-card i {
    font-size: 3rem;
    color: var(--primary-blue);
    margin-bottom: 20px;
}

/* =========================================
   GALERÍA DE VIDEOS
   ========================================= */
.video-section {
    padding: 80px 0;
    background: var(--white);
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.video-card {
    position: relative;
    padding-bottom: 56.25%; /* Proporción 16:9 para YouTube */
    height: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* Aseguramos que tanto YouTube (iframe) como los videos locales (video) se ajusten al contenedor 16:9 */
.video-card iframe,
.video-card video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 12px; /* Mantiene los bordes redondeados elegantes */
    background-color: #000; /* Fondo negro mientras carga */
}

/* =========================================
   CONTACTO Y MAPA GPS
   ========================================= */
.contact-section {
    padding: 80px 0;
    background: var(--primary-blue);
    color: var(--white);
}

.contact-section .section-title { color: var(--white); }

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    background: #13335c;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.contact-info {
    padding: 40px;
}

.contact-info h2 { color: var(--accent-gold); margin-bottom: 15px; }

.contact-list {
    list-style: none;
    padding: 0;
    margin: 30px 0;
}

.contact-list li {
    margin-bottom: 20px;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 15px;
}

.contact-list i { color: var(--accent-gold); font-size: 1.2rem; width: 20px; }

.contact-map {
    width: 100%;
    min-height: 400px;
}

.social-links-contact {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.social-links-contact a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.1);
    color: var(--white);
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.2rem;
    transition: 0.3s;
}

.social-links-contact a:hover {
    background: var(--accent-gold);
    color: var(--primary-blue);
}

/* =========================================
   FOOTER
   ========================================= */
.main-footer {
    background: #061528;
    color: #94a3b8;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h3 { color: var(--accent-gold); font-size: 1.8rem; margin-bottom: 15px; }
.footer-links h4 { color: var(--white); margin-bottom: 20px; }

.footer-links a {
    display: block;
    color: #94a3b8;
    text-decoration: none;
    margin-bottom: 10px;
    transition: 0.3s;
}

.footer-links a:hover { color: var(--accent-gold); }

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.9rem;
}

/* =========================================
   BOTÓN FLOTANTE WHATSAPP
   ========================================= */
.float-whatsapp {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 40px;
    right: 40px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 35px;
    box-shadow: 0px 4px 10px rgba(0,0,0,0.3);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
    text-decoration: none !important; /* <--- Esta línea elimina el subrayado */
}

.float-whatsapp:hover {
    transform: scale(1.1);
}

/* =========================================
   RESPONSIVE (MÓVILES) - PESTAÑAS CON BOX-SHADOW
   ========================================= */
@media (max-width: 992px) {
    .nav-links { 
        display: none; 
        flex-direction: column;
        position: absolute;
        top: 100%; 
        left: 0;
        width: 100%;
        background: var(--primary-blue);
        padding: 15px 0; /* Espacio de descompresión vertical */
        box-sizing: border-box;
        border-top: 1px solid rgba(255,255,255,0.05);
    }
    
    .nav-links.active {
        display: flex;
    }

    /* Cada pestaña se convierte en una tarjeta independiente alineada a la izquierda */
    .nav-links a {
        padding: 12px 16px;
        margin: 6px 20px; /* Alínea exactamente con el margen del logo (20px) y separa las pestañas */
        background: #112a4a; /* Fondo sutilmente más claro para proyectar el sombreado */
        color: #e2e8f0;
        font-size: 0.95rem; 
        display: flex;
        align-items: center;
        border-radius: 6px;
        text-decoration: none;
        border: 1px solid rgba(255, 255, 255, 0.03);
        
        /* SOMBRA ALREDEDOR DE TODA LA PESTAÑA */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4); 
        
        transition: all 0.25s ease;
    }

    /* Efecto al presionar o pasar el dedo: Brillo perimetral dorado */
    .nav-links a:hover, 
    .nav-links a:active {
        background: #153258;
        color: var(--accent-gold) !important;
        border-color: rgba(229, 184, 105, 0.3);
        
        /* Sombra expandida con destello institucional alrededor de toda la pestaña */
        box-shadow: 0 4px 15px rgba(229, 184, 105, 0.15); 
        transform: translateY(-1px); /* Efecto táctil de elevación */
    }

    /* Estilo uniforme para los portales, integrados perfectamente a la lista */
    .nav-links a.portal-btn {
        background: #143157;
        border: 1px solid rgba(229, 184, 105, 0.15);
        color: var(--accent-gold) !important;
    }

    .nav-links a.portal-btn:hover,
    .nav-links a.portal-btn:active {
        background: #1a3d6a;
        border-color: var(--accent-gold);
        box-shadow: 0 4px 15px rgba(229, 184, 105, 0.25);
    }

    /* Limpieza absoluta de estructuras previas */
    .nav-links a::after { display: none !important; }
    .menu-divider-mobile { display: none; }

    /* Ajustes generales obligatorios del contenedor responsivo */
    .mobile-menu-btn { display: block; }
    .hero-content h1 { font-size: 2.5rem; }
    .hero-buttons { flex-direction: column; }
    .contact-grid, .footer-content { grid-template-columns: 1fr; }
    .contact-map { height: 300px; }
    .float-whatsapp { bottom: 20px; right: 20px; width: 50px; height: 50px; font-size: 28px; }
}

@media (min-width: 993px) {
    .menu-divider-mobile { display: none; }
}