/* Sonbahis identity. Supplied transparent artwork is displayed without modification. */
:root {
  color-scheme: dark;
  --cream: #031c2c;
  --paper: #fffaf0;
  --ink: #f0f4f6;
  --muted: #9ab0bd;
  --green: #17384b;
  --green-dark: #061622;
  --rust: #ddc382;
  --yellow: #e5cb88;
  --line: #ffffff17;
  --gold: #ddc382;
  --gold-soft: #a78e54;
  --navy-panel: #092a3d;
  --sans: 'Cinzel Numbers', 'Segoe UI', Arial, sans-serif;
}

html { scroll-padding-top: 18px; }
body {
  background-color: var(--cream);
  background-image: radial-gradient(ellipse at 70% 0, #16435755, transparent 56%),
    radial-gradient(circle at 1px 1px, #d9bd7824 .7px, transparent 1px);
  background-size: auto, 74px 74px;
  font-size: 15px;
}
body::before { opacity: .018; }
button, a, select { outline-offset: 5px; }
button:focus-visible, a:focus-visible, select:focus-visible {
  outline: 3px solid #f4d67f;
  box-shadow: 0 0 0 5px #031c2c;
}
.app-shell { max-width: 1360px; padding: 0 56px; }
.site-header { height: 104px; border-bottom-color: #c7ad6833; gap: 24px; }
.brand { gap: 17px; letter-spacing: 0; }
.brand-logo { position: relative; width: 228px; aspect-ratio: 360 / 76; overflow: hidden; display: block; flex-shrink: 0; }
.brand-logo img { display: block; position: absolute; width: 100%; max-width: 100%; height: auto; left: 0; top: 50%; transform: translateY(-50%); }
.brand-game { font: 600 10px var(--sans); letter-spacing: 2.6px; color: var(--gold); border-left: 1px solid #d5bc7644; padding: 11px 0 11px 17px; }
.header-caption { margin-left: 0; color: #a1b4bf; font-size: 10px; letter-spacing: 2.2px; }
.header-actions { gap: 12px; }
.header-divider { background: #ffffff20; }
.icon-button { min-width: 44px; min-height: 44px; width: 44px; height: 44px; color: #c2cfd6; }
.icon-button:hover { background: #ffffff0b; color: var(--gold); }
.help-button { min-height: 44px; font-size: 12px; gap: 9px; color: #c2cfd6; }
.help-button:hover { color: var(--gold); }
.intro-row { padding: 44px 0 35px; }
.eyebrow { color: #b3c5ce; font-size: 11px; letter-spacing: 2px; }
.tiny-star { color: var(--gold); }
h1 { font-size: clamp(46px, 4.5vw, 66px); line-height: 1.08; letter-spacing: -2.1px; margin: 18px 0; }
h1 em, h2 em { color: var(--gold); }
.intro-copy { color: #9fb2bf; font-size: 14px; line-height: 1.85; }
.intro-aside { margin-right: 52px; transform: rotate(8deg); }
.lucky-seal { width: 114px; height: 114px; background: #b79c4510; border-color: #c1a96c80; outline-color: #c1a96c70; color: var(--gold); box-shadow: 0 0 40px #b5a66e0a; }
.lucky-seal strong { font-size: 45px; }
.lucky-seal span { font-size: 10px; }
.handwriting { color: #bcaa80; }
.hand-arrow { stroke: #bca66e; }
.felt { background-color: #0a2c40; background-image: radial-gradient(ellipse at 50% 0, #1b4c6259, transparent 70%), linear-gradient(115deg, #082337, #0c3043 50%, #082437); color: #f1eee3; }
.selection-table { border: 1px solid #bba15e42; border-radius: 16px; padding: 28px 37px 24px; box-shadow: inset 0 0 70px #00142244, 0 8px 0 -4px #011321, 0 20px 55px #00000029; }
.selection-table::after { inset: 10px; border-color: #c9b57d25; border-radius: 9px; }
.table-corner { border-color: #d4ba7066; }
.table-label { font-size: 10px; letter-spacing: 1.6px; color: #d7c99f; }
.status-dot { background: var(--gold); box-shadow: 0 0 0 4px #ddc38212; }
.table-small { font-size: 10px; letter-spacing: 1.8px; color: #8fa9b8; }
.card-deck { height: 274px; gap: clamp(18px, 2.3vw, 34px); padding-top: 8px; }
.pick-card { width: clamp(120px, 10.2vw, 148px); height: auto; aspect-ratio: 142 / 199; filter: drop-shadow(0 15px 12px #000e1a99); }
.pick-card:not(:disabled):hover, .pick-card:not(:disabled):focus-visible { filter: drop-shadow(0 15px 15px #000e1abf); }
.card-back { border: 5px solid #d9c488; background-color: #0b2435; background-image: repeating-linear-gradient(45deg, transparent, transparent 7px, #d2ba7526 7px, #d2ba7526 8px), repeating-linear-gradient(-45deg, transparent, transparent 7px, #d2ba7520 7px, #d2ba7520 8px); box-shadow: inset 0 0 0 2px #17364a, inset 0 0 0 3px #b59c5e; }
.card-back::before { border-color: #d1b97888; }
.card-back::after, .card-back .back-corner { color: #e1cb90; }
.card-medallion { width: 84px; height: 118px; background: radial-gradient(ellipse, #123c50, #082536); border-color: #c1a96b; outline-color: #c7ad6666; color: #e6ce8f; gap: 8px; }
.card-medallion strong { font: 38px 'Cinzel Numbers', Georgia, serif; font-style: normal; text-shadow: 0 2px 12px #d6bc5033; }
.card-medallion small { font-size: 8px; font-weight: 700; letter-spacing: 1.1px; }
.card-medallion small:last-child { font-size: 7px; font-weight: 400; letter-spacing: 2px; }
.card-medallion::before, .card-medallion::after { font-size: 10px; }
.card-choice-index { color: #bca86d; font-size: 10px; }
.table-note { color: #b6c5ce; font-size: 14px; }
.table-shuffle { min-height: 44px; padding: 8px 6px; color: #dfc98b; font-size: 12px; }
.table-shuffle svg { width: 17px; height: 17px; }
.table-shuffle:hover:not(:disabled) { color: #fff0c9; }
.primary-button { min-height: 48px; background: linear-gradient(115deg, #ecd69b, #d5b76d); border: 1px solid #ecd8a0; color: #132a39; box-shadow: 0 2px 0 #0c1b2377, inset 0 1px #fff4cc88; border-radius: 8px; font-size: 14px; }
.primary-button:hover:not(:disabled) { background: linear-gradient(115deg, #f5e3b3, #e6c982); box-shadow: 0 6px 22px #b99d3b19; }
.primary-button:disabled { opacity: .65; }
.quiet-button { color: #b3c4ce; font-size: 13px; min-height: 44px; padding: 8px 10px; border-radius: 7px; }
.quiet-button:hover { color: #f2dba3; background: #ffffff08; }
.selection-bottom { padding: 30px 0 38px; gap: 18px; }
.step-indicator { gap: 16px; }
.step { color: #8ca3b1; font-size: 10px; letter-spacing: .7px; }
.step b { width: 27px; height: 27px; border-color: #829cac40; font-size: 10px; }
.step.active { color: #ead59a; }
.step.active b { background: #d9bd79; border-color: #d9bd79; color: #082334; }
.step-line { background: #7e929b40; width: 28px; }
.selection-hint { font-size: 12px; color: #a2b6c1; }
.small-dot { background: #cfb66f; }
.resume-banner { background: #113247; border-color: #cfb77140; font-size: 13px; gap: 20px; }
.resume-banner button { color: #e3cc8d; min-height: 44px; padding: 8px; }
.reveal-area { padding: 26px 0 20px; gap: 22px; }
.reveal-area .tombala-ticket { border-color: #d6c58d; width: min(600px, 100%); }
.reveal-actions { gap: 16px; }
.reveal-actions .primary-button { font-size: 13px; min-height: 46px; }
.reveal-actions .quiet-button { font-size: 12px; }
.site-footer { border-color: #c7ad6826; padding: 25px 0 30px; color: #91a9b8; font-size: 11px; gap: 16px; }
.site-footer strong { font-size: 10px; letter-spacing: 1px; color: #d5c18b; font-weight: 650; }

/* The playing surface stays light so the real yellow ink is easy to see. */
.game-heading { padding: 32px 0 26px; }
.game-heading h1 { color: #eef2f4; font-size: 44px; margin-top: 12px; }
.game-layout { grid-template-columns: 296px minmax(0, 1fr); gap: 32px; align-items: start; }
.draw-panel { padding: 23px; border: 1px solid #b79b5f3b; border-radius: 14px; box-shadow: 0 14px 35px #00101b2b; }
.draw-topline .table-label { font-size: 9px; letter-spacing: 1.2px; }
.draw-topline > span:last-child { font-size: 11px; color: #9bb3c3; }
.draw-eyebrow { font-size: 10px; color: #d2bd83; margin-top: 25px; letter-spacing: 2px; }
.ball-orbit { margin: 17px auto 14px; }
.ball-orbit::before { border-color: #d2b97d2e; }
.orbit-spark { color: var(--gold); }
.number-ball { background: radial-gradient(circle at 35% 25%, #fffdf2 0, #f1e7c9 58%, #d0bd81 85%, #a88b42 100%); color: #123348; box-shadow: inset -6px -8px 16px #8c754533, inset 4px 4px 10px #fff8d9, 7px 16px 19px #00111c80; }
.number-ball::before { border-color: #9d884338; }
.ball-word { color: #8d7845; }
.draw-message { color: #c1d0d9; font-size: 12px; line-height: 1.65; min-height: 20px; margin: 12px 0 18px; }
.draw-button { min-height: 48px; font-size: 13px; }
.autoplay-control { gap: 10px; margin-top: 12px; }
.auto-toggle { color: #bdcfd9; min-height: 44px; font-size: 11px; gap: 9px; }
.switch-track { flex-shrink: 0; width: 30px; height: 18px; padding: 3px; border: none; background: #809aa944; }
.switch-track span { width: 12px; height: 12px; background: #b9c8d2; }
.auto-toggle[aria-pressed=true] .switch-track { background: #ddc382; }
.auto-toggle[aria-pressed=true] .switch-track span { background: #173347; transform: translateX(12px); }
#draw-speed { background: #082334; color: #d6e0e6; border-color: #a7bdcb40; border-radius: 6px; min-width: 59px; min-height: 44px; padding: 7px; font-size: 12px; }
#draw-speed option { background: #082334; color: #edf2f4; }
.recent-draws { border-color: #c2b07126; padding-top: 17px; margin-top: 16px; }
.recent-draws > span { color: #92acbd; font-size: 9px; letter-spacing: 1.6px; }
.recent-draws > div { gap: 8px; margin-top: 12px; }
.recent-number { color: #c8d7e0; border-color: #a2b9ca40; width: 30px; height: 30px; }
.recent-number:first-child { background: #e3cc8c; color: #143044; border-color: #e3cc8c; }
.recent-empty { color: #9db4c1; }
.player-panel { padding-top: 5px; }
.player-topline { padding: 0 2px 17px; }
.player-topline .eyebrow { font-size: 10px; color: #b7c8d1; }
.card-serial { color: #a2b8c6; font-size: 11px; }
.ticket-wrap { padding: 5px 0; }
.ticket-wrap::before { background: #a28d59; border-color: #d4bd7e; transform: rotate(-1.1deg); }
.tombala-ticket { background: #faf8ed; border: 1px solid #cabb8f; border-radius: 7px; transform: rotate(.35deg); color: #17384b; box-shadow: 0 12px 25px #00111c35; overflow: hidden; }
.ticket-header { background: #122e40; color: #e5d3a5; padding: 17px 20px; margin-bottom: 18px; min-height: 53px; }
.ticket-brand { font: 800 13px var(--sans); letter-spacing: .5px; white-space: nowrap; }
.ticket-brand span { color: #cdb57a; font-weight: 500; font-size: 10px; letter-spacing: 1px; }
.ticket-motto { color: #9ab1be; font-size: 8px; letter-spacing: 1.2px; }
.ticket-star { color: #d9bf7d; font-size: 22px; }
.ticket-grid { margin: 0 20px; border-color: #b1b8ae; background: #fffdf4; }
.ticket-cell { color: #12364a; border-color: #b1b8ae; font-size: 34px; height: 69px; }
.ticket-cell.empty { background-color: #e8e9de; background-image: repeating-linear-gradient(45deg, transparent 0, transparent 3px, #5c758510 3px, #5c758510 4px); }
.ticket-cell.empty::after { color: #83948a55; }
.ticket-cell[data-number]:not(.marked):hover { background: #eee7cd; }
.ticket-cell.available:not(.marked) { color: #91630b; }
.ticket-cell.available:not(.marked)::after { background: #aa780d; width: 5px; height: 5px; bottom: 7px; }
.ticket-cell.marked::before { background: #e6ef33c9; }
.ticket-cell:focus-visible { box-shadow: inset 0 0 0 3px #163f56; outline: none; }
.ticket-footer { color: #737f79; padding: 15px 20px; font-size: 9px; letter-spacing: .7px; }
.marker-hint { padding: 20px 2px; gap: 12px; }
.marker-icon { background: #d9c57519; color: #dac274; width: 38px; height: 38px; }
.marker-hint p { color: #b4c7d2; font-size: 12px; line-height: 1.75; }
.marker-hint strong { color: #ead6a2; }
.marker-hint p span { color: #91acbd; font-size: 11px; }
.marked-count { color: #91a9b7; font-size: 12px; }
.marked-count strong { color: #e6cf92; font-size: 25px; }
.achievement-track { gap: 12px; padding: 19px 0; border-color: #d0be7a22; }
.achievement { gap: 9px; }
.achievement-icon { width: 32px; height: 32px; border-color: #9cb2bc40; color: #a5bac5; }
.achievement strong { color: #c2d0d6; font-size: 11px; }
.achievement > div > span { color: #8ba5b7; font-size: 10px; }
.achievement.complete .achievement-icon { background: #dcc384; border-color: #dcc384; color: #0b2a3d; }
.achievement.complete strong { color: #e9d69f; }
.card-status { color: #b9ac85; font-size: 13px; margin-top: 19px; }
.number-board-section { margin: 32px 0 38px; }
.board-heading h2 { color: #edf2f5; font-size: 25px; }
.board-heading > div > span { color: #93acbb; font-size: 11px; }
.board-legend { gap: 16px; }
.board-legend i { background: #0c2b3e; border-color: #8194a132; width: 8px; height: 8px; }
.board-legend .drawn-legend { background: #d4bb7c; border-color: #d4bb7c; }
.board-legend .marked-legend { background: #dce945; border-color: #dce945; }
.number-board { gap: 7px; }
.board-number { background: #092639; color: #8ca9bb; border-color: #44617549; height: 34px; font-size: 12px; }
.board-number.drawn { color: #142f40; border-color: #d9c184; background: #d9c184; font-weight: 600; }
.board-number.marked { color: #1f3e3a; background: #e2eb57; border-color: #e2eb57; }
.board-number.latest { outline-color: #0b2a3d; box-shadow: 0 0 0 2px #f5e4b7; }
.modal { background: #092638; border-color: #c8ad6655; color: #edf3f6; width: 500px; padding: 38px; box-shadow: 0 20px 100px #000a13aa; }
.modal::backdrop { background: #000e1ccb; }
.modal .eyebrow { color: #b5c5ce; font-size: 10px; }
.modal-close { color: #b6c9d4; top: 10px; right: 10px; }
.modal h2 { color: #edf2f4; }
.rules strong { font-size: 14px; color: #e1d1a4; }
.rules p, .small-modal > p, .win-modal p { color: #b3c4cf; font-size: 13px; line-height: 1.8; }
.rules li > b { color: #dbc17d; }
.small-modal { width: 450px; }
.win-modal { width: 450px; }
.toast { background: #102f42; border: 1px solid #ddc3826b; color: #f3ead6; border-radius: 9px; bottom: max(24px, env(safe-area-inset-bottom)); box-shadow: 0 8px 30px #000a1466; }
.animated-marker { filter: drop-shadow(8px 12px 5px #0a192755); }

@media (max-width: 1100px) {
  .app-shell { padding: 0 36px; }
  .header-caption { display: none; }
  .brand-logo { width: 220px; }
  .game-layout { grid-template-columns: 260px minmax(0, 1fr); gap: 24px; }
  .draw-panel { padding: 21px 18px; }
  .card-deck { gap: 20px; height: 258px; }
  .pick-card { width: 125px; }
  .ticket-grid { margin: 0 14px; }
  .ticket-header { padding: 14px; margin-bottom: 14px; }
  .ticket-footer { padding: 12px 14px; font-size: 8px; }
  .ticket-cell { height: 63px; font-size: 30px; }
  .ticket-motto { display: none; }
  .achievement-track { gap: 7px; }
  .achievement { gap: 6px; }
  .achievement-icon { height: 28px; width: 28px; }
  .achievement strong { font-size: 10px; }
  .achievement > div > span { font-size: 9px; }
  .selection-bottom { flex-wrap: wrap; row-gap: 20px; }
  .step { font-size: 9px; }
  .selection-hint { font-size: 11px; }
}

@media (min-width: 761px) and (max-width: 900px) {
  .app-shell { padding: 0 26px; }
  .card-deck { gap: 17px; }
  .pick-card { width: min(112px, 15.5%); }
  .card-medallion { width: 65px; height: 98px; }
  .card-medallion strong { font-size: 29px; }
  .card-medallion small { font-size: 7px; }
  .card-medallion small:last-child { font-size: 6px; }
  .game-layout { grid-template-columns: 234px minmax(0, 1fr); gap: 20px; }
  .auto-toggle { font-size: 10px; gap: 5px; }
  #draw-speed { min-width: 54px; font-size: 11px; }
  .achievement { flex-direction: column; text-align: center; gap: 8px; }
  .ticket-cell { height: 61px; font-size: 27px; }
  .ticket-grid { margin: 0 11px; }
  .ticket-footer { padding-inline: 11px; font-size: 7px; }
  .marker-hint { gap: 8px; }
  .marker-hint p { font-size: 11px; }
  .marker-hint p span { font-size: 10px; }
}

/* Full, separate cards and five wide number targets on phones and small tablets. */
@media (max-width: 760px) {
  html { scroll-padding-top: 12px; }
  .app-shell { padding: 0 20px; }
  .site-header { height: 78px; gap: 8px; }
  .brand { gap: 0; }
  .brand-logo { width: 197px; }
  .brand-game, .header-caption, .header-divider { display: none; }
  .header-actions { gap: 5px; }
  .header-actions .icon-button, .help-button { width: 44px; height: 44px; min-width: 44px; min-height: 44px; padding: 10px; justify-content: center; border: 1px solid #a9becb24; border-radius: 9px; }
  .help-button span { display: none; }
  .help-button svg { width: 20px; height: 20px; }
  .intro-row { padding: 29px 0 27px; align-items: center; gap: 15px; }
  .eyebrow { font-size: 10px; letter-spacing: 1.45px; gap: 8px; }
  .tiny-star { font-size: 19px; }
  h1 { font-size: clamp(40px, 7.5vw, 52px); margin: 17px 0 14px; letter-spacing: -1.6px; line-height: 1.05; }
  .intro-copy { font-size: 12px; line-height: 1.8; }
  .intro-aside { margin: 0 13px 0 0; padding: 0; }
  .lucky-seal { width: 76px; height: 76px; outline-offset: 4px; }
  .lucky-seal strong { font-size: 32px; }
  .lucky-seal span { font-size: 7px; letter-spacing: 1.7px; }
  .handwriting, .hand-arrow { display: none; }
  .selection-table { min-height: 0; padding: 23px 22px 16px; border-radius: 13px; }
  .table-label { font-size: 10px; letter-spacing: 1px; }
  .table-small { display: none; }
  .card-deck { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-template-rows: auto auto; gap: 18px 17px; height: auto; max-width: 368px; width: 100%; margin: 27px auto 22px; padding: 0; }
  .pick-card { position: relative; grid-column: span 2; left: auto; top: auto; width: 100%; height: auto; aspect-ratio: 110 / 148; margin: 0; transform: rotate(var(--mobile-angle, 0deg)); filter: drop-shadow(0 7px 7px #00101c99); }
  .pick-card:nth-child(1) { --mobile-angle: -4deg; z-index: 1; }
  .pick-card:nth-child(2) { --mobile-angle: 0deg; z-index: 2; }
  .pick-card:nth-child(3) { --mobile-angle: 4deg; z-index: 3; }
  .pick-card:nth-child(4) { --mobile-angle: -3deg; grid-column: 2 / span 2; z-index: 4; }
  .pick-card:nth-child(5) { --mobile-angle: 3deg; grid-column: 4 / span 2; z-index: 5; }
  .pick-card:not(:disabled):hover, .pick-card:not(:disabled):focus-visible { transform: translateY(-5px) rotate(0deg); z-index: 6; }
  .card-back { border-width: 4px; border-radius: 6px; }
  .card-back::before { inset: 5px; }
  .card-back::after { left: 8px; top: 6px; font-size: 13px; }
  .card-back .back-corner { right: 8px; bottom: 6px; font-size: 13px; }
  .card-medallion { width: 62%; height: 71%; gap: 5px; outline-offset: 3px; }
  .card-medallion strong { font-size: clamp(25px, 6vw, 32px); }
  .card-medallion small { font-size: 7px; letter-spacing: .6px; }
  .card-medallion small:last-child { font-size: 6px; letter-spacing: 1.3px; }
  .card-medallion::before, .card-medallion::after { font-size: 8px; }
  .card-choice-index { display: none; }
  .card-deck.shuffling .pick-card { animation-name: shuffle-grid; }
  .pick-card.chosen { animation-name: choose-grid; }
  .card-deck.picking .pick-card:not(.chosen) { transform: translateY(15px) scale(.85); }
  .table-bottomline { gap: 10px; }
  .table-note { font-size: 12px; max-width: 160px; line-height: 1.5; }
  .table-shuffle { font-size: 11px; min-height: 44px; padding: 8px 0; gap: 6px; white-space: nowrap; }
  .table-shuffle svg { width: 16px; height: 16px; }
  .selection-bottom { padding: 25px 0 28px; align-items: center; flex-direction: column; gap: 17px; }
  .step-indicator { width: 100%; justify-content: space-between; gap: 9px; }
  .step { font-size: 10px; letter-spacing: .35px; gap: 7px; }
  .step b { width: 25px; height: 25px; font-size: 10px; }
  .step-line { width: 18px; }
  .selection-hint { font-size: 11px; }
  .reveal-area { padding: 24px 0 17px; gap: 21px; }
  .reveal-area .ticket-header { margin-bottom: 11px; padding: 13px 11px; }
  .reveal-area .ticket-grid { margin: 0 11px; }
  .reveal-area .ticket-cell { height: 45px; font-size: 25px; }
  .reveal-area .ticket-footer { padding: 12px 11px; font-size: 8px; }
  .reveal-actions { width: 100%; justify-content: space-between; gap: 8px; }
  .reveal-actions .primary-button { font-size: 12px; padding: 12px 16px; gap: 10px; }
  .reveal-actions .quiet-button { font-size: 11px; padding: 8px 2px; }
  .resume-banner { flex-wrap: wrap; justify-content: center; padding: 14px; gap: 4px; font-size: 12px; }
  .resume-banner button { font-size: 12px; }
  .game-heading { padding: 24px 0 21px; align-items: flex-end; gap: 8px; }
  .game-heading .eyebrow { font-size: 10px; }
  .game-heading h1 { font-size: clamp(31px, 6.3vw, 42px); letter-spacing: -1.2px; margin-top: 10px; }
  .game-heading .quiet-button { font-size: 11px; min-height: 44px; padding: 8px 0 8px 7px; gap: 5px; white-space: nowrap; }
  .game-layout { display: flex; flex-direction: column; gap: 23px; }
  .draw-panel { width: 100%; padding: 17px 20px 13px; display: grid; grid-template-columns: 116px minmax(0, 1fr); grid-template-rows: auto auto auto auto auto; column-gap: 20px; }
  .draw-topline { grid-column: 1 / -1; margin-bottom: 12px; }
  .draw-topline .table-label { font-size: 10px; }
  .draw-topline > span:last-child { font-size: 11px; }
  .draw-eyebrow { grid-column: 2; grid-row: 2; margin: 0 0 4px; text-align: left; font-size: 9px; }
  .ball-orbit { grid-column: 1; grid-row: 2 / 5; margin: 2px 0 0; width: 116px; height: 116px; align-self: start; }
  .number-ball { width: 106px; height: 106px; }
  .number-ball #current-number { font-size: 55px; }
  .number-ball::before { inset: 11px; }
  .ball-word { font-size: 11px; }
  .ball-orbit::before { inset: 7px -3px; }
  .spark-one { left: -4px; top: 0; font-size: 17px; }
  .spark-two { right: -1px; bottom: 13px; font-size: 12px; }
  .draw-message { grid-column: 2; grid-row: 3; align-self: start; text-align: left; margin: 0 0 8px; min-height: 32px; line-height: 1.4; font-size: 11px; }
  .draw-button { grid-column: 2; grid-row: 4; margin: 0; align-self: start; padding: 10px 12px; min-height: 44px; gap: 6px; font-size: 12px; }
  .draw-button svg { width: 17px; height: 17px; }
  .autoplay-control { grid-column: 1 / -1; grid-row: 5; margin: 8px 0 0; padding-top: 5px; border-top: 1px solid #c3ac7022; gap: 14px; }
  .auto-toggle { min-height: 44px; font-size: 12px; gap: 9px; }
  .switch-track { width: 30px; height: 18px; padding: 3px; }
  .switch-track span { width: 12px; height: 12px; }
  .auto-toggle[aria-pressed=true] .switch-track span { transform: translateX(12px); }
  #draw-speed { min-height: 44px; min-width: 67px; max-width: none; padding: 8px; font-size: 12px; }
  .recent-draws { grid-column: 1 / -1; grid-row: 6; display: flex; align-items: center; gap: 14px; margin-top: 7px; padding-top: 12px; }
  .recent-draws > span { font-size: 9px; letter-spacing: .9px; white-space: nowrap; }
  .recent-draws > div { margin: 0; min-height: 27px; gap: 7px; flex-wrap: wrap; }
  .recent-number { width: 27px; height: 27px; font-size: 13px; }
  .recent-empty { font-size: 11px; }
  .player-panel { width: 100%; padding: 0; }
  .player-topline { padding: 0 2px 13px; }
  .player-topline .eyebrow { font-size: 10px; letter-spacing: 1.1px; }
  .card-serial { font-size: 10px; }
  .ticket-wrap { padding: 5px 0; }
  .tombala-ticket { transform: none; border-radius: 7px; }
  .ticket-wrap::before { transform: rotate(-.8deg); }
  .ticket-header { padding: 14px; margin-bottom: 14px; min-height: 49px; }
  .ticket-brand { font-size: 13px; letter-spacing: .3px; }
  .ticket-brand span { font-size: 10px; }
  .ticket-motto { display: none; }
  .ticket-star { font-size: 21px; }
  .ticket-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 0 14px; }
  .ticket-cell.empty { display: none; }
  .ticket-cell { height: clamp(48px, 13vw, 61px); font-size: 30px; }
  .ticket-cell.available:not(.marked)::after { bottom: 5px; }
  .ticket-footer { padding: 13px 14px; font-size: 9px; letter-spacing: .3px; }
  .ticket-footer span:last-child { display: none; }
  .marker-hint { padding: 16px 1px; gap: 10px; }
  .marker-icon { width: 34px; height: 34px; }
  .marker-hint p { font-size: 12px; }
  .marker-hint p span { font-size: 11px; }
  .marked-count { font-size: 12px; }
  .marked-count strong { font-size: 25px; }
  .achievement-track { gap: 9px; padding: 17px 0; }
  .achievement { flex-direction: column; text-align: center; gap: 8px; }
  .achievement-icon { height: 30px; width: 30px; }
  .achievement strong { font-size: 11px; }
  .achievement > div > span { font-size: 10px; line-height: 1.4; }
  .card-status { font-size: 13px; line-height: 1.6; margin-top: 17px; }
  .number-board-section { margin: 28px 0 31px; }
  .board-heading { flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 17px; }
  .board-heading > div:first-child { display: block; }
  .board-heading h2 { font-size: 25px; }
  .board-heading > div:first-child > span { display: block; font-size: 11px; margin-top: 5px; }
  .board-legend { gap: 13px; }
  .board-legend > span { font-size: 10px !important; gap: 5px; }
  .board-legend i { height: 7px; width: 7px; }
  .number-board { grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; }
  .board-number { height: 31px; font-size: 12px; }
  .site-footer { font-size: 10px; flex-wrap: wrap; gap: 11px; padding: 20px 0 max(24px, env(safe-area-inset-bottom)); }
  .site-footer > span:first-child { max-width: none; }
  .site-footer strong { font-size: 10px; }
  .site-footer > span:last-child { gap: 6px; }
  .modal { padding: 38px 25px 26px; max-width: calc(100% - 24px); max-height: calc(100dvh - 28px); }
  .modal h2 { font-size: 32px; }
  .modal .eyebrow { font-size: 10px; }
  .rules li { gap: 13px; }
  .rules p { font-size: 13px; }
  .rules strong { font-size: 14px; }
  .modal-actions { gap: 14px; }
  .modal-actions .primary-button { padding-inline: 17px; }
  .win-modal h2 { font-size: 59px; }
  .toast { padding: 13px 16px; font-size: 12px; line-height: 1.55; bottom: max(20px, env(safe-area-inset-bottom)); }
  .animated-marker { width: 42px; height: 147px; }
}

@media (max-width: 480px) {
  .intro-aside { margin-right: 5px; }
  .lucky-seal { width: 63px; height: 63px; }
  .lucky-seal strong { font-size: 27px; }
  .lucky-seal span { font-size: 6px; letter-spacing: 1.2px; }
  .card-deck { max-width: 300px; gap: 15px 13px; margin-top: 24px; margin-bottom: 18px; }
  .selection-table { padding-inline: 20px; }
  .step-indicator { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
  .step { flex-direction: column; text-align: center; gap: 7px; font-size: 9px; letter-spacing: .3px; }
  .step-line { display: none; }
  .brand-logo { width: 188px; }
  .recent-draws { gap: 10px; }
  .recent-draws > span { font-size: 8px; letter-spacing: .55px; }
  .recent-draws > div { gap: 6px; }
}

@media (max-width: 374px) {
  .app-shell { padding: 0 16px; }
  .site-header { height: 72px; }
  .brand-logo { width: 164px; }
  .header-actions { gap: 4px; }
  .intro-row { padding: 25px 0; gap: 10px; }
  .intro-row .eyebrow { font-size: 9px; letter-spacing: 1px; }
  .intro-row h1 { font-size: 39px; }
  .intro-copy { font-size: 11px; }
  .intro-aside { display: none; }
  .selection-table { padding: 22px 17px 14px; }
  .card-deck { gap: 13px 13px; }
  .table-label { font-size: 9px; }
  .table-note { font-size: 11px; max-width: 120px; }
  .table-shuffle { font-size: 10px; gap: 5px; }
  .card-medallion small { font-size: 6px; }
  .card-medallion small:last-child { font-size: 5px; }
  .card-medallion strong { font-size: 25px; }
  .card-medallion { gap: 3px; }
  .card-medallion::before, .card-medallion::after { display: none; }
  .game-heading { padding: 21px 0 18px; }
  .game-heading h1 { font-size: 29px; }
  .game-heading .quiet-button { font-size: 10px; }
  .draw-panel { padding: 15px 15px 13px; grid-template-columns: 100px minmax(0, 1fr); column-gap: 14px; }
  .ball-orbit { width: 100px; height: 110px; }
  .number-ball { width: 96px; height: 96px; }
  .number-ball #current-number { font-size: 50px; }
  .draw-topline .table-label { font-size: 9px; }
  .draw-button { font-size: 11px; padding: 10px; }
  .draw-message { min-height: 33px; font-size: 10px; }
  .recent-number { width: 25px; height: 25px; font-size: 12px; }
  .recent-draws { align-items: flex-start; }
  .recent-draws > span { padding-top: 7px; }
  .recent-draws > div { gap: 5px; }
  .ticket-header { padding: 12px; margin-bottom: 12px; }
  .ticket-grid { margin: 0 12px; }
  .ticket-cell { height: 49px; font-size: 28px; }
  .ticket-footer { padding: 12px; font-size: 8px; }
  .marker-hint { gap: 7px; }
  .marker-hint p { font-size: 11px; }
  .marker-hint p span { font-size: 10px; }
  .marker-icon { width: 30px; height: 30px; }
  .achievement strong { font-size: 10px; }
  .achievement > div > span { font-size: 9px; }
  .number-board { gap: 5px; }
  .board-number { font-size: 11px; }
  .reveal-actions .primary-button { font-size: 11px; padding-inline: 12px; }
  .reveal-actions .quiet-button { font-size: 10px; }
}

@keyframes shuffle-grid {
  0% { transform: rotate(var(--mobile-angle)); }
  24% { transform: translate(var(--stack-x), var(--stack-y)) rotate(-6deg); }
  43% { transform: translate(calc(var(--stack-x) + var(--shuffle-x) * .65), calc(var(--stack-y) - 14px)) rotate(var(--shuffle-angle)); }
  66% { transform: translate(var(--stack-x), var(--stack-y)) rotate(6deg); }
  100% { transform: rotate(var(--mobile-angle)); }
}
@keyframes choose-grid { to { transform: translate(var(--stack-x), var(--stack-y)) rotateY(90deg) scale(1.05); } }

@media (prefers-reduced-motion: reduce) {
  .card-deck.shuffling .pick-card { animation: none; }
}

/* Keep the game clear of camera cutouts in landscape. */
.app-shell {
  padding-left: max(var(--edge-space, 56px), env(safe-area-inset-left));
  padding-right: max(var(--edge-space, 56px), env(safe-area-inset-right));
}
@media (max-width: 1100px) { :root { --edge-space: 36px; } }
@media (min-width: 761px) and (max-width: 900px) { :root { --edge-space: 26px; } }
@media (max-width: 760px) { :root { --edge-space: 20px; } }
@media (max-width: 374px) { :root { --edge-space: 16px; } }

/* User-supplied mobile and desktop artwork; picture loads only the matching asset. */
body {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  background: #031321;
}
.scene-background {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.scene-background picture,
.scene-background img {
  display: block;
  width: 100%;
  height: 100%;
}
.scene-background img {
  object-fit: cover;
  object-position: center center;
}
.scene-background::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #020e1dcc, #031a2c38 55%, #020e1d70),
    linear-gradient(0deg, #020c19b3, #020c191f 55%, #020c1940);
}
.intro-row, .game-heading, .site-header, .selection-bottom, .site-footer {
  text-shadow: 0 2px 14px #000d;
}
.intro-copy, .header-caption, .selection-hint, .site-footer { color: #c0ced7; }
.felt {
  background: linear-gradient(115deg, #041627ed, #0b2c3fe0 50%, #041627ed);
}
.player-panel, .number-board-section {
  position: relative;
  isolation: isolate;
}
.player-panel::before, .number-board-section::before {
  content: '';
  position: absolute;
  inset: -12px;
  z-index: -1;
  pointer-events: none;
  border: 1px solid #d5bc7629;
  border-radius: 14px;
  background: #041726e8;
}
@media (max-width: 760px) {
  .scene-background::after {
    background: linear-gradient(180deg, #020c195e, #020c196b 42%, #020c19a6);
  }
  .intro-row { text-shadow: 0 2px 12px #000, 0 0 24px #0009; }
  .player-panel::before, .number-board-section::before { inset: -10px; }
}

/* Compact layout after removing the annotated decorative text. */
.site-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
}
.site-header > .brand { justify-self: start; }
.site-header > .brand-game { border: 0; padding: 0; text-align: center; }
.site-header > .header-actions { justify-self: end; }
.selection-table .table-topline { justify-content: center; }
.table-bottomline { justify-content: flex-end; }
.intro-row h1 { margin-top: 0; }
.game-heading { justify-content: flex-end; padding: 14px 0 24px; }
@media (max-width: 760px) {
  .site-header { display: flex; justify-content: space-between; }
  .game-heading { padding: 10px 0 20px; }
}

/* Christmas: warm lights, evergreen details and quiet snow over the supplied artwork. */
.christmas-theme .app-shell { position: relative; z-index: 1; }
.christmas-theme .site-header { position: relative; }
.holiday-lights {
  position: absolute; left: 0; right: 0; bottom: -9px; height: 18px;
  display: flex; justify-content: space-between; align-items: flex-start;
  pointer-events: none; border-top: 1px solid #a1874b80;
}
.holiday-lights i {
  display: block; position: relative; width: 5px; height: 9px; margin-top: 3px;
  border-radius: 45% 45% 50% 50%; background: #ffe1a4;
  box-shadow: 0 0 7px #ffda89b3, 0 0 16px #f9bc5559;
}
.holiday-lights i::before { content: ''; position: absolute; width: 3px; height: 4px; background: #987e48; left: 1px; top: -3px; }
.holiday-lights i:nth-child(3n) { background: #d48b78; box-shadow: 0 0 8px #c9836277; }
.holiday-lights i:nth-child(2n) { margin-top: 7px; }
.holiday-lights i:nth-child(2n)::before { height: 8px; top: -7px; }
.holiday-sprig { position: absolute; top: 3px; width: 180px; height: 90px; pointer-events: none; stroke: none; z-index: 1; }
.sprig-left { left: 0; }
.sprig-right { right: 0; transform: scaleX(-1); }
.christmas-theme .selection-table { border-top-color: #d8bd7b99; }
.christmas-theme .card-back { border-color: #ddc68e; }
.christmas-theme .card-medallion { background: radial-gradient(ellipse at 50% 25%, #24504a, #082536 80%); }
.card-medallion strong { line-height: 0; }
.holiday-tree { width: 40px; height: 48px; stroke: none; }
.ticket-star .holiday-tree { width: 25px; height: 31px; display: block; }
.christmas-theme .ticket-header {
  background: linear-gradient(110deg, #123b3a, #092638 65%);
  border-bottom: 2px solid #bd9b54;
}
.christmas-theme .number-ball::after {
  content: ''; position: absolute; width: 24px; height: 13px; top: -6px; left: calc(50% - 12px);
  border: 1px solid #ebd49b; border-radius: 3px 3px 2px 2px;
  background: repeating-linear-gradient(90deg, #9d7c39 0 3px, #dfc581 3px 5px);
  box-shadow: 0 -6px 0 -3px #d8ba75;
}
.christmas-theme .lucky-seal { border: 5px double #9b9b62; outline: 2px dotted #bda974; background: #10383380; }
.holiday-toggle {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 12px;
  border: 1px solid #c3aa6a55; border-radius: 24px; color: #d0bc89; background: #051d2bd9;
  font-size: 12px; white-space: nowrap;
}
.holiday-toggle svg { width: 17px; height: 17px; }
.holiday-toggle[aria-pressed="true"] { color: #f3ddaa; background: #18393ed9; }
.holiday-toggle:hover:not(:disabled) { border-color: #ddc382; }
.holiday-toggle:disabled { opacity: .55; }
.christmas-theme .site-footer { align-items: center; padding-top: 14px; padding-bottom: 20px; }
.holiday-snow { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; display: none; }
.snow-enabled .holiday-snow { display: block; }
.holiday-snow i {
  position: absolute; top: -48px; left: var(--snow-x); width: var(--snow-size); height: var(--snow-size);
  background: url('/christmas-snowflake-20261121.webp') center / contain no-repeat; opacity: var(--snow-opacity, .8);
  animation: holiday-snowfall var(--snow-time) var(--snow-delay) linear infinite;
}
.snow-paused .holiday-snow i { animation-play-state: paused; }
@keyframes holiday-snowfall {
  from { transform: translate3d(0, 0, 0) rotate(var(--snow-angle)); }
  to { transform: translate3d(var(--snow-drift), calc(100vh + 96px), 0) rotate(calc(var(--snow-angle) + var(--snow-turn))); }
}
@media (max-width: 760px) {
  .holiday-sprig { width: 98px; height: 49px; top: 0; }
  .holiday-lights i:nth-child(even) { display: none; }
  .holiday-snow i { width: calc(var(--snow-size) * .82); height: calc(var(--snow-size) * .82); }
  .holiday-snow i:nth-child(n+13) { display: none; }
  .card-medallion .holiday-tree { width: 30px; height: 36px; }
  .ticket-star .holiday-tree { width: 21px; height: 25px; }
  .christmas-theme .number-ball::after { width: 18px; height: 10px; top: -4px; left: calc(50% - 9px); }
}
@media (max-width: 374px) {
  .holiday-sprig { width: 74px; height: 37px; }
  .card-medallion .holiday-tree { width: 26px; height: 31px; }
}
@media (prefers-reduced-motion: reduce) {
  .holiday-snow { display: none !important; }
  .holiday-snow i { animation: none !important; }
}

/* Image-rich Christmas table. Artwork remains decorative and clear of touch targets. */
.round-rules { padding: 12px 16px; margin: 0 0 18px; border: 1px solid #d6ba7059; border-radius: 10px; background: #071f2df5; color: #eed7a5; font-size: 13px; line-height: 1.6; }
.round-rules small { display: block; color: #c1cdd0; font-size: 12px; }
.service-notice { padding: 18px; margin-bottom: 18px; background: #3b2431; border: 1px solid #d7a66e; border-radius: 10px; color: #ffedcc; line-height: 1.6; }
.service-notice button { margin-left: 10px; min-height: 44px; padding: 8px 14px; border: 1px solid #dec181; border-radius: 8px; background: #173642; color: #f8e3b8; }
.game-heading + .round-rules { margin-bottom: 25px; }
.christmas-theme .intro-row {
  display: grid; grid-template-columns: 1fr 1.15fr; gap: 24px;
  align-items: center; padding: 22px 0 24px; min-height: 330px;
}
.christmas-theme .intro-row > div:first-child { position: relative; z-index: 1; }
.christmas-theme .intro-row h1 { font-size: clamp(44px, 4.5vw, 66px); }
.christmas-hero-art { position: relative; min-width: 0; align-self: end; }
.christmas-hero-art img {
  display: block; width: 100%; height: auto; max-height: 355px; object-fit: contain;
  filter: drop-shadow(0 14px 20px #0008);
  -webkit-mask-image: linear-gradient(0deg, transparent, #000 8% 94%, transparent);
  mask-image: linear-gradient(0deg, transparent, #000 8% 94%, transparent);
}
.christmas-theme .selection-table {
  padding-top: 154px; border: 1px solid #d7ba7888;
  background: radial-gradient(ellipse at 50% 40%, #164b47bf, transparent 70%), linear-gradient(120deg, #061c2cf5, #12362ef5, #061b2cf5);
  box-shadow: inset 0 0 0 5px #091e27, inset 0 0 0 6px #b99d5344, 0 20px 55px #0006;
}
.festive-table-trim {
  position: absolute; top: -8px; left: 0; width: 50%; height: 155px;
  object-fit: contain; object-position: center top; pointer-events: none; z-index: 1;
}
.festive-table-trim.trim-second { left: 50%; }
.christmas-theme .table-topline { position: relative; z-index: 2; }
.christmas-theme .table-label { color: #f1dfb1; }
.christmas-theme .card-deck { height: 270px; }
.christmas-theme .pick-card:nth-child(3n+1) .card-back {
  background-color: #571f2e;
  background-image: repeating-linear-gradient(45deg, transparent 0 7px, #e3bf791c 7px 8px), repeating-linear-gradient(-45deg, transparent 0 7px, #e3bf791c 7px 8px), radial-gradient(ellipse at 50% 20%, #882f41, #351526);
}
.christmas-theme .pick-card:nth-child(3n+2) .card-back {
  background-color: #164b3e;
  background-image: repeating-linear-gradient(45deg, transparent 0 7px, #e3bf7926 7px 8px), repeating-linear-gradient(-45deg, transparent 0 7px, #e3bf791c 7px 8px), radial-gradient(ellipse at 50% 20%, #2b6250, #0e2c29);
}
.christmas-theme .card-back { border-color: #e4ca8d; box-shadow: inset 0 0 0 2px #3b382e, inset 0 0 0 3px #bc9e62; }
.christmas-theme .card-medallion { background: radial-gradient(ellipse at 50% 25%, #18453eeb, #071d2cf5); box-shadow: 0 0 18px #d8b85f18; }
.christmas-theme .card-medallion .holiday-tree { width: 44px; height: 53px; }
.card-ribbon {
  position: absolute; top: 7px; left: calc(50% - 5px); width: 10px; height: 20px;
  background: linear-gradient(90deg, #8c572d, #eed18d, #af7635); border-radius: 0 0 2px 2px;
}
.card-ribbon::before, .card-ribbon::after {
  content: ''; position: absolute; top: 0; width: 20px; height: 11px;
  border: 1px solid #edce8c; background: linear-gradient(135deg, #a66f31, #f5d899 55%, #9e622d);
}
.card-ribbon::before { right: 4px; border-radius: 9px 4px 3px 9px; transform: rotate(20deg); }
.card-ribbon::after { left: 4px; border-radius: 4px 9px 9px 3px; transform: rotate(-20deg); }
.christmas-theme .primary-button { background: linear-gradient(110deg, #f8dfa3, #d3ac59); box-shadow: 0 3px 0 #86662e, inset 0 1px #fff4ca; }
.christmas-theme .game-heading { align-items: center; padding: 12px 0 20px; min-height: 100px; }
.game-festive-art { display: block; width: 150px; height: 100px; object-fit: contain; margin-right: auto; pointer-events: none; }
.christmas-theme .draw-panel { position: relative; padding-top: 78px; border-color: #bca16a88; background: linear-gradient(145deg, #1a4038f5, #071e2cf5 75%); }
.christmas-theme .draw-panel::after {
  content: ''; position: absolute; top: -20px; left: 0; right: 0; height: 85px; pointer-events: none;
  background: url('/christmas-garland-20261121.webp') center 70% / cover no-repeat;
}
.christmas-theme .ticket-header {
  position: relative; overflow: hidden;
  background: linear-gradient(105deg, #632637, #2b2632 60%, #143c38); min-height: 64px;
}
.christmas-theme .ticket-header::after {
  content: ''; position: absolute; top: -16px; right: 43px; width: 135px; height: 58px; pointer-events: none;
  background: url('/christmas-garland-20261121.webp') center / contain no-repeat;
}
.christmas-theme .ticket-brand, .christmas-theme .ticket-star { position: relative; z-index: 1; }
.christmas-theme .ticket-star .holiday-tree { width: 29px; height: 36px; }
.winner-art { display: block; width: 100%; height: 205px; object-fit: contain; margin: -10px auto 8px; }
.christmas-theme .win-modal { background: radial-gradient(ellipse at top, #214639, #071e2c 65%); border-color: #d4ba74; }
.christmas-theme .win-modal h2 { margin-top: 10px; }
@media (min-width: 761px) and (max-width: 1000px) {
  .christmas-theme .intro-row { grid-template-columns: 1fr 1fr; gap: 8px; min-height: 275px; }
  .christmas-theme .intro-row h1 { font-size: 46px; }
  .christmas-theme .intro-copy { font-size: 13px; }
  .christmas-theme .selection-table { padding-top: 122px; }
  .festive-table-trim { height: 120px; }
  .christmas-theme .ticket-header::after { width: 75px; right: 35px; opacity: .6; }
}
@media (max-width: 760px) {
  .christmas-theme .intro-row { display: flex; flex-direction: column; gap: 0; padding: 28px 0 8px; align-items: stretch; min-height: 0; }
  .christmas-theme .intro-row h1 { font-size: clamp(41px, 8.2vw, 56px); margin-bottom: 10px; }
  .christmas-theme .intro-copy { font-size: 12px; }
  .christmas-hero-art { align-self: center; width: min(100%, 460px); margin-top: -4px; }
  .christmas-hero-art img { max-height: 230px; }
  .christmas-theme .selection-table { padding-top: 112px; }
  .festive-table-trim { top: -5px; width: 100%; height: 110px; object-position: center top; }
  .festive-table-trim.trim-second { display: none; }
  .christmas-theme .card-deck { height: auto; }
  .christmas-theme .card-medallion .holiday-tree { width: 29px; height: 35px; }
  .card-ribbon { transform: scale(.7); transform-origin: top center; top: 5px; }
  .christmas-theme .game-heading { padding: 7px 0 14px; min-height: 76px; }
  .game-festive-art { width: 106px; height: 71px; }
  .christmas-theme .draw-panel { padding-top: 65px; }
  .christmas-theme .draw-panel::after { top: -14px; height: 69px; background-position: center 68%; }
  .christmas-theme .ticket-header { min-height: 59px; }
  .christmas-theme .ticket-header::after { right: 36px; width: 95px; top: -13px; }
  .christmas-theme .ticket-star .holiday-tree { width: 23px; height: 29px; }
  .winner-art { height: 180px; }
}
@media (max-width: 374px) {
  .christmas-theme .intro-row { padding-top: 26px; }
  .christmas-theme .intro-row h1 { font-size: 39px; }
  .christmas-hero-art img { max-height: 186px; }
  .christmas-theme .selection-table { padding-top: 98px; }
  .festive-table-trim { height: 94px; }
  .christmas-theme .card-medallion .holiday-tree { width: 24px; height: 29px; }
  .christmas-theme .ticket-header::after { width: 72px; opacity: .8; }
}

/* Christmas artwork keeps the live number and card branding unobstructed. */
.christmas-theme .ball-orbit { width: 210px; max-width: 100%; height: 206px; isolation: isolate; }
.number-wreath {
  position: absolute; width: 210px; height: 210px; max-width: none;
  left: 50%; top: 50%; transform: translate(-50%, -50%);
  object-fit: contain; z-index: 0; pointer-events: none; user-select: none;
}
.christmas-theme .number-ball {
  z-index: 1; background: none; color: #fff5d7;
  box-shadow: 0 8px 18px #00111c66;
}
.christmas-theme .number-ball::before { content: none; }
.number-ball-art {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0;
  object-fit: contain; pointer-events: none; user-select: none;
}
.christmas-theme .number-ball #current-number {
  position: relative; z-index: 1;
  font-family: 'Cinzel Numbers', Georgia, serif; font-size: 74px; font-weight: 600;
  font-style: normal; font-synthesis: none; font-variant-numeric: lining-nums tabular-nums;
  line-height: 1; letter-spacing: 0; text-align: center;
  /* Optical correction for Cinzel's baseline; scales with the number on every screen. */
  transform: translateY(.04em);
  color: #fff1c7; text-shadow: 0 1px 2px #3e0000aa;
}
#game-card .ticket-cell:disabled { cursor: default; }
.christmas-theme .ball-orbit::before, .christmas-theme .orbit-spark { display: none; }
.christmas-theme .ticket-header { min-height: 94px; padding: 8px 20px; gap: 12px; }
.christmas-theme .ticket-header::after { content: none; }
.ticket-christmas-art {
  display: block; width: min(232px, calc(100% - 170px)); height: 78px;
  min-width: 0; flex: 0 1 auto; object-fit: contain; object-position: right center;
  pointer-events: none; user-select: none;
}
.christmas-theme .ticket-brand { flex: 0 0 auto; }
@media (max-width: 760px) {
  .christmas-theme .ball-orbit { width: 116px; height: 126px; }
  .christmas-theme .number-ball #current-number { font-size: 58px; }
  .number-wreath { width: 134px; height: 134px; }
  .christmas-theme .ticket-header { min-height: 72px; padding: 8px 14px; gap: 8px; }
  .ticket-christmas-art { width: min(150px, calc(100% - 154px)); height: 56px; }
  .christmas-theme .reveal-area .ticket-header { padding: 8px 11px; }
}
@media (max-width: 374px) {
  .christmas-theme .ball-orbit { width: 100px; height: 116px; }
  .christmas-theme .number-ball #current-number { font-size: 54px; }
  .number-wreath { width: 120px; height: 120px; }
  .christmas-theme .ticket-header { padding-inline: 12px; }
  .christmas-theme .ticket-brand { font-size: 12px; letter-spacing: .1px; }
  .christmas-theme .ticket-brand span { display: block; margin-top: 3px; font-size: 9px; }
  .ticket-christmas-art { width: min(150px, calc(100% - 84px)); }
}

/* A completed row celebrates in the middle of the card header. */
.christmas-theme #game-card .ticket-header.has-celebration {
  display: grid;
  grid-template-columns: minmax(90px, 1fr) minmax(150px, 1.2fr) minmax(70px, 1fr);
  align-items: center; gap: 12px;
}
.has-celebration .ticket-brand span { display: block; margin-top: 3px; font-size: 9px; }
.has-celebration .ticket-christmas-art { width: 100%; max-width: 180px; justify-self: end; }
.ticket-celebration {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; max-width: 270px; min-height: 64px; padding: 9px 10px;
  justify-self: center; text-align: center; border-radius: 11px;
  color: #c7ffdf; border: 1px solid #7ceba280;
  background: radial-gradient(ellipse at top, #25894b66, transparent 75%), linear-gradient(135deg, #123f31, #072a24);
  box-shadow: inset 0 0 16px #68e68e14, 0 0 16px #4edb7a18;
}
.ticket-celebration[hidden] { display: none; }
.ticket-celebration::before {
  content: ''; position: absolute; inset: -100% -50%; pointer-events: none;
  background: linear-gradient(110deg, transparent 40%, #caffdd33 50%, transparent 60%);
  transform: translateX(-100%); z-index: -1;
}
.celebration-copy { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.celebration-title { color: #dbf7e5; font-size: 12px; font-weight: 600; line-height: 1.3; }
.celebration-reward {
  display: block; color: #a0ffbd; font-family: var(--sans); font-size: clamp(12px, 1.2vw, 17px);
  font-weight: 750; line-height: 1.3; white-space: nowrap; letter-spacing: .25px;
  text-shadow: 0 0 12px #68f49a55;
}
.celebration-spark { flex: 0 0 auto; font-size: 11px; color: #a3e8b7; opacity: .7; }
.ticket-celebration.is-celebrating { animation: prize-arrive .5s ease-out both; }
.is-celebrating .celebration-reward { animation: prize-glow 2s ease-in-out 4; }
.is-celebrating .celebration-spark { animation: prize-spark 2s ease-in-out 4; }
.ticket-celebration.is-celebrating::before { animation: prize-shine 2.6s ease-in-out 3; }
@keyframes prize-arrive { from { opacity: .5; transform: translateY(4px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes prize-glow {
  0%, 100% { opacity: 1; color: #a0ffbd; text-shadow: 0 0 10px #68f49a55; }
  50% { opacity: .52; color: #70d991; text-shadow: 0 0 2px #68f49a22; }
  75% { opacity: 1; color: #e4ffed; text-shadow: 0 0 8px #91ffb4, 0 0 20px #68f49a88; }
}
@keyframes prize-spark { 0%, 100% { opacity: .45; transform: scale(.8); } 75% { opacity: 1; transform: scale(1.2); } }
@keyframes prize-shine { 0%, 35% { transform: translateX(-100%); } 85%, 100% { transform: translateX(100%); } }
@media (max-width: 1100px) and (min-width: 761px) {
  .celebration-spark { display: none; }
}
@media (max-width: 760px) {
  .christmas-theme #game-card .ticket-header.has-celebration { grid-template-columns: 1fr 1fr; gap: 6px 12px; padding-bottom: 12px; }
  .has-celebration .ticket-brand { grid-column: 1; grid-row: 1; }
  .has-celebration .ticket-christmas-art { grid-column: 2; grid-row: 1; max-width: 150px; }
  .ticket-celebration { grid-column: 1 / -1; grid-row: 2; max-width: 100%; min-height: 58px; }
  .celebration-title { font-size: 12px; }
  .celebration-reward { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  .ticket-celebration.is-celebrating,
  .ticket-celebration.is-celebrating::before,
  .is-celebrating .celebration-reward,
  .is-celebrating .celebration-spark { animation: none; }
}
.show-result { margin: 0 0 18px auto; min-height: 44px; color: #e5cd91; }
.reward-modal { width: 480px; padding: 28px 34px; overflow-y: auto; overscroll-behavior: contain; }
.reward-modal .winner-art { height: 130px; margin: -4px auto 0; }
.reward-modal h2 { font-size: clamp(27px, 5vw, 39px); line-height: 1.2; margin: 10px 0; }
.reward-modal #win-copy { margin: 0; font-size: 13px; }
.reward-total { display: grid; gap: 2px; justify-items: center; margin: 14px 0 20px; color: #f4dc9d; }
.reward-total strong { font-family: var(--display); font-size: clamp(48px, 12vw, 70px); line-height: 1; font-weight: 600; }
.reward-total > span { font-size: 11px; font-weight: 700; letter-spacing: 3px; }
.reward-breakdown { list-style: none; padding: 0; margin: 0 0 20px; border-top: 1px solid #d4ba7433; }
.reward-breakdown li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid #d4ba7426; font-size: 12px; }
.reward-breakdown strong { font-size: 11px; white-space: nowrap; }
.reward-earned { color: #e5eddf; }
.reward-earned strong { color: #b9f2be; }
.reward-unearned { color: #a8b9bd; }
.reward-unearned strong { font-weight: 400; font-size: 10px; }
.reward-modal .claim-reward { min-height: 50px; justify-content: center; font-size: 15px; }
.reward-modal .claim-reward:disabled { opacity: .65; cursor: not-allowed; }
.reward-modal .reward-availability { margin: 9px 0 4px; font-size: 11px; color: #c5cfc5; }
.reward-actions { display: flex; justify-content: space-between; gap: 14px; margin-top: 8px; }
.reward-actions .quiet-button { min-height: 44px; font-size: 12px; }
@media (max-width: 480px), (max-height: 720px) {
  .reward-modal { padding: 22px 20px 14px; max-height: calc(100dvh - 24px); max-width: calc(100% - 24px); }
  .reward-modal .winner-art { height: 95px; }
  .reward-modal h2 { font-size: 29px; }
  .reward-total { margin: 12px 0 16px; }
  .reward-total strong { font-size: 52px; }
  .reward-breakdown { margin-bottom: 15px; }
}
