

.table-container.dice-table {
	margin: 40px 0 0;
	/*text-align: center;*/
}

.table-container.dice-table .table-column {
	padding-left: 40px !important;
}

.table-container.dice-table .table-row {
	border-bottom: 0;	
}

.table-container.dice-table .table-body .table-row {
	padding: 10px 0;
}

.table-container.dice-table .table-row i {
	color: #ffc34c;
	margin-left: 3px;
}

.table-container.dice-table .table-row:nth-child(even) {
	/*border-bottom: 0;*/
	background: var(--site-color-bg-dark);
}

.table-container.dice-table .table-header {
	background: var(--site-color-bg-light);
	border: 0;
	color: #596076;
}

.table-container.dice-table .table-body {
	/*x*/
}

.table-container.dice-table .avatar {
	border-width: 2px;
	margin-right: 5px;
}
.wheel-risk-btn.active { background: #8d3bde; border-color: #8d3bde; color: #fff; }
.bcr-side.active { border-color: #8d3bde; background: rgba(141,59,222,0.18); }
.dt-page #dt_side_dragon:hover,.dt-page #dt_side_dragon.active { border-color: rgba(255,107,107,.5); background: linear-gradient(145deg,rgba(210,58,58,.24),rgba(75,20,20,.24)); }
.dt-page #dt_side_tie:hover,.dt-page #dt_side_tie.active { border-color: rgba(244,201,93,.5); background: linear-gradient(145deg,rgba(173,126,30,.22),rgba(71,51,15,.24)); }
.dt-page #dt_side_tiger:hover,.dt-page #dt_side_tiger.active { border-color: rgba(244,150,60,.5); background: linear-gradient(145deg,rgba(186,109,45,.22),rgba(74,42,18,.24)); }
.dt-page #dt_side_dragon.active .dt-side-pays { color: #ff8f8f; }
.dt-page #dt_side_tie.active .dt-side-pays { color: #f4c95d; }
.dt-page #dt_side_tiger.active .dt-side-pays { color: #ffb066; }
.dt-page .dt-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.dt-page .dt-history .table-header { background: rgba(255,255,255,.025); }

/* =========================================
   KENO GAME
   ========================================= */

.kn-game-layout {
    display: flex;
    border-radius: 8px;
    overflow: hidden;
    min-height: 520px;
    margin-bottom: 24px;
}

/* ── Left panel ── */
.kn-controls {
    width: clamp(260px, 28vw, 340px);
    min-width: 240px;
    background: #3b274f;
    border-right: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 16px;
}
.kn-segment { display: flex; flex-direction: column; gap: 6px; }
.kn-label { font-size: 14px; color: #dbdbdb; font-weight: 400; }
.kn-input-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    padding: 10px 12px;
    box-sizing: border-box;
}
.kn-input-icon { color: #acacac; font-size: 14px; font-weight: 600; flex-shrink: 0; }
.kn-input {
    background: transparent !important;
    border: none !important;
    color: #fff !important;
    font-size: 16px;
    font-weight: 500;
    flex: 1;
    min-width: 0;
    outline: none;
    padding: 0;
}
.kn-chips { display: flex; gap: 4px; flex-shrink: 0; }
.kn-chip {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 4px;
    color: #acacac;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}
.kn-chip:hover { background: rgba(255,255,255,0.08); color: #fff; }

.kn-picks-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.kn-pick-actions { display: flex; gap: 4px; }

/* Paytable */
.kn-paytable {
    display: flex;
    flex-direction: column;
    gap: 3px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    padding: 10px 12px;
    max-height: 200px;
    overflow-y: auto;
    scrollbar-width: thin;
}
.kn-paytable-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: rgba(255,255,255,0.75);
}
.kn-paytable-row span:last-child { color: #fff; font-weight: 700; }
.kn-paytable-empty { font-size: 12px; color: rgba(255,255,255,0.4); }

.kn-btn-place {
    width: 100%;
    height: 52px;
    background: #8d3bde;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    flex-shrink: 0;
    margin-top: auto;
}
.kn-btn-place:hover { background: #7c2fcf; }
.kn-btn-place.disabled { opacity: 0.55; cursor: not-allowed; }

/* ── Right panel ── */
.kn-stage {
    flex: 1;
    background: #2b2333;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.kn-header {
    background: #3b274f;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 24px;
    flex-shrink: 0;
}
.kn-header-left { display: flex; align-items: center; gap: 8px; }
.kn-header-icon { width: 20px; height: 20px; object-fit: contain; flex-shrink: 0; }
.kn-header-title { font-size: 15px; font-weight: 600; color: #fff; }
.kn-info-icon { color: rgba(255,255,255,0.35); font-size: 14px; cursor: default; }
.kn-fair-link {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255,255,255,0.55) !important;
    text-decoration: none !important;
    transition: color 0.15s;
}
.kn-fair-link:hover { color: #fff !important; }

/* ── Display area ── */
.kn-display-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px 24px;
    gap: 18px;
}

.kn-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
    width: 100%;
    max-width: 560px;
}
.kn-cell {
    aspect-ratio: 1;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 8px;
    color: #dbdbdb;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.12s, border-color 0.12s, transform 0.08s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.kn-cell:hover { background: rgba(255,255,255,0.1); }
.kn-cell:active { transform: scale(0.94); }
.kn-cell.picked {
    background: rgba(141,59,222,0.28);
    border-color: #8d3bde;
    color: #fff;
}
.kn-cell.drawn {
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.35);
    color: #fff;
    animation: kn-pop 0.25s ease-out;
}
.kn-cell.hit {
    background: rgba(9,185,91,0.35) !important;
    border-color: #09b95b !important;
    color: #fff;
    animation: kn-pop 0.25s ease-out;
}
.kn-cell.miss { opacity: 0.45; }

.kn-hint {
    min-height: 20px;
    font-size: 14px;
    color: rgba(255,255,255,0.45);
    text-align: center;
}
.kn-hint.win  { color: #09b95b; font-weight: 600; }
.kn-hint.lose { color: #e84040; font-weight: 600; }

/* ── Responsive ── */
@media (max-width: 900px) {
    .kn-controls { width: 280px; min-width: 220px; }}

@media (max-width: 768px), (pointer: coarse) and (max-width: 1199px) and (max-height: 600px) and (orientation: landscape) {
    .kn-game-layout { flex-direction: column; min-height: unset; }
    .kn-stage { order: 1; }
    .kn-controls  { order: 2; width: 100%; min-width: unset; }
    .kn-display-area { padding: 16px 10px; gap: 12px; }
    .kn-grid { gap: 5px; max-width: 100%; }
    .kn-cell { font-size: 13px; border-radius: 6px; }}
.av-speed-btn.active {
    background: rgba(242,181,60,0.16);
    border-color: rgba(242,181,60,0.5);
    color: #f2b53c;
}
.pk-risk-btn.active { background: #8d3bde; color: #fff; }

/* Compact (tablet + mobile) layout. The sidebar collapses to a drawer at
   1024px, so the responsive tables switch to the compact grid here too. */
@media (max-width: 1024px) {

    .dice-history .table-row {
        grid-template-columns: minmax(0, 1.35fr) minmax(68px, 0.75fr) minmax(54px, 0.6fr) minmax(76px, 0.85fr);
    }

    .dice-history .table-row > .table-column:nth-child(4),
    .dice-history .table-row > .table-column:nth-child(5) {
        display: none;
    }}
.hilo-page .hilo-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.hilo-page .hilo-history .table-header { background: rgba(255,255,255,.025); }
.dice-page .dice-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.dice-page .dice-history .table-header { background: rgba(255,255,255,.025); }
.limbo-page .limbo-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.limbo-page .limbo-history .table-header { background: rgba(255,255,255,.025); }
.wheel-page .wheel-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.wheel-page .wheel-history .table-header { background: rgba(255,255,255,.025); }.rps-page .rps-move:hover:before,.rps-page .rps-move.active:before{opacity:.5;transform:scale(1.4)}.rps-page #rps_move_rock.active{border-color:rgba(168,115,239,.62)!important;box-shadow:inset 0 0 22px rgba(139,77,218,.16),0 8px 20px rgba(50,24,84,.2)}.rps-page #rps_move_rock.active i{color:#b989f5}.rps-page #rps_move_paper.active{border-color:rgba(95,209,207,.55)!important;box-shadow:inset 0 0 22px rgba(63,181,179,.13),0 8px 20px rgba(22,77,76,.18)}.rps-page #rps_move_paper.active i{color:#69d9d5}.rps-page #rps_move_scissors.active{border-color:rgba(244,201,93,.55)!important;box-shadow:inset 0 0 22px rgba(214,166,56,.13),0 8px 20px rgba(85,61,18,.18)}.rps-page #rps_move_scissors.active i{color:#f4d171}
.bj-page .bj-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.bj-page .bj-history .table-header { background: rgba(255,255,255,.025); }
.bcr-page #bcr_side_player:hover,.bcr-page #bcr_side_player.active { border-color: rgba(106,148,255,.5); background: linear-gradient(145deg,rgba(50,93,202,.24),rgba(21,36,81,.24)); }
.bcr-page #bcr_side_tie:hover,.bcr-page #bcr_side_tie.active { border-color: rgba(244,201,93,.5); background: linear-gradient(145deg,rgba(173,126,30,.22),rgba(71,51,15,.24)); }
.bcr-page #bcr_side_banker:hover,.bcr-page #bcr_side_banker.active { border-color: rgba(244,92,122,.5); background: linear-gradient(145deg,rgba(186,45,78,.22),rgba(74,18,36,.24)); }
.bcr-page #bcr_side_player.active .bcr-side-pays { color: #82a6ff; }
.bcr-page #bcr_side_tie.active .bcr-side-pays { color: #f4c95d; }
.bcr-page #bcr_side_banker.active .bcr-side-pays { color: #ff7892; }
.bcr-page .bcr-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.bcr-page .bcr-history .table-header { background: rgba(255,255,255,.025); }
.rps-page .rps-move.active { border-color: rgba(40,199,160,.55); background: linear-gradient(145deg,rgba(24,164,131,.24),rgba(12,68,55,.24)); }
.rps-page .rps-move.active i { color: #28C7A0; }
.rps-page .rps-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.rps-page .rps-history .table-header { background: rgba(255,255,255,.025); }

/* =========================================
   KENO 2026 UI REFRESH
   ========================================= */
.kn-page { max-width: 1240px; margin: 0 auto; padding: 24px 22px 42px; box-sizing: border-box; text-align: left; }
.kn-page-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.kn-page-identity { display: flex; align-items: center; gap: 12px; }
.kn-page-icon { display: grid; width: 46px; height: 46px; place-items: center; border: 1px solid rgba(171,120,255,.3); border-radius: 14px; background: linear-gradient(145deg,rgba(132,71,234,.26),rgba(43,22,76,.52)); box-shadow: inset 0 1px rgba(255,255,255,.08),0 12px 25px rgba(10,5,22,.24); }
.kn-page-icon img { width: 25px; height: 25px; object-fit: contain; }
.kn-page-kicker { display: block; margin-bottom: 2px; color: #8d829a; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.kn-page-identity h1 { margin: 0; color: #fff; font-size: 24px; line-height: 1.1; letter-spacing: -.025em; }
.kn-page-actions { display: flex; align-items: center; gap: 8px; }
.kn-how-button,.kn-top-fair { display: inline-flex; height: 36px; align-items: center; gap: 7px; padding: 0 12px; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; background: rgba(255,255,255,.035); color: #aaa2b4; font: 700 11px/1 Arial,sans-serif; text-decoration: none; box-sizing: border-box; }
.kn-how-button { cursor: pointer; }
.kn-how-button:hover,.kn-top-fair:hover { border-color: rgba(163,108,255,.32); background: rgba(135,74,232,.1); color: #fff; }
.kn-top-fair i { color: #f4c95d; }
.kn-page .kn-game-layout { min-height: 620px; margin-bottom: 18px; overflow: hidden; border: 1px solid rgba(255,255,255,.075); border-radius: 20px; background: #110d1c; box-shadow: 0 24px 65px rgba(5,2,14,.34),inset 0 1px rgba(255,255,255,.035); }
.kn-page .kn-controls { width: clamp(300px,27vw,340px); min-width: 300px; gap: 17px; padding: 22px; border-right: 1px solid rgba(255,255,255,.07); background: radial-gradient(circle at 20% 0,rgba(132,70,224,.15),transparent 34%),linear-gradient(165deg,#21172f,#16101f 72%); box-sizing: border-box; }
.kn-control-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-bottom: 17px; border-bottom: 1px solid rgba(255,255,255,.065); }
.kn-control-head > div span { display: block; margin-bottom: 3px; color: #857b8e; font-size: 10px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.kn-control-head > div strong { color: #f5f1f8; font-size: 15px; }
.kn-control-balance { display: inline-flex; align-items: center; gap: 5px; padding: 7px 9px; border: 1px solid rgba(244,201,93,.14); border-radius: 9px; background: rgba(244,201,93,.055); color: #d9ccaa; font-size: 11px; }
.kn-control-balance i,.kn-page .kn-input-icon { color: #f4c95d; }
.kn-page .kn-label { color: #a79ead; font-size: 11px; font-weight: 700; }
.kn-page .kn-input-row { min-height: 58px; padding: 8px 10px 8px 14px; border-color: rgba(171,122,255,.24); border-radius: 12px; background: rgba(6,4,12,.43); transition: border-color .2s,box-shadow .2s; }
.kn-page .kn-input-row:focus-within { border-color: #8952e2; box-shadow: 0 0 0 3px rgba(132,72,226,.12); }
.kn-page .kn-input { font-size: 18px; font-weight: 750; }
.kn-page .kn-chips { gap: 5px; }
.kn-page .kn-chip { min-width: 36px; height: 31px; padding: 0 8px; border-color: rgba(255,255,255,.075); border-radius: 8px; background: rgba(255,255,255,.045); color: #958b9e; font-size: 10px; }
.kn-page .kn-chip:hover { border-color: rgba(159,104,248,.38); background: rgba(130,69,226,.14); color: #fff; }
.kn-page .kn-picks-row { padding: 12px; border: 1px solid rgba(255,255,255,.065); border-radius: 11px; background: rgba(6,4,12,.28); }
.kn-page #kn_picked_count { color: #c69aff; font-size: 15px; font-weight: 900; }
.kn-page .kn-pick-actions { gap: 5px; }
.kn-page .kn-paytable { display: grid; max-height: 145px; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; padding: 8px; overflow-y: auto; border: 1px solid rgba(255,255,255,.065); border-radius: 11px; background: rgba(6,4,12,.28); scrollbar-width: thin; scrollbar-color: #5f3b8e transparent; }
.kn-page .kn-paytable-row { min-height: 31px; padding: 0 12px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); align-items:center; justify-content:initial; border: 1px solid rgba(255,255,255,.045); border-radius: 7px; background: rgba(255,255,255,.025); color: #7f7587; font-size: 10px; }
.kn-page .kn-paytable-row span { min-width:0; padding:3px 8px; text-align:center; line-height:1.2; }
.kn-page .kn-paytable-row span:last-child { border-left:1px solid rgba(255,255,255,.07); color: #f4c95d; font-weight: 800; }
.kn-page .kn-paytable-empty { grid-column: 1 / -1; padding: 14px 6px; color: #766d7d; font-size: 11px; line-height: 1.45; }
.kn-page .kn-btn-place { min-height: 52px; height: 52px; border-radius: 12px; background: linear-gradient(135deg,#7635db,#a254ef); font-size: 14px; font-weight: 800; box-shadow: 0 14px 28px rgba(92,40,177,.24),inset 0 1px rgba(255,255,255,.16); }
.kn-page .kn-btn-place:hover:not(.disabled) { background: linear-gradient(135deg,#8241e5,#ae61f7); }
.kn-risk-note { display: flex; align-items: flex-start; gap: 7px; margin: auto 0 0; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.055); color: #756b7d; font-size: 10px; line-height: 1.5; }
.kn-risk-note i { margin-top: 2px; color: #8e6fc1; }
.kn-page .kn-stage { position: relative; background: radial-gradient(circle at 54% 47%,rgba(83,48,142,.26),transparent 46%),linear-gradient(145deg,#100b1b,#09060f); }
.kn-page .kn-stage::before { content: ''; position: absolute; inset: 57px 0 0; pointer-events: none; opacity: .55; background-image: linear-gradient(rgba(255,255,255,.018) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.018) 1px,transparent 1px); background-size: 38px 38px; mask-image: radial-gradient(circle at center,#000,transparent 82%); }
.kn-page .kn-header { position: relative; z-index: 2; min-height: 57px; padding: 0 20px; border-bottom-color: rgba(255,255,255,.06); background: rgba(25,18,36,.84); }
.kn-page .kn-header-icon { width: 22px; height: 22px; }
.kn-page .kn-header-title { font-size: 14px; }
.kn-page .kn-info-icon { display: none; }
.kn-round-state { display: inline-flex; align-items: center; gap: 8px; color: #89808f; font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.kn-round-state i { width: 7px; height: 7px; border-radius: 50%; background: #55dba0; box-shadow: 0 0 0 4px rgba(85,219,160,.09),0 0 12px rgba(85,219,160,.4); }
.kn-page .kn-display-area { position: relative; z-index: 1; min-height: 563px; justify-content: center; padding: 27px 30px; gap: 20px; box-sizing: border-box; }
.kn-board-head { display: flex; width: min(100%,670px); align-items: flex-end; justify-content: space-between; gap: 16px; }
.kn-board-head > div:first-child span { display: block; margin-bottom: 3px; color: #786f80; font-size: 9px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.kn-board-head > div:first-child strong { color: #f1edf4; font-size: 14px; }
.kn-board-legend { display: flex; align-items: center; gap: 12px; color: #756c7c; font-size: 9px; font-weight: 700; text-transform: uppercase; }
.kn-board-legend span { display: flex; align-items: center; gap: 5px; }
.kn-board-legend i { width: 7px; height: 7px; border-radius: 2px; }
.kn-board-legend .selected { background: #9e62ef; box-shadow: 0 0 8px rgba(158,98,239,.5); }
.kn-board-legend .matched { background: #4ddd98; box-shadow: 0 0 8px rgba(77,221,152,.5); }
.kn-page .kn-grid { width: min(100%,670px); gap: 8px; padding: 18px; border: 1px solid rgba(255,255,255,.07); border-radius: 18px; background: linear-gradient(145deg,rgba(31,23,44,.86),rgba(10,7,16,.82)); box-shadow: 0 20px 45px rgba(3,1,8,.25),inset 0 1px rgba(255,255,255,.035); box-sizing: border-box; }
.kn-page .kn-cell { aspect-ratio: 1; min-width: 0; border: 1px solid rgba(255,255,255,.075); border-radius: 10px; background: linear-gradient(145deg,rgba(255,255,255,.055),rgba(255,255,255,.018)); color: #9b92a2; font-size: 12px; font-weight: 800; box-shadow: inset 0 1px rgba(255,255,255,.035); transition: transform .15s,border-color .15s,background .15s,color .15s,box-shadow .15s; }
.kn-page .kn-cell:hover { border-color: rgba(163,108,255,.43); background: rgba(137,75,226,.14); color: #fff; transform: translateY(-2px); }
.kn-page .kn-cell.picked { border-color: rgba(177,117,255,.68); background: linear-gradient(145deg,#9250e7,#6630b7); color: #fff; box-shadow: 0 7px 16px rgba(103,48,184,.28),inset 0 1px rgba(255,255,255,.2); }
.kn-page .kn-cell.drawn { border-color: rgba(244,201,93,.7); background: linear-gradient(145deg,#c89631,#80601d); color: #fff5cf; box-shadow: 0 7px 16px rgba(170,126,30,.25),0 0 15px rgba(244,201,93,.12); animation: kn-reveal-2026 .28s ease; }
.kn-page .kn-cell.hit { border-color: rgba(91,238,168,.8); background: linear-gradient(145deg,#3dd98f,#178b59); color: #fff; box-shadow: 0 7px 18px rgba(28,173,105,.29),0 0 18px rgba(77,221,152,.18); animation: kn-hit-2026 .4s ease; }
.kn-page .kn-cell.miss { opacity: .28; filter: saturate(.55); }
.kn-page .kn-hint { width: min(100%,670px); min-height: 34px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.055); border-radius: 9px; background: rgba(5,3,10,.3); color: #776e7e; font-size: 11px; box-sizing: border-box; }
.kn-page .kn-hint.win { border-color: rgba(67,216,141,.16); background: rgba(67,216,141,.07); color: #54db9d; }
.kn-page .kn-hint.lose { border-color: rgba(255,102,122,.16); background: rgba(255,102,122,.07); color: #ff7385; }
.kn-page .kn-history { overflow: hidden; border: 1px solid rgba(255,255,255,.07); border-radius: 16px; background: linear-gradient(145deg,rgba(29,21,40,.9),rgba(16,12,24,.94)); box-shadow: 0 15px 35px rgba(5,2,12,.2); }
.kn-history-title { display: flex; align-items: center; justify-content: space-between; padding: 17px 19px; border-bottom: 1px solid rgba(255,255,255,.055); }
.kn-history-title span { display: block; margin-bottom: 2px; color: #786f80; font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.kn-history-title h2 { margin: 0; color: #f1edf4; font-size: 14px; }
.kn-history-title > i { color: #74539f; }
.kn-page .kn-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.kn-page .kn-history .table-header { background: rgba(255,255,255,.025); }
@media (max-width: 900px) {
    .kn-page .kn-controls { width: 280px; min-width: 260px; padding: 18px; }
    .kn-page .kn-grid { gap: 6px; padding: 14px; }}
@media (max-width: 768px), (pointer: coarse) and (max-width: 1199px) and (max-height: 600px) and (orientation: landscape) {
    .kn-page { padding: 16px 12px 34px; }
    .kn-how-button { width: 36px; padding: 0; justify-content: center; font-size: 0; }
    .kn-how-button i { font-size: 13px; }
    .kn-page .kn-game-layout { flex-direction: column; min-height: 0; border-radius: 16px; }
    .kn-page .kn-stage { order: 1; }
    .kn-page .kn-controls { order: 2; width: 100%; min-width: 0; border-top: 1px solid rgba(255,255,255,.07); border-right: 0; }
    .kn-page .kn-display-area { min-height: 0; padding: 22px 18px; }}
@media (max-width: 540px) {
    .kn-page-icon { width: 40px; height: 40px; border-radius: 12px; }
    .kn-page-identity h1 { font-size: 20px; }
    .kn-top-fair { width: 36px; padding: 0; justify-content: center; font-size: 0; }
    .kn-top-fair i { font-size: 13px; }
    .kn-page .kn-display-area { padding: 18px 8px; }
    .kn-board-head { align-items: flex-start; }
    .kn-board-legend { flex-direction: column; align-items: flex-start; gap: 4px; }
    .kn-page .kn-grid { gap: 4px; padding: 8px; border-radius: 13px; }
    .kn-page .kn-cell { border-radius: 6px; font-size: 10px; }
    .kn-page .kn-input-row { flex-wrap: wrap; }
    .kn-page .kn-chips { width: 100%; }
    .kn-page .kn-chip { flex: 1; }
    .kn-control-head { align-items: flex-start; }}
@media (prefers-reduced-motion: reduce) {
    .kn-page .kn-cell.drawn,.kn-page .kn-cell.hit { animation: none; }}
.ck-page .ck-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.ck-page .ck-history .table-header { background: rgba(255,255,255,.025); }
.cf-page .cf-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.cf-page .cf-history .table-header { background: rgba(255,255,255,.025); }
.minesweeper-page .mines-grid-btn.active { background: linear-gradient(135deg,#7134c9,#9a55e5); color: #fff; box-shadow: 0 6px 13px rgba(91,40,167,.22),inset 0 1px rgba(255,255,255,.14); }
.minesweeper-page .minesweeper-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.minesweeper-page .minesweeper-history .table-header { background: rgba(255,255,255,.025); }
.tw-page .tw-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.tw-page .tw-history .table-header { background: rgba(255,255,255,.025); }
.plinko-page .pk-risk-btn[data-color="green"].active { border-color: rgba(69,213,151,.45) !important; background: linear-gradient(145deg,rgba(36,171,111,.32),rgba(25,105,75,.18)); color: #63e1a6; box-shadow: inset 0 0 16px rgba(35,199,126,.08); }
.plinko-page .pk-risk-btn[data-color="orange"].active { border-color: rgba(239,177,75,.45) !important; background: linear-gradient(145deg,rgba(210,133,42,.32),rgba(118,69,23,.18)); color: #ffc66d; box-shadow: inset 0 0 16px rgba(232,154,46,.08); }
.plinko-page .pk-risk-btn[data-color="red"].active { border-color: rgba(237,86,96,.45) !important; background: linear-gradient(145deg,rgba(197,52,64,.34),rgba(110,28,37,.18)); color: #ff7b85; box-shadow: inset 0 0 16px rgba(226,67,79,.08); }
.plinko-page .pk-history .table-tabs { padding: 10px 12px; border-bottom: 1px solid rgba(255,255,255,.055); background: rgba(255,255,255,.018); }
.plinko-page .pk-history .table-tab-btn { border-radius: 8px; }
.plinko-page .pk-history .table-header { background: rgba(255,255,255,.025); }
.plinko-page .pk-history .table-body .table-row { border-color: rgba(255,255,255,.045); }
.av-page .av-speed-btn.active { border-color:rgba(168,113,255,.45);background:linear-gradient(145deg,rgba(126,61,211,.32),rgba(69,31,118,.24));color:#c99fff;box-shadow:inset 0 0 16px rgba(155,91,235,.08); }
.av-page .av-history .table-tabs { padding:8px 12px;background:rgba(5,3,10,.18); }
.av-page .av-history .table-header { background:rgba(255,255,255,.025); }
.poker-page .pk-preaction-btn.active { border-color:#b47aff;background:linear-gradient(135deg,rgba(133,75,219,.7),rgba(82,43,145,.72));color:#fff;box-shadow:0 0 14px rgba(166,105,255,.22); }
.dt-page--duel .dt-side.active::after { opacity:.75; }
#dt_side_dragon.active .dt-side-emblem { border-color:rgba(244,178,74,.38); color:#f4ba58; box-shadow:0 0 18px rgba(229,153,48,.15); }
#dt_side_tie.active .dt-side-emblem { border-color:rgba(244,201,93,.35); color:#f4d273; }
#dt_side_tiger.active .dt-side-emblem { border-color:rgba(174,112,255,.42); color:#c99dff; box-shadow:0 0 18px rgba(147,77,235,.17); }
.dt-page--duel #dt_side_dragon:hover,.dt-page--duel #dt_side_dragon.active { border-color:rgba(237,174,65,.48); background:linear-gradient(145deg,rgba(142,87,23,.3),rgba(59,32,11,.28)); }
.dt-page--duel #dt_side_tiger:hover,.dt-page--duel #dt_side_tiger.active { border-color:rgba(164,97,250,.52); background:linear-gradient(145deg,rgba(103,48,174,.3),rgba(43,20,74,.3)); }
.dt-page--duel #dt_side_dragon.active .dt-side-pays { color:#f4c45d; }
.dt-page--duel #dt_side_tiger.active .dt-side-pays { color:#c99dff; }
.ft-public-title-icon > .fa { display: block; width: 1em; height: 1em; margin-top: 12px; font-size: 16px; line-height: 1; text-align: center; }

/* Keno mobile game scene ------------------------------------------------- */
@media (max-width:768px) and (orientation:portrait) {
    body.is-game-page .kn-page .kn-game-layout {
        grid-template-rows:minmax(0,1fr) 180px!important;gap:6px!important;
    }
    body.is-game-page .kn-page .kn-stage {
        grid-row:1!important;order:1!important;padding:0!important;display:block!important;overflow:hidden!important;
    }
    body.is-game-page .kn-page .kn-header,
    body.is-game-page .kn-page .kn-board-head { display:none!important; }
    body.is-game-page .kn-page .kn-display-area {
        width:100%!important;height:100%!important;min-height:0!important;padding:6px!important;display:grid!important;
        grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr) 26px!important;
        gap:5px!important;place-items:center!important;overflow:hidden!important;box-sizing:border-box!important;
    }
    body.is-game-page .kn-page .kn-grid {
        grid-column:1!important;grid-row:1!important;width:100%!important;height:auto!important;max-width:100%!important;max-height:100%!important;aspect-ratio:8/5!important;
        margin:auto!important;padding:5px!important;display:grid!important;grid-template-columns:repeat(8,minmax(0,1fr))!important;grid-template-rows:repeat(5,minmax(0,1fr))!important;
        gap:4px!important;border-radius:13px!important;box-sizing:border-box!important;overflow:hidden!important;
    }
    body.is-game-page .kn-page .kn-cell {
        width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;aspect-ratio:auto!important;padding:0!important;
        border-radius:7px!important;font-size:clamp(9px,2.8vw,12px)!important;touch-action:manipulation;
    }
    body.is-game-page .kn-page .kn-hint {
        grid-column:1!important;grid-row:2!important;width:100%!important;height:26px!important;min-height:26px!important;margin:0!important;padding:3px 7px!important;
        overflow:hidden!important;border-radius:8px!important;font-size:8px!important;text-align:center!important;text-overflow:ellipsis!important;white-space:nowrap!important;box-sizing:border-box!important;
    }

    body.is-game-page .kn-page .kn-controls {
        grid-row:2!important;order:2!important;padding:7px!important;display:grid!important;
        grid-template-columns:1fr!important;grid-template-rows:56px 42px 58px!important;gap:5px!important;overflow:hidden!important;
    }
    body.is-game-page .kn-page .kn-controls #keno_bet {
        grid-row:1!important;order:0!important;width:100%!important;height:56px!important;min-height:56px!important;margin:0!important;flex:none!important;
    }
    body.is-game-page .kn-page .kn-picks-segment { grid-row:2!important;margin:0!important;overflow:hidden!important; }
    body.is-game-page .kn-page .kn-picks-row {
        width:100%!important;height:42px!important;min-height:42px!important;padding:4px 7px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;border-radius:10px!important;box-sizing:border-box!important;
    }
    body.is-game-page .kn-page .kn-picks-row .kn-label { margin:0!important;font-size:9px!important;white-space:nowrap!important; }
    body.is-game-page .kn-page #kn_picked_count { font-size:12px!important; }
    body.is-game-page .kn-page .kn-pick-actions { height:34px!important;display:flex!important;gap:4px!important; }
    body.is-game-page .kn-page .kn-pick-actions .kn-chip { min-width:58px!important;height:34px!important;padding:0 7px!important;font-size:8px!important;border-radius:8px!important; }
    body.is-game-page .kn-page .kn-bet-segment { grid-row:3!important;margin:0!important;gap:3px!important;overflow:hidden!important; }
    body.is-game-page .kn-page .kn-label { margin:0!important;font-size:8px!important;line-height:1!important; }
    body.is-game-page .kn-page .kn-input-row {
        height:47px!important;min-height:47px!important;padding:4px 7px!important;flex-wrap:nowrap!important;gap:5px!important;overflow:hidden!important;
    }
    body.is-game-page .kn-page .kn-input { min-width:52px!important;font-size:16px!important; }
    body.is-game-page .kn-page .kn-chips { width:auto!important;margin:0!important;display:flex!important;flex:0 0 auto!important;gap:4px!important; }
    body.is-game-page .kn-page .kn-chips .kn-chip {
        width:38px!important;min-width:38px!important;height:36px!important;min-height:36px!important;padding:0 4px!important;flex:0 0 38px!important;
        border-radius:8px!important;font-size:9px!important;font-weight:850!important;
    }
    body.is-game-page .kn-page .kn-paytable-segment { display:none!important; }}

@media (max-width:350px) and (orientation:portrait) {
    body.is-game-page .kn-page .kn-game-layout { grid-template-rows:minmax(0,1fr) 172px!important; }
    body.is-game-page .kn-page .kn-controls { grid-template-rows:54px 39px 55px!important; }
    body.is-game-page .kn-page .kn-controls #keno_bet { height:54px!important;min-height:54px!important; }
    body.is-game-page .kn-page .kn-picks-row { height:39px!important;min-height:39px!important; }
    body.is-game-page .kn-page .kn-pick-actions .kn-chip { min-width:52px!important;height:31px!important; }
    body.is-game-page .kn-page .kn-input-row { height:44px!important;min-height:44px!important; }
    body.is-game-page .kn-page .kn-chips .kn-chip { width:34px!important;min-width:34px!important;height:34px!important;min-height:34px!important;flex-basis:34px!important; }
    body.is-game-page .kn-page .kn-grid { gap:3px!important;padding:4px!important; }}

@media (max-width:768px) and (orientation:landscape), (pointer:coarse) and (max-width:1199px) and (max-height:600px) and (orientation:landscape) {
    body.is-game-page .kn-page .kn-controls { grid-column:1!important;grid-row:1!important;order:1!important; }
    body.is-game-page .kn-page .kn-stage { grid-column:2!important;grid-row:1!important;order:2!important;padding:0!important;overflow:hidden!important; }
    body.is-game-page .kn-page .kn-header,
    body.is-game-page .kn-page .kn-board-head { display:none!important; }
    body.is-game-page .kn-page .kn-display-area { width:100%!important;height:100%!important;min-height:0!important;padding:4px!important;display:grid!important;grid-template-rows:minmax(0,1fr) 22px!important;gap:3px!important;place-items:center!important;overflow:hidden!important; }
    body.is-game-page .kn-page .kn-grid { width:auto!important;height:100%!important;max-width:100%!important;max-height:100%!important;aspect-ratio:8/5!important;padding:4px!important;display:grid!important;grid-template-columns:repeat(8,1fr)!important;grid-template-rows:repeat(5,1fr)!important;gap:3px!important; }
    body.is-game-page .kn-page .kn-cell { width:100%!important;height:100%!important;min-height:0!important;aspect-ratio:auto!important;font-size:8px!important; }
    body.is-game-page .kn-page .kn-hint { height:22px!important;min-height:22px!important;padding:2px 5px!important;font-size:7px!important; }}

/* Poker mobile table ---------------------------------------------------- */
@media (max-width:768px), (pointer:coarse) and (max-width:1199px) and (max-height:600px) and (orientation:landscape) {
	body.is-game-page .poker-page .pk-runout-toggle button.active { border-color:rgba(193,137,250,.65)!important;background:linear-gradient(145deg,rgba(144,74,211,.45),rgba(87,42,139,.46))!important;color:#fff!important;box-shadow:0 0 0 1px rgba(193,137,250,.1),0 5px 12px rgba(72,29,111,.22)!important; }}
.bnz-history .table-container { background: #2b2333; }

/* Desktop: keep every primary game surface on the left and its controls on
   the right. Mobile layouts continue to stack the surface above the controls
   and retain their route-specific sizing. */
@media (min-width:769px) {
    .kn-game-layout { flex-direction:row-reverse; }}

/* Selected bet, the total that came up, and the settled outcome. `won`/`lost`
   come straight from the server's multiplier -- the paytable is never
   re-derived here. */
.sc-page .sc-bet.active { border-color: rgba(163,108,255,.62); background: linear-gradient(145deg,rgba(132,71,234,.3),rgba(43,22,76,.4)); box-shadow: 0 0 0 3px rgba(132,72,226,.12),inset 0 1px rgba(255,255,255,.06); }
.sc-page .sc-bet.active .sc-bet-name,.sc-page .sc-bet.active .sc-bet-pays { color: #fff; }
.sc-page .sc-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.sc-page .sc-history .table-header { background: rgba(255,255,255,.025); }
.er-history .table-tabs { padding: 8px 12px; background: rgba(5,3,10,.18); }
.er-history .table-header { background: rgba(255,255,255,.025); }
.nv-public-title-icon > .fa { display: block; width: 1em; height: 1em; margin-top: 12px; font-size: 16px; line-height: 1; text-align: center; }
.rv-public-title-icon > .fa { display: block; width: 1em; height: 1em; margin-top: 12px; font-size: 16px; line-height: 1; text-align: center; }
.bd-public-title-icon > .fa { display: block; width: 1em; height: 1em; margin-top: 12px; font-size: 16px; line-height: 1; text-align: center; }