/* ==========================================================================
   BitcoinAI — design system
   Palette: graphite ground, bone text, single brass accent.
   Type: Archivo (variable width) for voice, IBM Plex Mono for data.
   ========================================================================== */

:root {
  /* ground */
  --void: #0a0908;
  --ground: #0d0c0b;
  --surface: #131110;
  --surface-2: #191614;
  --line: rgba(236, 231, 223, 0.11);
  --line-strong: rgba(236, 231, 223, 0.2);

  /* ink */
  --text: #ece7df;
  --text-dim: #a49d93;
  --text-faint: #8a837a;

  /* accent */
  --brass: #c2872c;
  --brass-hi: #e3b164;
  --brass-wash: rgba(194, 135, 44, 0.09);

  /* type */
  --sans: "Archivo", "Helvetica Neue", Helvetica, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* rhythm */
  --shell: 1240px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --band-y: clamp(5rem, 11vh, 9.5rem);

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font-family: var(--sans);
  font-size: clamp(1rem, 0.96rem + 0.18vw, 1.075rem);
  line-height: 1.7;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Atmosphere: two warm pools of light, a surveyor's grid, and grain.
   All fixed and inert so nothing repaints while the page scrolls. */
body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

body::before {
  background:
    radial-gradient(60rem 40rem at 78% -8%, rgba(194, 135, 44, 0.16), transparent 62%),
    radial-gradient(48rem 34rem at 4% 42%, rgba(139, 92, 30, 0.08), transparent 60%);
}

body::after {
  background-image:
    linear-gradient(rgba(236, 231, 223, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(236, 231, 223, 0.028) 1px, transparent 1px),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.28'/%3E%3C/svg%3E");
  background-size: 88px 88px, 88px 88px, 140px 140px;
  mask-image: linear-gradient(to bottom, #000 0, rgba(0, 0, 0, 0.55) 45%, transparent 92%);
  opacity: 0.7;
}

main,
.masthead,
.footer { position: relative; z-index: 1; }

/* --------------------------------------------------------------- primitives */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

h1, h2, h3 {
  margin: 0;
  font-weight: 700;
  font-stretch: 116%;
  letter-spacing: -0.028em;
  line-height: 1.03;
  text-wrap: balance;
}

h1 { font-size: clamp(2.75rem, 6.6vw, 5.5rem); }
h2 { font-size: clamp(1.85rem, 3.5vw, 3rem); }
h3 {
  font-size: 1.0625rem;
  font-stretch: 108%;
  letter-spacing: -0.012em;
  line-height: 1.3;
}

p { margin: 0; }

a { color: inherit; text-decoration: none; }

em {
  font-style: normal;
  color: var(--brass-hi);
}

:focus-visible {
  outline: 2px solid var(--brass-hi);
  outline-offset: 3px;
  border-radius: 2px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: absolute;
  top: -100%;
  left: var(--gutter);
  z-index: 60;
  padding: 0.75rem 1.15rem;
  background: var(--brass);
  color: #100c05;
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.skip:focus { top: 0.75rem; }

/* mono metadata label used across sections */
.index,
.footer__label,
.targets__heading {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--brass-hi);
}

.button {
  --btn-bg: transparent;
  --btn-fg: var(--text);
  --btn-line: var(--line-strong);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.4rem;
  border: 1px solid var(--btn-line);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
              border-color 0.3s var(--ease), transform 0.3s var(--ease);
}

.button--solid {
  --btn-bg: var(--brass);
  --btn-fg: #120d05;
  --btn-line: var(--brass);
}
.button--solid:hover {
  --btn-bg: var(--brass-hi);
  --btn-line: var(--brass-hi);
  transform: translateY(-2px);
}

.button--quiet:hover {
  --btn-bg: var(--brass-wash);
  --btn-line: var(--brass);
  --btn-fg: var(--brass-hi);
  transform: translateY(-2px);
}

/* ------------------------------------------------------------------ masthead */

.masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid var(--line);
  background: rgba(13, 12, 11, 0.72);
  backdrop-filter: blur(14px) saturate(120%);
}

.masthead__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 4.75rem;
}

.mark {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
}

.mark__glyph {
  width: 1.9rem;
  height: 1.9rem;
  color: var(--brass);
  transition: color 0.3s var(--ease), transform 0.5s var(--ease);
}
a.mark:hover .mark__glyph {
  color: var(--brass-hi);
  transform: rotate(-8deg);
}

.mark__word {
  font-size: 1.0625rem;
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: -0.02em;
}
.mark__word em { color: var(--brass-hi); }

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 2.6vw, 2.5rem);
}

.site-nav ul {
  display: flex;
  gap: clamp(1.1rem, 2.2vw, 2rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav ul a {
  position: relative;
  display: inline-block;
  padding-block: 0.35rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  transition: color 0.25s var(--ease);
}

.site-nav ul a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--brass);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.site-nav ul a:hover,
.site-nav ul a[aria-current="true"] { color: var(--text); }
.site-nav ul a:hover::after,
.site-nav ul a[aria-current="true"]::after { transform: scaleX(1); }

.masthead__toggle {
  display: none;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.masthead__toggle-bars {
  display: grid;
  gap: 4px;
  width: 14px;
}
.masthead__toggle-bars i {
  height: 1px;
  background: currentColor;
  transition: transform 0.3s var(--ease);
}
.masthead__toggle[aria-expanded="true"] .masthead__toggle-bars i:first-child { transform: translateY(2.5px) rotate(19deg); }
.masthead__toggle[aria-expanded="true"] .masthead__toggle-bars i:last-child { transform: translateY(-2.5px) rotate(-19deg); }

/* ---------------------------------------------------------------------- hero */

.hero {
  padding-top: clamp(3.5rem, 8vh, 7rem);
  padding-bottom: var(--band-y);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--line-strong);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.tag__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brass-hi);
  box-shadow: 0 0 0 0 rgba(227, 177, 100, 0.5);
  animation: ping 2.8s var(--ease) infinite;
}

@keyframes ping {
  0%   { box-shadow: 0 0 0 0 rgba(227, 177, 100, 0.45); }
  70%  { box-shadow: 0 0 0 7px rgba(227, 177, 100, 0); }
  100% { box-shadow: 0 0 0 0 rgba(227, 177, 100, 0); }
}

.hero h1 {
  margin: 1.6rem 0 1.5rem;
  font-stretch: 122%;
  letter-spacing: -0.042em;
}

.lede {
  max-width: 46ch;
  color: var(--text-dim);
  font-size: 1.0625rem;
  line-height: 1.72;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

/* emblem: the source render is a tall poster, so the frame crops to the mark */
.emblem { margin: 0; }

.emblem__frame {
  position: relative;
  padding: 0.75rem;
  border: 1px solid var(--line);
  background:
    linear-gradient(160deg, rgba(194, 135, 44, 0.07), transparent 55%),
    var(--surface);
}

.emblem__crop {
  position: relative;
  aspect-ratio: 780 / 675;
  overflow: hidden;
}

/* Offsets frame the source at x 170–950, y 280–955 — the emblem alone,
   clear of the wordmark baked into the bottom of the render. */
.emblem__crop img {
  position: absolute;
  top: -41.48%;
  left: -21.79%;
  width: 131.28%;
  height: auto;
  animation: emblem-settle 1.4s var(--ease) both;
}

@keyframes emblem-settle {
  from { opacity: 0; transform: scale(1.06); }
  to   { opacity: 1; transform: none; }
}

.emblem__tick {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 1px solid var(--brass);
}
.emblem__tick--tl { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.emblem__tick--br { right: -1px; bottom: -1px; border-left: 0; border-top: 0; }

.emblem__readout {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  padding: 0.85rem 0.25rem 0.15rem;
  border-top: 1px solid var(--line);
  margin-top: 0.75rem;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* design-target strip */
.targets {
  margin-top: clamp(3rem, 7vh, 5.5rem);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding-block: 1.5rem;
}

.targets dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin: 1.35rem 0 0;
  background: var(--line);
}

.targets dl > div {
  padding: 0.15rem 1.35rem 0.25rem 0;
  background: var(--ground);
}
.targets dl > div:first-child { padding-left: 0; }
.targets dl > div:not(:first-child) { padding-left: 1.35rem; }

.targets dt {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.targets dd {
  margin: 0.35rem 0 0;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: -0.03em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.targets__note {
  margin-top: 1.15rem;
  font-size: 0.8125rem;
  color: var(--text-faint);
}

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

.band { padding-block: var(--band-y); }

.band--inset {
  background: linear-gradient(180deg, rgba(25, 22, 20, 0.7), rgba(19, 17, 16, 0.35));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.band__head {
  display: grid;
  gap: 1.1rem;
  max-width: 52ch;
  margin-bottom: clamp(2.5rem, 6vh, 4.5rem);
}

/* -------------------------------------------------------------------- thesis */

.thesis {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

.thesis__prose {
  display: grid;
  gap: 1.4rem;
  max-width: 54ch;
  color: var(--text-dim);
  font-size: 1.0625rem;
}
.thesis__prose p:first-child { color: var(--text); }

.specs {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.specs li {
  display: grid;
  grid-template-columns: 2.75rem minmax(0, 1fr);
  gap: 1rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s var(--ease), padding-left 0.35s var(--ease);
}
.specs li:hover {
  background: var(--brass-wash);
  padding-left: 0.6rem;
}

.specs__num {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  padding-top: 0.2rem;
}

.specs p {
  margin-top: 0.35rem;
  color: var(--text-dim);
  font-size: 0.9375rem;
  line-height: 1.6;
}

/* ---------------------------------------------------------------------- tabs */

.tabs__list {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-bottom: 1px solid var(--line);
}

.tabs__list [role="tab"] {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 0.6rem;
  padding: 0.9rem 1.5rem 0.9rem 0;
  margin-right: 1.75rem;
  border: 0;
  background: none;
  color: var(--text-faint);
  font-family: var(--sans);
  font-size: clamp(1.0625rem, 1.6vw, 1.35rem);
  font-weight: 700;
  font-stretch: 112%;
  letter-spacing: -0.02em;
  cursor: pointer;
  transition: color 0.3s var(--ease);
}

.tabs__list [role="tab"]::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: calc(100% - 1.5rem);
  height: 2px;
  background: var(--brass);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}

.tabs__list [role="tab"]:hover { color: var(--text-dim); }
.tabs__list [role="tab"][aria-selected="true"] { color: var(--text); }
.tabs__list [role="tab"][aria-selected="true"]::after { transform: scaleX(1); }

.tabs__i {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  color: var(--brass);
}

.tabs__panel { padding-top: clamp(2rem, 4vh, 3rem); }
.tabs__panel:focus-visible { outline-offset: 6px; }

.panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
  gap: clamp(1.75rem, 4vw, 4rem);
  align-items: start;
  animation: panel-in 0.55s var(--ease) both;
}

@keyframes panel-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

.panel__icon {
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 1.4rem;
  color: var(--brass);
}

.panel__body h3 {
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  font-stretch: 114%;
  margin-bottom: 0.9rem;
}

.panel__body p {
  max-width: 50ch;
  color: var(--text-dim);
}

.panel__specs {
  margin: 0;
  border-top: 1px solid var(--line-strong);
}

.panel__specs > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
}

.panel__specs dt {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: var(--text-faint);
}

.panel__specs dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--brass-hi);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ------------------------------------------------------------------ pipeline */

.pipeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--line);
  border-top: 1px solid var(--brass);
}

/* a single pulse travels the length of the path once it scrolls into view */
.pipeline::before {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  width: 18%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--brass-hi), transparent);
  animation: travel 5.5s linear infinite;
}

@keyframes travel {
  from { transform: translateX(-100%); }
  to   { transform: translateX(555%); }
}

.pipeline__stage {
  padding: 1.75rem 1.35rem 2.25rem;
  background: var(--ground);
  transition: background 0.4s var(--ease);
}
.pipeline__stage:hover { background: var(--surface-2); }

.pipeline__id {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  color: var(--brass);
}

.pipeline__stage h3 {
  margin: 1.5rem 0 0.6rem;
  font-size: 1.25rem;
  font-stretch: 114%;
}

.pipeline__stage p {
  color: var(--text-dim);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* --------------------------------------------------- architecture map dialog */

/* The map lives only inside this dialog, so it stays closed — and therefore
   display:none — until the hero control opens it. */
.schematic {
  width: min(1120px, calc(100vw - 2rem));
  max-width: none;
  max-height: min(90vh, 62rem);
  padding: 0;
  border: 1px solid var(--line-strong);
  background: var(--ground);
  color: var(--text);
  overflow: hidden;
}

.schematic[open] {
  display: flex;
  flex-direction: column;
  animation: schematic-in 0.4s var(--ease) both;
}

.schematic::backdrop {
  background: rgba(6, 5, 5, 0.82);
  backdrop-filter: blur(6px);
}

@keyframes schematic-in {
  from { opacity: 0; transform: translateY(16px) scale(0.99); }
  to   { opacity: 1; transform: none; }
}

.schematic__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  border-bottom: 1px solid var(--line);
  background: linear-gradient(150deg, rgba(194, 135, 44, 0.1), transparent 60%), var(--surface);
}

.schematic__head h2 {
  margin-top: 0.7rem;
  font-size: clamp(1.5rem, 3.4vw, 2.15rem);
  font-stretch: 118%;
}

.schematic__close {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex: none;
  padding: 0.6rem 0.9rem;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text-dim);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease),
              background 0.25s var(--ease);
}
.schematic__close:hover {
  color: var(--brass-hi);
  border-color: var(--brass);
  background: var(--brass-wash);
}

.schematic__close-x {
  position: relative;
  width: 10px;
  height: 10px;
}
.schematic__close-x::before,
.schematic__close-x::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 1px;
  background: currentColor;
}
.schematic__close-x::before { transform: rotate(45deg); }
.schematic__close-x::after { transform: rotate(-45deg); }

.schematic__body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: clamp(1.5rem, 3.5vw, 2.5rem) clamp(1.25rem, 3vw, 2rem);
}

.schematic__foot {
  padding: 1rem clamp(1.25rem, 3vw, 2rem);
  border-top: 1px solid var(--line);
  background: var(--surface);
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* ----------------------------------------------------------- the map itself */

.map {
  margin: 0;
  padding: 0;
  list-style: none;
}

.map__tier { position: relative; }
.map__tier + .map__tier { padding-top: 3rem; }

/* hairline plus arrowhead standing in for the ▼ between layers */
.map__tier + .map__tier::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 1px;
  height: 3rem;
  background: linear-gradient(180deg, var(--line-strong), var(--brass));
  transform: translateX(-50%);
}

.map__tier + .map__tier::after {
  content: "";
  position: absolute;
  top: 2.35rem;
  left: 50%;
  width: 7px;
  height: 7px;
  border-right: 1px solid var(--brass);
  border-bottom: 1px solid var(--brass);
  transform: translateX(-50%) rotate(45deg);
}

.map__head {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding-bottom: 0.6rem;
  margin-bottom: 0.9rem;
  border-bottom: 1px solid var(--line);
}

.map__id {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--brass);
}

.map__name {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.map__row {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.map__row--1 { grid-template-columns: minmax(0, 1fr); }
.map__row--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.map__row--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.map__node {
  padding: 1.1rem 1.25rem 1.25rem;
  background: var(--surface);
  transition: background 0.35s var(--ease);
}
.map__node:hover { background: var(--surface-2); }

.map__node--spine {
  background: linear-gradient(140deg, var(--brass-wash), transparent 65%), var(--surface-2);
}
.map__node--spine h3 { color: var(--brass-hi); }

.map__node h3 {
  font-size: 1rem;
  font-stretch: 112%;
}

.map__note {
  margin-top: 0.5rem;
  max-width: 52ch;
  color: var(--text-dim);
  font-size: 0.875rem;
  line-height: 1.6;
}

.map__leaves {
  display: grid;
  gap: 0.3rem;
  margin: 0.85rem 0 0;
  padding: 0;
  list-style: none;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}

.map__leaves li {
  position: relative;
  padding-left: 1.1rem;
}
.map__leaves li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.6rem;
  height: 1px;
  background: var(--brass);
}

.map__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0.9rem 0 0;
  padding: 0;
  list-style: none;
}

.map__chips li {
  padding: 0.35rem 0.7rem;
  border: 1px solid var(--line-strong);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* the page behind a modal map must not scroll */
.is-modal,
.is-modal body { overflow: hidden; }

/* -------------------------------------------------------------------- limits */

.limits {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

.limits__head { display: grid; gap: 1.1rem; }
.limits__note { color: var(--text-faint); font-size: 0.9375rem; max-width: 34ch; }

.limits__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.limits__list li {
  padding: 1.25rem 0 1.25rem 2.5rem;
  border-bottom: 1px solid var(--line);
  color: var(--text-dim);
  font-size: 0.9875rem;
  position: relative;
}

.limits__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.85rem;
  width: 1.1rem;
  height: 1px;
  background: var(--brass);
}

.limits__list strong {
  color: var(--text);
  font-weight: 700;
  font-stretch: 108%;
}

/* ------------------------------------------------------------------- network */

.network {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

.network__supply {
  font-family: var(--mono);
  font-size: 0.9375rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass-hi);
}

.network__supply span {
  display: block;
  margin-bottom: 0.4rem;
  font-family: var(--sans);
  font-size: clamp(2.5rem, 5.5vw, 4rem);
  font-weight: 800;
  font-stretch: 118%;
  letter-spacing: -0.04em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.network__caption {
  max-width: 34ch;
  margin-top: 1.5rem;
  color: var(--text-faint);
  font-size: 0.875rem;
  line-height: 1.65;
}

.allocation {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.allocation thead th {
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--line-strong);
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.allocation thead th:last-child { text-align: right; }

/* the row's own background draws the share as a hairline bar along its base */
.allocation tbody tr {
  background-image: linear-gradient(
    90deg,
    var(--brass) 0 var(--share),
    var(--line) var(--share) 100%
  );
  background-size: 100% 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-color 0.35s var(--ease);
}
.allocation tbody tr:hover { background-color: var(--brass-wash); }

.allocation tbody th {
  padding: 1.05rem 1rem 1.05rem 0;
  font-weight: 400;
  font-size: 0.9375rem;
  color: var(--text);
}

.allocation tbody td {
  padding: 1.05rem 0;
  text-align: right;
  font-family: var(--mono);
  font-size: 0.9375rem;
  color: var(--brass-hi);
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------------- roadmap */

.roadmap {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.25rem, 3vw, 2.5rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.roadmap li {
  padding-top: 1.35rem;
  border-top: 1px solid var(--line-strong);
  position: relative;
}

.roadmap li::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 2.5rem;
  height: 3px;
  background: var(--brass);
}

.roadmap__phase {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.roadmap h3 {
  margin: 0.9rem 0 0.6rem;
  font-size: 1.35rem;
  font-stretch: 114%;
}

.roadmap p:last-child {
  color: var(--text-dim);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ------------------------------------------------------------------- closing */

.closing {
  padding-block: clamp(4rem, 9vh, 7rem);
  border-top: 1px solid var(--line);
}

.closing__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2.5rem;
}

.closing .index { margin-bottom: 1.1rem; }
.closing h2 { font-stretch: 120%; letter-spacing: -0.038em; }

.closing__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* -------------------------------------------------------------------- footer */

.footer {
  border-top: 1px solid var(--line);
  background: rgba(19, 17, 16, 0.6);
  padding-top: clamp(2.75rem, 6vh, 4.5rem);
}

.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.6fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 4vw, 4rem);
  padding-bottom: 2.75rem;
}

.footer__brand p,
.footer__note p:last-child {
  margin-top: 1.1rem;
  max-width: 40ch;
  color: var(--text-faint);
  font-size: 0.875rem;
  line-height: 1.65;
}

.footer__nav ul {
  display: grid;
  gap: 0.6rem;
  margin: 1.1rem 0 0;
  padding: 0;
  list-style: none;
}

.footer__nav a {
  font-size: 0.9rem;
  color: var(--text-dim);
  transition: color 0.25s var(--ease);
}
.footer__nav a:hover { color: var(--brass-hi); }

.footer__base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* ------------------------------------------------------------------- reveals */

/* Only hide when scripting is confirmed (the `js` class is set in <head>),
   so a failed or blocked script can never leave content invisible. */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  transition-delay: calc((var(--reveal-order, 0) - 1) * 90ms);
}

/* ------------------------------------------------------------- whitepaper page */

/* The whitepaper lives on its own document at /whitepaper, reached only from
   the buttons on the landing page. Everything below is scoped to it. */

.paper__stamp {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.paper__head {
  padding-top: clamp(3rem, 7vh, 5.5rem);
  padding-bottom: clamp(2.5rem, 6vh, 4rem);
  border-bottom: 1px solid var(--line);
}

.paper__head h1 {
  margin: 1.5rem 0 1.6rem;
  font-size: clamp(2.5rem, 5.6vw, 4.5rem);
  font-stretch: 122%;
  letter-spacing: -0.042em;
}

.paper__meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 2.5rem 0 0;
  background: var(--line);
  border: 1px solid var(--line);
}

.paper__meta > div {
  padding: 0.9rem 1.1rem 1rem;
  background: var(--ground);
}

.paper__meta dt {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.paper__meta dd {
  margin: 0.35rem 0 0;
  font-size: 0.9375rem;
  font-stretch: 106%;
}

.paper {
  display: grid;
  grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
  padding-block: clamp(2.5rem, 6vh, 4rem) clamp(4rem, 9vh, 7rem);
}

.paper__doc { min-width: 0; }

/* contents rail — tracks the section in view via aria-current. Scrolls on its
   own if fifteen entries are taller than a short viewport. */
.paper__toc {
  position: sticky;
  top: 6.5rem;
  max-height: calc(100vh - 9rem);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.paper__toc ol {
  counter-reset: toc;
  display: grid;
  margin: 1.1rem 0 0;
  padding: 0;
  list-style: none;
}

.paper__toc li { counter-increment: toc; }

.paper__toc a {
  display: flex;
  gap: 0.7rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--text-faint);
  transition: color 0.25s var(--ease);
}

.paper__toc a::before {
  content: counter(toc, decimal-leading-zero);
  flex: none;
  padding-top: 0.2em;
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--brass);
}

.paper__toc a:hover { color: var(--text); }
.paper__toc a[aria-current="true"] { color: var(--brass-hi); }

/* ------------------------------------------------------- whitepaper sections */

.sect + .sect {
  margin-top: clamp(3rem, 7vh, 5rem);
  padding-top: clamp(3rem, 7vh, 5rem);
  border-top: 1px solid var(--line);
}

.sect h2 {
  max-width: 36ch;
  margin: 1.1rem 0 1.35rem;
  font-size: clamp(1.55rem, 2.6vw, 2.25rem);
}

.sect > p {
  max-width: 68ch;
  color: var(--text-dim);
}
.sect > p + p { margin-top: 1.1rem; }

.sect > .pull {
  max-width: 60ch;
  margin: 1.75rem 0 0;
  padding: 1.25rem 1.5rem;
  border-left: 2px solid var(--brass);
  background: linear-gradient(120deg, var(--brass-wash), transparent 70%);
  color: var(--text);
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  font-stretch: 108%;
  line-height: 1.5;
}

.sect > .sect__note {
  max-width: 62ch;
  margin-top: 1.6rem;
  padding-left: 1rem;
  border-left: 1px solid var(--brass);
  color: var(--text-faint);
  font-size: 0.875rem;
}

/* 6.x subsections */
.sub { margin-top: clamp(2.25rem, 5vh, 3rem); }

.sub__title {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding-bottom: 0.7rem;
  margin-bottom: 1.1rem;
  border-bottom: 1px solid var(--line);
  font-size: 1.25rem;
  font-stretch: 112%;
}

.sub__title span {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  color: var(--brass);
}

.sub > p {
  max-width: 68ch;
  color: var(--text-dim);
}
.sub > p + p { margin-top: 1.1rem; }

/* dashed list, matching the map's leaf rule */
.bullets {
  display: grid;
  gap: 0.6rem;
  margin: 1.35rem 0 0;
  padding: 0;
  list-style: none;
  color: var(--text-dim);
}

.bullets li {
  position: relative;
  padding-left: 1.4rem;
}
.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 0.75rem;
  height: 1px;
  background: var(--brass);
}

.bullets--tight {
  gap: 0.35rem;
  font-size: 0.9375rem;
}

.bullets--cols {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 1.75rem;
}

.triad {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
  background: var(--line);
  border: 1px solid var(--line);
}

.triad li {
  padding: 1.15rem 1.25rem 1.3rem;
  background: var(--surface);
}

.triad__id {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  color: var(--brass);
}

.triad p {
  margin-top: 0.5rem;
  font-size: 0.9375rem;
}

.cards {
  display: grid;
  gap: 1px;
  margin-top: 1.75rem;
  background: var(--line);
  border: 1px solid var(--line);
}
.cards--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card {
  display: flex;
  flex-direction: column;
  padding: 1.35rem 1.4rem 1.5rem;
  background: var(--surface);
  transition: background 0.35s var(--ease);
}
.card:hover { background: var(--surface-2); }
.card--wide { grid-column: 1 / -1; }

.card p {
  margin-top: 0.6rem;
  color: var(--text-dim);
  font-size: 0.9375rem;
  line-height: 1.65;
}

.card .bullets { margin-top: 0.9rem; }

.card__note {
  padding-top: 0.85rem;
  border-top: 1px solid var(--line);
  color: var(--text-faint);
  font-size: 0.8125rem;
}
/* outranks `.card p` above, which would otherwise set the gap */
.card .card__note { margin-top: 1.1rem; }

/* layer stack, using the same arrowed hairline as the architecture map */
.stack {
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
}

.stack__step {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 1rem;
  padding: 1rem 1.25rem 1.05rem;
  border: 1px solid var(--line);
  background: var(--surface);
}

.stack__step + .stack__step { margin-top: 2.5rem; }

.stack__step + .stack__step::before {
  content: "";
  position: absolute;
  top: -2.5rem;
  left: 50%;
  width: 1px;
  height: 2.5rem;
  background: linear-gradient(180deg, var(--line-strong), var(--brass));
  transform: translateX(-50%);
}

.stack__step + .stack__step::after {
  content: "";
  position: absolute;
  top: -0.9rem;
  left: 50%;
  width: 7px;
  height: 7px;
  border-right: 1px solid var(--brass);
  border-bottom: 1px solid var(--brass);
  transform: translateX(-50%) rotate(45deg);
}

.stack__id {
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--brass);
}

.stack h3 { font-size: 1rem; }

.phases {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.75rem, 3.5vw, 2.75rem);
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
}

.phases > li {
  position: relative;
  padding-top: 1.35rem;
  border-top: 1px solid var(--line-strong);
}

.phases > li::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 2.5rem;
  height: 3px;
  background: var(--brass);
}

.phases h3 {
  margin: 0.9rem 0 0.6rem;
  font-size: 1.35rem;
  font-stretch: 114%;
}

.phases > li > p:not(.roadmap__phase) {
  color: var(--text-dim);
  font-size: 0.9375rem;
}

/* tokenomics table adds a BTAI column and a per-row gloss */
.sect > .network__supply {
  margin-top: 2.25rem;
  color: var(--brass-hi);
}

.allocation--paper { margin-top: 2rem; }

.allocation__note {
  display: block;
  max-width: 54ch;
  margin-top: 0.4rem;
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--text-faint);
}

.allocation--paper tbody td:first-of-type { color: var(--text-dim); }

.allocation tfoot th,
.allocation tfoot td {
  padding-top: 1.05rem;
  border-top: 1px solid var(--line-strong);
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.allocation tfoot th { font-weight: 500; color: var(--text-faint); }
.allocation tfoot td { text-align: right; color: var(--brass-hi); }

.disclaimer {
  margin-top: 1.5rem;
  padding: clamp(1.25rem, 3vw, 1.85rem);
  border: 1px solid var(--line-strong);
  background: var(--surface);
}

.disclaimer p {
  color: var(--text-dim);
  font-size: 0.9375rem;
  line-height: 1.7;
}
.disclaimer p + p { margin-top: 1rem; }

.signoff {
  margin-top: clamp(3rem, 7vh, 5rem);
  padding-top: clamp(2.5rem, 6vh, 3.5rem);
  border-top: 1px solid var(--line);
  text-align: center;
}

.signoff__line {
  margin-top: 1rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.signoff__claim {
  margin-top: 1.1rem;
  font-size: clamp(1.6rem, 3.4vw, 2.5rem);
  font-weight: 700;
  font-stretch: 118%;
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.signoff__ticker {
  margin-top: 1rem;
  font-family: var(--mono);
  font-size: 0.875rem;
  letter-spacing: 0.2em;
  color: var(--brass-hi);
}

.signoff .button { margin-top: 2.25rem; }

/* ---------------------------------------------------------------- responsive */

@media (max-width: 1080px) {
  .thesis,
  .limits,
  .network,
  .panel { grid-template-columns: minmax(0, 1fr); }

  .pipeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pipeline::before { display: none; }
  .roadmap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer__note { grid-column: 1 / -1; }

  .paper { grid-template-columns: minmax(0, 1fr); }
  .paper__toc {
    position: static;
    max-height: none;
    overflow: visible;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--line);
  }
  .paper__toc ol { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1.75rem; }
  .cards--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .masthead__toggle { display: inline-flex; }

  .site-nav {
    position: fixed;
    inset: 4.75rem 0 auto;
    display: grid;
    justify-items: start;
    gap: 0;
    padding: 1.25rem var(--gutter) 2rem;
    border-bottom: 1px solid var(--line);
    background: rgba(10, 9, 8, 0.97);
    backdrop-filter: blur(18px);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
  }

  .site-nav.is-open {
    transform: none;
    opacity: 1;
    visibility: visible;
  }

  .site-nav ul {
    display: grid;
    gap: 0;
    width: 100%;
  }
  .site-nav ul li { border-bottom: 1px solid var(--line); }
  .site-nav ul a { display: block; padding-block: 0.95rem; font-size: 0.875rem; }
  .masthead__cta { margin-top: 1.5rem; }

  .hero__grid { grid-template-columns: minmax(0, 1fr); }
  .emblem { order: -1; max-width: 30rem; }
  .targets dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .targets dl > div { padding: 1rem 1.25rem; }
  .targets dl > div:first-child,
  .targets dl > div:not(:first-child) { padding-left: 1.25rem; }
  .targets dl > div:nth-child(odd) { padding-left: 0; }

  .map__row--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .paper__stamp { display: none; }
  .paper__meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .phases { grid-template-columns: minmax(0, 1fr); }
  /* card bodies carry lists — one column reads better than two narrow ones */
  .cards--2,
  .cards--3,
  .triad { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 560px) {
  .pipeline,
  .roadmap,
  .footer__grid { grid-template-columns: minmax(0, 1fr); }
  .targets dl { grid-template-columns: minmax(0, 1fr); }
  .targets dl > div,
  .targets dl > div:nth-child(odd) { padding-left: 0; }
  .tabs__list [role="tab"] { margin-right: 1.1rem; font-size: 1rem; }
  .hero__actions .button { flex: 1 1 100%; justify-content: center; }

  .schematic { width: 100vw; max-height: 100vh; height: 100vh; border: 0; }
  .map__row--2,
  .map__row--3 { grid-template-columns: minmax(0, 1fr); }

  .paper__meta,
  .paper__toc ol,
  .bullets--cols { grid-template-columns: minmax(0, 1fr); }

  /* the BTAI column is derivable from the share, so drop it first */
  .allocation--paper thead th:nth-child(2),
  .allocation--paper tbody td:first-of-type,
  .allocation--paper tfoot td:first-of-type { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------- printing */

/* The whitepaper is a document people will print. Re-point the tokens at ink
   on paper rather than restating every rule. */
@media print {
  :root {
    --void: #fff;
    --ground: #fff;
    --surface: #fff;
    --surface-2: #fff;
    --line: rgba(0, 0, 0, 0.18);
    --line-strong: rgba(0, 0, 0, 0.32);
    --text: #111;
    --text-dim: #2b2b2b;
    --text-faint: #555;
    --brass: #8a5a12;
    --brass-hi: #6f4a10;
    --brass-wash: rgba(138, 90, 18, 0.07);
  }

  body { background: #fff; }
  body::before,
  body::after { display: none; }

  .skip,
  .masthead,
  .paper__toc,
  .footer,
  .signoff .button { display: none; }

  .paper { display: block; padding: 0; }
  .sect { break-inside: avoid; }
  .card,
  .stack__step,
  .triad li { break-inside: avoid; }
}
