/* Agent Tolls marketing site. World: the border checkpoint (see DESIGN.md). */

:root {
  --paper: #F1F3EC;
  --paper-raised: #F9FAF4;
  --ink: #17233B;
  --ink-soft: #47506A;
  --lane-green: #0E9F6E;
  --lane-green-deep: #0B7A55;
  --stop-red: #DE3B4B;
  --signal-amber: #E8A13A;
  --line: #D6DACB;
  --lane-idle: #C8CDBB;

  --font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Archivo", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  --shadow-panel: 0 2px 0 rgba(0, 0, 0, 0.07), 0 12px 24px rgba(0, 0, 0, 0.09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
}
::selection { background: var(--lane-green-deep); color: #fff; }
:focus-visible { outline: 2px solid var(--lane-green); outline-offset: 3px; border-radius: 2px; }

h1, h2, h3 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.98;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: 3.25rem; font-weight: 700; letter-spacing: 0.01em; }
h2 { font-size: 2.25rem; font-weight: 600; }
h3 { font-size: 1.25rem; font-weight: 600; letter-spacing: 0.04em; margin-bottom: 0.35em; }
p { margin: 0 0 1em; max-width: 68ch; }
code, .mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
code {
  background: rgba(23, 35, 59, 0.07);
  padding: 0.08em 0.35em;
  border-radius: 4px;
  font-size: 1em;
}
a { color: var(--lane-green-deep); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.muted { color: var(--ink-soft); }
.small { font-size: 0.875rem; }

/* ── header ─────────────────────────────────────────────── */
.site-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1.1rem clamp(1.25rem, 4vw, 3rem);
  border-bottom: 1px solid var(--line);
}
.wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.08em;
}
.site-header nav { display: flex; gap: 1.5rem; margin-left: auto; }
.site-header nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
}
.site-header nav a:hover { color: var(--ink); }

/* ── buttons ────────────────────────────────────────────── */
.btn {
  display: inline-block;
  background: var(--lane-green-deep);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  padding: 0.8rem 1.6rem;
  border-radius: 6px;
  border: 1px solid var(--lane-green-deep);
  transition: background 0.15s ease, transform 0.15s ease;
}
.btn:hover { background: #095F43; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-small { padding: 0.5rem 1rem; font-size: 1rem; }
.btn-large { font-size: 1.25rem; padding: 1rem 2rem; }
.btn-ghost {
  display: inline-block;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
  padding: 0.8rem 0.25rem;
  border-bottom: 2px solid var(--ink);
}
.btn-ghost:hover { color: var(--lane-green-deep); border-color: var(--lane-green-deep); }

/* ── hero ───────────────────────────────────────────────── */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding: clamp(2.5rem, 6vw, 5rem) clamp(1.25rem, 4vw, 3rem) clamp(3rem, 6vw, 5rem);
  max-width: 1240px;
  margin: 0 auto;
}
.hl { color: var(--lane-green-deep); }
.lede { font-size: 1.25rem; line-height: 1.5; color: var(--ink-soft); }

.border-notice {
  margin: 1.75rem 0;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--paper-raised);
  padding: 0.9rem 1.1rem;
  box-shadow: var(--shadow-panel);
  max-width: 46ch;
}
.border-notice p { margin: 0; font-size: 1rem; font-style: italic; }
.notice-label {
  display: block;
  line-height: 1.4;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.4rem;
}
.hero-cta { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }

/* ── checkpoint scene ───────────────────────────────────── */
.hero-scene { max-width: 620px; justify-self: end; width: 100%; }
#checkpoint { width: 100%; height: auto; display: block; }
.scene-ground { fill: var(--paper-raised); stroke: var(--ink); stroke-width: 2; }
.lane-label {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.12em;
  fill: var(--ink);
}
.lane-sub { font-family: var(--font-mono); font-size: 12px; line-height: 1.4; fill: var(--ink-soft); }
.lane-line { stroke: var(--line); stroke-width: 2; }
.lane-divider { stroke: var(--ink); stroke-width: 2; stroke-dasharray: 14 10; opacity: 0.55; }

.signal-field { stroke: var(--ink); stroke-width: 2.5; }
.signal-field.is-green { fill: var(--lane-green); }
.signal-field.is-red { fill: var(--stop-red); }
.signal-glyph { stroke: #fff; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; fill: none; }

.token { stroke: var(--ink); stroke-width: 2; }
.token-human { fill: #fff; }
.token-agent { fill: var(--ink); }
.token-text {
  font-family: var(--font-mono);
  line-height: 1.4;
  font-size: 12px;
  text-anchor: middle;
  fill: var(--ink-soft);
}
.token-agent + .token-text, #agentToken .token-text { fill: #fff; }
.walker-human .token-text { fill: var(--ink-soft); }

.gate-arm { fill: var(--stop-red); stroke: var(--ink); stroke-width: 2; }
.gate-pivot { fill: var(--ink); }

.booth-body { fill: var(--paper); stroke: var(--ink); stroke-width: 2; }
.booth-window { fill: var(--signal-amber); stroke: var(--ink); stroke-width: 2; }
.booth-price {
  font-family: var(--font-mono); font-weight: 600; font-size: 16px;
  text-anchor: middle; fill: var(--ink);
}
.booth-label {
  font-family: var(--font-mono);
  line-height: 1.4; font-size: 12px; letter-spacing: 0.14em;
  text-anchor: middle; fill: var(--ink-soft);
}

.chip { fill: var(--stop-red); stroke: var(--ink); stroke-width: 2; }
.chip-ok { fill: var(--lane-green); }
.chip-text {
  font-family: var(--font-mono);
  line-height: 1.4; font-weight: 600; font-size: 12px;
  text-anchor: middle; fill: #fff;
}

.coin { fill: var(--signal-amber); stroke: var(--ink); stroke-width: 2; }
.coin-text {
  font-family: var(--font-mono); font-weight: 600; font-size: 12px;
  text-anchor: middle; fill: var(--ink);
}

.content-card { fill: #fff; stroke: var(--ink); stroke-width: 2; }
.content-line { fill: var(--lane-idle); }

.stamp { fill: none; stroke: var(--ink); stroke-width: 2; opacity: 0.92; }
.stamp-text {
  font-family: var(--font-mono);
  line-height: 1.4; font-weight: 600; font-size: 16px;
  text-anchor: middle; fill: var(--ink);
}
.stamp-sub { font-size: 12px; font-weight: 400; fill: var(--ink-soft); }

.scene-caption { font-size: 1rem; color: var(--ink-soft); margin-top: 0.9rem; }

/* ── sections ───────────────────────────────────────────── */
.section {
  max-width: 1240px;
  margin: 0 auto;
  padding: 4.5rem clamp(1.25rem, 4vw, 3rem);
  border-top: 1px solid var(--line);
}
.section-lede { font-size: 1.25rem; line-height: 1.5; color: var(--ink-soft); max-width: 62ch; }
.section-lede.quiet { font-size: 1rem; }
.zero { color: var(--stop-red); }

/* problem: the two dead ends */
.dead-ends {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.dead-end { border-top: 2px solid var(--ink); padding-top: 1rem; }
.dead-end p { color: var(--ink-soft); margin: 0.5rem 0 0; }
.dead-lane { display: flex; align-items: center; gap: 0.6rem; font-size: 1rem; }
.lane-dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--ink); display: inline-block; }
.lane-dot-red { background: var(--stop-red); }
.lane-dot-idle { background: var(--lane-idle); }

/* flow steps */
.flow-steps { list-style: none; margin: 2.5rem 0 0; padding: 0; }
.flow-step {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 1.25rem;
  align-items: start;
  padding: 1.5rem 0;
  border-top: 2px dashed var(--line);
}
.flow-step:first-child { border-top-style: solid; border-top-color: var(--ink); }
.flow-step p { margin: 0; color: var(--ink-soft); max-width: 62ch; }
.step-signal { padding-top: 2px; }
.mini-signal {
  display: inline-block; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--ink);
}
.mini-red { background: var(--stop-red); }
.mini-amber { background: var(--signal-amber); }
.mini-green { background: var(--lane-green); }
.step-chip {
  font-size: 1rem; font-weight: 600;
  border: 2px solid var(--ink); border-radius: 4px;
  padding: 0.2rem 0.6rem; background: var(--paper-raised);
}

/* rate card */
.rate-card {
  margin-top: 3rem;
  background: var(--paper-raised);
  border: 2px solid var(--ink);
  border-radius: 6px;
  box-shadow: var(--shadow-panel);
  overflow: hidden;
  max-width: 760px;
}
.rate-head {
  text-transform: uppercase;
  line-height: 1.4;
  background: var(--signal-amber);
  border-bottom: 2px solid var(--ink);
  padding: 0.55rem 1.1rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
}
.rate-card table { width: 100%; border-collapse: collapse; }
.rate-card td { padding: 0.85rem 1.1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.rate-card tr:last-child td { border-bottom: 0; }
.rate-card .price { font-weight: 600; font-size: 1.25rem; white-space: nowrap; }
.rule { width: 12%; min-width: 60px; }
.rule-solid { border-bottom: 2px solid var(--ink); }
.rule-dashed { border-bottom: 2px dashed var(--lane-idle); }
.rate-foot { padding: 0.9rem 1.1rem; margin: 0; font-size: 1rem; color: var(--ink-soft); border-top: 1px solid var(--line); }

/* proof: stamps */
.stamps { display: flex; gap: 2rem; flex-wrap: wrap; margin: 2rem 0; }
.stamp-link { text-decoration: none; transform: rotate(-2.5deg); transition: transform 0.15s ease; }
.stamp-link-alt { transform: rotate(1.8deg); }
.stamp-link:hover { transform: rotate(0deg) translateY(-2px); }
.stamp-body {
  display: block;
  border: 2px solid var(--ink);
  border-radius: 4px;
  padding: 0.9rem 1.4rem;
  background: var(--paper-raised);
  opacity: 0.94;
  box-shadow: var(--shadow-panel);
}
.stamp-title { display: block; font-weight: 600; font-size: 1.25rem; color: var(--ink); letter-spacing: 0.04em; }
.stamp-meta { display: block; font-size: 0.75rem; color: var(--ink-soft); margin-top: 0.3rem; letter-spacing: 0.04em; }
.stamp-cta { display: block; font-size: 1rem; color: var(--lane-green-deep); margin-top: 0.5rem; font-weight: 600; }

/* why */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}
.why-item { border-top: 2px solid var(--ink); padding-top: 1rem; }
.why-item p { color: var(--ink-soft); margin: 0; }

/* cta */
.cta-panel {
  background: var(--ink);
  color: var(--paper);
  border-radius: 12px;
  padding: clamp(2rem, 5vw, 4rem);
  text-align: left;
}
.cta-panel h2 { color: var(--paper); }
.cta-panel p { color: #C7CDDB; max-width: 52ch; }
.cta-panel .muted { color: #9AA3B8; }
.cta-panel code { background: rgba(244, 241, 232, 0.12); color: var(--paper); }
.cta-panel .btn { border-color: var(--lane-green-deep); margin: 0.75rem 0 1rem; }

/* footer */
.site-footer {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 1.75rem clamp(1.25rem, 4vw, 3rem);
  border-top: 1px solid var(--line);
  font-size: 1rem;
}
.site-footer .mono { margin-left: auto; }

/* entrance defaults (GSAP enhances; no-JS still readable) */
[data-animate], [data-step] { opacity: 1; }

@media (max-width: 700px) {
  h1 { font-size: 2.4rem; }
  h2 { font-size: 1.9rem; }
}

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .hero-scene { justify-self: start; }
  .site-header nav { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
