/* Spaceman краш-игра — кастомные стили */

html { scroll-behavior: smooth; }
body { font-family: 'Inter', system-ui, -apple-system, sans-serif; }

/* Дисплейный шрифт для заголовков */
.font-display { font-family: 'Russo One', 'Inter', sans-serif; letter-spacing: 0.02em; }

/* Hero блок */
.hero-bg {
  background:
    radial-gradient(circle at 20% 30%, rgba(255,204,42,0.18) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(108,82,247,0.15) 0%, transparent 50%),
    linear-gradient(135deg, #1a1530 0%, #2b1d4d 50%, #1a1530 100%);
  position: relative;
  overflow: hidden;
}

.hero-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(2px 2px at 20% 30%, white, transparent),
    radial-gradient(1px 1px at 60% 70%, white, transparent),
    radial-gradient(1.5px 1.5px at 80% 20%, white, transparent),
    radial-gradient(1px 1px at 40% 80%, white, transparent),
    radial-gradient(2px 2px at 90% 50%, white, transparent);
  background-size: 200px 200px, 150px 150px, 250px 250px, 100px 100px, 180px 180px;
  opacity: 0.4;
  animation: starsFloat 60s linear infinite;
}

@keyframes starsFloat {
  from { transform: translateY(0); }
  to { transform: translateY(-200px); }
}

/* Карточка контента */
.content-card {
  background: #FFFFFF;
  border: 1px solid #ECEAF3;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(23, 22, 29, 0.04);
}

/* Желтый акцент */
.accent-yellow { background: #FFCC2A; color: #17161D; }

/* CTA-кнопка */
.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: #17161D;
  color: #ffffff;
  font-weight: 700;
  padding: 14px 30px;
  border-radius: 12px;
  transition: all 0.25s ease;
  text-decoration: none;
  box-shadow: 0 6px 20px rgba(23,22,29,0.18);
}
.btn-cta:hover {
  background: #000;
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(23,22,29,0.25);
}
.btn-cta i { color: #FFCC2A; }

.btn-cta-yellow {
  background: #FFCC2A;
  color: #17161D;
}
.btn-cta-yellow:hover { background: #FFD955; }
.btn-cta-yellow i { color: #17161D; }

/* Таблица сравнения */
.compare-table { width: 100%; border-collapse: collapse; }
.compare-table th, .compare-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid #ECEAF3;
  font-size: 0.95rem;
}
.compare-table th {
  background: #F3F2F7;
  color: #17161D;
  font-weight: 700;
}
.compare-table tr:hover td { background: #FFFBEE; }

/* Pros / Cons */
.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
@media (max-width: 768px) { .pros-cons { grid-template-columns: 1fr; } }
.pros-box { background: #F0FDF4; border-left: 4px solid #16a34a; border-radius: 12px; padding: 1.25rem 1.5rem; }
.cons-box { background: #FEF2F2; border-left: 4px solid #dc2626; border-radius: 12px; padding: 1.25rem 1.5rem; }
.pros-box li, .cons-box li { padding: 6px 0; display: flex; gap: 10px; }
.pros-box li::before { content: '✓'; color: #16a34a; font-weight: 700; }
.cons-box li::before { content: '✕'; color: #dc2626; font-weight: 700; }

/* FAQ */
.faq-item { background: #FFFFFF; border: 1px solid #ECEAF3; border-radius: 12px; overflow: hidden; }
.faq-q { width: 100%; text-align: left; padding: 1rem 1.25rem; background: transparent; cursor: pointer; display: flex; justify-content: space-between; align-items: center; font-weight: 600; color: #17161D; }
.faq-q:hover { background: #FFFBEE; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.3s ease, padding 0.3s ease; padding: 0 1.25rem; color: #4a4a5a; line-height: 1.7; }
.faq-item.open .faq-a { max-height: 600px; padding: 0 1.25rem 1.25rem 1.25rem; }
.faq-icon { transition: transform 0.25s ease; }

/* Tag/Chip */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  background: #FFCC2A;
  color: #17161D;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Содержание (TOC) */
.toc-box {
  background: #F3F2F7;
  border-radius: 16px;
  padding: 1.5rem;
  border-left: 4px solid #FFCC2A;
}
.toc-box ol { counter-reset: toc; }
.toc-box li { counter-increment: toc; padding: 5px 0; }
.toc-box li::marker { color: #FFCC2A; font-weight: 700; }
.toc-box a { color: #17161D; }
.toc-box a:hover { color: #6c52f7; text-decoration: underline; }

/* Промокод бейдж */
.promo-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #FFCC2A 0%, #FFD955 100%);
  color: #17161D;
  padding: 10px 20px;
  border-radius: 12px;
  font-weight: 700;
  border: 2px dashed #17161D;
}
.promo-code {
  font-family: 'Russo One', monospace;
  letter-spacing: 0.1em;
  font-size: 1.1rem;
  background: #17161D;
  color: #FFCC2A;
  padding: 4px 12px;
  border-radius: 6px;
}

/* Информационные блоки */
.info-box {
  background: linear-gradient(135deg, #FFFBEE 0%, #FFF6D6 100%);
  border-left: 4px solid #FFCC2A;
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
}
.info-box i { color: #FFCC2A; }

/* Картинки */
.figure-block {
  margin: 2rem 0;
  text-align: center;
}
.figure-block img {
  max-width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(23,22,29,0.10);
}
.figure-block figcaption {
  margin-top: 0.75rem;
  color: #6b6b7a;
  font-size: 0.9rem;
  font-style: italic;
}

/* Шаги (как играть) */
.step-card {
  background: #FFFFFF;
  border: 1px solid #ECEAF3;
  border-radius: 14px;
  padding: 1.5rem;
  position: relative;
  transition: all 0.25s ease;
}
.step-card:hover {
  border-color: #FFCC2A;
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(23,22,29,0.08);
}
.step-number {
  position: absolute;
  top: -16px;
  left: 1.5rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #FFCC2A;
  color: #17161D;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  border: 3px solid #FFFFFF;
}

/* Демо-плейсхолдер */
.demo-placeholder {
  background: linear-gradient(135deg, #1a1530 0%, #2b1d4d 50%, #1a1530 100%);
  border-radius: 20px;
  min-height: 460px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  border: 2px solid #FFCC2A;
}
.demo-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(2px 2px at 20% 30%, white, transparent), radial-gradient(1px 1px at 70% 60%, white, transparent), radial-gradient(2px 2px at 50% 80%, white, transparent);
  background-size: 250px 250px;
  opacity: 0.4;
}

.float-anim { animation: floatY 4s ease-in-out infinite; }
@keyframes floatY { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }

/* Анимация прозрачности */
.fade-in { animation: fadeIn 0.8s ease-out both; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* Текст: типографика для длинных статей */
.prose-article h2 {
  font-family: 'Russo One', 'Inter', sans-serif;
  font-size: 1.85rem;
  color: #17161D;
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
  line-height: 1.25;
  scroll-margin-top: 100px;
}
.prose-article h3 {
  font-family: 'Inter', sans-serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: #17161D;
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
}
.prose-article p {
  font-size: 1.02rem;
  line-height: 1.75;
  color: #2f2e3a;
  margin-bottom: 1rem;
}
.prose-article ul, .prose-article ol {
  margin: 1rem 0 1.25rem 1.5rem;
  line-height: 1.75;
}
.prose-article ul li { list-style: disc; margin-bottom: 6px; color: #2f2e3a; }
.prose-article ol li { list-style: decimal; margin-bottom: 6px; color: #2f2e3a; }
.prose-article strong { color: #17161D; font-weight: 700; }
.prose-article a { color: #6c52f7; font-weight: 600; }
.prose-article a:hover { text-decoration: underline; }
.prose-article blockquote {
  border-left: 4px solid #FFCC2A;
  background: #FFFBEE;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  border-radius: 8px;
  font-style: italic;
  color: #4a4a5a;
}

@media (max-width: 768px) {
  .prose-article h2 { font-size: 1.5rem; }
  .prose-article h3 { font-size: 1.2rem; }
  .prose-article p { font-size: 1rem; }
}

/* Картинки в тексте */
.inline-img-right {
  float: right;
  max-width: 320px;
  margin: 0 0 1rem 1.5rem;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(23,22,29,0.10);
}
.inline-img-left {
  float: left;
  max-width: 320px;
  margin: 0 1.5rem 1rem 0;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(23,22,29,0.10);
}
@media (max-width: 768px) {
  .inline-img-right, .inline-img-left {
    float: none;
    max-width: 100%;
    margin: 1.25rem auto;
    display: block;
  }
}

/* Сетка преимуществ */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.feature-card {
  background: #FFFFFF;
  border: 1px solid #ECEAF3;
  border-radius: 14px;
  padding: 1.5rem;
  transition: all 0.25s ease;
}
.feature-card:hover {
  border-color: #FFCC2A;
  box-shadow: 0 10px 28px rgba(23,22,29,0.08);
  transform: translateY(-3px);
}
.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #FFCC2A;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: #17161D;
  margin-bottom: 1rem;
}

/* Утилиты */
.container-narrow { max-width: 980px; margin-left: auto; margin-right: auto; }

/* Heatmap multipliers (декоративный нижний бар) */
.mult-bar {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  padding: 8px 0;
  scrollbar-width: none;
}
.mult-bar::-webkit-scrollbar { display: none; }
.mult-chip {
  flex-shrink: 0;
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  color: white;
}
.mult-yellow { background: #f59e0b; color: #17161D; }
.mult-purple { background: #7c3aed; }
.mult-blue { background: #2563eb; }
.mult-pink { background: #db2777; }

/* ============================================================
   ВЕРСИЯ 2.0 — ИНТЕРАКТИВ, ТЁМНАЯ ТЕМА, АНИМАЦИИ
   ============================================================ */

/* ---------- CSS-переменные / тёмная тема ---------- */
:root {
  --bg: #FFFFFF;
  --bg-soft: #F3F2F7;
  --bg-card: #FFFFFF;
  --text: #17161D;
  --text-soft: #555;
  --text-muted: #777;
  --accent: #FFCC2A;
  --dark: #17161D;
  --border: #ECEAF3;
  --shadow: 0 4px 20px rgba(23, 22, 29, 0.04);
  --shadow-lg: 0 20px 50px rgba(23, 22, 29, 0.12);
}
[data-theme="dark"] {
  --bg: #0F0E1A;
  --bg-soft: #1B1932;
  --bg-card: #18172A;
  --text: #F5F4FA;
  --text-soft: #BDBBC9;
  --text-muted: #8C8A9E;
  --border: #2A2845;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.5);
}
[data-theme="dark"] body { background: var(--bg); color: var(--text); }
[data-theme="dark"] header.bg-\[\#FFCC2A\] { background: var(--accent) !important; }
[data-theme="dark"] .content-card { background: var(--bg-card); border-color: var(--border); }
[data-theme="dark"] .toc-box { background: var(--bg-soft); border-color: var(--border); }
[data-theme="dark"] .info-box { background: var(--bg-soft); border-color: var(--border); color: var(--text); }
[data-theme="dark"] .compare-table th { background: var(--bg-soft); color: var(--text); }
[data-theme="dark"] .compare-table td { color: var(--text); border-color: var(--border); }
[data-theme="dark"] .feature-card,
[data-theme="dark"] .step-card { background: var(--bg-card); border-color: var(--border); color: var(--text); }
[data-theme="dark"] .feature-card h3,
[data-theme="dark"] .step-card h3 { color: var(--text); }
[data-theme="dark"] .feature-card p,
[data-theme="dark"] .step-card p { color: var(--text-soft); }
[data-theme="dark"] .faq-item { background: var(--bg-card); border-color: var(--border); }
[data-theme="dark"] .faq-q { color: var(--text); }
[data-theme="dark"] .faq-a { color: var(--text-soft); }
[data-theme="dark"] .prose-article p,
[data-theme="dark"] .prose-article li { color: var(--text-soft); }
[data-theme="dark"] .prose-article h2,
[data-theme="dark"] .prose-article h3 { color: var(--text); }
[data-theme="dark"] .prose-article blockquote { background: var(--bg-soft); color: var(--text); }
[data-theme="dark"] .bg-\[\#F3F2F7\] { background: var(--bg-soft) !important; }
[data-theme="dark"] .text-\[\#17161D\]:not(header *) { color: var(--text); }
[data-theme="dark"] .text-gray-600 { color: var(--text-soft) !important; }
[data-theme="dark"] nav[aria-label="Хлебные крошки"] { background: var(--bg-soft); border-color: var(--border); }
[data-theme="dark"] footer { background: var(--bg-card); color: var(--text); }
[data-theme="dark"] body.bg-white { background: var(--bg) !important; }

/* ---------- Прогресс-бар чтения ---------- */
.read-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, #FFCC2A, #FF6B6B, #FFCC2A);
  background-size: 200% 100%;
  z-index: 9999;
  transition: width 0.1s ease-out;
  animation: gradMove 3s linear infinite;
}
@keyframes gradMove {
  0% { background-position: 0% 0%; }
  100% { background-position: 200% 0%; }
}

/* ---------- Scroll-to-top ---------- */
.scroll-top {
  position: fixed;
  bottom: 24px; right: 24px;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--dark);
  color: var(--accent);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px);
  transition: all 0.3s;
  z-index: 100;
  font-size: 18px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}
.scroll-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.scroll-top:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,0,0,0.3); }

/* ---------- Theme toggle ---------- */
.theme-toggle {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(23,22,29,0.1);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #17161D;
  transition: all 0.25s;
}
.theme-toggle:hover { background: rgba(23,22,29,0.2); transform: rotate(15deg); }

/* ---------- Reveal-анимации ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}
[data-reveal="left"] { transform: translateX(-40px); }
[data-reveal="left"].revealed { transform: translateX(0); }
[data-reveal="right"] { transform: translateX(40px); }
[data-reveal="right"].revealed { transform: translateX(0); }
[data-reveal="scale"] { transform: scale(0.92); }
[data-reveal="scale"].revealed { transform: scale(1); }

/* ---------- Симулятор краш-игры ---------- */
.crash-sim {
  background: linear-gradient(135deg, #0a0a23 0%, #1a1a3e 100%);
  border-radius: 20px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255,204,42,0.2);
  box-shadow: var(--shadow-lg);
  color: #fff;
}
.crash-sim-canvas-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #0a0a23;
}
.crash-sim canvas {
  width: 100%;
  height: 100%;
  display: block;
}
.crash-sim-controls {
  padding: 16px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 640px) {
  .crash-sim-controls { grid-template-columns: 1fr 1fr; }
}
.crash-sim-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.crash-sim label {
  font-size: 12px;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}
.crash-sim input[type="number"] {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 16px;
  width: 100%;
  font-weight: 600;
  outline: none;
  transition: all 0.2s;
}
.crash-sim input[type="number"]:focus {
  border-color: #FFCC2A;
  background: rgba(255,204,42,0.08);
}
.crash-sim-btn {
  flex: 1;
  padding: 14px 20px;
  border-radius: 10px;
  font-weight: 800;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.crash-sim-btn.start { background: #2ecc71; color: #fff; }
.crash-sim-btn.start:hover:not(:disabled) { background: #27ae60; transform: translateY(-1px); }
.crash-sim-btn.cashout { background: #FFCC2A; color: #17161D; }
.crash-sim-btn.cashout:hover:not(:disabled) { background: #FFD84D; transform: translateY(-1px); }
.crash-sim-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.crash-sim-stats {
  background: rgba(0,0,0,0.3);
  padding: 12px 16px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  font-size: 14px;
}
.crash-sim-stats > div { display: flex; flex-direction: column; gap: 2px; }
.crash-sim-stats span:first-child { color: #888; font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; }
.crash-sim-stats span:last-child { font-weight: 800; font-size: 18px; color: #FFCC2A; }
.crash-sim-stats .profit-pos { color: #2ecc71 !important; }
.crash-sim-stats .profit-neg { color: #e74c3c !important; }
.crash-sim-history {
  display: flex;
  gap: 6px;
  padding: 10px 16px;
  background: rgba(0,0,0,0.2);
  flex-wrap: wrap;
  border-top: 1px solid rgba(255,255,255,0.05);
  min-height: 42px;
  align-items: center;
}
.crash-sim-history:empty::before {
  content: 'История раундов появится здесь';
  color: #555;
  font-size: 12px;
  font-style: italic;
}

/* ---------- Калькулятор стратегий ---------- */
.strategy-calc {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  box-shadow: var(--shadow);
}
.calc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 768px) {
  .calc-grid { grid-template-columns: 1fr 1fr; }
}
.calc-field { display: flex; flex-direction: column; gap: 6px; }
.calc-field label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.calc-field input[type="number"],
.calc-field input[type="range"] {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 600;
  outline: none;
  width: 100%;
}
.calc-field input[type="number"]:focus {
  border-color: var(--accent);
  background: var(--bg);
}
.calc-field input[type="range"] {
  padding: 0;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.calc-field input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px; height: 22px;
  background: var(--accent);
  border: 3px solid var(--dark);
  border-radius: 50%;
  cursor: pointer;
}
.calc-field input[type="range"]::-moz-range-thumb {
  width: 22px; height: 22px;
  background: var(--accent);
  border: 3px solid var(--dark);
  border-radius: 50%;
  cursor: pointer;
}

.calc-results {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
}
@media (min-width: 768px) {
  .calc-results { grid-template-columns: repeat(5, 1fr); }
}
.calc-result {
  background: var(--bg-soft);
  padding: 14px 16px;
  border-radius: 12px;
  text-align: center;
  border: 1px solid var(--border);
}
.calc-result-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 6px;
  font-weight: 700;
}
.calc-result-value {
  font-size: 22px;
  font-weight: 900;
  color: var(--text);
  font-family: 'Russo One', sans-serif;
}
.calc-result-value.positive { color: #16a34a; }
.calc-result-value.negative { color: #dc2626; }

/* ---------- Лента "live wins" ---------- */
.live-feed {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  max-height: 480px;
  overflow-y: auto;
  padding-right: 6px;
}
@media (min-width: 640px) {
  .live-feed { grid-template-columns: 1fr 1fr; }
}
.feed-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  transition: transform 0.2s, box-shadow 0.2s;
  animation: feedAppear 0.5s ease-out;
}
.feed-item:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
@keyframes feedAppear {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
.feed-name { font-weight: 700; font-size: 14px; color: var(--text); }
.feed-city { color: var(--text-muted); font-weight: 500; font-size: 12px; }
.feed-meta { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.feed-result { text-align: right; }
.feed-mult {
  font-family: 'Russo One', sans-serif;
  font-size: 16px;
  color: #FFCC2A;
  background: rgba(255,204,42,0.15);
  padding: 2px 8px;
  border-radius: 6px;
  display: inline-block;
}
.feed-win {
  font-weight: 800;
  color: #16a34a;
  font-size: 13px;
  margin-top: 4px;
}
.live-feed-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.live-dot {
  width: 10px; height: 10px;
  background: #e74c3c;
  border-radius: 50%;
  animation: livePulse 1.5s infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.7); }
  50% { opacity: 0.7; transform: scale(1.2); box-shadow: 0 0 0 8px rgba(231, 76, 60, 0); }
}

/* ---------- Sticky CTA ---------- */
.sticky-cta {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(120%);
  background: linear-gradient(135deg, #17161D, #2a2640);
  color: #fff;
  padding: 14px 20px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
  z-index: 90;
  width: calc(100% - 32px);
  max-width: 560px;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid rgba(255,204,42,0.3);
}
.sticky-cta.show { transform: translateX(-50%) translateY(0); }
.sticky-cta-icon {
  width: 44px; height: 44px;
  background: #FFCC2A;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #17161D;
  font-size: 22px;
  flex-shrink: 0;
}
.sticky-cta-text { flex: 1; min-width: 0; }
.sticky-cta-title {
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 2px;
}
.sticky-cta-timer {
  font-family: 'Russo One', sans-serif;
  color: #FFCC2A;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.sticky-cta-btn {
  background: #FFCC2A;
  color: #17161D;
  font-weight: 800;
  padding: 10px 18px;
  border-radius: 10px;
  text-decoration: none;
  white-space: nowrap;
  font-size: 14px;
  transition: transform 0.15s;
}
.sticky-cta-btn:hover { transform: scale(1.05); }
.sticky-cta-close {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  font-size: 18px;
  padding: 4px 8px;
  flex-shrink: 0;
}
.sticky-cta-close:hover { color: #fff; }

/* Алиасы для разметки renderUiAddons */
.sticky-cta-inner { display: contents; }
.sticky-cta-text strong {
  display: block; font-weight: 800; font-size: 14px; margin-bottom: 2px;
}
.sticky-cta-text span {
  display: block; font-size: 12px; color: #c9c4d8;
}
.sticky-countdown {
  font-family: 'Russo One', 'Inter', sans-serif;
  color: #FFCC2A;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

@media (max-width: 480px) {
  .sticky-cta { gap: 10px; padding: 12px 14px; }
  .sticky-cta-icon { width: 36px; height: 36px; font-size: 16px; }
  .sticky-cta-title { font-size: 13px; }
  .sticky-cta-btn { padding: 8px 12px; font-size: 13px; }
}

/* ---------- Cookie / 18+ баннер ---------- */
.cookie-banner {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  max-width: 480px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  box-shadow: var(--shadow-lg);
  z-index: 95;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: cookieSlide 0.5s ease;
}
@keyframes cookieSlide { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.cookie-banner.hidden { display: none; }
.cookie-banner-title {
  font-weight: 800;
  font-size: 15px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.cookie-banner-text {
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.5;
}
.cookie-banner-actions { display: flex; gap: 8px; }
.cookie-btn {
  flex: 1;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
}
.cookie-btn.primary,
.cookie-btn-primary { background: #17161D; color: #FFCC2A; }
.cookie-btn.primary:hover,
.cookie-btn-primary:hover { background: #000; }
.cookie-btn.secondary,
.cookie-btn-secondary { background: var(--bg-soft, #F3F2F7); color: var(--text, #17161D); }

/* HTML использует .cookie-banner-inner + .cookie-banner-text как контейнеры */
.cookie-banner-inner { display: flex; flex-direction: column; gap: 12px; }
.cookie-banner-text { display: block; }
.cookie-banner-text strong { display: block; font-weight: 800; font-size: 15px; color: var(--text, #17161D); margin-bottom: 4px; }
.cookie-banner-text span { display: block; font-size: 13px; color: var(--text-soft, #6b7280); line-height: 1.5; }

/* Плавное закрытие */
.cookie-banner { transition: transform .35s ease, opacity .35s ease; }
.cookie-banner.hidden { display: none !important; }

/* ---------- FAQ улучшения ---------- */
.faq-search {
  width: 100%;
  padding: 12px 16px 12px 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E") 14px center no-repeat;
  background-size: 18px;
  font-size: 15px;
  margin-bottom: 16px;
  color: var(--text);
  outline: none;
  transition: all 0.2s;
}
.faq-search:focus { border-color: var(--accent); background-color: var(--bg); }

.faq-item .faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding-top: 0;
  padding-bottom: 0;
}
.faq-item.open .faq-a {
  max-height: 800px;
  padding-top: 12px;
  padding-bottom: 4px;
}
.faq-item .faq-q::after {
  content: '+';
  transition: transform 0.3s;
  font-size: 24px;
  font-weight: 300;
}
.faq-item.open .faq-q::after { transform: rotate(45deg); }

/* ---------- Промокод копирование ---------- */
[data-copy] { transition: all 0.2s; user-select: all; }
[data-copy].copied { background: #2ecc71 !important; color: #fff !important; }
[data-copy]:hover { filter: brightness(1.1); }

/* ---------- Топ выигрышей ---------- */
.top-wins {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
.top-win-item {
  display: grid;
  grid-template-columns: 40px 1fr auto auto;
  gap: 14px;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 16px;
  border-radius: 14px;
  transition: all 0.3s;
}
.top-win-item:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.top-win-item.gold { background: linear-gradient(135deg, #FFCC2A22, transparent); border-color: #FFCC2A; }
.top-win-rank {
  font-family: 'Russo One', sans-serif;
  font-size: 24px;
  color: var(--text-muted);
  text-align: center;
}
.top-win-item.gold .top-win-rank { color: #FFCC2A; font-size: 28px; }
.top-win-info { min-width: 0; }
.top-win-name { font-weight: 700; font-size: 15px; color: var(--text); }
.top-win-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.top-win-mult {
  font-family: 'Russo One', sans-serif;
  background: var(--bg-soft);
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text);
}
.top-win-item.gold .top-win-mult { background: #FFCC2A; color: #17161D; }
.top-win-amount {
  font-weight: 800;
  color: #16a34a;
  font-family: 'Russo One', sans-serif;
  font-size: 16px;
  text-align: right;
}
@media (max-width: 540px) {
  .top-win-item { grid-template-columns: 32px 1fr auto; }
  .top-win-amount { grid-column: 2 / 4; text-align: right; margin-top: 2px; }
}

/* ---------- Hover эффект на логотипе ---------- */
header a[aria-label*="Spaceman"] img {
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
header a[aria-label*="Spaceman"]:hover img {
  transform: scale(1.08) rotate(-3deg);
}

/* ---------- Карточки с парящим эффектом ---------- */
.float-card {
  animation: floatY 5s ease-in-out infinite;
}
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---------- Утилиты ---------- */
.glow-yellow { box-shadow: 0 0 30px rgba(255, 204, 42, 0.4); }
.gradient-text {
  background: linear-gradient(90deg, #FFCC2A, #FF6B6B, #FFCC2A);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradMove 4s linear infinite;
}

/* ---------- Параллакс для hero ---------- */
.hero-bg::before { transform: translateY(var(--parallax, 0)); }

/* ---------- Уменьшение анимаций при prefers-reduced-motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* === v2 add-ons: copy-btn, promo-code button, faq-search wrap, not-prose === */
.copy-btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: #17161D; color: #FFCC2A;
  padding: 0.65rem 1rem; border-radius: 0.6rem;
  font-weight: 700; font-family: 'JetBrains Mono', ui-monospace, monospace;
  border: 0; cursor: pointer; transition: all .2s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
.copy-btn code { background: transparent; color: inherit; padding: 0; font: inherit; }
.copy-btn:hover { transform: translateY(-2px); box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.copy-btn.copied,
[data-copy].copied { background: #2ecc71 !important; color: #fff !important; }
[data-theme="dark"] .copy-btn { background: #FFCC2A; color: #17161D; }
[data-theme="dark"] .copy-btn:hover { background: #ffd84a; }

button.promo-code {
  display: inline-flex; align-items: center; gap: 0.45rem;
  border: 1px dashed #FFCC2A;
  background: rgba(255, 204, 42, 0.18);
  color: #FFCC2A; font-weight: 700;
  padding: 0.2rem 0.6rem; border-radius: 0.45rem;
  cursor: pointer; transition: all .2s ease;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  white-space: nowrap;
  vertical-align: baseline;
  line-height: 1.3;
  font-size: 0.95em;
}
button.promo-code:hover {
  background: #FFCC2A;
  color: #17161D;
  border-style: solid;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 204, 42, 0.35);
}
button.promo-code.copied { background: #2ecc71; color: #fff; border-color: #2ecc71; border-style: solid; }
button.promo-code i { font-size: .8em; opacity: .7; }

/* На светлом фоне (внутри prose-article) — тёмный текст */
.prose-article button.promo-code {
  color: #17161D;
  background: rgba(255, 204, 42, 0.22);
}
.prose-article button.promo-code:hover { color: #17161D; }
[data-theme="dark"] .prose-article button.promo-code {
  color: #FFCC2A;
  background: rgba(255, 204, 42, 0.15);
}

/* === Кастомное выделение текста (вместо стандартного синего) === */
::selection {
  background: #FFCC2A;
  color: #17161D;
  text-shadow: none;
}
::-moz-selection {
  background: #FFCC2A;
  color: #17161D;
  text-shadow: none;
}
[data-theme="dark"] ::selection {
  background: #FFCC2A;
  color: #17161D;
}
[data-theme="dark"] ::-moz-selection {
  background: #FFCC2A;
  color: #17161D;
}

.faq-search-wrap { margin-bottom: 1rem; }
.not-prose { /* отключаем prose-typography для калькулятора */ }
.prose-article .not-prose * { color: inherit; }
.prose-article .strategy-calc label { font-weight: 600; font-size: .85rem; }
.prose-article .strategy-calc input { font-family: inherit; }
.prose-article .strategy-result-label { color: var(--text-muted, #6b7280); font-size: .8rem; }

/* live-dot пульсация (если ещё нет) */
@keyframes live-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(46,204,113,.7); }
  50% { box-shadow: 0 0 0 8px rgba(46,204,113,0); }
}
