﻿body.room-page{overflow:hidden}.room-topbar{height:58px;padding:0 20px}.room-topbar .logo{width:145px}.back-link{color:#bbb;text-decoration:none}.room-shell{height:calc(100vh - 58px);display:grid;grid-template-columns:minmax(0,1fr) 360px;background:#08090d}.stage{min-width:0;display:flex;flex-direction:column;padding:14px 14px 10px}.stream-head{display:flex;align-items:center;gap:12px;padding:3px 6px 12px}.avatar{width:42px;height:42px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(135deg,var(--cyan),#755cff,var(--pink));font-weight:900;color:#101018}.stream-title{font-weight:700}.stream-sub{font-size:12px;color:#999;margin-top:4px}.live-dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--pink);box-shadow:0 0 10px var(--pink);margin-right:5px}.video-wrap{position:relative;min-height:0;flex:1;background:#050506;border-radius:13px;overflow:hidden;display:grid;place-items:center}.video-wrap video{width:100%;height:100%;object-fit:contain;background:#050506}.video-overlay{position:absolute;inset:0;display:grid;place-items:center;background:radial-gradient(circle at 50% 25%,#282232,#08080c 68%);z-index:4}.video-overlay img{width:190px;opacity:.75}.video-overlay p{color:#aaa;text-align:center}.video-overlay button{margin-top:8px}.stream-status{position:absolute;top:14px;left:14px;z-index:5;padding:7px 10px;border-radius:7px;background:rgba(0,0,0,.62);font-size:12px}.barrage-layer{position:absolute;inset:5% 0 15%;overflow:hidden;pointer-events:none;z-index:3}.danmaku{position:absolute;left:100%;white-space:nowrap;color:#fff;font-weight:650;text-shadow:0 2px 5px #000,-1px 0 #000;font-size:18px;animation:fly linear forwards}.danmaku strong{color:#61eadd}@keyframes fly{to{transform:translateX(calc(-100vw - 100%))}}.controls{position:absolute;left:0;right:0;bottom:0;padding:42px 16px 14px;background:linear-gradient(transparent,rgba(0,0,0,.78));display:flex;align-items:center;gap:12px;opacity:.25;transition:.2s;z-index:6}.video-wrap:hover .controls{opacity:1}.icon-button{width:38px;height:38px;border:0;border-radius:50%;background:rgba(255,255,255,.15);color:#fff}.quality{margin-left:auto;background:#292b35;border:1px solid rgba(255,255,255,.14);border-radius:7px;color:#fff;padding:8px 28px 8px 10px;outline:none}.quality option{background:#20212a;color:#fff}.room-side{background:#171821;border-left:1px solid var(--line);display:flex;flex-direction:column;min-height:0}.side-head{padding:18px 18px 14px;border-bottom:1px solid var(--line)}.side-stats{display:flex;gap:20px;color:#9b9ca8;font-size:13px;margin-top:10px}.side-stats b{color:#fff}.comments{flex:1;overflow:auto;padding:14px 16px;scrollbar-width:thin}.comment{font-size:14px;line-height:1.55;margin:0 0 11px;word-break:break-word}.comment .name{color:#68dfe0;margin-right:6px}.comment.system{color:#d5a840;background:rgba(213,168,64,.08);padding:9px;border-radius:8px}.chat-bar{border-top:1px solid var(--line);padding:12px;display:flex;gap:8px}.chat-bar input{flex:1;min-width:0;border:1px solid var(--line);background:#242530;color:#fff;padding:11px 12px;border-radius:10px;outline:none}.chat-bar input:focus{border-color:var(--pink)}.send{border:0;background:var(--pink);color:#fff;border-radius:10px;padding:0 14px}.like-fab{position:absolute;right:20px;bottom:82px;z-index:8;width:52px;height:52px;border:0;border-radius:50%;background:rgba(255,255,255,.92);color:var(--pink);font-size:25px;box-shadow:0 8px 35px rgba(0,0,0,.35)}.heart-fly{position:fixed;z-index:200;font-size:28px;pointer-events:none;animation:heartUp 1.1s ease-out forwards}@keyframes heartUp{to{transform:translateY(-130px) rotate(20deg) scale(1.5);opacity:0}}.mobile-chat-toggle{display:none}
@media(max-width:820px){body.room-page{overflow:auto}.room-topbar{padding:0 11px}.room-shell{height:auto;min-height:calc(100vh - 58px);display:block}.stage{padding:0;display:block}.stream-head{padding:10px 13px}.video-wrap{height:56.25vw;min-height:220px;border-radius:0}.controls{opacity:1}.room-side{height:44vh;border-left:0}.side-head{padding:12px 14px}.comments{padding:10px 13px}.like-fab{bottom:65px;right:14px}.room-topbar .user-actions{margin-left:auto}.back-link{display:none}}



.video-wrap:fullscreen,.video-wrap:-webkit-full-screen{width:100vw;height:100vh;border-radius:0;background:#000}.video-wrap:fullscreen .controls,.video-wrap:-webkit-full-screen .controls{opacity:1}

/* Keep every desktop panel inside the viewport, regardless of source resolution. */
@media(min-width:821px){
html,body.room-page{width:100%;height:100%;max-height:100dvh;overflow:hidden}
.room-shell{height:calc(100vh - 58px);height:calc(100dvh - 58px);min-height:0;overflow:hidden}
.stage{height:100%;min-height:0;overflow:hidden;box-sizing:border-box}
.stream-head{flex:0 0 auto}
.video-wrap{width:100%;max-width:100%;max-height:100%;min-height:0;flex:1 1 0}
.video-wrap video{display:block;width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain}
.room-side{min-height:0;overflow:hidden}
}

/* Compact viewing HUD: persistent information stays outside the actual picture. */
.stream-head{min-height:28px;padding:0 3px 8px;justify-content:space-between;gap:8px}
.stream-head .stream-status{position:static;background:transparent;padding:0;font-size:12px;color:#a6a8b6}
.audio-permission{font-size:12px;color:#ffc07b;cursor:pointer;text-align:right}
.controls{left:auto;right:8px;bottom:8px;padding:0;background:transparent;gap:6px;opacity:.65}
.icon-button{width:30px;height:30px;font-size:16px}
.quality{font-size:11px;padding:6px 20px 6px 7px;background:rgba(30,31,38,.7);border-radius:6px;max-width:125px}
.like-fab{width:32px;height:32px;font-size:18px;right:12px;bottom:52px;background:rgba(255,255,255,.72);box-shadow:none}
@media(max-width:820px){.stream-head{padding:7px 11px;min-height:28px}.controls{opacity:1;right:8px;bottom:6px}.like-fab{width:30px;height:30px;font-size:17px;right:10px;bottom:46px}}

/* Last decoded picture survives source resets; controls/chat stay interactive. */
.video-wrap .held-frame{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;background:#050506;pointer-events:none;z-index:2}
