/* ========================================
   TRIBAL MVD - UNIFIED STYLESHEET
   Grey & Blue Theme
   ======================================== */

/* CSS Variables - Color Palette */
:root {
    --primary: #2c3e50;        /* Dark slate blue */
    --secondary: #34495e;      /* Charcoal grey */
    --accent: #3498db;         /* Bright blue */
    --accent-dark: #2980b9;    /* Darker blue */
    --surface: #ecf0f1;        /* Light grey */
    --surface-dark: #bdc3c7;   /* Medium grey */
    --success: #27ae60;        /* Green */
    --danger: #e74c3c;         /* Red */
    --warning: #f39c12;        /* Orange */
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --border-color: #bdc3c7;
    --border-light: #ecf0f1;
}

/* ========================================
   GLOBAL STYLES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Lato', sans-serif;
    background: var(--surface);
    min-height: 100vh;
    color: var(--text-dark);
}

/* ========================================
   TOP NAVIGATION
   ======================================== */
.top-nav {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 0 24px;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.brand-text {
    font-family: 'Lato', serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.2;
}

.brand-text span {
    display: block;
    font-size: 10px;
    font-weight: 400;
    opacity: 0.8;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-tenant {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.tenant-badge {
    background: rgba(52, 152, 219, 0.2);
    padding: 4px 12px;
    border-radius: 12px;
    font-weight: 600;
    color: var(--accent);
}

.nav-divider {
    width: 1px;
    height: 32px;
    background: rgba(255,255,255,0.2);
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-user-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    border-radius: 8px;
    padding: 6px 10px;
    transition: background 0.15s, opacity 0.15s;
    cursor: pointer;
}

.nav-user-link:hover {
    background: rgba(255, 255, 255, 0.15);
    opacity: 0.9;
}

.user-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    color: white;
}

.user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 13px;
}

.user-info small {
    font-size: 11px;
    opacity: 0.8;
}

.logout-link {
    color: white;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background 0.2s;
}

.logout-link:hover {
    background: rgba(255,255,255,0.1);
    color: white;
    text-decoration: none;
}

/* ========================================
   HAMBURGER MENU
   ======================================== */
.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background 0.2s;
}

.sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.sidebar-toggle i {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ========================================
   SIDEBAR
   ======================================== */
.sidebar {
    position: fixed;
    top: 72px;
    left: 0;
    width: 260px;
    height: calc(100vh - 72px);
    background: white;
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    padding: 20px 0;
    transition: transform 0.3s ease, left 0.3s ease;
    z-index: 999;
}

.sidebar.collapsed {
    transform: translateX(-100%);
    left: -260px;
}

.sidebar-overlay {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
}

.sidebar-overlay.active {
    display: block;
}

.sidebar-section {
    margin-bottom: 24px;
}

.sidebar-label {
    padding: 0 20px 8px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-light);
    letter-spacing: 0.5px;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    color: #4a4a4a;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.sidebar-item:hover {
    background: var(--surface);
    color: var(--primary);
    text-decoration: none;
    border-left-color: var(--accent);
}

.sidebar-item i {
    width: 20px;
    text-align: center;
    color: var(--accent);
}

/* ========================================
   MAIN CONTENT AREA
   ======================================== */
.main-content {
    margin-left: 260px;
    margin-top: 0px;
    min-height: calc(100vh - 72px - 60px);
    transition: margin-left 0.3s ease;
}

/* When sidebar is collapsed - shift content to fill the space */
body.sidebar-collapsed .main-content {
    margin-left: 0;
}

body.sidebar-collapsed .page-footer {
    margin-left: 0;
}

/* ========================================
   PAGE ELEMENTS
   ======================================== */
.page-header {
    margin-bottom: 32px;
}

.page-title {
    font-family: 'Lato', serif;
    font-size: 26px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 6px;
}

.page-subtitle {
    color: var(--text-light);
    font-size: 14px;
}

.page-footer {
    margin-left: 260px;
    padding: 20px 28px;
    background: white;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-light);
    transition: margin-left 0.3s ease;
}

/* ========================================
   BUTTONS
   ======================================== */
.btn {
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-dark) 0%, #21618c 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
    color: white;
    text-decoration: none;
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background: var(--text-light);
    text-decoration: none;
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, var(--success) 0%, #229954 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
    text-decoration: none;
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.3);
    text-decoration: none;
    color: white;
}

.btn-link {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    background: none;
    border: none;
    padding: 0;
}

.btn-link:hover {
    color: var(--accent-dark);
    text-decoration: none;
}

/* Quick Action Buttons */
.quick-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.quick-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.quick-btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: white;
    text-decoration: none;
}

.quick-btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-dark) 0%, #21618c 100%);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
    text-decoration: none;
}

/* ========================================
   CARDS
   ======================================== */
.card {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-light);
    font-family: 'Lato', serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
    background: #f8f9fa;
    border-radius: 10px 10px 0 0;
}

/* Stat Cards */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-bottom: 28px;
}

.stat-card {
    background: white;
    border-radius: 10px;
    padding: 16px 14px;
    border: 1px solid var(--border-light);
    position: relative;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: 10px 10px 0 0;
}

.stat-card.green::before {
    background: var(--success);
}

.stat-card.gold::before,
.stat-card.blue::before {
    background: var(--accent);
}

.stat-card.red::before {
    background: var(--danger);
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 11px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
}

/* ========================================
   GRID VIEW / TABLES
   ======================================== */
.gridview {
    width: 100%;
    border-collapse: collapse;
    border: none;
}

.gridview th {
    background: #f8f9fa;
    padding: 10px 12px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #5a6c7d;
    border-bottom: 2px solid var(--border-light);
}

.gridview td {
    padding: 12px;
    border-bottom: 1px solid var(--border-light);
    font-size: 13px;
    color: var(--text-dark);
}

.gridview tr:hover td {
    background: #f8f9fa;
}

/* ========================================
   BADGES
   ======================================== */
.badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    display: inline-block;
}

.badge-success {
    background: rgba(39, 174, 96, 0.15);
    color: var(--success);
}

.badge-warning {
    background: rgba(243, 156, 18, 0.15);
    color: var(--warning);
}

.badge-danger {
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger);
}

.badge-info {
    background: rgba(52, 152, 219, 0.15);
    color: var(--accent);
}

.badge-individual {
    background: rgba(52, 152, 219, 0.15);
    color: var(--accent);
}

.badge-business {
    background: rgba(39, 174, 96, 0.15);
    color: var(--success);
}

.badge-tribal {
    background: rgba(243, 156, 18, 0.15);
    color: var(--warning);
}

/* ========================================
   FORMS
   ======================================== */
.form-card {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    padding: 28px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.section-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.form-row.three {
    grid-template-columns: repeat(3, 1fr);
}

.form-row.single {
    grid-template-columns: 1fr;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.form-label.required::after {
    content: ' *';
    color: var(--danger);
}

.form-control {
    padding: 10px 14px;
    border: 1.5px solid var(--border-light);
    border-radius: 6px;
    font-size: 14px;
    font-family: 'Lato', sans-serif;
    width: 100%;
    transition: all 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* Type Selector */
.type-selector {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 28px;
}

.type-option {
    border: 2px solid var(--border-light);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
}

.type-option:hover {
    border-color: var(--accent);
    background: rgba(52, 152, 219, 0.05);
}

.type-option.selected {
    border-color: var(--accent);
    background: rgba(52, 152, 219, 0.1);
}

.type-option i {
    font-size: 32px;
    color: var(--accent);
    margin-bottom: 10px;
    display: block;
}

.type-label {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-dark);
}

/* ========================================
   ALERTS
   ======================================== */
.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-success {
    background: rgba(39, 174, 96, 0.1);
    border: 1px solid var(--success);
    color: var(--success);
}

.alert-danger {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid var(--danger);
    color: var(--danger);
}

.alert-warning {
    background: rgba(243, 156, 18, 0.1);
    border: 1px solid var(--warning);
    color: var(--warning);
}

.alert-info {
    background: rgba(52, 152, 219, 0.1);
    border: 1px solid var(--accent);
    color: var(--accent);
}

/* ========================================
   LINKS
   ======================================== */
a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--accent-dark);
    text-decoration: underline;
}

/* ========================================
   CONTAINER LAYOUTS
   ======================================== */
.search-container,
.edit-container,
.wizard-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 28px;
}

.search-card {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.search-group {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.results-card {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.results-header {
    padding: 16px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid var(--border-light);
    font-weight: 700;
    font-size: 14px;
    color: var(--primary);
}

/* Action Footer */
.action-footer,
.wizard-footer {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* ========================================
   WIZARD STYLES
   ======================================== */
.wizard-progress {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    padding: 20px;
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.wizard-step {
    flex: 1;
    text-align: center;
    position: relative;
    padding: 10px;
    font-size: 13px;
}

.wizard-step.active {
    color: var(--accent);
    font-weight: 700;
}

.wizard-step.completed {
    color: var(--success);
}

.step-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--surface-dark);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-weight: 700;
    font-size: 14px;
}

.wizard-step.active .step-number {
    background: var(--accent);
}

.wizard-step.completed .step-number {
    background: var(--success);
}

.customer-summary {
    background: linear-gradient(135deg, #0f2318 0%, var(--primary) 100%);
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 28px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ========================================
   RESPONSIVE DESIGN - MOBILE FIRST
   ======================================== */

/* TABLET & SMALL DEVICES (768px and below) */
@media (max-width: 768px) {
    /* Show hamburger menu button */
    .sidebar-toggle {
        display: flex;
        margin-right: 8px;
    }

    /* Layout adjustments */
    .top-nav {
        height: 60px;
        padding: 0 12px;
    }

    .sidebar {
        top: 60px;
        width: 200px;
        height: calc(100vh - 60px);
    }

    .sidebar-overlay {
        top: 60px;
    }

    .main-content {
        margin-left: 200px;
        margin-top: 0px;
        min-height: calc(100vh - 60px - 60px);
    }

    .page-footer {
        margin-left: 200px;
    }

    /* Collapsed sidebar shifts content on tablet too */
    body.sidebar-collapsed .main-content {
        margin-left: 0;
    }

    body.sidebar-collapsed .page-footer {
        margin-left: 0;
    }

    /* Brand adjustments */
    .brand-text {
        font-size: 14px;
    }

    .brand-text span {
        font-size: 9px;
    }

    .brand-icon {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }

    /* Navigation adjustments */
    .nav-right {
        gap: 12px;
    }

    .user-info {
        display: none;
    }

    /* Page header adjustments */
    .page-title {
        font-size: 20px;
        margin-bottom: 4px;
    }

    .page-subtitle {
        font-size: 12px;
    }

    /* Form layouts */
    .form-row,
    .form-row.three {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 12px;
    }

    .form-card {
        padding: 16px;
        margin-bottom: 12px;
    }

    .section-title {
        font-size: 12px;
        margin-bottom: 12px;
        padding-bottom: 8px;
    }

    /* Grid layouts */
    .stat-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin-bottom: 16px;
    }

    .type-selector {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-bottom: 16px;
    }

    /* Card adjustments */
    .card {
        margin-bottom: 12px;
    }

    .card-header {
        padding: 12px 16px;
        font-size: 12px;
    }

    /* Button adjustments */
    .btn {
        padding: 8px 16px;
        font-size: 13px;
    }

    .quick-btn {
        padding: 10px 16px;
        font-size: 12px;
    }

    /* Search container */
    .search-container,
    .edit-container,
    .wizard-container {
        max-width: 100%;
        padding: 12px;
    }

    /* Grid view tables */
    .gridview {
        font-size: 12px;
    }

    .gridview th,
    .gridview td {
        padding: 8px;
        font-size: 12px;
    }

    /* Badges */
    .badge {
        padding: 3px 8px;
        font-size: 10px;
    }

    /* Spacing adjustments */
    .page-header {
        margin-bottom: 16px;
    }

    .stat-card {
        padding: 12px;
    }

    .stat-value {
        font-size: 20px;
    }

    .stat-label {
        font-size: 10px;
    }

    /* Text sizing */
    .text-2xl { font-size: 18px !important; }
    .text-3xl { font-size: 20px !important; }
    .text-4xl { font-size: 22px !important; }

    /* Spacing utilities - reduce on mobile */
    .p-28 { padding: 16px !important; }
    .p-40 { padding: 20px !important; }
    .mb-32 { margin-bottom: 16px !important; }
    .mt-32 { margin-top: 16px !important; }
}

/* SMALL MOBILE (480px and below) */
@media (max-width: 480px) {
    /* Collapse sidebar by default on mobile */
    .sidebar {
        transform: translateX(-100%);
        left: -200px;
        width: 200px;
    }

    .main-content {
        margin-left: 0;
    }

    .page-footer {
        margin-left: 0;
    }

    /* Show overlay when sidebar is open */
    .sidebar-overlay {
        top: 56px;
    }

    /* Top nav further adjustments */
    .top-nav {
        height: 56px;
        padding: 0 8px;
    }

    .brand {
        gap: 8px;
    }

    .brand-text {
        font-size: 12px;
    }

    .nav-right {
        gap: 8px;
    }

    .tenant-badge {
        display: none;
    }

    .nav-divider {
        display: none;
    }

    /* Layout adjustments */
    .main-content {
        min-height: calc(100vh - 56px - 60px);
    }

    /* Page content */
    .search-container,
    .edit-container,
    .wizard-container {
        padding: 8px;
    }

    .form-card {
        padding: 12px;
        border-radius: 8px;
    }

    /* Form adjustments */
    .form-label {
        font-size: 11px;
    }

    .form-control {
        padding: 8px 10px;
        font-size: 13px;
    }

    .form-group {
        margin-bottom: 12px;
    }

    /* Button full width on mobile */
    .btn {
        padding: 10px 12px;
        width: 100%;
        font-size: 13px;
    }

    .quick-btn {
        width: 100%;
        padding: 10px 12px;
        font-size: 12px;
    }

    /* Grid adjustments */
    .stat-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    /* Text sizing for mobile */
    .text-xl { font-size: 14px !important; }
    .text-2xl { font-size: 16px !important; }
    .text-3xl { font-size: 18px !important; }
    .text-4xl { font-size: 20px !important; }
    .text-5xl { font-size: 24px !important; }
    .text-6xl { font-size: 32px !important; }

    /* Alert boxes */
    .alert {
        padding: 10px 12px;
        font-size: 12px;
        gap: 8px;
    }

    .alert i {
        font-size: 16px;
    }

    /* Badges */
    .badge {
        padding: 2px 6px;
        font-size: 9px;
    }

    /* Table adjustments */
    .gridview th,
    .gridview td {
        padding: 6px;
        font-size: 11px;
    }

    /* Customer grid layout */
    .customer-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .vehicle-list {
        max-height: 200px;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .vehicle-detail {
        padding: 12px;
    }

    /* Card variants */
    .stat-card-simple {
        padding: 12px;
    }

    .action-card {
        padding: 16px;
        gap: 8px;
    }

    .action-card i {
        font-size: 24px;
    }

    .action-card h3 {
        font-size: 14px;
    }

    .action-card p {
        font-size: 12px;
    }

    /* Page footer */
    .page-footer {
        flex-direction: column;
        gap: 8px;
        font-size: 10px;
        padding: 12px;
    }

    /* Spacing adjustments */
    .p-28 { padding: 12px !important; }
    .p-40 { padding: 16px !important; }
    .p-20 { padding: 12px !important; }
    .p-24 { padding: 14px !important; }

    .mb-24 { margin-bottom: 12px !important; }
    .mb-28 { margin-bottom: 12px !important; }
    .mb-32 { margin-bottom: 12px !important; }
    .mt-24 { margin-top: 12px !important; }
    .mt-28 { margin-top: 12px !important; }
    .mt-32 { margin-top: 12px !important; }
}

/* LARGE DEVICES (1200px and above) */
@media (min-width: 1200px) {
    /* Slightly larger text sizes on desktop */
    .page-title {
        font-size: 28px;
    }

    .page-subtitle {
        font-size: 15px;
    }

    /* Wider containers */
    .search-container,
    .edit-container,
    .wizard-container {
        max-width: 1200px;
    }

    /* More generous spacing */
    .form-card {
        padding: 32px;
    }

    .stat-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* EXTRA LARGE DEVICES (1600px and above) */
@media (min-width: 1600px) {
    .sidebar {
        width: 280px;
    }

    .main-content {
        margin-left: 280px;
    }

    .page-footer {
        margin-left: 280px;
    }

    body.sidebar-collapsed .main-content {
        margin-left: 0;
    }

    body.sidebar-collapsed .page-footer {
        margin-left: 0;
    }

    .search-container,
    .edit-container,
    .wizard-container {
        max-width: 1400px;
    }
}

/* ========================================
   CUSTOMER VIEW PAGE SPECIFIC
   ======================================== */
.customer-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 0;
    min-height: calc(100vh - 212px);
}

.vehicle-list {
    background: white;
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    padding-left: 0;
}

.vehicle-list-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    font-family: 'Lato', serif;
    font-size: 13px;
    font-weight: 600;
    background: #f8f9fa;
}

.vehicle-item {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-light);
    border-left: 4px solid transparent;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    text-align: left;
    text-decoration: none;
    color: inherit;
    background: white;
}

.vehicle-item:hover {
    background: var(--surface);
    text-decoration: none;
    color: inherit;
}

.vehicle-item.active {
    background: rgba(52, 152, 219, 0.1);
}

.vehicle-item.active .vehicle-title {
    color: var(--accent);
    font-weight: 700;
}

.vehicle-title {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 5px;
    letter-spacing: 0.02em;
    word-spacing: 0.1em;
}

.vehicle-subtitle {
    font-size: 11px;
    color: var(--text-light);
    margin-bottom: 7px;
    font-family: monospace;
    letter-spacing: 0.03em;
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.active {
    background: var(--success);
}

.status-dot.expired {
    background: var(--danger);
}

.status-text {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-text.active {
    color: var(--success);
}

.status-text.expired {
    color: var(--danger);
}

.vehicle-detail {
    background: var(--surface);
    overflow-y: auto;
    padding: 24px 28px;
}

.detail-section {
    background: white;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    margin-bottom: 20px;
    overflow: hidden;
}

.detail-section .section-header {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-light);
    background: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.detail-section .section-title {
    font-family: 'Lato', serif;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
    border: none;
    padding: 0;
    margin: 0;
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 0;
}

.section-chevron {
    margin-left: 8px;
    font-size: 11px;
    color: var(--text-light);
    transition: transform 0.25s ease;
    flex-shrink: 0;
}

.detail-section.collapsed .section-chevron {
    transform: rotate(-90deg);
}

.detail-section .section-content {
    padding: 20px;
    overflow: hidden;
    max-height: 3000px;
    transition: max-height 0.35s ease, padding 0.35s ease, opacity 0.25s ease;
    opacity: 1;
}

.detail-section.collapsed .section-content {
    max-height: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    opacity: 0;
}

.detail-section.collapsed .section-header {
    border-bottom: none;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px 24px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.info-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-light);
}

.info-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.section-btn {
    padding: 5px 12px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid var(--border-light);
    background: white;
    color: #4a4a4a;
    text-decoration: none;
    display: inline-block;
}

    .section-btn:hover {
        background: var(--surface);
        text-decoration: none;
    }

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

    .section-btn.primary:hover {
        background: var(--secondary);
        text-decoration: none;
    }

.section-btn.accent {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

    .section-btn.accent:hover {
        background: var(--accent-dark);
        text-decoration: none;
    }

/* ========================================
   UTILITY CLASSES
   ======================================== */
.text-primary {
    color: var(--primary) !important;
}

.text-secondary {
    color: var(--secondary) !important;
}

.text-accent {
    color: var(--accent) !important;
}

.text-light {
    color: var(--text-light) !important;
}

.text-dark {
    color: var(--text-dark) !important;
}

.text-danger {
    color: var(--danger) !important;
}

.text-success {
    color: var(--success) !important;
}

.bg-primary {
    background: var(--primary) !important;
}

.bg-secondary {
    background: var(--secondary) !important;
}

.bg-accent {
    background: var(--accent) !important;
}

.border-primary {
    border-color: var(--primary) !important;
}

.border-accent {
    border-color: var(--accent) !important;
}

/* ========================================
   SPACING UTILITIES (Margins)
   ======================================== */
.mt-4 { margin-top: 4px !important; }
.mt-6 { margin-top: 6px !important; }
.mt-8 { margin-top: 8px !important; }
.mt-12 { margin-top: 12px !important; }
.mt-16 { margin-top: 16px !important; }
.mt-20 { margin-top: 20px !important; }
.mt-24 { margin-top: 24px !important; }
.mt-28 { margin-top: 28px !important; }
.mt-32 { margin-top: 32px !important; }

.mb-0 { margin-bottom: 0 !important; }
.mb-4 { margin-bottom: 4px !important; }
.mb-6 { margin-bottom: 6px !important; }
.mb-8 { margin-bottom: 8px !important; }
.mb-10 { margin-bottom: 10px !important; }
.mb-12 { margin-bottom: 12px !important; }
.mb-16 { margin-bottom: 16px !important; }
.mb-20 { margin-bottom: 20px !important; }
.mb-24 { margin-bottom: 24px !important; }
.mb-28 { margin-bottom: 28px !important; }
.mb-32 { margin-bottom: 32px !important; }

.ml-8 { margin-left: 8px !important; }
.ml-10 { margin-left: 10px !important; }
.ml-12 { margin-left: 12px !important; }

.mr-8 { margin-right: 8px !important; }
.mr-10 { margin-right: 10px !important; }
.mr-12 { margin-right: 12px !important; }

/* ========================================
   SPACING UTILITIES (Padding)
   ======================================== */
.p-12 { padding: 12px !important; }
.p-16 { padding: 16px !important; }
.p-20 { padding: 20px !important; }
.p-24 { padding: 24px !important; }
.p-28 { padding: 28px !important; }
.p-40 { padding: 40px !important; }

.px-20 { padding-left: 20px !important; padding-right: 20px !important; }

.p-0 { padding: 0 !important; }

/* ========================================
   DISPLAY & LAYOUT UTILITIES
   ======================================== */
.d-flex { display: flex !important; }
.d-block { display: block !important; }
.d-grid { display: grid !important; }

.flex-center { display: flex !important; align-items: center !important; justify-content: center !important; }
.flex-between { display: flex !important; justify-content: space-between !important; align-items: center !important; }
.flex-end { display: flex !important; align-items: flex-end !important; }
.flex-start { display: flex !important; align-items: flex-start !important; }

.gap-8 { gap: 8px !important; }
.gap-10 { gap: 10px !important; }
.gap-12 { gap: 12px !important; }
.gap-16 { gap: 16px !important; }
.gap-20 { gap: 20px !important; }

.flex-1 { flex: 1 !important; }

/* ========================================
   SIZE UTILITIES
   ======================================== */
.w-100 { width: 100% !important; }

/* ========================================
   TYPOGRAPHY UTILITIES
   ======================================== */
.text-center { text-align: center !important; }
.text-left { text-align: left !important; }
.text-right { text-align: right !important; }

.uppercase { text-transform: uppercase !important; }

.font-light { font-weight: 400 !important; }
.font-normal { font-weight: 500 !important; }
.font-semibold { font-weight: 600 !important; }
.font-bold { font-weight: 700 !important; }

.text-sm { font-size: 12px !important; }
.text-base { font-size: 14px !important; }
.text-lg { font-size: 16px !important; }
.text-xl { font-size: 18px !important; }
.text-2xl { font-size: 22px !important; }
.text-3xl { font-size: 26px !important; }
.text-4xl { font-size: 28px !important; }
.text-5xl { font-size: 32px !important; }
.text-6xl { font-size: 48px !important; }

.cursor-pointer { cursor: pointer !important; }

/* ========================================
   OPACITY UTILITIES
   ======================================== */
.opacity-50 { opacity: 0.5 !important; }
.opacity-60 { opacity: 0.6 !important; }
.opacity-75 { opacity: 0.75 !important; }

/* ========================================
   COMPONENT CARD VARIANTS
   ======================================== */
.stat-card-simple {
    padding: 20px;
    border-radius: 6px;
    background: white;
    border: 1px solid var(--border-light);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.stat-card-simple-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.stat-card-simple-header h3 {
    margin: 0;
    font-size: 13px;
    color: var(--text-light);
    text-transform: uppercase;
    font-weight: 600;
}

.stat-card-simple-value {
    margin: 0;
    font-size: 28px;
    font-weight: 600;
    color: var(--text-dark);
}

.action-card {
    padding: 24px;
    border-radius: 6px;
    color: white;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.action-card:hover {
    transform: translateY(-2px);
    text-decoration: none;
    color: white;
}

.action-card i {
    font-size: 28px;
}

.action-card h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.action-card p {
    margin: 0;
    font-size: 13px;
    opacity: 0.9;
}

.action-card-accent {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.action-card-accent:hover {
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
}

.action-card-success {
    background: linear-gradient(135deg, var(--success) 0%, #229954 100%);
    box-shadow: 0 2px 8px rgba(39, 174, 96, 0.3);
}

.action-card-success:hover {
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.4);
}

.action-card-warning {
    background: linear-gradient(135deg, var(--warning) 0%, #e67e22 100%);
    box-shadow: 0 2px 8px rgba(243, 156, 18, 0.3);
}

.action-card-warning:hover {
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4);
}

.action-card-purple {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
    box-shadow: 0 2px 8px rgba(155, 89, 182, 0.3);
}

.action-card-purple:hover {
    box-shadow: 0 4px 12px rgba(155, 89, 182, 0.4);
}

