/* =====================================================================
   PROJECT404 — cinematic landing site
   Layers on top of DesignSystem/css/styles.css.
   Adds: matte/obsidian palette, emerald glow, HUD chrome, boot, hero,
   division modules, AI network stage, community ticker, intel terminal,
   final skyline scene.
   ===================================================================== */

/* ---------- tokens (extending design system) ---------- */
.p404 {
  /* obsidian/graphite layered base — darker than design system default */
  --ob-0:   #04060a;   /* deepest */
  --ob-1:   #060a10;
  --ob-2:   #0a0f17;
  --ob-3:   #0e1622;
  --ob-4:   #131c2a;

  /* soft emerald — primary glow */
  --em:        #00ff9c;
  --em-soft:   #2bffb3;
  --em-deep:   #00b574;
  --em-glow:   rgba(0,255,156,0.42);
  --em-halo:   rgba(0,255,156,0.10);
  --em-line:   rgba(0,255,156,0.22);
  --em-faint:  rgba(0,255,156,0.06);

  /* cyan stays as data-highlight only */
  --cy:        #00e5ff;
  --cy-line:   rgba(0,229,255,0.22);
  --cy-halo:   rgba(0,229,255,0.10);

  --text-mut:  #8fa1b0;
  --text-faint: #4a5868;

  --hud-line:  rgba(255,255,255,0.08);
  --hud-line-strong: rgba(255,255,255,0.16);
}

/* push base body into matte black */
body.p404 {
  background:
    radial-gradient(1200px 700px at 80% -10%, rgba(0,255,156,0.05), transparent 60%),
    radial-gradient(900px 500px at 5% 30%, rgba(0,229,255,0.035), transparent 60%),
    radial-gradient(800px 600px at 50% 100%, rgba(0,255,156,0.04), transparent 70%),
    #04060a;
  color: #e6ecf2;
  font-family: var(--font-body);
  overflow-x: hidden;
}

::selection { background: rgba(0,255,156,0.22); color: #fff; }

/* Nav is fixed (~60px). Anchor-target sections need a top offset so their
   first content line isn't hidden under it. The design system's
   scroll-behavior: smooth on html handles the easing for #anchor jumps. */
section[data-section], #top { scroll-margin-top: 80px; }

/* lock body scroll while boot runs */
body.p404.is-booting { overflow: hidden; height: 100vh; }
/* hide hero text under the boot overlay until boot finishes (GSAP takes over after) */
body.p404.is-booting .hero__title,
body.p404.is-booting .hero__sub,
body.p404.is-booting .hero__support,
body.p404.is-booting .hero__ctas,
body.p404.is-booting .hero__chip,
body.p404.is-booting .hero__loc,
body.p404.is-booting .hero__hud,
body.p404.is-booting .hero__scroll { opacity: 0; }

/* ===================================================================
   PERSISTENT BACKGROUND (env)
   =================================================================== */
.env {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  overflow: hidden;
}
.env #envCanvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0.85;
}
.env__grid {
  position: absolute; inset: -20%;
  background-image:
    linear-gradient(rgba(0,255,156,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,156,0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 50%, #000 35%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 50%, #000 35%, transparent 75%);
  animation: env-grid-drift 60s linear infinite;
  opacity: 0.7;
}
@keyframes env-grid-drift {
  from { transform: translate3d(0,0,0); }
  to   { transform: translate3d(-64px,-64px,0); }
}
.env__haze {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 40% at 50% 110%, rgba(0,255,156,0.10), transparent 60%),
    radial-gradient(ellipse 60% 30% at 20% 30%, rgba(0,229,255,0.05), transparent 70%);
  filter: blur(20px);
  animation: env-haze 18s ease-in-out infinite alternate;
}
@keyframes env-haze {
  from { opacity: 0.7; transform: translate3d(0,0,0); }
  to   { opacity: 1;   transform: translate3d(-2%,-1%,0); }
}
.env__scanline {
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0) 0,
    rgba(255,255,255,0) 2px,
    rgba(255,255,255,0.015) 3px,
    rgba(255,255,255,0) 4px
  );
  mix-blend-mode: overlay;
  pointer-events: none;
}
.env__vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 50%, transparent 50%, rgba(0,0,0,0.55) 100%),
    linear-gradient(to bottom, rgba(0,0,0,0.35), transparent 25%, transparent 75%, rgba(0,0,0,0.5));
}
/* .env__noise removed 2026-05-20 — full-viewport mix-blend-mode overlay was
   repainting ~4×/sec. The grain it added wasn't load-bearing for the look. */
.env__noise { display: none; }

/* ===================================================================
   PERSISTENT HUD (corners, telemetry, ticker)
   =================================================================== */
.hud {
  position: fixed; inset: 0; z-index: 50;
  pointer-events: none;
}
.hud__corner {
  position: absolute;
  width: 26px; height: 26px;
  border: 1px solid var(--em-line);
  opacity: 0.6;
}
.hud__corner--tl { top: 14px; left: 14px; border-right: none; border-bottom: none; }
.hud__corner--tr { top: 14px; right: 14px; border-left: none; border-bottom: none; }
.hud__corner--bl { bottom: 60px; left: 14px; border-right: none; border-top: none; }
.hud__corner--br { bottom: 60px; right: 14px; border-left: none; border-top: none; }

.hud__telemetry {
  position: absolute; top: 78px; right: 24px;
  display: flex; gap: 18px;
  font-size: 10.5px; color: var(--text-mut);
  letter-spacing: 0.06em;
}
.hud__telemetry em { color: #e6ecf2; font-style: normal; }
.hud__telemetry i.hud__dot,
.hud__dot {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 8px var(--em-glow), 0 0 14px var(--em-halo);
  margin-right: 6px;
  animation: hud-blink 1.6s ease-in-out infinite;
}
@keyframes hud-blink { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

.hud__ticker {
  position: absolute; bottom: 14px; left: 14px; right: 14px;
  height: 28px;
  border: 1px solid var(--hud-line);
  background: linear-gradient(180deg, rgba(7,14,12,0.78), rgba(7,14,12,0.88));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  overflow: hidden;
  display: flex; align-items: center;
}
.hud__ticker::before {
  content: ""; width: 8px; height: 100%;
  background: linear-gradient(180deg, var(--em), var(--em-deep));
  box-shadow: 0 0 14px var(--em-glow);
  flex: 0 0 auto;
}
.hud__ticker-track {
  display: flex; gap: 36px;
  font-size: 10.5px;
  color: var(--text-mut);
  letter-spacing: 0.08em;
  white-space: nowrap;
  padding-left: 18px;
  animation: ticker 60s linear infinite;
}
.hud__ticker-track span b { color: #e6ecf2; font-weight: 500; }
.hud__ticker-track span em { color: var(--em); font-style: normal; }
@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@media (max-width: 760px) {
  .hud__telemetry { display: none; }
  .hud__corner--bl, .hud__corner--br { bottom: 50px; }
}

/* ===================================================================
   NAV
   =================================================================== */
.p404-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 60;
  padding: 16px 28px;
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}
.p404-nav.is-scrolled {
  background: rgba(4,7,12,0.72); /* slightly more opaque to compensate for lower blur */
  backdrop-filter: blur(10px) saturate(1.4);
  -webkit-backdrop-filter: blur(10px) saturate(1.4);
  border-bottom-color: var(--em-line);
}
.p404-nav__inner {
  max-width: 1320px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  gap: 28px;
}
.p404-nav__brand {
  display: flex; align-items: center; gap: 10px;
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.18em;
  font-size: 14px; color: #fff;
}
.p404-nav__brand-mark { color: var(--em); filter: drop-shadow(0 0 8px var(--em-glow)); }
.p404-nav__brand-text { color: #fff; }
.p404-nav__brand-sub {
  color: var(--text-mut); font-family: var(--font-mono);
  font-weight: 400; font-size: 10px; letter-spacing: 0.18em;
  margin-left: 2px;
}
.p404-nav__links {
  display: flex; align-items: center; gap: 20px;
  font-family: var(--font-mono); font-size: 10.5px;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--text-mut);
}
.p404-nav__links a { transition: color .25s, opacity .25s; position: relative; }
.p404-nav__links a:hover { color: #fff; }
.p404-nav__links a.is-active { color: #fff; }
.p404-nav__links a.is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -8px;
  height: 1px; background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
}
.p404-nav__cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--em-line);
  background: linear-gradient(180deg, rgba(0,255,156,0.06), rgba(0,255,156,0.02));
  color: #fff !important;
  border-radius: 2px;
  transition: all .25s;
  position: relative; overflow: hidden;
}
.p404-nav__cta:hover {
  border-color: var(--em);
  box-shadow: 0 0 14px var(--em-glow), inset 0 0 18px var(--em-halo);
}
/* mobile menu (hamburger) — hidden on desktop, shown <= 760px */
.p404-nav__toggle {
  display: none;
  width: 38px; height: 38px;
  background: transparent; border: 1px solid var(--em-line);
  border-radius: 2px;
  position: relative;
  cursor: pointer;
}
.p404-nav__toggle span {
  position: absolute; left: 9px; right: 9px; height: 1px;
  background: var(--em);
  transition: transform .3s, opacity .3s, top .3s;
}
.p404-nav__toggle span:nth-child(1) { top: 12px; }
.p404-nav__toggle span:nth-child(2) { top: 18px; }
.p404-nav__toggle span:nth-child(3) { top: 24px; }
.p404-nav__toggle.is-open span:nth-child(1) { top: 18px; transform: rotate(45deg); }
.p404-nav__toggle.is-open span:nth-child(2) { opacity: 0; }
.p404-nav__toggle.is-open span:nth-child(3) { top: 18px; transform: rotate(-45deg); }

/* Hamburger kicks in below 1180px — the 9-item desktop nav only fits
   reliably at 1180px+. Tablets and narrower get the slide-down menu. */
@media (max-width: 1180px) {
  .p404-nav__toggle { display: block; }
  .p404-nav__brand-sub { display: none; }

  .p404-nav__links {
    position: fixed; top: 60px; left: 0; right: 0;
    background: linear-gradient(180deg, rgba(4,7,12,0.96), rgba(4,7,12,0.99));
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--em-line);
    border-bottom: 1px solid var(--em-line);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 18px 16px;
    transform: translateY(-110%);
    transition: transform .35s ease;
    pointer-events: none;
    max-height: calc(100vh - 60px); overflow-y: auto;
  }
  .p404-nav__links.is-open { transform: translateY(0); pointer-events: auto; }
  .p404-nav__links a {
    padding: 14px 4px;
    border-bottom: 1px solid var(--hud-line);
    font-size: 13px;
    letter-spacing: 0.2em;
  }
  .p404-nav__links a.is-active::after { display: none; } /* underline doesn't read well in stacked menu */
  .p404-nav__links a:last-child { border-bottom: none; margin-top: 10px; }
  .p404-nav__cta { justify-content: space-between; }
}
@media (max-width: 760px) {
  .p404-nav { padding: 14px 18px; }
}

/* ===================================================================
   BOOT SEQUENCE
   =================================================================== */
.boot {
  position: fixed; inset: 0; z-index: 200;
  background: radial-gradient(ellipse at 50% 50%, #060a0e 0%, #02040a 60%, #000 100%);
  display: grid; place-items: center;
  overflow: hidden;
  transition: opacity .9s ease, transform .9s ease, filter .9s ease;
}
.boot.is-done { opacity: 0; transform: scale(1.04); filter: blur(8px); pointer-events: none; }

.boot__grid {
  position: absolute; inset: -30%;
  background-image:
    linear-gradient(rgba(0,255,156,0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,156,0.07) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 30%, transparent 80%);
  animation: boot-grid 30s linear infinite;
}
@keyframes boot-grid {
  from { transform: translate(0,0) rotate(0deg); }
  to   { transform: translate(-40px,-40px) rotate(360deg); }
}
.boot__scan {
  position: absolute; left: 0; right: 0; top: -10%;
  height: 24%;
  background: linear-gradient(to bottom, transparent 0%, rgba(0,255,156,0.06) 50%, transparent 100%);
  filter: blur(8px);
  animation: boot-scan 4.5s linear infinite;
}
@keyframes boot-scan { from { transform: translateY(0); } to { transform: translateY(540%); } }

.boot__core {
  position: relative;
  display: grid; place-items: center;
  width: min(640px, 92vw);
  gap: 22px;
}
.boot__ring {
  width: 280px; height: 280px;
  margin-bottom: -180px;
  filter: drop-shadow(0 0 16px var(--em-glow));
}
.boot__ring-spin { transform-origin: 100px 100px; animation: ring-spin 8s linear infinite; }
.boot__ring-spin--rev { animation: ring-spin 6s linear infinite reverse; }
@keyframes ring-spin { from { transform: rotate(0); } to { transform: rotate(360deg); } }

.boot__brand { text-align: center; padding-top: 140px; }
.boot__brand-eyebrow { color: var(--em); letter-spacing: 0.28em; opacity: 0.9; }
.boot__brand-mark {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.18em;
  font-size: clamp(36px, 6vw, 64px);
  color: #fff;
  margin-top: 6px;
  text-shadow: 0 0 28px var(--em-glow);
  animation: boot-flicker 6s steps(1) infinite;
}
@keyframes boot-flicker {
  0%, 18%, 22%, 50%, 54%, 100% { opacity: 1; }
  19%, 21% { opacity: 0.6; }
  52%      { opacity: 0.85; }
}
.boot__brand-sub { color: var(--text-mut); letter-spacing: 0.32em; font-size: 10.5px; margin-top: 10px; }

.boot__diag {
  width: 100%;
  display: grid; gap: 6px;
}
.boot__bar {
  height: 6px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--em-line);
  position: relative; overflow: hidden;
}
.boot__bar-fill {
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 0%;
  background: linear-gradient(90deg, var(--em-deep), var(--em));
  box-shadow: 0 0 10px var(--em-glow);
  transition: width .12s linear;
}
.boot__bar-fill::after {
  content: ""; position: absolute; right: 0; top: -2px; bottom: -2px; width: 10px;
  background: linear-gradient(90deg, transparent, var(--em));
  filter: blur(2px);
}
.boot__bar-meta { display: flex; justify-content: space-between; color: var(--text-mut); font-size: 10.5px; }
.boot__bar-handshake { color: var(--em); }

.boot__log {
  width: 100%;
  list-style: none;
  font-size: 10.5px;
  color: var(--text-mut);
  letter-spacing: 0.06em;
  display: grid; gap: 3px;
  min-height: 84px;
  padding-top: 6px;
  border-top: 1px solid var(--hud-line);
}
.boot__log li {
  display: flex; gap: 10px;
  opacity: 0; transform: translateY(4px);
  transition: opacity .25s, transform .25s;
}
.boot__log li.is-on { opacity: 1; transform: none; }
.boot__log li time {
  color: var(--em); flex: 0 0 80px;
  font-style: normal;
}
.boot__log li b { color: #e6ecf2; font-weight: 500; }

.boot__signoff {
  display: flex; align-items: center; gap: 10px;
  color: var(--em);
  font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: 0.18em;
  opacity: 0; transform: translateY(8px);
  transition: opacity .6s ease .2s, transform .6s ease .2s;
}
.boot.is-armed .boot__signoff { opacity: 1; transform: none; }
.boot__signoff-dot {
  display: inline-block; width: 8px; height: 8px;
  background: var(--em);
  box-shadow: 0 0 12px var(--em-glow);
  animation: hud-blink 1.2s infinite;
}

.boot__corner {
  position: absolute;
  font-family: var(--font-mono); font-size: 10px;
  color: var(--text-mut);
  letter-spacing: 0.14em;
  line-height: 1.7;
}
.boot__corner--tl { top: 22px; left: 24px; }
.boot__corner--tr { top: 22px; right: 24px; text-align: right; }
.boot__corner--bl { bottom: 22px; left: 24px; }
.boot__corner--br { bottom: 22px; right: 24px; text-align: right; }

/* ===================================================================
   HERO
   =================================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  padding-top: 120px; padding-bottom: 80px;
  z-index: 1;
}
.hero__layout {
  position: relative;
  display: grid; gap: 26px;
  min-height: calc(100vh - 220px);
  grid-template-columns: 1fr;
}

.hero__meta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
}
.hero__chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--em-line);
  background: linear-gradient(180deg, rgba(0,255,156,0.07), rgba(0,255,156,0.02));
  color: #fff;
  letter-spacing: 0.2em;
  font-size: 10px;
}
.hero__chip-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 8px var(--em-glow);
  animation: hud-blink 1.6s infinite;
}
.hero__loc { color: var(--text-mut); letter-spacing: 0.18em; font-size: 10.5px; }

.hero__title {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 0.95;
  font-size: clamp(36px, 6.4vw, 88px);
  color: #fff;
  text-shadow:
    0 0 12px rgba(0,255,156,0.14),
    0 0 40px rgba(0,255,156,0.08);
  margin: 18px 0 0;
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.32em; /* the visible space between PROJECT and 404 */
}
.hero__title-word { display: inline-block; }
.hero__title-404 {
  color: var(--em);
  margin-left: 0; /* the parent flex gap handles spacing now */
  position: relative;
  text-shadow: 0 0 18px var(--em-glow), 0 0 44px rgba(0,255,156,0.20);
}
.hero__title-404::after {
  content: "404";
  position: absolute; inset: 0;
  color: rgba(0,229,255,0.35);
  transform: translate(2px, 0);
  filter: blur(0.3px);
  mix-blend-mode: screen;
  animation: glitch-shift 6s infinite steps(1);
  pointer-events: none;
}
@keyframes glitch-shift {
  0%, 92%, 100% { transform: translate(2px, 0); opacity: 0.5; }
  93%           { transform: translate(-3px, 1px); opacity: 0.8; }
  95%           { transform: translate(4px, -1px); opacity: 0.4; }
  97%           { transform: translate(-2px, 0); opacity: 0.7; }
}

.hero__sub {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.4vw, 30px);
  color: #e6ecf2;
  max-width: 700px;
  margin-top: 8px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.hero__support {
  color: var(--text-mut);
  font-size: 11px;
  letter-spacing: 0.32em;
  margin-top: 4px;
}

.hero__ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 16px; }

/* Floating HUD widgets — absolute on desktop, stacked on mobile */
.hero__hud {
  position: absolute;
  width: 240px;
  padding: 14px 16px;
  background:
    linear-gradient(180deg, rgba(10,16,22,0.88), rgba(6,10,14,0.94)),
    radial-gradient(ellipse at top right, rgba(0,255,156,0.10), transparent 60%);
  border: 1px solid var(--em-line);
  border-radius: 2px;
  backdrop-filter: blur(8px) saturate(1.3);
  -webkit-backdrop-filter: blur(8px) saturate(1.3);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.02) inset,
    0 18px 50px rgba(0,0,0,0.5),
    0 0 30px rgba(0,255,156,0.08);
}
.hero__hud::before, .hero__hud::after {
  content: ""; position: absolute;
  width: 12px; height: 12px;
  border: 1px solid var(--em);
}
.hero__hud::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.hero__hud::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }
/* HUD widget positioning. HUDs sit BEHIND hero text via z-index below.
   hud--b moved further off-canvas (was -4%) so it doesn't crawl into the
   hero sub line on medium-desktop widths. */
.hero__hud--a { top: 200px; right: -8%; animation: float-a 7s ease-in-out infinite alternate; }
.hero__hud--b { bottom: 90px;  left: -18%; animation: float-b 8s ease-in-out infinite alternate; }
.hero__hud--c { bottom: 12%;   right: 4%;  animation: float-c 9s ease-in-out infinite alternate; width: 280px; }

/* Hero text always wins the stacking order over the decorative HUDs */
.hero__meta, .hero__title, .hero__sub, .hero__support, .hero__ctas, .hero__scroll {
  position: relative; z-index: 3;
}
.hero__hud { z-index: 1; }
@keyframes float-a { from { transform: translate(0,0); } to { transform: translate(-6px,8px); } }
@keyframes float-b { from { transform: translate(0,0); } to { transform: translate(6px,-6px); } }
@keyframes float-c { from { transform: translate(0,0); } to { transform: translate(-4px,-10px); } }

.hero__hud-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: 0.18em;
  color: var(--text-mut);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--hud-line);
}
.hero__hud-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 8px var(--em-glow);
}
.hero__hud-dot--alt { background: var(--cy); box-shadow: 0 0 8px rgba(0,229,255,0.55); }
.hero__hud-dot--ok  { background: var(--em); }

.hero__hud-rows {
  display: grid; gap: 6px;
  margin: 10px 0 6px;
  font-family: var(--font-mono); font-size: 11px;
}
.hero__hud-rows div { display: flex; justify-content: space-between; }
.hero__hud-rows span { color: var(--text-faint); letter-spacing: 0.14em; }
.hero__hud-rows b   { color: #fff; font-weight: 500; }

.hero__hud-spark {
  height: 26px; margin-top: 6px;
  background:
    linear-gradient(180deg, transparent 0%, rgba(0,255,156,0.10) 100%);
  position: relative;
  overflow: hidden;
}
.hero__hud-spark::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle 2px at 5% 60%, var(--em), transparent),
    radial-gradient(circle 2px at 15% 40%, var(--em), transparent),
    radial-gradient(circle 2px at 26% 70%, var(--em), transparent),
    radial-gradient(circle 2px at 38% 30%, var(--em), transparent),
    radial-gradient(circle 2px at 50% 60%, var(--em), transparent),
    radial-gradient(circle 2px at 62% 20%, var(--em), transparent),
    radial-gradient(circle 2px at 75% 65%, var(--em), transparent),
    radial-gradient(circle 2px at 88% 35%, var(--em), transparent),
    radial-gradient(circle 2px at 96% 55%, var(--em), transparent);
  filter: drop-shadow(0 0 4px var(--em-glow));
}
.hero__hud-spark::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(0,255,156,0.18), transparent);
  background-size: 30% 100%;
  background-repeat: no-repeat;
  animation: spark-sweep 2.4s linear infinite;
}
@keyframes spark-sweep {
  from { background-position: -30% 0; }
  to   { background-position: 130% 0; }
}

.hero__hud-bars {
  display: flex; gap: 4px;
  align-items: flex-end;
  height: 56px;
  margin-top: 8px;
}
.hero__hud-bars span {
  flex: 1;
  height: var(--v);
  background: linear-gradient(180deg, var(--em-soft), var(--em-deep));
  box-shadow: 0 0 6px var(--em-glow);
  animation: bar-pulse 2.2s ease-in-out infinite;
  transform-origin: bottom;
}
.hero__hud-bars span:nth-child(2n) { animation-delay: .2s; }
.hero__hud-bars span:nth-child(3n) { animation-delay: .4s; }
.hero__hud-bars span:nth-child(5n) { animation-delay: .8s; }
@keyframes bar-pulse {
  0%, 100% { transform: scaleY(1); filter: brightness(1); }
  50%      { transform: scaleY(0.65); filter: brightness(1.2); }
}

.hero__scroll {
  position: absolute; bottom: -10px; left: 0; right: 0;
  display: flex; align-items: center; justify-content: center;
  gap: 16px;
  color: var(--text-mut);
  font-size: 10.5px; letter-spacing: 0.28em;
}
.hero__scroll-bar {
  position: relative; width: 80px; height: 1px;
  background: var(--hud-line-strong);
  display: inline-block;
}
.hero__scroll-bar i {
  position: absolute; top: -1px; left: 0;
  width: 24px; height: 3px;
  background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
  animation: scroll-cue 2.4s ease-in-out infinite;
}
@keyframes scroll-cue {
  0%, 100% { transform: translateX(0); }
  50%      { transform: translateX(56px); }
}

@media (max-width: 980px) {
  .hero__hud--a, .hero__hud--b, .hero__hud--c { position: relative; right: auto; left: auto; bottom: auto; top: auto; width: 100%; margin-top: 12px; animation: none; }
  .hero__layout { min-height: auto; }
  .hero__title { font-size: clamp(56px, 16vw, 110px); }
}

/* ===================================================================
   SHARED — section eyebrows, headings, buttons
   =================================================================== */
.section-eyebrow {
  display: flex; align-items: center; gap: 14px;
  padding-top: 80px;
  color: var(--text-mut);
  letter-spacing: 0.28em;
  font-size: 10.5px;
}
.section-eyebrow__bar {
  width: 36px; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent);
}
.section-eyebrow__id { margin-left: auto; }

.section-head {
  margin-top: 18px;
  display: grid; gap: 14px;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  align-items: end;
  padding-bottom: 36px;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.02;
  font-size: clamp(32px, 4.4vw, 64px);
  color: #fff;
  max-width: 14ch;
}
.section-lede {
  color: var(--text-mut);
  font-size: 16px; line-height: 1.6;
  max-width: 56ch;
}
@media (max-width: 860px) {
  .section-head { grid-template-columns: 1fr; }
}

/* Buttons */
.btn-p404 {
  position: relative;
  display: inline-flex; align-items: center;
  padding: 14px 22px;
  border: 1px solid var(--hud-line-strong);
  background: linear-gradient(180deg, rgba(10,16,22,0.7), rgba(6,10,14,0.85));
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11.5px; letter-spacing: 0.22em; text-transform: uppercase;
  cursor: pointer;
  transition: border-color .3s, color .3s, background .3s, transform .25s, box-shadow .3s;
  overflow: hidden;
  border-radius: 2px;
}
.btn-p404::before, .btn-p404::after {
  content: ""; position: absolute;
  width: 8px; height: 8px;
  border: 1px solid var(--em);
  opacity: 0; transition: opacity .3s;
}
.btn-p404::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.btn-p404::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }
.btn-p404:hover::before, .btn-p404:hover::after { opacity: 1; }
.btn-p404:hover {
  border-color: var(--em-line);
  box-shadow: 0 0 0 1px var(--em-halo), 0 14px 40px rgba(0,255,156,0.1), inset 0 0 30px rgba(0,255,156,0.05);
}
.btn-p404__inner { display: inline-flex; align-items: center; gap: 10px; position: relative; z-index: 2; }
.btn-p404__label { display: inline-block; }
.btn-p404__pulse {
  position: absolute; inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(0,255,156,0.25), transparent 60%);
  opacity: 0; transition: opacity .4s;
}
.btn-p404:hover .btn-p404__pulse { opacity: 1; }
/* Primary CTA — white text matching the other CTAs, with emerald border +
   inner glow as the emphasis (rather than a colored fill that read as "dark"
   against the dark page bg). */
.btn-p404--primary {
  border-color: var(--em);
  background: linear-gradient(180deg, rgba(0,255,156,0.10), rgba(0,255,156,0.03));
  color: #fff;
  font-weight: 600;
  box-shadow:
    0 0 0 1px rgba(0,255,156,0.18) inset,
    0 0 18px rgba(0,255,156,0.18);
}
.btn-p404--primary .btn-p404__label { color: #fff; }
.btn-p404--primary:hover {
  background: linear-gradient(180deg, rgba(0,255,156,0.22), rgba(0,255,156,0.08));
  border-color: var(--em-soft);
  box-shadow:
    0 0 0 1px var(--em-glow) inset,
    0 0 24px var(--em-glow),
    0 18px 50px rgba(0,255,156,0.18);
}
.btn-p404--ghost {
  background: transparent;
  border-color: var(--hud-line);
  color: var(--text-mut);
}
.btn-p404--ghost:hover { color: #fff; }
.btn-p404--large { padding: 18px 28px; font-size: 12px; letter-spacing: 0.26em; }

/* ===================================================================
   DIVISION MODULES
   =================================================================== */
.div-systems { position: relative; z-index: 2; }

.modules {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 12px;
}
.modules .module--wide { grid-column: span 3; }
@media (max-width: 1080px) {
  .modules { grid-template-columns: repeat(2, 1fr); }
  .modules .module--wide { grid-column: span 2; }
}
@media (max-width: 680px) {
  .modules { grid-template-columns: 1fr; }
  .modules .module--wide { grid-column: span 1; }
}

.module {
  position: relative;
  padding: 22px 22px 18px;
  background:
    linear-gradient(180deg, rgba(14,22,32,0.62), rgba(6,10,14,0.82));
  border: 1px solid var(--hud-line);
  border-radius: 3px;
  overflow: hidden;
  isolation: isolate;
  transition: transform .35s ease, border-color .35s, box-shadow .35s;
  cursor: pointer;
}
.module::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle 300px at var(--mx,50%) var(--my,0%), rgba(0,255,156,0.12), transparent 60%);
  opacity: 0; transition: opacity .35s;
  pointer-events: none; z-index: 0;
}
.module::after {
  content: ""; position: absolute; inset: 0;
  border: 1px solid transparent;
  pointer-events: none; z-index: 1;
  transition: border-color .35s;
}
.module:hover { transform: translateY(-3px); border-color: var(--em-line); box-shadow: 0 24px 60px rgba(0,0,0,0.5), 0 0 24px rgba(0,255,156,0.08); }
.module:hover::before { opacity: 1; }
.module:hover::after  { border-color: rgba(0,255,156,0.18); }
.module > * { position: relative; z-index: 2; }

.module__head {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 10px; letter-spacing: 0.22em; color: var(--text-mut);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--hud-line);
}
.module__id { color: var(--em); }
.module__status {
  display: inline-flex; align-items: center; gap: 6px;
  color: #e6ecf2;
}
.module__status i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em); box-shadow: 0 0 6px var(--em-glow);
  animation: hud-blink 1.8s infinite;
}
.module__status--alt i { background: var(--cy); box-shadow: 0 0 6px rgba(0,229,255,0.5); }

/* Pending / regulatory review styling — used by Trade Intelligence card */
.module__status--pending {
  color: #ffb84d;
}
.module__status--pending i {
  background: #ffb84d;
  box-shadow: 0 0 6px rgba(255,184,77,0.55);
  animation: hud-blink 2.4s infinite;
}
.module--pending::before { background: radial-gradient(circle 300px at var(--mx,50%) var(--my,0%), rgba(255,184,77,0.08), transparent 60%) !important; }
.module--pending:hover { border-color: rgba(255,184,77,0.35); box-shadow: 0 24px 60px rgba(0,0,0,0.5), 0 0 24px rgba(255,184,77,0.08); }
.module--pending .module__cta { color: #ffb84d; opacity: 0.85; }
.module--pending:hover .module__cta { color: #ffc870; }

/* Trade Intelligence viz: line chart with bars beneath */
.module__viz--trade {
  height: 152px; /* slightly taller for the wide card's chart */
}
.module__viz--trade svg { width: 100%; height: 100%; }
.module__viz-trade-line {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  animation: stroke-draw 5s ease-in-out infinite;
}

/* Ventures viz: grid of squares with some glowing */
.module__viz--ventures svg g[fill="#00ff9c"] rect { animation: module-dots 3s ease-in-out infinite; }
.module__viz--ventures svg g[fill="#00ff9c"] rect:nth-child(2n) { animation-delay: .4s; }
.module__viz--ventures svg g[fill="#00ff9c"] rect:nth-child(3n) { animation-delay: .8s; }

.module__title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  margin-top: 14px;
  color: #fff;
  letter-spacing: -0.01em;
}
.module__lede {
  color: var(--text-mut);
  font-size: 14px; line-height: 1.5;
  margin-top: 6px;
  min-height: 3em;
}

.module__viz {
  margin-top: 14px;
  background:
    linear-gradient(180deg, rgba(0,255,156,0.04), transparent),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 8px);
  border: 1px solid var(--hud-line);
  border-radius: 2px;
  height: 132px;
  display: grid; place-items: center;
  position: relative; overflow: hidden;
}
.module__viz svg { width: 100%; height: 100%; }
.module__viz-dots circle { animation: module-dots 2.4s ease-in-out infinite; }
.module__viz-dots circle:nth-child(2n) { animation-delay: .3s; }
.module__viz-dots circle:nth-child(3n) { animation-delay: .6s; }
@keyframes module-dots { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.module__viz-stroke {
  stroke-dasharray: 320; stroke-dashoffset: 320;
  animation: stroke-draw 4s ease-in-out infinite;
}
@keyframes stroke-draw {
  0%   { stroke-dashoffset: 320; opacity: 0; }
  20%  { opacity: 1; }
  60%  { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -320; opacity: 0; }
}

.module__viz-sweep {
  transform-origin: 100px 60px;
  animation: radar-sweep 4s linear infinite;
}
@keyframes radar-sweep { from { transform: rotate(0); } to { transform: rotate(360deg); } }

.module__viz-wave {
  stroke-dasharray: 600; stroke-dashoffset: 600;
  animation: wave-draw 3.4s ease-in-out infinite;
}
@keyframes wave-draw {
  0%   { stroke-dashoffset: 600; }
  60%  { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -600; }
}

.module__viz--bars {
  display: flex; gap: 5px; padding: 14px;
  align-items: flex-end;
  background:
    linear-gradient(180deg, rgba(0,255,156,0.04), transparent),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 8px);
}
.module__viz--bars span {
  flex: 1;
  height: var(--h);
  background: linear-gradient(180deg, var(--em-soft), var(--em-deep));
  box-shadow: 0 0 4px var(--em-glow);
  animation: bar-pulse 2.6s ease-in-out infinite;
}
.module__viz--bars span:nth-child(2n) { animation-delay: .2s; }
.module__viz--bars span:nth-child(3n) { animation-delay: .4s; }
.module__viz--bars span:nth-child(5n) { animation-delay: .9s; }

.module__stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
  border-top: 1px solid var(--hud-line);
  padding-top: 12px;
  list-style: none;
}
.module__stats li {
  display: flex; flex-direction: column;
  gap: 2px;
}
.module__stats li span { color: var(--text-faint); font-size: 9.5px; letter-spacing: 0.2em; }
.module__stats li b    { color: #fff; font-family: var(--font-mono); font-weight: 500; font-size: 15px; letter-spacing: 0.04em; }

.module__cta {
  margin-top: 14px;
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--em);
  font-size: 10.5px; letter-spacing: 0.22em;
  padding-top: 12px;
  border-top: 1px dashed var(--hud-line);
  width: 100%;
}
.module:hover .module__cta { color: var(--em-soft); }

/* ===================================================================
   AI NETWORK STAGE
   =================================================================== */
.net { position: relative; z-index: 2; padding-bottom: 60px; }
.net__stage {
  position: relative;
  height: clamp(540px, 78vh, 760px);
  margin: 12px 32px 0;
  border: 1px solid var(--em-line);
  border-radius: 4px;
  background:
    radial-gradient(ellipse at 50% 50%, rgba(0,255,156,0.06), transparent 60%),
    linear-gradient(180deg, rgba(6,10,14,0.6), rgba(4,7,10,0.85));
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.03) inset,
    0 30px 80px rgba(0,0,0,0.6),
    0 0 50px rgba(0,255,156,0.08);
}
.net__stage::before, .net__stage::after {
  content: ""; position: absolute;
  width: 18px; height: 18px;
  border: 1px solid var(--em);
}
.net__stage::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.net__stage::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.net__stage #netCanvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
}
.net__overlay {
  position: absolute; inset: 0;
  pointer-events: none;
}

.net__panel {
  position: absolute;
  padding: 14px 16px;
  background:
    linear-gradient(180deg, rgba(10,16,22,0.85), rgba(6,10,14,0.92));
  border: 1px solid var(--em-line);
  border-radius: 2px;
  backdrop-filter: blur(10px);
  pointer-events: auto;
  min-width: 200px;
}
.net__panel--tl { top: 22px; left: 22px; }
.net__panel--tr { top: 22px; right: 22px; }
.net__panel--bl { bottom: 22px; left: 22px; min-width: 280px; }
.net__panel--br { bottom: 22px; right: 22px; min-width: 240px; }

.net__panel-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: 0.22em; color: var(--text-mut);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--hud-line);
}
.net__panel-head i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
}
.net__panel-body {
  display: grid; gap: 6px;
  margin-top: 10px;
  font-family: var(--font-mono); font-size: 11px;
}
.net__panel-body div { display: flex; justify-content: space-between; }
.net__panel-body span { color: var(--text-faint); letter-spacing: 0.14em; }
.net__panel-body b    { color: #fff; font-weight: 500; }

.net__panel-bignum {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.08em;
  font-size: 44px;
  color: var(--em);
  text-shadow: 0 0 22px var(--em-glow);
  line-height: 1;
  margin-top: 8px;
}
.net__panel-sub { color: var(--text-mut); font-size: 10px; letter-spacing: 0.22em; margin-top: 4px; }

.net__log {
  list-style: none; margin-top: 10px;
  display: grid; gap: 4px;
  font-size: 10.5px; color: var(--text-mut);
  max-height: 110px; overflow: hidden;
}
.net__log li { display: flex; gap: 8px; }
.net__log li span { color: var(--em); letter-spacing: 0.08em; }

.net__mix { list-style: none; margin-top: 10px; display: grid; gap: 6px; font-size: 10.5px; }
.net__mix li { display: grid; grid-template-columns: 60px 1fr 36px; gap: 8px; align-items: center; }
.net__mix span { color: var(--text-faint); letter-spacing: 0.14em; }
.net__mix i {
  position: relative; height: 4px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--hud-line);
}
.net__mix i::after {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0;
  width: var(--v);
  background: linear-gradient(90deg, var(--em-deep), var(--em));
  box-shadow: 0 0 6px var(--em-glow);
}
.net__mix b { color: #fff; text-align: right; font-family: var(--font-mono); font-weight: 500; }

.net__crosshair {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: 220px; height: 220px;
}
.net__crosshair span {
  position: absolute; background: var(--em-line);
}
.net__crosshair span:nth-child(1) { top: 0; left: 50%; width: 1px; height: 60px; transform: translateX(-0.5px); }
.net__crosshair span:nth-child(2) { bottom: 0; left: 50%; width: 1px; height: 60px; transform: translateX(-0.5px); }
.net__crosshair span:nth-child(3) { left: 0; top: 50%; height: 1px; width: 60px; transform: translateY(-0.5px); }
.net__crosshair span:nth-child(4) { right: 0; top: 50%; height: 1px; width: 60px; transform: translateY(-0.5px); }
.net__crosshair em {
  position: absolute; bottom: -28px; left: 50%; transform: translateX(-50%);
  font-style: normal;
  color: var(--em); font-size: 10px; letter-spacing: 0.18em; white-space: nowrap;
}

@media (max-width: 860px) {
  .net__stage { margin: 12px 16px 0; height: 540px; }
  .net__panel { min-width: auto; max-width: 240px; padding: 10px 12px; }
  .net__panel--bl { min-width: auto; }
  .net__panel-bignum { font-size: 30px; }
}

/* ===================================================================
   COMMUNITY
   =================================================================== */
.community { position: relative; z-index: 2; padding-bottom: 100px; }

.community__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 36px;
  margin-top: 24px;
}
@media (max-width: 980px) {
  .community__layout { grid-template-columns: 1fr; }
}

.community__lede .section-title { font-size: clamp(28px, 3.4vw, 44px); max-width: 18ch; }
.community__lede .section-lede  { font-size: 15px; margin-top: 16px; }
.community__ctas { display: flex; gap: 12px; margin-top: 22px; flex-wrap: wrap; }

.community__panel {
  background: linear-gradient(180deg, rgba(10,16,22,0.7), rgba(6,10,14,0.88));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  padding: 0;
  position: relative;
  overflow: hidden;
  min-height: 380px;
}
.community__panel::before, .community__panel::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.community__panel::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.community__panel::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.community__panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--hud-line);
  font-size: 10px; letter-spacing: 0.22em; color: var(--text-mut);
}
.community__panel-head i {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--em); box-shadow: 0 0 6px var(--em-glow); margin-right: 6px;
  animation: hud-blink 1.5s infinite;
}

.community__feed {
  list-style: none;
  padding: 12px 16px;
  display: grid; gap: 7px;
  font-size: 11.5px;
  color: var(--text-mut);
  max-height: 280px;
  overflow: hidden;
  position: relative;
  mask-image: linear-gradient(180deg, #000 80%, transparent);
  -webkit-mask-image: linear-gradient(180deg, #000 80%, transparent);
}
.community__feed li {
  display: grid;
  grid-template-columns: 64px 90px 1fr;
  gap: 10px;
  align-items: baseline;
  padding-bottom: 7px;
  border-bottom: 1px dashed rgba(255,255,255,0.04);
}
.community__feed time { color: var(--em); font-style: normal; letter-spacing: 0.08em; }
.community__feed b    { color: #fff; font-weight: 500; letter-spacing: 0.12em; }

.community__panel-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px;
  font-size: 10.5px; letter-spacing: 0.18em; color: var(--text-mut);
  border-top: 1px solid var(--hud-line);
  background: linear-gradient(180deg, transparent, rgba(0,255,156,0.04));
}
.community__panel-foot a { color: var(--em); }

.community__stats {
  list-style: none;
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 14px; margin-top: 36px;
}
.community__stats li {
  padding: 24px 22px;
  background: linear-gradient(180deg, rgba(10,16,22,0.6), rgba(6,10,14,0.78));
  border: 1px solid var(--hud-line);
  position: relative;
  overflow: hidden;
}
.community__stats li::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent);
}
.community__stats b {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.04em;
  font-size: clamp(28px, 3.6vw, 44px);
  color: #fff;
  text-shadow: 0 0 14px rgba(0,255,156,0.18);
}
.community__stats span { display: block; color: var(--text-mut); font-size: 10.5px; letter-spacing: 0.22em; margin-top: 4px; }
@media (max-width: 720px) {
  .community__stats { grid-template-columns: repeat(2, 1fr); }
}

/* ===================================================================
   INTEL TERMINAL
   =================================================================== */
.intel { position: relative; z-index: 2; padding-bottom: 80px; }

.intel__terminal {
  border: 1px solid var(--em-line);
  background:
    linear-gradient(180deg, rgba(10,16,22,0.7), rgba(4,7,10,0.92));
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}
.intel__terminal::before, .intel__terminal::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.intel__terminal::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.intel__terminal::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.intel__terminal-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 16px;
  border-bottom: 1px solid var(--hud-line);
  font-size: 10px; letter-spacing: 0.22em; color: var(--text-mut);
  background: linear-gradient(180deg, rgba(0,255,156,0.04), transparent);
}
.intel__terminal-bar i {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--em); box-shadow: 0 0 6px var(--em-glow); margin-right: 6px;
  animation: hud-blink 1.6s infinite;
}

.intel__grid {
  list-style: none;
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--hud-line);
}
@media (max-width: 1080px) { .intel__grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 680px)  { .intel__grid { grid-template-columns: 1fr; } }

.intel__card {
  background: linear-gradient(180deg, rgba(8,14,20,0.86), rgba(4,7,10,0.94));
  padding: 22px 22px 18px;
  position: relative;
  overflow: hidden;
  transition: background .35s;
  cursor: pointer;
}
.intel__card:hover {
  background: linear-gradient(180deg, rgba(0,255,156,0.06), rgba(4,7,10,0.94));
}

.intel__card-meta {
  display: flex; align-items: center; gap: 12px;
  font-size: 10px; letter-spacing: 0.18em; color: var(--text-mut);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hud-line);
}
.intel__card-tag {
  background: rgba(0,255,156,0.12);
  color: var(--em);
  padding: 3px 8px;
  border: 1px solid var(--em-line);
  letter-spacing: 0.2em;
}
.intel__card-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  margin-top: 12px;
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.intel__card-lede {
  color: var(--text-mut);
  font-size: 13.5px; line-height: 1.55;
  margin-top: 8px;
}
.intel__card-foot {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 16px;
  font-size: 10px; letter-spacing: 0.22em; color: var(--text-mut);
}
.intel__card-link { color: var(--em); transition: color .25s; }
.intel__card:hover .intel__card-link { color: var(--em-soft); }
.intel__card-scan {
  position: absolute; left: 0; right: 0; top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--em), transparent);
  filter: blur(0.5px);
  opacity: 0;
  transform: translateY(0);
  transition: opacity .25s;
}
.intel__card:hover .intel__card-scan { opacity: 1; animation: intel-scan 2s linear infinite; }
@keyframes intel-scan {
  0%   { transform: translateY(0); opacity: 0; }
  10%  { opacity: 1; }
  100% { transform: translateY(100%); opacity: 0; }
}

/* ===================================================================
   FINAL SCENE
   =================================================================== */
.final {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  padding: 120px 0 80px;
  overflow: hidden;
}
.final__skyline {
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 60%; pointer-events: none;
}
.final__skyline-art {
  position: absolute; left: 0; right: 0; bottom: 0;
  width: 100%; height: 100%;
}
.final__skyline-haze {
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 50%;
  background:
    radial-gradient(ellipse 70% 60% at 50% 100%, rgba(0,255,156,0.22), transparent 60%),
    radial-gradient(ellipse 80% 40% at 30% 110%, rgba(0,229,255,0.12), transparent 70%);
  filter: blur(20px);
  animation: env-haze 14s ease-in-out infinite alternate;
}
.final__skyline-lights {
  position: absolute; left: 0; right: 0; bottom: 12%; height: 50%;
  background-image:
    radial-gradient(circle 1.5px at 8% 60%, var(--em), transparent),
    radial-gradient(circle 1.2px at 14% 75%, var(--em), transparent),
    radial-gradient(circle 1.5px at 22% 50%, var(--cy), transparent),
    radial-gradient(circle 1.2px at 30% 70%, var(--em), transparent),
    radial-gradient(circle 1.5px at 41% 55%, var(--em), transparent),
    radial-gradient(circle 1.2px at 52% 80%, var(--cy), transparent),
    radial-gradient(circle 1.5px at 62% 65%, var(--em), transparent),
    radial-gradient(circle 1.2px at 71% 50%, var(--em), transparent),
    radial-gradient(circle 1.5px at 80% 78%, var(--cy), transparent),
    radial-gradient(circle 1.5px at 89% 60%, var(--em), transparent),
    radial-gradient(circle 1.2px at 95% 72%, var(--em), transparent);
  animation: lights-flicker 3.6s steps(8) infinite;
  filter: drop-shadow(0 0 6px var(--em-glow));
}
@keyframes lights-flicker {
  0%, 100% { opacity: 0.85; }
  20%      { opacity: 0.55; }
  40%      { opacity: 1; }
  60%      { opacity: 0.7; }
  80%      { opacity: 0.95; }
}

.final__inner { position: relative; z-index: 2; display: grid; gap: 26px; }

.final__eyebrow {
  display: flex; align-items: center; gap: 14px;
  color: var(--text-mut);
  letter-spacing: 0.28em;
  font-size: 10.5px;
  margin-bottom: 14px;
}
.final__eyebrow-bar {
  width: 36px; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent);
}
.final__eyebrow-id { margin-left: auto; }

.final__title {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 0.95;
  font-size: clamp(36px, 6vw, 96px);
  color: #fff;
  text-shadow:
    0 0 18px rgba(0,255,156,0.18),
    0 0 80px rgba(0,255,156,0.12);
  max-width: 16ch;
}
.final__sub {
  color: var(--text-mut);
  font-family: var(--font-display);
  font-size: clamp(16px, 1.4vw, 20px);
  max-width: 64ch;
  line-height: 1.55;
}

.final__ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 12px; }

.final__stamp {
  margin-top: 60px;
  padding: 16px 18px;
  border: 1px solid var(--em-line);
  background: linear-gradient(180deg, rgba(10,16,22,0.7), rgba(4,7,10,0.85));
  display: flex; justify-content: space-between; align-items: center;
  font-size: 10.5px; letter-spacing: 0.24em;
  color: var(--text-mut);
  max-width: 720px;
}
.final__stamp-label { color: var(--em); display: block; }
.final__stamp-id { color: #e6ecf2; display: block; margin-top: 4px; }
.final__stamp-side { display: flex; align-items: center; gap: 10px; color: var(--em); }
.final__stamp-tick {
  width: 8px; height: 8px; background: var(--em);
  box-shadow: 0 0 10px var(--em-glow);
  animation: hud-blink 1.4s infinite;
}

/* ===================================================================
   FOOTER
   =================================================================== */
.p404-foot {
  position: relative; z-index: 2;
  padding: 60px 0 70px;
  border-top: 1px solid var(--hud-line);
  background: linear-gradient(180deg, rgba(4,7,10,0), rgba(4,7,10,0.7));
}
.p404-foot__inner { display: grid; gap: 36px; }
.p404-foot__brand { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.p404-foot__brand-mark {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.18em;
  font-size: 16px; color: #fff;
}
.p404-foot__brand .mono { color: var(--text-mut); font-size: 11px; }

.p404-foot__cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
  font-size: 11.5px;
}
.p404-foot__cols div { display: grid; gap: 6px; color: var(--text-mut); }
.p404-foot__cols b   { color: var(--em); letter-spacing: 0.2em; font-weight: 500; font-size: 10.5px; }
.p404-foot__cols a   { color: #e6ecf2; cursor: pointer; transition: color .25s; }
.p404-foot__cols a:hover { color: var(--em); }

.p404-foot__line {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px;
  border-top: 1px solid var(--hud-line);
  color: var(--text-faint);
  font-size: 10.5px; letter-spacing: 0.18em;
}
@media (max-width: 720px) {
  .p404-foot__cols { grid-template-columns: repeat(2, 1fr); }
  .p404-foot__line { flex-direction: column; gap: 10px; align-items: flex-start; }
}

/* ===================================================================
   REVEAL UTILITIES (GSAP toggled via .is-in)
   =================================================================== */
[data-reveal] { opacity: 0; transform: translateY(20px); transition: opacity .9s ease, transform .9s ease; }
[data-reveal].is-in { opacity: 1; transform: none; }

[data-float] { will-change: transform; }

/* ===================================================================
   HOME — Phase A refresh (2026-05-20)
   Minimal hero modifier + sector selector + preview panel + Core
   micro-message + subscribe form.
   =================================================================== */

/* Minimal hero variant — drops 2 of 3 floating HUD widgets, reduces glow,
   lets the env background carry the ambient texture. */
.hero--minimal .hero__hud--a,
.hero--minimal .hero__hud--b { display: none; }
.hero--minimal .hero__title {
  text-shadow: 0 0 14px rgba(0,255,156,0.12), 0 0 40px rgba(0,255,156,0.06);
}
.hero--minimal .hero__title-404 {
  text-shadow: 0 0 18px var(--em-glow), 0 0 50px rgba(0,255,156,0.18);
}
.hero--minimal .hero__hud--c {
  bottom: 16%; right: 4%;
  width: 240px;
  opacity: 0.85;
  /* less neon, more ambient */
}
.hero--minimal .hero__layout { gap: 22px; }

/* SECTION HEADER PANEL
   Used on home sections (sectors + join) where the eyebrow/heading/lede
   were floating in the void without visual containment. Wraps them in a
   subtle glass panel matching the corner-bracket motif used elsewhere
   (.preview, .join-form, .cta-block, .stub-panel). */
.section-header-panel {
  position: relative;
  padding: 22px 28px 24px;
  margin: 12px 0 22px;
  background:
    linear-gradient(180deg, rgba(0,255,156,0.025), transparent 60%),
    linear-gradient(180deg, rgba(10,16,22,0.5), rgba(6,10,14,0.68));
  border: 1px solid var(--hud-line);
  border-radius: 3px;
  overflow: hidden;
}
.section-header-panel::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent 70%);
  box-shadow: 0 0 8px var(--em-glow);
}
.section-header-panel::after {
  content: ""; position: absolute; bottom: -1px; right: -1px; width: 14px; height: 14px;
  border: 1px solid var(--em);
  border-left: none; border-top: none;
}
/* Reset the default eyebrow/head spacing when used inside the header panel */
.section-header-panel .section-eyebrow { padding-top: 0; margin-bottom: 12px; }
.section-header-panel .section-head {
  display: block;
  margin-top: 6px;
  padding-bottom: 0;
}
.section-header-panel .section-title { max-width: none; margin: 0 0 10px; }
.section-header-panel .section-lede { max-width: 64ch; }
@media (max-width: 720px) {
  .section-header-panel { padding: 18px 20px 20px; }
}

/* SECTOR SELECTOR */
.sectors { position: relative; z-index: 2; padding-bottom: 40px; }

.sector-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 12px;
}
@media (max-width: 980px) { .sector-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .sector-grid { grid-template-columns: 1fr; } }

.sector-card {
  position: relative;
  text-align: left;
  padding: 20px 22px 18px;
  background: linear-gradient(180deg, rgba(10,16,22,0.5), rgba(6,10,14,0.74));
  border: 1px solid var(--hud-line);
  border-radius: 3px;
  color: inherit;
  font-family: inherit;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform .3s, border-color .3s, background .3s, box-shadow .3s;
}
.sector-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle 220px at 0% 0%, rgba(0,255,156,0.08), transparent 70%);
  opacity: 0; transition: opacity .35s;
  pointer-events: none;
}
.sector-card:hover {
  transform: translateY(-2px);
  border-color: var(--em-line);
  box-shadow: 0 14px 40px rgba(0,0,0,0.4), 0 0 18px rgba(0,255,156,0.06);
}
.sector-card:hover::before { opacity: 1; }
.sector-card.is-active {
  border-color: var(--em);
  background: linear-gradient(180deg, rgba(0,255,156,0.08), rgba(0,255,156,0.02)),
              linear-gradient(180deg, rgba(10,16,22,0.78), rgba(6,10,14,0.92));
  box-shadow: 0 0 0 1px var(--em-halo) inset, 0 0 24px rgba(0,255,156,0.12);
}
.sector-card.is-active::before { opacity: 1; }
.sector-card.is-active::after {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent);
  box-shadow: 0 0 8px var(--em-glow);
}
.sector-card__id {
  display: block;
  color: var(--em);
  letter-spacing: 0.2em;
  font-size: 10px;
  margin-bottom: 6px;
}
.sector-card__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 4px;
}
.sector-card__lede {
  color: var(--text-mut);
  font-size: 13px;
  line-height: 1.45;
}
.sector-card__arrow {
  position: absolute; right: 18px; bottom: 16px;
  color: var(--text-faint);
  font-size: 16px;
  transition: color .25s, transform .25s;
}
.sector-card:hover .sector-card__arrow,
.sector-card.is-active .sector-card__arrow {
  color: var(--em);
  transform: translateX(3px);
}

/* CORE MICRO-MESSAGE BAR — full-width status line.
   Left: pulsing dot + CORE label + dynamic message text.
   Right: ambient network-activity bars (relocated from the hero
   to live where the "network status" semantics actually belong). */
.core-msg {
  display: flex; align-items: center; gap: 12px;
  margin: 24px 0 12px;
  padding: 10px 16px;
  background: rgba(0,255,156,0.05);
  border: 1px solid var(--em-line);
  border-radius: 2px;
  color: var(--text-mut);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  transition: background .3s, color .3s;
}
.core-msg.is-firing {
  background: rgba(0,255,156,0.14);
  color: #fff;
}
.core-msg__dot {
  flex: 0 0 auto;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
  animation: hud-blink 1.8s infinite;
}
.core-msg__label {
  flex: 0 0 auto;
  color: var(--em);
  font-weight: 500;
  letter-spacing: 0.22em;
}
.core-msg__text {
  flex: 1 1 auto;
  min-width: 1px;
  /* truncate gracefully on small screens */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.core-msg__bars {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  height: 16px;
}
.core-msg__bars span {
  display: block;
  width: 3px;
  height: var(--v);
  background: linear-gradient(180deg, var(--em-soft), var(--em-deep));
  box-shadow: 0 0 4px var(--em-glow);
  animation: bar-pulse 2.4s ease-in-out infinite;
  transform-origin: bottom;
}
.core-msg__bars span:nth-child(2n) { animation-delay: .2s; }
.core-msg__bars span:nth-child(3n) { animation-delay: .4s; }
.core-msg__bars span:nth-child(5n) { animation-delay: .8s; }
@media (max-width: 560px) {
  .core-msg__bars { height: 14px; }
  .core-msg__bars span:nth-child(n+7) { display: none; } /* fewer bars on narrow screens */
}

/* PREVIEW PANEL */
.preview {
  position: relative;
  background:
    linear-gradient(180deg, rgba(0,255,156,0.04), transparent 70%),
    linear-gradient(180deg, rgba(10,16,22,0.78), rgba(6,10,14,0.92));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  overflow: hidden;
}
.preview::before, .preview::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.preview::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.preview::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.preview__head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid var(--hud-line);
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--text-mut);
  background: linear-gradient(180deg, rgba(0,255,156,0.05), transparent);
}
.preview__head-id { display: inline-flex; align-items: center; gap: 8px; }
.preview__head-id i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
  animation: hud-blink 1.8s infinite;
}
.preview__head-status { color: var(--em); }

.preview__body { padding: 26px 26px 24px; }
.preview__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(22px, 2.4vw, 32px);
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 10px;
}
.preview__lede {
  color: var(--text-mut);
  font-size: 15px;
  line-height: 1.55;
  max-width: 64ch;
  margin-bottom: 22px;
}

.preview__peeks {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 22px;
}
@media (max-width: 720px) { .preview__peeks { grid-template-columns: 1fr; } }
.preview__peeks li {
  padding: 12px 14px;
  background: rgba(10,16,22,0.5);
  border: 1px solid var(--hud-line);
  border-left: 2px solid var(--em-line);
  border-radius: 2px;
  display: grid; gap: 4px;
}
.preview__peeks li b {
  color: #fff;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: -0.005em;
}
.preview__peek-status {
  color: var(--em);
  font-size: 9.5px;
  letter-spacing: 0.2em;
}
.preview__foot { display: flex; gap: 12px; flex-wrap: wrap; }
@media (max-width: 560px) { .preview__foot .btn-p404 { width: 100%; justify-content: center; } }

/* JOIN / SUBSCRIBE FORM */
.join { position: relative; z-index: 2; padding-bottom: 50px; }
.join-form {
  position: relative;
  background:
    linear-gradient(180deg, rgba(10,16,22,0.78), rgba(6,10,14,0.92));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  padding: 28px 28px 24px;
  display: grid;
  gap: 16px;
  max-width: 760px;
  margin: 0 auto;
  box-shadow: 0 0 30px rgba(0,255,156,0.05), 0 18px 50px rgba(0,0,0,0.4);
}
.join-form::before, .join-form::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.join-form::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.join-form::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.join-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
@media (max-width: 560px) { .join-form__row { grid-template-columns: 1fr; } }

.join-form__field { display: grid; gap: 6px; }
.join-form__label {
  color: var(--em);
  font-size: 10px;
  letter-spacing: 0.22em;
}

.join-form input,
.join-form select,
.join-form textarea {
  width: 100%;
  padding: 12px 14px;
  background: rgba(4,7,10,0.6);
  border: 1px solid var(--hud-line);
  border-radius: 2px;
  color: #fff;
  font-family: var(--font-body);
  font-size: 14.5px;
  transition: border-color .25s, background .25s, box-shadow .25s;
}
.join-form select {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  cursor: pointer;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--em) 50%),
                    linear-gradient(135deg, var(--em) 50%, transparent 50%);
  background-position: calc(100% - 18px) center, calc(100% - 12px) center;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 36px;
}
.join-form textarea {
  resize: vertical;
  min-height: 84px;
  font-family: var(--font-body);
}
.join-form input::placeholder,
.join-form textarea::placeholder { color: var(--text-faint); }
.join-form input:focus,
.join-form select:focus,
.join-form textarea:focus {
  outline: none;
  border-color: var(--em);
  background: rgba(0,255,156,0.04);
  box-shadow: 0 0 0 3px rgba(0,255,156,0.10);
}

.join-form__foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.join-form__submit { min-width: 200px; justify-content: center; }
.join-form__hint {
  color: var(--text-faint);
  font-size: 10px;
  letter-spacing: 0.18em;
}
.join-form__status {
  margin-top: 4px;
  font-size: 11px;
  letter-spacing: 0.16em;
  min-height: 14px;
  color: var(--text-mut);
}
.join-form__status.is-ok { color: var(--em); }
.join-form__status.is-err { color: #ffb84d; }

/* Discord-direct fallback link below the form */
.join-form__alt {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 14px;
  padding-top: 16px;
  border-top: 1px dashed var(--hud-line);
}
.join-form__alt-divider {
  color: var(--text-faint);
  font-size: 10px;
  letter-spacing: 0.28em;
}
.join-form__alt-link {
  color: var(--em);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 4px 0;
  transition: color .25s, transform .25s;
}
.join-form__alt-link:hover {
  color: var(--em-soft);
  transform: translateX(2px);
}
@media (max-width: 560px) {
  .join-form__foot { flex-direction: column; align-items: stretch; }
  .join-form__submit { width: 100%; }
  .join-form { padding: 22px 18px 20px; }
}

/* ===================================================================
   PLATFORM PAGE (/platform — deep build)
   Page-level hero + pillars + tier cards + spec chips.
   Reuses .module and .stub-panel for module grid + spec panel.
   =================================================================== */
.page-hero {
  position: relative; z-index: 1;
  padding: 130px 0 60px;
}
.page-hero__inner { display: grid; gap: 22px; }
.page-hero__title {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.02em; line-height: 1.05;
  font-size: clamp(36px, 6.4vw, 88px); /* matches home hero — 2026-05-20 */
  color: #fff;
  text-shadow: 0 0 12px rgba(0,255,156,0.14), 0 0 40px rgba(0,255,156,0.08);
  margin: 12px 0 0;
}
.page-hero__title em { color: var(--em); font-style: normal; text-shadow: 0 0 24px var(--em-glow); }
.page-hero__sub {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(20px, 2.4vw, 30px);
  color: #e6ecf2;
  max-width: 760px;
  line-height: 1.4;
  letter-spacing: -0.01em;
}
.page-hero__support {
  color: var(--text-mut);
  font-size: 11px;
  letter-spacing: 0.28em;
  margin-top: 4px;
}
.page-hero__ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 14px; }

/* Pillars: 4-up of outcome statements */
.pillars { display: grid; gap: 16px; grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1080px) { .pillars { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px)  { .pillars { grid-template-columns: 1fr; } }
.pillar {
  position: relative;
  padding: 22px 22px 20px;
  background: linear-gradient(180deg, rgba(10,16,22,0.55), rgba(6,10,14,0.78));
  border: 1px solid var(--hud-line);
  border-radius: 3px;
  overflow: hidden;
}
.pillar::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, var(--em), transparent);
}
.pillar__head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.pillar__head .mono { color: var(--em); letter-spacing: 0.2em; font-size: 10px; }
.pillar__head i {
  width: 6px; height: 6px; border-radius: 50%; background: var(--em);
  box-shadow: 0 0 6px var(--em-glow);
}
.pillar__title {
  font-family: var(--font-display); font-weight: 600;
  font-size: 19px; color: #fff; letter-spacing: -0.01em; line-height: 1.2;
  margin-bottom: 8px;
}
.pillar__lede { color: var(--text-mut); font-size: 13.5px; line-height: 1.5; }

/* Spec chips: technical detail in voice */
.spec-chips {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
}
.spec-chip {
  padding: 14px 16px;
  background: rgba(10,16,22,0.6);
  border: 1px solid var(--hud-line);
  border-left: 2px solid var(--em);
  border-radius: 2px;
}
.spec-chip__label {
  display: block;
  font-family: var(--font-mono); font-size: 9.5px;
  letter-spacing: 0.2em; color: var(--em);
  margin-bottom: 4px;
}
.spec-chip__value {
  display: block;
  font-family: var(--font-mono); font-size: 13px;
  color: #fff; font-weight: 500; letter-spacing: 0.04em;
}

/* Operator tiers: 3-up */
.tiers { display: grid; gap: 18px; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 960px) { .tiers { grid-template-columns: 1fr; } }
.tier {
  position: relative;
  padding: 26px 24px 22px;
  background: linear-gradient(180deg, rgba(10,16,22,0.68), rgba(6,10,14,0.88));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  overflow: hidden;
}
.tier::before, .tier::after {
  content: ""; position: absolute; width: 12px; height: 12px;
  border: 1px solid var(--em);
}
.tier::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.tier::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }
.tier__id { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em; color: var(--em); }
.tier__title {
  font-family: var(--font-display); font-weight: 600;
  font-size: 24px; color: #fff; letter-spacing: -0.01em;
  margin: 6px 0 8px;
}
.tier__sub { color: var(--text-mut); font-size: 13.5px; line-height: 1.5; margin-bottom: 14px; }
.tier__list {
  list-style: none; display: grid; gap: 6px;
  font-size: 13px; color: #d8e0e8;
  padding-top: 12px; border-top: 1px solid var(--hud-line);
}
.tier__list li {
  position: relative; padding-left: 18px;
}
.tier__list li::before {
  content: "▸"; position: absolute; left: 0; color: var(--em);
}
.tier__cta {
  margin-top: 14px;
  font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: 0.22em; color: var(--em);
  display: inline-flex; align-items: center; gap: 6px;
}

/* Final CTA section variant for product pages */
.cta-block {
  position: relative;
  padding: 40px 32px;
  background:
    linear-gradient(180deg, rgba(0,255,156,0.06), transparent 70%),
    linear-gradient(180deg, rgba(10,16,22,0.7), rgba(6,10,14,0.88));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  text-align: center;
  overflow: hidden;
}
.cta-block::before, .cta-block::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.cta-block::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.cta-block::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }
.cta-block__eyebrow {
  font-family: var(--font-mono); font-size: 10px;
  letter-spacing: 0.28em; color: var(--em);
}
.cta-block__title {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(26px, 3.4vw, 42px); color: #fff;
  letter-spacing: -0.01em; line-height: 1.1;
  margin: 12px 0 10px;
  max-width: 22ch; margin-left: auto; margin-right: auto;
}
.cta-block__sub {
  color: var(--text-mut); font-size: 15px;
  max-width: 56ch; margin: 0 auto 22px; line-height: 1.55;
}
.cta-block__ctas { display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

@media (max-width: 720px) {
  .page-hero { padding: 100px 0 40px; }
  .cta-block { padding: 32px 22px; }
  .cta-block__ctas .btn-p404 { width: 100%; justify-content: center; }
  .page-hero__ctas .btn-p404 { width: 100%; justify-content: center; }
}

/* ===================================================================
   STUB PAGES — used by about/platform/gridhack/signals/network/projects/access
   Each page wears the same chrome (env, nav, footer) and a stub panel that
   reads as "this surface is currently building" rather than "404 / sorry."
   =================================================================== */
.stub {
  position: relative; z-index: 1;
  padding: 130px 0 80px;
}
.stub-header { padding-bottom: 50px; }
.stub-title {
  font-family: 'Orbitron', system-ui, sans-serif;
  font-weight: 900; letter-spacing: 0.02em; line-height: 1;
  font-size: clamp(40px, 6.4vw, 92px);
  color: #fff;
  text-shadow: 0 0 18px rgba(0,255,156,0.18), 0 0 60px rgba(0,255,156,0.10);
  margin: 18px 0 18px;
}
.stub-title em { color: var(--em); font-style: normal; text-shadow: 0 0 24px var(--em-glow); }
.stub-lede {
  font-family: var(--font-display);
  font-size: clamp(17px, 1.5vw, 22px);
  color: #d8e0e8;
  max-width: 64ch;
  line-height: 1.5;
}

.stub-body { display: grid; gap: 24px; }

.stub-panel {
  background: linear-gradient(180deg, rgba(10,16,22,0.72), rgba(4,7,10,0.92));
  border: 1px solid var(--em-line);
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}
.stub-panel::before, .stub-panel::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 1px solid var(--em);
}
.stub-panel::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.stub-panel::after  { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.stub-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 18px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em;
  color: var(--text-mut);
  border-bottom: 1px solid var(--hud-line);
  background: linear-gradient(180deg, rgba(0,255,156,0.06), transparent);
}
.stub-panel-head i {
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--em); box-shadow: 0 0 6px var(--em-glow); margin-right: 8px;
  animation: hud-blink 1.6s infinite;
}

.stub-panel-body {
  padding: 32px 30px 30px;
  display: grid; gap: 20px;
}
.stub-panel-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(24px, 2.6vw, 36px);
  color: #fff;
  letter-spacing: -0.01em;
  line-height: 1.1;
}
.stub-panel-lede {
  font-size: 15.5px; color: var(--text-mut); line-height: 1.55;
  max-width: 64ch;
}

.stub-progress { display: grid; gap: 8px; max-width: 540px; }
.stub-progress-bar {
  height: 6px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--em-line);
  overflow: hidden;
  position: relative;
}
.stub-progress-bar span {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--em-deep), var(--em));
  box-shadow: 0 0 10px var(--em-glow);
  position: relative;
}
.stub-progress-bar span::after {
  content: ""; position: absolute; right: 0; top: -2px; bottom: -2px; width: 10px;
  background: linear-gradient(90deg, transparent, var(--em));
  filter: blur(2px);
}
.stub-progress-meta {
  display: flex; justify-content: space-between;
  color: var(--text-mut); font-size: 10.5px; letter-spacing: 0.18em;
}

.stub-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 8px; }

/* operator log — feels like a deploy log streaming in */
.stub-log {
  list-style: none;
  display: grid; gap: 6px;
  font-family: var(--font-mono); font-size: 11px;
  color: var(--text-mut);
}
.stub-log li { display: grid; grid-template-columns: 90px 80px 1fr; gap: 10px; align-items: baseline; }
.stub-log li time { color: var(--em); }
.stub-log li b { color: #e6ecf2; font-weight: 500; letter-spacing: 0.14em; }

/* secondary "what's coming" sub-panels (used inside body of certain pages) */
.stub-sublist {
  display: grid; gap: 14px;
  grid-template-columns: repeat(2, 1fr);
}
@media (max-width: 760px) { .stub-sublist { grid-template-columns: 1fr; } }
.stub-sublist__item {
  padding: 16px 18px;
  background: rgba(10,16,22,0.5);
  border: 1px solid var(--hud-line);
  border-radius: 2px;
}
.stub-sublist__item b {
  font-family: var(--font-display); font-weight: 600; font-size: 15px;
  color: #fff; display: block; margin-bottom: 4px;
  letter-spacing: -0.01em;
}
.stub-sublist__item span { color: var(--text-mut); font-size: 13px; line-height: 1.45; }

/* mobile adjustments */
@media (max-width: 720px) {
  .stub { padding: 100px 0 60px; }
  .stub-panel-body { padding: 22px 18px; }
  .stub-cta .btn-p404 { width: 100%; justify-content: center; }
  .stub-log li { grid-template-columns: 70px 1fr; }
  .stub-log li b { grid-column: 2; }
  .stub-log li :last-child { grid-column: 1 / -1; }
}

/* ===================================================================
   MOBILE — consolidated fixes for phones (added 2026-05-20)
   =================================================================== */
@media (max-width: 720px) {
  /* tighter container padding so content has room */
  .container { padding: 0 18px; }
  .p404-nav { padding: 14px 18px; }

  /* hide ambient telemetry — too cluttered on small screens; ticker stays */
  .hud__corner--bl, .hud__corner--br { display: none; }
  .hud__corner { width: 18px; height: 18px; }

  /* hero — keep PROJECT 404 side-by-side, smaller, hide some HUDs */
  .hero { padding-top: 90px; padding-bottom: 40px; }
  .hero__title { font-size: clamp(34px, 9vw, 60px); gap: 0.28em; }
  .hero__sub { font-size: clamp(18px, 4.6vw, 24px); }
  .hero__support { font-size: 9.5px; letter-spacing: 0.2em; }
  .hero__meta { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hero__loc { font-size: 9.5px; }
  .hero__ctas { flex-direction: column; align-items: stretch; }
  .hero__ctas .btn-p404 { width: 100%; justify-content: center; }
  .hero__hud--a, .hero__hud--b { display: none; } /* keep only the bars panel */
  .hero__hud--c { margin-top: 8px; }
  .hero__scroll { display: none; } /* not needed on mobile */

  /* section heads */
  .section-eyebrow { padding-top: 50px; flex-wrap: wrap; }
  .section-eyebrow__id { margin-left: 0; flex-basis: 100%; font-size: 9.5px; }
  .section-title { font-size: clamp(28px, 6.5vw, 42px); }
  .section-lede { font-size: 14.5px; }

  /* AI network stage: panels stack below the canvas instead of corner-overlapping */
  .net__stage {
    margin: 12px 18px 0;
    height: auto;
    min-height: 320px;
    display: flex;
    flex-direction: column;
  }
  .net__stage #netCanvas { position: relative; height: 320px; width: 100%; flex: 0 0 320px; }
  .net__overlay { position: relative; inset: auto; padding: 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .net__panel { position: relative; inset: auto !important; min-width: 0 !important; max-width: none; }
  .net__panel--bl { grid-column: 1 / -1; min-width: 0 !important; }
  .net__crosshair { display: none; }
  .net__panel-bignum { font-size: 30px; }

  /* community */
  .community__panel { min-height: auto; }
  .community__feed { padding: 10px 12px; }
  .community__feed li {
    grid-template-columns: 56px 1fr;
    grid-template-rows: auto auto;
    gap: 4px 10px;
  }
  .community__feed time { grid-column: 1; grid-row: 1; }
  .community__feed b    { grid-column: 2; grid-row: 1; }
  .community__feed li > :last-child { grid-column: 1 / -1; grid-row: 2; padding-left: 0; opacity: 0.85; }

  /* community stats: 2-up, more breathing room */
  .community__stats { gap: 10px; }
  .community__stats li { padding: 18px 16px; }

  /* intel cards */
  .intel__card { padding: 18px 18px 16px; }
  .intel__card-title { font-size: 17px; }

  /* final scene */
  .final { padding: 80px 0 60px; }
  .final__title { font-size: clamp(32px, 8.5vw, 56px); }
  .final__sub br { display: none; }
  .final__sub { font-size: 14.5px; }
  .final__stamp { flex-direction: column; align-items: flex-start; gap: 12px; }

  /* footer */
  .p404-foot { padding: 40px 0 50px; }
  .p404-foot__cols { gap: 18px 14px; }
  .p404-foot__cols div { font-size: 11px; }

  /* boot — hide bottom corner labels (might overlap the core) */
  .boot__corner--bl, .boot__corner--br { display: none; }
  .boot__brand-mark { font-size: clamp(28px, 9vw, 48px); }
  .boot__ring { width: 220px; height: 220px; margin-bottom: -140px; }
  .boot__brand { padding-top: 110px; }
}

/* very small phones (iPhone SE class, <380px) */
@media (max-width: 380px) {
  .container { padding: 0 14px; }
  .hero__title { font-size: clamp(30px, 10vw, 42px); gap: 0.24em; }
  .hud__ticker { left: 10px; right: 10px; }
  .net__overlay { grid-template-columns: 1fr; }
}

/* taller-than-wide ratio guard: keep three.js canvas from being absurdly tall on landscape phones */
@media (max-height: 480px) and (orientation: landscape) {
  .hero { min-height: auto; padding-top: 70px; padding-bottom: 40px; }
  .hero__layout { min-height: auto; }
  .hero__hud--c { display: none; }
}

/* ===================================================================
   REDUCED MOTION
   =================================================================== */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .boot { display: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
  body.p404.is-booting { overflow: auto; height: auto; }
}
