/* ============================================================================
   MOBILE MENU STYLES
   ============================================================================ */

/* Hide mobile menu toggle on desktop */
.mobile-menu-toggle {
    display: none;
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile Menu Drawer */
.mobile-menu-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: var(--brand-bg-secondary);
    border-left: 1px solid var(--border-color);
    z-index: 1999;
    display: flex;
    flex-direction: column;
    transition: right 0.3s ease;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.5);
}

.mobile-menu-drawer.active {
    right: 0;
}

/* Mobile Menu Header */
.mobile-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    background: var(--brand-bg-tertiary);
}

.mobile-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.mobile-logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
    border-radius: 8px;
}

.mobile-brand-name {
    font-family: 'Orbitron', 'Rajdhani', 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.875rem;
    letter-spacing: 0.1em;
    background: linear-gradient(135deg, var(--brand-gradient-start) 0%, var(--brand-gradient-mid) 50%, var(--brand-gradient-end) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mobile-menu-close {
    flex-shrink: 0;
}

/* Mobile Navigation Links */
.mobile-nav {
    display: flex;
    flex-direction: column;
    padding: 1.5rem 0;
    overflow-y: auto;
    flex: 1;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    min-height: 48px; /* Accessible touch target */
    color: var(--text-secondary);
    text-decoration: none;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.mobile-nav-link i {
    font-size: 1.25rem;
    width: 24px;
    text-align: center;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link:focus {
    background: rgba(59, 130, 246, 0.1);
    color: var(--text-primary);
    border-left-color: var(--brand-accent);
}

.mobile-nav-link:hover i,
.mobile-nav-link:focus i {
    color: var(--brand-accent);
}

.mobile-nav-link.active {
    background: rgba(59, 130, 246, 0.15);
    color: var(--text-primary);
    border-left-color: var(--brand-accent);
}

.mobile-nav-link.active i {
    color: var(--brand-accent);
}

/* Light Mode Mobile Menu */
.light-mode .mobile-menu-drawer,
.light-theme .mobile-menu-drawer {
    background: #ffffff;
    border-left-color: rgba(0, 0, 0, 0.1);
}

.light-mode .mobile-menu-header,
.light-theme .mobile-menu-header {
    background: #f9fafb;
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

.light-mode .mobile-menu-overlay,
.light-theme .mobile-menu-overlay {
    background: rgba(0, 0, 0, 0.5);
}

/* Better spacing for mobile header */
@media (max-width: 768px) {
    .header-container {
        gap: 0.5rem;
        padding: 0.5rem 0.75rem;
        flex-wrap: nowrap;
        align-items: center;
    }
    
    .header-actions {
        gap: 0.5rem;
        flex-shrink: 0;
        display: flex;
        align-items: center;
    }
    
    .header-brand {
        flex-shrink: 1;
        min-width: 0;
        flex: 1;
    }
    
    .brand-link {
        padding: 0.25rem 0.25rem;
        gap: 0.5rem;
    }
    
    .brand-logo {
        width: 28px;
        height: 28px;
    }
    
    /* Show brand name on mobile */
    .brand-text {
        display: flex !important;
    }
    
    .brand-title {
        font-size: 0.75rem !important;
        letter-spacing: 0.05em !important;
        white-space: nowrap;
    }
    
    .brand-subtitle {
        display: none !important;
    }
    
    .nav-list {
        display: none !important;
    }
    
    /* Hide Contact Me button on mobile */
    .btn-cta {
        display: none !important;
    }
    
    .btn-icon {
        width: 2.25rem;
        height: 2.25rem;
        padding: 0;
    }
    
    .btn-icon i {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .mobile-menu-drawer {
        width: 90%;
        max-width: 280px;
    }
    
    .btn-cta {
        padding: 0;
        width: 2.5rem;
        height: 2.5rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .btn-cta span {
        display: none;
    }
    
    .btn-icon {
        width: 2.5rem;
        height: 2.5rem;
        padding: 0;
    }
    
    .header-actions {
        gap: 0.375rem;
    }
}
