/* The public arcade uses cut-paper props as the face of native controls. */
[data-game="crash"] { --table-prop: url("./assets/paper-controls/glider.webp"); }
[data-game="hilo"] { --table-prop: url("./assets/paper-controls/cards.webp"); }
[data-game="mines"] { --table-prop: url("./assets/paper-controls/crystal.webp"); }
[data-game="dice"] { --table-prop: url("./assets/paper-controls/dice.webp"); }
[data-game="plinko"] { --table-prop: url("./assets/paper-controls/chute.webp"); }
[data-game="blast"] { --table-prop: url("./assets/paper-controls/chalet.webp"); }

.illustrated-arcade {
  --paper-ribbon: url("./assets/paper-controls/ribbon.webp");
  --paper-tokens: url("./assets/paper-controls/tokens.webp");
  --paper-arrow: url("./assets/paper-controls/arrow.webp");
  --paper-stone: url("./assets/paper-controls/stone.webp");
  --paper-burst: url("./assets/paper-controls/burst.webp");
  --paper-medal: url("./assets/paper-controls/medal.webp");
}

/* Put the printed label beside the prop and keep a full-size touch surface. */
.illustrated-arcade .app[data-game] :is(.bet-dock-tier-cta button.bet-dock-cta-btn, button.hand-next) {
  --action-art: var(--table-prop);
  position: relative; isolation: isolate; display: flex; align-items: center; justify-content: center;
  gap: clamp(4px, 2vw, 12px); min-height: 48px; height: auto; padding: 3px clamp(13px, 5vw, 38px);
  margin-inline: auto; max-width: 480px; border: 0; border-radius: 0; box-shadow: none;
  background: transparent; color: #261c22; font-weight: 800; line-height: 1.15;
  text-transform: none; text-shadow: 0 1px #ffe4a6; overflow: visible;
}
.illustrated-arcade .app[data-game] :is(.bet-dock-tier-cta button.bet-dock-cta-btn, button.hand-next)::after {
  content: ""; position: absolute; inset: 0; z-index: -1; width: auto; height: auto;
  background: var(--paper-ribbon) center / 100% 100% no-repeat;
  border: 0; border-radius: 0; box-shadow: none; opacity: 1; pointer-events: none;
  mask: none; clip-path: none; transform: none; animation: none;
}
.illustrated-arcade .app[data-game] :is(.bet-dock-tier-cta button.bet-dock-cta-btn, button.hand-next)::before {
  content: ""; position: static; inset: auto; display: block; flex: 0 0 auto;
  width: clamp(36px, 11vw, 58px); height: clamp(37px, 9vw, 46px);
  background: var(--action-art) center / contain no-repeat; border: 0; box-shadow: none;
  clip-path: none; mask: none; opacity: 1; transform: none; animation: none; pointer-events: none;
}
.illustrated-arcade .app[data-game] button.bet-dock-cta-btn:disabled {
  opacity: .82; filter: saturate(.52); cursor: default;
}
.illustrated-arcade .app[data-game] :is(.bet-dock-cta-btn,.hand-next,.mine-cell,.room,.dice-side-pick,.bet-dock-segment-btn):focus-visible {
  outline: 3px solid #fff1b8 !important; outline-offset: -2px;
}
.illustrated-arcade .app[data-game] button.bet-dock-cta-btn[data-prop="collect"] { --action-art: var(--paper-tokens); }
.illustrated-arcade .app[data-game] button.bet-dock-cta-btn:is(.hilo-pick-higher,.hilo-pick-lower) {
  --action-art: var(--paper-arrow); gap: 3px; padding: 4px 11px; flex-wrap: nowrap;
}
.illustrated-arcade .app[data-game] button:is(.hilo-pick-higher,.hilo-pick-lower)::before { width: 23px; height: 30px; }
.illustrated-arcade .app[data-game] button.hilo-pick-lower::before { rotate: 180deg; }
.illustrated-arcade .app[data-game] .hilo-picks button small { color: #4c301c; }
.illustrated-arcade :is(.hilo-pick-icon,.dice-action-icon) { display: none !important; }

.illustrated-arcade .app[data-game] button.dice-side-pick {
  background: transparent; border-color: transparent; box-shadow: none; min-height: 44px;
}
.illustrated-arcade .app[data-game] button.dice-side-pick[aria-pressed="true"] {
  background: #392e26; border-bottom: 2px solid #f4c974;
}
.illustrated-arcade .dice-side-symbol {
  width: 24px; height: 25px; display: block; font-size: 0; background: var(--paper-arrow) center / contain no-repeat;
}
.illustrated-arcade .dice-side-pick:first-child .dice-side-symbol { rotate: 210deg; }
.illustrated-arcade .dice-side-pick:last-child .dice-side-symbol { rotate: 30deg; }

.illustrated-arcade .app[data-game] .practice-token {
  display: block; width: 23px; height: 23px; font-size: 0; background: var(--paper-tokens) center / contain no-repeat;
}
.illustrated-arcade .app[data-game] :is(.bet-dock-segment-btn,.bet-dock-chip) {
  border: 0; border-radius: 0; background: transparent; box-shadow: none;
}
.illustrated-arcade .app[data-game] .bet-dock-segment-btn.active {
  color: #ffdf98; text-decoration: underline; text-underline-offset: .25em;
}
.illustrated-arcade .app[data-game] .bet-dock-segment-btn.active::before {
  content: ""; display: inline-block; width: .95em; height: 1em; margin-right: .3em;
  background: var(--table-prop) center / contain no-repeat; vertical-align: -.12em;
}

.illustrated-arcade .app[data-game="mines"] .vault-board-space .mines-board button.mine-cell:is(.hidden,.safe,.mine),
.illustrated-arcade .app[data-game="mines"] .vault-board-space .mines-board button.mine-cell.hidden:is(:hover,:focus-visible):not(:disabled) {
  border: 0 !important; box-shadow: none !important; background: transparent !important;
}
.illustrated-arcade .app[data-game="mines"] .mines-board button.mine-cell.hidden .survey-stone {
  display: block; pointer-events: none; position: absolute; inset: 3%; width: auto; height: auto;
  background: var(--paper-stone) center / contain no-repeat; opacity: 1; clip-path: none; border: 0; transform: none;
}
.illustrated-arcade .app[data-game="mines"] .mines-board button.mine-cell.is-survey-marked .survey-stone {
  filter: brightness(1.35) drop-shadow(0 0 2px #ffd56a);
}
.illustrated-arcade .mine-cell .vault-coordinate { z-index: 2; }
.illustrated-arcade .app[data-game="mines"] .vault-crystal { background: var(--table-prop) center / contain no-repeat; }
.illustrated-arcade .app[data-game="mines"] .mine-cell.mine .mine-mark-inner {
  width: 90%; height: 90%; background: var(--paper-burst) center / contain no-repeat; color: transparent; font-size: 0;
}
.illustrated-arcade .mine-cell.mine .mine-mark-inner > * { visibility: hidden; }
.illustrated-arcade .vault-shutters i { background: var(--paper-stone) center / contain no-repeat; }

.illustrated-arcade .app[data-game="blast"] .grid button.room .room-copy {
  grid-template-columns: minmax(24px, 38%) minmax(0, 1fr); column-gap: 2px; padding: 2px 3px;
  background: radial-gradient(ellipse at center,#122137f2 36%,#14223899 64%,transparent 76%) !important;
  border: 0 !important; box-shadow: none !important;
}
.illustrated-arcade .app[data-game="blast"] .grid button.room .chalet-window {
  grid-row: 1 / 3; grid-column: 1; width: 100%; min-height: 32px; max-height: 45px; height: 100%;
  background: var(--table-prop) center / contain no-repeat; box-shadow: none; border: 0;
}
.illustrated-arcade .app[data-game="blast"] .grid button.room:is(.selected,.entered) .chalet-window {
  filter: drop-shadow(0 0 2px #ffd97a) brightness(1.2);
}
.illustrated-arcade .app[data-game="blast"] .grid button.room.exploded .chalet-window { background-image: var(--paper-burst); }
.illustrated-arcade .app[data-game="blast"] .grid button.room .room-id {
  align-self: end; justify-self: start; grid-row: 2; padding: 0 2px; border-radius: 3px;
  color: white; background: #12243c; z-index: 1;
}
.illustrated-arcade .app[data-game="blast"] .grid button.room :is(.room-meta,.room-odds) { text-shadow: 0 1px 2px #071426; }

.illustrated-arcade .app[data-game] :is(.cashout-receipt__check,.hand-seal,.vault-receipt-art,.snow-report-window) {
  width: 29px; height: 29px; display: block; border: 0; border-radius: 0; box-shadow: none; color: transparent;
  background: var(--paper-medal) center / contain no-repeat; font-size: 0;
}
.illustrated-arcade .app[data-game] :is([data-outcome="miss"],[data-outcome="bombed"],[data-outcome="lost"],[data-flight-outcome="missed"])
  :is(.cashout-receipt__check,.hand-seal,.vault-receipt-art,.snow-report-window) { background-image: var(--paper-burst); }
.illustrated-arcade .snow-report-window::before { display: none; }
.illustrated-arcade .landing-slip > div:first-child {
  padding-inline-start: 34px; background: var(--paper-medal) left center / 29px auto no-repeat;
}
.illustrated-arcade .landing-slip[data-outcome="miss"] > div:first-child { background-image: var(--paper-burst); }
.illustrated-arcade .plinko-stage[data-phase="landed"] .chute-emblem {
  background: var(--paper-ribbon) center / 100% 100% no-repeat; color: #2a211b; border: none; border-radius: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .illustrated-arcade .app[data-game] :is(.bet-dock-cta-btn,.hand-next)::before,
  .illustrated-arcade :is(.survey-stone,.chalet-window,.dice-side-symbol) {
    transition: transform 160ms cubic-bezier(.2,.8,.28,1);
  }
  .illustrated-arcade .app[data-game] :is(.bet-dock-cta-btn,.hand-next):active:not(:disabled)::before,
  .illustrated-arcade .room:active:not(:disabled) .chalet-window,
  .illustrated-arcade .dice-side-pick:active:not(:disabled) .dice-side-symbol {
    transform: translateY(2px) scale(.88);
  }
  .illustrated-arcade .app[data-game] button.bet-dock-cta-btn[aria-busy="true"]::before { animation: paper-lift .48s ease-in-out 2 alternate; }
  .illustrated-arcade :is(.cashout-receipt__check,.hand-seal,.vault-receipt-art,.snow-report-window,.landing-slip) {
    animation: paper-land .26s cubic-bezier(.18,.86,.32,1) both;
  }
  @keyframes paper-lift { to { transform: translateY(-2px) rotate(-8deg); } }
  @keyframes paper-land { from { transform: translateY(3px) scale(.92); } }
}
@media (max-width: 350px) {
  .illustrated-arcade .app[data-game] .bet-dock-tier-cta button.bet-dock-cta-btn { gap: 3px; letter-spacing: 0; }
  .illustrated-arcade .app[data-game] button:is(.hilo-pick-higher,.hilo-pick-lower)::before { width: 17px; }
}
