/* ===== Clearway Motor Group — shared styles ===== */
:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --ink: #10151c;
  --muted: #55606e;
  --line: #dde3ea;
  --steel: #1b2a3a;
  --steel-ink: #eaf1f8;
  --accent: #e8701a;
  --accent-ink: #ffffff;
  --good: #1f8a52;
  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d141c; --surface: #151f2a; --ink: #eef3f8; --muted: #9aa7b5;
    --line: #263341; --steel: #0a111a; --steel-ink: #eaf1f8; --accent: #f2822e;
    --accent-ink: #1a1005; --good: #44c17f; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0d141c; --surface: #151f2a; --ink: #eef3f8; --muted: #9aa7b5;
  --line: #263341; --steel: #0a111a; --steel-ink: #eaf1f8; --accent: #f2822e;
  --accent-ink: #1a1005; --good: #44c17f; color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-body); line-height: 1.55; -webkit-font-smoothing: antialiased;
}
.wrap {
  max-width: 1100px; margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
h1, h2, h3 { font-family: var(--font-display); text-wrap: balance; line-height: 1.08; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; }

/* Header + nav */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: var(--steel); color: var(--steel-ink); border-bottom: 1px solid rgba(255,255,255,0.08);
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 21; background: var(--steel); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 13px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-badge { width: 36px; height: 36px; display: block; flex: none; }
.brand .mark { font-family: var(--font-display); font-weight: 800; font-size: 1.12rem; letter-spacing: 0.02em; color: var(--steel-ink); }
.brand .mark b { color: var(--accent); }
.nav { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.nav a.link { font-family: var(--font-display); font-weight: 600; font-size: 0.92rem; color: #c3d0dd; text-decoration: none; letter-spacing: 0.01em; }
.nav a.link:hover, .nav a.link.active { color: #fff; }
.header-call { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 700; font-size: 1.0rem; color: var(--steel-ink); text-decoration: none; white-space: nowrap; }
.header-call .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 3px rgba(68,193,127,0.2); }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 40px; align-items: center; justify-content: center; background: transparent; border: 1px solid rgba(255,255,255,0.28); border-radius: 9px; color: var(--steel-ink); font-size: 1.35rem; line-height: 1; cursor: pointer; }
@media (max-width: 640px) {
  .site-header .wrap { flex-wrap: wrap; }
  .nav-toggle { display: inline-flex; }
  .nav { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 0; padding: 6px 0 4px; }
  .nav.open { display: flex; }
  .nav a.link { font-size: 1.02rem; padding: 12px 4px; border-top: 1px solid rgba(255,255,255,0.08); width: 100%; }
  .nav .header-call { font-size: 1.1rem; padding: 14px 4px; border-top: 1px solid rgba(255,255,255,0.08); }
}

/* Hero */
.hero { background: var(--steel); color: var(--steel-ink); }
.hero .wrap { padding-block: clamp(40px, 8vw, 76px); display: grid; gap: 28px; }
.eyebrow { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.18em; color: var(--accent); font-weight: 700; }
.hero h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); font-weight: 800; max-width: 16ch; }
.hero .lede { font-size: clamp(1.02rem, 2.4vw, 1.2rem); color: #c3d0dd; max-width: 56ch; }
.phone-xl { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.6rem, 5vw, 2.2rem); letter-spacing: 0.01em; font-variant-numeric: tabular-nums; color: #fff; }
.phone-note { font-size: 0.82rem; color: #9fb2c4; }

/* Buttons */
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.btn { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; padding: 14px 22px; border-radius: 10px; text-decoration: none; border: 1px solid transparent; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { background: transparent; color: var(--steel-ink); border-color: rgba(255,255,255,0.28); }
.btn-ghost.on-light { color: var(--ink); border-color: var(--line); }
@media (prefers-reduced-motion: no-preference) { .btn { transition: transform 0.08s ease; } .btn:active { transform: translateY(1px); } }

/* Section scaffolding */
section.band { padding-block: clamp(36px, 6vw, 60px); }
.sec-head { display: grid; gap: 8px; margin-bottom: 26px; }
.sec-head h2 { font-size: clamp(1.5rem, 4vw, 2.1rem); font-weight: 800; }
.sec-head p { color: var(--muted); max-width: 60ch; }
.sec-head .viewall { font-family: var(--font-display); font-weight: 700; color: var(--accent); text-decoration: none; font-size: 0.95rem; }

/* Current-cars card grid (home) */
.cc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.cc-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: inherit; }
.cc-card .ph { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; display: block; border-bottom: 1px solid var(--line); background: var(--bg); }
.cc-card .body { padding: 16px; display: grid; gap: 9px; }
.cc-card .tag { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent); font-weight: 700; }
.cc-card h3 { font-size: 1.12rem; font-weight: 700; }
.cc-card .meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.84rem; color: var(--muted); }
.cc-card .meta span { font-variant-numeric: tabular-nums; }
.cc-card .price { font-family: var(--font-display); font-weight: 800; font-size: 1.35rem; color: var(--ink); font-variant-numeric: tabular-nums; }
.cc-card .seemore { font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: 0.9rem; margin-top: 2px; }

/* Trust */
.trust-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.trust { display: grid; gap: 8px; }
.trust .n { font-family: var(--font-display); font-weight: 800; color: var(--accent); font-size: 1.1rem; }
.trust h3 { font-size: 1.05rem; font-weight: 700; }
.trust p { color: var(--muted); font-size: 0.92rem; }

/* Services */
.services { background: var(--steel); color: var(--steel-ink); }
.services .sec-head h2 { color: #fff; }
.services .sec-head p { color: #c3d0dd; }
.svc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; margin-bottom: 30px; }
.svc { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1); border-radius: 14px; padding: 22px; display: grid; gap: 10px; align-content: start; }
.svc .ic { width: 38px; height: 38px; color: var(--accent); }
.svc h3 { font-size: 1.15rem; font-weight: 700; color: #fff; }
.svc p { color: #b9c6d4; font-size: 0.93rem; }
.svc-cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.svc-cta .note { color: #9fb2c4; font-size: 0.88rem; }

/* Contact */
.contact { background: var(--surface); }
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.contact .block { display: grid; gap: 6px; min-width: 0; }
.contact .label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--muted); font-weight: 700; }
.contact .val { font-size: 1.05rem; }
.contact .val a { color: var(--accent); text-decoration: none; font-weight: 600; white-space: nowrap; font-size: 0.98rem; }
.contact .hours-row { display: flex; justify-content: space-between; gap: 16px; max-width: 320px; font-variant-numeric: tabular-nums; }
.contact .hours-row span:last-child { color: var(--muted); }

/* Vehicle showcase + gallery (Our Vehicles page) */
.cw-showcase { display: grid; grid-template-columns: minmax(0, 1.5fr) 1fr; gap: 28px; align-items: start; }
@media (max-width: 760px){ .cw-showcase { grid-template-columns: 1fr; } }
.cw-gallery { min-width: 0; }
.cw-stage { position: relative; }
.cw-main { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); cursor: zoom-in; display: block; }
.cw-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: none; background: rgba(16,21,28,0.5); color: #fff; font-size: 1.7rem; line-height: 1; display: grid; place-items: center; cursor: pointer; z-index: 2; padding: 0 0 4px 0; }
.cw-nav:hover { background: rgba(16,21,28,0.8); }
.cw-prev { left: 10px; }
.cw-next { right: 10px; }
.cw-lb-nav { position: fixed; top: 50%; transform: translateY(-50%); width: 54px; height: 54px; border-radius: 50%; border: none; background: rgba(255,255,255,0.15); color: #fff; font-size: 2.2rem; line-height: 1; display: grid; place-items: center; cursor: pointer; z-index: 51; padding: 0 0 5px 0; }
.cw-lb-nav:hover { background: rgba(255,255,255,0.3); }
.cw-lb-prev { left: max(16px, env(safe-area-inset-left, 0px)); }
.cw-lb-next { right: max(16px, env(safe-area-inset-right, 0px)); }
.cw-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(60px, 1fr)); gap: 8px; margin-top: 10px; }
.cw-thumb { padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; background: none; cursor: pointer; aspect-ratio: 1 / 1; }
.cw-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cw-thumb.active { border-color: var(--accent); }
.cw-thumb:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cw-details { display: grid; gap: 14px; min-width: 0; }
.cw-details .tag { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent); font-weight: 700; }
.cw-details h3 { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.4rem, 3.5vw, 1.9rem); }
.cw-price { font-family: var(--font-display); font-weight: 800; font-size: 2rem; font-variant-numeric: tabular-nums; }
.cw-pricenote { font-size: 0.78rem; color: var(--muted); max-width: 48ch; margin-top: -4px; }
.cw-specs { display: flex; flex-wrap: wrap; gap: 8px; }
.cw-specs span { font-size: 0.85rem; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font-variant-numeric: tabular-nums; }
.cw-blurb { color: var(--muted); font-size: 0.95rem; margin: 0; }
.cw-vin { font-size: 0.8rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.cw-lb { position: fixed; inset: 0; z-index: 50; background: rgba(5,8,12,0.93); display: grid; place-items: center; padding: 20px; cursor: zoom-out; }
.cw-lb img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
.cw-lb-hint { position: fixed; top: calc(14px + env(safe-area-inset-top, 0px)); right: max(20px, env(safe-area-inset-right, 0px)); color: #fff; font-size: 0.85rem; opacity: 0.85; }

/* Footer */
footer { background: var(--steel); color: #b9c6d4; }
footer .wrap { padding-block: 30px; display: grid; gap: 10px; font-size: 0.85rem; }
footer .mark { font-family: var(--font-display); font-weight: 800; color: #fff; font-size: 1.05rem; }
footer a { color: #cdd9e5; }
