.coop-panel{position:absolute;inset:0;z-index:90;display:grid;place-items:center;padding:24px;background:#302447c9}
.coop-box{width:min(540px,100%);max-height:100%;overflow:auto;border:3px solid #baa4d0;border-radius:20px;background:#fff8f0;color:#503c69;padding:24px;box-shadow:0 12px 40px #160d3450}
.coop-box h2{margin:0;font-size:26px}.coop-actions{display:grid;gap:12px;margin:20px 0}
#coop-join-form{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
#coop-code{width:140px;font:bold 20px monospace;letter-spacing:3px;text-transform:uppercase;padding:10px;border:2px solid #baa4d0;border-radius:8px}
#coop-room{margin:16px 0;display:flex;flex-wrap:wrap;gap:12px;align-items:center}#coop-room-code{font:bold 28px monospace;letter-spacing:4px}#coop-invite{width:100%}
#btn-coop{position:absolute;right:30px;top:100px}.coop-selection{display:flex;gap:12px;align-items:center;justify-content:flex-end;margin-bottom:5px;font-size:13px}
.coop-selecting .select-intro{display:none}.coop-selecting .select-footer{display:none}.coop-picked{outline:4px solid #4eac95;outline-offset:-4px}
.coop-status{position:absolute;left:12px;top:60px;z-index:35;max-width:330px;border-radius:8px;background:#302447e8;color:#fff8f0;padding:5px 9px;font:12px system-ui;pointer-events:none}
.coop-leave{position:absolute;left:12px;top:88px;z-index:36;font-size:11px;padding:4px 8px}
.coop-host-note{position:absolute;right:20px;bottom:12px;z-index:55;background:#302447ed;color:#fff8f0;border-radius:8px;padding:7px 12px;font:14px system-ui;pointer-events:none}
.is-coop .js-replay,.is-coop #btn-pause{display:none}.is-coop [data-touch="pause"]{visibility:hidden}
body.mobile-ui .coop-panel{position:fixed;padding:12px}body.mobile-ui .coop-box{padding:16px}body.mobile-ui #screen-select #btn-coop{position:absolute;right:12px;top:68px;margin:0;padding:3px 10px;min-height:0;height:26px;font-size:11px;line-height:1;z-index:3}body.mobile-ui .coop-selection{position:sticky;top:0;z-index:4;flex-wrap:wrap;gap:6px;background:#fff8f0;padding:4px}
body.mobile-ui .coop-status{font-size:11px;top:calc(54px * var(--inv-scale,1));padding:3px 6px}body.mobile-ui:not([data-mode="night"]) .coop-status{top:58px;bottom:auto;left:150px}
body.mobile-ui .coop-leave{top:calc(76px * var(--inv-scale,1));font-size:10px}body.mobile-ui:not([data-mode="night"]) .coop-leave{top:54px;bottom:auto;left:88px;right:auto}
.hs-partner{margin-top:12px}
.hs-partner [data-partner-uid]{opacity:.65}
/* Outside the night the top-left corner holds the day tabs: keep the 2P status and leave button in the free strip under the day log. */
body:not(.mobile-ui):not([data-mode="night"]) .coop-leave{top:auto;bottom:10px;left:20px}body:not(.mobile-ui):not([data-mode="night"]) .coop-status{top:auto;bottom:13px;left:84px}
/* Keep the day tabs reachable when a faster phone clears the night during 2P QA. */
body.mobile-ui[data-mode="day"] .coop-leave{top:4px;bottom:auto;left:auto;right:60px}
body.mobile-ui[data-mode="day"] .coop-status{top:16px;bottom:auto;left:auto;right:118px;max-width:220px}
/* The cleared-night report covers the top-left corner on desktop: park the 2P status and leave button in the bottom strip, as in the day. */
body.is-coop:not(.mobile-ui):has(#wave-report:not([hidden])) .coop-leave{top:auto;bottom:10px;left:20px}body.is-coop:not(.mobile-ui):has(#wave-report:not([hidden])) .coop-status{top:auto;bottom:13px;left:84px}
/* Day, desktop: the bottom-right is the departure button; keep the guest note beside the status instead of on top of it. */
body:not(.mobile-ui):not([data-mode="night"]) .coop-host-note{right:auto;left:300px;bottom:13px}
body.mobile-ui:not([data-mode="night"]) .coop-host-note{right:auto;left:12px;bottom:12px}
