/* GPS Fleet Tracker - Live Tracking Page */

:root {
    --primary-color: #3b82f6;
    --primary-dark: #2563eb;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--gray-100);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Top Navigation */
.top-navbar {
    background: white;
    box-shadow: var(--shadow-md);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: 64px;
}

.nav-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--primary-color);
}

.brand-icon {
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    gap: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    color: var(--gray-600);
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background: var(--gray-100);
    color: var(--primary-color);
}

.nav-link.active {
    background: var(--primary-color);
    color: white;
}

.btn-logout {
    padding: 0.5rem 1rem;
    background: var(--danger-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: #dc2626;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--gray-600);
}

/* Side Panel (Mobile) */
.side-panel-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1999;
    display: none;
}

.side-panel-overlay.show {
    display: block;
}

.side-panel {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    z-index: 2000;
    transition: left 0.3s ease;
    display: flex;
    flex-direction: column;
}

.side-panel.open {
    left: 0;
}

.side-panel-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.side-panel-content {
    flex: 1;
    padding: 1rem 0;
}

.side-nav-link {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--gray-700);
    text-decoration: none;
    transition: all 0.3s ease;
}

.side-nav-link:hover,
.side-nav-link.active {
    background: var(--primary-color);
    color: white;
}

.side-panel-logout {
    padding: 1.5rem;
    border-top: 1px solid var(--gray-200);
}

/* Main Container */
.main-container {
    display: flex;
    margin-top: 64px;
    height: calc(100vh - 64px);
}

/* Vehicle Sidebar */
.vehicle-sidebar {
    width: 320px;
    background: white;
    border-right: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

/* Mobile elements - hidden on desktop */
.mobile-fab-vehicles,
.mobile-fab-menu,
.mobile-sidebar-overlay,
.mobile-nav-overlay,
.mobile-sidebar-close,
.mobile-nav-sidebar {
    display: none;
}

.sidebar-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--gray-200);
}

.sidebar-header h3 {
    font-size: 1.1rem;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.vehicle-stats {
    display: flex;
    gap: 1rem;
}

.vehicle-stats .stat {
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 1rem;
}

.vehicle-stats .stat.online {
    background: #dcfce7;
    color: #166534;
}

.vehicle-stats .stat.offline {
    background: #fee2e2;
    color: #991b1b;
}

.search-box {
    padding: 0.75rem 1.25rem;
    position: relative;
}

.search-box input {
    width: 100%;
    padding: 0.6rem 1rem 0.6rem 2.5rem;
    border: 1px solid var(--gray-300);
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-box .search-icon {
    position: absolute;
    left: 1.75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.9rem;
}

.filter-buttons {
    display: flex;
    gap: 0.5rem;
    padding: 0 1.25rem 0.75rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.4rem 0.75rem;
    border: 1px solid var(--gray-300);
    background: white;
    border-radius: 2rem;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: var(--gray-100);
}

.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.vehicle-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
}

.loading-vehicles {
    text-align: center;
    padding: 2rem;
    color: var(--gray-500);
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Vehicle Card */
.vehicle-card {
    padding: 0.875rem;
    border: 1px solid var(--gray-200);
    border-radius: 0.75rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.vehicle-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.vehicle-card.selected {
    border-color: var(--primary-color);
    background: #eff6ff;
}

.vehicle-card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.vehicle-card-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.vehicle-card-icon.moving {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.vehicle-card-icon.stopped {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.vehicle-card-icon.offline {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

.vehicle-card-info {
    flex: 1;
    min-width: 0;
}

.vehicle-card-name {
    font-weight: 600;
    color: var(--gray-800);
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vehicle-card-device {
    font-size: 0.75rem;
    color: var(--gray-500);
}

.vehicle-card-status {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    border-radius: 1rem;
    font-weight: 500;
}

.vehicle-card-status.online {
    background: #dcfce7;
    color: #166534;
}

.vehicle-card-status.offline {
    background: #fee2e2;
    color: #991b1b;
}

.vehicle-card-details {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--gray-600);
}

.vehicle-card-details span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.sidebar-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.btn-refresh {
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.btn-refresh:hover {
    background: var(--primary-dark);
}

.last-update {
    font-size: 0.75rem;
    color: var(--gray-500);
}

/* Map Container */
.map-container {
    flex: 1;
    position: relative;
}

#map {
    width: 100%;
    height: 100%;
}

/* Map Controls */
.map-controls {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    z-index: 500;
}

.map-btn {
    width: 40px;
    height: 40px;
    background: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1.25rem;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-btn:hover {
    background: var(--gray-100);
    transform: scale(1.05);
}

.map-btn.active {
    background: var(--primary-color);
    color: white;
}

/* Vehicle Info Panel */
.vehicle-info-panel {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    width: 360px;
    background: white;
    border-radius: 1rem;
    box-shadow: var(--shadow-lg);
    z-index: 500;
    overflow: hidden;
}

.close-panel {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 28px;
    height: 28px;
    background: var(--gray-100);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close-panel:hover {
    background: var(--gray-200);
}

.info-header {
    padding: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.vehicle-icon {
    font-size: 2rem;
}

.vehicle-title {
    flex: 1;
}

.vehicle-title h3 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.device-id {
    font-size: 0.75rem;
    opacity: 0.9;
}

.status-indicator {
    padding: 0.3rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(255,255,255,0.2);
}

.status-indicator.online {
    background: #10b981;
}

.status-indicator.offline {
    background: #ef4444;
}

.info-body {
    padding: 1rem;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--gray-100);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-size: 0.85rem;
    color: var(--gray-600);
}

.info-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gray-800);
}

.info-actions {
    padding: 0.75rem 1rem;
    background: var(--gray-50);
    display: flex;
    gap: 0.5rem;
}

.info-actions .btn-action {
    flex: 1;
    padding: 0.5rem;
    border: 1px solid var(--gray-300);
    background: white;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.info-actions .btn-action:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Map Legend */
.map-legend {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow-md);
    z-index: 500;
    display: flex;
    gap: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--gray-600);
}

.legend-marker {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.legend-marker.moving {
    background: #10b981;
}

.legend-marker.stopped {
    background: #f59e0b;
}

.legend-marker.offline {
    background: #6b7280;
}

/* Custom Leaflet Markers */
.custom-marker {
    position: relative;
}

.marker-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    border: 3px solid white;
    transition: transform 0.3s ease;
}

.marker-icon.moving {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.marker-icon.stopped {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.marker-icon.offline {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

.marker-icon:hover {
    transform: scale(1.2);
}

.marker-label {
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 10px;
    white-space: nowrap;
}

/* Leaflet Popup Customization */
.leaflet-popup-content-wrapper {
    border-radius: 0.75rem;
    padding: 0;
}

.leaflet-popup-content {
    margin: 0;
    min-width: 200px;
}

.popup-content {
    padding: 1rem;
}

.popup-header {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--gray-800);
}

.popup-detail {
    font-size: 0.85rem;
    color: var(--gray-600);
    margin-bottom: 0.25rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .vehicle-sidebar {
        width: 280px;
    }
    
    .vehicle-info-panel {
        width: 320px;
    }
}

/* ==========================================
   MOBILE-FIRST GPS TRACKING APP EXPERIENCE
   Full-screen map with slide-out panels
   ========================================== */
@media (max-width: 768px) {
    /* Hide desktop navigation */
    .nav-menu,
    .nav-actions {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    /* Top navbar - slimmer on mobile */
    .top-navbar {
        height: 56px;
    }
    
    .nav-container {
        height: 56px;
        padding: 0 1rem;
    }
    
    .nav-brand {
        font-size: 1.1rem;
    }
    
    /* Main container - full screen map */
    .main-container {
        margin-top: 56px;
        height: calc(100vh - 56px);
        position: relative;
    }
    
    /* Vehicle Sidebar - Hidden by default, slides from left */
    .vehicle-sidebar {
        position: fixed;
        top: 56px;
        left: -100%;
        width: 85%;
        max-width: 320px;
        height: calc(100vh - 56px);
        z-index: 1500;
        transition: left 0.3s ease;
        border-right: none;
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
    }
    
    .vehicle-sidebar.mobile-open {
        left: 0;
    }
    
    /* Sidebar overlay for mobile */
    .mobile-sidebar-overlay {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1400;
        display: none;
        opacity: 0;
        transition: opacity 0.3s ease;
    }
    
    .mobile-sidebar-overlay.show {
        display: block;
        opacity: 1;
    }
    
    /* Mobile Navigation Overlay */
    .mobile-nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 2000;
        display: none;
        opacity: 0;
        transition: opacity 0.3s ease;
    }
    
    .mobile-nav-overlay.show {
        display: block;
        opacity: 1;
    }
    
    /* Mobile Navigation Sidebar */
    .mobile-nav-sidebar {
        position: fixed;
        top: 0;
        right: -280px;
        width: 280px;
        height: 100vh;
        background: white;
        z-index: 2100;
        display: flex;
        flex-direction: column;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
        transition: right 0.3s ease;
    }
    
    .mobile-nav-sidebar.open {
        right: 0;
    }
    
    .mobile-nav-header {
        padding: 20px;
        background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
        color: white;
        display: flex;
        align-items: center;
        gap: 12px;
    }
    
    .mobile-nav-header .brand-icon {
        font-size: 1.8rem;
    }
    
    .mobile-nav-header .brand-text {
        font-size: 1.2rem;
        font-weight: 600;
        flex: 1;
    }
    
    .mobile-nav-close {
        background: rgba(255, 255, 255, 0.2);
        border: none;
        color: white;
        width: 32px;
        height: 32px;
        border-radius: 50%;
        font-size: 1.2rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .mobile-nav-menu {
        flex: 1;
        padding: 16px 0;
        overflow-y: auto;
    }
    
    .mobile-nav-link {
        display: flex;
        align-items: center;
        gap: 16px;
        padding: 16px 24px;
        color: var(--gray-700);
        text-decoration: none;
        font-size: 1rem;
        transition: all 0.2s ease;
        border-left: 4px solid transparent;
    }
    
    .mobile-nav-link:hover {
        background: var(--gray-50);
        color: var(--primary-color);
    }
    
    .mobile-nav-link.active {
        background: #eff6ff;
        color: var(--primary-color);
        border-left-color: var(--primary-color);
        font-weight: 600;
    }
    
    .mobile-nav-link .nav-icon {
        font-size: 1.3rem;
        width: 28px;
        text-align: center;
    }
    
    .mobile-nav-footer {
        padding: 20px;
        border-top: 1px solid var(--gray-200);
    }
    
    .btn-logout-mobile {
        width: 100%;
        padding: 14px 20px;
        background: var(--danger-color);
        color: white;
        border: none;
        border-radius: 10px;
        font-size: 1rem;
        font-weight: 500;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        transition: background 0.2s ease;
    }
    
    .btn-logout-mobile:hover {
        background: #dc2626;
    }
    
    /* Mobile FAB for menu - bottom left */
    .mobile-fab-menu {
        position: fixed;
        bottom: 24px;
        left: 16px;
        width: 52px;
        height: 52px;
        background: white;
        color: var(--gray-700);
        border: none;
        border-radius: 50%;
        font-size: 1.4rem;
        cursor: pointer;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
        z-index: 1000;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }
    
    .mobile-fab-menu:hover,
    .mobile-fab-menu:active {
        transform: scale(1.1);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    }
    
    /* Map container - full screen */
    .map-container {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        height: 100%;
    }
    
    #map {
        height: 100%;
    }
    
    /* Floating Action Button to open vehicle list - above menu FAB */
    .mobile-fab-vehicles {
        position: fixed;
        bottom: 90px;
        left: 16px;
        width: 56px;
        height: 56px;
        background: var(--primary-color);
        color: white;
        border: none;
        border-radius: 50%;
        font-size: 1.5rem;
        cursor: pointer;
        box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
        z-index: 1000;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }
    
    .mobile-fab-vehicles:hover,
    .mobile-fab-vehicles:active {
        transform: scale(1.1);
        box-shadow: 0 6px 16px rgba(59, 130, 246, 0.5);
    }
    
    .mobile-fab-vehicles .fab-badge {
        position: absolute;
        top: -4px;
        right: -4px;
        background: var(--success-color);
        color: white;
        font-size: 0.7rem;
        font-weight: 600;
        padding: 2px 6px;
        border-radius: 10px;
        min-width: 20px;
        text-align: center;
    }
    
    /* Map controls - repositioned for mobile */
    .map-controls {
        position: fixed;
        bottom: 100px;
        right: 16px;
        z-index: 1000;
        flex-direction: column;
        gap: 8px;
    }
    
    .map-btn {
        width: 44px;
        height: 44px;
        font-size: 1.2rem;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    }
    
    /* Map legend - compact and repositioned */
    .map-legend {
        position: fixed;
        top: 70px;
        left: 50%;
        transform: translateX(-50%);
        bottom: auto;
        right: auto;
        flex-direction: row;
        gap: 12px;
        padding: 8px 16px;
        font-size: 0.75rem;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.95);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .legend-item span:last-child {
        display: none;
    }
    
    .legend-marker {
        width: 10px;
        height: 10px;
    }
    
    /* Vehicle Info Panel - Bottom sheet style */
    .vehicle-info-panel {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        max-height: 70vh;
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
        z-index: 1300;
        transform: translateY(100%);
        transition: transform 0.3s ease;
        overflow-y: auto;
    }
    
    .vehicle-info-panel.mobile-show {
        transform: translateY(0);
    }
    
    /* Add drag handle to info panel */
    .vehicle-info-panel::before {
        content: '';
        position: absolute;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
        width: 40px;
        height: 4px;
        background: var(--gray-300);
        border-radius: 2px;
    }
    
    .vehicle-info-panel .close-panel {
        position: absolute;
        top: 12px;
        right: 16px;
        width: 32px;
        height: 32px;
        font-size: 1.2rem;
    }
    
    .info-header {
        padding: 24px 16px 16px;
    }
    
    .info-body {
        padding: 0 16px 16px;
    }
    
    .info-row {
        padding: 10px 0;
    }
    
    .info-actions {
        padding: 16px;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .btn-action {
        padding: 10px 8px;
        font-size: 0.8rem;
    }
    
    /* Vehicle card optimizations for mobile sidebar */
    .vehicle-card {
        padding: 12px;
        margin-bottom: 8px;
    }
    
    .vehicle-card-header {
        margin-bottom: 8px;
    }
    
    .vehicle-card-icon {
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
    }
    
    .vehicle-card-name {
        font-size: 0.9rem;
    }
    
    .vehicle-card-details {
        font-size: 0.7rem;
        gap: 8px;
    }
    
    /* Search box in sidebar */
    .search-box {
        padding: 12px 16px;
    }
    
    .search-box input {
        padding: 10px 12px 10px 40px;
        font-size: 1rem;
    }
    
    /* Filter buttons */
    .filter-buttons {
        padding: 0 16px 12px;
        gap: 6px;
    }
    
    .filter-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    /* Sidebar header */
    .sidebar-header {
        padding: 16px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    
    .sidebar-header h3 {
        font-size: 1.1rem;
        margin-bottom: 0;
    }
    
    .vehicle-stats {
        gap: 8px;
    }
    
    .vehicle-stats .stat {
        font-size: 0.75rem;
        padding: 4px 8px;
    }
    
    /* Sidebar close button for mobile */
    .mobile-sidebar-close {
        display: block;
        position: absolute;
        top: 16px;
        right: 16px;
        width: 32px;
        height: 32px;
        background: var(--gray-100);
        border: none;
        border-radius: 50%;
        font-size: 1.2rem;
        cursor: pointer;
        z-index: 10;
    }
    
    /* Sidebar footer */
    .sidebar-footer {
        padding: 12px 16px;
        flex-direction: column;
        gap: 8px;
    }
    
    .btn-refresh {
        width: 100%;
        padding: 12px;
        font-size: 0.9rem;
    }
    
    .last-update {
        text-align: center;
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .vehicle-sidebar {
        width: 100%;
        max-width: none;
    }
    
    .vehicle-card-details {
        flex-wrap: wrap;
    }
    
    .filter-buttons {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }
    
    .filter-btn {
        flex-shrink: 0;
    }
    
    .info-actions {
        grid-template-columns: 1fr;
    }
    
    .btn-action {
        padding: 12px;
    }
    
    .mobile-fab-vehicles {
        bottom: 85px;
        left: 12px;
        width: 50px;
        height: 50px;
    }
    
    .mobile-fab-menu {
        bottom: 20px;
        left: 12px;
        width: 48px;
        height: 48px;
    }
    
    .map-controls {
        bottom: 20px;
        right: 12px;
    }
    
    .map-btn {
        width: 40px;
        height: 40px;
    }
}
