/*
 * The public website's stylesheet. One file, no build step, no framework.
 *
 * Written for the least technical person who will ever read it, on the
 * oldest phone and the slowest connection we expect to meet: body type at
 * the large end of the scale, nothing that depends on hover, nothing that
 * moves, and no request to any third party for the page itself — not even
 * a font. Inter is used where it is installed; otherwise the system face,
 * which costs no bytes and is what these phones render best anyway. The
 * one exception is the map demo, which is Google's, and is loaded only
 * when a key is present.
 *
 * The shape is a product page, not a document: one statement per band,
 * generous space instead of borders, and the map as the product shot.
 * Colours and sizes come from tokens.css, which mirrors the dashboard.
 */
@import url('tokens.css');

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

html {
  font-family: Inter, -apple-system, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.55;
  color: var(--color-ink);
  background: #fff;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  font-size: var(--text-lg);
}

h1,
h2,
h3 {
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1,
.statement {
  font-size: var(--text-3xl);
  letter-spacing: -0.02em;
}

h2 {
  font-size: var(--text-3xl);
}

h3 {
  font-size: var(--text-2xl);
}

@media (min-width: 64rem) {
  h1,
  .statement {
    font-size: var(--text-display);
  }
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--color-blue-action);
  text-underline-offset: 0.15em;
}

a:hover {
  color: var(--color-blue-hover);
}

:focus-visible {
  outline: 3px solid var(--color-blue-action);
  outline-offset: 3px;
}

.on-navy :focus-visible {
  outline-color: var(--color-focus-on-navy);
}

/* Layout ------------------------------------------------------------------ */

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

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

.band {
  padding-block: 4.5rem;
}

@media (min-width: 64rem) {
  .band {
    padding-block: 7rem;
  }
}

.band-paper {
  background: var(--color-paper);
}

.band-navy {
  background: var(--color-navy);
  color: var(--color-on-navy);
}

.band-navy h2,
.band-navy h3 {
  color: #fff;
}

.centered {
  text-align: center;
}

.centered p {
  margin-inline: auto;
}

.lede {
  font-size: var(--text-lg);
  color: var(--color-slate-700);
  max-width: 54ch;
}

@media (min-width: 64rem) {
  .lede {
    font-size: var(--text-2xl);
    line-height: 1.4;
  }
}

.band-navy .lede {
  color: var(--color-on-navy);
}

.eyebrow {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-slate-500);
  margin: 0 0 1rem;
}

.band-navy .eyebrow {
  color: var(--color-on-navy-dim);
}

/* Header ------------------------------------------------------------------ */

.skip {
  position: absolute;
  left: -999px;
  top: 0;
  padding: 0.75rem 1rem;
  background: var(--color-navy);
  color: #fff;
  z-index: 10;
}

.skip:focus {
  left: 1rem;
  top: 1rem;
}

.site-header {
  background: var(--color-navy);
  color: var(--color-on-navy);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.5rem;
  min-height: 3.5rem;
  padding-block: 0.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.16em;
  font-size: var(--text-base);
}

.brand svg {
  width: 26px;
  height: 26px;
}

.site-nav {
  margin-left: auto;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: inline-block;
  padding: 0.6rem 0.7rem;
  color: var(--color-on-navy);
  text-decoration: none;
  font-size: var(--text-base);
  font-weight: 500;
  border-radius: 6px;
}

.site-nav a:hover {
  color: #fff;
}

/* Hero -------------------------------------------------------------------- */

.hero {
  padding-block: 5rem 4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (min-width: 64rem) {
  .hero {
    padding-block: 7rem 5.5rem;
  }
}

.hero h1 {
  color: #fff;
  max-width: 16ch;
  margin-inline: auto;
}

.hero .lede {
  max-width: 40ch;
  margin: 1.25rem auto 0;
}

.hero .actions {
  justify-content: center;
  margin-top: 2.25rem;
}

/* Buttons — primary is the one interactive colour; 44px minimum target. */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-size: var(--text-base);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--color-blue-action);
  color: #fff;
}

.btn-primary:hover {
  background: var(--color-blue-hover);
  color: #fff;
}

.btn-primary:active {
  background: var(--color-blue-active);
}

.btn-secondary {
  background: #fff;
  border-color: var(--color-slate-300);
  color: var(--color-ink);
}

.btn-secondary:hover {
  color: var(--color-ink);
  border-color: var(--color-slate-500);
}

.band-navy .btn-secondary {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.actions .note {
  flex-basis: 100%;
  margin: 0.75rem 0 0;
  color: var(--color-on-navy-dim);
  font-size: var(--text-base);
}

/* Map demo — the product shot ---------------------------------------------- */

.demo {
  background: var(--color-navy);
  padding-bottom: 0;
}

.demo-frame {
  position: relative;
  height: min(72vh, 40rem);
  min-height: 22rem;
  background: var(--color-slate-100);
}

#map {
  position: absolute;
  inset: 0;
}

.demo-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 2rem;
  text-align: center;
  color: var(--color-slate-700);
  background:
    linear-gradient(0deg, rgba(15, 23, 42, 0.05) 1px, transparent 1px) 0 0 / 100% 3rem,
    linear-gradient(90deg, rgba(15, 23, 42, 0.05) 1px, transparent 1px) 0 0 / 3rem 100%,
    var(--color-slate-100);
}

.demo-frame.is-live .demo-fallback {
  display: none;
}

.demo-caption {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  max-width: min(100% - 2rem, 22rem);
  background: #fff;
  border: 1px solid var(--color-slate-300);
  border-radius: 12px;
  padding: 1rem 1.125rem;
  font-size: var(--text-base);
  box-shadow: 0 8px 24px rgba(10, 37, 64, 0.12);
}

.demo-caption .eyebrow {
  margin-bottom: 0.25rem;
}

.demo-caption p {
  margin: 0 0 0.75rem;
  color: var(--color-slate-700);
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: var(--text-sm);
  color: var(--color-slate-700);
}

.legend li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.legend i {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  border: 1.5px solid #fff;
  box-shadow: 0 0 0 1px var(--color-slate-300);
}

.example {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: var(--color-slate-100);
  color: var(--color-slate-700);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-left: 0.5rem;
  vertical-align: middle;
}

/* Feature bands ------------------------------------------------------------ */

.feature .statement {
  max-width: 18ch;
  margin-inline: auto;
}

.feature .lede {
  margin-top: 1rem;
}

.mock {
  margin: 2.5rem auto 0;
  max-width: 24rem;
  text-align: left;
}

.soon {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  background: var(--color-slate-100);
  color: var(--color-slate-700);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  vertical-align: middle;
}

.band-navy .soon {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

/* A report card as the app shows it. Colours here are the STYLE-GUIDE
   severity table, for illustration only — real reports carry their own. */
.report-card {
  background: #fff;
  border: 1px solid var(--color-slate-300);
  border-radius: 16px;
  padding: 1.25rem;
  font-size: var(--text-base);
}

.report-card .title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.chip {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-right: 0.4rem;
}

.report-card .meta {
  margin: 0.75rem 0 0;
  color: var(--color-slate-500);
  font-size: var(--text-sm);
}

.mono {
  font-family: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-variant-numeric: tabular-nums;
}

/* The activity card from the app's map. */
.stats-card {
  background: #fff;
  border: 1px solid var(--color-slate-300);
  border-radius: 16px;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: var(--text-base);
}

.stats-card .dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: var(--color-ok);
  flex: none;
}

.stats-card strong {
  font-weight: 600;
}

.stats-card .count {
  margin-left: auto;
  color: var(--color-slate-500);
}

.stats-card .count b {
  color: var(--color-ink);
  font-weight: 700;
}

/* Promise band ------------------------------------------------------------- */

.promise-grid {
  display: grid;
  gap: 2rem;
  list-style: none;
  margin: 3rem 0 0;
  padding: 0;
}

@media (min-width: 48rem) {
  .promise-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
  }
}

.promise-grid h3 {
  font-size: var(--text-2xl);
  margin-bottom: 0.5rem;
}

.promise-grid p {
  margin: 0;
  color: var(--color-on-navy);
}

/* Privacy grid ------------------------------------------------------------- */

.claims {
  display: grid;
  gap: 1.25rem;
  list-style: none;
  margin: 3rem 0 0;
  padding: 0;
}

@media (min-width: 48rem) {
  .claims {
    grid-template-columns: repeat(2, 1fr);
  }
}

.claim {
  background: #fff;
  border-radius: 16px;
  padding: 1.75rem;
  font-size: var(--text-base);
}

.band-paper .claim {
  border: 1px solid var(--color-slate-300);
}

.claim h3 {
  font-size: var(--text-lg);
  margin-bottom: 0.5rem;
}

.claim p {
  margin: 0;
  color: var(--color-slate-700);
}

/* Two-column band (about + contact) ---------------------------------------- */

.split {
  display: grid;
  gap: 3rem;
}

@media (min-width: 64rem) {
  .split {
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: start;
  }
}

/* Forms ------------------------------------------------------------------- */

.form {
  display: grid;
  gap: 1rem;
}

.field {
  display: grid;
  gap: 0.375rem;
}

label {
  font-weight: 500;
}

.input {
  width: 100%;
  font: inherit;
  font-size: var(--text-base);
  color: var(--color-ink);
  background: #fff;
  border: 1px solid var(--color-slate-300);
  border-radius: 10px;
  padding: 0.75rem 0.875rem;
  min-height: 3rem;
}

.input:focus {
  border-color: var(--color-blue-action);
}

textarea.input {
  min-height: 9rem;
  resize: vertical;
}

.hint {
  color: var(--color-slate-500);
  font-size: var(--text-sm);
  margin: 0;
}

/* The honeypot: off-screen for people, present for bots. Never display:none
   — some bots skip hidden fields, and an off-screen one catches more. */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Footer ------------------------------------------------------------------ */

.site-footer {
  background: var(--color-navy);
  color: var(--color-on-navy-dim);
  padding-block: 2.5rem;
  font-size: var(--text-base);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer a {
  color: var(--color-on-navy);
}

.site-footer ul {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.site-footer p {
  margin: 0;
}

/* Long-form pages (privacy, terms) ---------------------------------------- */

.prose h1 {
  font-size: var(--text-3xl);
}

.prose h2 {
  font-size: var(--text-2xl);
  margin-top: 2.5rem;
}

.prose h3 {
  font-size: var(--text-lg);
  margin-top: 1.75rem;
}

.prose p,
.prose li {
  max-width: 62ch;
}

.prose ul {
  padding-left: 1.25rem;
}

.prose li {
  margin-bottom: 0.5rem;
}

.todo {
  background: #fff8e6;
  border: 1px solid var(--color-warn);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--color-slate-700);
  font-size: var(--text-base);
}

dl.facts {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 0.5rem 1.5rem;
  margin: 1rem 0;
}

dl.facts dt {
  font-weight: 600;
}

dl.facts dd {
  margin: 0;
}

@media (max-width: 40rem) {
  dl.facts {
    grid-template-columns: 1fr;
    gap: 0.125rem;
  }

  dl.facts dd {
    margin-bottom: 0.75rem;
  }
}
