/* Ultra Professional Navigation Styles - HIDDEN */
.navbar {
    display: none !important;
}

.navbar.scrolled {
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(35px);
    -webkit-backdrop-filter: blur(35px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 50px rgba(0, 0, 0, 0.3);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

/* Ultra Professional Logo Design */
.nav-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.4s ease;
    letter-spacing: -0.03em;
    font-family: 'Inter', 'Poppins', sans-serif;
}

.nav-logo:hover {
    transform: translateY(-1px);
    color: #fbbf24;
}

.nav-logo img {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.08);
    transition: all 0.4s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.nav-logo:hover img {
    border-color: rgba(251, 191, 36, 0.5);
    box-shadow: 0 8px 30px rgba(251, 191, 36, 0.25);
    transform: scale(1.05);
}

/* Ultra Clean Navigation Menu */
.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.25rem;
    align-items: center;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: -0.02em;
    line-height: 1.5;
    font-family: 'Inter', 'Poppins', sans-serif;
    background: transparent;
    border: 1px solid transparent;
}

.nav-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.nav-link.active {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.2), rgba(251, 191, 36, 0.1));
    color: #fbbf24;
    font-weight: 600;
    border-color: rgba(251, 191, 36, 0.3);
    box-shadow: 0 4px 20px rgba(251, 191, 36, 0.15);
}

/* Ultra Professional Dropdown Styles */
.nav-dropdown {
    position: relative;
}

.nav-link.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding-right: 1.25rem;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1rem 0;
    min-width: 320px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px) scale(0.95);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9999;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
    margin-top: 0;
}

.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.dropdown-item {
    display: block;
    padding: 1rem 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 0.95rem;
    letter-spacing: -0.02em;
    position: relative;
    border-left: 3px solid transparent;
    font-family: 'Inter', 'Poppins', sans-serif;
}

.dropdown-item:hover {
    background: linear-gradient(90deg, rgba(251, 191, 36, 0.1), rgba(251, 191, 36, 0.05));
    color: #fbbf24;
    border-left-color: #fbbf24;
    padding-left: 1.75rem;
}

.dropdown-icon {
    font-size: 0.75rem;
    transition: transform 0.4s ease;
    opacity: 0.8;
    margin-left: auto;
}

.nav-dropdown:hover .dropdown-icon {
    transform: rotate(180deg);
    opacity: 1;
    color: #fbbf24;
}

/* Ultra Professional CTA Button */
.nav-cta {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #000;
    padding: 0.875rem 2rem;
    border-radius: 14px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.3);
    letter-spacing: -0.02em;
    margin-left: 1rem;
    font-family: 'Inter', 'Poppins', sans-serif;
    position: relative;
    overflow: hidden;
}

.nav-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.nav-cta:hover::before {
    left: 100%;
}

.nav-cta:hover {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(251, 191, 36, 0.4);
    color: #000;
}

/* Ultra Professional Floating Mobile Menu Toggle */
.mobile-menu-toggle {
    display: flex !important; /* Always visible */
    position: fixed !important;
    top: 25px !important;
    right: 25px !important;
    flex-direction: column;
    justify-content: center;
    width: 50px !important;
    height: 50px !important;
    background: rgba(0, 0, 0, 0.85) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 2px solid rgba(255, 255, 255, 0.15) !important;
    border-radius: 15px !important;
    cursor: pointer !important;
    /* Ensure toggle stays above everything else */
    z-index: 99999 !important;
    padding: 8px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3) !important;
    /* Additional properties to force fixed positioning */
    transform: translateZ(0) !important;
    will-change: transform !important;
    contain: layout !important;
}

.mobile-menu-toggle:hover {
    background: rgba(0, 0, 0, 0.95);
    border-color: rgba(251, 191, 36, 0.4);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4), 0 0 0 4px rgba(251, 191, 36, 0.1);
}

.hamburger-line {
    width: 26px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
    background: #fbbf24;
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
    transform: translateX(20px);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
    background: #fbbf24;
}

/* Modern Professional Mobile Menu - Complete Redesign */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(180deg, #0a0a0a 0%, #1a1a1a 100%);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    /* Ensure the mobile menu overlays all page elements, including scroll-progress */
    z-index: 99998 !important;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    transform: scale(0.95);
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

/* Desktop Menu Style - Clean Sidebar */
@media (min-width: 768px) {
    .mobile-menu {
        width: 450px;
        left: auto;
        right: 0;
        background: linear-gradient(180deg, #0f0f0f 0%, #1f1f1f 100%);
        border-left: 1px solid rgba(255, 255, 255, 0.1);
        transform: translateX(100%);
        box-shadow: -10px 0 50px rgba(0, 0, 0, 0.8);
    }
    
    .mobile-menu.active {
        transform: translateX(0);
    }
    
    .mobile-menu::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: calc(100vw - 450px);
        height: 100vh;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(5px);
        opacity: 0;
        transition: opacity 0.5s ease;
        z-index: -1;
    }
    
    .mobile-menu.active::before {
        opacity: 1;
    }
}

.mobile-nav-menu {
    display: flex;
    flex-direction: column;
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
    max-width: 400px;
}

/* Desktop navigation menu styling */
@media (min-width: 768px) {
    .mobile-nav-menu {
        padding: 3rem 2.5rem 2rem 2.5rem;
        max-width: 100%;
    }
}

.mobile-nav-link {
    display: block;
    color: #ffffff;
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 400;
    padding: 1rem 0;
    margin: 0.3rem 0;
    text-align: center;
    position: relative;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
    transition: all 0.4s ease;
    transform: translateX(-50%);
}

.mobile-nav-link:hover {
    color: #fbbf24;
    transform: translateY(25px);
}

.mobile-nav-link:hover::after {
    width: 60px;
}

/* Desktop navigation links */
@media (min-width: 768px) {
    .mobile-nav-link {
        text-align: left;
        font-size: 1.1rem;
        padding: 1.2rem 0;
        margin: 0.2rem 0;
        border-left: 3px solid transparent;
        padding-left: 1.5rem;
        transform: translateX(30px);
        animation: slideInRight 0.8s ease forwards;
    }

    .mobile-nav-link::after {
        left: 0;
        width: 0;
        height: 1px;
        background: #fbbf24;
        bottom: 0.5rem;
        transform: none;
    }

    .mobile-nav-link:hover {
        border-left-color: #fbbf24;
        transform: translateX(20px);
        background: rgba(251, 191, 36, 0.05);
    }

    .mobile-nav-link:hover::after {
        width: calc(100% - 1.5rem);
    }
}

.mobile-nav-link:nth-child(1) { animation-delay: 0.1s; }
.mobile-nav-link:nth-child(2) { animation-delay: 0.2s; }
.mobile-nav-link:nth-child(3) { animation-delay: 0.3s; }
.mobile-nav-link:nth-child(4) { animation-delay: 0.4s; }
.mobile-nav-link:nth-child(5) { animation-delay: 0.5s; }
.mobile-nav-link:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Mobile Dropdown Styles */
.mobile-dropdown-container {
    position: relative;
}

.mobile-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

/* Icon-only toggle button next to the Courses link */
.mobile-dropdown-toggle {
    background: transparent;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 0.5rem 0.25rem;
    display: inline-flex;
    align-items: center;
}

.mobile-dropdown-toggle i {
    transition: transform 0.3s ease;
    font-size: 0.875rem;
    margin-left: 0.5rem;
}

.mobile-dropdown-container.active .mobile-dropdown-toggle i {
    transform: rotate(180deg);
}

.mobile-dropdown-menu {
    max-height: 0;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    margin-top: 0.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateY(-10px);
}

.mobile-dropdown-container.active .mobile-dropdown-menu {
    max-height: 400px;
    opacity: 1;
    transform: translateY(0);
}

/* Desktop: Open mobile sidebar submenu on hover as well */
@media (min-width: 768px) {
    .mobile-dropdown-container:hover .mobile-dropdown-menu {
        max-height: 400px;
        opacity: 1;
        transform: translateY(0);
    }
    .mobile-dropdown-container:hover .mobile-dropdown-toggle i {
        transform: rotate(180deg);
    }
}

.mobile-dropdown-link {
    display: block;
    padding: 0.75rem 1rem;
    color: #ffffff;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 300;
    transition: all 0.3s ease;
    border-left: 2px solid transparent;
    opacity: 0;
    transform: translateX(-20px);
    animation: fadeInUp 0.6s ease forwards;
}

.mobile-dropdown-link:hover {
    color: #fbbf24;
    border-left-color: #fbbf24;
    background: rgba(251, 191, 36, 0.1);
    transform: translateX(5px);
}

/* Desktop dropdown styles */
@media (min-width: 768px) {
    .mobile-dropdown-menu {
        background: rgba(17, 24, 39, 0.9);
        margin-left: 1.5rem;
        border-radius: 12px;
        backdrop-filter: blur(10px);
        border: 1px solid rgba(251, 191, 36, 0.2);
    }
    
    .mobile-dropdown-link {
        padding: 1rem 1.5rem;
        font-size: 1rem;
        animation: slideInRight 0.6s ease forwards;
    }
    
    .mobile-dropdown-link:hover {
        background: rgba(251, 191, 36, 0.1);
        transform: translateX(10px);
    }
}

/* Remove old mobile hover effects */
@media (max-width: 767px) {
    .mobile-nav-link:hover, .mobile-nav-link:focus {
        color: #fbbf24;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInLeft {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.mobile-nav-link:hover {
    background: rgba(251, 191, 36, 0.1);
    border-color: rgba(251, 191, 36, 0.3);
    color: #fbbf24;
    transform: translateY(-2px);
}

.mobile-nav-cta {
    display: inline-block;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #000000;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    margin-top: 2.5rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.8s;
    box-shadow: 0 4px 20px rgba(251, 191, 36, 0.3);
    letter-spacing: 0.5px;
}

.mobile-nav-cta:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 30px rgba(251, 191, 36, 0.5);
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

/* Desktop CTA styling */
@media (min-width: 768px) {
    .mobile-nav-cta {
        margin-top: 3rem;
        margin-left: 1.5rem;
        padding: 0.9rem 2rem;
        border-radius: 30px;
        transform: translateX(30px);
        animation: slideInRight 0.8s ease forwards;
        animation-delay: 0.9s;
    }
    
    .mobile-nav-cta:hover {
        transform: translateX(0) translateY(-3px) scale(1.02);
    }
}



/* Responsive adjustments for floating hamburger */
@media (max-width: 480px) {
    .mobile-menu-toggle {
        top: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    .hamburger-line {
        width: 24px;
        height: 2.5px;
    }
}

/* Mobile menu is now always available */

/* Floating hamburger pulse animation */
@keyframes floatingPulse {
    0%, 100% { 
        transform: translateY(0) scale(1); 
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3); 
    }
    50% { 
        transform: translateY(-2px) scale(1.02); 
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4); 
    }
}

.mobile-menu-toggle {
    animation: floatingPulse 3s ease-in-out infinite;
}

.mobile-menu-toggle:hover {
    animation: none; /* Stop pulse on hover */
}

/* No scroll offset needed since no fixed navbar */
html {
    scroll-padding-top: 0;
}

/* Active section highlighting - Enhanced */
.nav-link.active-section {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.25), rgba(251, 191, 36, 0.15));
    color: #fbbf24;
    font-weight: 600;
    border-color: rgba(251, 191, 36, 0.4);
    box-shadow: 0 4px 20px rgba(251, 191, 36, 0.2);
}

/* Enhanced dropdown positioning and styling */
.navbar .nav-dropdown {
    position: relative !important;
}

.navbar .nav-dropdown .dropdown-menu {
    position: absolute !important;
    top: calc(100% + 12px) !important;
    left: 0 !important;
    right: auto !important;
    transform-origin: top center !important;
    width: max-content !important;
    min-width: 320px !important;
    max-width: 400px !important;
}

/* Enhanced dropdown items styling */
.navbar .dropdown-item {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    border-radius: 8px !important;
    margin: 0 0.5rem !important;
}

/* Professional loading state */
.navbar.loading {
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

/* Professional focus states for accessibility */
.nav-link:focus,
.nav-cta:focus,
.dropdown-item:focus {
    outline: 2px solid rgba(251, 191, 36, 0.5);
    outline-offset: 2px;
    border-radius: 8px;
}

/* Enhanced navbar background gradient */
.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.98) 0%, rgba(0, 0, 0, 0.95) 100%);
    z-index: -1;
}

/* Professional separator in dropdown */
.dropdown-item.separator {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 0.5rem;
    padding-top: 1rem;
}

/* CRITICAL OVERRIDE: Ensure mobile menu toggle is always fixed positioned */
button.mobile-menu-toggle,
.mobile-menu-toggle {
    position: fixed !important;
    top: 25px !important;
    right: 25px !important;
    z-index: 99999 !important;
    transform: translateZ(0) !important;
    will-change: transform !important;
}
