:root {
    --agency-ink: #132735;
    --agency-navy: #0c1d29;
    --agency-steel: #405765;
    --agency-muted: #73838a;
    --agency-brass: #c4a765;
    --agency-red: #b94143;
    --agency-paper: #edf1ef;
    --agency-line: #d7dfdc;
}

body {
    color: var(--agency-ink);
    font-family: "Source Sans 3", sans-serif;
    background-color: var(--agency-paper);
    background-image: radial-gradient(ellipse at 50% -20%, rgba(196, 167, 101, 0.11), transparent 42%), linear-gradient(180deg, #f3f5f3 0%, var(--agency-paper) 45%, #e8edeb 100%);
}

.agency-header {
    background: linear-gradient(112deg, #0b1b26 0%, #142e3d 58%, #0c1d29 100%);
    border-bottom: 3px solid var(--agency-brass);
    box-shadow: 0 8px 24px rgba(12, 29, 41, 0.17);
}

.agency-header-inner {
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.agency-identity,
.agency-actions {
    display: flex;
    align-items: center;
}

.agency-identity { gap: 1rem; }
.agency-mark { position: relative; display: grid; width: 48px; height: 48px; place-items: center; border: 1px solid rgba(196, 167, 101, 0.42); border-radius: 50%; color: var(--agency-brass); font-size: 1.8rem; line-height: 1; background: rgba(255, 255, 255, 0.045); }
.agency-mark-star { position: absolute; top: 0.78rem; left: 0.84rem; color: var(--agency-navy); font-size: 0.67rem; }
.agency-logo { width: auto; height: 60px; object-fit: contain; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2)); }
.agency-kicker, .section-kicker, .record-count-label, .fleet-status-filter > span {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}
.agency-kicker { color: #d6c28f; margin: 0 0 0.12rem; }
.agency-kicker span { color: var(--agency-red); padding: 0 0.25rem; }
.agency-title, .section-title, .panel-title { font-family: "Barlow Condensed", sans-serif; letter-spacing: 0; }
.agency-title { margin: 0; font-size: 1.72rem; line-height: 1; font-weight: 600; letter-spacing: 0.015em; }
.agency-actions { gap: 0.55rem; }
.action-primary, .action-refresh {
    min-height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: background-color 150ms ease, border-color 150ms ease;
}
.action-primary { display: inline-flex; align-items: center; gap: 0.55rem; padding: 0 0.9rem; border-color: #b94143; border-radius: 4px; background: var(--agency-red); color: white; font-size: 0.875rem; font-weight: 700; }
.action-primary:hover { background: #a23336; border-color: #a23336; }
.action-refresh { width: 40px; border-radius: 4px; background: rgba(255, 255, 255, 0.06); color: #dce5e7; }
.action-refresh:hover { background: rgba(255, 255, 255, 0.14); }

.dashboard-shell { padding-top: 2rem; padding-bottom: 3rem; }
.dashboard-hero { position: relative; display: flex; min-height: 184px; align-items: center; justify-content: space-between; gap: 2rem; overflow: hidden; padding: 2rem 2.25rem; border: 1px solid rgba(196, 167, 101, 0.36); border-radius: 8px; background: linear-gradient(112deg, #102735 0%, #183747 62%, #102532 100%); color: #fff; box-shadow: 0 12px 28px rgba(12, 29, 41, 0.13); }
.dashboard-hero::after { position: absolute; top: -110px; right: 12%; width: 330px; height: 330px; border: 1px solid rgba(196, 167, 101, 0.12); border-radius: 50%; box-shadow: 0 0 0 28px rgba(196, 167, 101, 0.025), 0 0 0 58px rgba(196, 167, 101, 0.02); content: ""; pointer-events: none; }
.dashboard-hero-copy, .dashboard-hero-seal { position: relative; z-index: 1; }
.dashboard-eyebrow { display: flex; align-items: center; gap: 0.55rem; margin: 0 0 0.65rem; color: #dfc786; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.13em; }
.dashboard-live-dot { width: 7px; height: 7px; border-radius: 50%; background: #7bc2a5; box-shadow: 0 0 0 4px rgba(123, 194, 165, 0.12); }
.dashboard-hero h2 { margin: 0; color: #fff; font-family: "Barlow Condensed", sans-serif; font-size: clamp(2.35rem, 4vw, 3.25rem); font-weight: 600; letter-spacing: 0.015em; line-height: 0.98; text-transform: uppercase; }
.dashboard-hero-copy > p:last-child { margin: 0.7rem 0 0; color: #c1cdd0; font-size: 0.96rem; }
.dashboard-hero-seal { display: flex; align-items: center; gap: 0.8rem; min-width: 220px; padding: 0.75rem 0 0.75rem 1.25rem; border-left: 1px solid rgba(220, 229, 231, 0.22); }
.dashboard-seal-icon { display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid rgba(196, 167, 101, 0.5); border-radius: 50%; color: var(--agency-brass); font-size: 1.15rem; }
.dashboard-hero-seal strong, .dashboard-hero-seal small { display: block; }
.dashboard-hero-seal strong { color: #f4f2e9; font-size: 0.82rem; letter-spacing: 0.03em; }
.dashboard-hero-seal small { margin-top: 0.15rem; color: #aebdc1; font-size: 0.74rem; }
.fleet-overview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.section-kicker { margin: 0 0 0.35rem; color: var(--agency-muted); }
.section-kicker-line { display: inline-block; width: 19px; height: 2px; margin: 0 0 3px; background: var(--agency-red); }
.section-title { margin: 0; color: var(--agency-ink); font-size: 2rem; line-height: 1; font-weight: 600; text-transform: uppercase; }
.record-count-label { display: flex; align-items: center; gap: 0.45rem; color: var(--agency-steel); }

.kpi-card { position: relative; display: flex; width: 100%; min-height: 132px; align-items: center; justify-content: space-between; gap: 0.75rem; overflow: hidden; padding: 1.1rem 1.15rem; border: 1px solid #dce3e0; border-top: 3px solid var(--kpi-accent); border-radius: 7px; background: linear-gradient(145deg, #fff 0%, #fafcfb 100%); color: inherit; font: inherit; text-align: left; cursor: pointer; box-shadow: 0 4px 12px rgba(19, 39, 53, 0.045); transition: transform 160ms ease, box-shadow 160ms ease; }
.kpi-card:hover { transform: translateY(-2px); box-shadow: 0 9px 20px rgba(19, 39, 53, 0.085); }
.kpi-card:focus-visible, .kpi-card.is-selected { outline: 3px solid color-mix(in srgb, var(--kpi-accent) 28%, transparent); outline-offset: 2px; }
.kpi-total { --kpi-accent: var(--agency-steel); }
.kpi-active { --kpi-accent: #37806c; }
.kpi-maintenance { --kpi-accent: #b48736; }
.kpi-out { --kpi-accent: var(--agency-red); }
.kpi-comodato { --kpi-accent: #7455a6; }
.kpi-legal { --kpi-accent: #bd6b32; }
.kpi-copy { min-width: 0; }
.kpi-label { margin: 0 0 0.2rem; color: var(--agency-muted); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.075em; text-transform: uppercase; }
.kpi-value { margin: 0; color: var(--agency-ink); font-family: "Barlow Condensed", sans-serif; font-size: 2.6rem; line-height: 1; font-weight: 600; }
.kpi-caption { margin: 0.42rem 0 0; color: #7d8b8e; font-size: 0.72rem; }
.kpi-icon { display: grid; flex: 0 0 auto; width: 46px; height: 46px; place-items: center; border: 1px solid color-mix(in srgb, var(--kpi-accent) 22%, white); border-radius: 50%; color: var(--kpi-accent); background: color-mix(in srgb, var(--kpi-accent) 8%, white); font-size: 1.05rem; }

.fleet-panel { overflow: hidden; border: 1px solid #d5dedb; border-radius: 7px; background: white; box-shadow: 0 6px 18px rgba(19, 39, 53, 0.055); }
.fleet-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.25rem; border-bottom: 1px solid var(--agency-line); }
.fleet-panel-title { display: flex; align-items: center; gap: 0.8rem; }
.fleet-panel-icon { display: grid; width: 42px; height: 42px; place-items: center; border: 1px solid #dce4e1; border-radius: 5px; background: #f3f6f4; color: var(--agency-steel); font-size: 1rem; }
.fleet-panel-heading .section-kicker { margin-bottom: 0.15rem; }
.panel-title { margin: 0; color: var(--agency-ink); font-size: 1.55rem; line-height: 1; font-weight: 600; }
.panel-unit { display: inline-flex; align-items: center; gap: 0.4rem; color: var(--agency-steel); font-size: 0.72rem; font-weight: 700; }
.fleet-report-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; }
.fleet-report-actions select { min-height: 40px; padding: 0 0.7rem; border: 1px solid #cbd5d3; border-radius: 5px; background: white; color: var(--agency-ink); font-size: 0.85rem; }
.fleet-print-dialog { width: min(420px, calc(100% - 2rem)); margin: auto; padding: 1.5rem; border: 1px solid var(--agency-line); border-radius: 7px; color: var(--agency-ink); box-shadow: 0 12px 30px rgba(12, 29, 41, 0.25); }
.fleet-print-dialog::backdrop { background: rgba(12, 29, 41, 0.65); }
.fleet-print-dialog h3 { margin: 0; font-size: 1.3rem; font-weight: 700; }
.fleet-print-dialog p { margin: 0.5rem 0 1rem; color: var(--agency-steel); }
.fleet-print-dialog fieldset { display: flex; flex-wrap: wrap; gap: 1rem; border: 0; padding: 0; }
.fleet-print-dialog legend { margin-bottom: 0.5rem; font-weight: 700; }
.fleet-print-dialog label { display: inline-flex; align-items: center; gap: 0.4rem; }
.fleet-print-dialog input { accent-color: var(--agency-steel); }
.fleet-print-dialog .fuel-print-dates { margin-bottom: 1rem; }
.fleet-print-dialog .fuel-print-dates input { padding: 0.4rem; border: 1px solid #cbd5d3; border-radius: 4px; }
.fleet-print-dialog-actions { display: flex; justify-content: flex-end; gap: 0.75rem; margin-top: 1.5rem; }
.fleet-print-dialog-actions button { min-height: 40px; padding: 0.5rem 0.9rem; border: 1px solid #cbd5d3; border-radius: 4px; background: white; font-weight: 700; }
.fleet-print-dialog-actions button[type="submit"] { border-color: var(--agency-steel); background: var(--agency-steel); color: white; }
.fleet-filters { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.9rem 1.25rem; border-bottom: 1px solid var(--agency-line); background: #f7f9f8; }
.fleet-search { display: flex; align-items: center; gap: 0.65rem; width: min(100%, 480px); min-height: 42px; padding: 0 0.8rem; border: 1px solid #cbd5d3; border-radius: 5px; background: white; color: var(--agency-muted); transition: border-color 150ms ease, box-shadow 150ms ease; }
.fleet-search:focus-within { border-color: var(--agency-steel); box-shadow: 0 0 0 3px rgba(64, 87, 101, 0.11); }
.fleet-search input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--agency-ink); font-size: 0.875rem; }
.fleet-search input::placeholder { color: #8a989c; }
.fleet-status-filter { display: flex; align-items: center; gap: 0.55rem; }
.fleet-status-filter > span { color: var(--agency-muted); font-size: 0.62rem; }
.fleet-status-filter select { min-height: 40px; padding: 0 2rem 0 0.7rem; border: 1px solid #cbd5d3; border-radius: 5px; background: white; color: var(--agency-ink); font-size: 0.85rem; }
.fleet-table { min-width: 900px; }
.fleet-table thead { background: linear-gradient(90deg, #142d3b, #1d3b4b); color: #f3f5f2; }
.fleet-table th { padding: 0.85rem 1rem; font-size: 0.64rem; font-weight: 700; letter-spacing: 0.075em; text-transform: uppercase; white-space: nowrap; }
.fleet-sort-button { display: inline-flex; align-items: center; gap: 0.5rem; border: 0; padding: 0; background: transparent; color: inherit; font: inherit; font-weight: inherit; letter-spacing: inherit; text-align: left; text-transform: inherit; cursor: pointer; }
.fleet-sort-button i { color: #a7b5b7; font-size: 0.7rem; opacity: 0.7; transition: color 140ms ease, opacity 140ms ease; }
.fleet-sort-button:hover i, .fleet-sort-button:focus-visible i, .fleet-sort-button.is-sorted i { color: #dfc786; opacity: 1; }
.fleet-sort-button:focus-visible { outline: 2px solid #dfc786; outline-offset: 4px; border-radius: 2px; }
.fleet-table tbody tr { border-bottom: 1px solid #e8edeb; }
.fleet-table tbody tr:nth-child(even) { background: #fafcfb; }
.fleet-table tbody tr:hover { background: #edf3f0; cursor: pointer; }
.fleet-table td { padding: 0.9rem 1rem; }
.fleet-panel-footer { display: flex; align-items: center; gap: 0.45rem; min-height: 40px; padding: 0.55rem 1.25rem; border-top: 1px solid #e4e9e7; background: #fafcfb; color: #77868a; font-size: 0.72rem; }
.fleet-panel-footer i { color: var(--agency-steel); }
.fuel-daily-table { min-width: 720px; }
.fuel-daily-table thead { background: linear-gradient(90deg, #142d3b, #1d3b4b); color: #f3f5f2; }
.fuel-daily-table th { padding: 0.8rem 1rem; font-size: 0.64rem; font-weight: 700; letter-spacing: 0.075em; text-transform: uppercase; }
.fuel-daily-table td { padding: 0.75rem 1rem; border-bottom: 1px solid #e8edeb; color: var(--agency-ink); font-size: 0.84rem; }
.fuel-daily-table tbody tr:nth-child(even) { background: #fafcfb; }
.fuel-daily-table .fuel-daily-empty { padding: 2rem; color: var(--agency-muted); text-align: center; }
.fuel-detail-toggle { border: 0; padding: 0.35rem 0.6rem; border-radius: 4px; background: #edf3f0; color: var(--agency-steel); font: inherit; font-size: 0.78rem; font-weight: 700; cursor: pointer; }
.fuel-detail-toggle:hover, .fuel-detail-toggle:focus-visible { background: #dce8e2; outline: 2px solid var(--agency-steel); outline-offset: 2px; }
.fuel-day-details > td { padding: 0.75rem 1rem 1rem; background: #f5f8f6; }
.fuel-detail-table { width: 100%; border-collapse: collapse; }
.fuel-detail-table th { background: #e8eeeb; color: var(--agency-muted); text-align: left; }
.fuel-detail-table th, .fuel-detail-table td { padding: 0.55rem 0.7rem; font-size: 0.76rem; }
.screen-nav-button { display: inline-flex; width: auto; align-items: center; justify-content: center; gap: 0.45rem; padding: 0 0.75rem; font-size: 0.8rem; font-weight: 700; }
.screen-nav-button[aria-current="page"] { border-color: var(--agency-brass); color: #f2d995; background: rgba(196, 167, 101, 0.13); }
.fuel-dashboard-link { display: flex; width: 100%; align-items: center; gap: 1rem; padding: 1.15rem 1.3rem; border: 1px solid #d5dedb; border-left: 4px solid #37806c; border-radius: 7px; background: linear-gradient(110deg, #fff, #f8fbf9); text-align: left; box-shadow: 0 6px 18px rgba(19, 39, 53, 0.055); transition: transform 160ms ease, box-shadow 160ms ease; cursor: pointer; }
.fuel-dashboard-link:hover, .fuel-dashboard-link:focus-visible { transform: translateY(-2px); outline: 2px solid rgba(55, 128, 108, 0.3); outline-offset: 2px; box-shadow: 0 9px 20px rgba(19, 39, 53, 0.085); }
.fuel-dashboard-icon { display: grid; width: 48px; height: 48px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: #e8f2ed; color: #37806c; font-size: 1.2rem; }
.fuel-dashboard-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; gap: 0.18rem; }
.fuel-dashboard-copy .section-kicker { color: #37806c; }
.fuel-dashboard-copy strong { color: var(--agency-ink); font-size: 1.05rem; }
.fuel-dashboard-copy small { color: var(--agency-muted); font-size: 0.82rem; }
.fuel-dashboard-action { display: inline-flex; align-items: center; gap: 0.5rem; color: var(--agency-steel); font-size: 0.85rem; font-weight: 700; white-space: nowrap; }
.fuel-page-actions { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.fuel-secondary-button { display: inline-flex; min-height: 38px; align-items: center; justify-content: center; gap: 0.45rem; padding: 0.45rem 0.75rem; border: 1px solid #cbd5d3; border-radius: 4px; background: white; color: var(--agency-ink); font-size: 0.82rem; font-weight: 700; cursor: pointer; }
.fuel-secondary-button:hover, .fuel-secondary-button:focus-visible { border-color: var(--agency-steel); background: #f2f5f3; outline: 2px solid rgba(64, 87, 101, 0.18); outline-offset: 1px; }
.fuel-overview { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.fuel-overview .kpi-value { font-size: 2rem; }
.fuel-register-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.8rem; padding: 1.25rem; }
.fuel-register-form label, .fuel-date-filters label { display: flex; flex-direction: column; gap: 0.3rem; color: var(--agency-muted); font-size: 0.72rem; font-weight: 700; }
.fuel-register-form input, .fuel-register-form select, .fuel-date-filters input { width: 100%; min-height: 40px; padding: 0.45rem 0.6rem; border: 1px solid #cbd5d3; border-radius: 4px; background: white; color: var(--agency-ink); font: inherit; font-size: 0.85rem; }
.fuel-register-form input:focus, .fuel-register-form select:focus, .fuel-date-filters input:focus { border-color: var(--agency-steel); outline: 2px solid rgba(64, 87, 101, 0.16); }
.fuel-form-actions { display: flex; align-items: end; }
.fuel-signature-field, .fuel-form-actions-full { grid-column: 1 / -1; }
.fuel-signature-field { min-width: 0; }
.fuel-signature-label { color: var(--agency-muted); font-size: 0.72rem; font-weight: 700; }
.fuel-signature-field canvas { display: block; }
.fuel-camera [hidden] { display: none; }
.fuel-camera-dialog { width: min(96vw, 900px); height: min(90vh, 760px); max-width: none; max-height: none; padding: 0; border: 0; border-radius: 12px; background: #0b1b26; color: white; overflow: hidden; }
.fuel-camera-dialog[open] { display: flex; flex-direction: column; }
.fuel-camera-dialog::backdrop { background: rgba(0, 0, 0, 0.75); }
.fuel-camera-dialog-header { padding: 1rem; text-align: center; font-weight: 700; }
.fuel-camera-viewport { flex: 1; min-height: 0; background: #000; }
.fuel-camera-viewport video { display: block; width: 100%; height: 100%; object-fit: contain; }
.fuel-camera-dialog-actions { display: flex; justify-content: center; gap: 0.75rem; padding: 1rem; }
.fuel-camera-dialog-actions .action-primary { width: auto; padding: 0 1rem; justify-content: center; }
@media (max-width: 640px) {
    .fuel-camera-dialog { inset: 0; width: 100%; height: 100%; margin: 0; border-radius: 0; }
    .fuel-camera-dialog-header { padding-top: max(1rem, env(safe-area-inset-top)); }
    .fuel-camera-dialog-actions { padding-bottom: max(1rem, env(safe-area-inset-bottom)); }
}
.fuel-form-actions-full { justify-content: flex-end; }
.fuel-filters { align-items: end; }
.fuel-date-filters { display: flex; align-items: end; gap: 0.55rem; }
.fuel-date-filters label { min-width: 140px; }
.fuel-results-count { color: var(--agency-steel); }
.workshop-dashboard-link { border-left-color: var(--agency-brass); }
.workshop-dashboard-link .fuel-dashboard-icon { background: #f6f0df; color: #94712d; }
.workshop-dashboard-link .fuel-dashboard-copy .section-kicker { color: #94712d; }
.workshop-register-form { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.workshop-register-form textarea { width: 100%; min-height: 64px; resize: vertical; padding: 0.45rem 0.6rem; border: 1px solid #cbd5d3; border-radius: 4px; background: white; color: var(--agency-ink); font: inherit; font-size: 0.85rem; }
.workshop-register-form textarea:focus { border-color: var(--agency-steel); outline: 2px solid rgba(64, 87, 101, 0.16); }
.workshop-service-field { grid-column: span 2; }
.workshop-table { min-width: 1150px; }
.workshop-table thead { background: linear-gradient(90deg, #142d3b, #1d3b4b); color: #f3f5f2; }
.workshop-table th { padding: 0.8rem 0.85rem; font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.workshop-table td { padding: 0.7rem 0.85rem; border-bottom: 1px solid #e8edeb; color: var(--agency-ink); font-size: 0.8rem; vertical-align: top; }
.workshop-table tbody tr:nth-child(even) { background: #fafcfb; }
.workshop-table .workshop-service-cell { min-width: 210px; max-width: 360px; white-space: pre-wrap; overflow-wrap: anywhere; }
.workshop-open-status { color: #a23336 !important; font-weight: 700; }
.workshop-actions-cell { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.workshop-actions-cell .fuel-detail-toggle { white-space: nowrap; }
.workshop-table .fuel-daily-empty { padding: 2rem; color: var(--agency-muted); text-align: center; }
.vehicle-detail-trigger { display: inline-flex; align-items: center; gap: 0.4rem; border: 0; padding: 0; background: transparent; color: var(--agency-ink); font: inherit; font-weight: 700; cursor: pointer; }
.vehicle-detail-trigger i { color: var(--agency-steel); font-size: 0.7rem; opacity: 0; transition: opacity 150ms ease; }
.vehicle-detail-trigger:hover { color: var(--agency-red); }
.vehicle-detail-trigger:hover i, .vehicle-detail-trigger:focus-visible i { opacity: 1; }
.vehicle-detail-dialog { width: min(100%, 900px); max-height: 92vh; overflow-y: auto; border: 1px solid var(--agency-brass); border-radius: 6px; background: #f7f9f8; box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35); }
.vehicle-detail-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.35rem; border-bottom: 1px solid var(--agency-line); background: white; }
.vehicle-detail-header .section-kicker { margin-bottom: 0.2rem; }
.vehicle-detail-header h2 { margin: 0; color: var(--agency-ink); font-family: "Barlow Condensed", sans-serif; font-size: 1.65rem; line-height: 1; font-weight: 600; }
.vehicle-detail-close { width: 38px; height: 38px; border: 1px solid var(--agency-line); border-radius: 4px; background: white; color: var(--agency-steel); }
.vehicle-detail-close:hover { background: var(--agency-ink); color: white; }
.vehicle-detail-body { display: grid; grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.2fr); gap: 1.25rem; padding: 1.25rem; }
.vehicle-detail-photo-wrap { position: relative; min-height: 260px; overflow: hidden; border: 1px solid var(--agency-line); border-radius: 4px; background: #e7ece9; }
.vehicle-detail-photo { width: 100%; height: 100%; min-height: 260px; object-fit: contain; cursor: zoom-in; }
.vehicle-detail-photo:focus-visible { outline: 3px solid var(--agency-red); outline-offset: -3px; }
.vehicle-photo-lightbox { position: fixed; inset: 0; z-index: 70; align-items: center; justify-content: center; padding: 3rem 1rem 1rem; background: rgba(3, 10, 15, 0.94); }
.vehicle-photo-lightbox-close { position: absolute; top: 1rem; right: 1rem; display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid rgba(255, 255, 255, 0.55); border-radius: 4px; background: rgba(255, 255, 255, 0.1); color: white; font-size: 1.25rem; cursor: pointer; }
.vehicle-photo-lightbox-close:hover, .vehicle-photo-lightbox-close:focus-visible { background: white; color: var(--agency-ink); }
.vehicle-photo-enlarged { display: block; max-width: 96vw; max-height: 92vh; object-fit: contain; }
.vehicle-photo-placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.65rem; color: #78878a; font-size: 0.8rem; }
.vehicle-photo-placeholder i { font-size: 2.4rem; }
.vehicle-detail-status { position: absolute; top: 0.75rem; left: 0.75rem; }
.vehicle-detail-subtitle { margin: 0 0 0.75rem; color: var(--agency-steel); font-size: 0.85rem; font-weight: 700; }
.vehicle-detail-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; margin: 0; border-top: 1px solid var(--agency-line); border-left: 1px solid var(--agency-line); }
.vehicle-detail-field { min-width: 0; padding: 0.65rem 0.7rem; border-right: 1px solid var(--agency-line); border-bottom: 1px solid var(--agency-line); background: white; }
.vehicle-detail-field dt { margin-bottom: 0.2rem; color: var(--agency-muted); font-size: 0.65rem; font-weight: 700; text-transform: uppercase; }
.vehicle-detail-field dd { margin: 0; overflow-wrap: anywhere; color: var(--agency-ink); font-size: 0.87rem; font-weight: 600; }
.vehicle-detail-footer { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.6rem; padding: 0.9rem 1.25rem; border-top: 1px solid var(--agency-line); background: white; }
.vehicle-detail-secondary, .vehicle-detail-edit { min-height: 40px; padding: 0 0.9rem; border: 1px solid var(--agency-line); border-radius: 4px; font-size: 0.85rem; font-weight: 700; }
.vehicle-detail-secondary { background: white; color: var(--agency-steel); }
.vehicle-detail-edit { display: inline-flex; align-items: center; gap: 0.5rem; border-color: var(--agency-red); background: var(--agency-red); color: white; }
.vehicle-detail-edit:hover { background: #a23336; }
.photo-upload-field { padding: 0.85rem; border: 1px solid var(--agency-line); border-radius: 4px; background: #f7f9f8; }
.photo-upload-field label { display: block; margin-bottom: 0.45rem; color: var(--agency-ink); font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
.photo-upload-field input { width: 100%; color: var(--agency-steel); font-size: 0.85rem; }
.photo-upload-field p { margin: 0.35rem 0 0; color: var(--agency-muted); font-size: 0.75rem; }

@media (max-width: 640px) {
    .agency-header-inner { min-height: 0; flex-wrap: wrap; padding-top: 0.65rem; padding-bottom: 0.6rem; }
    .agency-identity { flex: 1 1 100%; gap: 0.65rem; }
    .agency-mark { width: 40px; height: 40px; font-size: 1.55rem; }
    .agency-mark-star { top: 0.67rem; left: 0.72rem; font-size: 0.57rem; }
    .agency-kicker { font-size: 0.55rem; white-space: nowrap; }
    .agency-title { font-size: 1.35rem; white-space: nowrap; }
    .agency-actions { width: 100%; justify-content: flex-end; gap: 0.35rem; }
    .agency-actions #session-user { display: none; }
    .action-refresh { width: 36px; min-height: 36px; }
    .screen-nav-button { width: auto; padding: 0 0.45rem; font-size: 0.68rem; }
    .action-primary { width: 40px; justify-content: center; padding: 0; }
    .action-primary span { display: none; }
    .dashboard-shell { padding-top: 1.3rem; }
    .dashboard-hero { min-height: 166px; padding: 1.45rem 1.25rem; }
    .fuel-page-hero { align-items: flex-start; flex-direction: column; }
    .dashboard-hero-seal { display: none; }
    .dashboard-hero::after { right: -120px; }
    .dashboard-hero h2 { font-size: 2.45rem; }
    .fleet-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.7rem; }
    .kpi-card { min-height: 112px; padding: 0.75rem; }
    .kpi-icon { width: 32px; height: 32px; font-size: 0.82rem; }
    .kpi-value { font-size: 2.25rem; }
    .kpi-label { font-size: 0.6rem; }
    .kpi-caption { font-size: 0.65rem; }
    .fleet-panel-heading { flex-wrap: wrap; padding: 0.95rem; }
    .fleet-panel-icon { width: 36px; height: 36px; }
    .panel-title { font-size: 1.35rem; }
    .panel-unit { font-size: 0.6rem; }
    .fleet-filters { align-items: stretch; flex-direction: column; }
    .fleet-search { width: 100%; }
    .fuel-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fuel-register-form { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 0.9rem; }
    .workshop-service-field { grid-column: span 2; }
    .fuel-date-filters { flex-wrap: wrap; }
    .fuel-date-filters label { flex: 1 1 130px; }
    .fuel-page-actions { align-items: flex-start; flex-direction: column; }
    .fuel-page-actions .fuel-secondary-button { justify-content: flex-start; }
    .fuel-dashboard-link { align-items: flex-start; padding: 0.9rem; }
    .fuel-dashboard-action { align-self: center; font-size: 0; }
    .fuel-dashboard-action i { font-size: 0.9rem; }
    .fleet-status-filter { justify-content: space-between; }
    .fleet-panel-footer { padding-right: 0.9rem; padding-left: 0.9rem; }
    .vehicle-detail-body { grid-template-columns: 1fr; }
    .vehicle-detail-photo-wrap { min-height: 210px; }
    .vehicle-detail-photo { min-height: 210px; max-height: 250px; }
    .vehicle-detail-fields { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 380px) {
    .kpi-icon { display: none; }
    .kpi-label { font-size: 0.57rem; }
    .screen-nav-button { gap: 0.25rem; padding: 0 0.35rem; font-size: 0.62rem; }
    .fuel-register-form { grid-template-columns: 1fr; }
    .workshop-service-field { grid-column: span 1; }
    .fuel-dashboard-icon { width: 38px; height: 38px; }
}

@media (min-width: 641px) and (max-width: 900px) {
    .fleet-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fuel-register-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .workshop-register-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
    .kpi-card, .fleet-search { transition: none; }
    .kpi-card:hover { transform: none; }
}