.turn-path{display:flex;justify-content:center;gap:20px;list-style:none;margin:8px 0 10px;padding:0;color:#79546a;font-size:13px;font-weight:850}.turn-path li{display:flex;gap:7px;align-items:center;min-height:28px}.turn-path .ui-icon{width:18px;height:18px}.turn-path li[aria-current=step]{color:#88324f;text-decoration:underline;text-underline-offset:5px;text-decoration-thickness:2px}.turn-path li[aria-current=step] .ui-icon{stroke:#88324f}.opponent-choice{display:grid;grid-template-columns:1fr 1fr;gap:8px 16px;align-items:center;padding:10px 0}.opponent-choice label{font-size:14px;font-weight:850}.opponent-choice p{grid-column:1/-1;font-size:13px;color:#694152;margin:0}.keep-coach{padding:12px 16px;margin:12px 0 4px;background:#fff6e3;border-radius:14px;text-align:left}.keep-coach p{font-size:14px;line-height:1.55;margin:0 0 10px;color:#673f51}.keep-coach>div{display:flex;gap:12px;flex-wrap:wrap}.die-wrap.keep-suggested .die{outline:3px solid #2f797b;outline-offset:5px}.die-wrap.keep-suggested .die-label{color:#256568;font-weight:1000}.dice-webgl{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;z-index:2}.dice-zones{position:relative;isolation:isolate}.has-dice-3d .dice-cube,.has-dice-3d .die-shadow{opacity:0}.has-dice-3d .die{background:transparent}.has-dice-3d .die-label{position:relative;z-index:3}.has-dice-3d .die:focus-visible{outline:3px solid #2f797b;outline-offset:5px}.has-dice-3d .die[aria-pressed=true]{box-shadow:0 4px 10px #a16c3340}.dice-zones.has-dice-3d .die-wrap.is-dragged{opacity:.35}.pocket-pals{position:relative;margin:8px 4% 0;min-height:190px;isolation:isolate}.pocket-pals canvas,.pals-fallback{position:absolute;inset:0 0 52px;width:100%;height:138px;pointer-events:none}.pals-fallback{display:flex;justify-content:space-around;align-items:flex-end;gap:20px}.pals-fallback img{height:132px;width:26%;object-fit:contain;filter:drop-shadow(0 4px 4px #4d294e22)}.pals-fallback img:nth-child(2){height:62px;width:14%;margin-bottom:8px}.pals-actions{display:flex;justify-content:space-around;gap:12px;padding-top:134px}.pals-actions button{display:flex;align-items:center;justify-content:center;gap:7px;background:#fff6e3;color:#673f51;border:1px solid #cda78e;border-radius:12px;font:inherit;font-size:13px;font-weight:850;min-height:44px;min-width:80px;padding:8px 12px;cursor:pointer;box-shadow:0 3px 8px #713d2630}.pals-actions .ui-icon{width:18px;height:18px}.pals-actions button:hover{background:#fff0cc}.pals-actions button:active{transform:translateY(1px)}.pals-actions button:focus-visible{outline:3px solid #2f797b;outline-offset:3px}.pocket-pals>p{margin:8px 0 0;padding:6px 10px;text-align:center;color:#673f51;background:#fff6e3;border-radius:8px;font-size:13px;line-height:1.5}.graphics-status{font-size:13px;line-height:1.5;color:#694152}.living-star-dust{position:absolute;inset:0;pointer-events:none;overflow:hidden;z-index:1}.living-star-dust i{position:absolute;width:4px;height:4px;background:#fff3be;border-radius:50%;box-shadow:0 2px 5px #ffda8880;animation:table-firefly 8s ease-in-out infinite}.table-stage{contain:paint}.table-stage[data-mood=celebrate]{animation:table-celebrate 1.4s ease-out}.paused .living-star-dust,.room-sleeping .living-star-dust,.match-paused .living-star-dust{display:none}.pocket-pals[data-mode=sleep] #pal-amor{background:#f1e9f7}.pals-fallback[data-mode=wave] img:first-child{animation:pal-hello .8s ease-out 2}.pals-fallback[data-mode=dance] img{animation:pal-hello .65s ease-out 4}.pals-fallback[data-mode=sleep] img:last-child{transform:rotate(-10deg) translateY(3px);opacity:.9}.pals-fallback[data-mode=knock] img:last-child{animation:pal-hello .3s ease-out 3}@keyframes table-firefly{0%,100%{transform:translateY(0);opacity:.1}45%{transform:translateY(-15px);opacity:.7}70%{transform:translateY(-7px);opacity:.3}}@keyframes pal-hello{30%{transform:rotate(-5deg) translateY(-4px)}65%{transform:rotate(4deg) translateY(-2px)}}@keyframes table-celebrate{20%{filter:brightness(1.08)}100%{filter:brightness(1)}}@media(max-width:600px){.turn-path{gap:16px;font-size:12px}.pocket-pals{margin-inline:3%;min-height:180px}.pocket-pals canvas,.pals-fallback{height:128px}.pals-fallback img{height:124px}.pals-actions{padding-top:124px;gap:6px}.pals-actions button{min-width:68px;font-size:12px;padding:8px}.pocket-pals>p{font-size:12px}.opponent-choice{grid-template-columns:1fr}.opponent-choice p{grid-column:auto}.keep-coach{padding:12px}.keep-coach p{font-size:13px}.keep-coach .small-button{font-size:13px}}@media(prefers-reduced-motion:reduce){.living-star-dust{display:none}.table-stage[data-mood=celebrate],.pals-fallback img{animation:none!important}.pals-actions button:active{transform:none}}

.paused .pals-fallback img,.match-paused .pals-fallback img,.room-sleeping .pals-fallback img{animation:none!important}
.turn-path{width:max-content;max-width:100%;margin:8px auto 10px;padding:6px 12px;background:#fff6e3;border-radius:12px}.table-controls .tray-heading{padding:8px 12px;background:#fff6e3;border-radius:12px}.table-controls .tray-heading h2{color:#673f51}.table-controls #roll-count{color:#673f51;background:transparent}.table-stage[data-mood=celebrate]{animation:none}

/* Keep the same primary controls beside the dice during a turn. */
.play-area>.turn-actions{position:sticky;top:8px;z-index:9;margin:0;padding:8px 12px;background:#fff6e3;box-shadow:0 4px 10px #713d2620}.play-area>.turn-actions .roll-button{min-height:48px;padding:10px 24px;font-size:16px}.play-area>.turn-actions .finish-button{min-height:44px;padding:10px 12px;font-size:13px}.play-area>.turn-actions .watch-controls{margin:0}@media(max-width:600px){.play-area>.turn-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:8px;padding:8px}.play-area>.turn-actions button{width:100%;min-width:0;font-size:12px;padding:8px}.play-area>.turn-actions .watch-controls{grid-column:1/-1}}

/* Responsive menu composition: keep the room and the primary action in view. */
.scene-menu,.family-game .scene-menu{display:grid;grid-template-columns:repeat(5,minmax(0,1fr)) 94px;align-items:stretch}
.scene-menu>.motion-controls{display:flex;justify-content:center;align-items:center;gap:6px;min-width:0}
.scene-menu>.motion-controls button{flex:0 0 44px;width:44px;min-width:44px;height:44px;padding:8px}
.scene-menu>.motion-controls .button-label{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
.scene-menu>button{min-width:0}.scene-menu>button .button-label{white-space:normal}
.turn-assist{display:flex;align-items:start;justify-content:center;gap:8px;margin:6px 0}
.turn-assist>#keep-idea,.table-extras>summary{min-height:44px;margin:0;padding:10px 12px;border-radius:10px;background:#fff6e3;color:#673f51;font-size:13px;font-weight:850;line-height:1.5}
.table-extras{min-width:0}.table-extras>summary{cursor:pointer}.table-extras[open]{flex:1 1 55%}.table-extras .turn-utility{margin-top:8px}.table-extras #mode-note{margin-top:8px}
.coach-welcome #coach-player{margin:8px 0 0;font-size:13px;font-weight:700}
@media(max-width:999px){.scene-menu,.family-game .scene-menu{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:600px){
 .players>.player{flex:1 0 80px;min-width:80px}
 .scene-menu,.family-game .scene-menu{grid-template-columns:minmax(0,1fr) minmax(0,1fr) 94px}
 .scene-menu>button{flex-direction:column;gap:2px;padding:6px 4px;line-height:1.25}
 .scene-menu>button .button-label{font-size:12px}
 .turn-assist>#keep-idea,.table-extras>summary{padding:10px 8px;font-size:12px}
}
@media(max-width:359px){.play-area>.turn-actions{grid-template-columns:minmax(0,1fr)}.play-area>.turn-actions .roll-button{min-height:48px}.play-area>.turn-actions .finish-button{min-height:44px}.play-area>.turn-actions #roll-label{white-space:nowrap}}

/* The optional keep advice belongs beside the dice, not before the room. */
.table-stage>.turn-assist{margin:12px 4% 0}.table-stage>.keep-coach{margin:10px 4%}.table-extras #mode-note{padding:6px 10px;background:#fff6e3;border-radius:8px;color:#673f51}
@media(max-width:600px){
 .title-row>div>p{display:none}
 .players>.player{padding:6px;gap:4px}
 .players>.player .portrait{width:32px;height:32px}
 .table-controls .tray-heading{padding:6px 8px;gap:6px}
 .table-controls .tray-heading h2{font-size:14px;line-height:1.3;margin:0;flex:1}
 .table-controls #roll-count{padding:0;white-space:nowrap;font-size:11px}
 .table-controls .turn-path{padding:2px 8px;margin:5px auto}
 .table-controls #instruction{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
}
