/* The Radius landing page. Tokens and primitives mirror map/src/styles.css
   so the marketing page and the app read as one product. */

@font-face {
  font-family: 'Barlow Condensed';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/barlow-condensed-latin-500-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow Condensed';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/barlow-condensed-latin-600-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow Condensed';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/barlow-condensed-latin-700-normal.woff2') format('woff2');
}

:root {
  --surface: #fcfcfb;
  --page: #f9f9f7;
  --ink: #0b0b0b;
  --ink-2: #52514e;
  --muted: #898781;
  --hairline: #e1e0d9;
  --rule: #0b0b0b;
  --blue: #2a78d6;
  --violet: #4a3aa7;
  --accent: #0ca30c;
  --accent-wash: #e2f6e2;
  --accent-ink: #006300;
  --gold: #eda100;
  --display: 'Barlow Condensed', 'Arial Narrow', system-ui, sans-serif;
  --shadow: 6px 6px 0 rgba(11, 11, 11, 0.18);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--page);
}

img { max-width: 100%; display: block; }

.kicker {
  font-family: var(--display);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.muted { color: var(--muted); }
.fine { font-size: 12.5px; line-height: 1.5; }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  line-height: 0.98;
  margin: 8px 0 14px;
  letter-spacing: 0.01em;
}
h1 { font-size: clamp(44px, 7vw, 76px); }
h2 { font-size: clamp(30px, 4.2vw, 44px); }
h3 { font-size: 24px; }

p { margin: 0 0 14px; max-width: 60ch; }

a { color: var(--ink); }

button {
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 0;
}

.link {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  text-decoration: underline;
  color: inherit;
  cursor: pointer;
  text-transform: none;
  letter-spacing: normal;
}

/* Masthead */

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(18px, 5vw, 56px);
  background: var(--surface);
  border-bottom: 4px solid var(--rule);
}

.site-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 30px;
  text-transform: uppercase;
  line-height: 1;
}

.masthead-right { display: flex; align-items: center; gap: 12px; }

.btn-demo {
  display: inline-block;
  font-family: var(--display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--accent);
  color: #fff;
  border: 2px solid var(--accent);
  padding: 8px 16px;
  text-decoration: none;
}
.btn-demo:hover { background: var(--accent-ink); border-color: var(--accent-ink); color: #fff; }

.cta-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 10px;
}

.btn-outline {
  background: var(--surface);
  border: 2px solid var(--rule);
  padding: 8px 16px;
}
.btn-outline:hover { background: var(--ink); color: #fff; }

/* Hero: copy + CTA on the left, the live demo on the right, above the fold */

.hero {
  display: grid;
  grid-template-columns: minmax(340px, 5fr) 6fr;
  grid-template-rows: 1fr auto 1fr;
  grid-template-areas:
    'lead demo'
    'sub demo'
    'cta demo';
  gap: 0 clamp(24px, 4vw, 56px);
  padding: clamp(20px, 3vw, 40px) clamp(18px, 5vw, 56px) clamp(28px, 4vw, 56px);
}

.hero-lead { grid-area: lead; align-self: end; }
.hero > .subhead { grid-area: sub; }
.hero-cta { grid-area: cta; align-self: start; }
.hero-demo { grid-area: demo; align-self: center; }

.subhead { font-size: 18px; color: var(--ink-2); }

.row-shot img, .section-shot img {
  border: 2px solid var(--rule);
  box-shadow: var(--shadow);
}

/* Waitlist form */

.waitlist-slot { margin-top: 22px; max-width: 560px; }
.form-kicker { margin-bottom: 8px; }

.waitlist {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.waitlist input[type='email'], #gate input {
  border: 2px solid var(--rule);
  background: var(--surface);
  padding: 11px 12px;
  font: inherit;
  border-radius: 0;
  min-width: 0;
}

.waitlist button {
  grid-column: 2;
  grid-row: 1;
  background: var(--ink);
  color: #fff;
  border: 2px solid var(--ink);
  padding: 10px 20px;
}
.waitlist button:hover { background: var(--accent-ink); border-color: var(--accent-ink); }
.waitlist button:disabled { opacity: 0.6; cursor: wait; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.waitlist-ok {
  border: 2px solid var(--rule);
  background: var(--accent-wash);
  padding: 16px 18px;
}
.waitlist-ok strong {
  font-family: var(--display);
  font-size: 22px;
  text-transform: uppercase;
  display: block;
  margin-bottom: 4px;
}

.warn {
  border: 2px solid var(--rule);
  background: #fdeaea;
  padding: 8px 12px;
  font-size: 13px;
  margin-top: 8px;
}

/* Stat strip */

.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 2px solid var(--rule);
  border-bottom: 2px solid var(--rule);
  background: var(--surface);
}

.stat {
  padding: 18px 20px;
  border-right: 1px solid var(--hairline);
}
.stat:last-child { border-right: 0; }

.stat .num {
  font-family: var(--display);
  font-weight: 700;
  font-size: 34px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat .lbl {
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-top: 4px;
}

/* Demo */

.row-copy .kicker::after, .closing .kicker::after {
  content: '';
  display: block;
  width: 44px;
  border-top: 2px solid var(--rule);
  margin-top: 6px;
}

.demo-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-bottom: 8px;
}

.market-toggle { display: flex; }
.market-toggle .chip-btn + .chip-btn { border-left: 0; }

.demo-frame {
  position: relative;
  border: 2px solid var(--rule);
  box-shadow: var(--shadow);
  background: var(--surface);
}

#demo-map { height: 540px; }

.demo-chips {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  gap: 8px;
  z-index: 5;
}

.chip-btn {
  font-family: var(--display);
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 2px solid var(--rule);
  background: var(--surface);
  padding: 5px 10px;
}
.chip-btn.on { background: var(--ink); color: #fff; }

.demo-caption { margin-top: 12px; }

/* Demo map markers (mirrors the app's marker language) */

.demo-marker {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--blue);
  border: 2px solid #fcfcfb;
  box-shadow: 0 0 0 1.5px var(--rule);
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.demo-marker:hover, .demo-marker.pinned { background: var(--violet); }

.demo-anchor { cursor: pointer; }

.demo-tip {
  font-family: system-ui, sans-serif;
  font-size: 13px;
  line-height: 1.45;
}
.demo-tip .tip-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  text-transform: uppercase;
}
.demo-tip .tip-mins { color: var(--accent-ink); font-weight: 600; }

/* Pinned-popup header: type icon beside the title */
.demo-tip .tip-head {
  display: flex;
  align-items: center;
  gap: 6px;
}
.demo-tip .tip-icon { flex: none; }

/* Band picker inside pinned popups (mirrors the app's band-row) */

.band-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 7px;
}

.band-label {
  font-family: var(--display);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-right: 2px;
}

.band-btn {
  font-family: var(--display);
  font-weight: 700;
  font-size: 12.5px;
  line-height: 1;
  padding: 3px 8px;
  border: 1.5px solid var(--rule);
  border-radius: 999px;
  background: var(--surface);
  letter-spacing: normal;
  text-transform: none;
}

.band-btn.on {
  background: #0039a6;
  border-color: #0039a6;
  color: #fff;
}

/* Subway route bullets (mirrors the app's rt-bullet) */

.rt-row {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 3px;
  align-items: center;
  margin-top: 3px;
}

.rt-bullet {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 15px;
  height: 15px;
  padding: 0 2px;
  border-radius: 8px;
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

.mapboxgl-popup-content {
  border: 2px solid var(--rule);
  border-radius: 0;
  box-shadow: 4px 4px 0 rgba(11, 11, 11, 0.18);
  padding: 10px 12px;
}

.mapboxgl-popup-close-button {
  font-size: 18px;
  line-height: 1;
  padding: 2px 6px;
  right: 0;
  top: 0;
}

/* Alternating feature rows */

.row {
  display: grid;
  grid-template-columns: 5fr 6fr;
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  padding: clamp(36px, 5vw, 64px) clamp(18px, 5vw, 56px);
  border-top: 1px solid var(--hairline);
}

.row.flip .row-copy { order: 2; }
.row.flip .row-shot { order: 1; }

.row-shot.tall { max-width: 420px; justify-self: center; }

/* Closing */

.closing {
  border-top: 2px solid var(--rule);
  background: var(--surface);
  padding: clamp(40px, 6vw, 72px) clamp(18px, 5vw, 56px);
}

/* Footer */

footer {
  border-top: 4px solid var(--rule);
  padding: 22px clamp(18px, 5vw, 56px) 40px;
}

.footer-brand {
  font-family: var(--display);
  font-weight: 700;
  font-size: 20px;
  text-transform: uppercase;
  margin-bottom: 6px;
}

/* Gate dialog */

#gate {
  border: 2px solid var(--rule);
  border-radius: 0;
  box-shadow: var(--shadow);
  background: var(--surface);
  padding: 22px 24px;
  max-width: 340px;
  width: calc(100vw - 40px);
}
#gate::backdrop { background: rgba(11, 11, 11, 0.45); }
#gate h3 { margin: 6px 0 12px; }
#gate input { width: 100%; margin-bottom: 12px; }
.gate-actions { display: flex; justify-content: space-between; gap: 10px; }
.gate-actions button[type='submit'] {
  background: var(--ink);
  color: #fff;
  border: 2px solid var(--ink);
  padding: 8px 18px;
}

/* Responsive */

@media (max-width: 760px) {
  .hero, .row { grid-template-columns: 1fr; }
  /* Demo right under the headline; the pitch and email CTA follow it */
  .hero {
    grid-template-rows: none;
    grid-template-areas:
      'lead'
      'demo'
      'sub'
      'cta';
  }
  .hero > .subhead { margin-top: 18px; }
  .row.flip .row-copy { order: 1; }
  .row.flip .row-shot { order: 2; }
  .stat-strip { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2n) { border-right: 0; }
  .stat:nth-child(-n + 2) { border-bottom: 1px solid var(--hairline); }
  #demo-map { height: 380px; }
  .masthead .btn-demo { display: none; } /* the hero CTA is right below */
  .waitlist { grid-template-columns: 1fr; }
  .waitlist button { grid-column: 1; grid-row: auto; }
}
