/* kTripz Passenger Portal - Unified Premium Responsive Sidebar */
:root {
    --brand-yellow: #F59E0B;
    --brand-dark: #0F172A;
    --brand-muted: #F1F5F9;
    --text-main: #0F172A;
    --text-dim: #64748B;
    --bg-white: #FFFFFF;
    --glass: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(15, 23, 42, 0.08);
    --sidebar-w: 280px;
    --transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Sidebar Core */
.sidebar { 
    width: var(--sidebar-w); 
    background: var(--glass);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-right: 1px solid var(--glass-border); 
    display: flex; 
    flex-direction: column; 
    padding: 32px 20px; 
    position: fixed; 
    top: 0; bottom: 0; 
    left: 0; 
    z-index: 1200;
    transition: var(--transition);
    height: 100vh;
}

/* Branding */
.brand { 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    gap: 8px; 
    margin-bottom: 40px; 
    padding: 0 12px;
}
.brand-logo { 
    font-size: 32px; 
    font-weight: 800; 
    letter-spacing: -1.5px; 
    color: var(--brand-dark); 
}
.brand-logo span { color: var(--brand-yellow); }
.brand-tagline { 
    font-size: 11px; 
    font-weight: 800; 
    color: var(--text-dim); 
    text-transform: uppercase; 
    letter-spacing: 2px; 
    opacity: 0.7;
}

/* Navigation Links */
.nav-links { 
    display: flex; 
    flex-direction: column; 
    gap: 6px; 
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }

.nav-link { 
    display: flex; 
    align-items: center; 
    gap: 14px; 
    padding: 14px 18px; 
    border-radius: 20px; 
    text-decoration: none; 
    color: var(--text-dim); 
    font-size: 14px; 
    font-weight: 700; 
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: 1px solid transparent;
}

.nav-link:hover { 
    background: var(--brand-muted); 
    color: var(--brand-dark); 
    transform: translateX(4px); 
}

.nav-link.active { 
    background: var(--brand-dark); 
    color: #FFFFFF; 
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.15);
    border-color: rgba(255,255,255,0.1);
}

.nav-link i { flex-shrink: 0; opacity: 0.8; }
.nav-link.active i { color: var(--text-dim); opacity: 1; }

.nav-badge {
    margin-left: auto;
    font-size: 12px;
    font-weight: 800;
    color: var(--text-dim);
    background: transparent;
    padding: 0;
    border-radius: 8px;
}
.nav-link.active .nav-badge { background: transparent; color: rgba(255,255,255,0.7); }

/* Responsive Breakpoints */

/* Tier 1: Small Desktop/Tablet/Mobile (Toggle Mode) */
@media (max-width: 1200px) {
    .sidebar { 
        transform: translateX(-100%); 
        box-shadow: none;
    }
    .sidebar.open { 
        transform: translateX(0); 
        box-shadow: 30px 0 60px rgba(15, 23, 42, 0.15); 
    }
    .close-sidebar { 
        display: grid !important; 
        position: absolute;
        top: 24px; right: 20px;
        width: 40px; height: 40px;
        border-radius: 12px;
        background: var(--brand-muted);
        border: none;
        color: var(--text-main);
        place-items: center;
        cursor: pointer;
        z-index: 10;
        transition: 0.3s;
    }
    .close-sidebar:hover { background: #fee2e2; color: #ef4444; }
}

/* Tier 2: Large Desktop (Always Visible) */
@media (min-width: 1201px) {
    .close-sidebar { display: none !important; }
    .sidebar { transform: translateX(0); }
}

/* Backdrop */
.backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}
.backdrop.active { opacity: 1; visibility: visible; }
