/**
 * Ultra-Premium Navigation Dark Theme
 * Power of Knowledge - AI-Powered Academic Journal
 * 
 * Enhanced navigation styles for the Ultra-Premium dark theme.
 * Covers: main nav, mobile menu, mega menus, user dropdown.
 */

/* ============================================
   MAIN NAVIGATION BAR
   ============================================ */

.navbar,
.main-header,
#mainNav {
    background: rgba(18, 18, 26, 0.95) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(0, 212, 255, 0.1) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

/* ============================================
   TOP BAR & BRANDING (Header Extension)
   ============================================ */
.top-bar {
    background: var(--void-black, #0a0a0f) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
    color: var(--silver, #9ca3af) !important;
}

.top-bar a {
    color: var(--silver, #9ca3af) !important;
    transition: color 0.3s ease;
}

.top-bar a:hover {
    color: var(--quantum-blue, #00d4ff) !important;
}

.branding-section {
    background: linear-gradient(180deg, var(--void-black) 0%, var(--obsidian) 100%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.journal-title.gradient-text {
    background: linear-gradient(90deg, #fff 0%, #e2e8f0 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    text-shadow: 0 0 30px rgba(0, 212, 255, 0.2);
}

.journal-subtitle {
    color: var(--silver, #9ca3af) !important;
}

/* Sticky header glow effect */
/* Sticky header glow effect */
.navbar.scrolled,
.navbar.sticky,
.main-header.sticky {
    background: rgba(10, 10, 15, 0.98) !important;
    border-bottom: 1px solid rgba(0, 212, 255, 0.2) !important;
    box-shadow:
        0 4px 30px rgba(0, 0, 0, 0.4),
        0 0 30px rgba(0, 212, 255, 0.1) !important;

    /* FORCE STICKY BEHAVIOR */
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 10000 !important;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
    }

    to {
        transform: translateY(0);
    }
}

/* ============================================
   LOGO TREATMENT
   ============================================ */

.navbar-brand,
.site-logo,
.logo {
    position: relative;
}

.navbar-brand img,
.site-logo img,
.logo img {
    filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.3));
    transition: filter 0.3s ease;
}

.navbar-brand:hover img,
.site-logo:hover img {
    filter: drop-shadow(0 0 15px rgba(0, 212, 255, 0.5));
}

/* ============================================
   NAVIGATION LINKS
   ============================================ */

.navbar-nav .nav-link,
.main-nav a,
.primary-menu a {
    color: var(--silver, #9ca3af) !important;
    font-weight: 500;
    padding: 10px 16px !important;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.navbar-nav .nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--quantum-blue, #00d4ff), var(--neural-purple, #8b5cf6));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover {
    color: var(--platinum, #e5e7eb) !important;
    background: rgba(0, 212, 255, 0.05);
}

.navbar-nav .nav-link:hover::before {
    width: 60%;
}

.navbar-nav .nav-link.active {
    color: var(--quantum-blue, #00d4ff) !important;
}

.navbar-nav .nav-link.active::before {
    width: 60%;
}

/* ============================================
   DROPDOWN MENUS
   ============================================ */

.navbar .dropdown-menu,
.nav-dropdown {
    background: rgba(18, 18, 26, 0.95) !important;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.6),
        0 0 30px rgba(0, 212, 255, 0.15) !important;
    border-radius: 16px !important;
    padding: 12px !important;
    min-width: 240px;
    animation: dropdown-fade 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes dropdown-fade {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar .dropdown-item,
.nav-dropdown a {
    color: var(--silver, #9ca3af) !important;
    padding: 10px 16px !important;
    border-radius: 8px !important;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar .dropdown-item:hover,
.nav-dropdown a:hover {
    background: rgba(0, 212, 255, 0.1) !important;
    color: var(--quantum-blue, #00d4ff) !important;
    transform: translateX(4px);
}

.navbar .dropdown-item i,
.nav-dropdown a i {
    width: 20px;
    text-align: center;
    opacity: 0.7;
}

/* Dropdown divider */
.dropdown-divider {
    border-color: rgba(255, 255, 255, 0.06) !important;
    margin: 8px 0 !important;
}

/* ============================================
   MEGA MENU
   ============================================ */

.mega-menu {
    background: var(--anthracite, #1a1a2e) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 20px !important;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6) !important;
    padding: 24px !important;
}

.mega-menu .menu-column {
    border-right: 1px solid rgba(255, 255, 255, 0.06);
    padding: 0 24px;
}

.mega-menu .menu-column:last-child {
    border-right: none;
}

.mega-menu .menu-title {
    color: var(--platinum, #e5e7eb) !important;
    font-family: var(--font-display, 'Space Grotesk', sans-serif);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(0, 212, 255, 0.2);
}

.mega-menu a {
    color: var(--silver, #9ca3af) !important;
    padding: 8px 0 !important;
    display: block;
    transition: all 0.2s ease;
}

.mega-menu a:hover {
    color: var(--quantum-blue, #00d4ff) !important;
    padding-left: 8px !important;
}

/* ============================================
   USER MENU / PROFILE DROPDOWN
   ============================================ */

.user-menu,
.profile-dropdown {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(0, 212, 255, 0.3);
    transition: all 0.3s ease;
}

.user-avatar:hover {
    border-color: var(--quantum-blue, #00d4ff);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

.user-dropdown {
    background: var(--anthracite, #1a1a2e) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    padding: 16px !important;
    min-width: 260px;
}

.user-dropdown .user-info {
    text-align: center;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    margin-bottom: 12px;
}

.user-dropdown .user-name {
    color: var(--platinum, #e5e7eb);
    font-weight: 600;
    font-size: 1rem;
}

.user-dropdown .user-email {
    color: var(--silver, #9ca3af);
    font-size: 0.875rem;
}

/* ============================================
   AUTH BUTTONS (Login/Register)
   ============================================ */

.btn-login,
.nav-login {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: var(--platinum, #e5e7eb) !important;
    padding: 8px 20px !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
}

.btn-login:hover,
.nav-login:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: var(--quantum-blue, #00d4ff) !important;
    color: var(--quantum-blue, #00d4ff) !important;
}

.btn-register,
.nav-register {
    background: linear-gradient(135deg, var(--quantum-blue, #00d4ff), var(--neural-purple, #8b5cf6)) !important;
    border: none !important;
    color: white !important;
    padding: 8px 20px !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 20px rgba(0, 212, 255, 0.3) !important;
    transition: all 0.3s ease !important;
}

.btn-register:hover,
.nav-register:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.5) !important;
}

/* ============================================
   MOBILE MENU
   ============================================ */

.navbar-toggler,
.mobile-toggle {
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    background: transparent !important;
    padding: 8px 12px !important;
    border-radius: 8px !important;
}

.navbar-toggler:hover {
    background: rgba(0, 212, 255, 0.1) !important;
    border-color: var(--quantum-blue, #00d4ff) !important;
}

.navbar-toggler-icon {
    filter: invert(1) brightness(0.8);
}

/* Mobile menu panel */
.offcanvas,
.mobile-menu-panel {
    background: var(--obsidian, #12121a) !important;
    border-left: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.offcanvas-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

.offcanvas-title {
    color: var(--platinum, #e5e7eb) !important;
}

.offcanvas .btn-close {
    filter: invert(1);
    opacity: 0.7;
}

.offcanvas .nav-link {
    color: var(--silver, #9ca3af) !important;
    padding: 12px 16px !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* ============================================
   SEARCH BAR IN HEADER
   ============================================ */

.navbar-search,
.header-search {
    position: relative;
}

.navbar-search input,
.header-search input {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: var(--platinum, #e5e7eb) !important;
    padding: 10px 16px 10px 44px !important;
    border-radius: 12px !important;
    width: 250px;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    backdrop-filter: blur(10px);
}

.navbar-search input:focus,
.header-search input:focus {
    border-color: var(--quantum-blue, #00d4ff) !important;
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.2) !important;
    width: 300px;
}

.navbar-search i,
.header-search i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--silver, #9ca3af);
}

/* ============================================
   NOTIFICATION BELL
   ============================================ */

.notification-bell {
    position: relative;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.notification-bell:hover {
    background: rgba(0, 212, 255, 0.1);
}

.notification-bell .badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background: var(--synapse-pink, #ec4899) !important;
    color: white !important;
    font-size: 0.625rem;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   LANGUAGE SELECTOR
   ============================================ */

.language-selector select,
#google_translate_element select {
    background: var(--graphite, #252540) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: var(--platinum, #e5e7eb) !important;
    padding: 8px 12px !important;
    border-radius: 8px !important;
}