.bet-filters{display:flex;align-items:flex-end;flex-wrap:wrap;gap:10px;margin:16px 0 8px}.bet-filters label{display:flex;flex-direction:column;gap:6px;min-width:120px;font-size:11px;color:var(--muted)}.bet-filters input,.bet-filters select{height:36px;padding:7px 10px;border-radius:7px;border:1px solid var(--line);background:var(--input);color:var(--text);font:inherit;min-width:0}.bet-filters button{min-height:36px;padding:8px 13px;font-size:12px}.bet-filters button:disabled{opacity:.5;cursor:not-allowed}.bet-filter-hint{color:var(--muted);font-size:11px;margin:6px 0 12px}.bet-summary{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0 18px}.bet-summary>div{flex:1;min-width:110px;border:1px solid var(--line);background:var(--input);border-radius:8px;padding:10px 12px}.bet-summary small{display:block;color:var(--muted);font-size:10px;margin-bottom:6px}.bet-summary strong{font-size:13px;font-variant-numeric:tabular-nums}.history-filter-panel .field-error:empty{display:none}.play-history-dialog{width:min(920px,calc(100vw - 30px));max-height:92dvh}.play-history-dialog .history-table-wrap{max-height:44dvh}.history-filter-panel+.history-table-wrap{border-top:1px solid var(--line)}#captcha-letters img{display:block;max-width:100%;height:auto}.center-form button:disabled{opacity:.55;cursor:wait}
@media(max-width:600px){.bet-filters{gap:8px}.bet-filters label{flex:1 1 42%;min-width:0}.bet-filters input,.bet-filters select{width:100%}.bet-summary>div{min-width:90px}.play-history-dialog{padding:15px}.play-history-dialog .history-table-wrap{max-height:34dvh}.bet-summary{margin-bottom:10px;gap:6px}.bet-summary>div{padding:7px 9px}.bet-summary strong{font-size:11px}}
/* Stable three-column history across digit, tile and card games. */
#play-section .history-panel .history-row{grid-template-columns:minmax(105px,1fr) minmax(88px,1fr) 65px;min-height:36px;padding:3px 0;gap:6px;box-sizing:border-box}
#play-section .history-panel .history-digits{min-width:0;font-size:13px;letter-spacing:0;text-align:center;overflow:hidden}
#play-section .history-panel .history-digits[data-paired=true]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2px 5px;font-size:11px}
#play-section .history-hand{display:flex;align-items:center;justify-content:center;gap:3px;white-space:nowrap;min-width:0}
#play-section .history-hand small{font-size:9px;color:var(--muted);font-weight:400}
#play-section .history-hand b{font-size:inherit;overflow:hidden;text-overflow:ellipsis}
#play-section .history-panel .outcome-pill{white-space:normal;line-height:1.3;font-size:10px;padding:4px 3px}
#play-section .history-panel .history-row[data-waiting=true] .history-digits{color:var(--muted)}
@media(max-width:700px){#play-section .history-panel .history-row{grid-template-columns:minmax(100px,1fr) minmax(85px,1fr) 60px;gap:4px}#play-section .history-panel .history-digits[data-paired=true]{font-size:10px}}
/* The result area contains the centered outcome; prices remain in the market panel. */
#play-section .result-explanation{height:140px;display:flex;align-items:center;justify-content:center;padding:0 5px}
#play-section #raw-price{display:none}
#play-section #last-outcome{width:100%;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:9px;text-align:center;white-space:normal;overflow:hidden}
#play-section .result-title{font-size:13px;font-weight:500;color:var(--muted)}
#play-section .result-value{font-size:25px;line-height:1.3;font-weight:650;text-align:center}
#play-section .result-period{font-size:10px;line-height:1.5;color:var(--muted);overflow-wrap:anywhere;max-width:100%}
@media(max-width:700px){#play-section .result-explanation{height:100px;padding:0}#play-section #last-outcome{gap:5px}#play-section .result-title{font-size:10px}#play-section .result-value{font-size:18px}#play-section .result-period{font-size:8px}}
#play-section[data-four=true] .baccarat-hands{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;padding:0 7px;box-sizing:border-box}
#play-section[data-four=true] .baccarat-hand{min-width:0}
#play-section[data-mode=niuniu][data-four=true] .hand-cards{width:100%;justify-content:center;gap:1px}
#play-section[data-mode=niuniu][data-four=true] .baccarat-hand .playing-card{width:auto;min-width:0;max-width:11px;flex:1 1 0;height:20px}
#play-section[data-four=true] .hand-caption,#play-section[data-four=true] .hand-points{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#play-section #last-time{display:none}
/* Mobile: interval first, modes second, both use the complete available row. */
@media(max-width:700px){
 #play-section .play-header-shell .play-toolbar{display:flex;flex-direction:column;align-items:stretch;gap:7px}
 #play-section .play-header-shell .period-tabs{order:0;width:100%;margin:0;box-sizing:border-box;justify-content:space-between}
 #play-section .play-header-shell .period-tabs button{flex:1;min-width:0;padding:7px 4px}
 #play-section .play-header-shell .play-tabs{order:1;width:100%;max-width:none;margin:0;box-sizing:border-box;display:flex;flex-wrap:wrap;gap:3px;overflow:visible;justify-content:stretch}
 #play-section .play-header-shell .play-tabs button{flex:1 1 calc(20% - 3px);min-width:0;min-height:30px;padding:5px 3px;text-align:center;font-size:11px}
 #play-section .play-header-shell .play-tabs .mode-order-edit{border-left:0;border-radius:5px;padding-left:3px}
 html[lang=en] #play-section .play-header-shell .play-tabs button{flex-basis:calc(33.333% - 3px);font-size:10px}
}
@media(min-width:540px) and (max-width:700px){#play-section .play-header-shell .play-tabs button{flex:1 1 0;font-size:12px}html[lang=en] #play-section .play-header-shell .play-tabs button{flex:1 1 calc(20% - 3px);font-size:11px}}
#play-section #prediction-label{color:var(--accent);font-weight:750;font-size:14px;line-height:1.5;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
@media(max-width:430px){#play-section #prediction-label{font-size:12px;max-width:calc(100% - 75px)}}
/* Reuse the choice seals to identify both sides of every Dragon/Tiger table. */
#play-section .card-table .table-side-emblem{display:none;position:absolute;top:50%;transform:translateY(-50%);width:48px;height:48px;margin:0;z-index:4;pointer-events:none}
#play-section[data-mode=dragon] .card-table .table-side-emblem{display:block}
#play-section .card-table .table-side-emblem.emblem-dragon{left:12px}
#play-section .card-table .table-side-emblem.emblem-tiger{left:auto;right:12px}
#play-section[data-mode=dragon] .baccarat-hands{box-sizing:border-box;padding-inline:65px;gap:12px}
@media(max-width:700px){
 #play-section .card-table .table-side-emblem{width:22px;height:22px}
 #play-section .card-table .table-side-emblem.emblem-dragon{left:5px}
 #play-section .card-table .table-side-emblem.emblem-tiger{right:5px}
 #play-section[data-mode=dragon] .baccarat-hands{padding-inline:30px;gap:6px}
 #play-section[data-mode=dragon] .baccarat-hand .playing-card{width:18px;height:28px}
 #play-section[data-mode=dragon] .hand-cards{gap:1px}
}

.bet-summary>div[data-result=loss] strong{color:#eb8585}.bet-summary>div[data-result=profit] strong{color:#83b5ff}.bet-summary>div[data-result=even] strong{color:var(--text)}

#play-section[data-mode=jinhua] .history-hand small{display:inline-block;flex-shrink:0}
#play-section[data-mode=jinhua] .history-hand[data-winner=true],#play-section[data-mode=jinhua] .history-hand[data-winner=true] small,#play-section[data-mode=jinhua] .history-hand[data-winner=true] b{color:var(--accent);font-weight:700}
