/* Four flowing columns with one document scrollbar; no pinned controls. */
html:has(.room-layout){height:auto;min-height:100%;overflow-y:auto;overflow-x:clip;scroll-padding-top:12px}
body[data-site-page=chat]{height:auto;min-height:100dvh;overflow:visible}
body[data-site-page=chat] main{min-height:0;display:flex;flex-direction:column;gap:12px;width:100%;padding:0}
body[data-site-page=chat] .shell{height:auto;min-height:0;padding:0 18px 28px;overflow:visible}
body[data-site-page=chat] .room-live{flex:none;padding:0 12px;border:1px solid #ffffff20;border-radius:14px;background:#141210f8}
.room-live .voice-box{margin:0;border:0;background:transparent;padding:10px 0;min-height:0}
.room-switcher{display:none}
body[data-site-page=chat] .room-layout{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-template-rows:auto;align-items:start;height:auto;min-height:0;gap:14px;overflow:visible}
body[data-site-page=chat] .room-layout>.chat-panel,.room-column{min-width:0;min-height:0;height:auto;max-height:none;padding:12px;border:1px solid #ffffff20;border-radius:16px;background:#121212ed;overflow:visible}
body[data-site-page=chat] .room-layout .messages{height:auto;min-height:140px;max-height:none;flex:none;overflow:visible}
body[data-site-page=chat] .room-layout .composer{flex:none;background:#151515f9;border-radius:10px;padding-block:6px}
body[data-site-page=chat] .room-layout textarea{max-height:106px;resize:vertical}
.room-column{display:flex;flex-direction:column;gap:12px}
.room-column-head{display:flex;gap:8px;align-items:center;margin:0 0 4px;color:var(--fg);min-width:0}
.room-column-head span{display:inline-grid;place-items:center;min-width:24px;height:22px;border:1px solid #ffffff25;border-radius:5px;color:var(--accent);font:600 10px ui-monospace,monospace}
.room-column-head h2{font-size:14px;letter-spacing:.005em;line-height:1.1;margin:0}
.room-column>*,.room-layout>.chat-panel>*{min-width:0}
.room-column .voice-box{flex-wrap:wrap;justify-content:flex-start;column-gap:8px}
.room-column .voice-room-tabs,.room-column .voice-roster{flex:0 0 100%;min-width:0}
.room-column .room-live{padding:0 8px}
.room-column .voice-person{max-width:100%;overflow-wrap:anywhere}
.room-column .camera-panel,.room-column .screen-panel{padding:9px}
.room-column .drawing-tools{justify-content:flex-start;flex-wrap:wrap}
.room-column .chat-music-player,.room-column #music-mount{min-width:0}
.room-column .room-tool-mount{min-width:0;overflow-wrap:anywhere}
.room-column .screen-note{white-space:normal}
@media(min-width:761px) and (max-width:1139px){body[data-site-page=chat] .room-layout{grid-template-columns:repeat(2,minmax(0,1fr))}}
.room-column .camera-panel,.room-column .screen-panel,.room-column #music-panel,.room-column #drawing-area,.room-tool{width:100%;min-width:0;flex:none;max-height:none;border:1px solid #ffffff1b;border-radius:12px;background:#191919;padding:12px;overflow:visible}
.room-tool>summary,.room-column #music-panel summary{font-size:14px;font-weight:700;color:var(--fg);cursor:pointer}
.room-tool[open]>summary,.room-column #music-panel[open]>summary{margin-bottom:12px}
.room-tool-notice{font-size:13px;color:var(--muted);margin:8px 0 0}.room-tool-notice:empty{display:none}
.room-column .screen-bar{flex-wrap:wrap}
.room-column #drawing-area{height:auto;min-height:0}
.room-column #drawing-area .gallery-heading{font-size:15px;margin:0 0 10px}
.room-column #drawing-area .drawing-space{width:100%;padding:0}
.room-column #drawing-board{width:100%;height:auto;aspect-ratio:16/10;max-width:none;max-height:none;background:#151515;touch-action:none}
.room-column .draw-save{width:auto;padding-inline:8px;font-size:11px}
.room-column .chat-music-queue{max-height:none;overflow:visible}
.camera-videos{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(155px,100%),1fr));gap:8px}
.camera-videos:empty{display:none}
.camera-tile{min-width:0;margin:9px 0 0;display:grid;gap:4px}
.camera-tile video{width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:8px;background:#101010}
.camera-tile video.camera-mirror{transform:scaleX(-1)}
.camera-tile span,.camera-tile figcaption{font-size:12px;color:var(--muted);overflow-wrap:anywhere}
.camera-panel button{color:var(--fg);background:#202020;border:1px solid #ffffff25;border-radius:8px;padding:8px 12px}
.camera-panel button[aria-pressed=true]{border-color:var(--accent);color:var(--accent)}
@media(max-width:760px){
 body[data-site-page=chat] .shell{height:auto;min-height:0;padding:0 8px max(16px,env(safe-area-inset-bottom))}
 body[data-site-page=chat] main{gap:8px}
 body[data-site-page=chat] .room-layout{grid-template-columns:minmax(0,1fr);grid-template-rows:auto;height:auto}
 .room-switcher{display:flex;gap:6px;flex:none}
 .room-switcher a{flex:1;display:grid;place-items:center;min-height:42px;border:1px solid #ffffff28;border-radius:9px;background:#171717;color:#eee;font-size:13px;font-weight:700}
 body[data-site-page=chat] .room-layout>.chat-panel,.room-column{padding:9px}
 .room-column #drawing-board{aspect-ratio:4/3}
}
@media(max-width:410px){.room-switcher{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}}

.voice-room-tabs,.voice-roster{display:flex;gap:6px;flex-wrap:wrap;align-items:center}
.voice-room-choice,.voice-person{border:1px solid #ffffff29;background:#201e1a;color:#eee;border-radius:999px;padding:6px 10px;font-size:12px;font-weight:700}
.voice-room-choice[aria-pressed=true]{border-color:var(--accent);color:var(--accent)}
.voice-person{transition:background .16s,border-color .16s,box-shadow .16s}
.voice-person[data-mic=off]{color:#bbb;background:#1a1a1a}
.voice-person[data-speaking=true]{border-color:#e7cf52;background:#362e16;box-shadow:0 0 12px #e7cf5240}
.voice-person[data-speaking=true]::before{content:"";display:inline-block;width:6px;height:6px;border-radius:50%;background:#f5d750;margin-right:7px}
@media(prefers-reduced-motion:reduce){.voice-person{transition:none}}

.chat-danger-zone{display:flex;justify-content:flex-end;margin-top:10px}
.chat-danger-dialog h2{font-size:17px;color:#ffc1bd;margin:7px 0 4px}
.danger-badge{font:600 10px ui-monospace,monospace;color:#ffaaa5;text-transform:uppercase;letter-spacing:.12em}
.danger-button{min-height:40px;padding:8px 14px;border:1px solid #f48580;border-radius:8px;background:#8f3539;color:#fff5f3;font-size:13px;font-weight:700;white-space:nowrap}
.danger-button:hover:not(:disabled){background:#ad4143}
.chat-danger-dialog{border:1px solid #ac4b4b;background:#241719}
.chat-danger-dialog::backdrop{background:#0a0507b8}
.chat-danger-zone .danger-entry{min-height:32px;padding:4px 9px;background:transparent;border-color:#915354;color:#ffaaa5;font-size:11px}
.chat-danger-zone .danger-entry:hover:not(:disabled){background:#421d22}
.chat-danger-zone .danger-entry:focus-visible{outline:2px solid #ffaaa5;outline-offset:3px}
.room-column button.media-popout{font-size:12px;padding:6px 8px;justify-self:start;background:#231f17;border:1px solid #f2b94b48;color:#ffdb93;border-radius:7px}
.room-column button.media-popout[aria-pressed=true]{border-color:#f2b94b;color:#fff2d9}
