/* Neon Runner — styles. Plain CSS, no build step. */

:root {
  --bg: #07060f;
  --bg-2: #0b0d1e;
  --bg-3: #10122a;
  --panel: #0d0f22;
  --line: #262a52;
  --text: #e6e9ff;
  --muted: #a3a9d6;
  --magenta: #ff2bd6;
  --cyan: #00f0ff;
  --violet: #9d7bff;
  --red: #ff4d6d;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --radius: 10px;
  --max: 1120px;
}

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

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

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(255, 43, 214, .14), transparent 60%),
    radial-gradient(900px 500px at -10% 10%, rgba(0, 240, 255, .10), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  overflow-x: hidden;
}

/* CRT scanline overlay */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  background: repeating-linear-gradient(to bottom, rgba(0, 0, 0, 0) 0, rgba(0, 0, 0, 0) 2px, rgba(0, 0, 0, .18) 3px, rgba(0, 0, 0, 0) 4px);
  mix-blend-mode: multiply;
  animation: scan 9s linear infinite;
}
@keyframes scan { from { background-position-y: 0; } to { background-position-y: 40px; } }

img, svg { max-width: 100%; display: block; }
a { color: var(--cyan); text-underline-offset: 3px; }
a:hover { color: #7ff7ff; }

h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .6em; font-weight: 700; }
h2 { font-size: clamp(1.7rem, 4.5vw, 2.4rem); letter-spacing: .01em; }
h3 { font-size: 1.2rem; }
h4 { font-size: 1.1rem; margin-bottom: .4em; }
p { margin: 0 0 1em; }
ul, ol { padding: 0; margin: 0; }
code { font-family: var(--font-mono); }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1.25rem; }
.container-narrow { max-width: 780px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Focus */
:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}
main:focus { outline: none; }

/* Skip link */
.skip-link {
  position: absolute; left: .75rem; top: -4rem; z-index: 200;
  background: var(--cyan); color: #00131a; padding: .6rem 1rem;
  font-weight: 700; border-radius: 6px; text-decoration: none;
}
.skip-link:focus { top: .75rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 6, 15, .88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: .4rem 1rem; padding-top: .6rem; padding-bottom: .6rem;
}
.brand {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-mono); font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; text-decoration: none; color: var(--text);
  margin-right: auto; font-size: .95rem;
}
.brand-mark { color: var(--magenta); text-shadow: 0 0 8px var(--magenta); }
.brand:hover { color: var(--cyan); }

.site-nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: thin; }
.site-nav ul { display: flex; gap: .25rem; list-style: none; white-space: nowrap; }
.site-nav a {
  display: inline-block; padding: .4rem .65rem; color: var(--muted);
  text-decoration: none; font-family: var(--font-mono); font-size: .8rem;
  letter-spacing: .04em; border-radius: 6px;
}
.site-nav a:hover { color: var(--cyan); background: rgba(0, 240, 255, .08); }

/* Sections */
.section { padding: 4rem 0; position: relative; }
.section-alt { background: linear-gradient(180deg, var(--bg-2), var(--bg)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.eyebrow {
  font-family: var(--font-mono); color: var(--magenta); font-size: .8rem;
  letter-spacing: .18em; text-transform: uppercase; margin-bottom: .5rem;
}
.lead { font-size: 1.12rem; color: var(--text); max-width: 62ch; }
.sys { font-family: var(--font-mono); color: var(--cyan); font-weight: 700; }

/* Hero */
.hero { padding: 3rem 0 3.5rem; }
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
.prompt-line { font-family: var(--font-mono); color: var(--muted); font-size: .9rem; margin-bottom: 1.25rem; }
.prompt-type {
  display: inline-block; max-width: 100%;
  animation: type 2.6s steps(48, end) .3s both;
}
@keyframes type { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
.cursor { color: var(--cyan); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.glitch {
  position: relative; display: inline-block;
  font-family: var(--font-mono); font-weight: 800; text-transform: uppercase;
  font-size: clamp(2.5rem, 12vw, 5rem); letter-spacing: .04em; line-height: 1;
  color: #fff; margin: 0 0 1rem;
  text-shadow: 0 0 6px rgba(255, 43, 214, .9), 0 0 24px rgba(255, 43, 214, .55), 0 0 42px rgba(0, 240, 255, .35);
  animation: flicker 7s infinite;
}
.glitch::before, .glitch::after {
  content: attr(data-text);
  position: absolute; inset: 0; overflow: hidden; pointer-events: none;
  text-shadow: none;
}
.glitch::before { color: var(--cyan); animation: glitch-a 4s infinite steps(1); clip-path: inset(0 0 55% 0); }
.glitch::after { color: var(--magenta); animation: glitch-b 4s infinite steps(1); clip-path: inset(55% 0 0 0); }
@keyframes glitch-a {
  0%, 90%, 100% { transform: translate(0); opacity: 0; }
  91% { transform: translate(-3px, -1px); opacity: .85; }
  94% { transform: translate(3px, 1px); opacity: .85; }
  97% { transform: translate(-2px, 0); opacity: .85; }
}
@keyframes glitch-b {
  0%, 88%, 100% { transform: translate(0); opacity: 0; }
  89% { transform: translate(3px, 1px); opacity: .85; }
  93% { transform: translate(-3px, -1px); opacity: .85; }
  96% { transform: translate(2px, 0); opacity: .85; }
}
@keyframes flicker {
  0%, 18%, 22%, 62%, 64%, 100% { opacity: 1; }
  20%, 63% { opacity: .78; }
}

.tagline { font-size: clamp(1.15rem, 3.2vw, 1.5rem); color: var(--cyan); font-weight: 600; margin-bottom: .75rem; max-width: 32ch; }
.hero-sub { color: var(--muted); max-width: 54ch; }
.hero-sub [data-cfg] { color: var(--magenta); font-family: var(--font-mono); font-weight: 700; }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.5rem 0; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 2.9rem; padding: .65rem 1.25rem;
  font-family: var(--font-mono); font-weight: 700; font-size: .92rem; letter-spacing: .04em;
  text-decoration: none; border-radius: 8px; border: 2px solid transparent;
  transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-magenta { background: var(--magenta); color: #1a0016; box-shadow: 0 0 18px rgba(255, 43, 214, .4); }
.btn-magenta:hover { color: #1a0016; background: #ff6ee3; }

/* Token box */
.token-box {
  border: 1px solid var(--line); border-left: 3px solid var(--magenta);
  background: var(--panel); border-radius: var(--radius); padding: 1rem 1.1rem;
  max-width: 560px; font-family: var(--font-mono);
}
.token-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; padding: .25rem 0; }
.token-label { color: var(--muted); font-size: .75rem; letter-spacing: .16em; min-width: 5.5rem; }
.ticker { color: var(--magenta); font-weight: 800; font-size: 1.15rem; }
.ca-value { color: var(--text); background: var(--bg); border: 1px dashed var(--line); padding: .25rem .6rem; border-radius: 6px; font-size: .9rem; overflow-wrap: anywhere; }
.copy-btn {
  font-family: var(--font-mono); font-size: .8rem; font-weight: 700;
  background: var(--cyan); color: #00131a; border: 0; border-radius: 6px;
  padding: .4rem .8rem; min-height: 2.2rem; cursor: pointer;
}
.copy-btn:hover:not(:disabled) { background: #6ff6ff; }
.copy-btn:disabled { background: transparent; color: var(--muted); border: 1px solid var(--line); cursor: not-allowed; }
.token-note { font-family: var(--font-body); color: var(--muted); font-size: .85rem; margin: .6rem 0 0; }

.hero-art svg { width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 0 40px rgba(255, 43, 214, .15); }
.rain { animation: rain 1.6s linear infinite; }
@keyframes rain { from { transform: translate(0, -20px); } to { transform: translate(-8px, 20px); } }

/* Cards */
.cards { display: grid; gap: 1rem; margin: 1.25rem 0 2rem; }
.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.25rem; position: relative;
}
.card p:last-child { margin-bottom: 0; }
.card-tag { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .16em; color: var(--muted); margin-bottom: .35rem; }
.card-cyan { border-top: 3px solid var(--cyan); }
.card-magenta { border-top: 3px solid var(--magenta); }
.card-violet { border-top: 3px solid var(--violet); }
.tier { border-left: 3px solid var(--cyan); }
.tier:nth-child(2) { border-left-color: var(--violet); }
.tier:nth-child(3) { border-left-color: var(--magenta); }

.lore-grid { display: grid; gap: .25rem; margin-bottom: 1.5rem; }
.lore-grid p { max-width: 70ch; color: var(--muted); }
.lore-grid p.lead { color: var(--text); }
.lore-grid strong { color: var(--text); }

/* Heat panel */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; }
.heat-scale { height: 12px; border-radius: 999px; border: 1px solid var(--line); overflow: hidden; margin-top: 1rem; }
.heat-scale-bar { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--violet) 50%, var(--magenta) 80%, var(--red)); }
.heat-ticks { display: flex; justify-content: space-between; font-family: var(--font-mono); color: var(--muted); font-size: .75rem; margin-top: .3rem; }
.heat-bands { display: grid; gap: .5rem; margin: 1rem 0 0; }
.heat-bands div { display: flex; gap: .75rem; }
.heat-bands dt { font-family: var(--font-mono); color: var(--cyan); min-width: 3.2rem; font-weight: 700; }
.heat-bands dd { margin: 0; color: var(--muted); }

/* Steps */
.steps { list-style: none; display: grid; gap: 1rem; margin: 1.5rem 0; counter-reset: s; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.25rem 1.25rem 1.25rem; position: relative; }
.step-num { font-family: var(--font-mono); font-size: 2rem; font-weight: 800; color: var(--magenta); text-shadow: 0 0 12px rgba(255, 43, 214, .6); display: block; line-height: 1; margin-bottom: .6rem; }
.step h3 { margin-bottom: .3rem; }
.step p { margin: 0; color: var(--muted); }
.note, .disclaimer-note, .vote-line { font-size: .95rem; color: var(--muted); }
.disclaimer-note { border: 1px dashed var(--line); border-radius: var(--radius); padding: .8rem 1rem; max-width: 70ch; }

/* Terminal */
.terminal {
  background: #05060d; border: 1px solid var(--cyan); border-radius: var(--radius);
  box-shadow: 0 0 30px rgba(0, 240, 255, .15), inset 0 0 40px rgba(0, 240, 255, .04);
  max-width: 820px; margin: 1.5rem auto 0; overflow: hidden;
}
.terminal-bar { display: flex; align-items: center; gap: .75rem; background: #0d1530; padding: .55rem .9rem; border-bottom: 1px solid var(--line); }
.dots { display: inline-flex; gap: .35rem; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--magenta); display: block; }
.dots i:nth-child(2) { background: var(--violet); }
.dots i:nth-child(3) { background: var(--cyan); }
.terminal-path { font-family: var(--font-mono); font-size: .78rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.terminal-body { padding: 1.25rem; font-family: var(--font-mono); font-size: .95rem; line-height: 1.7; }
.ep-meta { color: var(--magenta); font-size: .78rem; letter-spacing: .16em; margin-bottom: .2rem; }
.ep-name { font-size: 1.6rem; color: var(--cyan); text-shadow: 0 0 10px rgba(0, 240, 255, .5); margin-bottom: 1rem; }
.ep-text p { color: #d7dcff; }
.sig { color: var(--red); font-weight: 700; }
.ep-q { color: var(--text); font-weight: 700; }
.choices { margin: 0 0 1.25rem; padding-left: 0; list-style: none; counter-reset: c; }
.choices li {
  counter-increment: c; position: relative; padding: .6rem .8rem .6rem 2.6rem; margin-bottom: .5rem;
  border: 1px solid var(--line); border-radius: 8px; background: rgba(0, 240, 255, .04);
}
.choices li::before {
  content: counter(c); position: absolute; left: .8rem; top: .6rem;
  color: var(--magenta); font-weight: 800;
}
.heat { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin-bottom: 1rem; }
.heat-text b { color: var(--magenta); }
.heat-bar { display: inline-flex; gap: 3px; }
.heat-bar i { width: 16px; height: 12px; background: #1a1d3a; border-radius: 2px; display: block; }
.heat-bar i.on { background: linear-gradient(180deg, var(--magenta), #c4129f); box-shadow: 0 0 8px rgba(255, 43, 214, .6); }
.vote-line { margin: 0; }

/* Tokenomics */
.facts { display: grid; gap: .75rem; margin: 1.5rem 0 0; }
.fact { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; }
.fact dt { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-bottom: .2rem; }
.fact dd { margin: 0; font-weight: 600; font-size: 1.05rem; overflow-wrap: anywhere; }
.fact code { color: var(--cyan); }

/* Characters */
.char { text-align: left; }
.avatar {
  width: 52px; height: 52px; display: grid; place-items: center; margin-bottom: .75rem;
  font-family: var(--font-mono); font-weight: 800; font-size: 1.4rem; border-radius: 10px;
  border: 2px solid currentColor; background: rgba(255, 255, 255, .03);
}
.avatar-cyan { color: var(--cyan); box-shadow: 0 0 14px rgba(0, 240, 255, .35); }
.avatar-magenta { color: var(--magenta); box-shadow: 0 0 14px rgba(255, 43, 214, .35); }
.avatar-violet { color: var(--violet); box-shadow: 0 0 14px rgba(157, 123, 255, .35); }
.avatar-red { color: var(--red); box-shadow: 0 0 14px rgba(255, 77, 109, .35); }
.char h3 { margin-bottom: .1rem; }
.char p { color: var(--muted); }
.char .card-tag { color: var(--cyan); }

/* FAQ */
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: .7rem; }
.faq summary {
  cursor: pointer; padding: 1rem 3rem 1rem 1.1rem; font-weight: 600; list-style: none; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 1.1rem; top: 50%; transform: translateY(-50%);
  font-family: var(--font-mono); color: var(--magenta); font-size: 1.4rem; font-weight: 700;
}
.faq details[open] summary::after { content: "\2212"; }
.faq details[open] { border-color: var(--cyan); }
.faq details p { padding: 0 1.1rem 1.1rem; margin: 0; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0 3rem; background: #05050c; }
.disclaimer {
  font-family: var(--font-mono); font-size: .9rem; color: var(--text);
  border: 1px solid var(--magenta); border-radius: var(--radius); padding: .9rem 1rem; max-width: 70ch;
}
.foot-links { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; list-style: none; margin: 1.5rem 0 1rem; }
.foot-links a { font-family: var(--font-mono); font-size: .88rem; }
.copyright { color: var(--muted); font-size: .85rem; margin: 0; }

/* Tablet / desktop */
@media (min-width: 640px) {
  .cards-3 { grid-template-columns: repeat(3, 1fr); }
  .cards-4 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .fact-wide { grid-column: 1 / -1; }
}
@media (min-width: 960px) {
  .header-inner { flex-wrap: nowrap; }
  .site-nav { order: 0; width: auto; overflow: visible; }
  .hero { padding: 5rem 0 5.5rem; }
  .hero-grid { grid-template-columns: 1.15fr .85fr; }
  .section { padding: 5rem 0; }
  .cards-4 { grid-template-columns: repeat(4, 1fr); }
  .steps { grid-template-columns: repeat(4, 1fr); }
  .facts { grid-template-columns: repeat(3, 1fr); }
  .lore-grid { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
  .terminal-body { padding: 1.75rem 2rem; font-size: 1rem; }
}

/* Reduced motion: no glitch, flicker, scanline movement, typing, rain or smooth scroll */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  body::after { animation: none; }
  .glitch { animation: none; }
  .glitch::before, .glitch::after { animation: none; display: none; }
  .prompt-type { animation: none; }
  .cursor { animation: none; }
  .rain { animation: none; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}
