/* Rift voice-call experience */
.app-shell.rift-voice-experience{grid-template-columns:72px 250px minmax(0,1fr)!important}
.app-shell.rift-voice-experience>.member-panel{display:none!important}
.app-shell.rift-voice-experience .content-panel{min-width:0}
.app-shell.rift-voice-experience .voice-view{display:block!important;min-width:0;min-height:0;padding:0!important;background:#0d0f13;overflow:hidden}
.app-shell.rift-voice-experience .voice-view.hidden{display:none!important}
.rvc-page{height:100%;min-height:0;background:#0d0f13;color:#f2f3f5}
.rvc-layout{height:100%;min-height:0;display:grid;grid-template-columns:minmax(0,1fr);transition:grid-template-columns .18s ease}
.rift-voice-chat-open .rvc-layout{grid-template-columns:minmax(0,1fr) minmax(330px,390px)}
.rvc-stage{position:relative;display:grid;grid-template-rows:auto minmax(0,1fr) auto;min-width:0;min-height:0;padding:18px 22px 16px;background:linear-gradient(180deg,#101216 0%,#0d0f13 100%);overflow:hidden}
.rvc-stage-head{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:42px;padding:0 3px 12px}
.rvc-stage-head>div:first-child{display:flex;flex-direction:column;gap:2px}.rvc-channel-kicker{font-size:9px;font-weight:800;letter-spacing:.12em;color:#747b86}.rvc-stage-head strong{font-size:16px;font-weight:700}
.rvc-stage-actions{display:flex;gap:6px}.rvc-stage-actions button,.rvc-header-chat{border:0;background:transparent;color:#aeb3bc;width:34px;height:34px;border-radius:9px;display:grid;place-items:center;cursor:pointer}.rvc-stage-actions button:hover,.rvc-header-chat:hover,.rvc-header-chat.active,.rvc-stage-actions button.active{background:#20232a;color:#fff}.rvc-stage-actions svg,.rvc-header-chat svg{width:20px;height:20px}
.rvc-grid{min-height:0;display:grid;grid-template-columns:repeat(2,minmax(260px,1fr));grid-auto-rows:minmax(190px,1fr);gap:8px;align-content:center;justify-content:center;overflow:auto;padding:8px 2px 16px}
.rvc-grid.single{grid-template-columns:minmax(340px,620px);grid-auto-rows:minmax(250px,1fr);place-content:center}
.rvc-participant{position:relative;min-width:0;min-height:190px;border:0;border-radius:7px;background:#1a1d23;color:#fff;overflow:hidden;cursor:pointer;display:flex;align-items:center;justify-content:center;padding:0;box-shadow:inset 0 0 0 1px rgba(255,255,255,.025)}
.rvc-participant:hover{background:#1f232a}.rvc-participant-bg{position:absolute;inset:0;background:radial-gradient(circle at 50% 42%,rgba(255,255,255,.035),transparent 45%)}
.rvc-avatar{position:relative;z-index:2;width:76px!important;height:76px!important;border-radius:50%!important;display:grid!important;place-items:center!important;font-size:24px!important;font-weight:700!important;box-shadow:0 0 0 5px #111318!important;opacity:1!important}
.rvc-participant-footer{position:absolute;z-index:6;left:12px;right:12px;bottom:10px;display:flex;align-items:center;justify-content:space-between;gap:10px}.rvc-participant-footer strong{font-size:13px;font-weight:650;text-shadow:0 1px 3px #000}.rvc-participant-footer .ui0212-voice-state{display:flex;gap:5px}.rvc-participant-footer .ui0212-voice-state span{width:24px;height:24px;border-radius:50%;background:rgba(10,11,14,.78);display:grid;place-items:center}.rvc-participant-footer svg{width:14px;height:14px;color:#ef5d62}
.rvc-empty{grid-column:1/-1;align-self:center;justify-self:center;text-align:center;color:#8d93a0;max-width:420px}.rvc-empty-icon{width:64px;height:64px;border-radius:50%;background:#1a1d23;margin:0 auto 14px;display:grid;place-items:center}.rvc-empty-icon svg{width:28px}.rvc-empty h2{color:#eef0f3;margin:0 0 6px;font-size:18px}.rvc-empty p{margin:0;font-size:13px;line-height:1.45}
.rvc-callbar{align-self:end;justify-self:center;display:flex;align-items:center;gap:8px;padding:8px 10px;border-radius:18px;background:rgba(18,20,25,.92);border:1px solid rgba(255,255,255,.055);box-shadow:0 12px 34px rgba(0,0,0,.28);backdrop-filter:blur(14px)}
.rvc-call-control{width:54px;height:52px;border:0;border-radius:14px;background:#252830;color:#d7d9de;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;cursor:pointer;transition:background .13s,color .13s,transform .13s}.rvc-call-control svg{width:20px;height:20px}.rvc-call-control span{font-size:9px;font-weight:650}.rvc-call-control:hover:not(:disabled){background:#30343d;color:#fff;transform:translateY(-1px)}.rvc-call-control.active{background:#214f39;color:#59d98d}.rvc-call-control.danger.active,.rvc-call-control.leave{background:#d64046;color:#fff}.rvc-call-control.leave:hover{background:#e14b51}.rvc-call-control:disabled{opacity:.42;cursor:not-allowed}
.rvc-join-wrap{display:flex;justify-content:center;padding:10px}.rvc-join-wrap .primary-button{min-width:140px}

/* Persistent voice-channel chat */
.rvc-chat{min-width:0;min-height:0;border-left:1px solid #24272e;background:#111318;display:grid;grid-template-rows:52px minmax(0,1fr) 22px auto;overflow:hidden}
.rvc-chat>header{display:flex;align-items:center;justify-content:space-between;padding:0 12px 0 16px;border-bottom:1px solid #24272e}.rvc-chat>header>div{display:flex;align-items:center;gap:7px;min-width:0}.rvc-chat>header>div>span{font-size:21px;color:#7f8792}.rvc-chat>header strong{font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.rvc-chat>header button{width:32px;height:32px;border:0;background:transparent;color:#9ba1aa;border-radius:7px;display:grid;place-items:center;cursor:pointer}.rvc-chat>header button:hover{background:#20232a;color:#fff}.rvc-chat>header svg{width:18px;height:18px}
.rvc-chat-messages{min-height:0;overflow-y:auto;padding:14px 10px 14px 14px}.rvc-chat-message{display:grid;grid-template-columns:34px minmax(0,1fr);gap:9px;padding:7px 4px;border-radius:6px}.rvc-chat-message:hover{background:#16191e}.rvc-chat-avatar{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-size:11px;font-weight:700;color:#fff}.rvc-chat-copy{min-width:0}.rvc-chat-copy>div:first-child{display:flex;align-items:baseline;gap:7px}.rvc-chat-copy strong{font-size:13px}.rvc-chat-copy time{font-size:10px;color:#737a85}.rvc-chat-copy p{margin:2px 0 0;color:#d4d7dc;font-size:13px;line-height:1.38;overflow-wrap:anywhere}.rvc-chat-image{display:block;max-width:100%;max-height:220px;border-radius:7px;margin-top:6px}.rvc-chat-file{display:inline-flex;margin-top:6px;color:#59a8ff;font-size:12px}.rvc-chat-empty,.rvc-chat-loading{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;color:#7e858f;gap:5px;padding:30px}.rvc-chat-empty strong{font-size:14px;color:#dadddf}.rvc-chat-empty span,.rvc-chat-loading{font-size:12px}.rvc-chat-typing{height:22px;padding:1px 15px;color:#8c939d;font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rvc-chat-composer{margin:0 12px 12px;padding:6px 7px;background:#1b1e24;border-radius:9px;display:grid;grid-template-columns:30px minmax(0,1fr) 30px;align-items:end;gap:4px}.rvc-chat-composer textarea{min-height:30px;max-height:120px;resize:none;border:0;background:transparent;color:#eef0f3;outline:none;padding:6px 4px;line-height:1.35}.rvc-chat-composer textarea::placeholder{color:#747b86}.rvc-chat-plus,.rvc-chat-send{width:30px;height:30px;border:0;border-radius:7px;background:transparent;color:#a3a9b2;display:grid;place-items:center;cursor:pointer}.rvc-chat-plus:hover,.rvc-chat-send:hover{background:#292d34;color:#fff}.rvc-chat-send{color:var(--accent,#d84b4b);font-size:18px}

/* Real-time media tiles */
.rvc-participant .rvm-tile-media{z-index:1!important}.rvc-participant .rvm-tile-media video{object-fit:cover!important}.rvc-participant .rvm-tile-media.screen video{object-fit:contain!important;background:#08090c}.rvc-participant .rvm-tile-media.camera video{transform:scaleX(-1)}.rvc-participant:has(.rvm-tile-media) .rvc-participant-bg,.rvc-participant:has(.rvm-tile-media)>.rvc-avatar{opacity:0!important}.rvc-participant .rvm-media-badge{left:10px;top:10px;background:#e5393f;color:#fff;font-weight:800;border-radius:5px;padding:4px 7px}.rvc-participant .rvm-tile-pip{right:10px;bottom:42px;width:26%;border-radius:8px;border:2px solid #111318;z-index:5}

/* Mic test */
.rvm-mic-test{grid-template-columns:auto minmax(220px,1fr) 94px!important}.rvm-meter{position:relative;height:24px!important;border-radius:5px;background:repeating-linear-gradient(90deg,#2b2f36 0 5px,transparent 5px 8px);overflow:hidden!important}.rvm-meter::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(35,165,90,.16) 0 62%,rgba(240,178,50,.12) 62% 82%,rgba(242,63,67,.14) 82%);pointer-events:none}.rvm-meter i{position:relative;z-index:2;height:18px!important;min-width:0!important;width:0;background:repeating-linear-gradient(90deg,#39c879 0 5px,transparent 5px 8px)!important;border-radius:0!important;transition:none!important}.rvm-mic-status{font-variant-numeric:tabular-nums;text-align:right;white-space:nowrap}.rvm-mic-test .primary-button{min-width:112px}

/* Camera preview dialog */
.modal:has(.rvc-camera-modal){width:min(860px,94vw)!important;max-width:860px!important;padding:0!important;overflow:hidden;background:#111318!important;border:1px solid #2c3038!important}
.rvc-camera-modal{background:#111318;color:#f1f2f4}.rvc-camera-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 18px;border-bottom:1px solid #292d34}.rvc-camera-head h2{margin:0;font-size:20px}.rvc-camera-device{display:flex;gap:6px;align-items:center}.rvc-camera-device select{height:36px;min-width:220px;max-width:330px;border:1px solid #343842;background:#171a20;color:#e7e9ec;border-radius:7px;padding:0 34px 0 10px}.rvc-camera-device button{width:36px;height:36px;border:1px solid #343842;background:#171a20;color:#b8bdc5;border-radius:7px;display:grid;place-items:center;cursor:pointer}.rvc-camera-device svg{width:18px}
.rvc-camera-live-preview{position:relative;height:min(52vh,430px);background:#050608;overflow:hidden;display:grid;place-items:center}.rvc-camera-live-preview video{width:100%;height:100%;object-fit:contain;position:relative;z-index:2}.rvc-camera-live-preview.blur video{filter:blur(14px);transform:scale(1.08)!important}.rvc-camera-live-preview.custom{background-image:linear-gradient(rgba(0,0,0,.14),rgba(0,0,0,.14)),var(--rvc-custom-bg);background-size:cover;background-position:center}.rvc-camera-live-preview.custom video{width:72%;height:72%;object-fit:cover;border-radius:8px;box-shadow:0 12px 32px rgba(0,0,0,.35)}.rvc-camera-preview-label{position:absolute;z-index:4;top:10px;left:10px;background:rgba(10,11,13,.74);color:#e8eaed;border-radius:5px;padding:4px 7px;font-size:9px;font-weight:800;letter-spacing:.08em}
.rvc-camera-options{padding:12px 18px}.rvc-camera-row{display:flex;align-items:center;justify-content:space-between;min-height:38px;font-size:13px}.rvc-mini-switch{position:relative;width:40px;height:22px;border:0;border-radius:999px;background:#3b3f47;cursor:pointer}.rvc-mini-switch i{position:absolute;width:16px;height:16px;border-radius:50%;background:#fff;left:3px;top:3px;transition:transform .14s}.rvc-mini-switch.on{background:#23a55a}.rvc-mini-switch.on i{transform:translateX(18px)}
.rvc-camera-backgrounds{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-top:9px}.rvc-camera-backgrounds>button{height:64px;border:2px solid transparent;border-radius:7px;background:#20232a;color:#fff;position:relative;overflow:hidden;cursor:pointer}.rvc-camera-backgrounds>button.active{border-color:#5865f2}.rvc-camera-backgrounds>button.blur{background:linear-gradient(135deg,#62697a,#8b7183);filter:saturate(.7)}.rvc-camera-backgrounds>button.custom{background:linear-gradient(135deg,#6b4f85,#bc6a9d,#537ba6)}.rvc-camera-backgrounds span{position:absolute;left:7px;bottom:6px;padding:2px 5px;border-radius:4px;background:rgba(0,0,0,.58);font-size:10px}.rvc-camera-actions{display:flex;justify-content:flex-end;gap:8px;padding:12px 18px 16px;border-top:1px solid #292d34}

/* Light theme */
html[data-rift-effective-theme='light'] .app-shell.rift-voice-experience .voice-view,html[data-rift-effective-theme='light'] .rvc-page,html[data-rift-effective-theme='light'] .rvc-stage{background:#e7e9ed;color:#171b21}
html[data-rift-effective-theme='light'] .rvc-stage{background:linear-gradient(180deg,#eef0f3,#e5e8ec)}html[data-rift-effective-theme='light'] .rvc-channel-kicker{color:#68717c}html[data-rift-effective-theme='light'] .rvc-participant{background:#d7dbe1;color:#20252c}html[data-rift-effective-theme='light'] .rvc-participant:hover{background:#cfd4db}html[data-rift-effective-theme='light'] .rvc-avatar{box-shadow:0 0 0 5px #eef0f3!important}html[data-rift-effective-theme='light'] .rvc-participant-footer strong{text-shadow:none;color:#20252c}
html[data-rift-effective-theme='light'] .rvc-callbar{background:rgba(255,255,255,.9);border-color:#cbd1d8}html[data-rift-effective-theme='light'] .rvc-call-control{background:#dfe3e8;color:#39414a}html[data-rift-effective-theme='light'] .rvc-call-control:hover:not(:disabled){background:#d2d7de;color:#171b21}
html[data-rift-effective-theme='light'] .rvc-chat{background:#f7f8fa;border-color:#cfd4da;color:#171b21}html[data-rift-effective-theme='light'] .rvc-chat>header{border-color:#d8dde3}html[data-rift-effective-theme='light'] .rvc-chat-message:hover{background:#eceff3}html[data-rift-effective-theme='light'] .rvc-chat-copy p{color:#303741}html[data-rift-effective-theme='light'] .rvc-chat-composer{background:#e7eaee}html[data-rift-effective-theme='light'] .rvc-chat-composer textarea{color:#20252c}
html[data-rift-effective-theme='light'] .modal:has(.rvc-camera-modal),html[data-rift-effective-theme='light'] .rvc-camera-modal{background:#fff!important;color:#171b21}html[data-rift-effective-theme='light'] .rvc-camera-head,html[data-rift-effective-theme='light'] .rvc-camera-actions{border-color:#d4d9df}html[data-rift-effective-theme='light'] .rvc-camera-device select,html[data-rift-effective-theme='light'] .rvc-camera-device button{background:#f3f5f7;color:#222831;border-color:#cbd1d8}

@media(max-width:980px){.app-shell.rift-voice-experience{grid-template-columns:64px 220px minmax(0,1fr)!important}.rift-voice-chat-open .rvc-layout{grid-template-columns:minmax(0,1fr) minmax(300px,350px)}.rvc-grid{grid-template-columns:1fr}.rvc-call-control{width:48px}.rvc-call-control span{display:none}.rvc-callbar{gap:6px}}
@media(max-width:760px){.app-shell.rift-voice-experience{grid-template-columns:1fr!important}.app-shell.rift-voice-experience .server-rail,.app-shell.rift-voice-experience .channel-panel{display:none}.rvc-stage{padding:10px}.rift-voice-chat-open .rvc-layout{grid-template-columns:1fr}.rift-voice-chat-open .rvc-stage{display:none}.rvc-chat{border-left:0}.rvc-grid.single{grid-template-columns:1fr}.rvc-camera-head{align-items:flex-start;flex-direction:column}.rvc-camera-device{width:100%}.rvc-camera-device select{min-width:0;width:100%}.rvc-camera-live-preview{height:42vh}.rvm-mic-test{grid-template-columns:1fr!important}.rvm-mic-status{text-align:left}}
