/* Leo's Car Lab — independent OmniCores concept. Authored by Fable, 15 October 2026.
   Palette from the Astra brief: ivory #F4F1EA, charcoal #202723, deep green #294D42, brass #B89A63 (decorative only). */

:root {
  --ivory: #F4F1EA;
  --charcoal: #202723;
  --green: #294D42;
  --green-deep: #1F3B33;
  --brass: #B89A63;
  --rule: rgba(32, 39, 35, 0.18);
  --muted: #4A524D;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --measure: 36rem;
  /* Sticky strip offset: measured at runtime by guide.js (strip height + gap). The fallback covers a two-line strip without JS. */
  --strip-gap: 0.75rem;
  --strip-offset: 4.75rem;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
/* Anchor targets and focused step headings must settle below the sticky strip, never under it. */
[id], .step-heading { scroll-margin-top: var(--strip-offset); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem; /* 17px */
  line-height: 1.6;
  color: var(--charcoal);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: anywhere;
}
@media (min-width: 48em) { body { font-size: 1.125rem; } }

img, svg { max-width: 100%; height: auto; display: block; }

.wrap { width: min(100% - 2.5rem, 72rem); margin-inline: auto; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; padding: 0; margin: -1px;
}

.skip-link {
  position: absolute; left: 0.75rem; top: -4rem; z-index: 100;
  background: var(--charcoal); color: var(--ivory); padding: 0.6rem 1rem; border-radius: 0.25rem; text-decoration: none;
}
.skip-link:focus { top: 0.75rem; }

a { color: var(--green); text-underline-offset: 0.16em; }
a:hover { color: var(--green-deep); }
:focus-visible { outline: 3px solid var(--charcoal); outline-offset: 3px; }
.concept-strip :focus-visible { outline-color: var(--ivory); }

/* Concept strip — persistent, high contrast, never hidden */
.concept-strip {
  position: sticky; top: 0; z-index: 50;
  background: var(--charcoal); color: var(--ivory);
  font-size: 0.9375rem; line-height: 1.45;
  border-bottom: 2px solid var(--brass);
}
.concept-strip p { margin: 0; padding: 0.6rem 1.25rem; text-align: center; }
.concept-strip a { color: var(--ivory); font-weight: 600; }

/* Header */
.site-header { border-bottom: 1px solid var(--rule); background: var(--ivory); }
.header-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1.5rem; padding: 1rem 0; }
.brand { margin: 0; font-size: 1.25rem; letter-spacing: -0.01em; }
.brand-name { font-weight: 700; }
.concept-tag {
  display: inline-block; margin-left: 0.4rem; padding: 0.1rem 0.5rem; vertical-align: middle;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--charcoal); border: 1.5px solid var(--charcoal); border-radius: 999px;
}
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
.nav-list a { display: inline-block; padding: 0.5rem 0; min-height: 44px; line-height: 2; color: var(--charcoal); text-decoration: none; font-weight: 500; border-bottom: 2px solid transparent; }
.nav-list a:hover { border-bottom-color: var(--charcoal); }
.nav-list .nav-cta { color: var(--green); font-weight: 700; }

/* Buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  min-height: 48px; padding: 0.7rem 1.4rem; border-radius: 0.35rem;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  border: 2px solid transparent; transition: background-color 120ms ease, color 120ms ease;
}
.button.primary { background: var(--green); color: #fff; border-color: var(--green); }
.button.primary:hover { background: var(--green-deep); border-color: var(--green-deep); color: #fff; }
.button.secondary { background: transparent; color: var(--charcoal); border-color: var(--charcoal); }
.button.secondary:hover { background: var(--charcoal); color: var(--ivory); }

/* Hero */
.hero { padding: 3rem 0 3.5rem; border-bottom: 1px solid var(--rule); }
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
.eyebrow { margin: 0 0 1rem; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
h1 { margin: 0 0 1rem; font-size: 2.25rem; /* 36px mobile */ line-height: 1.08; letter-spacing: -0.02em; font-weight: 700; max-width: 14ch; }
.lead { margin: 0 0 1.75rem; font-size: 1.25rem; line-height: 1.45; max-width: var(--measure); color: var(--charcoal); }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.note { margin: 1.1rem 0 0; font-size: 0.9375rem; color: var(--muted); }
.hero-art { margin: 0; border-radius: 0.5rem; overflow: hidden; }
.hero-art svg { width: 100%; height: auto; }

@media (min-width: 60em) {
  .hero { padding: 5rem 0 5.5rem; }
  .hero-grid { grid-template-columns: 7fr 5fr; gap: 4rem; }
  h1 { font-size: 3.5rem; /* 56px desktop */ }
  .hero-art { transform: translateY(1.25rem); }
}
@media (min-width: 80em) { h1 { font-size: 3.75rem; } }

/* Sections */
.section { padding: 3.5rem 0; }
@media (min-width: 60em) { .section { padding: 5rem 0; } }
h2 { margin: 0 0 0.75rem; font-size: 1.75rem; line-height: 1.15; letter-spacing: -0.015em; }
@media (min-width: 60em) { h2 { font-size: 2.25rem; } }
h3 { margin: 0 0 0.4rem; font-size: 1.25rem; line-height: 1.25; }
.section-intro { margin: 0 0 2rem; max-width: var(--measure); color: var(--muted); }

.services { border-bottom: 1px solid var(--rule); }
.paths { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.25rem; }
.path { padding: 1.5rem 0 1.75rem; border-top: 1px solid var(--rule); }
.path p:last-child { margin: 0; color: var(--muted); }
.path-label { margin: 0 0 0.5rem; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--green); }
.path-label::before { content: ""; display: inline-block; width: 1.5rem; height: 2px; margin-right: 0.6rem; vertical-align: middle; background: var(--brass); }
.location { margin: 2rem 0 0; padding-top: 1.25rem; border-top: 1px solid var(--rule); font-weight: 500; }
@media (min-width: 48em) { .paths { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }

.how { background: var(--green); color: var(--ivory); }
.how h2 { color: #fff; }
.how p { max-width: var(--measure); }
.how-grid { display: grid; gap: 2rem; }
@media (min-width: 60em) { .how-grid { grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; } }
.steps-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.steps-list li { display: flex; gap: 1rem; align-items: baseline; padding-bottom: 1rem; border-bottom: 1px solid rgba(244, 241, 234, 0.25); }
.step-num { flex: none; width: 2rem; height: 2rem; display: inline-flex; align-items: center; justify-content: center; border: 1.5px solid var(--brass); border-radius: 50%; color: var(--ivory); font-weight: 700; font-size: 0.9rem; }

/* Guide */
.guide-wrap { max-width: 44rem; }
.guide-disclaimer { margin: 0 0 1.5rem; padding: 0.75rem 1rem; border-left: 3px solid var(--brass); background: rgba(32, 39, 35, 0.05); font-size: 0.9375rem; }
.step-indicator { margin: 0 0 0.75rem; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.guide-form { margin: 0; }
.guide-step { margin: 0; padding: 0; border: 0; min-width: 0; }
.guide-step[hidden] { display: none; }
.step-heading { margin: 0 0 1rem; padding: 0; font-size: 1.5rem; line-height: 1.2; font-weight: 700; }
legend.step-heading { display: block; float: left; width: 100%; }
legend.step-heading + * { clear: both; }
.choices { display: grid; gap: 0.6rem; margin-bottom: 1rem; }
.choice {
  display: flex; align-items: center; gap: 0.85rem; min-height: 56px;
  padding: 0.75rem 1rem; border: 1.5px solid var(--rule); border-radius: 0.4rem; background: #fff; cursor: pointer;
}
.choice:hover { border-color: var(--charcoal); }
.choice input { width: 1.25rem; height: 1.25rem; margin: 0; flex: none; accent-color: var(--green); cursor: pointer; }
.choice:has(input:checked) { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }
.choice:has(input:focus-visible) { outline: 3px solid var(--charcoal); outline-offset: 2px; }
.choice input:focus-visible { outline: none; }
.field-error { margin: 0 0 1rem; font-weight: 600; color: #8A2E1F; }
.step-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 0.5rem; }

.result .suggestion { margin: 0 0 1.25rem; font-weight: 500; }
.preview { padding: 1.25rem 1.5rem; border: 1px solid var(--rule); border-left: 4px solid var(--green); border-radius: 0.4rem; background: #fff; }
.preview-label { margin: 0 0 0.5rem; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.preview-text { margin: 0; font-size: 1.125rem; line-height: 1.55; }
.result-note { margin: 1.25rem 0 0.5rem; font-weight: 600; }

/* Footer */
.site-footer { padding: 2.5rem 0 3rem; border-top: 1px solid var(--rule); font-size: 0.9375rem; color: var(--muted); }
.footer-strip { margin: 0 0 1rem; padding: 0.75rem 1rem; background: var(--charcoal); color: var(--ivory); border-radius: 0.35rem; font-weight: 600; }
.footer-strip a { color: var(--ivory); }
.footer-meta { margin: 0; max-width: 60rem; }
