:root {
  --violet: #9945ff;
  --violet-hi: #b46bff;
  --mint: #14f195;
  --gold: #ffc02e;
  --pink: #ff3d8b;
  --a1: var(--violet);
  --a2: var(--mint);
  --text: #eef0ff;
  --muted: #9a9cc4;
  --panel: rgba(13, 9, 34, 0.74);
  --line: rgba(255, 255, 255, 0.09);
  --display: 'Unbounded', 'Chakra Petch', system-ui, sans-serif;
  --ui: 'Chakra Petch', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
body.fs-mode { --a1: var(--gold); --a2: var(--pink); }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; margin: 0; }
body {
  background: #05030f;
  color: var(--text);
  font-family: var(--ui);
  font-weight: 500;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
}
[hidden] { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
button:disabled { cursor: default; opacity: 0.45; }
.sol { font-family: system-ui, sans-serif; font-style: normal; font-weight: 600; opacity: 0.85; margin-right: 0.18em; }

#bg { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
#app { position: relative; z-index: 1; height: 100dvh; display: flex; flex-direction: column; padding-bottom: env(safe-area-inset-bottom); }

/* ---------------------------------------------------------------- top bar */
.topbar {
  display: flex; align-items: center; gap: 14px;
  padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top));
  background: linear-gradient(180deg, rgba(5, 3, 15, 0.85), rgba(5, 3, 15, 0));
}
.brand { display: flex; align-items: center; gap: 9px; flex: none; }
.brand-mark { width: 30px; height: 30px; filter: drop-shadow(0 0 10px var(--a1)); animation: spinSlow 14s linear infinite; }
.brand-name { font-family: var(--display); font-weight: 900; font-size: 19px; letter-spacing: 0.04em; }
.brand-name b { background: linear-gradient(90deg, var(--a1), var(--a2)); -webkit-background-clip: text; background-clip: text; color: transparent; margin-left: 0.22em; }
@keyframes spinSlow { to { transform: rotate(360deg); } }

.feed { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; justify-content: center; font-size: 13px; color: var(--muted); }
.live { display: inline-flex; align-items: center; gap: 6px; flex: none; padding: 4px 10px; border-radius: 99px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); }
.live i { width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 8px var(--mint); animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: 0.35; } }
.feed-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-text b { color: var(--text); }
.feed-text em { font-style: normal; color: var(--gold); font-weight: 700; margin-left: 4px; }
.feed-text.flash { animation: feedIn 0.5s ease-out; }
@keyframes feedIn { from { opacity: 0; transform: translateY(8px); } }

.top-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.balance {
  display: flex; align-items: center; padding: 8px 14px; border-radius: 12px; cursor: pointer;
  background: rgba(13, 9, 34, 0.88); border: 1px solid var(--line);
  font-family: var(--display); font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums;
}
.balance .sol { color: var(--mint); }
.btn {
  padding: 9px 15px; border-radius: 12px; font-weight: 700; font-size: 14px; letter-spacing: 0.02em;
  background: rgba(255, 255, 255, 0.07); border: 1px solid var(--line); transition: transform 0.12s, filter 0.12s, background 0.12s;
}
.btn:hover { background: rgba(255, 255, 255, 0.12); }
.btn:active { transform: scale(0.96); }
.btn-go { background: linear-gradient(135deg, var(--violet), #6a2bd9 55%, #0fb87a 130%); border-color: rgba(255, 255, 255, 0.22); box-shadow: 0 4px 22px rgba(153, 69, 255, 0.45); }
.btn-go:hover { filter: brightness(1.15); background: linear-gradient(135deg, var(--violet), #6a2bd9 55%, #0fb87a 130%); }
.btn-ghost { background: transparent; color: var(--muted); max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn-block { width: 100%; padding: 13px; font-size: 16px; margin-top: 6px; }
.icon-btn {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-weight: 700; font-size: 14px;
  background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line);
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.12); }
.icon-btn.off { color: var(--muted); }

/* ---------------------------------------------------------------- stage */
.stage { flex: 1; min-height: 0; display: flex; flex-direction: column; align-items: center; padding: 0 8px; }
.stagebar { position: relative; flex: none; width: var(--cab-w, 100%); max-width: 100%; transform: translateY(var(--cab-shift, 0px)); z-index: 1; }
.stagebar .icon-btn { position: absolute; top: 50%; right: 0; width: 28px; height: 28px; margin-top: -14px; border-radius: 9px; font-size: 11px; }
.stagebar #btnInfo { right: 34px; }
.multbar { flex: none; height: 46px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.mult-label { font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin-right: 6px; }
.chip {
  min-width: 52px; padding: 6px 10px; text-align: center; border-radius: 10px; font-family: var(--display); font-weight: 800; font-size: 14px;
  color: rgba(255, 255, 255, 0.35); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line);
  clip-path: polygon(9px 0, 100% 0, calc(100% - 9px) 100%, 0 100%); transition: all 0.2s;
}
.chip.passed { color: rgba(255, 255, 255, 0.6); }
.chip.active { color: #0a0420; background: linear-gradient(135deg, var(--a2), #9dffd6); transform: scale(1.14); filter: drop-shadow(0 0 12px var(--a2)); }
.chip.pop, .fs-mult.pop { animation: pop 0.45s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes pop { 0% { transform: scale(2.1); filter: brightness(2.5) drop-shadow(0 0 24px #fff); } 100% { transform: scale(1.14); } }
.multbar.fs { gap: 22px; }
.fs-stat { display: flex; flex-direction: column; align-items: center; line-height: 1.1; min-width: 92px; }
.fs-stat span { font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.fs-stat b { font-family: var(--display); font-size: 17px; font-weight: 800; }
.fs-mult {
  font-family: var(--display); font-weight: 900; font-size: 30px; line-height: 1; padding: 4px 16px;
  background: linear-gradient(180deg, #fff6c0, var(--gold) 55%, #ff7a1a); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 14px rgba(255, 180, 40, 0.8)); transform: scale(1.14);
}

.reels { container-type: size; position: relative; flex: 1; min-height: 0; width: 100%; max-width: 1100px; }
#game { position: absolute; inset: 0; width: 100%; height: 100%; }

.announce, .bigwin {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  pointer-events: none; opacity: 0; transition: opacity 0.22s; z-index: 3;
  background: radial-gradient(ellipse at center, rgba(5, 3, 15, 0.82) 0%, rgba(5, 3, 15, 0.5) 45%, rgba(5, 3, 15, 0) 72%);
}
.announce.show, .bigwin.show { opacity: 1; }
.bigwin.show { pointer-events: auto; }
.an-title, .bw-title {
  font-family: var(--display); font-weight: 900; line-height: 1; letter-spacing: 0.02em;
  font-size: clamp(24px, min(6.6cqw, 13cqh), 88px); max-width: 96%;
  background: linear-gradient(180deg, #ffffff 10%, var(--a2) 50%, var(--a1) 95%); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 0 rgba(10, 3, 30, 0.9)) drop-shadow(0 0 34px var(--a1));
}
.show .an-title, .show .bw-title { animation: slam 0.7s cubic-bezier(0.2, 1.5, 0.35, 1) both, throb 1s 0.7s ease-in-out infinite; }
.an-sub { font-family: var(--display); font-weight: 800; font-size: clamp(18px, min(4.6cqw, 9cqh), 46px); margin-top: 0.4em; color: #fff; text-shadow: 0 0 24px var(--a2), 0 3px 0 #12052e; }
.an-note { margin-top: 0.7em; font-size: clamp(12px, 2vmin, 17px); letter-spacing: 0.2em; text-transform: uppercase; color: var(--a2); }
.show .an-sub, .show .an-note, .show .bw-amount { animation: rise 0.5s 0.25s ease-out both; }
.bw-title { font-size: clamp(30px, min(9.5cqw, 16cqh), 110px); background: linear-gradient(180deg, #fff 10%, #ffe27a 45%, #ff8a1a 95%); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 5px 0 rgba(60, 14, 0, 0.9)) drop-shadow(0 0 40px rgba(255, 170, 30, 0.9)); }
.bigwin[data-tier='1'] .bw-title { background-image: linear-gradient(180deg, #fff 10%, #ff9ad2 45%, #ff2d7e 95%); filter: drop-shadow(0 5px 0 rgba(50, 0, 30, 0.9)) drop-shadow(0 0 44px rgba(255, 60, 140, 0.95)); }
.bigwin[data-tier='2'] .bw-title { background-image: linear-gradient(180deg, #fff 5%, #9dffd6 35%, #14f195 55%, #9945ff 95%); filter: drop-shadow(0 5px 0 rgba(10, 3, 40, 0.9)) drop-shadow(0 0 50px rgba(20, 241, 149, 0.95)); }
.bw-amount { font-family: var(--display); font-weight: 900; font-size: clamp(24px, min(7cqw, 12cqh), 72px); margin-top: 0.3em; color: #fff; font-variant-numeric: tabular-nums; text-shadow: 0 0 30px rgba(255, 190, 60, 0.9), 0 4px 0 #2b0c00; }
@keyframes slam { 0% { transform: scale(4); opacity: 0; } 60% { opacity: 1; } 100% { transform: scale(1); } }
@keyframes throb { 50% { transform: scale(1.06); } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

/* ---------------------------------------------------------------- controls */
.controls {
  /* equal side columns (minmax(0, …) stops their content from widening one of them) keep Spin dead centre */
  flex: none; display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); grid-template-areas: 'bet spin right'; align-items: center; gap: 18px;
  padding: 10px 18px 14px; max-width: 1100px; width: 100%; margin: 0 auto;
}
.ctl label { display: block; font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.ctl-bet { grid-area: bet; justify-self: end; display: flex; flex-direction: column; }
.ctl-win { grid-area: right; justify-self: start; }
.ctl-toggles { grid-area: right; justify-self: end; display: flex; gap: 8px; align-self: end; }
.bet-row { display: flex; align-items: center; gap: 6px; }
.value {
  min-width: 128px; padding: 10px 14px; border-radius: 12px; text-align: center; background: rgba(13, 9, 34, 0.88); border: 1px solid var(--line);
  font-family: var(--display); font-weight: 800; font-size: 17px; font-variant-numeric: tabular-nums;
}
.win-value { min-width: 168px; color: var(--gold); border-color: rgba(255, 192, 46, 0.25); }
.win-value.hot { animation: winHot 0.6s ease-out; }
@keyframes winHot { 0% { transform: scale(1.18); box-shadow: 0 0 40px rgba(255, 192, 46, 0.8); background: rgba(255, 192, 46, 0.25); } }
.step { width: 40px; height: 40px; border-radius: 12px; font-size: 22px; font-weight: 700; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--line); }
.step.quick { width: auto; min-width: 40px; padding: 0 9px; font-size: 12px; letter-spacing: 0.04em; color: var(--muted); }
.step.quick:hover:not(:disabled) { color: var(--text); }
.step:disabled { opacity: 0.45; cursor: default; }
.step:hover:not(:disabled) { background: rgba(255, 255, 255, 0.14); }
.step:active:not(:disabled) { transform: scale(0.92); }
.toggle {
  padding: 10px 14px; border-radius: 12px; font-size: 12px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); transition: all 0.15s;
}
.toggle:hover { color: var(--text); }
.toggle.on { color: #08031a; background: var(--a2); border-color: transparent; box-shadow: 0 0 18px var(--a2); }
.auto-wrap { position: relative; }
.auto-menu { position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); display: flex; gap: 4px; padding: 6px; border-radius: 12px; background: rgba(13, 9, 34, 0.95); border: 1px solid var(--line); z-index: 5; }
.auto-menu button { padding: 8px 12px; border-radius: 8px; font-weight: 700; }
.auto-menu button:hover { background: var(--a1); }

.spin { grid-area: spin; position: relative; width: 108px; height: 108px; border-radius: 50%; display: grid; place-items: center; transition: transform 0.12s; }
.spin:hover { transform: scale(1.05); }
.spin:active { transform: scale(0.93); }
.spin-ring { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 0deg, var(--a1), var(--a2), #fff, var(--a1), var(--a2), var(--a1)); animation: spinSlow 3.2s linear infinite; filter: drop-shadow(0 0 16px var(--a1)); }
.spin.busy .spin-ring { animation-duration: 0.55s; }
.spin-core {
  position: relative; width: 90px; height: 90px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 35% 28%, #3a1d86, #150a3a 60%, #0a0520);
  box-shadow: inset 0 2px 12px rgba(255, 255, 255, 0.25), inset 0 -8px 18px rgba(0, 0, 0, 0.6);
}
.spin-label { font-family: var(--display); font-weight: 900; font-size: 17px; letter-spacing: 0.06em; background: linear-gradient(180deg, #fff, var(--a2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.spin.busy .spin-label { opacity: 0.45; }
.spin:not(.busy) .spin-core { animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe { 50% { box-shadow: inset 0 2px 12px rgba(255, 255, 255, 0.25), inset 0 -8px 18px rgba(0, 0, 0, 0.6), 0 0 34px var(--a2); } }

/* ---------------------------------------------------------------- modals */
.modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 16px; background: rgba(3, 2, 10, 0.72); backdrop-filter: blur(8px); opacity: 0; transition: opacity 0.18s; overflow-y: auto; user-select: text; -webkit-user-select: text; }
.modal.open { opacity: 1; }
.card {
  position: relative; width: min(480px, 100%); padding: 26px; border-radius: 22px; background: linear-gradient(180deg, #17103a, #0b0722);
  border: 1px solid rgba(180, 107, 255, 0.35); box-shadow: 0 30px 90px rgba(0, 0, 0, 0.7), 0 0 60px rgba(153, 69, 255, 0.25);
  transform: translateY(14px) scale(0.97); transition: transform 0.2s cubic-bezier(0.2, 1.3, 0.4, 1);
}
.modal.open .card { transform: none; }
.card-sm { width: min(400px, 100%); }
.card-lg { width: min(820px, 100%); }
.card-md { width: min(540px, 100%); }
.avatar { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 50% 35%, #2a1c5e, #0b0722); border: 1px solid rgba(180, 107, 255, 0.5); object-fit: contain; flex: none; }
.avatar-lg { width: 58px; height: 58px; box-shadow: 0 0 24px rgba(153, 69, 255, 0.45); }
.btn-user { display: flex; align-items: center; padding: 4px; border-radius: 50%; }
.btn-user span { display: none; } /* avatar only; the name is in the account popup */
.acct-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; padding-right: 34px; }
.acct-head h2 { margin: 0 0 2px; }
.acct-head .muted { margin: 0; }
.acct-logout { margin: 14px 0 0; }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 16px; }
.tile { padding: 11px 8px; border-radius: 13px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); text-align: center; min-width: 0; }
.tile b { display: block; font-family: var(--display); font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile small { display: block; margin-top: 3px; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.avatars { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; }
.avatars button { aspect-ratio: 1; border-radius: 12px; padding: 3px; background: rgba(0, 0, 0, 0.3); border: 1px solid var(--line); transition: transform 0.12s, border-color 0.12s, box-shadow 0.12s; }
.avatars button:hover { transform: scale(1.12); }
.avatars button.on { border-color: var(--mint); box-shadow: 0 0 14px rgba(20, 241, 149, 0.45); }
.avatars img { width: 100%; height: 100%; display: block; }
.sec { padding: 14px; border-radius: 15px; background: rgba(255, 255, 255, 0.035); border: 1px solid var(--line); margin-bottom: 12px; }
.sec .muted { margin-bottom: 10px; }
.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.sec-head h3 { margin: 0; }
.badge { padding: 3px 10px; border-radius: 99px; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; background: rgba(255, 255, 255, 0.08); color: var(--muted); }
.badge.on { background: rgba(20, 241, 149, 0.16); color: var(--mint); }
.qr-row { display: flex; gap: 14px; align-items: center; margin-bottom: 12px; }
.qr { width: 148px; height: 148px; border-radius: 12px; background: #fff; flex: none; }
.qr-side { min-width: 0; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.qr-side code { word-break: break-all; font-size: 13px; letter-spacing: 0.06em; }
.btn-row { display: flex; gap: 8px; justify-content: flex-end; }
.codes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-bottom: 12px; }
.codes code { padding: 8px 4px; border-radius: 9px; background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); text-align: center; font-size: 13px; }
.list { max-height: 210px; overflow-y: auto; }
.list .row { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; padding: 9px 2px; border-bottom: 1px solid var(--line); font-size: 14px; }
.list .row:last-child { border-bottom: 0; }
.list small { display: block; color: var(--muted); font-size: 12px; }
.list .tag { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mint); }
.claim { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 15px; border-radius: 15px; background: linear-gradient(135deg, rgba(153, 69, 255, 0.2), rgba(20, 241, 149, 0.1)); border: 1px solid rgba(180, 107, 255, 0.4); margin-bottom: 16px; }
.claim .muted { margin: 0; }
.claim-amt { font-family: var(--display); font-weight: 900; font-size: 22px; font-variant-numeric: tabular-nums; }
.claim-amt .sol { color: var(--mint); }
.btn:disabled { opacity: 0.45; pointer-events: none; }
@media (max-width: 600px) {
  .tiles { grid-template-columns: repeat(2, 1fr); }
  /* one row that swipes sideways; the padding leaves room for the selected glow inside the scroll area.
     width 0 + min-width 100% stops the row's full length from stretching the popup wider than the screen */
  .avatars { display: flex; gap: 8px; overflow-x: auto; padding: 8px 4px; margin: -8px 0; width: 0; min-width: 100%; box-sizing: border-box; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; scrollbar-width: none; touch-action: pan-x; }
  .avatars::-webkit-scrollbar { display: none; }
  .avatars button { flex: 0 0 58px; width: 58px; height: 58px; scroll-snap-align: start; }
  .avatars button:hover { transform: none; }
  .codes { grid-template-columns: repeat(2, 1fr); }
  .qr { width: 120px; height: 120px; }
}
.card h2 { font-family: var(--display); font-weight: 800; font-size: 22px; margin: 0 0 6px; }
.card h3 { font-family: var(--display); font-size: 13px; font-weight: 800; margin: 0 0 4px; color: var(--a2); letter-spacing: 0.04em; }
.close { position: absolute; top: 12px; right: 14px; width: 34px; height: 34px; border-radius: 10px; font-size: 22px; color: var(--muted); }
.close:hover { background: rgba(255, 255, 255, 0.08); color: var(--text); }
.muted { color: var(--muted); margin: 0 0 14px; line-height: 1.45; }
.small { font-size: 12.5px; }
.center { text-align: center; }
.error { color: #ff6b8b; min-height: 1.2em; margin: 4px 0; font-size: 14px; }
.link { color: var(--violet-hi); text-decoration: underline; font-size: 13px; padding: 0; }
.tabs { display: flex; gap: 4px; padding: 4px; border-radius: 13px; background: rgba(255, 255, 255, 0.05); margin-bottom: 16px; }
.tab { flex: 1; padding: 9px; border-radius: 10px; font-weight: 700; font-size: 14px; color: var(--muted); }
.tab.active { background: linear-gradient(135deg, var(--violet), #6a2bd9); color: #fff; }
.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 5px; }
input {
  width: 100%; padding: 12px 14px; border-radius: 12px; font: inherit; font-size: 16px; color: var(--text);
  background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus { border-color: var(--violet-hi); box-shadow: 0 0 0 3px rgba(153, 69, 255, 0.25); }
.with-btn { display: flex; gap: 8px; }
.wallet-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 16px; padding-right: 30px; }
.wallet-balance { font-family: var(--display); font-weight: 900; font-size: 30px; font-variant-numeric: tabular-nums; }
.wallet-balance .sol { color: var(--mint); }
.wallet-balance small { font-size: 13px; color: var(--muted); font-weight: 600; }
.notice { padding: 13px 15px; border-radius: 13px; background: rgba(153, 69, 255, 0.12); border: 1px solid rgba(153, 69, 255, 0.35); line-height: 1.45; margin-bottom: 12px; font-size: 14px; }
.notice-dev { background: rgba(255, 192, 46, 0.1); border-color: rgba(255, 192, 46, 0.35); }
.address { display: flex; gap: 8px; align-items: center; padding: 10px; border-radius: 12px; background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); margin-bottom: 10px; }
.address code { flex: 1; word-break: break-all; font-size: 13px; }
.dep-row { display: flex; gap: 14px; align-items: center; margin-bottom: 12px; }
.dep-side { min-width: 0; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.dep-side .muted { margin: 0; }
.dep-side code { word-break: break-all; font-size: 13px; line-height: 1.4; }
.dep-wait { display: flex; align-items: center; gap: 9px; padding: 10px 13px; border-radius: 12px; background: rgba(20, 241, 149, 0.08); border: 1px solid rgba(20, 241, 149, 0.28); margin-bottom: 12px; font-size: 14px; }
.dep-wait i { width: 9px; height: 9px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 10px var(--mint); animation: depPulse 1.2s ease-in-out infinite; }
.dep-wait.seen { background: rgba(255, 192, 46, 0.1); border-color: rgba(255, 192, 46, 0.4); }
.dep-wait.seen i { background: #ffc02e; box-shadow: 0 0 10px #ffc02e; }
@keyframes depPulse { 50% { opacity: 0.25; transform: scale(0.7); } }
.history a { color: var(--violet-hi); }
.history { max-height: 300px; overflow-y: auto; }
.history .row { display: grid; grid-template-columns: 1fr auto 96px; gap: 10px; align-items: center; padding: 10px 2px; border-bottom: 1px solid var(--line); font-size: 14px; }
.history small { display: block; color: var(--muted); font-size: 12px; }
.amt { font-family: var(--display); font-weight: 800; font-size: 13px; font-variant-numeric: tabular-nums; }
.amt.pos { color: var(--mint); }
.status { text-align: right; font-size: 12px; text-transform: capitalize; color: var(--muted); }
.status.pending { color: var(--gold); }
.status.confirmed, .status.sent { color: var(--mint); }

.paytable { display: grid; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 10px; margin-bottom: 18px; }
.pt { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 6px; border-radius: 14px; background: rgba(255, 255, 255, 0.045); border: 1px solid var(--line); }
.pt.special { border-color: rgba(20, 241, 149, 0.35); background: rgba(20, 241, 149, 0.06); }
.pt img { width: 68px; height: 68px; flex: none; }
.pt b { display: block; font-size: 13px; margin-bottom: 3px; }
.pt span { display: block; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pt span i { display: inline-block; width: 1.4em; font-style: normal; font-weight: 700; color: var(--gold); }
.rules { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px 22px; margin-bottom: 14px; }
.rules p { margin: 0; color: #c9cbe8; font-size: 14px; line-height: 1.5; }

.toasts { position: fixed; top: 70px; left: 50%; transform: translateX(-50%); z-index: 40; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { padding: 10px 18px; border-radius: 12px; background: rgba(20, 14, 50, 0.96); border: 1px solid rgba(180, 107, 255, 0.4); font-weight: 600; font-size: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); animation: toastIn 0.3s cubic-bezier(0.2, 1.4, 0.4, 1); transition: opacity 0.4s, transform 0.4s; max-width: 90vw; }
.toast.good { border-color: rgba(20, 241, 149, 0.6); }
.toast.warn { border-color: rgba(255, 107, 139, 0.7); }
.toast.out { opacity: 0; transform: translateY(-10px); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-14px) scale(0.9); } }
.conn { position: fixed; bottom: 10px; left: 10px; z-index: 50; padding: 6px 12px; border-radius: 10px; background: #5a1030; font-size: 13px; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 860px) {
  .feed-text { display: none; }
  .feed { justify-content: flex-start; }
}
/* not enough width for one row: bet controls get their own row, Spin stays centred between Win and the toggles */
@media (max-width: 1040px) {
  .controls { grid-template-areas: 'bet bet bet' 'win spin toggles'; gap: 8px 12px; padding: 8px 12px 12px; }
  .ctl-bet { justify-self: center; max-width: 100%; }
  .ctl-bet label { text-align: center; }
  .ctl-win { grid-area: win; justify-self: center; text-align: center; }
  .ctl-toggles { grid-area: toggles; justify-self: center; align-self: center; flex-direction: column; gap: 6px; }
  .ctl-toggles .toggle { width: 100%; }
  .win-value { min-width: 0; padding-left: 12px; padding-right: 12px; }
  .auto-menu { left: auto; right: 0; transform: none; }
}
@media (max-width: 600px) {
  .topbar { gap: 8px; padding: 8px 10px; }
  .brand-name { font-size: 15px; }
  .brand-mark { width: 24px; height: 24px; }
  .live { display: none; }
  .feed { display: none; }
  .top-actions { margin-left: auto; gap: 6px; }
  .balance { padding: 7px 10px; font-size: 13px; }
  .btn { padding: 8px 11px; font-size: 13px; }
  .icon-btn { width: 34px; height: 34px; }
  .stagebar #btnInfo { right: auto; left: 0; } /* one each side so the multiplier trail keeps the middle */
  .fs-stat { min-width: 84px; }
  .value { min-width: 0; padding: 9px 8px; font-size: 14px; }
  .bet-row { gap: 4px; }
  .bet-row .value { flex: 1; min-width: 84px; }
  .ctl-bet { justify-self: stretch; }
  .step { width: 34px; height: 38px; flex: none; }
  .step.quick { min-width: 36px; padding: 0 6px; font-size: 11px; }
  .toggle { padding: 8px 12px; font-size: 11px; }
  .spin { width: 92px; height: 92px; }
  .spin-core { width: 76px; height: 76px; }
  .spin-label { font-size: 14px; }
  .mult-label { display: none; }
  .multbar.fs { gap: 10px; }
  .fs-stat { min-width: 76px; }
  .card { padding: 20px 16px; }
}
@media (max-height: 520px) {
  .multbar { height: 36px; }
  .spin { width: 78px; height: 78px; }
  .spin-core { width: 64px; height: 64px; }
  .controls { padding-top: 4px; padding-bottom: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .brand-mark, .spin-ring { animation: none; }
}
@media (max-width: 480px) {
  .brand-name { display: none; }
}

/* links to the legal pages */
.legal { margin: 10px 0 0; }
.legal a { color: var(--mint); text-decoration: none; }
.legal a:hover { text-decoration: underline; }

.acct-logout a.link { margin-right: 18px; }
