/* ============================================================
   AETHERNET — design system
   Mix: ORDO (minimal, full-viewport, 00/01/02 motif, italic accents)
      + Zero Lux (industrial plates, heat ramp, candid status)
   Heat ramp here = threat → patched:  red → violet → cyan → white-hot
   ============================================================ */

:root {
  --bg: #05060d;
  --bg-2: #0a0c18;
  --panel: rgba(255, 255, 255, 0.03);
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.18);
  --ink: #eef1ff;
  --ink-2: #a3a9c7;
  --ink-3: #5f6688;

  --threat: #ff3d5a;
  --warn: #ff9f43;
  --aether: #7c5cff;
  --cyan: #2ff3e0;
  --white-hot: #ffffff;
  --ok: #3dffa2;

  --grad: linear-gradient(90deg, var(--threat), var(--aether) 45%, var(--cyan) 85%, #fff);

  --f-sans: "Space Grotesk", system-ui, -apple-system, Segoe UI, sans-serif;
  --f-serif: "Instrument Serif", Georgia, serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --pad: clamp(20px, 4vw, 56px);
  --max: 1320px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
}

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

html { scroll-behavior: smooth; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body {
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.is-loading { overflow: hidden; }

a { color: inherit; text-decoration: none; }
img, canvas { display: block; max-width: 100%; }
::selection { background: var(--aether); color: #fff; }

/* grain overlay (screenprint feel) */
body::after {
  content: "";
  position: fixed; inset: -50%;
  pointer-events: none; z-index: 90;
  opacity: .05;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  33% { transform: translate(-3%, 2%); }
  66% { transform: translate(2%, -3%); }
  100% { transform: translate(0, 0); }
}

/* ---------- loader (ORDO 000 counter) ---------- */
.loader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg);
  display: grid; place-items: center;
  transition: clip-path 1s var(--ease), visibility 0s 1s;
  clip-path: inset(0 0 0 0);
}
.loader.done { clip-path: inset(0 0 100% 0); visibility: hidden; }
.loader__inner { width: min(560px, 80vw); }
.loader__count {
  font-family: var(--f-mono);
  font-size: clamp(64px, 14vw, 160px);
  line-height: .9; letter-spacing: -.04em;
}
.loader__bar { height: 1px; background: var(--line); margin-top: 18px; overflow: hidden; }
.loader__bar i { display: block; height: 100%; width: 0; background: var(--grad); }
.loader__meta {
  display: flex; justify-content: space-between; margin-top: 12px;
  font-family: var(--f-mono); font-size: 11px; color: var(--ink-3);
  text-transform: uppercase; letter-spacing: .14em;
}

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--pad);
  transition: background .4s, border-color .4s, transform .5s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: rgba(5, 6, 13, .72); backdrop-filter: blur(14px); border-color: var(--line); }
.nav.hide { transform: translateY(-100%); }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: .02em; }
.brand__mark { width: 26px; height: 26px; }
.brand em { font-family: var(--f-serif); font-weight: 400; font-style: italic; color: var(--ink-2); }
.nav__links { display: flex; gap: 4px; font-size: 13px; }
.nav__links a {
  padding: 8px 12px; border-radius: 999px; color: var(--ink-2);
  font-family: var(--f-mono); text-transform: uppercase; letter-spacing: .08em; font-size: 11px;
  transition: color .2s, background .2s;
}
.nav__links a:hover, .nav__links a.active { color: var(--ink); background: var(--panel); }
.nav__links a span { color: var(--ink-3); margin-right: 6px; }
.nav__right { display: flex; align-items: center; gap: 10px; }
.sound {
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  background: none; border: 1px solid var(--line); color: var(--ink-2);
  padding: 7px 12px; border-radius: 999px; cursor: pointer; display: flex; gap: 8px; align-items: center;
}
.sound__bars { display: inline-flex; gap: 2px; align-items: flex-end; height: 10px; }
.sound__bars i { width: 2px; height: 3px; background: currentColor; }
.sound.on .sound__bars i { animation: eq .9s ease-in-out infinite; }
.sound.on .sound__bars i:nth-child(2) { animation-delay: .2s; }
.sound.on .sound__bars i:nth-child(3) { animation-delay: .4s; }
@keyframes eq { 50% { height: 10px; } }
.gh {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line-2); color: var(--ink-2); transition: color .2s, border-color .2s, transform .3s var(--ease);
}
.gh:hover { color: var(--ink); border-color: var(--ink); transform: rotate(-8deg) scale(1.06); }
.burger { display: none; background: none; border: 0; color: var(--ink); font-size: 22px; cursor: pointer; }

/* ---------- buttons ---------- */
.btn {
  --c: var(--ink);
  position: relative; display: inline-flex; align-items: center; gap: 12px;
  padding: 14px 22px; border-radius: 999px;
  border: 1px solid var(--line-2); color: var(--c);
  font-size: 14px; font-weight: 500; cursor: pointer; background: transparent;
  overflow: hidden; isolation: isolate;
  transition: border-color .3s, color .3s;
}
.btn small { font-family: var(--f-mono); font-size: 10px; color: var(--ink-3); transition: color .3s; }
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--grad); transform: translateY(101%);
  transition: transform .5s var(--ease);
}
.btn:hover { color: #05060d; border-color: transparent; }
.btn:hover small { color: #05060d; }
.btn:hover::before { transform: translateY(0); }
.btn--solid { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn--solid small { color: #4a4f6b; }
.btn .arrow { transition: transform .3s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- layout ---------- */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }
section { position: relative; }
.section { padding: clamp(90px, 14vh, 160px) 0; border-top: 1px solid var(--line); }

.kicker {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3);
}
.kicker b { color: var(--ink); font-weight: 500; }
.kicker::after { content: ""; flex: 0 0 48px; height: 1px; background: var(--line-2); }

h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.035em; line-height: .95; }
h1 { font-size: clamp(48px, 9.5vw, 148px); }
h2 { font-size: clamp(36px, 6vw, 88px); }
h3 { font-size: clamp(20px, 2vw, 28px); letter-spacing: -.02em; line-height: 1.1; }
.it { font-family: var(--f-serif); font-style: italic; font-weight: 400; letter-spacing: -.01em; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: clamp(17px, 1.5vw, 21px); color: var(--ink-2); max-width: 640px; }
.muted { color: var(--ink-2); }
.mono { font-family: var(--f-mono); }
.plate {
  font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3);
  border-top: 1px solid var(--line); padding-top: 10px; margin-top: 14px;
  display: flex; justify-content: space-between;
}

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 120px 0 56px; overflow: hidden;
}
.hero canvas.fx {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(ellipse at 50% 120%, transparent 30%, var(--bg) 80%),
              linear-gradient(to top, var(--bg) 0%, transparent 40%);
}
.hero > .wrap { position: relative; z-index: 2; width: 100%; }
.hero__top { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 28px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero__foot {
  display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-top: 56px;
  font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .14em;
}
.hero__foot .live::before {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--ok); margin-right: 8px; box-shadow: 0 0 12px var(--ok); animation: blink 1.6s infinite;
}
@keyframes blink { 50% { opacity: .25; } }
.page-hero { min-height: 78vh; }

/* split-line headline reveal */
.split .ln { display: block; overflow: hidden; padding-bottom: .06em; }
.split .ln > span { display: inline-block; transform: translateY(110%); transition: transform 1.1s var(--ease); }
.split.in .ln > span { transform: translateY(0); }
.split .ln:nth-child(2) > span { transition-delay: .08s; }
.split .ln:nth-child(3) > span { transition-delay: .16s; }

/* ---------- reveal ---------- */
[data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
[data-reveal="fade"] { transform: none; }
[data-reveal="left"] { transform: translateX(-40px); }
[data-reveal="scale"] { transform: scale(.96); }

/* ---------- stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.stat { padding: 28px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat__n { font-family: var(--f-mono); font-size: clamp(30px, 3.6vw, 52px); letter-spacing: -.04em; line-height: 1; }
.stat__l { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .14em; margin-top: 10px; }
.stat__tag { font-size: 10px; color: var(--warn); font-family: var(--f-mono); }

/* ---------- marquee ---------- */
.marquee { overflow: hidden; border-block: 1px solid var(--line); padding: 18px 0; white-space: nowrap; }
.marquee__track { display: inline-flex; gap: 48px; animation: marq 40s linear infinite; }
.marquee span { font-size: clamp(22px, 3vw, 40px); letter-spacing: -.02em; color: var(--ink-3); }
.marquee span b { color: var(--ink); font-weight: 500; }
.marquee span .dot { color: var(--aether); }
@keyframes marq { to { transform: translateX(-50%); } }

/* ---------- grids / cards ---------- */
.grid { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.card {
  position: relative; background: var(--bg); padding: 32px; min-height: 240px;
  display: flex; flex-direction: column; gap: 14px; overflow: hidden;
  transition: background .4s;
}
.card::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 50%), rgba(124, 92, 255, .16), transparent 60%);
}
.card:hover::before { opacity: 1; }
.card__n { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .14em; }
.card p { margin: 0; color: var(--ink-2); font-size: 15px; }
.card .tags { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  font-family: var(--f-mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase;
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px; color: var(--ink-2);
}
.tag--ok { color: var(--ok); border-color: rgba(61, 255, 162, .3); }
.tag--warn { color: var(--warn); border-color: rgba(255, 159, 67, .3); }
.tag--bad { color: var(--threat); border-color: rgba(255, 61, 90, .3); }
.tag--aether { color: var(--aether); border-color: rgba(124, 92, 255, .4); }

.icon { width: 36px; height: 36px; color: var(--cyan); }

/* ---------- steps (sticky scroll explainer, ORDO "how an agent works") ---------- */
.explainer { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }
.explainer__stage {
  position: sticky; top: 90px; height: calc(100vh - 140px); min-height: 460px;
  border: 1px solid var(--line); border-radius: 22px; overflow: hidden; background: var(--bg-2);
}
.explainer__stage canvas { width: 100%; height: 100%; }
.explainer__hud {
  position: absolute; left: 18px; right: 18px; bottom: 16px;
  display: flex; justify-content: space-between; font-family: var(--f-mono); font-size: 10px;
  color: var(--ink-3); text-transform: uppercase; letter-spacing: .14em;
}
.explainer__steps { display: flex; flex-direction: column; }
.step { min-height: 70vh; display: flex; flex-direction: column; justify-content: center; gap: 16px; opacity: .25; transition: opacity .5s; }
.step.active { opacity: 1; }
.step__n { font-family: var(--f-mono); font-size: 12px; color: var(--aether); }
.step ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.step li { font-family: var(--f-mono); font-size: 13px; color: var(--ink-2); padding-left: 18px; position: relative; }
.step li::before { content: "→"; position: absolute; left: 0; color: var(--cyan); }

/* ---------- terminal ---------- */
.term {
  background: #070812; border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
  font-family: var(--f-mono); font-size: 13px;
}
.term__bar { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--line); color: var(--ink-3); font-size: 11px; }
.term__bar i { width: 9px; height: 9px; border-radius: 50%; background: #2a2d44; }
.term__bar span { margin-left: auto; }
.term pre { margin: 0; padding: 18px; overflow-x: auto; line-height: 1.7; color: var(--ink-2); white-space: pre; }
.term .c-p { color: var(--cyan); }
.term .c-ok { color: var(--ok); }
.term .c-bad { color: var(--threat); }
.term .c-warn { color: var(--warn); }
.term .c-a { color: var(--aether); }
.term .c-d { color: var(--ink-3); }
.copy {
  margin-left: 8px; background: none; border: 1px solid var(--line); color: var(--ink-2); cursor: pointer;
  font-family: var(--f-mono); font-size: 10px; padding: 3px 8px; border-radius: 6px;
}
.copy:hover { color: var(--ink); border-color: var(--line-2); }
.cursor-blink::after { content: "▋"; color: var(--cyan); animation: blink 1s steps(1) infinite; }

/* ---------- forms ---------- */
.field { display: flex; gap: 0; border: 1px solid var(--line-2); border-radius: 999px; padding: 6px; background: var(--panel); }
.field input, .field select {
  flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--ink);
  padding: 10px 16px; font: inherit; font-family: var(--f-mono); font-size: 14px;
}
.field:focus-within { border-color: var(--aether); box-shadow: 0 0 0 4px rgba(124, 92, 255, .15); }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.chip {
  font-family: var(--f-mono); font-size: 11px; color: var(--ink-2); border: 1px dashed var(--line-2);
  padding: 6px 10px; border-radius: 999px; cursor: pointer; background: none;
}
.chip:hover { color: var(--ink); border-style: solid; }
.note { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); margin-top: 10px; }

/* ---------- scan report ---------- */
.report { display: none; margin-top: 40px; }
.report.show { display: block; }
.score { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.score__ring { width: 150px; height: 150px; position: relative; }
.score__ring svg { transform: rotate(-90deg); }
.score__ring b { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--f-mono); font-size: 40px; }
.findings { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.finding { background: var(--bg); padding: 18px 20px; display: grid; grid-template-columns: 90px 1fr auto; gap: 18px; align-items: start; }
.finding h4 { margin: 0 0 4px; font-size: 15px; font-weight: 500; }
.finding p { margin: 0; color: var(--ink-2); font-size: 13px; }
.finding code { font-family: var(--f-mono); font-size: 12px; color: var(--cyan); display: block; margin-top: 8px; white-space: pre-wrap; word-break: break-all; }
.sev { font-family: var(--f-mono); font-size: 10px; text-transform: uppercase; letter-spacing: .12em; padding: 4px 8px; border-radius: 6px; text-align: center; }
.sev--critical { background: rgba(255, 61, 90, .15); color: var(--threat); }
.sev--high { background: rgba(255, 120, 80, .14); color: #ff7850; }
.sev--medium { background: rgba(255, 159, 67, .12); color: var(--warn); }
.sev--low { background: rgba(124, 92, 255, .14); color: var(--aether); }
.sev--info { background: rgba(255, 255, 255, .06); color: var(--ink-2); }
.sev--pass { background: rgba(61, 255, 162, .1); color: var(--ok); }

/* ---------- status lists (Zero Lux candor) ---------- */
.lists { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.list { border: 1px solid var(--line); border-radius: 18px; padding: 28px; }
.list h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.list ul { list-style: none; padding: 0; margin: 0; }
.list li { padding: 12px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; font-size: 15px; }
.list li span:last-child { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); white-space: nowrap; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot--ok { background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.dot--warn { background: var(--warn); }
.dot--bad { background: var(--threat); }

/* ---------- notice ---------- */
.notice {
  border: 1px solid rgba(255, 159, 67, .35); background: rgba(255, 159, 67, .05);
  border-radius: 16px; padding: 22px 26px; display: flex; gap: 18px; align-items: flex-start;
}
.notice b { color: var(--warn); font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.notice p { margin: 0; color: var(--ink-2); }

/* ---------- token ---------- */
.alloc { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.alloc__bar { display: flex; height: 18px; border-radius: 999px; overflow: hidden; gap: 2px; }
.alloc__bar i { display: block; height: 100%; transform-origin: left; transform: scaleX(0); transition: transform 1.4s var(--ease); }
.in .alloc__bar i { transform: scaleX(1); }
.alloc__rows { margin-top: 24px; }
.alloc__row { display: grid; grid-template-columns: 14px 1fr auto; gap: 14px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.alloc__row i { width: 10px; height: 10px; border-radius: 3px; }
.alloc__row span:last-child { font-family: var(--f-mono); color: var(--ink-2); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 10px 24px; font-family: var(--f-mono); font-size: 13px; }
.kv dt { color: var(--ink-3); text-transform: uppercase; font-size: 11px; letter-spacing: .12em; padding-top: 2px; }
.kv dd { margin: 0; color: var(--ink); word-break: break-all; }

/* ---------- docs ---------- */
.docs { display: grid; grid-template-columns: 220px 1fr; gap: 48px; }
.docs__nav { position: sticky; top: 100px; align-self: start; display: grid; gap: 2px; }
.docs__nav a { font-family: var(--f-mono); font-size: 12px; color: var(--ink-3); padding: 7px 10px; border-left: 1px solid var(--line); }
.docs__nav a.active, .docs__nav a:hover { color: var(--ink); border-color: var(--cyan); }
.docs article h3 { margin: 56px 0 14px; scroll-margin-top: 100px; }
.docs article h3:first-child { margin-top: 0; }
.docs article p { color: var(--ink-2); }
.endpoint { display: flex; gap: 12px; align-items: center; font-family: var(--f-mono); font-size: 13px; padding: 12px 0; border-top: 1px solid var(--line); }
.method { font-size: 10px; padding: 3px 7px; border-radius: 5px; min-width: 52px; text-align: center; }
.method--get { background: rgba(47, 243, 224, .12); color: var(--cyan); }
.method--post { background: rgba(124, 92, 255, .16); color: #a995ff; }
.endpoint span:last-child { color: var(--ink-3); margin-left: auto; font-size: 12px; text-align: right; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 80px 0 32px; }
.footer__big { font-size: clamp(56px, 14vw, 220px); font-weight: 600; letter-spacing: -.06em; line-height: .8; margin: 0 0 56px; }
.footer__big .it { color: var(--ink-3); }
.footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.footer h5 { margin: 0 0 14px; font-family: var(--f-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .14em; color: var(--ink-3); font-weight: 400; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 14px; color: var(--ink-2); }
.footer ul a:hover { color: var(--ink); }
.footer__base {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 56px; padding-top: 20px; border-top: 1px solid var(--line);
  font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .1em;
}

/* ---------- cursor glow ---------- */
.glow {
  position: fixed; left: 0; top: 0; width: 420px; height: 420px; margin: -210px 0 0 -210px;
  border-radius: 50%; pointer-events: none; z-index: 1; mix-blend-mode: screen;
  background: radial-gradient(circle, rgba(124, 92, 255, .10), transparent 65%);
  transition: opacity .3s;
}

/* ---------- page transition ---------- */
.wipe {
  position: fixed; inset: 0; z-index: 99; pointer-events: none;
  background: var(--bg); transform: scaleY(0); transform-origin: bottom;
  transition: transform .55s var(--ease);
}
.wipe::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--grad); }
.wipe.go { transform: scaleY(1); }

/* ---------- toast ---------- */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 140%); z-index: 98;
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 999px; padding: 12px 20px;
  font-family: var(--f-mono); font-size: 12px; opacity: 0; visibility: hidden;
  transition: transform .5s var(--ease), opacity .3s, visibility 0s .5s;
}
.toast.show { transform: translate(-50%, 0); opacity: 1; visibility: visible; transition: transform .5s var(--ease), opacity .3s; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav__links { display: none; }
  .nav__links.open {
    display: flex; flex-direction: column; position: fixed; inset: 64px 0 auto 0; padding: 16px var(--pad) 24px;
    background: rgba(5, 6, 13, .96); border-bottom: 1px solid var(--line);
  }
  .burger { display: block; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .grid--3, .grid--2, .grid--4, .lists, .alloc, .explainer, .docs { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .explainer__stage { position: relative; top: 0; height: 60vh; }
  .step { min-height: auto; padding: 40px 0; opacity: 1; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .docs__nav { position: static; display: flex; flex-wrap: wrap; }
  .finding { grid-template-columns: 1fr; }
  .hero__top { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 600px) {
  .brand { white-space: nowrap; }
  .sound__label, .nav__right .btn--solid, .hero__foot span:nth-child(2) { display: none; }
  .hero__cta .btn { width: 100%; justify-content: space-between; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-reveal], .split .ln > span { opacity: 1; transform: none; }
}

/* ---------- network theme ----------
   --net / --net2 are set from public/data/token.json (single → network colors, multi → theme) */
:root { --net: #2ff3e0; --net2: #7c5cff; }
::selection { background: var(--net2); }
.kicker b { color: var(--net); }
.nav { box-shadow: inset 0 -1px 0 color-mix(in srgb, var(--net) 22%, transparent); }
[data-net-mode="single"] .multi-only { display: none; }
.neticon { display: inline-block; border-radius: 50%; flex: none; vertical-align: middle; }
.kicker__net { display: inline-flex; gap: 4px; margin-right: 6px; }
.kicker__net:empty { display: none; }

.netbadge {
  display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px 0 8px; border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--net) 40%, transparent);
  background: color-mix(in srgb, var(--net) 8%, transparent);
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink);
  transition: border-color .2s, background .2s;
}
.netbadge:hover { border-color: var(--net); background: color-mix(in srgb, var(--net) 16%, transparent); }
.netbadge__icons { display: inline-flex; }
.netbadge__label { white-space: nowrap; }
.netbadge__icons .neticon + .neticon { margin-left: -6px; box-shadow: 0 0 0 2px var(--bg); }
.netbadge__label:empty, .netbadge:has(.netbadge__icons:empty) { display: none; }

.btn--sm { padding: 8px 14px; font-size: 13px; }
.btn--net { background: var(--net); border-color: var(--net); color: #05060d; }
.btn--net:hover { color: #05060d; }
.btn[disabled] { opacity: .35; pointer-events: none; }
.dot--net { background: var(--net); box-shadow: 0 0 10px var(--net); }

/* ---------- contract registry ---------- */
.ca {
  position: relative; overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--net) 35%, transparent);
  background: linear-gradient(135deg, color-mix(in srgb, var(--net) 7%, transparent), transparent 60%), rgba(255,255,255,.015);
  border-radius: 20px; padding: 24px; margin-bottom: 20px;
}
.ca::before { content: ""; position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, var(--net), var(--net2), transparent); }
.ca__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.ca__cta { display: flex; gap: 8px; flex-wrap: wrap; }
.ca__label { display: flex; align-items: center; gap: 10px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); }

.reg { display: grid; gap: 12px; margin-top: 18px; }
.reg__row { border: 1px solid var(--line); border-left: 3px solid var(--c, var(--net)); border-radius: 14px; padding: 14px 16px; background: rgba(0,0,0,.25); display: grid; gap: 12px; }
.reg__nets { display: flex; flex-wrap: wrap; gap: 8px; }
.netchip {
  display: inline-flex; align-items: center; gap: 7px; padding: 4px 11px 4px 5px; border-radius: 999px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--c) 45%, transparent); background: color-mix(in srgb, var(--c) 10%, transparent);
}
.reg__main { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.reg__addr { flex: 1 1 340px; font-family: var(--f-mono); font-size: clamp(12px, 1.3vw, 16px); color: var(--ink); background: rgba(0,0,0,.35); border: 1px solid var(--line); border-radius: 10px; padding: 11px 14px; word-break: break-all; }
.reg__addr--pending { color: var(--warn); letter-spacing: .14em; font-size: 12px; }
.reg__act { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- live market strip ---------- */
.mkt { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 18px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.mkt__cell { padding: 14px 16px; border-right: 1px solid var(--line); display: grid; gap: 4px; }
.mkt__cell:nth-child(4) { border-right: 0; }
.mkt__cell span { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.mkt__cell b { font-family: var(--f-mono); font-weight: 500; font-size: clamp(16px, 1.8vw, 22px); letter-spacing: -.02em; }
.mkt__cell i { font-style: normal; font-family: var(--f-mono); font-size: 11px; }
.mkt__cell i.up { color: var(--ok); } .mkt__cell i.down { color: var(--threat); }
.mkt__src { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; padding: 8px 16px; border-top: 1px solid var(--line); font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- network cards (token page) ---------- */
.netgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.netcard {
  position: relative; border: 1px solid var(--line); border-radius: 18px; padding: 24px; overflow: hidden;
  background: radial-gradient(120% 80% at 0% 0%, color-mix(in srgb, var(--c) 12%, transparent), transparent 60%);
}
.netcard::after { content: ""; position: absolute; inset: auto 0 0; height: 2px; background: linear-gradient(90deg, var(--c), var(--c2), transparent); }
.netcard__head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.netcard__head b { display: block; font-size: 18px; font-weight: 500; }
.netcard__head span { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .08em; text-transform: uppercase; }
.netcard .kv a { color: var(--c); border-bottom: 1px dashed color-mix(in srgb, var(--c) 50%, transparent); }

@media (max-width: 1360px) { .netbadge__label { display: none; } .netbadge { padding: 0 8px; } }
@media (max-width: 700px) {
  .mkt { grid-template-columns: repeat(2, 1fr); }
  .mkt__cell:nth-child(2) { border-right: 0; }
  .mkt__cell:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}
[hidden] { display: none !important; }
