/* Phone dock: the surface reaches the screen edge; safe area is internal. */
:root{--screen-safe-top:env(safe-area-inset-top,0px);--screen-safe-bottom:env(safe-area-inset-bottom,0px)}
#boot-screen{display:none}
.layout-report{display:block;width:100%;height:270px;resize:vertical;border:1px solid #dbe2eb;border-radius:12px;padding:12px;background:#f6f8fb;font:14px/1.6 ui-monospace,monospace;color:#38475a;white-space:pre-wrap;-webkit-user-select:text;user-select:text}
body[data-boot="loading"] #boot-screen{position:fixed;inset:0;z-index:50;display:grid;place-items:center;background:#f5f5f7;color:#657286;font-size:16px}
body[data-boot="loading"]>header,body[data-boot="loading"]>main,body[data-boot="loading"]>#navigation{visibility:hidden}
#navigation .nav-icon svg{display:block;width:26px;height:26px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;overflow:visible;pointer-events:none}
#navigation .nav-icon{display:grid;place-items:center;width:30px;height:30px;line-height:1;flex:none}
@media(max-width:700px) and (orientation:portrait){
 html{height:100%;min-height:0;overflow:hidden}
 body{position:fixed;inset:0;height:auto;min-height:0;max-height:none;grid-template-rows:58px minmax(0,1fr);padding-bottom:0}
 body[data-screen="welcome"],body:has(#welcome:not([hidden])){grid-template-rows:58px minmax(0,1fr)}
 body main{padding-bottom:calc(76px + env(safe-area-inset-bottom,0px))}
 body[data-screen="welcome"] main{padding-bottom:max(8px,env(safe-area-inset-bottom,0px))}
 #navigation{position:fixed;inset:auto 0 0;width:100%;max-width:none;height:calc(72px + env(safe-area-inset-bottom,0px));margin:0;padding:7px max(10px,env(safe-area-inset-right,0px)) calc(7px + env(safe-area-inset-bottom,0px)) max(10px,env(safe-area-inset-left,0px));display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;align-items:stretch;align-self:auto;border:0;border-top:1px solid #dde3ec;border-radius:26px 26px 0 0;background:rgba(250,251,254,.96);box-shadow:0 -6px 22px #19324a08;z-index:8;isolation:isolate}
 #navigation button{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-width:0;min-height:56px;padding:4px 2px;margin:0;border:1px solid transparent;border-radius:18px;background:transparent;color:#728094;font-size:11px;font-weight:500;line-height:15px;letter-spacing:.05px;transition:background .16s,color .16s,transform .1s;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;touch-action:manipulation}
 #navigation .desktop-game{display:none}
 #navigation .mobile-games{display:flex!important}
 #navigation button.active{color:#0769c8;background:#e7f1ff;border-color:#dbeaff;box-shadow:inset 0 1px 0 #ffffffa6}
 #navigation button:active{transform:scale(.95);background:#edf2f8}
 #navigation button.active:active{background:#dbeaff}
 #navigation .nav-icon{width:29px;height:29px}
 #navigation .nav-icon svg{width:26px;height:26px}
 html[data-keyboard="open"] #navigation{display:none}
 html[data-keyboard="open"] body{height:var(--vv-height);top:var(--vv-top,0px);bottom:auto}
}
@media(max-width:360px) and (orientation:portrait){#navigation{gap:2px;padding-left:7px;padding-right:7px}#navigation button{font-size:10px}}
@media(prefers-reduced-motion:reduce){#navigation button{transition:none}}
