/* Witness — developer and information site.
   Black field, thin display type, mono labels. Four semantic tones:
   private (crimson, the Witness mark), public (blue), external (Bitcoin amber), owner (white). */

:root {
  --bg: #000;
  --bg-2: #0a0a0c;
  --panel: #0e0e11;
  --fg: #fff;
  --fg-2: rgba(255, 255, 255, 0.72);
  --fg-3: rgba(255, 255, 255, 0.5);
  --fg-4: rgba(255, 255, 255, 0.32);
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.18);

  --private: #ff3b30;
  --public: #5aa9ff;
  --external: #f7931a;
  --owner: #ffffff;

  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1240px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: dark;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 300; }
code { font-family: var(--mono); font-size: 0.88em; color: var(--fg); background: rgba(255,255,255,.06); padding: 0.1em 0.35em; border-radius: 4px; }
strong { font-weight: 500; color: var(--fg); }
:focus-visible { outline: 2px solid var(--public); outline-offset: 3px; border-radius: 6px; }

.skip { position: absolute; left: -9999px; top: 8px; background: #fff; color: #000; padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); font-weight: 400; }
.thin { font-weight: 200; color: var(--fg-4); }
.accent { color: var(--private); }

/* Mono section labels, e.g. "0.1 — THE THESIS" */
.label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--fg-3);
}
.label--sm { font-size: 10px; letter-spacing: 0.24em; color: var(--fg-4); }

.display {
  font-size: clamp(40px, 7vw, 88px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 200;
  max-width: 14ch;
  margin-top: 28px;
}
.intro {
  margin-top: 28px;
  max-width: 620px;
  font-size: clamp(17px, 1.6vw, 20px);
  color: var(--fg-2);
  line-height: 1.55;
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(22, 22, 26, 0.72);
  border: 1px solid var(--line);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  max-width: calc(100vw - 24px);
}
.nav__mark {
  width: 34px; height: 34px; flex: none;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #fff; color: #000;
}
.nav__mark svg { width: 20px; height: 20px; }
.nav__links { display: flex; }
.nav__links a {
  font-size: 13px; font-weight: 400;
  padding: 8px 14px;
  color: var(--fg-3);
  border-radius: 999px;
  transition: color .2s, background .2s;
  white-space: nowrap;
}
.nav__links a:hover, .nav__links a[aria-current="true"] { color: var(--fg); background: rgba(255,255,255,.06); }
.nav__cta {
  font-size: 13px; font-weight: 500;
  padding: 8px 16px; border-radius: 999px;
  background: var(--private); color: #fff;
  margin-left: 4px;
}
@media (max-width: 760px) {
  .nav__links a:not(:nth-child(3)):not(:nth-child(5)) { display: none; }
}

/* ---------- Right rail ---------- */
.rail {
  position: fixed; right: 22px; top: 50%; transform: translateY(-50%);
  z-index: 40; list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 10px;
}
.rail li { width: 3px; height: 24px; border-radius: 2px; background: rgba(255,255,255,.16); transition: background .3s, height .3s; }
.rail li.is-active { background: var(--public); height: 32px; }
@media (max-width: 900px) { .rail { display: none; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  height: 44px; padding: 0 20px;
  border-radius: 999px;
  font-size: 14px; font-weight: 400;
  border: 1px solid var(--line-2);
  color: var(--fg);
  transition: background .2s, border-color .2s, transform .2s var(--ease);
}
.btn:hover { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.3); }
.btn:active { transform: scale(.98); }
.btn--solid { background: #fff; color: #000; border-color: #fff; font-weight: 500; }
.btn--solid:hover { background: #e9e9ec; border-color: #e9e9ec; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  overflow: hidden;
  padding: 120px 0 40px;
}
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__veil {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(0,0,0,.92) 0%, rgba(0,0,0,.6) 38%, rgba(0,0,0,0) 70%),
    linear-gradient(0deg, #000 0%, rgba(0,0,0,0) 30%);
}
.hero__inner { position: relative; }
.hero__title {
  font-size: clamp(76px, 15vw, 196px);
  font-weight: 200;
  letter-spacing: -0.055em;
  line-height: .9;
  margin: 20px 0 0 -0.04em;
}
.hero__tag {
  margin-top: 28px;
  font-size: clamp(22px, 2.6vw, 32px);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.hero__lede { margin-top: 20px; max-width: 460px; color: var(--fg-2); font-size: 17px; }
.hero__actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero__foot {
  position: relative; margin-top: auto; padding-top: 56px;
  display: flex; justify-content: space-between; align-items: end; gap: 16px;
}
.hero__steps { list-style: none; margin: 0; padding: 0; display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 14px; color: var(--fg-2); }
.hero__steps .mono { font-size: 10px; color: var(--fg-4); margin-right: 6px; letter-spacing: .1em; }
.hero__arrow { color: var(--fg-4); }
.hero__scroll { writing-mode: vertical-rl; font-size: 9px; }
@media (max-width: 640px) {
  .hero__veil { background: linear-gradient(0deg, #000 8%, rgba(0,0,0,.72) 45%, rgba(0,0,0,.45) 100%); }
  .hero__scroll { display: none; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(96px, 14vw, 180px) 0; border-top: 1px solid var(--line); }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* Thesis */
.cols3 { margin-top: 72px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.cols3 article p:last-child { margin-top: 14px; color: var(--fg-2); font-size: 16px; }
@media (max-width: 820px) { .cols3 { grid-template-columns: 1fr; gap: 32px; } }

.pull { margin: 96px 0 0; padding: 0; }
.pull p {
  font-size: clamp(28px, 4.2vw, 52px);
  font-weight: 200; letter-spacing: -0.03em; line-height: 1.12;
  max-width: 18ch;
}
.pull p::before { content: ""; display: block; width: 40px; height: 1px; background: var(--private); margin-bottom: 28px; }

.triad { margin-top: 88px; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.triad__item { padding: 36px 28px 40px 0; position: relative; }
.triad__item + .triad__item { padding-left: 28px; border-left: 1px solid var(--line); }
.triad__item .dot { position: absolute; top: 40px; right: 24px; }
.triad__big { margin-top: 18px; font-size: clamp(24px, 2.6vw, 34px); font-weight: 200; letter-spacing: -0.02em; line-height: 1.15; }
@media (max-width: 820px) {
  .triad { grid-template-columns: 1fr; }
  .triad__item + .triad__item { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
}

.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot--private { background: var(--private); box-shadow: 0 0 12px var(--private); }
.dot--public { background: var(--public); box-shadow: 0 0 12px var(--public); }
.dot--external { background: var(--external); box-shadow: 0 0 12px var(--external); }
.dot--owner { background: #fff; box-shadow: 0 0 12px rgba(255,255,255,.7); }

.control { margin-top: 96px; display: grid; grid-template-columns: 5fr 7fr; gap: 56px; }
.control__lede { font-size: clamp(22px, 2.4vw, 30px); font-weight: 300; letter-spacing: -0.02em; line-height: 1.25; }
.control__grid { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.control__grid > div { background: var(--bg); padding: 24px; }
.control__grid dt { color: var(--fg-2); }
.control__grid dd { margin: 12px 0 0; color: var(--fg-2); font-size: 15px; }
@media (max-width: 900px) { .control { grid-template-columns: 1fr; gap: 32px; } }
@media (max-width: 520px) { .control__grid { grid-template-columns: 1fr; } }

/* Model layers */
.layers { margin-top: 72px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.layer {
  --tone: var(--fg);
  position: relative;
  min-height: 300px;
  padding: 22px 20px 24px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,0) 60%);
  display: flex; flex-direction: column;
  overflow: hidden;
  transition: border-color .3s, transform .4s var(--ease);
}
.layer::after {
  content: ""; position: absolute; left: 20px; right: 20px; top: 0; height: 1px;
  background: var(--tone); opacity: .8; box-shadow: 0 0 18px var(--tone);
}
.layer:hover { border-color: var(--line-2); transform: translateY(-3px); }
.layer[data-tone="private"] { --tone: var(--private); }
.layer[data-tone="public"] { --tone: var(--public); }
.layer[data-tone="external"] { --tone: var(--external); }
.layer[data-tone="owner"] { --tone: #fff; }
.layer__num { font-size: 56px; font-weight: 200; letter-spacing: -0.04em; line-height: 1; color: var(--fg-4); margin-bottom: 18px; }
.layer h3 { margin-top: auto; padding-top: 28px; font-size: 22px; font-weight: 300; letter-spacing: -0.015em; line-height: 1.2; }
.layer p:last-child { margin-top: 10px; font-size: 14px; color: var(--fg-3); line-height: 1.5; }
@media (max-width: 1100px) { .layers { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 720px) { .layers { grid-template-columns: 1fr 1fr; } .layer { min-height: 240px; } }
@media (max-width: 460px) { .layers { grid-template-columns: 1fr; } .layer { min-height: 0; } }

.split { margin-top: 56px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.split p {
  display: flex; align-items: center; gap: 14px;
  padding: 22px 24px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line);
  font-size: clamp(17px, 1.6vw, 20px); color: var(--fg-2);
}
@media (max-width: 720px) { .split { grid-template-columns: 1fr; } }

/* How it works */
.how { margin-top: 72px; border: 1px solid var(--line); border-radius: 20px; background: var(--bg-2); overflow: hidden; }
.how__tabs { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); }
.how__tabs button {
  appearance: none; background: none; border: 0; color: var(--fg-3);
  font: inherit; font-size: 17px; font-weight: 300;
  padding: 20px 24px; text-align: left; cursor: pointer;
  display: flex; gap: 12px; align-items: baseline;
  position: relative; transition: color .2s, background .2s;
}
.how__tabs button + button { border-left: 1px solid var(--line); }
.how__tabs button .mono { font-size: 10px; letter-spacing: .15em; color: var(--fg-4); }
.how__tabs button:hover { color: var(--fg); background: rgba(255,255,255,.02); }
.how__tabs button[aria-selected="true"] { color: var(--fg); }
.how__tabs button[aria-selected="true"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--fg); }
.how__tabs button[data-step="witness"][aria-selected="true"]::after { background: var(--public); }
.how__tabs button[data-step="translate"][aria-selected="true"]::after { background: #fff; }
.how__tabs button[data-step="prove"][aria-selected="true"]::after { background: var(--private); }

.how__body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.how__body > * { min-width: 0; }
.how__copy { padding: 36px 32px; border-right: 1px solid var(--line); }
.how__step h3 { margin-top: 14px; font-size: 34px; font-weight: 200; letter-spacing: -0.02em; }
.how__step p:not(.label) { margin-top: 14px; color: var(--fg-2); font-size: 15px; }
.how__step:not([hidden]) { animation: stepIn .5s var(--ease); }
@keyframes stepIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.facts { list-style: none; margin: 28px 0 0; padding: 0; border-top: 1px solid var(--line); }
.facts li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.facts .k { font-family: var(--mono); font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--fg-4); padding-top: 3px; white-space: nowrap; }
.facts li span:last-child { text-align: right; color: var(--fg); }

.how__fig { margin: 0; padding: 20px; display: flex; align-items: center; }
.how__scroll { width: 100%; min-width: 0; }
#arch { display: block; width: 100%; height: auto; }
@media (max-width: 960px) {
  .how__body { grid-template-columns: minmax(0, 1fr); }
  .how__copy { border-right: 0; border-bottom: 1px solid var(--line); padding: 28px 20px; }
  .how__fig { padding: 12px 0; }
  .how__scroll { overflow-x: auto; padding: 0 12px; -webkit-overflow-scrolling: touch; }
  #arch { min-width: 600px; }
}
@media (max-width: 560px) {
  .how__tabs button { padding: 16px 12px; font-size: 15px; flex-direction: column; gap: 2px; }
}

/* Architecture SVG */
.zone--public { fill: rgba(90,169,255,.035); }
.zone--private { fill: rgba(255,59,48,.03); }
.hatch { stroke: rgba(255,59,48,.07); stroke-width: 1; }
.zlabel { font-family: var(--mono); font-size: 10px; letter-spacing: .24em; }
.zlabel--public { fill: rgba(90,169,255,.7); }
.zlabel--private { fill: rgba(255,59,48,.75); }
.boundary { stroke: rgba(255,255,255,.35); stroke-dasharray: 2 5; stroke-width: 1; }
.blabel { font-family: var(--mono); font-size: 9px; letter-spacing: .3em; fill: var(--fg-3); paint-order: stroke; stroke: var(--bg-2); stroke-width: 6px; }
.n rect { fill: #111115; stroke: rgba(255,255,255,.2); stroke-width: 1; transition: stroke .35s, fill .35s; }
.n--pvt rect { stroke: rgba(255,59,48,.35); }
.n--adapter rect { stroke: rgba(255,59,48,.6); fill: #150c0c; }
.n--ext rect { stroke: rgba(247,147,26,.5); }
.n--rcpt rect { stroke: rgba(255,255,255,.35); }
.t1 { font-family: var(--sans); font-size: 15px; font-weight: 400; fill: #fff; }
.t2 { font-family: var(--sans); font-size: 12px; font-weight: 400; fill: rgba(255,255,255,.8); }
.t3 { font-family: var(--mono); font-size: 9px; letter-spacing: .06em; fill: rgba(255,255,255,.45); }
.e { fill: none; stroke: rgba(90,169,255,.35); stroke-width: 1; }
.e--quiet { stroke: rgba(255,255,255,.2); }
.arrowhead { fill: currentColor; }
#arch marker path { fill: rgba(255,255,255,.6); }
.flow { fill: none; stroke-width: 1.6; stroke-dasharray: 5 6; opacity: 0; transition: opacity .4s; animation: dash 1.2s linear infinite; }
.flow[data-step="witness"] { stroke: var(--public); }
.flow[data-step="translate"] { stroke: #fff; }
.flow[data-step="prove"] { stroke: var(--private); }
.flow--verify { stroke: var(--public) !important; stroke-dasharray: 2 5; }
.flabel { font-family: var(--mono); font-size: 10px; letter-spacing: .08em; opacity: 0; transition: opacity .4s; paint-order: stroke; stroke: var(--bg-2); stroke-width: 5px; }
.flabel[data-step="witness"] { fill: var(--public); }
.flabel[data-step="translate"] { fill: #fff; }
.flabel[data-step="prove"] { fill: #ff8a82; }
#arch[data-step="witness"] [data-step="witness"],
#arch[data-step="translate"] [data-step="translate"],
#arch[data-step="prove"] [data-step="prove"] { opacity: 1; }
#arch[data-step="witness"] [data-id="log"] rect,
#arch[data-step="witness"] [data-id="adapter"] rect,
#arch[data-step="translate"] [data-id="app"] rect,
#arch[data-step="translate"] [data-id="adapter"] rect,
#arch[data-step="prove"] [data-id="recipient"] rect,
#arch[data-step="prove"] [data-id="log"] rect { stroke: #fff; }
#arch[data-step="witness"] [data-id^="node"] rect { stroke: var(--public); }
#arch[data-step="witness"] [data-id="ots"] rect { stroke: var(--external); }
.packet { fill: #fff; filter: drop-shadow(0 0 6px #fff); }
@keyframes dash { to { stroke-dashoffset: -22; } }

.flowtext { margin-top: 40px; }
.flowtext pre { margin: 0; overflow-x: auto; padding: 24px; border-radius: 14px; border: 1px solid var(--line); background: var(--bg); }
.flowtext code { background: none; padding: 0; font-size: 13px; line-height: 1.6; color: var(--fg-2); }

/* Components */
.comp { list-style: none; margin: 72px 0 0; padding: 0; border-top: 1px solid var(--line); }
.comp li {
  display: grid; grid-template-columns: 64px minmax(0, 5fr) minmax(0, 7fr); gap: 24px; align-items: baseline;
  padding: 28px 0; border-bottom: 1px solid var(--line);
  transition: background .3s;
}
.comp li:hover { background: linear-gradient(90deg, rgba(255,255,255,.03), transparent); }
.comp__num { font-size: 11px; color: var(--fg-4); letter-spacing: .15em; }
.comp__name { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.comp h3 { font-size: clamp(22px, 2.4vw, 30px); font-weight: 300; letter-spacing: -0.02em; }
.comp li > p { color: var(--fg-2); font-size: 16px; }
@media (max-width: 760px) {
  .comp li { grid-template-columns: 40px 1fr; }
  .comp li > p { grid-column: 2; }
}
.tag { font-family: var(--mono); font-size: 9px; letter-spacing: .2em; text-transform: uppercase; color: var(--fg-3); border: 1px solid var(--line-2); padding: 3px 8px; border-radius: 999px; transform: translateY(-3px); }
.tag--public { color: var(--public); border-color: rgba(90,169,255,.4); }
.tag--private { color: #ff6d64; border-color: rgba(255,59,48,.45); }

.notice {
  margin-top: 48px; display: flex; gap: 18px; align-items: center;
  padding: 24px 28px; border-radius: 16px;
  background: linear-gradient(90deg, rgba(255,59,48,.08), rgba(255,59,48,0));
  border: 1px solid rgba(255,59,48,.25);
  font-size: clamp(17px, 1.7vw, 21px); color: var(--fg-2);
}
.notice__icon svg { width: 26px; height: 26px; fill: none; stroke: var(--private); stroke-width: 1.5; display: block; }

.nots { margin-top: 72px; }
.nots ul { list-style: none; margin: 20px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.nots li { font-size: 14px; color: var(--fg-3); padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); text-decoration: line-through; text-decoration-color: rgba(255,59,48,.6); }

/* Nodes */
.roles { margin-top: 72px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.roles article { background: var(--bg); padding: 28px 24px 32px; min-height: 168px; transition: background .3s; }
.roles article:hover { background: var(--panel); }
.roles__k { font-size: 12px; letter-spacing: .28em; color: var(--public); }
.roles article p:last-child { margin-top: 16px; color: var(--fg-2); font-size: 15px; }
.roles__note { background: linear-gradient(135deg, rgba(90,169,255,.1), rgba(0,0,0,0)) !important; }
.roles__note p { font-size: 17px !important; color: var(--fg) !important; margin-top: 0 !important; font-weight: 300; }
@media (max-width: 1000px) { .roles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .roles { grid-template-columns: 1fr; } .roles article { min-height: 0; } }

/* Developers */
.dev { margin-top: 72px; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 24px; align-items: start; }
@media (max-width: 960px) { .dev { grid-template-columns: 1fr; } }
.code { border-radius: 16px; border: 1px solid var(--line); background: #070709; overflow: hidden; }
.code__tabs { display: flex; align-items: center; border-bottom: 1px solid var(--line); overflow-x: auto; }
.code__tabs button {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; color: var(--fg-3);
  padding: 14px 16px; white-space: nowrap; position: relative;
}
.code__tabs button[aria-selected="true"] { color: var(--fg); }
.code__tabs button[aria-selected="true"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 1px; background: #fff; }
.code__copy { margin-left: auto; color: var(--fg-4) !important; }
.code__copy:hover { color: var(--fg) !important; }
.code__pane { margin: 0; padding: 24px; overflow-x: auto; font-family: var(--mono); font-size: 13px; line-height: 1.75; color: #d7d7de; }
.code__pane code { background: none; padding: 0; font-size: inherit; color: inherit; }
.tk { color: #c792ea; }
.ts { color: #a5d6a7; }
.tf { color: #82b1ff; }
.tn { color: #ffcb6b; }
.tc { color: #5d5d6b; }

.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.checks li { display: flex; gap: 18px; padding: 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); }
.checks .mono { font-size: 10px; color: var(--fg-4); letter-spacing: .15em; padding-top: 5px; }
.checks h3 { font-family: var(--mono); font-size: 14px; font-weight: 400; color: var(--public); }
.checks p { margin-top: 6px; color: var(--fg-2); font-size: 14px; }

.sdks { margin-top: 24px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.sdk { padding: 20px; border-radius: 14px; border: 1px solid var(--line); }
.sdk__lang { font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: var(--fg); }
.sdk__pkg { margin-top: 6px; font-size: 13px; color: var(--fg-3); font-family: var(--mono); }
@media (max-width: 760px) { .sdks { grid-template-columns: 1fr 1fr; } }

/* Closing */
.closing { padding: clamp(120px, 16vw, 220px) 0; border-top: 1px solid var(--line); background: radial-gradient(ellipse 60% 50% at 50% 100%, rgba(255,59,48,.12), transparent 70%); }
.closing__line { font-size: clamp(40px, 6.6vw, 92px); font-weight: 200; letter-spacing: -0.04em; line-height: 1.04; }

/* Footer */
.foot { border-top: 1px solid var(--line); padding: 40px 0 56px; }
.foot__inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.foot__brand { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 400; }
.foot__brand svg { width: 22px; height: 22px; color: var(--private); }
.foot__links { display: flex; flex-wrap: wrap; gap: 20px; font-size: 13px; color: var(--fg-3); }
.foot__links a:hover { color: var(--fg); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .flow { animation: none; }
  .how__step:not([hidden]) { animation: none; }
}

/* ---------- Suite badge + consensus line ---------- */
.suite {
  display: inline-flex; align-items: center; gap: 10px;
  margin-bottom: 28px; padding: 7px 14px 7px 10px;
  border: 1px solid var(--line-2); border-radius: 999px;
  background: rgba(255,255,255,.03);
  font-size: 12px; font-weight: 400; color: var(--fg-2);
}
.suite__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--private); box-shadow: 0 0 10px var(--private); }
.suite__sep { color: var(--fg-4); }
.hero__one {
  margin-top: 22px;
  font-size: clamp(26px, 3.2vw, 40px);
  font-weight: 200; letter-spacing: -0.025em; line-height: 1.1;
  color: var(--fg);
}
.hero__one + .hero__tag { margin-top: 14px; font-size: clamp(18px, 1.8vw, 22px); color: var(--fg-2); }

/* ---------- Node operators ---------- */
.ops { margin-top: 56px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.op { padding: 28px; border-radius: 16px; border: 1px solid var(--line); background: var(--bg-2); }
.op h3 { margin-top: 16px; font-size: clamp(24px, 2.4vw, 32px); font-weight: 200; letter-spacing: -0.02em; }
.op p:last-child { margin-top: 12px; color: var(--fg-2); font-size: 15px; max-width: 46ch; }
.op--audit { border-color: rgba(90,169,255,.35); background: linear-gradient(135deg, rgba(90,169,255,.1), rgba(0,0,0,0) 70%); }
.ops + .roles { margin-top: 24px; }
@media (max-width: 720px) { .ops { grid-template-columns: 1fr; } }

/* ---------- Anchor plugins ---------- */
.plug { margin-top: 24px; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-items: center; padding: 36px; border-radius: 18px; border: 1px solid var(--line); background: var(--bg-2); }
.plug h3 { margin-top: 14px; font-size: clamp(26px, 2.8vw, 38px); font-weight: 200; letter-spacing: -0.025em; }
.plug__copy p:last-child { margin-top: 14px; color: var(--fg-2); font-size: 15px; }
.plug__diagram { display: grid; grid-template-columns: auto 48px 1fr; align-items: center; }
.plug__core { padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line-2); background: #111115; font-size: 12px; color: var(--fg); }
.plug__rail { height: 1px; background: linear-gradient(90deg, var(--line-2), rgba(247,147,26,.6)); }
.plug__slots { list-style: none; margin: 0; padding: 0 0 0 16px; display: grid; gap: 8px; border-left: 1px solid rgba(255,255,255,.2); }
.plug__slots li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); font-size: 14px; color: var(--fg); }
.plug__slots small { margin-left: auto; font-family: var(--mono); font-size: 10px; letter-spacing: .08em; color: var(--fg-4); }
.plug__slots .is-default { border-color: rgba(247,147,26,.4); }
.plug__slots .is-empty { border-style: dashed; color: var(--fg-3); }
.plug__plus { width: 8px; text-align: center; color: var(--fg-3); }
@media (max-width: 900px) { .plug { grid-template-columns: 1fr; padding: 24px; } }
@media (max-width: 520px) { .plug__diagram { grid-template-columns: 1fr; gap: 10px; } .plug__rail { display: none; } .plug__slots { padding-left: 0; border-left: 0; } .plug__core { justify-self: start; } }

/* ---------- Attestation quorum ---------- */
.quorum { margin-top: 24px; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 32px; align-items: start; padding: 36px; border-radius: 18px; border: 1px solid var(--line); background: var(--bg-2); }
.quorum h3 { margin-top: 14px; font-size: clamp(26px, 2.8vw, 38px); font-weight: 200; letter-spacing: -0.025em; }
.quorum__copy > p:not(.label) { margin-top: 14px; color: var(--fg-2); font-size: 15px; }
.qstates { list-style: none; margin: 24px 0 0; padding: 0; border-top: 1px solid var(--line); }
.qstates li { display: grid; grid-template-columns: 10px 96px 1fr; gap: 12px; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--fg-2); }
.qstates .mono { font-size: 12px; color: var(--fg); }
.qdot { width: 8px; height: 8px; border-radius: 50%; transform: translateY(-1px); }
.qdot--pending { background: var(--external); }
.qdot--ok { background: var(--public); box-shadow: 0 0 10px var(--public); }
.qdot--fail { background: var(--private); box-shadow: 0 0 10px var(--private); }
.quorum__alarm { font-size: 14px !important; }
.quorum__code { margin: 0; padding: 22px; border-radius: 14px; border: 1px solid var(--line); background: #070709; overflow-x: auto; font-family: var(--mono); font-size: 12.5px; line-height: 1.7; color: #d7d7de; }
.quorum__code code { background: none; padding: 0; font-size: inherit; color: inherit; }
@media (max-width: 960px) { .quorum { grid-template-columns: 1fr; padding: 24px; } }
@media (max-width: 460px) { .qstates li { grid-template-columns: 10px 1fr; } .qstates li > span:last-child { grid-column: 2; } }

.checks__opt { border-style: dashed !important; }
.checks h3 .tag { margin-left: 6px; transform: translateY(-2px); display: inline-block; }
.closing__line--gap { margin-top: 28px; }
.foot__legal { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 12px; color: var(--fg-4); }

/* ---------- Footer legal + whitepaper link ---------- */
.foot__legal { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.foot__paper { font-size: 13px; color: var(--fg-2); padding: 8px 14px; border: 1px solid var(--line-2); border-radius: 999px; transition: color .2s, border-color .2s; }
.foot__paper:hover { color: var(--fg); border-color: rgba(255,255,255,.35); }

/* ---------- Whitepaper page ---------- */
.wp__layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 64px; padding-top: 120px; padding-bottom: 120px; }
.wp__toc { position: sticky; top: 100px; align-self: start; max-height: calc(100vh - 120px); overflow-y: auto; }
.wp__toc ol { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 2px; }
.wp__toc a { display: block; font-size: 13px; color: var(--fg-3); padding: 5px 0; line-height: 1.35; }
.wp__toc a:hover { color: var(--fg); }
.wp__doc { max-width: 760px; font-size: 16.5px; color: var(--fg-2); line-height: 1.7; }
.wp__title { margin-top: 20px; font-size: clamp(38px, 5.4vw, 64px); font-weight: 200; letter-spacing: -0.035em; line-height: 1.05; color: var(--fg); }
.wp__doc h2 { margin: 72px 0 0; padding-top: 28px; border-top: 1px solid var(--line); font-size: clamp(26px, 3vw, 34px); font-weight: 300; letter-spacing: -0.02em; line-height: 1.2; color: var(--fg); scroll-margin-top: 90px; }
.wp__doc h3 { margin: 40px 0 0; font-size: 20px; font-weight: 400; letter-spacing: -0.01em; color: var(--fg); scroll-margin-top: 90px; }
.wp__doc p, .wp__doc ul, .wp__doc ol { margin: 16px 0 0; }
.wp__doc ul, .wp__doc ol { padding-left: 22px; }
.wp__doc li + li { margin-top: 6px; }
.wp__doc strong { color: var(--fg); }
.wp__doc hr { display: none; }
.wp__doc blockquote { margin: 32px 0 0; padding: 20px 24px; border-left: 2px solid var(--private); background: rgba(255,59,48,.05); border-radius: 0 12px 12px 0; }
.wp__doc blockquote p { margin: 0; font-size: 19px; font-weight: 300; }
.wp__doc pre { margin: 20px 0 0; padding: 20px; overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: #070709; }
.wp__doc pre code { background: none; padding: 0; font-size: 12.5px; line-height: 1.6; color: #d7d7de; }
.wp-table { margin: 20px 0 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.wp-table table { width: 100%; border-collapse: collapse; font-size: 14px; }
.wp-table th, .wp-table td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); }
.wp-table th { font-family: var(--mono); font-size: 10px; font-weight: 400; letter-spacing: .16em; text-transform: uppercase; color: var(--fg-4); background: rgba(255,255,255,.02); }
.wp-table tr:last-child td { border-bottom: 0; }
.wp-table td:first-child { color: var(--fg); min-width: 140px; }
@media (max-width: 960px) {
  .wp__layout { grid-template-columns: 1fr; gap: 32px; padding-top: 100px; }
  .wp__toc { position: static; max-height: none; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
}
.plug__slots .is-example { border-style: dashed; color: var(--fg-3); }

/* ---------- Developer docs ---------- */
.docs__lede { margin-top: 18px; font-size: 19px; color: var(--fg-2); }
.dl { margin-top: 32px; display: grid; gap: 12px; }
.dl__card { display: grid; gap: 8px; padding: 22px 24px; border-radius: 16px; border: 1px solid var(--line); background: var(--bg-2); transition: border-color .2s, transform .3s var(--ease); }
.dl__card:hover { border-color: rgba(255,255,255,.3); transform: translateY(-2px); }
.dl__name { font-size: 20px; font-weight: 300; color: var(--fg); letter-spacing: -0.01em; }
.dl__desc { font-size: 14px; color: var(--fg-2); }
.dl__go { font-family: var(--mono); font-size: 12px; color: var(--public); }
.dl__cmd { display: block; font-size: 12px; padding: 10px 12px; border-radius: 10px; background: #070709 !important; border: 1px solid var(--line); overflow-x: auto; white-space: nowrap; color: #d7d7de !important; }
.devcta { margin-top: 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 22px 26px; border-radius: 16px; border: 1px solid rgba(90,169,255,.35); background: linear-gradient(135deg, rgba(90,169,255,.1), rgba(0,0,0,0) 70%); transition: border-color .2s; }
.devcta:hover { border-color: rgba(90,169,255,.7); }
.devcta > span:first-child { display: grid; gap: 6px; }
.devcta__t { font-size: clamp(20px, 2vw, 26px); font-weight: 300; color: var(--fg); }
.devcta__go { font-size: 14px; color: var(--public); }
.wp__layout > *, .dl__card { min-width: 0; }
.wp__doc p, .wp__doc li, .wp__doc td { overflow-wrap: anywhere; }
.partner { margin-top: 28px; padding: 20px 24px; border-radius: 16px; border: 1px dashed var(--line-2); background: var(--bg-2); }
.partner p:last-child { margin-top: 8px; font-size: 18px; color: var(--fg); }
.soon { min-height: 70vh; padding-top: 180px; padding-bottom: 120px; } .soon__text { margin-top: 20px; font-size: 19px; color: var(--fg-2); }
