:root {
  --bg: #07070b;
  --bg-2: #0e0e15;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-2: rgba(255, 255, 255, 0.07);
  --line: rgba(255, 255, 255, 0.1);
  --text: #f3f1ff;
  --muted: #9a97b3;
  --alive: #39ff88;
  --dead: #ff3b5c;
  --super: #a66bff;
  --gold: #ffd34d;
  --cyan: #00e5ff;
  --accent: var(--super);
  --accent-rgb: 166, 107, 255;
  --radius: 22px;
  --display: 'Unbounded', system-ui, sans-serif;
  --body: 'Space Grotesk', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: dark;
}
body[data-state='alive'] { --accent: var(--alive); --accent-rgb: 57, 255, 136; }
body[data-state='dead'] { --accent: var(--dead); --accent-rgb: 255, 59, 92; }

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  overflow-x: hidden;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
img, svg, canvas { display: block; max-width: 100%; }
::selection { background: var(--accent); color: #000; }

/* ---------- background ---------- */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.bg-grid {
  position: absolute; inset: -50%;
  background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 50% 45% at 50% 40%, #000 20%, transparent 70%);
  transform: perspective(900px) rotateX(55deg) translateY(-8%);
  animation: grid 18s linear infinite;
}
@keyframes grid { to { background-position: 0 64px, 0 0; } }
.blob { position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%; filter: blur(110px); opacity: .28; transition: background 1.2s var(--ease); }
.b1 { background: var(--accent); top: -25vmax; left: -15vmax; animation: drift 22s ease-in-out infinite alternate; }
.b2 { background: var(--cyan); bottom: -30vmax; right: -20vmax; opacity: .14; animation: drift 26s ease-in-out infinite alternate-reverse; }
@keyframes drift { to { transform: translate(12vmax, 8vmax) scale(1.15); } }
.noise {
  position: absolute; inset: 0; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
#confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 100; }

/* ---------- marquee ---------- */
.marquee { overflow: hidden; border-bottom: 1px solid var(--line); background: rgba(0,0,0,.35); font-family: var(--mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.marquee-track { display: inline-flex; animation: marquee 40s linear infinite; }
.marquee-track span { padding: 8px 0; }
.marquee b { color: var(--accent); font-weight: 700; transition: color .6s; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px clamp(16px, 4vw, 48px);
  background: rgba(7, 7, 11, .62); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 18px; }
.brand-cat { width: 34px; height: 34px; display: inline-block; }
.nav-links { display: flex; gap: 6px; }
.nav-links a { padding: 8px 14px; border-radius: 99px; color: var(--muted); font-weight: 500; font-size: 15px; transition: color .2s, background .2s; }
.nav-links a:hover { color: var(--text); background: var(--panel-2); }
.nav-cta { display: flex; align-items: center; gap: 10px; }
.icon-btn { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: 16px; transition: background .2s, border-color .2s; }
.icon-btn:hover { background: var(--panel-2); border-color: rgba(var(--accent-rgb), .5); }

/* ---------- buttons ---------- */
.btn {
  --bx: 0px; --by: 0px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 15px 26px; border-radius: 99px; font-weight: 700; font-size: 16px; letter-spacing: .01em;
  transform: translate(var(--bx), var(--by));
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background .3s, color .3s, border-color .3s;
  white-space: nowrap; user-select: none;
}
.btn-primary { background: var(--accent); color: #07070b; box-shadow: 0 0 0 0 rgba(var(--accent-rgb), .5), 0 10px 40px -10px rgba(var(--accent-rgb), .8); }
.btn-primary:hover { box-shadow: 0 0 0 6px rgba(var(--accent-rgb), .18), 0 14px 50px -8px rgba(var(--accent-rgb), .95); }
.btn-ghost { border: 1px solid var(--line); background: var(--panel); }
.btn-ghost:hover { border-color: rgba(var(--accent-rgb), .6); background: var(--panel-2); }
.btn-sm { padding: 10px 18px; font-size: 14px; }
.btn-lg { padding: 20px 40px; font-size: 20px; }
.btn:active { transform: translate(var(--bx), var(--by)) scale(.96); }
.btn[aria-disabled='true'] { opacity: .45; pointer-events: none; }

/* ---------- hero ---------- */
main { position: relative; }
.hero {
  display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: clamp(24px, 4vw, 64px);
  max-width: 1280px; margin: 0 auto; padding: clamp(28px, 4vw, 56px) clamp(16px, 4vw, 48px) clamp(24px, 4vw, 48px);
  min-height: min(calc(100vh - 110px), 920px);
}
.hero > * { min-width: 0; }
.state-badge {
  display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px 8px 12px; border-radius: 99px;
  border: 1px solid rgba(var(--accent-rgb), .4); background: rgba(var(--accent-rgb), .08);
  font-family: var(--mono); font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted);
  transition: border-color .6s, background .6s;
}
.state-badge b { color: var(--accent); transition: color .6s; }
#stateDelta { color: var(--text); }
.pulse-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(var(--accent-rgb), .7); animation: pulse 1.8s infinite; flex: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(var(--accent-rgb), 0); } 100% { box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0); } }

.hero-title { font-family: var(--display); font-weight: 900; font-size: clamp(56px, 8vw, 132px); line-height: .88; letter-spacing: -.045em; text-transform: uppercase; margin: 22px 0 18px; }
.hero-title .line { display: block; }
.hero-title em { font-style: normal; color: var(--accent); text-shadow: 0 0 60px rgba(var(--accent-rgb), .45); transition: color .6s, text-shadow .6s; }
.glitch { position: relative; display: inline-block; }
.glitch::before, .glitch::after { content: attr(data-text); position: absolute; inset: 0; pointer-events: none; opacity: 0; }
.glitch::before { color: var(--cyan); transform: translate(-4px, 2px); clip-path: inset(10% 0 55% 0); }
.glitch::after { color: #ff2bd6; transform: translate(4px, -2px); clip-path: inset(60% 0 8% 0); }
body[data-state='super'] .glitch::before, body[data-state='super'] .glitch::after, .glitch:hover::before, .glitch:hover::after { animation: glitch 2.6s infinite steps(1); }
@keyframes glitch {
  0%, 82%, 100% { opacity: 0; }
  84% { opacity: .9; clip-path: inset(12% 0 60% 0); }
  88% { opacity: .9; clip-path: inset(55% 0 12% 0); transform: translate(5px, -1px); }
  92% { opacity: .9; clip-path: inset(30% 0 40% 0); transform: translate(-5px, 2px); }
  96% { opacity: 0; }
}
.hero-sub { font-size: clamp(18px, 1.6vw, 22px); color: var(--muted); max-width: 520px; }
.hero-sub b { color: var(--text); }

.ca {
  display: flex; align-items: center; gap: 12px; margin: 30px 0 22px; padding: 8px 8px 8px 18px; max-width: 560px;
  border: 1px solid var(--line); border-radius: 18px; background: rgba(0,0,0,.4); backdrop-filter: blur(8px);
  transition: border-color .3s, box-shadow .3s;
}
.ca:hover { border-color: rgba(var(--accent-rgb), .5); box-shadow: 0 0 40px -10px rgba(var(--accent-rgb), .5); }
.ca-label { font-family: var(--mono); font-weight: 700; font-size: 12px; color: #07070b; background: var(--accent); padding: 4px 8px; border-radius: 6px; transition: background .6s; }
.ca-value { flex: 1; min-width: 0; font-family: var(--mono); font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.ca-copy { padding: 11px 18px; border-radius: 12px; background: var(--panel-2); font-weight: 700; font-size: 14px; transition: background .2s, color .2s; }
.ca-copy:hover { background: var(--accent); color: #07070b; }
.ca-copy:disabled { opacity: .4; cursor: not-allowed; background: var(--panel-2); color: var(--text); }
.ca.copied { animation: copied .6s var(--ease); }
@keyframes copied { 40% { transform: scale(1.03); box-shadow: 0 0 0 6px rgba(var(--accent-rgb), .25); } }

.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.socials { display: flex; gap: 8px; margin-left: 6px; }
.socials a { width: 50px; height: 50px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: 19px; transition: transform .3s var(--ease), border-color .3s, background .3s; }
.socials a:hover { transform: translateY(-3px) rotate(-8deg); border-color: var(--accent); background: rgba(var(--accent-rgb), .1); }

.hero-art { position: relative; aspect-ratio: 1; display: grid; place-items: center; }
.cat-stage { position: relative; width: 86%; z-index: 2; filter: drop-shadow(0 40px 60px rgba(0,0,0,.6)); animation: float 6s ease-in-out infinite; cursor: pointer; }
@keyframes float { 50% { transform: translateY(-14px); } }
.orbits { position: absolute; inset: 2%; z-index: 1; }
.orbits i { position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid rgba(var(--accent-rgb), .35); transition: border-color .6s; }
.orbits i::after { content: ''; position: absolute; top: 50%; left: -6px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 20px 4px rgba(var(--accent-rgb), .8); transition: background .6s; }
.orbits i:nth-child(1) { transform: rotateX(72deg) rotateZ(0); animation: orbit1 9s linear infinite; }
.orbits i:nth-child(2) { transform: rotateY(72deg); animation: orbit2 12s linear infinite; border-color: rgba(0, 229, 255, .3); }
.orbits i:nth-child(2)::after { background: var(--cyan); box-shadow: 0 0 20px 4px rgba(0,229,255,.8); }
.orbits i:nth-child(3) { inset: 12%; transform: rotateX(60deg) rotateY(-40deg); animation: orbit3 7s linear infinite; }
@keyframes orbit1 { to { transform: rotateX(72deg) rotateZ(360deg); } }
@keyframes orbit2 { to { transform: rotateY(72deg) rotateX(360deg); } }
@keyframes orbit3 { to { transform: rotateX(60deg) rotateY(-40deg) rotateZ(-360deg); } }
.speech {
  position: absolute; top: 6%; right: 2%; z-index: 3; padding: 10px 16px; border-radius: 18px 18px 18px 4px;
  background: var(--text); color: #07070b; font-weight: 700; font-size: 15px; box-shadow: 0 10px 30px rgba(0,0,0,.4);
  transform-origin: bottom left; animation: pop .5s var(--ease) both;
}
.speech.bump { animation: pop .5s var(--ease); }
@keyframes pop { from { transform: scale(.4) rotate(-8deg); opacity: 0; } }

/* ---------- cat art + states ---------- */
.cat { width: 100%; height: auto; overflow: visible; }
.cat .head { transform-origin: 200px 240px; animation: bob 3.2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-5px) rotate(-1.5deg); } }
.cat .eye { transform-box: fill-box; transform-origin: center; animation: blink 5s infinite; }
@keyframes blink { 0%, 94%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.08); } }
.cat .pupil { transition: transform .12s linear; }
.cat .ear-l { transform-origin: 160px 140px; animation: twitch 7s infinite; }
@keyframes twitch { 0%, 90%, 100% { transform: rotate(0); } 93% { transform: rotate(-9deg); } 96% { transform: rotate(3deg); } }
.cat .tail { transform-origin: 318px 320px; animation: wag 2.4s ease-in-out infinite; }
@keyframes wag { 50% { transform: rotate(-14deg); } }
.cat .iris { fill: var(--accent); transition: fill .6s; }
.cat .eyes-dead, .cat .mouth-dead, .cat .halo { display: none; }
.cat .halo { animation: halo 2.2s ease-in-out infinite; }
@keyframes halo { 50% { transform: translateY(-6px); } }

.state-dead .cat .eyes-alive, .state-dead .cat .mouth-alive { display: none; }
.state-dead .cat .eyes-dead, .state-dead .cat .mouth-dead, .state-dead .cat .halo { display: inline; }
.state-dead .cat .head { animation: bob-dead 4s ease-in-out infinite; }
@keyframes bob-dead { 50% { transform: translateY(3px) rotate(3deg); } }
.state-dead .cat .tail { animation: none; transform: rotate(18deg); }
.state-dead .cat .fur { fill: #d9d4e8; }

.state-super .cat .eyes-dead, .state-super .cat .halo { display: inline; animation: q-flicker 1.6s steps(1) infinite; }
.state-super .cat .eyes-alive { animation: q-flicker 1.6s steps(1) infinite reverse; }
@keyframes q-flicker { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
.state-super .cat { animation: chroma 3s infinite steps(1); }
@keyframes chroma {
  0%, 86%, 100% { filter: none; transform: none; }
  88% { filter: drop-shadow(5px 0 0 rgba(255,43,214,.8)) drop-shadow(-5px 0 0 rgba(0,229,255,.8)); transform: translateX(3px) skewX(-2deg); }
  92% { filter: drop-shadow(-6px 0 0 rgba(255,43,214,.8)) drop-shadow(6px 0 0 rgba(0,229,255,.8)); transform: translateX(-3px); }
}
.state-gold .cat .fur { fill: var(--gold); }
.state-gold .cat .iris { fill: #ff8a00; }
.stamp-text, .stamp-stroke { transition: fill .6s, stroke .6s; }
.state-alive .stamp-text { fill: #0a8f4a; } .state-alive .stamp-stroke { stroke: #0a8f4a; }
.state-super .stamp-text { fill: #7a3cff; } .state-super .stamp-stroke { stroke: #7a3cff; }

.cat-stage.react-buy .cat { animation: hop .55s var(--ease); }
@keyframes hop { 40% { transform: translateY(-26px) scale(1.04, .96); } 70% { transform: translateY(0) scale(.97, 1.03); } }
.cat-stage.react-sell .cat { animation: shiver .45s linear; }
@keyframes shiver { 20%, 60% { transform: translateX(-6px) rotate(-1deg); } 40%, 80% { transform: translateX(6px) rotate(1deg); } }

/* ---------- stats ---------- */
.stats-wrap { max-width: 1280px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 48px); scroll-margin-top: 90px; }
.stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.stat { padding: 20px; border-radius: 18px; border: 1px solid var(--line); background: var(--panel); backdrop-filter: blur(10px); position: relative; overflow: hidden; }
.stat::before { content: ''; position: absolute; inset: 0; background: radial-gradient(120px 60px at 0 0, rgba(var(--accent-rgb), .14), transparent); opacity: 0; transition: opacity .4s; }
.stat:hover::before { opacity: 1; }
.stat-k { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.stat-v { font-family: var(--display); font-weight: 800; font-size: clamp(18px, 1.7vw, 24px); letter-spacing: -.02em; white-space: nowrap; }
.stat-v.up { color: var(--alive); } .stat-v.down { color: var(--dead); }
.stat-v.flash { animation: flash .8s var(--ease); }
@keyframes flash { 30% { color: var(--accent); text-shadow: 0 0 24px rgba(var(--accent-rgb), .9); } }
.stat-v sub { font-size: .62em; vertical-align: -0.15em; }

.bonding { margin-top: 12px; padding: 20px 22px; border-radius: 18px; border: 1px solid var(--line); background: var(--panel); }
.bonding-top { display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: space-between; font-family: var(--mono); font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
#bondingLabel { color: var(--text); }
.bonding-bar { position: relative; height: 16px; border-radius: 99px; background: rgba(255,255,255,.06); overflow: hidden; }
.bonding-fill {
  position: absolute; inset: 0 auto 0 0; width: 0%; border-radius: 99px;
  background: linear-gradient(90deg, var(--cyan), var(--accent)); box-shadow: 0 0 30px rgba(var(--accent-rgb), .7);
  transition: width 1.2s var(--ease);
}
.bonding-fill::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(115deg, rgba(255,255,255,.22) 0 10px, transparent 10px 22px); animation: stripes 1s linear infinite; }
@keyframes stripes { to { background-position: 26px 0; } }

/* ---------- sections ---------- */
.section { max-width: 1280px; margin: 0 auto; padding: clamp(72px, 10vw, 140px) clamp(16px, 4vw, 48px) 0; scroll-margin-top: 40px; }
.section-head { text-align: center; max-width: 760px; margin: 0 auto 48px; }
.section-head.left { text-align: left; margin: 0 0 28px; }
.kicker { font-family: var(--mono); font-size: 13px; color: var(--accent); letter-spacing: .1em; transition: color .6s; }
.section-head h2, .cta h2 { font-family: var(--display); font-weight: 900; font-size: clamp(36px, 5.4vw, 72px); line-height: .98; letter-spacing: -.04em; margin: 14px 0 16px; text-transform: uppercase; }
.section-head p { color: var(--muted); font-size: 18px; }
.gold { color: var(--gold); } .quantum { color: var(--super); }

.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); backdrop-filter: blur(12px); overflow: hidden; }
.panel-head { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line); font-weight: 700; }
.feed-status { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; }

.live-grid { display: grid; grid-template-columns: 380px 1fr; gap: 16px; }
.feed { list-style: none; height: 480px; overflow: hidden; padding: 8px; mask-image: linear-gradient(#000 75%, transparent); }
.feed li { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 12px; font-size: 14px; animation: slide-in .45s var(--ease); }
.feed li + li { margin-top: 4px; }
.feed li.buy { background: rgba(57,255,136,.06); }
.feed li.sell { background: rgba(255,59,92,.06); }
.feed li.whale { background: linear-gradient(90deg, rgba(255,211,77,.18), rgba(255,211,77,.04)); box-shadow: inset 0 0 0 1px rgba(255,211,77,.35); }
.feed .tag { font-family: var(--mono); font-weight: 700; font-size: 11px; padding: 4px 8px; border-radius: 6px; }
.feed .buy .tag { background: var(--alive); color: #04210f; }
.feed .sell .tag { background: var(--dead); color: #2a0008; }
.feed .who { font-family: var(--mono); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed .amt { font-family: var(--mono); font-weight: 700; }
.feed .feed-empty { display: block; color: var(--muted); text-align: center; padding: 60px 20px; animation: none; }
@keyframes slide-in { from { opacity: 0; transform: translateY(-14px) scale(.98); } }

.chart-panel { position: relative; min-height: 528px; }
.chart-panel iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.chart-placeholder { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: var(--muted); padding: 24px; }
.chart-placeholder b { color: var(--text); }
.chart-ghost { position: absolute; inset: 15% 8%; opacity: .35;
  background: linear-gradient(to top right, transparent 49.4%, rgba(var(--accent-rgb), .9) 49.6%, rgba(var(--accent-rgb), .9) 50.4%, transparent 50.6%),
              linear-gradient(to bottom right, transparent 49.4%, rgba(0,229,255,.7) 49.6%, rgba(0,229,255,.7) 50.4%, transparent 50.6%);
  filter: blur(.5px); animation: q-flicker 1.2s steps(1) infinite; mask-image: radial-gradient(#000, transparent 70%); }
.chart-placeholder p { position: relative; font-size: 18px; }

/* ---------- lore ---------- */
.lore { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.lore-card { padding: 30px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); transition: transform .5s var(--ease), border-color .4s; }
.lore-card:hover { transform: translateY(-6px) rotate(-.6deg); border-color: rgba(var(--accent-rgb), .5); }
.lore-n { font-family: var(--mono); color: var(--accent); font-size: 14px; transition: color .6s; }
.lore-card h3 { font-family: var(--display); font-size: 24px; margin: 12px 0 10px; letter-spacing: -.02em; }
.lore-card p { color: var(--muted); }

/* ---------- game ---------- */
.game { display: grid; grid-template-columns: 1.1fr .9fr; gap: 16px; }
.game-stage { position: relative; border-radius: var(--radius); border: 1px solid var(--line); background: radial-gradient(circle at 50% 60%, rgba(var(--accent-rgb), .14), transparent 60%), var(--panel); min-height: 520px; display: grid; place-items: center; overflow: hidden; }
.game-box { width: min(340px, 70%); aspect-ratio: 1; transition: transform .3s var(--ease); filter: drop-shadow(0 30px 40px rgba(0,0,0,.5)); }
.game-box:hover { transform: scale(1.04) rotate(-2deg); }
.game-box:focus-visible { outline: 3px solid var(--accent); outline-offset: 8px; border-radius: 24px; }
.game-box.shaking { animation: box-shake .55s cubic-bezier(.36,.07,.19,.97); }
@keyframes box-shake { 10%, 90% { transform: translateX(-3px) rotate(-2deg); } 20%, 80% { transform: translateX(6px) rotate(3deg); } 30%, 50%, 70% { transform: translateX(-10px) rotate(-5deg); } 40%, 60% { transform: translateX(10px) rotate(5deg); } }
.game-box.hidden { display: none; }
.game-result { position: absolute; inset: 0; display: none; place-items: center; text-align: center; }
.game-result.show { display: grid; animation: reveal-pop .55s var(--ease); }
@keyframes reveal-pop { from { transform: scale(.6) translateY(40px); opacity: 0; } }
.game-result .cat { width: min(320px, 66%); margin: 0 auto; }
.game-result h3 { font-family: var(--display); font-size: clamp(30px, 4vw, 46px); font-weight: 900; letter-spacing: -.03em; margin-top: 6px; }
.game-result p { color: var(--muted); }
.game-result .again { margin-top: 14px; font-size: 14px; color: var(--muted); font-family: var(--mono); }
.res-alive h3 { color: var(--alive); } .res-dead h3 { color: var(--dead); } .res-gold h3 { color: var(--gold); text-shadow: 0 0 40px rgba(255,211,77,.7); } .res-super h3 { color: var(--super); }
.game-hint { position: absolute; bottom: 16px; font-family: var(--mono); font-size: 12px; color: var(--muted); }
kbd { font-family: var(--mono); padding: 2px 6px; border: 1px solid var(--line); border-radius: 5px; background: var(--panel-2); }
.game-side { display: flex; flex-direction: column; gap: 16px; }
.game-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.game-stats div { padding: 18px 16px; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); }
.game-stats span { display: block; font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -.03em; }
.game-stats small { font-family: var(--mono); font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.global-counter { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-radius: 16px; border: 1px solid rgba(var(--accent-rgb), .35); background: rgba(var(--accent-rgb), .07); color: var(--muted); }
.global-counter b { color: var(--text); font-family: var(--display); }
.game-log { flex: 1; min-height: 120px; max-height: 220px; overflow: hidden; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 6px; padding: 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); }
.game-log i { width: 22px; height: 22px; border-radius: 6px; animation: reveal-pop .3s var(--ease); }
.game-log .l-alive { background: var(--alive); } .game-log .l-dead { background: var(--dead); opacity: .7; }
.game-log .l-gold { background: var(--gold); box-shadow: 0 0 12px var(--gold); } .game-log .l-super { background: var(--super); box-shadow: 0 0 12px var(--super); }

/* ---------- meme ---------- */
.meme { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.meme-canvas-wrap { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--bg-2); }
#memeCanvas { width: 100%; height: auto; cursor: grab; touch-action: none; }
#memeCanvas.dragging { cursor: grabbing; }
.meme-drop { position: absolute; inset: 0; display: none; place-items: center; background: rgba(var(--accent-rgb), .2); border: 3px dashed var(--accent); border-radius: var(--radius); font-family: var(--display); font-size: 26px; }
.meme-canvas-wrap.drag-over .meme-drop { display: grid; }
.meme-controls { display: flex; flex-direction: column; gap: 18px; padding: 28px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); }
.field { display: flex; flex-direction: column; gap: 8px; }
.field > span { font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.field input[type='text'] { padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: rgba(0,0,0,.35); color: var(--text); font: 600 16px var(--body); outline: none; transition: border-color .2s, box-shadow .2s; }
.field input[type='text']:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .15); }
.field input[type='range'] { accent-color: var(--accent); }
.seg { display: flex; padding: 4px; border-radius: 14px; border: 1px solid var(--line); background: rgba(0,0,0,.35); }
.seg button { flex: 1; padding: 10px; border-radius: 10px; font-weight: 700; color: var(--muted); transition: background .25s, color .25s; }
.seg button.on { background: var(--accent); color: #07070b; }
.upload input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.upload-btn { padding: 14px 16px; border-radius: 12px; border: 1px dashed rgba(255,255,255,.25); text-align: center; font-weight: 700; cursor: pointer; transition: border-color .2s, background .2s; }
.upload:hover .upload-btn, .upload input:focus-visible + .upload-btn { border-color: var(--accent); background: rgba(var(--accent-rgb), .07); }
.meme-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- buy ---------- */
.buy-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 64px); }
.steps { list-style: none; counter-reset: s; display: flex; flex-direction: column; gap: 10px; }
.steps li { counter-increment: s; position: relative; padding: 18px 18px 18px 72px; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); }
.steps li::before { content: counter(s, decimal-leading-zero); position: absolute; left: 18px; top: 50%; transform: translateY(-50%); font-family: var(--display); font-weight: 900; font-size: 24px; color: var(--accent); transition: color .6s; }
.steps b { display: block; }
.steps span { color: var(--muted); font-size: 15px; }
.buy-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.chip { padding: 10px 16px; border-radius: 99px; border: 1px solid var(--line); font-weight: 700; font-size: 14px; transition: border-color .2s, background .2s, transform .3s var(--ease); }
.chip:hover { border-color: var(--accent); background: rgba(var(--accent-rgb), .1); transform: translateY(-2px); }
.tokenomics { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tk { padding: 24px; border-radius: 18px; border: 1px solid var(--line); background: var(--panel); }
.tk span { display: block; font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.tk b { display: block; font-family: var(--display); font-size: clamp(18px, 1.8vw, 24px); margin-top: 8px; letter-spacing: -.02em; }

/* ---------- roadmap ---------- */
.roadmap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.ket { padding: 28px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); position: relative; overflow: hidden; transition: transform .5s var(--ease), border-color .4s; }
.ket:hover { transform: translateY(-6px); border-color: rgba(var(--accent-rgb), .5); }
.ket-sym { font-family: var(--display); font-weight: 900; font-size: 54px; color: var(--accent); letter-spacing: -.04em; transition: color .6s; }
.ket h3 { font-family: var(--display); font-size: 20px; margin: 8px 0; }
.ket p { color: var(--muted); font-size: 15px; }

/* ---------- cta / footer ---------- */
.cta { max-width: 1280px; margin: clamp(80px, 10vw, 140px) auto 0; padding: clamp(48px, 8vw, 96px) 24px; text-align: center; border-radius: 36px; border: 1px solid rgba(var(--accent-rgb), .3); background: radial-gradient(circle at 50% 120%, rgba(var(--accent-rgb), .35), transparent 60%), var(--panel); width: calc(100% - 2 * clamp(16px, 4vw, 48px)); }
.cta h2 { margin-bottom: 28px; }
.footer { max-width: 1280px; margin: 0 auto; padding: 56px clamp(16px, 4vw, 48px) 40px; display: flex; gap: 32px; align-items: flex-start; justify-content: space-between; color: var(--muted); font-size: 14px; }
.footer p { max-width: 640px; }

/* ---------- toasts ---------- */
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 90; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; pointer-events: none; }
.toast { padding: 14px 18px; border-radius: 14px; background: rgba(20,20,30,.92); border: 1px solid var(--line); backdrop-filter: blur(12px); font-weight: 600; box-shadow: 0 20px 40px rgba(0,0,0,.4); animation: toast-in .4s var(--ease); max-width: min(360px, calc(100vw - 32px)); }
.toast.whale { border-color: var(--gold); background: linear-gradient(135deg, rgba(255,211,77,.25), rgba(20,20,30,.95)); font-size: 17px; }
.toast.out { animation: toast-out .35s var(--ease) forwards; }
@keyframes toast-in { from { transform: translateX(40px) scale(.95); opacity: 0; } }
@keyframes toast-out { to { transform: translateX(40px); opacity: 0; } }
body.shake main { animation: screen-shake .5s linear; }
@keyframes screen-shake { 20%, 60% { transform: translate(-5px, 3px); } 40%, 80% { transform: translate(5px, -3px); } }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .stats { grid-template-columns: repeat(3, 1fr); }
  .roadmap { grid-template-columns: repeat(2, 1fr); }
  .live-grid { grid-template-columns: 1fr; }
  .feed { height: 360px; }
}
@media (max-width: 860px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .hero { grid-template-columns: 1fr; min-height: 0; text-align: left; padding-top: 32px; }
  .hero-art { order: -1; width: min(420px, 92%); margin: 0 auto; }
  .hero-title { margin-top: 18px; }
  .lore, .game, .meme, .buy-grid { grid-template-columns: 1fr; }
  .game-stage { min-height: 420px; }
  .chart-panel { min-height: 420px; }
  .footer { flex-direction: column; }
}
@media (max-width: 520px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .roadmap, .tokenomics { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1; }
  .socials { margin-left: 0; width: 100%; }
  .ca { padding-left: 12px; }
  .ca-value { font-size: 12px; }
  .speech { font-size: 13px; right: 0; top: 0; }
  .state-badge { flex-wrap: wrap; row-gap: 2px; font-size: 12px; }
  .nav { padding: 12px 16px; }
  .brand { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* per-instance cat colors (game results, mini cats) */
.state-alive .cat .iris { fill: var(--alive); }
.state-dead .cat .iris { fill: var(--dead); }
.state-super .cat .iris { fill: var(--super); }
.state-gold .cat .iris { fill: #ff8a00; }
.state-dead .stamp-text { fill: #c3002f; } .state-dead .stamp-stroke { stroke: #c3002f; }
.state-gold .stamp-text { fill: #b07800; } .state-gold .stamp-stroke { stroke: #b07800; }

/* ---------- wallet ---------- */
.wallet-btn { gap: 8px; }
.wallet-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); transition: background .3s, box-shadow .3s; }
.wallet-btn.connected .wallet-dot { background: var(--alive); box-shadow: 0 0 10px var(--alive); }
.wallet-btn.connected.ineligible .wallet-dot { background: var(--gold); box-shadow: 0 0 10px var(--gold); }
#walletLabel { font-family: var(--mono); font-size: 13px; }

.modal { margin: auto; border: 0; padding: 0; background: transparent; color: var(--text); max-width: min(440px, calc(100vw - 32px)); width: 100%; }
.modal::backdrop { background: rgba(4, 4, 8, .7); backdrop-filter: blur(6px); }
.modal[open] .modal-card { animation: reveal-pop .4s var(--ease); }
.modal-card { padding: 24px; border-radius: 24px; border: 1px solid var(--line); background: #11111a; box-shadow: 0 30px 80px rgba(0,0,0,.6); }
.modal-head { display: flex; align-items: center; justify-content: space-between; }
.modal-head h3 { font-family: var(--display); font-size: 22px; }
.modal-sub { color: var(--muted); font-size: 15px; margin: 8px 0 18px; }
.wallet-list { display: flex; flex-direction: column; gap: 8px; }
.wallet-opt { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--panel); font-weight: 700; text-align: left; transition: border-color .2s, background .2s, transform .3s var(--ease); }
.wallet-opt:hover { border-color: var(--accent); background: rgba(var(--accent-rgb), .08); transform: translateX(3px); }
.wallet-opt img { width: 32px; height: 32px; border-radius: 9px; }
.wallet-opt .wi { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--panel-2); font-size: 18px; }
.wallet-opt small { margin-left: auto; font-family: var(--mono); font-size: 11px; color: var(--muted); font-weight: 500; }

/* ---------- gate ---------- */
.mode-chip { position: absolute; top: 16px; left: 16px; z-index: 3; padding: 6px 12px; border-radius: 99px; font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; border: 1px solid var(--line); background: rgba(0,0,0,.4); color: var(--muted); }
.mode-chip.holders { color: var(--gold); border-color: rgba(255,211,77,.45); }
.gate { position: absolute; inset: 0; z-index: 4; display: grid; place-items: center; padding: 20px; background: rgba(7,7,11,.62); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.gate-card { max-width: 380px; text-align: center; }
.gate-lock { font-size: 44px; animation: float 4s ease-in-out infinite; }
.gate-card h3 { font-family: var(--display); font-size: 28px; font-weight: 900; letter-spacing: -.02em; margin: 8px 0 6px; text-transform: uppercase; }
.gate-card p { color: var(--muted); }
.gate-card p b { color: var(--gold); }
.gate-meter { height: 10px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; margin: 16px 0 4px; }
.gate-meter-fill { height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--gold), var(--alive)); transition: width 1s var(--ease); }
.gate-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 18px; }

/* ---------- rewards + leaderboard ---------- */
.rewards-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 16px; margin-top: 16px; }
.pool { padding: 28px; position: relative; background: radial-gradient(circle at 100% 0, rgba(255,211,77,.16), transparent 55%), var(--panel); }
.pool-amount { display: flex; align-items: baseline; gap: 10px; margin-top: 10px; font-family: var(--display); font-weight: 900; letter-spacing: -.04em; }
.pool-amount span { font-size: clamp(48px, 6vw, 76px); line-height: 1; color: var(--gold); text-shadow: 0 0 40px rgba(255,211,77,.35); }
.pool-amount small { font-size: 22px; color: var(--muted); }
.pool-usd { font-family: var(--mono); color: var(--muted); font-size: 14px; margin: 6px 0 18px; }
.pool h3 { font-family: var(--display); font-size: 20px; letter-spacing: -.02em; margin-bottom: 8px; }
.pool p { color: var(--muted); font-size: 15px; }
.pool-note { display: flex; align-items: center; gap: 10px; margin-top: 14px; color: var(--text) !important; }
.pool-link { display: inline-block; margin-top: 14px; font-family: var(--mono); font-size: 13px; color: var(--accent); }
.board-list { list-style: none; padding: 8px; counter-reset: r; }
.board-list li { counter-increment: r; display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 12px; font-family: var(--mono); font-size: 14px; }
.board-list li:nth-child(odd) { background: rgba(255,255,255,.025); }
.board-list li::before { content: counter(r); font-family: var(--display); font-weight: 800; color: var(--muted); }
.board-list li:nth-child(1)::before { content: '🥇'; } .board-list li:nth-child(2)::before { content: '🥈'; } .board-list li:nth-child(3)::before { content: '🥉'; }
.board-list li.me { background: rgba(var(--accent-rgb), .12); box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), .4); }
.board-list b { font-family: var(--display); }
.board-list .board-empty { display: block; color: var(--muted); text-align: center; padding: 40px 16px; font-family: var(--body); }
.board-list li.board-empty::before { content: none; }
.board-you { margin: 0 16px 16px; padding: 12px 14px; border-radius: 12px; border: 1px dashed rgba(var(--accent-rgb), .4); font-family: var(--mono); font-size: 13px; color: var(--muted); }
.board-you b { color: var(--text); }

@media (max-width: 860px) {
  .rewards-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .nav-buy { display: none; }
}
