/* JH PlayLab — existing app layouts must be preserved. */
.jh-brand-home { position:absolute; bottom:10px; left:50%; transform:translateX(-50%); display:flex; align-items:center; gap:8px; z-index:40; max-width:95%; }
.jh-brand-home img { display:block; width:clamp(125px,15vw,210px); max-width:65vw; height:auto; }
.jh-brand-home.large img { width:clamp(210px,26vw,360px); }
.jh-brand-home button { border:1px solid #c9baf2; border-radius:20px; background:#fff; color:#272365; padding:6px 10px; font:12px system-ui,sans-serif; cursor:pointer; white-space:nowrap; }
.jh-brand-game { position:fixed; right:8px; bottom:6px; color:rgba(40,40,70,.55); font:10px system-ui,sans-serif; z-index:40; pointer-events:none; }
.jh-brand-overlay { position:fixed; inset:0; background:rgba(16,12,40,.56); display:none; align-items:center; justify-content:center; padding:16px; z-index:9999; }
.jh-brand-overlay.open { display:flex; }
.jh-brand-dialog { position:relative; box-sizing:border-box; width:min(92vw,560px); max-height:85vh; overflow:auto; border:4px solid #d9cafa; border-radius:24px; background:white; padding:24px; box-shadow:0 12px 35px #15103a55; color:#222250; text-align:center; font:15px/1.6 system-ui,sans-serif; }
.jh-brand-dialog img { display:block; width:min(80%,310px); margin:0 auto; }
.jh-brand-dialog h2 { font-size:19px; }
.jh-brand-dialog .jh-warning { background:#fff0f4; padding:12px; border-radius:12px; font-weight:650; }
.jh-brand-dialog .jh-close { position:absolute; right:10px; top:6px; font-size:28px; border:0; background:transparent; cursor:pointer; color:#24245c; }
@media(max-width:600px){.jh-brand-home{gap:5px;bottom:6px}.jh-brand-home img{width:130px}.jh-brand-home button{font-size:11px;padding:5px 7px}.jh-brand-dialog{padding:20px 12px}}

/* Survival: footer stays in normal flow, never covers controls. */
.lobby .jh-brand-home{position:static;transform:none;justify-content:center;flex-shrink:0;max-width:100%;margin:0 auto;gap:8px}.lobby .jh-brand-home img{width:clamp(125px,17vw,210px);max-width:55vw}.lobby #jh-brand-root{flex-shrink:0;max-width:100%}.jh-brand-game{color:#fff;opacity:.65;text-shadow:0 1px 3px #000,0 0 3px #000;right:max(8px,env(safe-area-inset-right));bottom:max(6px,env(safe-area-inset-bottom));pointer-events:none}.jh-brand-overlay{box-sizing:border-box}.jh-brand-dialog{max-height:85vh;max-height:85dvh;border:4px solid #c4a6f4;box-shadow:inset 0 0 0 2px #eee3ff,0 12px 35px #15103a55}.jh-brand-dialog h2{background:#e5d2ff;border-radius:30px;padding:8px;margin:14px 0;color:#20144e}.jh-brand-dialog .jh-warning{background:#ffe0eb}.jh-brand-dialog .jh-close{min-width:44px;min-height:44px;padding:0}.jh-brand-dialog img{max-width:75%}.jh-brand-dialog small{font-weight:700}.jh-brand-dialog button:focus-visible,.jh-info:focus-visible{outline:3px solid #22d3ee}.jh-brand-home button{min-height:32px}@media(max-height:420px){.lobby .jh-brand-home img{width:125px}.jh-brand-home button{min-height:28px;padding:3px 7px}.jh-brand-dialog{padding:12px;font-size:13px}.jh-brand-dialog h2{font-size:16px;margin:6px 0}.jh-brand-dialog p{margin:6px 0}}

/* Home branding: right-aligned footer, preserving its reserved layout space. */
.lobby #jh-brand-root{align-self:stretch;width:100%;display:flex;justify-content:flex-end;box-sizing:border-box;padding-right:max(0px,env(safe-area-inset-right));padding-bottom:max(0px,env(safe-area-inset-bottom))}.lobby .jh-brand-home{margin:0;justify-content:flex-end;max-width:100%}.lobby .jh-brand-home img{min-width:0;flex-shrink:1}.lobby .jh-brand-home button{flex-shrink:0}

/* Anchor branding to the viewport, not the centered lobby content. */
.lobby #jh-brand-root{position:fixed;right:max(12px,env(safe-area-inset-right));bottom:max(8px,env(safe-area-inset-bottom));width:auto;max-width:calc(100vw - 24px);padding:0;z-index:40;}
.lobby{padding-bottom:max(clamp(12px,3vh,30px),48px);}
