/* Instant full-screen game page (/play): the page is the game, nothing scrolls,
   zooms or opens a long-press callout. dvh follows iOS/Android toolbars. */
html, body { height: 100%; height: 100dvh; overflow: hidden; overscroll-behavior: none; }
body { position: fixed; inset: 0; touch-action: none; -webkit-touch-callout: none;
       -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
header.mu-topbar { padding-left: max(14px, env(safe-area-inset-left)); padding-right: max(14px, env(safe-area-inset-right)); }
canvas#canvas { inset: 0; width: 100%; height: 100dvh; -webkit-touch-callout: none; user-select: none; }
#muStick { margin-left: env(safe-area-inset-left); margin-bottom: env(safe-area-inset-bottom); }
#muRBtn, #muCamBtn { margin-right: env(safe-area-inset-right); }
/* iPhone Safari has no Fullscreen API: one line suggesting Add to Home Screen. */
#dwA2hs { position: fixed; z-index: 120; left: 50%; bottom: calc(10px + env(safe-area-inset-bottom)); transform: translateX(-50%);
          max-width: calc(100vw - 24px); padding: 7px 34px 7px 14px; border-radius: 999px; background: rgba(255, 250, 238, .96);
          color: #23364e; font: 600 13px/1.3 -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; white-space: nowrap;
          overflow: hidden; text-overflow: ellipsis; box-shadow: 0 4px 18px rgba(58, 91, 125, .25); border: 1px solid #f0c66a; }
#dwA2hs button { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none;
                 color: #8a6a2a; font: 700 16px/1 sans-serif; padding: 4px 6px; cursor: pointer; }
/* The bright theme's gradient title lacked background-clip, so it drew a solid bar. */
.mu-brand-title { -webkit-background-clip: text; background-clip: text; }
/* Canvas only, edge to edge: the portal top bar is hidden; the corner button shows it as an overlay. */
header#muTopBar { display: none !important; }
body.dw-menu header#muTopBar { display: flex !important; position: fixed; top: 0; left: 0; right: 0; z-index: 110; padding-left: calc(48px + env(safe-area-inset-left)); }
#dwMenuBtn { position: fixed; z-index: 111; top: calc(6px + env(safe-area-inset-top)); left: calc(6px + env(safe-area-inset-left));
             width: 32px; height: 32px; padding: 0; border-radius: 50%; border: 1px solid rgba(240, 198, 106, .8);
             background: rgba(255, 250, 238, .6); color: #23364e; font: 700 17px/1 sans-serif; cursor: pointer; opacity: .75; }
body.dw-menu #dwMenuBtn { opacity: 1; background: #fff8ea; }
/* Hidden proxy input for the phone keyboard (16px avoids iOS focus zoom). */
#dwIme { position: fixed; width: 2px; height: 2px; padding: 0; border: 0; margin: 0; opacity: 0; font-size: 16px;
         color: transparent; background: transparent; caret-color: transparent; z-index: 1; }
#dwEcho { display: none; position: fixed; z-index: 112; left: 50%; transform: translateX(-50%); max-width: calc(100vw - 24px);
          padding: 6px 14px; border-radius: 999px; background: rgba(255, 250, 238, .95); color: #23364e; border: 1px solid #f0c66a;
          font: 600 15px/1.3 -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; white-space: nowrap; pointer-events: none;
          box-shadow: 0 4px 18px rgba(58, 91, 125, .25); }
body.dw-typing #dwEcho { display: block; }
#muKeys { display: none !important; }
#dwImeForm { position: fixed; left: 0; top: 0; width: 0; height: 0; margin: 0; padding: 0; border: 0; }
#dwQBtn { display: none; position: fixed; z-index: 112; top: calc(46px + env(safe-area-inset-top)); left: calc(6px + env(safe-area-inset-left));
          padding: 8px 14px; border-radius: 999px; border: 1px solid #f0c66a; background: #fff8ea; color: #23364e;
          font: 700 14px/1 -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; cursor: pointer; box-shadow: 0 4px 14px rgba(58, 91, 125, .25); }
body.dw-menu #dwQBtn { display: block; }
