:root{font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;color:#f7f9fe;background:#0b1428}*{box-sizing:border-box}body{margin:0}header{background:#17233d;display:flex;align-items:center;justify-content:space-between;padding:16px max(18px,calc((100vw - 1100px)/2));border-bottom:1px solid #34445c}.brand{font-size:19px;font-weight:850;letter-spacing:1px}.logo{color:#f5be47}.muted,.hint{color:#a9bdd7}.topright{display:flex;gap:18px;align-items:center;font-size:13px}a{color:#80c8ff}main{max-width:1100px;margin:auto;padding:24px 16px 70px}.panel{background:#192943;border:1px solid #314664;border-radius:16px;padding:22px;margin:0 0 18px}.panel h2{margin:0 0 14px;font-size:22px}h1{font-size:30px;margin:0 0 16px}.row{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.between{justify-content:space-between}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:14px}button{border:none;border-radius:10px;background:#f4be4b;color:#171b28;padding:12px 17px;font:inherit;font-weight:750;cursor:pointer}button.secondary{background:#324866;color:#fff}button.danger{background:#a3424d;color:#fff}button.success{background:#36896a;color:#fff}button:disabled{opacity:.45;cursor:not-allowed}input,select{background:#101c32;border:1px solid #62748b;color:white;padding:12px 14px;border-radius:9px;font:inherit;max-width:100%}label{display:block;font-size:14px;color:#c4d2e5;margin-bottom:8px}.field{margin-bottom:14px}.notice{padding:12px 15px;border-radius:10px;background:#234d5c;border:1px solid #528b96;margin:12px 0}.error{background:#612c36;border-color:#ab5363}.big{font-weight:900;font-size:clamp(64px,14vw,150px);line-height:1.1;text-align:center;color:#f4be4b}.phrase{text-align:center;font-size:clamp(19px,3vw,29px);min-height:42px}.pin{font-size:37px;letter-spacing:6px;font-weight:900;color:#f4be4b}.pill{display:inline-block;background:#314661;border-radius:50px;padding:5px 10px;font-size:12px}.sub{color:#b0c5de;font-size:14px}.mini{font-size:13px}.called{display:flex;flex-wrap:wrap;gap:5px}.ball{width:37px;height:37px;border-radius:50%;display:grid;place-items:center;background:#334766;font-weight:800}.ball.active{background:#fac74e;color:#111a27}.ticket{background:#eef5ff;color:#132744;border:2px solid #ced8e7;border-radius:12px;padding:12px;min-width:0}.ticket h3{margin:0 0 10px;font-size:15px}.ticket-grid{display:grid;grid-template-columns:repeat(9,minmax(0,1fr));gap:3px}.ticket-cell{min-width:0;aspect-ratio:1 / 1;border-radius:6px;border:1px solid #c9d4e3;display:flex;align-items:center;justify-content:center;background:white;color:#142b4c;font-size:clamp(12px,2.6vw,20px);font-weight:850;padding:0;touch-action:manipulation}.ticket-cell.blank{background:#e5ebf3;border-color:transparent;cursor:default}.ticket-cell.marked{background:#13775d;color:#fff}.ticket-cell.called:not(.marked){box-shadow:inset 0 0 0 2px #e5a63a}.ticket-cell:disabled{opacity:1}.ticket-actions{margin-top:10px;display:flex;align-items:center;justify-content:space-between}.ticket-actions button{font-size:13px;padding:9px 11px}.ticket-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,370px),1fr));gap:14px}.qr{background:white;padding:8px;border-radius:10px;display:inline-block}.phase{font-size:16px;font-weight:750;color:#ffda82}.overlay{padding:14px;background:#3e4a2b;border-radius:12px}.status{font-size:13px;color:#aebed2}@media(max-width:600px){main{padding:13px 9px 55px}.panel{padding:15px}.ticket{padding:8px}.ticket-cell{font-size:clamp(11px,3.8vw,18px);border-radius:4px}.ticket-grid{gap:2px}header{padding:12px}.brand{font-size:16px}.big{font-size:90px}}

/* Large caller view and local voice recording studio */
.caller-panel{min-height:435px}.caller-panel .big{font-size:clamp(110px,18vw,240px);line-height:1.1;margin:14px auto}.caller-panel .phrase{font-size:clamp(23px,3.5vw,43px);font-weight:750}.caller-panel:fullscreen{background:#0b1428;border:0;border-radius:0;overflow:auto;padding:3vh 4vw}.caller-panel:fullscreen .big{font-size:clamp(180px,35vh,400px)}.caller-panel:fullscreen .phrase{font-size:clamp(32px,6vh,72px)}.caller-panel:fullscreen .called{justify-content:center}.studio-call{padding:20px;background:#101d32;border-radius:14px;text-align:center;margin:14px 0}.studio-call #studioNumber{font-size:clamp(75px,13vw,170px);font-weight:900;color:#fac74e}.studio-call #studioWords{font-size:clamp(21px,4vw,38px);font-weight:800}.studio-grid{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));gap:5px;margin:14px 0}.studio-grid button{padding:8px 2px;font-size:12px}.studio-grid .selected{outline:3px solid #fff;outline-offset:1px}@media(max-width:600px){.studio-grid{grid-template-columns:repeat(9,minmax(0,1fr))}}

/* Bingo Live 0.3, original caller-inspired TV layout */
.caller-panel{background:linear-gradient(120deg,#0b1b34,#102944);border-color:#315676}.caller-display{display:grid;grid-template-columns:minmax(250px,.82fr) minmax(300px,1.18fr);gap:24px}.caller-stage{text-align:center;display:flex;align-items:center;flex-direction:column;justify-content:center;padding:22px 8px}.caller-ball{width:clamp(190px,22vw,290px);height:clamp(190px,22vw,290px);border-radius:50%;background:radial-gradient(circle at 30% 22%,#fff,#f5f7fb 28%,#dce7f4 72%,#93abc4);color:#11243a;display:grid;place-items:center;font-size:clamp(95px,12vw,165px);font-weight:950;box-shadow:inset -12px -17px 26px #142b483b,0 0 0 11px #2a4d6a,0 0 35px #1bb5d444;margin:18px auto 22px}.caller-stage .phrase{font-size:clamp(23px,3vw,38px);font-weight:850}.caller-board h2{margin-top:8px}.board-history{display:grid;grid-template-columns:minmax(0,1fr) 88px;gap:12px}.number-board{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));gap:5px;align-content:start}.number-cell{aspect-ratio:1;display:grid;place-items:center;background:#172f48;border:1px solid #325372;border-radius:7px;font-weight:850;font-size:clamp(11px,1.2vw,17px)}.number-cell.called{background:#ffcb5d;color:#101d2d}.number-cell.latest{background:#68dedf;color:#10243b;box-shadow:0 0 12px #68dedf88}.recent-column{border-left:1px solid #315676;padding-left:10px}.recent-column b{font-size:13px}.recent-number{margin:5px 0;padding:6px;text-align:center;border-radius:8px;background:#1c3952;font-weight:900}.recent-number:first-child{border:1px solid #6be1e1;color:#6be1e1}.claim-indicator{min-height:36px;margin-top:12px;font-weight:850}.claim-indicator.checking{color:#81bbff;background:#173b66;border:2px solid #4189eb;padding:10px 16px;border-radius:12px;animation:claimPulse 1.1s infinite alternate}.claim-indicator.winner{color:#6aefb8}@keyframes claimPulse{from{box-shadow:0 0 0 #4189eb00}to{box-shadow:0 0 22px #4189eb66}}.ticket.ticket-checking{border:4px solid #277ce3;box-shadow:0 0 20px #277ce366;animation:claimPulse 1.1s infinite alternate}.ticket.ticket-winner{border:5px solid #20ae68;background:#dbfff0;box-shadow:0 0 23px #26e89a99}.ticket.ticket-winner h3{color:#06653c}.caller-panel:fullscreen{padding:4vh 3vw}.caller-panel:fullscreen .caller-display{height:calc(100vh - 110px)}.caller-panel:fullscreen .caller-ball{width:min(31vw,43vh);height:min(31vw,43vh);font-size:min(15vw,23vh)}.caller-panel:fullscreen .number-cell{font-size:clamp(12px,2vh,22px)}@media(max-width:920px){.caller-display{grid-template-columns:1fr}.caller-ball{width:220px;height:220px}.number-cell{font-size:clamp(11px,2vw,17px)}}

/* v0.4 responsive tickets: five tickets visible on a typical phone, with opt-in large marking targets */
.ticket-top{gap:5px}.ticket-top h3{margin:0;font-size:12px}.ticket-top .mini{font-size:11px}.ticket-zoom{background:#dbe6f5;color:#142b4c;font-size:10px;padding:3px 7px;border-radius:5px}
@media(max-width:600px){
 #playerScreen > .row:first-child{margin-bottom:5px}
 #playerScreen h1{font-size:18px;margin:0}
 #playerScreen>.panel{padding:8px 11px;margin-bottom:8px}
 #playerScreen .panel #playerLast{font-size:27px!important;line-height:1.05}
 #playerScreen .panel .notice{padding:5px 7px;margin:4px 0;font-size:11px}
 #playerScreen .panel .sub,#playerScreen .panel .phase{font-size:11px}
 #playerScreen .row h2{font-size:16px}
 #playerScreen .ticket-list{gap:5px;display:grid;grid-template-columns:1fr}
 #playerScreen .ticket{padding:4px 7px;border-width:1px;border-radius:7px}
 #playerScreen .ticket-grid{gap:2px}
 #playerScreen .ticket-cell{aspect-ratio:auto;height:20px;font-size:12px;border-radius:3px}
 #playerScreen .ticket-actions{margin-top:3px}
 #playerScreen .ticket-actions .mini{font-size:10px}
 #playerScreen .ticket-actions button{padding:4px 10px;font-size:11px}
 #playerScreen .ticket.ticket-expanded{padding:10px;border-width:3px}
 #playerScreen .ticket-expanded .ticket-cell{height:42px;font-size:18px}
 #playerScreen .ticket-expanded .ticket-actions{margin-top:10px}
 #playerScreen .ticket-expanded .ticket-actions button{padding:10px 16px;font-size:14px}
 #playerScreen .ticket-expanded .ticket-top h3{font-size:16px}
}

/* v0.5 enforce exactly three separate nine-column ticket rows */
.ticket-grid{display:flex;flex-direction:column;gap:2px}.ticket-row{display:grid;grid-template-columns:repeat(9,minmax(0,1fr));gap:2px;width:100%;min-width:0}.ticket-row .ticket-cell{width:100%;min-width:0}.ticket-top small{font-weight:400;font-size:10px;color:#4e6a87}.caller-settings{margin-top:14px;border-top:1px solid #456078;padding-top:10px}.caller-settings summary{font-weight:750;cursor:pointer;color:#fcce6d}.settings-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(185px,1fr));gap:12px;margin-top:15px}.settings-grid input[type=file]{max-width:100%;padding:7px}.caller-panel:fullscreen .caller-board{min-width:0}.caller-panel:fullscreen .number-board{grid-template-columns:repeat(10,minmax(0,1fr))}
@media(max-width:600px){#playerScreen .ticket-grid{gap:1px}#playerScreen .ticket-row{gap:2px}#playerScreen .ticket-cell{height:22px}#playerScreen .ticket-expanded .ticket-cell{height:43px}#playerScreen .ticket-top small{font-size:9px}#playerScreen .ticket-list{gap:4px}#playerScreen .ticket{padding:5px 6px}}

/* v0.7 operator help and audit UI */
.help-overlay{position:fixed;inset:0;background:#030915dd;z-index:30000;display:grid;place-items:center;padding:14px}.help-window{background:#1b2c4a;color:#f4f7ff;border:1px solid #426189;border-radius:15px;width:min(900px,100%);max-height:90dvh;overflow:auto;padding:20px}.help-layout{display:grid;grid-template-columns:220px 1fr;gap:18px}.help-nav{display:flex;flex-direction:column;gap:5px}.help-nav button{text-align:left;font-size:13px}.help-nav .help-active{background:#fac74e;color:#13213c}.help-content{line-height:1.75;padding:12px 18px;background:#0c1931;border-radius:9px;min-height:180px}.log-item{padding:7px 2px;border-bottom:1px solid #ffffff26;font-size:13px}.topright #operatorHelpButton{margin-left:8px}@media(max-width:640px){.help-layout{grid-template-columns:1fr}.help-nav{display:grid;grid-template-columns:1fr 1fr}.help-window{padding:10px}.help-content{padding:12px}}

/* Bingo Live v0.8 */
.audience-mode header{padding:10px 28px}.audience-mode main{max-width:none;padding:10px 2vw}.tv-screen{min-height:calc(100vh - 85px);background:radial-gradient(circle at top,#1b4580,#081629 75%);padding:2vw;border-radius:18px;color:white}.tv-head{display:flex;justify-content:space-between;font-size:clamp(20px,2.4vw,38px)}.tv-centre{text-align:center;padding:1vh}.tv-ball{display:grid;place-items:center;margin:0 auto;background:white;color:#122c53;border-radius:50%;width:min(25vw,30vh);height:min(25vw,30vh);font-size:clamp(68px,12vw,165px);font-weight:900;box-shadow:0 0 35px #50abff}.tv-phrase{font-size:clamp(28px,4vw,60px);font-weight:800}.tv-stage{font-size:clamp(16px,2.2vw,28px);color:#ffd76a}.tv-board{display:grid;grid-template-columns:repeat(15,1fr);gap:0.35vw;margin-top:1.5vh}.tv-cell{border:1px solid #59739a;border-radius:6px;text-align:center;padding:.5vh 0;font-weight:800;font-size:clamp(13px,1.55vw,24px);background:#102a4a}.tv-cell.hit{background:#ad8223;color:white}.tv-cell.now{background:#35a8e8;color:#07162a}.tv-winner{color:#fbd76d;text-align:center;font-size:clamp(24px,4vw,60px);font-weight:900;min-height:1.5em}.claim-ticket{max-width:650px}.claim-row{display:grid;grid-template-columns:repeat(9,1fr);gap:4px;margin:4px 0}.claim-row span{text-align:center;border-radius:6px;padding:9px 2px;font-weight:800}.claim-row .verified{background:#177ad1;color:white}.claim-row .unverified{background:#d6a53a;color:#131a23}.claim-row .empty{background:#1b2942}html[data-bingo-theme="gold"] .caller-panel{background:#4a3308}html[data-bingo-theme="purple"] .caller-panel{background:#311e58}.high-contrast .ticket-list{filter:contrast(1.35)}.high-contrast button{font-weight:900}

/* v0.8.1 Studio visibility fix: open as an actual visible on-screen panel */
body.studio-open{overflow:hidden}
.studio-modal{position:fixed;inset:3vh max(12px,calc((100vw - 950px)/2));z-index:99999;overflow:auto;max-height:94vh;box-shadow:0 0 0 100vmax rgba(3,10,25,.82),0 14px 50px #0009;border:2px solid #60b6ff;background:#132542;padding:24px;scroll-margin-top:12px}
.studio-modal .studio-call{text-align:center;margin:14px auto}
.studio-modal .studio-grid{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));gap:5px}
.studio-modal .studio-grid button{min-width:0;padding:8px 1px}
@media(max-width:540px){.studio-modal{inset:8px;padding:12px;max-height:calc(100vh - 16px)}.studio-modal .studio-grid{grid-template-columns:repeat(9,minmax(0,1fr))}}

/* v0.8.2: no floating mobile link; keep all three rows of every ticket unobstructed */
#playerScreen .ticket-list{padding-bottom:18px}#playerScreen #nextGamePanel{position:static!important}
/* One-screen full-screen mode: original caller presentation with its own game controls */
.single-screen-bar{display:none}.caller-panel:fullscreen .single-screen-bar{position:absolute;bottom:0;left:0;right:0;display:flex;align-items:center;justify-content:center;gap:9px;padding:10px 15px;background:#081426f2;z-index:10;flex-wrap:wrap}.caller-panel:fullscreen{position:relative;padding-bottom:76px}.caller-panel:fullscreen .caller-display{height:calc(100vh - 186px)}.single-screen-bar button{padding:8px 13px;font-size:14px}.single-screen-bar button:disabled{opacity:.35}
/* TV layout uses the same original caller board, ball, history and colours */
.audience-mode header{display:none}.audience-mode main{padding:0;max-width:none}.tv-unified{height:100dvh;min-height:100dvh;margin:0;border-radius:0;padding:2vh 3vw}.tv-unified .caller-display{height:calc(100dvh - 90px);min-height:0}.tv-unified .caller-ball{width:min(28vw,42vh);height:min(28vw,42vh);font-size:min(14vw,21vh)}.tv-unified .number-cell{font-size:clamp(12px,1.3vw,22px)}@media(max-width:920px){.tv-unified .caller-display{height:auto}.tv-unified .caller-ball{width:180px;height:180px;font-size:85px}}

/* v0.8.3 claim verification and paper ticket */
.review-flash{background:#2789ff!important;color:white!important;box-shadow:0 0 22px #3d98ff!important;animation:claimPulse .5s infinite alternate}
.confirmed-win{background:#107342!important;color:#fff!important;padding:15px;border-radius:12px;animation:claimPulse .6s infinite alternate}
#paperCheckBox .row{display:flex;flex-wrap:wrap;gap:9px}#paperCheckBox button:disabled{opacity:.45}
.ticket.ticket-checking .ticket-cell.claim-winning-number{animation:blueCell .5s infinite alternate;background:#2789ff!important;color:white!important}
@keyframes blueCell{from{background:#1872dc;color:#fff}to{background:#77c6ff;color:#07162a}}

.confirmed-number{background:#0aa96c!important;color:white!important;box-shadow:0 0 14px #0aa96c!important}

/* v0.8.5 projector: screen-fit board, same caller image as operator */
html:has(.tv-unified),body.audience-mode{height:100%;overflow:hidden}
body.audience-mode{margin:0}
body.audience-mode main{height:100dvh;min-height:0;padding:0;display:block;overflow:hidden}
.tv-unified{box-sizing:border-box;width:100%;height:100dvh;min-height:0;max-height:100dvh;padding:clamp(8px,1.3vh,17px) clamp(8px,1.5vw,25px);overflow:hidden;display:grid;grid-template-rows:auto minmax(0,1fr);gap:clamp(5px,1vh,12px)}
.tv-unified>.row{min-height:0;gap:10px;align-items:center}
.tv-unified>.row h2{font-size:clamp(15px,2.2vw,29px);line-height:1.1;margin:0}
.tv-unified .caller-display{height:100%!important;min-height:0!important;overflow:hidden;display:grid;grid-template-columns:minmax(0,.76fr) minmax(0,1.24fr);gap:clamp(8px,1.4vw,25px)}
.tv-unified .caller-stage{box-sizing:border-box;min-width:0;min-height:0;padding:5px;justify-content:center;overflow:hidden;gap:clamp(3px,.6vh,10px)}
.tv-unified .caller-ball{flex-shrink:0;width:min(26vw,37dvh)!important;height:min(26vw,37dvh)!important;font-size:min(13vw,19dvh)!important;margin:5px auto 10px}
.tv-unified .caller-stage .phrase{font-size:clamp(18px,2.4vw,40px);min-height:0;line-height:1.12}
.tv-unified .caller-stage .phase{font-size:clamp(14px,1.6vw,25px)}
.tv-unified .caller-board{min-width:0;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.tv-unified .caller-board>h2{margin:0 0 7px;font-size:clamp(14px,1.8vw,24px)}
.tv-unified .board-history{min-width:0;min-height:0;flex:1;grid-template-columns:minmax(0,1fr) clamp(58px,7vw,95px);gap:clamp(4px,.65vw,10px)}
.tv-unified .number-board{min-width:0;min-height:0;display:grid;grid-template-columns:repeat(10,minmax(0,1fr));grid-template-rows:repeat(9,minmax(0,1fr));gap:clamp(2px,.5vh,6px);align-content:stretch}
.tv-unified .number-cell{aspect-ratio:auto;min-width:0;min-height:0;border-radius:clamp(2px,.5vw,7px);font-size:clamp(11px,1.35vw,23px);line-height:1}
.tv-unified .recent-column{min-width:0;min-height:0;overflow:hidden;padding-left:clamp(3px,.5vw,9px)}
.tv-unified .recent-column b{font-size:clamp(10px,1.1vw,14px)}
.tv-unified #tvRecent{display:grid;grid-template-rows:repeat(12,minmax(0,1fr));height:calc(100% - 37px);min-height:0}
.tv-unified .recent-number{margin:1px 0;padding:0;display:grid;place-items:center;font-size:clamp(11px,1.3vw,20px);min-height:0}
@media(max-width:850px){.tv-unified .caller-display{grid-template-columns:minmax(0,.65fr) minmax(0,1.35fr)}.tv-unified .caller-ball{width:min(23vw,32dvh)!important;height:min(23vw,32dvh)!important;font-size:min(12vw,17dvh)!important}.tv-unified .caller-stage .phrase{font-size:clamp(14px,2.2vw,28px)}}
@media (orientation:portrait){.tv-unified{overflow:auto;max-height:none;min-height:100dvh;height:auto}.tv-unified .caller-display{display:flex;flex-direction:column;height:auto!important;overflow:visible}.tv-unified .caller-ball{width:min(40vw,22dvh)!important;height:min(40vw,22dvh)!important}.tv-unified .caller-board{min-height:48dvh}.tv-unified .board-history{min-height:42dvh}.tv-unified .number-cell{font-size:clamp(10px,2.3vw,18px)}body.audience-mode main{overflow:auto}}

/* v0.8.7 pre-game audience lobby */
.tv-unified.show-lobby{position:relative;display:block;padding:0;overflow:hidden}
.tv-unified.show-lobby>.row,.tv-unified.show-lobby>.caller-display{display:none!important}
.tv-lobby[hidden],.lobby-host-tools[hidden]{display:none!important}
.tv-lobby{position:absolute;inset:0;overflow:hidden;display:grid;place-items:center;background:radial-gradient(ellipse at 48% 25%,rgba(36,93,146,.42),transparent 60%),linear-gradient(140deg,rgba(4,16,41,.87),rgba(7,35,77,.90));color:white}
.tv-lobby-balls{position:absolute;inset:0;pointer-events:none;overflow:hidden}
.lobby-falling-ball{position:absolute;top:-15%;width:clamp(34px,4.6vw,84px);aspect-ratio:1;border-radius:50%;display:grid;place-items:center;color:#122b50;font-weight:900;font-size:clamp(14px,2vw,32px);background:radial-gradient(circle at 30% 22%,white,#b9daff 49%,#558cd0 88%);box-shadow:inset -4px -6px 9px #263c6680,0 7px 14px #0006;animation:fall-bingo 15s linear infinite}
@keyframes fall-bingo{0%{transform:translate3d(0,-15vh,0) rotate(-50deg)}100%{transform:translate3d(6vw,125vh,0) rotate(300deg)}}
.tv-lobby-content{position:relative;z-index:1;width:min(94vw,1430px);text-align:center;padding:clamp(12px,2vh,25px);box-sizing:border-box}
.tv-lobby-title{font-weight:900;font-size:clamp(24px,3.5vw,54px);color:#ffe094;text-shadow:0 3px 12px #0008;margin-bottom:clamp(10px,2vh,30px)}
.tv-lobby-main{display:grid;grid-template-columns:1fr 1fr;gap:clamp(10px,3vw,55px);align-items:center}
.tv-lobby-join,.tv-lobby-wait{background:#06182bdc;border:1px solid #ffffff35;border-radius:24px;padding:clamp(12px,2.3vw,30px);box-shadow:0 14px 48px #0007;min-width:0}
.tv-lobby-join h2{margin:0 0 10px;font-size:clamp(21px,3vw,45px);color:#fff}
.tv-lobby-join p{font-size:clamp(13px,1.6vw,25px);margin:clamp(4px,1vh,13px) 0}
.tv-lobby-qr{background:#fff;border-radius:14px;padding:12px;width:max-content;max-width:90%;margin:auto;min-height:200px;display:grid;place-items:center;color:#10223f}
.tv-lobby-qr img,.tv-lobby-qr canvas{max-width:100%;height:auto}
.tv-join-address{font-size:clamp(19px,2.3vw,39px);font-weight:900;overflow-wrap:anywhere;color:#8fd8ff}
.tv-lobby-pin{font-size:clamp(38px,5.5vw,90px);line-height:1.05;letter-spacing:.09em;font-weight:900;color:#ffe094;font-variant-numeric:tabular-nums}
.tv-lobby-wait #tvLobbyCountdownStatus{font-size:clamp(18px,2.15vw,35px);font-weight:700}
.tv-lobby-clock{font-size:clamp(70px,10vw,165px);line-height:1.35;font-weight:900;letter-spacing:-.045em;font-variant-numeric:tabular-nums;color:#ffe094;text-shadow:0 4px 15px #0009}
.tv-lobby-wait-note{font-size:clamp(14px,1.6vw,25px)}
.tv-lobby-count{margin-top:clamp(18px,4vh,50px);font-size:clamp(16px,1.9vw,29px);font-weight:700}
.tv-lobby-game-mode{margin-top:12px;color:#93d9ff;font-size:clamp(13px,1.55vw,23px)}
.lobby-host-tools{margin-top:12px;padding:14px;border:1px solid #ffffff2b;border-radius:12px}
.lobby-host-clock{font-weight:900;font-size:28px;font-variant-numeric:tabular-nums}
@media(max-width:650px),(orientation:portrait){.tv-lobby-main{grid-template-columns:1fr;gap:10px}.tv-lobby-content{max-height:100dvh;overflow:auto}.tv-lobby-title{margin-bottom:8px}.tv-lobby-join,.tv-lobby-wait{padding:8px}.tv-lobby-qr{min-height:0;padding:7px}.tv-lobby-qr img,.tv-lobby-qr canvas{max-width:105px!important;max-height:105px!important}.tv-lobby-clock{font-size:50px}.tv-lobby-pin{font-size:36px}}
@media(prefers-reduced-motion:reduce){.lobby-falling-ball{animation:none;display:none}}

/* v0.8.8 fair play settings */
.rule-choice{display:flex;align-items:center;gap:9px;margin:14px 0 5px;line-height:1.45}.rule-choice input{width:20px;height:20px;flex:none}.player-rule{border-left:4px solid #f5bd44;margin-bottom:10px}.tv-lobby-game-mode[hidden],.player-rule[hidden]{display:none!important}

/* v0.8.9: optional left dock keeps controls clear of the Windows auto-hide taskbar. */
.caller-panel:fullscreen.controls-left{padding-bottom:3vh}
.caller-panel:fullscreen.controls-left .caller-display{height:calc(100dvh - 115px)}
.caller-panel:fullscreen.controls-left .single-screen-bar{
 left:2vw;right:auto;bottom:clamp(16px,3vh,40px);
 width:min(39vw,580px);max-height:40vh;overflow-y:auto;
 display:flex;flex-wrap:wrap;justify-content:flex-start;align-content:flex-end;
 gap:5px;padding:7px;background:#081426ec;border:1px solid #365372;
 border-radius:10px;box-shadow:0 5px 20px #0008;
}
.caller-panel:fullscreen.controls-left .single-screen-bar button{
 font-size:clamp(11px,.95vw,14px);padding:6px 9px;min-height:32px;
}
.caller-panel:fullscreen.controls-bottom .single-screen-bar{
 bottom:0;left:0;right:0;width:auto;border-radius:0;
}
@media(max-width:850px){
 .caller-panel:fullscreen.controls-left .single-screen-bar{width:min(43vw,420px);left:1vw;bottom:12px}
 .caller-panel:fullscreen.controls-left .single-screen-bar button{padding:5px 7px}
}
@media(max-height:570px){
 .caller-panel:fullscreen.controls-left .single-screen-bar{max-height:40vh;overflow:auto;bottom:7px}
 .caller-panel:fullscreen.controls-left .single-screen-bar button{font-size:11px;min-height:26px;padding:3px 6px}
}

/* v0.9.0 paper claims in the one-screen full-screen caller */
.single-screen-bar .paper-dock-label{display:flex;align-items:center;gap:4px;padding:3px 6px;font-size:12px;color:#ffe4a0;white-space:nowrap}
.single-screen-bar [data-one="paper-approve"]:not(:disabled){background:#157b50;color:white}
.single-screen-bar [data-one="paper-reject"]:not(:disabled){background:#902b3c;color:white}
.caller-panel:fullscreen.controls-left .single-screen-bar{max-height:54vh;overflow:auto}
.caller-panel:fullscreen.controls-bottom .single-screen-bar{max-height:30vh;overflow:auto}
@media(max-height:600px){.caller-panel:fullscreen.controls-left .single-screen-bar{max-height:55vh}}

/* v0.9.1: branding and bottom-row dock alignment. */
#callerPanel>.row.between{align-items:flex-start;min-height:45px}
.full-caller-brand{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:5px;min-width:0;max-width:42vw;font-size:clamp(20px,2vw,35px);font-weight:850;line-height:1.12;color:#ffe2a2;overflow-wrap:anywhere}
.full-caller-brand img{object-fit:contain;object-position:left center;width:auto;max-width:min(260px,37vw);height:auto;max-height:clamp(48px,12vh,135px);display:block}
.full-caller-brand img[hidden]{display:none!important}
.caller-panel:fullscreen .full-caller-brand{max-width:36vw}
.caller-panel:fullscreen.controls-left .single-screen-bar{left:3vw;right:auto;width:min(36vw,520px);max-height:min(52vh,440px);bottom:12px;align-content:flex-end;overflow:auto}
.caller-panel:fullscreen.controls-left .caller-display{min-height:0}
@media(max-width:900px){.caller-panel:fullscreen.controls-left .single-screen-bar{width:min(43vw,430px);left:2vw}.full-caller-brand img{max-width:30vw}}

/* v0.9.2: mobile claim highlights only the actual winning pattern. */
.ticket.ticket-checking .ticket-cell.marked.called:not(.claim-winning-number){animation:none;}
.single-screen-bar [data-one="digital-approve"]:not(:disabled){background:#157b50;color:white}
.single-screen-bar [data-one="digital-reject"]:not(:disabled){background:#902b3c;color:white}
.single-screen-bar [hidden]{display:none!important}

/* v0.9.3 multiple ticket formats and player branding */
#playerScreen .ticket-row,.claim-row{grid-template-columns:repeat(var(--ticket-cols,9),minmax(0,1fr))}
#playerScreen .ticket-grid{--ticket-cols:9}
#playerScreen .ticket-cell.free-square{background:#f0c864;color:#132744;font-size:clamp(9px,2.2vw,14px);font-weight:900;cursor:default}
#playerScreen .mobile-venue{display:flex;align-items:center;gap:12px;min-width:0}
#playerScreen .mobile-venue img{max-height:64px;max-width:100px;object-fit:contain;flex-shrink:0}
#playerScreen .mobile-venue h1{overflow-wrap:anywhere;font-size:clamp(20px,5vw,30px)}

/* v0.9.4: current winning stage beneath the number/phrase */
.caller-stage .playing-for{margin-top:clamp(6px,1vh,14px);padding:7px 16px;border-radius:30px;background:rgba(9,30,55,.82);border:1px solid rgba(255,212,116,.58);color:#ffda83;font-size:clamp(17px,1.6vw,25px);font-weight:800;text-align:center;line-height:1.25}
.caller-panel:fullscreen .playing-for,.tv-unified .playing-for{font-size:clamp(16px,1.9vw,30px)}

/* v0.9.5: avoid horizontal scroll, give recent winners room and reduce caller crowding */
#callerPanel:fullscreen{overflow:hidden!important;overflow-x:hidden!important;padding:1.2dvh 1.4vw!important;width:100vw;max-width:100vw;height:100dvh;box-sizing:border-box}
#callerPanel:fullscreen>.row.between{min-height:0!important;height:auto;max-height:16dvh;align-items:flex-start}
#callerPanel:fullscreen .caller-display{height:calc(100dvh - clamp(75px,14dvh,154px))!important;min-height:0;min-width:0;grid-template-columns:minmax(0,.72fr) minmax(0,1.28fr);gap:clamp(6px,1.3vw,16px)}
#callerPanel:fullscreen .caller-stage{justify-content:flex-start;padding:0 3px!important;min-width:0;gap:2px}
#callerPanel:fullscreen .caller-ball{width:min(24vw,32dvh)!important;height:min(24vw,32dvh)!important;font-size:min(12vw,18dvh)!important;margin:3px auto 7px!important}
#callerPanel:fullscreen .phrase{font-size:clamp(19px,3.5dvh,34px)!important;min-height:0;line-height:1.1}
#callerPanel:fullscreen .playing-for{margin-top:3px;padding:4px 9px;font-size:clamp(13px,2.2dvh,21px)}
#callerPanel:fullscreen .caller-board{min-width:0;min-height:0;overflow:hidden}
#callerPanel:fullscreen .board-history{min-width:0;min-height:0;height:calc(100% - 35px);grid-template-columns:minmax(0,1fr) clamp(65px,8vw,102px);gap:6px}
#callerPanel:fullscreen .number-board{min-width:0;min-height:0;grid-template-rows:repeat(9,minmax(0,1fr));height:100%;gap:clamp(2px,.45dvh,6px)}
#callerPanel:fullscreen .number-cell{aspect-ratio:auto;min-height:0;font-size:clamp(11px,1.7dvh,22px)}
#callerPanel:fullscreen .recent-column{min-width:0;min-height:0;overflow:hidden}
#callerPanel:fullscreen #recentCalls{height:calc(100% - 32px);display:grid;grid-template-rows:repeat(12,minmax(0,1fr));overflow:hidden}
#callerPanel:fullscreen .recent-number{margin:1px 0;padding:1px;min-height:0;display:grid;place-items:center;font-size:clamp(10px,1.7dvh,19px)}
#callerPanel:fullscreen.controls-left .single-screen-bar{width:min(34vw,470px)!important;max-height:45dvh!important;left:1vw!important;padding:5px!important;gap:3px!important;overflow-y:auto!important;scrollbar-width:thin}
#callerPanel:fullscreen .single-screen-bar button{padding:4px 7px!important;font-size:clamp(10px,1.45dvh,13px)!important;min-height:25px!important;border-radius:5px}
#callerPanel:fullscreen .single-screen-bar .paper-dock-label{font-size:11px;padding:2px}
#callerPanel:fullscreen .full-caller-brand{font-size:clamp(17px,2.7dvh,29px);max-height:15dvh}
#callerPanel:fullscreen .full-caller-brand img{max-height:9dvh}
.winning-overlay{position:absolute;z-index:45;inset:21% 7% auto 7%;padding:clamp(18px,4dvh,42px);border-radius:22px;border:3px solid #f8d778;background:linear-gradient(150deg,rgba(10,35,59,.98),rgba(20,80,53,.96));box-shadow:0 10px 70px #000b;display:none;text-align:center;pointer-events:none;color:white}
.winning-overlay.active{display:block;animation:win-pop .35s ease-out}
.winning-overlay-title{font-size:clamp(34px,5.5vw,88px);color:#ffe28a;font-weight:950;text-shadow:0 3px 9px #0009}
.winning-overlay-name{font-size:clamp(22px,3vw,48px);font-weight:800;margin-top:8px}
@keyframes win-pop{from{transform:scale(.9);opacity:.2}to{transform:scale(1);opacity:1}}
.number-cell.waiting-spark{background:#50dfe7!important;color:#10213b!important;box-shadow:0 0 16px #45d6edcc}
.tv-unified{position:relative}
@media(prefers-reduced-motion:reduce){.winning-overlay.active{animation:none}}

/* v0.9.6 public projector window can enter immersive full-screen on its own */
body.audience-mode #tvScreen{position:relative;box-sizing:border-box;max-width:100%;}
#tvScreen .tv-fullscreen-button{position:fixed;right:14px;bottom:12px;z-index:250;padding:7px 12px;opacity:.8;font-size:12px;line-height:1.2;white-space:nowrap;}
#tvScreen .tv-fullscreen-button:hover,#tvScreen .tv-fullscreen-button:focus-visible{opacity:1;}
#tvScreen:fullscreen{width:100vw!important;height:100dvh!important;max-width:none!important;max-height:none!important;overflow:hidden!important;margin:0!important;border-radius:0!important;box-sizing:border-box!important;}
#tvScreen:fullscreen .tv-fullscreen-button{position:absolute;bottom:8px;right:12px;}
#tvScreen:fullscreen .caller-display{max-height:calc(100dvh - 100px);min-height:0;}
@media (max-height:680px){#tvScreen:fullscreen .tv-fullscreen-button{padding:3px 7px;font-size:11px}}

/* v0.9.7: one non-blocking orange pulse on the selected side-bet ball */
.number-cell.sidebet-orange-flash{animation:sidebetOnce .9s ease-out 1!important;position:relative;z-index:2}
@keyframes sidebetOnce{0%,100%{background:inherit}18%,60%{background:#f38b22;color:#171c2a;box-shadow:0 0 16px 5px #ffa52a}75%{background:#df7b15;color:#fff}}
.sidebet-row{margin:7px 0;align-items:center}.sidebet-row input[data-side-name]{flex:1;min-width:115px}

.sidebet-caller-result{font-size:clamp(12px,1.15vw,17px);font-weight:700;color:#ffbd67;background:#302519bb;border-radius:10px;padding:5px 10px;margin:5px auto;max-width:100%;text-align:center}
