/* ==========================================================================
   HYSTRIX ($HSTX) — DESIGN SYSTEM
   Palette: Deep Obsidian #0D0A16 · Stealth Veil #1B1530 · Ivory #F3EFE6 · Amber #FF9F1C
   Typography: Syne + Instrument Serif + Space Grotesk + Azeret Mono
   ========================================================================== */

:root {
  --bg: #0D0A16;
  --bg-deep: #08060F;
  --surface: #141022;
  --surface-2: #1B1530;
  --surface-3: #241C3E;
  --ivory: #F3EFE6;
  --ivory-dim: #D5CEBF;
  --muted: #9A92B4;
  --dim: #625A7D;
  --amber: #FF9F1C;
  --amber-bright: #FFB347;
  --amber-soft: rgba(255, 159, 28, 0.13);
  --amber-line: rgba(255, 159, 28, 0.36);
  --phantom: #AB9FF2;
  --phantom-soft: rgba(171, 159, 242, 0.14);
  --ok: #3FE0A8;
  --danger: #FF647C;
  --line: rgba(243, 239, 230, 0.09);
  --line-strong: rgba(243, 239, 230, 0.18);

  --f-display: "Syne", sans-serif;
  --f-serif: "Instrument Serif", Georgia, serif;
  --f-sans: "Space Grotesk", system-ui, -apple-system, sans-serif;
  --f-mono: "Azeret Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --wrap: 1240px;
  --nav-h: 76px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  background: var(--bg);
  color: var(--ivory);
  font-family: var(--f-sans);
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  background:
    radial-gradient(950px 520px at 82% -6%, rgba(255, 159, 28, 0.08), transparent 65%),
    radial-gradient(820px 600px at 14% 18%, rgba(86, 61, 156, 0.14), transparent 70%),
    var(--bg);
  color: var(--ivory);
  overflow-x: hidden;
  min-height: 100vh;
}

/* Subtle vertical architectural veil lines across the viewport */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(to right, rgba(243, 239, 230, 0.025) 1px, transparent 1px);
  background-size: calc(100vw / 6) 100%;
}

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

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }

.wrap {
  width: min(var(--wrap), calc(100% - 48px));
  margin-inline: auto;
}

.serif {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.amber { color: var(--amber); }
.ivory { color: var(--ivory); }
.muted { color: var(--muted); }
.mono { font-family: var(--f-mono); }

/* ==========================================================================
   OPENING INTRO ANIMATION
   ========================================================================== */

.intro {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-deep);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: opacity 0.65s var(--ease), visibility 0.65s var(--ease);
}

.intro.leaving {
  opacity: 0;
  pointer-events: none;
}

.intro-stage {
  position: relative;
  width: min(560px, 90vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.intro-veil-scene {
  width: 240px;
  height: 240px;
  position: relative;
}

.intro-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Flying volley lines during phase 1 */
.iq-streak {
  opacity: 0;
  transform: translate(-150px, 42px);
  animation: iqFly 1.05s var(--ease) forwards;
}
.iq-streak.s2 { animation-delay: 0.08s; }
.iq-streak.s3 { animation-delay: 0.16s; }
.iq-streak.s4 { animation-delay: 0.24s; }

@keyframes iqFly {
  0%   { opacity: 0; transform: translate(-170px, 48px); }
  25%  { opacity: 1; }
  75%  { opacity: 1; }
  100% { opacity: 0; transform: translate(170px, -48px); }
}

.intro-crest {
  opacity: 0;
  transform: scale(0.86) translateY(12px);
  transform-origin: center;
  animation: crestLock 0.85s var(--ease) 0.68s forwards;
}

@keyframes crestLock {
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.intro-crest .q-fan {
  transform-origin: 205px 335px;
  transform: scale(0.4);
  opacity: 0;
  animation: fanOut 0.65s cubic-bezier(0.18, 1.25, 0.4, 1) 0.88s forwards;
}

@keyframes fanOut {
  to { transform: scale(1); opacity: 1; }
}

.intro-word {
  display: flex;
  gap: 5px;
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(28px, 4.5vw, 40px);
  letter-spacing: 0.24em;
  text-indent: 0.24em;
  color: var(--ivory);
}

.intro-word span {
  opacity: 0;
  transform: translateY(14px);
  animation: letterUp 0.48s var(--ease) forwards;
}

@keyframes letterUp {
  to { opacity: 1; transform: translateY(0); }
}

.intro-sub {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--amber);
  opacity: 0;
  animation: letterUp 0.55s var(--ease) 1.45s forwards;
}

.intro-bar {
  width: 160px;
  height: 2px;
  background: rgba(243, 239, 230, 0.1);
  overflow: hidden;
  border-radius: 2px;
  margin-top: 4px;
}

.intro-bar::after {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  background: var(--amber);
  transform-origin: left;
  transform: scaleX(0);
  animation: barFill 2.35s linear forwards;
}

@keyframes barFill {
  to { transform: scaleX(1); }
}

.intro-skip {
  position: absolute;
  bottom: 28px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
}

.intro-fly {
  position: fixed;
  z-index: 10000;
  pointer-events: none;
  border-radius: 10px;
  transform-origin: top left;
  transition: transform 0.78s var(--ease), opacity 0.78s var(--ease);
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */

.nav {
  position: sticky;
  top: 0;
  z-index: 90;
  height: var(--nav-h);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(13, 10, 22, 0.72);
  border-bottom: 1px solid var(--line);
  transition: background 0.25s ease, border-color 0.25s ease;
}

.nav::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  height: 1px;
  width: calc(var(--sp, 0) * 100%);
  background: linear-gradient(90deg, var(--amber), #FFD27D);
  pointer-events: none;
}

.nav.scrolled {
  background: rgba(8, 6, 15, 0.92);
  border-bottom-color: var(--line-strong);
}

.nav-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.brand img {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  box-shadow: 0 0 0 1px rgba(243, 239, 230, 0.14);
}

.brand-word {
  font-family: var(--f-display);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.brand-tag {
  font-family: var(--f-mono);
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--amber-line);
  color: var(--amber);
  letter-spacing: 0.08em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(20, 16, 34, 0.65);
  flex: none;
}

.nav-links a {
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover { color: var(--ivory); }

.nav-links a.active {
  color: var(--bg-deep);
  background: var(--ivory);
  font-weight: 600;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.icon-link {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(20, 16, 34, 0.7);
  display: inline-grid;
  place-items: center;
  color: var(--muted);
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
  flex: none;
}

.icon-link:hover {
  color: var(--ivory);
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.icon-link svg { width: 16px; height: 16px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 11px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ivory);
  font-weight: 600;
  font-size: 14.5px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s var(--ease), border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
  border-color: rgba(243, 239, 230, 0.36);
}

.btn-sm {
  padding: 8px 14px;
  font-size: 13px;
  border-radius: 9px;
}

.btn-amber {
  background: var(--amber);
  border-color: var(--amber);
  color: #120D1D;
  font-weight: 700;
}

.btn-amber:hover {
  background: var(--amber-bright);
  border-color: var(--amber-bright);
  box-shadow: 0 10px 28px rgba(255, 159, 28, 0.28);
}

.btn-ivory {
  background: var(--ivory);
  border-color: var(--ivory);
  color: #120D1D;
  font-weight: 700;
}

.btn-ivory:hover {
  background: #FFFFFF;
  border-color: #FFFFFF;
}

.btn-ghost {
  background: rgba(20, 16, 34, 0.55);
  border-color: var(--line);
  color: var(--ivory-dim);
}

.btn-phantom {
  background: linear-gradient(135deg, rgba(171, 159, 242, 0.18), rgba(27, 21, 48, 0.92));
  border-color: rgba(171, 159, 242, 0.42);
  color: var(--ivory);
  flex: none;
}

.btn-phantom:hover {
  border-color: var(--phantom);
  box-shadow: 0 8px 24px rgba(171, 159, 242, 0.22);
}

.btn-phantom .ph-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--phantom);
  box-shadow: 0 0 10px var(--phantom);
}

.btn-phantom.connected {
  border-color: rgba(63, 224, 168, 0.5);
  background: linear-gradient(135deg, rgba(63, 224, 168, 0.14), rgba(20, 16, 34, 0.92));
}

.btn-phantom.connected .ph-dot {
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
}

.burger {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.burger span,
.burger span::before,
.burger span::after {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ivory);
  position: relative;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.burger span::before,
.burger span::after {
  content: "";
  position: absolute;
  left: 0;
}
.burger span::before { top: -6px; }
.burger span::after { top: 6px; }

/* ==========================================================================
   HERO SECTION (HOME)
   ========================================================================== */

.hero {
  position: relative;
  min-height: calc(100vh - var(--nav-h));
  display: flex;
  align-items: center;
  padding: 68px 0 76px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.hero-veil-band {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 19%;
  width: clamp(110px, 11vw, 168px);
  background: linear-gradient(180deg, rgba(31, 24, 56, 0.72), rgba(22, 16, 40, 0.85));
  border-left: 1px solid rgba(243, 239, 230, 0.08);
  border-right: 1px solid rgba(255, 159, 28, 0.18);
  pointer-events: none;
  z-index: 0;
}

.hero-veil-band::after {
  content: "STEALTH VEIL · ECDH ZONE";
  position: absolute;
  top: 28px;
  left: 50%;
  transform: translateX(-50%) rotate(90deg);
  transform-origin: center;
  white-space: nowrap;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.26em;
  color: rgba(243, 239, 230, 0.24);
}

.hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  gap: 48px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--amber-line);
  background: rgba(255, 159, 28, 0.08);
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ivory);
}

.eyebrow .pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 12px var(--amber);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.8); }
}

.hero h1 {
  margin: 22px 0 18px;
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(42px, 5.8vw, 80px);
  line-height: 0.98;
  letter-spacing: -0.03em;
}

.hero h1 .serif {
  font-size: 1.08em;
  color: var(--amber);
  font-weight: 400;
  padding-right: 6px;
}

.lead {
  margin: 0;
  max-width: 600px;
  font-size: clamp(16.5px, 1.35vw, 19px);
  line-height: 1.62;
  color: var(--muted);
}

.lead b, .lead strong { color: var(--ivory); font-weight: 600; }

.hero-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* CONTRACT ADDRESS BOX ON HERO */
.ca-card {
  margin-top: 28px;
  max-width: 640px;
  padding: 16px 18px;
  border-radius: 14px;
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(135deg, rgba(27, 21, 48, 0.92), rgba(16, 12, 28, 0.95));
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.42);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.ca-meta {
  min-width: 0;
  flex: 1 1 260px;
}

.ca-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
}

.ca-kicker .chain-chip {
  padding: 1px 7px;
  border-radius: 4px;
  background: rgba(243, 239, 230, 0.08);
  color: var(--ivory-dim);
}

.ca-addr {
  margin-top: 6px;
  font-family: var(--f-mono);
  font-size: 13.5px;
  color: var(--ivory);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ca-addr.pending {
  color: var(--ivory-dim);
}

.ca-caret {
  display: inline-block;
  width: 7px;
  height: 14px;
  margin-left: 6px;
  vertical-align: -2px;
  background: var(--amber);
  animation: caretBlink 1s steps(2) infinite;
}

@keyframes caretBlink {
  50% { opacity: 0; }
}

.ca-btns {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
}

/* Right-side Hero Live Stealth Inspector Card */
.veil-probe {
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: rgba(17, 13, 29, 0.86);
  backdrop-filter: blur(18px);
  padding: 24px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.55);
  position: relative;
  overflow: hidden;
}

.veil-probe::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--amber), transparent);
}

.probe-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.probe-live {
  color: var(--ok);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.probe-live::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ok);
}

.probe-stage {
  margin: 18px 0;
  display: grid;
  gap: 10px;
}

.probe-row {
  padding: 12px 14px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(10, 8, 18, 0.72);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.probe-row.veil-row {
  border-color: var(--amber-line);
  background: rgba(255, 159, 28, 0.06);
}

.probe-lbl {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.probe-val {
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ivory);
}

.probe-badge {
  font-family: var(--f-mono);
  font-size: 10.5px;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(63, 224, 168, 0.13);
  color: var(--ok);
  border: 1px solid rgba(63, 224, 168, 0.3);
}

.probe-foot {
  padding-top: 14px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}

/* ==========================================================================
   TICKER MARQUEE
   ========================================================================== */

.marquee {
  border-bottom: 1px solid var(--line);
  background: var(--bg-deep);
  overflow: hidden;
  padding: 13px 0;
}

.marquee-track {
  display: flex;
  width: max-content;
  gap: 38px;
  animation: marqueeScroll 32s linear infinite;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.marquee-track span {
  display: inline-flex;
  align-items: center;
  gap: 38px;
}

.marquee-track span::after {
  content: "✦";
  color: var(--amber);
  font-size: 10px;
}

@keyframes marqueeScroll {
  to { transform: translateX(-50%); }
}

/* ==========================================================================
   SECTIONS, HEADINGS & PAGE HEADERS
   ========================================================================== */

section {
  padding: 96px 0;
  border-bottom: 1px solid var(--line);
}

.page-hero {
  padding: 74px 0 62px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(760px 360px at 86% 15%, rgba(255, 159, 28, 0.09), transparent 70%),
    linear-gradient(180deg, rgba(20, 16, 34, 0.6), transparent);
}

.page-hero h1 {
  margin: 18px 0 16px;
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(36px, 4.8vw, 66px);
  line-height: 1.02;
  letter-spacing: -0.025em;
}

.page-hero h1 .serif {
  color: var(--amber);
  font-size: 1.08em;
}

.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 52px;
  flex-wrap: wrap;
}

.sec-kicker {
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.sec-kicker::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--amber);
}

.sec-head h2 {
  margin: 12px 0 0;
  font-family: var(--f-display);
  font-weight: 800;
  font-size: clamp(30px, 3.7vw, 50px);
  line-height: 1.06;
  letter-spacing: -0.025em;
  max-width: 720px;
}

.sec-head h2 .serif {
  color: var(--amber);
  font-size: 1.08em;
}

.sec-note {
  max-width: 400px;
  color: var(--muted);
  font-size: 15.5px;
  margin: 0;
}

/* ==========================================================================
   CARDS, GRIDS & DIAGRAMS
   ========================================================================== */

.g2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.g3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.g4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }

.card {
  padding: 28px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(22, 17, 38, 0.85), rgba(14, 11, 24, 0.9));
  position: relative;
  transition: border-color 0.25s ease, transform 0.25s var(--ease);
}

.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}

.card-idx {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--amber);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card h3 {
  margin: 0 0 10px;
  font-family: var(--f-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.62;
}

/* Exposed vs Veiled visual diagram */
.graph-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.graph-box {
  padding: 26px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.graph-box.good {
  border-color: var(--amber-line);
  background: linear-gradient(165deg, rgba(27, 21, 48, 0.92), rgba(15, 11, 25, 0.96));
}

.graph-tag {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 6px;
  margin-bottom: 14px;
}

.graph-tag.bad {
  background: rgba(255, 100, 124, 0.12);
  color: var(--danger);
  border: 1px solid rgba(255, 100, 124, 0.3);
}

.graph-tag.ok {
  background: var(--amber-soft);
  color: var(--amber);
  border: 1px solid var(--amber-line);
}

/* ==========================================================================
   HOLDER TIER CARDS
   ========================================================================== */

.tier-card {
  padding: 26px 24px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(20, 16, 34, 0.9), rgba(12, 9, 20, 0.95));
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  position: relative;
}

.tier-card.featured {
  border-color: var(--amber);
  background: linear-gradient(180deg, rgba(38, 28, 64, 0.92), rgba(16, 12, 28, 0.96));
  box-shadow: 0 20px 52px rgba(255, 159, 28, 0.12);
}

.tier-card.active-user-tier {
  outline: 2px solid var(--ok);
  outline-offset: 2px;
}

.tier-ribbon {
  position: absolute;
  top: -11px;
  right: 18px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--amber);
  color: #120D1D;
  font-family: var(--f-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tier-rank {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--muted);
  text-transform: uppercase;
}

.tier-name {
  margin: 6px 0 4px;
  font-family: var(--f-display);
  font-size: 26px;
  font-weight: 800;
}

.tier-hold {
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--amber);
}

.tier-fee-box {
  margin: 16px 0;
  padding: 14px;
  border-radius: 12px;
  background: rgba(8, 6, 15, 0.68);
  border: 1px solid var(--line);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.tier-fee-num {
  font-family: var(--f-display);
  font-size: 32px;
  font-weight: 800;
  color: var(--ivory);
}

.tier-card.featured .tier-fee-num { color: var(--amber); }

.tier-perks {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
  font-size: 14px;
  color: var(--ivory-dim);
}

.tier-perks li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  line-height: 1.45;
}

.tier-perks li::before {
  content: "▸";
  color: var(--amber);
  font-family: var(--f-mono);
  flex: none;
}

/* ==========================================================================
   INTERACTIVE CONSOLE / CALCULATORS / CODE BLOCKS
   ========================================================================== */

.console-shell {
  border-radius: 20px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  overflow: hidden;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.5);
}

.console-tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
  background: var(--bg-deep);
  overflow-x: auto;
}

.console-tab {
  padding: 16px 24px;
  border: none;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease;
}

.console-tab:hover { color: var(--ivory); }

.console-tab.active {
  background: var(--surface);
  color: var(--amber);
  box-shadow: inset 0 -2px 0 var(--amber);
}

.console-pane {
  display: none;
  padding: 32px;
}

.console-pane.active {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px;
}

.field {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.field label {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
}

.input, select.input {
  width: 100%;
  padding: 13px 15px;
  border-radius: 11px;
  border: 1px solid var(--line-strong);
  background: var(--bg-deep);
  color: var(--ivory);
  font-family: var(--f-mono);
  font-size: 13.5px;
  outline: none;
  transition: border-color 0.2s ease;
}

.input:focus {
  border-color: var(--amber);
}

.seg-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.seg-btn {
  padding: 8px 14px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--bg-deep);
  color: var(--muted);
  font-family: var(--f-mono);
  font-size: 12px;
  cursor: pointer;
}

.seg-btn.active {
  border-color: var(--amber);
  background: var(--amber-soft);
  color: var(--amber);
}

.out-panel {
  padding: 24px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--bg-deep);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.kv-list {
  display: grid;
  gap: 12px;
}

.kv-item {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(20, 16, 34, 0.55);
}

.kv-item .k {
  font-family: var(--f-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

.kv-item .v {
  font-family: var(--f-mono);
  font-size: 12.5px;
  color: var(--ivory);
  word-break: break-all;
}

.kv-item .v.amber { color: var(--amber); }
.kv-item .v.ok { color: var(--ok); }

/* Code / Spec Block */
.code-card {
  padding: 24px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: var(--bg-deep);
  font-family: var(--f-mono);
  font-size: 13px;
  line-height: 1.75;
  color: var(--ivory-dim);
  overflow-x: auto;
}

.code-card .cm { color: var(--dim); }
.code-card .kw { color: var(--amber); }
.code-card .fn { color: var(--phantom); }
.code-card .ok { color: var(--ok); }

/* Table */
.spec-table-wrap {
  border-radius: 16px;
  border: 1px solid var(--line);
  overflow-x: auto;
  background: var(--surface);
}

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

.spec-table th,
.spec-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px;
}

.spec-table th {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--bg-deep);
}

.spec-table tr:last-child td { border-bottom: none; }

/* Roadmap Timeline */
.roadmap-grid {
  display: grid;
  gap: 22px;
}

.phase-card {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 28px;
  padding: 30px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(20, 16, 34, 0.88), rgba(12, 9, 20, 0.94));
}

.phase-card.current {
  border-color: var(--amber);
  box-shadow: 0 18px 48px rgba(255, 159, 28, 0.1);
}

.phase-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
}

.phase-card.current .phase-status {
  border-color: var(--amber);
  background: var(--amber-soft);
  color: var(--amber);
}

.phase-list {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 22px;
}

.phase-list li {
  display: flex;
  gap: 10px;
  font-size: 14.5px;
  color: var(--ivory-dim);
}

.phase-list li::before {
  content: "◆";
  color: var(--amber);
  font-size: 10px;
  margin-top: 4px;
}

/* CTA Band */
.cta-band {
  padding: 44px;
  border-radius: 22px;
  border: 1px solid var(--amber-line);
  background:
    radial-gradient(600px 260px at 90% 50%, rgba(255, 159, 28, 0.16), transparent 70%),
    linear-gradient(135deg, var(--surface-2), var(--bg-deep));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}

.cta-band h2 {
  margin: 8px 0 0;
  font-family: var(--f-display);
  font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.08;
}

/* ==========================================================================
   PHANTOM WALLET MODAL
   ========================================================================== */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 950;
  background: rgba(5, 4, 10, 0.78);
  backdrop-filter: blur(10px);
  display: none;
  place-items: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: grid;
}

.modal {
  width: min(460px, 100%);
  border-radius: 20px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  padding: 26px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.68);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.modal-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--f-display);
  font-weight: 700;
  font-size: 19px;
}

.modal-close {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--bg-deep);
  cursor: pointer;
  color: var(--muted);
}

.modal-body {
  padding-top: 18px;
  display: grid;
  gap: 14px;
}

/* ==========================================================================
   FOOTER & TOAST
   ========================================================================== */

.footer {
  padding: 54px 0 42px;
  background: var(--bg-deep);
}

.footer-grid {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 36px;
  flex-wrap: wrap;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
}

.footer-nav {
  display: flex;
  gap: 44px;
  flex-wrap: wrap;
}

.footer-col {
  display: grid;
  gap: 9px;
}

.footer-col h4 {
  margin: 0 0 4px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
}

.footer-col a, .footer-col button {
  font-size: 14px;
  color: var(--muted);
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.footer-col a:hover, .footer-col button:hover { color: var(--ivory); }

.footer-bottom {
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-family: var(--f-mono);
  font-size: 11.5px;
  color: var(--dim);
}

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1200;
  padding: 12px 18px;
  border-radius: 11px;
  border: 1px solid var(--amber-line);
  background: rgba(14, 11, 24, 0.96);
  color: var(--ivory);
  font-family: var(--f-mono);
  font-size: 12.5px;
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.55);
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* Scroll Reveal */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 1024px) {
  .hero-grid,
  .console-pane.active,
  .graph-compare {
    grid-template-columns: 1fr;
  }
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .phase-card { grid-template-columns: 1fr; }
  .hero-veil-band { opacity: 0.35; right: 8%; }
}

@media (max-width: 820px) {
  .nav-links {
    position: fixed;
    top: calc(var(--nav-h) + 8px);
    left: 16px;
    right: 16px;
    flex-direction: column;
    align-items: stretch;
    border-radius: 16px;
    padding: 10px;
    background: rgba(12, 9, 21, 0.98);
    border-color: var(--line-strong);
    display: none;
  }
  .nav.open .nav-links { display: flex; }
  .burger { display: inline-flex; }
  .g2, .g3, .g4, .phase-list { grid-template-columns: 1fr; }
  .wrap { width: calc(100% - 32px); }
  section { padding: 68px 0; }
  .cta-band { padding: 28px; }
}
