/* ============================================================
   Pragmatic Play — official orange-on-dark theme
   ============================================================ */
:root {
  --bg: #0b0c11;
  --bg-2: #14151d;
  --panel: rgba(26, 28, 38, 0.72);
  --panel-solid: #181a24;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f4f5fa;
  --muted: #9aa0b2;
  /* Pragmatic Play signature orange (kept under legacy var names so the
     whole UI reskins from these few values). */
  --gold: #f6921e;     /* primary orange */
  --gold-2: #f4511e;   /* deep orange */
  --pink: #fbb034;     /* amber */
  --purple: #ff7a18;   /* warm orange */
  --cyan: #ffc266;     /* light amber */
  --green: #2fcf8e;
  --red: #ff5670;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
  --glow-gold: 0 0 18px rgba(246, 146, 30, 0.55);
  --font: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.5;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* The HTML `hidden` attribute must always win over component display rules
   (e.g. .modal{display:grid}, .wallet-pill{display:inline-flex}). Author CSS
   normally overrides the UA stylesheet's [hidden]{display:none}, which would
   leave modals/drawers visible on page load — force it here. */
[hidden] { display: none !important; }

/* ---------- 18+ Age gate ---------- */
.agegate {
  position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px;
  background: radial-gradient(60vw 60vh at 50% 0%, rgba(246, 146, 30, 0.18), transparent 70%), rgba(8, 9, 13, 0.96);
  backdrop-filter: blur(8px);
}
.agegate__card {
  width: 100%; max-width: 440px; text-align: center; padding: 36px 30px;
  background: var(--panel-solid); border: 1px solid var(--line); border-radius: 20px;
  box-shadow: var(--shadow); animation: pop 0.3s cubic-bezier(0.18, 1.2, 0.4, 1) both;
}
.agegate__brand { font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 24px; letter-spacing: 0.5px; }
.agegate__brand span { color: var(--gold); margin-left: 4px; }
.agegate__badge {
  width: 64px; height: 64px; margin: 20px auto 18px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 22px; color: #fff;
  background: linear-gradient(135deg, var(--gold), var(--gold-2)); box-shadow: var(--glow-gold);
}
.agegate__title { font-size: 19px; font-weight: 700; line-height: 1.35; margin-bottom: 10px; }
.agegate__text { color: var(--muted); font-size: 14px; margin-bottom: 22px; }
.agegate__yes { width: 100%; justify-content: center; margin-bottom: 12px; }
.agegate__no { color: var(--muted); font-size: 14px; font-weight: 600; padding: 8px; }
.agegate__no:hover { color: var(--text); }
.agegate__note { color: var(--muted); font-size: 12px; margin-top: 18px; opacity: 0.8; }

/* ---------- Ambient background ---------- */
.bg-aurora {
  position: fixed; inset: 0; z-index: -2;
  background:
    radial-gradient(60vw 50vh at 12% -5%, rgba(246, 146, 30, 0.30), transparent 60%),
    radial-gradient(55vw 50vh at 92% 0%, rgba(244, 81, 30, 0.26), transparent 60%),
    radial-gradient(70vw 60vh at 50% 110%, rgba(251, 176, 52, 0.16), transparent 60%),
    linear-gradient(180deg, var(--bg-2), var(--bg) 60%);
  animation: hueShift 24s ease-in-out infinite alternate;
}
.bg-grid {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(120vw 100vh at 50% -10%, #000 30%, transparent 80%);
}
@keyframes hueShift { from { filter: hue-rotate(0deg); } to { filter: hue-rotate(10deg); } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px; border-radius: 999px; font-weight: 700; font-size: 14px;
  letter-spacing: 0.2px; transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn--lg { padding: 15px 30px; font-size: 16px; }
.btn--block { width: 100%; }
.btn--gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-2));
  color: #fff; box-shadow: var(--glow-gold);
}
.btn--gold:hover { box-shadow: 0 0 28px rgba(246, 146, 30, 0.7); transform: translateY(-1px); }
.btn--ghost { background: rgba(255, 255, 255, 0.06); color: var(--text); border: 1px solid var(--line); }
.btn--ghost:hover { background: rgba(255, 255, 255, 0.12); }
.btn--outline { background: transparent; color: var(--text); border: 1.5px solid rgba(246, 146, 30, 0.6); }
.btn--outline:hover { border-color: var(--gold); box-shadow: var(--glow-gold); }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; }
.brand__spark { color: var(--gold); font-size: 20px; filter: drop-shadow(0 0 8px rgba(246, 146, 30, 0.8)); animation: twinkle 3s infinite; }
.brand__name { font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 21px; letter-spacing: 0.5px; line-height: 1; }
.brand__accent { color: var(--gold); margin-left: 4px; text-shadow: var(--glow-gold); }
.brand--sm .brand__name { font-size: 18px; }
@keyframes twinkle { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(8, 4, 15, 0.72); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner {
  max-width: 1320px; margin: 0 auto; padding: 12px 22px;
  display: flex; align-items: center; gap: 22px;
}
.mainnav { display: flex; gap: 6px; margin-left: 10px; }
.mainnav__link {
  padding: 8px 14px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--muted);
  transition: color 0.2s, background 0.2s;
}
.mainnav__link:hover { color: var(--text); }
.mainnav__link.is-active { color: var(--text); background: rgba(255, 255, 255, 0.07); }
.topbar__actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }

/* ---------- Wallet pill ---------- */
.wallet-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: linear-gradient(135deg, rgba(246, 146, 30, 0.16), rgba(244, 81, 30, 0.14));
  border: 1px solid rgba(246, 146, 30, 0.4); border-radius: 999px; padding: 6px 6px 6px 14px;
  font-weight: 700;
}
.wallet-pill__amount { font-variant-numeric: tabular-nums; }
.wallet-pill__cur { color: var(--muted); font-size: 12px; font-weight: 600; }
.wallet-pill__add {
  width: 26px; height: 26px; border-radius: 50%; font-size: 18px; font-weight: 700; line-height: 1;
  background: linear-gradient(135deg, var(--gold), var(--gold-2)); color: #fff;
  display: grid; place-items: center; transition: transform 0.15s;
}
.wallet-pill__add:hover { transform: scale(1.12) rotate(90deg); }

/* ---------- User menu ---------- */
.user-menu { position: relative; }
.user-menu__btn { display: inline-flex; align-items: center; gap: 9px; padding: 5px 10px 5px 5px; border-radius: 999px; border: 1px solid var(--line); }
.user-menu__btn:hover { background: rgba(255, 255, 255, 0.06); }
.user-menu__avatar {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff;
  background: linear-gradient(135deg, var(--gold), var(--gold-2));
}
.user-menu__name { font-weight: 600; font-size: 14px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.user-menu__drop {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 180px;
  background: var(--panel-solid); border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); overflow: hidden; padding: 6px;
}
.user-menu__item { display: block; width: 100%; text-align: left; padding: 10px 12px; border-radius: 8px; font-weight: 600; font-size: 14px; }
.user-menu__item:hover { background: rgba(255, 255, 255, 0.07); }

/* ---------- Hero ---------- */
.hero { max-width: 1100px; margin: 0 auto; padding: 70px 22px 30px; text-align: center; }
.hero__neon { display: inline-block; }
.hero__welcome { display: block; font-family: 'Poppins', sans-serif; font-weight: 600; letter-spacing: 4px; color: var(--gold); font-size: 15px; text-transform: uppercase; }
.hero__title {
  font-family: 'Poppins', sans-serif; font-weight: 800; line-height: 1.04;
  font-size: clamp(34px, 7vw, 78px); letter-spacing: -1px; margin: 8px 0 6px; text-transform: uppercase;
  background: linear-gradient(95deg, var(--gold) 0%, var(--pink) 45%, #fff 70%, var(--gold) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 6px 24px rgba(246, 146, 30, 0.35));
}
.hero__stars { color: var(--gold); letter-spacing: 8px; font-size: 18px; text-shadow: var(--glow-gold); }
.hero__tagline { color: var(--muted); max-width: 620px; margin: 16px auto 0; font-size: 16px; }
.hero__cta { display: flex; gap: 14px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }

/* ---------- Features strip ---------- */
.features { max-width: 1320px; margin: 30px auto 0; padding: 0 22px; }
.features__inner {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px;
}
.feature { text-align: center; padding: 6px; }
.feature__icon { font-size: 30px; margin-bottom: 8px; }
.feature__title { font-weight: 800; font-size: 16px; }
.feature__sub { color: var(--muted); font-size: 12.5px; margin-top: 3px; }
@media (max-width: 700px) {
  .features__inner { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Currency selector ---------- */
.cur-select {
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); color: var(--text);
  border-radius: 999px; padding: 8px 12px; font-size: 13px; font-weight: 600; cursor: pointer;
}
.cur-select:focus { outline: none; border-color: rgba(255, 197, 107, 0.5); }
.cur-select option { background: var(--panel-solid); color: var(--text); }

/* ---------- Jackpots ---------- */
.jackpots { max-width: 1320px; margin: 26px auto 0; padding: 0 22px; }
.jackpots__inner { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.jackpot {
  position: relative; overflow: hidden; border-radius: var(--radius); padding: 16px 18px;
  border: 1px solid rgba(255, 197, 107, 0.35); text-align: center;
  background: linear-gradient(135deg, rgba(246, 146, 30, 0.12), rgba(244, 81, 30, 0.1));
}
.jackpot--grand { border-color: rgba(255, 197, 107, 0.7); box-shadow: 0 0 26px rgba(255, 197, 107, 0.25); }
.jackpot__tier { font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; color: var(--gold); }
.jackpot__amount { font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 30px; letter-spacing: 0; margin-top: 4px; font-variant-numeric: tabular-nums; }
.jackpot__label { color: var(--muted); font-size: 11px; margin-top: 2px; }

/* ---------- Promotions ---------- */
.promos { max-width: 1320px; margin: 34px auto 0; padding: 0 22px; }
.section-title { font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 24px; letter-spacing: -0.5px; margin-bottom: 16px; }
.promos__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.promo {
  position: relative; border-radius: var(--radius); padding: 20px; border: 1px solid var(--line);
  background: linear-gradient(135deg, var(--panel), rgba(246, 146, 30, 0.08)); overflow: hidden;
}
.promo__type { font-size: 11px; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; display: inline-block; }
.promo__type--tournament { background: rgba(255, 197, 107, 0.16); color: var(--gold); }
.promo__type--bonus { background: rgba(56, 232, 160, 0.16); color: var(--green); }
.promo__name { font-weight: 800; font-size: 18px; margin: 10px 0 6px; }
.promo__desc { color: var(--muted); font-size: 13px; line-height: 1.5; }
.promo__meta { display: flex; gap: 14px; margin-top: 14px; flex-wrap: wrap; }
.promo__stat { font-size: 12px; }
.promo__stat b { display: block; font-size: 16px; color: var(--gold); font-variant-numeric: tabular-nums; }
.promo--clickable { cursor: pointer; transition: transform 0.18s ease, border-color 0.18s ease; }
.promo--clickable:hover { transform: translateY(-4px); border-color: rgba(246, 146, 30, 0.5); }
.promo__cta { margin-top: 14px; font-size: 13px; font-weight: 700; color: var(--gold); }

/* ---------- Ticker ---------- */
.ticker {
  margin: 40px auto 0; max-width: 1320px; overflow: hidden; border-block: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.ticker__track { display: inline-flex; gap: 34px; white-space: nowrap; padding: 11px 0; animation: scrollX 38s linear infinite; }
.ticker__item { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); font-weight: 600; }
.ticker__item b { color: var(--text); }
.ticker__win { color: var(--green); }
@keyframes scrollX { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Lobby ---------- */
.lobby { max-width: 1320px; margin: 0 auto; padding: 34px 22px 60px; }
.lobby__head { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; justify-content: space-between; margin-bottom: 18px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  padding: 9px 16px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--muted);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); transition: all 0.18s;
}
.chip:hover { color: var(--text); border-color: rgba(255, 197, 107, 0.4); }
.chip.is-active { color: #fff; background: linear-gradient(135deg, var(--gold), var(--gold-2)); border-color: transparent; box-shadow: var(--glow-gold); }
.search { position: relative; }
.search__icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 18px; }
.search__input {
  width: 260px; max-width: 60vw; padding: 11px 16px 11px 38px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); color: var(--text); font-size: 14px;
}
.search__input::placeholder { color: var(--muted); }
.search__input:focus { border-color: rgba(255, 197, 107, 0.5); background: rgba(255, 255, 255, 0.08); }

.lobby__title { font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 26px; letter-spacing: -0.5px; margin-bottom: 16px; }

/* ---------- Game grid (PP-style: art tile + name below) ---------- */
.game-grid {
  display: grid; gap: 20px 16px;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
}
.card {
  display: flex; flex-direction: column; gap: 10px; cursor: pointer;
  animation: rise 0.4s ease both;
}
.card__art {
  position: relative; aspect-ratio: 1 / 1; border-radius: 14px; overflow: hidden;
  background: var(--panel-solid); border: 1px solid var(--line);
  transition: transform 0.2s ease, box-shadow 0.25s ease, border-color 0.2s;
}
.card:hover .card__art, .card:focus-visible .card__art {
  transform: translateY(-5px); box-shadow: 0 18px 42px rgba(246, 146, 30, 0.35);
  border-color: rgba(255, 197, 107, 0.6);
}
.card__img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.45s ease; background: #1a1030; }
.card:hover .card__img { transform: scale(1.08); }
.card__fallback { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 12px; }
.card__fallback span { font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 18px; letter-spacing: 0; color: #fff; }
.card__tags { position: absolute; top: 8px; left: 8px; display: flex; gap: 5px; z-index: 2; }
.tag {
  font-size: 10px; font-weight: 800; letter-spacing: 0.5px; padding: 3px 7px; border-radius: 6px; text-transform: uppercase;
  backdrop-filter: blur(4px);
}
.tag--hot { background: linear-gradient(135deg, var(--pink), var(--red)); color: #fff; }
.tag--new { background: linear-gradient(135deg, var(--cyan), var(--purple)); color: #061018; }
.tag--live { background: linear-gradient(135deg, var(--red), #ff2d55); color: #fff; }
.card__hover {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  opacity: 0; transition: opacity 0.2s ease;
  background: radial-gradient(circle at center, rgba(10, 6, 20, 0.35), rgba(8, 4, 15, 0.84));
}
.card:hover .card__hover, .card:focus-within .card__hover { opacity: 1; }
.card__play {
  padding: 11px 26px; border-radius: 999px; font-weight: 800; font-size: 14px;
  background: linear-gradient(135deg, var(--gold), var(--gold-2)); color: #fff;
  box-shadow: var(--glow-gold); transform: translateY(8px); transition: transform 0.22s ease;
}
.card:hover .card__play { transform: none; }
.card__rtpb { font-size: 11px; font-weight: 700; color: var(--green); background: rgba(0, 0, 0, 0.45); padding: 3px 10px; border-radius: 999px; }
.card__title {
  font-weight: 600; font-size: 13.5px; text-align: center; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 2px;
  transition: color 0.2s;
}
.card:hover .card__title { color: var(--gold); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.empty { text-align: center; color: var(--muted); padding: 60px 0; font-size: 16px; }

/* ---------- Modal base ---------- */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(4, 2, 10, 0.78); backdrop-filter: blur(6px); animation: fade 0.2s ease; }
.modal__panel {
  position: relative; width: 100%; max-width: 420px; background: var(--panel-solid);
  border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 28px;
  animation: pop 0.25s cubic-bezier(0.18, 1.2, 0.4, 1) both;
}
.modal__close { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; border-radius: 50%; font-size: 15px; color: var(--muted); background: rgba(255, 255, 255, 0.06); }
.modal__close:hover { color: var(--text); background: rgba(255, 255, 255, 0.12); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(16px) scale(0.96); } to { opacity: 1; transform: none; } }

/* ---------- Auth ---------- */
.auth-tabs { display: flex; gap: 6px; background: rgba(255, 255, 255, 0.05); padding: 5px; border-radius: 999px; margin-bottom: 22px; }
.auth-tab { flex: 1; padding: 10px; border-radius: 999px; font-weight: 700; font-size: 14px; color: var(--muted); }
.auth-tab.is-active { background: linear-gradient(135deg, var(--gold), var(--gold-2)); color: #fff; }
.auth-form__title { font-size: 22px; margin-bottom: 16px; }
.field { display: block; margin-bottom: 14px; }
.field span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; font-weight: 600; }
.field input {
  width: 100%; padding: 12px 14px; border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); color: var(--text); font-size: 15px;
}
.field input:focus { border-color: rgba(255, 197, 107, 0.55); background: rgba(255, 255, 255, 0.08); }
.auth-form__hint { font-size: 12px; color: var(--muted); margin-top: 10px; text-align: center; }
.auth-form__error { margin-top: 12px; padding: 10px 12px; border-radius: 8px; background: rgba(255, 86, 112, 0.14); border: 1px solid rgba(255, 86, 112, 0.4); color: #ffb3c0; font-size: 13px; }

/* ---------- Cashier ---------- */
.cashier__title { font-size: 22px; margin-bottom: 4px; }
.cashier__tabs { margin-bottom: 18px; }
.cashier__sub { color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.cashier__methods { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 18px; }
.paymethod {
  padding: 12px 6px; border-radius: var(--radius-sm); font-size: 12px; font-weight: 600; color: var(--muted);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); transition: all 0.16s; line-height: 1.4;
}
.paymethod:hover { color: var(--text); border-color: rgba(246, 146, 30, 0.4); }
.paymethod.is-active { color: var(--text); border-color: var(--gold); background: rgba(246, 146, 30, 0.12); }
.cashier__chips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
.amt-chip {
  padding: 13px; border-radius: var(--radius-sm); font-weight: 700; font-size: 15px; color: var(--text);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); transition: all 0.16s;
}
.amt-chip:hover { border-color: rgba(246, 146, 30, 0.5); }
.amt-chip.is-active { color: #fff; background: linear-gradient(135deg, var(--gold), var(--gold-2)); border-color: transparent; box-shadow: var(--glow-gold); }
.cashier__custom { margin-bottom: 16px; }
.cashier__note { color: var(--muted); font-size: 12px; margin-top: 12px; text-align: center; }

/* ---------- Responsible gaming ---------- */
.rg__h { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--muted); margin: 22px 0 12px; }
.rg__limits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.rg__limits .field { margin-bottom: 0; }
.rg__limits .field span { display: flex; justify-content: space-between; align-items: baseline; }
.rg__limits .field em { color: var(--gold); font-style: normal; font-size: 11px; font-weight: 700; }
.rg__break { display: flex; flex-direction: column; gap: 10px; }
.rg__excluded { padding: 12px; border-radius: var(--radius-sm); background: rgba(255, 86, 112, 0.14); border: 1px solid rgba(255, 86, 112, 0.4); color: #ffb3c0; font-size: 13px; margin-bottom: 12px; }

/* ---------- Leaderboard ---------- */
.lb { max-width: 480px; }
.lb__prize { text-align: center; padding: 14px; margin-bottom: 14px; border-radius: var(--radius-sm); background: linear-gradient(135deg, rgba(246, 146, 30, 0.14), rgba(244, 81, 30, 0.12)); border: 1px solid rgba(246, 146, 30, 0.35); }
.lb__prize b { font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 26px; display: block; color: var(--gold); }
.lb__body { max-height: 50vh; overflow-y: auto; }
.lb__row { display: grid; grid-template-columns: 36px 1fr auto; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; }
.lb__row:nth-child(odd) { background: rgba(255, 255, 255, 0.03); }
.lb__row.is-you { background: rgba(246, 146, 30, 0.14); border: 1px solid rgba(246, 146, 30, 0.4); }
.lb__rank { font-weight: 800; font-size: 15px; text-align: center; }
.lb__rank.top { color: var(--gold); }
.lb__name { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb__score { font-weight: 800; font-variant-numeric: tabular-nums; color: var(--gold); }
.lb__me { margin-top: 12px; padding: 12px; border-radius: 10px; background: rgba(246, 146, 30, 0.12); border: 1px solid rgba(246, 146, 30, 0.35); text-align: center; font-size: 13px; }

/* ---------- Game stage (full-screen immersive player) ---------- */
.modal--game { padding: 0; }
.game-stage {
  position: relative; width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; margin: 0;
  display: flex; flex-direction: column; background: #06030d; overflow: hidden;
  border: 0; border-radius: 0; animation: fade 0.22s ease both;
}
.game-stage__bar {
  display: flex; align-items: center; gap: 12px; padding: 10px 16px;
  background: rgba(10, 6, 20, 0.92); border-bottom: 1px solid var(--line); flex-shrink: 0;
}
.game-stage__brand { font-family: 'Poppins', sans-serif; font-weight: 800; font-size: 15px; letter-spacing: 0.3px; color: var(--gold); margin-right: 4px; }
.game-stage__title { font-weight: 700; font-size: 15px; }
.game-stage__mode { font-size: 10px; font-weight: 800; letter-spacing: 1px; padding: 3px 8px; border-radius: 6px; background: rgba(56, 232, 160, 0.18); color: var(--green); border: 1px solid rgba(56, 232, 160, 0.4); }
.game-stage__mode.is-real { background: rgba(255, 197, 107, 0.18); color: var(--gold); border-color: rgba(255, 197, 107, 0.4); }
.game-stage__spacer { flex: 1; }
.iconbtn { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; font-size: 16px; color: var(--muted); background: rgba(255, 255, 255, 0.05); }
.iconbtn:hover { color: var(--text); background: rgba(255, 255, 255, 0.12); }
.game-stage__frame { position: relative; flex: 1; background: #000; }
.game-stage__frame iframe { position: relative; z-index: 2; width: 100%; height: 100%; border: 0; background: transparent; }
.game-stage__loader { position: absolute; inset: 0; z-index: 1; display: grid; place-content: center; justify-items: center; gap: 14px; color: var(--muted); }
.spinner { width: 42px; height: 42px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, 0.12); border-top-color: var(--gold); animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 100; }
.drawer__backdrop { position: absolute; inset: 0; background: rgba(4, 2, 10, 0.7); backdrop-filter: blur(4px); animation: fade 0.2s; }
.drawer__panel { position: absolute; top: 0; right: 0; height: 100%; width: 380px; max-width: 90vw; background: var(--panel-solid); border-left: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; animation: slideIn 0.25s ease both; }
@keyframes slideIn { from { transform: translateX(100%); } to { transform: none; } }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer__head h3 { font-size: 18px; }
.drawer__body { flex: 1; overflow-y: auto; padding: 12px; }
.tx { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-radius: 10px; }
.tx:nth-child(odd) { background: rgba(255, 255, 255, 0.03); }
.tx__type { font-weight: 600; font-size: 14px; text-transform: capitalize; }
.tx__date { font-size: 11px; color: var(--muted); }
.tx__amt { font-weight: 800; font-variant-numeric: tabular-nums; }
.tx__amt.pos { color: var(--green); }
.tx__amt.neg { color: var(--red); }
.drawer__empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* ---------- Toasts ---------- */
.toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 10px; align-items: center; pointer-events: none; }
.toast {
  pointer-events: auto; padding: 13px 20px; border-radius: 999px; font-weight: 600; font-size: 14px;
  background: var(--panel-solid); border: 1px solid var(--line); box-shadow: var(--shadow);
  animation: toastIn 0.3s ease both; max-width: 90vw;
}
.toast--ok { border-color: rgba(56, 232, 160, 0.5); }
.toast--err { border-color: rgba(255, 86, 112, 0.5); }
.toast--info { border-color: rgba(56, 232, 255, 0.5); }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); background: rgba(8, 4, 15, 0.6); margin-top: 30px; }
.footer__inner { max-width: 1320px; margin: 0 auto; padding: 38px 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 30px; }
.footer__muted { color: var(--muted); font-size: 13px; margin-top: 12px; max-width: 520px; }
.footer__legal { display: flex; gap: 16px; align-items: flex-start; }
.badge18 { flex-shrink: 0; width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--red); color: var(--red); font-weight: 800; display: grid; place-items: center; font-size: 14px; }
.footer__bar { text-align: center; padding: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .mainnav { display: none; }
  .footer__inner { grid-template-columns: 1fr; }
  .game-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
  .user-menu__name { display: none; }
}
@media (max-width: 520px) {
  .topbar__inner { padding: 10px 14px; gap: 10px; }
  .hero { padding-top: 44px; }
  .search__input { width: 100%; }
  .search { width: 100%; }
  .lobby__head { flex-direction: column; align-items: stretch; }
  .game-grid { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); }
  .wallet-pill__cur { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}
