/* Bingo. Everything is scoped under .bg. Nothing here is position: fixed. */
.bg { display: flex; flex-direction: column; color: #dfe9ff; font-variant-numeric: tabular-nums; --bg-accent: #55d6ff; --bg-warm: #ffd166; --bg-pink: #ff6b81; --bg-ink: #e8425f;
  --bg-c1: #8c2f39; --bg-c2: #3a1420; --bg-glow: #ffd166; --bg-wall: #2a1c2e; }
.bg *, .bg *::before, .bg *::after { box-sizing: border-box; }
.bg [hidden] { display: none !important; }
:where(.bg) button { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.bg-stage { position: relative; width: 100%; height: min(calc(100vh - 150px), 760px); min-height: 560px; overflow: hidden; border-radius: 12px; outline: none;
  background: radial-gradient(130% 75% at 50% -12%, var(--bg-c1) 0%, var(--bg-c2) 52%, var(--bg-wall) 100%); user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
@media (max-width: 600px) { .bg-stage { height: calc(100svh - 150px); max-height: 860px; } }
.stage.is-immersive .stage-body > .bg { min-height: 0; }
.stage.is-immersive .bg-stage { flex: 1 1 auto; height: auto; max-height: none; min-height: 0; border-radius: 0; }

/* the hall: a scalloped valance with a row of bulbs */
.bg-decor { position: absolute; inset: 0; pointer-events: none; }
.bg-curtain { position: absolute; left: 0; right: 0; top: 0; height: 11px; background: radial-gradient(circle at 50% 0, var(--bg-c1) 0 69%, transparent 72%) 0 0 / 30px 11px repeat-x; filter: brightness(1.35) saturate(1.1); }
.bg-bulbs { position: absolute; left: 0; right: 0; top: 2px; height: 6px; background: radial-gradient(circle, var(--bg-glow) 0 1.8px, transparent 2.6px) 0 0 / 30px 6px repeat-x; opacity: 0.95; animation: bg-twinkle 1.8s steps(2, jump-none) infinite; }
@keyframes bg-twinkle { 0% { opacity: 0.95; } 100% { opacity: 0.45; } }

/* balls: nine colour families */
.bg-k0 { --k1: #4aa3ff; --k2: #1456c4; } .bg-k1 { --k1: #ff6b81; --k2: #c21f3f; } .bg-k2 { --k1: #c9d2e6; --k2: #7c88a6; } .bg-k3 { --k1: #4fd18b; --k2: #16864c; }
.bg-k4 { --k1: #ffb347; --k2: #d96a0a; } .bg-k5 { --k1: #b78bff; --k2: #6a35d6; } .bg-k6 { --k1: #35d6c9; --k2: #0b8a82; } .bg-k7 { --k1: #ffd84a; --k2: #c79a06; } .bg-k8 { --k1: #ff8fd0; --k2: #c4338c; }
.bg-b { --s: 28px; flex: none; width: var(--s); height: var(--s); border-radius: 50%; display: inline-grid; place-items: center; background: radial-gradient(circle at 32% 26%, #fff 0 6%, var(--k1) 30%, var(--k2) 100%);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.45), inset 0 -2px 4px rgba(0, 0, 0, 0.25); }
.bg-b-in { width: 66%; height: 66%; border-radius: 50%; background: #fff; display: grid; place-items: center; align-content: center; color: #1d2333; line-height: 1; box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25); }
.bg-b-in i { font-style: normal; font-weight: 800; font-size: calc(var(--s) * 0.19); letter-spacing: 0.04em; color: var(--k2); }
.bg-b-in b { font-weight: 900; font-size: calc(var(--s) * 0.34); }
.bg-b-in i + b { font-size: calc(var(--s) * 0.3); }

/* ---------- menu ---------- */
.bg-menu { position: absolute; inset: 0; overflow-y: auto; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 26px 12px 14px; }
.bg-logo { display: flex; gap: 6px; flex: none; }
.bg-logo span { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 26px; color: #1d2333;
  background: radial-gradient(circle, #fff 0 45%, transparent 47%), radial-gradient(circle at 32% 26%, #fff 0 6%, var(--k1) 30%, var(--k2) 100%); box-shadow: 0 4px 10px rgba(0, 0, 0, 0.45), inset 0 -3px 6px rgba(0, 0, 0, 0.25); animation: bg-bob 3.2s ease-in-out infinite; }
.bg-logo span:nth-child(2) { animation-delay: -0.5s; } .bg-logo span:nth-child(3) { animation-delay: -1s; } .bg-logo span:nth-child(4) { animation-delay: -1.5s; } .bg-logo span:nth-child(5) { animation-delay: -2s; }
@keyframes bg-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.bg-sub { margin: 0; max-width: 460px; text-align: center; font-size: 14px; line-height: 1.35; color: #f0e6ea; text-wrap: balance; }
.bg-play { flex: none; width: min(100%, 420px); min-height: 84px; padding: 8px 14px; border: 0; border-radius: 18px; display: grid; place-items: center; align-content: center; gap: 2px; cursor: pointer;
  background: linear-gradient(#ffe69a, #ffb72e); color: #3a2400 !important; box-shadow: 0 6px 0 #b9770a, 0 14px 26px rgba(0, 0, 0, 0.42); transition: transform 0.08s, box-shadow 0.08s, filter 0.15s; }
.bg-play b { font-size: 30px; font-weight: 900; letter-spacing: 0.05em; line-height: 1.05; }
.bg-play small { font-size: 13px; font-weight: 700; opacity: 0.86; }
.bg-play:hover { filter: brightness(1.06); }
.bg-play:active { transform: translateY(4px); box-shadow: 0 2px 0 #b9770a, 0 6px 14px rgba(0, 0, 0, 0.42); }
.bg-tiles { flex: none; width: min(100%, 620px); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 4px; }
.bg-tile { position: relative; min-height: 60px; padding: 8px 10px; display: flex; flex-direction: column; justify-content: center; gap: 2px; text-align: left; cursor: pointer; border-radius: 12px;
  background: rgba(9, 14, 34, 0.72); border: 1px solid rgba(255, 255, 255, 0.16); transition: background 0.15s, border-color 0.15s, transform 0.08s; }
.bg-tile b { font-size: 15px; font-weight: 800; color: #fff; line-height: 1.15; }
.bg-tile small, .bg-tile [data-rg-daily] { font-size: 11.5px; color: #b9c6e4; line-height: 1.2; }
.bg-tile [data-rg-daily] { color: var(--bg-warm); }
.bg-tile [data-rg-daily]:empty { display: none; }
.bg-tile:hover { background: rgba(20, 30, 66, 0.86); border-color: rgba(255, 255, 255, 0.4); }
.bg-tile:active { transform: scale(0.97); }
@media (max-width: 600px) { .bg-menu { padding-top: 22px; gap: 8px; } .bg-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .bg-logo span { width: 48px; height: 48px; font-size: 23px; } .bg-tile { min-height: 56px; } }

/* ---------- the hall in play ---------- */
.bg-game { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 6px; padding: 14px 8px 8px; }
.bg-top { flex: none; display: flex; align-items: stretch; gap: 5px; min-height: 42px; }
.bg-patchip, .bg-chip { min-width: 0; height: 42px; background: rgba(8, 12, 30, 0.72); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 12px; }
.bg-patchip { flex: 0 1 auto; display: flex; align-items: center; gap: 6px; padding: 3px 9px 3px 4px; }
.bg-patfig { flex: none; width: 34px; height: 34px; display: grid; place-items: center; background: #fffdf5; border-radius: 7px; padding: 2px; }
.bg-pat { width: 100%; height: 100%; display: block; }
.bg-pat .on { fill: #e8425f; } .bg-pat .off { fill: #ddd5c0; } .bg-pat .fr { fill: #fff; opacity: 0.9; }
.bg-pattxt { min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.bg-pattxt small, .bg-chip small { font-size: 9.5px; letter-spacing: 0.09em; text-transform: uppercase; color: #a9b8d8; line-height: 1.1; white-space: nowrap; }
.bg-pattxt b { font-size: 14px; font-weight: 800; color: #fff; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bg-chip { flex: none; padding: 3px 9px; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.bg-chip b { font-size: 16px; font-weight: 800; color: #fff; line-height: 1.15; white-space: nowrap; }
.bg-score.is-dbl { border-color: var(--bg-warm); box-shadow: 0 0 12px rgba(255, 209, 102, 0.5); } .bg-score.is-dbl b { color: var(--bg-warm); }
.bg-score.is-bump b { animation: bg-bump 0.28s ease-out; }
@keyframes bg-bump { 0% { transform: scale(1); } 40% { transform: scale(1.25); } 100% { transform: scale(1); } }
.bg-grow { flex: 1 1 0; min-width: 0; }
.bg-ib { position: relative; flex: none; width: 42px; height: 42px; padding: 0; display: grid; place-items: center; color: #e6eeff; background: rgba(8, 12, 30, 0.72); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 12px; cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.08s; }
.bg-ib svg { width: 22px; height: 22px; display: block; }
.bg-ib:hover { background: rgba(26, 38, 80, 0.9); border-color: rgba(255, 255, 255, 0.5); }
.bg-ib:active { transform: scale(0.94); }
#bg-mute .bg-off { display: none; } #bg-mute.is-muted .bg-on { display: none; } #bg-mute.is-muted .bg-off { display: inline; } #bg-mute.is-muted { color: #9fb0cf; }
.bg :is(button, [tabindex]):focus-visible { outline: 3px solid #9fe8ff; outline-offset: 2px; }
.bg-stage:focus-visible { outline: none; }

/* prizes and the room */
.bg-room { flex: none; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 4px 5px; height: 26px; overflow: hidden; }
.bg-room.bg-rows2 { height: 56px; }
.bg-prize, .bg-rv { flex: none; height: 26px; display: inline-flex; align-items: center; gap: 4px; padding: 0 8px 0 3px; border-radius: 13px; font-size: 12px; font-weight: 700; white-space: nowrap; background: rgba(8, 12, 30, 0.66); border: 1px solid rgba(255, 255, 255, 0.13); color: #dfe9ff; }
.bg-prize i { font-style: normal; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; display: grid; place-items: center; font-size: 10.5px; font-weight: 900; color: #3a2400; background: linear-gradient(#ffe69a, #f0b030); }
.bg-prize.is-gone { opacity: 0.75; } .bg-prize.is-gone i { background: #56617f; color: #dfe9ff; }
.bg-prize.is-mine { border-color: var(--bg-warm); color: var(--bg-warm); box-shadow: 0 0 10px rgba(255, 209, 102, 0.4); opacity: 1; } .bg-prize.is-mine i { background: linear-gradient(#ffe69a, #f0b030); color: #3a2400; }
.bg-prize.is-next { border-color: rgba(255, 255, 255, 0.5); }
.bg-rv { padding: 0 3px 0 9px; }
.bg-rv i { font-style: normal; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; display: grid; place-items: center; font-size: 11px; font-weight: 900; background: rgba(255, 255, 255, 0.14); color: #fff; }
.bg-rv em { font-style: normal; font-size: 10px; color: #a9b8d8; font-weight: 600; }
.bg-rv.is-near { border-color: var(--bg-pink); color: #fff; animation: bg-near 0.9s ease-in-out infinite; } .bg-rv.is-near i { background: var(--bg-pink); }
.bg-rv.is-two i { background: #c9822a; }
.bg-rv.is-won { border-color: rgba(255, 209, 102, 0.6); } .bg-rv.is-won i { background: linear-gradient(#ffe69a, #f0b030); color: #3a2400; }
@keyframes bg-near { 0%, 100% { box-shadow: 0 0 0 rgba(255, 107, 129, 0); } 50% { box-shadow: 0 0 12px rgba(255, 107, 129, 0.8); } }
.bg-roomnote { font-size: 12.5px; line-height: 26px; color: #dfe9ff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 4px; }

/* main area: two layouts, chosen by the script so that card cells never fall under 40 px */
.bg-main { flex: 1 1 auto; min-height: 0; display: grid; gap: 6px; --bg-sidew: 200px; }
.bg-main.bg-l-side { grid-template-columns: minmax(0, 1fr) var(--bg-sidew); grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "cards caller" "cards board" "cards act"; }
.bg-main.bg-l-stack { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto; grid-template-areas: "caller" "cards" "act"; }
.bg-main.bg-l-stack.bg-wide { grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); grid-template-areas: "caller board" "cards cards" "act act"; }
.bg-cardsw { grid-area: cards; min-width: 0; min-height: 0; display: flex; flex-direction: column; gap: 6px; }
.bg-caller { grid-area: caller; min-width: 0; }
.bg-board { grid-area: board; min-width: 0; min-height: 0; }
.bg-act { grid-area: act; min-width: 0; }
.bg-main.bg-l-stack:not(.bg-wide) > .bg-board { display: none; }

/* the caller */
.bg-caller { position: relative; background: rgba(8, 12, 30, 0.6); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 12px; }
.bg-l-side .bg-caller { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 5px 5px 6px; }
.bg-l-side .bg-mach { width: 100%; height: var(--bg-machh, 84px); }
.bg-l-side .bg-now { margin-top: -12px; }
.bg-l-stack .bg-caller { display: grid; grid-template-columns: 84px auto minmax(0, 1fr); grid-template-rows: auto auto; grid-template-areas: "mach now callt" "mach now last"; align-items: center; column-gap: 8px; padding: 4px 8px 4px 4px; height: 82px; }
.bg-l-stack .bg-mach { grid-area: mach; width: 84px; height: 72px; }
.bg-l-stack .bg-now { grid-area: now; }
.bg-l-stack .bg-callt { grid-area: callt; align-self: end; text-align: left; }
.bg-l-stack .bg-last { grid-area: last; align-self: start; justify-content: flex-start; }
.bg-l-stack .bg-peek { position: absolute; right: 6px; top: 4px; }
.bg-mach { display: block; }
.bg-now { --s: var(--bg-nows, 64px); width: var(--s); height: var(--s); flex: none; display: grid; place-items: center; }
.bg-now .bg-b { --s: var(--bg-nows, 64px); }
.bg-now .bg-b.is-new { animation: bg-drop 0.42s cubic-bezier(0.2, 1.4, 0.4, 1); }
@keyframes bg-drop { 0% { transform: translateY(-26px) scale(0.5); opacity: 0; } 100% { transform: none; opacity: 1; } }
.bg-now-empty { width: 100%; height: 100%; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, 0.25); }
.bg-callt { min-height: 34px; display: flex; flex-direction: column; justify-content: center; font-size: 14px; font-weight: 800; line-height: 1.2; color: #fff; text-align: center; text-wrap: balance; overflow: hidden; }
.bg-callt small { display: block; font-size: 11.5px; font-weight: 600; color: #cdd8f2; }
.bg-last { display: flex; justify-content: center; gap: 3px; min-height: 24px; }
.bg-last .bg-b { --s: 24px; opacity: 0.92; } .bg-last .bg-b:nth-child(n+4) { opacity: 0.7; }
.bg-peek { display: flex; align-items: center; gap: 3px; padding: 2px 6px 2px 8px; border-radius: 14px; background: rgba(85, 214, 255, 0.16); border: 1px solid rgba(85, 214, 255, 0.5); font-size: 10.5px; font-weight: 700; color: #bfefff; }
.bg-peek .bg-b { --s: 22px; }

/* the board of called numbers */
.bg-board { background: rgba(8, 12, 30, 0.6); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 12px; padding: 4px; display: flex; overflow: hidden; }
.bg-bd { flex: 1 1 auto; min-width: 0; min-height: 0; display: flex; flex-direction: column; gap: 2px; }
.bg-bd.bg-bd-h { flex-direction: row; }
.bg-bd-hd { flex: none; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; }
.bg-bd-h .bg-bd-hd { grid-auto-flow: row; grid-auto-rows: 1fr; width: 18px; }
.bg-bd-hd i { font-style: normal; display: grid; place-items: center; min-height: 15px; border-radius: 4px; font-size: 10.5px; font-weight: 900; color: #fff; background: linear-gradient(var(--k1), var(--k2)); }
.bg-bd-g { flex: 1 1 auto; min-height: 0; display: grid; gap: 1px; }
.bg-bd-g i { font-style: normal; min-width: 0; min-height: 0; display: grid; place-items: center; overflow: hidden; border-radius: 3px; font-size: var(--bg-bdf, 10px); font-weight: 700; line-height: 1; color: rgba(214, 226, 255, 0.5); background: rgba(255, 255, 255, 0.05); }
.bg-bd-g i.on { color: #10162c; background: linear-gradient(var(--k1), var(--k2)); font-weight: 900; }
.bg-bd-g i.last { box-shadow: 0 0 0 2px #fff, 0 0 10px #fff; position: relative; z-index: 1; }

/* power-ups and the Bingo button */
.bg-act { display: flex; gap: 6px; }
.bg-l-side .bg-act { flex-direction: column; }
.bg-l-stack .bg-act { flex-direction: row; align-items: stretch; }
.bg-powbox { flex: none; display: flex; flex-direction: column; gap: 4px; justify-content: center; }
.bg-meter { height: 7px; border-radius: 4px; background: rgba(255, 255, 255, 0.14); overflow: hidden; }
.bg-meter i { display: block; height: 100%; width: 0; border-radius: 4px; background: linear-gradient(90deg, #55d6ff, #b78bff); transition: width 0.25s ease; }
.bg-pows { display: flex; gap: 4px; justify-content: center; }
.bg-pow { position: relative; flex: 1 1 0; min-width: 42px; max-width: 64px; height: 42px; padding: 0; display: grid; place-items: center; border-radius: 12px; cursor: pointer; color: #06203a; background: linear-gradient(#bff1ff, #55d6ff); border: 0; box-shadow: 0 3px 0 #1a86b0; transition: transform 0.08s, filter 0.15s; }
.bg-pow svg { width: 22px; height: 22px; display: block; }
.bg-pow i { position: absolute; right: -3px; top: -4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; font-style: normal; font-size: 11px; font-weight: 900; line-height: 17px; text-align: center; color: #3a2400; background: var(--bg-warm); }
.bg-pow:disabled { cursor: default; color: #8fa0c4; background: rgba(8, 12, 30, 0.6); box-shadow: none; border: 1px dashed rgba(255, 255, 255, 0.22); }
.bg-pow:disabled i { display: none; }
.bg-pow:not(:disabled):hover { filter: brightness(1.08); }
.bg-pow:not(:disabled):active { transform: translateY(2px); }
.bg-pow.is-new { animation: bg-bump 0.5s ease-out 2; }
.bg-bingorow { flex: 1 1 auto; min-width: 0; display: flex; gap: 5px; }
.bg-bingo { flex: 1 1 auto; min-width: 0; min-height: 58px; padding: 4px 8px; border: 0; border-radius: 16px; display: grid; place-items: center; align-content: center; cursor: pointer;
  background: linear-gradient(#ff8a9c, #e3264a); color: #fff !important; box-shadow: 0 5px 0 #8f1028, 0 10px 18px rgba(0, 0, 0, 0.4); transition: transform 0.08s, box-shadow 0.08s, filter 0.15s; }
.bg-bingo b { font-size: 24px; font-weight: 900; letter-spacing: 0.06em; line-height: 1.05; text-shadow: 0 2px 0 rgba(0, 0, 0, 0.25); }
.bg-bingo small { font-size: 11px; font-weight: 700; line-height: 1.15; opacity: 0.95; }
.bg-bingo small:empty { display: none; }
.bg-bingo:hover { filter: brightness(1.07); }
.bg-bingo:active { transform: translateY(3px); box-shadow: 0 2px 0 #8f1028, 0 5px 10px rgba(0, 0, 0, 0.4); }
.bg-bingo.is-hot { background: linear-gradient(#ffe69a, #ffb72e); color: #3a2400 !important; box-shadow: 0 5px 0 #b9770a, 0 0 22px rgba(255, 209, 102, 0.85); animation: bg-hot 0.7s ease-in-out infinite; }
.bg-bingo.is-hot b { text-shadow: none; }
@keyframes bg-hot { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.035); } }
.bg-bingo.is-locked { background: linear-gradient(#6b7694, #47506b); box-shadow: 0 5px 0 #2c3246; cursor: default; animation: none; }
.bg-bingo.is-shake { animation: bg-shake 0.3s linear; }
@keyframes bg-shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.bg-finish { flex: none; width: 48px; min-height: 58px; padding: 2px; border-radius: 14px; display: grid; place-items: center; align-content: center; gap: 1px; cursor: pointer; color: #06203a; background: linear-gradient(#c9f7d8, #4fd18b); border: 0; box-shadow: 0 4px 0 #16864c; }
.bg-finish svg { width: 22px; height: 22px; }
.bg-finish small { font-size: 10.5px; font-weight: 800; line-height: 1; }
.bg-l-side .bg-bingo { min-height: 64px; }
.bg-l-stack .bg-pow { flex: none; width: 44px; height: 44px; }

/* your cards */
.bg-cards { flex: 1 1 auto; min-height: 0; min-width: 0; display: flex; touch-action: pan-y; }
.bg-cards.bg-scroll { overflow: auto; }
.bg-page { flex: 1 1 auto; min-width: 0; min-height: 0; display: grid; gap: 6px 8px; justify-content: center; align-content: center; justify-items: center; }
.bg-page.is-in { animation: bg-pagein 0.2s ease-out; }
@keyframes bg-pagein { 0% { opacity: 0.2; transform: translateX(var(--bg-dir, 14px)); } 100% { opacity: 1; transform: none; } }
.bg-card { --bg-cw: 44px; --bg-ch: 44px; display: flex; flex-direction: column; align-items: stretch; }
.bg-card-tab { height: 15px; display: flex; align-items: flex-end; justify-content: space-between; gap: 6px; padding: 0 5px; font-size: 10.5px; font-weight: 800; line-height: 15px; color: #fff; white-space: nowrap; }
.bg-card-tab b { font-weight: 800; opacity: 0.9; }
.bg-togo { padding: 0 7px; border-radius: 8px 8px 0 0; background: rgba(8, 12, 30, 0.75); color: #dfe9ff; }
.bg-togo.is-one { background: var(--bg-warm); color: #3a2400; }
.bg-togo.is-ready { background: #4fd18b; color: #06301a; }
.bg-togo.is-won { background: linear-gradient(#ffe69a, #f0b030); color: #3a2400; }
.bg-paper { position: relative; padding: 3px; border-radius: 9px; background: linear-gradient(#fffdf5, #f1e8d2); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45); border: 1px solid #cfc3a4; }
.bg-letters { display: grid; grid-template-columns: repeat(5, var(--bg-cw)); gap: 2px; margin-bottom: 2px; }
.bg-letters i { font-style: normal; height: 18px; display: grid; place-items: center; border-radius: 5px; font-size: 13px; font-weight: 900; color: #fff; background: linear-gradient(var(--k1), var(--k2)); text-shadow: 0 1px 0 rgba(0, 0, 0, 0.3); }
.bg-grid { display: grid; gap: 2px; grid-template-columns: repeat(5, var(--bg-cw)); grid-auto-rows: var(--bg-ch); }
.bg-t90 .bg-grid { grid-template-columns: repeat(9, var(--bg-cw)); gap: 1px; }
.bg-t90.bg-compact .bg-grid { grid-template-columns: repeat(5, var(--bg-cw)); gap: 2px; }
.bg-t90.bg-compact .bg-cell { border-radius: 6px; }
.bg-t30 .bg-grid { grid-template-columns: repeat(3, var(--bg-cw)); }
.bg-cell { position: relative; padding: 0; margin: 0; min-width: 0; display: grid; place-items: center; border: 1px solid #d4c9ae; border-radius: 6px; background: #fffefa; color: #23283a !important; font-weight: 800; font-size: calc(min(var(--bg-cw), var(--bg-ch)) * 0.44); line-height: 1; cursor: pointer; }
.bg-t90 .bg-cell { border-radius: 4px; }
.bg-cell.bg-blank { background: repeating-linear-gradient(135deg, #e9dfc6 0 4px, #e2d7bb 4px 8px); border-color: #d9ceb3; cursor: default; }
.bg-cell.bg-free { background: #fff3c4; cursor: default; font-size: calc(var(--bg-cw) * 0.22); font-weight: 900; letter-spacing: 0.04em; color: #a8740a !important; }
.bg-cell.bg-inpat { background: #fff3c4; border-color: #e4c56a; }
.bg-card.bg-haspat .bg-cell:not(.bg-inpat):not(.bg-free) { color: #8c8a86 !important; font-weight: 700; }
button.bg-cell:hover { border-color: #8d7f5a; }
button.bg-cell:active { transform: scale(0.94); }
.bg-cell.is-daub::after, .bg-cell.is-wild::after, .bg-cell.bg-free::after { content: ""; position: absolute; inset: 9%; border-radius: 50%; background: var(--bg-ink); opacity: 0.56; mix-blend-mode: multiply; pointer-events: none; }
.bg-cell.bg-free::after { opacity: 0.3; }
.bg-cell.is-daub.is-fresh::after, .bg-cell.is-wild.is-fresh::after { animation: bg-blot 0.22s cubic-bezier(0.2, 1.5, 0.4, 1); }
@keyframes bg-blot { 0% { transform: scale(0.2); opacity: 0.9; } 100% { transform: scale(1); opacity: 0.56; } }
.bg-cell.is-wild::after { background: #e0a400; opacity: 0.62; }
.bg-cell.is-wild { box-shadow: 0 0 8px rgba(255, 200, 40, 0.9); }
.bg[data-shape="star"] .bg-cell.is-daub::after { inset: 3%; border-radius: 0; clip-path: polygon(50% 2%, 62% 35%, 98% 36%, 69% 58%, 80% 93%, 50% 72%, 20% 93%, 31% 58%, 2% 36%, 38% 35%); }
.bg[data-shape="heart"] .bg-cell.is-daub::after { inset: 6%; border-radius: 0; clip-path: polygon(50% 98%, 12% 62%, 2% 40%, 3% 22%, 13% 8%, 28% 4%, 41% 9%, 50% 21%, 59% 9%, 72% 4%, 87% 8%, 97% 22%, 98% 40%, 88% 62%); }
.bg[data-shape="clover"] .bg-cell.is-daub::after { inset: 4%; border-radius: 0; background: radial-gradient(circle at 50% 26%, var(--bg-ink) 0 23%, transparent 24.5%), radial-gradient(circle at 26% 55%, var(--bg-ink) 0 23%, transparent 24.5%), radial-gradient(circle at 74% 55%, var(--bg-ink) 0 23%, transparent 24.5%), radial-gradient(circle at 50% 80%, var(--bg-ink) 0 13%, transparent 14.5%), radial-gradient(circle at 50% 52%, var(--bg-ink) 0 14%, transparent 15.5%); }
.bg[data-shape="ring"] .bg-cell.is-daub::after { background: transparent; border: calc(var(--bg-cw) * 0.11) solid var(--bg-ink); opacity: 0.7; }
.bg-cell.is-win { background: #ffe9a3; border-color: #d99a00; box-shadow: 0 0 10px rgba(255, 200, 40, 0.95); z-index: 1; animation: bg-winc 0.7s ease-in-out 3; }
@keyframes bg-winc { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.08); } }
.bg-cell.is-nope { animation: bg-shake 0.25s linear; }
.bg-pop { position: absolute; left: 50%; top: -4px; transform: translateX(-50%); font-size: 12px; font-weight: 900; color: #fff; text-shadow: 0 1px 3px #000, 0 0 6px rgba(0, 0, 0, 0.9); pointer-events: none; z-index: 3; white-space: nowrap; animation: bg-popup 0.7s ease-out forwards; }
.bg-pop.is-bonus { color: var(--bg-warm); font-size: 14px; }
@keyframes bg-popup { 0% { opacity: 0; transform: translate(-50%, 6px); } 20% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -22px); } }
.bg-card.is-ready .bg-paper { box-shadow: 0 0 0 3px #4fd18b, 0 0 20px rgba(79, 209, 139, 0.8); animation: bg-ready 0.8s ease-in-out infinite; }
@keyframes bg-ready { 0%, 100% { box-shadow: 0 0 0 3px #4fd18b, 0 0 10px rgba(79, 209, 139, 0.5); } 50% { box-shadow: 0 0 0 3px #4fd18b, 0 0 24px rgba(79, 209, 139, 0.95); } }
.bg-card.is-won .bg-paper { box-shadow: 0 0 0 3px #f0b030, 0 0 18px rgba(255, 200, 40, 0.7); }
.bg-card.is-done .bg-paper { opacity: 0.94; }
.bg-ribbon { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(-8deg); padding: 3px 12px; border-radius: 8px; font-size: 14px; font-weight: 900; letter-spacing: 0.05em; color: #3a2400; background: linear-gradient(#ffe69a, #f0b030); box-shadow: 0 3px 10px rgba(0, 0, 0, 0.5); z-index: 2; pointer-events: none; white-space: nowrap; }

/* pager tabs */
.bg-tabs { flex: none; display: flex; gap: 6px; justify-content: center; }
.bg-tab { position: relative; flex: 1 1 0; max-width: 180px; min-height: 44px; padding: 4px 10px; border-radius: 12px; cursor: pointer; font-size: 13px; font-weight: 800; color: #dfe9ff; background: rgba(8, 12, 30, 0.72); border: 1px solid rgba(255, 255, 255, 0.2); }
.bg-tab[aria-selected="true"] { background: #fffdf5; color: #23283a !important; border-color: #fff; }
.bg-tab i { position: absolute; right: -4px; top: -5px; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 10px; font-style: normal; font-size: 11.5px; font-weight: 900; line-height: 19px; text-align: center; color: #fff; background: var(--bg-pink); box-shadow: 0 0 8px rgba(255, 107, 129, 0.8); }
.bg-tab i:empty { display: none; }
.bg-tab.is-ready { border-color: #4fd18b; box-shadow: 0 0 12px rgba(79, 209, 139, 0.8); }

/* toast, count-in, confetti, live region */
.bg-toast { position: absolute; left: 50%; top: 92px; transform: translateX(-50%); max-width: calc(100% - 24px); padding: 8px 14px; border-radius: 14px; font-size: 14px; font-weight: 800; line-height: 1.25; text-align: center; color: #fff; background: rgba(8, 12, 30, 0.93); border: 1px solid rgba(255, 255, 255, 0.35); box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5);
  pointer-events: none; opacity: 0; transition: opacity 0.2s; z-index: 6; text-wrap: balance; width: max-content; }
.bg-toast.is-on { opacity: 1; }
.bg-toast.is-bad { border-color: var(--bg-pink); } .bg-toast.is-good { border-color: var(--bg-warm); color: #fff3c9; } .bg-toast.is-rival { border-color: #b78bff; }
.bg-count { position: absolute; left: 0; right: 0; top: 60px; bottom: 0; z-index: 5; display: grid; place-items: center; padding: 12px; background: rgba(4, 6, 15, 0.62); }
.bg-count-in { width: min(100%, 360px); padding: 14px 16px 12px; border-radius: 18px; text-align: center; background: rgba(10, 16, 40, 0.95); border: 1px solid rgba(255, 255, 255, 0.25); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55); display: grid; justify-items: center; gap: 5px; }
.bg-count-in small { font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: #a9b8d8; }
.bg-count-in h3 { margin: 0; font-size: 19px; font-weight: 900; color: #fff; }
.bg-count-in p { margin: 0; font-size: 13.5px; line-height: 1.35; color: #dfe9ff; text-wrap: balance; }
.bg-count-fig { width: 84px; height: 84px; padding: 5px; border-radius: 12px; background: #fffdf5; }
.bg-count-n { font-size: 40px; font-weight: 900; line-height: 1; color: var(--bg-warm); min-height: 42px; }
.bg-fx { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 40; }
.bg-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- sheets ---------- */
.bg-sheet { position: absolute; inset: 0; z-index: 30; display: grid; place-items: center; padding: 10px; background: rgba(4, 6, 15, 0.78); }
.bg-dialog { width: min(100%, 520px); max-height: 100%; overflow-y: auto; overscroll-behavior: contain; padding: 14px 16px 16px; border-radius: 16px; background: #0e1730; border: 1px solid #2c3f6e; box-shadow: 0 18px 50px rgba(0, 0, 0, 0.6); outline: none; user-select: text; -webkit-user-select: text; }
.bg-dialog.bg-wide { width: min(100%, 860px); }
.bg-dlg-h { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.bg-dlg-h h2 { flex: 1 1 auto; min-width: 0; margin: 0; font-size: 20px; font-weight: 900; color: #fff; line-height: 1.2; letter-spacing: 0; text-transform: none; }
.bg-dialog p { margin: 0 0 8px; font-size: 14px; line-height: 1.45; color: #cfdbf5; }
.bg-dialog h3 { margin: 12px 0 6px; font-size: 12px; letter-spacing: 0.09em; text-transform: uppercase; color: #9fb0d4; font-weight: 800; }
.bg-dialog ul { margin: 0 0 8px; padding-left: 20px; font-size: 14px; line-height: 1.45; color: #cfdbf5; }
.bg-dialog li { margin-bottom: 4px; }
.bg-dialog kbd { display: inline-block; min-width: 22px; padding: 1px 6px; border-radius: 6px; font: inherit; font-size: 12px; font-weight: 800; text-align: center; color: #fff; background: #22325c; border: 1px solid #3a4f86; }
.bg-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
/* a result sheet that had to shrink to clear the site's reward card keeps its buttons in view */
.bg-dialog.bg-dodged { padding-bottom: 0; }
.bg-dodged > .bg-btns:last-child { position: sticky; bottom: 0; padding: 10px 0 14px; background: #0e1730; box-shadow: 0 -12px 12px -10px rgba(4, 6, 15, 0.95); }
.bg-btn { flex: 1 1 130px; min-height: 46px; padding: 8px 14px; border-radius: 12px; cursor: pointer; font-size: 15px; font-weight: 800; color: #eaf1ff; background: #1a274c; border: 1px solid #3a4f86; transition: background 0.15s, transform 0.08s; }
.bg-btn:hover { background: #24356a; }
.bg-btn:active { transform: scale(0.97); }
.bg-btn.bg-primary { color: #3a2400 !important; background: linear-gradient(#ffe69a, #ffb72e); border-color: #ffd166; box-shadow: 0 3px 0 #b9770a; }
.bg-btn.bg-primary:hover { filter: brightness(1.06); }
.bg-btn.bg-danger { color: #ffd9df; border-color: #8f3044; background: #3a1522; }
.bg-seg { display: flex; flex-wrap: wrap; gap: 6px; }
.bg-opt { flex: 1 1 0; min-width: 64px; min-height: 44px; padding: 5px 8px; border-radius: 11px; cursor: pointer; font-size: 14px; font-weight: 700; color: #dfe9ff; background: #152044; border: 1px solid #2f4172; display: grid; place-items: center; align-content: center; text-align: center; line-height: 1.15; }
.bg-opt small { font-size: 10.5px; font-weight: 600; color: #9fb0d4; }
.bg-opt[aria-pressed="true"] { color: #3a2400 !important; background: linear-gradient(#ffe69a, #ffc64d); border-color: #ffd166; } .bg-opt[aria-pressed="true"] small { color: #6b4a00; }
.bg-opt:disabled { opacity: 0.5; cursor: default; }
.bg-note { font-size: 12.5px !important; color: #9fb0d4 !important; }
/* pattern picker and stamps */
.bg-pats { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 6px; max-height: 232px; overflow-y: auto; padding: 3px; border-radius: 10px; background: rgba(0, 0, 0, 0.2); }
.bg-patbtn { min-height: 76px; padding: 5px 3px 4px; border-radius: 10px; cursor: pointer; display: grid; justify-items: center; align-content: start; gap: 3px; font-size: 10.5px; font-weight: 700; line-height: 1.1; text-align: center; color: #dfe9ff; background: #152044; border: 1px solid #2f4172; }
.bg-patbtn .bg-pat { width: 40px; height: 40px; padding: 2px; border-radius: 6px; background: #fffdf5; }
.bg-patbtn[aria-pressed="true"] { background: #2b3f7c; border-color: var(--bg-warm); box-shadow: 0 0 0 2px var(--bg-warm); color: #fff; }
.bg-stamps { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 7px; }
.bg-stamp { position: relative; min-height: 96px; padding: 6px 4px 5px; border-radius: 10px; display: grid; justify-items: center; align-content: start; gap: 3px; font-size: 11px; font-weight: 700; line-height: 1.12; text-align: center; color: #23283a; background: linear-gradient(#fffdf5, #f1e8d2); border: 2px dashed #b9a777; }
.bg-stamp .bg-pat { width: 46px; height: 46px; }
.bg-stamp em { font-style: normal; font-size: 10px; color: #7a6a3c; font-weight: 800; }
.bg-stamp.is-off { color: #a9b8d8; background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.2); }
.bg-stamp.is-off .bg-pat { opacity: 0.35; } .bg-stamp.is-off em { color: #7f8db0; }
.bg-stamp.is-new { box-shadow: 0 0 0 2px var(--bg-warm), 0 0 14px rgba(255, 209, 102, 0.8); }
.bg-progress { height: 9px; border-radius: 5px; background: rgba(255, 255, 255, 0.12); overflow: hidden; margin: 4px 0 8px; }
.bg-progress i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, #ffe69a, #ffb72e); }
/* Tour map */
.bg-venue { margin-top: 10px; border-radius: 12px; overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.14); background: linear-gradient(120deg, var(--v1), var(--v2)); }
.bg-venue-h { display: flex; align-items: baseline; gap: 8px; padding: 7px 10px 3px; }
.bg-venue-h b { font-size: 15px; font-weight: 900; color: #fff; }
.bg-venue-h span { flex: 1 1 auto; min-width: 0; font-size: 12px; color: rgba(255, 255, 255, 0.82); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bg-venue-h em { font-style: normal; font-size: 12px; font-weight: 800; color: var(--bg-warm); white-space: nowrap; }
.bg-halls { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 5px; padding: 5px 8px 9px; }
.bg-hall { min-height: 52px; padding: 3px 2px; border-radius: 10px; cursor: pointer; display: grid; justify-items: center; align-content: center; gap: 1px; color: #23283a !important; background: #fffdf5; border: 1px solid #cfc3a4; font-weight: 900; font-size: 15px; line-height: 1.1; }
.bg-hall small { font-size: 10px; font-weight: 800; color: #6c6a66; letter-spacing: 0.02em; }
.bg-hall .bg-st { font-size: 11px; letter-spacing: 1px; color: #c9c0aa; } .bg-hall .bg-st b { color: #e09a00; }
.bg-hall.is-next { box-shadow: 0 0 0 3px var(--bg-warm), 0 0 14px rgba(255, 209, 102, 0.8); }
.bg-hall:disabled { cursor: default; color: #a9b8d8 !important; background: rgba(8, 12, 30, 0.5); border-color: rgba(255, 255, 255, 0.15); } .bg-hall:disabled small, .bg-hall:disabled .bg-st { color: #7f8db0; }
@media (max-width: 600px) { .bg-halls { grid-template-columns: repeat(4, minmax(0, 1fr)); } .bg-dialog { padding: 12px 12px 14px; } }
/* hall intro and results */
.bg-intro { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: center; margin-bottom: 8px; }
.bg-intro-fig { width: 96px; height: 96px; padding: 6px; border-radius: 12px; background: #fffdf5; }
.bg-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin: 8px 0; }
.bg-facts:has(> :nth-child(3):last-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (min-width: 601px) { .bg-facts:has(> :nth-child(4):last-child) { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.bg-fact { padding: 6px 9px; border-radius: 10px; background: #152044; border: 1px solid #2a3b69; }
.bg-fact small { display: block; font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: #9fb0d4; }
.bg-fact b { font-size: 15px; font-weight: 800; color: #fff; }
.bg-stars { display: flex; justify-content: center; gap: 6px; margin: 6px 0; font-size: 34px; line-height: 1; color: #3a476e; }
.bg-stars b { color: var(--bg-warm); text-shadow: 0 0 12px rgba(255, 209, 102, 0.7); font-weight: 400; }
.bg-stars b.is-pop { animation: bg-starpop 0.45s cubic-bezier(0.2, 1.6, 0.4, 1) backwards; }
@keyframes bg-starpop { 0% { transform: scale(0.2) rotate(-40deg); opacity: 0; } 100% { transform: none; opacity: 1; } }
.bg-goal { text-align: center; font-size: 12.5px !important; color: #9fb0d4 !important; }
.bg-headline { text-align: center; margin: 2px 0 6px; font-size: 24px; font-weight: 900; color: var(--bg-warm); line-height: 1.15; text-wrap: balance; }
.bg-headline.is-loss { color: #cfdbf5; }
.bg-bigscore { text-align: center; font-size: 15px; color: #cfdbf5; margin-bottom: 6px; } .bg-bigscore b { font-size: 30px; font-weight: 900; color: #fff; }
.bg-prizelist { display: grid; gap: 4px; margin: 6px 0; }
.bg-prizelist div { display: flex; justify-content: space-between; gap: 10px; padding: 6px 10px; border-radius: 9px; font-size: 14px; background: #152044; border: 1px solid #2a3b69; color: #dfe9ff; }
.bg-prizelist div.is-mine { border-color: var(--bg-warm); color: var(--bg-warm); font-weight: 800; }
.bg-newstamps { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 6px 0; }
.bg-newstamps .bg-stamp { min-height: 0; width: 96px; }
.bg-dialog [data-rg-daily] { display: block; text-align: center; font-size: 13.5px; font-weight: 700; color: var(--bg-warm); margin: 6px 0; }
.bg-dialog [data-rg-daily]:empty { display: none; }
.bg-swatches { display: flex; flex-wrap: wrap; gap: 6px; }
.bg-sw { position: relative; width: 46px; height: 46px; border-radius: 12px; cursor: pointer; background: #fffdf5; border: 2px solid #cfc3a4; display: grid; place-items: center; padding: 0; }
.bg-sw::after { content: ""; width: 62%; height: 62%; border-radius: 50%; background: var(--sw, #e8425f); opacity: 0.75; }
.bg-sw[aria-pressed="true"] { border-color: var(--bg-warm); box-shadow: 0 0 0 3px var(--bg-warm); }
.bg-sw:disabled { cursor: default; background: #1a2446; border-color: #2f4172; } .bg-sw:disabled::after { opacity: 0.25; }
.bg-sw small { position: absolute; left: 0; right: 0; bottom: 1px; font-size: 9.5px; font-weight: 800; color: #dfe9ff; text-align: center; }
.bg-sw.bg-shape { font-size: 11px; font-weight: 800; color: #23283a !important; width: auto; min-width: 62px; padding: 0 8px; } .bg-sw.bg-shape::after { display: none; } .bg-sw.bg-shape:disabled { color: #8fa0c4 !important; }
/* sheet board */
.bg-bigboard { height: min(52vh, 380px); display: flex; }
.bg-bigboard .bg-bd-g i { font-size: 13px; border-radius: 5px; } .bg-bigboard .bg-bd-hd i { font-size: 13px; }
.bg-bigboard .bg-bd-h .bg-bd-hd { width: 24px; }

/* Caller mode: the board takes the place of the cards */
.bg-callerboard { flex: 1 1 auto; min-height: 0; min-width: 0; display: flex; padding: 6px; border-radius: 12px; background: rgba(8, 12, 30, 0.6); border: 1px solid rgba(255, 255, 255, 0.12); }
.bg-callerboard .bg-bd-g i { font-size: clamp(11px, 2.2vmin, 20px); border-radius: 6px; } .bg-callerboard .bg-bd-hd i { font-size: 14px; } .bg-callerboard .bg-bd-h .bg-bd-hd { width: 26px; }

@media (max-width: 600px) { .bg-game { padding: 13px 5px 6px; gap: 5px; } .bg-ib { width: 40px; height: 40px; } .bg-patchip, .bg-chip { height: 40px; } .bg-chip { padding: 3px 7px; } .bg-pattxt b { font-size: 13px; } .bg-patfig { width: 32px; height: 32px; } .bg-top { gap: 4px; min-height: 40px; } .bg-toast { top: 84px; font-size: 13px; } }

@media (prefers-reduced-motion: reduce) {
  .bg *, .bg *::before, .bg *::after { animation: none !important; transition: none !important; }
}
.bg.bg-still *, .bg.bg-still *::before, .bg.bg-still *::after { animation: none !important; transition: none !important; }

/* later additions */
button.bg-patchip { font: inherit; color: inherit; cursor: pointer; text-align: left; -webkit-appearance: none; appearance: none; }
button.bg-patchip:hover { border-color: rgba(255, 255, 255, 0.34); }
.bg-main.bg-noboard > .bg-board { display: none; }
.bg-main.bg-l-side.bg-noboard { grid-template-rows: minmax(0, 1fr) auto; grid-template-areas: "cards caller" "cards act"; }
.bg-main.bg-l-side.bg-noboard .bg-caller { justify-content: center; }
.bg-callermode .bg-room { display: none; }
.bg-recent { display: flex; justify-content: center; gap: 6px; margin: 2px 0 10px; --s: 38px; }
.bg-recent .bg-b:first-child { --s: 46px; }
.bg-ways { display: grid; grid-template-columns: repeat(auto-fill, minmax(54px, 1fr)); gap: 6px; margin: 6px 0; }
.bg-ways .bg-pat { width: 100%; height: auto; padding: 4px; border-radius: 8px; background: #fffdf5; border: 1px solid #cfc3a4; }
.bg-hall small { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bg-menu::before, .bg-menu::after { content: ""; flex: 1 1 0; min-height: 0; }
.bg-menu::after { flex-grow: 1.6; }
.bg-main.bg-l-stack.bg-wide .bg-act { justify-content: center; }
.bg-main.bg-l-stack.bg-wide .bg-bingorow { max-width: 560px; }
.bg-mcount { display: none; position: absolute; left: 5px; top: 4px; z-index: 1; padding: 1px 6px; border-radius: 9px; font-size: 10.5px; font-weight: 800; line-height: 15px; color: #fff; background: rgba(8, 12, 30, 0.78); border: 1px solid rgba(255, 255, 255, 0.16); }
@media (max-width: 600px) { .bg-top .bg-calls { display: none; } .bg-mcount { display: block; } .bg-tiles > .bg-tile:last-child:nth-child(odd) { grid-column: 1 / -1; } }
@media (max-width: 600px) {
  .bg-hall small { white-space: normal; line-height: 1.08; min-height: 2.16em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; text-align: center; }
  .bg-hall { min-height: 68px; }
  .bg-venue-h { flex-wrap: wrap; row-gap: 0; }
  .bg-venue-h em { order: 2; margin-left: auto; }
  .bg-venue-h span { order: 3; flex: 1 1 100%; white-space: normal; }
}

/* a phone on its side (a low, wide stage): the caller closes up beside the cards and the page tabs stand down the edge */
.bg-main.bg-short .bg-caller { display: grid; grid-template-columns: auto auto; grid-template-areas: "mach now" "callt callt" "last last"; justify-content: center; align-content: center; align-items: center; gap: 2px 8px; padding: 4px 6px; }
.bg-main.bg-short .bg-mach { grid-area: mach; width: 78px; height: var(--bg-machh, 64px); }
.bg-main.bg-short .bg-now { grid-area: now; margin-top: 0; }
.bg-main.bg-short .bg-callt { grid-area: callt; min-height: 30px; }
.bg-main.bg-short .bg-last, .bg-main.bg-short .bg-peek { grid-area: last; justify-self: center; }
.bg-main.bg-short .bg-caller:has(.bg-peek:not([hidden])) .bg-last, .bg-main.bg-short.bg-tiny .bg-last { display: none; }
.bg-main.bg-short .bg-bingo { min-height: 54px; }
.bg-main.bg-short .bg-cardsw { flex-direction: row; }
.bg-main.bg-short .bg-tabs { flex-direction: column; width: 52px; }
.bg-main.bg-short .bg-tab { flex: 0 1 64px; max-width: none; padding: 4px 2px; font-size: 12px; line-height: 1.15; }
.bg-main.bg-short .bg-letters i { height: 14px; font-size: 11.5px; }
.bg-cards.bg-scroll .bg-page { align-content: start; }
/* a small upright phone: the menu closes up so every tile shows without scrolling */
@media (max-width: 600px) and (max-height: 720px) {
  .bg-menu { padding: 18px 12px 8px; gap: 6px; } .bg-logo span { width: 42px; height: 42px; font-size: 21px; }
  .bg-play { min-height: 74px; } .bg-tile { min-height: 52px; padding: 6px 10px; }
}
@media (max-height: 480px) and (min-width: 560px) {
  .bg-game { padding: 11px 8px 4px; gap: 4px; }
  .bg-menu { padding: 18px 12px 8px; gap: 6px; } .bg-menu .bg-sub { display: none; } .bg-logo span { width: 40px; height: 40px; font-size: 20px; }
  .bg-play { min-height: 68px; } .bg-tile { min-height: 52px; padding: 5px 10px; }
}
