:root {
  --ink: #111827;
  --muted: #64748b;
  --paper: #f8fafc;
  --surface: #ffffff;
  --line: #dbe3ea;
  --accent: #f97316;
  --accent-dark: #c2410c;
  --navy: #0f172a;
  --green: #15803d;
  --red: #b91c1c;
  --radius: 18px;
  --shadow: 0 16px 50px rgba(15, 23, 42, .09);
}

* { box-sizing: border-box; }
html { max-width: 100%; overflow-x: hidden; color-scheme: light; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.55 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; object-fit: cover; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }

.site-header { min-height: 74px; padding: 12px max(20px, calc((100vw - 1180px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 24px; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(12px); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 21px; font-weight: 900; letter-spacing: -.04em; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--accent); color: white; transform: skew(-7deg); }
.site-header nav { display: flex; align-items: center; gap: 22px; font-weight: 700; }

.shell { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.narrow { width: min(760px, calc(100% - 40px)); margin-inline: auto; }
.hero { min-height: 570px; padding: 86px max(20px, calc((100vw - 1180px) / 2)); display: grid; grid-template-columns: 1.2fr .8fr; align-items: center; gap: 70px; color: white; background: radial-gradient(circle at 80% 15%, rgba(249,115,22,.5), transparent 32%), linear-gradient(135deg, #0f172a 0%, #1e293b 75%); }
.hero h1 { max-width: 760px; margin: 12px 0 22px; font-size: clamp(42px, 5vw, 74px); line-height: .98; letter-spacing: -.055em; }
.hero p { max-width: 650px; color: #cbd5e1; font-size: 19px; }
.eyebrow { color: var(--accent); font-size: 12px; font-weight: 900; letter-spacing: .16em; }
.hero-search { padding: 30px; border: 1px solid rgba(255,255,255,.17); border-radius: 24px; background: rgba(255,255,255,.08); box-shadow: var(--shadow); }
.hero-search label { display: block; margin-bottom: 10px; font-weight: 800; }
.search-row { display: grid; gap: 10px; }
.hero-search input { width: 100%; padding: 16px; border: 0; border-radius: 12px; }
.hero-search .text-link { display: inline-block; margin-top: 18px; color: white; }

.button { display: inline-flex; min-height: 46px; padding: 11px 20px; align-items: center; justify-content: center; border: 1px solid var(--accent); border-radius: 12px; background: var(--accent); color: white; font-weight: 850; box-shadow: none; }
.button:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.button-small { min-height: 40px; padding: 8px 15px; }
.button-large { min-height: 56px; padding-inline: 28px; }
.button-secondary { border-color: var(--line); background: white; color: var(--navy); }
.button-secondary:hover { background: #eef2f6; border-color: #cbd5e1; }
.button-success { background: var(--green); border-color: var(--green); }
.button-danger { background: var(--red); border-color: var(--red); }
.button:disabled { cursor: not-allowed; opacity: .5; }
.full { width: 100%; }
.text-link { color: var(--accent-dark); font-weight: 850; }

.section { padding-block: 70px; }
.section + .section { padding-top: 0; }
.section-heading { margin-bottom: 28px; display: flex; align-items: end; justify-content: space-between; gap: 30px; }
.section-heading h2, .page-header h1 { margin: 6px 0 0; font-size: clamp(31px, 4vw, 50px); line-height: 1.05; letter-spacing: -.04em; }
.brand-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.brand-grid a { padding: 22px 14px; border: 1px solid var(--line); border-radius: 14px; background: white; text-align: center; font-weight: 850; }
.brand-grid a:hover { border-color: var(--accent); transform: translateY(-2px); }
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.listing-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: white; box-shadow: 0 8px 28px rgba(15,23,42,.05); }
.listing-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card-image { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: #e2e8f0; }
.card-image img { width: 100%; height: 100%; }
.image-placeholder { height: 100%; display: grid; place-items: center; color: var(--muted); }
.status-chip { position: absolute; top: 12px; left: 12px; padding: 6px 9px; border-radius: 8px; font-size: 11px; font-weight: 900; }
.status-chip.sold { background: var(--navy); color: white; }
.card-body { padding: 18px; }
.card-body h3 { margin: 0; font-size: 19px; }
.price { margin: 9px 0 16px; color: var(--navy); font-size: 23px; font-weight: 950; letter-spacing: -.03em; }
.price-large { font-size: 34px; }
.card-specs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0; }
.card-specs div { min-width: 0; }
.card-specs dt { color: var(--muted); font-size: 11px; text-transform: uppercase; }
.card-specs dd { margin: 1px 0 0; overflow: hidden; font-size: 13px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }

.page-header { padding-block: 60px 35px; }
.page-header.compact { padding-top: 45px; }
.page-header p { color: var(--muted); }
.listing-layout { display: grid; grid-template-columns: 270px 1fr; gap: 30px; padding-bottom: 80px; align-items: start; }
.listing-layout > *, .filters form, .field, .results { min-width: 0; }
.filters { position: sticky; top: 95px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.filters h2 { margin-top: 0; }
.filters { position: static; }
.advanced-filters, .optional-vehicle-details { margin: 16px 0; border-top: 1px solid var(--line); padding-top: 14px; }
.advanced-filters summary, .optional-vehicle-details summary { cursor: pointer; font-weight: 700; padding: 12px 0; min-height: 44px; }
.equipment-field { min-width: 0; border: 0; padding: 0; margin: 18px 0; }
.equipment-field legend { font-weight: 750; }
.equipment-field p { font-size: 14px; color: #475569; }
.equipment-field label { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 14px; padding: 4px 0; overflow-wrap: anywhere; }
.equipment-field input[type="checkbox"] { width: 20px; height: 20px; flex: 0 0 20px; }
.equipment-field > div > div { margin-block: 12px; font-weight: 650; }
.equipment-field > div > div > div { font-weight: 400; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.filter-chips a { background: #fff7ed; border: 1px solid #fed7aa; border-radius: 18px; padding: 10px 14px; font-size: 14px; overflow-wrap: anywhere; max-width: 100%; }
.filters .field input[type="checkbox"] { width: 20px; height: 20px; }
.filters .field:has(input[type="checkbox"]) { display: grid; grid-template-columns: 28px minmax(0, 1fr); align-items: center; }
.filters .field:has(input[type="checkbox"]) label { grid-column: 2; grid-row: 1; display: flex; align-items: center; min-height: 44px; }
.filters .field input[type="checkbox"] { grid-column: 1; grid-row: 1; }
.vehicle-equipment ul { display: flex; flex-wrap: wrap; gap: 8px 28px; padding-left: 20px; }
@media (max-width: 960px) {
  .basic-filter-grid, .advanced-filter-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
  .equipment-field > div { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; }
}
@media (max-width: 390px) { .basic-filter-grid, .advanced-filter-grid, .equipment-field > div { grid-template-columns: minmax(0, 1fr); } }
.filters .button { margin-top: 8px; }
.card-grid-results { grid-template-columns: repeat(3, 1fr); }
.field { margin-bottom: 15px; }
.field label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 800; }
.field input:not([type="checkbox"]), .field select, .field textarea { width: 100%; min-width: 0; max-width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #cbd5e1; border-radius: 10px; background: white; }
.field textarea { min-height: 135px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); outline: 3px solid rgba(249,115,22,.14); }
.field-error input, .field-error select, .field-error textarea { border-color: var(--red); }
.error-text, .field-error small { display: block; margin-top: 5px; color: var(--red); }
.help, .privacy-note { display: block; margin-top: 5px; color: var(--muted); font-size: 13px; }
.pagination { margin-top: 30px; display: flex; justify-content: center; gap: 20px; font-weight: 800; }
.empty-state { grid-column: 1 / -1; padding: 50px; border: 1px dashed #94a3b8; border-radius: var(--radius); text-align: center; }

.form-shell { padding-bottom: 80px; }
.listing-form fieldset { margin: 0 0 22px; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.listing-form legend { padding: 0 8px; font-size: 19px; font-weight: 900; }
.listing-form legend span { display: inline-grid; place-items: center; width: 30px; height: 30px; margin-right: 7px; border-radius: 50%; background: var(--navy); color: white; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.form-submit { display: flex; justify-content: flex-end; }
.notice { margin: 16px 0; padding: 14px 17px; border-radius: 12px; background: #e0f2fe; }
.notice.warning { background: #fff7ed; color: #9a3412; }
.notice.error { background: #fee2e2; color: #991b1b; }
.notice.dev-only { border: 1px dashed #7c3aed; background: #f5f3ff; color: #5b21b6; }
.sold-notice { background: var(--navy); color: white; }
.success-panel, .error-page, .contact-reveal, .manage-panel { padding-block: 90px; text-align: center; }
.success-icon { width: 70px; height: 70px; margin: 0 auto 22px; display: grid; place-items: center; border-radius: 50%; background: #dcfce7; color: var(--green); font-size: 35px; font-weight: 900; }

.detail-page { padding-block: 35px 80px; }
.gallery { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 10px; max-height: 560px; overflow: hidden; border-radius: 22px; background: #e2e8f0; }
.gallery img { width: 100%; height: 100%; min-height: 250px; }
.gallery img:first-child { grid-row: span 2; }
.detail-layout { margin-top: 36px; display: grid; grid-template-columns: 1fr 350px; gap: 60px; align-items: start; }
.detail-layout h1 { margin: 5px 0; font-size: clamp(36px, 5vw, 58px); line-height: 1; letter-spacing: -.05em; }
.subtitle { color: var(--muted); font-size: 20px; }
.spec-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin: 30px 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--line); }
.spec-grid div { padding: 15px; background: white; }
.spec-grid dt { color: var(--muted); font-size: 12px; text-transform: uppercase; }
.spec-grid dd { margin: 3px 0 0; font-weight: 850; }
.description { padding-block: 20px; }
.contact-card { position: sticky; top: 100px; padding: 25px; border: 1px solid var(--line); border-radius: 20px; background: white; box-shadow: var(--shadow); }
.contact-card .button { margin-top: 10px; }
.contact-card small { display: block; margin-top: 17px; color: var(--muted); }
.report-box, .danger-zone { margin-top: 30px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; text-align: left; }
.report-box summary, .danger-zone summary { cursor: pointer; font-weight: 800; }
.contact-value { color: var(--accent-dark); font-size: 24px; font-weight: 900; }
.manage-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.manage-actions form { margin: 0; }
.danger-zone { margin-inline: auto; max-width: 500px; }
.messages { position: fixed; top: 88px; right: 20px; z-index: 40; width: min(390px, calc(100% - 40px)); }
.message { margin-bottom: 8px; padding: 13px; border-radius: 10px; background: #dcfce7; box-shadow: var(--shadow); }
.site-footer { padding: 45px max(20px, calc((100vw - 1180px) / 2)); background: var(--navy); color: white; }
.site-footer p { color: #94a3b8; }
.pilot-badge { margin-left: 8px; padding: 4px 7px; border: 1px solid #475569; border-radius: 7px; color: #cbd5e1; font-size: 11px; }
.import-review { padding-block: 50px 80px; }
.external-source { color: #475569; font-size: 13px; font-weight: 650; }
.source-data dd { margin-left: 0; margin-bottom: 14px; overflow-wrap: anywhere; }
.parser-diagnostics, .reject-import { margin-top: 28px; padding: 18px; border: 1px solid var(--line); border-radius: 10px; }
.parser-diagnostics summary, .reject-import summary { cursor: pointer; font-weight: 700; }
.import-review .manage-actions { position: sticky; bottom: 0; padding: 14px; background: white; border: 1px solid var(--line); border-radius: 12px; }
.import-source-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 28px; }
.import-source-grid article { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.source-text { max-height: 360px; overflow: auto; white-space: normal; }
.import-photo-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-block: 24px; }
.import-photo-grid > * { min-width: 0; max-width: 100%; }
.import-photo-grid img { width: 100%; max-width: 100%; height: auto; aspect-ratio: 3 / 2; border-radius: 12px; }
.token-output { display: block; margin-top: 24px; }
.token-output input { width: 100%; margin-top: 8px; padding: 12px; }
.table-wrap { max-width: 100%; overflow-x: auto; margin-block: 24px; }
.import-results { width: 100%; border-collapse: collapse; background: white; }
.import-results th, .import-results td { padding: 10px; border: 1px solid var(--line); text-align: left; vertical-align: top; }

@media (max-width: 960px) {
  .hero { min-height: auto; grid-template-columns: 1fr; gap: 35px; padding-block: 70px; }
  .brand-grid { grid-template-columns: repeat(3, 1fr); }
  .card-grid, .card-grid-results { grid-template-columns: repeat(2, 1fr); }
  .listing-layout { grid-template-columns: minmax(0, 1fr); }
  .filters { position: static; }
  .detail-layout { grid-template-columns: 1fr; gap: 30px; }
  .import-source-grid { grid-template-columns: 1fr; }
  .import-photo-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-card { position: static; }
}

@media (max-width: 620px) {
  .site-header { min-height: 66px; gap: 12px; padding-inline: 12px; }
  .site-header .brand { flex: 0 1 auto; min-width: 0; }
  .site-header nav { flex: 0 0 auto; gap: 8px; }
  .site-header nav > a:first-child { display: none; }
  .hero { padding-block: 54px; }
  .hero h1 { font-size: 43px; }
  .hero-search { padding: 20px; }
  .shell, .narrow { width: min(100% - 24px, 1180px); }
  .section { padding-block: 48px; }
  .section-heading { align-items: start; flex-direction: column; }
  .brand-grid { grid-template-columns: repeat(2, 1fr); }
  .card-grid, .card-grid-results { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .listing-form fieldset { padding: 18px 14px; }
  .gallery { display: flex; max-height: none; overflow-x: auto; scroll-snap-type: x mandatory; }
  .gallery img { min-width: 90%; height: 310px; scroll-snap-align: start; }
  .spec-grid { grid-template-columns: 1fr 1fr; }
  .detail-layout h1 { font-size: 40px; }
  .import-photo-grid { grid-template-columns: 1fr; }
}

/* Trust pages, consent and footer share the established CARZO palette. */
:focus-visible { outline: 3px solid #c2410c; outline-offset: 4px; }
.skip-link { position: absolute; left: 16px; top: -80px; padding: 12px; background: white; color: var(--navy); z-index: 30; }
.skip-link:focus { top: 10px; }
.site-footer { background: var(--navy); color: #e2e8f0; padding: 48px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.15fr 1fr 1fr 1.1fr; gap: 32px; }
.footer-grid section { min-width: 0; }
.footer-grid h2 { font-size: 15px; color: white; margin: 0 0 16px; }
.footer-grid p { font-size: 14px; line-height: 1.65; color: #cbd5e1; }
.footer-grid nav { display: grid; gap: 10px; font-size: 14px; }
.footer-grid a, .legal-page a, .privacy-choice a, .privacy-note a, .report-help a { text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.footer-grid a:hover { color: #fdba74; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 1px solid #475569; margin-top: 32px; padding-top: 22px; font-size: 13px; color: #cbd5e1; }
.legal-page { max-width: 900px; padding-block: 40px 72px; overflow-wrap: anywhere; }
.legal-page h1 { font-size: clamp(30px, 5vw, 46px); line-height: 1.18; letter-spacing: -.025em; }
.legal-page h2 { font-size: 24px; line-height: 1.3; margin-top: 36px; }
.legal-page p, .legal-page li { line-height: 1.75; }
.legal-page li + li { margin-top: 12px; }
.legal-lead { font-size: 19px; }
.legal-data { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 8px 20px; }
.legal-data dt { font-weight: 750; }
.legal-data dd { margin: 0; }
.legal-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.legal-table th, .legal-table td { padding: 14px; border: 1px solid var(--line); text-align: left; vertical-align: top; min-width: 165px; }
.legal-table th { background: #e2e8f0; }
.privacy-choice { margin-block: 24px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.privacy-choice h2 { margin: 0; font-size: 20px; }
.privacy-choice form, .privacy-controls { display: flex; gap: 12px; flex-wrap: wrap; }
.privacy-choice .button, .privacy-controls .button { background: white; color: var(--navy); border: 1px solid #64748b; }
.trust-form .field input[type="checkbox"] { width: 20px; height: 20px; }
.moderation-item { padding: 20px; margin-bottom: 18px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.moderation-evidence { white-space: pre-wrap; overflow-wrap: anywhere; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) {
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .legal-page { padding-block: 28px 48px; }
  .legal-data { grid-template-columns: minmax(0, 1fr); gap: 3px; }
  .legal-data dd { margin-bottom: 12px; }
  .privacy-choice { padding: 18px; }
  .privacy-choice form .button, .privacy-controls .button { width: 100%; }
}
