/* Zerocord — black & gray theme. All art and styling original. */
@font-face { font-family: "DM Sans"; src: url(/fonts/dmsans.woff) format("woff"); font-weight: 100 1000; font-style: normal; font-display: swap; }
:root {
  --rail: #1e1e21;
  --side: #2b2b2f;
  --chat: #313136;
  --elev: #38383d;
  --elev-2: #404046;
  --elev-1: #2b2b2f;
  --input: #38383d;
  --float: #111113;
  --panel: #232326;
  --code: #2b2b2f;
  --hover: rgba(78, 78, 86, .32);
  --active: rgba(78, 78, 86, .6);
  --line: #3b3b41;
  --line-2: #46464d;
  --text: #dbdbde;
  --text-2: #b5b5bb;
  --muted: #949499;
  --faint: #6d6d74;
  --white: #f2f2f3;
  --ink: #111113;
  --danger: #ef4444;
  --online: #23a55a;
  --idle: #f0b232;
  --dnd: #f23f43;
  --offline: #80848e;
  --speak: #23a55a;
  --mention-bg: rgba(240, 178, 50, .08);
  --mention-bar: #f0b232;
  --font: "gg sans", "DM Sans", "Noto Sans", "Helvetica Neue", Helvetica, Arial, "Noto Color Emoji", "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--rail); color: var(--text); font: 16px/1.375 var(--font); -webkit-font-smoothing: antialiased; overflow: hidden; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input, textarea, select { font: inherit; color: var(--text); }
a { color: #d4d4d8; text-decoration: underline; text-decoration-color: rgba(255,255,255,.3); }
a:hover { text-decoration-color: currentColor; }
svg.i { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
svg.i.sm { width: 16px; height: 16px; }
svg.i.xs { width: 14px; height: 14px; }
svg.i.lg { width: 24px; height: 24px; }
.hidden { display: none !important; }
.grow { flex: 1; min-width: 0; }
.ellip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- buttons ---------- */
.btn { height: 38px; padding: 0 16px; border-radius: 6px; background: var(--elev-2); font-weight: 600; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: background .15s, filter .15s; white-space: nowrap; }
.btn:hover { background: #2c2c31; }
.btn.primary { background: var(--white); color: var(--ink); }
.btn.primary:hover { background: #d4d4d8; }
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger:hover { background: #dc2626; }
.btn.green { background: #238636; color: #fff; }
.btn.green:hover { background: #2ea043; }
.btn.link { background: none; color: var(--text-2); padding: 0 8px; }
.btn.link:hover { text-decoration: underline; }
.btn.outline { background: transparent; border: 1px solid var(--line-2); }
.btn.outline:hover { background: var(--hover); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; }
.btn.wide { width: 100%; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.icon-btn { width: 32px; height: 32px; border-radius: 6px; display: grid; place-items: center; color: var(--muted); transition: background .12s, color .12s; flex: none; position: relative; }
.icon-btn:hover { background: var(--hover); color: var(--text); }
.icon-btn.active { color: var(--text); }
.icon-btn.red { color: var(--danger); }
.icon-btn.red:hover { color: #f87171; }

/* ---------- form ---------- */
.field-label { display: block; font-size: 12px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--text-2); margin-bottom: 8px; }
.field-label .req { color: var(--danger); }
.field-label .err { color: var(--danger); text-transform: none; font-weight: 500; font-style: italic; letter-spacing: 0; }
.input, .select, .textarea { display: block; width: 100%; padding: 10px 12px; border-radius: 6px; background: var(--rail); border: 1px solid var(--line); outline: none; font-size: 15px; transition: border-color .15s; }
.input:focus, .select:focus, .textarea:focus { border-color: #52525b; }
.textarea { resize: vertical; min-height: 80px; }
.field { margin-bottom: 18px; }
.hint { color: var(--muted); font-size: 13px; margin-top: 6px; }
input[type=color] { width: 56px; height: 38px; padding: 2px; border-radius: 6px; background: var(--rail); border: 1px solid var(--line); cursor: pointer; }
.switch { position: relative; width: 40px; height: 24px; border-radius: 12px; background: #3f3f46; transition: background .15s; flex: none; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch.on { background: #238636; }
.switch.on::after { transform: translateX(16px); }
.row { display: flex; gap: 12px; align-items: center; }
.row.top { align-items: flex-start; }

/* ---------- avatars ---------- */
.av { position: relative; flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: var(--ink); text-transform: uppercase; user-select: none; }
.av img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.av.s16 { width: 16px; height: 16px; font-size: 8px; }
.av.s20 { width: 20px; height: 20px; font-size: 9px; }
.av.s24 { width: 24px; height: 24px; font-size: 10px; }
.av.s32 { width: 32px; height: 32px; font-size: 13px; }
.av.s40 { width: 40px; height: 40px; font-size: 15px; }
.av.s80 { width: 80px; height: 80px; font-size: 30px; }
.av.s96 { width: 96px; height: 96px; font-size: 36px; }
.av .st { position: absolute; right: -2px; bottom: -2px; width: 14px; height: 14px; border-radius: 50%; border: 3px solid var(--side); background: var(--offline); }
.av.s40 .st { width: 16px; height: 16px; right: -3px; bottom: -3px; border-width: 3px; }
.av.s80 .st { width: 24px; height: 24px; border-width: 5px; right: 0; bottom: 0; }
.st.online { background: var(--online); }
.st.idle { background: var(--idle); }
.st.dnd { background: var(--dnd); }
.st.offline { background: var(--offline); }
.st.offline::after { content: ""; position: absolute; inset: 25%; border-radius: 50%; background: var(--side); }
.st.idle::after { content: ""; position: absolute; width: 60%; height: 60%; top: -10%; left: -10%; border-radius: 50%; background: var(--side); }
.st.dnd::after { content: ""; position: absolute; left: 20%; right: 20%; top: 42%; height: 16%; border-radius: 2px; background: var(--side); }
.status-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.status-dot.online { background: var(--online); } .status-dot.idle { background: var(--idle); } .status-dot.dnd { background: var(--dnd); } .status-dot.offline, .status-dot.invisible { background: var(--offline); }

/* ---------- badges ---------- */
.badge-ic { width: 22px; height: 22px; border-radius: 6px; display: inline-grid; place-items: center; color: var(--c); background: color-mix(in srgb, var(--c) 14%, var(--float)); border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); flex: none; }
.badge-ic svg { width: 14px; height: 14px; }
.badge-ic img { width: 16px; height: 16px; object-fit: contain; }
.badge-ic.lg { width: 44px; height: 44px; border-radius: 12px; }
.badge-ic.lg svg { width: 26px; height: 26px; }
.badge-ic.lg img { width: 30px; height: 30px; }
.badge-ic.md { width: 32px; height: 32px; border-radius: 9px; }
.badge-ic.md svg { width: 19px; height: 19px; }
.badge-row { display: inline-flex; gap: 2px; padding: 3px; border-radius: 8px; background: rgba(0,0,0,.55); flex-wrap: wrap; }
.inline-badges { display: inline-flex; gap: 3px; vertical-align: -5px; margin-left: 2px; }
.inline-badges .badge-ic { width: 18px; height: 18px; border-radius: 5px; }
.inline-badges .badge-ic svg { width: 12px; height: 12px; }

/* ---------- auth ---------- */
.auth { height: 100%; display: grid; place-items: center; padding: 20px; overflow: auto;
  background: radial-gradient(circle at 20% 20%, #1a1a1d 0, transparent 40%), radial-gradient(circle at 80% 90%, #161618 0, transparent 45%), var(--rail); }
.auth::before { content: ""; position: fixed; inset: 0; background-image: radial-gradient(rgba(255,255,255,.05) 1px, transparent 1px); background-size: 22px 22px; pointer-events: none; }
.auth-card { position: relative; width: min(480px, 100%); background: var(--chat); border: 1px solid var(--line); border-radius: 10px; padding: 32px; box-shadow: 0 24px 60px rgba(0,0,0,.6); }
.auth-card h1 { margin: 0 0 6px; font-size: 24px; text-align: center; }
.auth-card .sub { color: var(--muted); text-align: center; margin: 0 0 22px; }
.auth-logo { display: flex; justify-content: center; align-items: center; gap: 10px; margin-bottom: 18px; font-weight: 800; font-size: 20px; letter-spacing: -.02em; }
.auth-foot { margin-top: 12px; font-size: 14px; color: var(--muted); }
.auth-foot button { color: var(--text); font-weight: 600; }
.auth-foot button:hover { text-decoration: underline; }
.code-input { text-align: center; font-size: 28px; letter-spacing: 14px; font-weight: 700; font-family: var(--mono); padding: 12px; }
.form-error { color: #f87171; font-size: 14px; margin-bottom: 12px; min-height: 0; }

/* ---------- layout ---------- */
.app { height: 100%; display: flex; }
.rail { width: 72px; flex: none; background: var(--rail); display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 0; overflow-y: auto; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail-item { position: relative; width: 72px; display: flex; justify-content: center; }
.rail-pill { position: absolute; left: 0; top: 50%; width: 4px; height: 0; border-radius: 0 4px 4px 0; background: var(--white); transform: translateY(-50%); transition: height .18s ease; }
.rail-item.unread .rail-pill { height: 8px; }
.rail-item:hover .rail-pill { height: 20px; }
.rail-item.active .rail-pill { height: 36px; }
.rail-btn { width: 42px; height: 42px; border-radius: 50%; background: var(--chat); display: grid; place-items: center; font-weight: 600; font-size: 14px; color: var(--text); overflow: hidden; transition: border-radius .18s ease, background .18s, color .18s; position: relative; }
.rail-btn img { width: 100%; height: 100%; object-fit: cover; }
.rail-item:hover .rail-btn, .rail-item.active .rail-btn { border-radius: 14px; }
.rail-item:hover .rail-btn.home, .rail-item.active .rail-btn.home { background: var(--white); color: var(--ink); }
.rail-btn.home { background: var(--chat); }
.rail-btn.home svg { width: 24px; height: 24px; }
.rail-btn.green { color: var(--online); }
.rail-item:hover .rail-btn.green { background: var(--online); color: #fff; }
.rail-sep { width: 32px; height: 2px; border-radius: 1px; background: var(--line-2); flex: none; }
.ping { position: absolute; right: 10px; bottom: -3px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--dnd); color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 3px solid var(--rail); box-sizing: content-box; }

.sidebar { width: 240px; flex: none; background: var(--side); display: flex; flex-direction: column; min-height: 0; border-radius: 10px 0 0 0; overflow: hidden; }
.side-head { height: 48px; flex: none; display: flex; align-items: center; padding: 0 16px; border-bottom: 1px solid rgba(0,0,0,.28); box-shadow: 0 1px 0 rgba(0,0,0,.08); font-weight: 700; gap: 8px; cursor: pointer; transition: background .12s; }
.side-head:hover { background: var(--hover); }
.side-head.static { cursor: default; padding: 0 10px; }
.side-head.static:hover { background: none; }
.side-search { width: 100%; height: 28px; border-radius: 4px; background: var(--rail); color: var(--muted); font-size: 13px; text-align: left; padding: 0 8px; }
.side-scroll { flex: 1; overflow-y: auto; padding: 8px 8px 16px; scrollbar-width: thin; scrollbar-color: #2a2a2e transparent; }
.cat { display: flex; align-items: center; gap: 2px; padding: 16px 4px 4px 2px; color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; cursor: pointer; user-select: none; }
.cat:hover { color: var(--text); }
.cat .chev { transition: transform .15s; }
.cat.closed .chev { transform: rotate(-90deg); }
.cat .add { opacity: 0; margin-left: auto; color: var(--muted); }
.cat:hover .add { opacity: 1; }
.cat .add:hover { color: var(--text); }
.ch { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 8px; margin: 1px 0; border-radius: 6px; color: var(--muted); cursor: pointer; position: relative; transition: background .1s, color .1s; }
.ch:hover { background: var(--hover); color: var(--text-2); }
.ch.active { background: var(--active); color: var(--text); }
.ch.unread { color: var(--text); font-weight: 600; }
.ch.unread::before { content: ""; position: absolute; left: -8px; width: 4px; height: 8px; border-radius: 0 4px 4px 0; background: var(--white); }
.ch .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ch .tools { display: none; gap: 2px; }
.ch:hover .tools, .ch.active .tools { display: flex; }
.ch .tools button { color: var(--muted); display: grid; place-items: center; width: 20px; height: 20px; }
.ch .tools button:hover { color: var(--text); }
.ch .count { background: var(--dnd); color: #fff; font-size: 11px; font-weight: 800; padding: 0 6px; border-radius: 8px; line-height: 16px; }
.vc-list { margin: 0 0 4px 30px; }
.vc-u { display: flex; align-items: center; gap: 8px; height: 30px; padding: 0 8px; border-radius: 6px; color: var(--muted); font-size: 14px; cursor: pointer; }
.vc-u:hover { background: var(--hover); color: var(--text-2); }
.vc-u .av { box-shadow: 0 0 0 0 var(--speak); transition: box-shadow .1s; }
.vc-u.speaking .av { box-shadow: 0 0 0 2px var(--speak); }
.vc-u .flags { margin-left: auto; display: flex; gap: 4px; color: var(--muted); }
.live-tag { background: var(--dnd); color: #fff; font-size: 10px; font-weight: 800; border-radius: 4px; padding: 1px 5px; letter-spacing: .03em; }

.dm-row { display: flex; align-items: center; gap: 12px; height: 42px; padding: 0 8px; border-radius: 6px; color: var(--muted); cursor: pointer; margin: 1px 0; position: relative; }
.dm-row:hover { background: var(--hover); color: var(--text-2); }
.dm-row.active { background: var(--active); color: var(--text); }
.dm-row .x { display: none; margin-left: auto; color: var(--muted); }
.dm-row:hover .x { display: grid; }
.dm-row.unread { color: var(--text); font-weight: 600; }
.side-link { display: flex; align-items: center; gap: 12px; height: 42px; padding: 0 12px; border-radius: 6px; color: var(--muted); cursor: pointer; font-weight: 600; }
.side-link:hover { background: var(--hover); color: var(--text-2); }
.side-link.active { background: var(--active); color: var(--text); }
.side-title { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 12px; font-weight: 700; text-transform: uppercase; padding: 18px 8px 6px; }

.voice-conn { border-top: 1px solid var(--line); padding: 8px; background: var(--side); }
.voice-conn .top { display: flex; align-items: center; gap: 6px; }
.voice-conn .lbl { flex: 1; min-width: 0; }
.voice-conn .lbl b { display: block; color: var(--online); font-size: 14px; }
.voice-conn .lbl small { color: var(--muted); font-size: 12px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.voice-conn .lbl small:hover { text-decoration: underline; cursor: pointer; color: var(--text-2); }
.voice-conn .acts { display: flex; gap: 8px; margin-top: 8px; }
.voice-conn .acts button { flex: 1; height: 32px; border-radius: 6px; background: var(--elev); display: grid; place-items: center; color: var(--text-2); }
.voice-conn .acts button:hover { background: var(--elev-2); color: var(--text); }
.voice-conn .acts button.on { background: var(--white); color: var(--ink); }
.signal { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.signal i { width: 3px; background: var(--online); border-radius: 1px; }

.user-panel { height: 56px; flex: none; display: flex; align-items: center; gap: 4px; padding: 0 8px; background: var(--panel); }
.me-btn { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; padding: 4px; border-radius: 6px; text-align: left; transition: background .12s; }
.me-btn:hover { background: var(--hover); }
.me-btn .av .st { border-color: var(--panel); }
.me-btn .meta { min-width: 0; line-height: 1.2; }
.me-btn .meta b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me-btn .meta small { display: block; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-panel .icon-btn.off { color: var(--danger); }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; background: var(--chat); }
.main-head { height: 48px; flex: none; display: flex; align-items: center; gap: 8px; padding: 0 8px 0 16px; border-bottom: 1px solid rgba(0,0,0,.28); box-shadow: 0 1px 0 rgba(0,0,0,.08); }
.main-head .title { font-weight: 700; display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.main-head .title svg { color: var(--muted); }
.main-head .topic { color: var(--muted); font-size: 14px; border-left: 1px solid var(--line-2); padding-left: 12px; margin-left: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.main-head .tools { margin-left: auto; display: flex; gap: 4px; align-items: center; }
.main-head .icon-btn.active { color: var(--text); }
.main-body { flex: 1; min-height: 0; display: flex; }
.banner { background: #27272a; color: var(--text); font-size: 13px; font-weight: 600; text-align: center; padding: 6px; }
.chat { flex: 1; min-width: 0; display: flex; flex-direction: column; }

/* ---------- messages ---------- */
.messages { flex: 1; overflow-y: auto; padding-bottom: 12px; overflow-anchor: none; scrollbar-width: thin; scrollbar-color: #2a2a2e transparent; }
.chan-start { padding: 16px 16px 8px; margin-top: 16px; }
.chan-start .big { width: 68px; height: 68px; border-radius: 50%; background: var(--elev-2); display: grid; place-items: center; margin-bottom: 8px; }
.chan-start .big svg { width: 40px; height: 40px; }
.chan-start h1 { font-size: 30px; margin: 8px 0; letter-spacing: -.01em; }
.chan-start p { margin: 0; color: var(--muted); }
.loader { text-align: center; padding: 14px; color: var(--muted); font-size: 13px; }
.divider { display: flex; align-items: center; margin: 24px 16px 8px; color: var(--muted); font-size: 12px; font-weight: 600; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }
.divider span { padding: 0 6px; }
.msg { position: relative; padding: 2px 48px 2px 72px; min-height: 22px; }
.msg.head { margin-top: 17px; padding-top: 2px; }
.msg:hover, .msg.menu-open { background: rgba(255,255,255,.025); }
.msg.mentioned { background: var(--mention-bg); }
.msg.mentioned::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--mention-bar); }
.msg.editing { background: rgba(255,255,255,.03); }
.msg > .av { position: absolute; left: 16px; top: 4px; cursor: pointer; }
.msg.has-reply > .av { top: 26px; }
.msg .hdr { display: flex; align-items: baseline; gap: 8px; line-height: 22px; }
.msg .name { font-weight: 600; cursor: pointer; }
.msg .name:hover { text-decoration: underline; }
.msg .ts { color: var(--muted); font-size: 12px; }
.msg .side-ts { position: absolute; left: 0; width: 64px; text-align: right; top: 4px; font-size: 11px; color: var(--faint); display: none; line-height: 18px; }
.msg:not(.head):hover .side-ts { display: block; }
.msg .content { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text); line-height: 1.375; }
.msg.pending .content { color: var(--muted); }
.msg.failed .content { color: var(--danger); }
.msg .edited { font-size: 10px; color: var(--faint); margin-left: 4px; }
.msg .reply-ref { display: flex; align-items: center; gap: 4px; font-size: 13px; color: var(--muted); margin-bottom: 2px; position: relative; height: 20px; cursor: pointer; }
.msg .reply-ref::before { content: ""; position: absolute; left: -38px; top: 10px; width: 32px; height: 12px; border-left: 2px solid var(--line-2); border-top: 2px solid var(--line-2); border-top-left-radius: 6px; }
.msg .reply-ref .nm { font-weight: 600; color: var(--text-2); }
.msg .reply-ref .tx { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60ch; }
.msg .reply-ref:hover .tx { color: var(--text); }
.msg.flash { animation: flash 1.6s ease; }
@keyframes flash { 0%, 40% { background: rgba(255,255,255,.08); } 100% { background: transparent; } }
.content code { font-family: var(--mono); font-size: 85%; background: var(--code); border: 1px solid var(--line); padding: 0 .25em; border-radius: 4px; }
.content pre { background: var(--code); border: 1px solid var(--line); padding: 8px 10px; border-radius: 6px; overflow-x: auto; margin: 4px 0; max-width: 90%; white-space: pre; }
.content pre code { background: none; border: 0; padding: 0; font-size: 13px; }
.content blockquote { margin: 0; padding-left: 12px; border-left: 4px solid #3f3f46; }
.content .mention { background: rgba(255,255,255,.12); color: #fff; border-radius: 3px; padding: 0 2px; font-weight: 500; cursor: pointer; }
.content .mention:hover { background: rgba(255,255,255,.22); }
.content .spoiler { background: #27272a; color: transparent; border-radius: 3px; cursor: pointer; }
.content .spoiler.shown { background: rgba(255,255,255,.08); color: inherit; cursor: auto; }
.content .big-emoji { font-size: 44px; line-height: 1.2; }
.attachments { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.attachments img { max-width: min(400px, 100%); max-height: 320px; border-radius: 8px; cursor: zoom-in; display: block; background: var(--elev); }
.reactions { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.react { height: 26px; display: inline-flex; align-items: center; gap: 6px; padding: 0 7px; border-radius: 8px; background: var(--elev); border: 1px solid transparent; font-size: 14px; transition: border-color .1s, background .1s; }
.react b { font-size: 13px; color: var(--text-2); font-weight: 600; }
.react:hover { border-color: var(--line-2); }
.react.mine { background: rgba(255,255,255,.1); border-color: #71717a; }
.react.mine b { color: var(--text); }
.react.add { opacity: 0; color: var(--muted); }
.msg:hover .react.add { opacity: 1; }
.msg-tools { position: absolute; right: 14px; top: -16px; display: none; background: var(--elev); border: 1px solid var(--line); border-radius: 8px; padding: 2px; box-shadow: 0 4px 14px rgba(0,0,0,.35); z-index: 2; }
.msg:hover .msg-tools, .msg.menu-open .msg-tools { display: flex; }
.msg-tools button { width: 32px; height: 32px; border-radius: 6px; display: grid; place-items: center; color: var(--text-2); font-size: 17px; }
.msg-tools button:hover { background: var(--elev-2); color: var(--text); }
.msg-tools button.red:hover { color: var(--danger); }
.msg-tools .sep { width: 1px; background: var(--line); margin: 6px 2px; }
.edit-wrap { background: var(--input); border-radius: 8px; padding: 10px 12px; margin: 4px 0; }
.edit-wrap textarea { width: 100%; background: none; border: 0; outline: none; resize: none; line-height: 1.375; padding: 0; }
.edit-hint { font-size: 12px; color: var(--muted); margin: 2px 0 4px; }
.edit-hint button { color: #d4d4d8; }
.edit-hint button:hover { text-decoration: underline; }

/* ---------- composer ---------- */
.composer { padding: 0 16px; flex: none; }
.reply-bar { display: flex; align-items: center; gap: 8px; background: var(--elev); border-radius: 8px 8px 0 0; padding: 8px 12px 8px 16px; font-size: 14px; color: var(--muted); }
.reply-bar b { color: var(--text-2); }
.reply-bar button { margin-left: auto; color: var(--muted); }
.reply-bar button:hover { color: var(--text); }
.reply-bar + .composer-box { border-radius: 0 0 8px 8px; }
.uploads { display: flex; gap: 10px; padding: 12px; background: var(--input); border-radius: 8px 8px 0 0; border-bottom: 1px solid var(--line); overflow-x: auto; }
.uploads + .composer-box { border-radius: 0 0 8px 8px; }
.upload-tile { position: relative; width: 140px; flex: none; background: var(--elev-2); border-radius: 6px; padding: 8px; }
.upload-tile img { width: 100%; height: 100px; object-fit: cover; border-radius: 4px; display: block; }
.upload-tile .nm { font-size: 12px; color: var(--muted); margin-top: 6px; }
.upload-tile button { position: absolute; top: -8px; right: -8px; width: 26px; height: 26px; border-radius: 6px; background: var(--elev); border: 1px solid var(--line); color: var(--danger); display: grid; place-items: center; }
.composer-box { display: flex; align-items: flex-start; gap: 4px; background: var(--input); border-radius: 8px; padding: 0 6px 0 4px; min-height: 44px; }
.composer-box .icon-btn { margin-top: 6px; }
.composer-box textarea { flex: 1; background: none; border: 0; outline: none; resize: none; padding: 11px 4px; line-height: 1.375; max-height: 50vh; min-height: 44px; }
.composer-box textarea::placeholder { color: var(--faint); }
.composer-box.blocked { opacity: .6; }
.under { height: 24px; display: flex; align-items: center; justify-content: space-between; font-size: 12px; color: var(--text-2); padding: 0 2px; }
.under .warn { color: #f87171; font-weight: 600; }
.typing { display: flex; align-items: center; gap: 6px; }
.typing .dots { display: inline-flex; gap: 3px; }
.typing .dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--text-2); animation: blink 1.2s infinite; }
.typing .dots i:nth-child(2) { animation-delay: .2s; } .typing .dots i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 60%, 100% { opacity: .25; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-2px); } }

/* ---------- members ---------- */
.members { width: 240px; flex: none; background: var(--side); overflow-y: auto; padding: 8px 8px 20px; scrollbar-width: thin; scrollbar-color: #2a2a2e transparent; }
.mem-cat { color: var(--muted); font-size: 12px; font-weight: 700; text-transform: uppercase; padding: 20px 8px 4px; }
.mem { display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 8px; border-radius: 6px; cursor: pointer; transition: background .1s; }
.mem:hover { background: var(--hover); }
.mem.off { opacity: .35; }
.mem.off:hover { opacity: 1; }
.mem .meta { min-width: 0; flex: 1; line-height: 1.2; }
.mem .meta b { display: flex; align-items: center; gap: 4px; font-weight: 500; font-size: 15px; }
.mem .meta b span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mem .meta small { display: block; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.crown { color: #eab308; }

/* ---------- friends / home ---------- */
.friends { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.friends .list { flex: 1; overflow-y: auto; padding: 16px 20px; }
.fr-tabs { display: flex; gap: 8px; align-items: center; }
.fr-tab { padding: 2px 10px; border-radius: 6px; color: var(--muted); font-weight: 600; font-size: 15px; }
.fr-tab:hover { background: var(--hover); color: var(--text-2); }
.fr-tab.active { background: var(--active); color: var(--text); }
.fr-row { display: flex; align-items: center; gap: 12px; height: 62px; padding: 0 10px; border-top: 1px solid var(--line); border-radius: 8px; cursor: pointer; }
.fr-row:hover { background: var(--hover); border-top-color: transparent; }
.fr-row:hover + .fr-row { border-top-color: transparent; }
.fr-row .meta { flex: 1; min-width: 0; }
.fr-row .meta b { display: block; }
.fr-row .meta small { color: var(--muted); }
.fr-row .act { width: 36px; height: 36px; border-radius: 50%; background: var(--elev); display: grid; place-items: center; color: var(--muted); }
.fr-row:hover .act { background: var(--rail); }
.fr-row .act:hover { color: var(--text); }
.empty { text-align: center; color: var(--muted); padding: 60px 20px; }
.empty svg { width: 64px; height: 64px; opacity: .4; margin-bottom: 8px; }

/* ---------- voice stage ---------- */
.stage { flex: 1; background: #000; display: flex; flex-direction: column; min-width: 0; position: relative; }
.stage-grid { flex: 1; display: grid; gap: 8px; padding: 16px; align-content: center; justify-content: center; overflow: auto; }
.tile { position: relative; background: var(--elev); border-radius: 10px; overflow: hidden; display: grid; place-items: center; aspect-ratio: 16/9; min-width: 0; cursor: pointer; }
.tile::after { content: ""; position: absolute; inset: 0; border-radius: 10px; box-shadow: inset 0 0 0 0 var(--speak); transition: box-shadow .1s; pointer-events: none; }
.tile.speaking::after { box-shadow: inset 0 0 0 3px var(--speak); }
.tile video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.tile video.contain { object-fit: contain; }
.tile video.mirror { transform: scaleX(-1); }
.tile .av { z-index: 1; }
.tile .label { position: absolute; left: 8px; bottom: 8px; z-index: 2; display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,.6); padding: 4px 8px; border-radius: 6px; font-size: 14px; font-weight: 600; max-width: calc(100% - 16px); }
.tile .label svg { color: var(--danger); }
.tile .tile-tools { position: absolute; right: 8px; top: 8px; z-index: 2; display: none; gap: 4px; }
.tile:hover .tile-tools { display: flex; }
.tile-tools button, .tile-tools label { height: 28px; min-width: 28px; padding: 0 6px; border-radius: 6px; background: rgba(0,0,0,.7); display: flex; align-items: center; gap: 6px; color: var(--text); font-size: 12px; }
.tile-tools input[type=range] { width: 80px; accent-color: #fff; }
.stage.focus .stage-grid { grid-template-columns: 1fr !important; }
.stage-bar { flex: none; display: flex; justify-content: center; align-items: center; gap: 12px; padding: 16px; }
.stage-bar .cbtn { width: 56px; height: 56px; border-radius: 50%; background: #2a2a2e; display: grid; place-items: center; color: var(--text); transition: background .12s, transform .05s; position: relative; }
.stage-bar .cbtn:hover { background: #38383d; }
.stage-bar .cbtn:active { transform: scale(.96); }
.stage-bar .cbtn.on { background: var(--white); color: var(--ink); }
.stage-bar .cbtn.off { background: #3b1d1f; color: #fca5a5; }
.stage-bar .cbtn.hang { background: var(--danger); color: #fff; width: 64px; }
.stage-bar .cbtn.hang:hover { background: #dc2626; }
.stage-bar .cbtn svg { width: 24px; height: 24px; }
.stage-head { position: absolute; left: 0; right: 0; top: 0; padding: 14px 18px; display: flex; align-items: center; gap: 8px; font-weight: 700; z-index: 3; background: linear-gradient(#000c, transparent); pointer-events: none; }
.stage-join { flex: 1; display: grid; place-items: center; text-align: center; padding: 20px; }
.stage-join h2 { font-size: 26px; margin: 6px 0 4px; }
.stage-join p { color: var(--muted); margin: 0 0 20px; }
.stage-join .who { display: flex; justify-content: center; gap: -8px; margin-bottom: 14px; }
.stage-join .who .av { margin-left: -8px; border: 3px solid #000; }

/* ---------- popouts / menus / modals ---------- */
#layer > * { z-index: 100; }
.backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.78); display: grid; place-items: center; padding: 16px; z-index: 90; animation: fade .12s; }
.modal { width: min(460px, 100%); max-height: 90vh; overflow: hidden; display: flex; flex-direction: column; background: var(--chat); border-radius: 10px; border: 1px solid var(--line); box-shadow: 0 20px 60px rgba(0,0,0,.6); animation: pop .15s ease; }
.modal.wide { width: min(560px, 100%); }
.modal-body { padding: 24px; overflow-y: auto; }
.modal h2 { margin: 0 0 6px; font-size: 22px; text-align: center; }
.modal .lead { color: var(--muted); margin: 0 0 20px; text-align: center; }
.modal.left h2, .modal.left .lead { text-align: left; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 24px; background: var(--side); }
.modal .x { position: absolute; }
.choice { width: 100%; display: flex; align-items: center; gap: 14px; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: 8px; margin-bottom: 8px; text-align: left; transition: background .1s; }
.choice:hover { background: var(--hover); }
.choice.sel { border-color: #a1a1aa; background: var(--hover); }
.choice .ci { width: 40px; height: 40px; border-radius: 50%; background: var(--elev-2); display: grid; place-items: center; }
.choice small { display: block; color: var(--muted); }
.radio { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--muted); margin-left: auto; flex: none; }
.choice.sel .radio { border: 6px solid var(--white); }

.menu { position: fixed; z-index: 120; min-width: 188px; max-width: 280px; background: var(--float); border: 1px solid var(--line); border-radius: 8px; padding: 6px; box-shadow: 0 10px 30px rgba(0,0,0,.6); animation: pop .1s ease; }
.menu .mi { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 7px 8px; border-radius: 4px; font-size: 14px; color: var(--text-2); font-weight: 500; }
.menu .mi:hover { background: var(--white); color: var(--ink); }
.menu .mi.red { color: var(--danger); }
.menu .mi.red:hover { background: var(--danger); color: #fff; }
.menu .mi svg { margin-left: auto; }
.menu .msep { height: 1px; background: var(--line); margin: 4px 6px; }
.menu .mi .sub { display: block; font-size: 12px; color: var(--muted); }
.menu .mi:hover .sub { color: #3f3f46; }

.popout { position: fixed; z-index: 110; width: 320px; background: var(--float); border-radius: 10px; overflow: hidden; box-shadow: 0 12px 40px rgba(0,0,0,.7); border: 1px solid var(--line); animation: pop .12s ease; }
.pop-banner { height: 64px; }
.pop-av { position: absolute; left: 14px; top: 20px; border-radius: 50%; border: 6px solid var(--float); background: var(--float); cursor: pointer; }
.pop-av .av .st { border-color: var(--float); }
.pop-badges { display: flex; justify-content: flex-end; padding: 10px 12px 0; min-height: 44px; }
.pop-body { margin: 8px 12px 12px; background: var(--side); border-radius: 8px; padding: 12px; }
.pop-body h3 { margin: 0; font-size: 20px; line-height: 1.2; }
.pop-body .handle { color: var(--text-2); font-size: 14px; }
.pop-body .cstat { margin-top: 6px; font-size: 14px; color: var(--text-2); }
.pop-body hr { border: 0; height: 1px; background: var(--line); margin: 12px 0; }
.pop-body h4 { margin: 0 0 6px; font-size: 12px; text-transform: uppercase; color: var(--text-2); }
.pop-body p { margin: 0 0 12px; font-size: 14px; white-space: pre-wrap; }
.pop-body .wallet-sum { display: flex; gap: 8px; }
.pop-body .wallet-sum div { flex: 1; background: var(--rail); border-radius: 6px; padding: 8px; text-align: center; }
.pop-body .wallet-sum b { display: block; font-size: 18px; }
.pop-body .wallet-sum small { color: var(--muted); font-size: 11px; text-transform: uppercase; font-weight: 700; }
.pop-msg { width: 100%; margin-top: 12px; }
.pop-msg input { width: 100%; }

.emoji-pick { position: fixed; z-index: 120; width: 344px; background: var(--float); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 40px rgba(0,0,0,.7); overflow: hidden; animation: pop .1s; }
.emoji-pick .search { padding: 10px; border-bottom: 1px solid var(--line); }
.emoji-pick .search input { width: 100%; padding: 7px 10px; border-radius: 6px; background: var(--rail); border: 1px solid var(--line); outline: none; }
.emoji-grid { display: grid; grid-template-columns: repeat(8, 1fr); padding: 8px; gap: 2px; max-height: 280px; overflow-y: auto; }
.emoji-grid button { font-size: 24px; height: 38px; border-radius: 6px; }
.emoji-grid button:hover { background: var(--elev-2); }
.emoji-cat { grid-column: 1 / -1; font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; padding: 8px 4px 2px; }

.tooltip { position: fixed; z-index: 200; background: var(--float); color: var(--text); padding: 6px 10px; border-radius: 6px; font-size: 14px; font-weight: 600; pointer-events: none; box-shadow: 0 6px 20px rgba(0,0,0,.5); max-width: 260px; border: 1px solid var(--line); }
.tooltip small { display: block; color: var(--muted); font-weight: 500; font-size: 12px; }
.toasts { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 300; pointer-events: none; align-items: center; }
.toast { background: var(--elev-2); border: 1px solid var(--line-2); padding: 10px 16px; border-radius: 8px; font-size: 14px; font-weight: 500; box-shadow: 0 10px 30px rgba(0,0,0,.5); animation: pop .15s; }
.toast.err { border-color: #7f1d1d; background: #2a1215; }
.lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.88); z-index: 150; display: grid; place-items: center; animation: fade .12s; }
.lightbox img { max-width: 92vw; max-height: 86vh; border-radius: 6px; }
.lightbox a { position: absolute; bottom: 24px; color: var(--text-2); font-size: 14px; }

/* ---------- full-screen settings ---------- */
.settings { position: fixed; inset: 0; z-index: 95; display: flex; background: var(--chat); animation: zoomin .18s ease; }
.set-nav { flex: 1 0 218px; background: var(--side); display: flex; justify-content: flex-end; overflow-y: auto; }
.set-nav .inner { width: 218px; padding: 60px 6px 60px 20px; }
.set-nav h5 { margin: 0; padding: 6px 10px; font-size: 12px; text-transform: uppercase; color: var(--muted); }
.set-nav button { display: block; width: 100%; text-align: left; padding: 6px 10px; border-radius: 4px; color: var(--muted); font-weight: 500; margin-bottom: 2px; }
.set-nav button:hover { background: var(--hover); color: var(--text-2); }
.set-nav button.active { background: var(--active); color: var(--text); }
.set-nav button.red { color: var(--danger); }
.set-nav .sep { height: 1px; background: var(--line); margin: 8px 10px; }
.set-main { flex: 1 1 800px; overflow-y: auto; display: flex; }
.set-main .inner { width: 100%; max-width: 740px; padding: 60px 40px 80px; }
.set-main h2 { margin: 0 0 20px; font-size: 20px; }
.set-main h3 { margin: 28px 0 10px; font-size: 12px; text-transform: uppercase; color: var(--text-2); }
.set-close { flex: none; padding: 60px 20px 0 0; }
.set-close button { width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--muted); display: grid; place-items: center; color: var(--muted); }
.set-close button:hover { background: var(--hover); color: var(--text); border-color: var(--text); }
.set-close small { display: block; text-align: center; color: var(--muted); font-size: 12px; font-weight: 700; margin-top: 6px; }
.card { background: var(--side); border-radius: 8px; padding: 16px; }
.card + .card { margin-top: 12px; }
.acct-card { background: var(--side); border-radius: 8px; overflow: hidden; }
.acct-card .bn { height: 100px; }
.acct-card .top { display: flex; align-items: flex-end; gap: 16px; padding: 0 16px; margin-top: -40px; }
.acct-card .top .av { border: 7px solid var(--side); background: var(--side); }
.acct-card .top h3 { margin: 0 0 12px; font-size: 20px; text-transform: none; color: var(--text); }
.acct-card .rows { margin: 16px; background: var(--chat); border-radius: 8px; padding: 16px; }
.kv { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; }
.kv + .kv { border-top: 1px solid var(--line); }
.kv .k { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--text-2); }
.kv .v { font-size: 15px; }
.list-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: var(--side); border-radius: 8px; margin-bottom: 6px; }
.list-row .meta { flex: 1; min-width: 0; }
.list-row .meta small { display: block; color: var(--muted); font-size: 13px; }
.list-row select, .list-row .input { width: auto; padding: 6px 8px; font-size: 14px; }
.preview-pane { display: flex; gap: 24px; align-items: flex-start; flex-wrap: wrap; }
.preview-pane .form { flex: 1 1 300px; }
.meter { height: 8px; border-radius: 4px; background: var(--rail); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; background: var(--online); transition: width .08s; }

/* wallet */
.wallet-hero { display: flex; gap: 12px; margin-bottom: 8px; }
.wallet-hero .stat { flex: 1; background: var(--side); border-radius: 10px; padding: 16px; }
.wallet-hero .stat b { font-size: 28px; display: block; }
.wallet-hero .stat small { color: var(--muted); font-weight: 700; text-transform: uppercase; font-size: 12px; }
.wallet-hero .bar { height: 6px; border-radius: 3px; background: var(--rail); margin-top: 10px; overflow: hidden; }
.wallet-hero .bar i { display: block; height: 100%; background: var(--white); }
.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.badge-card { background: var(--side); border: 1px solid var(--line); border-radius: 10px; padding: 14px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; position: relative; transition: border-color .12s, transform .12s; }
.badge-card:hover { border-color: var(--line-2); transform: translateY(-1px); }
.badge-card.locked { opacity: .35; }
.badge-card b { font-size: 14px; }
.badge-card small { color: var(--muted); font-size: 12px; line-height: 1.3; }
.badge-card .btns { display: flex; gap: 6px; }
.alias-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--side); border-radius: 8px; margin-bottom: 6px; font-family: var(--mono); }
.alias-row .tag { font-family: var(--font); font-size: 11px; font-weight: 800; background: var(--white); color: var(--ink); border-radius: 4px; padding: 1px 6px; }
.ledger-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.ledger-row small { color: var(--muted); margin-left: auto; white-space: nowrap; }
.icon-pick { display: grid; grid-template-columns: repeat(auto-fill, 40px); gap: 6px; }
.icon-pick button { width: 40px; height: 40px; border-radius: 8px; background: var(--rail); border: 1px solid var(--line); display: grid; place-items: center; color: var(--text-2); }
.icon-pick button svg { width: 20px; height: 20px; }
.icon-pick button.sel { border-color: var(--white); color: var(--white); }

@keyframes pop { from { transform: scale(.96); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
@keyframes zoomin { from { transform: scale(1.04); opacity: 0; } }

::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-thumb { background: #29292d; border-radius: 8px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: #36363b; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- responsive ---------- */
.mobile-only { display: none !important; }
.scrim { display: none; }
@media (max-width: 1180px) {
  .members { position: fixed; right: 0; top: 48px; bottom: 0; z-index: 40; transform: translateX(100%); transition: transform .2s; }
  .app.show-members .members { box-shadow: -16px 0 40px rgba(0,0,0,.35); }
  .app.show-members .members { transform: none; }
  .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 35; opacity: 0; pointer-events: none; transition: opacity .2s; }
  .app.show-members .scrim { opacity: 1; pointer-events: auto; top: 48px; }
}
@media (max-width: 760px) {
  .mobile-only { display: grid !important; }
  .rail, .sidebar { position: fixed; top: 0; bottom: 0; z-index: 40; transition: transform .2s ease; }
  .rail { left: 0; padding-top: max(12px, env(safe-area-inset-top)); }
  .sidebar { left: 72px; width: min(300px, calc(100vw - 112px)); border-radius: 0; padding-bottom: env(safe-area-inset-bottom); }
  .app:not(.show-nav) .rail { transform: translateX(-100%); }
  .app:not(.show-nav) .sidebar { transform: translateX(calc(-100% - 72px)); }
  .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 35; opacity: 0; pointer-events: none; transition: opacity .2s; }
  .app.show-nav .scrim, .app.show-members .scrim { opacity: 1; pointer-events: auto; }
  .main-head { padding-top: env(safe-area-inset-top); height: calc(48px + env(safe-area-inset-top)); padding-left: 6px; }
  .main-head .topic { display: none; }
  .composer { padding: 0 8px env(safe-area-inset-bottom); }
  .msg { padding-right: 12px; padding-left: 64px; }
  .msg > .av { left: 12px; }
  .msg-tools { display: none !important; }
  .settings { flex-direction: column; }
  .set-nav { flex: none; max-height: 34vh; justify-content: flex-start; }
  .set-nav .inner { width: 100%; padding: 16px; padding-top: max(16px, env(safe-area-inset-top)); }
  .set-main .inner { padding: 20px 16px 60px; }
  .set-close { position: fixed; right: 12px; top: max(12px, env(safe-area-inset-top)); padding: 0; z-index: 2; }
  .set-close small { display: none; }
  .popout { left: 8px !important; right: 8px; width: auto; top: auto !important; bottom: 8px; }
  .stage-bar .cbtn { width: 48px; height: 48px; }
}

/* ===================== v3 additions ===================== */
.also { color: var(--muted); font-size: 13px; margin-top: 2px; }
.turbo-tag { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; background: linear-gradient(135deg, #a855f7, #ec4899); color: #fff; vertical-align: 2px; }
.turbo-tag svg { fill: currentColor; stroke: none; }
.pop-banner.tall { height: 110px; }
.cemoji { width: 22px; height: 22px; object-fit: contain; vertical-align: -6px; margin: 0 1px; }
.cemoji.big { width: 48px; height: 48px; }
.gif-embed { position: relative; display: block; margin-top: 4px; width: fit-content; }
.gif-embed img { max-width: min(360px, 100%); max-height: 300px; border-radius: 8px; display: block; }
.att-img { position: relative; display: inline-block; }
.fav { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 8px; background: rgba(0,0,0,.7); color: #fff; display: none; place-items: center; }
.fav svg { width: 16px; height: 16px; }
.gif-embed:hover .fav, .att-img:hover .fav { display: grid; }
.fav.on { display: grid; color: #facc15; }
.fav.on svg, .fav:hover svg { fill: currentColor; }
.att-video { max-width: min(480px, 100%); max-height: 360px; border-radius: 8px; background: #000; display: block; }
.att-file { display: flex; align-items: center; gap: 12px; width: min(420px, 100%); padding: 12px; background: var(--side); border: 1px solid var(--line); border-radius: 8px; }
.att-file a.ellip { display: block; color: #d4d4d8; font-weight: 600; }
.att-file small { color: var(--muted); font-size: 12px; }
.att-file svg.i.lg { color: var(--muted); }
.sticker img { width: 160px; height: 160px; object-fit: contain; display: block; margin-top: 4px; }
.upload-tile .ft { height: 100px; display: grid; place-items: center; color: var(--muted); background: var(--rail); border-radius: 4px; }
.upload-tile .prog { height: 3px; background: var(--rail); border-radius: 2px; margin-top: 6px; overflow: hidden; }
.upload-tile .prog i { display: block; height: 100%; background: var(--online); transition: width .2s; }
.emoji-grid button img { width: 28px; height: 28px; object-fit: contain; }
.emoji-grid button.locked, .sticker-grid button.locked { opacity: .35; filter: grayscale(1); }
.pick-body { max-height: 380px; overflow-y: auto; }
.gif-grid { columns: 2; column-gap: 6px; padding: 8px; }
.gif-grid button { display: block; width: 100%; margin-bottom: 6px; border-radius: 6px; overflow: hidden; position: relative; break-inside: avoid; }
.gif-grid img { width: 100%; display: block; }
.gif-grid .unfav { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 6px; background: rgba(0,0,0,.75); display: none; place-items: center; }
.gif-grid button:hover .unfav { display: grid; }
.sticker-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 6px 10px 10px; }
.sticker-grid button { border-radius: 8px; padding: 4px; }
.sticker-grid button:hover { background: var(--elev-2); }
.sticker-grid img { width: 100%; aspect-ratio: 1; object-fit: contain; display: block; }
.sticker-grid.big { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); padding: 14px 0; }
.st-card { background: var(--side); border-radius: 10px; padding: 10px; display: flex; flex-direction: column; align-items: center; gap: 6px; position: relative; }
.st-card img { width: 100px; height: 100px; object-fit: contain; }
.st-card .icon-btn { position: absolute; top: 4px; right: 4px; }
.em-prev { width: 32px; height: 32px; object-fit: contain; }
.slot-bar { height: 6px; background: var(--side); border-radius: 3px; overflow: hidden; margin-bottom: 14px; }
.slot-bar i { display: block; height: 100%; background: var(--white); }
.add-friend { display: flex; align-items: center; gap: 8px; background: var(--rail); border: 1px solid var(--line); border-radius: 8px; padding: 6px 6px 6px 14px; }
.add-friend:focus-within { border-color: #52525b; }
.add-friend input { flex: 1; background: none; border: 0; outline: none; font-size: 15px; padding: 6px 0; }
.fr-tab.add { background: var(--online); color: #fff; margin-left: 6px; }
.fr-tab.add.active { background: none; color: var(--online); }
.fr-tab .count { background: var(--dnd); color: #fff; font-size: 11px; font-weight: 800; padding: 0 5px; border-radius: 8px; margin-left: 4px; }
.fr-row .act.ok:hover { color: var(--online); }
.fr-row .act.no:hover { color: var(--danger); }
.alias-row .tag.dim, .tag.dim { background: var(--elev-2); color: var(--muted); }
.tag { font-size: 10px; font-weight: 800; background: var(--white); color: var(--ink); border-radius: 4px; padding: 1px 6px; letter-spacing: .03em; font-family: var(--font); }
.tag.red { background: var(--danger); color: #fff; }
.alias-row.is-main { border: 1px solid var(--line-2); }
.alias-row .btn { flex: none; }
.alias-row[draggable=true] { cursor: grab; }
.sub-h { font-size: 12px; color: var(--muted); font-weight: 700; margin: 14px 0 6px; text-transform: uppercase; }
.id-preview { display: flex; gap: 12px; align-items: center; }
.id-preview .handle { color: var(--text-2); font-size: 14px; }
.chip { display: inline-flex; align-items: center; gap: 2px; background: var(--rail); border-radius: 4px; padding: 0 5px; font-family: var(--mono); font-size: 12px; margin: 2px 2px 0 0; }
.chip.dim { opacity: .55; }
.chip button { color: var(--danger); font-weight: 800; }
.list-row.banned { opacity: .5; }
.list-row .btn { flex: none; }
.vanity-in { display: flex; align-items: center; background: var(--rail); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.vanity-in span { padding: 0 2px 0 12px; color: var(--muted); font-family: var(--mono); font-size: 13px; white-space: nowrap; }
.vanity-in input { flex: 1; min-width: 60px; background: none; border: 0; outline: none; padding: 10px 12px 10px 0; font-family: var(--mono); }
.vanity-in.locked { opacity: .45; }

/* turbo & boost (original look) */
.turbo-btn { background: linear-gradient(135deg, #a855f7, #ec4899); color: #fff; }
.turbo-btn:hover { background: linear-gradient(135deg, #9333ea, #db2777); }
.boost-btn { background: #db2777; color: #fff; }
.boost-btn:hover { background: #be185d; }
.turbo-nav { display: flex !important; align-items: center; gap: 6px; }
.turbo-nav svg { fill: #c084fc; stroke: none; }
.turbo-orb { width: 64px; height: 64px; border-radius: 20px; background: linear-gradient(135deg, #a855f7, #ec4899); display: grid; place-items: center; color: #fff; margin: 0 auto 12px; box-shadow: 0 10px 40px rgba(168,85,247,.35); flex: none; }
.turbo-orb svg { fill: #fff; stroke: none; width: 32px; height: 32px; }
.turbo-hero { display: flex; align-items: center; gap: 18px; padding: 28px; border-radius: 16px; background: radial-gradient(120% 140% at 0% 0%, rgba(168,85,247,.35), transparent 60%), radial-gradient(120% 140% at 100% 100%, rgba(236,72,153,.25), transparent 60%), #0c0c0e; border: 1px solid #2e1f3d; margin-bottom: 18px; flex-wrap: wrap; }
.turbo-hero .turbo-orb { margin: 0; }
.turbo-hero h1 { margin: 0; font-size: 34px; letter-spacing: -.02em; }
.turbo-hero p { margin: 2px 0 0; color: var(--text-2); }
.turbo-status { margin-left: auto; background: rgba(255,255,255,.08); padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.plan { position: relative; background: var(--side); border: 1px solid var(--line-2); border-radius: 14px; padding: 20px; }
.plan.current { border-color: #a855f7; box-shadow: 0 0 0 1px #a855f7 inset; }
.plan small { color: var(--muted); font-weight: 700; text-transform: uppercase; font-size: 12px; }
.plan .price { margin: 6px 0; display: flex; align-items: baseline; gap: 8px; }
.plan .price s { color: var(--muted); font-size: 18px; }
.plan .price b { font-size: 32px; }
.plan .price span { color: var(--muted); }
.plan .save { position: absolute; top: 14px; right: 14px; font-size: 11px; font-weight: 800; background: #ec4899; color: #fff; padding: 2px 8px; border-radius: 999px; }
.perk-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.perk-list > div { display: flex; gap: 12px; align-items: flex-start; background: var(--side); border-radius: 10px; padding: 12px; }
.perk-list svg { color: #c084fc; margin-top: 2px; }
.perk-list b { display: block; }
.perk-list small { color: var(--muted); }
.boost-head { text-align: center; margin: -24px -24px 18px; padding: 26px 24px 18px; }
.boost-gem { width: 56px; height: 56px; margin: 0 auto 8px; border-radius: 16px; background: #db2777; color: #fff; display: grid; place-items: center; }
.boost-track { position: relative; height: 8px; background: var(--rail); border-radius: 4px; margin: 26px 12px 40px; }
.boost-track .fill { height: 100%; border-radius: 4px; background: linear-gradient(90deg, #db2777, #f472b6); }
.boost-track .mark { position: absolute; top: -6px; width: 20px; height: 20px; margin-left: -10px; border-radius: 50%; background: var(--elev-2); border: 3px solid var(--chat); }
.boost-track .mark.on { background: #f472b6; }
.boost-track .mark span { position: absolute; top: 22px; left: 50%; transform: translateX(-50%); font-size: 11px; font-weight: 700; white-space: nowrap; color: var(--text-2); }
.boost-track .mark small { position: absolute; top: -20px; left: 50%; transform: translateX(-50%); font-size: 11px; color: var(--muted); }
.perk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; }
.perk-grid div { background: var(--rail); border-radius: 8px; padding: 10px; text-align: center; }
.perk-grid b { display: block; font-size: 18px; }
.perk-grid small { color: var(--muted); font-size: 11px; }
.level-card { background: var(--side); border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; margin-bottom: 8px; opacity: .6; }
.level-card.on { opacity: 1; border-color: #f472b6; }
.level-card .lh { display: flex; align-items: center; gap: 10px; }
.level-card .lh small { color: var(--muted); }
.level-card .lh .tag { margin-left: auto; background: #f472b6; color: #fff; }
.level-card ul { margin: 6px 0 0; padding-left: 18px; color: var(--text-2); font-size: 14px; }

/* ===================== v4: roles, permissions, prefs ===================== */
.msg .content { font-size: var(--chat-font, 15px); }
.id-ic { margin-left: auto; font-size: 9px; font-weight: 800; border: 1.5px solid currentColor; border-radius: 4px; padding: 0 3px; line-height: 14px; }
.role-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 12px; }
.role-chip { display: inline-flex; align-items: center; gap: 5px; background: var(--elev); border-radius: 4px; padding: 2px 7px; font-size: 12px; font-weight: 500; color: var(--text-2); }
.role-chip[data-rmrole] { cursor: pointer; }
.role-chip[data-rmrole]:hover .dot::after { content: "×"; color: #fff; font-size: 10px; display: grid; place-items: center; height: 100%; line-height: 1; }
.role-chip.add { width: 22px; justify-content: center; padding: 2px; color: var(--muted); }
.role-chip.add:hover { color: var(--text); background: var(--elev-2); }
.dot { width: 12px; height: 12px; border-radius: 50%; display: inline-block; flex: none; }
.role-check { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 6px; cursor: pointer; text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 15px; color: var(--text); margin: 0; }
.role-check:hover { background: var(--hover); }
.role-check.dis { opacity: .4; cursor: not-allowed; }
.role-check input { width: 18px; height: 18px; accent-color: #fff; }
.roles-wrap { display: flex; gap: 16px; align-items: flex-start; }
.roles-col { width: 230px; flex: none; }
.role-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 6px; cursor: pointer; color: var(--text-2); font-weight: 500; }
.role-row:hover { background: var(--hover); color: var(--text); }
.role-row.sel { background: var(--active); color: var(--text); }
.role-row.locked { opacity: .55; }
.role-row small { color: var(--muted); display: flex; align-items: center; gap: 2px; }
.role-edit { flex: 1; min-width: 0; }
.role-edit.empty { text-align: center; color: var(--muted); padding: 60px 20px; }
.role-edit.empty svg { width: 48px; height: 48px; opacity: .4; }
.sub-tabs { display: flex; gap: 18px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.sub-tabs button { padding: 8px 0; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.sub-tabs button:hover { color: var(--text-2); }
.sub-tabs button.active { color: var(--text); border-color: var(--white); }
.perm-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.perm-row b { display: block; font-weight: 600; }
.perm-row small { color: var(--muted); font-size: 13px; }
.switch:disabled { opacity: .35; cursor: not-allowed; }
.tri { display: flex; border: 1px solid var(--line-2); border-radius: 6px; overflow: hidden; flex: none; }
.tri button { width: 32px; height: 28px; color: var(--muted); font-weight: 800; }
.tri button + button { border-left: 1px solid var(--line-2); }
.tri button.on { background: var(--elev-2); color: var(--text); }
.tri button.on.deny { background: #7f1d1d; color: #fff; }
.tri button.on.allow { background: #166534; color: #fff; }
.color-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.color-row .sw { width: 28px; height: 28px; border-radius: 6px; border: 2px solid transparent; }
.color-row .sw.sel { border-color: #fff; }
.color-row .sw.none { background: repeating-linear-gradient(45deg, #3f3f46 0 4px, #27272a 4px 8px); }
.mem-table { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.mt-head, .mt-row { display: grid; grid-template-columns: minmax(0, 2fr) 110px minmax(0, 2fr) 36px; gap: 12px; align-items: center; padding: 8px 12px; }
.mt-head { background: var(--side); font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.mt-row { border-top: 1px solid var(--line); }
.mt-row:hover { background: var(--hover); }
.mt-row .role-chips { margin: 0; }
.theme-pick { display: flex; gap: 12px; }
.theme-sw { display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 600; color: var(--text-2); }
.theme-sw span { width: 64px; height: 64px; border-radius: 50%; border: 3px solid var(--line-2); }
.theme-sw.sel span { border-color: #fff; }
.range { width: 100%; accent-color: #fff; }
.composer-box.blocked-note { align-items: center; color: var(--muted); padding: 0 16px; gap: 8px; cursor: not-allowed; }
.msg.sys { display: flex; align-items: center; gap: 10px; color: var(--muted); margin-top: 10px; padding-top: 4px; padding-bottom: 4px; }
.msg.sys .sys-ic { position: absolute; left: 30px; color: var(--online); }
.msg.sys .name { color: var(--text); font-weight: 600; }
.msg.blocked-msg { color: var(--muted); font-size: 13px; padding-top: 6px; padding-bottom: 6px; margin-top: 8px; }
.msg.blocked-msg button { color: #d4d4d8; }
.msg.blocked-msg button:hover { text-decoration: underline; }
.msg.pinned::after { content: ""; position: absolute; right: 8px; top: 6px; width: 6px; height: 6px; border-radius: 50%; background: #eab308; }
.content .mention.role { font-weight: 600; }
.pin-item { display: flex; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); cursor: pointer; }
.pin-item:hover { background: var(--hover); }
.pin-item small { color: var(--muted); font-size: 12px; }
.pin-item .content { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.set-nav .ver { color: var(--faint); font-size: 12px; padding: 10px; }
.flags .srv { color: var(--danger); }
body.underline-links a { text-decoration: underline; text-decoration-color: currentColor; }
body.spoilers-shown .content .spoiler { color: inherit; background: rgba(255,255,255,.08); }
body.reduce-motion *, body.reduce-motion *::before, body.reduce-motion *::after { animation: none !important; transition: none !important; }
body.compact .msg { padding-left: 16px; }
body.compact .msg.head { margin-top: 4px; }
body.compact .msg > .av { display: none; }
body.compact .msg .hdr { display: inline-flex; flex-direction: row-reverse; gap: 6px; margin-right: 6px; }
body.compact .msg .content { display: inline; }
body.compact .msg .side-ts { display: none !important; }
body.compact .msg .reply-ref::before { display: none; }
body.theme-graphite { --rail: #121214; --side: #1a1a1d; --chat: #202023; --elev: #27272b; --elev-2: #2e2e33; --input: #2a2a2e; --line: #2c2c31; --line-2: #36363c; }
body.theme-graphite .user-panel { background: #161618; }
@media (max-width: 760px) { .roles-wrap { flex-direction: column; } .roles-col { width: 100%; } .mt-head, .mt-row { grid-template-columns: minmax(0, 1fr) 36px; } .mt-head span:nth-child(2), .mt-head span:nth-child(3), .mt-row > span:nth-child(2), .mt-row > span:nth-child(3) { display: none; } }

/* ===================== v5: AutoMod, access, explore ===================== */
.am-card { background: var(--side); border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; overflow: hidden; }
.am-head { display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.am-head b { display: block; }
.am-head small { color: var(--muted); font-size: 13px; }
.am-ic { width: 40px; height: 40px; border-radius: 10px; background: var(--elev-2); display: grid; place-items: center; flex: none; color: var(--text-2); }
.am-ic.sm { width: 24px; height: 24px; border-radius: 6px; }
.am-rule { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--chat); }
.am-rule b { display: block; font-size: 14px; }
.am-rule small { color: var(--muted); font-size: 12px; }
.exempt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.exempt-grid .role-check { padding: 6px 8px; font-size: 14px; }
.msg.am-alert { background: rgba(250, 204, 21, .05); border-left: 3px solid #eab308; margin: 10px 16px 0 16px; padding: 10px 14px !important; border-radius: 6px; }
.am-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 800; color: #facc15; text-transform: uppercase; margin-bottom: 4px; }
.am-quote { margin: 6px 0; padding: 6px 10px; background: var(--rail); border-radius: 6px; color: var(--text-2); font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.app-card .qa { margin-top: 10px; }
.app-card .qa small { color: var(--muted); font-size: 12px; font-weight: 700; text-transform: uppercase; }
.rules-list { margin: 0 0 14px; padding-left: 22px; color: var(--text); text-align: left; }
.rules-list li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.rules-gate { padding: 0 8px 0 14px; }
.modal.explore { width: min(900px, 100%); }
.explore-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.ex-card { background: var(--side); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; position: relative; transition: transform .12s, border-color .12s; }
.ex-card:hover { transform: translateY(-2px); border-color: var(--line-2); }
.ex-banner { height: 80px; }
.ex-icon { position: absolute; top: 52px; left: 14px; width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; font-weight: 800; color: var(--ink); border: 4px solid var(--side); overflow: hidden; }
.ex-icon img { width: 100%; height: 100%; object-fit: cover; }
.ex-body { padding: 32px 14px 14px; }
.ex-body p { color: var(--muted); font-size: 13px; margin: 4px 0 10px; min-height: 34px; }
.ex-body small { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12px; margin-bottom: 10px; }
.badge-vis .list-row.dim { opacity: .55; }

/* ===================== v6: flat badge art ===================== */
.badge-ic { width: 22px; height: 22px; border-radius: 0; background: none !important; border: 0 !important; display: inline-grid; place-items: center; flex: none; }
.badge-ic svg, .badge-ic .zb-svg { width: 100%; height: 100%; display: block; }
.badge-ic.md { width: 30px; height: 30px; }
.badge-ic.lg { width: 46px; height: 46px; }
.inline-badges .badge-ic { width: 18px; height: 18px; }
.badge-row .badge-ic { width: 22px; height: 22px; }
.pop-badges { padding: 10px 12px 0 112px; min-height: 44px; }
.pop-badges .badge-row { flex-wrap: wrap; justify-content: flex-end; max-width: 100%; }
.badge-card .badge-ic.lg { width: 52px; height: 52px; }
.srv-mark { display: inline-grid; flex: none; vertical-align: -3px; }
.srv-mark svg { width: 100%; height: 100%; }
.side-head .srv-mark { margin-right: -2px; }
.verify-btn { background: #1d4ed8; color: #fff; } .verify-btn:hover { background: #1e40af; }
.partner-btn { background: #2563eb22; color: #93c5fd; border: 1px solid #2563eb66; }
/* ===================== v8: Server Program tickets ===================== */
.program-hero { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.pg-card { flex: 1 1 220px; display: flex; gap: 12px; align-items: center; background: var(--side); border: 1px solid var(--line); border-radius: 10px; padding: 14px; }
.pg-card b { display: block; } .pg-card small { color: var(--muted); }
.ticket { display: flex; gap: 12px; align-items: flex-start; background: var(--side); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin-bottom: 8px; }
.ticket.big { display: block; }
.ticket small { color: var(--muted); font-size: 12px; display: block; margin-top: 4px; }
.tk-st { font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 2px 7px; border-radius: 4px; background: var(--elev-2); color: var(--muted); flex: none; }
.tk-st.open { background: #1d4ed8; color: #fff; } .tk-st.ok { background: #166534; color: #fff; } .tk-st.no { background: #7f1d1d; color: #fff; }
.tk-req { margin-top: 10px; padding: 10px 12px; background: var(--rail); border-radius: 8px; }
.tk-note { margin-top: 8px; color: var(--text-2); font-style: italic; white-space: pre-wrap; }
.tk-resp { margin-top: 8px; font-size: 14px; color: var(--text-2); }
.tk-img { max-width: 180px; max-height: 120px; border-radius: 8px; margin-top: 10px; display: block; }
.lock-note { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; color: var(--text-2); }
.count-pill { background: var(--dnd); color: #fff; font-size: 11px; font-weight: 800; padding: 0 6px; border-radius: 8px; margin-left: 4px; }
/* ===================== v9: program applications ===================== */
.apply-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.apply-grid.one { grid-template-columns: 1fr; margin-bottom: 8px; }
.apply-card { background: var(--side); border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; }
.ac-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 12px; }
.ac-head b { display: block; font-size: 16px; } .ac-head small { color: var(--muted); font-size: 13px; }
.req-bar { height: 6px; border-radius: 3px; background: var(--rail); overflow: hidden; }
.req-bar i { display: block; height: 100%; background: var(--online); }
.req { display: flex; align-items: center; gap: 8px; padding: 6px 0; font-size: 14px; border-bottom: 1px solid var(--line); }
.req small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.req .ri { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.req.ok .ri { background: #166534; color: #fff; } .req.no .ri { background: #3f1d1d; color: #fca5a5; }
.req.no { color: var(--text-2); }
.apply-card .btn.wide { margin-top: 14px; }
.ac-state { margin-top: 14px; font-size: 14px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: var(--chat); }
.qa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.qa-grid > div { background: var(--rail); border-radius: 8px; padding: 10px 12px; }
.qa-grid small { color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; display: block; margin-bottom: 4px; }
.req-details { margin-top: 10px; }
.req-details summary { cursor: pointer; color: var(--text-2); font-size: 14px; font-weight: 600; padding: 4px 0; }
@media (max-width: 760px) { .apply-grid, .qa-grid { grid-template-columns: 1fr; } }

/* ---------------- v10: reports, support chats, staff Reports dept, application review */
.pop-more { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 50%; background: rgba(0,0,0,.55); color: #e4e4e7; display: grid; place-items: center; }
.pop-more:hover { background: rgba(0,0,0,.8); color: #fff; }
.rp-kind { padding: 16px; }
.rp-kind .rk-ic { width: 40px; height: 40px; border-radius: 50%; background: var(--elev-2); display: grid; place-items: center; flex: none; }
.rp-reasons { display: grid; grid-template-columns: 1fr 1fr; gap: 0 8px; margin-bottom: 8px; }
.rp-reasons .choice { padding: 9px 12px; }
.rp-reasons .choice b { font-size: 13px; font-weight: 600; }
.rp-areas { display: grid; grid-template-columns: 1fr 1fr; gap: 0 8px; margin-bottom: 8px; }
.rp-target { display: flex; align-items: center; gap: 12px; padding: 10px 12px; margin-bottom: 14px; }
.rp-target small { display: block; color: var(--muted); }
.rp-target.sm { margin: 10px 0 0; }
.rp-done { width: 56px; height: 56px; margin: 4px auto 10px; border-radius: 50%; background: #166534; color: #fff; display: grid; place-items: center; }
.case-no { font-family: ui-monospace, Menlo, monospace; font-size: .92em; color: #a1a1aa; font-weight: 700; }
.mono { font-family: ui-monospace, Menlo, monospace; }
.nav-soon { display: flex !important; align-items: center; justify-content: space-between; opacity: .45; cursor: not-allowed !important; }
.nav-soon:hover { background: none !important; color: var(--muted) !important; }
.soon-pill { font-size: 9px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; padding: 1px 6px; border-radius: 4px; border: 1px solid var(--line-2); }
.tk-st.act { background: #a16207; color: #fff; display: inline-flex; align-items: center; gap: 4px; text-transform: none; letter-spacing: 0; font-size: 11px; }
.rp-ic { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.rp-ic.user { background: #7f1d1d; color: #fecaca; } .rp-ic.bug { background: #365314; color: #d9f99d; }
.rp-card.locked { opacity: .8; }
.rp-desc { white-space: pre-wrap; }
.rp-acts { margin-top: 12px; gap: 8px; align-items: center; }
.rp-acts .btn { flex: none; }
.lock-note { margin-top: 12px; padding: 10px 12px; border-radius: 6px; background: rgba(161,98,7,.15); border: 1px solid rgba(161,98,7,.45); color: #fde68a; display: flex; align-items: center; gap: 8px; font-size: 13px; }
.lnk { cursor: pointer; } .lnk:hover { text-decoration: underline; }
.tr-line { padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.tr-line .ts { color: var(--faint); font-size: 11px; }
.grp-av { background: #27272a; color: #e4e4e7; display: inline-grid; place-items: center; border-radius: 50%; flex: none; }
.grp-av.s80 .i { width: 36px; height: 36px; }
.dm-sub { display: block; font-size: 11px; color: var(--faint); font-weight: 500; }
.grp-members { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.grp-members .role-chip { cursor: pointer; gap: 6px; }
.staff-tag { font-size: 9px; font-weight: 800; background: #3f3f46; color: #fff; padding: 1px 4px; border-radius: 3px; }
.apps-head { display: flex; align-items: center; gap: 8px; margin-top: 24px; }
.apps-head h3 { margin: 0 !important; }
.app-card.clickable { cursor: pointer; transition: border-color .1s, background .1s; }
.app-card.clickable:hover { border-color: #71717a; background: var(--hover); }
.app-stack { display: flex; align-items: center; gap: 4px; margin-top: 6px; }
.modal.app-rev { width: 520px; }
.modal.app-rev .modal-body { padding-top: 0; }
.app-rev-head { height: 72px; margin: 0 -24px; border-radius: 0; border-radius: 8px 8px 0 0; }
.app-rev-id { display: flex; align-items: flex-end; gap: 14px; margin-top: -34px; }
.app-rev-id .av { border: 5px solid var(--chat); border-radius: 50%; }
.app-rev-id h2 { margin: 0 !important; }
.app-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 14px; }
.app-facts > div { background: var(--elev-2); border-radius: 6px; padding: 8px 10px; }
.app-facts small { display: block; font-size: 10px; font-weight: 800; text-transform: uppercase; color: var(--muted); letter-spacing: .03em; }
.app-facts b { font-size: 13px; }
.qa.big { background: var(--code); border-radius: 6px; padding: 10px 12px; margin-bottom: 8px; }
.qa.big small { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.field-label .req, label .req { display: inline; border: 0; padding: 0; margin: 0; color: var(--danger, #ef4444); }
.app-stack { justify-content: center; }

/* ---------------- v11: home links, message requests, interviews, Members page */
.side-pill { margin-left: auto; font-size: 10px; font-weight: 800; letter-spacing: .04em; padding: 2px 8px; border-radius: 10px; background: var(--white, #fff); color: #000; }
.side-count { margin-left: auto; }
.side-sep { height: 1px; background: var(--line); margin: 8px 8px 6px; }
.mem-link .mem-n { font-size: 12px; font-weight: 700; background: var(--elev-2); color: var(--text-2); padding: 1px 8px; border-radius: 10px; margin-left: 6px; }
.mem-link .grow { flex: 1; }
.req-intro { display: flex; gap: 14px; align-items: flex-start; margin: 4px 10px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--elev-1); }
.req-intro > .i { width: 26px; height: 26px; flex: none; color: var(--text-2); }
.req-intro b { display: block; margin-bottom: 2px; }
.req-intro small { color: var(--muted); line-height: 1.45; }
.req-row .meta small { display: block; }
.req-row .req-when { color: var(--faint); font-size: 11px; }
.req-bar-box { display: flex; align-items: center; gap: 10px; padding: 12px 16px !important; }
.req-bar-box small { display: block; color: var(--muted); font-size: 12px; }
.grp-av.int { background: #a16207; color: #fff; }
.int-tag { color: #fbbf24; font-weight: 700; }
.modal.members-panel { width: min(640px, 100%); position: relative; }
.modal.members-panel .modal-body { padding: 20px 24px 24px; max-height: 80vh; }
.mp-head { display: flex; align-items: center; }
.mp-head h2 { margin: 0 !important; }
.mp-x { position: absolute; top: 16px; right: 16px; color: var(--muted); }
.mp-x:hover { color: var(--text); }
.mp-tabs { margin: 12px 0 14px; }
.mp-n { font-size: 11px; font-weight: 700; background: var(--elev-2); padding: 1px 7px; border-radius: 9px; margin-left: 4px; }
.mem-search { margin-bottom: 10px; }
.mem-row, .mem-app { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.mem-row:hover, .mem-app:hover { background: var(--hover); }
.mem-row small, .mem-app small { display: block; color: var(--muted); font-size: 12px; }
.mem-app { align-items: flex-start; border: 1px solid var(--line); margin-bottom: 8px; padding: 12px; }
.mem-app-a { font-size: 13px; color: var(--text-2); margin-top: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mem-app-btns { display: flex; gap: 6px; flex: none; }
.role-chips.sm .role-chip { font-size: 11px; padding: 1px 6px; }
.owner-crown { color: #f5b83d; }
.side-link .side-count { margin-left: auto; }
.mem-link .side-count + .mem-n { margin-left: 6px; }
#mainHead .tools .btn.sm { margin-left: 6px; }
#mainHead .tools { padding-right: 6px; }

/* ---------------- v12: Blue App-style polish */
.ping.vc { min-width: 0; width: 16px; padding: 0; background: var(--online); }
.ping.vc svg.i { width: 10px; height: 10px; stroke-width: 2.6; }
body.theme-black { --rail: #000000; --side: #0f0f11; --chat: #151517; --elev: #1c1c1f; --elev-2: #232327; --elev-1: #121214; --input: #1e1e21; --float: #0d0d0f; --panel: #0a0a0c; --code: #0b0b0d; --hover: rgba(255,255,255,.055); --active: rgba(255,255,255,.10); --line: #242428; --line-2: #2e2e33; --text: #ececee; --text-2: #b9b9c0; --muted: #8a8a93; --faint: #5d5d66; }
body.theme-black .rail-btn, body.theme-black .rail-btn.home { background: var(--elev); }
.side-link, .dm-row { font-size: 16px; font-weight: 500; }
.chan { font-size: 16px; font-weight: 500; }
.cat { font-size: 12px; letter-spacing: .02em; }
.user-panel { height: 52px; margin: 0; }
.msg .name { font-weight: 600; }
.icon-btn { color: var(--muted); }
.icon-btn:hover { color: var(--text); }
@media (max-width: 760px) { .members { top: calc(48px + env(safe-area-inset-top)); } .app.show-members .scrim { top: calc(48px + env(safe-area-inset-top)); } }

/* ---------------- v13: round voice badge, expression picker, Blue App type scale */
.ping.vc { width: 16px; height: 16px; min-width: 16px; padding: 0; border-radius: 50%; display: grid; place-items: center; right: 9px; bottom: -3px; }
.ping.vc.live { background: var(--online); }
.ping.vc svg.i { width: 10px; height: 10px; stroke-width: 2.6; }

.emoji-pick.xp { display: flex; flex-direction: column; background: var(--side); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.4); }
.xp-tabs { display: flex; gap: 6px; padding: 12px 12px 4px; flex: none; }
.xp-tabs button { padding: 2px 8px; border-radius: 4px; font-size: 14px; font-weight: 500; color: var(--muted); line-height: 20px; }
.xp-tabs button:hover { background: var(--hover); color: var(--text-2); }
.xp-tabs button.active { background: var(--active); color: var(--text); }
.emoji-pick.xp > .search { flex: none; }
.emoji-pick.xp .pick-body { flex: 1; min-height: 0; overflow-y: auto; }
.xp-search { position: relative; margin: 8px 12px; flex: none; }
.xp-search input { width: 100%; height: 34px; border-radius: 4px; border: 0; background: var(--rail); padding: 0 34px 0 10px; font-size: 15px; outline: none; }
.xp-search input::placeholder { color: var(--muted); }
.xp-sic { position: absolute; right: 8px; top: 8px; color: var(--muted); }
.xp-body { flex: 1; min-height: 0; overflow-y: auto; padding: 0 8px 8px 12px; scrollbar-width: thin; scrollbar-color: var(--rail) transparent; }
.xp-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.xp-tile { position: relative; height: 110px; border-radius: 4px; overflow: hidden; background: var(--elev); display: grid; place-items: center; }
.xp-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.xp-shade { position: absolute; inset: 0; background: rgba(0,0,0,.5); transition: background .15s; }
.xp-tile:hover .xp-shade { background: rgba(0,0,0,.3); }
.xp-tile:hover { outline: 2px solid var(--white); outline-offset: -2px; }
.xp-label { position: relative; display: flex; align-items: center; gap: 6px; font-size: 16px; font-weight: 700; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.6); text-transform: capitalize; padding: 0 8px; text-align: center; }
.xp-head { display: flex; align-items: center; gap: 8px; height: 36px; margin-bottom: 4px; position: sticky; top: 0; background: var(--side); z-index: 2; }
.xp-head b { font-size: 16px; font-weight: 600; text-transform: capitalize; }
.xp-back { width: 28px; height: 28px; border-radius: 4px; display: grid; place-items: center; color: var(--muted); }
.xp-back:hover { background: var(--hover); color: var(--text); }
.xp-grid { display: flex; gap: 8px; align-items: flex-start; }
.xp-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.xp-gif { position: relative; width: 100%; border-radius: 4px; overflow: hidden; background: var(--elev); display: block; }
.xp-gif img { width: 100%; height: 100%; object-fit: cover; display: block; }
.xp-gif:hover { outline: 2px solid var(--white); outline-offset: -2px; }
.xp-star { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 4px; background: rgba(0,0,0,.6); color: #fff; display: none; place-items: center; }
.xp-gif:hover .xp-star, .xp-star.on { display: grid; }
.xp-star.on { color: #f0b232; }
.xp-star.on svg { fill: currentColor; }
.xp-star:hover { transform: scale(1.08); }
.xp-note { margin: 12px 2px 4px; font-size: 12px; color: var(--muted); line-height: 1.4; }
.xp-note code { font-size: 11px; }
.xp-loading { display: grid; place-items: center; padding: 60px 0; }
.xp-spin { width: 24px; height: 24px; border-radius: 50%; border: 3px solid var(--line-2); border-top-color: var(--text); animation: xpspin .8s linear infinite; }
@keyframes xpspin { to { transform: rotate(360deg); } }

/* Blue App type scale */
body { font-size: 16px; line-height: 1.375; }
.side-head { font-size: 16px; font-weight: 600; line-height: 20px; }
.cat { font-size: 12px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.chan { font-size: 16px; font-weight: 500; line-height: 20px; }
.side-link, .dm-row { font-size: 16px; font-weight: 500; }
.main-head .title { font-size: 16px; font-weight: 600; line-height: 20px; }
.main-head .topic { font-size: 14px; font-weight: 500; }
.msg .name { font-size: 16px; font-weight: 500; line-height: 22px; }
.msg .ts { font-size: 12px; font-weight: 500; margin-left: .25rem; line-height: 22px; }
.msg .content { font-weight: 400; line-height: 1.375; }
.composer-box textarea { font-size: 16px; }
.mem-cat { font-size: 12px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.mem .meta b { font-size: 16px; font-weight: 500; }
.me-btn .meta b { font-size: 14px; font-weight: 600; }
.me-btn .meta small { font-size: 12px; font-weight: 400; }
.btn { font-size: 14px; font-weight: 500; }
.btn.sm { font-size: 14px; }
.tooltip { font-size: 14px; font-weight: 600; }
.set-nav h5 { font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.set-nav button { font-size: 16px; font-weight: 500; line-height: 20px; }
.set-main h2 { font-size: 20px; font-weight: 600; line-height: 24px; }
.set-main h3 { font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.modal h2 { font-size: 24px; font-weight: 700; }
.field-label { font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.input, .select, .textarea { font-size: 16px; }
.fr-row .meta b { font-size: 16px; font-weight: 600; }
.fr-row .meta small { font-size: 14px; }
.menu .mi { font-size: 14px; font-weight: 500; }
.rail-btn { overflow: visible; }
.rail-btn img { border-radius: inherit; }
.side-link { white-space: nowrap; }
.side-link > :not(svg):not(.side-pill):not(.side-count):not(.count-pill) { overflow: hidden; text-overflow: ellipsis; }
.emoji-pick.xp .emoji-grid { max-height: none; flex: 1; min-height: 0; align-content: start; }
.emoji-pick.xp > :last-child { flex: 1; min-height: 0; overflow-y: auto; }

/* ---------------- v14: your profile popout + accounts */
.popout.me-pop { width: 300px; background: #232326; border: 1px solid #38383e; border-radius: 8px; overflow: visible; padding-bottom: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.45); }
.mp-banner { height: 105px; border-radius: 8px 8px 0 0; }
.mp-top { position: relative; height: 46px; }
.mp-av { position: absolute; left: 16px; top: -50px; border-radius: 50%; padding: 0; border: 6px solid #232326; background: #232326; }
.mp-av .av { display: block; }
.mp-av:hover::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: rgba(0,0,0,.25); }
.mp-st { position: absolute; right: -2px; bottom: -2px; width: 24px; height: 24px; border-radius: 50%; border: 5px solid #232326; background: var(--offline); }
.mp-st.online { background: var(--online); } .mp-st.idle { background: var(--idle); } .mp-st.dnd { background: var(--dnd); }
.mp-bubble { position: absolute; left: 106px; top: -30px; right: 12px; min-height: 40px; max-height: 64px; display: flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 20px; background: #2e2e33; border: 1px solid #3a3a40; color: var(--text-2); font-size: 14px; text-align: left; box-shadow: 0 4px 12px rgba(0,0,0,.25); }
.mp-bubble:hover { background: #35353b; }
.mp-bubble .mp-btext { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 18px; }
.mp-bubble .mp-btext.ph { font-style: italic; color: var(--muted); white-space: nowrap; display: block; text-overflow: ellipsis; }
.mp-bubble.set { color: var(--text); }
.mp-dot1, .mp-dot2 { position: absolute; border-radius: 50%; background: #2e2e33; border: 1px solid #3a3a40; }
.mp-dot1 { width: 16px; height: 16px; left: -10px; top: -6px; }
.mp-dot2 { width: 8px; height: 8px; left: -20px; top: -14px; }
.mp-id { padding: 0 16px 12px; }
.mp-id h3 { margin: 0; font-size: 20px; font-weight: 700; line-height: 24px; color: var(--text); }
.mp-handle { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 4px; font-size: 14px; color: var(--text); }
.mp-badge { display: inline-grid; place-items: center; height: 24px; min-width: 28px; padding: 0 4px; border-radius: 6px; background: #2e2e33; }
.mp-badge .badge-ic { width: 18px; height: 18px; background: none; border: 0; }
.mp-badge.more { font-size: 11px; font-weight: 700; color: var(--muted); }
.mp-card { margin: 0 8px 8px; background: #2b2b30; border-radius: 8px; }
.mp-live { padding: 10px 12px 10px; }
.mp-live-head { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; font-size: 14px; }
.mp-live-head b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live-pill { background: var(--dnd); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .02em; padding: 0 6px; border-radius: 10px; line-height: 18px; }
.mp-more { color: var(--muted); width: 24px; height: 24px; display: grid; place-items: center; border-radius: 4px; }
.mp-more:hover { color: var(--text); background: var(--hover); }
.mp-preview { border-radius: 6px; overflow: hidden; background: #000; aspect-ratio: 16 / 9; }
.mp-preview video { width: 100%; height: 100%; object-fit: contain; display: block; }
.mp-vc { display: flex; align-items: center; gap: 6px; margin-top: 10px; padding-top: 10px; border-top: 1px solid #3a3a40; color: var(--text-2); font-size: 14px; cursor: pointer; }
.mp-vc:hover .grow { color: var(--text); text-decoration: underline; }
.mp-sicon { width: 24px; height: 24px; border-radius: 8px; flex: none; display: grid; place-items: center; font-size: 9px; font-weight: 700; color: #fff; }
.mp-stack { display: flex; align-items: center; }
.mp-stack .av { margin-left: -6px; border: 2px solid #2b2b30; box-sizing: content-box; }
.mp-plus { margin-left: -6px; height: 24px; min-width: 24px; padding: 0 5px; border-radius: 12px; background: #1e1e21; border: 2px solid #2b2b30; font-size: 11px; font-weight: 700; display: grid; place-items: center; color: var(--text); }
.mp-menu { padding: 4px; }
.mp-row { display: flex; align-items: center; gap: 10px; width: 100%; height: 40px; padding: 0 10px; border-radius: 6px; font-size: 14px; font-weight: 500; color: var(--text-2); text-align: left; position: relative; }
.mp-row + .mp-row::before { content: ''; position: absolute; left: 10px; right: 10px; top: 0; height: 1px; background: #38383e; }
.mp-row:hover { background: #35353b; color: var(--text); }
.mp-row:hover::before, .mp-row:hover + .mp-row::before { opacity: 0; }
.mp-row svg.i { color: var(--muted); }
.mp-row .grow { flex: 1; }
.mp-sdot { width: 12px; height: 12px; border-radius: 50%; background: var(--offline); margin: 0 2px; }
.mp-sdot.online { background: var(--online); } .mp-sdot.idle { background: var(--idle); } .mp-sdot.dnd { background: var(--dnd); }
.acc-list { display: flex; flex-direction: column; gap: 4px; margin: 8px 0 12px; }
.acc-row { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 8px; background: var(--side); }
.acc-row small { display: block; color: var(--muted); font-size: 14px; }
.acc-row b { font-size: 16px; font-weight: 600; }
.acc-active { font-size: 12px; font-weight: 700; color: var(--online); padding: 0 6px; }
.acc-add { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 10px; border-radius: 8px; border: 1px dashed var(--line-2); color: var(--text-2); font-weight: 500; }
.acc-add:hover { background: var(--hover); color: var(--text); }
.acc-add span { flex: 1; text-align: left; }
.acc-add small { color: var(--muted); }
.acc-add.off { opacity: .5; cursor: not-allowed; }
.aa-err { color: var(--danger); font-size: 14px; min-height: 18px; }
.acc-cur { position: relative; display: inline-flex; }
.acc-cur svg.i { position: absolute; right: -4px; bottom: -4px; width: 14px; height: 14px; background: var(--online); color: #fff; border-radius: 50%; padding: 2px; stroke-width: 3; }

/* Blue App row metrics */
.ch { height: 32px; padding: 6px 8px; border-radius: 4px; font-size: 16px; font-weight: 500; line-height: 20px; color: #949499; }
.ch.unread, .ch.active { color: var(--text); }
.ch svg.i { width: 20px; height: 20px; }
.dm-row { height: 42px; border-radius: 4px; font-weight: 500; }
.side-link { height: 42px; border-radius: 4px; }
.mem { height: 42px; padding: 0 8px; border-radius: 4px; }
.mem-cat { padding: 24px 8px 0; height: 40px; }
.msg.head { margin-top: 17px; }
.msg .av.s40, .msg > .av { width: 40px; height: 40px; }
.main-head { height: 48px; }
.composer-box { border-radius: 8px; min-height: 44px; }
.btn { border-radius: 4px; }
.modal { border-radius: 8px; }
.menu { border-radius: 4px; padding: 6px 8px; }
.menu .mi { border-radius: 2px; min-height: 32px; }
.tooltip { border-radius: 5px; }

/* ---------------- v15: Blue App behaviour + polish */
/* default avatars */
.av.def { color: #fff; display: inline-grid; place-items: center; }
.av.def > svg { width: 58%; height: 58%; }
.av.def.s16 > svg { stroke-width: 3.4; }
/* server icons: gray until hovered/selected, then the server color */
.rail-btn:not(.home):not(.has-img) { background: var(--chat); color: var(--text); transition: border-radius .15s, background .15s, color .15s; }
.rail-item:hover .rail-btn:not(.home):not(.has-img), .rail-item.active .rail-btn:not(.home):not(.has-img) { background: var(--sc); color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,.25); }
.rail-item:hover .rail-btn.home, .rail-item.active .rail-btn.home { background: var(--white); color: var(--ink); }
.rail-item .rail-btn.add, .rail-item .rail-btn.explore { color: var(--online); }
.rail-item:hover .rail-btn.add, .rail-item:hover .rail-btn.explore { background: var(--online); color: #fff; }
/* member list */
.mem .meta { min-width: 0; }
.mem .meta b { display: flex; align-items: center; gap: 4px; white-space: nowrap; overflow: hidden; }
.mem .meta .mn { overflow: hidden; text-overflow: ellipsis; }
.mem .meta small { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 16px; }
.mem .meta small.act { color: var(--text-2); }
.mem .meta small.live-act { color: #c4b5fd; }
.mem.off { opacity: .35; }
.mem.off:hover { opacity: 1; }
.live-pill.sm { font-size: 10px; line-height: 14px; padding: 0 4px; border-radius: 4px; }
/* NEW divider + bars */
.new-divider { position: relative; height: 0; border-top: 1px solid var(--dnd); margin: 8px 14px 8px 16px; }
.new-divider span { position: absolute; right: -4px; top: -9px; background: var(--dnd); color: #fff; font-size: 10px; font-weight: 700; line-height: 16px; padding: 0 4px 0 6px; border-radius: 0 3px 3px 0; letter-spacing: .02em; }
.new-divider span::before { content: ''; position: absolute; left: -8px; top: 0; border: 8px solid transparent; border-right-color: var(--dnd); border-left-width: 0; }
.chat { position: relative; }
.new-bar { position: absolute; top: 0; left: 16px; right: 16px; z-index: 5; display: flex; align-items: center; height: 24px; background: #5b5bd6; background: #4f46e5; border-radius: 0 0 8px 8px; color: #fff; font-size: 14px; font-weight: 500; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.new-bar { background: #3b3b42; border: 1px solid #4a4a52; border-top: 0; }
.new-bar button { color: #fff; padding: 0 12px; height: 100%; font-weight: 600; display: flex; align-items: center; gap: 4px; }
.new-bar .grow { text-align: left; font-weight: 500; }
.new-bar button:hover { text-decoration: underline; }
.present-bar { display: flex; align-items: center; margin: 0 16px -6px; padding: 4px 4px 10px 12px; border-radius: 8px 8px 0 0; background: #3a3a40; font-size: 14px; color: var(--text-2); }
.present-bar button { display: flex; align-items: center; gap: 4px; font-weight: 600; color: var(--text); padding: 2px 8px; border-radius: 4px; font-size: 14px; }
.present-bar button:hover { background: var(--hover); }
/* header search */
.hd-search { position: relative; margin-left: 8px; }
.hd-search input { width: 144px; height: 24px; border: 0; border-radius: 4px; background: var(--rail); color: var(--text); font-size: 14px; padding: 0 24px 0 8px; transition: width .2s; outline: none; }
.hd-search input:focus, .hd-search.open input { width: 240px; }
.hd-search input::placeholder { color: var(--muted); }
.hs-ic { position: absolute; right: 6px; top: 5px; color: var(--muted); cursor: pointer; display: grid; }
.menu.search-hints { padding: 8px; }
.sh-title { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--text-2); padding: 4px 8px 8px; letter-spacing: .02em; }
.menu.search-hints .mi { flex-direction: row-reverse; justify-content: flex-end; gap: 10px; }
.menu.search-hints .mi .sub { display: inline; margin-left: 8px; }
.search-panel { position: fixed; right: 0; top: 48px; bottom: 0; width: 418px; max-width: 100vw; z-index: 45; background: var(--side); border-left: 1px solid var(--line); display: flex; flex-direction: column; box-shadow: -8px 0 24px rgba(0,0,0,.2); }
.sp-head { display: flex; align-items: center; height: 56px; padding: 0 12px 0 16px; background: var(--rail); flex: none; }
.sp-head b { font-size: 16px; font-weight: 600; }
.sp-body { flex: 1; overflow-y: auto; padding: 8px 12px 16px; }
.sp-ch { font-size: 14px; font-weight: 600; color: var(--text); padding: 14px 4px 6px; }
.sp-msg { position: relative; display: flex; gap: 12px; padding: 10px 12px; margin-bottom: 8px; border-radius: 8px; background: var(--chat); border: 1px solid transparent; cursor: pointer; }
.sp-msg:hover { border-color: var(--line-2); }
.sp-msg .hdr { display: flex; align-items: baseline; gap: 8px; }
.sp-msg .name { font-weight: 500; font-size: 16px; }
.sp-msg .ts { font-size: 12px; color: var(--muted); }
.sp-msg .content { font-size: 16px; line-height: 1.375; word-break: break-word; }
.sp-jumpbtn { position: absolute; top: 8px; right: 8px; display: none; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 4px; background: var(--elev-2); color: var(--text); }
.sp-msg:hover .sp-jumpbtn { display: block; }
.sp-pager { display: flex; align-items: center; justify-content: space-between; padding: 8px 4px; font-size: 14px; color: var(--muted); }
/* Active Now */
.friends.with-now:not(.hidden) { display: grid !important; grid-template-columns: minmax(0, 1fr) 360px; }
.active-now { border-left: 1px solid var(--line); padding: 16px; overflow-y: auto; }
.active-now h2 { font-size: 20px; font-weight: 800; margin: 8px 0 16px; }
.now-card { background: var(--side); border: 1px solid transparent; border-radius: 8px; padding: 16px; margin-bottom: 8px; cursor: pointer; }
.now-card:hover { background: #2f2f34; border-color: var(--line-2); }
.now-top { display: flex; align-items: center; gap: 12px; }
.now-top b { display: block; font-size: 16px; font-weight: 600; }
.now-top small { display: block; font-size: 14px; color: var(--muted); }
.now-sicon { width: 24px; height: 24px; border-radius: 8px; background: var(--chat); font-size: 9px; font-weight: 700; display: grid; place-items: center; object-fit: cover; }
.now-vc { display: flex; align-items: center; gap: 6px; margin-top: 12px; padding: 8px 10px; border-radius: 8px; background: var(--chat); font-size: 14px; color: var(--text-2); }
.now-empty { text-align: center; padding: 16px 8px; }
.now-empty b { display: block; font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.now-empty p { margin: 0; font-size: 14px; color: var(--muted); }
@media (max-width: 1180px) { .friends.with-now { grid-template-columns: 1fr; } .active-now { display: none; } }
/* quick switcher */
.modal.qs-modal { width: 570px; }
.modal.qs-modal .input { height: 70px; font-size: 24px; padding: 0 16px; border-radius: 4px; background: var(--rail); }
.qs-tip { font-size: 12px; color: var(--muted); padding: 8px 4px 0; }
.qs-tip b { color: var(--online); font-weight: 700; }
#qsr .mem { border-radius: 4px; }
#qsr .mem.qs-sel { background: var(--active); }
#qsr .mem.qs-sel b { color: var(--white); }
/* messages: Blue App hover + mention styles */
.msg:hover { background: rgba(0,0,0,.06); }
.msg.mentioned { background: rgba(240,178,50,.1); }
.msg.mentioned::before { background: #f0b232; }
.divider span { font-size: 12px; font-weight: 600; }

/* ---------------- v16: Twemoji */
img.emoji { width: 1.375em; height: 1.375em; vertical-align: -.3em; margin: 0 .05em; object-fit: contain; display: inline-block; }
.big-emoji img.emoji { width: 48px; height: 48px; vertical-align: -12px; }
.emoji-grid img.emoji, [data-e] > img.emoji { width: 32px; height: 32px; vertical-align: middle; margin: 0; }
.react img.emoji, .reaction img.emoji { width: 16px; height: 16px; vertical-align: -3px; }
.side-head img.emoji, .ch img.emoji, .mem img.emoji, .dm-row img.emoji { width: 18px; height: 18px; vertical-align: -3px; }

/* ---------------- v17: server tags, role styles, community, announcements, boosts page */
.srv-tag { display: inline-flex; align-items: center; gap: 3px; height: 18px; padding: 0 5px 0 4px; margin-left: 6px; border-radius: 4px; background: color-mix(in srgb, var(--tc) 18%, #1e1e21); border: 1px solid color-mix(in srgb, var(--tc) 35%, transparent); color: var(--tc); vertical-align: 2px; cursor: pointer; line-height: 1; }
.srv-tag b { font-size: 11px; font-weight: 800; letter-spacing: .04em; color: #f2f2f3; }
.srv-tag .tg { flex: none; }
.srv-tag.md { height: 22px; padding: 0 7px 0 5px; }
.srv-tag.md b { font-size: 12px; }
.srv-tag.lg { height: 44px; padding: 0 16px 0 12px; gap: 8px; border-radius: 10px; border-width: 2px; }
.srv-tag.lg b { font-size: 26px; letter-spacing: .03em; }
.srv-tag:hover { filter: brightness(1.15); }
.mem .srv-tag { margin-left: 4px; }
/* enhanced role styles */
.role-grad { background: linear-gradient(90deg, var(--g1), var(--g2), var(--g1)); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent !important; }
.role-holo { background: linear-gradient(90deg, #a5f3fc, #c4b5fd, #f9a8d4, #fde68a, #a5f3fc); background-size: 300% 100%; -webkit-background-clip: text; background-clip: text; color: transparent !important; animation: holo 6s linear infinite; }
.msg:hover .role-grad, .mem:hover .role-grad { animation: holo 3s linear infinite; }
@keyframes holo { to { background-position: -300% 0; } }
@media (prefers-reduced-motion: reduce) { .role-holo, .role-grad { animation: none !important; } }
.rs-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rs-card { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px; border-radius: 8px; background: var(--side); border: 2px solid transparent; text-align: left; }
.rs-card.sel { border-color: var(--white); }
.rs-card.locked { opacity: .6; }
.rs-card b { font-size: 14px; display: flex; gap: 4px; align-items: center; }
.rs-card small { font-size: 12px; color: var(--muted); }
.rs-prev { font-size: 16px; font-weight: 600; margin-bottom: 6px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.boost-chip { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; font-size: 11px; color: #f472b6; text-transform: none; letter-spacing: 0; }
/* tag settings */
.tag-preview { background: var(--chat); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; margin: 10px 0 18px; }
.msg-mock { display: flex; gap: 14px; }
.msg-mock b { font-weight: 500; }
.msg-mock .ts { font-size: 12px; color: var(--muted); margin-left: 4px; }
.tag-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.tg-b { width: 44px; height: 44px; border-radius: 8px; background: var(--side); color: var(--tc); display: grid; place-items: center; border: 2px solid transparent; }
.tg-b:hover { background: var(--elev); }
.tg-b.sel { border-color: var(--white); background: var(--elev); }
.tg-b.locked { opacity: .35; cursor: not-allowed; }
.lock-card { display: flex; gap: 14px; align-items: flex-start; padding: 18px; }
.lock-card > svg { width: 28px; height: 28px; color: #f472b6; flex: none; }
.tag-opts { display: flex; flex-direction: column; gap: 6px; }
.tag-opt { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; background: var(--side); border: 1px solid transparent; text-align: left; }
.tag-opt.sel { border-color: var(--line-2); background: var(--elev); }
.tag-opt .srv-tag { margin: 0; }
.tag-opt .radio { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--muted); }
.tag-opt.sel .radio { border: 5px solid var(--white); }
/* community */
.cm-hero { display: flex; gap: 16px; align-items: flex-start; padding: 20px; border-radius: 8px; background: linear-gradient(135deg, #2b2b30, #232326); border: 1px solid var(--line); margin-bottom: 18px; }
.cm-hero > svg { width: 40px; height: 40px; flex: none; color: var(--online); }
.cm-hero h2 { margin: 0 0 6px !important; }
.cm-hero p { margin: 0; color: var(--text-2); font-size: 14px; }
.cm-check { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 8px; background: var(--side); margin-bottom: 8px; }
.cm-check .ck { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--dnd); color: #fff; flex: none; }
.cm-check.ok .ck { background: var(--online); }
.cm-check small { display: block; color: var(--muted); font-size: 13px; }
.danger-card { display: flex; align-items: center; gap: 12px; border: 1px solid rgba(239,68,68,.4); padding: 14px 16px; }
/* announcements */
.follow-btn { display: inline-flex; align-items: center; gap: 4px; height: 24px; margin-right: 8px; background: var(--online) !important; color: #fff !important; }
.pub-tag { font-size: 10px; font-weight: 700; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line-2); border-radius: 3px; padding: 0 4px; margin-left: 6px; letter-spacing: .03em; }
.bot-tag { font-size: 10px; font-weight: 700; background: #5b5bd6; background: #3f3f46; color: #fff; padding: 1px 4px; border-radius: 3px; margin: 0 4px; vertical-align: 1px; }
.xp-av { display: grid; place-items: center; font-weight: 700; color: #fff; font-size: 14px; }
.xp-ch { color: var(--muted); font-weight: 500; }
/* boosts page */
.modal.boost-page { width: min(760px, 100%); }
.modal.boost-page .modal-body { max-height: 78vh; overflow-y: auto; padding-top: 0; }
.bpg-title { position: sticky; top: 0; z-index: 3; text-align: center; font-size: 18px; font-weight: 700; padding: 18px 0 12px; margin: 0 -24px; background: var(--chat); border-bottom: 1px solid var(--line); }
.bpg-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 0 -24px 22px; border-bottom: 1px solid var(--line); }
.bpg-stats > div { text-align: center; padding: 18px 0; border-right: 1px solid var(--line); }
.bpg-stats > div:last-child { border: 0; }
.bpg-stats b { display: inline-flex; align-items: center; gap: 6px; font-size: 24px; font-weight: 700; }
.bpg-stats b svg { color: #f472b6; width: 22px; height: 22px; }
.bpg-stats small { display: block; color: var(--muted); font-size: 15px; }
.bpg h2 { font-size: 22px !important; margin: 22px 0 4px !important; text-align: left; }
.bpg .lead { text-align: left; margin: 0 0 14px; }
.bl-row { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.bl-card { flex: 0 0 300px; scroll-snap-align: start; border: 1px solid var(--line-2); border-radius: 16px; padding: 18px 20px; background: var(--side); }
.bl-card.on { border-color: rgba(35,165,90,.55); }
.bl-track { position: relative; height: 32px; margin-bottom: 10px; }
.bl-track::before { content: ''; position: absolute; left: 0; right: -21px; top: 13px; height: 6px; border-radius: 3px; background: var(--line-2); }
.bl-card.on .bl-track::before { background: #f472b6; }
.bl-gem { position: absolute; left: 0; top: 0; width: 32px; height: 32px; border-radius: 50%; background: var(--elev-2); display: grid; place-items: center; color: var(--muted); }
.bl-card.on .bl-gem { background: #f472b6; color: #fff; }
.bl-card h3 { font-size: 20px; font-weight: 700; margin: 0 0 12px; text-transform: none; letter-spacing: 0; color: var(--text); }
.bl-card ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.bl-card li { display: flex; align-items: center; gap: 12px; font-size: 15px; }
.bl-card li svg { color: var(--text-2); flex: none; }
.bl-more { margin: 12px 0 18px; color: var(--text-2); font-size: 15px; }
.bl-foot { display: flex; align-items: center; justify-content: space-between; font-size: 15px; font-weight: 600; }
.bl-need { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); font-weight: 600; }
.bl-need svg { color: #f472b6; }
.bl-on { display: inline-flex; align-items: center; gap: 4px; color: var(--online); font-weight: 700; }
.bl-on svg { background: var(--online); color: #fff; border-radius: 50%; padding: 2px; width: 16px; height: 16px; }
.bl-left { color: var(--muted); font-weight: 500; }
.bp-card { border: 1px solid var(--line-2); border-radius: 16px; overflow: hidden; margin-bottom: 14px; background: var(--side); }
.bp-card.on { border-color: rgba(35,165,90,.55); }
.bp-art { height: 150px; display: grid; place-items: center; background: radial-gradient(circle at 50% 60%, #2f2f36, #1e1e21); }
.bp-tags { display: flex; flex-direction: column; align-items: center; gap: 10px; transform: rotate(-4deg); }
.bp-tags .srv-tag { margin: 0; }
.bp-role { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 34px; font-weight: 800; }
.bp-role span:last-child { font-size: 22px; }
.bp-body { padding: 16px 20px 18px; }
.bp-body h3 { font-size: 20px; font-weight: 700; margin: 0 0 4px; text-transform: none; letter-spacing: 0; color: var(--text); }
.bp-body p { margin: 0 0 12px; color: var(--text-2); font-size: 15px; }
.bpg-act > div { display: flex; align-items: center; gap: 12px; padding: 10px 0; font-size: 15px; }
.bpg-act svg { color: #f472b6; }
.bpg-act small { color: var(--muted); font-size: 13px; }
.btn.boost-btn { background: linear-gradient(90deg, #f472b6, #c084fc) !important; color: #fff !important; border: 0; }
.modal.boost-page .modal-foot .boost-btn { flex: 1; }

/* ---------------- v18: Blue App parity pass */
/* markdown */
.content .md-h1 { font-size: 24px; font-weight: 700; line-height: 1.375; margin: 8px 0 4px; }
.content .md-h2 { font-size: 20px; font-weight: 700; line-height: 1.375; margin: 8px 0 4px; }
.content .md-h3 { font-size: 16px; font-weight: 700; line-height: 1.375; margin: 8px 0 4px; }
.content .md-sub { font-size: 12px; color: var(--muted); line-height: 1.3; }
.content .md-ul, .content .md-ol { margin: 4px 0 4px 16px; padding-left: 16px; }
.content .md-ul li, .content .md-ol li { margin: 2px 0; }
.content blockquote, .content .md-bq { margin: 2px 0; padding: 0 12px; border-left: 4px solid #4e4e56; border-radius: 4px; display: block; white-space: pre-wrap; }
.content a.masked { color: #4fa3f7; }
.md-ts { background: rgba(255,255,255,.06); border-radius: 3px; padding: 0 2px; }
.msg-link { display: inline-flex; align-items: center; gap: 3px; padding: 0 4px; border-radius: 3px; background: rgba(88,101,242,.15); background: rgba(255,255,255,.08); color: var(--text) !important; font-weight: 500; text-decoration: none !important; }
.msg-link:hover { background: rgba(255,255,255,.16); }
.msg-link span { color: var(--muted); }
/* muted */
.ch.muted { opacity: .4; }
.ch.muted:hover, .ch.muted.active { opacity: 1; }
.rail-item.muted .rail-btn { filter: grayscale(.6) brightness(.85); }
/* forwarded */
.fwd { border-left: 4px solid #4e4e56; padding: 2px 0 4px 12px; margin: 4px 0 2px; border-radius: 2px; }
.fwd-l { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; margin-bottom: 2px; }
.fwd-src { font-size: 12px; color: var(--muted); margin-top: 4px; cursor: pointer; }
.fwd-src:hover { color: var(--text); text-decoration: underline; }
.modal.fw-modal { width: 480px; }
.fw-list { max-height: 280px; overflow-y: auto; margin: 8px 0 12px; }
.fw-row { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 6px; cursor: pointer; }
.fw-row:hover { background: var(--hover); }
.fw-row small { display: block; font-size: 12px; color: var(--muted); }
.fw-box { width: 22px; height: 22px; border-radius: 6px; border: 2px solid var(--line-2); display: grid; place-items: center; }
.fw-row.sel .fw-box { background: var(--white); border-color: var(--white); color: var(--ink); }
.fw-prev { display: flex; gap: 10px; padding: 10px 12px; background: var(--side); border-radius: 8px; margin-bottom: 10px; }
.fw-bar { width: 4px; border-radius: 2px; background: #4e4e56; }
.fw-prev small { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12px; }
.fw-txt { font-size: 14px; max-height: 60px; overflow: hidden; }
/* polls */
.poll { max-width: 440px; margin: 6px 0 2px; padding: 14px 16px; background: var(--side); border: 1px solid var(--line); border-radius: 8px; }
.pq { font-size: 17px; font-weight: 600; line-height: 1.3; }
.psub { font-size: 12px; color: var(--muted); margin: 2px 0 12px; }
.pa { position: relative; display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 12px; margin-bottom: 8px; border-radius: 8px; background: var(--chat); border: 1px solid transparent; text-align: left; overflow: hidden; }
.pa:not(.res):hover { background: var(--elev); }
.pa.sel { border-color: var(--white); }
.pfill { position: absolute; inset: 0 auto 0 0; background: rgba(255,255,255,.08); transition: width .3s; }
.pa.mine .pfill { background: rgba(35,165,90,.22); }
.pa.win .pfill { background: rgba(240,178,50,.22); }
.ptxt { position: relative; flex: 1; font-size: 15px; font-weight: 500; }
.pct { position: relative; font-size: 13px; color: var(--text-2); font-weight: 600; }
.pchk { position: relative; width: 18px; height: 18px; border-radius: 50%; background: var(--online); color: #fff; display: grid; place-items: center; }
.pbox { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--muted); display: grid; place-items: center; flex: none; }
.pbox.sq { border-radius: 5px; }
.pa.sel .pbox { background: var(--white); border-color: var(--white); color: var(--ink); }
.pfoot { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); margin-top: 4px; flex-wrap: wrap; }
.plink { color: var(--text-2); font-size: 13px; font-weight: 600; padding: 0 4px; }
.plink:hover { color: var(--text); text-decoration: underline; }
.modal.poll-modal { width: 520px; }
.pl-ans { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.pl-a { display: flex; gap: 6px; align-items: center; }
.pl-multi { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-2); padding-bottom: 8px; }
/* tag card */
.tag-card.popout { width: 290px; padding: 14px; overflow: visible; }
.tc-top { display: grid; place-items: center; padding: 12px 0 14px; background: radial-gradient(circle, #2f2f36, transparent 70%); margin: -14px -14px 12px; border-radius: 10px 10px 0 0; }
.tc-srv { display: flex; gap: 12px; align-items: center; }
.tc-icon { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; font-weight: 700; color: #fff; flex: none; }
.tc-srv b { display: flex; align-items: center; gap: 4px; font-size: 16px; }
.tc-srv small { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12px; margin-top: 2px; }
.tc-srv .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--offline); margin-left: 4px; }
.tc-srv .dot.on { background: var(--online); margin-left: 0; }
.tc-mark { width: 16px; height: 16px; border-radius: 50%; display: inline-grid; place-items: center; color: #fff; }
.tc-mark.v { background: #3ba4f0; } .tc-mark.p { background: #5b9cf6; }
.tc-desc { font-size: 13px; color: var(--text-2); margin: 10px 0 0; line-height: 1.4; }
.tc-acts { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.tc-acts .btn { flex: 1; }
.tc-priv { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--text-2); line-height: 1.4; }
.st-sw { margin-bottom: 16px; }
/* notes */
.pop-note { width: 100%; resize: none; border: 0; background: transparent; color: var(--text); font: inherit; font-size: 13px; padding: 4px; border-radius: 4px; overflow: hidden; outline: none; }
.pop-note:focus { background: var(--rail); }
/* v18 responsive fixes */
.tag-card.popout { box-sizing: border-box; max-width: calc(100vw - 16px); }
.emoji-pick.xp { max-width: calc(100vw - 16px); box-sizing: border-box; }
#mainHead .title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 1; }
#mainHead .tools { flex-shrink: 0; }
@media (max-width: 900px) {
  #mainHead .topic { display: none; }
  .hd-search input { width: 0; padding: 0; border: 0; background: transparent; }
  .hd-search { width: 28px; height: 28px; display: grid; place-items: center; }
  .hd-search .hs-ic { position: static; color: var(--muted); }
  .hd-search input:focus, .hd-search.open input { position: absolute; right: 0; top: -2px; width: min(240px, calc(100vw - 80px)); height: 28px; padding: 0 28px 0 8px; background: var(--rail); z-index: 5; }
  .hd-search input:focus + .hs-ic, .hd-search.open .hs-ic { position: absolute; right: 6px; top: 5px; z-index: 6; }
}
@media (max-width: 600px) {
  #hdPins, #hdInvite { display: none; }
  .follow-btn { width: 28px; padding: 0 !important; justify-content: center; font-size: 0 !important; margin-right: 4px; }
  .follow-btn svg { width: 14px; height: 14px; }
  .search-panel { width: 100vw; }
}
#mainHead .tools { display: flex; flex-wrap: nowrap; align-items: center; gap: 4px; }
.hd-search { display: inline-grid; flex: none; }
@media (min-width: 901px) { .hd-search { display: block; } }
@media (max-width: 900px) {
  .hd-search { position: relative; }
  .hd-search input { position: absolute; right: 0; top: 0; }
  .hd-search input:not(:focus) { width: 0; opacity: 0; pointer-events: none; }
  .hd-search.open input { width: min(240px, calc(100vw - 80px)); opacity: 1; pointer-events: auto; }
}
.fwd-poll { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text-2); margin: 2px 0; }

/* ---------------- v19: deep parity pass */
/* tag card v2 (Blue App layout) */
.tag-card.popout.tag-card2 { width: 340px; padding: 0; overflow: hidden; }
.tc-banner { height: 72px; background: linear-gradient(180deg, #3f3f46, #2b2b2f); }
.tc2-body { padding: 0 18px 18px; position: relative; }
.tc-icon2 { display: grid; place-items: center; width: 88px; height: 88px; margin-top: -48px; border-radius: 26px; border: 6px solid var(--float); font-size: 26px; font-weight: 700; color: #fff; }
.tc-name { display: flex; align-items: center; gap: 6px; font-size: 22px; font-weight: 700; margin-top: 10px; }
.tc-name .tc-mark { width: 20px; height: 20px; }
.tc-stats { display: flex; align-items: center; gap: 5px; font-size: 14px; color: var(--text); margin-top: 4px; }
.tc-stats .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--offline); margin-left: 6px; }
.tc-stats .dot.on { background: var(--online); margin-left: 0; }
.tc-est { font-size: 14px; color: var(--muted); margin-top: 2px; }
.tc-desc2 { font-size: 14px; color: var(--text-2); line-height: 1.4; margin: 12px 0 0; max-height: 120px; overflow-y: auto; }
.tc-chipline { display: flex; align-items: center; gap: 8px; margin: 12px 0; }
.tc-chipline .srv-tag { margin: 0; }
.tc-big { width: 100%; height: 44px; border-radius: 8px; background: var(--elev-2); color: #fff; font-size: 16px; font-weight: 600; }
.tc-big.green { background: #248046; }
.tc-big.green:hover { background: #1a6334; }
.tc-big:disabled { opacity: .6; cursor: default; }
/* profile editor */
.pf-tabs { margin-bottom: 18px; }
.pf-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; align-items: start; }
.pf-prev { position: sticky; top: 0; }
.pf-sep { height: 1px; background: var(--line); margin: 18px 0; }
.pf-count { text-align: right; font-size: 12px; color: var(--muted); margin-top: 4px; }
.turbo-chip { font-size: 10px; font-weight: 800; color: #fff; background: linear-gradient(90deg, #a855f7, #ec4899); padding: 1px 6px; border-radius: 4px; margin-left: 6px; letter-spacing: .03em; vertical-align: 1px; }
.th-sw { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.th-sw input { width: 64px; height: 48px; border-radius: 8px; }
.th-sw small { font-size: 12px; color: var(--muted); }
.pf-card { border-radius: 8px; overflow: hidden; background: var(--float); border: 1px solid var(--line); }
.pf-card.themed { background: linear-gradient(180deg, var(--t1), var(--t2)); padding: 4px; border: 0; }
.pf-card.themed .pf-inner { background: rgba(0,0,0,.45); border-radius: 6px; margin: 0 4px 4px; }
.pf-banner { height: 106px; }
.pf-card.themed .pf-banner { border-radius: 6px 6px 0 0; }
.pf-avwrap { position: relative; width: 92px; margin: -46px 0 0 16px; border-radius: 50%; border: 6px solid var(--float); background: var(--float); }
.pf-card.themed .pf-avwrap { border-color: var(--t1); background: var(--t1); }
.pf-avwrap .mp-st { border-color: var(--float); }
.pf-inner { padding: 8px 16px 16px; }
.pf-inner h3 { margin: 0; font-size: 20px; font-weight: 700; text-transform: none; letter-spacing: 0; color: var(--text); }
.pf-handle { font-size: 14px; color: var(--text-2); margin-top: 2px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.pf-cstat { font-size: 14px; margin-top: 8px; }
.pf-bio { font-size: 14px; margin-top: 10px; color: var(--text); line-height: 1.4; }
.pf-srv { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-top: 10px; }
.pf-example { width: 100%; margin-top: 14px; }
.unsaved { position: sticky; bottom: 16px; z-index: 6; display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 16px; border-radius: 8px; background: var(--rail); box-shadow: 0 8px 24px rgba(0,0,0,.45); font-weight: 500; }
.unsaved.shake { animation: shake .4s; background: #9b2c2c; }
@keyframes shake { 0%, 100% { transform: translateX(0); } 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.popout.themed { background: linear-gradient(180deg, var(--t1), var(--t2)); }
.popout.themed .pop-body { background: rgba(0,0,0,.4); border-radius: 6px; margin: 0 6px 6px; }
.pop-pron { color: var(--muted); }
@media (max-width: 1000px) { .pf-grid { grid-template-columns: 1fr; } .pf-prev { position: static; } }
/* notification settings */
.modal.notif-modal { width: 480px; }
.rail-item.muted .rail-btn { opacity: .55; }
/* safety */
.pause-card .kv { gap: 8px; }
.pause-card.on { border: 1px solid rgba(239,68,68,.5); background: rgba(239,68,68,.08); }
.select.sm { height: 32px; padding: 0 8px; font-size: 14px; }
/* streamer mode */
.sm-bar { position: fixed; top: 0; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; align-items: center; gap: 8px; padding: 4px 6px 4px 12px; border-radius: 0 0 8px 8px; background: #7c3aed; color: #fff; font-size: 13px; font-weight: 600; }
.sm-bar button { background: rgba(255,255,255,.2); color: #fff; border-radius: 4px; padding: 2px 8px; font-weight: 600; }
body.sm-info .acct-card .kv .v, body.sm-info #revEmail { filter: blur(6px); }
body.sm-links #invc, body.sm-links .inv-link { filter: blur(6px); }
/* member management */
.mm-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.mm-bar .input.sm { height: 32px; width: 200px; font-size: 14px; }
.mm-table { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.mm-head, .mm-row { display: grid; grid-template-columns: minmax(160px, 2fr) 1fr 1fr 1.1fr minmax(120px, 1.6fr) 36px; gap: 10px; align-items: center; padding: 8px 12px; }
.mm-head { background: var(--side); font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); letter-spacing: .02em; }
.mm-row { border-top: 1px solid var(--line); cursor: pointer; }
.mm-row:hover { background: var(--hover); }
.mm-name { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mm-name .meta { min-width: 0; }
.mm-name b { display: flex; align-items: center; gap: 4px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mm-name small { display: block; font-size: 12px; color: var(--muted); }
.mm-c { font-size: 13px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.role-add { width: 20px; height: 20px; border-radius: 4px; display: inline-grid; place-items: center; color: var(--muted); background: var(--elev); }
.to-chip { color: var(--idle); }
@media (max-width: 900px) { .mm-head span:nth-child(3), .mm-row > :nth-child(3), .mm-head span:nth-child(4), .mm-row > :nth-child(4) { display: none; } .mm-head, .mm-row { grid-template-columns: minmax(140px, 2fr) 1fr minmax(100px, 1.4fr) 36px; } }
.modal { max-width: calc(100vw - 16px); box-sizing: border-box; }
.mm-bar .select { width: auto; flex: none; } .mm-bar .input.sm { flex: 0 1 220px; }
.rail-item:hover .rail-btn:not(.home):not(.has-img), .rail-item.active .rail-btn:not(.home):not(.has-img) { color: var(--sct, #fff); text-shadow: none; }
.tc-icon2 { color: inherit; }

/* ================================================================ v20 — CEO User Management, IP blacklist, Global Admin */
.mono { font-family: var(--mono); font-size: .92em; }
.um-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.um-f { background: var(--side); border: 1px solid var(--line); color: var(--text-2); border-radius: 999px; padding: 4px 10px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.um-f i { font-style: normal; color: var(--muted); margin-left: 3px; font-weight: 500; }
.um-f:hover { color: var(--white); background: var(--hover); }
.um-f.on { background: #5865f2; border-color: #5865f2; color: #fff; }
.um-f.on i { color: rgba(255,255,255,.8); }
.um-letter { font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: .04em; padding: 14px 4px 6px; position: sticky; top: -1px; background: var(--chat); z-index: 1; }
.um-list .um-letter:first-child { padding-top: 0; }
.um-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: var(--side); border: 0; border-radius: 8px; padding: 10px 12px; margin-bottom: 4px; color: var(--text); font: inherit; cursor: pointer; }
.um-row:hover { background: var(--elev); }
.um-row .meta { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.um-row .meta b { font-weight: 600; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.um-row .un { color: var(--muted); font-weight: 400; }
.um-row small { color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.um-row small .on { color: var(--online); }
.um-row .um-al { display: flex; flex-wrap: wrap; gap: 4px; white-space: normal; }
.um-row.banned { opacity: .6; }
.um-ip { color: var(--text-2); font-size: 12.5px; flex: none; }
.um-row > .i { color: var(--faint); flex: none; }
.tag.um-wl { background: rgba(35,165,90,.18); color: #4ade80; display: inline-flex; align-items: center; gap: 3px; }
.tag.um-sus { background: rgba(240,178,50,.18); color: #f0b232; }
.tag.um-vpn { background: rgba(168,85,247,.18); color: #c084fc; }
.um-back { display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; color: var(--text-2); font: inherit; font-weight: 600; cursor: pointer; padding: 0; margin-bottom: 12px; }
.um-back .i { transform: rotate(90deg); }
.um-back:hover { color: var(--white); }
.um-hero { background: var(--float); border-radius: 8px; overflow: hidden; margin-bottom: 16px; }
.um-hero .bn { height: 72px; }
.um-hero .top { display: flex; align-items: flex-end; gap: 14px; padding: 0 16px 14px; margin-top: -30px; }
.um-hero .top .av { box-shadow: 0 0 0 6px var(--float); border-radius: 50%; flex: none; }
.um-hero .nm { min-width: 0; padding-bottom: 2px; }
.um-hero h3 { margin: 0 0 2px; font-size: 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.um-hero .sub { color: var(--muted); font-size: 14px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.um-tabs { flex-wrap: wrap; row-gap: 4px; }
.um-n { font-style: normal; background: var(--elev); color: var(--text-2); border-radius: 999px; padding: 0 6px; font-size: 11px; margin-left: 2px; }
.um-kv .kv .k { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .02em; }
.um-kv .kv .v { margin-top: 2px; }
.um-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.um-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.um-badge { display: inline-flex; align-items: center; gap: 6px; background: var(--side); border-radius: 8px; padding: 6px 10px; }
.um-badge small { color: var(--text-2); font-size: 13px; }
.um-act { display: flex; align-items: center; gap: 12px; background: var(--side); border-radius: 8px; padding: 12px 14px; margin-bottom: 8px; flex-wrap: wrap; }
.um-act .ic { width: 34px; height: 34px; border-radius: 50%; background: var(--elev); display: grid; place-items: center; color: var(--text-2); flex: none; }
.um-act.red .ic { background: rgba(239,68,68,.15); color: #f87171; }
.um-act .grow { min-width: 200px; flex: 1; }
.um-act b { display: block; font-weight: 600; }
.um-act small { color: var(--muted); font-size: 13px; line-height: 1.35; display: block; margin-top: 2px; }
.um-warn { display: flex; align-items: center; gap: 8px; border-left: 3px solid #f0b232; margin-bottom: 8px; }
.um-iprow { display: flex; align-items: center; gap: 12px; background: var(--side); border-radius: 8px; padding: 10px 12px; margin-bottom: 6px; }
.um-iprow .grow { min-width: 0; flex: 1; }
.um-iprow small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 3px; line-height: 1.35; }
.um-iprow.blocked { border-left: 3px solid var(--danger); }
.check-row { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 14px; cursor: pointer; margin: 4px 0; }
.ga-bar { display: flex; align-items: center; gap: 10px; margin: 8px 8px 10px; padding: 10px 10px 10px 12px; border-radius: 8px; background: rgba(88,101,242,.16); border: 1px solid rgba(88,101,242,.4); color: var(--white); }
.ga-bar > .i { color: #8b95ff; flex: none; }
.ga-bar .grow { min-width: 0; flex: 1; }
.ga-bar b { display: block; font-size: 13px; }
.ga-bar small { display: block; font-size: 11.5px; color: var(--text-2); line-height: 1.3; }
@media (max-width: 600px) {
  .um-ip { display: none; }
  .um-act > .row, .um-act > button { margin-left: 46px; }
  .um-act .row input.input { width: 120px !important; }
}
.um-hero h3 { text-transform: none; letter-spacing: 0; color: var(--white); font-weight: 700; }
.um-warn > .i { flex: none; }

/* ================================================================ v20 — invite embeds */
.inv-embeds { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.inv-card { width: 100%; max-width: 432px; background: var(--float); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.inv-bn { height: 64px; background: linear-gradient(180deg, #0d0f1a, #1c1f2e); }
.inv-body { padding: 0 16px 16px; display: flex; flex-direction: column; align-items: flex-start; }
.inv-ic { width: 64px; height: 64px; margin-top: -34px; border-radius: 18px; border: 5px solid var(--float); box-sizing: content-box; display: grid; place-items: center; overflow: hidden; font-weight: 700; font-size: 20px; background: var(--elev); }
.inv-ic img { width: 100%; height: 100%; object-fit: cover; }
.inv-name { display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 18px; font-weight: 700; color: var(--white); max-width: 100%; line-height: 1.2; }
.inv-name .ellip { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inv-name svg, .inv-name .srv-mark { flex: none; }
.inv-stats { display: flex; gap: 14px; margin-top: 4px; color: var(--text-2); font-size: 14px; flex-wrap: wrap; }
.inv-stats span { display: inline-flex; align-items: center; gap: 6px; }
.inv-stats .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--offline); display: inline-block; }
.inv-stats .dot.on { background: var(--online); }
.inv-est { color: var(--muted); font-size: 14px; margin-top: 2px; }
.inv-btn { margin-top: 14px; width: 100%; height: 40px; border: 0; border-radius: 10px; background: #248046; color: #fff; font: inherit; font-weight: 600; font-size: 15px; cursor: pointer; transition: background .12s; }
.inv-btn:hover:not(:disabled) { background: #1a6334; }
.inv-btn.go { background: var(--elev-2); }
.inv-btn.go:hover { background: var(--line-2); }
.inv-btn:disabled { opacity: .55; cursor: not-allowed; }
.inv-card.bad .inv-body { padding-top: 16px; }
.inv-card.bad .inv-ic { margin-top: 0; border: 0; background: var(--elev); color: var(--muted); }
.inv-card.bad .inv-name { color: var(--text-2); }
.inv-card .sk { background: var(--elev); border-radius: 6px; animation: invPulse 1.2s ease-in-out infinite; }
.inv-card .sk-l { height: 18px; width: 60%; margin-top: 12px; }
.inv-card .sk-s { height: 12px; width: 40%; margin-top: 8px; }
.inv-card .inv-ic.sk { border-color: var(--float); }
.inv-card .inv-btn.sk { cursor: default; }
@keyframes invPulse { 50% { opacity: .5; } }

/* ================================================================ v21 — threads */
.th-rows { position: relative; }
.ch.th-row { padding-left: 34px; min-height: 30px; position: relative; }
.ch.th-row .nm { font-size: 15px; }
.th-curve { position: absolute; left: 18px; top: -8px; width: 12px; height: 23px; border-left: 2px solid var(--line-2); border-bottom: 2px solid var(--line-2); border-bottom-left-radius: 8px; pointer-events: none; }
.th-row:not(.last)::after { content: ''; position: absolute; left: 18px; top: 13px; bottom: -6px; border-left: 2px solid var(--line-2); pointer-events: none; }
.th-chip { display: block; width: 100%; max-width: 480px; text-align: left; margin-top: 6px; background: var(--side); border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; color: var(--text); font: inherit; cursor: pointer; }
.th-chip:hover { background: var(--elev); }
.th-chip .t1 { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.th-chip .t1 b { color: var(--white); font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.th-chip .n { color: #00a8fc; font-weight: 600; font-size: 13px; display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; }
.th-chip .t2 { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; color: var(--text-2); min-width: 0; }
.th-chip .t2 b { color: var(--white); font-weight: 600; white-space: nowrap; }
.th-chip .t2 .ellip { min-width: 0; flex: 1; }
.th-chip .ago { color: var(--muted); white-space: nowrap; margin-left: auto; padding-left: 8px; }
.sys-link { color: var(--white); cursor: pointer; }
.sys-link:hover { text-decoration: underline; }
.crumb { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; padding: 0; color: var(--muted); font: inherit; font-weight: 600; cursor: pointer; min-width: 0; }
.crumb:hover { color: var(--text-2); }
#mainHead .title .crumb-sep { color: var(--faint); margin: 0 2px; }
.th-tools { display: inline-flex; align-items: center; gap: 6px; }
.th-flag { color: var(--muted); display: inline-flex; }
.th-note { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-2); background: var(--side); border-radius: 8px 8px 0 0; padding: 6px 12px; margin-bottom: -4px; }
.th-src { display: flex; align-items: center; gap: 10px; background: var(--side); border-radius: 8px; padding: 10px 12px; margin: 4px 0 14px; min-width: 0; }
.th-src .grow { min-width: 0; }
.th-src .ellip { color: var(--text-2); font-size: 14px; }
.th-start .big { background: var(--elev); }
.th-starter { display: flex; gap: 12px; text-align: left; background: var(--side); border-radius: 8px; padding: 12px 14px; margin-top: 14px; max-width: 640px; }
.th-starter .grow { min-width: 0; }
.th-starter .ts { color: var(--muted); font-size: 12px; margin-left: 4px; }
.th-starter .content { margin-top: 2px; }
.th-pop { position: fixed; z-index: 120; width: 480px; max-width: calc(100vw - 16px); max-height: min(560px, 75vh); display: flex; flex-direction: column; padding: 0 !important; overflow: hidden; }
.th-pop-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); flex: none; }
.th-pop-head b { color: var(--white); }
.th-pop-head .sep { width: 1px; height: 22px; background: var(--line-2); }
.th-pop-head input { flex: 1; min-width: 60px; background: var(--chat); border: 0; border-radius: 4px; padding: 6px 8px; color: var(--text); font: inherit; font-size: 14px; outline: none; }
.th-pop-body { overflow-y: auto; padding: 6px 8px 10px; }
.th-sec { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .02em; padding: 12px 6px 6px; }
.th-item { display: block; width: 100%; text-align: left; background: var(--side); border: 0; border-radius: 8px; padding: 10px 12px; margin-bottom: 6px; color: var(--text); font: inherit; cursor: pointer; }
.th-item:hover { background: var(--elev); }
.th-item .nm { color: var(--white); font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 4px; }
.th-item .sub { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; color: var(--text-2); min-width: 0; white-space: nowrap; overflow: hidden; }
.th-item .sub b { color: var(--white); font-weight: 600; }
.th-item .ago { color: var(--muted); flex: none; }
.dotsep { color: var(--faint); margin: 0 2px; }
.cn-wrap { position: relative; }
.cn-wrap #cnIc { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--muted); display: inline-flex; }
.cn-wrap .input { padding-left: 32px; }

/* ================================================================ v21 — forum channels */
#chat.forum-mode #composer { display: none; }
#chat.forum-mode #messages { padding: 0; }
.forum { max-width: 1100px; margin: 0 auto; padding: 16px 20px 40px; }
.fm-top { position: sticky; top: 0; z-index: 2; background: var(--chat); padding: 4px 0 10px; }
.fm-search { display: flex; align-items: center; gap: 8px; background: var(--side); border: 1px solid var(--line); border-radius: 8px; padding: 6px 6px 6px 12px; color: var(--muted); }
.fm-search input { flex: 1; min-width: 0; background: none; border: 0; outline: none; color: var(--text); font: inherit; font-size: 15px; padding: 6px 0; }
.fm-search .btn { flex: none; display: inline-flex; align-items: center; gap: 6px; }
.fm-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.fm-pill { display: inline-flex; align-items: center; gap: 6px; background: var(--side); border: 1px solid var(--line); color: var(--text-2); border-radius: 999px; padding: 4px 12px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.fm-pill:hover { color: var(--white); }
.fm-sep { width: 1px; height: 20px; background: var(--line-2); margin: 0 4px; }
.fm-tag { background: var(--side); border: 1px solid var(--line); color: var(--text-2); border-radius: 999px; padding: 4px 10px; font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; }
.fm-tag:hover:not(:disabled) { color: var(--white); background: var(--elev); }
.fm-tag.on { background: rgba(88,101,242,.22); border-color: #5865f2; color: #fff; }
.fm-tag:disabled { opacity: .45; cursor: not-allowed; }
.fm-clear { background: none; border: 0; color: #00a8fc; font: inherit; font-size: 13px; cursor: pointer; }
.fm-tagpick { display: flex; flex-wrap: wrap; gap: 6px; }
.fm-guide { background: var(--side); border-radius: 8px; padding: 10px 14px; margin: 4px 0 12px; color: var(--text-2); font-size: 14px; }
.fm-guide summary { cursor: pointer; font-weight: 600; color: var(--white); display: flex; align-items: center; gap: 6px; list-style: none; }
.fm-guide summary::-webkit-details-marker { display: none; }
.fm-guide .tx { margin-top: 6px; white-space: pre-wrap; }
.fm-guide.sm { margin-top: 0; }
.fm-guide.sm b { color: var(--white); }
.fm-list.list { display: flex; flex-direction: column; gap: 8px; }
.fm-list.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.fm-card { display: flex; gap: 14px; width: 100%; text-align: left; background: var(--side); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; color: var(--text); font: inherit; cursor: pointer; }
.fm-card:hover { background: var(--elev); border-color: var(--line-2); }
.fm-card .fm-main { flex: 1; min-width: 0; }
.fm-card .fm-title { font-size: 16px; font-weight: 600; color: var(--text-2); line-height: 1.3; overflow-wrap: anywhere; }
.fm-card.unread .fm-title { color: var(--white); }
.fm-card .fm-snip { margin-top: 4px; color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fm-card .fm-snip b { color: var(--text-2); font-weight: 600; }
.fm-card .fm-foot { margin-top: 8px; }
.fm-meta { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; flex-wrap: wrap; }
.fm-rx { display: inline-flex; align-items: center; gap: 3px; margin-left: 10px; background: var(--elev); border-radius: 6px; padding: 1px 6px; }
.fm-side { flex: none; width: 96px; height: 96px; border-radius: 8px; overflow: hidden; background: var(--elev); }
.fm-side img { width: 100%; height: 100%; object-fit: cover; }
.fm-tags-row { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 6px; }
.fm-chip { display: inline-flex; align-items: center; gap: 3px; background: var(--elev); color: var(--text-2); border-radius: 999px; padding: 2px 10px; font-size: 13px; font-weight: 500; }
.fm-chip.sm { font-size: 12px; padding: 1px 8px; }
.fm-chip.pin { background: rgba(88,101,242,.2); color: #c9cdfb; }
.fm-card.g { flex-direction: column; padding: 0; gap: 0; overflow: hidden; }
.fm-card.g .fm-thumb { height: 150px; background: var(--elev); }
.fm-card.g .fm-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fm-noimg { padding: 14px; color: var(--muted); font-size: 13px; overflow: hidden; height: 100%; box-sizing: border-box; }
.fm-g-body { padding: 12px 14px; }
.fm-empty { text-align: center; color: var(--muted); padding: 56px 20px; }
.fm-empty > .i { width: 48px; height: 48px; color: var(--faint); }
.fm-empty h3 { color: var(--white); margin: 12px 0 4px; text-transform: none; font-size: 18px; letter-spacing: 0; }
.fm-empty.sm { padding: 30px 16px; }
.fm-empty .btn { margin-top: 12px; }
.forum-start { padding-top: 20px; }
.forum-start h1 { margin-top: 4px; }
.forum-start .fm-tags-row { justify-content: flex-start; }
.fm-divider { display: flex; align-items: center; gap: 10px; margin: 10px 16px; color: var(--muted); font-size: 12px; font-weight: 600; }
.fm-divider::before, .fm-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.ft-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.ft-row .ft-emo { width: 60px; flex: none; text-align: center; }
.ft-row .input:not(.ft-emo) { flex: 1; min-width: 0; }
@media (max-width: 600px) {
  .forum { padding: 10px 10px 30px; }
  .fm-side { width: 64px; height: 64px; }
  .fm-search .btn { padding: 6px 10px; }
  .fm-list.gallery { grid-template-columns: 1fr 1fr; gap: 8px; }
  .th-pop-head input { display: none; }
}

/* ================================================================ v21 — server folders */
.rail-folder { width: 72px; display: flex; flex-direction: column; align-items: center; }
.rail-folder.open { position: relative; }
.rail-folder.open::before { content: ''; position: absolute; top: 0; bottom: 0; left: 15px; right: 15px; border-radius: 16px; background: color-mix(in srgb, var(--fc) 16%, var(--side)); z-index: 0; }
.rail-folder > .rail-item, .folder-kids > .rail-item { position: relative; z-index: 1; }
.folder-kids { display: flex; flex-direction: column; gap: 8px; padding-bottom: 6px; width: 72px; align-items: center; }
.rail-folder.open > .folder-head { margin-bottom: 8px; }
.folder-btn { background: transparent !important; color: var(--fc) !important; }
.folder-btn .i { width: 24px; height: 24px; fill: var(--fc); fill-opacity: .35; }
.folder-mini { background: color-mix(in srgb, var(--fc) 28%, var(--side)) !important; border-radius: 14px !important; display: grid !important; grid-template-columns: 1fr 1fr; grid-auto-rows: 15px; gap: 3px; padding: 5px; place-items: stretch !important; box-sizing: border-box; }
.fm-mini { border-radius: 5px; background: var(--sc); color: var(--sct); font-size: 7px; font-weight: 700; display: grid; place-items: center; overflow: hidden; line-height: 1; }
.fm-mini img { width: 100%; height: 100%; object-fit: cover; }
.rail-item.dragging { opacity: .4; }
.rail-item.drop-before::before, .rail-item.drop-after::after { content: ''; position: absolute; left: 14px; right: 14px; height: 3px; border-radius: 3px; background: #23a55a; z-index: 3; }
.rail-item.drop-before::before { top: -6px; }
.rail-item.drop-after::after { bottom: -6px; }
.rail-item.drop-into .rail-btn { box-shadow: 0 0 0 3px #23a55a; border-radius: 14px; }
.fl-colors { display: flex; flex-wrap: wrap; gap: 8px; }
.fl-col { width: 36px; height: 36px; border-radius: 8px; border: 0; cursor: pointer; position: relative; box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); }
.fl-col.on { box-shadow: 0 0 0 2px var(--chat), 0 0 0 4px var(--white); }
.fl-col.custom input { opacity: 0; position: absolute; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.fl-col.custom::after { content: '+'; color: #fff; font-weight: 700; position: absolute; inset: 0; display: grid; place-items: center; text-shadow: 0 1px 2px rgba(0,0,0,.5); pointer-events: none; }

/* ================================================================ v21 — inbox + shared popout card */
.pop-card { position: fixed; z-index: 115; background: var(--float); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 10px 30px rgba(0,0,0,.6); animation: pop .1s ease; }
#hdInbox { position: relative; }
.inbox-dot { position: absolute; top: 5px; right: 5px; width: 8px; height: 8px; border-radius: 50%; background: var(--danger, #f23f43); box-shadow: 0 0 0 2px var(--chat); }
.inbox-pop { width: 520px; max-width: calc(100vw - 16px); max-height: min(640px, 80vh); display: flex; flex-direction: column; overflow: hidden; }
.ib-head { flex: none; padding: 12px 14px 0; border-bottom: 1px solid var(--line); background: var(--side); }
.ib-title { display: flex; align-items: center; gap: 8px; color: var(--white); font-size: 16px; }
.ib-tabs { display: flex; gap: 16px; margin-top: 10px; }
.ib-tabs button { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); font: inherit; font-weight: 600; font-size: 14px; padding: 6px 0 9px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.ib-tabs button:hover { color: var(--text-2); }
.ib-tabs button.on { color: var(--white); border-bottom-color: #5865f2; }
.ib-tabs i { font-style: normal; background: var(--danger, #f23f43); color: #fff; border-radius: 999px; padding: 0 6px; font-size: 11px; line-height: 16px; }
.ib-body { overflow-y: auto; padding: 8px 10px 14px; }
.ib-loading { color: var(--muted); padding: 30px; text-align: center; }
.ib-chan { display: flex; align-items: center; gap: 8px; padding: 12px 6px 6px; font-size: 13px; min-width: 0; }
.ib-chan .nm { display: inline-flex; align-items: center; gap: 3px; color: var(--white); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ib-chan .sv { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ib-sp { width: 20px; height: 20px; border-radius: 6px; background: var(--sc); color: var(--sct); font-size: 8px; font-weight: 700; display: grid; place-items: center; overflow: hidden; flex: none; }
.ib-sp img { width: 100%; height: 100%; object-fit: cover; }
.ib-group { background: var(--side); border-radius: 8px; padding: 0 8px 8px; margin-bottom: 8px; }
.ib-group .ib-chan { padding: 10px 2px 6px; }
.ib-check { width: 28px; height: 28px; }
.ib-item { position: relative; background: var(--chat); border-radius: 6px; padding: 8px 10px; margin-bottom: 4px; cursor: pointer; }
.ib-item:hover { background: var(--elev); }
.ib-group .ib-item { background: transparent; }
.ib-group .ib-item:hover { background: var(--elev); }
.ib-msg { display: flex; gap: 10px; }
.ib-msg .grow { min-width: 0; }
.ib-msg .hd { display: flex; align-items: baseline; gap: 6px; }
.ib-msg .hd b { color: var(--white); font-weight: 600; }
.ib-msg .ts { color: var(--muted); font-size: 12px; }
.ib-msg .tx { color: var(--text); font-size: 14px; overflow-wrap: anywhere; max-height: 120px; overflow: hidden; }
.ib-acts { position: absolute; top: 6px; right: 6px; display: none; gap: 4px; align-items: center; }
.ib-item:hover .ib-acts { display: flex; }
.ib-more { display: block; margin: 10px auto 0; }

/* ================================================================ v21 — scheduled events */
.mem-n.live { background: #23a55a; color: #fff; font-size: 10px; font-weight: 800; padding: 1px 6px; border-radius: 999px; }
.ev-side { margin: 6px 8px 2px; padding: 8px 10px; border-radius: 8px; background: rgba(35,165,90,.14); border: 1px solid rgba(35,165,90,.35); cursor: pointer; }
.ev-side:hover { background: rgba(35,165,90,.2); }
.ev-side .t { display: flex; align-items: center; gap: 4px; color: #4ade80; font-size: 12px; font-weight: 600; min-width: 0; }
.ev-side .t .ellip { min-width: 0; flex: 1; }
.ev-side .lv { background: #23a55a; color: #fff; font-size: 10px; font-weight: 800; padding: 0 5px; border-radius: 4px; }
.ev-side .n { color: var(--white); font-weight: 600; font-size: 14px; margin-top: 2px; }
.ev-modal { width: 620px; }
.ev-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.ev-head h2 { margin: 0; flex: 1; display: flex; align-items: center; gap: 8px; }
.ev-list { display: flex; flex-direction: column; gap: 10px; max-height: 62vh; overflow-y: auto; }
.ev-card { background: var(--side); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.ev-card.live { border-color: rgba(35,165,90,.55); }
.ev-card.flash { animation: evflash 1.6s ease; }
@keyframes evflash { 0%, 40% { box-shadow: 0 0 0 2px #5865f2; } 100% { box-shadow: none; } }
.ev-cover { height: 150px; background: var(--elev); }
.ev-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ev-body { padding: 14px 16px 12px; }
.ev-when { font-size: 13px; font-weight: 600; color: var(--text-2); }
.ev-when > span { display: inline-flex; align-items: center; gap: 5px; }
.ev-live { color: #4ade80; }
.ev-soon { color: #00a8fc; }
.ev-name { color: var(--white); font-size: 18px; font-weight: 700; margin-top: 4px; line-height: 1.25; overflow-wrap: anywhere; }
.ev-desc { color: var(--text-2); font-size: 14px; margin-top: 6px; max-height: 84px; overflow: hidden; }
.ev-foot { display: flex; align-items: center; gap: 6px; margin-top: 12px; flex-wrap: wrap; }
.ev-where { display: inline-flex; align-items: center; gap: 5px; color: var(--text-2); font-size: 14px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60%; }
.ev-where a { color: #00a8fc; }
.ev-count { display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; padding: 4px 6px; border-radius: 4px; }
.ev-count:hover { background: var(--elev); color: var(--text-2); }
.ev-int { display: inline-flex; align-items: center; gap: 5px; }
.ev-int.on { background: rgba(88,101,242,.2); color: #c9cdfb; }
.ev-wiz-modal { width: 560px; }
.ev-steps { display: flex; gap: 8px; margin-bottom: 16px; }
.ev-steps span { flex: 1; font-size: 12px; font-weight: 600; color: var(--muted); display: flex; flex-direction: column; gap: 6px; }
.ev-steps span i { height: 4px; border-radius: 4px; background: var(--elev); }
.ev-steps span.on, .ev-steps span.done { color: var(--white); }
.ev-steps span.on i, .ev-steps span.done i { background: #5865f2; }
.ev-step-body h2 { margin-bottom: 2px; }
.ev-step-body .ev-card { margin-top: 8px; }
.ev-dt { gap: 10px; flex-wrap: wrap; }
.ev-dt .field { min-width: 140px; }
.ev-dt input[type=date], .ev-dt input[type=time] { color-scheme: dark; }
.ev-wiz-foot { display: flex; align-items: center; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.ev-ppl { max-height: 50vh; overflow-y: auto; }
.ev-toast { position: fixed; right: 16px; bottom: 16px; z-index: 200; display: flex; align-items: center; gap: 10px; background: var(--float); border: 1px solid rgba(35,165,90,.5); border-radius: 10px; padding: 12px 12px 12px 14px; box-shadow: 0 10px 30px rgba(0,0,0,.5); max-width: calc(100vw - 32px); width: 360px; animation: pop .15s ease; color: #4ade80; }
.ev-toast .grow { min-width: 0; }
.ev-toast b { color: var(--white); display: block; }
.ev-toast small { color: var(--text-2); }

/* ================================================================ v21 — stage channels */
#stage.stg-mode { padding: 0; display: flex; }
.stg { flex: 1; display: flex; flex-direction: column; min-height: 0; background: #0f0f11; }
.stg-top { display: flex; align-items: center; gap: 12px; padding: 14px 20px; border-bottom: 1px solid rgba(255,255,255,.06); color: var(--muted); }
.stg-top > .i { width: 28px; height: 28px; color: #4ade80; flex: none; }
.stg-top .grow { min-width: 0; }
.stg-top .t1 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.stg-top .t1 b { color: var(--white); font-size: 16px; }
.stg-top .t2 { color: var(--text-2); font-size: 14px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stg-ev { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: #c9cdfb; background: rgba(88,101,242,.2); border-radius: 999px; padding: 1px 8px; }
.stg-n { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.stg-main { flex: 1; overflow-y: auto; padding: 18px 24px; }
.stg-sec h4 { margin: 4px 0 12px; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); font-weight: 700; }
.stg-sec + .stg-sec { margin-top: 22px; }
.stg-spk { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 14px; }
.stg-aud { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.stg-t { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px; border-radius: 10px; cursor: pointer; min-width: 0; }
.stg-t:hover { background: rgba(255,255,255,.04); }
.stg-t.big { background: #1a1a1e; padding: 20px 10px 16px; }
.stg-t .av-wrap { position: relative; border-radius: 50%; }
.stg-t .av-wrap .av { box-shadow: 0 0 0 3px transparent; transition: box-shadow .12s; }
.stg-t.speaking .av-wrap .av { box-shadow: 0 0 0 3px #23a55a; }
.stg-t .hand, .stg-t .mic { position: absolute; right: -4px; bottom: -2px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; border: 3px solid #0f0f11; }
.stg-t .hand { background: #f0b232; color: #1a1a1e; }
.stg-t .mic { background: #ed4245; color: #fff; }
.stg-t.big .hand, .stg-t.big .mic { border-color: #1a1a1e; }
.stg-t .nm { display: flex; align-items: center; gap: 4px; max-width: 100%; color: var(--text); font-size: 14px; font-weight: 500; min-width: 0; }
.stg-t .modb { color: #4ade80; display: inline-flex; flex: none; }
.stg-idle { text-align: center; color: var(--text-2); padding: 60px 20px; max-width: 460px; margin: 0 auto; }
.stg-idle > .i { width: 56px; height: 56px; color: #4ade80; }
.stg-idle h2 { color: var(--white); margin: 12px 0 6px; }
.stg-idle .btn { margin-top: 14px; display: inline-flex; align-items: center; gap: 6px; }
.stg-wait { margin-top: 16px; font-size: 13px; color: var(--muted); }
.stg-bar { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-top: 1px solid rgba(255,255,255,.06); }
.stg-bar .btn { display: inline-flex; align-items: center; gap: 6px; }
.stg-b { position: relative; width: 48px; height: 48px; border-radius: 50%; border: 0; background: #2b2b2f; color: var(--white); display: grid; place-items: center; cursor: pointer; }
.stg-b:hover { background: #38383d; }
.stg-b.on { background: #f0b232; color: #1a1a1e; }
.stg-b.off { background: #ed4245; }
.stg-b.req i { position: absolute; top: -2px; right: -2px; background: #ed4245; color: #fff; font-style: normal; font-size: 11px; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px; display: grid; place-items: center; padding: 0 4px; border: 2px solid #0f0f11; }
.stg-side-topic { font-size: 12px; color: var(--muted); padding: 0 8px 4px 32px; }
.stg-side-aud { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); padding: 2px 8px 4px 32px; }
@media (max-width: 600px) {
  .stg-main { padding: 14px; }
  .stg-spk { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
  .stg-bar { padding: 10px 12px; gap: 8px; }
  .stg-b { width: 44px; height: 44px; }
}

/* ================================================================ v21 — soundboard */
.sb-pop { width: 420px; max-width: calc(100vw - 16px); max-height: min(460px, 70vh); display: flex; flex-direction: column; overflow: hidden; }
.sb-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--side); }
.sb-head input#sbQ { flex: 1; min-width: 0; background: var(--chat); border: 0; border-radius: 4px; padding: 7px 9px; color: var(--text); font: inherit; font-size: 14px; outline: none; }
.sb-vol { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.sb-vol input { width: 80px; accent-color: #5865f2; }
.sb-body { overflow-y: auto; padding: 4px 12px 12px; }
.sb-sec { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--muted); padding: 12px 0 8px; display: flex; align-items: center; gap: 6px; }
.sb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.sb-grid.static { margin-top: 8px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.sb-tile { position: relative; display: flex; align-items: center; gap: 6px; background: var(--chat); border: 1px solid var(--line); border-radius: 8px; padding: 8px 26px 8px 8px; color: var(--text); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; text-align: left; min-width: 0; transition: transform .08s; }
.sb-tile:hover { background: var(--elev); border-color: var(--line-2); }
.sb-tile:active, .sb-tile.fired { transform: scale(.95); background: rgba(88,101,242,.25); }
.sb-tile .em { font-size: 18px; flex: none; }
.sb-tile .nm { min-width: 0; }
.sb-tile .pv { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); opacity: 0; }
.sb-tile:hover .pv { opacity: 1; }
.sb-tile .pv:hover { background: var(--line-2); color: var(--white); }
.sb-tile.locked { opacity: .5; }
.sb-foot { border-top: 1px solid var(--line); padding: 6px 12px; }
.sb-em { font-size: 20px; width: 28px; text-align: center; }
.sb-admin .list-row { gap: 10px; }
[data-conn] { position: relative; }
[data-conn].sb-ping .av, [data-conn].sb-ping .av-wrap { animation: sbring 1.5s ease; border-radius: 50%; }
@keyframes sbring { 0% { box-shadow: 0 0 0 0 rgba(88,101,242,.9); } 70% { box-shadow: 0 0 0 12px rgba(88,101,242,0); } 100% { box-shadow: none; } }
.sb-emoji { position: absolute; left: 50%; top: 0; transform: translateX(-50%); font-size: 22px; pointer-events: none; animation: sbfloat 1.6s ease forwards; z-index: 5; }
@keyframes sbfloat { 0% { opacity: 0; transform: translate(-50%, 6px) scale(.6); } 20% { opacity: 1; transform: translate(-50%, -8px) scale(1.1); } 100% { opacity: 0; transform: translate(-50%, -40px) scale(1); } }

.av.s48 { width: 48px; height: 48px; font-size: 18px; }
.ev-list > * { flex: none; }

/* ================================================================ v22 — Blue App 2025 look (colors sampled from real Blue App screenshots)
   Themes: Dark (default) · Ash (lighter) · Onyx (near black). */
:root {
  --rail: #121214; --side: #121214; --chat: #1a191e; --members-bg: #121214;
  --elev: #25242a; --elev-2: #2c2b31; --elev-1: #1e1d22; --input: #222126; --code: #121214;
  --float: #201f24; --panel: #201f24; --menu: #28272d;
  --hover: rgba(255,255,255,.045); --active: rgba(255,255,255,.1);
  --line: #2a292f; --line-2: #36353b;
  --text: #dcdbe0; --text-2: #a3a2a8; --muted: #97969b; --faint: #67686d; --white: #f2f2f4; --ink: #0e0e10;
  --blurple: #5865f2; --blurple-h: #4752c4; --green: #3a834c; --green-h: #326f41; --red: #da373c; --red-h: #a12829;
  --link: #00a8fc; --danger: #f23f43; --online: #43a25a; --idle: #ca9654; --dnd: #d83a42; --offline: #82838b;
  --mention-bg: rgba(240,178,50,.08); --mention-bar: #f0b232;
}
body.theme-ash {
  --rail: #2c2d32; --side: #2c2d32; --chat: #323338; --members-bg: #2c2d32;
  --elev: #393a3f; --elev-2: #404146; --elev-1: #2e2f34; --input: #393a3f; --code: #2b2c31;
  --float: #242429; --panel: #26272c; --menu: #2b2c31;
  --hover: rgba(255,255,255,.04); --active: rgba(255,255,255,.09);
  --line: #393a3f; --line-2: #45464c; --text: #dbdee1; --text-2: #b5bac1; --muted: #949ba4; --faint: #6d6f78;
}
body.theme-black {
  --rail: #070709; --side: #070709; --chat: #0c0c0e; --members-bg: #070709;
  --elev: #17171a; --elev-2: #1e1e22; --elev-1: #111114; --input: #151518; --code: #070709;
  --float: #111114; --panel: #111114; --menu: #18181b;
  --hover: rgba(255,255,255,.04); --active: rgba(255,255,255,.09);
  --line: #1c1c20; --line-2: #26262b; --text: #dcdbe0; --text-2: #a3a2a8; --muted: #8f8e94; --faint: #5f5e64;
}
body.theme-black .rail-btn, body.theme-black .rail-btn.home { background: var(--elev); }

/* frame: rail + channel list share one background; chat sits in a rounded inset */
.rail { background: var(--rail); }
.sidebar { background: var(--side); border-radius: 0; }
.members { background: var(--members-bg); }
.chat, .stage:not(.stg-mode), .friends { background: var(--chat); }
#mainHead { background: var(--chat); border-bottom: 1px solid var(--line); box-shadow: none; }
.side-head { border-bottom: 1px solid var(--line); box-shadow: none; }

/* server rail */
.rail-btn { width: 40px; height: 40px; background: var(--elev); border-radius: 12px; }
.rail-item:hover .rail-btn, .rail-item.active .rail-btn { border-radius: 12px; }
.rail-item:hover .rail-btn:not(.has-img):not(.home):not(.green):not(.folder-mini):not(.folder-btn) { background: var(--blurple); color: #fff; }
.rail-btn.home { background: var(--elev); color: var(--text); }
.rail-item.active .rail-btn.home, .rail-item:hover .rail-btn.home { background: var(--blurple); color: #fff; }
.rail-btn.green { background: var(--elev); color: var(--text); }
.rail-item:hover .rail-btn.green { background: var(--green); color: #fff; }
.rail-sep { background: var(--line-2); }

/* channel list */
.ch { margin: 1px 8px; border-radius: 8px; height: 34px; color: var(--muted); }
.ch:hover { background: var(--hover); color: var(--text); }
.ch.active { background: var(--active); color: var(--white); }
.ch.unread { color: var(--white); font-weight: 600; }
.cat { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 600; color: var(--muted); padding: 18px 8px 4px 16px; gap: 4px; }
.cat > span { order: 1; }
.cat .chev { order: 2; transform: rotate(0deg); opacity: .8; }
.cat.closed .chev { transform: rotate(-90deg); }
.cat .add { order: 3; margin-left: auto; }
.cat:hover { color: var(--text); }
.side-title { text-transform: none; font-size: 14px; font-weight: 500; letter-spacing: 0; padding: 18px 8px 6px 16px; }
.side-link { margin-left: 8px; margin-right: 8px; border-radius: 8px; }
.side-link.active { background: var(--active); }
.side-sep { margin-left: 16px !important; margin-right: 16px !important; background: var(--line) !important; }
.mem-n { background: var(--elev-2); color: var(--text); border-radius: 999px; padding: 1px 8px; font-weight: 600; }
.dm-row { margin-left: 8px; margin-right: 8px; border-radius: 8px; }
.dm-row.active { background: var(--active); }
.side-search { background: var(--elev); border-radius: 8px; }

/* member list */
.mem-cat { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 500; }
.mem { border-radius: 8px; }

/* floating user panel (spans rail + channel list like Blue App's refresh) */
.user-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; margin: 0 8px 8px; height: 56px; }

/* messages + composer */
.msg:hover, .msg.menu-open { background: var(--hover); }
.msg-tools { background: var(--float); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 4px 14px rgba(0,0,0,.35); }
.composer-box { background: var(--input); border: 1px solid var(--line); border-radius: 10px; }
.reply-bar { background: var(--elev-1); }

/* buttons: Blue App colors */
.btn { border-radius: 8px; background: var(--elev-2); color: var(--white); }
.btn:hover { background: var(--line-2); }
.btn.primary { background: var(--blurple); color: #fff; }
.btn.primary:hover { background: var(--blurple-h); }
.btn.green { background: var(--green); color: #fff; }
.btn.green:hover { background: var(--green-h); }
.btn.danger { background: var(--red); color: #fff; }
.btn.danger:hover { background: var(--red-h); }
.btn.link { background: none; color: var(--text); }
.btn.link:hover { text-decoration: underline; background: none; }
.inv-btn, .tag-card .big-btn { background: var(--green); }
.inv-btn:hover:not(:disabled) { background: var(--green-h); }
.switch.on { background: var(--blurple); }

/* modals, menus, popouts, tooltips */
.modal { background: var(--float); border-radius: 12px; border: 1px solid var(--line); }
.modal-foot { background: var(--float); border-top: 1px solid var(--line); }
.menu { background: var(--menu); border: 1px solid var(--line-2); border-radius: 8px; padding: 6px; }
.menu .mi { color: var(--text); border-radius: 6px; }
.menu .mi:hover { background: var(--active); color: var(--white); }
.menu .mi:hover .sub { color: var(--text-2); }
.menu .mi.red { color: #f57376; }
.menu .mi.red:hover { background: var(--danger); color: #fff; }
.tooltip { background: var(--menu); border-color: var(--line-2); border-radius: 8px; }
.pop-card, .popout { background: var(--float); border-color: var(--line-2); border-radius: 10px; }
.input, .textarea, .select { background: var(--elev-1); border: 1px solid var(--line); border-radius: 8px; }
.input:focus, .textarea:focus, .select:focus { border-color: var(--blurple); }
.card { background: var(--elev-1); border: 1px solid var(--line); border-radius: 10px; }
.settings { background: var(--chat); }
.set-nav { background: var(--side); }
.set-nav button { border-radius: 8px; }
.set-nav button.active { background: var(--active); color: var(--white); }

/* text */
a, .link-like { color: var(--link); }
.count, .ping, .count-pill { background: var(--dnd); }
/* Desktop: the voice + user panel float across the rail and the channel list, like Blue App's refresh. */
@media (min-width: 761px) {
  .voice-conn, .user-panel { position: fixed; left: 8px; width: 296px; z-index: 30; box-sizing: border-box; }
  .user-panel { bottom: 8px; margin: 0; }
  .voice-conn { bottom: 64px; background: var(--panel); border: 1px solid var(--line); border-bottom: 0; border-radius: 10px 10px 0 0; }
  .voice-conn:not(.hidden) + .user-panel { border-radius: 0 0 10px 10px; border-top-color: var(--line); }
  .rail { padding-bottom: 80px; }
  .side-scroll { padding-bottom: 72px; }
  .sidebar:has(.voice-conn:not(.hidden)) .side-scroll, .app:has(.voice-conn:not(.hidden)) .rail { padding-bottom: 180px; }
}
.rail-item:hover .rail-btn:not(.home):not(.has-img):not(.green):not(.folder-mini):not(.folder-btn),
.rail-item.active .rail-btn:not(.home):not(.has-img):not(.green):not(.folder-mini):not(.folder-btn) { background: var(--blurple); color: #fff; text-shadow: none; }
.fr-tab { border-radius: 8px; }
.fr-tab.active { background: var(--active); color: var(--white); }
.fr-tab.add { background: var(--blurple); color: #fff; }
.fr-tab.add.active { background: none; color: #949cf7; }
.friends .field-label { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 500; }

/* ================================================================ v23 — Blue App desktop type scale & spacing */
body { font-size: 16px; }
/* channel list */
.side-head { font-size: 16px; font-weight: 600; line-height: 20px; }
.cat { text-transform: uppercase; font-size: 12px; font-weight: 600; letter-spacing: .02em; line-height: 16px; padding: 16px 8px 4px 10px; gap: 2px; }
.cat > span, .cat .chev, .cat .add { order: 0; }
.cat .chev { width: 12px; height: 12px; transform: none; }
.cat.closed .chev { transform: rotate(-90deg); }
.cat .add { margin-left: auto; }
.ch { height: 32px; font-size: 16px; font-weight: 500; line-height: 20px; }
.ch > .i:first-child { width: 20px; height: 20px; flex: none; }
.side-title { text-transform: uppercase; font-size: 12px; font-weight: 600; letter-spacing: .02em; padding: 16px 8px 4px 18px; }
.side-link { height: 42px; font-size: 16px; font-weight: 500; }
.dm-row { height: 42px; font-size: 16px; font-weight: 500; }
/* member list */
.mem-cat { text-transform: uppercase; font-size: 12px; font-weight: 600; letter-spacing: .02em; padding: 24px 8px 4px; height: auto; }
.mem { height: 42px; }
.mem .meta b, .mem .mn { font-size: 16px; font-weight: 500; }
.mem .meta small { font-size: 12px; }
/* chat */
#mainHead .title { font-size: 16px; font-weight: 600; }
#mainHead .topic { font-size: 14px; }
.msg { padding: 2px 48px 2px 72px; }
.msg.head { margin-top: 17px; }
.msg .content { font-size: 1rem; line-height: 1.375rem; }
.msg .hdr .name { font-size: 16px; font-weight: 500; line-height: 1.375rem; }
.msg .hdr .ts { font-size: 12px; font-weight: 500; margin-left: 4px; color: var(--muted); }
.msg .side-ts { font-size: 11px; }
.msg > .av { width: 40px; height: 40px; left: 16px; top: 2px; }
.divider span { font-size: 12px; font-weight: 600; }
#input { font-size: 16px; line-height: 1.375rem; }
.composer-box { min-height: 44px; }
/* user panel */
.user-panel .meta b { font-size: 14px; font-weight: 600; }
.user-panel .meta small { font-size: 12px; }
/* settings */
.set-nav h5 { font-size: 12px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; padding: 6px 10px; }
.set-nav button { font-size: 16px; font-weight: 500; line-height: 20px; padding: 6px 10px; margin-bottom: 2px; }
.set-main h2 { font-size: 20px; font-weight: 600; line-height: 24px; margin-bottom: 20px; }
.wn-item { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--line); }
.wn-item p { margin: 0; color: var(--text-2); line-height: 1.45; }
.wn-v { flex: none; background: var(--blurple); color: #fff; font-weight: 700; font-size: 12px; border-radius: 6px; padding: 2px 8px; margin-top: 1px; }
.wn-item.first .wn-v { background: var(--green); }
/* tooltips & buttons */
.tooltip { font-size: 14px; font-weight: 600; }
.btn { font-size: 14px; font-weight: 500; }

/* ================================================================ v24 — Blue App details */
.qr-row { display: flex; gap: 4px; padding: 2px 2px 6px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
.qr { flex: 1; height: 40px; border-radius: 8px; background: var(--elev); font-size: 22px; display: grid; place-items: center; transition: background .1s, transform .1s; }
.qr:hover { background: var(--elev-2); transform: scale(1.05); }
.up-pair { display: inline-flex; align-items: center; border-radius: 6px; }
.up-pair:hover { background: var(--hover); }
.up-pair .icon-btn:first-child { width: 30px; }
.up-caret { width: 16px !important; height: 32px; color: var(--muted); padding: 0; }
.up-caret:hover { color: var(--white); background: none !important; }
.user-panel { gap: 2px; }
.vc-limit { display: inline-flex; align-items: stretch; height: 18px; border-radius: 9px; overflow: hidden; font-size: 11px; font-weight: 600; margin-left: auto; border: 1px solid var(--line-2); flex: none; }
.vc-limit b { padding: 0 5px 0 7px; display: grid; place-items: center; background: var(--elev); color: var(--text); font-weight: 600; }
.vc-limit i { font-style: normal; padding: 0 7px 0 6px; display: grid; place-items: center; background: var(--chat); color: var(--muted); clip-path: polygon(4px 0, 100% 0, 100% 100%, 0 100%); margin-left: -3px; }
.vc-limit.full b { color: var(--danger); }
.ch .vc-limit + .tools { margin-left: 4px; }
.new-pill { margin-left: auto; font-size: 11px; font-weight: 700; color: #949cf7; background: rgba(88,101,242,.16); border-radius: 999px; padding: 1px 7px; letter-spacing: .02em; flex: none; }
.ch:hover .new-pill { display: none; }
.side-banner { height: 120px; margin: -1px 0 8px; background: center/cover no-repeat; position: relative; }
.side-banner::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.55), transparent 55%); }
.side-head.over-banner { position: relative; z-index: 2; background: transparent; border-bottom-color: transparent; margin-bottom: -48px; text-shadow: 0 1px 3px rgba(0,0,0,.6); }

/* ================================================================ v25 — platform indicators + call timer */
.plat-ind { display: inline-flex; align-items: center; gap: 2px; margin-left: 5px; vertical-align: -2px; flex: none; }
.plat-ind .i { width: 14px; height: 14px; stroke-width: 2.2; }
.plat-ind.st-online { color: var(--online); }
.plat-ind.st-idle { color: var(--idle); }
.plat-ind.st-dnd { color: var(--dnd); }
.msg .hdr .plat-ind { margin-left: 2px; margin-right: 2px; }
.dm-row .plat-ind { margin-left: 4px; }
.vc-time { margin-left: 6px; font-size: 12px; font-weight: 600; color: var(--online); font-variant-numeric: tabular-nums; }
#voiceConn .lbl b { display: inline; }

/* ================================================================ v26 — message reports */
.rm-modal .modal-body { max-height: 72vh; overflow-y: auto; }
.rm-where { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--muted); margin: 4px 0 6px; flex-wrap: wrap; }
.rm-where .btn { margin-left: 6px; }
.rm-card { border: 1px solid var(--line-2); border-radius: 8px; padding: 10px 12px; margin-bottom: 16px; background: var(--elev-1, rgba(0,0,0,.15)); max-height: 220px; overflow-y: auto; }
.rm-msg { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; }
.rm-msg .grow { min-width: 0; }
.rm-hdr { display: flex; align-items: baseline; gap: 6px; }
.rm-hdr b { font-size: 15px; font-weight: 600; }
.rm-hdr .ts { font-size: 12px; color: var(--muted); }
.rm-body { font-size: 15px; line-height: 1.375; white-space: pre-wrap; word-break: break-word; }
.rm-atts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.rm-img { max-width: 220px; max-height: 160px; border-radius: 6px; display: block; }
.rm-file { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.rp-reasons .choice small { display: block; font-size: 12px; color: var(--muted); font-weight: 400; margin-top: 1px; }
.rm-care { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 8px; background: rgba(88, 101, 242, .12); border: 1px solid rgba(88, 101, 242, .35); font-size: 13px; margin: 0 0 12px; }
.rm-staff { border: 1px solid var(--line-2); border-radius: 8px; padding: 8px 12px; margin: 10px 0; }
.rm-staff .rm-msg.reported { background: rgba(242, 63, 67, .08); border-left: 3px solid var(--red); padding: 8px; margin: 4px -4px; border-radius: 4px; }
.rm-staff .rm-msg.dim { opacity: .65; }
.rm-ctx summary { cursor: pointer; font-size: 12px; color: var(--muted); margin: 2px 0 4px; }
.rp-lbl { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.rm-steps { margin: 8px 0 0 20px; line-height: 1.8; }

/* ================================================================ v27 — push to talk, desktop screen picker */
.im-pick { display: grid; gap: 8px; max-width: 520px; }
.im-pick .choice { margin: 0; }
.im-pick .choice small { display: block; font-size: 12px; color: var(--muted); font-weight: 400; }
.ptt-row { margin-top: 12px; gap: 16px; }
.ptt-key { min-width: 200px; justify-content: flex-start; gap: 8px; font-weight: 600; }
.ptt-key.unset { color: var(--muted); }
.ptt-key.recording { box-shadow: 0 0 0 2px var(--red) inset; color: var(--red); }
.ptt-note { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); padding: 10px 12px; border-radius: 8px; background: var(--elev-1, rgba(0,0,0,.18)); transition: color .1s, background .1s; flex-wrap: wrap; }
.ptt-note.live { color: var(--online); background: rgba(35, 165, 90, .12); }
.ptt-note a { color: var(--link, #00a8fc); }
.vc-ptt { display: block; font-size: 11px; color: var(--muted); }
.src-modal { width: min(720px, 94vw); }
.src-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; max-height: 50vh; overflow-y: auto; margin-top: 10px; }
.src { display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 8px; border: 2px solid transparent; background: var(--elev-2, #2b2b30); text-align: left; cursor: pointer; }
.src.sel { border-color: var(--blurple); }
.src > img { width: 100%; aspect-ratio: 16 / 9; object-fit: contain; background: #000; border-radius: 4px; }
.src span { display: flex; align-items: center; gap: 6px; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.src-ic { width: 16px; height: 16px; }
.su-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--online); margin-right: 5px; vertical-align: 0; }

/* ================================================================ v28 — email reminder bar */
.nbar { position: fixed; top: 0; left: 0; right: 0; height: 36px; z-index: 50; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 0 44px; background: var(--blurple); color: #fff; font-size: 14px; font-weight: 500; }
.nbar > span { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nbar-btn { flex: none; border: 1px solid rgba(255,255,255,.85); color: #fff; background: transparent; border-radius: 4px; padding: 3px 12px; font-size: 13px; font-weight: 600; cursor: pointer; }
.nbar-btn:hover { background: #fff; color: var(--blurple); }
.nbar-x { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: none; border: 0; color: #fff; opacity: .8; cursor: pointer; display: grid; place-items: center; }
.nbar-x:hover { opacity: 1; }
body.has-nbar .app { height: calc(100% - 36px); margin-top: 36px; }
body.has-nbar .user-panel { bottom: 8px; }
@media (max-width: 760px) { .nbar { font-size: 12px; padding: 0 36px 0 10px; justify-content: flex-start; } }

/* ================================================================ v29 — CEO news, wipe/scan, official messages */
.nav-sub { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 10px 8px 2px; opacity: .7; }
.nav-sub.danger { color: var(--red); opacity: .85; }
.seg { display: inline-flex; gap: 2px; background: var(--elev-1, #1e1e22); border-radius: 8px; padding: 3px; margin-bottom: 14px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; color: var(--muted); padding: 7px 14px; border-radius: 6px; font-weight: 600; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.seg button.on { background: var(--blurple); color: #fff; }
.news-preview { border: 1px solid var(--line-2); border-radius: 10px; padding: 12px; margin: 10px 0 16px; background: var(--chat, #141418); }
.np-label { font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.scan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; margin-bottom: 14px; }
.scan-card { display: flex; gap: 12px; align-items: center; text-align: left; padding: 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--elev-1, #1c1c20); cursor: pointer; color: var(--text); }
.scan-card:hover { border-color: var(--blurple); }
.scan-card.on { border-color: var(--blurple); box-shadow: 0 0 0 1px var(--blurple) inset; }
.scan-card .ic { width: 40px; height: 40px; border-radius: 10px; background: var(--elev-2, #2a2a30); display: grid; place-items: center; color: var(--blurple); flex: none; }
.scan-card small { display: block; color: var(--muted); font-size: 12px; font-weight: 400; margin-top: 2px; }
.scan-results { border: 1px solid var(--line-2); border-radius: 10px; padding: 8px 12px; max-height: 420px; overflow-y: auto; margin-bottom: 8px; }
.scan-head { font-size: 13px; color: var(--muted); padding: 4px 0 8px; }
.scan-badges { display: inline-flex; gap: 3px; margin-top: 2px; }
.scan-badge { display: inline-flex; }
.danger-h { color: var(--red); }
.wipe-list { display: flex; flex-direction: column; gap: 8px; }
.official-note { color: #aab1ff; }
/* official messages */
.msg.official { background: linear-gradient(90deg, rgba(88,101,242,.10), transparent 60%); border-left: 3px solid var(--blurple); border-radius: 4px; padding-left: 60px; margin: 6px 0; }
.msg.official .off-av { position: absolute; left: 16px; top: 10px; width: 32px; height: 32px; border-radius: 50%; background: var(--blurple); color: #fff; display: grid; place-items: center; }
.official-chip { display: inline-flex; align-items: center; gap: 3px; background: var(--blurple); color: #fff; font-size: 10px; font-weight: 800; letter-spacing: .03em; padding: 1px 6px; border-radius: 4px; margin-left: 6px; vertical-align: 1px; }
.off-kind { font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); letter-spacing: .04em; margin: 1px 0 3px; }
.off-kind.off-strike, .off-kind.off-restrict { color: var(--red); }
.off-title { font-weight: 700; font-size: 15px; margin-bottom: 2px; }
.msg.official .content { white-space: pre-wrap; }

/* ================================================================ v30 — voice messages + import */
.vm-bar { display: flex; align-items: center; gap: 10px; }
.vm-rec { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text); }
.vm-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--red); animation: vmpulse 1s infinite; }
@keyframes vmpulse { 50% { opacity: .3; } }
.vm-send { color: var(--blurple) !important; }
.vm-play { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; background: var(--elev-1, #1e1e22); border: 1px solid var(--line-2); max-width: 340px; }
.vm-play > .i { color: var(--blurple); flex: none; }
.vm-label { font-size: 12px; color: var(--muted); font-weight: 600; margin-bottom: 4px; }
.vm-play audio { width: 100%; height: 32px; }
.imp-why { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; background: rgba(88,101,242,.1); border: 1px solid rgba(88,101,242,.3); font-size: 13px; line-height: 1.5; margin-bottom: 14px; }
.imp-drop { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 28px; border: 2px dashed var(--line-2); border-radius: 12px; color: var(--muted); }
.imp-drop.over { border-color: var(--blurple); background: rgba(88,101,242,.06); }
.imp-drop b { color: var(--text); }
.imp-out { margin-top: 14px; }
.imp-prog, .imp-done { display: flex; align-items: center; gap: 8px; font-size: 14px; padding: 12px; border-radius: 8px; background: var(--elev-1, #1e1e22); }
.imp-done { color: var(--online); }

/* ================================================================ v31 — bot tags */
.bot-tag { display:inline-flex; align-items:center; background:var(--blurple); color:#fff; font-size:10px; font-weight:800; letter-spacing:.02em; padding:1px 5px; border-radius:4px; margin-left:6px; vertical-align:1px; text-transform:uppercase; line-height:1.4; }
.mem .bot-tag, .dm-row .bot-tag { margin-left:5px; }
[data-devportal] { display:flex; align-items:center; gap:6px; }

/* captcha box on the sign-up form */
.cap-box { min-height: 66px; display: flex; align-items: center; }
.cap-loading { color: var(--muted); font-size: 13px; padding: 10px 0; }

/* verified bot: checkmark inside the BOT tag */
.bot-tag.verified { gap:2px; padding-left:3px; }
.bot-tag .bot-check { width:11px; height:11px; flex:none; }
