/* Namehold public pre-launch site
   Dark-first launch page for prospective token holders, with a light register available.
   Layout: one column, max 1120px, hairlines not cards; the ledger motif (mono, tabular figures) carries the brand.
   Type: Archivo (display, UI) · Newsreader (long-form) · IBM Plex Mono (names, figures, addresses). */

:root {
  --bg: #0e1014; --surface: #151821; --surface-2: #1d212b;
  --fg: #eef0f4; --fg-2: #b9bec9; --muted: #8b91a1;
  --line: #2a2f3a; --line-2: #222733;
  --accent: #6aa3f5; --accent-ink: #0b1220; --accent-soft: #182642;
  --token: #f0894f; --token-soft: #3a2416;
  --good: #3fc77a; --warn: #f2b84b; --crit: #ef6b6b;
  --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s-gray: #4a4f5c;
  --grid: #2b2f3a; --axis: #3a3f4b;
  --display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --body: "Newsreader", Georgia, "Times New Roman", serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Menlo, Consolas, monospace;
  --radius: 4px; --wrap: 1120px; --gutter: 20px;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #f3f4f6; --surface: #ffffff; --surface-2: #e9ebef;
  --fg: #141720; --fg-2: #4b5160; --muted: #747a8a;
  --line: #d5d8df; --line-2: #e5e7ec;
  --accent: #1d5bd6; --accent-ink: #ffffff; --accent-soft: #e3ecfb;
  --token: #b84a18; --token-soft: #fbe9df;
  --good: #0a7a3a; --warn: #9a5b00; --crit: #b3261e;
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100; --s-gray: #b9bdc7;
  --grid: #e4e6eb; --axis: #c3c6cf;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--display); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
img, svg { max-width: 100%; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.1; text-wrap: balance; margin: 0; letter-spacing: -0.015em; }
h1 { font-size: clamp(2.2rem, 1.3rem + 3.6vw, 4rem); font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem); font-weight: 700; }
h3 { font-size: 1.12rem; font-weight: 700; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.eyebrow.token { color: var(--token); }
.dn { font-family: var(--mono); font-size: 0.92em; background: var(--surface-2); padding: 0.05em 0.4em; border-radius: var(--radius); white-space: nowrap; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.src { font-size: 0.76rem; color: var(--muted); }
.src a { color: inherit; }

/* Top bar */
.topbar { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; gap: 1rem; min-height: 60px; }
.brand { display: flex; align-items: baseline; gap: 0.6rem; text-decoration: none; color: var(--fg); margin-right: auto; }
.brand .mark { font-weight: 800; font-size: 1.25rem; letter-spacing: -0.035em; }
.brand .tag { font-family: var(--mono); font-size: 0.68rem; color: var(--muted); }
.nav { display: flex; gap: 0.1rem; }
.nav a { font-size: 0.86rem; font-weight: 500; color: var(--fg-2); text-decoration: none; padding: 0.4rem 0.65rem; border-radius: var(--radius); }
.nav a:hover { background: var(--surface-2); color: var(--fg); }
.nav a[aria-current="page"] { color: var(--fg); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; font: inherit; font-size: 0.9rem; font-weight: 600; padding: 0.65rem 1.1rem; border-radius: var(--radius); border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.06); }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.sm { font-size: 0.8rem; padding: 0.4rem 0.75rem; }
.theme-btn, .menu-btn { font: inherit; font-size: 0.8rem; font-weight: 600; color: var(--fg-2); background: transparent; border: 1px solid var(--line); border-radius: var(--radius); padding: 0.4rem 0.65rem; cursor: pointer; }
.theme-btn:hover, .menu-btn:hover { background: var(--surface-2); color: var(--fg); }
.menu-btn { display: none; }
@media (max-width: 900px) {
  .menu-btn { display: inline-block; }
  .nav { display: none; width: 100%; flex-direction: column; padding-block: 0.4rem 0.8rem; border-top: 1px solid var(--line-2); }
  .nav.open { display: flex; }
  .topbar .wrap { flex-wrap: wrap; }
  .topbar .btn { display: none; }
  .brand .tag { display: none; }
}

/* Pre-launch notice */
.notice { background: var(--surface-2); border-bottom: 1px solid var(--line); font-size: 0.8rem; color: var(--fg-2); }
.notice .wrap { padding-block: 0.55rem; line-height: 1.45; }
.notice a { margin-left: 0.3rem; }
.notice b { color: var(--fg); font-weight: 600; }

/* Hero */
.hero { padding-block: 4.5rem 3rem; border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
.hero .eyebrow { margin-bottom: 1.1rem; }
.hero h1 { max-width: 16ch; }
.hero .lede { font-family: var(--body); font-size: clamp(1.15rem, 1rem + 0.6vw, 1.4rem); line-height: 1.5; color: var(--fg-2); max-width: 58ch; margin-top: 1.3rem; }
.hero .lede b { color: var(--fg); font-weight: 600; }
.hero .cta { display: flex; gap: 0.7rem; flex-wrap: wrap; margin-top: 1.8rem; }
.hero .fine { margin-top: 1rem; font-size: 0.78rem; color: var(--muted); max-width: 60ch; }

/* Signals strip */
.signals { border-bottom: 1px solid var(--line); background: var(--surface); }
.signals .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0; }
.signal { padding: 1rem 1.1rem 1rem 0; border-right: 1px solid var(--line-2); margin-right: 1.1rem; min-width: 0; }
.signal:last-child { border-right: 0; margin-right: 0; }
.signal .v { font-size: clamp(1.4rem, 1.1rem + 1vw, 1.9rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.signal .v.token { color: var(--token); }
.signal .l { font-size: 0.8rem; color: var(--fg-2); margin-top: 0.3rem; line-height: 1.35; }
.signal .s { font-family: var(--mono); font-size: 0.66rem; color: var(--muted); margin-top: 0.35rem; }
@media (max-width: 700px) { .signal { border-right: 0; border-bottom: 1px solid var(--line-2); margin-right: 0; padding-right: 0; } .signal:last-child { border-bottom: 0; } }

/* Sections */
.section { padding-block: 3.4rem; border-bottom: 1px solid var(--line-2); }
.section:last-of-type { border-bottom: 0; }
.section-head { display: grid; gap: 0.6rem; margin-bottom: 1.8rem; max-width: 72ch; }
.section-head .intro { font-family: var(--body); font-size: 1.14rem; line-height: 1.55; color: var(--fg-2); }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2.2rem; align-items: start; }
.cols-wide { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 2.2rem; align-items: start; }
.three-col { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.6rem; }
.two-col > *, .cols-wide > *, .three-col > * { min-width: 0; }
@media (max-width: 860px) { .two-col, .cols-wide, .three-col { grid-template-columns: minmax(0, 1fr); } }
.prose { font-family: var(--body); font-size: 1.1rem; line-height: 1.62; max-width: 68ch; }
.prose p + p { margin-top: 1rem; }
.prose ul { padding-left: 1.2rem; margin: 0.6rem 0 0; }
.prose li + li { margin-top: 0.35rem; }
.prose b { font-weight: 600; }
.prose h3 { font-family: var(--display); margin: 1.6rem 0 0.5rem; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.4rem; counter-reset: step; }
.step { padding-top: 0.8rem; border-top: 2px solid var(--line); min-width: 0; }
.step::before { counter-increment: step; content: counter(step, decimal-leading-zero); font-family: var(--mono); font-size: 0.75rem; color: var(--muted); display: block; margin-bottom: 0.35rem; }
.step h3 { font-size: 1rem; margin-bottom: 0.35rem; }
.step p { font-family: var(--body); font-size: 1rem; line-height: 1.5; color: var(--fg-2); }

/* KPI tiles and ledgers */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.kpi { padding: 1rem 1.1rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); min-width: 0; }
.kpi .v { font-size: clamp(1.4rem, 1.1rem + 1vw, 1.9rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.kpi .v.ph { color: var(--muted); font-weight: 500; }
.kpi .l { font-size: 0.82rem; color: var(--fg-2); margin-top: 0.35rem; line-height: 1.35; }
.kpi .s { font-family: var(--mono); font-size: 0.66rem; color: var(--muted); margin-top: 0.4rem; }
.table-scroll { overflow-x: auto; max-width: 100%; }
table.ledger { width: 100%; border-collapse: collapse; font-size: 0.86rem; line-height: 1.4; background: var(--surface); }
table.ledger th, table.ledger td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--line-2); vertical-align: top; }
table.ledger th { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); font-weight: 600; border-bottom: 1px solid var(--line); }
table.ledger td.r, table.ledger th.r { text-align: right; font-variant-numeric: tabular-nums; }
table.ledger td.mono { font-family: var(--mono); font-size: 0.82rem; }
table.ledger caption { caption-side: bottom; text-align: left; font-size: 0.76rem; color: var(--muted); padding-top: 0.5rem; }
.ph { color: var(--muted); }
.pill { display: inline-block; font-size: 0.68rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; padding: 0.15rem 0.5rem; border-radius: 999px; border: 1px solid var(--line); color: var(--fg-2); white-space: nowrap; line-height: 1.4; }
.pill.token { color: var(--token); border-color: color-mix(in srgb, var(--token) 45%, transparent); }
.pill.accent { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.pill.good { color: var(--good); border-color: color-mix(in srgb, var(--good) 40%, transparent); }
.pill.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }

/* Callouts */
.callout { border: 1px solid var(--line); background: var(--surface); padding: 1.2rem 1.3rem; border-radius: var(--radius); }
.callout .eyebrow { margin-bottom: 0.5rem; }
.callout p, .callout li { font-family: var(--body); font-size: 1.04rem; line-height: 1.55; }
.callout ul { margin: 0.5rem 0 0; padding-left: 1.1rem; }
.callout li + li { margin-top: 0.35rem; }
.callout.token { border-color: color-mix(in srgb, var(--token) 40%, var(--line)); }
.callout.draft { border-style: dashed; }
.callout.draft .eyebrow { color: var(--warn); }

/* Charts */
.chart { margin: 0; border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); }
.chart-head { padding: 0.9rem 1.1rem 0.4rem; }
.chart-head h3 { font-size: 0.98rem; }
.chart-head .sub { font-size: 0.8rem; color: var(--muted); margin-top: 0.2rem; }
.chart-body { position: relative; padding: 0.4rem 1.1rem 0.6rem; min-width: 0; }
.chart-body svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart svg text { font-family: var(--display); font-size: 12px; fill: var(--muted); }
.chart svg .lbl { fill: var(--fg-2); }
.chart svg .lbl-strong { fill: var(--fg); font-weight: 600; }
.chart-foot { display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 0.4rem 1.1rem 0.8rem; font-size: 0.76rem; color: var(--muted); flex-wrap: wrap; }
.chart-foot a { color: inherit; }
.chart-tools button { font: inherit; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--fg-2); background: transparent; border: 1px solid var(--line); border-radius: var(--radius); padding: 0.2rem 0.5rem; cursor: pointer; }
.chart-tip { position: absolute; pointer-events: none; background: var(--fg); color: var(--bg); font-size: 0.76rem; line-height: 1.35; padding: 0.4rem 0.55rem; border-radius: var(--radius); white-space: nowrap; transform: translate(-50%, calc(-100% - 10px)); opacity: 0; transition: opacity 0.1s; z-index: 5; }
.chart-tip.on { opacity: 1; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; padding: 0.2rem 1.1rem; font-size: 0.78rem; color: var(--fg-2); }
.chart-legend span { display: inline-flex; align-items: center; gap: 0.4rem; }
.chart-legend i { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
table.chart-table { width: 100%; border-collapse: collapse; font-size: 0.82rem; margin: 0.2rem 0 0.6rem; }
table.chart-table th, table.chart-table td { text-align: left; padding: 0.35rem 1.1rem; border-top: 1px solid var(--line-2); }
table.chart-table th { font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
table.chart-table td.r, table.chart-table th.r { text-align: right; font-variant-numeric: tabular-nums; }

/* Diagram */
.diagram { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 1rem; overflow-x: auto; }
.diagram svg { display: block; min-width: 640px; width: 100%; height: auto; }
.diagram svg text { font-family: var(--display); font-size: 12px; fill: var(--fg); }
.diagram svg .t-muted { fill: var(--muted); font-size: 11px; }
.diagram svg .t-mono { font-family: var(--mono); font-size: 11px; }
.diagram svg .t-strong { font-weight: 700; }
.diagram svg .box { fill: var(--surface-2); stroke: var(--line); }
.diagram svg .box-accent { fill: var(--accent-soft); stroke: var(--accent); }
.diagram svg .box-token { fill: var(--token-soft); stroke: var(--token); }
.diagram svg .arrow { stroke: var(--fg-2); fill: none; stroke-width: 1.5; }
.diagram svg .arrow-token { stroke: var(--token); }
.diagram svg .arrow-accent { stroke: var(--accent); }
.diagram svg .head { fill: var(--fg-2); }
.diagram svg .head-token { fill: var(--token); }
.diagram svg .head-accent { fill: var(--accent); }
.diagram-cap { font-size: 0.78rem; color: var(--muted); margin-top: 0.6rem; }

/* Definition rows */
.defs { display: grid; grid-template-columns: minmax(0, 210px) minmax(0, 1fr); gap: 0.7rem 1.4rem; }
.defs dt { font-weight: 600; }
.defs dd { margin: 0; color: var(--fg-2); font-family: var(--body); font-size: 1.04rem; line-height: 1.5; }
@media (max-width: 640px) { .defs { grid-template-columns: minmax(0, 1fr); gap: 0.2rem 0; } .defs dd { margin-bottom: 0.7rem; } }

/* Roadmap */
.timeline { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; }
.phase { border-top: 2px solid var(--accent); padding-top: 0.7rem; min-width: 0; }
.phase.token { border-top-color: var(--token); }
.phase.now { border-top-color: var(--good); }
.phase .when { font-family: var(--mono); font-size: 0.72rem; color: var(--muted); }
.phase h3 { font-size: 1rem; margin: 0.25rem 0 0.4rem; }
.phase ul { margin: 0; padding-left: 1.1rem; font-size: 0.92rem; color: var(--fg-2); line-height: 1.5; }
.phase li + li { margin-top: 0.25rem; }

/* FAQ */
.faq details { border-top: 1px solid var(--line); padding: 0.9rem 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 600; font-size: 1rem; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; }
.faq details[open] summary::after { content: "–"; }
.faq .a { font-family: var(--body); font-size: 1.04rem; line-height: 1.55; color: var(--fg-2); margin-top: 0.6rem; max-width: 70ch; }

/* Waitlist */
.waitlist { border: 1px solid var(--line); background: var(--surface); border-radius: 6px; padding: 1.6rem; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 1.6rem; align-items: center; }
@media (max-width: 800px) { .waitlist { grid-template-columns: minmax(0, 1fr); } }
.waitlist h2 { font-size: 1.5rem; }
.waitlist p { font-family: var(--body); font-size: 1.05rem; color: var(--fg-2); margin-top: 0.6rem; line-height: 1.5; }
.waitlist form { display: grid; gap: 0.7rem; }
.waitlist label { font-size: 0.8rem; font-weight: 600; color: var(--fg-2); display: grid; gap: 0.3rem; }
.waitlist input, .waitlist select { font: inherit; font-size: 0.95rem; padding: 0.65rem 0.8rem; border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg); color: var(--fg); width: 100%; }
.waitlist input:focus, .waitlist select:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.waitlist .row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.6rem; align-items: end; }
@media (max-width: 480px) { .waitlist .row { grid-template-columns: minmax(0, 1fr); } }
.waitlist .msg { font-size: 0.85rem; min-height: 1.2em; color: var(--fg-2); }
.waitlist .msg.ok { color: var(--good); }
.waitlist .msg.warn { color: var(--warn); }
.waitlist .fine { font-size: 0.74rem; color: var(--muted); line-height: 1.45; }

/* Footer */
.footer { padding-block: 2.2rem 3rem; border-top: 1px solid var(--line); font-size: 0.8rem; color: var(--muted); }
.footer .wrap { display: grid; gap: 0.6rem; }
.footer .links { display: flex; gap: 1rem; flex-wrap: wrap; }
.footer a { color: inherit; }
.mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 1.6rem; } .mt-3 { margin-top: 2.4rem; }
.stack { display: grid; gap: 1.4rem; }
[hidden] { display: none !important; }
