/* ========== MOBILE NAVIGATION ========== */
.mobile-header { display: none; }
.mobile-nav-overlay { display: none; }
.mobile-nav { display: none; }
.mobile-bottom-nav { display: none; }

/* Hide desktop menus on mobile only */
@media (max-width: 768px) {
    
    .dropdown { display: none !important; }
    .box:first-child { display: none; }
    
    .mobile-header {
        display: flex;
        justify-content: flex-start;
        align-items: center;
        padding: 6px 12px;
        background: var(--primary);
        color: white;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1000;
        box-shadow: 0 2px 5px rgba(0,0,0,0.2);
        gap: 6px;
    }
    
    .mobile-logo {
        width: 26px;
        height: 26px;
        border-radius: 4px;
        cursor: pointer;
        flex-shrink: 0;
    }

    .mobile-dl-btn {
        background: rgba(255,255,255,0.15);
        border: none;
        color: white;
        font-size: 15px;
        padding: 3px 7px;
        cursor: pointer;
        min-width: 30px;
        min-height: 30px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 4px;
        margin-left: auto;
    }
    
    .mobile-menu-btn, .mobile-msg-btn {
        background: none;
        border: none;
        color: white;
        font-size: 20px;
        padding: 4px 8px;
        cursor: pointer;
        min-width: 36px;
        min-height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
    }
    
    .mobile-title { 
        font-size: 16px; 
        font-weight: bold; 
        flex: 1;
        text-align: center;
    }
    
    .mobile-msg-btn .msg-badge {
        position: absolute;
        top: 2px;
        right: 0;
        background: #dc3545;
        color: white;
        font-size: 9px;
        font-weight: bold;
        padding: 2px 5px;
        border-radius: 8px;
        min-width: 16px;
        z-index: 1001;
    }
    
    .mobile-nav-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.5);
        z-index: 1001;
    }
    .mobile-nav-overlay.active { display: block; }
    
    .mobile-nav {
        display: block;
        position: fixed;
        top: 0;
        left: -280px;
        width: 280px;
        height: 100%;
        background: white;
        z-index: 1002;
        overflow-y: auto;
        overscroll-behavior: contain;
        transition: left 0.3s ease;
        box-shadow: 2px 0 5px rgba(0,0,0,0.3);
    }
    .mobile-nav.active { left: 0; }
    
    .mobile-nav-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 15px;
        background: #005a8c;
        color: white;
        font-weight: bold;
    }
    .mobile-nav-header button {
        background: none;
        border: none;
        color: white;
        font-size: 20px;
        cursor: pointer;
    }
    
    .mobile-nav-section { padding: 4px 0; }
    .mobile-nav-section a {
        display: block;
        padding: 9px 20px;
        color: #333;
        text-decoration: none;
        border-bottom: 1px solid #f0f0f0;
        font-size: 14px;
    }
    .mobile-nav-section a:hover { background: #f5f5f5; }
    .mobile-nav-label {
        display: block;
        padding: 5px 20px;
        color: #666;
        font-size: 11px;
        font-weight: bold;
        text-transform: uppercase;
    }
    .mobile-nav-divider { height: 1px; background: #ddd; margin: 3px 15px; }
    
    .mobile-bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #f8f9fa;
        border-top: 1px solid #ddd;
        z-index: 999;
        padding-bottom: env(safe-area-inset-bottom);
    }
    .mobile-bottom-nav a {
        flex: 1;
        text-align: center;
        padding: 8px 3px;
        color: #666;
        text-decoration: none;
        font-size: 10px;
        line-height: 1.2;
        white-space: nowrap;
    }
    .mobile-bottom-nav a.active { 
        color: var(--primary); 
        background: #e3f2fd; 
    }
    .mobile-bottom-nav span:first-child { 
        font-size: 16px; 
        display: block;
    }
    
    body { 
        padding-top: 44px; 
        padding-bottom: 55px; 
    }

    /* Reduce excessive background on mobile */
    html, body {
        background: #e0e0de;
    }
    
    .row, .box {
        background: transparent;
    }
    
    .alert-info {
        margin: 10px;
        padding: 12px;
    }
    
    .pwa-banner {
        margin: 10px;
        padding: 12px;
    }

    .timeline-pagination {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        align-items: center;
    }
    .timeline-pagination a {
        white-space: nowrap;
        font-size: 13px;
        padding: 6px 10px !important;
    }
    .timeline-pagination span {
        white-space: nowrap;
    }

    .timeline-table td:first-child,
    .timeline-table td:first-child a {
        white-space: nowrap;
    }
}