/* Lake Motor Group — modernized rebuild */
:root {
  --bg: #ffffff;            /* card / surface */
  --bg-alt: #f7f8fa;        /* soft page background, sections */
  --fg: #101828;
  --fg-muted: #5b6470;
  --line: #eaecf0;
  --accent: #d32431;        /* brand red — CTAs, active, badges */
  --accent-fg: #ffffff;
  --accent-hover: #b11c28;
  /* Money/positive green — price & financing badges only */
  --good: #067647;
  --good-bg: #ecfdf3;
  --good-line: #abefc6;
  --shadow: 0 1px 3px rgba(16, 24, 40, .08);
  --shadow-2: 0 8px 24px rgba(16, 24, 40, .12);
  --radius: 12px;
  --radius-sm: 8px;
  --maxw: 1180px;
  /* Dark "chrome" — header / topbar / dark bands / footer */
  --ink: #101725;
  --ink-bar: #0b1019;
  --ink-fg: #ffffff;
  --ink-muted: #9aa7bd;
  --ink-line: rgba(255, 255, 255, .10);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
/* The HTML hidden attribute should always win over any display:* class
   rule. Browsers default to [hidden] { display: none } but a class selector
   can override that — !important here guarantees correctness everywhere. */
[hidden] { display: none !important; }
body {
  font: 16px/1.55 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--fg);
  background: var(--bg-alt);
  -webkit-font-smoothing: antialiased;
}
.price, .tabular { font-variant-numeric: tabular-nums; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.muted { color: var(--fg-muted); }
.small { font-size: .9em; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.center { text-align: center; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* Header */
.site-header {
  background: var(--ink);
  border-bottom: 1px solid var(--ink-line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px 24px;
}
.brand { display: flex; align-items: center; color: var(--fg); text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand img { max-height: 48px; width: auto; }
.nav {
  display: flex; gap: 4px;
  margin-left: auto;
}
.nav a {
  color: var(--ink-fg);
  padding: 8px 12px;
  border-radius: 8px;
  font-weight: 500;
}
.nav a:hover { background: rgba(255, 255, 255, .08); text-decoration: none; }
.nav a.active { color: #fff; box-shadow: inset 0 -2px 0 var(--accent); }
.cta {
  background: var(--accent);
  color: var(--accent-fg);
  padding: 9px 14px;
  border-radius: 999px;
  font-weight: 600;
}
.cta:hover { background: var(--accent-hover); text-decoration: none; }

@media (max-width: 800px) {
  .header-inner { flex-wrap: wrap; gap: 12px; padding: 12px 16px; }
  .nav { order: 3; width: 100%; justify-content: center; overflow-x: auto; }
  .cta { margin-left: auto; }
  .container { padding: 0 16px; }
}

/* Hero */
.hero {
  background: linear-gradient(180deg, #111e35 0%, #1D3461 100%);
  color: #fff;
  padding: 72px 0 88px;
}
.hero .eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .8rem;
  color: #a4b6e3;
  margin: 0 0 10px;
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.1;
  margin: 0 0 16px;
  letter-spacing: -.02em;
}
.hero .lede { font-size: 1.15rem; color: #cdd6ee; max-width: 56ch; margin: 0 0 28px; }
.hero-copy { max-width: 760px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: transparent; color: inherit; border-color: rgba(255,255,255,.4); }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; display: inline-block; vertical-align: -3px; margin-right: 6px; }
.hero .btn-ghost { color: #fff; }
.section .btn-ghost { color: var(--fg); border-color: var(--line); }
.btn-ghost:hover { background: rgba(255,255,255,.08); }
.section .btn-ghost:hover { background: var(--bg-alt); }

/* Sections */
.section { padding: 56px 0; }
.section.narrow { max-width: 760px; }
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; margin-bottom: 24px;
}
.section h2, .section h1 { margin: 0; }
.link { font-weight: 600; }

.band { background: var(--bg-alt); padding: 56px 0; margin-top: 24px; }
.band-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.band h2 { margin: 0 0 12px; }
.features { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.features li { padding-left: 22px; position: relative; }
.features li::before {
  content: "✓"; color: var(--accent);
  position: absolute; left: 0; font-weight: 700;
}
@media (max-width: 800px) { .band-grid { grid-template-columns: 1fr; gap: 24px; } }

/* Grid + cards */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.card {
  display: block;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  color: var(--fg);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: #d6dae1;
  text-decoration: none;
}
.card-img {
  aspect-ratio: 4/3;
  background: var(--bg-alt);
  overflow: hidden;
}
.card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-placeholder {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  color: var(--fg-muted);
  background: repeating-linear-gradient(45deg, #f0f1f5 0 12px, #f6f7f9 12px 24px);
}
.card-placeholder.big { aspect-ratio: 16/10; font-size: 1.1rem; }
.card-body { padding: 16px; }
.card-title { font-weight: 600; }
.card-meta {
  display: flex; justify-content: space-between;
  margin-top: 8px; color: var(--fg-muted); font-size: .95rem;
}
.card-price { color: var(--fg); font-weight: 700; }

/* Richer vehicle card (Sergey spec: big price, green deal pill, est payment, location) */
.card-media { position: relative; }
.card-count {
  position: absolute; bottom: 8px; right: 8px;
  background: rgba(16, 24, 40, .75); color: #fff;
  font-size: .72rem; font-weight: 500; padding: 2px 8px; border-radius: 6px;
}
.card-specs { color: var(--fg-muted); font-size: .85rem; margin-top: 6px; }
.card-pricerow { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.card-pricerow .card-price { font-size: 1.5rem; }
.badge-deal {
  background: var(--good-bg); color: var(--good); border: 1px solid var(--good-line);
  font-size: .72rem; font-weight: 600; padding: 3px 8px; border-radius: 6px; white-space: nowrap;
}
.card-est { color: var(--fg-muted); font-size: .82rem; margin-top: 3px; }
.card-loc { color: var(--fg-muted); font-size: .82rem; margin-top: 6px; }

/* Empty / zero-inventory state — branded recovery, never a blank grid */
.empty-state {
  text-align: center; max-width: 40rem; margin: 8px auto 0;
  padding: 40px 24px; background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius);
}
.empty-state h2 { margin: 0 0 8px; }
.empty-state p { color: var(--fg-muted); margin: 0 0 20px; }
.empty-state .other-lots { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 8px; }
.empty-state .lot-chip {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px;
  color: var(--fg); font-size: .9rem; background: var(--bg-alt);
}
.empty-state .lot-chip:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.empty-state .lot-chip b { color: var(--accent); }

/* Filters */
.filters { margin-bottom: 20px; }
.filters input[type=search] {
  width: 100%;
  max-width: 420px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 1rem;
}
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}
.filter-row select {
  padding: 8px 30px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.95rem;
  background-color: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'><path d='M1 1l4 4 4-4' stroke='%23666' stroke-width='1.5' fill='none'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  appearance: none;
  cursor: pointer;
}
.filter-row select:focus { outline: 2px solid var(--accent, #0a66c2); outline-offset: 1px; }
.filter-row .reset {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.9rem;
  text-decoration: underline;
  cursor: pointer;
  padding: 6px 8px;
}
.filter-row .reset:hover { color: var(--fg); }
.filter-count {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.9rem;
}
.filter-count strong { color: var(--fg); }

/* Car detail */
.breadcrumb { margin: 0 0 16px; }
.car-detail {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 36px;
  margin-top: 8px;
}
@media (max-width: 700px) { .car-detail { grid-template-columns: 1fr; } }
/* Grid columns default to min-width:auto, so a 40+ thumb filmstrip (which has
   its own overflow-x) would otherwise expand the left column to its full
   intrinsic width and blow the two-column layout off-screen. min-width:0 lets
   the column shrink so the filmstrip scrolls inside it instead. */
.car-gallery { min-width: 0; }
.gallery-thumbs { scrollbar-width: thin; scrollbar-color: var(--accent) transparent; }
.gallery-thumbs::-webkit-scrollbar { height: 4px; }
.gallery-thumbs::-webkit-scrollbar-track { background: transparent; }
.gallery-thumbs::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 2px; }
.gallery-main { position: relative; background: var(--bg-alt); border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/3; min-height: 320px; max-height: 480px; }
.gallery-stage { position: absolute; inset: 0; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-main.has-photo img { cursor: zoom-in; }

/* Inline gallery prev/next — large, always-visible nav so customers can step
   through photos right on the main image, without hunting tiny thumbnails or
   opening the lightbox. Sized to a comfortable touch target (~52px desktop,
   46px mobile) with a high-contrast backdrop that reads over any photo. */
.g-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 52px; height: 52px; padding: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(20,22,25,.62); color: #fff;
  border: 1px solid rgba(255,255,255,.30); border-radius: 50%;
  cursor: pointer; opacity: .92;
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
  transition: background .15s, opacity .15s, transform .12s;
}
.g-nav:hover { background: rgba(20,22,25,.86); opacity: 1; }
.g-nav:active { transform: translateY(-50%) scale(.92); }
.g-nav:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; opacity: 1; }
.g-nav svg { width: 26px; height: 26px; }
.g-prev { left: 12px; }
.g-next { right: 12px; }
@media (max-width: 640px) {
  .g-nav { width: 46px; height: 46px; }
  .g-nav svg { width: 23px; height: 23px; }
  .g-prev { left: 8px; } .g-next { right: 8px; }
}

/* Hover overlay (desktop): darken the photo + show a centered magnifier so
   it's obvious the image is clickable to zoom. Only when a photo is shown
   (.has-photo), never over the video iframe. */
.gallery-main.has-photo::after {
  content: ""; position: absolute; inset: 0;
  background: rgba(0,0,0,0); transition: background .15s;
  pointer-events: none;
}
.gallery-main.has-photo:hover::after { background: rgba(0,0,0,.18); }
.gallery-magnify {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%) scale(.9);
  width: 56px; height: 56px; padding: 13px;
  background: rgba(0,0,0,.5); color: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .15s, transform .15s; pointer-events: none;
}
.gallery-main.has-photo:hover .gallery-magnify { opacity: 1; transform: translate(-50%,-50%) scale(1); }
.gallery-magnify svg { width: 100%; height: 100%; }

/* Expand-to-fullscreen button — always visible when a photo is shown.
   On touch devices (no hover) this is the persistent zoom affordance. */
.gallery-expand {
  position: absolute; bottom: 10px; right: 10px; z-index: 1;
  width: 40px; height: 40px; padding: 9px;
  background: rgba(0,0,0,.6); color: #fff; border: none; border-radius: 8px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.gallery-main:not(.has-photo) .gallery-expand { display: none; }
.gallery-expand:hover { background: rgba(0,0,0,.85); }
.gallery-expand svg { width: 100%; height: 100%; }

/* ── Fullscreen photo viewer ────────────────────────────────────────────────
   Full-res photo on a black stage with smooth cursor-anchored zoom, clamped
   pan (the image can never drift off to one side), and frosted-glass controls.
   Self-contained, no library. JS moves the overlay to <body> on init so
   position:fixed always resolves against the viewport. */
.lightbox {
  position: fixed; inset: 0;
  width: 100vw; height: 100vh; z-index: 9999;
  background: radial-gradient(125% 125% at 50% 38%, #16181b 0%, #000 72%);
  display: flex; flex-direction: column;
  opacity: 0; visibility: hidden;
  transition: opacity .28s ease, visibility .28s ease;
}
.lightbox.open { opacity: 1; visibility: visible; }

.lb-stage {
  flex: 1 1 auto; min-height: 0; width: 100%;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; touch-action: none;
  cursor: zoom-in;
}
.lightbox.is-zoomed .lb-stage { cursor: grab; }
.lightbox.is-panning .lb-stage { cursor: grabbing; }

.lb-img {
  max-width: 100%; max-height: 100%; object-fit: contain;
  user-select: none; -webkit-user-drag: none;
  transform: translate(0,0) scale(1); transform-origin: center center;
  transition: transform .22s cubic-bezier(.22,.61,.36,1);
  will-change: transform;
}
.lightbox.is-panning .lb-img { transition: none; }   /* 1:1 follow while dragging */
.lightbox.open .lb-img { animation: lb-fade-in .32s ease; }
@keyframes lb-fade-in { from { opacity: 0; } to { opacity: 1; } }

/* Subtle top hint */
.lb-hint {
  position: absolute; top: 0; left: 0; right: 0; z-index: 3;
  text-align: center; padding: 16px;
  color: rgba(255,255,255,.6); font-size: .8rem; letter-spacing: .04em;
  pointer-events: none; text-shadow: 0 1px 3px rgba(0,0,0,.6);
}

/* Frosted control buttons */
.lb-btn {
  position: absolute; z-index: 4;
  display: flex; align-items: center; justify-content: center;
  background: rgba(22,24,27,.55); color: #fff;
  border: 1px solid rgba(255,255,255,.16); border-radius: 999px;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  cursor: pointer; box-shadow: 0 4px 18px rgba(0,0,0,.35);
  transition: background .18s, transform .18s, border-color .18s, opacity .18s;
}
.lb-btn:hover { background: rgba(46,49,54,.82); border-color: rgba(255,255,255,.34); transform: scale(1.06); }
.lb-btn:active { transform: scale(.94); }
.lb-btn svg { width: 58%; height: 58%; }
.lb-close { top: 18px; right: 18px; width: 52px; height: 52px; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 76px; height: 76px; background: rgba(22,24,27,.7); }
.lb-nav:hover { transform: translateY(-50%) scale(1.06); }
.lb-nav svg { width: 64%; height: 64%; }
.lb-prev { left: 24px; }
.lb-next { right: 24px; }

.lb-counter {
  position: absolute; top: 20px; left: 20px; z-index: 4;
  color: #fff; font-size: .9rem; font-weight: 600; letter-spacing: .02em;
  background: rgba(22,24,27,.55); border: 1px solid rgba(255,255,255,.14);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  padding: 6px 14px; border-radius: 999px;
}

/* Zoom cluster — always visible; "Fit" doubles as the reset-to-fit button */
.lb-zoom {
  position: absolute; left: 50%; bottom: 104px; transform: translateX(-50%);
  z-index: 4; display: flex; align-items: center; gap: 4px;
  background: rgba(22,24,27,.55); border: 1px solid rgba(255,255,255,.14);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  padding: 6px; border-radius: 999px; box-shadow: 0 6px 22px rgba(0,0,0,.4);
}
.lb-zoom-btn { position: static; width: 38px; height: 38px; background: transparent; border: none; box-shadow: none; }
.lb-zoom-btn:hover { background: rgba(255,255,255,.16); transform: none; }
.lb-zoom-level {
  min-width: 58px; height: 38px; padding: 0 12px;
  background: transparent; color: #fff; border: none; cursor: pointer;
  font-size: .8rem; font-weight: 700; letter-spacing: .04em;
  border-radius: 999px; transition: background .15s, color .15s;
}
.lb-zoom-level:hover { background: rgba(255,255,255,.16); }
.lightbox.is-zoomed .lb-zoom-level { color: #ffd23f; }   /* highlight the reset when zoomed */

/* Filmstrip */
.lb-filmstrip {
  flex: 0 0 auto; display: flex; gap: 8px;
  overflow-x: auto; padding: 12px 16px;
  background: rgba(9,10,11,.94); scrollbar-width: thin;
}
.lb-thumb {
  flex: 0 0 92px; height: 64px; padding: 0;
  border: 2px solid transparent; border-radius: 6px;
  overflow: hidden; cursor: pointer; background: none;
  opacity: .5; transition: opacity .18s, border-color .18s, transform .18s;
}
.lb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lb-thumb:hover { opacity: .85; transform: translateY(-2px); }
.lb-thumb.active { border-color: #fff; opacity: 1; }

@media (max-width: 600px) {
  .lb-nav { width: 60px; height: 60px; }
  .lb-prev { left: 12px; } .lb-next { right: 12px; }
  .lb-thumb { flex: 0 0 76px; height: 54px; }
  .lb-zoom { bottom: 92px; }
  .lb-hint { font-size: .72rem; padding: 12px; }
}
.gallery-iframe { width: 100%; height: 100%; min-height: 320px; }
.gallery-iframe iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; padding-bottom: 6px; }
.thumb-video { position: relative; }
.thumb-video .play-overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  pointer-events: none;
  border-radius: inherit;
}
.thumb-video .play-overlay svg { width: 28px; height: 28px; opacity: 0.95; }
.thumb {
  flex: 0 0 80px; height: 60px; padding: 0;
  border: 2px solid transparent; background: var(--bg-alt);
  border-radius: 8px; overflow: hidden; cursor: pointer;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.active { border-color: var(--accent); }
.car-info h1 { font-size: 1.7rem; margin: 0 0 4px; letter-spacing: -.01em; }
.price { font-size: 1.8rem; font-weight: 800; margin: 12px 0 8px; color: var(--accent); }
.urgency-note {
  font-size: .88rem;
  color: #b45309;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 6px 10px;
  margin: 0 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.urgency-note svg { width: 14px; height: 14px; flex-shrink: 0; }

/* SOLD banner on a sold car's detail page (replaces price + urgency) */
.sold-banner {
  display: flex; align-items: center; gap: 14px;
  background: #fef2f2; border: 1px solid #fecaca; border-radius: 8px;
  padding: 14px 16px; margin: 14px 0 22px;
}
.sold-banner .sold-stamp {
  display: inline-block; font-weight: 900; font-size: 1.2rem;
  letter-spacing: 2px; color: #fff; background: #dc2626;
  padding: 6px 12px; border-radius: 4px; transform: rotate(-3deg);
}
.sold-banner .sold-note { color: #7f1d1d; line-height: 1.4; }
.sold-banner a { color: #7f1d1d; text-decoration: underline; }

/* SOLD diagonal stamp on recently-sold gallery cards */
.card-sold { position: relative; }
.card-sold .card-img { position: relative; }
.card-sold .sold-stamp {
  position: absolute; top: 18px; right: -8px;
  background: #dc2626; color: #fff; font-weight: 900; font-size: 1rem;
  letter-spacing: 2px; padding: 6px 14px; border-radius: 4px;
  transform: rotate(8deg); box-shadow: 0 2px 8px rgba(0,0,0,.25);
  pointer-events: none;
}
.card-sold .card-img img { filter: brightness(.92); }

/* SPECIAL stamp for the AI-picked featured car on /specials.html */
.card-special { position: relative; max-width: 600px; }
.card-special .card-img { position: relative; }
.card-special .special-stamp {
  position: absolute; top: 18px; left: -8px;
  background: #047857; color: #fff; font-weight: 900; font-size: 1rem;
  letter-spacing: 2px; padding: 6px 14px; border-radius: 4px;
  transform: rotate(-6deg); box-shadow: 0 2px 8px rgba(0,0,0,.25);
  pointer-events: none;
}
.special-reason {
  margin: 10px 0 0; padding: 10px 12px;
  background: #ecfdf5; border-left: 3px solid #047857;
  color: #064e3b; font-size: 0.95rem; line-height: 1.4;
  border-radius: 0 6px 6px 0;
}

.specs { display: grid; grid-template-columns: max-content 1fr; column-gap: 16px; row-gap: 6px; margin: 0 0 22px; }
.specs dt { color: var(--fg-muted); }
.specs dd { margin: 0; font-weight: 500; }
.contact-actions { display: flex; gap: 10px; flex-wrap: wrap; margin: 10px 0 16px; }
.carfax-card { border: 1px solid var(--border, #e2e2e2); border-radius: 10px; overflow: hidden; margin: 0 0 14px; font-size: .9rem; }
.carfax-card-header { background: #003087; color: #fff; padding: 9px 14px; font-weight: 600; display: flex; align-items: center; gap: 9px; letter-spacing: .01em; }
.carfax-wordmark { background: #fff; color: #003087; font-weight: 800; font-size: .72rem; letter-spacing: .04em; padding: 2px 6px; border-radius: 3px; }
.carfax-card-body { display: grid; grid-template-columns: 1fr 1fr; }
.carfax-stat { padding: 10px 14px; border-top: 1px solid #f0f0f0; display: flex; align-items: flex-start; gap: 8px; line-height: 1.3; }
.carfax-stat .ci { flex: none; }
.carfax-stat.good { color: #1a7a1a; }
.carfax-stat.warn { color: #c0392b; }
.carfax-stat small { opacity: .7; }
@media (max-width: 540px) { .carfax-card-body { grid-template-columns: 1fr; } }
.carfax-badge { display: inline-block; margin: 2px 0 12px; }
.car-description { margin-top: 28px; overflow-wrap: break-word; }
.car-features { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 6px; }
.car-features li { padding-left: 20px; position: relative; font-size: .95rem; }
.car-features li::before { content: "•"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }

/* Contact grid */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; margin-top: 12px; }
@media (max-width: 800px) { .contact-grid { grid-template-columns: 1fr; } }

/* Lead form */
.lead-section { margin-top: 56px; padding-top: 32px; border-top: 1px solid var(--line); max-width: 720px; }
.lead-section h2 { margin: 0 0 4px; }
.lead-form { display: grid; gap: 14px; margin-top: 18px; position: relative; }
.lead-form label { display: grid; gap: 6px; }
.lead-form label > span { font-size: .9rem; color: var(--fg-muted); }
.lead-form label em { font-style: normal; color: var(--fg-muted); font-weight: 400; }
.lead-form input[type=text],
.lead-form input[type=tel],
.lead-form input[type=email],
.lead-form textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
  background: #fff;
  color: var(--fg);
}
.lead-form textarea { resize: vertical; min-height: 90px; }
.lead-form input:focus,
.lead-form textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: transparent;
}
.lead-form .lead-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 600px) { .lead-form .lead-row { grid-template-columns: 1fr; } }
.lead-form button[type=submit] { justify-self: start; }
.lead-form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* Floating "leave a message" widget */
.lm-bubble {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
  display: grid;
  place-items: center;
  z-index: 100;
  transition: transform .15s ease, box-shadow .15s ease;
}
.lm-bubble:hover { transform: translateY(-2px); box-shadow: 0 8px 26px rgba(0, 0, 0, .22); }
.lm-bubble svg  { width: 26px; height: 26px; }
.lm-bubble-open { background: var(--accent-hover); }

.lm-panel {
  position: fixed;
  bottom: 92px;
  right: 24px;
  width: 340px;
  max-height: calc(100vh - 120px);
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .22);
  z-index: 99;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.lm-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  background: #1D3461;
  color: #fff;
}
.lm-header h3 { margin: 0; font-size: 1rem; }
.lm-close {
  background: transparent; border: none; color: #fff;
  font-size: 1.5rem; line-height: 1; cursor: pointer; padding: 0 4px;
}
.lm-form { padding: 14px 16px 16px; display: grid; gap: 10px; position: relative; overflow-y: auto; }
.lm-form label { display: grid; gap: 4px; }
.lm-form label > span { font-size: .85rem; color: var(--fg-muted); }
.lm-form label em { font-style: normal; font-weight: 400; }
.lm-form input[type=text],
.lm-form input[type=tel],
.lm-form textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
}
.lm-form textarea { resize: vertical; min-height: 72px; }
.lm-form input:focus, .lm-form textarea:focus {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent;
}
.lm-form button[type=submit] { justify-self: start; }

/* Conversation view (after chat is started) */
.lm-chat { display: flex; flex-direction: column; height: 360px; max-height: calc(100vh - 180px); }
.lm-messages { flex: 1; overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; background: #f6f7f9; }
.lm-msg { max-width: 80%; padding: 8px 12px; border-radius: 14px; font-size: .92rem; line-height: 1.35; word-wrap: break-word; }
.lm-msg-visitor { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.lm-msg-staff   { align-self: flex-start; background: #fff; color: var(--fg); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.lm-chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); background: #fff; }
.lm-chat-form input {
  flex: 1; padding: 9px 12px; border: 1px solid var(--line); border-radius: 999px;
  font: inherit;
}
.lm-chat-form input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.lm-chat-send {
  background: var(--accent); color: #fff; border: none; width: 38px; height: 38px;
  border-radius: 50%; font-size: 1.3rem; cursor: pointer; flex-shrink: 0;
}
.lm-chat-send:hover { background: var(--accent-hover); }
.lm-chat-ended {
  text-align: center;
  padding: 16px;
  border-top: 1px solid var(--line);
  background: #fff;
}
.lm-chat-ended p { margin: 0 0 10px; color: var(--fg-muted); font-size: .9rem; }

@media (max-width: 600px) {
  .lm-panel { width: calc(100vw - 32px); right: 16px; bottom: 80px; }
  .lm-bubble { right: 16px; bottom: 16px; }
}

/* Mobile-only sticky bottom action bar — present only on car detail pages */
.mobile-sticky-bar { display: none; }
@media (max-width: 768px) {
  .mobile-sticky-bar {
    display: flex; position: fixed;
    bottom: 0; left: 0; right: 0;
    padding: 10px 16px; gap: 10px;
    background: #fff;
    border-top: 1px solid var(--line);
    box-shadow: 0 -4px 12px rgba(0,0,0,.08);
    z-index: 40;
  }
  .mobile-sticky-bar .btn { flex: 1; justify-content: center; text-align: center; padding-left: 0; padding-right: 0; }
  /* When the sticky bar is on the page, push the floating "leave us a message"
     bubble higher so it doesn't sit on top of the bar. */
  body:has(.mobile-sticky-bar) .lm-bubble { bottom: 84px; }
  body:has(.mobile-sticky-bar) { padding-bottom: 72px; }
}

/* Footer */
.site-footer { background: var(--ink); border-top: 3px solid var(--accent); color: var(--ink-muted); padding: 48px 0 24px; margin-top: 64px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.site-footer h4 { margin: 0 0 8px; font-size: .95rem; color: var(--ink-fg); }
.site-footer p { margin: 4px 0; }
.site-footer a { color: var(--ink-fg); }
.site-footer a:hover { color: var(--accent); }
.site-footer .muted { color: var(--ink-muted); }
.footer-bottom { border-top: 1px solid var(--ink-line); margin-top: 32px; padding-top: 16px; font-size: .85rem; text-align: center; color: var(--ink-muted); }
.footer-bottom a { color: var(--ink-fg); }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* ── Capital One financing — PREVIEW placeholders only. No third-party
   scripts load yet; these get swapped for the verified Capital One loaders
   once the integration is confirmed. ─────────────────────────────────────── */
:root { --capone-navy: #004977; --capone-red: #d03027; }
.nav-prequal {
  font-weight: 700; color: #fff;
  border: 1px solid rgba(255, 255, 255, .45); border-radius: 999px; padding: 4px 12px;
}
.nav-prequal:hover { background: #fff; color: var(--capone-navy); text-decoration: none; }
.capone-mark { font-weight: 800; letter-spacing: -.02em; color: var(--capone-navy); }
.capone-mark span { color: var(--capone-red); }
.capone-mark-lg { font-size: 1.6rem; }
.capone-preview {
  font-size: .62rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: #8a6d00; background: #fff3cd; border: 1px solid #ffe08a;
  padding: 2px 7px; border-radius: 999px; vertical-align: middle;
}
.capone-panel {
  margin-top: 18px; padding: 16px;
  border: 1px solid #cfe0ec; border-radius: var(--radius);
  background: linear-gradient(180deg,#f4f9fd,#eef5fb);
}
.capone-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.capone-lead { margin: 0 0 8px; font-size: .95rem; line-height: 1.4; }
.capone-est { margin: 0 0 12px; font-size: 1.05rem; color: var(--capone-navy); }
.capone-est strong { font-size: 1.35rem; }
.capone-est span { display: block; font-size: .72rem; color: var(--fg-muted); font-weight: 400; }
.capone-btn { background: var(--capone-red); color: #fff; width: 100%; text-align: center; }
.capone-btn:hover { background: #b3271a; text-decoration: none; }
.capone-note { margin: 10px 0 0; font-size: .72rem; color: var(--fg-muted); font-style: italic; }
.capone-hero { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.capone-appshell {
  margin-top: 20px; padding: 24px;
  border: 1px solid #cfe0ec; border-radius: var(--radius);
  background: linear-gradient(180deg,#f4f9fd,#eef5fb);
}
.capone-appshell-row { display: flex; gap: 12px; margin-bottom: 14px; }
.capone-skel {
  flex: 1; height: 44px; border-radius: 8px;
  background: linear-gradient(90deg,#e3edf5,#f2f7fb,#e3edf5);
  background-size: 200% 100%; animation: capone-shimmer 1.4s linear infinite;
}
.capone-skel.skel-lg { height: 52px; }
@keyframes capone-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.capone-btn-lg { display: inline-block; width: auto; padding: 12px 22px; margin-top: 4px; }

/* --- Locations (per-lot pages + index) ----------------------------------- */
.loc-detail {
  display: flex; flex-wrap: wrap; gap: 1.5rem 2.5rem;
  align-items: start; margin: 1rem 0 2rem;
  padding: 1.25rem 1.5rem; background: var(--bg-alt);
  border: 1px solid var(--line); border-radius: var(--radius);
}
.loc-facts { list-style: none; margin: 0; padding: 0; min-width: 16rem; }
.loc-facts li { margin: 0 0 .55rem; }
.loc-facts strong {
  display: block; font-size: .72rem; letter-spacing: .04em;
  text-transform: uppercase; color: var(--fg-muted);
}
.loc-hours { border-collapse: collapse; font-size: .92rem; }
.loc-hours caption {
  text-align: left; font-size: .72rem; letter-spacing: .04em;
  text-transform: uppercase; color: var(--fg-muted); margin-bottom: .3rem;
}
.loc-hours th { text-align: left; font-weight: 500; padding: .12rem 1.5rem .12rem 0; }
.loc-hours td { text-align: right; color: var(--fg-muted); }
.loc-card .card-body { padding: 1.1rem 1.25rem; }
.loc-card-meta {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-top: .6rem; font-size: .9rem; color: var(--fg-muted);
}

/* --- Top utility bar: location switcher (left) + phone (right) --------- */
.topbar { background: var(--ink-bar); border-bottom: 1px solid var(--ink-line); font-size: .9rem; color: var(--ink-muted); }
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; min-height: 44px; padding-top: 4px; padding-bottom: 4px;
}
.loc-switch { position: relative; }
.loc-switch summary {
  list-style: none; display: inline-flex; align-items: center; gap: 8px;
  cursor: pointer; user-select: none; padding: 5px 12px; min-height: 38px;
  border-radius: 999px; color: var(--ink-fg);
}
.loc-switch summary::-webkit-details-marker { display: none; }
.loc-switch summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.loc-switch-text { white-space: nowrap; }
.loc-switch summary:hover { background: rgba(255, 255, 255, .08); }
.loc-switch-kicker { color: var(--ink-muted); }
.loc-switch-name { font-weight: 600; }
.loc-chev { color: var(--ink-muted); font-size: .8em; }
.loc-menu {
  position: absolute; left: 0; top: calc(100% + 8px); z-index: 60;
  min-width: 18rem; max-width: calc(100vw - 32px);
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 6px;
}
.loc-menu-head {
  display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .04em;
  color: var(--fg-muted); padding: 8px 10px;
}
.loc-menu-item {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding: 10px; border-radius: 8px; color: var(--fg); text-decoration: none;
}
.loc-menu-item:hover { background: var(--bg-alt); text-decoration: none; }
.loc-menu-item[aria-current="true"] { background: var(--bg-alt); font-weight: 600; }
.loc-menu-name { font-weight: 500; }
.loc-menu-meta { font-size: .85rem; color: var(--fg-muted); }
.loc-menu-all {
  display: block; padding: 10px; margin-top: 4px; border-top: 1px solid var(--line);
  font-weight: 600; color: var(--accent); text-decoration: none;
}
.loc-menu-all:hover { background: var(--bg-alt); text-decoration: none; }
.topbar-phone { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-fg); font-weight: 600; text-decoration: none; }
.topbar-phone:hover { color: var(--accent); text-decoration: none; }
@media (max-width: 800px) {
  .topbar-inner { padding-left: 16px; padding-right: 16px; }
  .topbar-phone span { display: none; }
}

/* --- Choose-your-store cards ------------------------------------------- */
.choose-hero { text-align: center; max-width: 42rem; margin-inline: auto; }
.loc-card-cta { display: inline-block; margin-top: .7rem; color: var(--accent); font-weight: 600; }

/* ── Inline "Ask AI about this vehicle" chat (detail page) ─────────────── */
.va-chat { margin-top: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg); box-shadow: var(--shadow); overflow: hidden; }
.va-head { padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--bg-alt); }
.va-title { display: block; font-weight: 600; font-size: .95rem; color: var(--fg); }
.va-sub { display: block; margin-top: 2px; font-size: .78rem; color: var(--fg-muted); }
.va-thread { display: flex; flex-direction: column; gap: 8px; padding: 14px; max-height: 340px; overflow-y: auto; }
.va-msg { max-width: 85%; padding: 8px 12px; border-radius: 14px; font-size: .92rem; line-height: 1.4; word-wrap: break-word; white-space: pre-wrap; }
.va-msg-bot { align-self: flex-start; background: var(--bg-alt); color: var(--fg); border-bottom-left-radius: 4px; }
.va-msg-bot a { color: var(--accent); }
.va-msg-user { align-self: flex-end; background: var(--accent); color: var(--accent-fg); border-bottom-right-radius: 4px; }
.va-typing { display: flex; gap: 4px; align-items: center; }
.va-typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--fg-muted); animation: va-blink 1.2s infinite both; }
.va-typing span:nth-child(2) { animation-delay: .2s; }
.va-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes va-blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: .9; } }
.va-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 14px 12px; }
.va-chip { font: inherit; font-size: .85rem; cursor: pointer; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); color: var(--fg); }
.va-chip:hover { border-color: var(--accent); color: var(--accent); }
.va-form { display: flex; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--line); background: var(--bg); }
.va-form input { flex: 1; padding: 9px 12px; border: 1px solid var(--line); border-radius: 999px; font: inherit; }
.va-form input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.va-send { flex-shrink: 0; width: 38px; height: 38px; border: none; border-radius: 50%; background: var(--accent); color: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.va-send:hover { background: var(--accent-hover); }
.va-foot { padding: 0 14px 12px; }
.va-foot a { color: var(--accent); }

/* ── Header polish: topbar contact, GET PRE-APPROVED, trust strip ─────── */
.topbar-contact { display: inline-flex; align-items: center; gap: 14px; }
.topbar-addr { color: var(--ink-muted); }
.cta-prequal { white-space: nowrap; }
.trust-strip { background: var(--bg); border-bottom: 1px solid var(--line); }
.trust-inner { display: flex; flex-wrap: wrap; gap: 8px 28px; justify-content: center; padding: 9px 24px; font-size: .82rem; color: var(--fg-muted); }
.trust-item b { color: var(--fg); font-weight: 600; }
@media (max-width: 800px) { .topbar-addr { display: none; } .trust-inner { font-size: .74rem; gap: 6px 14px; } }

/* ── Homepage search band (inventory-first) + nearest-store widget ────── */
.search-band { background: var(--ink); color: var(--ink-fg); padding: 40px 0 44px; }
.search-band h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); margin: 0 0 6px; letter-spacing: -.02em; }
.search-band .sb-sub { color: var(--ink-muted); margin: 0 0 22px; }
.sb-search { display: flex; gap: 10px; max-width: 640px; }
.sb-search input { flex: 1; padding: 13px 18px; border: 1px solid var(--ink-line); border-radius: 999px; font: inherit; background: #fff; color: var(--fg); }
.sb-search button { border: none; border-radius: 999px; padding: 13px 24px; background: var(--accent); color: #fff; font-weight: 600; cursor: pointer; }
.sb-search button:hover { background: var(--accent-hover); }
.sb-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.sb-chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--ink-line); background: rgba(255,255,255,.06); color: var(--ink-fg); border-radius: 999px; padding: 7px 14px; font-size: .88rem; }
.sb-chip:hover { background: rgba(255,255,255,.14); text-decoration: none; }
.sb-chip b { color: #fff; }
/* nearest-store */
.nearby { margin-top: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.nearby form { display: flex; gap: 8px; }
.nearby input { width: 130px; padding: 10px 14px; border: 1px solid var(--ink-line); border-radius: 999px; background: #fff; color: var(--fg); font: inherit; }
.nearby button, .nearby .geo-btn { border: 1px solid var(--ink-line); background: rgba(255,255,255,.06); color: var(--ink-fg); border-radius: 999px; padding: 10px 16px; font: inherit; font-size: .9rem; cursor: pointer; }
.nearby button:hover, .nearby .geo-btn:hover { background: rgba(255,255,255,.14); }
.nearby-result { width: 100%; margin-top: 6px; color: var(--ink-fg); font-size: .95rem; }
.nearby-result a { color: #fff; font-weight: 600; text-decoration: underline; }

/* New-arrival badge (top-left of card photo) */
.card-badge-new { position: absolute; top: 8px; left: 8px; z-index: 1; background: var(--accent); color: #fff; font-size: .7rem; font-weight: 600; padding: 3px 9px; border-radius: 6px; letter-spacing: .01em; }
/* Sticky price/CTA rail on the detail page (desktop) */
@media (min-width: 901px) { .car-info { position: sticky; top: 96px; align-self: start; } }

/* ── Sonic-style faceted inventory filter (left sidebar) ──────────────── */
.inv-layout { display: grid; grid-template-columns: 264px 1fr; gap: 28px; align-items: start; }
.inv-filters { position: sticky; top: 96px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 14px 14px; }
.inv-filters-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); font-weight: 700; }
.inv-clear { background: none; border: none; color: var(--accent); font: inherit; font-size: .85rem; cursor: pointer; }
.inv-search { width: 100%; margin: 12px 0; padding: 10px 14px; border: 1px solid var(--line); border-radius: 999px; font: inherit; }
.facet { border-bottom: 1px solid var(--line); }
.facet > summary { list-style: none; cursor: pointer; padding: 12px 0; font-weight: 600; font-size: .92rem; display: flex; justify-content: space-between; align-items: center; }
.facet > summary::-webkit-details-marker { display: none; }
.facet > summary::after { content: "+"; color: var(--fg-muted); font-weight: 400; font-size: 1.1rem; }
.facet[open] > summary::after { content: "–"; }
.facet-body { padding: 0 0 12px; display: flex; flex-direction: column; gap: 9px; max-height: 240px; overflow-y: auto; }
.facet-opt { display: flex; align-items: center; gap: 8px; font-size: .88rem; cursor: pointer; }
.facet-opt input { accent-color: var(--accent); flex-shrink: 0; }
.facet-opt > span { flex: 1; }
.facet-opt b { color: var(--fg-muted); font-weight: 400; font-size: .82rem; }
.facet-opt.is-zero { opacity: .4; }
.facet-range { flex-direction: row; align-items: center; gap: 8px; }
.facet-range select { flex: 1; padding: 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.inv-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; }
.inv-count { color: var(--fg-muted); }
.inv-count strong { color: var(--fg); }
.inv-toolbar #f-sort { padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: var(--bg); }
@media (max-width: 800px) { .inv-layout { grid-template-columns: 1fr; } .inv-filters { position: static; } }

.similar-cars { margin-top: 44px; }

/* radius search list (homepage search band) */
.nearby select { padding: 10px 14px; border: 1px solid var(--ink-line); border-radius: 999px; background: #fff; color: var(--fg); font: inherit; }
.nearby-loc { color: #fff; font-size: .98rem; margin-bottom: 8px; }
.nearby-loc b { font-weight: 700; }
.nearby-list { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.nearby-list > b { color: #fff; }
.nearby-lot { color: var(--ink-fg); font-size: .95rem; }
.nearby-lot a { color: #fff; font-weight: 600; text-decoration: underline; }

/* ── "Search Near You" — ZIP + radius slider (Sergey reference) ───────── */
.search-near-wrap { padding-top: 0; margin-top: -28px; }
.search-near { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 28px 28px; max-width: 720px; box-shadow: var(--shadow); }
.search-near h2 { margin: 0 0 4px; }
.search-near > p { color: var(--fg-muted); margin: 0 0 18px; }
.sn-row { display: flex; gap: 12px; }
.sn-row input { flex: 1; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius-sm); font: inherit; }
.sn-row input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.sn-btn { background: var(--ink); color: #fff; border: none; border-radius: var(--radius-sm); padding: 0 28px; font-weight: 600; font-size: 1rem; cursor: pointer; white-space: nowrap; }
.sn-btn:hover { background: #1a2435; }
.sn-slider { margin-top: 22px; }
.sn-head { display: flex; justify-content: space-between; font-weight: 600; margin-bottom: 8px; }
#radius-range { width: 100%; accent-color: var(--accent); height: 6px; }
.sn-ticks { display: flex; justify-content: space-between; color: var(--fg-muted); font-size: .8rem; margin-top: 4px; }
.sn-geo { background: none; border: none; color: var(--accent); font: inherit; cursor: pointer; margin-top: 16px; padding: 0; }
.sn-geo:hover { text-decoration: underline; }
.search-near .nearby-result { color: var(--fg); margin-top: 16px; }
.search-near .nearby-list { display: flex; flex-direction: column; gap: 6px; }
.search-near .nearby-list > b { color: var(--fg); }
.search-near .nearby-lot { color: var(--fg); font-size: .95rem; }
.search-near .nearby-lot a { color: var(--accent); font-weight: 600; }
@media (max-width: 600px) { .sn-row { flex-direction: column; } .sn-btn { padding: 13px; } }

/* ── Carfax page-1 preview (clickable → full PDF) ─────────────────────── */
.carfax-preview { display: block; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 14px 0; box-shadow: var(--shadow); }
.carfax-preview:hover { box-shadow: var(--shadow-2); text-decoration: none; }
.carfax-preview img { width: 100%; display: block; border-bottom: 1px solid var(--line); }
.carfax-preview-cta { display: block; padding: 11px 14px; font-weight: 600; color: var(--accent); text-align: center; background: var(--bg); }

.sn-map { height: 320px; border-radius: var(--radius-sm); margin-top: 18px; border: 1px solid var(--line); z-index: 0; }
.sn-map .leaflet-popup-content a { color: var(--accent); font-weight: 600; }

/* slim "near you" link in the homepage search band */
.sb-near { margin: 16px 0 0; }
.sb-near a { color: var(--ink-fg); text-decoration: none; font-size: .92rem; }
.sb-near a:hover { color: var(--accent); }
/* full-width Search Near You on the chooser page */
.search-near-lg { max-width: none; }
.search-near-lg .sn-map { height: 420px; }
