/* Ironclad marketing/legal site — plain CSS, no build step (Vercel serves this folder as-is).
   Rebuilt 2026-10-01 from design/website/Web-Home.dc.html. Tokens mirror apps/mobile/theme.ts —
   if you retheme the app, copy the new values here too. */
:root {
  --bg: #0a0a0a;
  --surface: #141414;
  --raised: #1c1c1c;
  --hairline: #262626;
  --hairline-soft: #1f1f1f;
  --border-strong: #333333;
  --text: #f5f5f4;
  --muted: #a1a1a1;
  --faint: #8a8a8a;
  --dim: #848484; /* was #6b6b6b — used for text, so it must clear 4.5:1 (5.36 on --bg) */
  --loss: #ff5a4e;
  --rank-ironclad: #ffe3a3;
  --rank-tempered: #7fa7ff;
  --rank-forged: #ff9a3c;
  --rank-cast: #c9c2b6;
  --rank-ore: #b98e5a;
  --rank-scrap: #8a8a8a;
  --rank-rust: #c76a52; /* was #c0583e — 4.44:1; now clears 4.5:1 on --bg, --surface and --raised */
  --max-width: 1200px;
  --gutter: 20px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
}

.mono { font-family: "Geist Mono", ui-monospace, Menlo, monospace; }
.serif-italic { font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-weight: 400; }

a { color: var(--text); text-decoration: none; }
a:hover { color: #ffffff; }
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
  border-radius: 4px;
}

button { font-family: inherit; cursor: pointer; }

/* Hidden until focused: the first stop for keyboard users, jumping past the nav. */
.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--text);
  color: var(--bg);
  border-radius: 10px;
  font-weight: 600;
}
.skip-link:focus { top: 12px; color: var(--bg); }

/* Visually hidden, still read by screen readers. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.03em; }
p { margin: 0; color: var(--muted); }

.wrap { max-width: var(--max-width); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* ---------- Nav ---------- */
.nav {
  position: relative;
  display: flex;
  align-items: center;
  gap: 32px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 22px var(--gutter);
  border-bottom: 1px solid var(--hairline-soft);
}
.nav .brand {
  font-family: "Geist Mono", monospace;
  font-size: 14px;
  letter-spacing: 0.28em;
  font-weight: 600;
  flex-shrink: 0;
}
.nav-panel { display: flex; align-items: center; gap: 32px; flex-grow: 1; }
.nav-links { display: flex; gap: 32px; flex-grow: 1; font-size: 15px; flex-wrap: wrap; }
.nav-links a { color: var(--muted); }
.nav-links a:hover { color: var(--text); }
.nav-cta {
  height: 44px;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  background: var(--text);
  color: var(--bg) !important;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  flex-shrink: 0;
}
.nav-cta:hover { background: #ffffff; }

.nav-toggle { display: none; }
/* Below 860px the checkbox is the menu toggle — visually hidden but still focusable, so the menu
   opens from the keyboard (Space) as well as by tapping the burger, which is its label. */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  margin-left: auto;
  cursor: pointer;
}
.nav-burger span { width: 22px; height: 2px; background: var(--text); border-radius: 2px; }

@media (max-width: 860px) {
  .nav-panel {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    padding: 24px var(--gutter) 28px;
    background: var(--surface);
    border-bottom: 1px solid var(--hairline);
  }
  .nav-links { flex-direction: column; gap: 18px; }
  .nav-toggle:checked ~ .nav-panel { display: flex; }
  .nav-burger { display: flex; }
  .nav-toggle {
    display: block;
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
    pointer-events: none;
  }
  .nav-toggle:focus-visible + .nav-burger { outline: 2px solid var(--text); outline-offset: 3px; border-radius: 4px; }
}

/* ---------- Hero ---------- */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 64px;
  padding: 72px var(--gutter) 96px;
  max-width: var(--max-width);
  margin: 0 auto;
}
.hero-copy { flex-grow: 1; display: flex; flex-direction: column; gap: 24px; max-width: 640px; }
.hero-quote { font-size: 20px; color: var(--muted); }
.hero-quote .loss { color: var(--loss); }
.hero h1 { font-size: clamp(40px, 6vw, 80px); line-height: 0.98; }
.hero-sub { font-size: 18px; line-height: 1.5; color: var(--muted); max-width: 540px; }
.hero-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding-top: 8px; }
/* The official Apple/Google badge artwork (apps/web/badges) already carries its own colour and
   typography — these links are just a sized, focusable frame around each <img>. The Google PNG
   has more built-in padding baked into the image than Apple's SVG, so it needs a taller box to
   read as the same visual size. */
.store-badge-link { display: inline-flex; border-radius: 10px; }
.store-badge-link img { display: block; height: 54px; width: auto; }
.store-badge-link.google img { height: 74px; }

.phone {
  width: 300px;
  max-width: 80vw;
  flex-shrink: 0;
  box-sizing: border-box;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 44px;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6);
}
.phone-screen {
  background: var(--bg);
  border-radius: 34px;
  padding: 32px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.phone-date { font-size: 13px; color: var(--muted); }
.phone-title { font-weight: 600; font-size: 20px; letter-spacing: -0.03em; }
.phone-ledger { display: flex; flex-direction: column; gap: 8px; padding: 14px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 14px; }
.phone-score { display: flex; align-items: baseline; gap: 8px; }
.phone-score .num { font-weight: 600; font-size: 56px; line-height: 0.9; letter-spacing: -0.05em; }
.phone-score .of { font-size: 15px; color: var(--muted); }
.phone-lost { font-family: "Geist Mono", monospace; font-size: 11px; color: var(--loss); }
.phone-chart-row { display: flex; justify-content: space-between; gap: 8px; white-space: nowrap; padding-top: 8px; border-top: 1px solid var(--hairline); font-size: 11px; color: var(--muted); }
.phone-rows { display: flex; flex-direction: column; gap: 8px; }
.phone-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 40px;
  padding: 0 12px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 12px;
  font-size: 12px;
}
.phone-row .k { font-weight: 600; }
.phone-row .v { font-family: "Geist Mono", monospace; font-size: 11px; color: var(--muted); }

@media (max-width: 900px) {
  .hero { flex-direction: column; padding-top: 48px; }
  .phone { order: 2; width: 260px; }
  .hero-copy { order: 1; max-width: 100%; }
}

/* ---------- Generic section ---------- */
.section { padding: 88px var(--gutter); border-top: 1px solid var(--hairline-soft); }
.section-inner { max-width: var(--max-width); margin: 0 auto; }
.eyebrow { display: block; font-family: "Geist Mono", monospace; font-size: 13px; letter-spacing: 0.16em; color: var(--faint); margin-bottom: 12px; }
.section h2 { font-size: clamp(32px, 4.5vw, 52px); line-height: 1.05; }
.section-head { display: flex; flex-direction: column; gap: 12px; max-width: 720px; margin-bottom: 48px; }
.section-head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; flex-wrap: wrap; margin-bottom: 40px; }
.section-head-row p { max-width: 420px; font-size: 17px; line-height: 1.55; }

/* ---------- How it works ---------- */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card { display: flex; flex-direction: column; gap: 16px; padding: 32px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 20px; }
.card .step-n { font-family: "Instrument Serif", serif; font-size: 48px; line-height: 1; color: var(--dim); }
.card .step-t { font-size: 22px; font-weight: 600; letter-spacing: -0.02em; }
.card .step-d, .card p { font-size: 16px; line-height: 1.55; color: var(--muted); }

@media (max-width: 860px) {
  .steps { grid-template-columns: 1fr; }
}

/* ---------- The score ---------- */
.score-section { display: flex; gap: 64px; align-items: center; flex-wrap: wrap; }
.score-copy { flex: 1 1 420px; display: flex; flex-direction: column; gap: 20px; }
.score-copy p { font-size: 18px; line-height: 1.55; }
.score-card { flex: 1 1 420px; display: flex; flex-direction: column; gap: 16px; padding: 32px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 24px; }
.split-bar { display: flex; height: 14px; gap: 4px; }
.split-bar .productive { width: 60%; background: var(--text); border-radius: 4px; }
.split-bar .health { width: 25%; background: var(--faint); border-radius: 4px; }
.split-bar .habits { width: 15%; background: #5c5c5c; border-radius: 4px; }
.split-grid { display: grid; grid-template-columns: minmax(0, 60fr) minmax(0, 25fr) minmax(84px, 15fr); gap: 12px; }
.split-grid .split-t { font-weight: 600; font-size: 16px; display: block; margin-bottom: 4px; white-space: nowrap; }
.split-grid span.split-d { font-size: 13px; line-height: 1.45; color: var(--muted); display: block; }
.penalty-note { display: flex; align-items: center; gap: 12px; margin-top: 4px; padding: 16px 18px; background: rgba(255, 90, 78, 0.08); border: 1px solid rgba(255, 90, 78, 0.3); border-radius: 14px; }
.penalty-note .amt { font-family: "Geist Mono", monospace; font-size: 17px; font-weight: 600; color: var(--loss); }
.penalty-note span:last-child { font-size: 14px; color: #d4a5a1; }

@media (max-width: 640px) {
  .split-grid { grid-template-columns: 1fr; gap: 16px; }
}

/* ---------- Ranks ---------- */
/* A real line chart (not bars) — each dot sits at its rank's point threshold, connected in one
   ascending line. Below 760px the SVG's own text would scale down to unreadable, so mobile gets a
   plain list of the same numbers instead (same swap-out pattern the old bar chart used). */
.rank-chart-wrap { display: block; position: relative; }
.rank-chart { display: block; width: 100%; height: auto; }
.rank-list-mobile { display: none; }
.rank-list-mobile .rank-item { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 14px; }
.rank-list-mobile .rank-name { font-size: 16px; font-weight: 600; }
.rank-list-mobile .min { font-family: "Geist Mono", monospace; font-size: 14px; font-weight: 600; }
.rank-list-mobile { flex-direction: column; gap: 10px; }

/* Desktop only — one badge centred under each rank name in the chart itself, at the same x
   position (as a % of the chart's own 700-wide viewBox) its name and dot already sit at. Purely
   visual, not interactive. */
.rank-badges-desktop { display: block; position: relative; height: 88px; margin-top: 8px; }
.rank-badges-desktop img { position: absolute; top: 0; transform: translateX(-50%); display: block; }

/* Mobile only — plain, non-interactive badges in a row under the list, matching the chart's
   desktop ones but without needing per-name positioning. */
.rank-badges { display: none; flex-wrap: wrap; justify-content: center; gap: 12px; }
.rank-badge-item { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 10px; }
.rank-badge-item img { display: block; }
/* Forged, Tempered and Ironclad carry a glow / sparkles inside their frame, so their shields read
   smaller at the same size — they're drawn ~25% larger, overlapping their padding so the labels
   stay level with the others. */
.rank-badge-item img.rank-badge-big { margin: -7px 0; }
.rank-badge-item img.rank-badge-bigger { margin: -12px 0; }
.rank-badge-label { font-size: 13px; font-weight: 600; }

@media (max-width: 760px) {
  .rank-chart-wrap { display: none; }
  .rank-list-mobile { display: flex; }
  .rank-badges-desktop { display: none; }
  .rank-badges { display: flex; }
}

/* ---------- Features ---------- */
.features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.feature { display: flex; gap: 20px; padding: 32px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 20px; }
.feature-icon { width: 48px; height: 48px; flex-shrink: 0; border-radius: 12px; background: var(--bg); border: 1px solid var(--hairline); display: flex; align-items: center; justify-content: center; }
.feature-body { display: flex; flex-direction: column; gap: 8px; }
.feature-title { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; }
.feature-tag { font-family: "Geist Mono", monospace; font-size: 11px; letter-spacing: 0.1em; font-weight: 500; color: var(--faint); margin-left: 8px; }
.feature-body p { font-size: 16px; line-height: 1.55; }

@media (max-width: 760px) {
  .features { grid-template-columns: 1fr; }
}

/* ---------- Pricing ---------- */
.pricing-head { display: flex; flex-direction: column; gap: 12px; align-items: center; text-align: center; margin-bottom: 48px; }
.pricing-head p { font-size: 18px; }
.pricing-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; max-width: 900px; margin: 0 auto; }
.plan { display: flex; flex-direction: column; gap: 20px; padding: 32px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 24px; }
.plan.pro { background: var(--raised); border-color: var(--text); }
.plan-head { display: flex; justify-content: space-between; align-items: center; }
.plan-name { font-size: 21px; font-weight: 600; }
.plan-badge { font-family: "Geist Mono", monospace; font-size: 11px; letter-spacing: 0.12em; padding: 5px 10px; background: var(--text); color: var(--bg); border-radius: 999px; font-weight: 600; }
.plan-price { display: flex; align-items: baseline; gap: 10px; }
.plan-price .amt { font-weight: 600; font-size: 44px; letter-spacing: -0.04em; }
.plan-price .per { font-size: 15px; color: var(--muted); }
.plan-note { font-size: 13px; color: var(--muted); margin-top: -8px; }
.plan-features { display: flex; flex-direction: column; gap: 12px; list-style: none; margin: 0; padding: 0; }
.plan-features li { display: flex; gap: 10px; font-size: 15px; color: #d4d4d4; }
.plan.pro .plan-features li { color: var(--text); }
.plan-features svg { flex-shrink: 0; margin-top: 2px; }

@media (max-width: 700px) {
  .pricing-grid { grid-template-columns: 1fr; }
}

/* ---------- FAQ ---------- */
.faq-section { display: flex; gap: 64px; flex-wrap: wrap; }
.faq-intro { flex: 1 1 320px; display: flex; flex-direction: column; gap: 12px; }
.faq-intro p { font-size: 16px; line-height: 1.55; }
.faq-intro a { text-decoration: underline; text-underline-offset: 3px; }
.faq-list { flex: 2 1 480px; display: flex; flex-direction: column; }
.faq-item { border-bottom: 1px solid var(--hairline); }
.faq-item summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 0;
  font-size: 19px;
  font-weight: 600;
  cursor: pointer;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .sign { font-family: "Geist Mono", monospace; font-size: 22px; color: var(--faint); flex-shrink: 0; }
.faq-item summary .sign::after { content: "+"; }
.faq-item[open] summary .sign::after { content: "\2212"; }
.faq-item .faq-answer { font-size: 16px; line-height: 1.6; color: var(--muted); max-width: 640px; padding-bottom: 22px; }

/* ---------- Closing CTA ---------- */
.cta-band {
  margin: 0 var(--gutter);
  padding: 64px var(--gutter);
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}
.cta-band h2 { font-size: clamp(32px, 6vw, 58px); line-height: 1; }
.cta-band p { font-size: 18px; }
.cta-band .hero-actions { justify-content: center; }

/* ---------- Footer ---------- */
.site-footer { max-width: var(--max-width); margin: 96px auto 0; padding: 56px var(--gutter) 40px; border-top: 1px solid var(--hairline-soft); display: flex; flex-direction: column; gap: 40px; }
.footer-top { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.footer-brand { display: flex; flex-direction: column; gap: 12px; max-width: 320px; }
.footer-brand .brand { font-family: "Geist Mono", monospace; font-size: 14px; letter-spacing: 0.28em; font-weight: 600; }
.footer-brand p { font-size: 14px; color: var(--faint); line-height: 1.55; }
.footer-cols { display: flex; gap: 32px; flex-wrap: wrap; }
.footer-col { display: flex; flex-direction: column; gap: 12px; font-size: 14px; min-width: 150px; }
.footer-col .heading { font-family: "Geist Mono", monospace; font-size: 11px; letter-spacing: 0.14em; color: var(--dim); }
.footer-col a { color: var(--muted); }
.footer-col a:hover { color: var(--text); }

/* ---------- Legal / simple pages ---------- */
main.legal { max-width: 720px; margin: 0 auto; padding: 64px var(--gutter) 88px; }
main.legal h1 { font-size: 36px; margin-bottom: 8px; }
main.legal .updated { color: var(--dim); font-size: 13px; margin-bottom: 32px; }
main.legal h2 { font-size: 20px; margin-top: 36px; margin-bottom: 8px; }
main.legal p, main.legal li { color: var(--muted); font-size: 15px; line-height: 1.6; }
main.legal ul { padding-left: 20px; }
main.legal a { text-decoration: underline; text-underline-offset: 3px; }
.legal-placeholder {
  margin: 20px 0;
  padding: 20px;
  border: 1px dashed var(--border-strong);
  border-radius: 12px;
  color: var(--faint);
  font-family: "Geist Mono", monospace;
  font-size: 13px;
}

/* ---------- 404 / press (centered simple pages) ---------- */
main.centered {
  max-width: 560px;
  margin: 0 auto;
  min-height: 60vh;
  padding: 96px var(--gutter);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
  justify-content: center;
}
main.centered h1 { font-size: 40px; }
main.centered p { font-size: 16px; }

@media (max-width: 480px) {
  .hero-actions, .cta-band .hero-actions { flex-direction: column; align-items: stretch; }
  .store-badge-link { justify-content: center; }
}

/* Hero phone: Potential beside the current score, and the chart's two-line legend (matches the
   app's Log hero). */
.phone-potential { font-family: "Geist Mono", monospace; font-size: 12px; color: var(--muted); white-space: nowrap; }
.phone-legend { display: flex; justify-content: center; gap: 16px; font-size: 11px; color: var(--muted); }
.phone-legend span { display: inline-flex; align-items: center; gap: 6px; }
.phone-legend i { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
