/* ========================================
   MOBILE RESPONSIVE STYLES
   ======================================== */

/* Hide mobile elements on desktop by default */
.mobile-menu-toggle,
.mobile-menu-overlay {
    display: none;
}

/* Mobile Navigation Styles - Active on Mobile Devices */
@media (max-width: 768px) {
    
    /* ========== NAVIGATION BAR ========== */
    
    .navbar {
        padding: 15px 20px;
        flex-wrap: nowrap;
        justify-content: space-between;
    }
    
    /* **UPDATED:** Style the logo for mobile (Restored from previous step) */
    .logo {
        display: block !important; /* Ensure the logo is now visible */
        font-size: 1.8rem; /* Make it bigger */
        color: var(--color-accent-primary); /* Apply the green color */
        font-family: 'Orbitron', sans-serif;
        font-weight: 900;
        text-shadow: 0 0 10px rgba(56, 227, 95, 0.5); /* Add glow */
        flex-shrink: 0; 
    }
    
    /* Hide desktop navigation on mobile */
    .desktop-nav {
        display: none !important;
    }
    
    /* Hide desktop auth container on mobile */
    .desktop-auth {
        display: none !important;
    }
    
    /* Show mobile menu toggle */
    .mobile-menu-toggle {
        /* UPDATED STYLES: Button is now fixed, lowered, and larger (Restored from previous step) */
        position: fixed;
        top: 25px; /* MOVED DOWN */
        right: 20px;
        
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 35px; /* INCREASED */
        height: 28px; /* INCREASED */
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 101;
        transition: all var(--transition-speed);
    }
    
    .hamburger-line {
        width: 100%;
        height: 4px; /* INCREASED for bolder look */
        background: var(--color-accent-primary);
        border-radius: 2px;
        transition: all var(--transition-speed);
        box-shadow: 0 0 10px rgba(56, 227, 95, 0.4);
    }
    
    .mobile-menu-toggle:hover .hamburger-line {
        box-shadow: 0 0 15px rgba(56, 227, 95, 0.6);
    }
    
    .mobile-menu-toggle.active .hamburger-line:nth-child(1) {
        transform: translateY(12px) rotate(45deg); /* Adjusted for new height/line thickness */
    }
    
    .mobile-menu-toggle.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active .hamburger-line:nth-child(3) {
        transform: translateY(-12px) rotate(-45deg); /* Adjusted for new height/line thickness */
    }
    
    /* ========== MOBILE MENU OVERLAY ========== */
    
    .mobile-menu-overlay {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(10, 14, 20, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        z-index: 100;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                    visibility 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
    }
    
    .mobile-menu-overlay.active {
        opacity: 1;
        visibility: visible;
    }
    
    .mobile-menu-content {
        width: 100%;
        height: 100%;
        padding: 80px 25px 30px;
        display: flex;
        flex-direction: column;
        transform: translateY(-20px);
        transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .mobile-menu-overlay.active .mobile-menu-content {
        transform: translateY(0);
    }
    
    .mobile-menu-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 30px;
        padding-bottom: 20px;
        border-bottom: 2px solid var(--color-border-bright);
    }
    
    .mobile-menu-title {
        font-size: 1.8rem;
        font-family: 'Orbitron', sans-serif;
        font-weight: 900;
        background: var(--gradient-primary);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        text-transform: uppercase;
        letter-spacing: 2px;
    }
    
    .mobile-menu-close {
        background: rgba(56, 227, 95, 0.1);
        border: 2px solid var(--color-accent-primary);
        width: 45px;
        height: 45px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all var(--transition-speed);
        color: var(--color-accent-primary);
        font-size: 1.3rem;
    }
    
    .mobile-menu-close:hover {
        background: var(--color-accent-primary);
        color: white;
        transform: rotate(90deg);
        box-shadow: 0 0 20px rgba(56, 227, 95, 0.5);
    }
    
    /* ========== MOBILE AUTH CONTAINER ========== */
    
    .mobile-auth-container {
        margin-bottom: 30px;
        padding: 20px;
        background: rgba(22, 27, 34, 0.6);
        border: 1px solid var(--color-border-bright);
        border-radius: var(--border-radius);
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    
    .mobile-auth-container .login-btn {
        width: 100%;
        justify-content: center;
        padding: 12px 20px;
        font-size: 0.95rem;
    }
    
    .mobile-user-profile {
        display: flex;
        align-items: center;
        gap: 15px;
        width: 100%;
    }
    
    .mobile-user-avatar {
        width: 50px;
        height: 50px;
        border-radius: 50%;
        border: 2px solid var(--color-accent-primary);
        box-shadow: 0 0 15px rgba(56, 227, 95, 0.3);
    }
    
    .mobile-user-info {
        flex-grow: 1;
    }
    
    .mobile-user-name {
        font-size: 1.1rem;
        font-weight: 700;
        color: var(--color-off-white);
        margin-bottom: 2px;
    }
    
    .mobile-user-tag {
        font-size: 0.85rem;
        color: var(--color-muted-text);
    }
    
    .mobile-profile-btn {
        padding: 10px 20px;
        background: var(--gradient-primary);
        border: none;
        border-radius: var(--border-radius-sm);
        color: white;
        font-weight: 600;
        font-size: 0.9rem;
        cursor: pointer;
        transition: all var(--transition-speed);
        box-shadow: 0 4px 15px rgba(56, 227, 95, 0.3);
    }
    
    .mobile-profile-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(56, 227, 95, 0.4);
    }
    
    /* ========== MOBILE NAVIGATION ========== */
    
    .mobile-nav {
        flex-grow: 1;
        margin-bottom: 25px;
    }
    
    .mobile-nav ul {
        list-style: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        gap: 8px;
    }
    
    .mobile-nav-link {
        display: flex;
        align-items: center;
        gap: 15px;
        padding: 18px 20px;
        background: rgba(22, 27, 34, 0.6);
        border: 1px solid var(--color-border-bright);
        border-left: 4px solid transparent;
        border-radius: var(--border-radius-sm);
        color: var(--color-muted-text);
        text-decoration: none;
        font-size: 1rem;
        font-weight: 600;
        transition: all var(--transition-speed);
        position: relative;
        overflow: hidden;
    }
    
    .mobile-nav-link::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 0;
        height: 100%;
        background: rgba(56, 227, 95, 0.1);
        transition: width var(--transition-speed);
    }
    
    .mobile-nav-link:hover::before {
        width: 100%;
    }
    
    .mobile-nav-link i {
        font-size: 1.3rem;
        color: var(--color-accent-primary);
        transition: all var(--transition-speed);
        position: relative;
        z-index: 1;
    }
    
    .mobile-nav-link span {
        position: relative;
        z-index: 1;
    }
    
    .mobile-nav-link:hover,
    .mobile-nav-link.active {
        border-left-color: var(--color-accent-primary);
        color: var(--color-off-white);
        transform: translateX(5px);
        box-shadow: 0 4px 15px rgba(56, 227, 95, 0.2);
    }
    
    .mobile-nav-link.active {
        background: rgba(56, 227, 95, 0.15);
        border-color: var(--color-accent-primary);
        color: var(--color-accent-primary);
    }
    
    .mobile-nav-link:hover i {
        transform: scale(1.15);
        filter: drop-shadow(0 0 8px var(--color-accent-primary));
    }
    
    /* ========== MOBILE QUICK ACTIONS ========== */
    
    .mobile-quick-actions {
        display: flex;
        gap: 12px;
        padding-top: 25px;
        border-top: 2px solid var(--color-border-bright);
    }
    
    .mobile-action-btn {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        padding: 18px 15px;
        background: var(--gradient-primary);
        border: 2px solid var(--color-accent-primary);
        border-radius: var(--border-radius);
        color: white;
        text-decoration: none;
        font-weight: 700;
        font-size: 0.85rem;
        text-align: center;
        transition: all var(--transition-speed);
        box-shadow: 0 4px 15px rgba(56, 227, 95, 0.3);
    }
    
    .mobile-action-btn:hover {
        transform: translateY(-3px);
        box-shadow: 0 8px 25px rgba(56, 227, 95, 0.4);
    }
    
    .mobile-action-btn i {
        font-size: 1.5rem;
    }
    
    /* ========== HERO SECTION ========== */
    
    .hero-section {
        padding: 50px 20px;
        margin-bottom: 50px;
    }
    
    .main-title {
        font-size: 2.2rem;
        letter-spacing: 1px;
        line-height: 1.2;
    }
    
    .tagline {
        font-size: 1rem;
        margin-bottom: 35px;
        line-height: 1.6;
    }
    
    .button-group {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn {
        width: 100%;
        max-width: none;
        padding: 14px 20px;
        font-size: 0.95rem;
    }
    
    /* ========== FEATURES GRID ========== */
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .feature-card {
        padding: 25px;
    }
    
    .feature-icon {
        font-size: 2.5rem;
    }
    
    .feature-card h4 {
        font-size: 1.2rem;
    }
    
    .feature-card p {
        font-size: 0.9rem;
    }
    
    /* ========== STATS SECTION ========== */
    
    .stats-section {
        padding: 50px 20px;
        margin: 50px 0;
    }
    
    .stats-section-title {
        font-size: 1.8rem;
        margin-bottom: 35px;
        letter-spacing: 1px;
    }
    
    .live-stats-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .live-stat-card {
        padding: 25px 20px;
        gap: 15px;
    }
    
    .stat-icon-wrapper {
        width: 65px;
        height: 65px;
    }
    
    .stat-icon-large {
        font-size: 1.8rem;
    }
    
    .stat-info h4 {
        font-size: 0.75rem;
    }
    
    .stat-number {
        font-size: 2.2rem;
    }
    
    /* ========== COMMANDS PAGE ========== */
    
    .page-title {
        font-size: 2.2rem;
        letter-spacing: 1px;
    }
    
    .page-subtitle {
        font-size: 0.95rem;
        margin-bottom: 35px;
    }
    
    .search-panel {
        margin-bottom: 30px;
    }
    
    .search-input {
        padding: 15px 20px;
        font-size: 0.95rem;
    }
    
    .command-list {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    
    .command-card {
        padding: 20px;
    }
    
    .command-card h4 {
        font-size: 1.1rem;
    }
    
    .command-card p {
        font-size: 0.9rem;
    }
    
    /* ========== DOCUMENTATION PAGE ========== */
    
    .documentation-layout {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .docs-sidebar {
        position: static;
        max-height: none;
        margin-bottom: 25px;
        padding: 20px;
    }
    
    .docs-search-input {
        padding: 12px 35px 12px 12px;
        font-size: 0.9rem;
    }
    
    .docs-category-title {
        font-size: 0.7rem;
    }
    
    .docs-nav-item {
        padding: 12px 15px;
        font-size: 0.85rem;
    }
    
    .docs-content {
        padding: 30px 20px;
        min-height: auto;
    }
    
    .docs-article h2 {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }
    
    .docs-article-content {
        font-size: 0.95rem;
        line-height: 1.8;
    }
    
    .docs-welcome h2 {
        font-size: 1.8rem;
    }
    
    .docs-welcome-info h3 {
        font-size: 1.3rem;
        margin-top: 25px;
    }
    
    /* ========== PROFILE PAGE ========== */
    
    .profile-container {
        padding: 30px 15px;
    }
    
    .profile-banner {
        padding: 30px 20px;
    }
    
    .profile-avatar {
        width: 100px;
        height: 100px;
    }
    
    .profile-name {
        font-size: 1.8rem;
        margin-bottom: 8px;
    }
    
    .profile-username {
        font-size: 1rem;
    }
    
    .profile-id-badge {
        font-size: 0.8rem;
        padding: 8px 15px;
    }
    
    .profile-stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .profile-stat-card {
        padding: 20px;
    }
    
    .profile-stat-icon i {
        font-size: 1.8rem;
    }
    
    .profile-stat-value {
        font-size: 2rem;
    }
    
    .profile-actions-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .profile-action-card {
        padding: 18px;
    }
    
    .action-icon-wrapper {
        width: 50px;
        height: 50px;
    }
    
    .action-icon-wrapper i {
        font-size: 1.3rem;
    }
    
    .action-content h4 {
        font-size: 1.0rem;
    }
    
    .action-content p {
        font-size: 0.85rem;
    }
    
    .profile-details-card {
        padding: 25px 20px;
    }
    
    .profile-detail-item {
        padding: 12px 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .profile-detail-label {
        font-size: 0.8rem;
    }
    
    .profile-detail-value {
        font-size: 1rem;
    }
    
    /* ========== TEXT BLOCKS (TERMS & PRIVACY) ========== */
    
    .text-block {
        padding: 30px 20px;
        margin: 0 15px;
    }
    
    .text-block h3 {
        font-size: 1.3rem;
        margin-top: 25px;
        margin-bottom: 12px;
    }
    
    .text-block p, .text-block ul {
        font-size: 0.95rem;
        margin-bottom: 15px;
        line-height: 1.7;
    }
    
    /* ========== FOOTER ========== */
    
    .site-footer {
        /* Reduce overall top margin and padding for a compact mobile footer */
        padding: 20px 20px 20px; /* Reduced top padding from 40px */
        margin-top: 40px; /* Reduced margin from 60px */
    }

    /* **NEW:** Hide the links and actions container */
    .footer-content {
        display: none !important;
    }
    
    /* Original styles for footer links/actions - now overridden by .footer-content display: none
    .footer-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 35px;
    }
    
    .footer-links,
    .footer-actions {
        flex-basis: auto;
        width: 100%;
    }
    */
    
    .footer-credit {
        /* **UPDATED:** Remove top spacing and border above the copyright line */
        margin-top: 0;
        padding-top: 0;
        border-top: none; /* Ensure no border is visible from the credit line */
        font-size: 0.8rem;
    }
    
    /* Removed other footer links/actions styles since they are now hidden */
    
    /* ========== CONTENT CONTAINER ========== */
    
    .content-container {
        margin: 40px auto;
        padding: 0 15px;
    }
    
    .page-content {
        padding: 30px 0;
    }
    
    /* ========== NOTIFICATION BAR ========== */
    
    .notification-bar {
        padding: 15px 25px;
        font-size: 0.9rem;
        border-radius: var(--border-radius-sm);
        width: calc(100% - 30px);
        left: 15px;
        transform: none;
    }
    
    .notification-bar.show {
        transform: translateY(-15px);
    }
}

/* Extra small devices (phones in portrait) */
@media (max-width: 480px) {
    
    .mobile-menu-toggle {
        top: 20px; /* Adjusted to match new main top position */
        right: 15px; /* Adjust right to match new navbar padding */
        width: 30px; /* INCREASED from 25px */
        height: 24px; /* INCREASED from 20px */
    }
    
    .mobile-menu-toggle.active .hamburger-line:nth-child(1) {
        transform: translateY(10px) rotate(45deg); /* Adjusted for new height/line thickness */
    }
    
    .mobile-menu-toggle.active .hamburger-line:nth-child(3) {
        transform: translateY(-10px) rotate(-45deg); /* Adjusted for new height/line thickness */
    }
    
    .hamburger-line {
        height: 4px; /* Must match the main rule */
    }

    /* Keep .logo visible and styled */
    .logo {
        font-size: 1.5rem !important; /* Slightly smaller logo on extra small screens */
    }
    
    .main-title {
        font-size: 1.8rem;
        letter-spacing: 0.5px;
    }
    
    .page-title {
        font-size: 1.8rem;
    }
    
    .tagline {
        font-size: 0.95rem;
    }
    
    .feature-card {
        padding: 20px;
    }
    
    .feature-icon {
        font-size: 2.2rem;
    }
    
    .stats-section-title {
        font-size: 1.5rem;
    }
    
    .stat-icon-wrapper {
        width: 55px;
        height: 55px;
    }
    
    .stat-icon-large {
        font-size: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.8rem;
    }
    
    .mobile-menu-content {
        padding: 70px 20px 25px;
    }
    
    .mobile-menu-title {
        font-size: 1.5rem;
    }
    
    .mobile-nav-link {
        padding: 15px 18px;
        font-size: 0.95rem;
    }
    
    .mobile-nav-link i {
        font-size: 1.2rem;
    }
    
    .mobile-action-btn {
        padding: 15px 12px;
        font-size: 0.8rem;
    }
    
    .mobile-action-btn i {
        font-size: 1.3rem;
    }
    
    .docs-article h2 {
        font-size: 1.5rem;
    }
    
    .profile-name {
        font-size: 1.5rem;
    }
    
    .profile-username {
        font-size: 0.9rem;
    }
}

/* Landscape orientation on small devices */
@media (max-width: 768px) and (orientation: landscape) {
    
    .mobile-menu-overlay {
        overflow-y: auto;
    }
    
    .mobile-menu-content {
        padding: 60px 20px 20px;
    }
    
    .hero-section {
        padding: 40px 20px;
    }
    
    .stats-section {
        padding: 40px 20px;
    }
}