/* ============================================================
   VoltWin — Roulette (web)
   ============================================================ */

:root {
  --bg: #16110d;
  --bg-elevated: #1c1611;
  --panel: #201a15;
  --panel-2: #241d17;
  --panel-border: rgba(255, 255, 255, 0.14);
  --border: rgba(255, 255, 255, 0.08);
  --text: #f5f0ea;
  --text-muted: #8c887f;
  --text-dim: #b8b3aa;

  --orange-1: #ffc02e;
  --orange-2: #ff9d00;
  --orange-3: #e6720e;
  --orange-4: #7a3300;
  --orange-glow: rgba(255, 157, 0, 0.45);

  --green: #21e065;
  --green-bg: rgba(33, 224, 101, 0.12);
  --red: #ff4757;
  --red-bg: rgba(255, 71, 87, 0.12);
  --blue: #2f8bfd;

  --tile-teal-1: #35e6d6;
  --tile-teal-2: #0a8f8a;
  --tile-amber-1: #ffd35c;
  --tile-amber-2: #d98a12;
  --tile-cyan-1: #6fd0ff;
  --tile-cyan-2: #1c7fd4;
  --tile-purple-1: #c084fc;
  --tile-purple-2: #7c2dd6;
  --tile-lime-1: #d3f26a;
  --tile-lime-2: #7ba823;
  --tile-pink-1: #ff8fc6;
  --tile-pink-2: #d63b8e;

  /* Bright, punchy tile background colors — same hues as before, just routed
     through their own variables so the shared golden top-glow (below) can
     layer on top for a bit of brand cohesion without dulling them down. */
  --tile-bg-teal-1: #3ef0df;
  --tile-bg-teal-2: #0aa79f;
  --tile-bg-amber-1: #ffd35c;
  --tile-bg-amber-2: #d9860f;
  --tile-bg-cyan-1: #6fd0ff;
  --tile-bg-cyan-2: #1c7fd4;
  --tile-bg-purple-1: #c084fc;
  --tile-bg-purple-2: #7c2dd6;
  --tile-bg-lime-1: #d3f26a;
  --tile-bg-lime-2: #7ba823;
  --tile-bg-pink-1: #ff8fc6;
  --tile-bg-pink-2: #d63b8e;

  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  --font: "Poppins", "Inter", system-ui, -apple-system, sans-serif;
  --shadow-card: 0 18px 40px -20px rgba(0, 0, 0, 0.7);
  --shadow-card-lg: 0 30px 70px -24px rgba(0, 0, 0, 0.75);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 1280px;
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.4;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(38% 34% at 10% -6%, rgba(255, 157, 0, 0.14), transparent 68%),
    radial-gradient(30% 28% at 92% 4%, rgba(47, 139, 253, 0.09), transparent 68%),
    radial-gradient(36% 30% at 60% 104%, rgba(33, 224, 101, 0.06), transparent 68%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
}

svg {
  display: block;
  flex-shrink: 0;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}

a {
  text-decoration: none;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

::selection {
  background: var(--orange-2);
  color: #2a1300;
}

a, button, input, textarea, select {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--orange-1);
  outline-offset: 2px;
  border-radius: 6px;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  border-radius: 8px;
}

.icon {
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── shared surfaces ── */

.surface {
  background: var(--panel);
  border: 1px solid var(--panel-border);
}

.gold-text {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.btn-gold {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  overflow: hidden;
  border-radius: var(--radius-xs);
  background: linear-gradient(180deg, var(--orange-1) 0%, var(--orange-2) 55%, var(--orange-3) 100%);
  border: 1px solid rgba(255, 220, 150, 0.4);
  color: #2a1300;
  font-weight: 600;
  box-shadow:
    0 10px 24px -6px var(--orange-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -2px 4px rgba(90, 40, 0, 0.35);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
}

.btn-gold::before {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(110deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  animation: shine 3.6s ease-in-out infinite;
}

.btn-gold:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    0 14px 30px -6px var(--orange-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    inset 0 -2px 4px rgba(90, 40, 0, 0.35);
}

.btn-gold:active {
  transform: translateY(0);
  filter: brightness(0.98);
}

@keyframes shine {
  0%, 25% { left: -60%; }
  75%, 100% { left: 130%; }
}

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

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulseDot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.6); }
  50% { box-shadow: 0 0 0 5px rgba(255, 71, 87, 0); }
}

/* ============================================================
   Header
   ============================================================ */

.header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 74px;
  background: rgba(22, 17, 13, 0.85);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 12px 30px -16px rgba(0, 0, 0, 0.7);
}

.header__inner {
  max-width: 1880px;
  height: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
}

.header__group {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.header__inner > .header__group:first-child {
  justify-self: start;
}

.header__inner > .header__group:last-child {
  justify-self: end;
}

.header__group--center {
  justify-self: center;
}

.brand {
  display: flex;
  align-items: center;
}

.brand__logo {
  width: 232px;
  height: auto;
  flex-shrink: 0;
}

.room-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
}

.room-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 128px;
  height: 52px;
  padding: 6px 18px;
  border-radius: var(--radius-xs);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.room-tab:hover {
  border-color: rgba(255, 157, 0, 0.35);
}

.room-tab__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
  white-space: nowrap;
  transition: color 0.15s ease;
}

.room-tab__bet {
  font-size: 11px;
  font-weight: 500;
  line-height: 1.2;
  color: var(--text-muted);
  white-space: nowrap;
}

.room-tab.is-active {
  border-color: rgba(255, 157, 0, 0.5);
  background: radial-gradient(120% 140% at 50% 50%, rgba(255, 157, 0, 0.14), transparent 70%), var(--panel);
  box-shadow: 0 0 0 1px var(--orange-1), 0 8px 20px -8px var(--orange-glow);
}

.room-tab.is-active .room-tab__name {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.room-tab.is-active .room-tab__bet {
  color: var(--text-dim);
}

.bonus-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 20px 0 16px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.bonus-chip--lg {
  height: 52px;
  padding: 0 24px 0 18px;
  gap: 12px;
}

.bonus-chip--lg .bonus-chip__label {
  font-size: 17px;
}

.bonus-chip__gift {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--orange-1);
  filter: drop-shadow(0 0 6px var(--orange-glow));
}

.bonus-chip__label {
  font-size: 14px;
  color: var(--text-dim);
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  color: #2a1300;
  box-shadow: 0 4px 12px -2px var(--orange-glow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.icon-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 16px -2px var(--orange-glow);
}

.lang-dropdown {
  position: relative;
  flex-shrink: 0;
}

.flag-chip {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: visible;
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.flag-chip:hover {
  border-color: rgba(255, 157, 0, 0.3);
}

.lang-dropdown.is-open .flag-chip {
  border-color: rgba(255, 157, 0, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 157, 0, 0.12);
}

.flag-chip__flag {
  transform: translateY(0.5px);
}

.chip-arrow {
  transition: transform 0.2s ease;
}

.lang-dropdown.is-open .chip-arrow {
  transform: rotate(180deg);
}

.lang-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 208px;
  padding: 8px;
  margin: 0;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card-lg), 0 0 0 1px rgba(255, 157, 0, 0.06);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px) scale(0.97);
  transform-origin: top right;
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
  z-index: 40;
}

.lang-dropdown.is-open .lang-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.lang-menu::before {
  content: "";
  position: absolute;
  top: -6px;
  right: 16px;
  width: 12px;
  height: 12px;
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  border-top: 1px solid var(--border);
  transform: rotate(45deg);
}

.lang-menu__title {
  padding: 6px 10px 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.lang-menu__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 10px;
  border-radius: 9px;
  font-size: 14px;
  color: var(--text-dim);
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease;
}

.lang-menu__item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.lang-menu__flag {
  font-size: 26px;
  line-height: 1;
  width: 30px;
  text-align: center;
  flex-shrink: 0;
}

.lang-menu__name {
  flex: 1;
  min-width: 0;
}

.lang-menu__check {
  width: 16px;
  height: 16px;
  color: var(--orange-1);
  opacity: 0;
  flex-shrink: 0;
  transform: scale(0.6);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.lang-menu__item.is-active {
  color: var(--text);
  background: rgba(255, 157, 0, 0.08);
}

.lang-menu__item.is-active .lang-menu__check {
  opacity: 1;
  transform: scale(1);
}

.chip-arrow {
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--panel-2);
  border: 2px solid var(--bg);
  display: grid;
  place-items: center;
  color: var(--text-muted);
}

.chip-arrow .icon {
  width: 8px;
  height: 8px;
  stroke-width: 2.4;
}

.search-btn {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  color: var(--text-muted);
  transition: color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.search-btn:hover {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
  transform: translateY(-1px);
}

.notif-dropdown {
  position: relative;
  flex-shrink: 0;
}

.bell-btn {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--text-dim);
  flex-shrink: 0;
  transition: color 0.15s ease, transform 0.15s ease;
}

.bell-btn:hover {
  color: var(--text);
}

.bell-btn__dot {
  position: absolute;
  top: 10px;
  right: 11px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
  animation: pulseDot 2.2s ease-out infinite;
}

/* Notifications dropdown */

.notif-dropdown.is-open .bell-btn {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
}

.notif-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 360px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card-lg), 0 0 0 1px rgba(255, 157, 0, 0.06);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px) scale(0.97);
  transform-origin: top right;
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
  z-index: 40;
  overflow: hidden;
}

.notif-dropdown.is-open .notif-panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.notif-panel::before {
  content: "";
  position: absolute;
  top: -6px;
  right: 18px;
  width: 12px;
  height: 12px;
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  border-top: 1px solid var(--border);
  transform: rotate(45deg);
}

.notif-panel__head {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.notif-panel__count {
  display: grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: var(--radius-pill);
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  color: #2a1300;
  font-size: 12px;
  font-weight: 700;
}

.notif-panel__list {
  display: flex;
  flex-direction: column;
  max-height: 480px;
  overflow-y: auto;
  padding: 6px;
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.14s ease;
}

.notif-item:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.notif-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.notif-item__icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.notif-item__icon svg {
  width: 18px;
  height: 18px;
}

.notif-item__icon--system,
.notif-item__icon--coin,
.notif-item__icon--success,
.notif-item__icon--message,
.notif-item__icon--review {
  background: rgba(255, 157, 0, 0.14);
  color: var(--orange-1);
}

.notif-item__body {
  flex: 1;
  min-width: 0;
}

.notif-item__title {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.notif-item__unread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--green);
  box-shadow: 0 0 6px rgba(33, 224, 101, 0.65);
}

.notif-item__text {
  margin: 3px 0 5px;
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--text-muted);
}

.notif-item__time {
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.75;
}

.balance {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 6px 0 18px;
  border-radius: var(--radius-pill);
}

.balance__icon {
  color: var(--orange-1);
  flex-shrink: 0;
}

.balance__value {
  font-size: 17px;
  font-weight: 600;
  white-space: nowrap;
}

.balance__value .dim {
  color: var(--text-muted);
  font-weight: 400;
}

.profile {
  position: relative;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  cursor: pointer;
}

.profile img {
  width: 100%;
  height: 100%;
  border-radius: 10%;
  object-fit: cover;
  box-shadow: 0 0 0 2px var(--orange-2), 0 6px 16px -4px rgba(0, 0, 0, 0.6);
  transition: box-shadow 0.2s ease;
}

.profile:hover img {
  box-shadow: 0 0 0 2px var(--orange-1), 0 0 0 5px rgba(255, 157, 0, 0.25), 0 6px 16px -4px rgba(0, 0, 0, 0.6);
}

.profile .chip-arrow {
  background: var(--bg-elevated);
}

/* ============================================================
   Layout
   ============================================================ */

.layout {
  max-width: 1880px;
  margin: 0 auto;
  padding: 17px 24px 40px;
  display: grid;
  grid-template-columns: 232px 1fr;
  gap: 20px;
  align-items: start;
}

/* ============================================================
   Sidebar
   ============================================================ */

.sidebar {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: sticky;
  top: 91px;
}

.side-nav {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.side-nav + .side-nav {
  margin-top: 6px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* The empty divider-only .side-nav right before the social icons should sit
   as close to its own divider line as a normal menu item sits above its divider */
.side-nav:has(+ .side-social) {
  padding-top: 6px;
}

.side-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.side-social__item {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: var(--radius-sm);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.side-social__item:hover {
  color: var(--orange-1);
  border-color: rgba(255, 157, 0, 0.35);
  background: var(--panel-2);
  transform: translateY(-1px);
}

.side-social__item svg {
  width: 22px;
  height: 22px;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(22, 17, 13, 0.6);
}

.site-footer__inner {
  max-width: 1880px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  opacity: 0.7;
}

.site-footer__copy {
  white-space: nowrap;
}

.footer-lang-select {
  height: 30px;
  padding: 0 10px;
  border-radius: var(--radius-xs);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  color: var(--text-dim);
  font-family: inherit;
  font-size: 12px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.footer-lang-select:hover,
.footer-lang-select:focus-visible {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
}

.footer-lang-select option {
  background: var(--bg-elevated);
  color: var(--text);
}

.side-nav__item {
  position: relative;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 52px;
  padding: 0 16px;
  border-radius: var(--radius-xs);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  font-size: 15px;
  font-weight: 500;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.side-nav__item .icon {
  width: 20px;
  height: 20px;
  color: inherit;
}

.side-nav__item--play {
  font-size: 17px;
  font-weight: 700;
}

.side-nav__item--play .icon {
  width: 26px;
  height: 26px;
}

.side-nav__item:hover {
  color: var(--text);
  background: var(--panel-2);
  border-color: rgba(255, 255, 255, 0.14);
}

.side-nav__item:not(.side-nav__item--active)::before {
  content: "";
  position: absolute;
  left: -16px;
  top: 50%;
  width: 6px;
  height: 26px;
  border-radius: 3px;
  background: var(--text-muted);
  opacity: 0;
  transform: translateY(-50%) scaleY(0.4);
  transform-origin: center;
  transition: opacity 0.15s ease, transform 0.15s ease, background 0.15s ease;
}

.side-nav__item:not(.side-nav__item--active):hover::before {
  opacity: 1;
  transform: translateY(-50%) scaleY(1);
  background: var(--orange-2);
}

.side-nav__item--active {
  color: #2a1300;
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  border-color: rgba(255, 220, 150, 0.4);
  box-shadow: 0 10px 24px -8px var(--orange-glow), inset 0 1px 0 rgba(255, 255, 255, 0.4);
  transform: none;
}

.side-nav__item--active:hover {
  color: #2a1300;
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
}

.side-nav__item--active::before {
  content: "";
  position: absolute;
  left: -16px;
  top: 50%;
  width: 6px;
  height: 26px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  box-shadow: 0 0 10px var(--orange-glow);
  opacity: 0;
  transform: translateY(-50%) scaleY(0.4);
  transform-origin: center;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.side-nav__item--active:hover::before {
  opacity: 1;
  transform: translateY(-50%) scaleY(1);
}

/* ============================================================
   Main content
   ============================================================ */

.main {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

.main-top {
  display: grid;
  grid-template-columns: 1fr 292px;
  gap: 20px;
  align-items: stretch;
}

/* ── Bet panel ── */

.bet-card {
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-card);
}

.bet-tabs {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.bet-tab {
  position: relative;
  padding: 0 2px 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color 0.15s ease;
}

.bet-tab:hover {
  color: var(--text-dim);
}

.bet-tab.is-active {
  color: var(--text);
}

.bet-tab.is-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--orange-1), var(--orange-3));
  box-shadow: 0 0 8px var(--orange-glow);
}

.tab-panel {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.tab-panel[hidden] {
  display: none;
}

.field-row {
  display: flex;
  gap: 10px;
}

.field-row .field {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}


.field {
  margin-bottom: 16px;
}

.amount-box--compact {
  padding: 0 12px;
}

.field__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 10px;
  font-size: 14px;
}

.field__head span {
  font-weight: 500;
  color: var(--text-dim);
}

.amount-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 48px;
  padding: 0 8px 0 14px;
  border-radius: var(--radius-xs);
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.amount-box:hover,
.amount-box:focus-within {
  border-color: rgba(255, 157, 0, 0.4);
  box-shadow: 0 0 0 3px rgba(255, 157, 0, 0.1);
}

.amount-box__input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  outline: none;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  padding: 0;
}

.amount-box__actions {
  display: flex;
  gap: 4px;
}

.tag-btn {
  height: 30px;
  padding: 0 12px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 600;
  display: grid;
  place-items: center;
  transition: filter 0.15s ease, transform 0.15s ease;
}

.tag-btn:hover {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

.tag-btn--half { background: var(--green-bg); color: var(--green); }
.tag-btn--double { background: var(--red-bg); color: var(--red); }
.tag-btn--max {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  color: #2a1300;
  box-shadow: 0 4px 10px -2px var(--orange-glow);
}

.preset-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 22px;
}

.preset-row button {
  height: 34px;
  border-radius: var(--radius-xs);
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.preset-row button:hover {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
  transform: translateY(-1px);
}

.auto-note {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 10px;
  padding: 0 10px;
}

.auto-note__icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #ffd54a;
  filter: drop-shadow(0 0 6px rgba(255, 213, 74, 0.5));
}

.auto-note__text {
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-muted);
  text-align: center;
  padding: 2px 0;
}

.bet-card .btn-gold {
  margin-top: auto;
  height: 54px;
  font-size: 17px;
}

/* ── Game area ── */

.game-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card-lg), 0 0 0 1px rgba(255, 157, 0, 0.08);
  min-height: 100%;
  background:
    radial-gradient(60% 90% at 15% 0%, rgba(255, 157, 0, 0.1), transparent 70%),
    radial-gradient(50% 80% at 100% 100%, rgba(47, 139, 253, 0.08), transparent 70%),
    var(--panel);
}

.game-top {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 24px 0;
}

.game-top__players,
.game-top__timer,
.game-top__bank {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.game-top__players { justify-self: start; }
.game-top__timer {
  position: relative;
  justify-self: center;
  align-items: center;
  width: 90px;
  padding-bottom: 32px;
}
.game-top__bank { justify-self: end; align-items: flex-end; }

.game-top__label {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}

.game-top__value {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
  color: var(--text);
}

.game-top__value img {
  width: 20px;
  height: 20px;
  filter: drop-shadow(0 0 6px rgba(255, 200, 0, 0.5));
}

.game-top__value svg {
  width: 18px;
  height: 18px;
  color: var(--orange-1);
  flex-shrink: 0;
}

#gameTimer {
  /* Absolutely centered on the exact midline of .game-top__timer, regardless
     of font metrics — this is the only way to guarantee it lines up with the
     "ТАЙМЕР" label above it, no matter how either text renders. */
  position: absolute;
  top: 29px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--tile-teal-1);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

.bet-strip {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 2px;
  width: 100%;
  padding: 20px 8px 24px 8px;
}

.bet-tile {
  /* No padding here on purpose: container queries always measure the content box,
     so the query container must have zero padding for its thresholds to match the
     fragment's true edge-to-edge width. All spacing lives on .bet-tile__inner instead. */
  container-type: inline-size;
  position: relative;
  flex: 0 1 auto;
  min-width: 1%;
  height: 178px;
  padding: 0;
  overflow: visible;
  border-radius: var(--radius-xs);
  box-shadow: 0 14px 28px -12px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  animation: fadeUp 0.45s ease both;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.bet-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px -12px rgba(0, 0, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  z-index: 5;
}

.bet-tile__inner {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 5px 10px;
  transition: padding 0.15s ease;
}

.bet-tile__text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

/* Getting tight — drop the login and bet amount, but keep their slot reserved so the
   avatar and chance % stay exactly where they sit on full-size fragments */
@container (max-width: 84px) {
  .bet-tile__inner { padding-left: 2px; padding-right: 2px; }
  .bet-tile__text { visibility: hidden; }
}

/* Fragment is narrower than the standard 72px avatar + 4px — no room for it, drop the chance % too and just show the color */
@container (max-width: 75px) {
  .bet-tile__inner { padding-left: 0; padding-right: 0; }
  .bet-tile__avatar,
  .bet-tile__chance { display: none; }
}

.bet-tile--teal,
.bet-tile--amber,
.bet-tile--cyan,
.bet-tile--purple,
.bet-tile--lime,
.bet-tile--pink {
  /* Shared warm highlight glow at the top of every tile — ties all the
     different hues back to the same golden "light source" as the rest
     of the brand, instead of each color feeling like its own island. */
  background-image: radial-gradient(140% 70% at 50% -15%, rgba(255, 208, 130, 0.22), transparent 62%), linear-gradient(165deg, var(--tile-bg-1), var(--tile-bg-2));
}

.bet-tile--teal { --tile-bg-1: var(--tile-bg-teal-1); --tile-bg-2: var(--tile-bg-teal-2); }
.bet-tile--amber { --tile-bg-1: var(--tile-bg-amber-1); --tile-bg-2: var(--tile-bg-amber-2); }
.bet-tile--cyan { --tile-bg-1: var(--tile-bg-cyan-1); --tile-bg-2: var(--tile-bg-cyan-2); }
.bet-tile--purple { --tile-bg-1: var(--tile-bg-purple-1); --tile-bg-2: var(--tile-bg-purple-2); }
.bet-tile--lime { --tile-bg-1: var(--tile-bg-lime-1); --tile-bg-2: var(--tile-bg-lime-2); }
.bet-tile--pink { --tile-bg-1: var(--tile-bg-pink-1); --tile-bg-2: var(--tile-bg-pink-2); }

.bet-tile__avatar {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 6px 14px -4px rgba(0, 0, 0, 0.45);
}

.bet-tile__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bet-tile__amount {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 15px;
  font-weight: 800;
  color: #1a1206;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2);
}

.bet-tile__amount img {
  width: 14px;
  height: 14px;
}

.bet-tile__chance {
  width: 100%;
  height: 19px;
  flex-shrink: 0;
  margin-top: auto;
  border-radius: var(--radius-pill);
  background: rgba(0, 0, 0, 0.32);
}

.bet-tile__chance-value {
  display: block;
  text-align: center;
  line-height: 19px;
  font-size: 12px;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.85);
}

.bet-tile__name {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 100%;
  padding: 5px 6px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.35);
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
}

.bet-tile__name span {
  overflow: hidden;
  text-overflow: ellipsis;
}

.bet-tile__tooltip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 12px);
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  max-width: 220px;
  padding: 3px 14px 3px 8px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card-lg), 0 0 0 1px rgba(255, 157, 0, 0.06);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-50%) translateY(6px) scale(0.96);
  transform-origin: bottom center;
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
}

.bet-tile:hover .bet-tile__tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0) scale(1);
}

.bet-tile__tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  width: 11px;
  height: 11px;
  background: var(--bg-elevated);
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transform: translate(-50%, -55%) rotate(45deg);
}

.bet-tile__tooltip-avatar {
  width: 50px;
  height: 50px;
  flex-shrink: 0;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid rgba(255, 157, 0, 0.55);
}

.bet-tile__tooltip-body {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.bet-tile__tooltip-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bet-tile__tooltip-amount {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 700;
  color: var(--orange-1);
  white-space: nowrap;
}

.bet-tile__tooltip-amount img {
  width: 14px;
  height: 14px;
}

.bet-tile__tooltip-chance {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-dim);
  white-space: nowrap;
}

.bet-tile__name svg {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
  color: #ffd54a;
}

.boss-bar {
  display: flex;
  align-items: center;
  padding: 4px 20px;
  gap: 20px;
  border-radius: var(--radius-md);
}

.boss-bar__slot {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
  min-width: 0;
}

.boss-bar__stats {
  display: flex;
  align-items: center;
  gap: 26px;
  flex: 1;
  min-width: 0;
}

.boss-bar__info-btn {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  background: var(--panel-2);
  border: 1px solid var(--panel-border);
  color: var(--text-dim);
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.boss-bar__info-btn:hover {
  color: var(--orange-1);
  border-color: rgba(255, 157, 0, 0.35);
}

.boss-bar__info-btn svg {
  width: 17px;
  height: 17px;
}

.boss-bar__avatar {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  border-radius: 14px;
  object-fit: cover;
  border: 2px solid rgba(255, 157, 0, 0.55);
  box-shadow: 0 6px 14px -4px rgba(0, 0, 0, 0.45);
}

.boss-bar__info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.boss-bar__title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.boss-bar__title--current {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 14px var(--orange-glow);
}

.boss-bar__title--challenger {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 14px var(--orange-glow);
}

.boss-bar__login {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.boss-bar__slot--profit {
  flex: 1;
  justify-content: center;
  min-width: 0;
}

.boss-bar__slot--profit .boss-bar__info {
  align-items: center;
  text-align: center;
}

.boss-bar__slot--profit .boss-bar__title {
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 14px var(--orange-glow);
}

.boss-bar__slot--right {
  justify-content: flex-end;
}

.boss-bar__amount {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 17.25px;
  line-height: 1;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.boss-bar__amount .dim {
  color: var(--text-muted);
  font-weight: 400;
}

.boss-bar__amount img {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.boss-bar__divider {
  width: 1px;
  height: 46px;
  flex-shrink: 0;
  background: var(--border);
}

.boss-bar__streak {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 3px;
}

.boss-bar__flag {
  display: grid;
  place-items: center;
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  color: var(--text-muted);
  opacity: 0.45;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.boss-bar__flag svg {
  width: 100%;
  height: 100%;
}

.boss-bar__flag.is-won {
  color: var(--orange-1);
  opacity: 1;
  filter: drop-shadow(0 0 4px var(--orange-glow));
}

/* ── Results: winners table + new players ── */

.results-grid {
  display: grid;
  grid-template-columns: 1fr 292px;
  gap: 20px;
}

.results-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  animation: fadeUp 0.45s ease both;
}

.results-col--welcome { animation-delay: 0.06s; }

.results-head {
  height: 58px;
  border-radius: var(--radius-md);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  display: grid;
  grid-template-columns: 76px minmax(90px, 1.4fr) minmax(72px, 0.7fr) minmax(90px, 0.9fr) minmax(60px, 0.6fr) minmax(90px, 0.9fr);
  align-items: center;
  gap: 12px;
  /* Extra 8px on the right to match the width of .results-list's scrollbar,
     so right-aligned columns line up with the header exactly */
  padding: 0 28px 0 20px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.results-head--single {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-right: 20px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: normal;
  text-transform: none;
  color: var(--text);
}

.results-head__toggle {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  background: var(--panel-2);
  border: 1px solid var(--panel-border);
  color: var(--text-dim);
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.results-head__toggle:hover {
  color: var(--orange-1);
  border-color: rgba(255, 157, 0, 0.35);
}

.results-head__icon {
  width: 17px;
  height: 17px;
}

.results-head__icon--users { display: none; }

.results-col--welcome.is-payouts .results-head__icon--wallet { display: none; }
.results-col--welcome.is-payouts .results-head__icon--users { display: block; }

.results-body {
  border-radius: var(--radius-md);
  overflow: hidden;
  flex: 1;
  box-shadow: var(--shadow-card);
}

.results-list {
  display: flex;
  flex-direction: column;
  height: 648px;
  overflow-y: hidden;
}

.results-row {
  display: grid;
  grid-template-columns: 76px minmax(90px, 1.4fr) minmax(72px, 0.7fr) minmax(90px, 0.9fr) minmax(60px, 0.6fr) minmax(90px, 0.9fr);
  align-items: center;
  gap: 12px;
  height: 54px;
  padding: 0 20px;
  transition: background 0.15s ease;
}

.results-row:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.results-row:hover {
  background: rgba(255, 255, 255, 0.035);
}

.results-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 14px;
  color: var(--text-dim);
}

.results-cell--num {
  justify-content: center;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
  white-space: nowrap;
}

.results-cell--winner {
  color: var(--text);
  font-weight: 500;
}

.results-cell__avatar {
  width: 36px;
  height: 36px;
  border-radius: 10%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 157, 0, 0.55);
}

.results-cell__winner-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.results-cell__winner-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.results-cell__winner-rating {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.results-cell__winner-rating-delta {
  color: var(--green);
  font-weight: 600;
}

.results-cell--win,
.results-cell--bet {
  justify-content: flex-end;
  font-weight: 600;
  color: var(--text);
}

.results-cell--win img,
.results-cell--bet img {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.results-cell--chance {
  justify-content: flex-end;
  color: var(--text-muted);
  font-weight: 600;
}

.results-cell--chance.is-red { color: var(--red); }
.results-cell--chance.is-yellow { color: var(--orange-1); }
.results-cell--chance.is-blue { color: var(--blue); }
.results-cell--chance.is-green { color: var(--green); }

.results-cell--players {
  justify-content: flex-end;
  gap: 7px;
  color: var(--text-muted);
  font-weight: 500;
}

.results-cell--players svg {
  width: 20px;
  height: 15px;
  flex-shrink: 0;
}

.player-list {
  display: flex;
  flex-direction: column;
  height: 648px;
  overflow-y: hidden;
}

.player-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 54px;
  padding: 0 20px;
  transition: background 0.15s ease;
}

.player-row:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.player-row:hover {
  background: rgba(255, 255, 255, 0.035);
}

.player-row__user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.player-row__avatar {
  width: 36px;
  height: 36px;
  border-radius: 10%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 157, 0, 0.55);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.player-row:hover .player-row__avatar {
  transform: scale(1.08);
  box-shadow: 0 0 0 2px var(--orange-2);
}

.player-row__name {
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-dim);
}

.player-row__badge {
  flex-shrink: 0;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.06);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}

.results-col--welcome .payout-list { display: none; }
.results-col--welcome.is-payouts .payout-list { display: flex; }
.results-col--welcome.is-payouts .player-list { display: none; }

.payout-list {
  flex-direction: column;
  height: 648px;
  overflow-y: hidden;
}

.payout-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 54px;
  padding: 0 20px;
  transition: background 0.15s ease;
}

.payout-row:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.payout-row:hover {
  background: rgba(255, 255, 255, 0.035);
}

.payout-row__user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.payout-row__avatar {
  width: 36px;
  height: 36px;
  border-radius: 10%;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 157, 0, 0.55);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.payout-row:hover .payout-row__avatar {
  transform: scale(1.08);
  box-shadow: 0 0 0 2px var(--orange-2);
}

.payout-row__info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.payout-row__name {
  font-size: 14px;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.payout-row__amount {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.payout-row__crypto {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  object-fit: contain;
}


/* ============================================================
   Интеграция с движком Fast-Win
   ============================================================ */

/* Таймер: в макете он был #gameTimer, в движке — #timer */
#timer {
  position: absolute;
  top: 29px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--tile-teal-1);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

#timer.is-hot {
  color: var(--red);
  animation: pulseHot 1s ease-in-out infinite;
}

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

/* ── Шапка ── */

.btn-gold--header {
  height: 48px;
  padding: 0 22px;
  font-size: 15px;
}

.balance--rating {
  gap: 8px;
}

.balance__star {
  font-size: 17px;
  line-height: 1;
  color: var(--orange-1);
}

.side-nav__item--alert::after {
  content: "";
  width: 7px;
  height: 7px;
  margin-left: auto;
  border-radius: 50%;
  background: var(--red);
  animation: pulseDot 1.8s ease-in-out infinite;
}

.side-social__item i {
  font-size: 21px;
  line-height: 1;
}

/* ── Подвал ── */

.site-footer__links {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

.site-footer__links a {
  color: var(--text-muted);
  transition: color 0.15s ease;
}

.site-footer__links a:hover,
.site-footer__copy a {
  color: var(--orange-1);
}

/* ── Карточка ставки ── */

.tab-panel > form {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.bet-message {
  min-height: 20px;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
}

.bet-tab__badge:not(:empty) {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  margin-left: 7px;
  padding: 0 6px;
  border-radius: var(--radius-pill);
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  color: #2a1300;
  font-size: 11px;
  font-weight: 700;
}

.auto-note__link {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auto-note__link:hover {
  color: var(--orange-1);
}

/* ── Состояния игрового поля ── */

.game-state {
  position: absolute;
  left: 0;
  right: 0;
  top: 55%;
  transform: translateY(-50%);
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 24px;
  pointer-events: none;
}

.game-state__title {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-muted);
}

.game-state--accent .game-state__title {
  color: var(--orange-1);
}

/* Подсказка про двух игроков живёт под основным сообщением, а не поверх него */
#top_message {
  top: auto;
  bottom: 26px;
  transform: none;
}

#top_message .game-state__title {
  font-size: 15px;
}

/* Строки списков появляются через CSS: jQuery-анимации сбивают display у grid/flex-строк */
.row-in {
  animation: rowIn 0.45s ease both;
}

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

/* ── Розыгрыш победителя ── */

.game-roll {
  position: absolute;
  left: 0;
  right: 0;
  top: 96px;
  bottom: 0;
  z-index: 5;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background: rgba(22, 17, 13, 0.94);
  overflow: hidden;
}

.game-roll__inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-roll__ribbon-wrap {
  width: 100%;
  text-align: center;
}

.game-roll__ribbon {
  position: relative;
  height: 120px;
  margin-top: 14px;
  overflow: hidden;
}

.game-roll__marker {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  z-index: 2;
  width: 3px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--orange-1), var(--orange-3));
  box-shadow: 0 0 14px var(--orange-glow);
}

.game-roll__strip {
  position: absolute;
  top: 0;
  left: 0;
  height: 120px;
  width: 9000px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.game-roll__cell {
  width: 100px;
  height: 100px;
  flex-shrink: 0;
  border-radius: 14%;
  object-fit: cover;
  border: 1px solid var(--panel-border);
}

.game-roll__winner {
  display: flex;
  align-items: center;
  gap: 22px;
}

.game-roll__winner-avatar {
  width: 110px;
  height: 110px;
  border-radius: 14%;
  object-fit: cover;
  border: 2px solid var(--orange-1);
  box-shadow: 0 0 30px -6px var(--orange-glow);
}

.game-roll__winner-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.game-roll__winner-name {
  font-size: 22px;
  font-weight: 700;
}

.game-roll__winner-sum {
  font-size: 20px;
  color: var(--text-dim);
}

.game-roll__winner-sum b {
  color: var(--orange-1);
}

.game-roll__winner-meta {
  font-size: 14px;
  color: var(--text-muted);
}

/* ── Босс комнаты ── */

.boss-bar__login a:hover {
  color: var(--orange-1);
}

.boss-bar__streak {
  margin-top: 4px;
}

/* ── Строки списков стали ссылками ── */

.player-row,
.payout-row,
.results-row {
  color: inherit;
}

.results-cell--winner > a {
  display: flex;
  flex-shrink: 0;
}

.results-cell__winner-name:hover,
.results-cell--num a:hover,
.results-cell--chance a:hover {
  color: var(--orange-1);
}

/* ── Старые страницы внутри нового каркаса ── */

.legacy-page {
  width: 100%;
}

.legacy-page img {
  display: inline-block;
}

/* ============================================================
   Личный кабинет
   ============================================================ */

.page-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
}

.page-head__title {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.page-head__sub {
  font-size: 14px;
  color: var(--text-muted);
}

.page-head__sub b {
  color: var(--text-dim);
  font-weight: 600;
}

.acc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.acc-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 24px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  animation: fadeUp 0.45s ease both;
}

.acc-card--wide {
  grid-column: span 2;
}

.acc-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.acc-card__title {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}

.acc-card__link {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.15s ease;
}

.acc-card__link:hover {
  color: var(--orange-1);
}

/* ── Профиль ── */

.acc-profile {
  display: flex;
  align-items: center;
  gap: 16px;
}

.acc-profile__avatar {
  width: 76px;
  height: 76px;
  border-radius: 12%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--orange-1);
  box-shadow: 0 0 24px -8px var(--orange-glow);
}

.acc-profile__info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.acc-profile__name {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.2;
}

.acc-profile__rating {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.15s ease;
}

.acc-profile__rating b {
  color: var(--orange-1);
  font-weight: 600;
}

.acc-profile__rating:hover {
  color: var(--text-dim);
}

.acc-meta {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.acc-meta__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.acc-meta__row:last-child {
  border-bottom: none;
}

.acc-meta dt {
  font-size: 13px;
  color: var(--text-muted);
}

.acc-meta dd {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.acc-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 44px;
  margin-top: auto;
  border-radius: var(--radius-xs);
  border: 1px solid var(--panel-border);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.acc-logout:hover {
  color: var(--red);
  border-color: rgba(255, 71, 87, 0.4);
  background: var(--red-bg);
}

/* ── Суммы и кнопки ── */

.acc-amount {
  display: flex;
  align-items: center;
  gap: 12px;
}

.acc-amount img {
  filter: drop-shadow(0 0 8px rgba(255, 200, 0, 0.5));
}

.acc-amount__value {
  font-size: 34px;
  font-weight: 700;
  line-height: 1;
}

.acc-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
}

.acc-actions .btn-gold {
  height: 46px;
  font-size: 15px;
}

.acc-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  border-radius: var(--radius-xs);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-dim);
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.acc-btn:hover {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
  background: var(--panel-2);
}

.acc-note {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}

.acc-note--dim {
  font-size: 12px;
  opacity: 0.75;
}

/* ── Сетка настроек ── */

.acc-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.acc-link {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 52px;
  padding: 0 16px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border);
  background: var(--panel-2);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dim);
  transition: color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.acc-link .icon {
  width: 19px;
  height: 19px;
  color: var(--orange-1);
}

.acc-link:hover {
  color: var(--text);
  border-color: rgba(255, 157, 0, 0.35);
  transform: translateY(-1px);
}

/* ── Реф. статистика ── */

.acc-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.acc-stat {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel-2);
}

.acc-stat__label {
  font-size: 12px;
  color: var(--text-muted);
}

.acc-stat__value {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
}

.acc-share {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.acc-share__label {
  font-size: 13px;
  color: var(--text-muted);
}

.acc-share .share42init {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.acc-share .share42init a {
  opacity: 0.85;
  transition: opacity 0.15s ease;
}

.acc-share .share42init a:hover {
  opacity: 1;
}

/* ============================================================
   Денежные страницы: история, выплаты, пополнение
   ============================================================ */

.page-head__back {
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.15s ease;
}

.page-head__back:hover {
  color: var(--orange-1);
}

.acc-toolbar__links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.acc-toolbar__links .acc-btn {
  padding: 0 18px;
  height: 42px;
}

.acc-alert {
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--panel-border);
  background: var(--panel-2);
  font-size: 14px;
}

.acc-alert--error {
  border-color: rgba(255, 71, 87, 0.4);
  background: var(--red-bg);
  color: var(--red);
}

.acc-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 48px 20px;
  color: var(--text-muted);
  font-size: 15px;
}

.acc-empty .icon {
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  opacity: 0.6;
}

.acc-empty--error {
  color: var(--red);
  font-size: 18px;
  font-weight: 600;
}

.acc-pager {
  margin-top: 20px;
  text-align: center;
}

/* ── Таблица операций ── */

.op-table {
  display: flex;
  flex-direction: column;
}

.op-head,
.op-row {
  display: grid;
  grid-template-columns: 90px 130px 1fr 150px;
  align-items: center;
  gap: 14px;
  padding: 0 4px;
}

.op-head {
  height: 42px;
  border-bottom: 1px solid var(--panel-border);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.op-row {
  min-height: 52px;
  padding-top: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s ease;
}

.op-row:last-child {
  border-bottom: none;
}

.op-row:hover {
  background: rgba(255, 255, 255, 0.03);
}

.op-cell {
  min-width: 0;
  font-size: 14px;
  color: var(--text-dim);
}

.op-cell--id {
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
}

.op-cell--sum {
  text-align: right;
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.op-cell--sum.is-plus { color: var(--green); }
.op-cell--sum.is-minus { color: var(--red); }

.op-cell--date {
  text-align: right;
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
}

.op-desc {
  color: var(--text);
  font-weight: 500;
}

.op-tag {
  display: inline-block;
  margin-left: 9px;
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: var(--panel-2);
  border: 1px solid var(--border);
  font-size: 12px;
  color: var(--text-muted);
}

/* ── Выбор платёжной системы ── */

.ps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}

.ps-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 18px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel-2);
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.ps-card:hover {
  border-color: rgba(255, 157, 0, 0.45);
  transform: translateY(-2px);
}

/* Логотипы ПС нарисованы под светлый фон — держим белую подложку */
.ps-card__logo {
  display: grid;
  place-items: center;
  width: 100%;
  height: 74px;
  padding: 10px;
  border-radius: var(--radius-xs);
  background: #fff;
}

.ps-card__logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.ps-card__title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  text-align: center;
}

/* Заголовок страницы не должен переопределяться правилами моста */
.legacy-page .page-head__title,
.page-head .page-head__title {
  font-size: 26px;
  margin: 0;
}
