:root {
  --bg: #f2f4f7;
  --card: #ffffff;
  --card-alt: #eef1f5;
  --separator: rgba(13, 17, 23, 0.09);
  --fill: rgba(13, 17, 23, 0.05);

  --label: #0d1117;
  --label2: #5a6474;
  --label3: #98a1af;

  --accent: #b9e60f;
  --accent-ink: #14260a;
  --tint-bg: rgba(150, 200, 10, 0.16);

  --blue: #2f7bff;
  --green: #12b76a;
  --red: #e5484d;
  --orange: #f2870d;
  --yellow: #eab308;
  --purple: #7c5cff;
  --gray: #8b94a3;

  --nav-blur: rgba(255, 255, 255, 0.9);
  --shadow: 0 6px 18px rgba(16, 24, 40, 0.08);
  --radius: 14px;
}

[data-theme="dark"] {
  --bg: #080b11;
  --card: #131924;
  --card-alt: #1b2230;
  --separator: rgba(255, 255, 255, 0.075);
  --fill: rgba(255, 255, 255, 0.06);

  --label: #f2f5fa;
  --label2: #98a3b4;
  --label3: #5f6b7d;

  --accent: #d4ff3d;
  --accent-ink: #0d1f04;
  --tint-bg: rgba(212, 255, 61, 0.13);

  --blue: #4c9bff;
  --green: #24d17e;
  --red: #ff4d5e;
  --orange: #ff9f2e;
  --yellow: #ffd54a;
  --purple: #a78bfa;
  --gray: #8b94a3;

  --nav-blur: rgba(9, 12, 18, 0.9);
  --shadow: 0 10px 26px rgba(0, 0, 0, 0.4);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  background: var(--bg);
  color: var(--label);
  font: 16px/1.3 -apple-system, "SF Pro Text", "Segoe UI Variable", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
  user-select: none;
  -webkit-user-select: none;
}
[data-theme="dark"] body {
  background:
    radial-gradient(120% 60% at 50% -10%, rgba(212, 255, 61, 0.05), transparent 60%),
    var(--bg);
}

#app { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); min-height: 100vh; }
#app.no-tabs { padding-bottom: 28px; }

.boot { height: 100vh; display: flex; align-items: center; justify-content: center; }
.spinner {
  width: 26px; height: 26px; border-radius: 50%;
  border: 2.5px solid var(--fill); border-top-color: var(--accent);
  animation: spin 0.75s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.screen { animation: fade 0.22s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.hall-top { display: flex; align-items: center; gap: 10px; padding: 12px 16px 4px; }
.hall-top .brand { width: 34px; height: 34px; border-radius: 9px; }
.hall-top .bt { line-height: 1.15; }
.hall-top .bt b { display: block; font-size: 17px; font-weight: 800; letter-spacing: -0.4px; }
.hall-top .bt i {
  display: block; font-style: normal; font-size: 10px; font-weight: 800;
  letter-spacing: 1.5px; text-transform: uppercase; color: var(--label3);
}
.hall-top .wallet {
  margin-left: auto; display: flex; align-items: center; gap: 6px;
  background: var(--tint-bg); color: var(--label);
  border: 1px solid var(--separator); border-radius: 999px; padding: 7px 13px;
  font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.hall-top .wallet .svgi { width: 14px; height: 14px; color: var(--accent); }
[data-theme="light"] .hall-top .wallet .svgi { color: #8fae08; }

.pagehead { display: flex; align-items: flex-end; gap: 10px; padding: 14px 16px 4px; }
.pagehead .body { flex: 1; min-width: 0; }
.pagehead .k {
  font-size: 10px; font-weight: 800; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--label3);
}
.pagehead h1 { font-size: 27px; font-weight: 800; letter-spacing: -0.7px; line-height: 1.1; margin-top: 3px; }
.pagehead .sub { font-size: 13px; color: var(--label2); margin-top: 4px; }
.pagehead .act {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 6px;
  border: none; font-family: inherit; cursor: pointer;
  background: var(--fill); color: var(--label); border-radius: 999px;
  font-size: 12.5px; font-weight: 700; padding: 8px 13px;
}
.pagehead .act .svgi { width: 14px; height: 14px; }
.pagehead .act:active { opacity: 0.7; }

.nav { padding: 14px 16px 4px; }
.nav .eyebrow {
  font-size: 10px; font-weight: 800; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--label3); margin-bottom: 3px;
}
.nav h1 { font-size: 27px; font-weight: 800; letter-spacing: -0.7px; line-height: 1.1; }
.nav .sub { font-size: 13px; color: var(--label2); margin-top: 4px; }

.group-header {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 800; letter-spacing: 1.3px;
  text-transform: uppercase; color: var(--label2);
  padding: 0 18px 8px; margin-top: 22px;
}
.group-header::before {
  content: ""; width: 3px; height: 12px; border-radius: 2px;
  background: var(--accent); flex-shrink: 0;
}
.sec { display: flex; align-items: center; gap: 8px; padding: 22px 18px 10px; }
.sec .t { font-size: 16px; font-weight: 800; letter-spacing: -0.3px; }
.sec .c {
  font-size: 11px; font-weight: 800; color: var(--label2);
  background: var(--fill); padding: 3px 8px; border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.sec .more { margin-left: auto; font-size: 12.5px; font-weight: 700; color: var(--label2); }

.list {
  background: var(--card); border: 1px solid var(--separator);
  border-radius: var(--radius); margin: 0 16px 8px; overflow: hidden;
  box-shadow: var(--shadow);
}
.row {
  display: flex; align-items: center; gap: 12px;
  min-height: 52px; padding: 11px 14px; position: relative;
  background: transparent;
}
.row + .row::before {
  content: ""; position: absolute; left: 14px; right: 0; top: 0;
  height: 1px; background: var(--separator);
}
.row.inset-sep + .row::before { left: 58px; }
.row.tappable { cursor: pointer; }
.row.tappable:active { background: var(--fill); }
.row .body { flex: 1; min-width: 0; }
.row .title { font-size: 15.5px; font-weight: 700; letter-spacing: -0.25px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .subtitle { font-size: 12.5px; color: var(--label2); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .value { font-size: 16px; font-weight: 800; color: var(--label); font-variant-numeric: tabular-nums; flex-shrink: 0; }
.row .value.win { color: var(--green); }
.row .value.loss { color: var(--red); }
.row .chevron { color: var(--label3); flex-shrink: 0; display: flex; }
.row .chevron .svgi { width: 16px; height: 16px; }
.row.empty { justify-content: center; color: var(--label2); font-size: 13.5px; padding: 20px 16px; text-align: center; }

.row.me { background: var(--tint-bg); }
.row.me::after {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--accent);
}

.svgi { width: 20px; height: 20px; display: block; flex-shrink: 0; }

.icon {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--fill); color: var(--label2);
}
.icon .svgi { width: 18px; height: 18px; }
.icon.blue { background: rgba(47, 123, 255, 0.14); color: var(--blue); }
.icon.green { background: rgba(18, 183, 106, 0.15); color: var(--green); }
.icon.orange { background: rgba(242, 135, 13, 0.15); color: var(--orange); }
.icon.purple { background: rgba(124, 92, 255, 0.16); color: var(--purple); }
.icon.gray { background: var(--fill); color: var(--label2); }
[data-theme="dark"] .icon.blue { background: rgba(76, 155, 255, 0.16); }
[data-theme="dark"] .icon.green { background: rgba(36, 209, 126, 0.16); }
[data-theme="dark"] .icon.orange { background: rgba(255, 159, 46, 0.16); }
[data-theme="dark"] .icon.purple { background: rgba(167, 139, 250, 0.18); }

.rankbox {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--fill); color: var(--label2);
  font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.rankbox .svgi { width: 18px; height: 18px; }
.rankbox.g { background: linear-gradient(145deg, #f7d774, #d4a017); color: #3d2c00; }
.rankbox.s { background: linear-gradient(145deg, #dfe4ea, #a8b0bb); color: #2b3038; }
.rankbox.b { background: linear-gradient(145deg, #e0a071, #b06d33); color: #33200c; }

.avatar {
  border-radius: 50%; flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(145deg, var(--card-alt), var(--fill));
  color: var(--label); font-weight: 800;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 62px; height: 62px; font-size: 25px; box-shadow: 0 0 0 2px var(--accent); }
.avatar.sm { width: 36px; height: 36px; font-size: 15px; }

.profile-card {
  padding: 16px;
  background: linear-gradient(150deg, var(--card-alt), var(--card) 62%);
}
.profile-top { display: flex; align-items: center; gap: 14px; }
.profile-top .name { font-size: 19px; font-weight: 800; letter-spacing: -0.45px; }
.profile-top .handle { font-size: 12.5px; color: var(--label2); margin-top: 2px; }
.badge-elo {
  margin-left: auto; flex-shrink: 0;
  display: inline-flex; align-items: center; gap: 5px;
  background: var(--accent); color: var(--accent-ink);
  border-radius: 999px; padding: 7px 13px;
  font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.badge-elo .svgi { width: 13px; height: 13px; color: var(--accent-ink); }

.winbar { margin-top: 14px; }
.winbar .lab {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 10px; font-weight: 800; letter-spacing: 1.1px;
  text-transform: uppercase; color: var(--label2); margin-bottom: 6px;
}
.winbar .lab b { color: var(--label); font-size: 13px; font-variant-numeric: tabular-nums; letter-spacing: 0; }
.winbar .track { height: 6px; border-radius: 999px; background: var(--fill); overflow: hidden; }
.winbar .track i { display: block; height: 100%; border-radius: 999px; background: var(--accent); }

.stat-strip {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--separator); margin: 16px -16px -16px; padding: 13px 0 15px;
}
.stat-strip .cell { text-align: center; position: relative; }
.stat-strip .cell + .cell::before {
  content: ""; position: absolute; left: 0; top: 12%; height: 76%; width: 1px; background: var(--separator);
}
.stat-strip .v { font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.5px; }
.stat-strip .k {
  font-size: 10px; font-weight: 700; letter-spacing: 0.8px;
  text-transform: uppercase; color: var(--label2); margin-top: 3px;
}

.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; border: none; cursor: pointer; font-family: inherit;
  background: var(--accent); color: var(--accent-ink);
  font-size: 15.5px; font-weight: 800; letter-spacing: -0.2px;
  padding: 15px; border-radius: 13px;
  transition: opacity 0.12s ease, transform 0.1s ease;
}
.btn .svgi { width: 17px; height: 17px; }
.btn:active { opacity: 0.82; transform: scale(0.985); }
.btn.tinted { background: transparent; color: var(--label); box-shadow: inset 0 0 0 1.5px var(--separator); }
.btn.gray-btn { background: var(--fill); color: var(--label); }
.btn.plain { background: transparent; color: var(--label2); font-weight: 700; }
.btn.danger { background: transparent; color: var(--red); font-weight: 700; }
.btn:disabled { opacity: 0.4; pointer-events: none; }
.btn-stack { padding: 0 16px; display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }

.mini-btn {
  border: none; cursor: pointer; font-family: inherit; flex-shrink: 0;
  background: var(--accent); color: var(--accent-ink);
  font-size: 13px; font-weight: 800; padding: 8px 14px; border-radius: 999px;
}
.mini-btn:active { opacity: 0.75; }
.mini-btn.green-btn { background: var(--green); color: #fff; }
.mini-btn.plain-btn { background: var(--fill); color: var(--label2); }
.mini-btn:disabled { opacity: 0.4; pointer-events: none; }
.row .btn-pair { display: flex; gap: 8px; flex-shrink: 0; }

.pill-state {
  font-size: 10px; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase;
  padding: 4px 9px; border-radius: 7px; background: var(--fill); color: var(--label2); flex-shrink: 0;
}
.pill-state.busy { background: rgba(229, 72, 77, 0.16); color: var(--red); }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  display: flex; background: var(--nav-blur);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--separator);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.tabbar .tab {
  position: relative; flex: 1; border: none; background: none; cursor: pointer; font-family: inherit;
  padding: 10px 0 8px; color: var(--label3);
  display: flex; flex-direction: column; align-items: center; gap: 3px;
}
.tabbar .tab::before {
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 26px; height: 2.5px; border-radius: 0 0 3px 3px; background: transparent;
}
.tabbar .tab .ti { position: relative; display: flex; }
.tabbar .tab .ti .svgi { width: 22px; height: 22px; }
.tabbar .tab .tl { font-size: 10px; font-weight: 700; letter-spacing: 0.2px; }
.tabbar .tab.on { color: var(--label); }
.tabbar .tab.on::before { background: var(--accent); }
.tabbar .tab.on .ti { opacity: 1; }
.tabbar .tab .dot {
  position: absolute; right: -4px; top: -2px;
  width: 8px; height: 8px; border-radius: 50%; background: var(--red);
}

.seg {
  display: flex; gap: 4px; background: var(--fill); border-radius: 12px;
  padding: 4px; margin: 12px 16px 0;
  overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.seg::-webkit-scrollbar { display: none; }
.seg-item {
  flex: 1 0 auto; min-width: 0; white-space: nowrap;
  border: none; cursor: pointer; background: none; font-family: inherit;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 12.5px; font-weight: 800; letter-spacing: -0.1px;
  padding: 9px 12px; border-radius: 9px; color: var(--label2);
  transition: background 0.15s ease, color 0.15s ease;
}
.seg-item .svgi { width: 15px; height: 15px; flex: 0 0 auto; }
.seg-item.on { background: var(--accent); color: var(--accent-ink); box-shadow: none; }
[data-theme="dark"] .seg-item.on { background: var(--accent); color: var(--accent-ink); }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 16px 16px 2px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--separator); cursor: pointer; font-family: inherit;
  background: var(--card); color: var(--label2);
  font-size: 12.5px; font-weight: 700; padding: 8px 14px; border-radius: 999px;
  transition: background 0.15s ease, color 0.15s ease;
}
.chip .svgi { width: 14px; height: 14px; }
.chip.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.chip:active { opacity: 0.8; }

.hero {
  position: relative; margin: 12px 16px 0; border-radius: 18px; overflow: hidden;
  background: #05070d; box-shadow: var(--shadow); cursor: pointer;
  transition: transform 0.12s ease;
}
.hero:active { transform: scale(0.99); }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero .hero-body {
  position: relative; padding: 18px; min-height: 176px;
  display: flex; flex-direction: column; justify-content: center;
}
.hero .kicker {
  display: inline-flex; align-items: center; gap: 5px; align-self: flex-start;
  color: #d4ff3d; font-size: 10px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase;
}
.hero .kicker .svgi { width: 12px; height: 12px; }
.hero h2 {
  color: #fff; font-size: 22px; font-weight: 800; letter-spacing: -0.5px;
  line-height: 1.12; margin: 6px 0 4px; max-width: 66%;
}
.hero .hsub { color: rgba(255, 255, 255, 0.68); font-size: 12.5px; max-width: 62%; line-height: 1.35; }
.hero .hcta {
  align-self: flex-start; margin-top: 12px; border: none; font-family: inherit; cursor: pointer;
  display: inline-flex; align-items: center; gap: 7px;
  background: #d4ff3d; color: #0a1f05; font-size: 13.5px; font-weight: 800;
  padding: 10px 16px; border-radius: 11px; letter-spacing: -0.2px;
}
.hero .hcta .svgi { width: 14px; height: 14px; }
.hero .hcta:active { opacity: 0.85; }

.gcard {
  position: relative; margin: 0 16px 12px; border-radius: 16px; overflow: hidden;
  background: #0b1018; cursor: pointer; box-shadow: var(--shadow);
  transition: transform 0.12s ease;
  display: flex; flex-direction: column; justify-content: flex-end; min-height: 212px;
}
.gcard:active { transform: scale(0.985); }
.gcard > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.gcard .top {
  position: absolute; top: 10px; left: 10px; right: 10px;
  display: flex; align-items: flex-start; gap: 6px;
}
.tagpill {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 10px; font-weight: 800; letter-spacing: 0.7px; text-transform: uppercase;
  padding: 5px 9px; border-radius: 8px; white-space: nowrap;
  background: rgba(6, 10, 16, 0.62); color: #fff;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.tagpill .svgi { width: 11px; height: 11px; }
.tagpill.live { background: rgba(230, 45, 45, 0.92); }
.tagpill.live .svgi { animation: livedot 1.5s ease-in-out infinite; }
@keyframes livedot { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
.tagpill.hot { background: rgba(255, 122, 0, 0.92); }
.tagpill.odds { margin-left: auto; background: rgba(212, 255, 61, 0.94); color: #0a1f05; }

.gcard .info {
  position: relative; padding: 58px 14px 14px;
  display: flex; align-items: flex-end; gap: 10px;
  background: linear-gradient(to top, rgba(3, 6, 11, 0.94) 12%, rgba(3, 6, 11, 0.55) 62%, rgba(3, 6, 11, 0));
}
.gcard .info .body { flex: 1; min-width: 0; }
.gcard .gname { color: #fff; font-size: 18px; font-weight: 800; letter-spacing: -0.45px; }
.gcard .gsub { color: rgba(255, 255, 255, 0.62); font-size: 12px; margin-top: 2px; }
.gcard .meta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.gcard .meta span {
  display: inline-flex; align-items: center; gap: 4px;
  color: rgba(255, 255, 255, 0.7); font-size: 11.5px; font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.gcard .meta .svgi { width: 13px; height: 13px; }
.gcard .cta {
  flex-shrink: 0; border: none; font-family: inherit; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  background: #d4ff3d; color: #0a1f05;
  font-size: 13px; font-weight: 800; padding: 10px 15px; border-radius: 11px;
}
.gcard .cta .svgi { width: 13px; height: 13px; }
.gcard .cta:active { opacity: 0.85; }

.soon-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 16px; }
.scard {
  position: relative; border-radius: 14px; overflow: hidden; background: #0b1018;
  box-shadow: var(--shadow);
}
.scard > img {
  width: 100%; display: block; aspect-ratio: 4 / 3; object-fit: cover;
  filter: grayscale(0.7) brightness(0.55);
}
.scard .sinfo {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 10px;
  background: linear-gradient(to top, rgba(3, 6, 11, 0.92), rgba(3, 6, 11, 0));
}
.scard .sn { color: #fff; font-size: 13.5px; font-weight: 800; letter-spacing: -0.2px; }
.scard .ss { color: rgba(255, 255, 255, 0.55); font-size: 11px; margin-top: 1px; }
.scard .slock {
  position: absolute; top: 8px; right: 8px;
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(6, 10, 16, 0.7); color: rgba(255, 255, 255, 0.8);
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.6px; text-transform: uppercase;
  padding: 4px 7px; border-radius: 7px;
}
.scard .slock .svgi { width: 10px; height: 10px; }

.hall-note {
  display: flex; align-items: center; gap: 10px; margin: 18px 16px 6px;
  padding: 12px 14px; border-radius: 12px;
  background: var(--card); border: 1px solid var(--separator);
  color: var(--label2); font-size: 12.5px; line-height: 1.4;
}
.hall-note .svgi { width: 18px; height: 18px; color: var(--label3); flex-shrink: 0; }

.code-card {
  position: relative; padding: 22px 16px 20px; text-align: center;
  background:
    radial-gradient(90% 120% at 50% 0%, var(--tint-bg), transparent 62%),
    var(--card);
}
.code-card::before, .code-card::after {
  content: ""; position: absolute; bottom: -9px; width: 18px; height: 18px;
  border-radius: 50%; background: var(--bg);
}
.code-card::before { left: -9px; }
.code-card::after { right: -9px; }
.code-label {
  font-size: 10px; font-weight: 800; color: var(--label2);
  text-transform: uppercase; letter-spacing: 1.5px;
}
.code-value {
  font-size: 40px; font-weight: 800; letter-spacing: 8px; margin: 10px 0 4px;
  font-variant-numeric: tabular-nums; text-indent: 8px; color: var(--label);
  font-family: "SF Mono", ui-monospace, "Cascadia Mono", monospace;
}
.code-hint { font-size: 12px; color: var(--label2); }

.code-input {
  width: 100%; border: 1.5px solid var(--separator); outline: none;
  font-family: "SF Mono", ui-monospace, monospace;
  background: var(--card-alt); color: var(--label); border-radius: 12px;
  font-size: 27px; font-weight: 800; letter-spacing: 6px; text-align: center;
  padding: 15px 10px; text-transform: uppercase;
  transition: border-color 0.15s ease;
}
.code-input:focus { border-color: var(--accent); }
.code-input::placeholder { color: var(--label3); letter-spacing: 4px; }

.waiting-anim { text-align: center; padding: 18px 0 4px; }
.waiting-anim .bounce-ball {
  display: inline-flex; padding: 7px; border-radius: 50%; background: #fff; color: #14351f;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3); animation: bob 1.2s ease-in-out infinite;
}
.waiting-anim .bounce-ball .svgi { width: 34px; height: 34px; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
.waiting-anim .txt {
  font-size: 11px; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase;
  color: var(--label2); margin-top: 12px;
}

.qs-stage { text-align: center; padding: 26px 16px 18px; }
.qs-radar { position: relative; width: 136px; height: 136px; margin: 0 auto; }
.qs-radar i {
  position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid var(--accent); opacity: 0;
  animation: qsPing 2.4s cubic-bezier(0.2, 0.6, 0.3, 1) infinite;
}
.qs-radar i:nth-child(2) { animation-delay: 0.8s; }
.qs-radar i:nth-child(3) { animation-delay: 1.6s; }
.qs-core {
  position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: var(--accent); color: var(--accent-ink);
  box-shadow: 0 0 0 8px var(--tint-bg), var(--shadow);
}
.qs-core .svgi { width: 30px; height: 30px; }
@keyframes qsPing { 0% { transform: scale(0.45); opacity: 0.9; } 100% { transform: scale(1); opacity: 0; } }
.qs-clock {
  margin-top: 16px; font-size: 30px; font-weight: 800; letter-spacing: 1px; color: var(--label);
  font-variant-numeric: tabular-nums; font-family: "SF Mono", ui-monospace, "Cascadia Mono", monospace;
}
.qs-hint { font-size: 13px; color: var(--label2); margin-top: 4px; }
.qs-val {
  font-size: 14.5px; font-weight: 700; color: var(--label); flex-shrink: 0; max-width: 52%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.qs-more { margin-top: 14px; }
.qs-sum {
  display: flex; align-items: center; gap: 10px; list-style: none; cursor: pointer;
  margin: 0 16px 8px; padding: 13px 14px; border-radius: var(--radius);
  background: var(--card); border: 1px dashed var(--separator);
  font-size: 14.5px; font-weight: 700; color: var(--label2);
}
.qs-sum::-webkit-details-marker { display: none; }
.qs-sum:active { background: var(--fill); }
.qs-sum span { flex: 1; }
.qs-sum .svgi { width: 18px; height: 18px; flex-shrink: 0; }
.qs-sum .svgi:last-child {
  width: 16px; height: 16px; color: var(--label3);
  transform: rotate(90deg); transition: transform 0.2s ease;
}
.qs-more[open] .qs-sum .svgi:last-child { transform: rotate(-90deg); }
.qs-more .group-header { margin-top: 14px; }
@media (prefers-reduced-motion: reduce) {
  .qs-radar i { animation: none; opacity: 0.3; }
  .qs-radar i:nth-child(2) { transform: scale(0.72); }
  .qs-radar i:nth-child(3) { display: none; }
}

.match-head {
  display: flex; align-items: flex-start; gap: 10px;
  margin: 12px 16px 10px; padding: 14px 14px 12px;
  border-radius: var(--radius); background: var(--card);
  border: 1px solid var(--separator); box-shadow: var(--shadow);
}
.match-head .side { flex: 1; min-width: 0; }
.match-head .side.right { text-align: right; }
.match-head .pn {
  font-size: 11px; font-weight: 800; letter-spacing: 0.9px; text-transform: uppercase;
  color: var(--label2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.match-head .score {
  font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums;
  letter-spacing: -1.4px; flex-shrink: 0; padding: 0 6px; line-height: 1;
}
.pips { display: flex; gap: 5px; margin-top: 9px; }
.side.right .pips { justify-content: flex-end; }
.pip { width: 9px; height: 9px; border-radius: 3px; background: var(--fill); }
.pip.goal { background: var(--green); }
.pip.miss { background: var(--red); }
.pip.now { background: var(--accent); animation: pulse 1.1s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

.timer { height: 4px; background: var(--fill); border-radius: 999px; margin: 0 16px 12px; overflow: hidden; }
.timer .fill { height: 100%; background: var(--accent); border-radius: 999px; width: 100%; }
.timer .fill.low { background: var(--red); }

.pitch {
  position: relative; margin: 0 16px; border-radius: var(--radius); overflow: hidden;
  padding: 30px 14px 58px;
  background:
    radial-gradient(120% 70% at 50% 4%, rgba(212, 255, 61, 0.10), transparent 60%),
    linear-gradient(178deg, #1a5f40 0%, #14522f 48%, #0a3020 100%);
  box-shadow: inset 0 -30px 50px rgba(0, 0, 0, 0.35);
}
.pitch::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,0.05) 0 22px, transparent 22px 44px);
  opacity: 0.6;
}
.stands {
  position: absolute; left: 0; right: 0; top: 0; height: 34px;
  background:
    radial-gradient(60% 140% at 50% 0%, rgba(212, 255, 61, 0.18), transparent 70%),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.07) 0 3px, transparent 3px 7px),
    #071c14;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.goalframe {
  position: relative; height: 160px; max-width: 306px; margin: 0 auto;
  border: 5px solid rgba(255, 255, 255, 0.96); border-bottom: none;
  border-radius: 4px 4px 0 0;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
  background:
    repeating-linear-gradient(0deg, transparent 0 10px, rgba(255,255,255,0.10) 10px 11px),
    repeating-linear-gradient(90deg, transparent 0 10px, rgba(255,255,255,0.10) 10px 11px),
    linear-gradient(180deg, rgba(0,0,0,0.20), rgba(0,0,0,0.05));
}
.keeper {
  position: absolute; left: 50%; bottom: 3px; z-index: 2;
  transform: translateX(-50%);
  transition: transform 0.42s cubic-bezier(0.22, 0.9, 0.3, 1.05);
}
.keeper .chr {
  width: 56px; height: 70px; transform-origin: 50% 100%;
  filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.4));
  animation: kp-ready 1.5s ease-in-out infinite;
}
@keyframes kp-ready {
  0%, 100% { transform: translateX(-5px) scaleY(1); }
  50% { transform: translateX(5px) scaleY(0.955); }
}
.keeper.d0 .chr, .keeper.d1 .chr, .keeper.d2 .chr { animation: none; }
.goal-zones.live + .keeper { opacity: 0.45; transition: opacity 0.2s ease; }
.keeper.d0 { transform: translateX(-50%) translate(-92px, -34px) rotate(-52deg); }
.keeper.d1 { transform: translateX(-50%) translateY(-52px) scale(1.05); }
.keeper.d2 { transform: translateX(-50%) translate(92px, -34px) rotate(52deg); }
.keeper.saved .chr { animation: kp-cheer 0.45s ease 2; }
@keyframes kp-cheer { 50% { transform: translateY(-7px); } }
.striker {
  position: absolute; left: 50%; bottom: 6px; z-index: 3;
  transform: translateX(-84px); pointer-events: none;
}
.striker .chr {
  width: 53px; height: 66px; transform-origin: 50% 100%;
  filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.4));
  animation: st-idle 1.15s ease-in-out infinite;
}
@keyframes st-idle {
  0%, 100% { transform: scaleY(1); }
  50% { transform: scaleY(0.96) translateY(1px); }
}
.striker.kick { animation: st-kick 0.5s cubic-bezier(0.3, 0, 0.3, 1) forwards; }
.striker.kick .chr { animation: none; }
@keyframes st-kick {
  0%   { transform: translateX(-84px) rotate(0deg); }
  45%  { transform: translateX(-58px) rotate(-14deg); }
  70%  { transform: translateX(-40px) rotate(16deg); }
  100% { transform: translateX(-46px) rotate(8deg); }
}
.ball {
  position: absolute; left: 50%; bottom: 16px; z-index: 3;
  background: #fff; color: #123322; border-radius: 50%; padding: 2px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.35);
  transform: translateX(-50%);
  transition: transform 0.46s cubic-bezier(0.16, 0.72, 0.32, 1);
}
.ball .svgi { width: 24px; height: 24px; }
.ball.fly .svgi { animation: ballspin 0.65s cubic-bezier(0.2, 0.6, 0.4, 1); }
@keyframes ballspin { to { transform: rotate(720deg); } }
.goalframe.netshake { animation: netshake 0.55s ease; }
@keyframes netshake {
  25% { transform: translateY(2px) scaleY(0.985); }
  50% { transform: translateY(-1px); }
  75% { transform: translateY(1px); }
}
.pitch.goalglow .stands { animation: flashbulbs 1s ease; }
@keyframes flashbulbs {
  0%, 100% { filter: brightness(1); }
  20% { filter: brightness(2.1); }
  45% { filter: brightness(1.2); }
  65% { filter: brightness(1.8); }
}
.pitch.shake { animation: pitchshake 0.45s ease; }
@keyframes pitchshake {
  20% { transform: translateX(-5px); }
  40% { transform: translateX(4px); }
  60% { transform: translateX(-3px); }
  80% { transform: translateX(2px); }
}
.burst { position: absolute; inset: -20px 0 0; z-index: 6; pointer-events: none; }
.burst i {
  position: absolute; top: 45%; width: 7px; height: 11px; border-radius: 2px;
  opacity: 0; animation: conf 1.05s cubic-bezier(0.2, 0.7, 0.4, 1) forwards;
}
@keyframes conf {
  0% { opacity: 1; transform: translate(0, 0) rotate(0deg); }
  55% { opacity: 1; transform: translate(var(--dx), var(--dy)) rotate(var(--rot)); }
  100% { opacity: 0; transform: translate(calc(var(--dx) * 1.3), 60px) rotate(calc(var(--rot) * 1.6)); }
}
.goal-zones { position: absolute; inset: 0; z-index: 4; display: none; }
.goal-zones.live { display: grid; grid-template-columns: repeat(3, 1fr); }
.gzone {
  border: none; cursor: pointer; font-family: inherit; position: relative;
  background: rgba(255, 255, 255, 0.05);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  color: rgba(255, 255, 255, 0.9);
  transition: background 0.15s ease, transform 0.12s ease;
}
.gzone + .gzone { border-left: 1px dashed rgba(255, 255, 255, 0.22); }
.gzone:active { transform: scale(0.97); }
.gzone .gz-mark {
  display: flex; opacity: 0.55; transition: opacity 0.15s ease, transform 0.15s ease;
}
.gzone .gz-mark .svgi { width: 26px; height: 26px; }
.goal-zones.live .gzone:not(.on) .gz-mark { animation: zone-hint 1.3s ease-in-out infinite; }
.goal-zones.live .gzone:nth-child(2):not(.on) .gz-mark { animation-delay: 0.18s; }
.goal-zones.live .gzone:nth-child(3):not(.on) .gz-mark { animation-delay: 0.36s; }
@keyframes zone-hint { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.gzone .gz-lab {
  font-size: 10px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}
.goal-zones.shoot .gzone:hover { background: rgba(212, 255, 61, 0.16); }
.goal-zones.save .gzone:hover { background: rgba(76, 155, 255, 0.16); }
.gzone.on {
  background: rgba(212, 255, 61, 0.28);
  box-shadow: inset 0 0 0 2px var(--accent);
}
.goal-zones.save .gzone.on { background: rgba(76, 155, 255, 0.3); box-shadow: inset 0 0 0 2px #7cb8ff; }
.gzone.on .gz-mark { opacity: 1; transform: scale(1.12); }
.gzone:disabled { opacity: 0.35; pointer-events: none; }
.goal-zones.locked { pointer-events: none; }

.spot { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); width: 6px; height: 6px; background: rgba(255,255,255,0.75); border-radius: 50%; }
.verdict {
  position: absolute; inset: 0; z-index: 5; pointer-events: none;
  display: flex; align-items: center; justify-content: center;
  font-size: 36px; font-weight: 800; letter-spacing: 1.5px; color: #fff;
  text-transform: uppercase;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.55), 0 0 26px rgba(255, 255, 255, 0.25);
  opacity: 0;
}
.verdict.show { opacity: 1; animation: verdict-pop 0.55s cubic-bezier(0.2, 1.4, 0.4, 1); }
@keyframes verdict-pop {
  0% { transform: scale(0.3) rotate(-8deg); }
  60% { transform: scale(1.18) rotate(3deg); }
  100% { transform: none; }
}

.status {
  text-align: center; font-size: 12.5px; font-weight: 700; color: var(--label2);
  min-height: 20px; padding: 16px 20px 4px; letter-spacing: 0.2px;
}
.status.hot { color: var(--label); }
.status.sudden { color: var(--orange); text-transform: uppercase; letter-spacing: 1px; font-size: 11.5px; font-weight: 800; }

.picker { padding: 10px 16px 0; }
.picker .hint {
  font-size: 10.5px; font-weight: 800; letter-spacing: 1.3px; text-transform: uppercase;
  color: var(--label3); text-align: center; padding-bottom: 12px;
}
.zones { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.zone {
  border: 1px solid var(--separator); cursor: pointer; font-family: inherit;
  background: var(--card); color: var(--label); border-radius: 13px;
  padding: 16px 0; box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.1s ease, background 0.15s ease;
}
.zone:active { transform: scale(0.95); }
.zone .svgi { width: 26px; height: 26px; }
.zone.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.zone:disabled { opacity: 0.35; pointer-events: none; }

.rps-stage {
  position: relative; margin: 0 16px; border-radius: var(--radius); overflow: hidden;
  min-height: 200px; padding: 0 26px;
  display: flex; align-items: center; justify-content: space-between;
  perspective: 620px; perspective-origin: 50% 38%;
  background:
    radial-gradient(120% 95% at 12% 8%, rgba(212, 255, 61, 0.14), transparent 55%),
    radial-gradient(120% 95% at 88% 92%, rgba(124, 92, 255, 0.18), transparent 55%),
    var(--card);
  border: 1px solid var(--separator);
}
.rps-stage.hit { animation: stagehit 0.32s ease; }
@keyframes stagehit {
  20% { transform: perspective(600px) rotateY(3deg) translateX(-4px); }
  45% { transform: perspective(600px) rotateY(-3deg) translateX(4px); }
  70% { transform: perspective(600px) rotateY(1deg); }
}

.rps-floor {
  position: absolute; left: -12%; right: -12%; bottom: 4px; height: 110px;
  z-index: 0; pointer-events: none;
  transform: rotateX(64deg); transform-origin: 50% 100%;
  background:
    radial-gradient(60% 70% at 50% 45%, rgba(212, 255, 61, 0.08), transparent 70%),
    repeating-linear-gradient(0deg, var(--separator) 0 1px, transparent 1px 22px),
    repeating-linear-gradient(90deg, var(--separator) 0 1px, transparent 1px 26px);
  opacity: 0.55;
  -webkit-mask-image: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent 85%);
  mask-image: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent 85%);
}

.rps-hand {
  z-index: 2; color: var(--label);
  --face: calc(var(--dir) * 20deg);
  transform-style: preserve-3d;
  transform: rotateY(var(--face));
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.28));
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.25s ease, opacity 0.25s ease;
}
.rps-hand.left { --dir: 1; }
.rps-hand.right { --dir: -1; }
.rps-hand .inner { display: inline-block; transform-style: preserve-3d; transition: transform 0.15s ease; }
.rps-hand .inner .svgi { width: 62px; height: 62px; stroke-width: 1.5; }
.rps-hand .inner.show { transform: scale(1.06); animation: flipopen 0.45s cubic-bezier(0.2, 1.3, 0.4, 1); }
@keyframes flipopen {
  0% { transform: rotateY(calc(var(--dir) * 90deg)) scale(0.7); }
  100% { transform: rotateY(0deg) scale(1.06); }
}

.rps-hand.shaking { animation: pump 0.3s ease-in-out 3; }
@keyframes pump {
  0%, 100% { transform: rotateY(var(--face)) translateY(0) translateZ(0); }
  35% { transform: rotateY(var(--face)) translateY(-20px) translateZ(55px) rotateX(26deg) rotateZ(calc(var(--dir) * -6deg)); }
  70% { transform: rotateY(var(--face)) translateY(5px) translateZ(-18px) rotateX(-9deg); }
}
.rps-hand.slam { transform: rotateY(var(--face)) translateX(calc(var(--dir) * 18px)) translateZ(60px); }
.rps-hand.winner {
  transform: rotateY(var(--face)) translateX(calc(var(--dir) * 18px)) translateZ(120px) scale(1.05);
  color: var(--accent);
  filter: drop-shadow(0 0 20px rgba(212, 255, 61, 0.45));
}
.rps-hand.loser {
  transform: rotateY(var(--face)) translateX(calc(var(--dir) * 18px)) translateZ(-90px) rotateX(-32deg) scale(0.92);
  opacity: 0.4; filter: grayscale(0.8) drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}
.rps-hand.tie { transform: rotateY(var(--face)) translateX(calc(var(--dir) * 6px)) translateZ(22px); }

.rps-vs {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  font-size: 13px; font-weight: 800; letter-spacing: 2px;
  color: var(--label3); z-index: 1; text-align: center; min-width: 90px;
  text-transform: uppercase;
}
.rps-vs.count { font-size: 16px; color: var(--label2); animation: countflip 0.3s ease infinite; }
@keyframes countflip {
  0% { transform: translate(-50%, -50%) rotateX(-75deg) scale(0.8); opacity: 0.35; }
  55% { transform: translate(-50%, -50%) rotateX(10deg) scale(1.08); opacity: 1; }
  100% { transform: translate(-50%, -50%) rotateX(0deg) scale(1); }
}

.clash-flash {
  position: absolute; left: 50%; top: 50%; width: 130px; height: 130px;
  margin: -65px 0 0 -65px; border-radius: 50%; z-index: 3; pointer-events: none;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0) 62%);
  transform: scale(0.1); opacity: 0;
}
.clash-flash.boom { animation: boom 0.5s ease-out; }
@keyframes boom {
  0% { transform: scale(0.15); opacity: 0.95; }
  100% { transform: scale(1.8); opacity: 0; }
}

.rps-verdict {
  position: absolute; left: 0; right: 0; bottom: 12px; z-index: 4; pointer-events: none;
  text-align: center; font-size: 13px; font-weight: 800; letter-spacing: 0.3px;
  transform-origin: 50% 100%;
  opacity: 0; transform: perspective(400px) rotateX(-65deg) translateY(8px);
  transition: opacity 0.2s ease, transform 0.3s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.rps-verdict.show { opacity: 1; transform: perspective(400px) rotateX(0deg) translateY(0); }

.rps-zones { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; perspective: 700px; }
.rps-zone {
  border: 1px solid var(--separator); cursor: pointer; font-family: inherit;
  background: var(--card); border-radius: 14px; padding: 15px 0 12px;
  box-shadow: var(--shadow); transform-style: preserve-3d;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  transition: transform 0.12s ease, background 0.15s ease;
}
.rps-zone .e { display: flex; color: var(--label); }
.rps-zone .e .svgi { width: 32px; height: 32px; }
.rps-zone .l {
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.9px;
  text-transform: uppercase; color: var(--label2);
}
.rps-zone:active { transform: rotateX(14deg) scale(0.94); }
.rps-zone.on { background: var(--accent); border-color: var(--accent); animation: zonepick 0.5s cubic-bezier(0.3, 1.2, 0.4, 1); }
@keyframes zonepick {
  0% { transform: rotateY(0deg) translateZ(0); }
  50% { transform: rotateY(180deg) translateZ(36px); }
  100% { transform: rotateY(360deg) translateZ(0); }
}
.rps-zone.on .e { color: var(--accent-ink); }
.rps-zone.on .l { color: var(--accent-ink); }
.rps-zone:disabled { opacity: 0.35; pointer-events: none; }

.result {
  margin: 14px 16px 0; padding: 28px 20px 22px; text-align: center;
  border-radius: 18px; border: 1px solid var(--separator);
  background:
    radial-gradient(100% 90% at 50% 0%, var(--tint-bg), transparent 60%),
    var(--card);
  box-shadow: var(--shadow);
}
.result .emo {
  width: 78px; height: 78px; margin: 0 auto; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--fill); color: var(--label2);
}
.result .emo .svgi { width: 40px; height: 40px; }
.result .emo.win { background: var(--accent); color: var(--accent-ink); }
.result .emo.loss { background: rgba(229, 72, 77, 0.14); color: var(--red); }
.result h2 {
  font-size: 26px; font-weight: 800; letter-spacing: -0.6px; margin: 14px 0 4px;
  text-transform: uppercase;
}
.result h2.win { color: var(--label); }
.result h2.loss { color: var(--label2); }
.result .sc { font-size: 14px; color: var(--label2); font-variant-numeric: tabular-nums; }
.result .elo {
  display: inline-block; margin-top: 12px; padding: 7px 14px; border-radius: 999px;
  background: var(--fill); font-size: 13px; font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.result .elo.up { background: rgba(18, 183, 106, 0.15); color: var(--green); }
.result .elo.down { background: rgba(229, 72, 77, 0.14); color: var(--red); }

.note { font-size: 12.5px; color: var(--label2); padding: 10px 20px 0; line-height: 1.45; }
.note.center { text-align: center; }
.note.err { color: var(--red); font-weight: 700; }

.error-page { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 80vh; padding: 0 32px; text-align: center; }
.error-page .e {
  width: 84px; height: 84px; border-radius: 50%; display: flex;
  align-items: center; justify-content: center;
  background: var(--fill); color: var(--label3);
}
.error-page .e .svgi { width: 40px; height: 40px; }
.error-page .t { font-size: 15px; color: var(--label2); margin-top: 18px; line-height: 1.45; }

.toast {
  position: fixed; left: 50%; bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%) translateY(10px); z-index: 100;
  background: #10151d; color: #fff; border: 1px solid rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  font-size: 13px; font-weight: 700; padding: 11px 18px; border-radius: 999px;
  opacity: 0; transition: opacity 0.2s ease, transform 0.2s ease; pointer-events: none; max-width: 88vw;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.dice-stage {
  position: relative; margin: 0 16px; border-radius: var(--radius); overflow: hidden;
  min-height: 200px; padding: 18px 12px 34px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  background:
    radial-gradient(120% 95% at 14% 6%, rgba(212, 255, 61, 0.13), transparent 55%),
    radial-gradient(120% 95% at 86% 94%, rgba(242, 135, 13, 0.16), transparent 55%),
    var(--card);
  border: 1px solid var(--separator);
}
.dice-stage.hit { animation: stagehit 0.32s ease; }

.dtray {
  flex: 1; min-width: 0; display: flex; flex-direction: column;
  align-items: center; gap: 10px;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease;
}
.dtray.winner { transform: scale(1.08); }
.dtray.loser { transform: scale(0.9); opacity: 0.45; }

.die-svg { width: clamp(26px, 9vw, 38px); height: clamp(26px, 9vw, 38px); display: block; color: var(--label); }

.d3-slot { display: flex; flex-direction: column; align-items: center; }
.d3-slot::after {
  content: ""; width: 58%; height: 8px; margin-top: 6px; border-radius: 50%;
  background: radial-gradient(50% 50% at 50% 50%, rgba(0, 0, 0, 0.4), transparent 72%);
  opacity: 0.85;
}
.d3-wrap {
  --die: clamp(58px, 17vw, 76px);
  width: var(--die); height: var(--die);
  perspective: 640px; perspective-origin: 50% 42%;
}
.d3-slot.idle .d3 { opacity: 0.5; }
.d3-slot.throw .d3-wrap { animation: dthrow 1.15s cubic-bezier(0.2, 0.7, 0.3, 1); }
.d3-slot.throw::after { animation: dshadow 1.15s cubic-bezier(0.2, 0.7, 0.3, 1); }
@keyframes dshadow {
  0%   { transform: scale(1); opacity: 0.85; }
  20%  { transform: scale(0.7); opacity: 0.35; }
  58%  { transform: scale(1.06); opacity: 0.9; }
  100% { transform: scale(1); opacity: 0.85; }
}
@keyframes dthrow {
  0%   { transform: translateY(0) scale(1); }
  20%  { transform: translateY(-30px) scale(1.07); }
  58%  { transform: translateY(3px) scale(0.96); }
  76%  { transform: translateY(-7px) scale(1.02); }
  100% { transform: translateY(0) scale(1); }
}
.d3 {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d;
  transition: transform 1.15s cubic-bezier(0.16, 0.7, 0.2, 1), opacity 0.25s ease;
}
.d3f {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: 15px; border: 1px solid var(--separator); color: var(--label);
  background-color: var(--card-alt);
  background-image: linear-gradient(155deg, var(--card-alt), var(--card));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backface-visibility: hidden;
}
.d3f .die-svg { width: 84%; height: 84%; }
.d3f .die-svg rect { display: none; }
.d3f.f5 { filter: brightness(1.14); }
.d3f.f2 { filter: brightness(0.82); }
.d3f.f3, .d3f.f4 { filter: brightness(0.93); }
.d3f.f6 { filter: brightness(0.88); }
.d3f.f1 { transform: translateZ(calc(var(--die) / 2)); }
.d3f.f6 { transform: rotateY(180deg) translateZ(calc(var(--die) / 2)); }
.d3f.f3 { transform: rotateY(90deg) translateZ(calc(var(--die) / 2)); }
.d3f.f4 { transform: rotateY(-90deg) translateZ(calc(var(--die) / 2)); }
.d3f.f5 { transform: rotateX(90deg) translateZ(calc(var(--die) / 2)); }
.d3f.f2 { transform: rotateX(-90deg) translateZ(calc(var(--die) / 2)); }
@media (prefers-reduced-motion: reduce) {
  .d3 { transition-duration: 0.3s; }
  .d3-slot.throw .d3-wrap, .d3-slot.throw::after { animation: none; }
}

.dtotal {
  font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums;
  letter-spacing: -0.5px; color: var(--label3);
}
.dtotal.on { color: var(--label); }
.dtotal.bust { color: var(--red); font-size: 15px; letter-spacing: 1.2px; }

.dice-vs {
  flex-shrink: 0; font-size: 12px; font-weight: 800; letter-spacing: 1.6px;
  color: var(--label3); text-transform: uppercase; min-width: 46px; text-align: center;
}
.dice-vs.count { color: var(--accent); animation: pulse 0.9s ease-in-out infinite; }

.dmult {
  font-size: 10px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase;
  color: var(--label3); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.av-hist {
  display: flex; gap: 6px; overflow-x: auto; padding: 12px 16px 2px;
  scrollbar-width: none;
}
.av-hist::-webkit-scrollbar { display: none; }
.av-pill {
  flex: 0 0 auto; font-size: 11px; font-weight: 800; padding: 5px 9px;
  border-radius: 999px; font-variant-numeric: tabular-nums;
  background: var(--fill); color: var(--label2);
}
.av-pill.bad { color: #ff6b7d; background: rgba(255, 77, 94, 0.14); }
.av-pill.good { color: var(--green); background: rgba(36, 209, 126, 0.14); }
.av-pill.gold { color: #ffd54a; background: rgba(255, 213, 74, 0.16); }

.av-sky {
  position: relative; margin: 12px 16px 0; height: 236px;
  border-radius: 18px; overflow: hidden;
  background:
    radial-gradient(120% 90% at 20% 100%, rgba(255, 45, 85, 0.16), transparent 60%),
    radial-gradient(100% 80% at 90% 0%, rgba(124, 92, 255, 0.18), transparent 60%),
    linear-gradient(160deg, #1a0b1e, #0a0611 70%);
  border: 1px solid var(--separator);
}
.av-sky::before {
  content: ""; position: absolute; inset: 0; opacity: 0.5;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.045) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(180deg, rgba(255,255,255,0.045) 0 1px, transparent 1px 44px);
  background-position: 0 0, 0 0;
}
.av-sky.flying::before { animation: avscroll 1.1s linear infinite; }
@keyframes avscroll {
  to { background-position: -44px 0, 0 44px; }
}
.av-sky::after {
  content: ""; position: absolute; inset: 0; opacity: 0; pointer-events: none;
  background:
    radial-gradient(2px 2px at 12% 24%, rgba(255,255,255,0.7), transparent 60%),
    radial-gradient(1.5px 1.5px at 46% 62%, rgba(255,255,255,0.5), transparent 60%),
    radial-gradient(2px 2px at 74% 18%, rgba(255,255,255,0.6), transparent 60%),
    radial-gradient(1.5px 1.5px at 88% 76%, rgba(255,255,255,0.45), transparent 60%),
    radial-gradient(1px 1px at 30% 86%, rgba(255,255,255,0.5), transparent 60%);
  background-size: 240px 200px;
  transition: opacity 0.4s ease;
}
.av-sky.flying::after { opacity: 0.7; animation: avstars 0.9s linear infinite; }
@keyframes avstars {
  to { background-position: -240px 200px; }
}
.av-sky.crashed::after {
  opacity: 1; background: radial-gradient(75% 75% at 62% 38%, rgba(255, 59, 92, 0.35), transparent 70%);
  background-size: auto; animation: avflash 0.6s ease-out forwards;
}
@keyframes avflash {
  from { opacity: 1; }
  to { opacity: 0; }
}
.av-curve { position: absolute; inset: 0; width: 100%; height: 100%; }

.av-plane {
  position: absolute; left: 4%; bottom: 6%; z-index: 3;
  color: #ff3b5c; transform: translate(-50%, 50%) rotate(-18deg);
  filter: drop-shadow(0 0 10px rgba(255, 59, 92, 0.6));
  will-change: left, bottom, transform;
}
.av-plane .svgi { width: 34px; height: 34px; }
.av-sky.betting .av-plane { opacity: 0.35; }
.av-sky.flying .av-plane { opacity: 1; }
.av-sky.crashed .av-plane {
  transition: transform 0.55s cubic-bezier(0.5, 0, 1, 1), opacity 0.55s ease;
  transform: translate(280px, -200px) rotate(32deg); opacity: 0;
}

.av-center {
  position: absolute; inset: 0; z-index: 4; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.av-mult {
  font-size: 46px; font-weight: 800; letter-spacing: -1.5px; color: #fff;
  font-variant-numeric: tabular-nums; text-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}
.av-mult.boom {
  color: #ff4d5e; text-shadow: 0 0 28px rgba(255, 60, 80, 0.55);
  animation: avboom 0.5s cubic-bezier(0.2, 1.6, 0.4, 1);
}
@keyframes avboom {
  0% { transform: scale(1.5); }
  100% { transform: scale(1); }
}
.av-phase {
  font-size: 11px; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6); margin-top: 6px;
}
.av-sky.crashed .av-phase { color: #ff6b7d; }

.av-bar {
  position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
  background: rgba(255, 255, 255, 0.08); z-index: 5;
}
.av-bar i { display: block; height: 100%; width: 0%; background: var(--accent); transition: width 0.1s linear; }

.av-panel {
  margin: 14px 16px 0; padding: 14px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--separator); box-shadow: var(--shadow);
}
.av-amount { display: flex; align-items: center; gap: 10px; }
.av-step {
  width: 44px; height: 44px; flex-shrink: 0; border: none; cursor: pointer;
  font-family: inherit; font-size: 22px; font-weight: 800;
  background: var(--fill); color: var(--label); border-radius: 12px;
}
.av-step:active { opacity: 0.7; }
.av-val {
  flex: 1; text-align: center; display: flex; align-items: baseline;
  justify-content: center; gap: 6px;
}
.av-val b { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.6px; }
.av-val span { font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--label2); letter-spacing: 1px; }

.av-chips { display: flex; gap: 8px; margin-top: 10px; }
.av-chip {
  flex: 1; border: 1px solid var(--separator); cursor: pointer; font-family: inherit;
  background: transparent; color: var(--label2);
  font-size: 13px; font-weight: 800; padding: 9px 0; border-radius: 10px;
  font-variant-numeric: tabular-nums;
}
.av-chip:active { background: var(--fill); }

.av-panel .btn { margin-top: 12px; }
.btn.danger-cta {
  background: #ff3b5c; color: #fff;
  animation: avpulse 1s ease-in-out infinite;
}
@keyframes avpulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 59, 92, 0.5); }
  50% { box-shadow: 0 0 0 10px rgba(255, 59, 92, 0); }
}

.av-auto {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 12px;
  font-size: 12px; font-weight: 700; color: var(--label2);
}
.av-auto .x { color: var(--label3); }
.av-auto-in {
  width: 72px; border: 1px solid var(--separator); outline: none;
  background: var(--card-alt); color: var(--label); border-radius: 9px;
  font-family: inherit; font-size: 14px; font-weight: 800; text-align: center;
  padding: 7px 0; font-variant-numeric: tabular-nums;
}
.av-auto-in:focus { border-color: var(--accent); }

.bl-stage {
  position: relative; margin: 12px 16px 0; height: 260px;
  border-radius: 18px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(120% 90% at 50% 110%, rgba(255, 77, 109, 0.16), transparent 60%),
    radial-gradient(100% 80% at 20% 0%, rgba(47, 208, 113, 0.14), transparent 60%),
    linear-gradient(160deg, #10202e, #080c14 72%);
  border: 1px solid var(--separator);
}
.bl-stage::before {
  content: ""; position: absolute; inset: 0; opacity: 0.5;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(180deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 44px);
}
.bl-stage.shake { animation: blshake 0.4s ease; }
@keyframes blshake {
  15% { transform: translate(-6px, 2px); }
  35% { transform: translate(6px, -3px); }
  55% { transform: translate(-4px, 2px); }
  75% { transform: translate(3px, -1px); }
}

.bl-balloon {
  position: relative; z-index: 2; transform: scale(0.72);
  transform-origin: 50% 62%;
  transition: transform 0.35s cubic-bezier(0.34, 1.5, 0.64, 1), opacity 0.25s ease, filter 0.3s ease;
}
.bl-svg { width: 150px; height: 190px; display: block; }
.bl-balloon.cool { filter: hue-rotate(0deg); }
.bl-balloon.warm { filter: hue-rotate(-58deg) saturate(1.25); }
.bl-balloon.hot { filter: hue-rotate(-118deg) saturate(1.5) drop-shadow(0 0 18px rgba(255, 77, 109, 0.45)); }
.bl-balloon.pumped { animation: blpump 0.35s cubic-bezier(0.2, 1.5, 0.4, 1); }
@keyframes blpump {
  0% { transform: scale(var(--s, 1)) translateY(0); }
  40% { transform: scale(calc(var(--s, 1) * 1.06)) translateY(-6px); }
}
.bl-balloon.popping { animation: blpop 0.26s ease-in forwards; }
@keyframes blpop {
  0% { transform: scale(1.02); }
  60% { transform: scale(1.22); }
  100% { transform: scale(1.5); opacity: 0; }
}

.bl-boom {
  position: absolute; z-index: 4; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 40px; font-weight: 800; letter-spacing: 2px; color: #ff4d6d;
  text-shadow: 0 4px 24px rgba(255, 77, 109, 0.5);
  opacity: 0; transform: scale(0.7); pointer-events: none;
  transition: opacity 0.2s ease, transform 0.3s cubic-bezier(0.2, 1.5, 0.4, 1);
}
.bl-boom.show { opacity: 1; transform: scale(1); }

.bl-center {
  position: absolute; left: 0; right: 0; bottom: 14px; z-index: 3;
  text-align: center; pointer-events: none;
}
.bl-mult {
  font-size: 38px; font-weight: 800; letter-spacing: -1.2px; color: #fff;
  font-variant-numeric: tabular-nums; text-shadow: 0 4px 20px rgba(0, 0, 0, 0.55);
}
.bl-sub { font-size: 12px; font-weight: 700; color: rgba(255, 255, 255, 0.62); margin-top: 3px; }

.bl-next {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin: 12px 16px 0; min-height: 20px;
  font-size: 12px; font-weight: 800; letter-spacing: 0.3px;
}
.bl-next-m { color: var(--label); }
.bl-next-r { color: #ff6b7d; }

.btn.cash-cta { background: var(--green); color: #fff; margin-top: 10px; }
.btn.cash-cta:disabled { opacity: 0.35; }

.bl-fairbar {
  margin: 10px 16px 0; padding: 9px 12px; border-radius: 10px;
  background: var(--fill); color: var(--label2);
  font-size: 11px; font-weight: 600; letter-spacing: 0.2px;
  font-family: "SF Mono", ui-monospace, monospace;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-height: 15px;
}
.bl-fairbar b { color: var(--label); font-family: inherit; }
.bl-fairbar.tappable { cursor: pointer; }
.bl-fairbar.tappable:active { opacity: 0.7; }

.sw-stage {
  position: relative; margin: 10px 16px 0; padding: 10px;
  border-radius: 18px; overflow: hidden;
  background:
    radial-gradient(100% 80% at 50% 0%, rgba(255, 45, 146, 0.16), transparent 60%),
    linear-gradient(165deg, #221033, #120a1e 70%);
  border: 1px solid var(--separator);
}
.sw-grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px;
}
.sw-cell {
  position: relative; aspect-ratio: 1; border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.18s ease;
}
.sym { width: 84%; height: 84%; display: block; }

.sw-cell.fall { animation: swfall 0.34s cubic-bezier(0.24, 0.85, 0.3, 1.04) both; }
@keyframes swfall {
  from { transform: translateY(calc(var(--dy) * -100% + var(--dy) * -4px)); }
  to { transform: none; }
}
.sw-cell.dim { opacity: 0.4; }
.sw-cell.hit {
  background: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.5);
  animation: swglow 0.42s ease infinite alternate;
}
@keyframes swglow {
  from { transform: scale(1); }
  to { transform: scale(1.07); }
}
.sw-cell.pop { animation: swpop 0.24s ease-in forwards; }
@keyframes swpop {
  0% { transform: scale(1.07); opacity: 1; }
  100% { transform: scale(0.2); opacity: 0; }
}

.sw-combo {
  height: 18px; margin: 0 0 8px; display: flex; align-items: center;
  justify-content: center; gap: 10px;
  opacity: 0; transform: translateY(-4px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.sw-combo.show { opacity: 1; transform: none; }
.sw-combo .cbi { display: inline-flex; align-items: center; gap: 4px; }
.sw-combo .cbi .sym { width: 16px; height: 16px; }
.sw-combo .cbi b { font-size: 12px; font-weight: 800; color: #fff; }
.sw-combo .cbn {
  font-size: 10px; font-weight: 800; letter-spacing: 1px; color: var(--accent);
}

.sw-win {
  position: absolute; left: 0; right: 0; bottom: 10px; text-align: center;
  font-size: 17px; font-weight: 800; letter-spacing: -0.3px; color: #fff;
  text-shadow: 0 3px 16px rgba(0, 0, 0, 0.6); pointer-events: none;
  opacity: 0; transform: translateY(8px); transition: opacity 0.2s ease, transform 0.25s ease;
}
.sw-win.show { opacity: 1; transform: none; }
.sw-win.big { font-size: 24px; color: #ffd54a; }

.sw-bomb {
  position: absolute; top: 12px; right: 12px;
  width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 30%, #ff8fa3, #e11d48 70%);
  color: #fff; font-size: 15px; font-weight: 800; letter-spacing: -0.4px;
  box-shadow: 0 6px 18px rgba(225, 29, 72, 0.5);
  opacity: 0; transform: scale(0.4); transition: opacity 0.2s ease, transform 0.3s cubic-bezier(0.2, 1.5, 0.4, 1);
}
.sw-bomb.show { opacity: 1; transform: scale(1); }

.sw-bonusbar {
  margin: 10px 16px 0; min-height: 0; overflow: hidden;
  display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 700; color: var(--label);
  border-radius: 12px; transition: min-height 0.2s ease;
}
.sw-bonusbar.on {
  min-height: 40px; padding: 10px 12px;
  background: linear-gradient(90deg, rgba(255, 45, 146, 0.22), rgba(255, 213, 74, 0.18));
  border: 1px solid var(--separator);
}
.sw-bonusbar .svgi { width: 15px; height: 15px; color: #ffd54a; }
.sw-bonusbar b { letter-spacing: 1px; }

.sw-panel {
  margin: 12px 16px 0; padding: 14px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--separator); box-shadow: var(--shadow);
}
.sw-panel .btn { margin-top: 10px; }

.sw-fair {
  margin: 10px 16px 0; padding: 9px 12px; border-radius: 10px;
  background: var(--fill); color: var(--label2);
  font-size: 11px; font-weight: 600; font-family: "SF Mono", ui-monospace, monospace;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-height: 15px;
}
.sw-fair b { color: var(--label); font-family: inherit; }
.sw-fair.tappable { cursor: pointer; }
.sw-fair.tappable:active { opacity: 0.7; }

.sw-tsym {
  width: 34px; height: 34px; flex-shrink: 0; border-radius: 9px;
  background: var(--fill); display: flex; align-items: center; justify-content: center;
}
.sw-tsym .sym { width: 26px; height: 26px; }
#sw-table .value { font-size: 12.5px; font-weight: 700; }

.rb-hist { display: flex; gap: 5px; overflow-x: auto; padding: 12px 16px 2px; scrollbar-width: none; }
.rb-hist::-webkit-scrollbar { display: none; }
.rb-dot {
  flex: 0 0 auto; width: 24px; height: 24px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800; color: #fff;
}
.rb-dot.kirmizi { background: #e5484d; }
.rb-dot.siyah { background: #2b3038; box-shadow: inset 0 0 0 1px rgba(255,255,255,.18); }
.rb-dot.altin { background: linear-gradient(145deg, #f7d774, #d4a017); color: #3d2c00; }

.rb-stage {
  position: relative; margin: 12px 16px 0; height: 190px;
  border-radius: 18px; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  background:
    radial-gradient(120% 90% at 20% 100%, rgba(229, 72, 77, 0.14), transparent 60%),
    radial-gradient(100% 80% at 90% 0%, rgba(124, 92, 255, 0.16), transparent 60%),
    linear-gradient(160deg, #14101e, #0a0611 70%);
  border: 1px solid var(--separator);
}

.rb-card { width: 86px; height: 116px; perspective: 600px; }
.rb-card.flip .rb-face { animation: rbflip 0.6s cubic-bezier(0.3, 0, 0.2, 1); }
@keyframes rbflip {
  0% { transform: rotateY(0); }
  50% { transform: rotateY(90deg); }
  100% { transform: rotateY(0); }
}
.rb-face {
  width: 100%; height: 100%; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 800; color: #fff; text-align: center;
  background: var(--fill);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14), 0 6px 18px rgba(0, 0, 0, 0.35);
}
.rb-face.kirmizi { background: linear-gradient(160deg, #ff5a60, #c22a30); }
.rb-face.siyah { background: linear-gradient(160deg, #3a404b, #1b1f26); }
.rb-face.altin { background: linear-gradient(145deg, #f7d774, #d4a017); color: #3d2c00; }

.rb-phase {
  font-size: 11px; font-weight: 800; letter-spacing: 1.4px; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.rb-picks {
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px;
  margin: 12px 16px 0;
}
.rb-pick {
  border: none; cursor: pointer; font-family: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 12px 6px; border-radius: 14px; color: #fff;
}
.rb-pick.kirmizi { background: linear-gradient(160deg, #ff5a60, #c22a30); }
.rb-pick.siyah {
  background: linear-gradient(160deg, #3a404b, #1b1f26);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14);
}
.rb-pick.altin { background: linear-gradient(145deg, #f7d774, #d4a017); color: #3d2c00; }
.rb-pick:disabled { opacity: 0.55; cursor: default; }
.rb-pick.on { outline: 2px solid #fff; outline-offset: 2px; opacity: 1; }
.rb-pick:active:not(:disabled) { transform: scale(0.97); }
.rb-pay { font-size: 11px; font-weight: 800; opacity: 0.8; }
.rb-name { font-size: 14px; font-weight: 800; }
.rb-pool { font-size: 11px; font-weight: 700; opacity: 0.75; font-variant-numeric: tabular-nums; }

.rb-note { margin-top: 10px; text-align: center; font-size: 12px; color: var(--label3); }

.rb-chip { width: 26px; height: 26px; border-radius: 9px; flex-shrink: 0; }
.rb-chip.kirmizi { background: #e5484d; }
.rb-chip.siyah { background: #2b3038; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); }
.rb-chip.altin { background: linear-gradient(145deg, #f7d774, #d4a017); }

.rl-screen {
  --rl-gold: #d9b968;
  --rl-gold-ink: #f0dda2;
  --rl-line: rgba(240, 226, 180, 0.4);
  min-height: 100dvh;
  background:
    radial-gradient(120% 90% at 50% 0%, #176038 0%, #0e4527 52%, #0a3520 100%);
  padding-bottom: calc(168px + env(safe-area-inset-bottom, 0px));
}

.rl-screen .bt b { color: #f2efe4; }
.rl-screen .bt i { color: #a9c4ae; }
.rl-screen .wallet { background: rgba(0, 0, 0, 0.3); color: #f0dda2; }
.rl-screen .hall-note { color: #8fb097; }
.rl-screen .hall-note .svgi { color: var(--rl-gold); }

.rl-topbar {
  display: flex; align-items: center; gap: 10px;
  margin: 6px 14px 0;
}
.rl-phase {
  display: inline-block; padding: 4px 9px; border-radius: 7px;
  font-size: 10.5px; font-weight: 800; letter-spacing: 1.2px;
  text-transform: uppercase; white-space: nowrap;
  color: #cfe0d2; background: rgba(0, 0, 0, 0.3);
}
.rl-phase.betting { color: #0a2513; background: linear-gradient(180deg, #59e08c, #2bb45f); }
.rl-phase.closing, .rl-phase.spinning { color: #2a1a02; background: linear-gradient(180deg, #f3c455, #dd9a2b); }
.rl-phase.result { color: #2a2104; background: linear-gradient(180deg, var(--rl-gold-ink), var(--rl-gold)); }

.rl-live { flex: 1; display: flex; gap: 10px; min-width: 0; overflow: hidden; }
.rl-live span {
  display: flex; align-items: center; gap: 4px; white-space: nowrap;
  font-size: 11px; font-weight: 700; color: #a9c4ae;
  font-variant-numeric: tabular-nums;
}
.rl-live .svgi { width: 12px; height: 12px; color: var(--rl-gold); opacity: 0.8; }

.rl-count {
  font-size: 21px; font-weight: 800; letter-spacing: -0.5px;
  font-variant-numeric: tabular-nums; color: #f2efe4; white-space: nowrap;
}
.rl-count.hot { color: #ff6a75; }
.rl-count.res { font-size: 14px; letter-spacing: 0; }
.rl-count.res.red { color: #ff5a6a; }
.rl-count.res.black { color: #e8ebf2; }
.rl-count.res.green { color: #45d98a; }

.rl-bar {
  height: 4px; border-radius: 999px; background: rgba(0, 0, 0, 0.35);
  overflow: hidden; margin: 6px 14px 0;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.5);
}
.rl-bar i {
  display: block; height: 100%; width: 0%; border-radius: 999px;
  background: linear-gradient(90deg, #2bb45f, #59e08c);
}
.ph-betting .rl-bar i { transition: width 0.12s linear; }
.ph-spinning .rl-bar i { background: linear-gradient(90deg, #dd9a2b, #f3c455); }

.rl-strip { padding: 8px 14px 0; }
.rl-pills { display: flex; gap: 5px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.rl-pills::-webkit-scrollbar { display: none; }
.rl-pill {
  flex: 0 0 auto; min-width: 26px; height: 26px; padding: 0 5px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 11.5px; font-weight: 800; color: #fff;
  font-variant-numeric: tabular-nums;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22), 0 1px 3px rgba(0, 0, 0, 0.35);
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.45);
}
.rl-pill.red { background: linear-gradient(180deg, #d92b45, #a01329); }
.rl-pill.black { background: linear-gradient(180deg, #2c323e, #171b24); }
.rl-pill.green { background: linear-gradient(180deg, #13934f, #0a5c31); }
.rl-pill.empty { background: rgba(0, 0, 0, 0.3); color: #a9c4ae; font-weight: 700; border-radius: 8px; box-shadow: none; }
.rl-pill:first-child:not(.empty) { outline: 2px solid var(--rl-gold); outline-offset: 1px; }

.rl-boardwrap {
  display: grid; margin: 10px 12px 0; perspective: 900px;
}
.rl-boardwrap > * { grid-area: 1 / 1; }
.rl-boardwrap .rl-board,
.rl-trackview {
  transition: opacity 0.3s ease, transform 0.34s ease, visibility 0.34s;
}
.rl-trackview {
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: rotateY(-14deg) scale(0.94);
}
.rl-boardwrap.track .rl-board {
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: rotateY(14deg) scale(0.94);
}
.rl-boardwrap.track .rl-trackview {
  opacity: 1; visibility: visible; pointer-events: auto; transform: none;
}

.rl-board, .rl-trackview {
  padding: 7px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.14);
  box-shadow:
    inset 0 0 0 1px rgba(217, 185, 104, 0.5),
    inset 0 0 0 3px rgba(0, 0, 0, 0.22),
    inset 0 0 22px rgba(0, 0, 0, 0.25);
}
.rl-layout { display: grid; grid-template-columns: 26px 1fr 22px; }

.rl-grid {
  position: relative;
  display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 1fr;
}
.rl-doz { display: grid; grid-template-rows: 1fr 4fr 4fr 4fr; }
.rl-dozpad { display: block; }
.rl-rail { position: relative; }

.rl-cell {
  position: relative; border: none; cursor: pointer; font-family: inherit;
  background: transparent; color: #f2efe0;
  box-shadow: inset 0 0 0 1px var(--rl-line);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 28px; padding: 1px; gap: 0;
  font-size: 13.5px; font-weight: 800; font-variant-numeric: tabular-nums;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
  transition: filter 0.15s ease;
}
.rl-cell:active { filter: brightness(1.4); }
.rl-cell.red { background: linear-gradient(180deg, #c92742, #98122a); }
.rl-cell.black { background: linear-gradient(180deg, #262c38, #12161e); }
.rl-cell.green, .rl-cell.zero { background: linear-gradient(180deg, #12854a, #0a5e33); }
.rl-cell.zero { grid-column: 1 / -1; font-size: 15px; min-height: 26px; }
.rl-cell .t { pointer-events: none; line-height: 1.1; }
.rl-cell .x {
  pointer-events: none; font-size: 8px; font-weight: 700;
  letter-spacing: 0.5px; color: var(--rl-gold-ink); opacity: 0.8;
}
.rl-cell.vert .t {
  writing-mode: vertical-rl; transform: rotate(180deg);
  letter-spacing: 0.8px; font-size: 10.5px; color: var(--rl-gold-ink);
}

.rl-cols, .rl-out {
  display: grid; grid-template-columns: repeat(3, 1fr);
  margin-left: 26px; margin-right: 22px;
}
.rl-cols .rl-cell { min-height: 26px; font-size: 11.5px; letter-spacing: 0.4px; color: var(--rl-gold-ink); }
.rl-out .rl-cell { min-height: 37px; font-size: 11px; letter-spacing: 0.4px; }

.rl-out .rl-cell.red, .rl-out .rl-cell.black { background: transparent; }
.rl-out .rl-cell.red::before, .rl-out .rl-cell.black::before {
  content: ""; width: 10px; height: 10px; margin-bottom: 1px;
  transform: rotate(45deg) scale(0.92); border-radius: 2px; pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}
.rl-out .rl-cell.red::before { background: linear-gradient(135deg, #e04a60, #98122a); }
.rl-out .rl-cell.black::before { background: linear-gradient(135deg, #39404e, #10141c); }

.rl-cell.hit {
  box-shadow: inset 0 0 0 2px var(--rl-gold), 0 0 16px rgba(217, 185, 104, 0.65);
  z-index: 2; animation: rlhit 0.5s ease;
}
@keyframes rlhit {
  0% { transform: scale(1); } 45% { transform: scale(1.16); } 100% { transform: scale(1); }
}

.ph-spinning .rl-board, .ph-result .rl-board, .ph-closing .rl-board { opacity: 0.92; }
.ph-spinning .rl-spot::before, .ph-result .rl-spot::before, .ph-closing .rl-spot::before { opacity: 0; }

.rl-spotlayer { position: absolute; inset: 0; pointer-events: none; }
.rl-spot {
  position: absolute; transform: translate(-50%, -50%);
  width: 24px; height: 24px; border-radius: 50%;
  border: none; padding: 0; cursor: pointer; pointer-events: auto;
  background: transparent; z-index: 3;
  display: flex; align-items: center; justify-content: center;
}
.rl-spot::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: rgba(240, 226, 180, 0.5); transition: opacity 0.2s ease;
}
.rl-spot.has::before { display: none; }
.rl-spot:active::before { background: var(--rl-gold); transform: scale(1.6); }
.rl-rail .rl-spot::before { background: rgba(240, 226, 180, 0.33); }

.rl-onchip, .rl-chipbtn {
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0) 55%),
    radial-gradient(circle, var(--cc) 0 55%, #f4eeda 55% 60.5%, var(--cc) 60.5% 64%, rgba(0, 0, 0, 0) 64.5%),
    repeating-conic-gradient(#f4eeda 0deg 16deg, var(--cc) 16deg 60deg);
  color: #fff; text-shadow: 0 1px 1px rgba(0, 0, 0, 0.55);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5), inset 0 -2px 4px rgba(0, 0, 0, 0.22);
}
.rl-onchip.c1, .rl-chipbtn.c1 { --cc: #c3392f; }
.rl-onchip.c2, .rl-chipbtn.c2 { --cc: #2d5fc4; }
.rl-onchip.c3, .rl-chipbtn.c3 { --cc: #1e9153; }
.rl-onchip.c4, .rl-chipbtn.c4 { --cc: #23262e; }
.rl-onchip.c5, .rl-chipbtn.c5 { --cc: #7440cf; }

.rl-onchip {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 23px; height: 23px;
  display: flex; align-items: center; justify-content: center;
  font-size: 8.5px; font-weight: 800; font-style: normal;
  font-variant-numeric: tabular-nums; z-index: 5; pointer-events: none;
}

.rl-cell.won, .rl-spot.won { z-index: 6; }
.rl-cell.won .rl-onchip, .rl-spot.won .rl-onchip {
  box-shadow: 0 0 0 2px var(--rl-gold), 0 0 16px rgba(217, 185, 104, 0.85);
  animation: rlwin 0.6s ease-in-out 2;
}
@keyframes rlwin { 50% { transform: translate(-50%, -50%) scale(1.24); } }
.rl-cell.lost .rl-onchip, .rl-spot.lost .rl-onchip { opacity: 0.3; }

.rl-spinstage {
  overflow: hidden; max-height: 0; opacity: 0;
  transition: max-height 0.5s cubic-bezier(0.25, 0.75, 0.3, 1), opacity 0.32s ease;
}
.ph-closing .rl-spinstage, .ph-spinning .rl-spinstage, .ph-result .rl-spinstage {
  max-height: 640px; opacity: 1;
}
.rl-spininner { padding: 12px 14px 2px; }

.rl-wheelbox {
  position: relative; margin: 0 auto;
  width: min(58vw, 236px); aspect-ratio: 1;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.55));
}
.rl-bowl, .rl-wheel { position: absolute; inset: 0; }
.rl-wheel { will-change: transform; }
.rl-svg { width: 100%; height: 100%; display: block; }

.rl-sec.red { fill: #b3122e; }
.rl-sec.black { fill: #14181f; }
.rl-sec.green { fill: #0d8047; }
.rl-lab {
  fill: #f4f1e6; font-size: 8.6px; font-weight: 700; text-anchor: middle;
  dominant-baseline: middle; font-family: -apple-system, "Segoe UI", sans-serif;
}

.rl-ball {
  position: absolute; left: 50%; top: 50%; z-index: 3;
  width: 8%; height: 8%; border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #ffffff, #e8ebf0 48%, #a9b0bd 82%, #767e8c);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.65), inset 0 -1px 2px rgba(0, 0, 0, 0.28);
  transform: translate(-50%, -50%) translateY(-39.5%);
  will-change: transform;
}

.rl-num {
  position: absolute; left: 50%; top: 50%; z-index: 4;
  transform: translate(-50%, -50%) scale(0.55);
  min-width: 37%; padding: 7px 10px; border-radius: 999px;
  font-size: clamp(18px, 5.6vw, 26px); font-weight: 800; text-align: center;
  font-variant-numeric: tabular-nums; color: #fff;
  border: 2px solid var(--rl-gold);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  opacity: 0; transition: opacity 0.25s ease, transform 0.3s cubic-bezier(0.2, 1.6, 0.4, 1);
}
.rl-num.show { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.rl-num.red { background: linear-gradient(180deg, #d92b45, #9c1128); }
.rl-num.black { background: linear-gradient(180deg, #2b3140, #141821); }
.rl-num.green { background: linear-gradient(180deg, #13934f, #0a5c31); }

.rl-wins { margin: 12px auto 0; max-width: 360px; text-align: left; }
.rl-wins:empty { display: none; }
.rl-winhead {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 12.5px; font-weight: 800; letter-spacing: 0.5px; color: #2a2104;
  background: linear-gradient(180deg, var(--rl-gold-ink), var(--rl-gold));
  border-radius: 10px; padding: 9px 11px; text-align: center;
  box-shadow: 0 2px 10px rgba(217, 185, 104, 0.3);
}
.rl-winhead.lose { background: rgba(229, 72, 77, 0.22); color: #ff8b93; box-shadow: none; }
.rl-winhead.idle { background: rgba(255, 255, 255, 0.08); color: #b9c4b4; box-shadow: none; }
.rl-winhead .svgi { width: 15px; height: 15px; }
.rl-winrow {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px;
  background: rgba(255, 255, 255, 0.08); border-radius: 10px; margin-top: 4px;
  font-size: 12.5px; color: #ecefe6;
}
.rl-winrow .l {
  flex: 1; min-width: 0; font-weight: 700;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rl-winrow .p { color: var(--rl-gold); font-weight: 800; font-size: 11px; }
.rl-winrow .a { color: #c3cdc0; font-variant-numeric: tabular-nums; }
.rl-winrow .a b { color: #59e08c; }

.rl-trackhead {
  display: flex; align-items: center; gap: 5px; padding: 2px 4px 6px;
  font-size: 9.5px; font-weight: 800; letter-spacing: 1.1px; color: var(--rl-gold-ink, #f0dda2);
}
.rl-trackhead i { font-style: normal; letter-spacing: 0.2px; font-weight: 700; opacity: 0.7; color: #a9c4ae; }
.rl-trackhead .svgi { width: 12px; height: 12px; color: #d9b968; }
.rl-tracksvg { width: 100%; display: block; }

.rl-tslot { cursor: pointer; }
.rl-tslot polygon { stroke: rgba(240, 226, 180, 0.35); stroke-width: 0.6; }
.rl-tslot polygon.red { fill: #b3122e; }
.rl-tslot polygon.black { fill: #171b24; }
.rl-tslot polygon.green { fill: #0d8047; }
.rl-tslot:active polygon { filter: brightness(1.6); }
.rl-tslot text {
  fill: #f4f1e6; font-size: 8px; font-weight: 700; text-anchor: middle;
  dominant-baseline: middle; pointer-events: none;
  font-family: -apple-system, "Segoe UI", sans-serif;
}

.rl-tzone { cursor: pointer; }
.rl-tzone rect {
  fill: rgba(255, 255, 255, 0.06);
  stroke: rgba(217, 185, 104, 0.55); stroke-width: 0.8;
}
.rl-tzone:active rect { fill: rgba(217, 185, 104, 0.3); }
.rl-tzone text {
  fill: #f0dda2; font-size: 9px; font-weight: 800; letter-spacing: 1.4px;
  text-anchor: middle; dominant-baseline: middle; pointer-events: none;
  font-family: -apple-system, "Segoe UI", sans-serif;
}
.rl-tzone.gold rect {
  fill: rgba(217, 185, 104, 0.22);
  stroke: #d9b968; stroke-width: 1;
}
.rl-tzone.gold text { fill: #f6e7b4; letter-spacing: 1.8px; }
.rl-tzone.gold.dim { opacity: 0.35; }

.rl-dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  padding: 8px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  background: rgba(6, 24, 14, 0.88);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-top: 1px solid rgba(217, 185, 104, 0.35);
}
.rl-mine {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 12px; color: #a9c4ae; font-variant-numeric: tabular-nums;
}
.rl-mine b { color: #f2efe4; font-size: 14.5px; }
.rl-mine.on { color: #dfe8df; }
.rl-mine .lim { font-size: 10.5px; color: #7e997f; }

.rl-chiprow { display: flex; gap: 6px; justify-content: space-between; margin-top: 8px; }
.rl-chipbtn {
  flex: 0 0 auto; width: 48px; height: 48px; margin: 0 auto;
  cursor: pointer; font-family: inherit; border: none;
  font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums;
  opacity: 0.72; filter: saturate(0.9);
  transition: transform 0.14s ease, opacity 0.15s ease, filter 0.15s ease;
}
.rl-chipbtn.on {
  opacity: 1; filter: none; transform: translateY(-4px) scale(1.06);
  box-shadow: 0 0 0 2px var(--rl-gold, #d9b968), 0 6px 12px rgba(0, 0, 0, 0.45);
}
.rl-chipbtn:active { transform: scale(0.94); }

.rl-acts { display: flex; gap: 6px; margin-top: 9px; }
.rl-act {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 4px;
  height: 34px; border-radius: 10px; cursor: pointer; font-family: inherit;
  background: rgba(255, 255, 255, 0.09); color: #dfe8df; border: none;
  font-size: 11.5px; font-weight: 700;
}
.rl-act.wide { flex: 1.15; }
.rl-act .svgi { width: 14px; height: 14px; }
.rl-act:active { opacity: 0.7; }
.rl-act:disabled { opacity: 0.35; pointer-events: none; }
.rl-act.on {
  background: linear-gradient(180deg, #f0dda2, #d9b968); color: #2a2104;
}

.rl-fairbar {
  display: flex; align-items: center; gap: 8px;
  margin: 10px 14px 0; padding: 9px 12px; border-radius: 10px;
  background: rgba(0, 0, 0, 0.28); color: #a9c4ae;
  font-size: 11px; font-weight: 600; letter-spacing: 0.2px;
  font-family: "SF Mono", ui-monospace, monospace;
  min-height: 15px;
}
.rl-fairbar .fh {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rl-fairbar b { color: #e8e4d2; font-family: inherit; }
.rl-fairbar .fx {
  flex: 0 0 auto; color: #f0dda2; text-decoration: underline;
  text-underline-offset: 2px; font-family: inherit; cursor: pointer;
}
.rl-fairbar.tappable { cursor: pointer; }
.rl-fairbar.tappable:active { opacity: 0.7; }

@media (prefers-reduced-motion: reduce) {
  .rl-num, .rl-spinstage, .rl-trackview, .rl-boardwrap .rl-board { transition: none; }
  .rl-cell.hit, .rl-cell.won .rl-onchip, .rl-spot.won .rl-onchip { animation: none; }
}

.lobby-hero {
  position: relative; margin: 12px 16px 0; border-radius: 18px; overflow: hidden;
  background: #05070d; box-shadow: var(--shadow);
  display: flex; flex-direction: column; justify-content: flex-end; min-height: 196px;
}
.lobby-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lobby-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(3, 6, 11, 0.92) 0%, rgba(3, 6, 11, 0.45) 42%, rgba(3, 6, 11, 0) 72%);
}
.lobby-hero .lb-back,
.lobby-hero .lb-wallet {
  position: absolute; top: 10px; z-index: 2;
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(6, 10, 16, 0.62); color: #fff;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.lobby-hero .lb-back {
  left: 10px; width: 34px; height: 34px; justify-content: center;
  border: none; border-radius: 11px; padding: 0; cursor: pointer; font-family: inherit;
}
.lobby-hero .lb-back .svgi { width: 18px; height: 18px; }
.lobby-hero .lb-back:active { opacity: 0.7; }
.lobby-hero .lb-wallet {
  right: 10px; height: 34px; padding: 0 11px; border-radius: 11px;
  font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.lobby-hero .lb-wallet .svgi { width: 14px; height: 14px; color: var(--accent); }
.lobby-hero .lb-info { position: relative; z-index: 1; padding: 14px 16px 16px; }
.lobby-hero .lb-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 9px; }
.lobby-hero .lb-tags .tagpill.odds { margin-left: 0; }
.lobby-hero h1 {
  color: #fff; font-size: 24px; font-weight: 800; letter-spacing: -0.6px; line-height: 1.12;
}
.lobby-hero .lb-sub {
  color: rgba(255, 255, 255, 0.68); font-size: 12.5px; line-height: 1.35; margin-top: 4px;
}

.row .value.elo { display: inline-flex; align-items: center; gap: 4px; font-size: 15px; }
.row .value.elo .svgi { width: 14px; height: 14px; color: var(--accent); }
[data-theme="light"] .row .value.elo .svgi { color: #8fae08; }

.mk-wallet {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0;
  padding: 14px 8px 10px;
  background: linear-gradient(150deg, var(--card-alt), var(--card) 62%);
}
.mk-wallet .mk-cell { text-align: center; padding: 4px 6px; position: relative; }
.mk-wallet .mk-cell + .mk-cell::before {
  content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 1px; background: var(--separator);
}
.mk-wallet .mk-cell .ic {
  width: 34px; height: 34px; border-radius: 10px; margin: 0 auto 6px;
  display: flex; align-items: center; justify-content: center;
  background: var(--tint-bg); color: var(--accent);
}
[data-theme="light"] .mk-wallet .mk-cell .ic { color: #8fae08; }
.mk-wallet .mk-cell .ic .svgi { width: 18px; height: 18px; }
.mk-wallet .mk-cell .v {
  font-size: 22px; font-weight: 800; letter-spacing: -0.5px; font-variant-numeric: tabular-nums;
}
.mk-wallet .mk-cell .k {
  font-size: 10px; font-weight: 800; letter-spacing: 1.3px; text-transform: uppercase; color: var(--label3); margin-top: 2px;
}
.mk-wallet .mk-foot {
  grid-column: 1 / -1; text-align: center; margin-top: 10px; padding-top: 8px;
  border-top: 1px solid var(--separator);
  font-size: 12px; color: var(--label2); font-variant-numeric: tabular-nums;
}

.row.mk-prod { align-items: flex-start; padding-top: 13px; padding-bottom: 13px; }
.row.mk-prod .icon { margin-top: 2px; }
.row.mk-prod .mk-desc { font-size: 12.5px; color: var(--label2); margin-top: 2px; line-height: 1.35; }
.row.mk-prod .mk-price {
  margin-top: 5px; font-size: 12.5px; font-weight: 800; color: var(--label);
  font-variant-numeric: tabular-nums;
}
.mk-right {
  flex-shrink: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 7px;
}
.row.tappable .mk-right { align-items: flex-end; }

.mk-qty {
  display: inline-flex; align-items: center; gap: 2px;
  background: var(--fill); border-radius: 999px; padding: 2px;
}
.mk-qty button {
  width: 28px; height: 28px; border: none; border-radius: 50%; cursor: pointer; font-family: inherit;
  background: var(--card); color: var(--label); font-size: 17px; font-weight: 800; line-height: 1;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}
.mk-qty button:active { opacity: 0.7; }
.mk-qty b {
  min-width: 26px; text-align: center; font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.mk-right .mini-btn { min-width: 64px; }

.pill-state.on { background: var(--tint-bg); color: var(--label); }

.mk-chance {
  display: inline-flex; align-items: center;
  font-size: 12px; font-weight: 800; letter-spacing: 0.2px; font-variant-numeric: tabular-nums;
  color: var(--green); background: rgba(18, 183, 106, 0.14); border-radius: 7px; padding: 4px 8px;
}
.mk-chance { color: #0b7a47; }
[data-theme="dark"] .mk-chance { color: var(--green); }
.mk-chance.big { font-size: 15px; padding: 6px 11px; }
[data-theme="dark"] .mk-chance { background: rgba(36, 209, 126, 0.16); }

.mk-stats { display: grid; grid-template-columns: repeat(3, 1fr); padding: 14px 8px; }
.mk-stats .cell { text-align: center; position: relative; }
.mk-stats .cell + .cell::before {
  content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 1px; background: var(--separator);
}
.mk-stats .cell .v { font-size: 20px; font-weight: 800; letter-spacing: -0.4px; font-variant-numeric: tabular-nums; }
.mk-stats .cell .k {
  font-size: 10px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; color: var(--label3); margin-top: 2px;
}

.mk-note {
  display: flex; gap: 10px; align-items: flex-start;
  margin: 14px 16px 0; padding: 11px 13px; border-radius: 12px;
  background: var(--tint-bg); border: 1px solid var(--separator);
  font-size: 12.5px; line-height: 1.45; color: var(--label2);
}
.mk-note .svgi { width: 16px; height: 16px; color: var(--accent); flex-shrink: 0; margin-top: 1px; }
[data-theme="light"] .mk-note .svgi { color: #8fae08; }

.mk-actions { padding: 0 16px; display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.mk-actions .note { padding: 0 4px; }

.mk-result {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  margin: 16px 16px 0; padding: 18px 16px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--separator); box-shadow: var(--shadow);
  color: var(--label2);
}
.mk-result .svgi { width: 36px; height: 36px; color: var(--label3); margin-bottom: 4px; }
.mk-result b { font-size: 19px; font-weight: 800; letter-spacing: -0.4px; color: var(--label); }
.mk-result span { font-size: 12.5px; }
.mk-result.win { background: var(--tint-bg); }
.mk-result.win .svgi { color: var(--accent); }
[data-theme="light"] .mk-result.win .svgi { color: #8fae08; }
