/* MAFIA KING: page, loading screen, and the DOM controls and panels over the canvas.
   THE LOOK IS THE OWNER'S PICTURE (ref/owner/full-view.png): near-black leather plates with worn bronze edges,
   pale-gold serif capitals, blood red for the deed, deep purple behind. Control boxes come from core/layout.js
   (set in design units by ui/hud.js). Every amount is type: tabular lining figures.
   The bar's painted pieces (the plates seat's, client/assets/ui/) take over from the drawn ones when ui/app.js
   finds them in that folder's manifest (html.ui-art and one class and one --art-* address per piece). */

/* THE PALETTE AND THE FACES ARE THE PACK'S (the lift, 18 Nov 2026): the three faces and the :root variables that stood
   here are /pack/screen/palette.css (packs/<pack>/screen/palette.css), which every page links BEFORE this sheet. */

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--ink);
  color: var(--white);
  font-family: var(--font);
  font-weight: 700;
  font-variant-numeric: lining-nums tabular-nums;
  overscroll-behavior: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* a game, not a page: a second tap or a pinch never zooms it, a long press brings no menu; panels still scroll */
  touch-action: pan-x pan-y;
  -webkit-touch-callout: none;
}
img { -webkit-user-drag: none; user-select: none; pointer-events: none; }
/* figures of one width: each stands in its own cell */
.num i { display: inline-block; width: 0.61em; text-align: center; font-style: normal; }
/* running text */
.panel-body p, .rules li, .keys dd, .card .rule, .card .meta, .row small, .small:not(.head), .confirm-box p, .first-cards span, .fatal p, #rotate p, .model, .hist, .kv dt, .pay.special p, .bonus-item p { font-family: var(--font-text); }
/* what a player may want to copy (the seeds under HISTORY AND FAIRNESS) can be selected */
.selectable { -webkit-user-select: text; user-select: text; }

/* clip, not hidden: nothing here is ever scrolled, not even by a script (scrollIntoView moves a hidden box) */
#app { position: fixed; inset: 0; overflow: hidden; overflow: clip; }
#game { position: absolute; inset: 0; }
#game canvas { display: block; width: 100%; height: 100%; touch-action: none; }

[hidden] { display: none !important; }

button {
  font: inherit;
  color: inherit;
  border: 0;
  padding: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
button:disabled { cursor: default; }
/* the keyboard's ring: on every control, never for a finger or a mouse */
button:focus-visible, input:focus-visible, [tabindex]:focus-visible { outline: 2.5px solid var(--bronze-hi); outline-offset: 2px; }
.panel:focus, .panel:focus-visible { outline: none; }

/* ---------------------------------------------------------------- the design stage (controls) */
#ui {
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  transform-origin: 0 0;
  pointer-events: none;
}
/* --k is the hud's scale (CSS px per unit of #ui): --px9 is 9 px on the glass, the floor for any lettering here.
   --shake turns a shake given in the stage's units into this scale. */
#ui { --px9: calc(9px / var(--k, 1)); --px10: calc(10px / var(--k, 1)); --px11: calc(11px / var(--k, 1)); --px12: calc(12px / var(--k, 1)); }
#ui > * { position: absolute; pointer-events: auto; translate: calc(var(--sx, 0px) * var(--shake, 1)) calc(var(--sy, 0px) * var(--shake, 1)); }
/* a shake (game.shake) moves the controls by --sx / --sy; this still copy of each control's box keeps taking
   the taps where the control really is */
#ui > button::after { content: ''; position: absolute; inset: 0; translate: calc(-1 * var(--sx, 0px) * var(--shake, 1)) calc(-1 * var(--sy, 0px) * var(--shake, 1)); }
/* a full-screen card is on the canvas: the bar and the badges step out of its way (game.cover) */
#ui, #badges { transition: opacity 0.2s ease; }
html[data-cover='1'] #ui, html[data-cover='1'] #badges { opacity: 0; }
html[data-cover='1'] #ui > * { pointer-events: none; }
/* under the loading screen and the TAP TO PLAY screen the bar waits out of sight: it fades in as the game opens */
/* (J08, the WebKit seat's W1, 18 Nov: this hung on `#app:has(#splash)`; Safari's next engine does not look at that
   rule again when the first screen leaves by a change of its id, so the bar stayed unseen for up to 14 s after
   TAP TO PLAY. It now hangs on an attribute ui/app.js sets in finish(), the one place every way in passes.) */
html:not([data-entered='1']) #ui { opacity: 0; }

/* the bar's backing. On a phone: dark leather rising out of the scene, the readouts on solid dark. On a desktop
   the bar is a PLATE (his picture), not a band across the window: the scene shows round it */
#ui .strip { pointer-events: none; background: linear-gradient(180deg, rgba(14, 10, 11, 0) 0px, rgba(14, 10, 11, 0.66) 30px, rgba(14, 10, 11, 0.95) 54px, var(--ink) 68px); }
html[data-layout='desktop'] #ui .strip { background: linear-gradient(180deg, rgba(8, 5, 6, 0) 0%, rgba(8, 5, 6, 0.34) 60%, rgba(8, 5, 6, 0.5) 100%); }
/* the plate: dark leather, a worn copper rim with cut corners, a thin line inside it (his picture) */
#ui .plate {
  pointer-events: none;
  --cut: 11px;
  --shape: polygon(var(--cut) 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, var(--cut) 100%, 0 calc(100% - var(--cut)), 0 var(--cut));
  background: linear-gradient(180deg, #ffb45a 0%, #e07a26 9%, #8f3d10 30%, #6a2a0a 62%, #c5641c 90%, #ffab4e 100%);
  clip-path: var(--shape);
}
#ui .plate::before { content: ''; position: absolute; inset: 3.5px; --cut: 9px; clip-path: var(--shape);
  background:
    radial-gradient(120% 90% at 30% 0%, rgba(120, 60, 110, 0.16) 0%, rgba(120, 60, 110, 0) 60%),
    linear-gradient(180deg, #1c1315 0%, #130d0f 50%, #0b0708 100%); }
#ui .plate::after { content: ''; position: absolute; inset: 7.5px; --cut: 7px; clip-path: var(--shape);
  background: linear-gradient(180deg, rgba(233, 134, 44, 0.75), rgba(143, 61, 16, 0.6));
  -webkit-mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); padding: 1.2px; }
html.art-plate #ui .plate::before, html.art-plate #ui .plate::after { content: none; }
html.art-plate #ui .plate { background: var(--art-plate) center / 100% 100% no-repeat; clip-path: none; }
/* (his plate has its thin rule after the menu and its bet box painted in: the drawn ones step aside) */
html.art-plate #ui .betframe { display: none; }
html.art-plate[data-layout='desktop'] #ui .ic.menu::before { content: none; }

/* icon buttons: no plate of their own */
#ui .ic { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; color: var(--pale); transition: transform 0.06s ease, opacity 0.15s ease; }
#ui .ic svg { width: 24px; height: 24px; fill: currentColor; display: block; }
#ui .ic:active { transform: scale(0.9); }
#ui .ic.off { opacity: 0.35; }
#ui .ic .sub, #ui .boxed .sub { font-size: max(9px, var(--px9)); font-weight: 700; letter-spacing: 0.1em; color: var(--dim); line-height: 1; }
#ui .ic.on { color: var(--bronze-hi); }
#ui .ic.on .sub { color: var(--bronze-hi); }
#ui .ic.turbo svg { width: 26px; height: 20px; }
#ui .ic.step svg { width: 22px; height: 22px; }
/* the menu mark: three pale-gold bars, and on the plate a thin rule after it */
#ui .ic.menu svg { width: 38px; height: 38px; }
html[data-layout='desktop'] #ui .ic.menu::before { content: ''; position: absolute; right: -18px; top: -6%; bottom: -6%; width: 1.5px; background: linear-gradient(180deg, rgba(243, 223, 174, 0.2), rgba(243, 223, 174, 0.75) 25%, rgba(243, 223, 174, 0.75) 75%, rgba(243, 223, 174, 0.2)); }
html.art-menu #ui .ic.menu { background: var(--art-menu) center / 80% auto no-repeat; }
html.art-menu #ui .ic.menu svg { display: none; }

/* dark boxes round BET and AUTO */
#ui .boxed { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; border-radius: 7px; background: linear-gradient(180deg, #0b0808 0%, #161012 100%); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.5), inset 0 2px 5px rgba(0, 0, 0, 0.7); color: var(--pale); transition: transform 0.06s ease, opacity 0.15s ease; }
#ui .boxed svg { width: 22px; height: 22px; fill: currentColor; display: block; }
#ui .boxed:active { transform: scale(0.94); }
#ui .boxed.off { opacity: 0.35; }
#ui .boxed.on { box-shadow: inset 0 0 0 1.5px var(--bronze-hi), 0 0 10px rgba(240, 207, 143, 0.5); color: var(--bronze-hi); }
/* autoplay: on the plate it is the mark alone (his picture); where it floats over the art it has a disc */
#ui .boxed.auto { border-radius: 50%; background: none; box-shadow: none; }
#ui .boxed.auto .sub { display: none; }
#ui .boxed.auto svg { width: 96%; height: 96%; }
#ui .boxed.auto.on { color: var(--bronze-hi); filter: drop-shadow(0 0 6px rgba(255, 196, 110, 0.8)); box-shadow: none; }
html.art-auto #ui .boxed.auto { background: var(--art-auto) center / 100% auto no-repeat; }
html.art-auto #ui .boxed.auto svg { display: none; }

/* SPIN: the large round bronze button. The ring is drawn here until the painted one lands */
#ui .btn-spin {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  --disc: #17110f;
  background:
    linear-gradient(155deg, rgba(255, 240, 205, 0.22) 0%, rgba(255, 240, 205, 0) 38%, rgba(0, 0, 0, 0.3) 100%),
    radial-gradient(circle closest-side, var(--disc) 0 66%, #0a0605 67% 69%, #5a2208 70%, #e9862c 73%, #ffcf82 77%, #f08a2a 82%, #b24f14 87%, #5a2208 90%, #d9772a 93%, #8a3a10 97%, #2e1206 100%);
  box-shadow: 0 5px 14px rgba(0, 0, 0, 0.7), 0 0 0 var(--ringw, 0px) var(--ring, transparent), 0 0 var(--glow, 0px) var(--ring, transparent);
  color: var(--pale);
  transition: transform 0.06s ease, filter 0.12s ease, opacity 0.15s ease;
}
#ui .btn-spin svg { width: 72%; height: 72%; fill: currentColor; }
#ui .btn-spin .face { display: none; }
#ui .btn-spin:active:not(:disabled) { transform: scale(0.95); filter: brightness(1.18); }
/* SPIN's lettering is sized by the button itself (cqw: hundredths of its width), whatever size the bar gives it,
   and it keeps inside the dark disc of the button: a circle about 56 cqw across. */
#ui .btn-spin { container-type: size; }
#ui .btn-spin .count { position: relative; font-size: 26px; font-size: 32cqw; font-weight: 700; line-height: 0.8; font-variant-numeric: lining-nums tabular-nums; }
#ui .btn-spin .count[data-n='3'] { font-size: 19px; font-size: 24cqw; }
#ui .btn-spin .count[data-n='4'] { font-size: 16px; font-size: 19cqw; }
/* which mode SPIN is in, in words: AUTO or FREE under the count (the button's own text stays the count). The count
   and the word are one stack, centred in the disc; three figures are set smaller so they stay inside it too */
#ui .btn-spin[data-cap='AUTO'], #ui .btn-spin[data-cap='FREE'], #ui .btn-spin[data-cap='WINS'], #ui .btn-spin[data-cap^='NUDGE'] { flex-direction: column; }
#ui .btn-spin[data-cap='AUTO']::before, #ui .btn-spin[data-cap='FREE']::before, #ui .btn-spin[data-cap='WINS']::before, #ui .btn-spin[data-cap^='NUDGE']::before { content: attr(data-cap); order: 1; position: relative; font-size: max(9px, var(--px9)); font-size: max(9.5cqw, var(--px9)); font-weight: 700; letter-spacing: 0.08em; margin-right: -0.08em; margin-top: 3cqw; line-height: 0.8; pointer-events: none; color: var(--dim); }
#ui .btn-spin[data-cap='AUTO'] .count, #ui .btn-spin[data-cap='FREE'] .count, #ui .btn-spin[data-cap='WINS'] .count, #ui .btn-spin[data-cap^='NUDGE'] .count { font-size: 19px; font-size: 25cqw; }
#ui .btn-spin[data-cap='AUTO'] .count[data-n='3'], #ui .btn-spin[data-cap='FREE'] .count[data-n='3'], #ui .btn-spin[data-cap='WINS'] .count[data-n='3'] { font-size: 16px; font-size: 20cqw; }
#ui .btn-spin[data-cap='AUTO'] .count[data-n='4'], #ui .btn-spin[data-cap='FREE'] .count[data-n='4'], #ui .btn-spin[data-cap='WINS'] .count[data-n='4'] { font-size: 13px; font-size: 16cqw; }
/* a SPIN under 60 px on the glass (ui/hud.js marks it) has no room for both: the count alone, as large as fits */
#ui .btn-spin.tight::before { content: none; }
#ui .btn-spin.tight .count { font-size: 29cqw; }
#ui .btn-spin.tight .count[data-n='3'] { font-size: 22cqw; }
#ui .btn-spin.tight .count[data-n='4'] { font-size: 17cqw; }
/* turbo and super turbo leave a mark on SPIN's rim */
#ui .btn-spin .spd { display: none; position: absolute; right: -4%; top: -2%; height: 30%; min-width: 30%; padding: 0 6%; align-items: center; justify-content: center; border-radius: 999px; background: var(--ink); box-shadow: inset 0 0 0 1.5px var(--bronze-hi), 0 0 8px rgba(240, 207, 143, 0.5); color: var(--bronze-hi); font-family: Arial, Helvetica, sans-serif; font-style: normal; font-size: 15px; font-size: 20cqw; font-weight: 700; line-height: 1; letter-spacing: -0.08em; pointer-events: none; }
#ui .btn-spin .spd::before { content: '\203A\203A'; position: relative; top: -0.07em; }
#ui .btn-spin[data-speed='super'] .spd::before { content: '\203A\203A\203A'; }
#ui .btn-spin[data-speed='turbo'] .spd, #ui .btn-spin[data-speed='super'] .spd { display: flex; }
/* STOP while the reels can be hurried, SKIP while a win shows: the disc turns blood red */
#ui .btn-spin[data-mode='stop'], #ui .btn-spin[data-mode='skip'] { --disc: #6a0d13; color: var(--white); }
#ui .btn-spin[data-mode='stop'] svg { width: 38%; height: 38%; }
#ui .btn-spin[data-mode='skip'] svg { width: 42%; height: 42%; }
#ui .btn-spin[data-mode='auto'] { --disc: #2c1640; color: var(--pale); }
/* a SHOWDOWN plays and cannot be hurried: SPIN offers nothing (no sign, a dark disc; with the painted set, its
   dulled empty face). It still takes the press, so the refusal can be felt (QA phone q5, fault 11) */
#ui .btn-spin[data-mode='hold'] { --disc: #1c1416; color: var(--dim); cursor: default; }
#ui .btn-spin[data-mode='free'] { --disc: #2c1640; color: var(--bronze-hi); }
/* a feature spin is on: a ring round SPIN in its colour (the reference's orange ring) */
#ui .btn-spin[data-feature='heat'], #ui .btn-spin[data-feature='badblood'] { --ringw: 2.5px; --glow: 14px; }
#ui .btn-spin[data-feature='heat'] { --ring: #e9a13c; }
#ui .btn-spin[data-feature='badblood'] { --ring: var(--red-hi); }
#ui .btn-spin:disabled { opacity: 0.55; filter: saturate(0.5); }
/* the painted SPIN: at rest (his ring arrow), pressed, STOP, and an empty disc for the counts and SKIP */
html.art-spin #ui .btn-spin { background: var(--art-spin) center / 100% 100% no-repeat; box-shadow: 0 0 0 var(--ringw, 0px) var(--ring, transparent), 0 0 var(--glow, 0px) var(--ring, transparent); }
html.art-spin #ui .btn-spin[data-mode='spin'] svg { display: none; }
html.art-spin.art-spin-down #ui .btn-spin[data-mode='spin']:active:not(:disabled) { background-image: var(--art-spin-down); filter: none; transform: none; }
html.art-spin.art-spin-stop #ui .btn-spin[data-mode='stop'] { background-image: var(--art-spin-stop); }
html.art-spin.art-spin-stop #ui .btn-spin[data-mode='stop'] svg { display: none; }
html.art-spin.art-spin-blank #ui .btn-spin[data-mode='skip'], html.art-spin.art-spin-blank #ui .btn-spin[data-mode='auto'], html.art-spin.art-spin-blank #ui .btn-spin[data-mode='free'] { background-image: var(--art-spin-blank); }
html.art-spin.art-spin-disabled #ui .btn-spin[data-mode='spin']:disabled { background-image: var(--art-spin-disabled); opacity: 1; filter: none; }
html.art-spin.art-spin-disabled #ui .btn-spin[data-mode='hold'] { background-image: var(--art-spin-disabled); }
html.art-spin.art-spin-blank:not(.art-spin-disabled) #ui .btn-spin[data-mode='hold'] { background-image: var(--art-spin-blank); filter: saturate(0.45) brightness(0.85); }

/* BUY BONUS: the round bronze medallion (his picture). Its words are sized by the medallion itself */
#ui .btn-buy {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 50%;
  container-type: size;
  --disc: #151012;
  background:
    linear-gradient(155deg, rgba(255, 240, 205, 0.2) 0%, rgba(255, 240, 205, 0) 38%, rgba(0, 0, 0, 0.28) 100%),
    radial-gradient(circle closest-side, var(--disc) 0 72%, #0a0605 73% 74%, #5a2208 75%, #e9862c 78%, #ffcf82 81%, #f08a2a 85%, #b24f14 89%, #5a2208 91%, #d9772a 94%, #8a3a10 97%, #2e1206 100%);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.7);
  color: var(--pale);
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1;
  transition: transform 0.06s ease, opacity 0.15s ease, filter 0.12s ease;
}
#ui .btn-buy { flex-direction: column; }
#ui .btn-buy span { font-size: 13px; font-size: max(19.5cqw, var(--px9)); line-height: 1; }
#ui .btn-buy .wings { display: block; width: 38cqw; height: 11.5cqw; margin-top: 3cqw; color: #f08a2a; }
#ui .btn-buy .wings svg { width: 100%; height: 100%; display: block; fill: currentColor; }
#ui .btn-buy.disable .wings { display: none; }
html.art-buy-words #ui .btn-buy:not(.disable) .wings { visibility: hidden; }
#ui .btn-buy:active { transform: scale(0.94); filter: brightness(1.15); }
#ui .btn-buy.off { opacity: 0.5; filter: saturate(0.5); }
/* a feature spin is on: BUY BONUS is DISABLE, its disc blood red */
#ui .btn-buy.disable { --disc: #7a0f16; color: var(--white); }
#ui .btn-buy.disable span { font-size: 11px; font-size: max(13.5cqw, var(--px9)); letter-spacing: 0.02em; }
/* the painted medallion: his own words at rest; an empty one for DISABLE, its disc washed blood red */
html.art-buy #ui .btn-buy { background: var(--art-buy) center / 100% 100% no-repeat; box-shadow: none; }
html.art-buy #ui .btn-buy.disable { box-shadow: inset 0 0 0 100px rgba(170, 18, 26, 0.34); }
html.art-buy-words #ui .btn-buy:not(.disable) { background-image: var(--art-buy-words); }
html.art-buy-words #ui .btn-buy:not(.disable) span, html.art-buy-words #ui .btn-buy:not(.disable) .wings { visibility: hidden; }
html.art-buy-words.art-buy-down #ui .btn-buy:not(.disable):not(.off):active { background-image: var(--art-buy-down); transform: none; filter: none; }
html.art-buy-words.art-buy-disabled #ui .btn-buy.off:not(.disable) { background-image: var(--art-buy-disabled); opacity: 1; filter: none; }

/* readouts: a small label over its amount, in pale gold, no plate of their own */
#ui .readout { display: flex; flex-direction: column; justify-content: center; white-space: nowrap; overflow: hidden; pointer-events: none; }
#ui .readout .label { font-size: max(9px, var(--px9)); font-weight: 700; letter-spacing: 0.08em; color: var(--dim); line-height: 1.15; }
#ui .readout .value { font-size: 17px; font-weight: 700; line-height: 1.08; font-variant-numeric: lining-nums tabular-nums; color: var(--pale); }
html[data-layout='desktop'] #ui .readout .label { font-size: max(16px, var(--px9)); font-weight: 600; color: var(--pale); letter-spacing: 0.02em; line-height: 1.1; }
html[data-layout='desktop'] #ui .readout .value { font-size: 30px; line-height: 1.02; }
#ui .readout.win .value { color: var(--bronze-hi); text-shadow: 0 0 10px rgba(240, 207, 143, 0.35); }
#ui .readout .value { transform-origin: 0 50%; }
#ui .readout.boxed .value, #ui .readout.boxed .label { transform-origin: 50% 50%; }
#ui .readout.duo { flex-direction: row; align-items: center; justify-content: flex-start; gap: 6px; }
#ui .readout.duo > div { display: flex; flex-direction: column; min-width: 0; }
#ui .readout.duo .value { font-size: 15px; }
html[data-layout='desktop'] #ui .readout.duo .value { font-size: 24px; }
html[data-layout='desktop'] #ui .readout.duo .label { font-size: max(13px, var(--px9)); }
#ui .readout.boxed { pointer-events: auto; align-items: center; text-align: center; padding: 0 4px; }
#ui .readout.boxed .label { font-size: max(9px, var(--px9)); }
html[data-layout='desktop'] #ui .readout.boxed .label { font-size: max(16px, var(--px9)); }
html[data-layout='desktop'] #ui .readout.boxed .value { font-size: 28px; }
#ui .bet-value.still { pointer-events: none; }
#ui .bet-value[data-feature='heat'] { box-shadow: inset 0 0 0 1.5px #e9a13c; }
#ui .bet-value[data-feature='heat'] .value { color: #f3b65a; }
#ui .bet-value[data-feature='badblood'] { box-shadow: inset 0 0 0 1.5px var(--red-hi); }
#ui .bet-value[data-feature='badblood'] .value { color: #ff8d8d; }
/* the bet box with its up and down arrows inside it (his picture): the amount at the left, a thin rule, the arrows */
#ui .betframe { pointer-events: none; border-radius: 4px; background: linear-gradient(180deg, #0c0909 0%, #161012 100%); box-shadow: inset 0 0 0 1.2px rgba(214, 120, 46, 0.6), inset 0 2px 6px rgba(0, 0, 0, 0.75); }
#ui .betframe::after { content: ''; position: absolute; top: 12%; bottom: 12%; left: var(--rule, 78%); width: 1px; background: rgba(214, 120, 46, 0.4); }
#ui[data-steps='stacked'] .readout.boxed.bet-value { background: none; box-shadow: none; }
#ui[data-steps='stacked'] .bet-value[data-feature='heat'], #ui[data-steps='stacked'] .bet-value[data-feature='badblood'] { box-shadow: none; }
#ui[data-steps='stacked'] .readout.boxed.bet-value:not(.still) { align-items: flex-start; text-align: left; padding: 0 0 0 12px; }
#ui[data-steps='stacked'] .readout.boxed.bet-value:not(.still) .value, #ui[data-steps='stacked'] .readout.boxed.bet-value:not(.still) .label { transform-origin: 0 50%; }
#ui[data-steps='stacked'] .ic.step svg { width: 40px; height: 40px; }
html.art-bet-up #ui[data-steps='stacked'] .ic.step[aria-label='Bet up'] { background: var(--art-bet-up) center 72% / 64% auto no-repeat; }
html.art-bet-down #ui[data-steps='stacked'] .ic.step[aria-label='Bet down'] { background: var(--art-bet-down) center 28% / 64% auto no-repeat; }
html.art-bet-up #ui[data-steps='stacked'] .ic.step[aria-label='Bet up'] svg, html.art-bet-down #ui[data-steps='stacked'] .ic.step[aria-label='Bet down'] svg { display: none; }
/* RESET: the button is finger-sized, the chip drawn in it is small */
#ui .chip { display: flex; align-items: flex-end; justify-content: flex-end; padding-bottom: 3px; }
#ui .chip span { display: block; padding: 6px 9px; border-radius: 6px; background: linear-gradient(180deg, var(--bronze-hi), var(--bronze)); color: var(--ink); font-size: max(10px, var(--px9)); font-weight: 700; letter-spacing: 0.1em; line-height: 1; box-shadow: 0 2px 0 rgba(0, 0, 0, 0.45); transition: transform 0.06s ease, filter 0.1s ease; }
#ui .chip:active span { transform: translateY(2px); filter: brightness(1.12); }

#ui .readout-line { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 4px; font-size: 14px; font-weight: 700; white-space: nowrap; font-variant-numeric: lining-nums tabular-nums; color: var(--pale); }
#ui .readout-line i { font-style: normal; font-size: 11px; letter-spacing: 0.12em; color: var(--dim); }

/* the message plate (phone): free spins left in a bonus; a feature spin that is on */
#ui .message { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 14px; font-weight: 700; letter-spacing: 0.05em; white-space: nowrap; color: var(--pale); pointer-events: none; }
#ui .message.plate { pointer-events: auto; border-radius: 7px; background: linear-gradient(180deg, #1d1517, #0e0a0b); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.55); padding: 0 8px; transition: transform 0.06s ease, filter 0.1s ease; }
#ui .message.plate:active { transform: scale(0.97); filter: brightness(1.3); }
#ui .message .label { font-size: max(10px, var(--px9)); letter-spacing: 0.1em; color: var(--dim); }
#ui .message b { font-size: 16px; font-variant-numeric: lining-nums tabular-nums; }
#ui .message .fi svg, #ui .banner .fi svg { width: 15px; height: 15px; fill: currentColor; display: block; }
#ui .message.on[data-feature='heat'] { box-shadow: inset 0 0 0 1.5px #e9a13c, 0 0 10px rgba(233, 161, 60, 0.5); color: #f3b65a; }
#ui .message.on[data-feature='badblood'] { box-shadow: inset 0 0 0 1.5px var(--red-hi), 0 0 10px rgba(232, 48, 58, 0.5); color: #ff9c9c; }

/* a feature spin is on: its name over the bar (the reference's strip). A press switches it off */
#ui .banner { display: flex; align-items: center; justify-content: center; gap: 7px; padding: 0 12px; border-radius: 5px 5px 0 0; background: linear-gradient(180deg, #b0161f 0%, #6e0b10 100%); box-shadow: inset 0 0 0 1px rgba(240, 207, 143, 0.6), 0 -2px 10px rgba(0, 0, 0, 0.5); color: var(--white); font-size: max(11px, var(--px10)); letter-spacing: 0.08em; line-height: 1; white-space: nowrap; overflow: hidden; }
#ui .banner[data-feature='heat'] { background: linear-gradient(180deg, #c9781f 0%, #7a3f0a 100%); }
#ui .banner b { font-weight: 700; }
#ui .banner span { color: var(--pale); font-variant-numeric: lining-nums tabular-nums; }
#ui .banner:active { filter: brightness(1.2); }

.switch { width: 34px; height: 20px; border-radius: 10px; background: rgba(255, 246, 226, 0.16); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.4); position: relative; flex: none; transition: background 0.15s; display: inline-block; }
.switch::after { content: ''; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: linear-gradient(180deg, var(--white), var(--tan)); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.5); transition: transform 0.15s; }
.on > .switch, [aria-checked='true'] > .switch, [aria-pressed='true'] > .switch { background: var(--red); box-shadow: inset 0 0 0 1px var(--bronze-hi); }
.on > .switch::after, [aria-checked='true'] > .switch::after, [aria-pressed='true'] > .switch::after { transform: translateX(14px); }
.row .switch { width: 50px; height: 28px; border-radius: 14px; }
.row .switch::after { left: 3px; top: 3px; width: 22px; height: 22px; }
.row[aria-checked='true'] .switch::after, .row .mini[aria-checked='true'] .switch::after { transform: translateX(22px); }

/* ---------------------------------------------------------------- badges and toasts */
/* (QA q1 fault 14) the marks are no longer in the sky: they stand on the bar, at the top right of the BALANCE readout,
   small engraved capitals in the bar's own dim bronze; on a phone (no bar) just over the BALANCE label. The page
   moves #badges into #ui .readout.bal; until it does (and if it cannot) they keep a small top-left corner. */
#badges { position: absolute; left: calc(6px + var(--sal)); top: calc(6px + var(--sat)); display: flex; gap: 6px; pointer-events: none; z-index: 5; }
.badge { font-size: 9px; font-weight: 700; letter-spacing: 0.12em; padding: 1px 4px; border-radius: 3px; background: rgba(14, 10, 11, 0.7); color: var(--dim); box-shadow: inset 0 0 0 1px rgba(160, 120, 70, 0.45); line-height: 1.2; }
#ui .readout.bal { overflow: visible; }
#ui .readout.bal #badges { left: auto; right: 0; top: 2px; gap: 4px; z-index: 1; }
/* on the desktop bar: on the BALANCE label's line, just after the word (a grid: label | marks, then the amount) */
#ui:not([data-floating='1']) .readout.bal { display: grid; grid-template-columns: auto 1fr; align-content: center; justify-items: start; }
#ui:not([data-floating='1']) .readout.bal > .label { grid-row: 1; grid-column: 1; }
#ui:not([data-floating='1']) .readout.bal > .value { grid-row: 2; grid-column: 1 / span 2; }
#ui:not([data-floating='1']) .readout.bal #badges { position: static; grid-row: 1; grid-column: 2; align-self: center; margin-left: 7px; gap: 3px; }
#ui:not([data-floating='1']) .readout.bal .badge { font-size: 8px; letter-spacing: 0.07em; padding: 0 2px; line-height: 1.25; }
#ui .readout.bal .badge { font-family: var(--font-text); font-size: 9px; padding: 0 3px; background: none; box-shadow: inset 0 0 0 1px rgba(160, 120, 70, 0.5); color: var(--dim); opacity: 0.9; }
#ui .readout.bal .badge.test, #ui .readout.bal .badge.dev { color: var(--tan); }
html[data-bar] #ui[data-floating='1'] .readout.bal #badges { right: auto; top: auto; left: 50%; bottom: 100%; transform: translate(-50%, -1px); white-space: nowrap; }
html[data-bar] #ui[data-floating='1'] .readout.bal .badge { font-size: 7.5px; text-shadow: none; background: rgba(14, 10, 11, 0.55); }

#toasts { position: absolute; left: 0; right: 0; top: calc(34px + var(--sat)); display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none; z-index: 30; }
.toast { max-width: 86%; padding: 9px 16px; border-radius: 6px; background: linear-gradient(180deg, #1d1517, #0e0a0b); box-shadow: var(--edge), 0 6px 18px rgba(0, 0, 0, 0.6); color: var(--pale); font-size: 15px; font-weight: 700; letter-spacing: 0.05em; text-align: center; animation: toast-in 0.2s ease-out; }
.toast.out { opacity: 0; transition: opacity 0.3s; }
@keyframes toast-in { from { transform: translateY(-8px); opacity: 0; } }

/* ---------------------------------------------------------------- panels */
#panels { position: absolute; inset: 0; pointer-events: none; z-index: 20; }
.scrim { position: absolute; inset: 0; background: rgba(8, 4, 8, 0.74); pointer-events: auto; animation: fade-in 0.18s ease-out; }
@keyframes fade-in { from { opacity: 0; } }
.panel {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(100%, 560px);
  max-height: calc(100% - 24px - var(--sat));
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  border-radius: 12px 12px 0 0;
  background: linear-gradient(180deg, #24132f 0%, #170d1c 46%, #100a0d 100%);
  box-shadow: var(--edge), 0 -10px 40px rgba(0, 0, 0, 0.65);
  padding-bottom: var(--sab);
  pointer-events: auto;
  animation: sheet-in 0.3s cubic-bezier(0.2, 0.9, 0.3, 1);
}
/* the rules keep one size from page to page, so the tabs and the arrows stay under the finger */
.panel[data-panel='info'] { height: min(calc(100% - 24px - var(--sat)), 640px); }
@keyframes sheet-in { from { transform: translate(-50%, 100%); } }
html[data-layout='desktop'] .panel {
  bottom: auto;
  top: 50%;
  width: min(92%, 760px);
  max-height: 88%;
  transform: translate(-50%, -50%);
  border-radius: 12px;
  animation: pop-in 0.2s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}
@keyframes pop-in { from { transform: translate(-50%, -46%) scale(0.94); opacity: 0; } }
.panel.wide { width: min(100%, 720px); }
html[data-layout='desktop'] .panel.wide { width: min(94%, 1060px); }
html[data-layout='desktop'] .panel[data-panel='info'] { height: min(88%, 640px); width: min(94%, 940px); }
html[data-layout='desktop'] .tabs { gap: 5px; }
html[data-layout='desktop'] .tabs button { padding: 0 10px; font-size: 13px; letter-spacing: 0.05em; }
/* a line of rules is never longer than the eye can follow */
.rules > ol, .rules > p, .rules > .keys, .rules > .specials, .rules > .bonus-list { max-width: 780px; }
html[data-layout='desktop'] .panel.drawer { left: 0; top: 0; bottom: 0; width: calc(380px + var(--sal)); padding-left: var(--sal); max-height: none; height: 100%; transform: none; border-radius: 0 12px 12px 0; animation: drawer-in 0.22s ease-out; }
@keyframes drawer-in { from { transform: translateX(-100%); } }
.panel.box { width: min(92%, 350px); bottom: calc(12px + var(--sab)); border-radius: 12px; }
html[data-layout='desktop'] .panel.box { width: 360px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 12px 6px 20px; flex: none; min-height: 50px; }
.panel-title { font-size: 23px; font-weight: 700; letter-spacing: 0.08em; color: var(--pale); text-shadow: 0 2px 0 rgba(0, 0, 0, 0.6); }
.panel-close { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.5); transition: background 0.1s ease, transform 0.06s ease; }
.panel-close svg { width: 18px; height: 18px; fill: var(--pale); }
.panel-close:active { background: rgba(240, 207, 143, 0.18); transform: scale(0.92); }
.panel-body { flex: 1 1 auto; min-height: 0; padding: 4px 20px 18px; overflow-x: hidden; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(201, 161, 90, 0.5) transparent; }
.panel-body p { margin: 6px 0 10px; font-size: 16px; line-height: 1.34; font-weight: 400; color: var(--text); }
.panel-foot { display: flex; gap: 10px; padding: 10px 20px 16px; flex: none; }
.cta {
  flex: 1;
  min-height: 48px;
  padding: 0 10px;
  border-radius: 7px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.08em;
  background: linear-gradient(180deg, #d4222c 0%, #a3131b 52%, #6e0b10 100%);
  box-shadow: inset 0 0 0 1px rgba(240, 207, 143, 0.55), inset 0 2px 0 rgba(255, 255, 255, 0.18), 0 3px 0 rgba(0, 0, 0, 0.5);
  color: var(--white);
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.5);
}
.cta.ghost { background: rgba(240, 207, 143, 0.06); box-shadow: inset 0 0 0 1.5px rgba(201, 161, 90, 0.7); color: var(--pale); }
.cta.gold { background: linear-gradient(180deg, #f3d69a 0%, #cf9d55 52%, #8a5a2b 100%); box-shadow: inset 0 0 0 1px rgba(44, 27, 14, 0.7), inset 0 2px 0 rgba(255, 255, 255, 0.35), 0 3px 0 rgba(0, 0, 0, 0.5); color: #1a0f08; text-shadow: 0 1px 0 rgba(255, 240, 205, 0.5); }
.cta { transition: transform 0.06s ease, filter 0.1s ease; }
.cta:active:not(:disabled) { transform: translateY(2px); filter: brightness(1.15); }
.cta:disabled { opacity: 0.45; }
.code { font-size: 11px; color: var(--dim); text-align: right; letter-spacing: 0.06em; margin: 0 20px 8px; }

/* menu rows */
.rows { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 50px; padding: 6px 14px; border-radius: 7px; background: rgba(240, 207, 143, 0.06); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.22); font-size: 17px; font-weight: 700; letter-spacing: 0.06em; color: var(--pale); width: 100%; text-align: left; }
.row small { display: block; font-size: 13px; font-weight: 400; color: var(--dim); letter-spacing: 0.02em; }
.row { transition: transform 0.06s ease, filter 0.1s ease, background 0.1s ease; }
button.row:active { transform: scale(0.985); filter: brightness(1.35); }
/* a speed: its name, and one switch for the base game and one for the bonus game */
.row.duo { align-items: center; padding-right: 8px; }
.row .pair { display: flex; gap: 6px; flex: none; }
.row .mini { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-width: 84px; min-height: 48px; padding: 2px 6px; border-radius: 6px; color: var(--pale); transition: background 0.1s ease, transform 0.06s ease; }
.row .mini small { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; color: var(--dim); white-space: nowrap; }
.row .mini .switch { width: 46px; height: 24px; border-radius: 12px; }
.row .mini .switch::after { left: 3px; top: 3px; width: 18px; height: 18px; }
.row .mini:active { transform: scale(0.95); background: rgba(240, 207, 143, 0.1); }
/* a slider: a 44 px strip to the finger, a 6 px track and a 22 px knob to the eye */
.row input[type='range'] { flex: 0 0 48%; height: 44px; margin: -8px 0; background: transparent; cursor: pointer; -webkit-appearance: none; appearance: none; touch-action: pan-y; }
.row input[type='range']::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--red) var(--fill, 50%), rgba(255, 246, 226, 0.2) var(--fill, 50%)); }
.row input[type='range']::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 22px; height: 22px; margin-top: -8px; border-radius: 50%; background: linear-gradient(180deg, var(--bronze-hi), var(--bronze)); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.6), inset 0 0 0 1px rgba(44, 27, 14, 0.6); }
.row input[type='range']::-moz-range-track { height: 6px; border-radius: 3px; background: rgba(255, 246, 226, 0.2); }
.row input[type='range']::-moz-range-progress { height: 6px; border-radius: 3px; background: var(--red); }
.row input[type='range']::-moz-range-thumb { width: 22px; height: 22px; border: 0; border-radius: 50%; background: var(--bronze-hi); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5); }
.model { margin-top: 10px; font-size: 11px; font-weight: 400; color: var(--dim); letter-spacing: 0.06em; }

/* ---- the buy menu: its own bet box on top, then four cards (the reference's layout) ---- */
.betrow { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 64px; padding: 0 20px 6px; flex: none; font-size: 12px; letter-spacing: 0.1em; color: var(--dim); position: relative; }
.betrow .betbox { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 132px; height: 52px; border-radius: 7px; background: linear-gradient(180deg, #0b0808, #161012); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.55), inset 0 2px 5px rgba(0, 0, 0, 0.7); line-height: 1.05; }
.betrow .betbox small { font-size: 11px; letter-spacing: 0.12em; color: var(--tan); }
.betrow .betbox b { color: var(--pale); font-size: 22px; letter-spacing: 0.02em; font-variant-numeric: lining-nums tabular-nums; }
.betrow .step { width: 50px; height: 48px; flex: none; border-radius: 7px; background: linear-gradient(180deg, #2a1c1e, #140e0f); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.6); font-family: Arial, Helvetica, sans-serif; font-size: 26px; font-weight: 700; line-height: 1; color: var(--pale); transition: transform 0.06s ease, filter 0.1s ease; }
.betrow .step:active:not(:disabled) { transform: scale(0.92); filter: brightness(1.5); }
.betrow .step:disabled { opacity: 0.35; }
.betrow .bal { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); text-align: right; line-height: 1.1; font-size: 11px; }
.betrow .bal b { display: block; font-size: 16px; color: var(--pale); letter-spacing: 0.02em; font-variant-numeric: lining-nums tabular-nums; }

.cards { display: flex; flex-direction: column; gap: 8px; }
.card {
  --accent: var(--red);
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  grid-template-rows: auto 1fr auto;
  grid-template-areas: 'pic name price' 'pic rule go' 'pic meta go';
  column-gap: 10px;
  row-gap: 2px;
  align-items: start;
  text-align: left;
  min-height: 108px;
  border-radius: 9px;
  padding: 8px;
  background: linear-gradient(180deg, #211518 0%, #130d0f 100%);
  box-shadow: inset 0 0 0 1.5px var(--bronze), inset 0 1px 0 1.5px rgba(240, 207, 143, 0.5), inset 0 0 0 3px #0c0809, inset 0 0 0 4px rgba(201, 161, 90, 0.3);
  position: relative;
  width: 100%;
  color: var(--white);
}
.card[data-kind='feature'] { --accent: var(--bronze-hi); }
.card .thumb { grid-area: pic; align-self: center; }
.card .name { grid-area: name; font-size: 18px; font-weight: 700; letter-spacing: 0.05em; color: var(--pale); line-height: 1.02; padding-top: 3px; }
.card .rule { grid-area: rule; font-size: 13.5px; line-height: 1.2; font-weight: 400; color: var(--text); }
.card .meta { grid-area: meta; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; font-size: 11px; font-weight: 400; font-style: italic; letter-spacing: 0.06em; color: var(--dim); align-self: end; }
.card .price { grid-area: price; font-size: 20px; font-weight: 700; color: var(--pale); line-height: 1; font-variant-numeric: lining-nums tabular-nums; text-align: right; padding-top: 3px; white-space: nowrap; }
.card .price small { display: block; font-size: 11px; color: var(--dim); font-weight: 700; letter-spacing: 0.08em; margin-top: 3px; }
.card .go { grid-area: go; align-self: end; justify-self: end; width: 104px; height: 44px; border-radius: 6px; display: grid; place-items: center; font-size: 15px; font-weight: 700; letter-spacing: 0.1em; background: linear-gradient(180deg, #d4222c 0%, #a3131b 52%, #6e0b10 100%); box-shadow: inset 0 0 0 1px rgba(240, 207, 143, 0.55), inset 0 2px 0 rgba(255, 255, 255, 0.18); color: var(--white); text-shadow: 0 1px 0 rgba(0, 0, 0, 0.5); }
.card[data-kind='feature'] .go { background: linear-gradient(180deg, #f3d69a 0%, #cf9d55 52%, #8a5a2b 100%); box-shadow: inset 0 0 0 1px rgba(44, 27, 14, 0.7), inset 0 2px 0 rgba(255, 255, 255, 0.35); color: #1a0f08; text-shadow: 0 1px 0 rgba(255, 240, 205, 0.5); }
.card.on { box-shadow: inset 0 0 0 2px var(--bronze-hi), inset 0 0 0 4px #0c0809, 0 0 16px rgba(240, 207, 143, 0.45); }
.card.on .go { background: linear-gradient(180deg, #a3141c 0%, #5e0a0f 100%); box-shadow: inset 0 0 0 1px rgba(240, 207, 143, 0.55); color: var(--white); text-shadow: none; }
.card.poor .price { color: #ff8d8d; }
.card.poor .go { background: rgba(255, 246, 226, 0.1); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.3); color: var(--dim); font-size: 11px; text-shadow: none; }
.card .go.offer { background: linear-gradient(180deg, #f3d69a 0%, #cf9d55 52%, #8a5a2b 100%); color: #1a0f08; font-size: 13px; }
.card { transition: transform 0.06s ease, filter 0.1s ease; }
.card:active:not(.poor) { transform: scale(0.985); filter: brightness(1.15); }
.cards.dim { opacity: 0.4; }
/* a card's picture. A STAND-IN (until the painted ones land) is the symbols' own stills on a dark plank */
.thumb { position: relative; display: block; width: 92px; height: 92px; border-radius: 6px; background: #120c0d center / cover no-repeat; box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.4); overflow: hidden; }
.thumb.standin { background: repeating-linear-gradient(90deg, #1c1311 0 22px, #17100e 22px 23px, #201613 23px 46px, #130c0b 46px 47px); }
.thumb .fan { position: absolute; inset: 6px 4px 12px; display: flex; align-items: center; justify-content: center; }
.thumb .fan img, .thumb .fan .tile { width: 62%; height: auto; aspect-ratio: 1; object-fit: contain; flex: none; margin: 0 -17%; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.7)); }
.thumb[data-n='1'] .fan img, .thumb[data-n='1'] .fan .tile { width: 78%; margin: 0; }
.thumb[data-n='3'] .fan > :nth-child(1) { transform: rotate(-12deg) translateY(4%); }
.thumb[data-n='3'] .fan > :nth-child(2) { transform: translateY(-6%); z-index: 1; }
.thumb[data-n='3'] .fan > :nth-child(3) { transform: rotate(12deg) translateY(4%); }
.thumb[data-n='4'] .fan img, .thumb[data-n='4'] .fan .tile { width: 54%; margin: 0 -18%; }
.thumb[data-n='4'] .fan > :nth-child(1) { transform: rotate(-16deg) translateY(6%); }
.thumb[data-n='4'] .fan > :nth-child(2) { transform: rotate(-5deg) translateY(-5%); z-index: 1; }
.thumb[data-n='4'] .fan > :nth-child(3) { transform: rotate(5deg) translateY(-5%); z-index: 1; }
.thumb[data-n='4'] .fan > :nth-child(4) { transform: rotate(16deg) translateY(6%); }
.thumb .fan .tile { display: grid; place-items: center; border-radius: 6px; background: #2a1c1e; box-shadow: inset 0 0 0 1px var(--bronze); font-style: normal; font-size: 13px; color: var(--pale); }
.thumb .tag { position: absolute; left: 4px; top: 2px; z-index: 2; font-size: 22px; line-height: 1; color: var(--bronze-hi); text-shadow: 0 2px 0 #1a0f08, 0 0 6px rgba(0, 0, 0, 0.9); }
.thumb small { position: absolute; right: 3px; bottom: 2px; z-index: 2; font-size: 7.5px; font-weight: 700; font-style: normal; letter-spacing: 0.1em; color: rgba(236, 220, 176, 0.6); }
/* a desktop: four cards in a row, each a column (title, one line, picture, volatility, price, a full-width button) */
html[data-layout='desktop'] .cards { flex-direction: row; gap: 12px; }
html[data-layout='desktop'] .card { flex: 1 1 0; min-width: 0; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto auto auto auto auto; grid-template-areas: 'name' 'rule' 'pic' 'meta' 'price' 'go'; justify-items: center; text-align: center; row-gap: 7px; min-height: 0; padding: 14px 12px 12px; }
html[data-layout='desktop'] .card .name { font-size: 19px; min-height: 2.05em; display: flex; align-items: center; padding: 0; }
html[data-layout='desktop'] .card .rule { font-size: 14.5px; min-height: 3.6em; }
html[data-layout='desktop'] .card .thumb { width: 124px; height: 124px; }
html[data-layout='desktop'] .card .meta { justify-content: center; font-size: 11.5px; align-self: center; min-height: 1.2em; }
html[data-layout='desktop'] .card .price { text-align: center; font-size: 25px; padding: 0; }
html[data-layout='desktop'] .card .go { width: 100%; height: 48px; font-size: 18px; justify-self: stretch; }
@media (max-height: 560px) and (max-aspect-ratio: 23/20) { .card { min-height: 92px; grid-template-columns: 76px minmax(0, 1fr) auto; } .card .thumb { width: 76px; height: 76px; } }

.panel.box .panel-body { padding: 16px 20px 4px; }
.confirm-box { text-align: center; padding: 2px 0 0; }
.confirm-box .ico { display: grid; place-items: center; margin-bottom: 6px; color: var(--bronze-hi); }
.confirm-box .ico svg { width: 40px; height: 40px; fill: currentColor; }
.confirm-box .pic { display: grid; place-items: center; margin: 10px 0 4px; }
.confirm-box .pic .thumb { width: 112px; height: 112px; }
.confirm-box p { margin: 8px 0 0; font-size: 14.5px; font-weight: 400; line-height: 1.3; letter-spacing: 0.02em; color: var(--text); }
.pager { align-items: center; padding-top: 6px; }
.pager .cta { flex: 0 0 64px; min-height: 44px; font-family: Arial, Helvetica, sans-serif; font-size: 26px; line-height: 1; }
.pager .page-count { flex: 1; text-align: center; font-size: 14px; letter-spacing: 0.1em; color: var(--dim); font-variant-numeric: lining-nums tabular-nums; }
.confirm-box .name { font-size: 25px; font-weight: 700; color: var(--pale); letter-spacing: 0.06em; line-height: 1.05; }
.confirm-box .head { font-size: 14px; letter-spacing: 0.12em; color: var(--bronze-hi); margin-top: 4px; }
.confirm-box .kv2 { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; margin: 12px 4px 0; text-align: left; font-size: 12px; letter-spacing: 0.1em; color: var(--dim); align-items: baseline; }
.confirm-box .kv2 b { font-size: 22px; color: var(--pale); letter-spacing: 0.02em; text-align: right; font-variant-numeric: lining-nums tabular-nums; }
.confirm-box .why { min-height: 1.2em; margin-top: 6px; font-size: 13px; color: #ff8d8d; }

/* info pages */
.tabs { display: flex; gap: 6px; padding: 0 20px 8px; overflow-x: auto; flex: none; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; min-height: 44px; min-width: 56px; padding: 0 13px; border-radius: 6px; background: rgba(240, 207, 143, 0.07); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.3); color: var(--tan); font-size: 13.5px; font-weight: 700; letter-spacing: 0.07em; white-space: nowrap; transition: transform 0.06s ease, filter 0.1s ease; }
.tabs button:active { transform: scale(0.95); filter: brightness(1.4); }
.tabs button[aria-selected='true'] { background: linear-gradient(180deg, #c81e28, #7a0d13); box-shadow: inset 0 0 0 1px rgba(240, 207, 143, 0.6); color: var(--white); }
.rules ol { margin: 4px 0 10px; padding-left: 24px; }
.rules li { font-size: 17px; line-height: 1.34; margin-bottom: 8px; font-weight: 400; color: var(--text); }
.rules li::marker { color: var(--gold); font-weight: 700; }
.rules h3 { margin: 16px 0 6px; font-size: 18px; letter-spacing: 0.08em; color: var(--pale); }
.rules h3:first-child { margin-top: 4px; }
/* small pictures at the head of a block: a symbol 52 px square */
.rule-pics { display: flex; gap: 8px; margin: 2px 0 8px; }
.rule-pics img { width: 52px; height: 52px; object-fit: contain; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.6)); }
.small { font-size: 14px; font-weight: 400; color: var(--tan); line-height: 1.3; }
.small.head { margin: 12px 0 6px; font-weight: 700; letter-spacing: 0.1em; font-size: 13px; color: var(--gold); }
.pays { display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 8px; }
.pay { display: flex; align-items: center; gap: 10px; padding: 7px 9px; border-radius: 7px; background: rgba(240, 207, 143, 0.06); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.22); }
.pay .sym { width: 60px; height: 60px; flex: none; border-radius: 6px; background: #17100e center / 96% no-repeat; box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.25); display: grid; place-items: center; text-align: center; font-size: 11px; font-weight: 700; color: var(--tan); }
.pay table { border-collapse: collapse; font-size: 15px; font-variant-numeric: lining-nums tabular-nums; color: var(--white); }
.pay td { padding: 0 4px; line-height: 1.25; }
.pay td:first-child { color: var(--gold); }
.pay .nm { font-size: 11.5px; letter-spacing: 0.08em; color: var(--pale); }
.pay.special { align-items: center; }
.pay.special p { margin: 2px 0 0; font-size: 14px; line-height: 1.28; }
.specials { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.keys { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; margin: 4px 0 10px; font-size: 15px; line-height: 1.32; }
.keys dt { color: var(--pale); font-weight: 700; letter-spacing: 0.06em; white-space: nowrap; }
.keys dd { margin: 0; font-weight: 400; color: var(--text); }
.lines { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 9px; margin: 4px 0 10px; }
.line { text-align: center; font-size: 12px; color: var(--tan); }
.line svg { width: 100%; height: auto; display: block; border-radius: 5px; background: #17100e; box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.3); margin-bottom: 2px; }
.line .cell { fill: rgba(255, 246, 226, 0.09); }
.line .hit { fill: var(--gold); }
.line .run { fill: none; stroke: var(--red-hi); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; font-size: 15px; }
.kv dt { color: var(--tan); font-weight: 400; }
.kv dd { margin: 0; word-break: break-all; font-variant-numeric: lining-nums tabular-nums; }
.bonus-list { display: flex; flex-direction: column; gap: 8px; }
.bonus-item { padding: 10px 14px; border-radius: 7px; background: rgba(240, 207, 143, 0.06); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.22); }
.bonus-item b { font-size: 17px; letter-spacing: 0.06em; color: var(--pale); }
.bonus-item p { margin: 4px 0 0; font-size: 15px; font-variant-numeric: lining-nums tabular-nums; }
.hist { width: 100%; border-collapse: collapse; font-size: 13px; font-weight: 400; font-variant-numeric: lining-nums tabular-nums; color: var(--text); }
.hist th { text-align: left; font-size: 11px; letter-spacing: 0.1em; color: var(--dim); font-weight: 700; padding: 2px 4px; }
.hist td { padding: 5px 4px; border-top: 1px solid rgba(201, 161, 90, 0.16); }
.hist button { min-height: 44px; min-width: 62px; padding: 0 8px; border-radius: 6px; background: rgba(240, 207, 143, 0.1); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.4); color: var(--pale); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; transition: transform 0.06s ease, filter 0.1s ease; }
.hist button:active:not(:disabled) { transform: scale(0.95); filter: brightness(1.5); }
.hist td:last-child { text-align: right; white-space: nowrap; }
.hist-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; margin: 0 -4px; }
.hist .ok { color: var(--ok); }
.hist .bad { color: #ff8d8d; }

/* autoplay, bet sheet */
.grid-choices { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; margin-bottom: 10px; }
.grid-choices button { min-height: 46px; border-radius: 999px; background: rgba(240, 207, 143, 0.08); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.35); color: var(--pale); font-size: 15.5px; font-weight: 700; font-variant-numeric: lining-nums tabular-nums; transition: transform 0.06s ease, filter 0.1s ease; }
.grid-choices button:active { transform: scale(0.95); filter: brightness(1.4); }
.grid-choices button[aria-pressed='true'] { background: linear-gradient(180deg, #f3d69a 0%, #cf9d55 52%, #8a5a2b 100%); box-shadow: inset 0 0 0 1px rgba(44, 27, 14, 0.7); color: #1a0f08; }
.grid-choices.four { grid-template-columns: repeat(4, 1fr); }
.grid-choices small { display: inline; font-size: 11px; letter-spacing: 0.1em; opacity: 0.8; margin-left: 3px; }
.panel[data-panel='bet'] .grid-choices button { border-radius: 7px; }
.panel[data-panel='auto'] .row { font-size: 15px; }
.panel[data-panel='auto'] .grid-choices button { font-size: 14.5px; white-space: nowrap; }
.panel[data-panel='bet'] .grid-choices small { display: block; margin: 0; }

/* ---------------------------------------------------------------- loader, splash, fatal, rotate */
#loader {
  position: absolute;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 20px;
  /* his dusk: warm light low down, purple above, night at the top */
  background: radial-gradient(130% 85% at 50% 108%, #e48a34 0%, #a8394a 26%, #4a2a73 56%, #1c0f26 82%, #0e0a0b 100%);
  background-size: cover;
  background-position: center bottom;
  transition: opacity 0.35s ease;
}
#loader.done { opacity: 0; pointer-events: none; }
.loader-title { font-size: clamp(44px, 12vw, 96px); font-weight: 700; letter-spacing: 0.04em; line-height: 0.92; text-align: center; color: var(--red-hi); text-shadow: 0 0 2px #1a0f08, 0 3px 0 #2c1b0e, 0 0 22px rgba(232, 48, 58, 0.55); }
.loader-title span { color: var(--red-hi); display: block; }
.loader-title img { display: block; width: min(78vw, 520px); height: auto; margin: 0 auto; }
.loader-track { width: min(70%, 320px); height: 12px; border-radius: 6px; background: rgba(14, 10, 11, 0.8); box-shadow: inset 0 0 0 1.5px var(--bronze); overflow: hidden; }
.loader-fill { width: 0%; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--red), var(--bronze-hi)); transition: width 0.15s linear; }
.loader-text { font-size: 15px; font-weight: 700; letter-spacing: 0.24em; color: var(--pale); min-height: 1.2em; }

/* the one bright button of the first screen: blood red, a bronze edge */
.play-go { flex: none; min-width: min(74vw, 300px); min-height: 60px; padding: 0 34px; border-radius: 9px; background: linear-gradient(180deg, #e02630 0%, #a3131b 52%, #6e0b10 100%); color: var(--white); font-size: 25px; font-weight: 700; letter-spacing: 0.14em; line-height: 1; white-space: nowrap; text-shadow: 0 2px 0 rgba(60, 4, 8, 0.8); box-shadow: inset 0 0 0 2px var(--bronze-hi), inset 0 0 0 4px #5e0a0f, 0 0 26px rgba(232, 48, 58, 0.6), 0 5px 0 #2c0508; animation: go-pulse 1.5s ease-in-out infinite; }
.play-go:active { transform: scale(0.97); animation: none; filter: brightness(1.15); }
@keyframes go-pulse { 50% { transform: scale(1.05); filter: brightness(1.12); } }
/* its three cards: a picture, a name, a few words */
.first-cards { list-style: none; margin: 0; padding: 0; width: min(100%, 400px); display: flex; flex-direction: column; gap: 8px; }
.first-cards li { display: grid; grid-template-columns: 56px 1fr; grid-template-rows: 1fr 1fr; column-gap: 12px; min-height: 68px; padding: 6px 14px 6px 8px; border-radius: 9px; background: linear-gradient(180deg, rgba(29, 21, 23, 0.92), rgba(14, 10, 11, 0.92)); box-shadow: var(--edge), 0 6px 16px rgba(8, 3, 6, 0.5); }
.first-cards img, .first-cards li > i { grid-row: 1 / 3; align-self: center; width: 56px; height: 56px; object-fit: contain; }
.first-cards li > i { display: grid; place-items: center; border-radius: 6px; background: #2a1c1e; box-shadow: inset 0 0 0 1px var(--bronze); font-style: normal; font-size: 13px; color: var(--pale); }
.first-cards b { align-self: end; padding-bottom: 2px; font-size: 20px; font-weight: 700; letter-spacing: 0.08em; line-height: 1; color: var(--pale); }
.first-cards span { align-self: start; padding-top: 2px; font-size: 13.5px; font-weight: 400; letter-spacing: 0.03em; line-height: 1.12; color: var(--text); }
@media (min-aspect-ratio: 23/20) {
  .first-cards { flex-direction: row; width: min(100%, 980px); gap: 14px; }
  .first-cards li { flex: 1 1 0; grid-template-columns: 1fr; grid-template-rows: auto auto auto; justify-items: center; align-content: center; text-align: center; row-gap: 5px; min-height: 0; padding: 14px 12px; }
  .first-cards img, .first-cards li > i { grid-row: auto; width: 96px; height: 96px; }
  .first-cards b { align-self: center; padding: 0; font-size: 23px; }
  .first-cards span { align-self: center; padding: 0; font-size: 15.5px; }
  #splash .play-go { min-width: 320px; min-height: 64px; font-size: 27px; }
}

/* the first screen: the loading screen's own picture and title stay where they were, the bar gives way to three
   cards and one bright button. Nothing of the game shows through. */
#splash, #splash-out {
  position: absolute;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 20px 22px calc(20px + var(--sab));
  background: radial-gradient(130% 85% at 50% 108%, #e48a34 0%, #a8394a 26%, #4a2a73 56%, #1c0f26 82%, #0e0a0b 100%);
  background-size: cover;
  background-position: center bottom;
  cursor: pointer;
  transition: opacity 0.28s ease;
}
#splash-out { opacity: 0; pointer-events: none; }
/* his landscape behind the first screen, under a dusk veil so the cards and the button read */
@media (max-aspect-ratio: 23/20) {
  #splash, #splash-out { background-image: linear-gradient(180deg, rgba(14, 8, 16, 0.5) 0%, rgba(14, 8, 16, 0.34) 30%, rgba(14, 8, 16, 0.72) 100%), url('/assets/scene/half/bg_base_portrait.webp'), radial-gradient(130% 85% at 50% 108%, #e48a34 0%, #a8394a 26%, #4a2a73 56%, #1c0f26 82%, #0e0a0b 100%); background-position: center; }
}
@media (min-aspect-ratio: 23/20) {
  #splash, #splash-out { background-image: linear-gradient(180deg, rgba(14, 8, 16, 0.5) 0%, rgba(14, 8, 16, 0.3) 30%, rgba(14, 8, 16, 0.7) 100%), url('/assets/scene/half/bg_base_landscape.webp'), radial-gradient(130% 85% at 50% 108%, #e48a34 0%, #a8394a 26%, #4a2a73 56%, #1c0f26 82%, #0e0a0b 100%); background-position: center; }
}
/* the title on the first screen: the loading screen's own (client/index.html: his lettering as a picture, the word
   in type only until the picture is in). Its rules there are tied to #loader, so they are said again for #splash */
#splash .loader-title, #splash-out .loader-title { position: relative; flex: none; width: min(80vw, 600px); aspect-ratio: 4.6 / 1; display: flex; align-items: center; justify-content: center; }
#splash .loader-title img, #splash-out .loader-title img { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; object-fit: contain; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.6)); }
#splash .loader-title img.in + .loader-word, #splash-out .loader-title img.in + .loader-word { display: none; }
#splash .loader-word, #splash-out .loader-word { font: 900 clamp(44px, 13vw, 104px) / 1 Impact, 'MK Heavy', Haettenschweiler, 'Arial Narrow Bold', 'Arial Black', sans-serif; letter-spacing: 0.03em; color: #d81e1a; white-space: nowrap; text-shadow: 0 0 2px #1a0f08, 0 3px 0 #2c1b0e; }
/* a low frame (the 393 x 531 game frame, 375 x 420): the title and the cards give up height, the button none */
@media (max-height: 580px) and (max-aspect-ratio: 23/20) {
  #splash, #splash-out { gap: 10px; padding-top: 12px; padding-bottom: calc(12px + var(--sab)); }
  #splash .loader-title { width: min(64vw, 120vh); }
  .first-cards { gap: 6px; }
  .first-cards li { min-height: 58px; grid-template-columns: 46px 1fr; }
  .first-cards img, .first-cards li > i { width: 46px; height: 46px; }
  .first-cards b { font-size: 18px; }
  .first-cards span { font-size: 13px; }
  #splash .play-go { min-height: 54px; font-size: 22px; }
}
@media (max-height: 460px) and (max-aspect-ratio: 23/20) {
  #splash .loader-title { width: min(54vw, 100vh); }
  .first-cards li { min-height: 48px; grid-template-columns: 38px 1fr; padding-top: 3px; padding-bottom: 3px; }
  .first-cards img, .first-cards li > i { width: 38px; height: 38px; }
  .first-cards b { font-size: 16px; }
  .first-cards span { font-size: 12px; }
  #splash .play-go { min-height: 48px; font-size: 20px; }
}

/* SPIN breathes when nobody has played for a while */
#ui[data-idle='1'] .btn-spin[data-mode='spin']:not(:disabled) { animation: spin-breathe 2.4s ease-in-out infinite; }
@keyframes spin-breathe { 50% { transform: scale(1.06); filter: brightness(1.2); } }

.fatal, #rotate {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  background: var(--ink);
}
.fatal b, #rotate b { font-size: 30px; letter-spacing: 0.06em; color: var(--red-hi); }
#rotate b { color: var(--pale); }
.fatal p, #rotate p { margin: 0; max-width: 420px; font-size: 18px; font-weight: 400; line-height: 1.3; color: var(--text); }
.fatal button { margin-top: 10px; padding: 0 22px; flex: none; }
#rotate svg { width: 72px; height: 72px; fill: var(--bronze-hi); animation: tilt 1.6s ease-in-out infinite; }
@keyframes tilt { 50% { transform: rotate(-90deg); } }

@media (prefers-reduced-motion: reduce) {
  .panel, .scrim, .toast, .play-go { animation: none; }
}

/* ---------------------------------------------------------------- every size a player can hold */

/* a mouse over a control: it answers before the press */
@media (hover: hover) and (pointer: fine) {
  #ui .ic:hover:not(.off), #ui .boxed:hover:not(.off) { filter: brightness(1.3); }
  #ui .btn-buy:hover:not(.off), #ui .btn-spin:hover:not(:disabled) { filter: brightness(1.12); }
  #ui .message.plate:hover, #ui .banner:hover { filter: brightness(1.2); }
  button.row:hover, .row .mini:hover, .tabs button:not([aria-selected='true']):hover, .grid-choices button:not([aria-pressed='true']):hover,
  .hist button:hover:not(:disabled) { background-color: rgba(240, 207, 143, 0.16); }
  .betrow .step:hover:not(:disabled) { filter: brightness(1.3); }
  .panel-close:hover { background: rgba(240, 207, 143, 0.12); }
  .card:hover:not(.poor), .cta:hover:not(:disabled) { filter: brightness(1.1); }
}

/* ---- a phone (the hud's 'float' form, and 'side' for a phone on its side): NO BAR. Round bronze controls float over
   the art TO THE OWNER'S OWN PROPORTIONS (his iPhone screenshot of the reference, 440 x 765: ui/hud.js TABLE; one
   unit of #ui is the screen's width / 440, so every size below is a share of the width). The money is label over
   value on the bottom edge. */
/* a soft foot of dusk under the money row, so pale figures read on a bright land; the land shows through it */
html #ui[data-floating='1'] .strip { background: linear-gradient(180deg, rgba(8, 5, 6, 0) 0%, rgba(8, 5, 6, 0.38) 50%, rgba(8, 5, 6, 0.7) 100%); }
/* THE FINGER: a control may measure less than 44 CSS px to the eye (the menu is a tenth of the width); the area
   that answers a touch never does */
html #ui[data-floating='1'] { --finger: calc(44.5px / var(--k, 1)); }
html #ui[data-floating='1'] > button::after { inset: min(0px, calc((100% - var(--finger)) / 2)); border-radius: inherit; }
/* every small control is a dark disc with a bronze rim (his own painted disc where the page has it), round whatever
   its touch box; its mark is sized by the disc */
html #ui[data-floating='1'] .ic, html #ui[data-floating='1'] .boxed.auto { border-radius: 50%; background: radial-gradient(circle closest-side, rgba(20, 15, 16, 0.94) 0 80%, #5a2208 82%, #e08430 88%, #8a3a10 95%, #2e1206 98%, rgba(46, 18, 6, 0) 100%) center / contain no-repeat; box-shadow: none; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.6)); }
html.art-spin-blank #ui[data-floating='1'] .ic, html.art-spin-blank #ui[data-floating='1'] .boxed.auto { background: var(--art-spin-blank) center / contain no-repeat; }
html.art-spin-blank.art-menu #ui[data-floating='1'] .ic.menu { background: var(--art-menu) center / 46% auto no-repeat, var(--art-spin-blank) center / contain no-repeat; }
html.art-spin-blank.art-auto #ui[data-floating='1'] .boxed.auto { background: var(--art-auto) center / 58% auto no-repeat, var(--art-spin-blank) center / contain no-repeat; }
html #ui[data-floating='1'] .ic svg, html #ui[data-floating='1'] .boxed.auto svg { width: 50%; height: 50%; }
html #ui[data-floating='1'] .ic.menu::before { content: none; }
html #ui[data-floating='1'] .ic.step svg { width: 50%; height: auto; aspect-ratio: 1; }
html #ui[data-floating='1'] .ic.step.off { opacity: 0.5; }
/* the speed: small, the chevrons alone (one, two, three); lit while turbo or super turbo is on. Its name is said by
   the notice that follows a press */
html #ui[data-floating='1'] .ic.turbo { gap: 0; color: var(--tan); }
html #ui[data-floating='1'] .ic.turbo svg { width: 56%; height: 42%; }
html #ui[data-floating='1'] .ic.turbo .sub { display: none; }
html #ui[data-floating='1'] .ic.turbo.on { color: var(--bronze-hi); filter: drop-shadow(0 0 5px rgba(255, 196, 110, 0.9)); }
html #ui[data-floating='1'] .boxed.auto.on { filter: drop-shadow(0 0 6px rgba(255, 196, 110, 0.9)); }
/* SPIN: his bronze rim stays solid, its dark disc lets a little of the land through (the reference's is see-through).
   The picture is drawn on the button's face (ui/hud.js), which takes whatever picture the button's state names */
html #ui[data-floating='1'] .btn-spin { isolation: isolate; background-size: 0 0 !important; filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.5)); box-shadow: 0 0 0 var(--ringw, 0px) var(--ring, transparent), 0 0 var(--glow, 0px) var(--ring, transparent); }
html #ui[data-floating='1'] .btn-spin .face { display: block; position: absolute; inset: 0; z-index: -1; border-radius: 50%; pointer-events: none; background-image: inherit; background-position: center; background-size: 100% 100%; background-repeat: no-repeat; -webkit-mask-image: radial-gradient(circle closest-side, rgba(0, 0, 0, 0.72) 0 78%, #000 85%); mask-image: radial-gradient(circle closest-side, rgba(0, 0, 0, 0.72) 0 78%, #000 85%); }
/* (the speed has its own button beside SPIN here, lit while it is on: SPIN's rim carries no second mark) */
html #ui[data-floating='1'] .btn-spin .spd { display: none !important; }
html #ui[data-floating='1'] .btn-spin:active:not(:disabled) { filter: brightness(1.15) drop-shadow(0 3px 5px rgba(0, 0, 0, 0.5)); }
html #ui[data-floating='1'] .btn-buy { filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.6)); }
/* the money row: label over value, small, centred on its place, with a dark edge so it reads over the land.
   (html[data-bar]: these outrank the desktop bar's sizes, which a phone on its side would otherwise take) */
html[data-bar] #ui[data-floating='1'] .readout { text-shadow: 0 1px 2px #000, 0 0 5px rgba(0, 0, 0, 0.95), 0 0 11px rgba(0, 0, 0, 0.7); justify-content: center; align-items: center; text-align: center; padding-bottom: 2.5px; overflow: visible; }
html[data-bar] #ui[data-floating='1'] .readout .label, html[data-bar] #ui[data-floating='1'] .readout.boxed .label, html[data-bar] #ui[data-floating='1'] .readout.duo .label { font-size: max(9px, var(--px9)); font-weight: 700; color: var(--tan); line-height: 1.12; letter-spacing: 0.07em; }
html[data-bar] #ui[data-floating='1'] .readout .value, html[data-bar] #ui[data-floating='1'] .readout.boxed .value { font-size: max(12.5px, var(--px12)); line-height: 1.04; transform-origin: 50% 50%; }
html[data-bar] #ui[data-floating='1'] .readout.boxed { background: none; box-shadow: none; border-radius: 0; padding: 0 0 2.5px; overflow: visible; align-items: center; text-align: center; }
html[data-bar] #ui[data-floating='1'] .readout.duo { flex-direction: row; align-items: center; justify-content: center; gap: 8px; }
html[data-bar] #ui[data-floating='1'] .readout.duo > div { align-items: center; flex: 0 1 auto !important; }
html[data-bar] #ui[data-floating='1'] .readout.duo .value { font-size: max(12px, var(--px11)); }
html[data-bar] #ui[data-floating='1'] .bet-value[data-feature='heat'], html[data-bar] #ui[data-floating='1'] .bet-value[data-feature='badblood'] { box-shadow: none; }
/* a phone on its side: the dusk under the money stands at the two sides only, never on the machine's foot */
html #ui[data-form='side'] .strip { -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(var(--ml, 0px) - 30px), transparent var(--ml, 0px), transparent var(--mr, 0px), #000 calc(var(--mr, 0px) + 30px)); mask-image: linear-gradient(90deg, #000 0, #000 calc(var(--ml, 0px) - 30px), transparent var(--ml, 0px), transparent var(--mr, 0px), #000 calc(var(--mr, 0px) + 30px)); }
html #ui[data-floating='1'] .banner { border-radius: 5px; font-size: max(10px, var(--px10)); letter-spacing: 0.05em; padding: 0 7px; gap: 5px; }
html #ui[data-floating='1'] .banner span { display: none; }
/* (a phone on its side: the title sign is in the top middle, on the machine; the DEMO badge keeps the top-left corner) */

/* ---- narrow phones (under 370 px): tighter gutters; chips three to a row ---- */
@media (max-width: 369px) {
  .panel-head { padding-left: 14px; }
  .panel-body { padding-left: 14px; padding-right: 14px; }
  .panel-foot { padding-left: 14px; padding-right: 14px; }
  .tabs { padding-left: 14px; padding-right: 14px; }
  .betrow { padding: 0 14px 6px; gap: 6px; justify-content: flex-start; }
  .betrow .betbox { min-width: 104px; }
  .betrow .bal { right: 14px; }
  .card { grid-template-columns: 70px minmax(0, 1fr) auto; column-gap: 8px; }
  .card .thumb { width: 70px; height: 70px; }
  .card .go { width: 92px; }
  .card .name { font-size: 16px; }
  .grid-choices:not(.four) { grid-template-columns: repeat(3, 1fr); }
  .pays { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); }
  .pay .sym { width: 48px; height: 48px; }
  .rules li { font-size: 16px; }
  .row .mini { min-width: 72px; }
}
/* the buy menu's own bet box on a phone: at the left, the balance at the right */
@media (max-aspect-ratio: 23/20) and (max-width: 599px) {
  .betrow { justify-content: flex-start; }
}

/* ---- a tablet held upright: panels are dialogs in the middle, not sheets across the bottom ---- */
@media (min-width: 600px) and (max-aspect-ratio: 23/20) {
  .panel { bottom: auto; top: 50%; width: min(88%, 620px); max-height: 82%; transform: translate(-50%, -50%); border-radius: 12px; padding-bottom: 0; animation: pop-in 0.2s cubic-bezier(0.2, 0.9, 0.3, 1.2); }
  .panel.wide { width: min(92%, 720px); }
  .panel[data-panel='info'] { height: min(82%, 760px); }
  .panel.box { width: 380px; top: 50%; bottom: auto; }
  .panel-title { font-size: 26px; }
  .panel-body p, .rules li { font-size: 18px; }
  .row { min-height: 56px; font-size: 19px; }
  .card { min-height: 128px; }
  .card .rule { font-size: 15px; }
  .first-cards { width: min(100%, 520px); }
  .first-cards b { font-size: 23px; }
  .first-cards span { font-size: 17px; }
  .toast { font-size: 18px; }
}

/* ---- a low, wide window (a phone on its side): panels use the height there is ---- */
@media (max-height: 480px) and (min-aspect-ratio: 23/20) {
  html[data-layout='desktop'] .panel { width: min(calc(100% - 16px - var(--sal) - var(--sar)), 700px); max-height: calc(100% - 10px); }
  html[data-layout='desktop'] .panel.wide { width: min(calc(100% - 16px - var(--sal) - var(--sar)), 860px); }
  html[data-layout='desktop'] .panel[data-panel='info'] { height: calc(100% - 10px); }
  html[data-layout='desktop'] .panel.drawer { width: calc(350px + var(--sal)); max-height: none; }
  html[data-layout='desktop'] .panel.box { width: min(calc(100% - 16px), 380px); }
  /* the bet sheet leaves the game in sight beside it, so a press outside can close it */
  html[data-layout='desktop'] .panel[data-panel='bet'] { width: min(calc(100% - 16px - var(--sal) - var(--sar)), 460px); }
  .panel-head { min-height: 44px; padding-top: 2px; padding-bottom: 0; }
  .panel-title { font-size: 19px; }
  .panel-body { padding-bottom: 10px; }
  .panel-foot { padding-top: 6px; padding-bottom: 8px; }
  .betrow { min-height: 50px; }
  .betrow .betbox { height: 44px; }
  .tabs { padding-bottom: 6px; }
  .rows { gap: 6px; }
  .rules li { font-size: 15px; margin-bottom: 6px; }
  .rules h3 { margin-top: 10px; }
  .panel.box .panel-body { padding-top: 10px; }
  .confirm-box .ico svg { width: 30px; height: 30px; }
  .confirm-box .name { font-size: 21px; }
  .confirm-box .pic .thumb { width: 64px; height: 64px; }
  .confirm-box .kv2 { margin-top: 8px; }
  html[data-layout='desktop'] .card { row-gap: 3px; padding: 7px; }
  html[data-layout='desktop'] .card .thumb { width: 60px; height: 60px; }
  html[data-layout='desktop'] .card .name { font-size: 15px; min-height: 0; }
  html[data-layout='desktop'] .card .rule { font-size: 12.5px; min-height: 0; }
  html[data-layout='desktop'] .card .price { font-size: 19px; }
  html[data-layout='desktop'] .card .go { height: 44px; }
  #splash, #splash-out { gap: 8px; padding-top: 8px; padding-bottom: calc(8px + var(--sab)); }
  #splash .loader-title { width: min(44vw, 340px); }
  .first-cards { gap: 8px; width: min(100%, 680px); }
  .first-cards li { grid-template-columns: 44px 1fr; grid-template-rows: 1fr 1fr; justify-items: start; text-align: left; row-gap: 0; column-gap: 8px; padding: 5px 10px 5px 6px; }
  .first-cards img, .first-cards li > i { grid-row: 1 / 3; width: 44px; height: 44px; }
  .first-cards b { align-self: end; font-size: 16px; }
  .first-cards span { align-self: start; font-size: 12px; }
  #splash .play-go { min-height: 46px; font-size: 20px; }
  #toasts { top: calc(8px + var(--sat)); }
  .toast { font-size: 13px; padding: 6px 12px; }
}

/* the notch and the home bar at the sides of the loading screen and the splash */
#loader, #splash, #splash-out { padding-left: calc(22px + var(--sal)); padding-right: calc(22px + var(--sar)); }
#toasts { padding: 0 calc(8px + var(--sar)) 0 calc(8px + var(--sal)); }
#ui .value small.of { font-size: 0.62em; opacity: 0.8; margin-left: 0.15em; }

/* ---- fix round 1b (17 Nov, QA q1 gate faults 7 and 10, q2 phone F3, F10, F14) ---- */
/* THE FINGER IS THE BOX: where the controls float, ui/hud.js grows a control drawn under 44 CSS px to a 44 px box
   round the same centre and gives the drawing's own size as --fw / --fh: the disc and its mark keep that size */
html #ui[data-floating='1'] .ic, html #ui[data-floating='1'] .boxed.auto { background-size: var(--fw, 100%) var(--fh, 100%); }
html.art-spin-blank #ui[data-floating='1'] .ic, html.art-spin-blank #ui[data-floating='1'] .boxed.auto { background-size: var(--fw, 100%) var(--fh, 100%); }
html.art-spin-blank.art-menu #ui[data-floating='1'] .ic.menu { background-size: calc(var(--fw, 100%) * 0.46) auto, var(--fw, 100%) var(--fh, 100%); }
html.art-spin-blank.art-auto #ui[data-floating='1'] .boxed.auto { background-size: calc(var(--fw, 100%) * 0.58) auto, var(--fw, 100%) var(--fh, 100%); }
html #ui[data-floating='1'] .ic svg, html #ui[data-floating='1'] .boxed.auto svg { width: calc(var(--fw, 100%) * 0.5); height: calc(var(--fh, 100%) * 0.5); }
html #ui[data-floating='1'] .ic.step svg { width: calc(var(--fw, 100%) * 0.5); height: auto; }
html #ui[data-floating='1'] .ic.turbo svg { width: calc(var(--fw, 100%) * 0.56); height: calc(var(--fh, 100%) * 0.42); }
html #ui[data-floating='1'] .btn-buy, html.art-buy #ui[data-floating='1'] .btn-buy { background-size: var(--fw, 100%) var(--fh, 100%); }
/* nothing a player reads on a phone is under 11 px (q2 F14): the money row's labels, the caption under SPIN's count */
html[data-bar] #ui[data-floating='1'] .readout .label, html[data-bar] #ui[data-floating='1'] .readout.boxed .label, html[data-bar] #ui[data-floating='1'] .readout.duo .label { font-size: max(11.2px, calc(11.2px / var(--k, 1))); letter-spacing: 0.05em; }
#ui .btn-spin[data-cap]::before { font-size: max(9.5cqw, var(--px11)) !important; }
#ui .btn-spin[data-cap^='NUDGE']::before { letter-spacing: 0.02em; margin-right: 0; }
/* a phone in a bonus: WIN over TOTAL WIN at the right of the money row, each with the whole width for its figure */
html[data-bar] #ui[data-floating='1'][data-duo='1'] .readout.duo { flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
html[data-bar] #ui[data-floating='1'][data-duo='1'] .readout.duo > div { width: 100%; }
html[data-bar] #ui[data-floating='1'][data-duo='1'] .readout.duo .value, html[data-bar] #ui[data-floating='1'][data-duo='1'] .readout.boxed .value { font-size: max(12.5px, var(--px12)); }
/* the desktop bar in a bonus: WIN, TOTAL WIN and the spins side by side, each wide enough for EUR 30,000,000.00
   (ui/hud.js lays the three fields out; the labels are a size smaller there so FREE SPINS fits its field) */
html[data-layout='desktop'] #ui[data-duo='1']:not([data-floating='1']) .readout.duo .label, html[data-layout='desktop'] #ui[data-duo='1']:not([data-floating='1']) .readout.boxed .label { font-size: max(14px, var(--px9)); }
html[data-layout='desktop'] #ui[data-duo='1']:not([data-floating='1']) .readout.duo .value, html[data-layout='desktop'] #ui[data-duo='1']:not([data-floating='1']) .readout.boxed .value { font-size: 24px; }
html[data-layout='desktop'] #ui[data-duo='1']:not([data-floating='1']) .readout.duo > div { overflow: hidden; }
/* (in a bonus the plate is his plain one: the painted bet box would stand round nothing, across TOTAL WIN) */
html.art-plate.art-plate-plain #ui[data-duo='1']:not([data-floating='1']) .plate { background-image: var(--art-plate-plain); }
/* THE BUY MENU ON A PHONE: all four cards in one thumb's reach without a scroll on a 393 x 659 phone (q2 F22). The
   card's line runs under its price too, the facts sit under the line at the left, the button at the bottom right */
html:not([data-layout='desktop']) .card { grid-template-columns: 80px minmax(0, 1fr) auto; grid-template-rows: auto auto 1fr; grid-template-areas: 'pic name price' 'pic rule rule' 'pic meta go'; min-height: 0; row-gap: 3px; padding: 7px 8px; }
html:not([data-layout='desktop']) .card .thumb { width: 80px; height: 80px; align-self: start; }
html:not([data-layout='desktop']) .card .name { font-size: 16px; padding-top: 2px; }
html:not([data-layout='desktop']) .card .rule { font-size: 13px; line-height: 1.18; }
html:not([data-layout='desktop']) .card .meta { gap: 0 8px; line-height: 1.25; }
html:not([data-layout='desktop']) .card .go { height: 44px; width: 100px; }
html:not([data-layout='desktop']) .cards { gap: 7px; }
html:not([data-layout='desktop']) .panel[data-panel='buy'] .betrow { min-height: 56px; }
html:not([data-layout='desktop']) .panel[data-panel='buy'] .panel-body { padding-bottom: 10px; }
/* THE BET SHEET: every bet without a scroll on a 393 x 659 phone (q2 F22): 44 px rows, 4 px apart */
html:not([data-layout='desktop']) .panel[data-panel='bet'] .grid-choices { gap: 4px; }
html:not([data-layout='desktop']) .panel[data-panel='bet'] .grid-choices button { min-height: 44px; }
html:not([data-layout='desktop']) .panel[data-panel='bet'] .panel-body { padding-bottom: 10px; }
html:not([data-layout='desktop']) .card .name { font-size: 15.5px; letter-spacing: 0.025em; }
@media (max-width: 369px) {
  html:not([data-layout='desktop']) .card { grid-template-columns: 66px minmax(0, 1fr) auto; column-gap: 8px; }
  html:not([data-layout='desktop']) .card .thumb { width: 66px; height: 66px; }
  html:not([data-layout='desktop']) .card .go { width: 92px; }
  html:not([data-layout='desktop']) .card .rule { font-size: 12.5px; }
}
@media (max-width: 369px) {
  html:not([data-layout='desktop']) .cards { gap: 5px; }
  html:not([data-layout='desktop']) .card { padding: 6px 7px; row-gap: 2px; }
  html:not([data-layout='desktop']) .card .rule { font-size: 12px; line-height: 1.15; }
  html:not([data-layout='desktop']) .panel[data-panel='buy'] .betrow { min-height: 50px; padding-bottom: 4px; }
}

/* ---- FIX ROUND 2 (critic q3 fault 12) ---- */
/* THE ONE COUNT OF A BONUS: on SPIN only, "6" over "FREE", in the disc (ui/hud.js setSpin). It is a readout the bar's
   readers know, so the bar's own readout rules are undone here: it sits in the disc like the AUTO count */
#ui .btn-spin[data-disc='1'] { flex-direction: column; }
#ui .btn-spin .readout.disc { position: relative; display: flex; flex-direction: column-reverse; align-items: center; justify-content: center; overflow: visible; pointer-events: none; }
#ui .btn-spin .readout.disc .value.count, html[data-layout='desktop'] #ui .btn-spin .readout.disc .value.count, html[data-bar] #ui[data-floating='1'] .btn-spin .readout.disc .value.count { font-size: 19px; font-size: 25cqw; line-height: 0.8; color: inherit; text-shadow: none; transform: none; }
#ui .btn-spin .readout.disc .value.count[data-n='3'] { font-size: 20cqw !important; }
#ui .btn-spin .readout.disc .value.count[data-n='4'] { font-size: 16cqw !important; }
#ui .btn-spin .readout.disc .label, html[data-layout='desktop'] #ui .btn-spin .readout.disc .label, html[data-bar] #ui[data-floating='1'] .btn-spin .readout.disc .label { font-size: max(9.5cqw, var(--px11)); font-weight: 700; letter-spacing: 0.08em; margin: 3cqw -0.08em 0 0; line-height: 0.8; color: var(--dim); }
#ui .btn-spin.tight .readout.disc .label { display: none; }
#ui .btn-spin.tight .readout.disc .value.count { font-size: 29cqw; }
/* words for screen readers only (drawn nowhere) */
#ui .sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* THE RULES ON A DESKTOP: a panel that uses the screen and type to read at arm's length (critic q3 fault 12: "about
   11 px in a small panel"). Nothing on the rules pages under 15 px; running text 18 px; the panel up to 1240 x 820.
   (A phone on its side keeps its own low-window rules above.) */
@media (min-height: 481px) {
html[data-layout='desktop'] .panel[data-panel='info'] { width: min(94%, 1240px); height: min(92%, 820px); }
html[data-layout='desktop'] .panel[data-panel='info'] .panel-title { font-size: 28px; }
html[data-layout='desktop'] .panel[data-panel='info'] .tabs { gap: 8px; }
html[data-layout='desktop'] .panel[data-panel='info'] .tabs button { padding: 0 14px; font-size: 15px; min-height: 46px; }
html[data-layout='desktop'] .panel[data-panel='info'] .panel-body { padding: 8px 28px 20px; }
html[data-layout='desktop'] .panel[data-panel='info'] .rules > ol, html[data-layout='desktop'] .panel[data-panel='info'] .rules > p, html[data-layout='desktop'] .panel[data-panel='info'] .rules > .keys, html[data-layout='desktop'] .panel[data-panel='info'] .rules > .specials, html[data-layout='desktop'] .panel[data-panel='info'] .rules > .bonus-list { max-width: 1040px; }
html[data-layout='desktop'] .panel[data-panel='info'] .rules li, html[data-layout='desktop'] .panel[data-panel='info'] .panel-body p { font-size: 18px; line-height: 1.4; }
html[data-layout='desktop'] .panel[data-panel='info'] .rules h3 { font-size: 21px; }
html[data-layout='desktop'] .panel[data-panel='info'] .rule-pics img { width: 64px; height: 64px; }
html[data-layout='desktop'] .panel[data-panel='info'] .small { font-size: 16px; }
html[data-layout='desktop'] .panel[data-panel='info'] .small.head { font-size: 15px; }
html[data-layout='desktop'] .panel[data-panel='info'] .keys { font-size: 17px; gap: 8px 16px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pays { grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 10px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pay { gap: 12px; padding: 9px 12px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pay .sym { width: 76px; height: 76px; font-size: 15px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pay table { font-size: 18px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pay .nm { font-size: 15px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pay.special p { font-size: 17px; line-height: 1.32; }
html[data-layout='desktop'] .panel[data-panel='info'] .lines { grid-template-columns: repeat(7, minmax(0, 132px)); gap: 14px 18px; }
html[data-layout='desktop'] .panel[data-panel='info'] .line { font-size: 15px; }
html[data-layout='desktop'] .panel[data-panel='info'] .kv { font-size: 17px; }
html[data-layout='desktop'] .panel[data-panel='info'] .bonus-item b { font-size: 19px; }
html[data-layout='desktop'] .panel[data-panel='info'] .bonus-item p { font-size: 17px; }
html[data-layout='desktop'] .panel[data-panel='info'] .pager .page-count { font-size: 16px; }
/* the history beside them: the same reading size */
html[data-layout='desktop'] .panel[data-panel='history'] .hist { font-size: 15px; }
html[data-layout='desktop'] .panel[data-panel='history'] .hist th { font-size: 13px; }
html[data-layout='desktop'] .panel[data-panel='history'] .kv { font-size: 16px; }
}

/* the rules on a phone: the pay names and the lines' numbers at 13 px (they were 11.5 and 12) */
html:not([data-layout='desktop']) .pay .nm { font-size: 13px; letter-spacing: 0.05em; }
html:not([data-layout='desktop']) .line { font-size: 13px; }
/* a note on a phone held upright ("RESUMING YOUR LAST ROUND") stands over the land under the machine, never over
   THE TAKE or the BIG KING meter in the sky (core 02:44) */
@media (max-aspect-ratio: 23/20) {
  html:not([data-layout='desktop']) #toasts { top: auto; bottom: calc(27% + var(--sab)); }
}

/* ---- FIX ROUND 2b (QA gate q3 fault 4; QA desktop q3 faults 12, 13, 14) ---- */
/* the bet's two steps on a phone: their touch boxes grow AWAY from SPIN (ui/hud.js); --fx / --fy keep the drawing
   on SPIN's rim where the table has it */
html #ui[data-floating='1'] .ic.step, html.art-spin-blank #ui[data-floating='1'] .ic.step { background-position: calc(50% + var(--fx, 0px)) calc(50% + var(--fy, 0px)); }
html #ui[data-floating='1'] .ic.step svg { transform: translate(var(--fx, 0px), var(--fy, 0px)); }

/* HIS BAR, MEASURED AT 1670 x 942 (his picture's own size; outbox/interface/shots/f2b/q3-bar-his-vs-ours.png): the
   labels BALANCE and BET stood 5 px low and a little large, the amounts 2 to 4 px low, both about 7 px left of his;
   his labels are a warmer gold. In stage units (1 du = 1.047 px there) */
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout:not(.duo) > .label { position: relative; top: -4.8px; font-size: max(15.5px, var(--px9)); letter-spacing: 0.1em; color: #f0d98a; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal > .value, html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.win:not(.duo) > .value { position: relative; top: -2px; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bet-value:not(.still) > .value { position: relative; top: -3.6px; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal { padding-left: 8px; }
html[data-layout='desktop'] #ui[data-steps='stacked']:not([data-floating='1']) .readout.boxed.bet-value:not(.still) { padding-left: 18px; }
/* his bet arrows are thinner and smaller than the painted pieces drawn at 64%: 52% (bright area at 1440 x 900: ours
   148 px, his 146; it was 291 against 188 at 1670 x 942: outbox/interface/shots/f2b/) */
html.art-bet-up #ui[data-steps='stacked'] .ic.step[aria-label='Bet up'] { background-size: 52% auto; }
html.art-bet-down #ui[data-steps='stacked'] .ic.step[aria-label='Bet down'] { background-size: 52% auto; }
/* DEMO beside BALANCE at 11 px on the glass (it was 8 px); the tester's marks (TEST ROUNDS, DEV PAGE: test servers
   only) stand under the plate, on the land, at 11 px too, so DEMO never reaches WIN */
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal #badges { position: static; margin-left: 8px; gap: 4px; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge:not(.test):not(.dev) { position: relative; top: -4.8px; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge { font-size: max(11px, var(--px11)); letter-spacing: 0.06em; padding: 0 3px; line-height: 1.25; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.test, html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.dev { position: absolute; left: 8px; top: calc(100% + 18px); white-space: nowrap; background: rgba(14, 10, 11, 0.6); }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.test ~ .badge.dev { left: calc(8px + 9em); }

/* WHY AUTOPLAY STOPPED (desktop q3 fault 12): a plate where the player is looking (ui/hud.js note): the reels' bottom
   edge on a desktop, just over SPIN on a phone. Two lines: what happened, why */
#ui .auto-note { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 6px 14px; border-radius: 10px; background: linear-gradient(180deg, rgba(36, 20, 30, 0.96), rgba(14, 9, 11, 0.96)); box-shadow: inset 0 0 0 1.5px rgba(224, 160, 80, 0.85), 0 6px 22px rgba(0, 0, 0, 0.7); text-align: center; pointer-events: none; z-index: 6; white-space: nowrap; animation: note-in 0.22s cubic-bezier(0.2, 0.9, 0.3, 1.25); transition: opacity 0.25s ease; }
#ui .auto-note.out { opacity: 0; }
#ui .auto-note b { font-size: 26px; font-weight: 700; letter-spacing: 0.08em; color: var(--pale); line-height: 1.05; text-shadow: 0 2px 0 rgba(0, 0, 0, 0.6); }
#ui .auto-note span { font-family: var(--font-text); font-size: 18px; font-weight: 700; letter-spacing: 0.05em; color: var(--bronze-hi); line-height: 1.15; }
html[data-bar] #ui[data-floating='1'] .auto-note { padding: 4px 10px; gap: 2px; }
html[data-bar] #ui[data-floating='1'] .auto-note b { font-size: max(20px, var(--px12)); }
html[data-bar] #ui[data-floating='1'] .auto-note span { font-size: max(14px, var(--px11)); white-space: normal; }
@keyframes note-in { from { opacity: 0; transform: scale(0.9); } }
@media (prefers-reduced-motion: reduce) { #ui .auto-note { animation: none; } }

/* THE BUY CONFIRM BOX (desktop q3 fault 14: 'about 200 px wide on a 1440 px screen, with 11 px labels'): a box a
   player cannot miss or misread. A desktop: 680 px, the card's own painted picture 260 px beside the words, the
   price in 32 px figures, labels 16 px, buttons 60 px. A phone: the picture 150 px over the words, labels 14 px */
@media (min-height: 481px) {
  html[data-layout='desktop'] .panel.box[data-panel='buyConfirm'] { width: min(92%, 680px); border-radius: 14px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .panel-body { padding: 28px 30px 6px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box { display: grid; grid-template-columns: 260px minmax(0, 1fr); grid-template-areas: 'pic name' 'pic head' 'pic text' 'pic kv' 'pic why'; grid-template-rows: auto auto auto 1fr auto; column-gap: 28px; text-align: left; align-items: start; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .name { grid-area: name; font-size: 36px; letter-spacing: 0.05em; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .pic { grid-area: pic; margin: 0; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .pic .thumb { width: 260px; height: 260px; border-radius: 10px; box-shadow: inset 0 0 0 1.5px rgba(224, 160, 80, 0.7), 0 6px 18px rgba(0, 0, 0, 0.55); }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .head { grid-area: head; font-size: 19px; margin-top: 8px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box p { grid-area: text; margin-top: 14px; font-size: 19px; line-height: 1.35; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .kv2 { grid-area: kv; align-self: end; margin: 18px 0 0; gap: 8px 16px; font-size: 16px; letter-spacing: 0.08em; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .kv2 b { font-size: 32px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .confirm-box .why { grid-area: why; font-size: 16px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .panel-foot { gap: 14px; padding: 12px 30px 26px; }
  html[data-layout='desktop'] .panel[data-panel='buyConfirm'] .cta { min-height: 60px; font-size: 22px; }
}
html:not([data-layout='desktop']) .panel.box[data-panel='buyConfirm'] { width: min(calc(100% - 20px), 420px); }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .name { font-size: 26px; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .pic .thumb { width: 150px; height: 150px; border-radius: 9px; box-shadow: inset 0 0 0 1.5px rgba(224, 160, 80, 0.7), 0 4px 14px rgba(0, 0, 0, 0.55); }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .head { font-size: 16px; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box p { font-size: 16px; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .kv2 { font-size: 14px; letter-spacing: 0.07em; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .kv2 b { font-size: 26px; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .cta { min-height: 54px; font-size: 20px; }
/* (a low phone: the picture gives way first) */
@media (max-height: 600px) and (max-aspect-ratio: 23/20) {
  html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .pic .thumb { width: 104px; height: 104px; }
  html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box .pic { margin: 6px 0 2px; }
  html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .confirm-box p { margin-top: 5px; font-size: 15px; }
}

/* ---- FIX ROUND 3 (17 Nov): the critic's q4 fault 8, the phone tester's q3 P3s ---------------------------------- */
/* the "... SPINS ON" tab: a press on the desktop bar switches the feature off; on a phone it is a notice only (the OFF
   disc beside SPIN does that at a finger's size), its words 12 px at least */
#ui .banner[role='button'] { cursor: pointer; }
html #ui[data-floating='1'] .banner { pointer-events: none; font-size: max(12px, var(--px11)); letter-spacing: 0.04em; }
html #ui[data-floating='1'] .banner .fi svg { width: 13px; height: 13px; }
/* the DEMO and TEST ROUNDS marks over BALANCE on a phone: 11 px, readable */
html[data-bar] #ui[data-floating='1'] .readout.bal #badges { gap: 4px; }
html[data-bar] #ui[data-floating='1'] .readout.bal .badge { font-size: 11px; letter-spacing: 0.06em; padding: 0 4px; line-height: 1.25; }
/* RULES AND PAYS on a phone: every tab whole, in two rows of four (no strip running off the edge with a word cut) */
html:not([data-layout='desktop']) .panel[data-panel='info'] .tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; overflow: visible; padding: 0 12px 8px; }
html:not([data-layout='desktop']) .panel[data-panel='info'] .tabs button { min-width: 0; min-height: 44px; padding: 3px 2px; font-size: clamp(11.5px, 2.9vw, 12.5px); letter-spacing: 0.02em; line-height: 1.12; white-space: normal; overflow-wrap: normal; }
/* a phone on its side: the eight tabs in one row */
@media (max-height: 480px) and (min-aspect-ratio: 23/20) {
  html[data-layout] .panel[data-panel='info'] .tabs { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 5px; overflow: visible; }
  html[data-layout] .panel[data-panel='info'] .tabs button { min-width: 0; min-height: 44px; padding: 3px 3px; font-size: 12.5px; letter-spacing: 0.03em; line-height: 1.12; white-space: normal; }
}
/* the bet sheet: amounts of four figures a little smaller, so they keep air inside their chips */
@media (max-width: 419px) { .panel[data-panel='bet'] .grid-choices button.long { font-size: 13.5px; letter-spacing: 0; } }
/* autoplay on its side: the counts in one row, so every limit is in sight above START */
@media (max-height: 480px) and (min-aspect-ratio: 23/20) {
  .panel[data-panel='auto'] .grid-choices.count { grid-template-columns: repeat(7, minmax(0, 1fr)); }
  .panel[data-panel='auto'] .grid-choices { margin-bottom: 4px; gap: 5px; }
  .panel[data-panel='auto'] .grid-choices button { min-height: 44px; }
  .panel[data-panel='auto'] .small.head { margin: 3px 0 3px; }
  .panel[data-panel='auto'] .row { min-height: 44px; margin-bottom: 2px; }
  .panel[data-panel='auto'] .panel-body { padding-top: 0; padding-bottom: 6px; }
}
/* MORE BELOW: a panel cut off at its foot says so until it has been scrolled to its end */
.panel .more-cue { position: absolute; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: rgba(14, 10, 11, 0.92); box-shadow: inset 0 0 0 1px rgba(201, 161, 90, 0.6), 0 3px 10px rgba(0, 0, 0, 0.6); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; color: var(--pale); white-space: nowrap; pointer-events: none; animation: cue-bob 1.6s ease-in-out infinite; }
.panel .more-cue[hidden] { display: none; }
.panel .more-cue i { font-style: normal; color: var(--bronze-hi); }
@keyframes cue-bob { 50% { translate: 0 2px; } }
@media (prefers-reduced-motion: reduce) { .panel .more-cue { animation: none; } }
/* HISTORY AND FAIRNESS: the hashed seed breaks only between its groups of 16; on a phone it has the whole width */
.kv dd.seed { word-break: normal; overflow-wrap: normal; }
.kv dd.seed .grp { white-space: nowrap; }
html:not([data-layout='desktop']) .kv dt.long { grid-column: 1 / -1; }
html:not([data-layout='desktop']) .kv dd.seed { grid-column: 1 / -1; margin-top: -2px; margin-bottom: 4px; }
.panel[data-panel='history'] .model { margin: 2px 0 10px; }
html[data-layout='desktop'] .panel[data-panel='history'] .model { font-size: 13px; }
@media (max-width: 369px) { html:not([data-layout='desktop']) .panel[data-panel='info'] .tabs button { letter-spacing: 0; } }

/* ---- FIX ROUND 4 (17 Nov): build q5's faults (QA phone 7, 8, 9, 11; critic 4, 7, 8) ------------------------------ */
/* AN UPRIGHT PHONE IN A BONUS: WIN over TOTAL WIN on a dark footing of their own, the figures a size up (they stood
   thin on the lit grass and the headlights). ui/hud.js sizes the box to its words (winBox). */
html[data-bar='float'] #ui[data-floating='1'][data-duo='1'] .readout.win.duo { justify-content: center; gap: 4px; padding: 6px 7px; border-radius: 9px; background: linear-gradient(180deg, rgba(30, 17, 14, 0.84), rgba(12, 8, 8, 0.92)); box-shadow: inset 0 0 0 1px rgba(207, 111, 34, 0.75), inset 0 0 0 2.5px rgba(20, 12, 10, 0.9), 0 3px 12px rgba(0, 0, 0, 0.55); }
html[data-bar='float'] #ui[data-floating='1'][data-duo='1'] .readout.win.duo .label { color: var(--pale); text-shadow: 0 1px 2px #000; }
html[data-bar='float'] #ui[data-floating='1'][data-duo='1'] .readout.win.duo .value { font-size: max(15px, calc(15px / var(--k, 1))); line-height: 1.08; color: #ffd58c; text-shadow: 0 1px 2px #000; }
/* THE DEMO AND TEST ROUNDS MARKS. A phone (upright or on its side): the top-left corner of the glass, off the King,
   off every button, clear of the sign and of THE TAKE (ui/app.js keeps them out of the money row there); never over
   the loading or the first screen. */
html:not([data-entered='1']) #badges { opacity: 0; }
html[data-bar='float'] #badges, html[data-bar='side'] #badges { gap: 4px; }
html[data-bar='float'] #badges .badge, html[data-bar='side'] #badges .badge { font-family: var(--font-text); font-size: 11px; letter-spacing: 0.06em; padding: 0 4px; line-height: 1.25; background: rgba(14, 10, 11, 0.5); color: var(--tan); box-shadow: inset 0 0 0 1px rgba(160, 120, 70, 0.5); }
/* A bar with a plate (desktop): the tester's marks stand ON THE PLATE, just over DEMO, the same small capitals (the
   live walk's fault 1: TEST ROUNDS hung under the plate, on the grass). Beside DEMO there is no room: WIN begins
   there. Between the plate's rim and the label there are 13 px: the capitals alone, without DEMO's hairline box. */
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal #badges { position: relative; top: 0; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.test, html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.dev { left: 0; top: auto; bottom: calc(100% + 5.8px); padding: 0 3px; line-height: 1; background: none; box-shadow: none; }
html[data-layout='desktop'] #ui:not([data-floating='1']) .readout.bal .badge.test ~ .badge.dev { left: 9em; }


/* ================================================================ POLISH BUILD 1 (17 Nov 2026, the interface seat) */
/* PM item 19: THE PRESS ANSWERS THE FINGER. SPIN's painted face is DRAWN by the page on a canvas (ui/hud.js: every
   state's picture is decoded once and kept, so no state ever waits a frame for its picture); where it is, the
   sheet's own state pictures step aside. STOP is the copper square the page draws there. */
#ui .btn-spin .face canvas { display: block; width: 100%; height: 100%; border-radius: 50%; }
#ui .btn-spin[data-cv='1'] { isolation: isolate; } /* lead hotfix 17 Nov 16:50: the style sheet's picture STAYS under the drawn face, so a browser whose canvas comes up empty (the owner: "The spin button is missing") still shows the button */
#ui .btn-spin[data-cv='1'] .face { display: block; position: absolute; inset: 0; z-index: -1; border-radius: 50%; pointer-events: none; }
#ui .btn-spin[data-cv='1'][data-mode='hold'] { filter: none; }
/* THE MARK ON THE RING'S OWN CENTRE (the owner, 18 Nov: "It needs to be absolutely centered on the button"). In his
   painted SPIN the arrow's circle lies 1.14% of the button left of and 0.36% under the centre of the copper ring,
   STOP's square 0.07% right and 0.10% over it. The inside of the dark disc, with its mark, is drawn once more moved
   by that much, soft-edged inside the disc; the ring stays. ui/hud.js does the same on its canvas (FACE_SHIFT), which
   lies over this and hides it whenever it is drawn: one face is seen, and it is the same face if the canvas is empty. */
#ui:not([data-floating='1']) .btn-spin[data-cv='1'] .face { background-image: inherit; background-repeat: no-repeat; background-size: 0 0; }
#ui .btn-spin .face canvas { position: relative; }
#ui .btn-spin[data-mode='spin'] .face::before, #ui .btn-spin[data-mode='hold'] .face::before, #ui .btn-spin[data-mode='stop'] .face::before { content: ''; position: absolute; inset: 0; border-radius: 50%; pointer-events: none; background-image: inherit; background-position: center; background-size: 100% 100%; background-repeat: no-repeat; transform: translate(1.144%, -0.356%); -webkit-mask-image: radial-gradient(circle closest-side, #000 73%, rgba(0, 0, 0, 0) 82%); mask-image: radial-gradient(circle closest-side, #000 73%, rgba(0, 0, 0, 0) 82%); }
#ui .btn-spin[data-mode='stop'] .face::before { transform: translate(-0.074%, 0.103%); }
/* (with no painted set at all, STOP's drawn square is copper too) */
#ui .btn-spin[data-mode='stop'] svg { fill: #e58a36; }
/* SPIN SINKS ON FINGER DOWN: the look is keyed on the finger itself (data-down, set in the pointer's own event),
   not on the browser's :active, which a phone may put on late or not at all. It goes down and in, and its face is
   drawn darker (ui/hud.js); no wait (the way down takes no transition, the way up 0.06 s). The sheet changes ONLY
   the button's place and size here, never its filter: a new filter on the first press of a visit cost the
   graphics card a tenth of a second before the look was seen (measured on film: 150 ms, then 33). */
#ui .btn-spin[data-cv='1']:active:not(:disabled) { transform: none; filter: none; }
html #ui[data-floating='1'] .btn-spin[data-cv='1']:active:not(:disabled) { filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.5)); }
#ui .btn-spin[data-down='1']:not(:disabled), #ui .btn-spin[data-cv='1'][data-down='1']:active:not(:disabled) { transform: translateY(2.6%) scale(0.945) !important; transition-duration: 0s; animation: none; }

/* THE OWNER'S WORD, 17 Nov 12:35 (BRIEF ruling 22, point 8): A SPEED BUTTON ON THE DESKTOP BAR. A small round copper
   button at the right end of his plate, by SPIN and autoplay (ui/hud.js SPEED): his own copper ring with its dark
   disc (the empty SPIN picture, small), the phone's own marks in his pale gold: one chevron NORMAL, two TURBO,
   three SUPER TURBO; lit while turbo or super turbo is on. Its name is said by the notice that follows a press
   and by SPIN's own rim mark. T on the keyboard as before. */
#ui:not([data-floating='1']) .ic.turbo { border-radius: 50%; gap: 0; color: var(--pale); background: radial-gradient(circle closest-side, #17110f 0 74%, #5a2208 76%, #e9862c 80%, #ffcf82 85%, #f08a2a 90%, #8a3a10 96%, rgba(46, 18, 6, 0) 100%) center / contain no-repeat; filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.55)); transition: transform 0.06s ease, filter 0.12s ease; }
html.art-spin-blank #ui:not([data-floating='1']) .ic.turbo { background: var(--art-spin-blank) center / contain no-repeat; }
#ui:not([data-floating='1']) .ic.turbo svg { width: 54%; height: 42%; position: relative; left: 1.5%; filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.7)); }
/* (the speed has its own button beside SPIN now, lit while it is on: SPIN's rim carries no second mark, as on a phone) */
#ui:not([data-floating='1']) .btn-spin .spd { display: none !important; }
#ui:not([data-floating='1']) .ic.turbo .sub { display: none; }
#ui:not([data-floating='1']) .ic.turbo.on { color: #ffd58c; }
#ui:not([data-floating='1']) .ic.turbo.on svg { filter: drop-shadow(0 0 5px rgba(255, 190, 100, 0.95)) drop-shadow(0 1px 1px rgba(0, 0, 0, 0.7)); }
#ui:not([data-floating='1']) .ic.turbo:active { transform: translateY(2.6%) scale(0.94); filter: brightness(0.9) drop-shadow(0 1px 2px rgba(0, 0, 0, 0.65)); }
@media (hover: hover) and (pointer: fine) {
  #ui:not([data-floating='1']) .ic.turbo:hover:not(:active) { filter: brightness(1.14) drop-shadow(0 3px 5px rgba(0, 0, 0, 0.55)); }
}

/* THE FIGURE THAT FLIES TO WIN LANDS IN IT (ui/hud.js, `win:land`): the box swells about its own figure */
#ui .readout.win { transform-origin: 22% 62%; }
html[data-bar] #ui[data-floating='1'] .readout.win { transform-origin: 50% 60%; }

/* PM item 18 (the world seat's request of 12:42): ON AN UPRIGHT PHONE A NOTICE STANDS ON THE MACHINE'S FOOT, clear
   of the land where the King's head, hands and flame are: its bottom edge on the reels' bottom edge (ui/app.js
   gives the height of that edge, --toast-foot; 33.5% of the screen where it has not). Still never in the sky,
   where THE TAKE and the BIG KING meter are. */
@media (max-aspect-ratio: 23/20) {
  html[data-bar='float'] #toasts { top: auto; bottom: calc(var(--toast-foot, 33.5%) + var(--toast-lift, 0px)); }
}
/* (STOP on a phone: SPIN's dark disc lets the land through; its copper square does not: it is metal) */
html #ui[data-floating='1'] .btn-spin[data-cv='1'][data-mode='stop'] .face { -webkit-mask-image: linear-gradient(#000, #000), radial-gradient(circle closest-side, rgba(0, 0, 0, 0.72) 0 78%, #000 85%); mask-image: linear-gradient(#000, #000), radial-gradient(circle closest-side, rgba(0, 0, 0, 0.72) 0 78%, #000 85%); -webkit-mask-size: 33% 33%, 100% 100%; mask-size: 33% 33%, 100% 100%; -webkit-mask-position: center, center; mask-position: center, center; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; }

/* POLISH BUILD 1, second sitting. THE MARKS IN A LOW FRAME (HIT's 393 x 531; the phone-frame seat's note of 13:18):
   the sky is cut first there, so the sign stands at the top edge with its left wing where TEST ROUNDS was. DEMO
   alone keeps the corner (it ends before the wing); the owner's mark is not drawn in such a frame (ui/app.js
   homeBadges sets data-cut). And everywhere: TEST ROUNDS is drawn only where the page was opened with the cheat
   key (the lead, 13:22); on a plain visit it carries `hidden`. */
#badges[data-cut='1'] .badge.test { display: none !important; }
/* "+N FREE SPINS": the count on SPIN swells as each light lands on it (ui/hud.js, `spins:land`): about its own middle */
#ui .btn-spin [data-k='left'] { transform-origin: 50% 55%; }
/* THIRD SITTING (the phone-frame seat's note of 14:02: in that corner DEMO still lay on the wing's tip, and in TURF
   WAR on the word THE of THE TAKE). In a frame whose sign stands at the top edge DEMO leaves the corner for the
   money row: on BALANCE's own line, just after the word, as it stands beside BALANCE on the desktop's plate
   (ui/app.js homeBadges moves it into the readout and gives the word's half width and middle line). */
html[data-bar] #ui[data-floating='1'] .readout.bal #badges[data-cut='1'] { left: calc(50% + var(--bal-label-half, 28px) + 5px); right: auto; top: var(--bal-label-mid, 7px); bottom: auto; transform: translateY(-50%); }
html[data-bar] #ui[data-floating='1'] .readout.bal #badges[data-cut='1'] .badge { font-size: 11px; letter-spacing: 0.05em; padding: 0 3px; line-height: 1.12; text-shadow: none; }

/* ================================================================ POLISH BUILD 1, AFTER THE INDEPENDENT CHECK (17 Nov 16:20) */
/* THE PHONE'S NOTICE STANDS IN THE LAND BESIDE THE KING (the check: on the reels' foot it "covers the lower part of
   the bottom row of symbols for 1.8 s"; before that it lay on his hair). ui/app.js finds the strip of land under
   the machine's foot and right of him, and gives the tab's right edge (--toast-right), the room between him and
   that edge (--toast-room) and the height of the tab's top (--toast-foot); the notice is a small plate there, its
   words on as many lines as they need. Where there is no such strip (data-toast is empty) the rule above stands. */
@media (max-aspect-ratio: 23/20) {
  html[data-bar='float'][data-toast='land'] #toasts { left: auto; right: var(--toast-right, 8px); width: var(--toast-room, 230px); padding: 0; align-items: flex-end; gap: 4px; }
  html[data-bar='float'][data-toast='land'] .toast { max-width: 100%; font-size: 12px; line-height: 1.22; letter-spacing: 0.04em; padding: 5px 10px; border-radius: 5px; box-shadow: var(--edge), 0 3px 8px rgba(0, 0, 0, 0.55); }
}
/* THE PHONE'S WIN IS READ AT A GLANCE (the check: the held amount was "the small pale figure in the corner: readable
   on the sheet, no more"). On an upright phone WIN shows only while there is an amount to show, in the money
   row's small pale type over the wheat. The amount is now the row's one bright figure: his warm gold, a quarter
   larger than BALANCE and BET beside it, on a soft dark footing so the wheat does not eat it. The label keeps
   its size. (In a bonus WIN and TOTAL WIN have their own plate: untouched.) */
html[data-bar] #ui[data-floating='1'] .readout.win:not(.duo) .value { font-size: max(16px, calc(var(--px12, 12.5px) * 1.28)); color: #ffd98f; text-shadow: 0 1px 2px #000, 0 0 6px rgba(0, 0, 0, 0.9), 0 0 13px rgba(255, 176, 74, 0.5); }
html[data-bar] #ui[data-floating='1'] .readout.win:not(.duo) .label { color: var(--pale); text-shadow: 0 1px 2px #000, 0 0 6px rgba(0, 0, 0, 0.85); }
/* ... AND IN A LOW FRAME (HIT's 393 x 531; data-toast is 'slip'): a notice of one line is a slip on the machine's foot
   rail, as tall as the feature tab and in line with it: in the tab's place while no feature is on, just left of
   the tab while one is (ui/app.js gives the places; ui/panels.js marks the notices that fit on one line). */
@media (max-aspect-ratio: 23/20) {
  html[data-bar='float'][data-toast='slip'] .toast.slip { position: fixed; top: var(--slip-top, 60%); right: var(--slip-right-off, 8px); max-width: var(--slip-room-off, 80%); height: var(--slip-h, 18px); box-sizing: border-box; display: flex; align-items: center; white-space: nowrap; overflow: hidden; font-size: 10.5px; line-height: 1; letter-spacing: 0.04em; padding: 0 8px; border-radius: 4px; box-shadow: var(--edge), 0 2px 5px rgba(0, 0, 0, 0.5); }
  html[data-bar='float'][data-toast='slip'][data-feature-tab='1'] .toast.slip { right: var(--slip-right-on, 8px); max-width: var(--slip-room-on, 50%); }
}

/* ================================================================ THE NIGHT'S MENDS (18 Nov, docs/night/PUNCH-LIST.md) */
/* J05. ON A DESKTOP THE BUY MENU NEVER SCROLLS (HIT's desktop card is 1084 x 610; smaller cards 1024 x 576 and
   960 x 540 cut ACTIVATE and BUY at the panel's foot, and nothing said there was more). Under 700 px of height the
   panel may stand 8 px from the top and the bottom, and the cards' picture gives way first (124 px down to 60);
   under 520 px their air goes too. A phone on its side (480 px and under) keeps its own rules above. The net
   under these rules is in ui/panels.js (buy: fit). */
@media (min-height: 481px) and (max-height: 700px) and (min-aspect-ratio: 23/20) {
  html[data-layout='desktop'] .panel[data-panel='buy'] { max-height: calc(100% - 16px); }
  html[data-layout='desktop'] .panel[data-panel='buy'] .card .thumb { width: clamp(60px, calc(100vh - 440px), 124px); height: clamp(60px, calc(100vh - 440px), 124px); }
}
@media (min-height: 481px) and (max-height: 520px) and (min-aspect-ratio: 23/20) {
  html[data-layout='desktop'] .panel[data-panel='buy'] .card { row-gap: 3px; padding: 10px 10px 9px; }
  html[data-layout='desktop'] .panel[data-panel='buy'] .panel-body { padding-bottom: 10px; }
  html[data-layout='desktop'] .panel[data-panel='buy'] .betrow { min-height: 58px; }
}
/* J10. THE BUY MENU ON A PHONE 370 TO 400 PX WIDE (390 and 393 are the commonest iPhones: there BAD BLOOD SPINS and
   THE SHAKEDOWN broke in two, VOLATILITY and RETURN ran to three lines, and the list was 562 px in a 515 px
   window). The 360 px phone's own measures hold up to 400: the picture 66, the button 92, the tighter air. A fact
   never breaks inside itself (VOLATILITY: VERY HIGH is one piece, RETURN 96.32% the other). Where the window is
   shorter than the list (HIT's 393 x 531) the panel says MORE BELOW (ui/panels.js buy: moreCue). */
html:not([data-layout='desktop']) .card .meta span { white-space: nowrap; }
/* (second sitting, 18 Nov: to 410, not 400: an iPhone 16 Pro and 17 Pro are 402 wide, and there BAD BLOOD SPINS was
   still two lines and the list 562 px, 6 over a 700 px window with no cue) */
@media (min-width: 370px) and (max-width: 410px) {
  html:not([data-layout='desktop']) .card { grid-template-columns: 66px minmax(0, 1fr) auto; column-gap: 8px; padding: 6px 7px; row-gap: 2px; }
  html:not([data-layout='desktop']) .card .thumb { width: 66px; height: 66px; }
  html:not([data-layout='desktop']) .card .go { width: 92px; }
  html:not([data-layout='desktop']) .card .rule { font-size: 12.5px; line-height: 1.15; }
  html:not([data-layout='desktop']) .cards { gap: 5px; }
  html:not([data-layout='desktop']) .panel[data-panel='buy'] .betrow { min-height: 50px; padding-bottom: 4px; }
}
/* ... and the confirm box's deed is one line on a phone: BACK is the narrow one, "BUY €400.00" has the room */
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .panel-foot .cta { white-space: nowrap; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .panel-foot .cta.ghost { flex: 0 1 32%; }
html:not([data-layout='desktop']) .panel[data-panel='buyConfirm'] .panel-foot .cta.long { font-size: 17px; letter-spacing: 0.04em; }
@media (max-width: 410px) { html:not([data-layout='desktop']) .card .go { letter-spacing: 0.05em; } }
/* J07. NOT ENOUGH BALANCE: LOWER BET and RESET DEMO BALANCE stand one above the other at full width, each on one
   line (side by side the long one broke in three and touched the button's edges); on a phone the title of an
   error box is one line (21 px: NOT ENOUGH BALANCE, SOMETHING WENT WRONG). ui/panels.js box() marks the foot. */
.panel-foot.stack { flex-direction: column; gap: 8px; }
.panel-foot.stack .cta { flex: none; width: 100%; white-space: nowrap; }
html:not([data-layout='desktop']) .panel[data-panel='error'] .confirm-box .name { font-size: 21px; letter-spacing: 0.04em; }
/* J09. HIS MONEY IS 15 PX ON HIS PHONE (the phone audit: BALANCE and BET were 12.5 px on the glass at 440 wide, 12 at
   393 and 360). On an upright phone the figures are 15 px at 440 wide, 13.4 at 393, never under 13; WIN keeps its
   quarter over them (19 px at 440). No new plate under them. (In a bonus WIN and TOTAL WIN keep their own size.) */
html[data-bar='float'] #ui[data-floating='1'] { --fig: max(15px, calc(13px / var(--k, 1))); }
html[data-bar='float'] #ui[data-floating='1'] .readout .value, html[data-bar='float'] #ui[data-floating='1'] .readout.boxed .value { font-size: var(--fig); }
html[data-bar='float'] #ui[data-floating='1'] .readout.duo .value { font-size: max(12px, var(--px11)); }
html[data-bar='float'] #ui[data-floating='1'] .readout.win:not(.duo) .value { font-size: calc(var(--fig) * 1.28); }
/* J23 and J22. THE BOX SAYS THE PRICE ONCE (ui/panels.js buy: confirm). A feature spin's box is its name, its picture,
   "€4.00 A SPIN" and ACTIVATE: that one line is the box's figure, so it is set as one. */
.panel[data-panel='buyConfirm'][data-kind='feature'] .confirm-box .head { font-size: 22px; letter-spacing: 0.06em; color: var(--pale); margin-top: 8px; font-variant-numeric: lining-nums tabular-nums; }
@media (min-height: 481px) { html[data-layout='desktop'] .panel[data-panel='buyConfirm'][data-kind='feature'] .confirm-box .head { font-size: 30px; margin-top: 14px; } }
/* J22, second half. THE ONE TAG: "HEAT SPINS ON" stands on a cut of his own plate (the bar's plain plate, small: it
   was a flat orange or red tab), its words 13 px on the glass at least, without the cost (BET says it, once).
   And OFF, one word everywhere, 12 px at least, on his own medallion as he painted it (it was DISABLE on a flat
   blood-red wash on a desktop and a 9 px OFF on a phone). Without his pictures the copper tab and disc above stand. */
html #ui .banner, html #ui[data-floating='1'] .banner { font-size: max(13px, calc(13px / var(--k, 1))); letter-spacing: 0.05em; }
html.art-plate-plain #ui .banner, html.art-plate-plain #ui .banner[data-feature='heat'] { background: var(--art-plate-plain) center / 100% 100% no-repeat; box-shadow: none; border-radius: 0; color: var(--pale); text-shadow: 0 1px 2px #000, 0 0 5px rgba(0, 0, 0, 0.8); filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.55)); }
html #ui .banner .fi { color: #f0a13a; }
html #ui .btn-buy.disable span { font-size: 12px; font-size: max(22cqw, var(--px12)); letter-spacing: 0.06em; }
html.art-buy #ui .btn-buy.disable { box-shadow: none; }
html.art-buy #ui .btn-buy.disable span { color: var(--pale); text-shadow: 0 1px 2px #000, 0 0 6px rgba(0, 0, 0, 0.85); }
/* J22: ON A DESKTOP A NOTICE HANGS FROM THE STAGE (it stood 34 px from the window's top: on the machine's name at
   HIT's desktop card). One that fits on one line is a slip on the bar's top edge, in the feature tab's place and in
   its look (ui/app.js says where; ui/panels.js marks the ones that fit); a longer one keeps the window's top. */
html[data-bar='desktop'][data-toast='slip'] .toast.slip { position: fixed; top: var(--dslip-top, 60%); left: var(--dslip-left-off, 30%); max-width: var(--dslip-room-off, 40%); height: var(--dslip-h, 20px); box-sizing: border-box; display: flex; align-items: center; white-space: nowrap; overflow: hidden; font-size: 13px; line-height: 1; letter-spacing: 0.05em; padding: 0 14px; border-radius: 4px 4px 0 0; }
/* (while a feature spin is on the slip stands OVER its tab for the moment it shows: beside it there is no room at
   HIT's desktop card; with a panel open a notice keeps the window's top: ui/panels.js) */
html.art-plate-plain[data-bar='desktop'][data-toast='slip'] .toast.slip { background: var(--art-plate-plain) center / 100% 100% no-repeat; box-shadow: none; border-radius: 0; text-shadow: 0 1px 2px #000, 0 0 5px rgba(0, 0, 0, 0.8); filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.55)); }
/* ---- THE MEND SITTING (18 Nov 01:05; the independent check's words, outbox/night/n-interface/CHECK.md) ---- */
/* J22: a desktop's notice too long for one line is a slip of TWO lines in the tab's place (ui/panels.js measures it
   and stands it 3 px over the tab's top: it reaches no symbol above and no word of the bar below); and while a feature
   spin is on the slip is as wide as the tag at least (its width is set from the glass), its words in the middle. */
html[data-bar='desktop'][data-toast='slip'] .toast.slip.two { height: auto; white-space: normal; line-height: 1.1; padding: 2px 14px; }
html[data-bar='desktop'][data-toast='slip'][data-feature-tab='1'] .toast.slip { justify-content: center; }
/* J10: VOLATILITY and RETURN on ONE line on an upright phone. Beside the button the column has 152 to 194 px and the
   line needs 242 with the 8 px between its two facts: it runs from the card's left edge, under the picture's foot,
   and ends before the button. The card is no taller. The flex row and its 8 px stay; the letters stand closer where
   the phone is narrower, so the words end 6 px or more before the button (measured: 6 at 360, 9 at 375, 13 at 390,
   16 at 393, 15 at 402, 42 at 440). Under 360 wide the two lines beside the button stand as they were. */
@media (min-width: 360px) and (max-width: 480px) {
  html:not([data-layout='desktop']) .card .meta { grid-column: 1 / 3; grid-row: 3; align-self: end; flex-wrap: nowrap; }
}
@media (min-width: 360px) and (max-width: 420px) {
  html:not([data-layout='desktop']) .card .meta { letter-spacing: 0.03em; }
}
@media (min-width: 360px) and (max-width: 384px) {
  html:not([data-layout='desktop']) .card .meta { letter-spacing: 0; }
}

/* ================================================================ THE NIGHT'S MENDS, SECOND SITTING (18 Nov 01:15) */
/* THE PLATES SEAT'S TWO PIECES FOR THE BAR (night list J68, for J64; its ask of 18 Nov 00:57, its six lines as it
   tried them): the fast-forward mark made of his arrowhead (`icon_skip`) in place of the drawn one, and his copper
   ring wrapped round the small discs (`btn_disc`). ALL SIX DO NOTHING until its pieces are installed (`ui/manifest.json`
   then gives the classes `art-spin-skip` and `art-disc` and the two addresses; ui/app.js adopt()): an independent eye
   passes them first. */
html.art-spin-skip #ui .btn-spin[data-mode='skip'] svg { display: none; }
html.art-spin-skip #ui .btn-spin[data-mode='skip']::after { content: ''; position: absolute; inset: 0; background: var(--art-spin-skip) center / 100% 100% no-repeat; pointer-events: none; }
html.art-disc.art-spin-blank #ui[data-floating='1'] .ic, html.art-disc.art-spin-blank #ui[data-floating='1'] .boxed.auto { background-image: var(--art-disc); }
html.art-disc.art-spin-blank.art-menu #ui[data-floating='1'] .ic.menu { background-image: var(--art-menu), var(--art-disc); }
html.art-disc.art-spin-blank.art-auto #ui[data-floating='1'] .boxed.auto { background-image: var(--art-auto), var(--art-disc); }
html.art-disc.art-spin-blank #ui:not([data-floating='1']) .ic.turbo { background-image: var(--art-disc); }
/* A PANEL LEAVES IN 0.12 S (night list J24; ui/panels.js leave()): the closed panel's picture, in a layer of its own
   over `#panels` that takes no press: down 24 px and a fade, the veil fading with it (it fades in already). `translate`
   is its own property, so every panel keeps the `transform` it rests in (a sheet, a box, the desktop's window); the
   desktop's drawer goes back the way it came. Less motion asked: ui/panels.js takes the panel away at once. */
#panels-out { position: absolute; inset: 0; pointer-events: none; z-index: 20; }
#panels-out .scrim, #panels-out .panel { pointer-events: none; }
#panels-out .scrim { animation: veil-out 0.12s ease-in both; }
#panels-out .panel { animation: panel-out 0.12s ease-in both; }
html[data-layout='desktop'] #panels-out .panel.drawer { animation-name: drawer-out; }
@keyframes veil-out { to { opacity: 0; } }
@keyframes panel-out { to { translate: 0 24px; opacity: 0; } }
@keyframes drawer-out { to { translate: -24px 0; opacity: 0; } }
/* THE HISTORY TABLE FITS (night list J43; ui/panels.js history()): the rounds first and fairness under them; no SEED
   column; COST only where a round cost something other than its bet. Up to 560 px wide a round is TWO LINES: its
   time, its name and CHECK (never squeezed: it read "CHEC" at 393), then its money, each figure with its own word in
   front, on a line that may wrap but never leaves the screen (a 2,000.00 bet with a bought bonus and a win of seven
   figures). Wider screens keep the table, a column narrower. */
.hist td.b, .hist td.c, .hist td.w { white-space: nowrap; }
.panel[data-panel='history'] .hist-wrap + .kv, .panel[data-panel='history'] p + .kv { margin-top: 16px; }
@media (max-width: 560px) {
  .hist, .hist tbody { display: block; }
  .hist thead { display: none; }
  .hist tr { display: flex; flex-wrap: wrap; align-items: center; column-gap: 12px; row-gap: 0; padding: 0 4px 8px; border-top: 1px solid rgba(201, 161, 90, 0.16); }
  .hist tr::before { content: ''; flex: 0 0 100%; order: 2; }
  .hist td { border-top: 0; padding: 0; }
  .hist td.t, .hist td.r, .hist td.k { order: 1; }
  .hist td.t { color: var(--dim); }
  .hist td.r { flex: 1 1 0; min-width: 0; color: var(--pale); letter-spacing: 0.04em; }
  .hist td.k { flex: none; min-height: 44px; display: flex; align-items: center; }
  .hist td.b, .hist td.c, .hist td.w { order: 3; }
  .hist td.c:empty { display: none; }
  .hist td[data-l]::before { content: attr(data-l) '\a0'; font-size: 11px; letter-spacing: 0.1em; color: var(--dim); font-weight: 700; }
}
/* THE PHONE'S BONUS FIGURES STAND ON HIS BAR PLATE (night list J45): WIN over TOTAL WIN on a cut of `bar_plate_plain`
   (a border picture: its four corners whole, the middle of its long rims and of its slate at their own width, never
   squeezed sideways; only the short sides are stretched, to the box's height) in place of the plum
   web box. The box, its words and their sizes are untouched (ui/hud.js winBox): the plate is a layer behind them,
   3 px larger all round so the words keep their air inside the copper. Without the piece (`art-plate-plain` not
   adopted) the old box stands. BACK TO THE WEB BOX: delete these two lines. */
html.art-plate-plain[data-bar='float'] #ui[data-floating='1'][data-duo='1'] .readout.win.duo { background: none; box-shadow: none; border-radius: 0; isolation: isolate; }
html.art-plate-plain[data-bar='float'] #ui[data-floating='1'][data-duo='1'] .readout.win.duo::before { content: ''; position: absolute; inset: -3px; z-index: -1; border: 11px solid transparent; border-image: var(--art-plate-plain) 56 fill / 11px repeat stretch; filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.6)); pointer-events: none; }
