/* ЖАБА — премиум-казино тема, мобильная вёрстка (базовая ширина 380px), без библиотек.
   Анимации только на transform/opacity (60fps), prefers-reduced-motion учтён внизу. */

:root {
  --bg0: #070c0a;
  --card: rgba(23, 33, 28, 0.55);
  --card2: rgba(11, 19, 15, 0.72);
  --border: rgba(255, 255, 255, 0.08);
  --text: #eaf4ee;
  --muted: #8fa39a;
  --green: #22c55e;
  --green-soft: #4ade80;
  --gold: #f6bf26;
  --gold-soft: #fde68a;
  --red: #f87171;
  --radius: 20px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background:
    radial-gradient(55% 34% at 50% 0%, rgba(34, 197, 94, 0.16), transparent 70%),
    radial-gradient(70% 45% at 50% 40%, rgba(34, 197, 94, 0.06), transparent 70%),
    radial-gradient(42% 30% at 88% 86%, rgba(246, 191, 38, 0.05), transparent 70%),
    linear-gradient(180deg, #0a100e 0%, #070b0a 55%, #05080a 100%);
  background-attachment: fixed;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100vh;
}

#app {
  max-width: 420px;
  margin: 0 auto;
  padding: 12px 14px 10px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.hidden { display: none !important; }

/* ================= Верхняя панель ================= */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 0 10px;
}

.balance-box {
  background: var(--card);
  backdrop-filter: blur(14px) saturate(1.25);
  -webkit-backdrop-filter: blur(14px) saturate(1.25);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  padding: 5px 14px;
  min-height: 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.balance-label {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.3px;
}

.balance-value {
  font-size: 18px;
  font-weight: 800;
  color: var(--gold-soft);
  text-shadow: 0 0 16px rgba(246, 191, 38, 0.35);
  font-variant-numeric: tabular-nums;
}

.topbar-actions { display: flex; gap: 8px; }

/* ================= Кнопки (тап-таргеты ≥48px) ================= */
.btn {
  position: relative;
  min-height: 48px;
  padding: 0 16px;
  border: none;
  border-radius: 14px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 0.06s ease, opacity 0.15s ease, filter 0.15s ease;
}

.btn:active { transform: scale(0.97); }

.btn:disabled {
  opacity: 0.4;
  filter: saturate(0.5);
  cursor: default;
}

.btn-ghost {
  background: rgba(21, 32, 25, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  font-size: 14px;
}

/* Переключатель языка — компактный, в стиле ghost-кнопок */
.lang-select {
  min-height: 48px;
  padding: 0 10px;
  border-radius: 14px;
  background: rgba(21, 32, 25, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
  appearance: none;
  -webkit-appearance: none;
}

.lang-select:focus-visible {
  outline: 2px solid rgba(74, 222, 128, 0.6);
  outline-offset: 1px;
}

.lang-select option {
  background: #0d1611;
  color: #e8f3e8;
}

.btn-primary {
  background: linear-gradient(180deg, #43e07f 0%, #17a44c 100%);
  color: #052b12;
  box-shadow: 0 6px 22px rgba(34, 197, 94, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.btn-cashout {
  background: linear-gradient(180deg, #ffdf70 0%, #eda311 100%);
  color: #2b1c02;
  box-shadow: 0 6px 22px rgba(245, 158, 11, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.btn-big {
  width: 100%;
  min-height: 56px;
  font-size: 18px;
  border-radius: 16px;
}

/* Пульс кнопки «Кормить» — только opacity на псевдоэлементе (дёшево) */
#btn-feed::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: inherit;
  box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.45), 0 0 26px rgba(74, 222, 128, 0.45);
  opacity: 0;
  pointer-events: none;
}

#btn-feed:not(:disabled)::after { animation: feedPulse 1.5s ease-in-out infinite; }

@keyframes feedPulse {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

/* ================= Плашка тест-режима ================= */
.test-banner {
  background: rgba(251, 191, 36, 0.10);
  border: 1px solid rgba(251, 191, 36, 0.30);
  color: #fcd34d;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  padding: 9px 10px;
  border-radius: 12px;
  margin-bottom: 12px;
}

/* ================= Экран ставки ================= */
.game-title {
  font-size: 27px;
  font-weight: 800;
  text-align: center;
  margin-top: 2px;
  letter-spacing: -0.5px;
  background: linear-gradient(180deg, #f2fff7, #9fe8bb);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--text);
}

.game-sub {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  margin-top: 4px;
  line-height: 1.45;
}

.toad-idle {
  display: flex;
  justify-content: center;
  margin: 12px 0 4px;
  animation: bob 2.6s ease-in-out infinite;
}

.toad-idle svg,
.toad-idle img { width: 120px; height: auto; display: block; }

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.bet-card {
  background: var(--card);
  backdrop-filter: blur(16px) saturate(1.25);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 12px 34px rgba(0, 0, 0, 0.35);
  border-radius: var(--radius);
  padding: 16px 14px;
  margin-top: 12px;
}

.preset-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.preset {
  min-height: 48px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(21, 32, 25, 0.7);
  color: var(--text);
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 0.06s ease, border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.preset:active { transform: scale(0.95); }

.preset.active {
  border-color: var(--green);
  background: rgba(34, 197, 94, 0.14);
  color: var(--green-soft);
  box-shadow: 0 0 14px rgba(34, 197, 94, 0.25);
}

.bet-label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin: 14px 0 6px;
}

#bet-input {
  width: 100%;
  height: 52px;
  background: rgba(9, 16, 13, 0.8);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 20px;
  font-weight: 700;
  text-align: center;
  outline: none;
  -moz-appearance: textfield;
  appearance: textfield;
  margin-bottom: 14px;
}

#bet-input:focus {
  border-color: rgba(74, 222, 128, 0.5);
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.12);
}

#bet-input::-webkit-outer-spin-button,
#bet-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* ================= Игровой экран ================= */
.stage {
  position: relative;
  background: var(--card);
  backdrop-filter: blur(16px) saturate(1.25);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 12px 34px rgba(0, 0, 0, 0.35);
  border-radius: var(--radius);
  padding: 16px 14px 20px;
  text-align: center;
  overflow: hidden;
}

.round-chip {
  display: inline-block;
  font-size: 12px;
  color: var(--muted);
  background: var(--card2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 7px 12px;
  font-variant-numeric: tabular-nums;
}

.toad-wrap {
  height: 210px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Светящийся пьедестал за жабой — растёт с кормлениями (--toad-scale из JS) */
.toad-circle {
  --toad-scale: 1;
  width: 172px;
  height: 172px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 40%,
    rgba(74, 222, 128, 0.30), rgba(34, 197, 94, 0.10) 52%, transparent 72%);
  box-shadow: 0 0 60px rgba(34, 197, 94, 0.16);
  transform: scale(var(--toad-scale));
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toad { display: flex; align-items: center; justify-content: center; }

#toad { transform-origin: 50% 92%; }

#toad svg,
#toad img { width: 152px; height: auto; display: block; }

.toad-img { user-select: none; -webkit-user-select: none; }

/* ---------- SVG-жаба: риг стадий раздувания ---------- */
.toad-svg { overflow: visible; }

.toad-svg .body-main,
.toad-svg .belly,
.toad-svg .pupil,
.toad-svg .drop,
.toad-svg .burst {
  transform-box: fill-box;
  transform-origin: center;
}

.toad-svg .body-main {
  transform-origin: 50% 88%;
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toad-svg .belly {
  transform-origin: 50% 72%;
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toad-svg .pupil { transition: transform 0.3s ease; }
.toad-svg .brows { opacity: 0; transition: opacity 0.3s ease; }
.toad-svg .mouth-worry { opacity: 0; transition: opacity 0.25s ease; }
.toad-svg .mouth-smile { opacity: 1; transition: opacity 0.25s ease; }
.toad-svg .drop { opacity: 0; }

#toad.stage-2 .body-main { transform: scale(1.03, 1.02); }
#toad.stage-2 .belly { transform: scale(1.08, 1.06); }
#toad.stage-3 .body-main { transform: scale(1.06, 1.045); }
#toad.stage-3 .belly { transform: scale(1.16, 1.12); }
#toad.stage-4 .body-main { transform: scale(1.09, 1.07); }
#toad.stage-4 .belly { transform: scale(1.24, 1.18); }
#toad.stage-5 .body-main { transform: scale(1.12, 1.09); }
#toad.stage-5 .belly { transform: scale(1.33, 1.24); }
#toad.stage-6 .body-main { transform: scale(1.16, 1.12); }
#toad.stage-6 .belly { transform: scale(1.42, 1.31); }

#toad.stage-4 .brows,
#toad.stage-5 .brows,
#toad.stage-6 .brows { opacity: 1; }

#toad.stage-4 .mouth-worry,
#toad.stage-5 .mouth-worry,
#toad.stage-6 .mouth-worry { opacity: 1; }

#toad.stage-4 .mouth-smile,
#toad.stage-5 .mouth-smile,
#toad.stage-6 .mouth-smile { opacity: 0; }

#toad.stage-4 .pupil { transform: scale(0.85); }
#toad.stage-5 .pupil { transform: scale(0.7); }
#toad.stage-6 .pupil { transform: scale(0.55); }

#toad.stage-5 .drop-1 { animation: drip 1.3s ease-in infinite; }
#toad.stage-5 .drop-2 { animation: drip 1.3s ease-in 0.55s infinite; }
#toad.stage-6 .drop-1 { animation: drip 0.9s ease-in infinite; }
#toad.stage-6 .drop-2 { animation: drip 0.9s ease-in 0.3s infinite; }
#toad.stage-6 .drop-3 { animation: drip 0.9s ease-in 0.6s infinite; }

@keyframes drip {
  0% { opacity: 0; transform: translateY(0); }
  20% { opacity: 1; }
  100% { opacity: 0; transform: translateY(15px); }
}

/* Тряска жабы нарастает со стадиями (на вложенном svg/img, чтобы не мешать gulp) */
#toad.stage-4 > * { --tr: 0.7px; animation: tremble 0.5s linear infinite; }
#toad.stage-5 > * { --tr: 1.2px; animation: tremble 0.34s linear infinite; }
#toad.stage-6 > * { --tr: 1.9px; animation: tremble 0.22s linear infinite; }

@keyframes tremble {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  25% { transform: translate(var(--tr), calc(-1 * var(--tr))) rotate(0.5deg); }
  50% { transform: translate(calc(-1 * var(--tr)), var(--tr)) rotate(-0.5deg); }
  75% { transform: translate(var(--tr), var(--tr)) rotate(0.3deg); }
}

/* Squash-and-stretch «проглатывание» при кормлении */
#toad.gulp { animation: gulp 0.5s cubic-bezier(0.36, 1.2, 0.5, 1); }

@keyframes gulp {
  0% { transform: scale(1, 1); }
  30% { transform: scale(1.15, 0.82); }
  60% { transform: scale(0.93, 1.1); }
  82% { transform: scale(1.04, 0.97); }
  100% { transform: scale(1, 1); }
}

/* Взрыв: SVG-звезда раскрывается */
.toad-svg-boom .burst { animation: burstIn 0.5s cubic-bezier(0.2, 1.4, 0.4, 1) forwards; }

@keyframes burstIn {
  0% { transform: scale(0.15); opacity: 0; }
  55% { transform: scale(1.18); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

.stage.shake { animation: shake 0.55s ease; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  12% { transform: translateX(-9px) rotate(-0.7deg); }
  28% { transform: translateX(8px) rotate(0.6deg); }
  44% { transform: translateX(-7px); }
  60% { transform: translateX(6px); }
  76% { transform: translateX(-4px); }
  90% { transform: translateX(2px); }
}

/* ---------- Множитель ---------- */
.mult {
  font-size: 52px;
  font-weight: 900;
  letter-spacing: -1.5px;
  margin-top: 6px;
  color: var(--green-soft);
  background: linear-gradient(180deg, #eafff2, #4ade80 70%, #22c55e);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 14px rgba(74, 222, 128, 0.30));
  transition: filter 0.4s ease;
  font-variant-numeric: tabular-nums;
}

.mult.mult-hot {
  color: var(--gold);
  background-image: linear-gradient(180deg, #fff7d6, #fbbf24 60%, #f59e0b);
  filter: drop-shadow(0 0 18px rgba(251, 191, 36, 0.5));
}

.mult.mult-fire {
  color: var(--red);
  background-image: linear-gradient(180deg, #ffe4e6, #fb7185 55%, #ef4444);
  filter: drop-shadow(0 0 20px rgba(248, 113, 113, 0.55));
}

.mult.pop { animation: multPop 0.3s ease; }

@keyframes multPop {
  0% { transform: scale(1); }
  40% { transform: scale(1.14); }
  100% { transform: scale(1); }
}

.cash-now {
  margin-top: 6px;
  font-size: 16px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.next-info {
  margin-top: 5px;
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.stage.win-flash { animation: winFlash 1.1s ease; }

@keyframes winFlash {
  0% { box-shadow: 0 0 0 0 rgba(246, 191, 38, 0); }
  30% { box-shadow: 0 0 52px 8px rgba(246, 191, 38, 0.35); }
  100% { box-shadow: none; }
}

.float-win {
  position: absolute;
  left: 50%;
  top: 36%;
  transform: translate(-50%, 14px);
  font-size: 36px;
  font-weight: 800;
  color: var(--gold-soft);
  text-shadow: 0 2px 20px rgba(246, 191, 38, 0.55);
  pointer-events: none;
  animation: floatUp 1.1s ease-out forwards;
  font-variant-numeric: tabular-nums;
  z-index: 6;
}

@keyframes floatUp {
  0% { opacity: 0; transform: translate(-50%, 14px); }
  20% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -62px); }
}

/* ---------- Частицы (взрыв и монетное конфетти) ---------- */
.fx-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 5;
}

.boom-p {
  position: absolute;
  left: 50%;
  top: 40%;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  opacity: 0;
  animation: boomFly 0.85s cubic-bezier(0.15, 0.85, 0.4, 1) forwards;
}

@keyframes boomFly {
  0% { transform: translate(-50%, -50%); opacity: 1; }
  70% { opacity: 1; }
  100% {
    transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) rotate(var(--rot)) scale(0.35);
    opacity: 0;
  }
}

.coin-p {
  position: absolute;
  top: -20px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #ffefad, #f7c948 55%, #cf8a08);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35), 0 0 10px rgba(251, 191, 36, 0.45);
  opacity: 0;
  animation-name: coinFall;
  animation-timing-function: cubic-bezier(0.45, 0.05, 0.8, 0.5);
  animation-fill-mode: forwards;
}

@keyframes coinFall {
  0% { transform: translateY(0) rotate(0deg); opacity: 0; }
  8% { opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateY(370px) rotate(var(--spin)); opacity: 0; }
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

/* ================= Карточка результата ================= */
.result-card {
  background: var(--card);
  backdrop-filter: blur(16px) saturate(1.25);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 18px 20px;
  text-align: center;
  animation: popIn 0.3s ease;
}

@keyframes popIn {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.result-emoji {
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
}

.result-emoji svg,
.result-emoji img { width: 150px; height: auto; display: block; }

.result-title {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 6px;
  font-variant-numeric: tabular-nums;
}

.result-text {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 18px;
}

.result-win {
  border-color: rgba(246, 191, 38, 0.35);
  box-shadow: 0 0 44px rgba(246, 191, 38, 0.12);
}

.result-win .result-title {
  color: var(--gold-soft);
  text-shadow: 0 0 18px rgba(246, 191, 38, 0.4);
}

.result-win .result-emoji svg,
.result-win .result-emoji img {
  filter: drop-shadow(0 0 22px rgba(246, 191, 38, 0.35));
}

.result-bust {
  border-color: rgba(248, 113, 113, 0.35);
  box-shadow: 0 0 40px rgba(248, 113, 113, 0.10);
}

.result-bust .result-title { color: var(--red); }

/* ================= Лента событий ================= */
.events { margin-top: 18px; }

.events-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
}

.events-list {
  list-style: none;
  background: var(--card);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 4px 14px;
  max-height: 236px;
  overflow-y: auto;
}

.ev {
  display: flex;
  align-items: baseline;
  gap: 4px;
  padding: 11px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 14px;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

.ev:last-child { border-bottom: none; }

.ev-new { animation: evIn 0.45s ease; }

@keyframes evIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}

.ev-ico { flex: none; font-size: 14px; }

.ev-name { font-weight: 700; }

.ev-cash .ev-amt { color: var(--gold-soft); font-weight: 700; }

.ev-bust .ev-text { color: var(--red); }

.ev-empty { color: var(--muted); }

/* ================= Подвал ================= */
.footer {
  margin-top: 16px;
  padding-bottom: 10px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

/* ================= Модалка «Честность» ================= */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(3, 7, 6, 0.66);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 12px;
  z-index: 50;
}

.modal-body {
  width: 100%;
  max-width: 420px;
  max-height: 86vh;
  overflow-y: auto;
  background: rgba(16, 26, 21, 0.88);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 -12px 40px rgba(0, 0, 0, 0.4);
  border-radius: 20px;
  padding: 18px 16px;
  animation: sheetUp 0.25s ease;
}

@keyframes sheetUp {
  from { transform: translateY(24px); opacity: 0.5; }
  to { transform: none; opacity: 1; }
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.modal-head h2 { font-size: 20px; font-weight: 800; }

.fair-text {
  font-size: 13px;
  line-height: 1.5;
  color: #b8d4c5;
  background: rgba(34, 197, 94, 0.07);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  word-break: break-word;
}

.fair-field { margin-bottom: 13px; }

.fair-field > span,
.fair-field > label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 5px;
}

.fair-field code {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  word-break: break-all;
  background: rgba(9, 16, 13, 0.8);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px 10px;
  color: #a7f3d0;
}

.seed-row { display: flex; gap: 8px; }

.seed-row input {
  flex: 1;
  min-width: 0;
  height: 48px;
  background: rgba(9, 16, 13, 0.8);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
  padding: 0 12px;
  outline: none;
}

.seed-row input:focus { border-color: rgba(74, 222, 128, 0.5); }

.hint { font-size: 12px; margin-top: 6px; color: var(--muted); min-height: 15px; }

.hint.err { color: var(--red); }

.hint.ok { color: var(--green-soft); }

.fair-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}

.fair-table th {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-align: left;
  padding: 7px 4px;
  border-bottom: 1px solid var(--border);
}

.fair-table td {
  padding: 7px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.fair-table .num { text-align: right; }

/* ================= Тост ================= */
.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translate(-50%, 12px);
  max-width: 90vw;
  background: rgba(24, 37, 31, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  font-size: 14px;
  text-align: center;
  padding: 12px 18px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 60;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ================= Доступность: минимум движения ================= */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
