@font-face{font-family:Sora;src:url(../trade/fonts/sora-latin-v17.woff2) format('woff2');font-weight:100 800;font-display:swap}
:root{color-scheme:dark;--bg:#0b0c11;--surface:#14161f;--card:#1b1d27;--edge:#282b39;--edge2:#343849;--text:#eef0f7;--muted:#9096ab;--green:#35d59b;--blue:#55c8f2;--red:#ff5d73}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font:13px Sora,-apple-system,BlinkMacSystemFont,'PingFang SC','Microsoft YaHei',sans-serif;font-variant-numeric:tabular-nums;-webkit-font-smoothing:antialiased}button,input{font:inherit}button{color:inherit;cursor:pointer;border:1px solid var(--edge2);background:var(--card);font-weight:700;touch-action:manipulation;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}button:hover{border-color:#626980}button:disabled{opacity:.45;cursor:default}button:focus-visible,a:focus-visible,input:focus-visible,summary:focus-visible{outline:2px solid var(--blue);outline-offset:3px}a{color:inherit;text-decoration:none}h1,h2,h3,p{margin:0}input{min-width:0;color:var(--text);background:none;border:0;outline:0}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{appearance:textfield}svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}.defs{position:absolute;width:0;height:0;overflow:hidden}[hidden]{display:none!important}button,a,input{-webkit-tap-highlight-color:transparent}
.site{height:60px;border-bottom:1px solid var(--edge);display:flex;align-items:center;padding:0 22px;gap:32px;background:#0a0b10}.brand{display:flex;align-items:center;gap:8px;font-size:19px;font-weight:800;letter-spacing:.02em}.brand svg{width:78px;height:13px;stroke:none}.site nav{display:flex;gap:28px;color:var(--muted);font-weight:700}.site nav a{min-height:44px;display:flex;align-items:center}.site nav a.active{color:var(--text)}.site-wallet{margin-left:auto;background:var(--surface);border:1px solid var(--edge);border-radius:24px;padding:5px 14px;text-align:right}.site-wallet small{font-size:10px;letter-spacing:.06em;display:block;color:var(--muted)}.site-wallet b{font-size:16px;font-weight:800}
.page{max-width:1120px;margin:12px auto 0;padding:0 22px}.game-header{height:62px;display:flex;align-items:center;justify-content:space-between;gap:12px}.identity{display:flex;align-items:center;gap:9px;min-width:0}.game-logo{width:30px;height:30px;object-fit:contain;flex-shrink:0;color:var(--green)}h1{font-size:21px;font-weight:800}.title-help{background:none;border:0;padding:0;min-height:44px;text-align:left;font-weight:800;white-space:nowrap}.title-help span{font-size:12px;letter-spacing:.08em;color:var(--muted);margin-left:5px}.tools{display:flex;align-items:center;gap:7px}.text-tool{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;min-width:44px;padding:0 8px;background:none;border:0;color:var(--muted);font-size:12px}.text-tool:hover{color:var(--text)}.text-tool svg{width:17px;height:17px}.square{width:44px;height:44px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;font-size:22px}.game-frame{height:clamp(500px,calc(100dvh - 200px),680px);border:1px solid var(--edge);border-radius:16px;background:var(--surface);overflow:hidden;display:grid;grid-template-rows:48px minmax(0,1fr) 112px}.empty{font-size:11px;color:var(--muted);white-space:nowrap}.chip{height:44px;min-width:52px;border:0;border-radius:7px;padding:0 9px;white-space:nowrap;flex-shrink:0;font-size:11px;color:var(--muted);background:var(--card)}.chip.win{color:var(--green);background:#35d59b18}
.table{position:relative;min-height:0;isolation:isolate;display:grid;grid-template-rows:1fr 64px 1fr;justify-items:center;padding:44px 60px 18px;gap:0;background-image:radial-gradient(ellipse at 50% 44%,#274a3e30,transparent 66%),linear-gradient(#ffffff02 1px,transparent 1px),linear-gradient(90deg,#ffffff02 1px,transparent 1px);background-size:auto,32px 32px,32px 32px}.table-ring{position:absolute;width:83%;height:78%;top:10%;border:1px solid #75c9ac0e;border-radius:50%;box-shadow:0 0 0 28px #35d59b02;pointer-events:none;z-index:-1}.lane{display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:0;min-height:0;width:100%}.lane-label{display:flex;align-items:center;gap:10px;height:26px;margin-bottom:8px;font-size:12px;font-weight:700;color:#c5cbdb}.score{padding:4px 9px;min-width:28px;border:1px solid #5d6b7f44;border-radius:6px;font-size:12px;color:var(--text);background:#1e2633;line-height:16px}.score.soft{color:#b9ceff}.score.bust{color:var(--red);background:#ff5d7312;border-color:#ff5d732a}.score.win{color:var(--green);background:#35d59b14;border-color:#35d59b33}.cards{height:clamp(78px,calc((100dvh - 434px)/2),142px);display:flex;align-items:center;justify-content:center;position:relative;perspective:1000px;padding:0 12px;max-width:100%}.card{height:100%;aspect-ratio:2.25/3.2;position:relative;flex-shrink:0;transition:transform .4s,opacity .4s;margin-left:var(--overlap,8px);filter:drop-shadow(0 5px 7px #0004)}.card:first-child{margin-left:0}.card-inner{position:absolute;inset:0;transform-style:preserve-3d;transition:transform .55s cubic-bezier(.22,.7,.18,1)}.card.open .card-inner{transform:rotateY(180deg)}/* WebKit can paint a turned-away back's own-layer children through the face; hide the back once the turn passes edge-on. */.card.open .back{visibility:hidden;transition:visibility 0s linear .275s}.face,.back{position:absolute;inset:0;backface-visibility:hidden;-webkit-backface-visibility:hidden;border-radius:8px;overflow:hidden}.face{background:linear-gradient(125deg,#fcfcff,#dfe5ee);color:#182239;transform:rotateY(180deg);border:1px solid #fff9}.face.red{color:#d44160}.corner{position:absolute;top:7px;left:8px;display:flex;flex-direction:column;align-items:center;font-size:19px;font-weight:800;line-height:1.05}.corner small{font-size:13px;margin-top:2px}.corner.bottom{inset:auto 8px 7px auto;transform:rotate(180deg)}.suit{position:absolute;inset:0;display:grid;place-items:center;font-family:Georgia,serif;font-size:43px}.back{display:grid;place-items:center;background:repeating-linear-gradient(45deg,#ffffff04 0 1px,transparent 1px 7px),linear-gradient(135deg,#263e40,#152a2b);border:1px solid #648b8566;box-shadow:inset 0 0 0 5px #172d2e,inset 0 0 0 6px #7eb9a940}.back>i{border:1px solid #8ec9b75c;border-radius:4px;transform:rotate(45deg);display:grid;place-items:center;width:34px;height:34px;color:#b2d6c8;font-size:16px}.back>i b{transform:rotate(-45deg)}.card.arriving{animation:deal .48s cubic-bezier(.15,.65,.2,1) both}.card.placeholder{opacity:.32}.dealer-note{font-size:10px;color:#69778a;margin-top:8px;line-height:14px}.table-message{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:7px;text-align:center;z-index:2;min-height:0}#message{font-size:17px;font-weight:700;letter-spacing:.02em}#subMessage{font-size:10px;color:var(--muted);letter-spacing:.03em}.players{width:100%;min-height:0;display:flex;align-items:center;justify-content:center;gap:24px}.player-hand{position:relative;display:flex;align-items:center;flex-direction:column;min-width:0;flex:0 1 auto;padding:4px 18px 6px;border-radius:13px;transition:background .3s,box-shadow .3s}.player-hand.active{background:#35d59b06;box-shadow:inset 0 0 0 1px #35d59b2a}.player-hand.active .lane-label>span{color:var(--green)}.hand-bottom{display:flex;gap:8px;align-items:center;justify-content:center;margin-top:7px;font-size:10px;color:var(--muted);height:16px;white-space:nowrap}.hand-bottom b{font-size:10px;color:#bdc6d5}.players.split-hands{gap:12px}.split-hands .player-hand{padding:4px 8px 6px;flex:1;max-width:205px}.split-hands .cards{height:clamp(70px,calc((100dvh - 434px)/2),115px)}.split-hands .card{--overlap:-25px}.split-hands .card:first-child{margin-left:0}.shoe{position:absolute;right:42px;top:42%;display:flex;align-items:center;flex-direction:column;gap:12px;color:#586e6b;font-size:10px;letter-spacing:.08em}.shoe i{display:block;width:35px;height:48px;border-radius:5px;background:repeating-linear-gradient(45deg,#ffffff04 0 1px,transparent 1px 6px),#1b302f;border:1px solid #49605c;box-shadow:3px -3px #192725,3px -3px 0 1px #344541,6px -6px #172120,6px -6px 0 1px #2a3a37;transform:rotate(10deg)}
.secondary{display:flex;align-items:center;justify-content:center;gap:8px;border-radius:12px;min-height:44px;padding:0 16px}.action{border-radius:13px;min-height:60px;position:relative;display:flex;align-items:center;justify-content:center;gap:10px;font-weight:800;border:1px solid #ffffff38;overflow:hidden;box-shadow:inset 0 1px #ffffff65,0 3px var(--shadow,#0c7958);transition:filter .15s,transform .15s;flex-shrink:0;color:var(--ink,#06251b);background:linear-gradient(125deg,var(--light,#58e8b4),var(--solid,#30c692))}.action:hover:not(:disabled){filter:brightness(1.07);border-color:#ffffff70}.action:active:not(:disabled){transform:translateY(2px);box-shadow:inset 0 1px #ffffff65,0 1px var(--shadow,#0c7958)}.blue{--light:#8cdcf8;--solid:#44bde7;--shadow:#1b718e;--ink:#07222c}.start-note{display:flex;flex-direction:column;gap:8px;white-space:nowrap}.start-note b{font-size:11px;color:#abb5c5;font-weight:600}.start-note span{font-size:10px;color:#6e788c}.start-button.profit span,.start-button.profit b,.start-button.profit svg{display:none}.start-button.profit small{font-size:16px;position:relative;z-index:1;display:block!important}.start-button.profit:after{content:'';position:absolute;inset:1px;background:linear-gradient(110deg,transparent 35%,#fff9 50%,transparent 65%);background-size:230px 100%;background-repeat:no-repeat;animation:sweep 1s linear infinite;pointer-events:none}.footer{display:flex;justify-content:space-between;align-items:center;padding:13px 2px;color:#71788d;font-size:10px;gap:8px}.footer .text-tool{font-size:10px}.particles{position:absolute;inset:0;pointer-events:none;overflow:hidden}.spark{position:absolute;width:4px;height:4px;background:var(--green);border-radius:1px;left:50%;top:50%;animation:spark 1.2s ease-out both;box-shadow:0 0 6px #35d59b5c}.clearing .card{opacity:0;transform:translateY(-12px);transition:opacity .35s,transform .35s}
@keyframes deal{from{opacity:0;transform:translate(90px,-45px) rotate(12deg)}to{opacity:1;transform:none}}@keyframes receipt{from{opacity:0;scale:.88}to{opacity:1;scale:1}}@keyframes sweep{from{background-position:-230px}to{background-position:300px}}@keyframes spark{to{transform:translate(var(--dx),var(--dy)) rotate(160deg);opacity:0}}
dialog{width:min(520px,calc(100vw - 24px));max-height:calc(100dvh - 24px);padding:0;border:1px solid var(--edge);border-radius:20px;color:var(--text);background:var(--surface);box-shadow:0 30px 100px #0008;overflow:hidden}dialog::backdrop{background:rgb(5 6 11 / 74%);backdrop-filter:blur(7px)}.modal-header{height:74px;padding:0 22px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--edge)}.modal-header h2{font-size:20px;font-weight:800;outline:none}.modal-body{padding:22px;max-height:calc(100dvh - 124px);overflow:auto;overscroll-behavior:contain;line-height:1.8}.info-card{border:1px solid var(--edge);background:var(--card);border-radius:14px;padding:18px;margin-bottom:16px}.info-card h3{font-size:13px;margin-bottom:12px}.info-card p,.muted{color:var(--muted);font-size:12px;line-height:1.9}.info-card:last-child{margin-bottom:0}.help-demo{display:flex;align-items:center;justify-content:center;gap:14px;margin:0 0 22px;padding:6px}.help-card{width:62px;height:88px;border-radius:7px;background:#edf0f7;color:#172338;font-size:23px;font-weight:800;display:flex;flex-direction:column;align-items:center;justify-content:center}.help-card:first-child{transform:rotate(-8deg)}.help-card.red{color:#cc4160;transform:rotate(8deg)}.help-demo>strong{color:var(--green);font-size:23px}.stats{display:grid;grid-template-columns:1fr 1fr;gap:24px}.stats small{display:block;color:var(--muted);font-size:10px;margin-bottom:7px}.stats b{font-size:20px;line-height:1.3;display:block}.modal-body>.muted{margin-top:16px}.form-field{display:flex;flex-direction:column;gap:8px}.form-field label{font-size:12px}.form-field input{height:44px;min-height:44px;border:1px solid var(--edge2);border-radius:10px;background:var(--bg);padding:0 12px;width:100%;font-size:12px}.action-row{display:flex;gap:8px;margin-top:4px;flex-wrap:wrap}.wide{width:100%;margin-top:16px}.record-row{width:100%;display:flex;align-items:center;justify-content:space-between;padding:12px 14px;min-height:64px;border-radius:12px;margin-bottom:8px;text-align:left;gap:16px}.record-row span{display:flex;flex-direction:column;gap:5px}.record-row small{color:var(--muted);font-size:10px}.positive{color:var(--green)}.negative{color:var(--red)}.history-empty{text-align:center;padding:36px 0 44px;color:var(--muted)}.detail-hand{display:flex;align-items:center;justify-content:space-between;margin-top:14px;gap:12px}.detail-hand strong{font-size:14px;letter-spacing:.1em}.toast{position:fixed;bottom:34px;left:50%;transform:translateX(-50%);padding:12px 20px;border:1px solid var(--edge2);border-radius:12px;background:#242a36;z-index:30;font-size:12px;max-width:calc(100% - 32px);text-align:center}.lobby{max-width:1120px;margin:60px auto;padding:0 24px}.eyebrow{color:var(--green);font-size:10px;letter-spacing:.1em}.lobby h2{font-size:32px;margin:16px 0 12px}.lobby p{color:var(--muted);font-size:12px}.lobby-game{width:280px;height:260px;border-radius:18px;background:radial-gradient(ellipse at 50% 0,#35d59b23,transparent 80%),var(--surface);margin-top:32px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:12px}.lobby-game svg{height:70px;width:70px;color:var(--green);stroke-width:1.3;margin-bottom:10px}.lobby-game strong{font-size:20px}.lobby-game>span{color:var(--muted);font-size:10px;letter-spacing:.15em}.lobby-game small{color:var(--green);margin-top:10px}.lobby-note{margin-top:24px}
@media(min-width:761px) and (max-width:1160px){.start-note{display:none}}
@media(min-width:761px) and (max-height:800px){.footer{padding-top:9px;padding-bottom:9px}.table{padding-top:44px;padding-bottom:10px;grid-template-rows:1fr 50px 1fr}.dealer-note{margin-top:5px}.cards{height:clamp(76px,calc((100dvh - 450px)/2),125px)}}
@media(max-width:760px){html{overscroll-behavior-y:contain}.site{display:none;height:50px;padding:0 12px;gap:20px}.brand{font-size:17px}.site nav{gap:16px;font-size:12px}.site nav a:nth-child(n+3){display:none}.site-wallet{display:none}.page{margin:0;padding:0;max-width:none}.game-header{height:58px;padding:0 8px;gap:5px}.identity{gap:4px}.game-logo,.title-help span,.desktop-tool{display:none}.title-help{font-size:15px}.tools{gap:2px}.square{border-radius:10px}.tools .square svg{width:19px;height:19px}.game-frame{height:calc(100svh - 112px - env(safe-area-inset-bottom,0px));min-height:376px;border-radius:0;border-left:0;border-right:0;grid-template-rows:44px minmax(0,1fr) 158px}.empty{font-size:9px}.chip{min-width:48px;font-size:10px;padding:0 8px}.table{padding:44px 18px 10px;grid-template-rows:1fr 54px 1fr}.table-ring{width:96%;height:78%;top:12%}.lane-label{font-size:11px;height:22px;margin-bottom:6px;gap:8px}.score{font-size:11px;padding:2px 7px;line-height:16px}.cards{height:clamp(67px,calc((100svh - 522px)/2),126px);padding:0 8px}.corner{font-size:16px;top:5px;left:6px}.corner small{font-size:11px;margin-top:1px}.corner.bottom{inset:auto 6px 5px auto}.suit{font-size:34px}.face,.back{border-radius:7px}.back{box-shadow:inset 0 0 0 4px #172d2e,inset 0 0 0 5px #7eb9a940}.back>i{width:24px;height:24px;font-size:12px}.dealer-note{font-size:10px;line-height:12px;margin-top:6px}.table-message{gap:6px}#message{font-size:14px}#subMessage{font-size:10px}.hand-bottom{font-size:10px;margin-top:6px;line-height:14px;height:14px}.hand-bottom b{font-size:10px}.player-hand{padding:4px 10px 6px}.shoe{right:20px;top:45%;font-size:10px;gap:8px}.shoe i{width:22px;height:31px;box-shadow:2px -2px #192725,2px -2px 0 1px #344541,4px -4px #172120,4px -4px 0 1px #2a3a37}.players{gap:8px}.players.split-hands{gap:6px;align-items:center;flex-wrap:nowrap;overflow-x:auto;justify-content:flex-start;padding:3px 2px;scrollbar-width:thin}.split-hands .player-hand{flex:0 0 calc(50% - 3px);max-width:none;padding:4px 5px 6px}.split-hands .cards{height:clamp(62px,calc((100svh - 522px)/2),106px)}.split-hands .card{--overlap:-24px}.start-note{display:none}.start-button.profit small{font-size:13px}.footer{height:calc(54px + env(safe-area-inset-bottom,0px));padding:0 12px env(safe-area-inset-bottom,0px);font-size:10px;margin-bottom:0;align-items:center}.footer .text-tool{font-size:10px}.modal-header{height:66px;padding:0 18px}.modal-header h2{font-size:20px}.modal-body{padding:18px;max-height:calc(100dvh - 108px);padding-bottom:calc(18px + env(safe-area-inset-bottom,0px))}.info-card{padding:16px}.stats{gap:24px 14px}.stats b{font-size:19px}.lobby{margin:35px auto}.lobby-game{width:100%;max-width:320px}.toast{font-size:11px;bottom:24px}}
@media(max-width:360px){.site nav{gap:14px}.game-header{gap:4px}.title-help{font-size:15px}.table{padding-left:12px;padding-right:12px}}
@media(max-width:760px) and (max-height:650px){.table{padding-top:44px;padding-bottom:6px;grid-template-rows:1fr 40px 1fr}.lane-label{margin-bottom:4px;height:20px}.dealer-note{margin-top:4px;font-size:10px}.cards{height:66px}.suit{font-size:25px}.corner{font-size:12px;left:5px;top:4px}.corner small{font-size:10px}.corner.bottom{right:5px;bottom:4px}.table-message{gap:3px}#message{font-size:12px}#subMessage{font-size:10px}.hand-bottom{margin-top:4px;font-size:10px}.split-hands .cards{height:62px}.shoe{display:none}}
@media(max-width:760px) and (orientation:landscape){.game-frame{min-height:420px}.cards{height:90px}.split-hands .cards{height:84px}.footer{margin-bottom:20px}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important}.start-button.profit:after{display:none}.particles{display:none}}
/* Keep both hands within their fixed tracks at each family viewport. */
@media(min-width:761px){.cards{height:clamp(76px,calc((100dvh - 594px)/2),142px)}.split-hands .cards{height:clamp(70px,calc((100dvh - 594px)/2),115px)}}
.card.placeholder{opacity:.62}.player-hand{flex-shrink:1}.table-message{align-self:stretch}
@media(max-width:760px){.dealer-note{display:none}.cards{height:clamp(62px,calc((100svh - 598px)/2),126px)}.split-hands .cards{height:clamp(58px,calc((100svh - 598px)/2),106px)}}
@media(max-width:760px) and (max-height:720px){.hand-bottom{display:none}.player-hand{padding-top:2px;padding-bottom:2px}.table .lane-label{height:20px;margin-bottom:4px}.cards{height:clamp(58px,calc((100svh - 544px)/2),100px)}.split-hands .cards{height:clamp(54px,calc((100svh - 544px)/2),90px)}}
@media(max-width:760px) and (max-height:620px){.table{grid-template-rows:1fr 30px 1fr}.cards,.split-hands .cards{height:48px}.table .lane-label{height:18px;margin-bottom:4px}.table-message{gap:2px}#message{font-size:11px}#subMessage{font-size:10px}.corner{font-size:10px;left:4px;top:3px}.corner small{font-size:10px}.corner.bottom{right:4px;bottom:3px}.suit{font-size:20px}.back>i{width:18px;height:18px;font-size:9px}.players .player-hand{padding-top:0;padding-bottom:0}}
/* A compact win receipt leaves every final card and hand score visible. */



@media(max-width:760px) and (max-height:620px) and (orientation:portrait){.game-frame{min-height:372px}}

.start-button.profit span{display:inline;font-size:11px}.start-button.profit small{font-size:13px}
@media(max-width:360px){.start-button.profit span{font-size:10px}.start-button.profit small{font-size:12px}}

/* Account/recovery controls retain the existing family entry points. */
.acct{display:flex;align-items:center;gap:8px}.acct button{min-height:44px;border-radius:10px;padding:0 12px;font-size:11px}.addr{max-width:110px;overflow:hidden;text-overflow:ellipsis;font-size:10px;color:var(--muted)}.note{padding:10px 18px;border-bottom:1px solid var(--edge);color:var(--muted)}#clock{font-size:10px;color:var(--muted)}.record-row>span:last-child{text-align:right}.record-row>span{min-width:0}.record-row small{overflow-wrap:anywhere}.modal-body input{width:100%}.verification{white-space:pre-wrap;overflow-wrap:anywhere;color:var(--muted);font-size:11px}.form-field .action-row{margin-top:4px}.players.split-hands .player-hand{flex-shrink:0}
@media(max-width:760px){.acct{margin-left:auto}.addr{max-width:80px}.acct button{padding:0 8px;font-size:10px}.site{gap:12px}.site nav{gap:12px}.site nav a:not(:first-child){display:none}.site-wallet{display:none}.players.split-hands .player-hand{flex:0 0 46%}.modal-header{height:66px;padding:0 18px}.modal-body{padding:18px;max-height:calc(100dvh - 114px)}}
@media(prefers-reduced-motion:reduce){.card.arriving{outline:1px solid #8ec9b7}}

/* The decision clock uses the table margin, preserving the two-line center. */
#clock{position:absolute;right:16px;top:10px;font-size:10px;white-space:nowrap}
@media(max-width:760px){#clock{right:10px;top:8px;font-size:10px}}

/* Fairness evidence stays available on demand, with the family field spacing. */
.modal-body details{border-top:1px solid var(--edge);margin-top:12px;padding-top:8px}.modal-body summary{min-height:44px;display:flex;align-items:center;cursor:pointer;color:var(--muted);font-size:12px}.modal-body details .verification{padding-top:8px}.form-field .action-row{margin-top:4px}.info-card>.action-row{margin-top:12px}

/* Mobile wager entry above the full-width game actions. */










/* Fairness-only field/action rhythm and explicit receipt tools. */
#modal[data-fairness="settings"] .section-card,#modal[data-fairness="settings"] .card,#modal[data-fairness="settings"] .info-card{margin-bottom:14px}#modal[data-fairness="settings"] .form-field,#modal[data-fairness="settings"] .seed-field,#modal[data-fairness="settings"] .fair-field{display:block;margin:0}
#modal[data-fairness="settings"] label{display:block;font-size:10px;font-weight:700;color:#9096ab;line-height:1.5;margin:0 0 8px}#modal[data-fairness="settings"] input[maxlength]{display:block;width:100%;min-width:0;height:44px;min-height:44px;padding:0 12px;font-size:13px}
#modal[data-fairness="settings"] .action-row,#modal[data-fairness="settings"] .fair-buttons,#modal[data-fairness="detail"] .action-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-top:12px}#modal[data-fairness="settings"] .primary,#modal[data-fairness="detail"] .primary{background:#eef0f7;color:#14161f}
#modal[data-fairness="settings"] .form-field>small,#modal[data-fairness="settings"] .seed-field>small,#modal[data-fairness="settings"] .fair-field>small{display:block;margin-top:8px;font-size:11px;line-height:1.7;color:#9096ab}#modal[data-fairness="settings"] button,#modal[data-fairness="detail"] button{min-height:44px;font-size:12px}#modal[data-fairness="settings"] p:empty{display:none}
#modal .receipt-export{margin-top:12px;overflow-wrap:anywhere}#modal .receipt-export p{font-size:12px;line-height:1.8;color:#9096ab;margin:0}#modal .receipt-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}#modal .receipt-download,#modal .receipt-copy{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:9px 14px;border:1px solid #343849;border-radius:10px;background:#1b1d27;color:#eef0f7;font:700 12px Sora,sans-serif;text-decoration:none}#modal .receipt-export textarea{display:block;width:100%;max-width:100%;min-height:140px;margin-top:12px;padding:12px;border:1px solid #343849;border-radius:9px;background:#0b0c11;color:#eef0f7;font:12px monospace;user-select:text}
#modal[data-fairness="settings"] button,#modal[data-fairness="detail"] button{border-radius:10px;font-weight:700;padding:9px 14px}#modal[data-fairness="settings"] .section-card,#modal[data-fairness="settings"] .card,#modal[data-fairness="settings"] .info-card{padding:17px}#modal[data-fairness="settings"] p{font-size:13px;line-height:1.8}@media(max-width:760px){#modal[data-fairness="settings"] .section-card,#modal[data-fairness="settings"] .card,#modal[data-fairness="settings"] .info-card{padding:15px}}



/* HEADER-BALANCE-INT-01：窄屏顶栏余额只显示整数，截断不进位（setHeaderBalance，见 public/trade/wallet-connect.js）。 */
.hb-narrow{display:none}
@media(max-width:760px){.mobile-balance .hb-wide{display:none}.mobile-balance .hb-narrow{display:inline}}

/* GAMES-MOBILE-ONE-SCREEN-01: a portrait phone shows the whole game in one visual viewport; short landscape keeps its earlier
   scrolling layout. GAMES-SHARED-AUTO-STATUS-01 amendment C2: the shared status strip does not take its height out of the frame;
   the body grows by it, so the page moves down and scrolls and split hands keep their room. Header, recent row and controls keep
   their size; the table (.table, a size container) sizes the cards from what is left, never larger than the size above. Card
   corners and suit follow the card size and never grow past the sizes above. The frame floor (368px) keeps 48px cards at
   the shortest spacing; under it the page scrolls and nothing is cut. */
/* Amendment C2 on desktop too: the earlier clamp, not the shared one that subtracts the strip (navigation.css). */
@media(min-width:761px){.page>.game-frame{height:clamp(500px,calc(100dvh - 200px),680px)}}
@supports(container-type:size){
@media(max-width:760px) and (orientation:portrait){
 body{display:flex;flex-direction:column;min-height:calc(100vh + var(--status-height,0px));min-height:calc(100dvh + var(--status-height,0px))}
 body>.page{flex:1 0 auto;display:flex;flex-direction:column;width:100%}
 .page>.game-frame{flex:1 0 auto;height:auto;min-height:368px}
 .table{container-type:size;--bj-fit:calc((100cqh - 192px)/2)}
 .cards{--bj-card:max(48px,min(clamp(62px,calc((100svh - 566px)/2),126px),var(--bj-fit)));height:var(--bj-card)}
 .split-hands .cards{--bj-card:max(48px,min(clamp(58px,calc((100svh - 566px)/2),106px),var(--bj-fit)))}
 .corner{font-size:min(16px,calc(var(--bj-card)*.21))}
 .corner small{font-size:max(10px,min(11px,calc(var(--bj-card)*.146)))}
 .suit{font-size:min(34px,calc(var(--bj-card)*.42))}
 .back>i{width:min(24px,calc(var(--bj-card)*.375));height:min(24px,calc(var(--bj-card)*.375));font-size:min(12px,calc(var(--bj-card)*.19))}
}
@media(max-width:760px) and (orientation:portrait) and (max-height:720px){
 .table{--bj-fit:calc((100cqh - 132px)/2)}
 .cards{--bj-card:max(48px,min(clamp(58px,calc((100svh - 512px)/2),100px),var(--bj-fit)))}
 .split-hands .cards{--bj-card:max(48px,min(clamp(54px,calc((100svh - 512px)/2),90px),var(--bj-fit)))}
}
@media(max-width:760px) and (orientation:portrait) and (max-height:650px){
 .table{--bj-fit:calc((100cqh - 108px)/2)}
 .corner{font-size:min(12px,calc(var(--bj-card)*.21))}
 .corner small{font-size:10px}
 .suit{font-size:min(25px,calc(var(--bj-card)*.42))}
}
@media(max-width:760px) and (orientation:portrait) and (max-height:620px){
 .cards,.split-hands .cards{--bj-card:48px}
 .corner{font-size:10px}
 .corner small{font-size:10px}
 .suit{font-size:20px}
 .back>i{width:18px;height:18px;font-size:9px}
}
}
/* GAMES-GUEST-DEMO-01 amendment C: the guest login button sits right after the footer note. */
.guest-login{margin-right:auto}

/* GAMES-SHARED-SHELL-01 revision D (owner decisions 22-24, README 9.4/9.7): the start button keeps its play icon; the four
   in-round buttons show only the 20px word; the insurance row is the dealer note plus two shell buttons as wide as their words. */
.controls-bar .decisions .direction-button>svg{display:none}
.controls-bar .insurance.direction-buttons{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:8px;align-items:center}
.controls-bar .insurance>span{font-size:10px;font-weight:700;line-height:14px;color:#eef0f7}
.controls-bar .insurance>span small{display:block;margin-top:2px;color:#9096ab;font-size:10px;font-weight:700}
.controls-bar .insurance .direction-button{flex:none;padding:0 12px}
@media(min-width:761px){.controls-bar .insurance>span{font-size:12px}.controls-bar .insurance .direction-button{padding:0 18px}}
/* The prototype draws the start button alone in the bet row at both widths; the start note beside it on the desktop goes. */
.controls-bar .start-note{display:none}
/* GAMES-WIN-LOSS-FEEDBACK-01 (DESIGN.md 触控区怎么量): the sound credit links in the help dialog take a 44px tap. */
dialog details a[href]{display:inline-block;min-width:44px;min-height:44px;line-height:44px;text-align:center}
/* GAMES-WIN-LOSS-FEEDBACK-01: the table's top padding is 44px (DESIGN.md 顶部留位) and its bottom padding is not, so the settlement receipt
   is centred on the table's content (its middle row), half the padding difference below the table's own middle, as it was when the
   paddings were even; it then clears the dealer's and the player's cards. */




/* It must also clear both rows' labels and scores. Desktops up to 800px high take the short spacing below, where the cards fill what
   the rows leave, so 70.5px stay free between the dealer's cards and the player's label at every height; the 50px receipt sits in the
   middle of them (7px under the table's middle, 10px clear on each side). Landscape phones keep 90px cards, which overflow their rows
   into the middle one; the frame's floor goes from 420px to 440px so 36px stay free, and the compact receipt sits in the middle of them. */
@media(max-width:760px) and (orientation:landscape){.game-frame{min-height:440px}}
/* With the 44px top padding a desktop up to 760px high (the frame stops at 500px) has 117px rows: 76px cards no longer fitted, the
   dealer's row was squeezed to 64px under 76px faces and the player's hand ran out of the table across the message. Up to 800px high
   the rows take the short phones' spacing (22px labels, 2px hand padding) and the cards take what the rows leave, the same in both
   rows: 67px at a 500px frame, 76px at 718px high, 97px at 760px, 117px at 800px (split hands stop at 115px). The faces scale with
   the card (the corner rank keeps 10px), reaching the desktop's 19px corner from 91px cards and 43px suit from 113px, so nothing
   jumps at 760/761px. The suit takes .38 of the card, not the phones' .42, and the corners sit 5px/6px in as on phones, not 7px/8px:
   the suit glyph comes from a fallback font (no Georgia on Linux or Android, DejaVu Serif or Noto Serif instead) that draws it about
   4.5px higher on a 67px card than macOS does, so at .42 with 7px/8px a Q met the suit (macOS kept 0.07px under the Q, Linux crossed
   by 1px); now macOS keeps at least 3.1px between every rank and the suit, top and bottom. Above 800px the rows keep the desktop
   spacing and the cards start again from 100.5px. */
@media(min-width:761px) and (max-height:800px){
 .table .lane-label{height:22px;margin-bottom:4px}.player-hand,.split-hands .player-hand{padding-top:2px;padding-bottom:2px}.hand-bottom{margin-top:4px}.dealer-note{margin-top:3px}
 .cards{--bj-card:min(142px,calc((max(500px,100dvh - 200px) - 366px)/2));height:var(--bj-card)}
 .split-hands .cards{--bj-card:min(115px,calc((max(500px,100dvh - 200px) - 366px)/2));height:var(--bj-card)}
 .corner{top:5px;left:6px;font-size:max(10px,min(19px,calc(var(--bj-card)*.21)))}.corner.bottom{inset:auto 6px 5px auto}.corner small{font-size:max(10px,min(13px,calc(var(--bj-card)*.146)))}.suit{font-size:min(43px,calc(var(--bj-card)*.38))}
}
/* Above 800px high the dealer's row (label, cards, note) is 56px taller than its cards and the rows are (frame - 288px) / 2, so the
   dealer's cards were 2-3px shorter than the player's; both rows now take what the dealer's row leaves (100.5px at 801px high, 140px
   from 880px, split hands stop at 115px). The earlier (100dvh - 594px) / 2 is at least 2px larger at every height here, so it is not kept. */
@media(min-width:761px) and (min-height:801px){.cards{height:calc((clamp(500px,100dvh - 200px,680px) - 400px)/2)}.split-hands .cards{height:min(115px,calc((clamp(500px,100dvh - 200px,680px) - 400px)/2))}}
/* Portrait phones size the cards from the table (--bj-card above), but split hands kept the fallback height (its selector is more
   specific), which the 44px top padding made 16px smaller than the dealer's row (61.5px against 77.5px at 375x667, where the
   corner touched the suit). Split hands take --bj-card too; they still stop at their own smaller cap (106px, 90px under 720px high). */
@supports(container-type:size){@media(max-width:760px) and (orientation:portrait){.split-hands .cards{height:var(--bj-card)}}}

#modal[open]{display:flex;flex-direction:column}#modal .modal-header{flex:none}#modal .modal-body{min-height:0;max-height:none}#modalClose{background:none;border:1px solid #343849;border-radius:10px}
