/**
 * AI Photo Trend - Modern Navigation System
 * Professional, glassmorphism design with smooth animations
 * No stacking context issues - clean z-index hierarchy
 */

/* ===== MODERN NAVIGATION BAR ===== */
.modern-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: rgba(20, 20, 31, 0.75);
    border-bottom: 1px solid rgba(179, 0, 255, 0.15);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Scrolled state - darker background */
.modern-nav.scrolled {
    background: rgba(20, 20, 31, 0.95);
    box-shadow: 0 4px 32px rgba(0, 0, 0, 0.25);
}

.nav-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0.875rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

/* Logo */
.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: var(--text-primary);
    text-decoration: none;
    flex-shrink: 0;
}

.nav-logo .logo-icon {
    font-size: 1.5rem;
}

.nav-logo .logo-text {
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Desktop Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1;
    justify-content: center;
}

.nav-links li {
    position: relative;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-links a.active {
    color: var(--accent-purple);
}

/* Active indicator underline */
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-red));
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 2px;
}

.nav-links a.active::after,
.nav-links a:hover::after {
    width: 100%;
}

/* Action Buttons */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.nav-actions .btn {
    min-width: 110px;
    text-align: center;
}

/* Mobile Toggle Button */
.mobile-toggle {
    display: none;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-red));
    border: none;
    border-radius: 12px;
    width: 48px;
    height: 48px;
    cursor: pointer;
    position: relative;
    z-index: 10002;
    transition: all 0.3s ease;
    padding: 0;
}

.mobile-toggle:hover {
    box-shadow: 0 6px 20px rgba(179, 0, 255, 0.5);
}

.mobile-toggle:active {
    transform: scale(0.95);
}

/* Hamburger Icon */
.hamburger {
    width: 24px;
    height: 20px;
    position: relative;
    display: inline-block;
}

.hamburger span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: white;
    border-radius: 3px;
    left: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hamburger span:nth-child(1) {
    top: 0;
}

.hamburger span:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
}

.hamburger span:nth-child(3) {
    bottom: 0;
}

/* Animated hamburger when active */
.mobile-toggle.active .hamburger span:nth-child(1) {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
}

.mobile-toggle.active .hamburger span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active .hamburger span:nth-child(3) {
    bottom: 50%;
    transform: translateY(50%) rotate(-45deg);
}

/* ===== MOBILE SIDEBAR NAVIGATION ===== */
.mobile-sidebar {
    position: fixed;
    top: 0;
    left: -100%;
    width: 320px;
    height: 100vh;
    background: linear-gradient(180deg, rgba(17, 17, 34, 0.98), rgba(25, 25, 40, 0.98));
    z-index: 9999;
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 4px 0 32px rgba(0, 0, 0, 0.5);
    border-right: 1px solid rgba(179, 0, 255, 0.2);
}

.mobile-sidebar.active {
    left: 0;
}

.sidebar-header {
    padding: 2rem 1.5rem 1.5rem;
    border-bottom: 1px solid rgba(179, 0, 255, 0.15);
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sidebar-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-red));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.sidebar-user-info h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
    color: var(--text-primary);
}

.sidebar-user-info p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

.sidebar-links {
    list-style: none;
    padding: 1.5rem 1rem;
    margin: 0;
}

.sidebar-links li {
    margin-bottom: 0.5rem;
}

.sidebar-links a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.sidebar-links a:hover {
    background: rgba(179, 0, 255, 0.1);
    color: var(--text-primary);
}

.sidebar-links a.active {
    background: linear-gradient(135deg, rgba(179, 0, 255, 0.2), rgba(255, 0, 107, 0.15));
    color: var(--accent-purple);
    border-left: 3px solid var(--accent-purple);
}

.sidebar-links svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 1.5rem;
    border-top: 1px solid rgba(179, 0, 255, 0.15);
    margin-top: auto;
}

/* Mobile Overlay */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ===== HERO SECTION SPACING ===== */
/* Add top margin to hero sections to account for fixed navbar */
.landing-hero,
.dashboard-hero,
.contact-hero-section,
.profile-hero,
.gallery-section:first-of-type,
.themes-gallery-section:first-of-type,
.plans-page-section:first-of-type {
    margin-top: 70px; /* Navbar height + spacing (30-40px) */
}

/* Theme page - compact header design */
.theme-gen-container {
    margin-top: 0;
    padding-top: 1rem; /* Minimal top padding */
}

.theme-gen-header {
    margin-top: 0; /* Already handled by container padding */
}

/* ===== TABLET & MOBILE - HAMBURGER MENU ===== */
/* Desktop only shows full nav, everything else gets hamburger */
@media (max-width: 1024px) {
    .nav-content {
        padding: 0.75rem 1.5rem;
    }
    
    /* Hide desktop menu, show mobile toggle */
    .nav-links,
    .nav-actions {
        display: none;
    }
    
    .mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* ===== TABLETS ===== */
@media (max-width: 768px) {
    .nav-content {
        padding: 0.75rem 1rem;
    }
    
    .nav-logo {
        font-size: 1rem;
    }
    
    .nav-logo .logo-icon {
        font-size: 1.25rem;
    }
    
    /* Mobile: Adjust hero spacing */
    .landing-hero,
    .dashboard-hero,
    .contact-hero-section,
    .profile-hero,
    .gallery-section:first-of-type,
    .themes-gallery-section:first-of-type,
    .plans-page-section:first-of-type {
        margin-top: 70px; /* Slightly less on mobile */
    }
}

/* ===== MOBILE PHONES ===== */
@media (max-width: 480px) {
    .mobile-sidebar {
        width: 280px;
    }
    
    .nav-logo {
        font-size: 0.9rem;
    }
    
    .mobile-toggle {
        width: 44px;
        height: 44px;
    }
}

