/* Keep the maze and the thumb controls visible together, even on short phones. */
.chill-dialog[data-mode=arcade]{width:min(94vw,600px);height:min(850px,calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom)));max-height:calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));padding:20px;overflow:hidden}
.chill-dialog[data-mode=arcade][open]{display:flex;flex-direction:column}
.chill-heading{flex:none}.chill-heading h2{font-size:25px;margin:6px 0 3px;line-height:1.15}.chill-heading>p{font-size:12px;line-height:1.4;margin:0;color:#81778e}.chill-heading .eyebrow{font-size:9px}.chill-heading .chill-close{width:42px;height:42px;min-height:42px;margin:-5px -5px 0 8px}
.chill-dialog[data-mode=arcade]>.chill-status{flex:none;margin:10px 0 8px;min-height:20px;font-size:13px;font-weight:650;color:#675486}
.popcorn-game{flex:1;min-height:0;display:grid;grid-template-rows:minmax(0,1fr) auto auto;gap:12px}
.popcorn-stage{min-height:0;min-width:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.popcorn-stage canvas{width:auto;height:auto;max-width:100%;max-height:100%;aspect-ratio:1;object-fit:contain;margin:0;border-radius:14px;touch-action:none;user-select:none;-webkit-user-select:none}
.chill-controls{display:flex;align-items:center;justify-content:space-between;gap:24px;width:min(100%,400px);margin:0 auto;touch-action:none;user-select:none;-webkit-user-select:none}
.popcorn-dpad{display:grid;grid-template-columns:repeat(3,52px);grid-template-rows:repeat(3,52px);gap:4px;flex:none;touch-action:none;-webkit-touch-callout:none;background:#f1ebf9;border-radius:24px}
.popcorn-dpad button{min-width:52px;min-height:52px;padding:0;border:1px solid #d8cbea;border-radius:15px;font:700 27px/1 system-ui,sans-serif;background:#e9dff7;color:#60488d;box-shadow:0 3px 0 #d8cbea;touch-action:none}
.popcorn-dpad button[data-dir="0,-1"]{grid-area:1/2}.popcorn-dpad button[data-dir="-1,0"]{grid-area:2/1}.popcorn-dpad button[data-dir="0,1"]{grid-area:3/2}.popcorn-dpad button[data-dir="1,0"]{grid-area:2/3}
.dpad-center{grid-area:2/2;display:grid;place-items:center;color:#c6b7db;font-size:26px;pointer-events:none}
.popcorn-dpad button.is-held,.popcorn-dpad button:active{background:#7555b9;color:white;border-color:#6b4ca9;box-shadow:0 1px 0 #5d3d9c;transform:translateY(2px)}
.popcorn-actions{flex:1;min-width:0;display:flex;align-items:center;flex-direction:column;gap:10px}.popcorn-actions [data-horn]{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;width:106px;max-width:100%;min-height:100px;border-radius:27px;background:#ffedc9;border:1px solid #e4c28b;color:#745128;font-size:14px;box-shadow:0 4px 0 #e7d0a9;touch-action:manipulation}.popcorn-actions [data-horn]:active:not(:disabled){transform:translateY(2px);box-shadow:0 2px 0 #e7d0a9}.popcorn-actions [data-horn]:disabled{opacity:.55;box-shadow:none}
.popcorn-actions [data-horn] svg{width:29px;height:29px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.popcorn-actions [data-horn] small{font-size:10px;margin:0;color:inherit}.popcorn-actions p{font-size:10px;line-height:1.5;text-align:center;color:#83748f;margin:0}
.popcorn-footer{display:flex;align-items:center;justify-content:space-between;gap:12px}.popcorn-footer [data-restart]{font-size:11px;min-height:40px;padding:8px 12px;flex:none}.popcorn-footer small{font-size:10px;line-height:1.4;margin:0;text-align:right;max-width:190px}
@media(max-width:450px){.chill-dialog[data-mode=arcade]{padding:14px}.popcorn-game{gap:10px}.chill-controls{gap:18px}.chill-heading h2{font-size:23px}.popcorn-footer small{max-width:150px}}
@media(max-height:520px) and (orientation:landscape){.chill-dialog[data-mode=arcade]{width:min(96vw,850px);padding:12px 18px}.chill-heading h2{font-size:21px}.chill-heading>p{display:none}.chill-dialog[data-mode=arcade]>.chill-status{margin:6px 0}.popcorn-game{grid-template-columns:minmax(0,1fr) 290px;grid-template-rows:minmax(0,1fr) auto;gap:8px 18px}.popcorn-stage{grid-area:1/1/3/2}.chill-controls{grid-area:1/2;gap:16px}.popcorn-footer{grid-area:2/2}.popcorn-footer small{max-width:150px}.popcorn-actions [data-horn]{width:96px;min-height:88px}.popcorn-actions p{font-size:9px}}
@media(prefers-reduced-motion:reduce){.popcorn-dpad button,.popcorn-actions [data-horn]{transition:none}}
