/* CarGrid — app.css
   Mobile-first. Cascade layers keep specificity predictable.
   Brand: navy #03173E, grid red #F1181F (from the logo files).
   Type: Archivo (variable width + weight), self-hosted and subset. */

@layer reset, tokens, base, layout, components, pages, utilities;

@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

@view-transition { navigation: auto; }

/* ---------------- reset ---------------- */
@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  * { margin: 0; }
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  body { min-height: 100dvh; }
  /* Pages only ever scroll up and down, like an app. Sideways rows (menus, photos, tables) scroll inside themselves. */
  html, body { overflow-x: clip; overscroll-behavior-x: none; }
  @supports not (overflow: clip) { html, body { overflow-x: hidden; } }
  input, select, textarea { max-width: 100%; min-width: 0; }
  /* iPhone home-screen app (iOS 26): a page shorter than the screen got a shorter viewport, so the
     bottom tab bar floated above the bottom edge on short pages (Cars, Leads). Keeping the page at
     least screen-tall gives every page the full screen. See WebKit bug 301108. */
  @media (display-mode: standalone) {
    html { min-height: min(100lvh, calc(100% + env(safe-area-inset-top))); }
  }
  img, svg, video { display: block; max-width: 100%; }
  img { height: auto; }
  input, button, select, textarea { font: inherit; color: inherit; }
  button { cursor: pointer; background: none; border: 0; padding: 0; }
  a { color: inherit; }
  ul[class], ol[class] { list-style: none; padding: 0; }
  [hidden] { display: none !important; }
  table { border-collapse: collapse; }
}

/* ---------------- tokens ---------------- */
@layer tokens {
  :root {
    --navy: #03173E;
    --navy-2: #0B2556;
    --navy-3: #16336D;
    --red: #F1181F;
    --red-btn: #D7121A;      /* 4.9:1 with white text */
    --red-dark: #B30E15;
    --ink: #0B1733;
    --ink-2: #3A4766;
    --muted: #5D6884;
    --line: #E2E7F0;
    --line-2: #CCD4E2;
    --mist: #F3F5F9;
    --paper: #FFFFFF;
    --good: #0B8457;
    --good-bg: #E6F5EE;
    --warn: #A35F00;
    --warn-bg: #FFF4E0;
    --bad: #B42318;
    --bad-bg: #FDECEA;
    --wa: #128C4A;
    --wa-hover: #0E7A40;

    --font: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

    --step--1: clamp(.8125rem, .79rem + .1vw, .875rem);
    --step-0: clamp(.9375rem, .91rem + .15vw, 1rem);
    --step-1: clamp(1.0625rem, 1rem + .3vw, 1.1875rem);
    --step-2: clamp(1.25rem, 1.14rem + .55vw, 1.5rem);
    --step-3: clamp(1.5rem, 1.3rem + 1vw, 2rem);
    --step-4: clamp(1.875rem, 1.5rem + 1.9vw, 2.875rem);
    --step-5: clamp(2.25rem, 1.6rem + 3.2vw, 4rem);

    --r-sm: 8px;
    --r: 12px;
    --r-lg: 18px;
    --pill: 999px;

    --gap: clamp(16px, 2.5vw, 24px);
    --wrap: 1240px;
    --head-h: 64px;
    --tab-h: 64px;
    --safe-b: env(safe-area-inset-bottom, 0px);
    --ring: 0 0 0 3px rgba(241, 24, 31, .28);
    --shadow-pop: 0 18px 48px -12px rgba(3, 23, 62, .28), 0 2px 6px rgba(3, 23, 62, .08);
  }
}

/* ---------------- base ---------------- */
@layer base {
  html { scroll-padding-top: calc(var(--head-h) + 12px); }
  body {
    font-family: var(--font);
    font-size: var(--step-0);
    line-height: 1.55;
    color: var(--ink);
    background: var(--paper);
    font-stretch: 100%;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
    font-feature-settings: "kern", "liga";
  }
  h1, h2, h3, h4 { line-height: 1.12; font-weight: 750; font-stretch: 112%; letter-spacing: -.012em; text-wrap: balance; }
  h1 { font-size: var(--step-4); font-weight: 800; font-stretch: 118%; letter-spacing: -.022em; }
  h2 { font-size: var(--step-3); }
  h3 { font-size: var(--step-1); font-stretch: 105%; letter-spacing: -.005em; }
  p { text-wrap: pretty; }
  a { text-decoration-thickness: 1px; text-underline-offset: 3px; }
  a:hover { color: var(--red-btn); }
  :focus-visible { outline: 2px solid var(--red); outline-offset: 2px; border-radius: 4px; }
  ::selection { background: rgba(241, 24, 31, .18); }
  small, .small { font-size: var(--step--1); }
  .muted { color: var(--muted); }
  code { font-size: .9em; background: var(--mist); padding: .1em .35em; border-radius: 4px; }
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
    @view-transition { navigation: none; }
  }
}

/* ---------------- layout ---------------- */
@layer layout {
  .wrap { width: min(100% - 2 * var(--gap), var(--wrap)); margin-inline: auto; }
  .section { padding-block: clamp(32px, 5vw, 64px); }
  .section + .section { padding-top: 0; }
  main { padding-bottom: calc(var(--tab-h) + var(--safe-b) + 16px); }
  @media (min-width: 960px) { main { padding-bottom: 0; } }

  .skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--navy); color: #fff; padding: 8px 14px; border-radius: var(--r-sm); }
  .skip:focus { left: 8px; }

  /* top progress line (only appears for slow loads, see app.js) */
  .progress { position: fixed; inset: 0 0 auto; height: 3px; z-index: 90; pointer-events: none; transform-origin: left; transform: scaleX(0); background: var(--red); opacity: 0; }
  .progress.run { opacity: 1; animation: prog 8s cubic-bezier(.1, .7, .2, 1) forwards; }
  .progress.done { opacity: 0; transform: scaleX(1); transition: opacity .25s .1s, transform .2s; }
  @keyframes prog { from { transform: scaleX(0); } to { transform: scaleX(.92); } }

  /* header */
  .site-head { position: sticky; top: 0; z-index: 40; background: rgba(255, 255, 255, .92); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top, 0px); }
  .head-row { height: var(--head-h); display: flex; align-items: center; gap: 24px; }
  .brand img { height: 40px; width: auto; }
  .head-nav { display: none; gap: 4px; }
  .head-nav a { text-decoration: none; font-weight: 600; font-size: var(--step--1); padding: 8px 12px; border-radius: var(--pill); color: var(--ink-2); }
  .head-nav a:hover { background: var(--mist); color: var(--ink); }
  .head-nav a[aria-current] { color: var(--ink); background: var(--mist); }
  .head-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
  .head-actions .icon-btn { position: relative; }
  .saved-count { position: absolute; top: 2px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--red); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }
  @media (min-width: 960px) {
    .head-nav { display: flex; }
    .brand img { height: 46px; }
    .head-search { display: none; }
  }


  /* bottom app tab bar (phones) */
  .tabbar {
    position: fixed; inset: auto 0 0; z-index: 45; display: grid; grid-template-columns: repeat(5, 1fr);
    height: calc(var(--tab-h) + var(--safe-b)); padding-bottom: var(--safe-b);
    background: rgba(255, 255, 255, .96); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--line);
  }
  /* keep the bars still while pages change; only the page content cross-fades */
  .tabbar { view-transition-name: tabbar; }
  .app-top { view-transition-name: apptop; }
  ::view-transition-group(tabbar), ::view-transition-group(apptop) { animation: none; }
  .app-main { min-width: 0; }
  .tabbar, .app-top { -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; -webkit-touch-callout: none; }
  .tabbar a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-decoration: none; font-size: 11px; font-weight: 600; color: var(--muted); }
  .tabbar a[aria-current], .tabbar a.is-on { color: var(--navy); }
  .tabbar a[aria-current] svg { color: var(--red); }
  .tabbar .tab-plus { width: 40px; height: 32px; border-radius: 12px; background: var(--navy); color: #fff; display: grid; place-items: center; }
  .tabbar .tab-sell { color: var(--navy); }
  .tabbar .dot { position: absolute; top: 9px; left: calc(50% + 8px); width: 8px; height: 8px; border-radius: 50%; background: var(--red); }
  @media (min-width: 960px) { .tabbar { display: none; } }

  /* footer */
  .site-foot { background: var(--navy); color: #C9D2E6; padding: 48px 0 calc(var(--tab-h) + var(--safe-b) + 28px); margin-top: 48px; }
  @media (min-width: 960px) { .site-foot { padding-bottom: 32px; } }
  .foot-top { display: grid; gap: 32px; }
  .foot-brand img { height: 44px; width: auto; }
  .foot-brand p { margin-top: 14px; max-width: 34ch; font-size: var(--step--1); }
  .foot-cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 20px; }
  .site-foot h3 { color: #fff; font-size: var(--step--1); font-weight: 700; margin-bottom: 10px; font-stretch: 100%; }
  .site-foot ul { list-style: none; padding: 0; display: grid; gap: 7px; font-size: var(--step--1); }
  .site-foot a { text-decoration: none; color: #C9D2E6; }
  .site-foot a:hover { color: #fff; }
  .foot-bottom { margin-top: 36px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-size: 12px; color: #8E9BB9; }
  @media (min-width: 720px) { .foot-cols { grid-template-columns: repeat(3, 1fr); } }
  @media (min-width: 1040px) { .foot-top { grid-template-columns: 1fr 3fr; } .foot-cols { grid-template-columns: repeat(5, 1fr); } }
}

/* ---------------- components ---------------- */
@layer components {
  /* buttons */
  .btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 44px; padding: 0 18px; border-radius: var(--pill);
    font-weight: 650; font-size: var(--step-0); text-decoration: none; white-space: nowrap;
    border: 1.5px solid transparent; transition: background .15s, border-color .15s, transform .1s;
    -webkit-user-select: none; user-select: none;
  }
  .btn:active { transform: scale(.98); }
  .btn-sm { min-height: 36px; padding: 0 14px; font-size: var(--step--1); }
  .btn-lg { min-height: 52px; padding: 0 24px; font-size: var(--step-1); }
  .btn-block { width: 100%; }
  .btn-primary { background: var(--red-btn); color: #fff; }
  .btn-primary:hover { background: var(--red-dark); color: #fff; }
  .btn-ghost { background: var(--paper); color: var(--ink); border-color: var(--line-2); }
  .btn-ghost:hover { border-color: var(--navy); color: var(--ink); }
  .btn-light { background: #fff; color: var(--navy); }
  .btn-light:hover { background: #EEF1F7; color: var(--navy); }
  .btn-wa { background: var(--wa); color: #fff; }
  .btn-wa:hover { background: var(--wa-hover); color: #fff; }
  .btn[disabled] { opacity: .5; pointer-events: none; }
  .icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 50%; color: var(--ink); text-decoration: none; }
  .icon-btn:hover { background: var(--mist); color: var(--ink); }
  .icon-btn.glass { background: rgba(255, 255, 255, .9); backdrop-filter: blur(8px); box-shadow: 0 2px 8px rgba(3, 23, 62, .14); }
  .linklike { color: inherit; text-decoration: underline; text-underline-offset: 3px; font-size: inherit; }
  .link-more { display: inline-flex; align-items: center; gap: 4px; font-weight: 650; font-size: var(--step--1); text-decoration: none; color: var(--navy); }
  .link-more:hover { color: var(--red-btn); }

  /* fields */
  .field { display: grid; gap: 6px; min-width: 0; }
  .field > span, legend { font-size: var(--step--1); font-weight: 650; color: var(--ink-2); }
  .field small { color: var(--muted); }
  input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea {
    width: 100%; min-height: 48px; padding: 10px 14px; border-radius: var(--r-sm);
    border: 1.5px solid var(--line-2); background: var(--paper); font-size: 16px; /* no iOS zoom */
    transition: border-color .15s, box-shadow .15s;
  }
  textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
  select {
    appearance: none; -webkit-appearance: none; padding-right: 38px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%2303173E' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 14px center;
  }
  input:focus, select:focus, textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(3, 23, 62, .12); }
  select:disabled, input:disabled { background-color: var(--mist); color: var(--muted); }
  input[type=file] { font-size: var(--step--1); }
  fieldset { border: 0; padding: 0; min-width: 0; display: grid; gap: 8px; }
  fieldset.group { gap: 14px; padding-bottom: 8px; }
  fieldset.group legend { font-size: var(--step-1); color: var(--ink); font-weight: 750; margin-bottom: 4px; font-stretch: 108%; }
  .field-pair, .field-trio { display: grid; gap: 14px; }
  @media (min-width: 560px) { .field-pair { grid-template-columns: 1fr 1fr; } .field-trio { grid-template-columns: repeat(3, 1fr); } }
  .stack { display: grid; gap: 16px; }
  .check, .tick, .switch { display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 550; }
  .check input, .tick input { width: 20px; height: 20px; accent-color: var(--red-btn); flex: none; }
  .switch input { appearance: none; -webkit-appearance: none; width: 46px; height: 28px; border-radius: 14px; background: var(--line-2); position: relative; transition: background .2s; flex: none; }
  .switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s; }
  .switch input:checked { background: var(--good); }
  .switch input:checked::after { transform: translateX(18px); }
  .switch input:disabled { opacity: .5; }

  /* segmented control */
  .seg { display: flex; padding: 4px; gap: 4px; background: var(--mist); border-radius: var(--pill); overflow-x: auto; scrollbar-width: none; }
  .seg::-webkit-scrollbar { display: none; }
  .seg label { flex: 1 0 auto; cursor: pointer; }
  .seg input { position: absolute; opacity: 0; pointer-events: none; }
  .seg span { display: block; text-align: center; padding: 9px 14px; border-radius: var(--pill); font-weight: 650; font-size: var(--step--1); color: var(--ink-2); white-space: nowrap; transition: background .15s, color .15s; }
  .seg input:checked + span { background: var(--paper); color: var(--navy); box-shadow: 0 1px 3px rgba(3, 23, 62, .16); }
  .seg input:focus-visible + span { box-shadow: var(--ring); }
  .seg-sm span { padding: 7px 10px; }

  /* chips */
  .chips { display: flex; flex-wrap: wrap; gap: 8px; }
  .chip { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: var(--pill); border: 1px solid var(--line-2); text-decoration: none; font-weight: 600; font-size: var(--step--1); color: var(--ink); background: var(--paper); }
  .chip b { color: var(--muted); font-weight: 600; }
  .chip:hover { border-color: var(--navy); color: var(--navy); }

  /* alerts, pills, badges */
  .flashes { display: grid; gap: 8px; margin-top: 12px; }
  .alert { padding: 12px 16px; border-radius: var(--r-sm); font-weight: 550; font-size: var(--step--1); border-left: 4px solid; }
  .alert-success { background: var(--good-bg); border-color: var(--good); color: #064D33; }
  .alert-error { background: var(--bad-bg); border-color: var(--bad); color: #7A160F; }
  .alert-warn { background: #FFF6E0; border-color: #C98A00; color: #5C3D00; margin-bottom: 16px; }
  .alert-info { background: #EEF2FA; border-color: var(--navy); }
  .pill { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: var(--pill); font-size: 12px; font-weight: 700; background: var(--mist); color: var(--ink-2); white-space: nowrap; }
  .pill-live, .pill-verified { background: var(--good-bg); color: var(--good); }
  .pill-draft, .pill-none { background: var(--mist); color: var(--ink-2); }
  .pill-reserved, .pill-pending { background: var(--warn-bg); color: var(--warn); }
  .pill-sold { background: var(--navy); color: #fff; }
  .pill-hidden, .pill-rejected { background: var(--bad-bg); color: var(--bad); }
  .badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--red-btn); color: #fff; font-size: 11px; font-weight: 750; }
  .verified { display: inline-flex; align-items: center; gap: 4px; color: var(--good); font-weight: 650; font-size: var(--step--1); }
  .verified.on-dark { color: #7DE3B6; }
  .mono { display: grid; place-items: center; width: 52px; height: 52px; border-radius: var(--r); background: var(--navy); color: #fff; font-weight: 800; font-size: 22px; font-stretch: 120%; flex: none; }
  .mono.big { width: 72px; height: 72px; font-size: 30px; }

  /* car card */
  .cards { display: grid; gap: 18px; grid-template-columns: 1fr; }
  @media (min-width: 560px) { .cards { grid-template-columns: repeat(2, 1fr); } }
  @media (min-width: 900px) { .cards { grid-template-columns: repeat(3, 1fr); } }
  @media (min-width: 1180px) { .cards:not(.cards-3) { grid-template-columns: repeat(4, 1fr); } }
  .card { position: relative; container-type: inline-size; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; transition: border-color .15s, box-shadow .2s; }
  .card:hover { border-color: var(--line-2); box-shadow: 0 10px 28px -14px rgba(3, 23, 62, .35); }
  .card-link { position: absolute; inset: 0; z-index: 1; }
  .card-link:focus-visible { outline-offset: -3px; border-radius: var(--r-lg); }
  .card-media { position: relative; aspect-ratio: 3 / 2; background: var(--mist); }
  @media (min-width: 560px) { .card-media { aspect-ratio: 4 / 3; } }
  .card-media img { width: 100%; height: 100%; object-fit: cover; }
  .card-body { padding: 14px 16px 16px; display: grid; gap: 6px; }
  .card-title { font-size: var(--step-0); font-weight: 650; font-stretch: 100%; letter-spacing: 0; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .card-price { font-size: var(--step-2); font-weight: 800; font-stretch: 112%; letter-spacing: -.015em; color: var(--navy); font-variant-numeric: tabular-nums; line-height: 1.1; }
  .card-price small { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: 0; font-stretch: 100%; }
  .card-specs { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: var(--step--1); color: var(--ink-2); }
  .card-specs li { display: inline-flex; align-items: center; gap: 4px; }
  .card-specs svg { color: var(--muted); }
  .card-specs .ok, .card-specs .ok svg { color: var(--good); }
  .card-foot { display: flex; justify-content: space-between; gap: 8px; align-items: center; padding-top: 8px; margin-top: 4px; border-top: 1px solid var(--line); font-size: var(--step--1); color: var(--muted); }
  .card-loc { display: inline-flex; align-items: center; gap: 4px; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .card-loc svg { flex: none; }
  .card.is-sold .card-media img { filter: grayscale(.5); opacity: .8; }
  .card .tag { position: absolute; z-index: 2; left: 10px; }
  .tag { display: inline-flex; padding: 4px 9px; border-radius: 6px; font-size: 11.5px; font-weight: 700; background: rgba(255, 255, 255, .94); color: var(--navy); }
  .tag-cond { top: 10px; }
  .tag-new { background: var(--navy); color: #fff; }
  .tag-sold, .tag-reserved, .tag-fresh { bottom: 10px; }
  .tag-sold { background: var(--navy); color: #fff; }
  .tag-reserved { background: #FFE6B0; color: #6E4100; }
  .tag-fresh { background: var(--red-btn); color: #fff; }
  .tag-ok { background: var(--good-bg); color: var(--good); }
  .save-btn { position: absolute; z-index: 2; top: 8px; right: 8px; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .92); color: var(--navy); box-shadow: 0 1px 4px rgba(3, 23, 62, .18); }
  .save-btn .on { display: none; color: var(--red); }
  .save-btn[aria-pressed=true] .on { display: block; animation: pop .3s ease-out; }
  .save-btn[aria-pressed=true] .off { display: none; }
  @keyframes pop { 50% { transform: scale(1.25); } }
  .noimg { width: 100%; height: 100%; display: grid; place-content: center; justify-items: center; gap: 6px; color: var(--line-2); font-size: 12px; font-weight: 600; }
  .noimg span { color: var(--muted); }
  @container (max-width: 240px) { .card-body { padding: 10px 12px 12px; } .card-specs li:nth-child(n+3) { display: none; } }

  /* horizontal rails (scroll-snap) */
  .rail { display: grid; grid-auto-flow: column; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 12px; margin-inline: calc(-1 * var(--gap)); padding-inline: var(--gap); scrollbar-width: none; overscroll-behavior-x: contain; }
  .rail::-webkit-scrollbar { display: none; }
  .rail > * { scroll-snap-align: start; }
  .cards-rail { grid-auto-columns: min(78%, 290px); }

  /* section headings */
  .sec-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
  .sub-h { font-size: var(--step-2); margin: 36px 0 16px; }

  /* empty states */
  .empty { border: 1.5px dashed var(--line-2); border-radius: var(--r-lg); padding: clamp(28px, 5vw, 48px); text-align: center; display: grid; justify-items: center; gap: 10px; background: var(--paper); }
  .empty p { color: var(--muted); max-width: 46ch; }
  .empty.compact { padding: 22px; }
  .empty-page { text-align: center; display: grid; justify-items: center; gap: 14px; padding-block: 72px; }
  .empty-page p { color: var(--muted); max-width: 46ch; }
  .inline-search { display: flex; gap: 8px; width: min(100%, 460px); }

  /* breadcrumbs */
  .crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: var(--step--1); color: var(--muted); padding-block: 14px 6px; }
  .crumbs a { text-decoration: none; color: var(--muted); }
  .crumbs a:hover { color: var(--navy); text-decoration: underline; }
  .crumbs [aria-current] { color: var(--ink); font-weight: 600; }

  /* pager */
  .pager { display: flex; align-items: center; justify-content: center; gap: 16px; padding: 28px 0; color: var(--muted); font-size: var(--step--1); }

  /* tables */
  .table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--paper); }
  .table { width: 100%; font-size: var(--step--1); }
  .table th { text-align: left; font-weight: 650; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: #FAFBFD; }
  .table td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
  .table tr:last-child td { border-bottom: 0; }
  .table .num { text-align: right; font-variant-numeric: tabular-nums; }
  .table input, .table select { min-height: 38px; padding: 6px 10px; font-size: 14px; }
  .table select { padding-right: 32px; background-position: right 10px center; }
  .w-year { width: 96px !important; }

  /* details menus */
  details.menu { position: relative; }
  details.menu summary { list-style: none; }
  details.menu summary::-webkit-details-marker { display: none; }
  .menu-pop { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; min-width: 190px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-pop); padding: 6px; display: grid; }
  .menu-pop a, .menu-pop button { display: block; width: 100%; text-align: left; padding: 10px 12px; border-radius: var(--r-sm); text-decoration: none; font-weight: 550; font-size: var(--step--1); }
  .menu-pop a:hover, .menu-pop button:hover { background: var(--mist); color: var(--ink); }
  .menu-pop .danger { color: var(--bad); }
  .menu-pop form { display: contents; }

  /* "Get the CarGrid app": bottom sheet on phones, corner card on computers */
  .install-sheet { position: fixed; inset: 0; z-index: 80; display: grid; align-items: end; pointer-events: none; }
  .install-sheet[hidden] { display: none; }
  .is-scrim { position: absolute; inset: 0; background: rgba(3, 23, 62, .45); pointer-events: auto; animation: fadeIn .25s ease-out; }
  .is-card { position: relative; pointer-events: auto; background: var(--paper); color: var(--ink); border-radius: 24px 24px 0 0; padding: 10px 20px calc(18px + var(--safe-b)); box-shadow: 0 -16px 48px rgba(3, 23, 62, .28); animation: sheetUp .38s cubic-bezier(.2, .9, .2, 1); max-height: 88dvh; overflow-y: auto; }
  .is-grab { display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 14px; }
  .is-x { position: absolute; top: 12px; right: 12px; width: 36px; height: 36px; color: var(--muted); }
  .is-head { display: flex; align-items: center; gap: 14px; margin: 4px 36px 16px 0; }
  .is-head img { width: 56px; height: 56px; border-radius: 14px; box-shadow: 0 4px 14px rgba(3, 23, 62, .2); flex: none; }
  .is-head strong { display: block; font-size: var(--step-1); line-height: 1.2; }
  .is-head span { color: var(--muted); font-size: var(--step--1); }
  .is-perks { display: grid; gap: 10px; margin: 0 0 18px; }
  .is-perks li { display: flex; gap: 10px; align-items: center; font-weight: 600; font-size: var(--step--1); }
  .is-perks svg { color: var(--good, #138A4B); flex: none; }
  .is-steps { display: grid; gap: 12px; margin: 0 0 18px; padding: 14px; background: var(--mist); border-radius: var(--r); counter-reset: none; font-size: var(--step--1); line-height: 1.45; }
  .is-steps li { display: flex; gap: 12px; align-items: flex-start; }
  .is-steps li > b { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-size: 13px; }
  .is-key { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; margin: 0 2px; border-radius: 8px; background: var(--paper); border: 1px solid var(--line); font-weight: 700; white-space: nowrap; vertical-align: middle; }
  .is-key svg { color: #0A7AFF; }
  .is-inapp { display: grid; gap: 10px; }
  .is-inapp .btn { justify-self: start; }
  .is-actions { display: grid; gap: 8px; }
  .is-go { width: 100%; justify-content: center; }
  .is-later { width: 100%; justify-content: center; border-color: transparent; color: var(--muted); }
  html.install-open { overflow: hidden; }
  @media (min-width: 960px) {
    .install-sheet { inset: auto 24px 24px auto; width: 400px; }
    .is-scrim, .is-grab, .is-later { display: none; }
    .is-card { border-radius: var(--r-lg); padding: 18px 20px; box-shadow: var(--shadow-pop); animation: rise .35s cubic-bezier(.2, .8, .2, 1); }
    html.install-open { overflow: visible; }
    .is-perks { display: none; }
  }
  .site-foot .foot-app { color: #fff; background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.35); }
  .site-foot .foot-app:hover { color: #fff; background: rgba(255,255,255,.16); border-color: #fff; }
  .install-sheet:not([data-mode=perks]) .is-go svg { display: none; }
  @keyframes sheetUp { from { transform: translateY(100%); } }
  @keyframes fadeIn { from { opacity: 0; } }
  @keyframes rise { from { transform: translateY(16px); opacity: 0; } }

  .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .hp { position: absolute; left: -9999px; }
}

/* ---------------- pages ---------------- */
@layer pages {
  /* ===== Hero + the grid motif (the signature element) ===== */
  .hero { position: relative; overflow: hidden; background: var(--navy); color: #fff; padding: clamp(36px, 7vw, 88px) 0 clamp(28px, 5vw, 56px); isolation: isolate; }
  .hero-grid { position: absolute; z-index: -1; right: -40px; top: 32px; width: min(62vw, 640px); aspect-ratio: 2 / 1; display: grid; grid-template-columns: repeat(7, 1fr); grid-template-rows: repeat(2, 1fr); gap: 10px; transform: skewX(-18deg); opacity: .9; }
  .hero-grid i { display: block; border-radius: 3px; background: var(--red); opacity: 0; animation: gridIn .6s cubic-bezier(.2, .8, .2, 1) forwards; }
  .hero-grid i:nth-child(3n) { background: var(--navy-3); }
  .hero-grid i:nth-child(5n+1) { background: transparent; }
  .hero-grid i:nth-child(1) { animation-delay: .02s } .hero-grid i:nth-child(2) { animation-delay: .06s } .hero-grid i:nth-child(3) { animation-delay: .1s }
  .hero-grid i:nth-child(4) { animation-delay: .14s } .hero-grid i:nth-child(5) { animation-delay: .18s } .hero-grid i:nth-child(6) { animation-delay: .22s }
  .hero-grid i:nth-child(7) { animation-delay: .26s } .hero-grid i:nth-child(8) { animation-delay: .08s } .hero-grid i:nth-child(9) { animation-delay: .12s }
  .hero-grid i:nth-child(10) { animation-delay: .16s } .hero-grid i:nth-child(11) { animation-delay: .2s } .hero-grid i:nth-child(12) { animation-delay: .24s }
  .hero-grid i:nth-child(13) { animation-delay: .28s } .hero-grid i:nth-child(14) { animation-delay: .32s }
  @keyframes gridIn { from { opacity: 0; transform: translateX(-28px); } to { opacity: var(--o, .85); transform: none; } }
  .hero-grid i:nth-child(-n+3) { --o: .35; } .hero-grid i:nth-child(n+8):nth-child(-n+10) { --o: .5; }
  @media (max-width: 720px) { .hero-grid { width: 92vw; right: -38vw; top: 18px; opacity: .55; } }
  .hero-inner { position: relative; display: grid; gap: clamp(22px, 4vw, 36px); }
  .hero-copy { max-width: 680px; }
  .hero h1 { font-size: var(--step-5); font-stretch: 122%; line-height: 1.02; letter-spacing: -.03em; }
  .hero p { margin-top: 16px; font-size: var(--step-1); color: #C3CDE3; max-width: 56ch; }
  .hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

  .search-card { background: var(--paper); color: var(--ink); border-radius: var(--r-lg); padding: 14px; box-shadow: var(--shadow-pop); display: grid; gap: 14px; max-width: 1040px; }
  .search-fields { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
  .search-fields .search-go { grid-column: 1 / -1; }
  @media (max-width: 639px) { .search-card .field > span { font-size: 12px; } .search-card select { font-size: 15px; padding-left: 12px; } }
  @media (min-width: 1000px) { .search-card { padding: 18px; } .search-fields { grid-template-columns: repeat(4, 1fr) auto; align-items: end; } .search-fields .search-go { grid-column: auto; } }
  .search-go { width: 100%; }
  @media (min-width: 1000px) { .search-go { width: auto; min-height: 48px; } }
  .search-quick { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: var(--step--1); color: var(--muted); align-items: center; }
  .search-quick a { font-weight: 600; color: var(--navy); text-decoration: none; }
  .search-quick a:hover { text-decoration: underline; }
  .hero-stats { display: flex; flex-wrap: wrap; gap: 14px 40px; }
  .hero-stats div { display: flex; flex-direction: column-reverse; }
  .hero-stats dt { color: #9FAED0; font-size: var(--step--1); }
  .hero-stats dd { margin: 0; font-size: var(--step-3); font-weight: 800; font-stretch: 115%; font-variant-numeric: tabular-nums; }

  /* body type tiles */
  .body-rail { grid-auto-columns: 128px; }
  .body-tile { display: grid; justify-items: start; gap: 2px; padding: 16px 14px 14px; border: 1px solid var(--line); border-radius: var(--r); text-decoration: none; color: var(--ink); background: var(--paper); }
  .body-tile:hover { border-color: var(--navy); color: var(--ink); }
  .body-ico { width: 64px; height: 28px; color: var(--navy); margin-bottom: 8px; }
  .bt-name { font-weight: 700; font-size: var(--step--1); }
  .bt-n { font-size: 12px; color: var(--muted); }

  /* brand grid */
  .brand-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
  @media (min-width: 640px) { .brand-grid { grid-template-columns: repeat(4, 1fr); } }
  @media (min-width: 1100px) { .brand-grid { grid-template-columns: repeat(8, 1fr); } }
  .brand-tile { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 10px; align-items: center; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
  .brand-tile:hover { border-color: var(--navy); color: var(--ink); }
  .brand-tile img, .brand-tile .mono { grid-row: span 2; width: 40px; height: 40px; border-radius: 10px; font-size: 18px; }
  .brand-tile img { object-fit: contain; }
  .lp-brand { display: flex; align-items: center; gap: 12px; }
  .lp-brand img { width: 44px; height: 44px; object-fit: contain; flex: none; }
  .brand-tile .bn { font-weight: 700; font-size: var(--step--1); line-height: 1.2; }
  .brand-tile .bc { font-size: 12px; color: var(--muted); }
  @media (min-width: 1100px) { .brand-tile { grid-template-columns: 1fr; justify-items: center; text-align: center; row-gap: 6px; padding: 16px 10px; } .brand-tile img, .brand-tile .mono { grid-row: auto; } }

  .split { display: grid; gap: 32px; }
  .split h2 { font-size: var(--step-2); margin-bottom: 14px; }
  @media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } }

  .trust { background: var(--mist); padding: clamp(40px, 6vw, 72px) 0; margin-top: clamp(16px, 3vw, 32px); }
  .trust-inner h2 { max-width: 22ch; }
  .trust-points { display: grid; gap: 24px; margin-top: 28px; }
  @media (min-width: 820px) { .trust-points { grid-template-columns: repeat(3, 1fr); gap: 32px; } }
  .trust-points svg { color: var(--red); margin-bottom: 12px; }
  .trust-points p { color: var(--ink-2); margin-top: 6px; }

  .dealer-cta { display: grid; gap: 20px; align-items: center; border-radius: var(--r-lg); background: linear-gradient(115deg, var(--navy) 0%, var(--navy-2) 100%); color: #fff; padding: clamp(28px, 5vw, 48px); margin-top: clamp(32px, 5vw, 56px); }
  .dealer-cta.section { padding-block: clamp(28px, 5vw, 48px); }
  .dealer-cta p { color: #C3CDE3; margin-top: 10px; max-width: 56ch; }
  @media (min-width: 900px) { .dealer-cta { grid-template-columns: 1fr auto; } }

  /* ===== Listing / SEO pages ===== */
  .lp-head { padding: 6px 0 18px; display: grid; gap: 10px; }
  .lp-intro { color: var(--ink-2); max-width: 70ch; font-size: var(--step-1); }
  .lp-body { display: grid; gap: 24px; }
  @media (min-width: 1000px) { .lp-body { grid-template-columns: 290px 1fr; align-items: start; } }

  .price-box { display: grid; gap: 16px; padding: 20px; border-radius: var(--r-lg); background: var(--navy); color: #fff; margin-bottom: 24px; }
  .pb-main { display: grid; gap: 4px; }
  .pb-label { color: #A9B6D4; font-size: var(--step--1); font-weight: 600; }
  .pb-range { font-size: var(--step-4); font-weight: 800; font-stretch: 118%; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.05; }
  .pb-note { color: #C3CDE3; font-size: var(--step--1); }
  .pb-conds { display: flex; flex-wrap: wrap; gap: 10px; }
  .pb-conds div { background: rgba(255, 255, 255, .08); border-radius: var(--r-sm); padding: 10px 14px; }
  .pb-conds dt { color: #A9B6D4; font-size: 12px; }
  .pb-conds dd { margin: 0; font-weight: 750; font-variant-numeric: tabular-nums; }
  @media (min-width: 900px) { .price-box { grid-template-columns: 1fr auto; align-items: center; padding: 26px 30px; } }

  /* filters: sidebar on desktop, slide-up sheet on phones */
  .filter-form { display: grid; }
  .filter-scroll { display: grid; gap: 16px; }
  .sheet-head, .sheet-foot { display: none; }
  .f-q { background: var(--mist) !important; border-color: transparent !important; }
  @media (min-width: 1000px) {
    .filters { position: sticky; top: calc(var(--head-h) + 16px); max-height: calc(100dvh - var(--head-h) - 32px); overflow-y: auto; padding: 18px; border: 1px solid var(--line); border-radius: var(--r-lg); scrollbar-width: thin; }
    .sheet-foot { display: flex; gap: 8px; position: sticky; bottom: -18px; background: var(--paper); padding: 14px 0 0; margin-top: 16px; }
    .sheet-foot .btn { flex: 1; }
    .filter-open { display: none; }
  }
  @media (max-width: 999px) {
    .filters { position: fixed; inset: auto 0 0; z-index: 70; max-height: 88dvh; background: var(--paper); border-radius: 22px 22px 0 0; box-shadow: 0 -12px 40px rgba(3, 23, 62, .25); transform: translateY(105%); transition: transform .3s cubic-bezier(.2, .8, .2, 1); display: flex; flex-direction: column; padding-bottom: var(--safe-b); }
    .filters.open { transform: none; }
    .filter-form { display: flex; flex-direction: column; min-height: 0; flex: 1; }
    .sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 6px 20px; font-size: var(--step-1); }
    .sheet-head::before { content: ""; position: absolute; top: 8px; left: 50%; width: 40px; height: 4px; margin-left: -20px; border-radius: 2px; background: var(--line-2); }
    .filter-scroll { overflow-y: auto; padding: 4px 20px 16px; overscroll-behavior: contain; }
    .sheet-foot { display: flex; gap: 10px; padding: 12px 20px; border-top: 1px solid var(--line); }
    .sheet-foot .btn { flex: 1; }
  }
  .scrim { position: fixed; inset: 0; z-index: 65; background: rgba(3, 23, 62, .45); }
  @media (min-width: 1000px) { .scrim { display: none !important; } }

  .toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
  .toolbar .count { margin-right: auto; color: var(--ink-2); }
  .toolbar .count strong { color: var(--ink); font-variant-numeric: tabular-nums; }
  .sort-form select { min-height: 36px; padding: 6px 34px 6px 14px; border-radius: var(--pill); font-size: 14px; font-weight: 600; width: auto; background-position: right 12px center; }
  .related, .faqs { margin-top: 40px; }
  .related h2, .faqs h2 { font-size: var(--step-2); margin-bottom: 14px; }
  .faqs details { border-top: 1px solid var(--line); padding: 14px 0; }
  .faqs details:last-child { border-bottom: 1px solid var(--line); }
  .faqs summary { cursor: pointer; font-weight: 650; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
  .faqs summary::after { content: "+"; font-size: 22px; line-height: 1; color: var(--muted); }
  .faqs details[open] summary::after { content: "–"; }
  .faqs p { margin-top: 8px; color: var(--ink-2); max-width: 72ch; }

  /* ===== Car page ===== */
  .owner-bar { background: var(--warn-bg); color: #6E4100; text-align: center; padding: 10px 16px; font-weight: 600; font-size: var(--step--1); }
  .car-layout { display: grid; gap: 20px; }
  @media (min-width: 1000px) {
    .car-layout { grid-template-columns: minmax(0, 1fr) 380px; grid-template-areas: "gal panel" "details panel"; gap: 28px 36px; align-items: start; }
    .gallery { grid-area: gal; } .car-panel { grid-area: panel; position: sticky; top: calc(var(--head-h) + 16px); } .car-details { grid-area: details; }
  }
  .gallery { position: relative; }
  .gal-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: var(--r-lg); background: var(--mist); overscroll-behavior-x: contain; }
  .gal-track::-webkit-scrollbar { display: none; }
  .gal-slide { flex: 0 0 100%; scroll-snap-align: center; aspect-ratio: 4 / 3; }
  .gal-slide img, .gal-slide .noimg { width: 100%; height: 100%; object-fit: cover; }
  .gal-count { position: absolute; bottom: 12px; left: 12px; background: rgba(3, 23, 62, .75); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: var(--pill); font-variant-numeric: tabular-nums; }
  .gal-tools { position: absolute; top: 12px; right: 12px; display: flex; gap: 8px; }
  .gal-tools .save-btn { position: static; width: 44px; height: 44px; }
  .gal-back { display: none; }
  .gal-nav { display: none; position: absolute; top: 50%; translate: 0 -50%; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .92); place-items: center; color: var(--navy); box-shadow: 0 2px 10px rgba(3, 23, 62, .2); }
  .gal-prev { left: 12px; } .gal-next { right: 12px; }
  .gal-thumbs { display: none; gap: 8px; margin-top: 10px; overflow-x: auto; scrollbar-width: none; }
  .gal-thumbs button { flex: none; border-radius: var(--r-sm); overflow: hidden; opacity: .6; outline: 2px solid transparent; outline-offset: -2px; }
  .gal-thumbs button.on { opacity: 1; outline-color: var(--red); }
  .gal-thumbs img { width: 96px; height: 72px; object-fit: cover; }
  @media (min-width: 1000px) {
    .gal-nav { display: grid; } .gal-thumbs { display: flex; }
    .gallery:has(.gal-thumbs) .gal-count { bottom: calc(72px + 22px); }
    .gallery:has(.gal-thumbs) .gal-nav { top: calc((100% - 82px) / 2); }
  }
  @media (max-width: 999px) {
    .car-top { display: none; }
    .gallery { margin-inline: calc(-1 * var(--gap)); }
    .gal-track { border-radius: 0; }
    body:has(.car-page .gallery) .site-head { display: none; }
    .gal-back { display: grid; position: absolute; z-index: 3; top: calc(12px + env(safe-area-inset-top, 0px)); left: 12px; width: 44px; height: 44px; border-radius: 50%; place-items: center; background: rgba(255, 255, 255, .92); color: var(--navy); box-shadow: 0 2px 8px rgba(3, 23, 62, .14); }
    .gal-tools { top: calc(12px + env(safe-area-inset-top, 0px)); }
  }
  .car-page:not(:has(.gallery)) .gal-back { display: none; }

  .panel-card { display: grid; gap: 10px; }
  @media (min-width: 1000px) { .panel-card { padding: 24px; border: 1px solid var(--line); border-radius: var(--r-lg); } }
  .tags-row { display: flex; flex-wrap: wrap; gap: 6px; }
  .tags-row .tag { position: static; background: var(--mist); }
  .tags-row .tag-sold { background: var(--navy); }
  .car-title { font-size: var(--step-3); font-stretch: 110%; }
  .car-loc { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: var(--step--1); }
  .car-price { font-size: var(--step-4); font-weight: 800; font-stretch: 116%; letter-spacing: -.02em; color: var(--navy); font-variant-numeric: tabular-nums; line-height: 1.05; margin-top: 4px; }
  .neg { color: var(--muted); font-size: var(--step--1); margin-top: -4px; }
  .verdict { display: grid; gap: 8px; padding: 12px 14px; border-radius: var(--r); background: var(--mist); font-size: var(--step--1); }
  .verdict strong { margin-right: 4px; }
  .v-meter { position: relative; height: 6px; border-radius: 3px; background: linear-gradient(90deg, #0B8457 0 30%, #5BA67D 30% 55%, #D9A23A 55% 80%, #C0453B 80%); }
  .v-meter i { position: absolute; top: 50%; left: var(--pos); width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: #fff; border: 3px solid var(--navy); }
  .v-great strong, .v-good strong { color: var(--good); } .v-fair strong { color: var(--warn); } .v-high strong { color: var(--bad); }
  .cta-stack { display: grid; gap: 10px; margin-top: 6px; }
  .sold-note { padding: 12px 14px; border-radius: var(--r); background: var(--mist); font-size: var(--step--1); }
  .dealer-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-lg); text-decoration: none; color: var(--ink); margin-top: 14px; background: var(--paper); }
  .dealer-card:hover { border-color: var(--navy); color: var(--ink); }
  .dealer-card img { width: 52px; height: 52px; border-radius: var(--r); object-fit: cover; }
  .dc-text { display: grid; flex: 1; min-width: 0; gap: 2px; }
  .dc-text > span { font-size: var(--step--1); color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 10px; }

  .car-details { display: grid; gap: 8px; }
  .block { padding: 22px 0; border-top: 1px solid var(--line); }
  .block h2 { font-size: var(--step-2); margin-bottom: 14px; }
  .spec-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
  @media (min-width: 640px) { .spec-grid { grid-template-columns: repeat(3, 1fr); } }
  .spec-grid div { background: var(--paper); padding: 12px 14px; outline: 1px solid var(--line); }
  .spec-grid dt { font-size: 12px; color: var(--muted); font-weight: 600; }
  .spec-grid dd { margin: 2px 0 0; font-weight: 650; }
  .prose { color: var(--ink-2); max-width: 72ch; }
  .feature-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px 16px; }
  .feature-list li { display: flex; gap: 8px; align-items: center; }
  .feature-list svg { color: var(--good); flex: none; }
  .where { display: flex; gap: 10px; color: var(--ink-2); }
  .where svg { color: var(--red); flex: none; margin-top: 3px; }
  .yt { position: relative; display: block; width: 100%; max-width: 720px; aspect-ratio: 16 / 9; border-radius: var(--r-lg); overflow: hidden; background: #000; }
  .yt img { width: 100%; height: 100%; object-fit: cover; opacity: .85; }
  .yt-play { position: absolute; inset: 0; margin: auto; width: 68px; height: 68px; border-radius: 50%; background: var(--red-btn); color: #fff; display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0, 0, 0, .35); }
  .yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
  .safety ul { padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); }
  .report { margin-top: 18px; }
  .report summary { cursor: pointer; display: inline-flex; gap: 6px; align-items: center; font-size: var(--step--1); color: var(--muted); font-weight: 600; }
  .report form { margin-top: 12px; max-width: 420px; }

  .contact-bar { position: fixed; z-index: 46; inset: auto 0 0; display: flex; align-items: center; gap: 10px; padding: 10px 14px calc(10px + var(--safe-b)); background: rgba(255, 255, 255, .97); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
  .cb-price { display: grid; margin-right: auto; line-height: 1.15; min-width: 0; }
  .cb-price strong { font-size: var(--step-2); font-weight: 800; font-stretch: 112%; color: var(--navy); }
  .cb-price span { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .contact-bar .btn-ghost { width: 48px; padding: 0; }
  .contact-bar .btn-wa { padding: 0 20px; min-height: 48px; }
  .car-page ~ .tabbar, body:has(.contact-bar) .tabbar { display: none; }
  @media (min-width: 1000px) { .contact-bar { display: none; } }

  /* ===== Dealer storefront ===== */
  .store-head { background: var(--navy); color: #fff; padding: 28px 0; }
  .store-inner { display: grid; gap: 18px; grid-template-columns: auto 1fr; align-items: center; }
  .store-logo { width: 72px; height: 72px; border-radius: var(--r-lg); background: #fff; object-fit: cover; }
  .store-logo.mono { background: var(--red-btn); font-size: 30px; }
  .store-text h1 { font-size: var(--step-3); }
  .store-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 8px; color: #C3CDE3; font-size: var(--step--1); }
  .store-meta span { display: inline-flex; align-items: center; gap: 5px; }
  .store-cta { grid-column: 1 / -1; display: flex; gap: 10px; }
  .store-cta .btn { flex: 1; }
  @media (min-width: 820px) { .store-inner { grid-template-columns: auto 1fr auto; } .store-cta { grid-column: auto; } .store-logo { width: 88px; height: 88px; } }
  .store-body { display: grid; gap: 28px; padding-block: 28px; }
  @media (min-width: 1000px) { .store-body { grid-template-columns: 1fr 320px; align-items: start; } }
  .store-side { display: grid; gap: 16px; }
  .side-block { padding: 18px; border: 1px solid var(--line); border-radius: var(--r-lg); display: grid; gap: 10px; }
  .side-block h2 { font-size: var(--step-1); }
  .stand { display: grid; gap: 4px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
  .stand:last-of-type { border-bottom: 0; }
  .stand p { color: var(--ink-2); font-size: var(--step--1); }
  .socials a { font-weight: 600; text-decoration: none; color: var(--navy); }
  .dealer-list { display: grid; gap: 12px; }
  @media (min-width: 760px) { .dealer-list { grid-template-columns: 1fr 1fr; } }
  .dealer-list .dealer-card { margin-top: 0; }

  /* ===== Static pages ===== */
  .prose-page { max-width: 760px; }
  .prose-page h1 { margin-bottom: 18px; }
  .prose-page h2 { font-size: var(--step-2); margin: 28px 0 10px; }
  .prose-page p, .prose-page li { color: var(--ink-2); }
  .prose-page ul { padding-left: 20px; display: grid; gap: 6px; }
  .step-list { counter-reset: s; display: grid; gap: 18px; margin-top: 24px; }
  @media (min-width: 900px) { .step-list { grid-template-columns: repeat(3, 1fr); } }
  .step-list li { counter-increment: s; padding: 22px; border: 1px solid var(--line); border-radius: var(--r-lg); }
  .step-list li::before { content: counter(s); display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--navy); color: #fff; font-weight: 800; margin-bottom: 14px; }
  .step-list p { color: var(--ink-2); margin-top: 6px; }
  .plans { display: grid; gap: 14px; margin-top: 18px; }
  @media (min-width: 640px) { .plans { grid-template-columns: repeat(2, 1fr); } }
  @media (min-width: 1100px) { .plans { grid-template-columns: repeat(4, 1fr); } }
  .plan { padding: 22px; border: 1px solid var(--line); border-radius: var(--r-lg); display: grid; gap: 10px; align-content: start; }
  .plan-pick { border: 2px solid var(--navy); }
  .plan-price { font-size: var(--step-3); font-weight: 800; font-stretch: 114%; color: var(--navy); }
  .plan-price small { font-size: var(--step--1); color: var(--muted); font-weight: 600; }
  .plan ul { padding-left: 18px; display: grid; gap: 6px; color: var(--ink-2); font-size: var(--step--1); }
  .center-cta { text-align: center; margin-top: 28px; }
  .hero-sell { padding-bottom: clamp(48px, 8vw, 96px); }

  /* ===== Auth ===== */
  .auth { min-height: 100dvh; display: grid; }
  @media (min-width: 960px) { .auth { grid-template-columns: 5fr 6fr; } }
  .auth-art { display: none; position: relative; overflow: hidden; background: var(--navy); color: #fff; padding: 48px; isolation: isolate; }
  .auth-art .hero-grid { top: auto; bottom: 64px; right: -60px; width: 120%; }
  .auth-art img { height: 52px; width: auto; }
  .auth-quote { margin-top: 32px; font-size: var(--step-3); font-weight: 750; font-stretch: 115%; line-height: 1.15; max-width: 16ch; letter-spacing: -.02em; }
  @media (min-width: 960px) { .auth-art { display: block; } }
  .auth-main { width: min(100% - 40px, 520px); margin: 0 auto; padding: 32px 0 48px; display: grid; gap: 14px; align-content: start; }
  .auth-brand img { height: 44px; width: auto; }
  @media (min-width: 960px) { .auth-brand { display: none; } .auth-main { align-content: center; } }
  .auth-h { font-size: var(--step-3); margin-top: 10px; }
  .auth-alt { text-align: center; font-size: var(--step--1); }
  .loc-fields { display: grid; gap: 14px; }
  .area-field { position: relative; }
  .suggest { position: absolute; z-index: 30; top: 76px; left: 0; right: 0; background: var(--paper); border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: var(--shadow-pop); max-height: 260px; overflow-y: auto; padding: 6px; }
  .suggest li { padding: 10px 12px; border-radius: var(--r-sm); cursor: pointer; font-weight: 550; display: flex; justify-content: space-between; gap: 10px; }
  .suggest li[aria-selected=true], .suggest li:hover { background: var(--mist); }
  .suggest li small { color: var(--muted); font-weight: 500; }

  /* install page */
  body.install { background: var(--mist); }
  .install-card { width: min(100% - 32px, 560px); margin: 40px auto; padding: 32px; background: #fff; border-radius: var(--r-lg); display: grid; gap: 16px; box-shadow: var(--shadow-pop); }
  .install-card img { height: 48px; width: auto; }
  .checks { list-style: none; padding: 0; display: grid; gap: 4px; font-size: var(--step--1); }
  .checks .ok { color: var(--good); } .checks .bad { color: var(--bad); font-weight: 700; }

  /* ===== App shell (dashboard + admin) ===== */
  .app-body { background: var(--mist); }
  .side { display: none; }
  .app-top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px; padding: calc(10px + env(safe-area-inset-top, 0px)) 16px 10px; background: rgba(255, 255, 255, .95); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
  .who { display: grid; line-height: 1.2; margin-right: auto; min-width: 0; }
  .who strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .who span { font-size: 12px; color: var(--muted); }
  .app-content { padding: 18px 16px calc(var(--tab-h) + var(--safe-b) + 24px); max-width: 1180px; }
  .app-main > .flashes { padding: 0 16px; }
  @media (min-width: 960px) {
    .app-body { display: grid; grid-template-columns: 248px 1fr; }
    .side { display: flex; flex-direction: column; gap: 22px; position: sticky; top: 0; height: 100vh; height: 100dvh; padding: 22px 16px; background: var(--navy); color: #C9D2E6; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; }
    .side .brand { background: #fff; border-radius: var(--r); padding: 8px 12px; align-self: start; }
    .side .brand img { height: 36px; }
    .side nav { display: grid; gap: 2px; }
    .side nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-sm); text-decoration: none; color: #C9D2E6; font-weight: 600; font-size: var(--step--1); }
    .side nav a:hover { background: rgba(255, 255, 255, .07); color: #fff; }
    .side nav a[aria-current] { background: rgba(255, 255, 255, .12); color: #fff; }
    .side nav a[aria-current] svg { color: var(--red); }
    .side nav .badge { margin-left: auto; }
    .side-tag { font-size: 12px; font-weight: 700; color: #fff; background: var(--red-btn); align-self: start; padding: 2px 10px; border-radius: var(--pill); margin-top: -10px; }
    .side-foot { margin-top: auto; display: grid; gap: 2px; font-size: var(--step--1); padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .12); }
    .side-foot a, .side-foot button { display: block; width: 100%; padding: 9px 12px; border-radius: var(--r-sm); color: #DCE3F2; font-weight: 600; text-decoration: none; text-align: left; }
    .side-foot a:hover, .side-foot button:hover { color: #fff; background: rgba(255, 255, 255, .07); }
    .side-foot form { margin: 0; }
    @media (max-height: 820px) { .side { gap: 14px; padding-block: 14px; } .side nav a { padding-block: 8px; } }
    .app-top { padding: 14px 32px; }
    .app-content { padding: 28px 32px 48px; }
    .app-main > .flashes { padding: 0 32px; }
    .more-nav, .admin-mobile-nav { display: none !important; }
  }
  .admin-mobile-nav select { min-height: 38px; padding: 6px 32px 6px 12px; font-size: 14px; width: auto; }
  .page-head { margin-bottom: 18px; display: grid; gap: 6px; }
  .page-head h1 { font-size: var(--step-3); font-stretch: 110%; }
  .page-head.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
  .page-head.row h1 { margin-right: auto; }
  .back-link { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--paper); border: 1px solid var(--line); color: var(--ink); }
  .mini-search input { min-height: 40px; padding: 6px 14px; border-radius: var(--pill); width: 220px; }
  .panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; margin-bottom: 16px; }
  .panel h2 { font-size: var(--step-1); margin-bottom: 12px; font-stretch: 106%; }
  .panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
  .panel-head h2 { margin: 0; }
  @media (min-width: 960px) { .panel { padding: 22px 24px; } }
  .two-col { display: grid; gap: 16px; }
  @media (min-width: 1000px) { .two-col { grid-template-columns: 1fr 1fr; align-items: start; } .two-col > .panel { margin-bottom: 0; } }
  .kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 16px; }
  @media (min-width: 760px) { .kpis { grid-template-columns: repeat(5, 1fr); } .kpis-4 { grid-template-columns: repeat(4, 1fr); } }
  .kpi { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; display: grid; gap: 2px; }
  .kpi span { font-size: 12px; font-weight: 650; color: var(--muted); }
  .kpi strong { font-size: var(--step-3); font-weight: 800; font-stretch: 114%; font-variant-numeric: tabular-nums; line-height: 1.15; color: var(--navy); }
  .kpi small { font-size: 12px; color: var(--muted); }
  .nudge { display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-bottom: 16px; border-radius: var(--r-lg); background: var(--navy); color: #fff; text-decoration: none; }
  .nudge:hover { color: #fff; background: var(--navy-2); }
  .nudge > svg:first-child { color: #7DE3B6; flex: none; }
  .nudge span { display: grid; flex: 1; font-size: var(--step--1); color: #C3CDE3; }
  .nudge strong { color: #fff; font-size: var(--step-0); }
  .todo { display: grid; gap: 10px; }
  .todo li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 12px 14px; border-radius: var(--r); background: var(--mist); font-size: var(--step--1); }
  .todo a { text-decoration: none; }
  .inline { display: inline-flex; gap: 8px; flex-wrap: wrap; align-items: center; }
  .wrap-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; margin-bottom: 16px; }
  .wrap-row input:not([type=checkbox]) { width: auto; min-width: 160px; }
  .lead-mini, .car-mini { display: grid; gap: 2px; }
  .lead-mini li { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: var(--step--1); }
  .lead-mini li:last-child { border-bottom: 0; }
  .lm-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
  .src { display: inline-flex; padding: 2px 8px; border-radius: 6px; font-size: 11px; font-weight: 750; background: var(--mist); }
  .src-whatsapp { background: #E3F6EC; color: var(--wa); }
  .src-call { background: #E8EEFA; color: var(--navy); }
  .car-mini a { display: flex; gap: 12px; align-items: center; padding: 8px 0; text-decoration: none; }
  .car-mini img, .thumb-empty { width: 64px; height: 48px; border-radius: var(--r-sm); object-fit: cover; background: var(--mist); flex: none; display: grid; place-items: center; color: var(--muted); }
  .car-mini span { display: grid; font-size: var(--step--1); min-width: 0; }
  .car-mini small { color: var(--muted); }

  .tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-bottom: 16px; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs a { flex: none; padding: 8px 14px; border-radius: var(--pill); text-decoration: none; font-weight: 650; font-size: var(--step--1); color: var(--ink-2); background: var(--paper); border: 1px solid var(--line); }
  .tabs a span { color: var(--muted); margin-left: 4px; font-variant-numeric: tabular-nums; }
  .tabs a[aria-current] { background: var(--navy); color: #fff; border-color: var(--navy); }
  .tabs a[aria-current] span { color: #A9B6D4; }

  .car-rows { display: grid; gap: 10px; }
  .car-row { display: flex; align-items: center; gap: 8px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 10px 10px 10px 10px; }
  .car-row.is-flagged { border-color: #F1B8B3; }
  .cr-main { display: flex; gap: 14px; flex: 1; min-width: 0; text-decoration: none; color: var(--ink); }
  .cr-main:hover { color: var(--ink); }
  .cr-main img, .cr-main .thumb-empty { width: 112px; height: 84px; border-radius: var(--r); object-fit: cover; flex: none; }
  .cr-text { display: grid; gap: 2px; min-width: 0; font-size: var(--step--1); align-content: center; }
  .cr-text strong { font-size: var(--step-0); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .cr-price { font-weight: 800; color: var(--navy); font-variant-numeric: tabular-nums; }
  .cr-meta { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; color: var(--muted); font-size: 12px; }
  .flag-note { color: var(--bad); font-size: 12px; font-weight: 600; }
  .row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
  @media (max-width: 560px) { .cr-main img, .cr-main .thumb-empty { width: 88px; height: 66px; } .car-row .row-actions { width: 100%; } .car-row { flex-wrap: wrap; } }

  /* car form */
  .car-form { display: grid; gap: 0; padding-bottom: 80px; }
  .form-sec { display: grid; gap: 16px; }
  .form-sec h2 { margin-bottom: 0; }
  .loc-choice { display: grid; gap: 10px; }
  @media (min-width: 640px) { .loc-choice { grid-template-columns: 1fr 1fr; } }
  .choice { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1.5px solid var(--line-2); border-radius: var(--r); cursor: pointer; }
  .choice:has(input:checked) { border-color: var(--navy); background: #F5F7FC; }
  .choice input { accent-color: var(--navy); width: 20px; height: 20px; margin-top: 2px; flex: none; }
  .choice span { display: grid; }
  .choice small { color: var(--muted); }
  .feature-pick { display: flex; flex-wrap: wrap; gap: 8px; }
  .feature-pick .tick { padding: 8px 12px; border: 1px solid var(--line-2); border-radius: var(--pill); font-size: var(--step--1); }
  .feature-pick .tick:has(input:checked) { border-color: var(--navy); background: #F0F3FA; }
  .feature-pick .tick input { width: 16px; height: 16px; }
  .photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
  @media (min-width: 640px) { .photo-grid { grid-template-columns: repeat(5, 1fr); } }
  .ph { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-sm); overflow: hidden; background: var(--mist); cursor: grab; touch-action: pan-y; }
  .ph:first-child::after { content: "Cover"; position: absolute; left: 6px; bottom: 6px; font-size: 11px; font-weight: 700; color: #fff; background: var(--navy); padding: 2px 8px; border-radius: 6px; }
  .ph img { width: 100%; height: 100%; object-fit: cover; }
  .ph.dragging { opacity: .4; }
  .ph.uploading img { opacity: .5; }
  .ph.uploading::before { content: ""; position: absolute; inset: auto 0 0; height: 3px; background: var(--red); animation: prog 4s ease-out forwards; transform-origin: left; z-index: 1; }
  .ph-del { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; border-radius: 50%; background: rgba(3, 23, 62, .8); color: #fff; display: grid; place-items: center; }
  .ph-add { aspect-ratio: 4 / 3; border: 2px dashed var(--line-2); border-radius: var(--r-sm); display: grid; place-content: center; justify-items: center; gap: 4px; cursor: pointer; color: var(--navy); font-weight: 650; font-size: var(--step--1); position: relative; }
  .ph-add:hover { border-color: var(--navy); background: #F5F7FC; }
  .ph-add input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
  .upload-status { font-size: var(--step--1); color: var(--muted); min-height: 1.4em; }
  .form-bar { position: sticky; bottom: calc(var(--tab-h) + var(--safe-b)); z-index: 20; display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; padding: 12px; margin-top: 8px; background: rgba(255, 255, 255, .96); backdrop-filter: blur(12px); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 -6px 24px -10px rgba(3, 23, 62, .2); }
  @media (min-width: 960px) { .form-bar { bottom: 16px; } }
  @media (max-width: 560px) { .form-bar .btn { flex: 1; } }

  .lead-list { display: grid; gap: 10px; margin-bottom: 14px; }
  .lead { display: flex; align-items: center; gap: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px; }
  .lead img, .lead .thumb-empty { width: 72px; height: 54px; border-radius: var(--r-sm); object-fit: cover; flex: none; }
  .lead-text { display: grid; gap: 2px; flex: 1; min-width: 0; font-size: var(--step--1); }
  .lead-text strong { font-size: var(--step-0); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .lead-note { color: var(--ink-2); }
  .lead-form select { min-height: 38px; padding: 6px 32px 6px 12px; font-size: 14px; width: auto; background-position: right 10px center; }
  @media (max-width: 560px) { .lead { flex-wrap: wrap; } .lead-form { width: 100%; } .lead-form select { width: 100%; } }

  .more-nav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: -4px 0 18px; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; }
  .more-nav::-webkit-scrollbar, .tabs::-webkit-scrollbar { display: none; }
  .more-nav a, .more-nav button { flex: none; padding: 8px 14px; border-radius: var(--pill); background: var(--paper); border: 1px solid var(--line); text-decoration: none; font-weight: 650; font-size: var(--step--1); }
  .more-nav a[aria-current] { background: var(--navy); color: #fff; border-color: var(--navy); }
  .more-nav form { display: contents; }
  .more-nav button { color: var(--bad); text-decoration: none; }
  .stand-list, .staff-list { display: grid; gap: 0; }
  .stand-row, .staff-row { display: flex; justify-content: space-between; align-items: start; gap: 12px; flex-wrap: wrap; }
  .stand-row p { color: var(--ink-2); font-size: var(--step--1); margin: 4px 0; }
  .logo-row { display: flex; align-items: center; gap: 16px; }
  .logo-row img { border-radius: var(--r); object-fit: cover; }
  .ok-line { display: flex; gap: 8px; align-items: center; color: var(--good); font-weight: 650; }
  .plan-now { display: grid; gap: 18px; }
  @media (min-width: 760px) { .plan-now { grid-template-columns: 1.2fr 1fr 1fr; align-items: center; } }
  .plan-now > div:first-child { display: grid; }
  .plan-now strong { font-size: var(--step-3); font-stretch: 114%; color: var(--navy); }
  .usage { display: grid; gap: 6px; font-size: var(--step--1); }
  .bar { height: 8px; border-radius: 4px; background: var(--mist); overflow: hidden; }
  .bar i { display: block; height: 100%; background: var(--navy); border-radius: 4px; }
  .bank { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; margin-bottom: 14px; }
  @media (min-width: 640px) { .bank { grid-template-columns: repeat(4, 1fr); } }
  .bank div { background: var(--paper); padding: 10px 14px; }
  .bank dt { font-size: 12px; color: var(--muted); }
  .bank dd { margin: 0; font-weight: 700; }

  /* admin */
  .todo-strip { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
  .todo-strip a { padding: 10px 14px; border-radius: var(--r); background: var(--warn-bg); color: #6E4100; text-decoration: none; font-size: var(--step--1); }
  .mcharts { display: grid; gap: 12px; margin-bottom: 16px; }
  @media (min-width: 760px) { .mcharts { grid-template-columns: 1fr 1fr; } }
  @media (min-width: 1200px) { .mcharts { grid-template-columns: repeat(4, 1fr); } }
  .mchart { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px; display: grid; gap: 10px; }
  .mchart figcaption { display: grid; }
  .mchart figcaption span { font-size: 12px; font-weight: 650; color: var(--muted); }
  .mchart figcaption strong { font-size: var(--step-2); font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
  .mchart figcaption small { color: var(--muted); }
  .mchart svg { width: 100%; height: auto; overflow: visible; }
  .mchart .axis { stroke: var(--line-2); stroke-width: 1; }
  .mchart .mbar path { fill: #8C9BBE; }
  .mchart .mbar.is-last path { fill: var(--navy); }
  .mchart .mbar .hit { fill: transparent; }
  .mchart .mbar:hover path { fill: var(--red-btn); }
  .mchart .tick { font-size: 10px; fill: var(--muted); font-family: var(--font); }
  .mtable summary { font-size: 12px; color: var(--muted); cursor: pointer; }
  .mtable .table td { padding: 4px 8px; }
  .cat-layout { display: grid; gap: 16px; }
  @media (min-width: 1000px) { .cat-layout { grid-template-columns: 260px 1fr; align-items: start; } }
  .cat-brands ul { max-height: 420px; overflow-y: auto; display: grid; margin-bottom: 18px; }
  .cat-brands a { display: flex; justify-content: space-between; padding: 7px 10px; border-radius: var(--r-sm); text-decoration: none; font-size: var(--step--1); font-weight: 600; }
  .cat-brands a[aria-current], .cat-brands a:hover { background: var(--mist); }
  .cat-brands a { justify-content: flex-start; align-items: center; gap: 8px; }
  .cat-brands a img { width: 20px; height: 20px; object-fit: contain; flex: none; }
  .cat-brands a .muted { margin-left: auto; }
  .cat-title { display: flex; align-items: center; gap: 10px; }
  .cat-title img { width: 40px; height: 40px; object-fit: contain; }
  .cat-update { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; justify-content: space-between; margin-bottom: 16px; }
  .cat-update h2 { margin: 0 0 4px; }
  .cat-update p { margin: 0; max-width: 70ch; }
  .d-block { display: block; }
  .cat-brands ul { list-style: none; padding: 0; }
  .cat-layout > * { min-width: 0; }
  .cat-layout .table input[name=name] { min-width: 170px; }
  .cat-layout .table select { min-width: 120px; }
  .setup-steps { padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); font-size: var(--step--1); margin-bottom: 16px; }
  .ig-queue { display: grid; gap: 14px; }
  .ig-item { display: flex; gap: 14px; align-items: flex-start; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
  .ig-item img { width: 120px; border-radius: var(--r-sm); object-fit: cover; flex: none; }
  .ig-form { flex: 1; min-width: 0; gap: 8px; }
  .ig-form textarea { font-size: 14px; }
  .ig-posted { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .ig-posted a { display: grid; gap: 4px; text-decoration: none; font-size: 12px; }
  .ig-posted img { border-radius: var(--r-sm); aspect-ratio: 4 / 5; object-fit: cover; }
  .ig-head .inline-search { margin-top: 6px; }


  /* ===== Verification ===== */
  .doc-pick { display: grid; gap: 12px; }
  @media (min-width: 640px) { .doc-pick { grid-template-columns: 1fr 1fr; } }
  .doc-drop { position: relative; display: grid; justify-items: start; gap: 4px; padding: 18px; border: 2px dashed var(--line-2); border-radius: var(--r-lg); cursor: pointer; background: var(--paper); overflow: hidden; }
  .doc-drop:hover { border-color: var(--navy); }
  .doc-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
  .doc-drop svg { color: var(--navy); margin-bottom: 4px; }
  .doc-drop .doc-state { font-size: var(--step--1); color: var(--muted); }
  .doc-drop.is-reading { border-style: solid; border-color: var(--navy); }
  .doc-drop.is-ok { border-style: solid; border-color: var(--good); background: var(--good-bg); }
  .doc-drop.is-ok .doc-state { color: var(--good); font-weight: 600; }
  .doc-drop.is-warn { border-style: solid; border-color: #E0B15B; background: var(--warn-bg); }
  .doc-drop.is-warn .doc-state { color: #6E4100; }
  .doc-bar { display: block; width: 100%; height: 4px; border-radius: 2px; background: transparent; margin-top: 8px; overflow: hidden; }
  .doc-drop.is-reading .doc-bar { background: var(--mist); }
  .doc-bar i { display: block; height: 100%; width: 0; background: var(--navy); transition: width .2s; }
  .photo-tips { padding-left: 18px; color: var(--muted); font-size: var(--step--1); display: grid; gap: 2px; }
  .check-list { list-style: none; padding: 0; display: grid; gap: 8px; }
  .check-list li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-sm); background: var(--mist); }
  .check-list li span:last-child { display: grid; }
  .check-list small { color: var(--muted); }
  .check-list .ck { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; flex: none; color: #fff; background: var(--muted); }
  .check-list .ok .ck { background: var(--good); }
  .check-list .bad .ck { background: var(--bad); }
  .check-list .bad { background: var(--bad-bg); }
  .doc-compare { display: grid; gap: 16px; }
  @media (min-width: 1000px) { .doc-compare { grid-template-columns: 1fr 1fr; } .doc-compare .panel { margin-bottom: 0; } }
  .doc-img { width: 100%; max-height: 520px; object-fit: contain; background: var(--mist); border-radius: var(--r-sm); border: 1px solid var(--line); }
  .ocr-text { white-space: pre-wrap; font-size: 12px; max-height: 260px; overflow: auto; background: var(--mist); padding: 10px; border-radius: var(--r-sm); margin-top: 8px; }
  .doc-compare details { margin-top: 10px; }
  .doc-compare summary { cursor: pointer; font-size: var(--step--1); font-weight: 600; color: var(--navy); }
  .decide { margin-top: 16px; }
  .score-ring { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; flex: none; border: 4px solid; }
  .score-ring.s-ok { border-color: var(--good); color: var(--good); }
  .score-ring.s-mid { border-color: #E0B15B; color: var(--warn); }
  .score-ring.s-low { border-color: var(--bad); color: var(--bad); }

  /* ===== Help, support, tickets ===== */
  .help-hero { background: var(--navy); color: #fff; padding: clamp(32px, 6vw, 64px) 0 clamp(24px, 4vw, 40px); }
  .help-hero p { color: #C3CDE3; margin-top: 10px; font-size: var(--step-1); max-width: 60ch; }
  .help-jump { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
  .help-jump a { padding: 8px 14px; border-radius: var(--pill); background: rgba(255, 255, 255, .1); color: #fff; text-decoration: none; font-weight: 650; font-size: var(--step--1); }
  .help-jump a:hover { background: rgba(255, 255, 255, .2); color: #fff; }
  .help-start { display: grid; gap: 40px; }
  .guide h2 { margin-bottom: 4px; }
  .guide .btn { margin-top: 18px; }
  .faq-groups { display: grid; gap: 8px; }
  .faq-groups .faqs { margin-top: 18px; }
  .faq-groups .faqs h3 { font-size: var(--step-1); margin-bottom: 8px; }
  .support-band { display: grid; gap: 18px; align-items: center; padding: clamp(24px, 4vw, 36px); border-radius: var(--r-lg); background: var(--mist); margin-block: 24px 8px; }
  .support-band p { color: var(--ink-2); margin-top: 6px; }
  .sb-ctas { display: flex; flex-wrap: wrap; gap: 10px; }
  @media (min-width: 900px) { .support-band { grid-template-columns: 1fr auto; } }
  .support-grid { display: grid; gap: 20px; }
  @media (min-width: 1000px) { .support-grid { grid-template-columns: 340px 1fr; align-items: start; } }
  .support-side { display: grid; gap: 14px; }
  .support-side .btn-block + .btn-block { margin-top: 0; }
  .quick-links { list-style: none; padding: 0; display: grid; gap: 8px; font-size: var(--step--1); }
  .quick-links a { font-weight: 600; color: var(--navy); }
  .ticket-page { max-width: 820px; display: grid; gap: 14px; }
  .ticket-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
  .ticket-head h1 { font-size: var(--step-3); margin-top: 4px; }
  .thread { list-style: none; padding: 0; display: grid; gap: 12px; margin: 8px 0; }
  .msg { max-width: 86%; padding: 12px 16px; border-radius: 16px; background: var(--paper); border: 1px solid var(--line); }
  .msg-customer { justify-self: start; border-bottom-left-radius: 4px; }
  .msg-admin { justify-self: end; background: var(--navy); color: #fff; border-color: var(--navy); border-bottom-right-radius: 4px; }
  .msg-meta { display: flex; gap: 10px; font-size: 12px; margin-bottom: 4px; opacity: .8; }
  .msg-body { white-space: normal; overflow-wrap: anywhere; }
  .app-body .msg-customer { background: var(--paper); }
  .reply-box { margin-top: 6px; }
  .ticket-admin { display: grid; gap: 16px; }
  @media (min-width: 1100px) { .ticket-admin { grid-template-columns: 1fr 300px; align-items: start; } }
  .ticket-admin .side-block { background: var(--paper); }
  .ticket-admin h3 { font-size: var(--step--1); margin-top: 8px; }
  .nudge-wa > svg:first-child { color: #6FE3A2; }
  .nudge-wa .btn { flex: none; }
  .foot-support { display: grid; gap: 8px; margin-top: 18px; justify-items: start; }
  .foot-support span { font-size: 12px; font-weight: 700; color: #7DE3B6; }
  .foot-support a:not(.btn) { color: #fff; font-size: var(--step-2); font-weight: 800; font-stretch: 112%; font-variant-numeric: tabular-nums; }
  .wa-float { display: none; }
  @media (min-width: 960px) {
    .wa-float { position: fixed; z-index: 55; right: 22px; bottom: 22px; display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px 12px 14px; border-radius: var(--pill); background: var(--wa); color: #fff; text-decoration: none; font-weight: 700; font-size: var(--step--1); box-shadow: 0 10px 30px -8px rgba(18, 140, 74, .6); }
    .wa-float:hover { background: var(--wa-hover); color: #fff; }
    body:has(.install-sheet:not([hidden])) .wa-float { bottom: 120px; }
  }
  .terms-check { align-items: flex-start; padding: 14px; border: 1.5px solid var(--line-2); border-radius: var(--r); font-weight: 500; font-size: var(--step--1); line-height: 1.5; }
  .terms-check:has(input:checked) { border-color: var(--good); background: var(--good-bg); }
  .terms-check input { margin-top: 2px; }
  .unverified-note { margin-top: 10px; padding: 10px 14px; border-radius: var(--r); background: var(--warn-bg); color: #6E4100; font-size: var(--step--1); }
  .toc { display: flex; flex-wrap: wrap; gap: 6px 14px; padding: 14px 16px; border-radius: var(--r); background: var(--mist); font-size: var(--step--1); margin-bottom: 8px; }
  .toc a { font-weight: 600; color: var(--navy); }

  /* how it works (home) */
  .how-grid { display: grid; gap: 16px; }
  @media (min-width: 900px) { .how-grid { grid-template-columns: 1fr 1fr; } }
  .how-col { padding: 22px; border: 1px solid var(--line); border-radius: var(--r-lg); display: grid; gap: 14px; align-content: start; }
  .how-col .btn { justify-self: start; }
  .how-steps { counter-reset: h; list-style: none; padding: 0; display: grid; gap: 12px; }
  .how-steps li { counter-increment: h; position: relative; padding-left: 44px; min-height: 30px; color: var(--ink-2); }
  .how-steps li::before { content: counter(h); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--navy); color: #fff; font-weight: 800; font-size: 14px; }
  .how-steps strong { color: var(--ink); }
  .faq-peek { margin-top: 16px; padding: 16px 18px; border-radius: var(--r); background: var(--mist); }
  .faq-peek h3 { font-size: var(--step-0); margin-bottom: 8px; }
  .faq-peek ul { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
  .faq-peek a { font-weight: 600; color: var(--navy); }

  /* getting started checklist (dealer) */
  .getting-started .bar { margin-bottom: 14px; }
  .gs-list { list-style: none; padding: 0; display: grid; gap: 4px; margin-bottom: 10px; }
  .gs-list a { display: flex; gap: 12px; align-items: center; padding: 10px 8px; border-radius: var(--r-sm); text-decoration: none; font-weight: 600; font-size: var(--step--1); }
  .gs-list a:hover { background: var(--mist); }
  .gs-tick { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line-2); display: grid; place-items: center; flex: none; }
  .gs-list .done a { color: var(--muted); text-decoration: line-through; }
  .gs-list .done .gs-tick { background: var(--good); border-color: var(--good); color: #fff; }
}

/* ---------------- utilities ---------------- */
@layer utilities {
  .center { text-align: center; }
  @media (max-width: 959px) { .hide-sm { display: none !important; } }
  .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  @media (display-mode: standalone) {
    .install-sheet, [data-install] { display: none !important; }
  }
}

/* ---------------- dealer websites (cargrid.ng/dealer/{slug}) ---------------- */
@layer pages {
  .pg-site { --head-h: 68px; padding-bottom: calc(72px + var(--safe-b)); }
  @media (min-width: 900px) { .pg-site { padding-bottom: 0; } }
  .site-bar { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.92); backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); }
  .site-bar-row { height: var(--head-h); display: flex; align-items: center; gap: 16px; }
  .site-brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 800; font-stretch: 108%; font-size: var(--step-1); letter-spacing: -.01em; min-width: 0; }
  .site-brand span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .site-brand img, .site-mono { flex: none; width: 44px; height: 44px; border-radius: 12px; object-fit: cover; background: #fff; box-shadow: 0 0 0 1px var(--line); }
  .site-mono { display: grid; place-items: center; background: var(--site); color: var(--site-on); font-weight: 900; font-size: 20px; box-shadow: none; }
  .site-brand:hover { color: inherit; }
  .site-brand.on-dark { color: #fff; }
  .site-nav { display: none; gap: 4px; margin-left: auto; }
  .site-nav a { padding: 8px 14px; border-radius: var(--pill); text-decoration: none; font-weight: 650; color: var(--ink-2); }
  .site-nav a:hover { background: var(--mist); color: var(--ink); }
  .site-bar-wa { margin-left: auto; }
  @media (min-width: 900px) { .site-nav { display: flex; } .site-bar-wa { margin-left: 8px; } }
  @media (max-width: 420px) { .site-bar-wa span { display: none; } .site-bar-wa { padding-inline: 12px; } }

  .site-hero { position: relative; isolation: isolate; color: var(--site-on); background: radial-gradient(120% 140% at 85% 0%, color-mix(in srgb, var(--site) 70%, #fff 30%) 0%, var(--site) 45%, var(--site-dark) 100%); overflow: hidden; }
  .site-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: repeating-linear-gradient(-62deg, transparent 0 46px, rgba(255,255,255,.05) 46px 92px); }
  .site-hero.has-cover { color: #fff; background: var(--site-dark); }
  .site-hero.has-cover::after { background: linear-gradient(180deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.35) 45%, rgba(0,0,0,.78) 100%); }
  .site-cover { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
  .site-hero-in { display: grid; justify-items: start; gap: 12px; padding-block: clamp(56px, 10vw, 120px) clamp(40px, 6vw, 64px); }
  .site-hero-logo { width: 84px; height: 84px; border-radius: 22px; background: #fff; object-fit: cover; box-shadow: 0 12px 30px -10px rgba(0,0,0,.5); }
  .site-hero h1 { font-size: var(--step-5); max-width: 18ch; }
  .site-tagline { font-size: var(--step-2); font-weight: 600; max-width: 38ch; opacity: .92; line-height: 1.3; }
  .site-badges { display: flex; flex-wrap: wrap; gap: 8px; }
  .site-badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--pill); background: rgba(255,255,255,.16); backdrop-filter: blur(6px); font-size: var(--step--1); font-weight: 700; }
  .site-badge.good { background: #fff; color: var(--good); }
  .site-hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
  .btn-site-ghost { background: transparent; color: inherit; border: 2px solid currentColor; }
  .btn-site-ghost:hover { background: rgba(255,255,255,.12); color: inherit; }

  .site-stats { position: relative; z-index: 2; margin-top: -28px; display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); background: #fff; border-radius: var(--r-lg); box-shadow: var(--shadow-pop); overflow: hidden; }
  .site-stats div { display: grid; gap: 2px; padding: 16px clamp(12px, 2vw, 20px); border-right: 1px solid var(--line); }
  .site-stats div:last-child { border-right: 0; }
  .site-stats strong { font-size: var(--step-3); font-weight: 850; font-stretch: 112%; color: var(--site); line-height: 1; }
  .site-stats span { font-size: var(--step--1); color: var(--muted); font-weight: 600; }

  .site-sec { padding-block: clamp(36px, 5vw, 56px) 0; }
  .site-sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
  .site-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 calc(-1 * var(--gap)) 18px; padding-inline: var(--gap); }
  .site-chips::-webkit-scrollbar { display: none; }
  .site-chips a { flex: none; padding: 8px 16px; border-radius: var(--pill); border: 1px solid var(--line-2); text-decoration: none; font-weight: 650; font-size: var(--step--1); background: #fff; }
  .site-chips a small { color: var(--muted); margin-left: 2px; }
  .site-chips a[aria-current] { background: var(--site); border-color: var(--site); color: var(--site-on); }
  .site-chips a[aria-current] small { color: inherit; opacity: .75; }

  .site-band { margin-top: clamp(40px, 6vw, 64px); background: var(--mist); padding-block: clamp(40px, 6vw, 72px); }
  .site-about { display: grid; gap: 20px; }
  @media (min-width: 860px) { .site-about { grid-template-columns: 1fr 1.3fr; gap: 48px; } }
  .site-eyebrow { color: var(--site); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: var(--step--1); margin-bottom: 8px; }
  .site-about-text { font-size: var(--step-1); color: var(--ink-2); display: grid; gap: 16px; }
  .site-socials { display: flex; flex-wrap: wrap; gap: 8px; font-size: var(--step--1); }
  .site-socials a { padding: 6px 12px; border-radius: var(--pill); background: #fff; border: 1px solid var(--line); text-decoration: none; font-weight: 650; }

  .site-visit { display: grid; gap: 16px; }
  @media (min-width: 860px) { .site-visit { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); } }
  .site-stand { display: grid; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; }
  .site-stand iframe { width: 100%; height: 220px; border: 0; background: var(--mist); }
  @media (min-width: 860px) { .site-stand:only-child { grid-template-columns: 1.5fr 1fr; } .site-stand:only-child iframe { height: 100%; min-height: 280px; } .site-stand:only-child > div { align-content: center; padding: 28px; } }
  .site-stand > div { display: grid; gap: 6px; justify-items: start; padding: 16px 18px 18px; }
  .site-stand p { color: var(--ink-2); font-size: var(--step--1); }

  .site-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; padding: clamp(24px, 4vw, 40px); border-radius: var(--r-lg); background: var(--site); color: var(--site-on); }
  .site-cta p { opacity: .85; margin-top: 6px; }

  .site-end { margin-top: clamp(40px, 6vw, 64px); background: #0B1220; color: #fff; padding-top: 44px; }
  .site-end-grid { display: grid; gap: 28px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
  .site-end h2 { font-size: var(--step-0); text-transform: uppercase; letter-spacing: .08em; color: #8C97B2; margin-bottom: 10px; }
  .site-end-brand p { margin-top: 12px; color: #C3CDE3; }
  .site-end-list { display: grid; gap: 8px; }
  .site-end a:not(.btn) { color: #fff; text-decoration: none; }
  .site-end a:not(.btn):hover { text-decoration: underline; }
  .muted-on-dark { color: #9FAAC3; }
  .site-link { font-weight: 700; word-break: break-all; margin-bottom: 10px; }
  .site-share { display: flex; gap: 8px; flex-wrap: wrap; }
  .site-credit { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 36px; padding-block: 18px 26px; border-top: 1px solid rgba(255,255,255,.1); font-size: var(--step--1); color: #8C97B2; }
  .site-credit a { color: #C3CDE3 !important; }

  .site-dock { position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; padding: 10px 12px calc(10px + var(--safe-b)); background: rgba(255,255,255,.95); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
  .site-dock a { display: flex; align-items: center; justify-content: center; gap: 8px; height: 50px; border-radius: var(--pill); border: 1px solid var(--line-2); text-decoration: none; font-weight: 750; }
  .site-dock a.dock-wa { background: var(--wa); border-color: var(--wa); color: #fff; grid-column: span 1; }
  @media (min-width: 900px) { .site-dock { display: none; } }
}

/* dashboard: "Your website" card and website settings */
@layer pages {
  .site-link-card { display: grid; grid-template-columns: auto 1fr; gap: 14px 16px; align-items: start; border: 1px solid var(--line); background: linear-gradient(135deg, #fff 0%, #F4F7FD 100%); }
  .slc-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--navy); color: #fff; }
  .slc-text { display: grid; gap: 4px; min-width: 0; }
  .slc-text h2 { font-size: var(--step-1); }
  .slc-url { font-weight: 800; font-size: var(--step-1); color: var(--navy); word-break: break-all; }
  .slc-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
  @media (min-width: 900px) { .site-link-card { grid-template-columns: auto 1fr auto; align-items: center; } .slc-actions { grid-column: auto; } }
  .form-sub { font-size: var(--step-2); margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
  .swatches { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
  .swatch { position: relative; cursor: pointer; }
  .swatch input[type=radio] { position: absolute; opacity: 0; inset: 0; }
  .swatch i { display: block; width: 36px; height: 36px; border-radius: 50%; box-shadow: 0 0 0 1px rgba(0,0,0,.12); }
  .swatch:has(input:checked) i, .swatch-custom:has(input[type=radio]:checked) input[type=color] { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--ink); }
  .swatch:has(input:focus-visible) i { outline: 2px solid var(--red); outline-offset: 4px; }
  .swatch-custom input[type=color] { -webkit-appearance: none; appearance: none; flex: none; inline-size: 36px; block-size: 36px; min-height: 0; max-width: 36px; padding: 0; border: 0; border-radius: 50%; overflow: hidden; cursor: pointer; background: conic-gradient(red, yellow, lime, cyan, blue, magenta, red); }
  .swatch-custom input[type=color]::-webkit-color-swatch-wrapper { padding: 0; }
  .swatch-custom input[type=color]::-webkit-color-swatch { border: 0; border-radius: 50%; }
  .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .cover-row { display: grid; gap: 10px; }
  .cover-row img { width: 100%; max-width: 480px; aspect-ratio: 5 / 2; object-fit: cover; border-radius: var(--r); }
}

/* sign up: choose dealer or private seller */
@layer pages {
  .seller-pick { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
  @media (max-width: 420px) { .seller-pick { grid-template-columns: 1fr; } }
  .seller-opt { position: relative; display: grid; gap: 4px; align-content: start; padding: 16px; border: 1.5px solid var(--line-2); border-radius: var(--r-lg); cursor: pointer; background: #fff; }
  .seller-opt input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
  .seller-opt .so-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--mist); color: var(--navy); margin-bottom: 4px; }
  .seller-opt small { color: var(--muted); line-height: 1.4; }
  .seller-opt:has(input:checked) { border-color: var(--navy); box-shadow: 0 0 0 2px var(--navy) inset; }
  .seller-opt:has(input:checked) .so-icon { background: var(--navy); color: #fff; }
  .seller-opt:has(input:focus-visible) { outline: 2px solid var(--red); outline-offset: 2px; }
  .register-form .only-individual { display: none; }
  .register-form:has(input[value=individual]:checked) .only-individual { display: revert; }
  .register-form:has(input[value=individual]:checked) .only-dealer { display: none; }
  .seller-tag { display: inline-flex; align-items: center; gap: 4px; font-size: var(--step--1); color: var(--muted); font-weight: 600; }
}

@layer pages {
  .btn-danger { background: var(--bad); color: #fff; border-color: var(--bad); }
  .btn-danger:hover { background: #8F1C13; color: #fff; }
}

@layer pages {
  .danger-zone { border: 1px solid #F3C4BF; }
  .danger-zone h2 { color: var(--bad); }
  .slug-input { display: flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); border-radius: var(--r); padding-left: 12px; background: #fff; }
  .slug-input input { border: 0 !important; box-shadow: none !important; flex: 1; min-width: 0; padding-left: 0; }
  .slug-input:focus-within { box-shadow: var(--ring); border-color: var(--red); }
}

@layer pages {
  .smtp-box { border: 1px solid var(--line); border-radius: var(--r); padding: 12px 16px; display: grid; gap: 12px; }
  .smtp-box summary { cursor: pointer; font-weight: 700; }
}

/* ---------------- analytics (admin and dealer) ---------------- */
@layer pages {
  .an-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 16px; }
  @media (min-width: 1000px) { .an-cards { grid-template-columns: repeat(4, 1fr); } }
  .an-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 18px; display: grid; gap: 2px; align-content: start; }
  .an-card:first-child { border-color: var(--navy); box-shadow: 0 0 0 1px var(--navy) inset; }
  .an-cl { font-size: 12px; font-weight: 750; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
  .an-card > strong { font-size: var(--step-4); font-weight: 850; font-stretch: 112%; color: var(--navy); line-height: 1.05; font-variant-numeric: tabular-nums; }
  .an-sub { font-size: 13px; color: var(--muted); font-weight: 600; }
  .an-sub em { font-style: normal; font-weight: 800; margin-left: 4px; }
  .an-sub em.up { color: var(--good); }
  .an-sub em.down { color: var(--bad); }
  .an-card dl { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
  .an-card dt { font-size: 11.5px; color: var(--muted); font-weight: 600; }
  .an-card dd { margin: 0; font-weight: 800; font-variant-numeric: tabular-nums; }
  .an-bars { width: 100%; height: auto; display: block; }
  .an-bars .an-bar { fill: var(--navy); opacity: .85; }
  .an-bars .an-bar.now { fill: var(--red-btn); opacity: 1; }
  .an-bars g:hover .an-bar { opacity: 1; }
  .an-bars .axis { stroke: var(--line-2); }
  .an-bars text { font-size: 11px; fill: var(--muted); font-family: var(--font); }
  .an-period { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 24px 0 8px; }
  .an-period h2 { margin: 0; }
  .an-period .tabs { margin: 0; }
  .an-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; counter-reset: an; }
  .an-list li { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: 10px; overflow: hidden; isolation: isolate; font-size: 14px; }
  .an-list li i { position: absolute; inset: 0 auto 0 0; z-index: -1; background: #E9EEF8; border-radius: 10px; }
  .an-list li:first-child i { background: #DCE4F5; }
  .an-l { min-width: 0; font-weight: 650; }
  .an-l a { color: var(--ink); text-decoration: none; }
  .an-l a:hover { text-decoration: underline; }
  .an-l small { display: block; font-weight: 500; color: var(--muted); font-size: 12px; }
  .an-v { font-weight: 800; font-variant-numeric: tabular-nums; flex: none; }
  .an-h3 { font-size: var(--step-0); margin: 18px 0 8px; }
  .an-split { height: 14px; border-radius: 999px; background: #C9D3E8; overflow: hidden; }
  .an-split i { display: block; height: 100%; background: var(--navy); }
  .an-split-l { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-top: 6px; }
  .an-split-l strong { color: var(--ink); }
  .verified-dot { color: var(--good); font-weight: 900; }
  .ds-cars td small { display: block; color: var(--muted); }
  .ds-thumb { width: 64px; height: 48px; border-radius: 8px; object-fit: cover; background: var(--mist); }
}

@layer pages {
  .visits-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; padding: 14px 18px; margin-bottom: 16px; border-radius: var(--r-lg); background: var(--navy); color: #C7D1E8; text-decoration: none; font-size: 14px; }
  .visits-strip strong { color: #fff; font-size: var(--step-2); font-weight: 850; margin-right: 4px; font-variant-numeric: tabular-nums; }
  .visits-strip .vs-link { margin-left: auto; color: #fff; font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
  .visits-strip:hover { color: #fff; }
}

@layer pages {
  .plan-grid { display: grid; grid-template-columns: 1.1fr 1.2fr .8fr .7fr; gap: 8px 10px; align-items: center; }
  .plan-grid .pg-h { font-size: 12px; font-weight: 700; color: var(--muted); }
  .plan-grid input { width: 100%; min-width: 0; }
}

@layer pages {
  .plans-free { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
  .paid-plans { display: grid; gap: 12px; }
}
@layer pages {
  .ds-cards { grid-template-columns: 1fr; }
  @media (min-width: 760px) { .ds-cards { grid-template-columns: repeat(3, 1fr); } }
  @media (max-width: 600px) { .an-bars text { font-size: 24px; } }
  .ds-cars { min-width: 600px; }
  .ds-cars td:first-child { min-width: 260px; }
}

@layer pages {
  .app-version { display: block; margin-top: 10px; font-size: 12px; color: #8C97B2; font-weight: 600; }
}

@layer pages {
  .kv { display: grid; gap: 0; margin: 0 0 10px; }
  .kv > div { display: grid; grid-template-columns: minmax(120px, 180px) 1fr; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); }
  .kv dt { color: var(--muted); font-size: var(--step--1); }
  .kv dd { margin: 0; font-weight: 650; }
}
