/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

/* Container Layout */
.container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.sidebar {
    width: 260px;
    background: linear-gradient(135deg, #0a2342 0%, #000000 100%);
    color: white;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    z-index: 1000;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-menu {
    list-style: none;
    padding: 20px 0;
}

.menu-item {
    margin: 5px 0;
}

.menu-item a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.menu-item a:hover,
.menu-item.active a {
    background-color: rgba(255,255,255,0.1);
    color: white;
    border-left-color: #fff;
}

.menu-item a i {
    width: 20px;
    margin-right: 12px;
    font-size: 1.1rem;
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background-color: #f5f7fa;
}

/* Top Bar */
.top-bar {
    background: white;
    padding: 15px 30px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border-bottom: 1px solid #e1e5e9;
}

/* Page Header */
.page-header {
    background: white;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e1e5e9;
}

.page-header h1 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2d3748;
    margin: 0;
}

.page-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.top-bar-left h1 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2d3748;
}

.sidebar-toggle {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: #4a5568;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: background-color 0.3s ease;
}

.sidebar-toggle:hover {
    background-color: #f7fafc;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Search Box */
.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box input {
    padding: 10px 40px 10px 15px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    width: 300px;
    font-size: 0.9rem;
    transition: border-color 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-box i {
    position: absolute;
    right: 15px;
    color: #a0aec0;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: #3c81fa;
    color: #ffffff;
}

.btn-primary:hover {
    background: #c7d2fe;
    color: #1a202c;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.12);
}

.btn-secondary {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    color: white;
    border: none;
    box-shadow: 0 2px 8px rgba(74, 85, 104, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(74, 85, 104, 0.4);
}

.btn-outline {
    background-color: transparent;
    color: #4a5568;
    border: 2px solid #e2e8f0;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background-color: #f7fafc;
    border-color: #cbd5e0;
    color: #2d3748;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Update Status Button */
.btn-update-status {
    background: #22c55e;
    color: #fff;
    font-size: 1.08rem;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    min-width: 180px;
    padding: 10px 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(34,197,94,0.08);
    cursor: pointer;
}
.btn-update-status:hover {
    background: #16a34a;
    box-shadow: 0 4px 16px rgba(34,197,94,0.13);
}

/* Content Area */
.content-area {
    padding: 30px;
    flex: 1;
}

/* Filters */
.filters {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 14px 18px 10px 18px;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 18px;
    border: 1px solid #e2e8f0;
    position: relative;
    overflow: hidden;
    min-height: unset;
}

.filters::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

.filters-header {
    margin-bottom: 8px;
    position: relative;
}

.filters-header h2 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.filters-header h2::before {
    content: '';
    width: 4px;
    height: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

.filters-content {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    align-items: flex-end;
    margin-bottom: 0;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 140px;
    margin-bottom: 0;
}

.filter-group label {
    font-weight: 600;
    color: #2d3748;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0px;
}

.filter-group select,
.filter-group input {
    padding: 7px 10px;
    border: 2px solid #e2e8f0;
    border-radius: 7px;
    font-size: 0.9rem;
    min-width: 120px;
    background-color: #ffffff;
    transition: all 0.3s ease;
    font-family: inherit;
    height: 34px;
}

.filter-group select,
.filter-group input[type="date"] {
    min-width: 120px;
    max-width: 150px;
}

.filter-group input[type="text"] {
    min-width: 160px;
    max-width: 200px;
}

.btn,
.btn-secondary,
.btn-outline {
    min-width: 90px;
    height: 36px;
    font-size: 0.95rem;
    padding: 0 18px;
    margin-bottom: 0;
}

/* Table Container */
.table-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    overflow: hidden;
    margin-bottom: 25px;
}

.orders-table {
    width: 100%;
    border-collapse: collapse;
}

.orders-table th {
    background-color: #f8fafc;
    padding: 15px 20px;
    text-align: left;
    font-weight: 600;
    color: #4a5568;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.9rem;
}

.orders-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.9rem;
}

.orders-table tbody tr:hover {
    background-color: #f8fafc;
}

/* Status Badges */
.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-pending {
    background-color: #fef3c7;
    color: #d97706;
}

.status-confirmed {
    background-color: #dbeafe;
    color: #2563eb;
}

.status-processing {
    background-color: #e0e7ff;
    color: #7c3aed;
}

.status-shipped {
    background-color: #d1fae5;
    color: #059669;
}

.status-delivered {
    background-color: #dcfce7;
    color: #16a34a;
}

.status-cancelled {
    background-color: #fee2e2;
    color: #dc2626;
}

/* Customer Status Badges */
.status-active {
    background-color: #c6f6d5;
    color: #22543d;
}

.status-inactive {
    background-color: #fed7d7;
    color: #c53030;
}

.status-vip {
    background-color: #fef5e7;
    color: #d69e2e;
}

.status-new {
    background-color: #e6fffa;
    color: #234e52;
}

/* Driver Status Badges */
.status-on_delivery {
    background-color: #e0e7ff;
    color: #7c3aed;
}

.status-off_duty {
    background-color: #fef3c7;
    color: #d97706;
}

/* Truck Status Badges */
.status-available {
    background-color: #dcfce7;
    color: #16a34a;
}

.status-in_use {
    background-color: #dbeafe;
    color: #2563eb;
}

.status-maintenance {
    background-color: #fef3c7;
    color: #d97706;
}

.status-out_of_service {
    background-color: #fee2e2;
    color: #dc2626;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 8px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-view {
    background-color: #3b82f6;
    color: white;
}

.btn-edit {
    background-color: #f59e0b;
    color: white;
}

.btn-delete {
    background-color: #ef4444;
    color: white;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

.pagination span {
    font-weight: 500;
    color: #4a5568;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        width: 200px;
    }
    
    .search-box input {
        width: 250px;
    }
    .filters-content {
        gap: 10px 10px;
    }
    .filter-group input[type="text"] {
        min-width: 120px;
        max-width: 150px;
    }
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        position: fixed;
        top: 0;
        left: -100%;
        height: 100vh;
        z-index: 1000;
    }
    
    .sidebar.active {
        left: 0;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .top-bar {
        padding: 15px 20px;
    }
    
    .page-header {
        padding: 15px 20px;
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .page-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .content-area {
        padding: 20px;
    }
    
    .filters {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filters-content {
        flex-direction: column;
        gap: 8px;
    }
    
    .filter-group {
        min-width: 100px;
    }
    
    .filter-group label {
        min-width: 80px;
    }
    
    .search-box input {
        width: 200px;
    }
    
    .orders-table {
        font-size: 0.8rem;
    }
    
    .orders-table th,
    .orders-table td {
        padding: 10px 12px;
    }
}

@media (max-width: 480px) {
    .top-bar {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .top-bar-right {
        flex-direction: column;
        gap: 10px;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .orders-table {
        display: block;
        overflow-x: auto;
    }
} 