/* Образ: упаковка нарезного батона — белый пакет, чёрный шрифт, зелёные акценты, этикетка «Состав».
   Одна светлая тема. Цвет хлеба живёт только в самом ломтике. */
:root {
  --bg: #f7f7f4;          /* бумага, почти белая */
  --surface: #ffffff;
  --ink: #14161a;
  --ink-2: #444a52;
  --muted: #747a83;
  --line: #e2e3e0;
  --line-2: #cfd1cd;
  --accent: #0f7d43;      /* зелёный: заметнее синего; белый текст на нём читается (5,2:1) */
  --accent-hover: #0b6435;
  --accent-soft: #e5f4ea;
  --crust: #d9a441;       /* золотистый цвет корки — только для полоски под шапкой */
  --good: #1f8a4c;
  --bad: #c23a2c;
  --radius: 10px;
  --max: 1080px;
  --display: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --sans: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --num: "Onest", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  /* токеномика: проверенная категориальная палитра, порядок фиксирован */
  --series-1: #008300; --series-2: #eda100; --series-3: #6250d6;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
b { font-weight: 600; }
h2, h3, p, dl, dd, ol, ul { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
img { display: block; }
code { font: 13px/1.4 var(--mono); overflow-wrap: anywhere; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }

.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono, #time, .board td, .kv dd, .rows dd { font-variant-numeric: tabular-nums; }
.eyebrow, .stat-label { font: 500 12px/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.display { font: 800 clamp(32px, 4.8vw, 52px)/1.04 var(--display); letter-spacing: -.035em; text-wrap: balance; }

.chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 6px; border: 1px solid var(--line-2); background: var(--surface); font: 500 12px/1 var(--mono); color: var(--ink-2); white-space: nowrap; }
.chip .dot, .btn .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.chip.status.live .dot { background: var(--good); }
.chip.bonus { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card.flush { padding: 0; overflow: hidden; }

/* ── кнопки ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 20px; border-radius: 8px; border: 1px solid var(--line-2);
  background: var(--surface); color: var(--ink); font-size: 15px; font-weight: 600; text-decoration: none;
  cursor: pointer; transition: background .15s, color .15s, border-color .15s, transform .1s; white-space: nowrap;
}
.btn:hover { border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.sm { height: 36px; padding: 0 14px; font-size: 13px; }
.btn.icon-only { width: 36px; padding: 0; }
.btn:disabled { opacity: .5; cursor: default; }
.btn.connected .dot { background: var(--good); }

/* ── шапка ─────────────────────────────────────────────────────────────── */
.top {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30; height: 60px;
  display: flex; align-items: center; gap: 24px;
  padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px));
  background: rgba(255, 255, 255, .88); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.logo { border-radius: 8px; }
.brand-name { font: 800 20px/1 var(--display); letter-spacing: -.03em; color: var(--ink); }
.nav { display: flex; gap: 24px; margin-left: 12px; font-size: 14px; }
.nav a { color: var(--ink-2); text-decoration: none; }
.nav a:hover { color: var(--accent); }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
@media (max-width: 880px) { .nav { display: none; } }
@media (max-width: 420px) { .brand .chip { display: none; } .top { gap: 12px; } }

/* ── игра ──────────────────────────────────────────────────────────────── */
.stage {
  position: relative; overflow: hidden;
  height: calc(100vh - 60px); height: calc(100svh - 60px); min-height: 560px; max-height: 940px;
  user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; touch-action: manipulation; cursor: pointer;
  background: linear-gradient(180deg, #ffffff 0%, #fbfbf9 60%, #f1f1ed 100%);
}
.glow { position: absolute; left: 50%; bottom: 0; width: min(1000px, 130vw); height: 34%; transform: translateX(-50%); pointer-events: none;
  background: radial-gradient(closest-side, rgba(20, 22, 26, .045), transparent 80%); }

.scene3d { position: absolute; inset: 0; pointer-events: none; }
.scene3d canvas { display: block; width: 100%; height: 100%; }
.scene { visibility: hidden; }                     /* плоский ломтик — запасной: только если 3D не запустился */
.stage.no-3d .scene { visibility: visible; }
.stage.has-3d .scene { display: none; }


.hud { position: absolute; top: clamp(26px, 6vh, 64px); left: 0; right: 0; text-align: center; pointer-events: none; transition: opacity .3s; }
/* до старта вместо «0» — объяснение, зачем держать ломтик */
.intro { position: absolute; top: clamp(24px, 5.5vh, 60px); left: 0; right: 0; padding: 0 20px; text-align: center; transition: opacity .3s, transform .3s; z-index: 2; }
.intro h1 { margin: 0; font: 800 clamp(30px, 5vw, 56px)/1.04 var(--display); letter-spacing: -.04em; text-wrap: balance; }
.intro h1 .tk { color: var(--accent); }
.intro p { margin: 14px auto 0; max-width: 520px; color: var(--ink-2); font-size: clamp(15px, 1.6vw, 17px); text-wrap: pretty; }
.prize-pill { margin-top: 18px; display: inline-flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; padding: 10px 16px; border-radius: 10px;
  background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); color: var(--ink); text-decoration: none; font-size: 14px; cursor: pointer; }
.prize-pill:hover { border-color: var(--accent); }
.prize-pill .pp-label { font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .04em; color: var(--accent); }
.prize-pill b { font-weight: 800; }
.prize-pill .pp-time { font: 500 13px/1 var(--mono); color: var(--ink-2); }
.stage[data-state="idle"] .hud { opacity: 0; }
.stage:not([data-state="idle"]) .intro { opacity: 0; transform: translateY(-8px); pointer-events: none; }
@media (max-width: 560px) { .intro p { font-size: 14px; } .prize-pill { gap: 6px 10px; padding: 9px 12px; } }
.balance { margin-top: 8px; font: 800 clamp(64px, 14vw, 124px)/1 var(--num); letter-spacing: -.05em; font-variant-numeric: tabular-nums; }
.meta { margin-top: 14px; display: inline-flex; align-items: center; gap: 10px; color: var(--muted); font: 500 14px/1 var(--mono); }
.mult { color: var(--accent); font-weight: 600; }
.mult.pop { animation: pop .5s ease-out; }
@keyframes pop { 30% { transform: scale(1.45); } }

.wind { position: absolute; top: 44%; left: 0; right: 0; pointer-events: none; font: 22px/1 var(--mono); letter-spacing: .3em; color: var(--muted); opacity: 0; transition: opacity .25s; }
.wind.l { text-align: left; padding-left: clamp(16px, 6vw, 72px); }
.wind.r { text-align: right; padding-right: clamp(16px, 6vw, 72px); }

/* SVG-запаска */
.scene { position: absolute; left: 0; right: 0; bottom: clamp(56px, 14vh, 130px); display: flex; justify-content: center; pointer-events: none; }
.bread-wrap { width: auto; }
.bread-img { display: block; height: clamp(150px, 34vh, 290px); width: auto; transform-origin: 50% 100%; filter: drop-shadow(0 18px 14px rgba(40, 28, 10, .22)); }
.ground { position: absolute; left: 0; right: 0; bottom: 0; border-top: 1px solid var(--line-2); }

.hints { position: absolute; left: 20px; right: 20px; bottom: clamp(18px, 4vh, 36px); text-align: center; pointer-events: none; transition: opacity .3s; }
.hint { font-weight: 600; }
.hint-sub { margin: 4px auto 0; max-width: 460px; font-size: 13px; color: var(--muted); }
@media (max-height: 640px) { .hint-sub { display: none; } }
@media (hover: none) { .kbd { display: none; } }
.stage:not([data-state="idle"]) .hints { opacity: 0; }

.stage.shake { animation: shake .34s ease-out; }
@keyframes shake { 20% { transform: translate(-4px, 3px); } 45% { transform: translate(3px, -2px); } 70% { transform: translate(-1px, 1px); } }

.result {
  position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; padding: 16px; cursor: default;
  background: rgba(247, 247, 244, .6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  animation: fade .3s ease-out;
}
@keyframes fade { from { opacity: 0; } }
.result-card { width: min(420px, 100%); padding: 28px 26px 24px; text-align: center; box-shadow: 0 24px 60px -30px rgba(20, 22, 26, .3); animation: rise .35s cubic-bezier(.2, .8, .2, 1); }
@keyframes rise { from { transform: translateY(12px); opacity: 0; } }
.result-main { margin-top: 10px; font: 800 60px/1 var(--num); letter-spacing: -.045em; color: var(--accent); }
.result-sub { margin-top: 10px; color: var(--muted); font-size: 14px; }
.rows { margin-top: 20px; text-align: left; border-top: 1px solid var(--line); }
.rows > div { display: flex; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.rows dt { color: var(--muted); }
.rows dd { font-weight: 600; }
.actions { margin-top: 20px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.actions .btn.primary { min-width: 150px; }
.notice { margin-top: 12px; font-size: 13px; color: var(--bad); }
.notice.info { color: var(--muted); }

/* ── блоки ─────────────────────────────────────────────────────────────── */
.block { max-width: var(--max); margin: 0 auto; padding: clamp(72px, 10vw, 120px) max(20px, env(safe-area-inset-right, 0px)) 0 max(20px, env(safe-area-inset-left, 0px)); scroll-margin-top: 64px; }
.block-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.block-head .eyebrow { margin-bottom: 10px; }
.head-chips { display: flex; gap: 8px; }
.lead { margin-top: 16px; max-width: 620px; font-size: 18px; color: var(--ink-2); }

.how { display: grid; grid-template-columns: 1.1fr 2fr; gap: 40px; align-items: start; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.steps li { padding: 24px 22px; }
.steps li + li { border-left: 1px solid var(--line); }
.steps h3 { font: 700 19px/1.2 var(--display); letter-spacing: -.02em; color: var(--ink); }
.steps p { margin-top: 10px; color: var(--ink-2); font-size: 15px; }
@media (max-width: 900px) { .how { grid-template-columns: 1fr; gap: 24px; } }
@media (max-width: 640px) { .steps { grid-template-columns: 1fr; } .steps li + li { border-left: 0; border-top: 1px solid var(--line); } }

/* токен */
.stats { display: grid; grid-template-columns: repeat(5, 1fr); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.stat { padding: 18px 20px; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-value { margin-top: 8px; font: 700 23px/1.2 var(--num); letter-spacing: -.02em; }
.stat-value.up { color: var(--good); }
.stat-value.down { color: var(--bad); }
@media (max-width: 900px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat + .stat { border-left: 0; }
  .stat { border-top: 1px solid var(--line); }
  .stat:nth-child(-n+2) { border-top: 0; }
  .stat:nth-child(even) { border-left: 1px solid var(--line); }
  .stat:last-child { grid-column: 1 / -1; border-left: 0; }
}

.chart-card { margin-top: 12px; padding: 0; overflow: hidden; height: clamp(320px, 46vw, 480px); }
.chart-card.empty { height: 140px; }
.chart-card iframe { display: block; width: 100%; height: 100%; border: 0; }
.chart-empty { height: 100%; display: grid; place-items: center; padding: 24px; text-align: center; }
.source { margin-top: 10px; }

.split { margin-top: 12px; display: grid; grid-template-columns: 1.1fr 1fr; gap: 12px; align-items: start; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

/* этикетка «Состав» */
.label-box { border: 2px solid var(--accent); border-radius: 6px; padding: 0; background: var(--surface); }
.label-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 14px 20px; background: var(--accent); color: #fff; }
.label-head h3 { font: 800 18px/1 var(--display); letter-spacing: .04em; text-transform: uppercase; }
.label-head span { font: 500 12px/1 var(--mono); opacity: .85; }
.label-body { padding: 18px 20px 20px; }
.supply { font: 700 clamp(26px, 3.6vw, 34px)/1.1 var(--num); letter-spacing: -.02em; }
.supply .muted { font: 500 13px/1 var(--mono); letter-spacing: 0; }
.seg { margin-top: 18px; display: flex; gap: 2px; height: 28px; }
.seg-part { position: relative; min-width: 4px; border-radius: 4px; display: flex; align-items: center; padding-left: 8px; color: #fff; font: 600 12px/1 var(--mono); outline-offset: 3px; cursor: default; }
.seg-part.dark-text { color: #14161a; }
.legend { margin-top: 16px; display: grid; gap: 0; border-top: 1px dashed var(--line-2); }
.legend li { display: grid; grid-template-columns: 12px 1fr auto; align-items: center; gap: 12px; font-size: 14px; padding: 9px 0; border-bottom: 1px dashed var(--line-2); }
.legend .sw { width: 12px; height: 12px; border-radius: 3px; }
.legend .amt { color: var(--muted); font: 500 13px var(--mono); }
#tokenomicsNote { margin-top: 14px; }
.label-foot { margin-top: 14px; display: flex; justify-content: space-between; gap: 12px; font: 500 11px/1.4 var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }

.wallet-lead { color: var(--ink-2); margin-bottom: 18px; }
#walletOff .small { margin-top: 12px; }
.wallet-addr code { font-size: 14px; }
#walletOn .rows { margin: 14px 0 16px; }
.tiers { margin-top: 22px; width: 100%; border-collapse: collapse; font-size: 14px; }
.tiers caption { text-align: left; padding-bottom: 6px; }
.tiers th { text-align: left; font: 500 11px var(--mono); color: var(--muted); letter-spacing: .04em; text-transform: uppercase; padding: 8px 0; border-bottom: 1px solid var(--line); }
.tiers td { padding: 9px 0; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.tiers th:last-child, .tiers td:last-child { text-align: right; }
.tiers tr.on td { color: var(--accent); font-weight: 600; }

.contract { margin-top: 12px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.contract code { flex: 1 1 260px; min-width: 0; }
.contract-links { display: inline-flex; gap: 14px; font-size: 14px; }
.contract-links a { color: var(--accent); text-underline-offset: 3px; }

/* лидеры */
.tabs { display: inline-flex; padding: 3px; border-radius: 8px; background: #ececea; }
.tabs button { height: 32px; padding: 0 14px; border: 0; border-radius: 6px; background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 600; cursor: pointer; }
.tabs button[aria-pressed="true"] { background: var(--surface); color: var(--accent); box-shadow: 0 1px 2px rgba(0, 0, 0, .1); }
.board { width: 100%; border-collapse: collapse; font-size: 15px; }
.board th { text-align: left; font: 500 11px var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); padding: 14px 22px 10px; border-bottom: 1px solid var(--line); }
.board td { padding: 14px 22px; border-bottom: 1px solid var(--line); }
.board tbody tr:last-child td { border-bottom: 0; }
.board .c-rank { width: 64px; color: var(--muted); font-family: var(--mono); }
.board .c-best, .board .c-bal { text-align: right; }
.board .c-best { color: var(--muted); width: 120px; }
.board .c-bal { width: 140px; font-weight: 600; }
.board tr.top3 td:first-child { color: var(--accent); font-weight: 700; }
.board tr.me td { background: var(--accent-soft); }
.board tr.gap td { padding: 4px 22px; text-align: center; color: var(--muted); letter-spacing: .3em; }
.board td.empty { text-align: center; color: var(--muted); padding: 44px 22px; }
.you { margin-left: 8px; font: 600 11px/1 var(--mono); padding: 3px 7px; border-radius: 4px; background: var(--accent); color: #fff; vertical-align: 1px; }
#boardNote { margin-top: 12px; }
@media (max-width: 560px) {
  .board th, .board td { padding-left: 14px; padding-right: 14px; }
  .board .c-best { display: none; }
  .board .c-rank { width: 44px; }
}

/* розыгрыш */
.big { margin-top: 10px; font: 700 clamp(30px, 4.6vw, 44px)/1.1 var(--num); letter-spacing: -.03em; }
.kv { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.kv > div { padding: 16px 20px; }
.kv > div + div { border-left: 1px solid var(--line); }
.kv dt { font: 500 11px var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.kv dd { margin-top: 4px; font: 700 23px/1.2 var(--num); }
.rules { margin-top: 24px; display: grid; gap: 8px; color: var(--ink-2); max-width: 720px; }
.rules li { padding-left: 22px; position: relative; }
.rules li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; border-radius: 2px; background: var(--accent); }
.rules b { color: var(--ink); }
@media (max-width: 640px) { .kv dd { font-size: 18px; } .kv > div { padding: 14px; } }

/* обещание */
.pledge-box { border-top: 3px solid var(--ink); padding-top: 28px; }
.pledge-box .eyebrow + .statement { margin-top: 14px; }
.statement { font: 800 clamp(34px, 6.4vw, 70px)/1.02 var(--display); letter-spacing: -.04em; text-wrap: balance; max-width: 900px; }
.statement span { color: var(--accent); }
.proof { margin-top: 28px; border-top: 1px solid var(--line); max-width: 720px; }
.proof:empty { display: none; }
.proof > div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.proof dt { color: var(--muted); }
.proof dd { font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.proof dd a { color: var(--accent); text-underline-offset: 3px; }

/* faq */
.faq { border-top: 1px solid var(--line); max-width: 820px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 40px 18px 0; position: relative; font-size: 17px; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font: 400 24px/1 var(--mono); color: var(--accent); }
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 0 20px; max-width: 680px; color: var(--ink-2); }

/* подвал */
.foot { max-width: var(--max); margin: clamp(80px, 11vw, 130px) auto 0; padding: 26px max(20px, env(safe-area-inset-right, 0px)) calc(34px + env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px)); border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
.foot-brand { display: inline-flex; align-items: center; gap: 8px; font: 800 16px/1 var(--display); letter-spacing: -.02em; color: var(--ink); }
.foot-brand .muted { font: 500 12px var(--mono); }
.foot-links { display: inline-flex; flex-wrap: wrap; gap: 18px; font-size: 14px; }
.foot-links a { color: var(--ink-2); text-underline-offset: 3px; }
.foot-links a:hover { color: var(--accent); }
.foot-note { flex-basis: 100%; }

/* диалог */
dialog { width: min(420px, calc(100vw - 32px)); padding: 26px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); box-shadow: 0 30px 80px -30px rgba(20, 22, 26, .35); }
dialog::backdrop { background: rgba(20, 22, 26, .3); backdrop-filter: blur(3px); }
dialog h3 { font: 800 24px/1.1 var(--display); letter-spacing: -.02em; margin-bottom: 18px; }
dialog label { display: block; margin-bottom: 14px; font-size: 13px; font-weight: 600; }
dialog input { display: block; width: 100%; margin-top: 6px; height: 46px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--bg); color: var(--ink); font: inherit; font-size: 16px; }
dialog input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
dialog input:disabled { opacity: .6; }
dialog .actions { justify-content: flex-start; }

.tooltip { position: fixed; z-index: 50; pointer-events: none; padding: 8px 10px; border-radius: 6px; background: var(--ink); color: #fff; font-size: 12px; line-height: 1.4; max-width: 240px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .stage.shake, .mult.pop, .result-card { animation: none; }
}

/* ── плашка о фейках: специально огромная и красная ────────────────────── */
.fake-banner { background: #d61f1f; color: #fff; border-bottom: 4px solid #8f0e0e; }
.fb-inner { max-width: var(--max); margin: 0 auto; padding: clamp(22px, 4vw, 40px) max(20px, env(safe-area-inset-right, 0px)) clamp(22px, 4vw, 36px) max(20px, env(safe-area-inset-left, 0px)); text-align: center; }
.fb-title { font: 900 clamp(30px, 6.4vw, 72px)/1 var(--display); letter-spacing: -.03em; text-transform: uppercase; text-wrap: balance; }
.fb-sub { margin-top: 14px; font-size: clamp(16px, 2vw, 21px); font-weight: 600; text-wrap: balance; }
.fb-launch { margin-top: 16px; display: inline-block; padding: 10px 18px; border-radius: 10px; background: #fff; color: #b31414; font: 700 clamp(16px, 2.2vw, 22px)/1.2 var(--display); }
.fb-launch b { font-variant-numeric: tabular-nums; }
.fb-list { margin: 18px auto 0; max-width: 720px; display: grid; gap: 6px; text-align: left; }
.fb-list li { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 8px 12px; border-radius: 8px; background: rgba(0, 0, 0, .18); font-size: 13px; }
.fb-list .fake-tag { font: 800 11px/1 var(--mono); padding: 4px 7px; border-radius: 4px; background: #fff; color: #b31414; letter-spacing: .06em; }
.fb-list code { flex: 1 1 220px; min-width: 0; font-size: 12px; color: #fff; }
.fb-list a { color: #fff; }
.fb-foot { margin-top: 16px; font-size: 13px; opacity: .92; }
.fb-foot a { color: #fff; }

/* ── вступление: кнопки ────────────────────────────────────────────────── */
.intro-actions { margin-top: 18px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.intro-actions .prize-pill { margin-top: 0; }
.claim-pill { display: inline-flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: 10px; border: 0; background: var(--accent); color: #fff; font-size: 14px; cursor: pointer;
  box-shadow: 0 8px 20px -10px rgba(15, 125, 67, .7); transition: background .15s, transform .1s; }
.claim-pill:hover { background: var(--accent-hover); }
.claim-pill:active { transform: translateY(1px); }
.claim-pill .pp-label { font: 500 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .04em; opacity: .85; }
.claim-pill b { font-weight: 800; }
.claim-pill.done { background: var(--accent-soft); color: var(--accent); box-shadow: none; }

/* ── 49 SOL: зелёная полоса во всю ширину ──────────────────────────────── */
.sol-band { margin-top: clamp(56px, 8vw, 96px); background: var(--accent); color: #fff; position: relative; overflow: hidden; scroll-margin-top: 60px; }
.sol-band::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(900px 420px at 85% 0%, rgba(255, 255, 255, .16), transparent 70%), radial-gradient(700px 380px at 0% 100%, rgba(0, 0, 0, .18), transparent 70%); }
.sol-inner { position: relative; max-width: var(--max); margin: 0 auto; padding: clamp(48px, 7vw, 88px) max(20px, env(safe-area-inset-right, 0px)) clamp(44px, 6vw, 72px) max(20px, env(safe-area-inset-left, 0px)); }
.sol-top { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: end; margin-bottom: 28px; }
.eyebrow.light, .rules.light, .sol-note { color: rgba(255, 255, 255, .78); }
.sol-title { margin: 8px 0 0; display: flex; align-items: baseline; gap: 14px; line-height: .82; }
.sol-title #solPrizeBig { font: 900 clamp(120px, 21vw, 240px)/.82 var(--num); letter-spacing: -.07em; }
.sol-unit { font: 900 clamp(40px, 6vw, 72px)/1 var(--display); letter-spacing: -.02em; }
.sol-lead { margin-top: 20px; max-width: 520px; font-size: clamp(16px, 1.8vw, 19px); color: rgba(255, 255, 255, .92); }
.sol-lead .tk { font-weight: 700; color: #fff; }
.sol-actions { margin-top: 24px; display: flex; gap: 10px; flex-wrap: wrap; }
.btn.lg { height: 52px; padding: 0 24px; font-size: 16px; border-radius: 10px; }
.btn.white { background: #fff; border-color: #fff; color: var(--accent); }
.btn.white:hover { background: #eef8f1; border-color: #eef8f1; }
.btn.white.entered { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .4); color: #fff; cursor: default; }
.btn.outline-light { background: transparent; border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn.outline-light:hover { border-color: #fff; background: rgba(255, 255, 255, .08); }
.sol-side { padding: 22px; border-radius: 14px; background: rgba(0, 0, 0, .16); border: 1px solid rgba(255, 255, 255, .16); }
.sol-soon { margin-top: 8px; font: 800 28px/1.1 var(--display); }
.sol-stats { margin-top: 18px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid rgba(255, 255, 255, .2); }
.sol-stats > div { padding-top: 12px; }
.sol-stats dt { font: 500 11px/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: rgba(255, 255, 255, .7); }
.sol-stats dd { margin-top: 4px; font: 800 24px/1.1 var(--num); }
.sol-note { margin-top: 10px; font-size: 13px; }
.sol-table { border: 0; color: var(--ink); } /* полоса зелёная с белым текстом — таблице возвращаем тёмный */
.rules.light { margin-top: 22px; }
.rules.light b { color: #fff; }
.rules.light li::before { background: #fff; }
@media (max-width: 820px) { .sol-top { grid-template-columns: 1fr; align-items: start; } }

/* таймер плитками */
.cd { margin-top: 10px; display: flex; gap: 8px; }
.cd-tile { flex: 1; min-width: 0; max-width: 84px; padding: 10px 6px 8px; border-radius: 10px; background: var(--ink); color: #fff; text-align: center; }
.cd-num { display: block; font: 800 clamp(24px, 3.2vw, 34px)/1 var(--num); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.cd-lab { display: block; margin-top: 6px; font: 500 10px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; opacity: .7; }
.cd-light .cd-tile { background: #fff; color: var(--accent); }

/* ── недельный розыгрыш: лотерейный билет ───────────────────────────────── */
.ticket { position: relative; display: grid; grid-template-columns: 1.5fr 1fr; background: var(--surface); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 30px 60px -40px rgba(20, 22, 26, .35); overflow: hidden; }
.ticket-main { padding: clamp(24px, 4vw, 44px); }
.ticket-prize { margin-top: 12px; font: 900 clamp(40px, 6.4vw, 76px)/.95 var(--num); letter-spacing: -.05em; color: var(--accent); text-wrap: balance; }
.ticket-sub { margin-top: 12px; font-size: 16px; color: var(--ink-2); }
.ticket-actions { margin-top: 24px; display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.ticket-stub { position: relative; padding: clamp(24px, 4vw, 40px); background: var(--accent-soft); border-left: 2px dashed color-mix(in srgb, var(--accent) 35%, transparent); }
/* вырезы-полукруги на линии отрыва */
.ticket-stub::before, .ticket-stub::after { content: ""; position: absolute; left: -15px; width: 28px; height: 28px; border-radius: 50%; background: var(--bg); border: 1px solid var(--line); }
.ticket-stub::before { top: -15px; }
.ticket-stub::after { bottom: -15px; }
.stub-stats { margin-top: 18px; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid color-mix(in srgb, var(--accent) 22%, transparent); }
.stub-stats > div { padding-top: 12px; }
.stub-stats dt { font: 500 11px/1.3 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.stub-stats dd { margin-top: 4px; font: 800 22px/1.1 var(--num); }
@media (max-width: 820px) {
  .ticket { grid-template-columns: 1fr; }
  .ticket-stub { border-left: 0; border-top: 2px dashed color-mix(in srgb, var(--accent) 35%, transparent); }
  .ticket-stub::before, .ticket-stub::after { top: -15px; bottom: auto; }
  .ticket-stub::before { left: -15px; }
  .ticket-stub::after { left: auto; right: -15px; }
}

/* ── диалог раздачи ───────────────────────────────────────────────────── */
.claim-box h3 .tk { color: var(--accent); }
.claim-meter { margin-top: 18px; height: 10px; border-radius: 6px; background: #ececea; overflow: hidden; }
.claim-meter-fill { height: 100%; width: 0; background: var(--accent); border-radius: 6px; transition: width .4s; }
#clCount { margin-top: 8px; }
.claim-done { margin-top: 14px; padding: 12px 14px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font-weight: 600; }

/* ── выбор кошелька ─────────────────────────────────────────────────────── */
.wallet-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.wd-list { margin-top: 14px; display: grid; gap: 8px; }
.wd-item { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 600; cursor: pointer; text-align: left; }
.wd-item:hover { border-color: var(--accent); background: var(--accent-soft); }
.wd-item img, .wd-letter { width: 32px; height: 32px; border-radius: 8px; flex: none; }
.wd-letter { display: grid; place-items: center; background: #ececea; color: var(--ink-2); font: 800 15px/1 var(--display); }
.wd-item .wd-tag { margin-left: auto; font: 500 11px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.wd-item .wd-tag.muted { color: var(--muted); }
.wd-sub { margin-top: 18px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.wd-empty { padding: 12px 14px; border-radius: 10px; background: #f3f3f0; font-size: 14px; color: var(--ink-2); }

/* ── награды ────────────────────────────────────────────────────────────── */
.rewards { margin-top: 18px; padding: 16px; border-radius: 12px; background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); }
.rw-total { margin-top: 6px; font: 800 28px/1.1 var(--num); letter-spacing: -.02em; }
.rw-total .tk { font-size: 15px; color: var(--accent); }
#rwBreak { margin-top: 4px; }
.rw-status { margin-top: 10px; font-size: 14px; font-weight: 600; color: var(--accent); }
.rw-status a { color: var(--accent); }

.lang-btn { font-family: var(--mono); letter-spacing: .04em; min-width: 44px; display: inline-flex; align-items: center; gap: 7px; }
.lang-btn img { width: 20px; height: 14px; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); object-fit: cover; }
.lang-pick { position: relative; }
.lang-menu { position: absolute; z-index: 120; top: calc(100% + 8px); right: 0; min-width: 180px; margin: 0; padding: 6px; list-style: none;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 40px -16px rgba(20, 20, 10, .35); }
.lang-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 600; }
.lang-menu a:hover { background: var(--accent-soft); }
.lang-menu a[aria-current] { background: var(--accent-soft); color: var(--accent); }
.lang-menu img { width: 22px; height: 15px; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); }
@media (max-width: 520px) { .lang-btn span { display: none; } .lang-btn { min-width: 0; padding-left: 10px; padding-right: 10px; } }

/* ── счёт в токенах ─────────────────────────────────────────────────────── */
.balance { display: inline-flex; align-items: baseline; gap: 12px; }
.balance-tk { font: 800 clamp(16px, 2.4vw, 24px)/1 var(--display); letter-spacing: -.01em; color: var(--accent); }
.res-done { margin-top: 14px; display: grid; gap: 6px; text-align: left; }
.res-done li { padding: 9px 12px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font-size: 14px; font-weight: 600; }
.res-pay { margin-top: 10px; }

/* ── ежедневные испытания ───────────────────────────────────────────────── */
.ch-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.ch-card { position: relative; padding: 20px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.ch-card.done { border-color: var(--accent); background: var(--accent-soft); }
.ch-tier { font: 500 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ch-title { margin-top: 10px; font: 800 20px/1.2 var(--display); letter-spacing: -.02em; }
.ch-reward { margin-top: 6px; font-weight: 700; color: var(--accent); }
.ch-bar { margin-top: 16px; height: 8px; border-radius: 5px; background: #ececea; overflow: hidden; }
.ch-bar i { display: block; height: 100%; width: 0; background: var(--accent); border-radius: 5px; transition: width .4s; }
.ch-prog { margin-top: 8px; font: 500 12px/1 var(--mono); color: var(--muted); }
.ch-check { position: absolute; top: 16px; right: 16px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.ch-card.ready { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft), 0 10px 30px -14px rgba(15, 125, 67, .55); }
.ch-claim { margin-top: 12px; width: 100%; animation: chPulse 1.8s ease-in-out infinite; }
.ch-claim:disabled { animation: none; opacity: .8; }
@keyframes chPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(15, 125, 67, .35); } 50% { box-shadow: 0 0 0 7px rgba(15, 125, 67, 0); } }
.ch-card.just .ch-check { animation: chPop .55s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes chPop { from { transform: scale(0); } to { transform: scale(1); } }
.shake { animation: shake .4s; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
.ch-mine { color: var(--accent); border-color: var(--accent); font-weight: 700; }
.bump { animation: bump .5s ease; }
@keyframes bump { 40% { transform: scale(1.12); } }
.prize-pill.has-reward { background: var(--accent); border-color: var(--accent); color: #fff; animation: chPulse 1.8s ease-in-out infinite; }
.prize-pill.has-reward .pp-label, .prize-pill.has-reward .pp-time, .prize-pill.has-reward b { color: #fff; }
#resDone li { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.reward-fx { position: fixed; z-index: 1000; pointer-events: none; width: 0; height: 0; }
.reward-fx b { position: absolute; left: 0; top: 0; white-space: nowrap; font-weight: 900; font-size: 32px; line-height: 1; letter-spacing: -.01em; color: var(--accent);
  text-shadow: 0 0 2px #fff, 0 2px 0 #fff, 0 8px 22px rgba(15, 125, 67, .3); }
.reward-fx i { position: absolute; left: 0; top: 0; display: block; border-radius: 50%; }
@media (prefers-reduced-motion: reduce) { .ch-claim, .prize-pill.has-reward { animation: none; } }
#chNote { margin-top: 12px; }
@media (max-width: 820px) { .ch-grid { grid-template-columns: 1fr; } }

/* ── топ-3 недели ───────────────────────────────────────────────────────── */
.podium { margin-top: 16px; display: grid; gap: 6px; max-width: 420px; }
.podium li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 14px; border-radius: 10px; background: #f6f6f3; font-weight: 600; }
.podium li:first-child { background: var(--accent-soft); color: var(--accent); }
.podium .pl { font: 600 13px/1.4 var(--mono); color: var(--muted); }
.podium li:first-child .pl { color: var(--accent); }

/* ── логотипы Solana и кошельков ────────────────────────────────────────── */
.sol-unit { display: inline-flex; align-items: center; gap: 12px; }
.sol-logo { width: clamp(34px, 5vw, 54px); height: auto; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .18)); background: #fff; border-radius: 12px; padding: 7px 6px; box-sizing: content-box; }
.chain-chip img, .chain-mini img { display: inline-block; vertical-align: -1px; }
.chain-mini { display: inline-flex; align-items: center; gap: 6px; }
.wallet-logos { margin-top: 14px; display: flex; gap: 8px; }
.wallet-logos img { border-radius: 8px; }
.foot-sol { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.foot-sol img { display: inline-block; }

/* ── варианты света (класс ставит bread3d.js) ───────────────────────────── */
.light-fx { position: absolute; inset: 0; pointer-events: none; }
.light-fx .dust { position: absolute; inset: 0; width: 100%; height: 100%; }
/* лампа: лёгкая дымка в сцене — чуть темнее белого, чтобы луч читался светом */
/* контровой: чуть темнее фон прямо за ломтиком, чтобы светящаяся кромка читалась */
.stage.light-rim .light-fx { background: radial-gradient(circle at 50% 64%, rgba(28, 24, 18, .18) 0%, rgba(28, 24, 18, .07) 22%, rgba(28, 24, 18, 0) 44%); }
/* окно пекарни: тёплый диагональный луч + пылинки */
.stage.light-window .light-fx { background: linear-gradient(112deg, rgba(255, 196, 112, 0) 34%, rgba(255, 196, 112, .30) 46%, rgba(255, 196, 112, .16) 60%, rgba(255, 196, 112, 0) 72%); }
.stage.light-window .glow { background: radial-gradient(closest-side, rgba(255, 190, 110, .12), transparent 80%); }

/* 3D-сцена начинается под надписями (top ставит app.js) — кнопки больше не наезжают на ломтик */
/* на невысоких экранах — компактнее заголовок, чтобы ломтику хватало места */
@media (max-height: 820px) and (min-width: 521px) { .intro h1 { font-size: clamp(30px, 4vw, 44px); } .intro p { margin-top: 10px; } .intro-actions { margin-top: 14px; } }
@media (max-height: 820px) and (min-width: 1000px) { .intro h1 br { display: none; } .intro h1 { font-size: 40px; } .intro p { max-width: 640px; } }
@media (max-width: 520px) {
  .intro-actions { gap: 8px; }
  .intro-actions .pp-label { display: none; }
  .prize-pill, .claim-pill { padding: 8px 12px; font-size: 13px; }
  .prize-pill .pp-time { display: none; }
}

.pledge-cond { margin-top: 14px; max-width: 620px; padding: 12px 16px; border-left: 3px solid var(--accent); background: var(--accent-soft); border-radius: 0 8px 8px 0; font-weight: 600; color: var(--ink); }

/* ── гостям: «сохрани токены» ─────────────────────────────────────────── */
.guest-bar { position: fixed; z-index: 90; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); transform: translateX(-50%);
  width: min(720px, calc(100vw - 24px)); display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 14px;
  background: #fff; border: 1px solid #f0c36b; border-radius: 14px; box-shadow: 0 12px 40px -12px rgba(30, 24, 10, .35); color: var(--ink); }
.guest-bar p { flex: 1; font-size: 14px; line-height: 1.35; margin: 0; }
.guest-bar b { color: var(--accent); white-space: nowrap; }
.gb-ico { flex: none; width: 26px; height: 26px; border-radius: 50%; background: #f5a524; color: #fff; display: grid; place-items: center; font-weight: 900; }
.gb-close { flex: none; width: 30px; height: 30px; border: 0; background: transparent; color: var(--muted); font-size: 22px; line-height: 1; cursor: pointer; border-radius: 8px; }
.gb-close:hover { background: rgba(0, 0, 0, .05); }
@media (max-width: 560px) { .guest-bar { flex-wrap: wrap; } .guest-bar p { flex-basis: calc(100% - 70px); font-size: 13px; } .guest-bar .btn { flex: 1; } }
.res-guest { margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: #fff7e6; border: 1px solid #f0c36b; text-align: left; }
.res-guest p { font-size: 13px; line-height: 1.4; margin: 0 0 10px; color: var(--ink); }
.flash { position: fixed; z-index: 100; left: 50%; top: 76px; transform: translateX(-50%); max-width: min(560px, calc(100vw - 24px));
  padding: 12px 16px; border-radius: 12px; background: var(--accent); color: #fff; font-weight: 600; box-shadow: 0 12px 30px -10px rgba(15, 125, 67, .5); transition: opacity .5s, transform .5s; }
.flash.out { opacity: 0; transform: translate(-50%, -10px); }

/* ── 49 SOL: видно сразу (светло-зелёная плашка в цветах сайта) ─────── */
.nav a.nav-sol { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; background: #e3f5ea; color: #0b5f33; font-weight: 700; border: 1px solid #b7e2c8; }
.nav a.nav-sol:hover { color: #0b5f33; background: #d4efdf; }
.sol-badge { display: inline-flex; align-items: center; gap: 8px; margin: 0 auto 16px; padding: 6px 14px 6px 6px; border-radius: 999px; text-decoration: none;
  background: #e3f5ea; color: #0b3d22; font-size: 14px; border: 1px solid #b7e2c8; box-shadow: 0 8px 24px -14px rgba(15, 125, 67, .55); position: relative;
  animation: solGlow 2.6s ease-in-out infinite; }
.sol-badge img { width: 26px; height: 26px; padding: 5px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px #b7e2c8; }
.sol-badge .sb-label { font: 600 11px/1 var(--mono); text-transform: uppercase; letter-spacing: .05em; color: var(--accent); }
.sol-badge b { font-weight: 900; font-size: 15px; color: #0b3d22; }
.sol-badge .sb-text { color: #3c6b50; }
.sol-badge .sb-arrow { color: var(--accent); transition: transform .15s; }
.sol-badge:hover { background: #d4efdf; }
.sol-badge:hover .sb-arrow { transform: translateX(3px); }
@keyframes solGlow { 0%, 100% { box-shadow: 0 8px 24px -14px rgba(15, 125, 67, .55), 0 0 0 0 rgba(15, 125, 67, .25); } 50% { box-shadow: 0 8px 24px -14px rgba(15, 125, 67, .55), 0 0 0 6px rgba(15, 125, 67, 0); } }
@media (max-width: 560px) { .sol-badge { font-size: 13px; margin-bottom: 12px; } .sol-badge .sb-text { display: none; } }
.sol-main-tag { display: inline-block; margin-right: 8px; padding: 3px 8px; border-radius: 6px; background: #ffe58a; color: #3d2c00; }
.sol-title #solPrizeBig { background: linear-gradient(100deg, #fff 0%, #fff 42%, #c9ffe6 50%, #fff 58%, #fff 100%); background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: solShine 5s ease-in-out infinite; }
@keyframes solShine { 0%, 55% { background-position: 100% 0; } 100% { background-position: -160% 0; } }
@media (prefers-reduced-motion: reduce) { .sol-badge, .sol-title #solPrizeBig { animation: none; } }

.nav { align-items: center; }
/* совсем низкие телефоны: убираем подзаголовок, чтобы ломтику хватило места под кнопками */
@media (max-height: 700px) and (max-width: 520px) { .intro p { display: none; } .intro-actions { margin-top: 14px; } .sol-badge { margin-bottom: 10px; } }

/* игра: шкала до следующего множителя */
.mult-next { margin: 14px auto 0; width: min(260px, 70vw); display: flex; flex-direction: column; align-items: center; gap: 7px; }
.mn-bar { width: 100%; height: 6px; border-radius: 99px; background: rgba(15, 125, 67, .14); overflow: hidden; }
.mn-bar i { display: block; height: 100%; background: var(--accent); border-radius: inherit; transform-origin: left; transform: scaleX(0); }
.mult-next span { font: 500 12px/1 var(--mono); color: var(--muted); letter-spacing: .02em; }

/* большие множители: счётчик дрожит и «раскаляется» */
.hud .balance.hot1 { animation: jit1 .14s steps(2) infinite; color: #0f7d43; }
.hud .balance.hot2 { animation: jit2 .1s steps(2) infinite; color: #0b8f4a; text-shadow: 0 0 18px rgba(20, 200, 110, .35); }
.hud .balance.hot3 { animation: jit3 .07s steps(2) infinite; color: #e3a008; text-shadow: 0 0 22px rgba(245, 170, 20, .55), 0 0 2px #fff; }
.hud .balance.hot3 .balance-tk { color: #c98a00; }
@keyframes jit1 { 0% { transform: translate(0, 0); } 50% { transform: translate(1px, -1px); } }
@keyframes jit2 { 0% { transform: translate(-1.5px, 1px) rotate(-.4deg); } 50% { transform: translate(1.5px, -1px) rotate(.4deg); } }
@keyframes jit3 { 0% { transform: translate(-2.5px, 1.5px) rotate(-.8deg) scale(1.02); } 50% { transform: translate(2.5px, -1.5px) rotate(.8deg) scale(1.04); } }
@media (prefers-reduced-motion: reduce) { .hud .balance.hot1, .hud .balance.hot2, .hud .balance.hot3 { animation: none; } }

/* первый экран: боковые панели (только широкие экраны, в игре прячутся) */
.hero-side { display: none; }
@media (min-width: 1180px) {
  .hero-side { display: block; position: absolute; z-index: 3; bottom: clamp(110px, 17vh, 210px); width: 224px; padding: 16px 16px 14px;
    background: rgba(255, 255, 255, .78); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border: 1px solid var(--line); border-radius: 16px;
    box-shadow: 0 14px 40px -24px rgba(20, 20, 10, .35); transition: opacity .3s; cursor: default; }
  .hero-me { left: max(24px, calc(50% - 600px)); }
  .hero-top { right: max(24px, calc(50% - 600px)); }
  .stage:not([data-state="idle"]) .hero-side { opacity: 0; pointer-events: none; }
}
.hm-value { margin: 10px 0 0; font: 800 34px/1 var(--num); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.hm-value .tk { font: 800 14px/1 var(--display); color: var(--accent); letter-spacing: 0; }
.hm-sub { margin: 8px 0 0; font-size: 13px; line-height: 1.35; color: var(--muted); }
.hero-me .btn { margin-top: 12px; width: 100%; }
.ht-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 2px; }
.ht-list li { display: grid; grid-template-columns: 22px 1fr auto; gap: 8px; align-items: center; padding: 6px 4px; border-radius: 8px; font-size: 14px; }
.ht-list li.me { background: var(--accent-soft); }
.ht-rank { font: 600 12px/1 var(--mono); color: var(--muted); }
.ht-list li:nth-child(1) .ht-rank { color: #c98a00; }
.ht-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.ht-val { font: 600 13px/1 var(--mono); color: var(--accent); font-variant-numeric: tabular-nums; }
.ht-empty { display: block !important; color: var(--muted); font-size: 13px; }
.ht-more { display: inline-block; margin-top: 10px; font-size: 13px; color: var(--accent); text-decoration: none; font-weight: 600; }

/* стрим */
.live-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #111; border: 1px solid var(--line); }
.live-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #e5372b; margin-right: 6px; vertical-align: 1px; animation: livePulse 1.4s ease-in-out infinite; }
@keyframes livePulse { 50% { box-shadow: 0 0 0 5px rgba(229, 55, 43, 0); opacity: .6; } 0%, 100% { box-shadow: 0 0 0 0 rgba(229, 55, 43, .5); } }
.nav a.nav-live { display: inline-flex; align-items: center; color: #e5372b; font-weight: 700; }

/* пузырьки-бонусы */
.bubbles { position: absolute; inset: 0; pointer-events: none; z-index: 4; }
.bubble { position: absolute; width: 74px; height: 74px; margin: -37px 0 0 -37px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; pointer-events: auto;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .95) 0 9%, rgba(255, 255, 255, .25) 22%, rgba(214, 245, 226, .35) 55%, rgba(15, 125, 67, .55) 100%);
  box-shadow: inset 0 0 14px rgba(255, 255, 255, .7), 0 10px 26px -10px rgba(15, 125, 67, .6); color: #0b5f33; font: 800 17px/1 var(--display);
  animation: bubIn .35s cubic-bezier(.2, 1.5, .4, 1), bubFloat 1.6s ease-in-out .35s infinite alternate; touch-action: manipulation; }
.bubble span { pointer-events: none; text-shadow: 0 1px 0 #fff; }
.bubble::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 3px solid rgba(15, 125, 67, .55);
  clip-path: inset(0 0 0 0); animation: bubTimer var(--life, 3.5s) linear forwards; }
.bubble.popped { animation: bubPop .4s ease-out forwards; pointer-events: none; }
.bubble.gone { animation: bubGone .3s ease-in forwards; pointer-events: none; }
@keyframes bubIn { from { transform: scale(0); } to { transform: scale(1); } }
@keyframes bubFloat { from { transform: translateY(0); } to { transform: translateY(-10px); } }
@keyframes bubTimer { from { opacity: 1; transform: scale(1); } to { opacity: .15; transform: scale(.82); } }
@keyframes bubPop { 0% { transform: scale(1); opacity: 1; } 60% { transform: scale(1.35); opacity: .6; } 100% { transform: scale(1.6); opacity: 0; } }
@keyframes bubGone { to { transform: scale(.4); opacity: 0; } }
@media (max-width: 560px) { .bubble { width: 64px; height: 64px; margin: -32px 0 0 -32px; font-size: 15px; } }

.nav a { white-space: nowrap; }

/* пауза */
.pause-btn { position: absolute; z-index: 6; top: 14px; right: 14px; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, .85);
  display: none; place-items: center; cursor: pointer; box-shadow: 0 6px 18px -10px rgba(0, 0, 0, .35); }
.pause-btn span { width: 12px; height: 14px; border-left: 4px solid var(--ink); border-right: 4px solid var(--ink); }
.stage[data-state="playing"] .pause-btn { display: grid; }
.pause-screen { position: absolute; inset: 0; z-index: 7; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: rgba(246, 244, 240, .72); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); cursor: default; }
.pause-screen[hidden] { display: none; }
.ps-title { margin: 0; font: 900 clamp(40px, 8vw, 72px)/1 var(--display); letter-spacing: -.03em; }
.ps-sub { margin: 0; font-size: 13px; color: var(--muted); }
.stage[data-state="paused"] .bubble, .stage[data-state="paused"] .bubble::after { animation-play-state: paused; }
.stage[data-state="paused"] .hud { opacity: 1; }

.x-link { color: var(--ink); }
.x-link:hover { color: #000; }
@media (max-width: 440px) { .brand-name { display: none; } .top-actions { gap: 6px; } }

/* анонс стрима на Twitch */
.stream-bar { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 8px 16px; background: #f3edff; border-bottom: 1px solid #ddd0ff; color: #2b1561; font-size: 14px; }
.stream-bar[hidden] { display: none; }
.stb-logo { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: #9146ff; color: #fff; flex: none; }
.stb-dot { width: 8px; height: 8px; border-radius: 50%; background: #9146ff; flex: none; animation: livePulse 1.6s ease-in-out infinite; }
.stream-bar.is-live .stb-dot { background: #e5372b; }
.stb-text { margin: 0; }
.stb-text b { font-weight: 800; }
.stb-when { margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: #fff; border: 1px solid #ddd0ff; font: 600 12px/1.4 var(--mono); color: #5b2fc9; white-space: nowrap; }
.stream-bar.is-live .stb-when { color: #e5372b; border-color: #f6c3bf; }
.stb-btn { flex: none; padding: 6px 14px; border-radius: 8px; background: #9146ff; color: #fff; font-weight: 700; text-decoration: none; font-size: 13px; }
.stb-btn:hover { background: #7c2ff0; }
@media (max-width: 560px) { .stream-bar { gap: 8px; padding: 7px 12px; font-size: 13px; justify-content: space-between; } .stb-dot { display: none; } .stb-text b { display: block; } .stb-when { margin: 2px 0 0; display: inline-block; } }
/* пока висит плашка стрима — первый экран короче на её высоту, чтобы всё влезало без прокрутки */
body:has(.stream-bar:not([hidden])) .stage { height: calc(100vh - 104px); height: calc(100svh - 104px); }
@media (max-width: 560px) { body:has(.stream-bar:not([hidden])) .stage { height: calc(100svh - 128px); } }

/* ═══ вариант «тёмная комната»: первый экран тёмный, освещает только лампа сверху ═══ */
html.hero-dark .top { background: rgba(14, 12, 10, .92); border-bottom-color: #2a241d; }
html.hero-dark .brand-name { color: #f4ede2; }
html.hero-dark .brand .chip { background: transparent; color: #cfc4b3; border-color: #3a3127; }
html.hero-dark .nav a { color: #cbbfae; }
html.hero-dark .nav a:hover { color: #fff; }
html.hero-dark .nav a.nav-sol { background: rgba(20, 241, 149, .1); color: #8ff0bf; border-color: rgba(20, 241, 149, .28); }
html.hero-dark .top .btn.ghost { background: transparent; color: #eadfcd; border-color: #3a3127; }
html.hero-dark .top .btn.ghost:hover { border-color: #8a7a64; }
html.hero-dark .x-link { color: #eadfcd; }
html.hero-dark .stream-bar { background: #1a1325; border-bottom-color: #2d2140; color: #e7dcff; }
html.hero-dark .stb-when { background: #241a35; border-color: #3b2b57; color: #c8b0ff; }
html.hero-dark .stage { background: #0c0a08; color: #f2ebe0; }
/* свет лампы на «стенах»: сверху по центру ярко, к краям — полумрак */
html.hero-dark .stage::before { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background: radial-gradient(ellipse 34% 62% at 50% -6%, rgba(255, 214, 160, .42) 0%, rgba(255, 196, 130, .16) 45%, rgba(255, 190, 120, 0) 100%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(255, 200, 140, .07), transparent 70%); }
/* внизу — плавный переход в светлую страницу */
html.hero-dark .stage::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 48px; pointer-events: none; z-index: 1; background: linear-gradient(180deg, transparent, var(--bg)); }
html.hero-dark .scene3d { z-index: 1; }
html.hero-dark .glow { display: none; }
html.hero-dark .intro h1 { color: #fbf5ea; text-shadow: 0 2px 30px rgba(0, 0, 0, .6); }
html.hero-dark .intro p { color: #c9bda9; }
html.hero-dark .intro p b { color: #fbf5ea; }
html.hero-dark .sol-badge { background: rgba(20, 241, 149, .08); border-color: rgba(20, 241, 149, .3); color: #e8fff3; box-shadow: 0 0 30px -8px rgba(20, 241, 149, .35); }
html.hero-dark .sol-badge b { color: #fff; }
html.hero-dark .sol-badge .sb-label { color: #3ee8a0; }
html.hero-dark .sol-badge .sb-text { color: #a6dcc2; }
html.hero-dark .sol-badge .sb-arrow { color: #3ee8a0; }
html.hero-dark .prize-pill { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .16); color: #f2ebe0; }
html.hero-dark .prize-pill .pp-label { color: #6fe0a6; }
html.hero-dark .prize-pill .pp-time { color: #b9ad99; }
html.hero-dark .hud, html.hero-dark .balance { color: #fbf5ea; }
html.hero-dark .hud .eyebrow, html.hero-dark .meta, html.hero-dark .mult-next span { color: #b9ad99; }
html.hero-dark .mn-bar { background: rgba(255, 255, 255, .12); }
html.hero-dark .hint { color: #f2ebe0; }
html.hero-dark .hint-sub { color: #9d917e; }
html.hero-dark .hero-side { background: rgba(22, 19, 15, .72); border-color: #2f281f; color: #f2ebe0; box-shadow: 0 18px 50px -20px rgba(0, 0, 0, .8); }
html.hero-dark .hero-side .eyebrow, html.hero-dark .hm-sub, html.hero-dark .ht-rank { color: #9d917e; }
html.hero-dark .ht-list li.me { background: rgba(20, 241, 149, .1); }
html.hero-dark .pause-btn { background: rgba(30, 26, 21, .85); border-color: #3a3127; }
html.hero-dark .pause-btn span { border-color: #f2ebe0; }
html.hero-dark .wind { color: #cbbfae; }

html.hero-dark .intro, html.hero-dark .hints, html.hero-dark .hud { position: absolute; z-index: 2; }   /* текст над лучом — читается */
html.hero-dark .intro h1 .tk, html.hero-dark .balance-tk, html.hero-dark .hm-value .tk { color: #35d683; }
html.hero-dark .ht-val { color: #35d683; }
html.hero-dark .stage::after { height: 110px; background: linear-gradient(180deg, rgba(247, 247, 244, 0), rgba(247, 247, 244, .35) 45%, var(--bg)); }
html.hero-dark .intro p, html.hero-dark .hint-sub, html.hero-dark .sol-badge .sb-text { text-shadow: 0 0 10px rgba(12, 10, 8, .95), 0 0 2px rgba(12, 10, 8, .9); }
html.hero-dark .stage::after { height: 34px; background: linear-gradient(180deg, rgba(247, 247, 244, 0), var(--bg)); }
html.hero-dark .hints { bottom: clamp(30px, 5vh, 46px); }

/* ═══ вариант «серый сайт»: лампа над страницей. Широкий тусклый свет освещает весь сайт,
   узкий яркий круг — на хлебе (его рисует 3D). Края страницы уходят в серый полумрак. ═══ */
html.site-gray { --bg: #8e8b86; --ink-2: #2f3237; --muted: #4f545b; --line: rgba(20, 18, 14, .14); --line-2: rgba(20, 18, 14, .22); --surface: rgba(250, 247, 242, .9); }
html.site-gray body { background: #8e8b86; }
html.site-gray body::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 46% 70% at 50% -12%, rgba(255, 246, 228, .78) 0%, rgba(255, 240, 216, .5) 38%, rgba(255, 236, 210, 0) 80%),
    radial-gradient(ellipse 95% 130% at 50% -20%, rgba(255, 240, 220, .45) 0%, rgba(255, 236, 214, .18) 55%, rgba(255, 236, 214, 0) 100%),
    linear-gradient(180deg, #a19d97 0%, #85827d 100%); }
html.site-gray .top { background: rgba(214, 209, 201, .82); border-bottom-color: rgba(20, 18, 14, .12); }
html.site-gray .stage { background: transparent; }
html.site-gray .glow { display: none; }
html.site-gray .stream-bar { background: rgba(236, 228, 255, .72); }
html.site-gray .hero-side { background: rgba(250, 247, 242, .82); }
html.site-gray .foot { background: transparent; }
html.site-gray .sol-band { box-shadow: 0 30px 80px -40px rgba(0, 0, 0, .45); }
/* белая тема со «фонариком»: фон чуть серее, чтобы белое пятно света читалось */
.stage.light-spot { background: radial-gradient(ellipse 60% 55% at 50% 30%, #f4f3f0 0%, #e6e5e1 60%, #dcdbd6 100%); }
/* узкие телефоны: длинные подписи кнопок переносятся, а не вылезают за экран */
@media (max-width: 420px) {
  .sol-actions .btn, .ticket-actions .btn { white-space: normal; height: auto; min-height: 46px; padding: 12px 16px; text-align: center; width: 100%; }
  .sol-top > * { min-width: 0; }
}

/* предупреждение: пришёл со страницы чужой монеты */
.ref-warn { position: relative; padding: 14px 52px 14px 20px; background: #b4231a; color: #fff; text-align: center; }
.ref-warn[hidden] { display: none; }
.rw-title { margin: 0; font-weight: 800; font-size: 16px; }
.rw-sub { margin: 4px 0 0; font-size: 14px; opacity: .92; word-break: break-word; }
.rw-close { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px; border: 0; border-radius: 8px; background: rgba(255, 255, 255, .15); color: #fff; font-size: 20px; cursor: pointer; }

.flash.err { background: #b4231a; box-shadow: 0 12px 30px -10px rgba(180, 35, 26, .5); }
