/* =========================================================
   Void Bootstrapper — website styles
   Shared by every page. Sections:
     1. tokens & base      5. home
     2. backdrop & loader  6. features / customize
     3. top bar & dock     7. download / faq
     4. buttons & cards    8. footer, responsive
   ========================================================= */

/* ---------- 1. tokens & base ---------- */
:root {
  --accent: #a855f7;
  --accent-2: #c084fc;
  --accent-3: #e9d5ff;
  --accent-dim: rgba(168,85,247,.14);
  --accent-line: rgba(168,85,247,.38);
  --bg: #0a0a0c;
  --panel: rgba(18,18,22,.72);
  --border: rgba(255,255,255,.08);
  --border-2: rgba(255,255,255,.14);
  --text: #ececf1;
  --text-dim: #a1a1ab;
  --text-faint: #62626d;
  --good: #3ecf6e;
  --radius: 18px;
  --max: 1140px;
  --ease: cubic-bezier(.2,.8,.2,1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text); min-height: 100vh;
  font-family: -apple-system, "Segoe UI", Inter, Roboto, Arial, sans-serif; font-size: 15px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; cursor: pointer; }
svg.icon { width: 18px; height: 18px; flex-shrink: 0; }
::selection { background: rgba(168,85,247,.35); }
.sprite { display: none; }
[hidden] { display: none !important; }

/* ---------- 2. backdrop & loader ---------- */
.bg-tunnel { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }
.bg-fade { position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 45% at 50% 0%, rgba(147,51,234,.16), transparent 70%),
    radial-gradient(ellipse at 50% 40%, rgba(10,10,12,0) 0%, rgba(10,10,12,.6) 55%, rgba(10,10,12,.94) 100%); }
.page { position: relative; z-index: 1; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* The loader's essential rules are also inlined in each page's <head>, so it shows
   before this file has arrived. These add the finishing touches. */
.loader.done { opacity: 0; visibility: hidden; transition: opacity .45s ease, visibility 0s linear .45s; }
.loader-label { margin-top: 18px; font-size: 11px; font-weight: 800; letter-spacing: 2px; color: var(--text-faint); }

/* ---------- 3. top bar & dock ---------- */
.topbar { position: fixed; top: 0; left: 0; right: 0; z-index: 20; padding: 16px 24px; pointer-events: none; transition: background .3s ease, backdrop-filter .3s ease, border-color .3s ease; border-bottom: 1px solid transparent; }
/* once the page is scrolled, content no longer shows through behind the top bar */
.topbar.scrolled { background: rgba(10,10,12,.72); backdrop-filter: blur(16px); border-bottom-color: var(--border); }
.topbar-inner { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; }
.topbar-inner > * { pointer-events: auto; }
.brand { display: flex; align-items: center; gap: 11px; font-weight: 800; justify-self: start; white-space: nowrap; }
.brand img { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 6px 18px -6px rgba(168,85,247,.6); }
.brand small { display: block; font-size: 9.5px; letter-spacing: 1.5px; color: var(--text-faint); font-weight: 700; margin-top: -2px; }
.top-actions { justify-self: end; display: flex; gap: 8px; align-items: center; }

.dock {
  position: relative; display: flex; gap: 2px; padding: 5px; border-radius: 999px;
  background: rgba(16,16,20,.72); border: 1px solid var(--border); backdrop-filter: blur(18px) saturate(140%);
  box-shadow: 0 12px 40px -14px rgba(0,0,0,.8), inset 0 1px 0 rgba(255,255,255,.04);
}
.dock-pill {
  position: absolute; top: 5px; bottom: 5px; left: 0; width: 0; border-radius: 999px;
  background: linear-gradient(180deg, rgba(168,85,247,.32), rgba(168,85,247,.16));
  border: 1px solid var(--accent-line); box-shadow: 0 6px 20px -6px rgba(168,85,247,.55);
  transition: left .42s var(--ease), width .42s var(--ease);
}
.dock-pill.no-anim { transition: none; }
.dock a {
  position: relative; z-index: 1; display: flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px;
  color: var(--text-dim); font-weight: 650; font-size: 13.5px; white-space: nowrap; transition: color .2s ease;
}
.dock a svg { width: 17px; height: 17px; transition: transform .25s var(--ease); }
.dock a:hover { color: var(--text); }
.dock a:hover svg { transform: translateY(-1px); }
.dock a.active { color: #fff; }
.dock a.active svg { color: var(--accent-3); }

/* ---------- 4. buttons & cards ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px; border: none;
  font-weight: 700; font-size: 14.5px; border-radius: 13px; padding: 13px 22px; white-space: nowrap;
  transition: transform .12s ease, filter .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: linear-gradient(180deg, #fff 0%, #dcdce0 100%); color: #111; }
.btn-primary:hover { filter: brightness(1.05); }
.btn-accent { background: linear-gradient(180deg, #b46cf9 0%, #8b2fe6 100%); color: #fff; box-shadow: 0 12px 34px -12px rgba(168,85,247,.85), inset 0 1px 0 rgba(255,255,255,.2); }
.btn-accent:hover { filter: brightness(1.08); box-shadow: 0 16px 40px -12px rgba(168,85,247,.95), inset 0 1px 0 rgba(255,255,255,.2); }
.btn-ghost { background: rgba(22,22,26,.6); color: var(--text); border: 1px solid var(--border-2); backdrop-filter: blur(8px); }
.btn-ghost:hover { border-color: rgba(255,255,255,.26); }
.btn-sm { padding: 9px 15px; font-size: 13px; border-radius: 11px; }
.btn-lg { padding: 16px 28px; font-size: 16px; border-radius: 15px; }
.icon-only { padding: 9px; border-radius: 11px; }

main { padding-top: 96px; animation: pageIn .55s var(--ease) both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

.eyebrow { font-size: 11.5px; font-weight: 800; letter-spacing: 1.9px; color: var(--accent-2); }
.section-head { text-align: center; max-width: 660px; margin: 0 auto 46px; }
.section-head h1, .section-head h2 { font-size: clamp(32px, 4.6vw, 52px); letter-spacing: -1.4px; line-height: 1.05; margin: 12px 0 14px; font-weight: 850; }
.section-head p { color: var(--text-dim); margin: 0; font-size: 16.5px; }
.section-head.small h2 { font-size: clamp(26px, 3.4vw, 36px); }
.grad { background: linear-gradient(120deg, #f3e8ff 0%, #c084fc 45%, #9333ea 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
section.block { padding: 40px 0 70px; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.card {
  position: relative; background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px;
  backdrop-filter: blur(12px); transition: border-color .3s ease, transform .3s var(--ease); overflow: hidden;
}
.card::after { /* glow that follows the mouse (position set by script.js) */
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .3s ease;
  background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(168,85,247,.14), transparent 60%);
}
.card:hover { border-color: var(--accent-line); transform: translateY(-3px); }
.card:hover::after { opacity: 1; }
.ficon {
  width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: var(--accent-dim); border: 1px solid var(--accent-line); color: var(--accent-3); margin-bottom: 18px;
}
.card h3 { margin: 0 0 8px; font-size: 17px; letter-spacing: -.2px; }
.card p { margin: 0; font-size: 14.2px; color: var(--text-dim); }
.card.wide { grid-column: span 2; }
.card ul { margin: 14px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 7px; }
.card li { display: flex; gap: 9px; align-items: flex-start; font-size: 13.5px; color: var(--text-dim); }
.card li svg { width: 15px; height: 15px; color: var(--good); margin-top: 3px; flex-shrink: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; }
.chip { font-size: 11.5px; font-weight: 700; padding: 5px 10px; border-radius: 999px; background: rgba(255,255,255,.05); border: 1px solid var(--border); color: var(--text-dim); }

.cta {
  text-align: center; padding: 60px 24px; border-radius: 26px; border: 1px solid var(--accent-line); position: relative; overflow: hidden;
  background: radial-gradient(ellipse at 50% 0%, rgba(168,85,247,.26), rgba(15,15,18,.88) 70%); backdrop-filter: blur(10px);
}
.cta h2 { font-size: clamp(30px, 4.4vw, 46px); margin: 0 0 10px; letter-spacing: -1.2px; font-weight: 850; }
.cta p { color: var(--text-dim); margin: 0 0 28px; }

/* ---------- 5. home ---------- */
.hero { padding: 54px 0 34px; text-align: center; }
.pill {
  display: inline-flex; align-items: center; gap: 9px; padding: 7px 15px 7px 9px; border-radius: 999px; font-size: 12.5px; font-weight: 700;
  background: rgba(168,85,247,.1); border: 1px solid var(--accent-line); color: #dcc4fb;
}
.pill .tag { background: var(--accent); color: #fff; border-radius: 999px; padding: 2px 9px; font-size: 10.5px; letter-spacing: .6px; }
.hero h1 { font-size: clamp(44px, 8vw, 92px); line-height: .98; letter-spacing: -3px; margin: 24px 0 20px; font-weight: 880; }
.hero p.lead { font-size: clamp(16px, 2vw, 19.5px); color: var(--text-dim); max-width: 660px; margin: 0 auto 34px; }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-meta { margin-top: 18px; font-size: 12.5px; color: var(--text-faint); display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }
.hero-meta span { display: inline-flex; align-items: center; gap: 6px; }
.hero-meta svg { width: 14px; height: 14px; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; max-width: 860px; margin: 54px auto 0;
  background: var(--border); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; backdrop-filter: blur(10px); }
.stat { background: rgba(14,14,17,.82); padding: 20px 16px; text-align: center; }
.stat b { display: block; font-size: 26px; font-weight: 850; letter-spacing: -.5px; }
.stat span { font-size: 11px; font-weight: 700; letter-spacing: 1.2px; color: var(--text-faint); text-transform: uppercase; }

.mock-wrap { padding: 70px 0 30px; perspective: 1600px; }
.mock {
  max-width: 1000px; margin: 0 auto; border-radius: 20px; border: 1px solid var(--border-2); overflow: hidden;
  background: rgba(11,11,14,.9); backdrop-filter: blur(6px); transform: rotateX(8deg); transform-origin: top center;
  box-shadow: 0 70px 140px -50px rgba(168,85,247,.55), 0 40px 80px -40px rgba(0,0,0,.9);
  display: grid; grid-template-columns: 214px 1fr; min-height: 480px; text-align: left; transition: transform .9s var(--ease);
}
.mock-wrap.in .mock { transform: rotateX(0deg); }
.mock-side { background: #0c0c0e; border-right: 1px solid rgba(255,255,255,.05); padding: 18px 12px; display: flex; flex-direction: column; gap: 2px; }
.mock-brand { display: flex; align-items: center; gap: 9px; padding: 2px 6px 16px; font-weight: 800; font-size: 13px; }
.mock-brand img { width: 30px; height: 30px; border-radius: 8px; }
.mock-brand small { display: block; font-size: 8.5px; letter-spacing: 1.2px; color: var(--text-faint); font-weight: 700; }
.mock-item { display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 8px; font-size: 12.5px; color: var(--text-dim); font-weight: 500; }
.mock-item svg { width: 15px; height: 15px; color: var(--text-faint); }
.mock-item.active { background: #1a1a1f; color: #fff; }
.mock-item.active svg { color: var(--accent); }
.mock-main { padding: 26px 30px; position: relative; }
.mock-eyebrow { font-size: 10px; font-weight: 800; letter-spacing: 1.5px; color: var(--text-faint); }
.mock-title { font-size: 30px; font-weight: 850; letter-spacing: -.6px; margin: 6px 0 4px; }
.mock-title span { color: var(--accent); }
.mock-sub { font-size: 13px; color: var(--text-dim); margin-bottom: 18px; }
.mock-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin-bottom: 16px; }
.mock-stat { background: rgba(22,22,26,.8); border: 1px solid rgba(255,255,255,.07); border-radius: 12px; padding: 12px; }
.mock-stat svg { width: 15px; height: 15px; color: var(--accent); margin-bottom: 6px; }
.mock-stat b { display: block; font-size: 17px; }
.mock-stat b.mono { font-family: Consolas, monospace; font-size: 13px; padding: 2px 0; }
.mock-stat small { font-size: 8.5px; font-weight: 800; letter-spacing: 1px; color: var(--text-faint); }
.mock-game { display: flex; align-items: center; gap: 12px; background: rgba(17,17,20,.9); border: 1px solid rgba(255,255,255,.07); border-radius: 11px; padding: 10px 12px; margin-bottom: 14px; }
.mock-game .gi { width: 38px; height: 38px; border-radius: 9px; background: linear-gradient(135deg, #f59e0b, #ef4444); flex-shrink: 0; }
.mock-game b { font-size: 13px; display: block; }
.mock-game small { font-size: 11px; color: var(--text-faint); }
.mock-game .play { margin-left: auto; font-size: 11px; font-weight: 700; padding: 7px 11px; border-radius: 8px; background: linear-gradient(180deg, #4be08a, #22a35c); color: #07240f; }
.mock-launch { display: flex; align-items: center; gap: 14px; background: rgba(22,22,26,.8); border: 1px solid rgba(255,255,255,.07); border-radius: 14px; padding: 16px 18px; }
.mock-launch .li { width: 42px; height: 42px; border-radius: 11px; background: #1b1b20; border: 1px solid rgba(255,255,255,.07); display: flex; align-items: center; justify-content: center; }
.mock-launch .li svg { width: 20px; height: 20px; transform: rotate(-12deg); }
.mock-launch b { font-size: 14.5px; display: block; }
.mock-launch small { font-family: Consolas, monospace; font-size: 11.5px; color: var(--text-dim); }
.mock-launch .chev { margin-left: auto; color: var(--text-faint); }
.mock-toast { position: absolute; right: 22px; bottom: 22px; display: flex; align-items: center; gap: 9px; background: rgba(23,23,28,.96); border: 1px solid rgba(255,255,255,.08); border-radius: 11px; padding: 10px 15px; font-size: 12.5px; font-weight: 600; animation: toastLoop 4s var(--ease) infinite; }
.mock-toast::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--good); }
@keyframes toastLoop { 0%, 12% { opacity: 0; transform: translateY(8px); } 20%, 85% { opacity: 1; transform: none; } 100% { opacity: 0; } }

/* ---------- 6. features / customize ---------- */
.swap-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.swap { text-align: center; padding: 28px 18px 22px; }
.swap .demo {
  height: 110px; border-radius: 14px; margin-bottom: 18px; display: flex; align-items: center; justify-content: center;
  background-color: #1c1c22;
  background-image: linear-gradient(45deg, #24242b 25%, transparent 25%), linear-gradient(-45deg, #24242b 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #24242b 75%), linear-gradient(-45deg, transparent 75%, #24242b 75%);
  background-size: 20px 20px; background-position: 0 0, 0 10px, 10px -10px, -10px 0; border: 1px solid var(--border);
}
.swap .demo img { width: 64px; height: 64px; object-fit: contain; }
.swap .demo .cursor-demo { width: 46px; height: 46px; color: #c084fc; }
.swap .demo .font-demo { font-size: 34px; font-weight: 800; letter-spacing: -.5px; font-family: Georgia, "Times New Roman", serif; }
.swap .demo .wave { display: flex; align-items: center; gap: 4px; height: 50px; }
.swap .demo .wave i { width: 5px; border-radius: 3px; background: linear-gradient(180deg, #c084fc, #7e22ce); animation: wave 1.1s ease-in-out infinite; }
.swap .demo .wave i:nth-child(2) { animation-delay: .12s; } .swap .demo .wave i:nth-child(3) { animation-delay: .24s; }
.swap .demo .wave i:nth-child(4) { animation-delay: .36s; } .swap .demo .wave i:nth-child(5) { animation-delay: .48s; }
.swap .demo .wave i:nth-child(6) { animation-delay: .6s; } .swap .demo .wave i:nth-child(7) { animation-delay: .72s; }
@keyframes wave { 0%, 100% { height: 12px; } 50% { height: 46px; } }
.presets { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.preset { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 18px; }
.preset b { font-size: 14.5px; }
.preset small { display: block; color: var(--text-faint); font-size: 12.5px; }
.preset .val { font-size: 12px; font-weight: 700; padding: 6px 11px; border-radius: 9px; background: rgba(255,255,255,.05); border: 1px solid var(--border); color: var(--text-dim); white-space: nowrap; }

/* ---------- 7. download / faq ---------- */
.dl-layout { display: grid; grid-template-columns: 1.15fr .85fr; gap: 16px; align-items: start; }
.dl-main { padding: 34px; }
.dl-head { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.dl-head img { width: 64px; height: 64px; border-radius: 16px; box-shadow: 0 12px 30px -10px rgba(168,85,247,.7); }
.dl-head h2 { margin: 0; font-size: 26px; letter-spacing: -.6px; }
.dl-head .ver { font-size: 13px; color: var(--text-dim); margin-top: 2px; }
.dl-head .ver b { color: var(--accent-3); }
.dl-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 24px; }
.fact { background: rgba(255,255,255,.03); border: 1px solid var(--border); border-radius: 13px; padding: 12px 14px; }
.fact span { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: 1.1px; color: var(--text-faint); }
.fact b { font-size: 15px; }
.dl-btn { width: 100%; }
.dl-note { font-size: 12.5px; color: var(--text-faint); margin-top: 14px; text-align: center; }
.panel-title { font-size: 12px; letter-spacing: 1.5px; color: var(--text-faint); margin: 0 0 14px; font-weight: 800; }
.notes ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.notes li { display: flex; gap: 10px; font-size: 14px; color: var(--text-dim); }
.notes li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); margin-top: 8px; flex-shrink: 0; box-shadow: 0 0 0 3px rgba(168,85,247,.18); }
.steps-mini ol { margin: 0; padding: 0; list-style: none; counter-reset: s; display: flex; flex-direction: column; gap: 14px; }
.steps-mini li { counter-increment: s; display: flex; gap: 12px; font-size: 14px; color: var(--text-dim); }
.steps-mini li::before { content: counter(s); width: 26px; height: 26px; flex-shrink: 0; border-radius: 50%; background: #fff; color: #111; font-weight: 800; font-size: 12.5px; display: flex; align-items: center; justify-content: center; }
.steps-mini li b { color: var(--text); display: block; }
.side-stack { display: flex; flex-direction: column; gap: 16px; }

.faq { max-width: 800px; margin: 0 auto; display: flex; flex-direction: column; gap: 10px; }
.faq details { background: var(--panel); border: 1px solid var(--border); border-radius: 16px; padding: 4px 22px; backdrop-filter: blur(12px); transition: border-color .25s ease; }
.faq details[open] { border-color: var(--accent-line); }
.faq summary { cursor: pointer; list-style: none; padding: 17px 0; font-weight: 700; font-size: 15.5px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--text-faint); font-size: 22px; line-height: 1; transition: transform .25s var(--ease), color .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); color: var(--accent-2); }
.faq details p { margin: 0 0 18px; color: var(--text-dim); font-size: 14.5px; }
.faq-more { text-align: center; margin-top: 30px; color: var(--text-dim); }
.faq-more a { color: var(--accent-2); font-weight: 700; }

/* mod developer guide (mods.html) */
.docs-hero { padding-bottom: 30px; }
.docs-layout { display: grid; grid-template-columns: 220px 1fr; gap: 40px; align-items: start; }
.docs-toc { position: sticky; top: 100px; display: flex; flex-direction: column; gap: 2px; padding: 16px; border-radius: 16px; background: var(--panel); border: 1px solid var(--border); backdrop-filter: blur(12px); }
.toc-title { font-size: 10.5px; font-weight: 800; letter-spacing: 1.5px; color: var(--text-faint); margin: 0 0 8px 8px; }
.docs-toc a { font-size: 13px; color: var(--text-dim); padding: 6px 8px; border-radius: 8px; transition: background .15s ease, color .15s ease; }
.docs-toc a:hover { color: var(--text); background: rgba(255,255,255,.04); }
.docs-toc a.active { color: #fff; background: var(--accent-dim); box-shadow: inset 2px 0 0 var(--accent); }
.docs { min-width: 0; max-width: 820px; }
.docs h2 { font-size: 28px; letter-spacing: -.6px; margin: 56px 0 14px; scroll-margin-top: 100px; }
.docs h2:first-child { margin-top: 0; }
.docs h3 { font-size: 17px; margin: 28px 0 8px; }
.docs p { color: var(--text-dim); font-size: 15px; margin: 0 0 14px; }
.docs p b, .docs li b { color: var(--text); }
.docs a { color: var(--accent-2); }
.docs code { font-family: "SF Mono", Consolas, monospace; font-size: .88em; background: rgba(168,85,247,.12); border: 1px solid rgba(168,85,247,.22); color: #e4d2fd; padding: 1px 6px; border-radius: 6px; }
.docs-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 20px 0 6px; }
.docs-cards .card { padding: 20px; }
.docs-cards .card h3 { margin: 0 0 6px; }
.docs-cards .card p { font-size: 13.5px; margin: 0; }
pre.code {
  position: relative; margin: 10px 0 18px; padding: 18px 20px; border-radius: 14px; overflow-x: auto;
  background: rgba(10,10,14,.92); border: 1px solid var(--border); font-family: "SF Mono", Consolas, monospace;
  font-size: 13px; line-height: 1.65; color: #d9d6e3; tab-size: 2;
}
pre.code .copy {
  position: absolute; top: 10px; right: 10px; font-family: inherit; font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 8px;
  background: rgba(255,255,255,.06); border: 1px solid var(--border); color: var(--text-dim); opacity: 0; transition: opacity .15s ease;
}
pre.code:hover .copy { opacity: 1; }
pre.code .copy:hover { color: #fff; border-color: var(--accent-line); }
.tok-kw { color: #c084fc; font-weight: 600; }
.tok-str { color: #86efac; }
.tok-num { color: #fbbf24; }
.tok-com { color: #6b6b78; font-style: italic; }
.tok-api { color: #7dd3fc; }
.tok-fn { color: #f9a8d4; }
.step { display: flex; gap: 16px; margin: 18px 0; }
.step-n { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; background: #fff; color: #111; font-weight: 800; display: flex; align-items: center; justify-content: center; margin-top: 2px; }
.step > div { min-width: 0; flex: 1; }
.step h3 { margin: 4px 0 6px; }
.callout { padding: 12px 16px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid var(--border); color: var(--text-dim); font-size: 14px; margin: 14px 0; }
.callout.tip { background: var(--accent-dim); border-color: var(--accent-line); color: #e4d2fd; }
.table-wrap { overflow-x: auto; margin: 10px 0 18px; border: 1px solid var(--border); border-radius: 14px; background: var(--panel); backdrop-filter: blur(12px); }
.docs table { width: 100%; border-collapse: collapse; font-size: 14px; }
.docs th { text-align: left; font-size: 11px; letter-spacing: 1.2px; color: var(--text-faint); font-weight: 800; padding: 12px 16px; border-bottom: 1px solid var(--border); text-transform: uppercase; }
.docs td { padding: 11px 16px; border-bottom: 1px solid rgba(255,255,255,.05); color: var(--text-dim); vertical-align: top; }
.docs tr:last-child td { border-bottom: none; }
.docs td:first-child { white-space: nowrap; }
.pos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; max-width: 460px; padding: 10px; border-radius: 14px; border: 1px dashed var(--accent-line); margin: 10px 0 16px; }
.pos-grid span { text-align: center; font-family: "SF Mono", Consolas, monospace; font-size: 12px; padding: 10px 4px; border-radius: 9px; background: rgba(168,85,247,.1); color: #e4d2fd; }
.pos-grid span:nth-child(-n+3) { margin-bottom: 40px; }
@media (max-width: 1000px) {
  .docs-layout { grid-template-columns: 1fr; }
  .docs-toc { display: none; }
}
@media (max-width: 700px) {
  .docs-cards { grid-template-columns: 1fr; }
  .docs td:first-child { white-space: normal; }
}

/* "coming soon" popup (built by script.js) */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; padding: 24px;
  background: rgba(6,6,8,.66); backdrop-filter: blur(8px); opacity: 0; visibility: hidden;
  transition: opacity .25s ease, visibility 0s linear .25s;
}
.modal-backdrop.open { opacity: 1; visibility: visible; transition: opacity .25s ease; }
.modal {
  width: 380px; max-width: 100%; text-align: center; padding: 34px 30px 28px; border-radius: 22px;
  background: linear-gradient(180deg, rgba(24,24,29,.97), rgba(14,14,17,.97)); border: 1px solid var(--accent-line);
  box-shadow: 0 40px 100px -30px rgba(168,85,247,.5), 0 30px 60px -30px rgba(0,0,0,.85);
  transform: translateY(14px) scale(.97); transition: transform .35s var(--ease);
}
.modal-backdrop.open .modal { transform: none; }
.modal-icon {
  width: 60px; height: 60px; margin: 0 auto 16px; border-radius: 18px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(150deg, #c084fc, #7e22ce); color: #fff; box-shadow: 0 12px 30px -10px rgba(168,85,247,.8);
}
.modal-icon svg { width: 30px; height: 30px; }
.modal-tag { display: inline-block; font-size: 10.5px; font-weight: 800; letter-spacing: 1.6px; color: var(--accent-3); background: var(--accent-dim); border: 1px solid var(--accent-line); padding: 4px 11px; border-radius: 999px; }
.modal h3 { font-size: 21px; margin: 14px 0 8px; letter-spacing: -.3px; }
.modal p { color: var(--text-dim); margin: 0 0 22px; font-size: 14.5px; }
.modal .btn { width: 100%; }
.mock-game img.gi { object-fit: cover; background: #1b1b20; }

/* 404 */
.notfound { min-height: 70vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.notfound h1 { font-size: clamp(90px, 16vw, 160px); margin: 0; letter-spacing: -6px; line-height: 1; }
.notfound p { color: var(--text-dim); margin: 6px 0 28px; font-size: 17px; }

/* ---------- accounts: login / register / profile ---------- */
.account-btn.current { border-color: var(--accent-line); color: #fff; }
.account-btn span { max-width: 140px; overflow: hidden; text-overflow: ellipsis; }

.auth-block { min-height: calc(100vh - 260px); display: flex; align-items: center; }
.auth-block .wrap { width: 100%; }
.auth-card { max-width: 430px; margin: 0 auto; padding: 34px 32px 28px; display: flex; flex-direction: column; gap: 16px; }
.auth-head { text-align: center; margin-bottom: 4px; }
.auth-head img { width: 54px; height: 54px; border-radius: 15px; margin: 0 auto 14px; box-shadow: 0 10px 30px -8px rgba(168,85,247,.7); }
.auth-head h1 { font-size: 27px; letter-spacing: -.6px; margin: 0 0 4px; font-weight: 850; }
.auth-head p { margin: 0; color: var(--text-dim); font-size: 14.5px; }
.auth-submit { width: 100%; margin-top: 4px; }
.auth-alt { text-align: center; font-size: 13.5px; color: var(--text-dim); }
.auth-alt a { color: var(--accent-2); font-weight: 700; }
.auth-alt a:hover { text-decoration: underline; }

.pcard-danger { border-color: rgba(239,68,68,.25); }
.pcard-icon.danger { background: rgba(239,68,68,.15); color: #ef4444; }
.btn-danger { background: #dc2626; color: #fff; border: none; }
.btn-danger:hover { background: #b91c1c; color: #fff; }
.delete-confirm { display: flex; flex-direction: column; gap: 12px; }
.delete-confirm p { font-size: 14px; color: var(--text-dim); line-height: 1.5; }
.delete-confirm .field { margin: 0; }
.delete-confirm .btn-row { display: flex; gap: 8px; }
.auth-divider { display: flex; align-items: center; gap: 12px; color: var(--text-dim); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.08); }
.discord-reg { display: flex; flex-direction: column; gap: 10px; align-items: center; }
.discord-reg-status { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--text-dim); }
.discord-reg-icon { display: flex; color: #5865f2; }
.btn-discord { background: #5865f2; color: #fff; border: none; display: inline-flex; align-items: center; gap: 8px; width: 100%; justify-content: center; }
.btn-discord:hover { background: #4752c4; color: #fff; }
.btn-discord svg { flex-shrink: 0; }

.field { display: flex; flex-direction: column; gap: 7px; }
.field > span { font-size: 12px; font-weight: 750; letter-spacing: .4px; color: var(--text-dim); }
.field small { font-size: 12px; color: var(--text-faint); }
.field input {
  width: 100%; font: inherit; font-size: 14.5px; color: var(--text); background: rgba(8,8,10,.7);
  border: 1px solid var(--border-2); border-radius: 12px; padding: 12px 14px; outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field input::placeholder { color: var(--text-faint); }
.field input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(168,85,247,.16); }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 46px; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); background: none; border: none; padding: 8px; color: var(--text-faint); border-radius: 8px; display: flex; }
.pw-toggle:hover { color: var(--text); }
.pw-meter { height: 4px; border-radius: 4px; background: rgba(255,255,255,.07); overflow: hidden; }
.pw-meter i { display: block; height: 100%; width: 0; border-radius: 4px; transition: width .3s var(--ease), background .3s ease; }
.pw-meter[data-score="0"] i, .pw-meter[data-score="1"] i { width: 25%; background: #ef4444; }
.pw-meter[data-score="2"] i { width: 50%; background: #f59e0b; }
.pw-meter[data-score="3"] i { width: 75%; background: #a3e635; }
.pw-meter[data-score="4"] i { width: 100%; background: var(--good); }
.captcha { display: flex; justify-content: center; min-height: 78px; }
.form-error { font-size: 13.5px; color: #fca5a5; background: rgba(239,68,68,.1); border: 1px solid rgba(239,68,68,.32); border-radius: 11px; padding: 10px 13px; }
.form-error[hidden] { display: none; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.loading { position: relative; color: transparent !important; }
.btn.loading svg { visibility: hidden; }
.btn.loading::after { content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; animation: loader-spin .7s linear infinite; }
.btn-ghost.loading::after { border-color: rgba(255,255,255,.2); border-top-color: var(--text); }
.btn-discord { background: linear-gradient(180deg, #b46cf9 0%, #8b2fe6 100%); color: #fff; box-shadow: 0 12px 34px -12px rgba(168,85,247,.85); }
.btn-discord:hover { filter: brightness(1.08); }

.profile { display: flex; flex-direction: column; gap: 14px; }
.profile-head { display: flex; align-items: center; gap: 20px; padding: 26px 28px; }
.avatar { width: 66px; height: 66px; border-radius: 20px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 28px; font-weight: 850; color: #fff; background: linear-gradient(150deg, #c084fc, #7e22ce); box-shadow: 0 12px 30px -10px rgba(168,85,247,.8); }
.profile-head .who { flex: 1; min-width: 0; }
.profile-head h1 { margin: 2px 0 2px; font-size: 28px; letter-spacing: -.6px; font-weight: 850; overflow: hidden; text-overflow: ellipsis; }
.profile-head .meta { color: var(--text-dim); font-size: 13.5px; overflow-wrap: anywhere; }
.profile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.pcard { padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.pcard form { display: flex; flex-direction: column; gap: 12px; }
.pcard .btn { align-self: flex-start; }
.pcard-head { display: flex; align-items: center; gap: 13px; }
.pcard-head h3 { margin: 0; font-size: 16.5px; }
.pcard-head p { margin: 0; color: var(--text-dim); font-size: 13px; }
.pcard-head > div:nth-child(2) { flex: 1; min-width: 0; }
.pcard-icon { width: 42px; height: 42px; border-radius: 13px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: var(--accent-dim); border: 1px solid var(--accent-line); color: var(--accent-3); }

.pcard-text { margin: 0; color: var(--text-dim); font-size: 14px; }
.pcard-note { color: var(--text-faint); font-size: 12.5px; }
.status { font-size: 11px; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--border-2); color: var(--text-dim); white-space: nowrap; }
.status.good { color: #86efac; border-color: rgba(62,207,110,.4); background: rgba(62,207,110,.1); }
.status.warn { color: #fcd34d; border-color: rgba(245,158,11,.4); background: rgba(245,158,11,.1); }
.kv { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.kv:last-child { border-bottom: none; }
.kv span { color: var(--text-dim); }
.mono { font-family: "SF Mono", Consolas, monospace; font-size: 13px; letter-spacing: .5px; }
.discord-user { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 12px; background: var(--accent-dim); border: 1px solid var(--accent-line); }
.discord-user[hidden], [data-license-active][hidden] { display: none; }
.discord-user img { width: 34px; height: 34px; border-radius: 50%; }

.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 70; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  padding: 12px 20px; border-radius: 13px; font-size: 14px; font-weight: 650; color: var(--text);
  background: rgba(22,22,27,.96); border: 1px solid var(--accent-line); box-shadow: 0 20px 50px -18px rgba(0,0,0,.9);
  transition: opacity .25s ease, transform .3s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1240px) and (min-width: 1001px) {
  .account-btn { padding: 9px; }
  .account-btn span { display: none; } /* the dock still has its labels here — keep the bar on one line */
}
@media (max-width: 860px) {
  .profile-grid { grid-template-columns: 1fr; }
  .profile-grid > * { grid-column: auto !important; grid-row: auto !important; }
}
@media (max-width: 700px) {
  .auth-card { padding: 28px 20px 22px; }
  .profile-head { flex-wrap: wrap; padding: 22px 20px; }
  .profile-head .btn { width: 100%; }
}

/* ---------- 8. footer & responsive ---------- */
footer { border-top: 1px solid var(--border); padding: 34px 0 44px; margin-top: 60px; background: rgba(10,10,12,.72); backdrop-filter: blur(10px); }
footer .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13px; color: var(--text-faint); }
footer .made b { color: var(--accent-2); }
footer nav { display: flex; gap: 20px; }
footer nav a:hover { color: var(--text); }

@media (max-width: 1000px) {
  .grid, .swap-grid { grid-template-columns: 1fr 1fr; }
  .dl-layout { grid-template-columns: 1fr; }
  .mock { grid-template-columns: 1fr; }
  .mock-side { display: none; }
  .dock a span { display: none; }
  .dock a { padding: 10px 13px; }
}
@media (max-width: 700px) {
  .topbar-inner { grid-template-columns: auto 1fr auto; gap: 8px; }
  .brand span { display: none; }
  .dock { justify-self: center; }
  /* on phones only the account button stays, as an icon */
  .top-actions > :not(.account-btn) { display: none; }
  .account-btn { padding: 9px; }
  .account-btn span { display: none; }
  .grid, .presets, .swap-grid { grid-template-columns: 1fr; }
  .card.wide { grid-column: auto; }
  .stats, .mock-stats, .dl-facts { grid-template-columns: 1fr 1fr; }
  .mock-toast { display: none; }
  .hero { padding-top: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
