:root {
  --orange: #ff942b;
  --yellow: #ffd36a;
  --midnight: #1b1029;
  --plum: #302044;
  --plum2: #241634;
  --lavender: #9c83b7;
  --cyan: #8fe9e8;
  --green: #8ad15c;
  --ivory: #f2e9d8;
  --red: #e44e54;
  --bg: #0e0817;
  --card: rgba(36, 22, 52, 0.85);
  --line: rgba(156, 131, 183, 0.25);
  --radius: 20px;
  --gut: clamp(16px, 4vw, 48px);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  background: radial-gradient(1200px 600px at 80% -10%, rgba(255, 148, 43, 0.12), transparent), var(--bg);
  color: var(--ivory);
  font: 16px/1.55 "Nunito Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--yellow); }
h1, h2, h3, .btn, .tab, .brand { font-family: Fredoka, "Arial Rounded MT Bold", "Nunito Sans", sans-serif; }
h2 { font-size: clamp(28px, 4.2vw, 46px); margin: 0 0 0.4em; color: var(--orange); line-height: 1.1; }
h3 { margin: 0.2em 0 0.3em; }
.drip { font-family: Creepster, Fredoka, "Arial Rounded MT Bold", sans-serif; font-weight: 400; letter-spacing: 0.02em; }
.o { color: var(--orange); }
.muted { color: var(--lavender); }
.tiny { font-size: 13px; color: var(--lavender); }
.err { color: #ff8a8f; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; z-index: 99; background: var(--yellow); color: #000; padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px var(--gut); padding-top: max(10px, env(safe-area-inset-top));
  background: rgba(14, 8, 23, 0.82); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ivory); font-size: 22px; font-weight: 700; letter-spacing: 0.5px; white-space: nowrap; }
.brand b { color: var(--orange); }
nav { display: flex; align-items: center; gap: 4px; }
nav a { color: var(--ivory); text-decoration: none; padding: 8px 12px; border-radius: 10px; font-weight: 700; }
nav a:hover { background: var(--plum); }
nav a.cta { background: var(--orange); color: #2a1206; margin-left: 6px; }
.menu-btn { display: none; background: none; border: 0; width: 44px; height: 44px; padding: 10px; cursor: pointer; }
.menu-btn span { display: block; height: 3px; background: var(--ivory); border-radius: 3px; margin: 5px 0; }
@media (max-width: 900px) {
  .menu-btn { display: block; }
  nav { position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; background: #140b22; padding: 8px var(--gut) 16px; border-bottom: 1px solid var(--line); display: none; }
  nav.open { display: flex; }
  nav a { padding: 12px; }
  nav a.cta { margin: 6px 0 0; text-align: center; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 22px; border-radius: 16px;
  background: var(--plum); color: var(--ivory); border: 2px solid rgba(255, 148, 43, 0.55); text-decoration: none; font-size: 18px; font-weight: 600; cursor: pointer;
  transition: transform 0.1s, box-shadow 0.15s;
}
.btn:hover { box-shadow: 0 0 0 4px rgba(255, 148, 43, 0.2); }
.btn:active { transform: scale(0.97); }
.btn.primary { background: linear-gradient(180deg, #ffb057, #ff8a1f); color: #2a1206; border-color: var(--yellow); box-shadow: 0 5px 0 #9a4a0e, 0 0 30px rgba(255, 148, 43, 0.4); }
.btn.small { min-height: 36px; padding: 6px 14px; font-size: 15px; }
.btn.disabled { opacity: 0.5; cursor: default; border-style: dashed; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ---------- hero ---------- */
.hero { position: relative; min-height: min(92vh, 860px); display: grid; align-items: center; overflow: hidden; padding: 60px var(--gut) 40px; }
.hero-bg { position: absolute; inset: 0; z-index: -1; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 60%; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(14, 8, 23, 0.92) 0%, rgba(14, 8, 23, 0.55) 45%, rgba(14, 8, 23, 0) 75%), linear-gradient(0deg, var(--bg) 0%, transparent 25%); }
.hero-inner { max-width: 640px; }
.kicker { text-transform: uppercase; letter-spacing: 0.22em; color: var(--yellow); font-weight: 800; font-size: 13px; margin: 0 0 8px; }
.hero h1 { font-size: clamp(56px, 10vw, 128px); line-height: 0.95; margin: 0 0 18px; text-shadow: 0 5px 0 #2a0f05, 0 0 40px rgba(255, 148, 43, 0.35); }
.hero h1 span { display: inline-block; }
.lead { font-size: clamp(17px, 1.6vw, 21px); max-width: 560px; }
.ctas { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0 12px; }
.note { color: var(--lavender); font-size: 14px; }
.countdown-card { position: absolute; right: var(--gut); bottom: 40px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; backdrop-filter: blur(6px); text-align: center; }
.countdown-card p { margin: 0 0 6px; color: var(--yellow); font-weight: 800; text-transform: uppercase; letter-spacing: 0.12em; font-size: 12px; }
.countdown { display: flex; gap: 10px; font-family: Fredoka, sans-serif; justify-content: center; }
.countdown span { display: flex; flex-direction: column; align-items: center; min-width: 54px; }
.countdown b { font-size: 34px; line-height: 1; color: var(--ivory); }
.countdown small { color: var(--lavender); font-size: 11px; text-transform: uppercase; }
.countdown.done { font-size: 20px; color: var(--orange); }
@media (max-width: 760px) {
  .hero { min-height: auto; padding-top: 40px; }
  .hero-bg img { object-position: 70% 50%; opacity: 0.6; }
  .countdown-card { position: static; margin-top: 18px; }
}

/* ---------- sections ---------- */
section { padding: clamp(40px, 7vw, 80px) var(--gut); max-width: 1240px; margin: 0 auto; }
.hero, .features { max-width: none; }
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); padding: 0; border-block: 1px solid var(--line); }
.features div { background: #130b1f; padding: 18px var(--gut); display: flex; flex-direction: column; }
.features b { font-family: Fredoka, sans-serif; font-size: 20px; }
.features span { color: var(--lavender); font-size: 14px; }
@media (max-width: 700px) { .features { grid-template-columns: 1fr 1fr; } }
.sub { color: var(--lavender); margin-top: 0; }

/* ---------- embed ---------- */
.embed-wrap { border-radius: 24px; padding: 6px; background: linear-gradient(135deg, rgba(255, 148, 43, 0.7), rgba(156, 131, 183, 0.5)); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55); }
.embed { position: relative; aspect-ratio: 16 / 9; width: 100%; border-radius: 19px; overflow: hidden; background: #0b0612; }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.facade { all: unset; position: absolute; inset: 0; cursor: pointer; display: grid; place-items: center; }
.facade img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(0.55); }
.play-circle { position: relative; width: clamp(70px, 12vw, 110px); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: var(--orange); color: #2a1206; font-size: clamp(30px, 5vw, 48px); box-shadow: 0 0 0 10px rgba(255, 148, 43, 0.25), 0 10px 40px rgba(0, 0, 0, 0.6); }
.facade-text { position: absolute; bottom: 12%; font: 700 clamp(16px, 2.4vw, 24px) Fredoka, sans-serif; text-shadow: 0 2px 0 #000; }
.facade:focus-visible .play-circle { outline: 4px solid var(--yellow); }
.placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 20px; gap: 6px; border: 3px dashed rgba(255, 211, 106, 0.6); border-radius: 19px; background: repeating-linear-gradient(45deg, #150c22 0 18px, #1a0f2a 18px 36px); }
.placeholder.small { position: static; border-radius: 16px; padding: 22px; }
.placeholder img { width: clamp(56px, 10vw, 110px); height: auto; }
.ph-badge { display: inline-block; background: var(--yellow); color: #2a1206; font-weight: 800; letter-spacing: 0.15em; font-size: 12px; padding: 4px 10px; border-radius: 999px; }
.ph-title { font: 700 clamp(18px, 2.5vw, 26px) Fredoka, sans-serif; margin: 4px 0 0; }
.ph-msg { color: var(--lavender); max-width: 640px; margin: 0 0 8px; font-size: clamp(13px, 1.6vw, 16px); }

/* ---------- worlds ---------- */
.world-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.world { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.world img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; height: auto; }
.world div { padding: 12px 16px 16px; position: relative; }
.world p { margin: 0; color: var(--lavender); font-size: 14px; }
.num { position: absolute; top: -22px; right: 14px; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--orange); color: #2a1206; font: 700 20px Fredoka, sans-serif; }
.panic { margin-top: 26px; display: grid; grid-template-columns: 1.1fr 1fr; gap: 0; border-radius: 26px; overflow: hidden; border: 2px solid rgba(255, 59, 107, 0.6); background: #1a0a18; box-shadow: 0 0 60px rgba(255, 59, 107, 0.2); }
.panic img { width: 100%; height: 100%; object-fit: cover; }
.panic-text { padding: clamp(18px, 3vw, 34px); }
.panic h2 { font-size: clamp(30px, 4vw, 50px); color: var(--ivory); }
.panic .o { color: #ff3b6b; }
.phases { padding-left: 1.2em; }
.phases li { margin: 6px 0; }
@media (max-width: 860px) { .panic { grid-template-columns: 1fr; } }

/* ---------- leaderboard ---------- */
.board { }
.board-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.tabs { display: flex; gap: 6px; background: var(--plum2); padding: 5px; border-radius: 16px; }
.tab { border: 0; background: transparent; color: var(--ivory); padding: 10px 16px; border-radius: 12px; font-size: 16px; cursor: pointer; min-height: 44px; }
.tab.on { background: var(--orange); color: #2a1206; }
#lb-body { margin-top: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; min-height: 120px; }
ol.lb { list-style: none; margin: 0; padding: 0; }
ol.lb li { display: grid; grid-template-columns: 3.4em 1fr auto auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 12px; }
ol.lb li:nth-child(odd) { background: rgba(48, 32, 68, 0.6); }
ol.lb li:nth-child(1) .rk { color: var(--yellow); }
.rk { font-weight: 800; color: var(--orange); }
.nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.ds { color: var(--lavender); font-size: 14px; }
.sc { font: 700 18px Fredoka, sans-serif; }
@media (max-width: 480px) { ol.lb li { grid-template-columns: 2.6em 1fr auto; } .ds { display: none; } }

/* ---------- skins promo ---------- */
.skins-promo { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; }
@media (max-width: 760px) { .skins-promo { grid-template-columns: 1fr; } }

/* ---------- token ---------- */
.token-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.card.warn { border-color: rgba(255, 211, 106, 0.4); }
.card ul { padding-left: 1.1em; margin: 0; }
.card li { margin: 6px 0; font-size: 15px; }
.ca { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ca code { background: #0b0612; padding: 10px 12px; border-radius: 10px; word-break: break-all; font-size: 14px; }
.chain { font-weight: 800; color: var(--cyan); }
.donut { width: 150px; aspect-ratio: 1; border-radius: 50%; margin: 6px auto 12px; -webkit-mask: radial-gradient(circle, transparent 48%, #000 49%); mask: radial-gradient(circle, transparent 48%, #000 49%); }
.legend { list-style: none; padding: 0; }
.legend li { display: flex; align-items: center; gap: 8px; }
.legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* ---------- roadmap ---------- */
.rm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.rm { background: var(--card); border: 1px solid var(--line); border-radius: 22px 22px 8px 8px; padding: 18px; position: relative; }
.rm.done { border-color: rgba(138, 209, 92, 0.5); }
.rm.now { border-color: var(--orange); box-shadow: 0 0 30px rgba(255, 148, 43, 0.18); }
.rm-badge { font-size: 12px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--lavender); }
.rm.done .rm-badge { color: var(--green); }
.rm.now .rm-badge { color: var(--orange); }
.rm ul { padding-left: 1.1em; margin: 6px 0 0; color: #ddd2e8; }

/* ---------- community / footer ---------- */
.community { text-align: center; }
.community .row { justify-content: center; }
footer { border-top: 1px solid var(--line); padding: 24px var(--gut) max(24px, env(safe-area-inset-bottom)); text-align: center; color: var(--lavender); font-size: 14px; }
footer p { margin: 4px 0; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .btn { transition: none; } }
