/* ---------- Tokens ---------- */
:root {
  --orange: #FF8F43;
  --night: #14172B;
  --moon: #FFE08A;
  --mint: #7CF5C9;

  --bg: #14172B;
  --bg-2: #1C2145;
  --text: #F4F2FF;
  --muted: #A9AED0;
  --accent: #7CF5C9;
  --card: rgba(255, 255, 255, .055);
  --card-strong: rgba(255, 255, 255, .09);
  --border: rgba(255, 255, 255, .12);
  --header: rgba(20, 23, 43, .72);
  --glow: rgba(124, 245, 201, .35);
  --shadow: 0 20px 50px -20px rgba(0, 0, 0, .6);

  --radius: 22px;
  --display: 'Fredoka', 'Baloo 2', system-ui, sans-serif;
  --body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

:root[data-theme="light"] {
  --bg: #FFF4E4;
  --bg-2: #FFE6C7;
  --text: #14172B;
  --muted: #555A7B;
  --accent: #0A8763;
  --card: rgba(255, 255, 255, .62);
  --card-strong: rgba(255, 255, 255, .85);
  --border: rgba(20, 23, 43, .12);
  --header: rgba(255, 244, 228, .78);
  --glow: rgba(10, 135, 99, .28);
  --shadow: 0 20px 45px -22px rgba(120, 70, 20, .35);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.12; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 6.2vw, 4.5rem); font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: clamp(2rem, 4.2vw, 3rem); font-weight: 600; }
h3 { font-size: 1.35rem; font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }
p { margin: 0; }
a { color: inherit; }
ul, ol { list-style: none; margin: 0; padding: 0; }
.accent { color: var(--orange); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

.container { width: min(1120px, 100% - 40px); margin-inline: auto; }
.container--narrow { width: min(780px, 100% - 40px); }

/* ---------- Night sky ---------- */
.sky {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(900px 520px at 78% -8%, rgba(255, 143, 67, .16), transparent 62%),
    radial-gradient(800px 600px at 8% 18%, rgba(124, 245, 201, .08), transparent 60%),
    linear-gradient(180deg, var(--bg-2), var(--bg) 55%);
}
.stars span {
  position: absolute; border-radius: 50%; background: #fff;
  animation: twinkle 4s ease-in-out infinite;
}
:root[data-theme="light"] .stars { display: none; }
@keyframes twinkle { 0%, 100% { opacity: .15; } 50% { opacity: .9; } }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 20;
  background: var(--header);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.header__inner { display: flex; align-items: center; gap: 20px; height: 68px; }
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--display); font-weight: 600; font-size: 1.25rem; text-decoration: none;
}
.logo em { font-style: normal; color: var(--orange); font-size: .85em; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a {
  padding: 8px 14px; border-radius: 999px; text-decoration: none;
  font-size: .95rem; font-weight: 500; color: var(--muted); transition: color .2s, background .2s;
}
.nav a:hover { color: var(--text); background: var(--card-strong); }
.header__actions { display: flex; align-items: center; gap: 10px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 22px; border-radius: 999px;
  background: var(--mint); color: var(--night);
  font-family: var(--display); font-weight: 600; font-size: 1rem; text-decoration: none; white-space: nowrap;
  border: 2px solid var(--night);
  transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 0 0 4px var(--glow), 0 10px 30px -8px var(--glow); }
.btn--small { padding: 8px 16px; font-size: .92rem; }
.btn--large { padding: 16px 32px; font-size: 1.15rem; }
.x-icon { width: 1em; height: 1em; fill: currentColor; }

.theme-toggle {
  width: 40px; height: 40px; flex: none; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--border); background: var(--card); color: var(--text);
  cursor: pointer; transition: box-shadow .2s, transform .2s;
}
.theme-toggle:hover { box-shadow: 0 0 0 4px var(--glow); transform: rotate(-12deg); }
.theme-toggle svg { width: 20px; height: 20px; fill: currentColor; stroke: currentColor; }
.icon-sun { display: none; }
:root[data-theme="light"] .icon-sun { display: block; }
:root[data-theme="light"] .icon-moon { display: none; }

/* ---------- Badges ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 12px; border-radius: 999px;
  font-size: .78rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--border); background: var(--card);
}
.badge--live { color: var(--accent); border-color: currentColor; background: color-mix(in srgb, var(--accent) 12%, transparent); }
.badge--live i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; animation: pulse 1.8s ease-out infinite; }
.badge--next { color: var(--orange); border-color: currentColor; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 var(--glow); }
  100% { box-shadow: 0 0 0 10px transparent; }
}

/* ---------- Hero ---------- */
.hero { position: relative; padding: clamp(48px, 8vw, 96px) 0 clamp(56px, 8vw, 100px); }
.hero__inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero__text > * + * { margin-top: 22px; }
.lead { font-size: 1.18rem; color: var(--muted); max-width: 34em; }

.moon {
  position: absolute; top: 28px; right: 6%; width: 86px; height: 86px; border-radius: 50%;
  background: var(--moon);
  box-shadow: 0 0 60px 12px rgba(255, 224, 138, .28), inset -14px -10px 0 rgba(20, 23, 43, .1);
}

.contract {
  max-width: 520px; padding: 14px 16px; border-radius: 18px;
  background: var(--card); border: 1px solid var(--border);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.contract__label { display: block; font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.contract__row { display: flex; align-items: center; gap: 12px; }
.contract code { flex: 1; min-width: 0; font: 500 .92rem ui-monospace, 'SF Mono', Menlo, Consolas, monospace; overflow-wrap: anywhere; }
.contract code.is-pending { font-family: inherit; color: var(--muted); }
.copy[hidden] { display: none; }
.copy {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px; cursor: pointer;
  font: 600 .88rem var(--body); color: var(--accent);
  background: transparent; border: 1px solid currentColor; transition: box-shadow .2s, background .2s;
}
.copy:hover { box-shadow: 0 0 0 4px var(--glow); }
.copy.is-copied { background: color-mix(in srgb, var(--accent) 16%, transparent); }
.copy svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

.stats { display: flex; flex-wrap: wrap; gap: 10px 28px; }
.stats strong { display: block; font-family: var(--display); font-size: 1.7rem; font-weight: 600; line-height: 1.1; }
.stats span { font-size: .88rem; color: var(--muted); }

.hero__cat { position: relative; display: grid; place-items: center; }
.hero__cat::before {
  content: ""; position: absolute; width: 78%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 143, 67, .5), transparent 68%);
  filter: blur(24px); animation: breathe 5s ease-in-out infinite;
}
.cat { position: relative; width: min(100%, 440px); height: auto; overflow: visible; }
.cat__coin { transform-origin: 115px 150px; animation: breathe-coin 5s ease-in-out infinite; }
.cat__zzz text { animation: zzz 3.6s ease-in-out infinite; }
.cat__zzz text:nth-child(2) { animation-delay: .5s; }
.cat__zzz text:nth-child(3) { animation-delay: 1s; }
.cat__eye-open { display: none; }
.cat:hover .cat__eye-open { display: inline; }
.cat:hover .cat__eye-closed { display: none; }
@keyframes breathe { 0%, 100% { transform: scale(.94); opacity: .75; } 50% { transform: scale(1.06); opacity: 1; } }
@keyframes breathe-coin { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.025) translateY(-3px); } }
@keyframes zzz { 0%, 100% { transform: translateY(4px); opacity: .35; } 50% { transform: translateY(-5px); opacity: 1; } }

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 8vw, 104px) 0; }
.eyebrow { font-size: .8rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }
.section__lead { margin-top: 14px; color: var(--muted); font-size: 1.1rem; max-width: 40em; }
.sub { margin-top: 64px; font-size: 1.7rem; }

.panel, .card, .stage, .phase, .faq details {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}
.panel { padding: 28px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
.card { padding: 28px; transition: transform .25s, border-color .25s, box-shadow .25s; }
.card:hover, .stage:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow), 0 0 28px -8px var(--glow); }
.card__icon { width: 52px; height: 52px; display: grid; place-items: center; font-size: 1.6rem; border-radius: 16px; background: var(--card-strong); margin-bottom: 18px; }
.card p { margin-top: 10px; color: var(--muted); }

/* ---------- Tokenomics ---------- */
.tok { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 40px; }
.tok__side { display: grid; gap: 20px; }

.donut { position: relative; width: min(240px, 70%); margin: 22px auto; }
.donut svg { display: block; width: 100%; transform: rotate(-90deg); }
.donut circle { fill: none; stroke-width: 24; }
.donut__track { stroke: var(--card-strong); }
.donut__ring { stroke: var(--mint); stroke-dasharray: 100; stroke-dashoffset: 0; filter: drop-shadow(0 0 10px var(--glow)); }
:root[data-theme="light"] .donut__ring { stroke: #2FC99A; }
.js .reveal:not(.in) .donut__ring { stroke-dashoffset: 100; }
.reveal.in .donut__ring { transition: stroke-dashoffset 1.4s cubic-bezier(.3, .7, .2, 1) .2s; }
.donut__center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donut__center strong { font-family: var(--display); font-size: 2.3rem; font-weight: 700; line-height: 1; }
.donut__center span { font-size: .85rem; color: var(--muted); }

.alloc li { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--border); color: var(--muted); }
.alloc li:first-child { color: var(--text); }
.alloc b { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--text); }
.dot { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--muted); flex: none; }
.dot--mint { background: var(--mint); border-color: var(--mint); }

.panel--highlight { display: flex; align-items: center; gap: 24px; border-color: color-mix(in srgb, var(--orange) 55%, transparent); }
.panel--highlight p { margin-top: 6px; color: var(--muted); }
.zero { font-family: var(--display); font-weight: 700; font-size: clamp(3.4rem, 7vw, 5rem); line-height: 1; color: var(--orange); }

.checks { display: grid; gap: 16px; }
.checks li { position: relative; padding-left: 34px; color: var(--muted); }
.checks strong { color: var(--text); }
.checks li::before {
  content: "✓"; position: absolute; left: 0; top: 1px; width: 22px; height: 22px;
  display: grid; place-items: center; border-radius: 50%;
  font-size: .8rem; font-weight: 700; background: var(--mint); color: var(--night);
}


.stages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 32px; }
.stage { padding: 22px; transition: transform .25s, border-color .25s, box-shadow .25s; }
.stage__num { font-size: .75rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.stage h4 { font-size: 1.35rem; margin: 4px 0 12px; }
.stage__trigger { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: .82rem; font-weight: 600; color: var(--accent); background: color-mix(in srgb, var(--accent) 13%, transparent); }
.stage p { margin-top: 12px; color: var(--muted); font-size: .97rem; }

/* ---------- Roadmap ---------- */
.timeline { position: relative; margin-top: 40px; padding-left: 38px; display: grid; gap: 18px; }
.timeline::before { content: ""; position: absolute; left: 10px; top: 12px; bottom: 12px; width: 2px; background: linear-gradient(var(--accent), var(--border) 30%); }
.phase { position: relative; padding: 22px 24px; }
.phase::before {
  content: ""; position: absolute; left: -35px; top: 28px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--muted);
}
.phase__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.phase__num { font-size: .78rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.phase p { margin-top: 8px; color: var(--muted); }
.phase--live { border-color: var(--accent); animation: live-glow 3s ease-in-out infinite; }
.phase--live::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 5px var(--glow); }
@keyframes live-glow {
  0%, 100% { box-shadow: var(--shadow), 0 0 18px -6px var(--glow); }
  50% { box-shadow: var(--shadow), 0 0 42px -2px var(--glow); }
}

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; margin-top: 36px; }
.faq details { transition: border-color .2s; }
.faq details[open], .faq details:hover { border-color: var(--accent); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 22px; cursor: pointer; list-style: none;
  font-family: var(--display); font-weight: 600; font-size: 1.12rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font-size: 1.5rem; line-height: 1; color: var(--accent); transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 22px 20px; color: var(--muted); }

/* ---------- Final + footer ---------- */
.final__panel { text-align: center; padding: clamp(32px, 6vw, 56px); }
.final__panel p { margin: 14px auto 28px; color: var(--muted); max-width: 32em; }
.stretch { width: min(240px, 70%); height: auto; margin-bottom: 14px; color: var(--text); }

.footer { border-top: 1px solid var(--border); padding: 36px 0 48px; color: var(--muted); }
.footer__top { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; color: var(--text); }
.disclaimer { font-size: .88rem; line-height: 1.65; }
.disclaimer strong { color: var(--text); }

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease, border-color .25s, box-shadow .25s; }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .stages { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .nav { display: none; }
  .header__actions { margin-left: auto; }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__cat { order: -1; }
  .cat { width: min(72%, 320px); }
  .moon { width: 56px; height: 56px; top: 16px; right: 20px; }
  .tok { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .container, .container--narrow { width: calc(100% - 32px); }
  .hide-sm { display: none; }
  .stages { grid-template-columns: 1fr; }
  .panel--highlight { flex-direction: column; align-items: flex-start; gap: 10px; }
  .panel, .card { padding: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
