/* CarSwap — design system.
   Charcoal/asphalt + warm sand + traffic-signal status colors (green =
   available, amber = reserved, gray = offline) — a road/border-crossing
   palette, deliberately distinct from the water-blue (JohnPlumbing) and
   navy/orange (PelonRemodeling) palettes used elsewhere in this fleet. */

:root {
  --cs-ink: #1b2430;
  --cs-ink-2: #232f3f;
  --cs-slate: #4b5768;
  --cs-steel: #8393a6;
  --cs-steel-light: #c3ccd6;
  --cs-sand: #f6f2e9;
  --cs-sand-2: #ede5d3;
  --cs-white: #ffffff;
  --cs-amber: #dd8f1e;
  --cs-amber-dark: #b8760e;
  --cs-green: #1f9d55;
  --cs-green-dark: #17803f;
  --cs-red: #c94a3c;
  --cs-red-dark: #a83a2f;
  --cs-line: rgba(255, 255, 255, 0.12);
  --cs-line-dark: rgba(27, 36, 48, 0.12);
  --font-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 6px;
  --radius-lg: 10px;
  --shadow: 0 4px 16px rgba(27, 36, 48, 0.15);
  --shadow-lg: 0 12px 32px rgba(27, 36, 48, 0.22);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-base);
  color: var(--cs-ink);
  background: var(--cs-sand);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--cs-amber-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--cs-ink);
}

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cs-amber-dark);
  margin-bottom: 10px;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; color: var(--cs-slate); }

.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.section { padding: 56px 0; }
.section-dark { background: var(--cs-ink); color: var(--cs-white); }
.section-dark h1, .section-dark h2, .section-dark h3, .section-dark p { color: var(--cs-white); }
.section-dark p { color: var(--cs-steel-light); }
.text-center { text-align: center; }
.center { margin-left: auto; margin-right: auto; }
.max-w-prose { max-width: 62ch; }
.mt-0 { margin-top: 0; }

.skip-link { position: absolute; left: -999px; top: 0; background: var(--cs-ink); color: #fff; padding: 10px 16px; z-index: 100; }
.skip-link:focus { left: 10px; top: 10px; }

/* ── Header ─────────────────────────────────────────────────────────────── */
.site-header { background: var(--cs-ink); border-bottom: 3px solid var(--cs-amber); position: sticky; top: 0; z-index: 20; }
.nav { max-width: 1160px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.1rem; color: #fff; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 34px; height: 34px; background: var(--cs-amber); color: var(--cs-ink); border-radius: 7px; display: flex; align-items: center; justify-content: center; font-weight: 900; }
.nav-links { display: none; gap: 18px; margin-left: auto; }
.nav-links a { color: var(--cs-steel-light); font-weight: 600; font-size: 0.94rem; }
.nav-links a:hover { color: #fff; text-decoration: none; }
.nav-actions { display: none; margin-left: 8px; }
.nav-toggle { margin-left: auto; background: transparent; border: none; color: #fff; padding: 6px; }
.mobile-menu { display: none; flex-direction: column; gap: 2px; background: var(--cs-ink-2); padding: 10px 20px 18px; }
.mobile-menu.open { display: flex; }
.mobile-menu a { color: var(--cs-steel-light); padding: 10px 0; border-bottom: 1px solid var(--cs-line); font-weight: 600; }
.mobile-menu a.btn { margin-top: 10px; text-align: center; }

@media (min-width: 860px) {
  .nav-links { display: flex; }
  .nav-actions { display: flex; }
  .nav-toggle { display: none; }
  .mobile-menu { display: none !important; }
}

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border-radius: var(--radius); font-weight: 800; font-size: 0.98rem; cursor: pointer; border: none; min-height: 46px; text-align: center; }
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--cs-amber); color: var(--cs-ink); }
.btn-primary:hover { background: var(--cs-amber-dark); }
.btn-outline { background: transparent; color: #fff; border: 1.5px solid var(--cs-line); }
.btn-outline-dark { background: transparent; color: var(--cs-ink); border: 1.5px solid var(--cs-line-dark); }
.btn-green { background: var(--cs-green); color: #fff; }
.btn-green:hover { background: var(--cs-green-dark); }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero { background: var(--cs-ink); color: #fff; padding: 70px 0 60px; }
.hero p { color: var(--cs-steel-light); font-size: 1.08rem; max-width: 62ch; }
.hero h1 { color: #fff; }
.road-stripe { height: 6px; background: repeating-linear-gradient(90deg, var(--cs-amber) 0 40px, transparent 40px 70px); }

/* ── Steps ──────────────────────────────────────────────────────────────── */
.steps { display: grid; gap: 18px; grid-template-columns: 1fr; margin: 28px 0; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { background: var(--cs-white); border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow); border: 1px solid var(--cs-line-dark); }
.step .step-num { width: 34px; height: 34px; border-radius: 50%; background: var(--cs-amber); color: var(--cs-ink); font-weight: 900; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }

/* ── Cards / grid ───────────────────────────────────────────────────────── */
.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: 1fr; }
@media (min-width: 760px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--cs-white); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow); border: 1px solid var(--cs-line-dark); }

/* ── Notice / callouts ──────────────────────────────────────────────────── */
.notice { background: var(--cs-sand-2); border: 1px solid var(--cs-line-dark); border-radius: var(--radius); padding: 14px 16px; font-size: 0.92rem; color: var(--cs-slate); }
.notice-strong { background: var(--cs-ink); color: #fff; border-radius: var(--radius); padding: 16px 18px; font-weight: 700; }
.notice-strong p { color: var(--cs-steel-light); margin: 0; }

/* ── Status badges ──────────────────────────────────────────────────────── */
.status-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; font-size: 0.76rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.03em; }
.status-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.status-available { background: rgba(31, 157, 85, 0.14); color: var(--cs-green-dark); }
.status-reserved { background: rgba(221, 143, 30, 0.16); color: var(--cs-amber-dark); }
.status-swapped { background: rgba(75, 87, 104, 0.14); color: var(--cs-slate); }
.status-offline { background: rgba(75, 87, 104, 0.14); color: var(--cs-steel); }

/* ── Board (map + list) ─────────────────────────────────────────────────── */
.board-layout { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 920px) { .board-layout { grid-template-columns: 1.1fr 0.9fr; align-items: start; } }
#map { width: 100%; height: 360px; border-radius: var(--radius-lg); box-shadow: var(--shadow); border: 1px solid var(--cs-line-dark); background: var(--cs-sand-2); }
@media (min-width: 920px) { #map { height: 560px; } }
.car-list { display: flex; flex-direction: column; gap: 12px; }
.car-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--cs-white); border-radius: var(--radius-lg); padding: 16px; box-shadow: var(--shadow); border: 1px solid var(--cs-line-dark); cursor: pointer; }
.car-row:hover { border-color: var(--cs-amber); text-decoration: none; }
.car-row .num { font-size: 1.5rem; font-weight: 900; color: var(--cs-ink); }
.car-row .dist { font-size: 0.86rem; color: var(--cs-slate); }
.leaflet-popup-content b { font-size: 1.1rem; }

/* ── Car detail ─────────────────────────────────────────────────────────── */
.car-detail-card { background: var(--cs-white); border-radius: var(--radius-lg); padding: 26px; box-shadow: var(--shadow-lg); border: 1px solid var(--cs-line-dark); max-width: 520px; margin: 0 auto; }
.car-detail-card .num-big { font-size: 3rem; font-weight: 900; line-height: 1; margin-bottom: 6px; }
.detail-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--cs-line-dark); font-size: 0.94rem; }
.detail-row span:first-child { color: var(--cs-slate); }
.detail-row span:last-child { font-weight: 700; }

/* ── Forms ──────────────────────────────────────────────────────────────── */
.form-card { background: var(--cs-white); border-radius: var(--radius-lg); padding: 26px; box-shadow: var(--shadow-lg); border: 1px solid var(--cs-line-dark); max-width: 480px; margin: 0 auto; }
label { display: block; font-size: 0.84rem; font-weight: 700; color: var(--cs-slate); margin-bottom: 6px; }
input[type=text], input[type=tel], input[type=number], textarea, select {
  width: 100%; padding: 13px; font-size: 16px; border-radius: var(--radius); border: 1.5px solid var(--cs-line-dark);
  background: var(--cs-white); color: var(--cs-ink); margin-bottom: 16px;
}
textarea { min-height: 90px; }
.field-error { color: var(--cs-red); font-size: 0.86rem; margin: -10px 0 14px; display: none; }

/* ── Reservation confirmation ───────────────────────────────────────────── */
.confirm-card { text-align: center; }
.confirm-code { font-family: ui-monospace, Menlo, monospace; font-size: 2rem; font-weight: 900; letter-spacing: 0.06em; background: var(--cs-sand-2); border-radius: var(--radius); padding: 14px; margin: 14px 0; }
.confirm-steps { text-align: left; margin: 18px 0; }
.confirm-steps li { margin-bottom: 10px; color: var(--cs-slate); }

/* ── Chips ──────────────────────────────────────────────────────────────── */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { background: var(--cs-sand-2); border: 1px solid var(--cs-line-dark); border-radius: 999px; padding: 6px 14px; font-size: 0.86rem; font-weight: 700; color: var(--cs-ink); }

/* ── Sticky mobile CTA ──────────────────────────────────────────────────── */
.sticky-cta { position: fixed; bottom: 0; left: 0; right: 0; display: flex; gap: 8px; padding: 10px 14px; background: var(--cs-white); border-top: 1px solid var(--cs-line-dark); box-shadow: 0 -4px 16px rgba(0,0,0,.08); z-index: 15; }
.sticky-cta .btn { flex: 1; }
@media (min-width: 760px) { .sticky-cta { display: none; } }
body.has-sticky-cta { padding-bottom: 76px; }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.site-footer { background: var(--cs-ink); color: var(--cs-steel-light); padding: 46px 0 24px; margin-top: 40px; }
.footer-grid { display: grid; gap: 26px; grid-template-columns: 1fr; margin-bottom: 26px; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: repeat(4, 1fr); } }
.footer-grid h4 { color: #fff; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.04em; }
.footer-grid a { color: var(--cs-steel-light); }
.footer-grid p { color: var(--cs-steel-light); font-size: 0.92rem; }
.footer-bottom { display: flex; flex-direction: column; gap: 10px; padding-top: 20px; border-top: 1px solid var(--cs-line); font-size: 0.84rem; color: var(--cs-steel); }
@media (min-width: 760px) { .footer-bottom { flex-direction: row; justify-content: space-between; } }
.footer-bottom a { color: var(--cs-steel-light); margin-right: 16px; }

/* ── Utility ────────────────────────────────────────────────────────────── */
.loading, .empty-state { text-align: center; padding: 40px 20px; color: var(--cs-slate); }
.age-gate-note { display: flex; align-items: center; gap: 8px; font-size: 0.86rem; color: var(--cs-steel-light); }
