/* 
  Academia Élite - Navigation Styles
  Estética: Luxury Glassmorphism & Neon Glow (Modernizado)
*/

/* Reset de visibilidad por defecto */
.mobile-only {
    display: none !important;
}

.desktop-only {
    display: flex !important;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background: rgba(5, 5, 5, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-sizing: border-box;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.navbar.nav-scrolled {
    background: rgba(5, 5, 5, 0.98);
    border-bottom: 1px solid rgba(197, 160, 89, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    padding: 12px 5%;
}

.nav-logo {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 1px;
    color: white;
    flex: 1;
    z-index: 1100;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.1);
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex: 2;
}

/* Botones Base con Efecto Vidrio Premium */
.nav-link,
.btn-alumno,
.btn-profe {
    background: rgba(255, 255, 255, 0.03) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 8px !important;
    padding: 10px 20px !important;
    text-decoration: none;
    font-size: 11px;
    letter-spacing: 1.5px;
    font-weight: 600;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

/* Hover fx - Glow */
.nav-link:hover,
.btn-alumno:hover,
.btn-profe:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    color: #fff !important;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

/* ESTADO ACTIVO (Dorado Élite) */
.nav-link.active {
    background: linear-gradient(135deg, rgba(197, 160, 89, 0.15) 0%, rgba(197, 160, 89, 0.05) 100%) !important;
    border: 1px solid rgba(197, 160, 89, 0.6) !important;
    color: #c5a059 !important;
    box-shadow: 0 0 25px rgba(197, 160, 89, 0.2);
}

/* Accesos Right Side */
.nav-access {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    flex: 1;
    z-index: 1100;
}

.btn-alumno {
    border-color: rgba(183, 28, 28, 0.3) !important;
}

.btn-alumno:hover {
    box-shadow: 0 0 20px rgba(183, 28, 28, 0.4) !important;
    border-color: #b71c1c !important;
}

.btn-profe {
    border-color: rgba(197, 160, 89, 0.3) !important;
    color: #c5a059 !important;
}

.btn-profe:hover {
    box-shadow: 0 0 20px rgba(197, 160, 89, 0.4) !important;
    border-color: #c5a059 !important;
}

/* --- MOBILE TOGGLE (Hamburguesa Estilo Cristal Moderno) --- */
.nav-toggle {
    display: none;
    /* Desktop default */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    z-index: 1100;

    /* Caja de cristal */
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.nav-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(197, 160, 89, 0.5);
    box-shadow: 0 0 15px rgba(197, 160, 89, 0.2);
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: white;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    /* Elastic bouncy effect */
    border-radius: 4px;
    position: relative;
}

/* Animación Hamburguesa activa */
.nav-toggle.active {
    border-color: #c5a059;
    background: rgba(197, 160, 89, 0.1);
    box-shadow: 0 0 20px rgba(197, 160, 89, 0.3);
}

.nav-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
    background: #c5a059;
    width: 28px;
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(10px);
}

.nav-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
    background: #c5a059;
    width: 28px;
}

/* --- RESPONSIVE LOGIC --- */
@media (max-width: 1024px) {
    .mobile-only {
        display: block !important;
    }

    .desktop-only {
        display: none !important;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 250px;
        height: 100vh;

        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-left: 1px solid rgba(197, 160, 89, 0.3);

        flex-direction: column;
        justify-content: flex-start;
        padding-top: 80px;
        transition: right 0.5s cubic-bezier(0.77, 0, 0.18, 1);
        z-index: 1050;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.8);
    }

    .nav-links.active {
        right: 0;
    }

    /* Links en Mobile */
    .nav-link {
        font-size: 0.9rem !important;
        padding: 12px 20px !important;
        width: 100%;
        text-align: left;
        background: transparent !important;
        border: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        opacity: 0;
        transform: translateX(20px);
        transition: opacity 0.4s ease, transform 0.4s ease;
    }

    /* Staggered animation reveal can be done in JS or simplified here */
    .nav-links.active .nav-link {
        opacity: 1;
        transform: translateX(0);
    }

    .nav-links.active .nav-link:nth-child(1) {
        transition-delay: 0.1s;
    }

    .nav-links.active .nav-link:nth-child(2) {
        transition-delay: 0.2s;
    }

    .nav-links.active .nav-link:nth-child(3) {
        transition-delay: 0.3s;
    }

    .nav-links.active .nav-link:nth-child(4) {
        transition-delay: 0.4s;
    }

    .nav-links.active .nav-link:nth-child(5) {
        transition-delay: 0.5s;
    }

    .nav-links.active .nav-link:nth-child(6) {
        transition-delay: 0.6s;
    }

    .nav-link.active {
        background: transparent !important;
        border-bottom: 1px solid #c5a059 !important;
        color: #c5a059 !important;
        box-shadow: none;
    }

    /* Accesos móviles destacados */
    .nav-link.mobile-only {
        width: 90%;
        margin: 10px auto !important;
        border-radius: 6px !important;
        border: 1px solid rgba(197, 160, 89, 0.2) !important;
        font-size: 0.85rem !important;
        background: rgba(197, 160, 89, 0.05) !important;
        text-align: center;
    }

    .nav-link.mobile-only.red {
        color: #ef4444 !important;
        border-color: rgba(239, 68, 68, 0.3) !important;
        margin-top: 20px !important;
    }

    .nav-link.mobile-only.gold {
        color: #c5a059 !important;
        border-color: rgba(197, 160, 89, 0.5) !important;
    }
}