:root{--machine-accent:#8b5cf6;--machine-cyan:#22d3ee;--machine-panel:rgba(18,20,36,.94);--machine-border:rgba(255,255,255,.13)}
.machine-lobby-page,.machine-game-page{min-height:100vh;background:radial-gradient(circle at 10% 10%,rgba(124,58,237,.28),transparent 34%),radial-gradient(circle at 90% 0,rgba(6,182,212,.2),transparent 32%),#090b14;color:#f8fafc}
.machine-shell{width:min(1180px,calc(100% - 28px));margin:0 auto;padding:24px 0 56px}
.machine-topbar{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;padding:24px;border:1px solid var(--machine-border);border-radius:26px;background:linear-gradient(145deg,rgba(20,23,43,.96),rgba(10,12,25,.95));box-shadow:0 24px 60px rgba(0,0,0,.28)}
.machine-topbar.compact{align-items:center}.machine-topbar h1{margin:.35rem 0 .4rem;font-size:clamp(2rem,5vw,4rem);line-height:1}.machine-topbar p{max-width:780px;margin:0;color:#cbd5e1;line-height:1.6}.machine-topbar .eyebrow{color:#67e8f9;font-weight:900;letter-spacing:.14em}.machine-header-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:10px;max-width:460px}
.machine-explainer{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin:18px 0}.machine-explainer>div{display:flex;flex-direction:column;gap:4px;padding:18px;border:1px solid var(--machine-border);border-radius:18px;background:rgba(15,18,33,.86)}.machine-explainer strong{font-size:1.05rem;color:#fff}.machine-explainer span{color:#aab3c5;line-height:1.45}
.machine-card-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}.machine-game-card{display:flex;flex-direction:column;align-items:flex-start;min-height:280px;padding:22px;border:1px solid var(--machine-border);border-radius:24px;background:linear-gradient(155deg,rgba(31,34,58,.96),rgba(15,17,31,.96));box-shadow:0 18px 44px rgba(0,0,0,.24)}.machine-game-card h2{margin:12px 0 8px}.machine-game-card p{flex:1;margin:0 0 18px;color:#bdc5d6;line-height:1.55}.machine-game-icon{display:grid;place-items:center;width:64px;height:64px;border-radius:20px;background:linear-gradient(145deg,#7c3aed,#0891b2);font-size:2rem;box-shadow:0 12px 30px rgba(124,58,237,.28)}
.machine-live-option{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-top:20px;padding:20px;border:1px solid var(--machine-border);border-radius:22px;background:rgba(15,18,33,.85)}.machine-live-option>div{display:flex;align-items:center;gap:14px}.machine-live-option>div>span{font-size:2rem}.machine-live-option h2,.machine-live-option p{margin:0}.machine-live-option p{color:#b9c0d0}
.machine-setup-card{display:grid;grid-template-columns:1fr 1fr;gap:24px;margin-top:18px;padding:24px;border:1px solid var(--machine-border);border-radius:24px;background:var(--machine-panel)}.machine-setup-copy{display:flex;align-items:center;gap:18px}.machine-setup-copy h2,.machine-setup-copy p{margin:0}.machine-setup-copy p{margin-top:5px;color:#b7c0d1}.machine-setup-icon{font-size:3.5rem}.machine-start-form{display:grid;gap:14px}.machine-start-form label{display:grid;gap:6px}.machine-start-form input[type=text],.machine-start-form input:not([type]){width:100%}.machine-start-form fieldset{display:flex;flex-wrap:wrap;gap:12px;border:1px solid var(--machine-border);border-radius:16px;padding:12px 14px}.machine-start-form legend{padding:0 6px;color:#c4b5fd;font-weight:800}.machine-start-form fieldset label{display:flex;align-items:center;gap:7px}
.machine-status{min-height:24px;margin:12px 0;padding:0 4px;color:#cbd5e1}.machine-status.error{color:#fecaca}.machine-status.success{color:#bbf7d0}.machine-stage{display:grid;gap:18px}.machine-scoreboard{display:grid;grid-template-columns:1fr auto 1fr auto;align-items:center;gap:14px;padding:18px;border:1px solid var(--machine-border);border-radius:22px;background:var(--machine-panel)}.machine-scoreboard>div:not(.machine-score-vs){display:flex;justify-content:space-between;align-items:center;gap:18px;padding:14px 16px;border-radius:16px;background:rgba(255,255,255,.055)}.machine-scoreboard span{color:#aeb7c8}.machine-scoreboard strong{font-size:1.7rem}.machine-score-vs{font-weight:900;color:#67e8f9}.machine-best{min-width:150px}
.machine-content-card,.machine-domino-table{padding:24px;border:1px solid var(--machine-border);border-radius:24px;background:linear-gradient(155deg,rgba(24,27,48,.97),rgba(11,13,25,.97));box-shadow:0 24px 64px rgba(0,0,0,.25)}.machine-round-head{display:flex;align-items:center;gap:12px;margin-bottom:22px}.machine-round-head>span{color:#aeb7c8}.machine-round-head .machine-difficulty{padding:5px 10px;border-radius:999px;background:rgba(139,92,246,.17);color:#ddd6fe;text-transform:capitalize}.machine-round-head strong{margin-left:auto;padding:8px 12px;border-radius:12px;background:#111827;color:#67e8f9;font-size:1.2rem}.machine-question{font-size:clamp(1.35rem,3vw,2.25rem);font-weight:850;line-height:1.3;text-align:center}.machine-hint{padding:12px 14px;border-radius:14px;background:rgba(34,211,238,.1);color:#cffafe}.machine-phrase-mask{margin:16px auto;max-width:900px;text-align:center;font-size:clamp(1.8rem,5vw,4rem);font-weight:900;letter-spacing:.12em;line-height:1.35;color:#f0abfc;word-break:break-word}.machine-quote{margin:18px auto;max-width:900px;text-align:center;font-size:clamp(1.45rem,3.3vw,2.55rem);font-weight:800;line-height:1.45;color:#f5f3ff}.machine-secret-icon{text-align:center;font-size:4rem}
.machine-answer-form{display:grid;grid-template-columns:1fr auto;gap:12px;max-width:860px;margin:24px auto 0}.machine-answer-form input{min-width:0}.machine-answer-form.choices{grid-template-columns:repeat(2,minmax(0,1fr))}.machine-answer-form.choices label{position:relative;display:block}.machine-answer-form.choices input{position:absolute;opacity:0;pointer-events:none}.machine-answer-form.choices span{display:block;padding:16px;border:2px solid rgba(255,255,255,.12);border-radius:16px;background:rgba(255,255,255,.045);cursor:pointer;font-weight:800}.machine-answer-form.choices input:checked+span{border-color:#22d3ee;background:rgba(34,211,238,.16)}.machine-answer-form.choices button{grid-column:1/-1}.machine-round-result,.machine-match-finish{margin-top:22px;padding:20px;border-radius:18px;text-align:center}.machine-round-result.correct{background:rgba(34,197,94,.13);border:1px solid rgba(34,197,94,.34)}.machine-round-result.wrong{background:rgba(239,68,68,.11);border:1px solid rgba(239,68,68,.3)}.machine-round-result>strong{font-size:1.45rem}.machine-match-finish{background:rgba(139,92,246,.15);border:1px solid rgba(139,92,246,.34)}.machine-match-finish>span{font-size:4rem}.machine-match-finish h2{font-size:2rem}
.machine-domino-opponent{display:flex;align-items:center;gap:12px}.machine-avatar{display:grid;place-items:center;width:54px;height:54px;border-radius:18px;background:rgba(139,92,246,.18);font-size:1.8rem}.machine-domino-opponent div:last-child{display:flex;flex-direction:column}.machine-domino-opponent span{color:#aab3c5}.machine-turn-banner{margin:18px 0;padding:12px;text-align:center;border-radius:14px;background:rgba(245,158,11,.14);color:#fde68a;font-weight:900}.machine-turn-banner.is-player{background:rgba(34,197,94,.14);color:#bbf7d0}
.machine-board-heading{display:flex;align-items:end;justify-content:space-between;gap:12px;margin:2px 2px 10px}.machine-board-heading>div{display:grid;gap:2px}.machine-board-heading strong{font-size:1.18rem}.machine-board-heading span{color:#9fb5ad}.machine-board-count{padding:6px 10px;border-radius:999px;background:rgba(20,184,166,.14);color:#99f6e4!important;font-weight:800}
.machine-domino-board{display:flex;align-content:center;align-items:center;justify-content:center;flex-wrap:wrap;gap:13px;min-height:300px;width:100%;padding:28px;border:6px solid #173f34;border-radius:26px;background:radial-gradient(circle at center,rgba(52,211,153,.16),transparent 58%),linear-gradient(135deg,rgba(255,255,255,.035),transparent 45%),#0b3329;box-shadow:inset 0 0 0 2px rgba(167,243,208,.08),inset 0 18px 40px rgba(0,0,0,.26),0 18px 38px rgba(0,0,0,.24);overflow:auto}.machine-empty-board{width:100%;text-align:center;color:#a7f3d0;font-size:1.05rem}
.machine-domino{position:relative;display:grid;grid-template-rows:1fr 3px 1fr;flex:0 0 auto;width:64px;height:116px;border:3px solid #0d0d0f;border-radius:11px;background:linear-gradient(145deg,#fff,#e9eef5);color:#0f172a;box-shadow:0 8px 18px rgba(0,0,0,.36);overflow:hidden}.machine-domino-half{display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,1fr);place-items:center;padding:7px}.machine-pip{width:8px;height:8px;border-radius:50%;background:transparent}.machine-pip.is-on{background:#111827;box-shadow:inset 0 -1px 1px rgba(255,255,255,.28)}.machine-domino-divider{display:block;width:100%;height:3px;background:#111827}.machine-domino.on-board{grid-template-columns:1fr 3px 1fr;grid-template-rows:1fr;width:116px;height:64px}.machine-domino.on-board .machine-domino-divider{width:3px;height:100%}.machine-domino.on-board .machine-domino-half{padding:7px}.machine-domino.on-board.is-double{transform:rotate(90deg);margin:26px}.machine-domino.playable{outline:4px solid #22d3ee;outline-offset:4px;box-shadow:0 0 0 8px rgba(34,211,238,.1),0 10px 22px rgba(0,0,0,.38)}
.machine-domino-ends{display:flex;justify-content:space-between;gap:10px;margin:18px 0;color:#cbd5e1}.machine-domino-ends span{padding:8px 10px;border-radius:12px;background:rgba(255,255,255,.045)}.machine-message{text-align:center;color:#e2e8f0}.machine-domino-controls{text-align:center;margin:14px 0}.machine-player-hand{margin-top:20px;padding-top:18px;border-top:1px solid var(--machine-border)}.machine-player-hand h2{margin-bottom:8px}.machine-domino-hand{display:flex;align-items:flex-start;gap:18px;padding:18px 8px 28px;overflow-x:auto}.machine-hand-item{display:grid;justify-items:center;gap:12px}.machine-domino-actions{display:flex;gap:6px}.machine-domino-actions button{padding:7px 9px;font-size:.78rem;white-space:nowrap}.machine-draw-button{min-width:180px}
.machine-footer-actions{display:flex;justify-content:center;flex-wrap:wrap;gap:10px}.machine-header-actions .game-sound-switch{margin:0}.machine-game-page button,.machine-game-page .button,.machine-lobby-page .button{border-radius:14px}
@media(max-width:900px){.machine-topbar,.machine-topbar.compact{flex-direction:column}.machine-header-actions{justify-content:flex-start;max-width:none}.machine-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.machine-setup-card{grid-template-columns:1fr}.machine-scoreboard{grid-template-columns:1fr auto 1fr}.machine-best{grid-column:1/-1}.machine-explainer{grid-template-columns:1fr}.machine-answer-form.choices{grid-template-columns:1fr}}
@media(max-width:620px){.machine-shell{width:min(100% - 16px,1180px);padding-top:8px}.machine-topbar{padding:18px;border-radius:20px}.machine-card-grid{grid-template-columns:1fr}.machine-live-option{align-items:flex-start;flex-direction:column}.machine-scoreboard{grid-template-columns:1fr auto 1fr;padding:10px}.machine-scoreboard>div:not(.machine-score-vs){padding:10px;flex-direction:column;gap:2px}.machine-best{grid-column:1/-1;flex-direction:row!important}.machine-content-card,.machine-domino-table{padding:14px}.machine-answer-form{grid-template-columns:1fr}.machine-answer-form button{width:100%}.machine-domino-board{min-height:220px;padding:18px 10px;gap:10px;border-width:4px}.machine-domino{width:56px;height:102px}.machine-domino.on-board{width:102px;height:56px}.machine-domino.on-board.is-double{margin:23px}.machine-pip{width:7px;height:7px}.machine-domino-ends{font-size:.83rem;flex-wrap:wrap}.machine-domino-ends span{flex:1 1 30%;text-align:center}.machine-board-heading{align-items:flex-start}.machine-board-heading>div span{font-size:.82rem}.machine-header-actions{width:100%}.machine-header-actions .button,.machine-header-actions button{flex:1}.machine-setup-copy{align-items:flex-start}}

/* v0.7.38 room-style domino machine mode */
.machine-domino-page .machine-topbar.room-like{border-radius:28px;background:linear-gradient(145deg,rgba(20,23,43,.98),rgba(10,12,25,.98));border-color:rgba(239,68,68,.45);box-shadow:0 18px 48px rgba(0,0,0,.32)}
.machine-domino-room-shell{display:grid;gap:16px}.machine-domino-room-head{display:flex;justify-content:space-between;align-items:flex-start;gap:18px;padding:18px 20px;border:1px solid rgba(239,68,68,.35);border-radius:24px;background:linear-gradient(145deg,rgba(18,20,36,.96),rgba(10,12,25,.94))}.machine-domino-room-title{display:flex;align-items:center;gap:16px}.machine-domino-brand{display:grid;place-items:center;width:58px;height:58px;border-radius:18px;background:linear-gradient(145deg,#7c3aed,#2563eb);font-size:1.8rem}.machine-domino-room-title h2{margin:0;font-size:2rem}.machine-domino-room-title p{margin:6px 0 0;color:#cbd5e1}.machine-domino-status-row{display:grid;justify-items:end;gap:10px}.machine-side-chip-row{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:10px}.machine-side-chip{display:inline-flex;align-items:center;gap:10px;padding:8px 12px;border:1px solid rgba(255,255,255,.15);border-radius:999px;background:#05070d;color:#f8fafc;font-weight:900}.machine-side-chip strong{display:grid;place-items:center;min-width:34px;height:34px;padding:0 8px;border-radius:12px;background:#f1f5f9;color:#0f172a}.machine-side-chip.is-enabled{border-color:rgba(34,211,238,.7);box-shadow:0 0 0 3px rgba(34,211,238,.12)}.machine-side-chip:disabled{opacity:.55;cursor:not-allowed}
.machine-domino-score-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.machine-seat-card{display:flex;align-items:center;gap:14px;padding:14px 16px;border:1px solid rgba(255,255,255,.12);border-radius:20px;background:linear-gradient(145deg,rgba(20,23,40,.95),rgba(12,14,26,.95))}.machine-seat-card.is-active{border-color:rgba(239,68,68,.8);box-shadow:0 0 0 2px rgba(239,68,68,.16)}.machine-seat-avatar{display:grid;place-items:center;width:48px;height:48px;border-radius:50%;border:2px solid rgba(239,68,68,.8);background:rgba(255,255,255,.08);font-size:1.45rem}.machine-seat-card strong{display:block;font-size:1.1rem}.machine-seat-card span{display:block;margin-top:3px;color:#9ce780;font-weight:700}
.machine-room-table-wrap{padding:0}.machine-room-table{padding:16px;border:1px solid rgba(255,255,255,.09);border-radius:24px;background:rgba(8,10,20,.96)}.machine-room-table-inner{padding:18px;border:6px solid rgba(239,68,68,.78);border-radius:34px;background:linear-gradient(180deg,rgba(6,12,22,.5),rgba(6,12,22,.2))}.machine-board-status{margin:0 0 16px;padding:12px 16px;border-radius:18px;background:rgba(0,0,0,.34);color:#e2e8f0;font-weight:700}.machine-room-style-board{min-height:420px;gap:16px;border-width:2px;border-style:dashed;border-color:rgba(255,255,255,.1);border-radius:28px;background:radial-gradient(circle at center,rgba(66,120,89,.28),transparent 55%),linear-gradient(90deg,rgba(0,0,0,.15),rgba(255,255,255,.02),rgba(0,0,0,.15)),#061611}.machine-board-tile-wrap{display:grid;place-items:center}.machine-room-table-footer{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap}.machine-room-boneyard-note{color:#cbd5e1;font-size:.95rem}.machine-domino-controls{display:flex;justify-content:center;align-items:center;gap:10px;flex-wrap:wrap}
.machine-hand-launcher{position:fixed;left:18px;bottom:18px;z-index:70;display:inline-flex;align-items:center;gap:10px;padding:14px 18px;border:none;border-radius:999px;background:linear-gradient(145deg,#dc2626,#b91c1c);color:#fff;font-weight:900;box-shadow:0 18px 36px rgba(0,0,0,.35)}.machine-hand-launcher b{display:grid;place-items:center;min-width:28px;height:28px;padding:0 8px;border-radius:999px;background:#fff;color:#991b1b}.machine-hand-panel{position:fixed;left:18px;right:18px;bottom:86px;z-index:80;display:grid;gap:14px;max-height:min(48vh,430px);padding:18px;border:1px solid rgba(255,255,255,.15);border-radius:24px;background:linear-gradient(145deg,rgba(16,19,34,.98),rgba(8,10,20,.98));box-shadow:0 30px 60px rgba(0,0,0,.45)}.machine-hand-panel[hidden]{display:none!important}.machine-hand-toolbar{display:flex;justify-content:flex-end}.machine-hand-close{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;border:1px solid rgba(255,255,255,.16);background:rgba(255,255,255,.05);font-size:1.6rem}.machine-hand-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:14px}.machine-hand-heading h2{margin:0;font-size:1.9rem}.machine-hand-heading p{margin:5px 0 0;color:#cbd5e1}.machine-hand-controls{display:flex;align-items:center;gap:10px}.machine-branch-helper{padding:10px 14px;border-radius:14px;background:rgba(255,255,255,.05);color:#cbd5e1}.machine-branch-helper.is-ready{background:rgba(34,211,238,.12);color:#cffafe;border:1px solid rgba(34,211,238,.28)}.machine-hand-tile{display:grid;justify-items:center;gap:8px;padding:8px 6px 0;border:none;background:transparent}.machine-hand-tile.is-selected .machine-domino{outline:4px solid #f59e0b;outline-offset:4px;box-shadow:0 0 0 10px rgba(245,158,11,.12),0 10px 24px rgba(0,0,0,.38)}.machine-hand-tile-label{font-size:.78rem;color:#cbd5e1;font-weight:700}.machine-empty-hand{width:100%;color:#cbd5e1;text-align:center;padding:16px 0;margin:0}
.machine-domino-hand{display:flex;align-items:flex-start;gap:18px;padding:12px 4px 18px;overflow-x:auto;overflow-y:hidden}.machine-domino.on-board{width:112px;height:62px}.machine-domino.on-board.is-double{margin:24px 6px}.machine-footer-actions{margin-top:8px}
@media(max-width:900px){.machine-domino-room-head,.machine-hand-heading,.machine-room-table-footer{flex-direction:column;align-items:flex-start}.machine-domino-status-row{justify-items:start;width:100%}.machine-side-chip-row{justify-content:flex-start}.machine-domino-score-row{grid-template-columns:1fr}.machine-room-style-board{min-height:340px}.machine-hand-panel{left:10px;right:10px;bottom:74px;max-height:min(52vh,440px)}}
@media(max-width:620px){.machine-domino-room-title h2{font-size:1.5rem}.machine-domino-brand{width:50px;height:50px}.machine-room-style-board{min-height:280px;padding:18px 8px}.machine-hand-launcher{left:12px;bottom:12px;padding:12px 16px}.machine-hand-panel{padding:14px;border-radius:20px}.machine-hand-heading h2{font-size:1.55rem}.machine-domino.on-board{width:96px;height:54px}.machine-domino.on-board.is-double{margin:20px 4px}.machine-side-chip{width:100%;justify-content:space-between}.machine-side-chip-row{width:100%}}

/* v0.7.39 original-room interaction parity for Dominoes vs Machine */
.machine-room-style-board{position:relative;display:block;min-height:430px;padding:76px 118px;overflow:auto}
.machine-board-sequence{display:flex;align-items:center;justify-content:center;align-content:center;flex-wrap:wrap;gap:14px;min-width:100%;min-height:260px}
.machine-open-end-summary{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px}.machine-open-end-summary span{display:inline-flex;align-items:center;gap:8px;padding:7px 10px;border-radius:999px;background:#05070d;color:#f8fafc;font-size:.78rem;font-weight:900}.machine-open-end-summary strong{display:grid;place-items:center;min-width:30px;height:30px;padding:0 7px;border-radius:9px;background:#f8fafc;color:#111827;font-size:1rem}
.machine-drop-zone{position:absolute;top:50%;z-index:18;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;width:76px;min-height:78px;padding:8px;border:2px dashed rgba(255,255,255,.35);border-radius:16px;background:rgba(0,0,0,.58);color:#e5e7eb;transform:translateY(-50%);transition:opacity .15s ease,border-color .15s ease,background .15s ease,transform .15s ease}.machine-drop-left{left:22px}.machine-drop-right{right:22px}.machine-drop-zone span{font-size:.66rem;text-transform:uppercase;letter-spacing:.055em;text-align:center}.machine-drop-zone strong{display:grid;place-items:center;width:36px;height:36px;border:2px solid #111827;border-radius:9px;background:#f8fafc;color:#111827;font-size:1.05rem}.machine-drop-zone.is-neutral{opacity:.78}.machine-drop-zone.is-valid{opacity:1;border-color:#fef08a;background:rgba(254,240,138,.16);color:#fff;cursor:pointer;box-shadow:0 0 0 3px rgba(254,240,138,.12)}.machine-drop-zone.is-invalid{opacity:.2}.machine-drop-zone.is-over{opacity:1;border-style:solid;border-color:#fff;background:rgba(124,58,237,.78);transform:translateY(-50%) scale(1.08);box-shadow:0 0 0 5px rgba(255,255,255,.18)}.machine-drop-zone:disabled{cursor:not-allowed;filter:none}.machine-drop-zone[hidden]{display:none!important}

.machine-domino-half{position:relative}.machine-domino-half[data-value="1"] .machine-pip.is-on{background:#ec4899}.machine-domino-half[data-value="2"] .machine-pip.is-on{background:#3b82f6}.machine-domino-half[data-value="3"] .machine-pip.is-on{background:#22c55e}.machine-domino-half[data-value="4"] .machine-pip.is-on{background:#f59e0b}.machine-domino-half[data-value="5"] .machine-pip.is-on{background:#a855f7}.machine-domino-half[data-value="6"] .machine-pip.is-on{background:#ef4444}body[data-domino-pips="black"] .machine-domino-half .machine-pip.is-on{background:#090909;box-shadow:inset 0 1px 1px rgba(255,255,255,.28)}

.machine-hand-launcher{left:18px;bottom:18px;z-index:1260;min-height:48px;padding:10px 14px;border:2px solid rgba(255,255,255,.72);box-shadow:0 14px 38px rgba(0,0,0,.56)}.machine-hand-launcher.is-my-turn{animation:machine-hand-turn-pulse 1.55s ease-in-out infinite;box-shadow:0 0 0 4px rgba(239,68,68,.2),0 14px 38px rgba(0,0,0,.56)}@keyframes machine-hand-turn-pulse{0%,100%{transform:translateY(0)}50%{transform:translateY(-5px)}}
.machine-hand-panel{position:fixed;left:18px;right:auto;bottom:78px;z-index:1250;width:min(980px,calc(100vw - 36px));max-height:min(58vh,470px);padding:12px 16px 14px;border:1px solid #52525e;border-top:5px solid #dc2626;border-radius:20px;background:rgba(23,23,29,.985);box-shadow:0 24px 70px rgba(0,0,0,.66);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}.machine-hand-panel.is-positioned{right:auto;bottom:auto}.machine-hand-panel.is-panel-dragging{cursor:grabbing;user-select:none;-webkit-user-select:none;box-shadow:0 28px 80px rgba(0,0,0,.76),0 0 0 2px rgba(239,68,68,.7)}
.machine-hand-toolbar{display:flex;align-items:center;justify-content:flex-end;gap:8px;margin:0 0 10px}.machine-hand-drag-handle{display:flex;align-items:center;justify-content:center;gap:7px;min-width:142px;min-height:36px;margin-right:auto;padding:7px 12px;border:1px dashed #71717a;border-radius:11px;background:#27272f;color:#f4f4f5;cursor:grab;touch-action:none;font-size:.82rem;font-weight:900}.machine-hand-drag-handle:active{cursor:grabbing}.machine-hand-drag-handle>span:first-child{font-size:1.02rem;line-height:1;letter-spacing:-1px}.machine-hand-reset-position,.machine-hand-rotate{min-height:36px;padding:7px 10px;border:1px solid #555563;border-radius:10px;background:#303038;color:#fff;font-size:.76rem;white-space:nowrap}.machine-hand-rotate[aria-pressed="true"]{border-color:#dc2626;background:rgba(220,38,38,.2)}.machine-hand-close{position:static;display:grid;place-items:center;width:36px;height:36px;min-width:36px;padding:0;border:1px solid #555563;border-radius:50%;background:#303038;color:#fff;font-size:1.45rem;line-height:1}.machine-hand-heading{padding-right:0}.machine-hand-heading h2{display:flex;align-items:center;gap:7px}.machine-hand-panel .machine-domino-hand{min-height:138px;margin-top:4px;padding:12px 4px 8px;overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;overscroll-behavior-x:contain}.machine-hand-tile{flex:0 0 auto;display:grid;justify-items:center;gap:7px;padding:8px!important;border:0!important;border-radius:14px;background:transparent!important;color:#fff;filter:none!important;transition:transform .15s ease,background .15s ease,opacity .15s ease,box-shadow .15s ease;user-select:none;-webkit-user-select:none;touch-action:none}.machine-hand-tile small{display:none}.machine-hand-tile.is-playable{cursor:grab;background:rgba(220,38,38,.1)!important;box-shadow:inset 0 0 0 2px rgba(34,211,238,.78)}.machine-hand-tile.is-playable:hover{transform:translateY(-6px)}.machine-hand-tile.is-playable:active{cursor:grabbing}.machine-hand-tile.is-unplayable{opacity:.34;cursor:not-allowed}.machine-hand-tile.is-waiting{opacity:.55;cursor:not-allowed}.machine-hand-tile.is-selected{transform:translateY(-9px);background:rgba(245,158,11,.12)!important;box-shadow:0 0 0 3px #fff,0 0 0 7px #f59e0b}.machine-hand-tile.is-dragging{opacity:.25;transform:none}.machine-domino-drag-ghost{position:fixed!important;left:0;top:0;z-index:5000;pointer-events:none;transform:translate(-50%,-50%) rotate(-4deg) scale(1.04);opacity:.92;box-shadow:0 18px 36px rgba(0,0,0,.55)}body.machine-domino-pointer-active,body.machine-hand-panel-dragging{user-select:none!important;-webkit-user-select:none!important}body.machine-hand-panel-dragging{cursor:grabbing!important}

.machine-hand-panel.is-vertical-hand{width:min(248px,calc(100vw - 16px));max-height:min(82vh,760px)}.machine-hand-panel.is-vertical-hand .machine-hand-toolbar{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 40px;grid-template-areas:"drag drag drag" "reset rotate close";align-items:center;gap:7px;width:100%}.machine-hand-panel.is-vertical-hand .machine-hand-drag-handle{grid-area:drag;width:100%;min-width:0;min-height:34px;margin:0;padding:0;overflow:hidden}.machine-hand-panel.is-vertical-hand .machine-hand-drag-handle>span{display:none}.machine-hand-panel.is-vertical-hand .machine-hand-drag-handle::before{content:"";display:block;width:72px;height:5px;border-radius:999px;background:#a1a1aa}.machine-hand-panel.is-vertical-hand .machine-hand-reset-position{grid-area:reset;width:100%;min-width:0}.machine-hand-panel.is-vertical-hand .machine-hand-rotate{grid-area:rotate;width:100%;min-width:0}.machine-hand-panel.is-vertical-hand .machine-hand-close{grid-area:close;justify-self:end}.machine-hand-panel.is-vertical-hand .machine-hand-heading{flex-direction:column;align-items:stretch;gap:10px}.machine-hand-panel.is-vertical-hand .machine-hand-controls{width:100%}.machine-hand-panel.is-vertical-hand .machine-hand-controls button{width:100%}.machine-hand-panel.is-vertical-hand .machine-domino-hand{display:grid;grid-auto-flow:row;justify-content:center;align-content:start;gap:10px;min-height:0;max-height:none;padding:8px 2px 4px;overflow-x:hidden;overflow-y:auto}.machine-hand-panel.is-vertical-hand .machine-hand-tile{width:100%;justify-items:center;padding:6px!important}.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-playable:hover{transform:translateX(4px)}.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-selected{transform:translateX(7px)}

@media(max-width:760px){.machine-room-style-board{min-height:350px;padding:76px 90px}.machine-drop-left{left:10px}.machine-drop-right{right:10px}.machine-drop-zone{width:68px;min-height:72px}.machine-hand-panel{left:8px;right:8px;bottom:8px;width:auto;max-height:min(64vh,500px);padding:10px 12px 12px;border-radius:18px}.machine-hand-panel.is-positioned{right:auto;width:min(680px,calc(100vw - 16px))}.machine-hand-panel.is-vertical-hand{width:min(232px,calc(100vw - 12px));max-height:80vh}.machine-hand-drag-handle{min-width:0;flex:1;padding:7px 9px}.machine-hand-launcher{left:10px;bottom:10px;padding:9px 12px}}
@media(max-width:520px){.machine-room-style-board{min-height:320px;padding:86px 18px 94px}.machine-drop-zone{top:auto;bottom:10px;transform:none;width:calc(50% - 22px);min-height:66px}.machine-drop-zone.is-over{transform:scale(1.04)}.machine-drop-left{left:10px}.machine-drop-right{right:10px}.machine-board-sequence{min-height:190px}.machine-hand-launcher>span:nth-child(2){display:none}.machine-hand-panel{max-height:68vh}.machine-hand-toolbar{gap:6px}.machine-hand-reset-position,.machine-hand-rotate{font-size:.72rem;padding:7px 8px}}
@media(prefers-reduced-motion:reduce){.machine-hand-launcher.is-my-turn{animation:none}}

/* v0.7.40 boneyard badge + optional Training Mode */
.machine-room-table-footer{margin-top:14px;padding:0 2px}.machine-board-footer-status{margin:0;color:#f8fafc;font-weight:700}.machine-boneyard-badge{display:inline-flex;align-items:center;gap:5px;padding:10px 14px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:rgba(0,0,0,.72);color:#fff;box-shadow:0 8px 20px rgba(0,0,0,.25);white-space:nowrap}.machine-boneyard-badge strong{font-size:1.05rem}.machine-domino-controls{margin-top:10px}
.machine-training-toggle{min-height:38px;padding:8px 12px;border:1px solid #555563;border-radius:11px;background:#303038;color:#fff;font-weight:800;white-space:nowrap}.machine-training-toggle[aria-pressed="true"]{border-color:#fff;background:linear-gradient(145deg,#7c3aed,#2563eb);box-shadow:0 0 0 3px rgba(124,58,237,.24)}.machine-training-tip{margin:2px 0 4px;padding:11px 13px;border:1px solid rgba(34,211,238,.35);border-radius:13px;background:rgba(34,211,238,.1);color:#cffafe;line-height:1.45}.machine-training-tip[hidden]{display:none!important}
.machine-hand-tile.is-neutral-play{cursor:grab;opacity:1}.machine-hand-tile.is-neutral-play:hover{transform:translateY(-4px)}.machine-hand-tile.is-neutral-play:active{cursor:grabbing}.machine-hand-tile small{display:none;color:#e2e8f0;font-size:.72rem;font-weight:800;text-align:center}.machine-training-on .machine-hand-tile small{display:block}.machine-training-on .machine-hand-tile.is-playable{background:rgba(34,211,238,.1)!important;box-shadow:inset 0 0 0 2px rgba(34,211,238,.8)}.machine-training-on .machine-hand-tile.is-unplayable{opacity:.34}.machine-training-on .machine-drop-zone.is-invalid{opacity:.2}.machine-training-on .machine-drop-zone.is-valid{opacity:1}
@media(max-width:760px){.machine-hand-controls{width:100%;flex-wrap:wrap}.machine-hand-controls .machine-training-toggle,.machine-hand-controls .machine-draw-button{flex:1}.machine-room-table-footer{align-items:center}.machine-boneyard-badge{margin-left:auto}}
@media(max-width:520px){.machine-room-table-footer{flex-direction:row;align-items:center}.machine-board-footer-status{font-size:.82rem}.machine-boneyard-badge{padding:8px 11px;font-size:.88rem}}


/* v0.7.41 machine domino layout polish */

body.machine-domino-match-live .machine-topbar{padding:16px 20px;gap:16px;border-radius:22px}
body.machine-domino-match-live .machine-topbar h1{font-size:clamp(1.8rem,4vw,3rem);margin:.15rem 0 .25rem}
body.machine-domino-match-live .machine-topbar p{display:none}
body.machine-domino-match-live .machine-topbar .eyebrow{font-size:.76rem}
body.machine-domino-match-live .machine-header-actions{gap:8px;max-width:380px}
body.machine-domino-match-live #machine-stage{margin-top:10px}
.machine-domino-room-head{padding:0 2px 6px}
.machine-domino-room-title h2{margin:0 0 6px;font-size:clamp(1.7rem,3.2vw,2.7rem)}
.machine-domino-room-title p{margin:0;color:#cbd5e1;font-size:.98rem}
.machine-domino-status-row{align-items:flex-start;gap:10px}
.machine-turn-banner{padding:8px 14px}
.machine-open-end-summary span{padding:8px 10px}
.machine-domino-score-row{margin-top:12px}
.machine-seat-card{padding:12px 14px}
.machine-room-table{padding:12px}
.machine-room-table-inner{padding:14px}
.machine-room-style-board{min-height:500px;padding:88px 102px 96px}
.machine-board-sequence{min-height:240px}
.machine-room-table-footer{margin-top:12px}
.machine-boneyard-badge{padding:9px 14px}
.machine-hand-panel{width:min(760px,calc(100vw - 36px));max-height:min(52vh,430px);padding:10px 14px 12px}
.machine-hand-panel .machine-domino-hand{min-height:118px;gap:12px;padding:10px 2px 6px}
.machine-hand-panel .machine-domino{width:58px;height:104px}
.machine-hand-panel .machine-domino-half{padding:6px}
.machine-hand-panel.is-vertical-hand{width:min(238px,calc(100vw - 16px));max-height:min(82vh,740px)}
.machine-hand-panel.is-vertical-hand .machine-domino-hand{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:10px;overflow-x:hidden;overflow-y:auto;scrollbar-width:thin}
.machine-hand-panel.is-vertical-hand .machine-hand-tile{width:100%;padding:4px 2px!important}
.machine-hand-panel.is-vertical-hand .machine-domino{width:98px;height:52px;grid-template-columns:1fr 8px 1fr;grid-template-rows:1fr}
.machine-hand-panel.is-vertical-hand .machine-domino.is-double{width:52px;height:98px;grid-template-columns:1fr;grid-template-rows:1fr 8px 1fr}
.machine-hand-panel.is-vertical-hand .machine-domino.is-double .machine-domino-divider{width:100%;height:8px}
.machine-hand-panel.is-vertical-hand .machine-domino .machine-domino-divider{width:8px;height:100%}
.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-playable:hover{transform:translateX(3px)}
.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-selected{transform:translateX(5px)}
@media(max-width:900px){
  body.machine-domino-match-live .machine-topbar{padding:14px 16px}
  .machine-room-style-board{min-height:440px;padding:78px 84px 90px}
  .machine-hand-panel{width:min(700px,calc(100vw - 20px))}
}
@media(max-width:760px){
  .machine-room-style-board{min-height:390px;padding:74px 74px 88px}
  .machine-board-sequence{min-height:220px}
  .machine-hand-panel{width:min(660px,calc(100vw - 16px));max-height:min(60vh,440px)}
  .machine-hand-panel.is-vertical-hand{width:min(228px,calc(100vw - 12px))}
}
@media(max-width:520px){
  body.machine-domino-match-live .machine-topbar h1{font-size:1.55rem}
  .machine-room-style-board{min-height:340px;padding:82px 16px 94px}
  .machine-hand-panel{left:8px;right:8px;bottom:8px;width:auto}
  .machine-hand-panel.is-positioned{width:min(620px,calc(100vw - 16px))}
  .machine-hand-panel.is-vertical-hand{width:min(220px,calc(100vw - 12px))}
}

/* v0.7.47 — true vertical hand dock with no sideways scrolling */
.machine-hand-panel.is-vertical-hand{
  box-sizing:border-box;
  width:min(304px,calc(100vw - 16px))!important;
  max-width:calc(100vw - 16px)!important;
  min-width:0;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  overscroll-behavior-x:none;
}
.machine-hand-panel.is-vertical-hand *{box-sizing:border-box;max-width:100%}
.machine-hand-panel.is-vertical-hand .machine-hand-toolbar{
  grid-template-columns:minmax(0,1fr) minmax(0,1fr) 36px;
  gap:6px;
}
.machine-hand-panel.is-vertical-hand .machine-hand-reset-position,
.machine-hand-panel.is-vertical-hand .machine-hand-rotate{
  min-width:0;
  padding:6px 5px;
  font-size:.69rem;
  overflow:hidden;
  text-overflow:ellipsis;
}
.machine-hand-panel.is-vertical-hand .machine-hand-heading{
  width:100%;
  min-width:0;
  gap:8px;
  overflow:hidden;
}
.machine-hand-panel.is-vertical-hand .machine-hand-heading>div{
  width:100%;
  min-width:0;
}
.machine-hand-panel.is-vertical-hand .machine-hand-heading h2{
  font-size:1.35rem;
  white-space:normal;
}
.machine-hand-panel.is-vertical-hand .machine-hand-heading p{
  font-size:.78rem;
  line-height:1.35;
  overflow-wrap:anywhere;
}
.machine-hand-panel.is-vertical-hand .machine-hand-controls{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(74px,.72fr);
  gap:7px;
  width:100%;
  min-width:0;
}
.machine-hand-panel.is-vertical-hand .machine-hand-controls button{
  width:100%;
  min-width:0;
  padding:8px 6px;
  font-size:.72rem;
  white-space:normal;
  line-height:1.15;
}
.machine-hand-panel.is-vertical-hand .machine-training-tip{
  width:100%;
  min-width:0;
  font-size:.76rem;
  overflow-wrap:anywhere;
}
.machine-hand-panel.is-vertical-hand .machine-domino-hand{
  display:flex!important;
  flex-direction:column!important;
  flex-wrap:nowrap!important;
  align-items:center!important;
  justify-content:flex-start!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  min-height:0!important;
  max-height:none!important;
  gap:7px!important;
  padding:7px 2px 4px!important;
  overflow-x:hidden!important;
  overflow-y:visible!important;
  scrollbar-width:none;
  touch-action:pan-y;
}
.machine-hand-panel.is-vertical-hand .machine-domino-hand::-webkit-scrollbar:horizontal{display:none}
.machine-hand-panel.is-vertical-hand .machine-hand-tile{
  flex:0 0 auto!important;
  width:100%!important;
  min-width:0!important;
  padding:3px 2px!important;
  overflow:hidden;
}
.machine-hand-panel.is-vertical-hand .machine-domino{
  width:88px!important;
  height:46px!important;
  grid-template-columns:1fr 7px 1fr!important;
  grid-template-rows:1fr!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino.is-double{
  width:46px!important;
  height:88px!important;
  grid-template-columns:1fr!important;
  grid-template-rows:1fr 7px 1fr!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino .machine-domino-divider{
  width:7px!important;
  height:100%!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino.is-double .machine-domino-divider{
  width:100%!important;
  height:7px!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino-half{padding:5px!important}
.machine-hand-panel.is-vertical-hand .machine-pip{width:6px!important;height:6px!important}
@media(max-width:760px){
  .machine-hand-panel.is-vertical-hand,
  .machine-hand-panel.is-vertical-hand.is-positioned{
    width:min(292px,calc(100vw - 12px))!important;
    max-width:calc(100vw - 12px)!important;
  }
}
@media(max-width:360px){
  .machine-hand-panel.is-vertical-hand,
  .machine-hand-panel.is-vertical-hand.is-positioned{
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    padding-left:10px;
    padding-right:10px;
  }
  .machine-hand-panel.is-vertical-hand .machine-hand-controls{
    grid-template-columns:minmax(0,1fr) 68px;
  }
}


/* v0.7.48 — connected Machine Domino board, matching the live-room yard */
.machine-room-style-board{
  position:relative;
  display:block;
  min-height:520px;
  padding:0!important;
  overflow:hidden;
}
.machine-connected-layer{
  position:absolute;
  inset:0;
  z-index:3;
  pointer-events:none;
}
.machine-connected-spinner,
.machine-connected-piece{
  position:absolute;
  left:var(--machine-x);
  top:var(--machine-y);
  transform:translate(-50%,-50%);
  display:grid;
  place-items:center;
}
.machine-connected-spinner{z-index:6;min-width:64px;min-height:64px}
.machine-connected-piece{z-index:4}
.machine-connected-spinner .machine-domino,
.machine-connected-piece .machine-domino{
  margin:0!important;
  transform:none!important;
}
.machine-domino.machine-board-domino{
  border-width:3px;
  border-radius:10px;
  box-shadow:0 5px 13px rgba(0,0,0,.5);
}
.machine-domino.machine-board-horizontal{
  width:92px;
  height:50px;
  grid-template-columns:1fr 3px 1fr;
  grid-template-rows:1fr;
}
.machine-domino.machine-board-horizontal .machine-domino-divider{width:3px;height:100%}
.machine-domino.machine-board-vertical{
  width:50px;
  height:92px;
  grid-template-columns:1fr;
  grid-template-rows:1fr 3px 1fr;
}
.machine-domino.machine-board-vertical .machine-domino-divider{width:100%;height:3px}
.machine-domino.machine-board-domino .machine-domino-half{padding:5px}
.machine-domino.machine-board-domino .machine-pip{width:7px;height:7px}
.machine-connected-spinner .machine-domino{
  box-shadow:0 0 0 3px rgba(34,197,94,.72),0 5px 14px rgba(0,0,0,.55);
}
.machine-connected-piece.is-double .machine-domino{
  box-shadow:0 0 0 3px rgba(34,197,94,.48),0 5px 13px rgba(0,0,0,.5);
}
.machine-room-style-board .machine-drop-zone{
  left:var(--machine-drop-x)!important;
  right:auto!important;
  top:var(--machine-drop-y)!important;
  bottom:auto!important;
  transform:translate(-50%,-50%);
}
.machine-room-style-board .machine-drop-zone.is-over{
  transform:translate(-50%,-50%) scale(1.08);
}
.machine-board-sequence{display:none!important}
@media(max-width:760px){
  .machine-room-style-board{min-height:440px}
  .machine-domino.machine-board-horizontal{width:78px;height:43px}
  .machine-domino.machine-board-vertical{width:43px;height:78px}
  .machine-domino.machine-board-domino .machine-domino-half{padding:4px}
  .machine-domino.machine-board-domino .machine-pip{width:6px;height:6px}
  .machine-room-style-board .machine-drop-zone{width:62px;min-height:66px;padding:6px}
}
@media(max-width:520px){
  .machine-room-style-board{min-height:400px}
  .machine-domino.machine-board-horizontal{width:70px;height:39px}
  .machine-domino.machine-board-vertical{width:39px;height:70px}
  .machine-domino.machine-board-domino .machine-pip{width:5px;height:5px}
  .machine-room-style-board .machine-drop-zone{width:56px;min-height:60px}
}

/* v0.7.70 — compact live match header and true full-board mode */
body.machine-domino-match-live .machine-shell{
  width:min(1480px,calc(100% - 18px));
  padding-top:8px;
}
body.machine-domino-match-live .machine-topbar{
  min-height:54px;
  padding:8px 12px;
  align-items:center;
  border-radius:16px;
}
body.machine-domino-match-live .machine-topbar>div:first-child{
  display:flex;
  align-items:center;
  min-width:0;
}
body.machine-domino-match-live .machine-topbar>div:first-child h1,
body.machine-domino-match-live .machine-topbar>div:first-child p,
body.machine-domino-match-live .machine-topbar>div:first-child .eyebrow{
  display:none!important;
}
body.machine-domino-match-live .machine-topbar .back-link{
  margin:0;
  white-space:nowrap;
}
body.machine-domino-match-live .machine-header-actions{
  margin-left:auto;
  max-width:none;
  gap:6px;
}
body.machine-domino-match-live .machine-header-actions .button,
body.machine-domino-match-live .machine-header-actions button,
body.machine-domino-match-live .game-sound-switch{
  min-height:36px;
  padding:7px 10px;
  font-size:.82rem;
}
body.machine-domino-match-live #machine-status:empty{display:none}
body.machine-domino-match-live #machine-stage{margin-top:6px}
body.machine-domino-match-live .machine-domino-room-head{padding-bottom:4px}
body.machine-domino-match-live .machine-domino-room-title h2{font-size:clamp(1.45rem,2.4vw,2.15rem)}
body.machine-domino-match-live .machine-domino-room-title p{font-size:.88rem}
body.machine-domino-match-live .machine-domino-score-row{margin-top:8px;gap:8px}
body.machine-domino-match-live .machine-seat-card{padding:8px 12px}

.machine-board-focus-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-bottom:8px;
}
.machine-board-focus-toolbar>span{
  color:#e2e8f0;
  font-weight:900;
  letter-spacing:.02em;
}
.machine-board-fullscreen-button{
  min-height:38px;
  padding:8px 12px;
  white-space:nowrap;
}
body.machine-domino-match-live .machine-room-style-board{
  min-height:clamp(540px,67vh,860px);
}

body.machine-board-focus-active{overflow:hidden!important}
#machine-stage:fullscreen,
#machine-stage.machine-board-focus{
  position:fixed!important;
  inset:0!important;
  z-index:5000!important;
  width:100vw!important;
  height:100dvh!important;
  max-width:none!important;
  margin:0!important;
  padding:8px!important;
  overflow:hidden!important;
  background:#080b14!important;
}
#machine-stage:fullscreen .machine-domino-room-shell,
#machine-stage.machine-board-focus .machine-domino-room-shell{
  height:100%;
  min-height:0;
  display:grid;
  grid-template-rows:auto auto minmax(0,1fr);
  gap:7px;
}
#machine-stage:fullscreen .machine-domino-room-head,
#machine-stage.machine-board-focus .machine-domino-room-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:0 4px;
}
#machine-stage:fullscreen .machine-domino-room-title p,
#machine-stage.machine-board-focus .machine-domino-room-title p{
  display:none;
}
#machine-stage:fullscreen .machine-domino-room-title h2,
#machine-stage.machine-board-focus .machine-domino-room-title h2{
  margin:0;
  font-size:1.35rem;
}
#machine-stage:fullscreen .machine-domino-score-row,
#machine-stage.machine-board-focus .machine-domino-score-row{
  margin:0;
  gap:8px;
}
#machine-stage:fullscreen .machine-seat-card,
#machine-stage.machine-board-focus .machine-seat-card{
  padding:7px 10px;
}
#machine-stage:fullscreen .machine-room-table-wrap,
#machine-stage.machine-board-focus .machine-room-table-wrap{
  min-height:0;
  height:100%;
  display:grid;
}
#machine-stage:fullscreen .machine-room-table,
#machine-stage.machine-board-focus .machine-room-table,
#machine-stage:fullscreen .machine-room-table-inner,
#machine-stage.machine-board-focus .machine-room-table-inner{
  height:100%;
  min-height:0;
}
#machine-stage:fullscreen .machine-room-table,
#machine-stage.machine-board-focus .machine-room-table{
  padding:4px;
}
#machine-stage:fullscreen .machine-room-table-inner,
#machine-stage.machine-board-focus .machine-room-table-inner{
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto auto;
  padding:8px;
  border-width:4px;
}
#machine-stage:fullscreen .machine-room-style-board,
#machine-stage.machine-board-focus .machine-room-style-board{
  min-height:0!important;
  height:100%!important;
}
#machine-stage:fullscreen .machine-room-table-footer,
#machine-stage.machine-board-focus .machine-room-table-footer{
  margin-top:6px;
}
#machine-stage:fullscreen>.machine-footer-actions,
#machine-stage.machine-board-focus>.machine-footer-actions{
  display:none!important;
}
#machine-stage:fullscreen .machine-hand-panel,
#machine-stage.machine-board-focus .machine-hand-panel,
#machine-stage:fullscreen .machine-hand-launcher,
#machine-stage.machine-board-focus .machine-hand-launcher{
  z-index:5200;
}

@media(max-width:700px){
  body.machine-domino-match-live .machine-shell{width:calc(100% - 8px);padding-top:4px}
  body.machine-domino-match-live .machine-topbar{min-height:46px;padding:6px 8px}
  body.machine-domino-match-live .machine-header-actions .button,
  body.machine-domino-match-live .machine-header-actions button{padding:6px 8px;font-size:.75rem}
  body.machine-domino-match-live .machine-header-actions .button[href*="domino.php"]{display:none}
  body.machine-domino-match-live .machine-domino-room-title p{display:none}
  body.machine-domino-match-live .machine-room-style-board{min-height:58vh}
  .machine-board-focus-toolbar{position:sticky;top:0;z-index:30;margin:0 0 6px;padding:4px;border-radius:10px;background:rgba(8,11,20,.92)}
  #machine-stage:fullscreen,
  #machine-stage.machine-board-focus{padding:4px!important}
  #machine-stage:fullscreen .machine-domino-room-head,
  #machine-stage.machine-board-focus .machine-domino-room-head{display:none}
  #machine-stage:fullscreen .machine-domino-score-row,
  #machine-stage.machine-board-focus .machine-domino-score-row{grid-template-columns:1fr 1fr}
  #machine-stage:fullscreen .machine-seat-card,
  #machine-stage.machine-board-focus .machine-seat-card{padding:5px 7px;font-size:.78rem}
  #machine-stage:fullscreen .machine-room-table-footer,
  #machine-stage.machine-board-focus .machine-room-table-footer{font-size:.78rem}
  #machine-stage:fullscreen .machine-domino-controls,
  #machine-stage.machine-board-focus .machine-domino-controls{margin-top:4px}
}

/* v0.7.77 — immediate start with optional rules dialog */
.machine-start-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.machine-rule-summary{margin:0;text-align:center;color:#cbd5e1;font-size:.85rem;font-weight:750}
.machine-rules-dialog{
  width:min(720px,calc(100vw - 24px));
  max-height:min(88vh,760px);
  padding:0;
  border:1px solid rgba(196,181,253,.5);
  border-radius:24px;
  background:#111421;
  color:#f8fafc;
  box-shadow:0 28px 90px rgba(0,0,0,.72);
  overflow:auto;
}
.machine-rules-dialog::backdrop{background:rgba(2,6,23,.8);backdrop-filter:blur(5px)}
.machine-rules-form{display:grid;gap:20px;padding:22px}
.machine-rules-head{display:flex;align-items:flex-start;justify-content:space-between;gap:18px}
.machine-rules-head h2{margin:4px 0 3px;font-size:1.75rem}
.machine-rules-head p{margin:0;color:#aeb7c8}
.machine-rules-head .eyebrow{color:#67e8f9;font-size:.7rem;font-weight:900;letter-spacing:.12em}
.machine-rules-close{display:grid;place-items:center;flex:0 0 auto;width:40px;height:40px;padding:0;border:1px solid rgba(255,255,255,.18);border-radius:50%;background:rgba(255,255,255,.06);color:#fff;font-size:1.5rem}
.machine-rules-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.machine-rules-grid label{display:grid;gap:7px;color:#e2e8f0;font-weight:850}
.machine-rules-grid select{width:100%;min-height:46px;padding:10px 12px;border:1px solid rgba(255,255,255,.17);border-radius:12px;background:#202536;color:#fff}
.machine-rule-check{display:flex;align-items:flex-start;gap:11px;padding:13px;border:1px solid rgba(34,211,238,.28);border-radius:14px;background:rgba(34,211,238,.08)}
.machine-rule-check input{margin-top:4px}
.machine-rule-check span{display:grid;gap:2px}.machine-rule-check small{color:#b9c2d3}
.machine-rules-actions{display:flex;justify-content:flex-end;gap:10px}
@media(max-width:620px){
  .machine-start-actions,.machine-rules-grid{grid-template-columns:1fr}
  .machine-rules-form{padding:17px}
  .machine-rules-actions{display:grid;grid-template-columns:1fr 1fr}
}

/* v0.7.79 — require a side choice when double-click has two legal placements */
.machine-branch-choice-overlay{position:fixed;inset:0;z-index:12000;display:grid;place-items:center;padding:16px;background:rgba(2,6,23,.78);backdrop-filter:blur(4px)}
.machine-branch-choice-card{display:grid;gap:16px;width:min(540px,calc(100vw - 24px));padding:20px;border:1px solid rgba(103,232,249,.42);border-radius:22px;background:linear-gradient(145deg,#171a2b,#0c0f1c);box-shadow:0 28px 80px rgba(0,0,0,.72)}
.machine-branch-choice-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.machine-branch-choice-head span{color:#67e8f9;font-size:.68rem;font-weight:1000;letter-spacing:.12em}.machine-branch-choice-head h2{margin:4px 0 0;font-size:1.45rem}.machine-branch-choice-head>button{display:grid;place-items:center;width:38px;height:38px;padding:0;border:1px solid rgba(255,255,255,.18);border-radius:50%;background:rgba(255,255,255,.06);color:#fff;font-size:1.4rem}
.machine-branch-choice-tile{display:grid;place-items:center;min-height:118px}.machine-branch-choice-tile .machine-domino{transform:rotate(90deg) scale(.82)}
.machine-branch-choice-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}.machine-branch-choice{display:grid;gap:4px;min-height:72px;padding:12px;border:1px solid rgba(255,255,255,.15);border-radius:14px;color:#fff}.machine-branch-choice.is-left{background:linear-gradient(145deg,#0f766e,#155e75)}.machine-branch-choice.is-right{background:linear-gradient(145deg,#6d28d9,#7e22ce)}.machine-branch-choice span{font-size:1.05rem;font-weight:1000}.machine-branch-choice strong{font-size:.78rem;color:#e2e8f0}.machine-branch-choice-cancel{width:100%}
@media(max-width:480px){.machine-branch-choice-actions{grid-template-columns:1fr}.machine-branch-choice-card{padding:16px}.machine-branch-choice-head h2{font-size:1.2rem}}

/* v0.7.80 — visible domino drag preview in normal and Full Board modes */
#machine-stage>.machine-domino-drag-ghost{
  position:fixed!important;
  z-index:22000!important;
  display:grid!important;
  visibility:visible!important;
  opacity:1!important;
  margin:0!important;
  pointer-events:none!important;
  filter:none!important;
  transform:translate(-50%,-50%) rotate(-4deg) scale(1.08)!important;
  outline:4px solid rgba(103,232,249,.95);
  outline-offset:4px;
  box-shadow:0 0 0 8px rgba(34,211,238,.16),0 22px 48px rgba(0,0,0,.72)!important;
}
#machine-stage:fullscreen>.machine-domino-drag-ghost,
#machine-stage.machine-board-focus>.machine-domino-drag-ghost{z-index:30000!important}

/* v0.7.70 — yard-first layout with all match status below the board */
body.machine-domino-match-live .machine-domino-room-head,
body.machine-domino-match-live .machine-domino-score-row{
  display:none!important;
}
.machine-domino-yard-first{
  display:grid;
  grid-template-rows:minmax(0,1fr);
  gap:0;
}
.machine-domino-yard-first .machine-room-table-inner{
  display:grid;
  grid-template-rows:auto minmax(720px,1fr) auto auto;
  gap:8px;
  padding:10px;
}
body.machine-domino-match-live .machine-room-style-board{
  min-height:clamp(720px,78vh,980px)!important;
  border-radius:24px;
}
.machine-yard-status-strip{
  display:grid;
  grid-template-columns:minmax(160px,1fr) auto auto auto minmax(160px,1fr);
  align-items:center;
  gap:8px;
  margin-top:4px;
  padding:8px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  background:rgba(3,7,18,.9);
}
.machine-yard-player,
.machine-yard-machine{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
  padding:7px 10px;
  border-radius:12px;
  background:rgba(255,255,255,.055);
}
.machine-yard-player span,
.machine-yard-machine span{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-weight:800;
}
.machine-yard-player strong,
.machine-yard-machine strong{white-space:nowrap;color:#bbf7d0}
.machine-yard-player small,
.machine-yard-machine small{white-space:nowrap;color:#94a3b8}
.machine-turn-banner-bottom{
  margin:0;
  min-width:120px;
  padding:9px 14px;
  white-space:nowrap;
}
.machine-open-end-summary-bottom{
  justify-content:center;
  flex-wrap:nowrap;
}
.machine-open-end-summary-bottom span{padding:6px 8px}
.machine-open-end-summary-bottom strong{min-width:28px;height:28px}
.machine-yard-status-strip .machine-boneyard-badge{
  padding:9px 13px;
  font-size:.95rem;
}
.machine-domino-yard-first .machine-domino-controls{
  margin-top:0;
}
#machine-stage:fullscreen .machine-domino-yard-first,
#machine-stage.machine-board-focus .machine-domino-yard-first{
  grid-template-rows:minmax(0,1fr)!important;
}
#machine-stage:fullscreen .machine-domino-yard-first .machine-room-table-inner,
#machine-stage.machine-board-focus .machine-domino-yard-first .machine-room-table-inner{
  grid-template-rows:auto minmax(0,1fr) auto auto;
}
#machine-stage:fullscreen .machine-yard-status-strip,
#machine-stage.machine-board-focus .machine-yard-status-strip{
  margin-top:2px;
  padding:6px;
}
#machine-stage:fullscreen .machine-room-style-board,
#machine-stage.machine-board-focus .machine-room-style-board{
  min-height:0!important;
  height:100%!important;
}
@media(max-width:1100px){
  .machine-yard-status-strip{
    grid-template-columns:1fr auto auto 1fr;
  }
  .machine-open-end-summary-bottom{
    grid-column:2 / span 2;
    grid-row:2;
  }
  .machine-turn-banner-bottom{grid-column:2}
  .machine-yard-status-strip .machine-boneyard-badge{grid-column:3}
  body.machine-domino-match-live .machine-room-style-board{min-height:650px!important}
  .machine-domino-yard-first .machine-room-table-inner{grid-template-rows:auto minmax(650px,1fr) auto auto}
}
@media(max-width:700px){
  .machine-yard-status-strip{
    grid-template-columns:1fr 1fr;
    gap:6px;
  }
  .machine-yard-player,
  .machine-yard-machine{padding:6px 8px;font-size:.82rem}
  .machine-yard-player small,
  .machine-yard-machine small{display:none}
  .machine-turn-banner-bottom{grid-column:1 / -1;grid-row:auto;text-align:center;min-width:0}
  .machine-open-end-summary-bottom{grid-column:1;grid-row:auto;justify-content:flex-start}
  .machine-yard-status-strip .machine-boneyard-badge{grid-column:2;justify-self:end}
  body.machine-domino-match-live .machine-room-style-board{min-height:520px!important}
  .machine-domino-yard-first .machine-room-table-inner{grid-template-rows:auto minmax(520px,1fr) auto auto;padding:6px}
}
@media(max-width:460px){
  body.machine-domino-match-live .machine-room-style-board{min-height:480px!important}
  .machine-domino-yard-first .machine-room-table-inner{grid-template-rows:auto minmax(480px,1fr) auto auto}
  .machine-yard-player,
  .machine-yard-machine{display:grid;gap:2px}
  .machine-open-end-summary-bottom span{font-size:.7rem}
}

/* v0.7.73 — simple bottom status, score flashes, and fitted board bounds */
.machine-room-table-inner{position:relative}
.machine-yard-status-strip.machine-yard-status-simple{
  display:grid;
  grid-template-columns:minmax(84px,1fr) minmax(150px,1.4fr) minmax(84px,1fr);
  align-items:center;
  gap:8px;
  margin-top:4px;
  padding:7px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:15px;
  background:rgba(3,7,18,.92);
}
.machine-end-pill{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:42px;
  padding:6px 10px;
  border-radius:12px;
  background:rgba(255,255,255,.055);
  color:#e2e8f0;
  font-weight:900;
}
.machine-end-pill span{font-size:.72rem;letter-spacing:.08em;color:#cbd5e1}
.machine-end-pill strong{
  display:grid;
  place-items:center;
  width:30px;
  height:30px;
  border:2px solid #111827;
  border-radius:8px;
  background:#f8fafc;
  color:#111827;
  font-size:1rem;
}
.machine-turn-banner-bottom{
  display:grid;
  place-items:center;
  min-width:0;
  min-height:42px;
  margin:0;
  padding:8px 12px;
  border-radius:12px;
  text-align:center;
  white-space:nowrap;
}
.machine-domino-yard-first .machine-domino-controls{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:10px;
  margin-top:0;
  min-height:44px;
}
.machine-domino-yard-first .machine-domino-controls .machine-boneyard-badge{
  padding:7px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  color:#cbd5e1;
  font-size:.84rem;
}
.machine-score-effects{
  position:absolute;
  inset:0;
  z-index:45;
  overflow:hidden;
  pointer-events:none;
}
.machine-score-float{
  position:absolute;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:9px 15px;
  border:2px solid #86efac;
  border-radius:999px;
  background:rgba(5,46,22,.94);
  color:#bbf7d0;
  font-size:clamp(1rem,2vw,1.45rem);
  font-weight:1000;
  letter-spacing:.04em;
  box-shadow:0 0 0 5px rgba(34,197,94,.14),0 0 28px rgba(34,197,94,.7);
  animation:machinePointsRise 1.75s ease-out forwards;
}
.machine-score-float.is-player{left:10%;bottom:9%}
.machine-score-float.is-machine{right:10%;top:10%}
@keyframes machinePointsRise{
  0%{opacity:0;transform:translateY(24px) scale(.78);filter:brightness(.9)}
  16%{opacity:1;transform:translateY(0) scale(1.08);filter:brightness(1.65)}
  35%{transform:translateY(-18px) scale(1);filter:brightness(1.1)}
  58%{opacity:1;transform:translateY(-38px) scale(1.04);filter:brightness(1.55)}
  100%{opacity:0;transform:translateY(-92px) scale(.9);filter:brightness(1)}
}
.machine-room-style-board{
  overflow:hidden!important;
  contain:layout paint;
}
#machine-stage:fullscreen .machine-yard-status-strip.machine-yard-status-simple,
#machine-stage.machine-board-focus .machine-yard-status-strip.machine-yard-status-simple{
  grid-template-columns:minmax(84px,1fr) minmax(150px,1.4fr) minmax(84px,1fr);
  padding:6px;
}
@media(max-width:700px){
  .machine-yard-status-strip.machine-yard-status-simple{
    grid-template-columns:minmax(72px,1fr) minmax(122px,1.5fr) minmax(72px,1fr);
    gap:5px;
    padding:5px;
  }
  .machine-end-pill{min-height:38px;padding:5px 7px;gap:5px}
  .machine-end-pill span{font-size:.62rem}
  .machine-end-pill strong{width:27px;height:27px;font-size:.9rem}
  .machine-turn-banner-bottom{min-height:38px;padding:6px 8px;font-size:.82rem}
  .machine-score-float.is-player{left:5%;bottom:8%}
  .machine-score-float.is-machine{right:5%;top:8%}
}
@media(max-width:420px){
  .machine-yard-status-strip.machine-yard-status-simple{
    grid-template-columns:72px minmax(108px,1fr) 72px;
  }
  .machine-end-pill{display:grid;gap:2px;text-align:center}
  .machine-end-pill strong{margin:auto}
  .machine-domino-yard-first .machine-domino-controls{flex-wrap:wrap}
}

/* v0.7.73 scrollable connected canvas correction */
.machine-room-style-board{
  overflow:auto!important;
  overscroll-behavior:contain;
  scrollbar-gutter:stable both-edges;
  contain:none!important;
}
.machine-connected-canvas{
  position:relative;
  min-width:100%;
  min-height:100%;
}
.machine-score-effects{
  position:absolute;
  left:10px;
  right:10px;
  top:54px;
  bottom:102px;
  z-index:45;
  overflow:hidden;
  pointer-events:none;
}
#machine-stage:fullscreen .machine-score-effects,
#machine-stage.machine-board-focus .machine-score-effects{
  top:48px;
  bottom:96px;
}
@media(max-width:700px){
  .machine-score-effects{left:6px;right:6px;top:48px;bottom:94px}
}

/* v0.7.73 — centered player scores beside Domino Yard title */
.machine-board-focus-toolbar{
  display:grid;
  grid-template-columns:minmax(120px,1fr) auto minmax(120px,1fr);
  align-items:center;
  gap:12px;
}
.machine-yard-title{
  justify-self:start;
  font-weight:1000;
  letter-spacing:.02em;
}
.machine-yard-top-scoreboard{
  justify-self:center;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  min-width:0;
  padding:5px 8px;
  border:1px solid rgba(255,255,255,.12);
  border-radius:14px;
  background:rgba(2,8,23,.72);
}
.machine-yard-top-player{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
  padding:5px 9px;
  border-radius:10px;
  background:rgba(255,255,255,.055);
}
.machine-yard-top-player span{
  max-width:180px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#f8fafc;
  font-weight:900;
}
.machine-yard-top-player strong{
  white-space:nowrap;
  color:#86efac;
  font-size:.86rem;
}
.machine-yard-top-player.is-machine strong{color:#c4b5fd}
.machine-yard-top-vs{
  color:#67e8f9;
  font-size:.72rem;
  font-weight:1000;
  letter-spacing:.08em;
}
.machine-board-fullscreen-button{justify-self:end}
#machine-stage:fullscreen .machine-yard-top-scoreboard,
#machine-stage.machine-board-focus .machine-yard-top-scoreboard{padding:4px 7px}
@media(max-width:760px){
  .machine-board-focus-toolbar{
    grid-template-columns:1fr auto;
    gap:8px;
  }
  .machine-yard-title{grid-column:1;grid-row:1}
  .machine-board-fullscreen-button{grid-column:2;grid-row:1}
  .machine-yard-top-scoreboard{
    grid-column:1 / -1;
    grid-row:2;
    width:100%;
  }
  .machine-yard-top-player{
    flex:1 1 0;
    justify-content:center;
  }
  .machine-yard-top-player span{max-width:120px}
}
@media(max-width:430px){
  .machine-yard-top-scoreboard{gap:5px;padding:4px}
  .machine-yard-top-player{display:grid;gap:1px;padding:4px 6px;text-align:center}
  .machine-yard-top-player span{max-width:105px;font-size:.76rem}
  .machine-yard-top-player strong{font-size:.75rem}
}

/* v0.7.73 — score effect targets top player card; avatar restored */
.machine-yard-top-player{
  position:relative;
  overflow:visible;
}
.machine-yard-avatar{
  flex:0 0 auto;
  display:grid!important;
  place-items:center;
  width:36px;
  height:36px;
  border:2px solid rgba(134,239,172,.72);
  border-radius:50%;
  overflow:hidden;
  background:rgba(255,255,255,.08);
  color:#f8fafc!important;
  font-weight:1000;
}
.machine-yard-top-player.is-machine .machine-yard-avatar{border-color:rgba(196,181,253,.78)}
.machine-yard-avatar img{display:block;width:100%;height:100%;object-fit:cover}
.machine-yard-avatar b{display:grid;place-items:center;width:100%;height:100%;font-size:.82rem}
.machine-yard-top-copy{
  display:grid!important;
  gap:1px;
  min-width:0;
  line-height:1.05;
}
.machine-yard-top-copy>span{
  display:block;
  max-width:116px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#f8fafc!important;
  font-weight:900;
}
.machine-yard-top-copy>strong{display:block;white-space:nowrap;color:#86efac;font-size:.86rem}
.machine-yard-top-player.is-machine .machine-yard-top-copy>strong{color:#c4b5fd}
.machine-score-float.machine-score-flight{
  position:fixed;
  z-index:10000;
  left:50vw;
  top:50vh;
  display:block;
  min-width:0;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
  color:#22ff77;
  font-size:clamp(2rem,6vw,4.2rem);
  font-weight:1000;
  line-height:1;
  text-align:center;
  box-shadow:none;
  text-shadow:0 0 8px rgba(34,255,119,.95),0 0 18px rgba(34,197,94,.75);
  pointer-events:none;
  transform:translate(-50%,-50%);
  animation:machinePointsCenterToScore 1.35s cubic-bezier(.2,.76,.32,1) forwards;
}
.machine-score-float.machine-score-flight.is-machine{
  color:#c084fc;
  text-shadow:0 0 8px rgba(192,132,252,.98),0 0 20px rgba(147,51,234,.82);
}
@keyframes machinePointsCenterToScore{
  0%{left:50vw;top:50vh;opacity:0;transform:translate(-50%,-50%) scale(.7)}
  12%{left:50vw;top:50vh;opacity:1;transform:translate(-50%,-50%) scale(1.14);filter:brightness(1.75)}
  38%{left:50vw;top:50vh;opacity:1;transform:translate(-50%,-50%) scale(1.04);filter:brightness(1)}
  78%{left:var(--machine-score-end-x);top:var(--machine-score-end-y);opacity:1;transform:translate(-50%,-100%) scale(.58)}
  88%{left:var(--machine-score-end-x);top:var(--machine-score-end-y);opacity:1;transform:translate(-50%,-100%) scale(.5)}
  100%{left:var(--machine-score-end-x);top:var(--machine-score-end-y);opacity:0;transform:translate(-50%,-100%) scale(.42)}
}
.machine-yard-top-copy>strong.is-score-land{
  animation:machineScoreTotalLand .4s ease-out;
}
.machine-yard-top-player.is-machine .machine-yard-top-copy>strong.is-score-land{
  color:#c084fc;
}
@keyframes machineScoreTotalLand{
  0%{transform:scale(.86);filter:brightness(1)}
  45%{transform:scale(1.28);filter:brightness(1.8)}
  100%{transform:scale(1);filter:brightness(1)}
}
/* v0.7.73 — definitive hand layout: desktop 3 columns, mobile 2 */
.machine-hand-panel.is-vertical-hand{
  width:min(390px,calc(100vw - 18px))!important;
  max-height:min(86vh,760px)!important;
}
.machine-hand-panel.is-vertical-hand .machine-hand-toolbar{
  grid-template-columns:minmax(0,1fr) 40px!important;
  grid-template-areas:"drag drag" "reset close"!important;
}
.machine-hand-panel.is-vertical-hand .machine-hand-reset-position{grid-area:reset!important}
.machine-hand-panel.is-vertical-hand .machine-hand-close{grid-area:close!important}
.machine-hand-panel.is-vertical-hand .machine-domino-hand{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-auto-flow:row!important;
  align-items:start!important;
  justify-items:center!important;
  align-content:start!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  max-height:calc(86vh - 240px)!important;
  gap:9px 8px!important;
  padding:8px 2px 6px!important;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  scrollbar-width:thin!important;
}
.machine-hand-panel.is-vertical-hand .machine-hand-tile{
  display:grid!important;
  justify-items:center!important;
  width:auto!important;
  min-width:0!important;
  padding:4px!important;
  overflow:visible!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino,
.machine-hand-panel.is-vertical-hand .machine-domino.is-double{
  width:46px!important;
  height:88px!important;
  grid-template-columns:1fr!important;
  grid-template-rows:1fr 7px 1fr!important;
  margin:0!important;
}
.machine-hand-panel.is-vertical-hand .machine-domino .machine-domino-divider,
.machine-hand-panel.is-vertical-hand .machine-domino.is-double .machine-domino-divider{
  width:100%!important;
  height:7px!important;
}
.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-playable:hover{transform:translateY(-4px)!important}
.machine-hand-panel.is-vertical-hand .machine-hand-tile.is-selected{transform:translateY(-6px)!important}
@media(max-width:700px){
  .machine-yard-avatar{width:32px;height:32px}
  .machine-yard-top-copy>span{max-width:92px;font-size:.76rem}
  .machine-yard-top-copy>strong{font-size:.75rem}
  .machine-hand-panel.is-vertical-hand{width:min(272px,calc(100vw - 12px))!important}
  .machine-hand-panel.is-vertical-hand .machine-domino-hand{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:8px!important;
    max-height:calc(88vh - 245px)!important;
  }
  .machine-hand-panel.is-vertical-hand .machine-domino,
  .machine-hand-panel.is-vertical-hand .machine-domino.is-double{
    width:42px!important;
    height:80px!important;
    grid-template-rows:1fr 6px 1fr!important;
  }
  .machine-hand-panel.is-vertical-hand .machine-domino .machine-domino-divider,
  .machine-hand-panel.is-vertical-hand .machine-domino.is-double .machine-domino-divider{height:6px!important}
}
