/* Play fills the browser window even when native fullscreen is unavailable. */
html:has(body.game-playing),body.game-playing{width:100%;height:100%;margin:0;overflow:hidden;overscroll-behavior:none}
body.game-playing #app{width:100%;height:100dvh;max-width:none;margin:0;background:#0b1720;overflow:hidden}
body.game-playing #play-screen{height:100%;display:flex;flex-direction:column;min-height:0;padding-top:env(safe-area-inset-top,0px);padding-left:env(safe-area-inset-left,0px);padding-right:env(safe-area-inset-right,0px);padding-bottom:env(safe-area-inset-bottom,0px)}
body.game-playing #play-screen>header{height:48px;min-height:48px;flex:0 0 48px;padding:0 16px;gap:20px}
body.game-playing #play-screen>footer{display:none}
body.game-playing #stage{width:100%;height:auto;min-height:0;flex:1 1 0;overflow:hidden}
body.game-playing #chapter{font-size:12px}
body.game-playing .brand{font-size:21px}
body.game-playing .brand span{font-size:10px}
#fullscreen-button{white-space:nowrap;min-width:72px;text-align:center}
#app:fullscreen{max-width:none;width:100%;height:100dvh;margin:0;background:#0b1720}
#app:fullscreen::backdrop{background:#0b1720}
body.game-playing #dialogue{bottom:12px;max-height:48%;min-height:194px;padding:16px 20px}
body.game-playing #explore-panel{bottom:12px;min-height:150px;max-height:220px;padding:12px 18px}
body.game-playing #touch-controls{bottom:240px}
body.game-playing #modal-layer{padding:max(12px,env(safe-area-inset-top,0px)) max(12px,env(safe-area-inset-right,0px)) max(12px,env(safe-area-inset-bottom,0px)) max(12px,env(safe-area-inset-left,0px))}
body.game-playing #modal{max-height:92dvh}
@media(max-width:850px){
 body.game-playing #play-screen>header{height:44px;min-height:44px;flex-basis:44px;padding:0 10px;gap:10px}
 body.game-playing #chapter{font-size:10px}
 body.game-playing nav{gap:4px}
 body.game-playing nav button{font-size:10px;padding:7px 8px}
 body.game-playing #dialogue{left:10px;right:10px;bottom:10px;min-height:194px;max-height:46%;padding:12px}
 body.game-playing #explore-panel{left:10px;right:10px;bottom:10px;min-height:200px;max-height:245px;padding:12px}
 body.game-playing #touch-controls{bottom:265px;right:12px}
 #fullscreen-button{min-width:62px}
}
@media(max-height:600px) and (min-width:600px){
 body.game-playing .brand{display:none}
 body.game-playing #play-screen>header{height:38px;min-height:38px;flex-basis:38px}
 body.game-playing #dialogue{min-height:0;max-height:52%;padding:10px 14px;gap:12px;grid-template-columns:66px 1fr}
 body.game-playing #portrait-card{width:66px;height:66px;margin-top:20px}
 body.game-playing #portrait{width:64px;height:64px}
 body.game-playing #dialogue.narrator{grid-template-columns:1fr}
 body.game-playing #dialogue-text{font-size:12px;line-height:1.65;min-height:0;margin:7px 0 9px}
 body.game-playing #speaker{font-size:13px}
 body.game-playing #choices button{font-size:11px;padding:6px 9px;min-height:30px}
 body.game-playing #explore-panel{min-height:0;max-height:38%;padding:8px 12px}
 body.game-playing #ambient-text{display:none}
 body.game-playing #objective{font-size:12px;margin:3px 0 7px}
 body.game-playing #spot-list button,body.game-playing #travel-list button{font-size:10px;padding:5px 8px}
 body.game-playing #travel-list{margin-top:5px}
 body.game-playing #touch-controls{bottom:calc(38% + 20px)}
 body.game-playing #minimap{width:96px;height:56px}
 body.game-playing .location{font-size:10px;padding:4px 8px;max-width:calc(100% - 130px)}
}
