:root {
  --bg: #050a18;
  --bg-2: #081026;
  --panel: #0c1633;
  --panel-2: #0f1c40;
  --line: rgba(130, 170, 255, 0.13);
  --line-2: rgba(130, 170, 255, 0.24);
  --text: #e7edff;
  --muted: #94a3c8;
  --dim: #64739a;
  --blue: #1e5bff;
  --blue-2: #3b82f6;
  --cyan: #22d3ee;
  --trad: #f97362;
  --trad-soft: rgba(249, 115, 98, 0.12);
  --arc: #22d3ee;
  --arc-soft: rgba(34, 211, 238, 0.12);
  --grad: linear-gradient(100deg, #1e5bff 0%, #2f8bff 45%, #22d3ee 100%);
  --radius: 16px;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Consolas, monospace;
  --mc: 'VT323', ui-monospace, monospace;
  --shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.6);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; }
code { font-family: var(--mono); font-size: 0.88em; background: rgba(130, 170, 255, 0.1); padding: 0.1em 0.4em; border-radius: 6px; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0; letter-spacing: -0.02em; }
p { margin: 0; }

.wrap { width: min(1240px, 100% - 48px); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: 0.85em; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px) saturate(140%);
  background: rgba(5, 10, 24, 0.6);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, background 0.2s;
}
.nav.is-scrolled { border-bottom-color: var(--line); background: rgba(5, 10, 24, 0.85); }
.nav-inner { width: min(1240px, 100% - 48px); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.nav-links { display: flex; gap: 4px; align-items: center; }
.nav-links a { padding: 8px 14px; border-radius: 999px; color: var(--muted); font-weight: 500; font-size: 0.94rem; transition: color 0.15s, background 0.15s; }
.nav-links a:hover, .nav-links a.is-active { color: var(--text); background: rgba(130, 170, 255, 0.08); }
.nav-links .nav-cta { background: var(--grad); color: #fff; margin-left: 8px; }
.nav-links .nav-cta:hover { color: #fff; filter: brightness(1.1); background: var(--grad); }

/* ---------- Buttons & chips ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 14px 24px; border-radius: 999px; font-weight: 600; transition: transform 0.15s, box-shadow 0.15s, background 0.15s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 10px 30px -10px rgba(34, 140, 255, 0.7); }
.btn-ghost { border: 1px solid var(--line-2); color: var(--text); }
.btn-ghost:hover { background: rgba(130, 170, 255, 0.08); }

.chip {
  border: 1px solid var(--line-2); background: rgba(130, 170, 255, 0.05);
  padding: 7px 14px; border-radius: 999px; cursor: pointer; font-size: 0.88rem; font-weight: 500;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.chip:hover { background: rgba(130, 170, 255, 0.12); }
.chip.is-active { background: rgba(34, 211, 238, 0.14); border-color: rgba(34, 211, 238, 0.55); color: #a5f3fc; }

.mini-btn {
  border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(255, 255, 255, 0.07);
  padding: 7px 12px; border-radius: 8px; cursor: pointer; font-size: 0.86rem; font-weight: 500;
  font-family: var(--mono); transition: background 0.15s, transform 0.1s;
}
.mini-btn:hover { background: rgba(255, 255, 255, 0.14); }
.mini-btn:active { transform: translateY(1px); }
.mini-btn.danger { border-color: rgba(248, 113, 113, 0.45); color: #fca5a5; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 96px 0 110px; }
.hero-glow {
  position: absolute; inset: -30% -10% auto auto; width: 900px; height: 900px; pointer-events: none;
  background: radial-gradient(closest-side circle at center, rgba(30, 91, 255, 0.35), transparent),
              radial-gradient(closest-side circle at 60% 40%, rgba(34, 211, 238, 0.22), transparent);
}
.hero-inner { position: relative; display: grid; grid-template-columns: 1.25fr 1fr; gap: 48px; align-items: center; }
.eyebrow { display: inline-block; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #7dd3fc; margin-bottom: 18px; }
.hero h1 { font-size: clamp(2.5rem, 5.4vw, 4.4rem); font-weight: 800; margin-bottom: 22px; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 620px; }
.hero-actions { display: flex; gap: 14px; margin: 34px 0 44px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 36px; flex-wrap: wrap; }
.hero-stats div { display: flex; flex-direction: column; max-width: 180px; }
.hero-stats strong { font-size: 2.3rem; font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; line-height: 1.1; }
.hero-stats span { color: var(--muted); font-size: 0.9rem; }
.hero-art { display: flex; justify-content: center; }
.logo-orbit {
  position: relative; width: 340px; height: 340px; display: grid; place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.18), transparent 65%);
}
.logo-orbit::before, .logo-orbit::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  border: 1px dashed rgba(125, 211, 252, 0.25); animation: spin 40s linear infinite;
}
.logo-orbit::after { inset: -34px; border-style: solid; border-color: rgba(59, 130, 246, 0.12); animation-duration: 70s; animation-direction: reverse; }
.logo-orbit img { width: 256px; height: 256px; filter: drop-shadow(0 20px 50px rgba(34, 140, 255, 0.45)); animation: float 6s ease-in-out infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 50% { transform: translateY(-10px); } }

/* ---------- Sections ---------- */
.section { padding: 104px 0; }
.section-alt { background: linear-gradient(180deg, var(--bg-2), var(--bg)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 780px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 800; margin-bottom: 16px; }
.section-head p { color: var(--muted); font-size: 1.1rem; }

.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.why-card { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.why-soon {
  background: linear-gradient(160deg, rgba(30, 91, 255, 0.14), rgba(34, 211, 238, 0.06) 60%, var(--panel));
  border: 1px dashed rgba(34, 211, 238, 0.45);
}
.soon-badge {
  position: absolute; top: 22px; right: 22px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: #a5f3fc; background: rgba(34, 211, 238, 0.12); border: 1px solid rgba(34, 211, 238, 0.4); padding: 4px 10px; border-radius: 999px;
}
.why-icon { font-size: 1.9rem; margin-bottom: 14px; }
.why-card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.why-card p { color: var(--muted); font-size: 0.96rem; }

/* ---------- Compare ---------- */
.compare-tabs { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-bottom: 24px; }
.ctab {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left;
  padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--panel);
  cursor: pointer; transition: border-color 0.15s, background 0.15s, transform 0.15s;
}
.ctab:hover { transform: translateY(-2px); border-color: var(--line-2); }
.ctab.is-active { border-color: rgba(34, 211, 238, 0.6); background: linear-gradient(180deg, rgba(34, 211, 238, 0.1), var(--panel)); }
.ctab-icon { font-size: 1.4rem; margin-bottom: 6px; }
.ctab-label { font-weight: 700; }
.ctab-save { font-size: 0.8rem; color: #67e8f9; font-weight: 600; }

.compare-body { background: var(--panel); border: 1px solid var(--line); border-radius: 22px; padding: 32px; box-shadow: var(--shadow); }
.compare-summary { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; margin-bottom: 28px; }
.compare-task h3 { font-size: 1.6rem; margin-bottom: 10px; }
.cmp-task { font-family: var(--mono); font-size: 0.88rem; color: #a5b4fc; background: rgba(99, 102, 241, 0.1); border: 1px solid rgba(99, 102, 241, 0.25); padding: 10px 14px; border-radius: 10px; margin-bottom: 16px; }
.cmp-plain { color: var(--muted); font-size: 1.02rem; }

.compare-meters { display: flex; flex-direction: column; gap: 18px; }
.meter-head { display: flex; justify-content: space-between; font-weight: 600; font-size: 0.92rem; margin-bottom: 6px; }
.meter-save { color: #67e8f9; }
.meter-row { display: grid; grid-template-columns: 76px 1fr 44px; align-items: center; gap: 10px; margin: 4px 0; font-size: 0.85rem; }
.meter-name { color: var(--muted); }
.meter-val { text-align: right; font-family: var(--mono); font-weight: 700; }
.meter-track { height: 12px; background: rgba(255, 255, 255, 0.05); border-radius: 999px; overflow: hidden; }
.meter-fill { height: 100%; width: 0; border-radius: 999px; transition: width 0.9s cubic-bezier(0.2, 0.8, 0.2, 1); }
.compare-meters.is-in .meter-fill { width: var(--w); }
.meter-trad { background: linear-gradient(90deg, #fb923c, var(--trad)); }
.meter-arc { background: var(--grad); }

.compare-lists { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 28px; }
.clist { border-radius: 14px; padding: 20px 22px; }
.clist h4 { font-size: 1rem; margin-bottom: 10px; }
.clist ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 7px; }
.clist li { position: relative; padding-left: 26px; font-size: 0.95rem; }
.clist li::before { position: absolute; left: 0; top: 0; font-weight: 800; }
.clist-trad { background: var(--trad-soft); border: 1px solid rgba(249, 115, 98, 0.25); }
.clist-trad h4 { color: #fdba74; }
.clist-trad li::before { content: '✗'; color: var(--trad); }
.clist-arc { background: var(--arc-soft); border: 1px solid rgba(34, 211, 238, 0.28); }
.clist-arc h4 { color: #67e8f9; }
.clist-arc li::before { content: '✓'; color: var(--arc); }

.compare-view-toggle { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; color: var(--muted); font-size: 0.9rem; flex-wrap: wrap; }
.compare-code { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.code-col-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.code-col-count { font-family: var(--mono); font-size: 0.82rem; color: var(--muted); }
.tag { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; padding: 5px 11px; border-radius: 999px; }
.tag-trad { background: var(--trad-soft); color: #fdba74; border: 1px solid rgba(249, 115, 98, 0.3); }
.tag-arc { background: var(--arc-soft); color: #67e8f9; border: 1px solid rgba(34, 211, 238, 0.35); }
.compare-code[data-view="side"] .code-col-arc { position: sticky; top: 88px; }
.compare-code[data-view="side"] pre.code { font-size: 11.2px; line-height: 1.55; }
.compare-code[data-view="side"] .code-scroll { max-height: none; }
.compare-code[data-view="side"] .code-col-arc .code-scroll { max-height: calc(100vh - 160px); }
.compare-code[data-view="read"] { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.compare-code[data-view="read"] .code-scroll { max-height: 600px; }
.code-col-trad .code-panel { border-color: rgba(249, 115, 98, 0.28); }
.code-col-arc .code-panel { border-color: rgba(34, 211, 238, 0.35); box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.08), 0 20px 50px -20px rgba(34, 211, 238, 0.25); }

.totals { margin-top: 40px; background: var(--panel); border: 1px solid var(--line); border-radius: 22px; padding: 32px; }
.totals h3 { font-size: 1.3rem; margin-bottom: 20px; }
.total-row { display: grid; grid-template-columns: 190px 1fr 170px; gap: 16px; align-items: center; margin-bottom: 12px; }
.total-name { font-weight: 600; }
.total-val { font-family: var(--mono); font-size: 0.9rem; text-align: right; color: var(--muted); }
.total-track { height: 22px; background: rgba(255, 255, 255, 0.05); border-radius: 999px; overflow: hidden; }
.total-fill { height: 100%; width: 0; border-radius: 999px; transition: width 1.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.totals.is-in .total-fill { width: var(--w); }
.total-callout { margin-top: 20px; font-size: 1.15rem; }
.total-callout b { font-size: 2rem; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; margin-right: 6px; }
.fineprint { margin-top: 16px; font-size: 0.82rem; color: var(--dim); max-width: 900px; }

/* ---------- Code panels ---------- */
.code-panel { background: #060c1f; border: 1px solid var(--line-2); border-radius: 14px; overflow: hidden; }
.code-tabs { display: flex; align-items: center; gap: 2px; padding: 6px 6px 0; background: rgba(255, 255, 255, 0.025); border-bottom: 1px solid var(--line); overflow-x: auto; }
.code-tab { border: 0; background: transparent; padding: 7px 12px; font-family: var(--mono); font-size: 0.78rem; color: var(--muted); border-radius: 8px 8px 0 0; cursor: pointer; white-space: nowrap; }
.code-tab.is-active { background: #060c1f; color: var(--text); box-shadow: inset 0 2px 0 var(--blue-2); }
.code-spacer { flex: 1; }
.code-copy { border: 1px solid var(--line-2); background: transparent; color: var(--muted); font-size: 0.74rem; padding: 3px 10px; border-radius: 6px; cursor: pointer; margin: 0 4px 5px; }
.code-copy:hover { color: var(--text); }
.code-scroll { overflow: auto; max-height: 540px; scrollbar-width: thin; scrollbar-color: rgba(130, 170, 255, 0.25) transparent; }
.code-file-label { position: sticky; top: 0; z-index: 1; font-family: var(--mono); font-size: 0.74rem; color: #fdba74; padding: 6px 14px; background: #0a1430; border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); }
.code-file-label:first-child { border-top: 0; }
pre.code { margin: 0; padding: 12px 0; font-family: var(--mono); font-size: 12.6px; line-height: 1.65; counter-reset: l; }
.cl { display: flex; padding-right: 16px; min-width: max-content; transition: background 0.6s; }
.cn { width: 44px; flex: none; text-align: right; padding-right: 14px; color: #33406a; user-select: none; }
.cc { white-space: pre; }
.cl.flash { animation: flash 1.4s ease-out; }
@keyframes flash {
  0% { background: rgba(34, 211, 238, 0.32); box-shadow: inset 3px 0 0 var(--cyan); }
  100% { background: transparent; box-shadow: inset 3px 0 0 transparent; }
}
.tk-kw { color: #c792ea; }
.tk-str { color: #a5e57a; }
.tk-com { color: #5b6a93; font-style: italic; }
.tk-ann { color: #fbbf24; }
.tk-num { color: #f78c6c; }
.tk-type { color: #7dd3fc; }
.tk-fn { color: #82aaff; }
.tk-key { color: #7dd3fc; }

/* ---------- Demos ---------- */
.demo-nav {
  position: sticky; top: 68px; z-index: 20; display: flex; gap: 6px; flex-wrap: wrap;
  padding: 12px 0; margin-bottom: 36px; background: linear-gradient(var(--bg) 70%, transparent);
}
.demo-nav a { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); font-size: 0.88rem; color: var(--muted); background: var(--panel); transition: all 0.15s; }
.demo-nav a:hover, .demo-nav a.is-active { color: var(--text); border-color: rgba(34, 211, 238, 0.55); background: rgba(34, 211, 238, 0.1); }

.demo { background: var(--panel); border: 1px solid var(--line); border-radius: 22px; padding: 30px; margin-bottom: 36px; box-shadow: var(--shadow); scroll-margin-top: 140px; }
.demo-head { display: flex; justify-content: space-between; gap: 32px; margin-bottom: 24px; }
.demo-head > div { max-width: 720px; }
.demo-kicker { font-size: 0.76rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #7dd3fc; }
.demo-head h3 { font-size: 1.6rem; margin: 6px 0 10px; }
.demo-head p { color: var(--muted); }
.demo-facts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; min-width: 200px; }
.demo-facts li { font-size: 0.88rem; color: var(--muted); background: rgba(34, 211, 238, 0.06); border: 1px solid rgba(34, 211, 238, 0.18); border-radius: 10px; padding: 6px 12px; }
.demo-facts b { color: #67e8f9; font-family: var(--mono); font-size: 1.05rem; margin-right: 4px; }
.demo-body { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.demo-code .code-scroll { max-height: 560px; }

.demo-stage {
  position: relative; border-radius: 16px; padding: 18px; min-height: 420px;
  display: flex; flex-direction: column; gap: 14px;
}
.stage-world {
  background:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(180deg, #1a2a55 0%, #16254a 50%, #1b3a2a 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Minecraft primitives */
.mc-text, .mc-line, .mc-inv-title, .mc-sidebar, .bossbar-title, .actionbar, .holo-text, .holo-board, .npc-label, .mc-tooltip, .s-name, .cmd-input, .cmd-suggest, .cmd-hint, .console {
  font-family: var(--mc); font-size: 20px; line-height: 1.15; letter-spacing: 0.01em;
}
.mc-line, .mc-text, .holo-text, .holo-board, .bossbar-title, .actionbar, .npc-label, .s-name, .mc-sidebar { text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.55); }
.c-amber { color: #fcd34d; }
.c-green5 { color: #22c55e; }
.c-green { color: #4ade80; }
.c-gray { color: #aaaaaa; }
.c-dim { color: #7f8aa8; }
.c-white { color: #ffffff; }
.c-red { color: #ff6b6b; }
.c-sky { color: #7dd3fc; }
.c-yellow { color: #ffff55; }
.c-cyan { color: #55ffff; }
.b { font-weight: 700; }

.mc-hud-top { display: flex; justify-content: space-between; align-items: center; }
.mc-inv {
  align-self: center; background: #c6c6c6; padding: 10px 12px 12px; border-radius: 4px;
  box-shadow: inset 3px 3px 0 #fff, inset -3px -3px 0 #555, 0 0 0 2px #000, 0 20px 40px -10px rgba(0, 0, 0, 0.6);
}
.mc-inv-title { color: #404040; margin-bottom: 6px; text-shadow: none; }
.mc-inv-title .b { text-shadow: none; }
.mc-grid { display: grid; grid-template-columns: repeat(9, 40px); }
.mc-slot {
  position: relative; width: 40px; height: 40px; background: #8b8b8b;
  box-shadow: inset 2px 2px 0 #373737, inset -2px -2px 0 #fff;
  display: grid; place-items: center; user-select: none;
}
.mc-slot.has-item { cursor: pointer; }
.mc-slot.has-item:hover { background: #a3a3a3; }
.mc-slot.deny { animation: shake 0.35s; }
.mc-item { font-size: 24px; line-height: 1; filter: drop-shadow(1px 2px 0 rgba(0, 0, 0, 0.35)); }
.mc-pane { width: 32px; height: 32px; background: rgba(80, 80, 80, 0.55); box-shadow: inset 0 0 0 2px rgba(60, 60, 60, 0.6); }
.mc-count { position: absolute; right: 2px; bottom: -2px; font-family: var(--mc); font-size: 20px; color: #fff; text-shadow: 2px 2px 0 #3f3f3f; }
.mc-inv-small .mc-inv-title { font-size: 17px; }
@keyframes shake { 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }

.mc-chat {
  background: rgba(0, 0, 0, 0.45); border-radius: 4px; padding: 8px 10px; min-height: 96px; max-height: 150px;
  overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end;
}
.mc-chat-tall { min-height: 170px; max-height: 210px; }
.mc-line { color: #fff; animation: lineIn 0.25s ease-out; word-break: break-word; }
@keyframes lineIn { from { opacity: 0; transform: translateY(4px); } }

.mc-tooltip {
  position: fixed; left: 0; top: 0; z-index: 100; pointer-events: none; opacity: 0;
  background: rgba(16, 0, 16, 0.94); padding: 6px 9px; border-radius: 3px;
  box-shadow: inset 0 0 0 2px #2a0a5e, 0 0 0 1px #100010; text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.6);
  transition: opacity 0.08s;
}
.mc-tooltip.is-on { opacity: 1; }

.bump { animation: bump 0.45s ease-out; }
@keyframes bump { 30% { transform: scale(1.18); filter: brightness(1.4); } }

/* Command */
.cmd-toolbar { display: flex; justify-content: space-between; }
.toggle { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 0.9rem; color: var(--muted); }
.toggle input { display: none; }
.toggle span { width: 38px; height: 22px; border-radius: 999px; background: rgba(255, 255, 255, 0.15); position: relative; transition: background 0.2s; }
.toggle span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.toggle input:checked + span { background: var(--cyan); }
.toggle input:checked + span::after { transform: translateX(16px); }
.cmd-players { display: flex; gap: 8px; flex-wrap: wrap; }
.cmd-player { display: inline-flex; align-items: center; gap: 8px; background: rgba(0, 0, 0, 0.3); border: 1px solid rgba(255, 255, 255, 0.08); padding: 5px 12px 5px 6px; border-radius: 999px; font-size: 0.88rem; }
.cmd-player i { color: var(--muted); font-style: normal; }
.cmd-player b { color: #fde047; font-family: var(--mono); font-size: 0.82rem; }
.head { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 4px; background: linear-gradient(135deg, #b98a64, #7b5536); font-size: 0.72rem; font-weight: 800; color: #fff; margin-right: 6px; }
.cmd-player .head { margin-right: 0; }
.cmd-input-wrap { position: relative; }
.cmd-input {
  width: 100%; background: rgba(0, 0, 0, 0.55); border: 2px solid rgba(255, 255, 255, 0.12); border-radius: 4px;
  padding: 8px 12px; color: #fff; outline: none;
}
.cmd-input:focus { border-color: rgba(255, 255, 255, 0.4); }
.cmd-input::placeholder { color: rgba(255, 255, 255, 0.4); }
.cmd-suggest, .cmd-hint {
  position: absolute; left: 12px; bottom: calc(100% + 4px); background: rgba(0, 0, 0, 0.85); padding: 4px 8px;
  display: none; min-width: 160px; border-radius: 2px; z-index: 5;
}
.cmd-suggest.is-on, .cmd-hint.is-on { display: block; }
.sg { color: #aaaaaa; cursor: pointer; }
.sg.is-first { color: #ffff55; }
.cmd-hint { color: #aaaaaa; }
.cmd-hint b { color: #ffff55; font-weight: 400; }
.cmd-quick { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; font-size: 0.86rem; color: var(--muted); }
.cmd-quick .chip { font-family: var(--mono); font-size: 0.78rem; padding: 5px 10px; }
.handled { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding-top: 4px; border-top: 1px dashed rgba(255, 255, 255, 0.1); }
.handled-label { font-size: 0.82rem; color: var(--muted); margin-right: 4px; }
.pill { font-size: 0.78rem; padding: 4px 10px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.12); color: var(--dim); transition: all 0.25s; }
.pill.ok { color: #86efac; border-color: rgba(74, 222, 128, 0.5); background: rgba(74, 222, 128, 0.1); }
.pill.fail { color: #fca5a5; border-color: rgba(248, 113, 113, 0.55); background: rgba(248, 113, 113, 0.12); }
.pill.ok::before { content: '✓ '; }
.pill.fail::before { content: '✗ '; }

/* Scoreboard */
.sb-controls, .eco-controls, .bb-controls, .chat-controls { display: flex; gap: 12px; flex-wrap: wrap; align-items: end; }
.sb-controls label, .eco-controls label, .bb-controls label, .chat-controls label { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: var(--muted); font-weight: 500; }
.demo-stage input:not([type="checkbox"]):not(.cmd-input), .demo-stage select {
  background: rgba(0, 0, 0, 0.35); border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 8px; padding: 7px 10px; font-size: 0.9rem; color: var(--text); outline: none;
}
.demo-stage input:focus, .demo-stage select:focus { border-color: rgba(34, 211, 238, 0.6); }
.demo-stage select option { background: #0c1633; }
.sb-scene { flex: 1; display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; }
.mc-sidebar { justify-self: end; min-width: 220px; background: rgba(0, 0, 0, 0.42); padding: 0 0 6px; }
.mc-sidebar-title { text-align: center; padding: 3px 10px; background: rgba(0, 0, 0, 0.25); margin-bottom: 4px; transition: color 0.2s; }
.sb-line { padding: 1px 12px; }
.sb-actions { display: flex; flex-direction: column; gap: 8px; min-width: 170px; }
.sb-actions .mini-btn { font-family: inherit; text-align: left; }
.sb-tick { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; color: var(--muted); font-family: var(--mono); margin-top: 6px; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }

/* Config */
.stage-config { gap: 12px; }
.cfg-editor { display: flex; flex-direction: column; background: #060c1f; border: 1px solid var(--line-2); border-radius: 12px; overflow: hidden; }
.cfg-tab { font-family: var(--mono); font-size: 0.72rem; color: var(--muted); padding: 8px 12px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; word-break: break-all; }
.cfg-tab b { color: var(--text); }
.cfg-state { color: var(--muted); padding: 0 8px; border-radius: 999px; }
.cfg-state.ok { color: #86efac; background: rgba(74, 222, 128, 0.12); }
.cfg-state.bad { color: #fca5a5; background: rgba(248, 113, 113, 0.14); }
#cfg-text { flex: 1; min-height: 270px; resize: vertical; border: 0; outline: none; background: transparent; padding: 12px 14px; font-family: var(--mono); font-size: 12.5px; line-height: 1.6; color: #d7e3ff; tab-size: 2; }
.cfg-right { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.console { background: #03060f; border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 10px; padding: 8px 10px; font-size: 17px; min-height: 130px; max-height: 150px; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; color: #cbd5e1; }
.console .mc-line { text-shadow: none; font-size: 17px; }
.cfg-game { display: flex; flex-direction: column; gap: 8px; }
.cfg-game-head { display: flex; justify-content: space-between; align-items: center; font-size: 0.8rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; }
.cfg-game-head .mini-btn { text-transform: none; letter-spacing: 0; font-family: inherit; }

/* Economy */
.eco-controls input[type="number"] { width: 100px; }
.eco-btns { display: flex; gap: 6px; align-items: center; }
.eco-result { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; min-height: 40px; background: rgba(0, 0, 0, 0.3); border-radius: 10px; padding: 8px 12px; font-size: 0.9rem; color: var(--muted); }
.res { font-family: var(--mono); font-size: 0.82rem; font-weight: 700; padding: 4px 10px; border-radius: 8px; }
.res-ok { color: #86efac; background: rgba(74, 222, 128, 0.12); border: 1px solid rgba(74, 222, 128, 0.4); }
.res-bad { color: #fca5a5; background: rgba(248, 113, 113, 0.12); border: 1px solid rgba(248, 113, 113, 0.45); }
.eco-scene { display: grid; grid-template-columns: 1fr 210px; gap: 16px; align-items: start; }
.eco-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; background: rgba(0, 0, 0, 0.25); border-radius: 10px; overflow: hidden; }
.eco-table th, .eco-table td { padding: 8px 12px; text-align: left; }
.eco-table th { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 600; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
.eco-table td:not(:first-child) { font-family: var(--mono); }
.eco-table td.bump { display: table-cell; color: #67e8f9; }
.eco-table tr.row-hit { background: rgba(34, 211, 238, 0.07); }
.holo-board { text-align: center; padding: 10px 6px; background: rgba(0, 0, 0, 0.25); border-radius: 6px; }
.holo-title { color: #f59e0b; font-weight: 700; margin-bottom: 4px; font-size: 22px; }
.holo-board ol { list-style: none; margin: 0; padding: 0; }
.holo-board li { display: grid; grid-template-columns: 34px 1fr auto; gap: 6px; padding: 1px 6px; text-align: left; transition: background 0.4s; }
.holo-board li.moved { animation: moved 0.9s ease-out; }
@keyframes moved { 0% { background: rgba(250, 204, 21, 0.35); transform: translateX(-6px); } }
.holo-board .nm { color: #fff; }
.holo-board .sc { color: #fcd34d; }

/* Ghosts */
.ghost-btns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ghost-btns .danger { margin-left: auto; }
.ghost-scene {
  position: relative; height: 300px; border-radius: 12px; overflow: hidden;
  background: linear-gradient(180deg, #5b8def 0%, #8fb8ff 55%, #b6d4ff 72%);
}
.sky-sun { position: absolute; top: 26px; right: 44px; width: 42px; height: 42px; background: #fff7c2; box-shadow: 0 0 40px 10px rgba(255, 247, 194, 0.6); }
.ground { position: absolute; left: 0; right: 0; bottom: 0; height: 70px; background: linear-gradient(180deg, #5dac3d 0 14px, #8b5a2b 14px 100%); }
.ground::before { content: ''; position: absolute; inset: 14px 0 0; background: repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.08) 0 22px, transparent 22px 44px); }
#ghost-canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 3; }
.steve { position: absolute; left: 30%; bottom: 70px; width: 36px; height: 108px; transform: translateX(-50%); z-index: 2; }
.s-head { width: 36px; height: 36px; background: linear-gradient(180deg, #3b2412 0 30%, #b98a64 30%); box-shadow: inset 7px 18px 0 -12px #fff, inset -7px 18px 0 -12px #fff; }
.s-body { width: 36px; height: 38px; background: #20a5b5; }
.s-legs { width: 36px; height: 34px; background: linear-gradient(90deg, #3b3fa0 0 48%, #2d3188 52%); }
.s-name { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); background: rgba(0, 0, 0, 0.35); padding: 0 6px; color: #fff; white-space: nowrap; font-size: 18px; }
.holo-text {
  position: absolute; left: 30%; bottom: 220px; transform: translate(-50%, 10px) scale(0.8); z-index: 3;
  background: rgba(0, 0, 0, 0.35); padding: 2px 10px; font-size: 24px; opacity: 0; transition: opacity 0.3s, transform 0.3s;
}
.holo-text.is-on { opacity: 1; transform: translate(-50%, 0) scale(1); }
.npc {
  position: absolute; left: 70%; bottom: 70px; width: 40px; transform: translateX(-50%) scale(0.6); z-index: 2; cursor: pointer;
  opacity: 0; pointer-events: none; transition: opacity 0.35s, transform 0.35s;
}
.npc.is-on { opacity: 1; transform: translateX(-50%) scale(1); pointer-events: auto; filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgba(255, 255, 255, 0.8)); }
.npc:hover { filter: drop-shadow(0 0 3px #ffff55) drop-shadow(0 0 10px rgba(255, 255, 85, 0.8)); }
.npc-label { position: absolute; bottom: calc(100% + 10px); left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; background: rgba(0, 0, 0, 0.35); padding: 2px 8px; white-space: nowrap; font-size: 19px; }
.npc-label .small { font-size: 16px; }
.npc-head { position: relative; width: 40px; height: 44px; background: #bd8b72; box-shadow: inset 0 8px 0 #9c6d52; }
.npc-nose { position: absolute; left: 15px; top: 22px; width: 10px; height: 16px; background: #a66f55; }
.npc-robe { width: 40px; height: 62px; background: linear-gradient(90deg, #6b4a2f 0 50%, #5e3f27 50%); }

/* Boss bar */
.bb-scene { position: relative; flex: 1; min-height: 280px; border-radius: 12px; background: linear-gradient(180deg, #0f1a33, #1a2d4f 60%, #243d2a); overflow: hidden; }
.bossbar { position: absolute; top: 22px; left: 50%; width: min(420px, 80%); transform: translate(-50%, -12px); opacity: 0; transition: opacity 0.25s, transform 0.25s; text-align: center; }
.bossbar.is-on { opacity: 1; transform: translate(-50%, 0); }
.bossbar-title { color: #fff; margin-bottom: 4px; }
.bossbar-track { height: 10px; background: #2b2b2b; box-shadow: inset 0 0 0 1px #000, 0 0 0 1px rgba(0, 0, 0, 0.6); }
.bossbar-fill { height: 100%; width: 100%; transition: width 0.45s linear, background 0.2s; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.25), inset 0 2px 0 rgba(255, 255, 255, 0.35); }
.actionbar { position: absolute; bottom: 36px; left: 50%; transform: translateX(-50%); color: #fff; opacity: 0; transition: opacity 0.3s; font-size: 22px; }
.actionbar.is-on { opacity: 1; }

/* Chat */
.chat-form { display: flex; gap: 8px; }
.chat-form .mini-btn { font-family: inherit; }
.chat-item { color: #55ffff; cursor: help; text-decoration: underline dotted rgba(85, 255, 255, 0.5); text-underline-offset: 3px; }

/* ---------- Modules ---------- */
.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.module-card {
  display: flex; flex-direction: column; gap: 6px; text-align: left; padding: 22px; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  transition: transform 0.15s, border-color 0.15s, background 0.15s;
}
.module-card:hover { transform: translateY(-3px); border-color: rgba(34, 211, 238, 0.45); background: var(--panel-2); }
.module-icon { font-size: 1.7rem; }
.module-name { font-weight: 700; font-size: 1.05rem; }
.module-desc { color: var(--muted); font-size: 0.92rem; flex: 1; }
.module-more { color: #67e8f9; font-size: 0.85rem; font-weight: 600; margin-top: 6px; }
.module-dialog { width: min(760px, 94vw); background: var(--panel); color: var(--text); border: 1px solid var(--line-2); border-radius: 20px; padding: 24px; box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.8); }
.module-dialog::backdrop { background: rgba(2, 5, 14, 0.7); backdrop-filter: blur(4px); }
.md-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 16px; }
.md-icon { font-size: 2rem; }
.md-head > div { flex: 1; }
.md-title { font-size: 1.3rem; margin-bottom: 4px; }
.md-desc { color: var(--muted); }
.md-close { border: 0; background: rgba(255, 255, 255, 0.06); width: 34px; height: 34px; border-radius: 50%; cursor: pointer; }
.md-close:hover { background: rgba(255, 255, 255, 0.14); }

/* ---------- Get started ---------- */
.steps { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.step-num { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; background: var(--grad); color: #fff; }
.step h3 { font-size: 1.2rem; }
.step p { color: var(--muted); font-size: 0.95rem; margin-bottom: 6px; }
.step .demo-code { margin-top: auto; flex: 1; display: flex; flex-direction: column; }
.step .code-panel { flex: 1; display: flex; flex-direction: column; }
.step .code-scroll { flex: 1; }
.final-cta {
  margin-top: 56px; display: flex; align-items: center; gap: 24px; padding: 32px; border-radius: 22px;
  background: linear-gradient(110deg, rgba(30, 91, 255, 0.22), rgba(34, 211, 238, 0.14));
  border: 1px solid rgba(34, 211, 238, 0.3);
}
.final-cta > div { flex: 1; }
.final-cta h3 { font-size: 1.5rem; margin-bottom: 6px; }
.final-cta p { color: var(--muted); }

.footer { border-top: 1px solid var(--line); padding: 28px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer .brand { font-size: 1rem; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .compare-tabs { grid-template-columns: repeat(3, 1fr); }
  .demo-body { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .nav-links a:not(.nav-cta) { display: none; }
  .demo-nav { top: 68px; overflow-x: auto; flex-wrap: nowrap; }
  .demo-nav a { white-space: nowrap; }
  .hero { padding: 64px 0 72px; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
  .logo-orbit { width: 220px; height: 220px; }
  .logo-orbit img { width: 170px; height: 170px; }
  .compare-summary, .compare-lists { grid-template-columns: minmax(0, 1fr); }
  .compare-code, .compare-code[data-view="read"] { grid-template-columns: minmax(0, 1fr); }
  .compare-code[data-view="side"] .code-col-trad .code-scroll { max-height: 520px; }
  .compare-code[data-view="side"] .code-col-arc { position: static; }
  .compare-body, .demo, .totals { padding: 20px; }
  .demo-head { flex-direction: column; }
  .demo-facts { flex-direction: row; flex-wrap: wrap; }
  .eco-scene { grid-template-columns: minmax(0, 1fr); }
  .demo-stage { padding: 12px; }
  .total-row { grid-template-columns: 1fr; gap: 6px; }
  .total-val { text-align: left; }
  .final-cta { flex-direction: column; text-align: center; }
}
@media (max-width: 560px) {
  .wrap, .nav-inner { width: calc(100% - 28px); }
  .compare-tabs { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: 1fr; }
  .mc-grid { grid-template-columns: repeat(9, 28px); }
  .mc-slot { width: 28px; height: 28px; }
  .mc-item { font-size: 17px; }
  .mc-pane { width: 22px; height: 22px; }
  .mc-inv { padding: 8px; }
  .ghost-btns .danger { margin-left: 0; }
  .sb-scene { grid-template-columns: 1fr; }
  .mc-sidebar { justify-self: stretch; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
  .meter-fill, .total-fill { width: var(--w); }
}
