/* ============================================================
   VULU v3 — Global-chat app layout (4-pane). Reuses cozy-base.css
   for rail/squircle/avatar/facepile/buttons. On-brand colors.
   ============================================================ */

.app3 { display: flex; height: 100%; }

/* app rail — reuse .rail/.sq from cozy-base; profile avatar at bottom */
.app3 .rail .sq.prof { background: transparent; padding: 0; }
.app3 .rail .sq.prof:hover, .app3 .rail .sq.prof.active { background: transparent; }
.app3 .rail .sq.prof .av .avbg { box-shadow: 0 0 0 2px var(--rail-bg); }

/* ---------- LIVES panel (column 2) ---------- */
.lives { width: 270px; flex: 0 0 auto; background: var(--side-bg); display: flex; flex-direction: column; }
.lives__head { height: 50px; flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 0 14px 0 16px; border-bottom: 1px solid var(--hair); font-weight: 700; font-size: 15px; letter-spacing: -0.01em; }
.lives__head .ib { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); }
.lives__head .ib .ic { width: 17px; height: 17px; }
.lives__body { flex: 1 1 auto; overflow: hidden; padding: 10px 8px; }
.lives__grp { display: flex; align-items: center; gap: 7px; padding: 8px 8px 8px; font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.lives__grp .lvdot { width: 7px; height: 7px; border-radius: 999px; background: var(--red); }
.lives__grp .n { margin-left: auto; color: var(--text-2); }

/* user panel reuse .upanel from base */

/* ---- V1: rich rows ---- */
.cv1 .lr { display: flex; align-items: center; gap: 11px; padding: 9px 9px; border-radius: 10px; cursor: pointer; transition: background .12s; }
.cv1 .lr:hover { background: var(--raised); }
.cv1 .lr > div { flex: 1 1 auto; min-width: 0; }
.cv1 .lr .nm { font-size: 13.5px; font-weight: 700; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv1 .lr .sub { font-size: 12px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv1 .lr .v { margin-left: auto; font-size: 12px; font-weight: 700; color: var(--text-2); display: inline-flex; align-items: center; gap: 5px; flex: 0 0 auto; }
.cv1 .lr .v i { width: 6px; height: 6px; border-radius: 999px; background: var(--red); }

/* ---- V2: profile cards ---- */
.cv2 .lc { padding: 12px; border-radius: 14px; background: var(--surface); margin-bottom: 9px; cursor: pointer; transition: background .12s, transform .12s; }
.cv2 .lc:hover { background: var(--raised); }
.cv2 .lc .top { display: flex; align-items: center; gap: 11px; }
.cv2 .lc .top > div { flex: 1 1 auto; min-width: 0; }
.cv2 .lc .nm { font-size: 14px; font-weight: 700; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv2 .lc .hd { font-size: 12px; color: var(--muted); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv2 .lc .watch { margin-left: auto; width: 34px; height: 34px; border-radius: 9px; background: var(--green-tint); color: var(--green); display: grid; place-items: center; flex: 0 0 auto; }
.cv2 .lc .watch .ic { width: 16px; height: 16px; }
.cv2 .lc .row2 { display: flex; align-items: center; gap: 9px; margin-top: 11px; }
.cv2 .lc .lvbadge { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 800; color: var(--red); letter-spacing: 0.04em; flex: 0 0 auto; }
.cv2 .lc .lvbadge i { width: 6px; height: 6px; border-radius: 999px; background: var(--red); }
.cv2 .lc .cat { font-size: 11.5px; font-weight: 600; color: var(--text-2); background: var(--fill); padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.cv2 .lc .v { margin-left: auto; font-size: 12px; font-weight: 700; color: var(--text-2); }

/* ---- V3: thumbnail-led ---- */
.cv3 .lt { margin-bottom: 12px; cursor: pointer; }
.cv3 .lt .thumb { height: 104px; border-radius: 12px; position: relative; overflow: hidden; transition: box-shadow .12s; }
.cv3 .lt:hover .thumb { box-shadow: 0 0 0 2px var(--green-line); }
.cv3 .lt .thumb .top { position: absolute; top: 8px; left: 8px; right: 8px; display: flex; justify-content: space-between; z-index: 2; }
.cv3 .lt .cap { display: flex; gap: 10px; padding: 9px 2px 0; }
.cv3 .lt .cap > div { flex: 1 1 auto; min-width: 0; }
.cv3 .lt .ti { font-size: 13px; font-weight: 700; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cv3 .lt .sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.badgered { display: inline-flex; align-items: center; gap: 5px; background: rgba(0,0,0,0.55); backdrop-filter: blur(6px); padding: 4px 8px; border-radius: 7px; font-size: 10px; font-weight: 800; color: #fff; letter-spacing: 0.04em; }
.badgered i { width: 5px; height: 5px; border-radius: 999px; background: var(--red); }

/* ---------- CHAT (center) ---------- */
.chat { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; background: var(--main-bg); }
.chan { height: 56px; flex: 0 0 auto; display: flex; align-items: center; gap: 11px; padding: 0 18px; border-bottom: 1px solid var(--hair); }
.chan .hash { color: var(--muted); display: grid; place-items: center; } .chan .hash .ic { width: 20px; height: 20px; }
.chan h2 { margin: 0; font-size: 16px; font-weight: 700; letter-spacing: -0.01em; }
.chan .topic { font-size: 13px; color: var(--muted); padding-left: 12px; margin-left: 1px; border-left: 1px solid var(--divider); }
.chan .acts { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.chan .ib { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); cursor: pointer; }
.chan .ib:hover { background: var(--raised); color: var(--text); }
.chan .ib .ic { width: 19px; height: 19px; }
.chan .mc { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 11px; border-radius: 8px; color: var(--text-2); font-size: 13px; font-weight: 700; }
.chan .mc .ic { width: 16px; height: 16px; }

/* ---- polished header: title + unified search + notifications ---- */
.chan { gap: 14px; }
.chan__title { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.chan__title h2 { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: -0.02em; white-space: nowrap; }
.chan .acts { margin-left: auto; display: flex; align-items: center; gap: 10px; min-width: 0; }

/* wallet — single container holding all 4 currencies as segments */
.wallet { display: flex; align-items: center; background: var(--raised); border: 1px solid var(--border); border-radius: 10px; height: 40px; overflow: hidden; }
.wchip { display: inline-flex; align-items: center; gap: 7px; height: 100%; padding: 0 12px; background: none; border: 0; cursor: pointer; transition: background .15s; }
/* expanded: separated segments, each highlights individually */
.wallet:not(.compact) .wchip + .wchip { box-shadow: inset 1px 0 0 var(--border); }
.wallet:not(.compact) .wchip:hover { background: var(--fill-hover); }
/* compact: unified block — hovering anywhere highlights all four */
.wallet.compact { cursor: pointer; transition: background .15s; }
.wallet.compact:hover { background: var(--raised-2); }
.wic { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; flex: 0 0 auto; background: var(--raised-2); }
.wic .ic { width: 14px; height: 14px; }
.wv { font-size: 13px; font-weight: 800; letter-spacing: -0.01em; color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap; max-width: 60px; overflow: hidden; }
.wallet.compact .wchip { padding: 0; width: 40px; justify-content: center; }
.wallet.compact .wv { max-width: 0; opacity: 0; margin-left: -7px; transition: max-width .18s ease, opacity .15s ease, margin-left .18s ease; }
/* audit A1: balances were fully hidden in compact mode — reveal on hover/keyboard focus */
.wallet.compact:hover .wv, .wallet.compact:focus-within .wv { max-width: 60px; opacity: 1; margin-left: 0; }
.wallet.compact:hover .wchip, .wallet.compact:focus-within .wchip { width: auto; padding: 0 10px; }
.w--cash .wic { color: var(--green); }
.w--gems .wic { color: var(--purple); }
.w--fuel .wic { color: var(--gold); }
.w--robux .wic { color: var(--grey-dot); }

/* search — icon button that expands into a field */
.searchbox { flex: 0 0 auto; }
.searchbox.open { flex: 1 1 auto; min-width: 0; }
.searchbtn { width: 40px; height: 40px; border-radius: 10px; background: var(--fill); border: 1px solid var(--border); display: grid; place-items: center; color: var(--text-2); cursor: pointer; transition: background .15s, color .15s; }
.searchbtn:hover { background: var(--fill-hover); color: var(--text); }
.searchbtn .ic { width: 19px; height: 19px; }
.searchbox.open { display: flex; align-items: center; gap: 9px; height: 40px; padding: 0 8px 0 13px; background: var(--rail-bg); border: 1px solid #3a4140; border-radius: 10px; }
.searchbox__ic { display: grid; place-items: center; color: var(--muted); flex: 0 0 auto; }
.searchbox__ic .ic { width: 16px; height: 16px; }
.searchbox.open input { flex: 1 1 auto; min-width: 0; background: none; border: 0; outline: none; color: var(--text); font-size: 14px; font-family: inherit; }
.searchbox.open input::placeholder { color: var(--muted); }
.searchbox__x { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: none; border: 0; color: var(--muted); cursor: pointer; flex: 0 0 auto; }
.searchbox__x:hover { background: var(--fill); color: var(--text); }
.searchbox__x .ic { width: 15px; height: 15px; }
.notif { position: relative; width: 40px; height: 40px; border-radius: 10px; background: var(--fill); border: 1px solid var(--border); display: grid; place-items: center; color: var(--text-2); cursor: pointer; transition: background .15s, color .15s; }
.notif:hover { background: var(--fill-hover); color: var(--text); }
.notif .ic { width: 19px; height: 19px; }
.notif .dot { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--red); color: #fff; font-size: 10.5px; font-weight: 800; line-height: 18px; text-align: center; box-shadow: 0 0 0 2px var(--main-bg); }
.notif .notif__count { display: inline-grid; place-items: center; font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: 0; color: #fff; text-shadow: none; }
.notif.on { background: var(--raised-2); color: var(--text); border-color: #313838; }

/* notifications popup — anchored under the bell */
.notif-wrap { position: relative; }
.npop-scrim { position: fixed; inset: 0; z-index: 80; }
.npop { position: absolute; top: calc(100% + 12px); right: 0; z-index: 81; width: 340px; background: var(--raised); border: 1px solid var(--border); border-radius: 16px; box-shadow: 0 20px 56px rgba(0,0,0,0.62); overflow: hidden; }
.npop::before { content: ""; position: absolute; top: -6px; right: 13px; width: 11px; height: 11px; background: var(--raised); border-left: 1px solid var(--border); border-top: 1px solid var(--border); transform: rotate(45deg); }
.npop__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 15px 11px; border-bottom: 1px solid var(--divider); }
.npop__head h3 { margin: 0; font-size: 15px; font-weight: 800; letter-spacing: -0.01em; }
.npop__read { background: none; border: 0; color: var(--text-2); font-size: 12px; font-weight: 700; font-family: inherit; cursor: pointer; padding: 4px 6px; border-radius: 7px; }
.npop__read:hover { background: var(--fill); color: var(--text); }
.npop__list { max-height: 360px; overflow-y: auto; padding: 6px; }
.npop__row { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 11px; border: 0; background: none; border-radius: 11px; cursor: pointer; text-align: left; font-family: inherit; }
.npop__row:hover { background: var(--raised-2); }
.npop__row.unread { background: rgba(255,255,255,0.022); }
.npop__ic { width: 38px; height: 38px; border-radius: 11px; background: var(--raised-2); color: var(--text-2); display: grid; place-items: center; flex: 0 0 auto; }
.npop__ic .ic { width: 19px; height: 19px; }
.npop__ic.red { color: var(--red); }
.npop__ic.gem { color: var(--purple); }
.npop__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 auto; }
.npop__body .t { font-size: 13.5px; font-weight: 700; color: var(--text); line-height: 1.25; }
.npop__body .s { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.npop__dot { width: 8px; height: 8px; border-radius: 999px; background: var(--red); flex: 0 0 auto; }

/* ---- composer polish ---- */
.cbox:focus-within { box-shadow: 0 0 0 1px #3a4140; }

/* ---- lives header count ---- */
.lives__head .hcount { font-size: 12px; font-weight: 700; color: var(--text-2); background: var(--fill); border-radius: 999px; padding: 2px 9px; }

/* ============================================================
   WIDGETIZED STAGE — chat + friends as contained, spaced cards
   ============================================================ */
.stage { flex: 1 1 auto; min-width: 0; min-height: 0; display: flex; gap: 14px; padding: 14px; background: var(--bg); }
.stage .chat { flex: 1 1 auto; min-width: 0; border: 1px solid var(--border); border-radius: 16px; overflow: hidden; background: var(--main-bg); }
.stage .chat .stream { min-height: 0; padding: 10px 8px 4px; }
.stage .mlist { width: 236px; flex: 0 0 auto; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); padding: 14px 12px; overflow: hidden; position: relative; }

/* right column = currency card + friends card, stacked */

/* chat header sits a touch lighter than the message canvas */
.stage .chan { background: var(--surface); border-bottom: 1px solid var(--border); }

/* messages — roomier, rounded hover, cleaner rhythm */
.stage .msg { padding: 8px 12px; border-radius: 12px; gap: 13px; }
.stage .msg:hover { background: rgba(255,255,255,0.035); }
.stage .msg__head { margin-bottom: 3px; }
.stage .msg__line { color: #e6ece8; }
.stage .reacts { margin-top: 9px; }
.stage .react { height: 26px; border-radius: 999px; }

/* system events (gems / gifts) read as a contained little chip-row */
.stage .sysmsg { margin: 6px 10px; padding: 9px 13px; border-radius: 12px; background: rgba(255,255,255,0.022); border: 1px solid var(--hair); }
.stage .sysmsg.gift { background: rgba(190,56,243,0.08); border-color: rgba(190,56,243,0.20); }

.stage .welcome { padding: 14px 14px 16px; }
.stage .composer { padding: 8px 10px 12px; }

/* friends widget */
.stage .mlist .gl { padding: 13px 9px 6px; }
.stage .mlist .gl:first-child { padding-top: 8px; }

/* friend rows: avatar (ring/dot) + name, whole row is clickable */
.frow { display: flex; align-items: center; gap: 11px; width: 100%; padding: 7px 9px; border-radius: 10px; background: none; border: 0; cursor: pointer; font-family: inherit; text-align: left; transition: background .12s; }
.frow:hover { background: var(--raised); }
.frow .fnm { flex: 1 1 auto; min-width: 0; font-size: 13.5px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.frow.off { opacity: 0.5; }
.frow.off:hover { opacity: 0.85; }

/* live action menu — pops right under the clicked friend */
.fscrim { position: fixed; inset: 0; z-index: 28; }
.factions { position: absolute; left: 12px; right: 12px; z-index: 30; background: var(--raised-2); border: 1px solid var(--border); border-radius: 12px; padding: 6px; box-shadow: 0 16px 44px rgba(0,0,0,0.6); }
.factions__who { font-size: 10.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); padding: 7px 9px 5px; }
.factions button { display: flex; align-items: center; gap: 11px; width: 100%; padding: 10px 10px; border-radius: 9px; background: none; border: 0; cursor: pointer; color: var(--text); font-size: 13.5px; font-weight: 600; font-family: inherit; text-align: left; transition: background .12s; }
.factions button:hover { background: var(--raised); }
.factions button .ic { width: 18px; height: 18px; color: var(--text-2); flex: 0 0 auto; }
.factions button.join .ic { color: var(--red); }
.factions button.join--watch .ic { color: var(--green); }

/* floating chooser — pops beside the clicked avatar in the minimized rail */
.fscrim--fixed { z-index: 58; }
.factions--float {
  position: fixed; left: auto; width: 232px; z-index: 60;
  padding: 7px;
}
.factions__peek { display: flex; align-items: center; gap: 10px; padding: 6px 8px 9px; margin-bottom: 3px; border-bottom: 1px solid var(--hair); }
.factions__pmeta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.factions__pnm { font-size: 14px; font-weight: 700; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.factions__who2 { font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }

/* ---- docked message popups (max 3) ---- */
.chatdock { position: absolute; right: 16px; bottom: 0; display: flex; align-items: flex-end; gap: 12px; z-index: 60; pointer-events: none; }
.chatdock .cwin { pointer-events: auto; }
.cwin { width: 343px; background: var(--raised); border: 1px solid var(--border); border-bottom: 0; border-radius: 14px 14px 0 0; overflow: hidden; box-shadow: 0 16px 48px rgba(0,0,0,0.55); display: flex; flex-direction: column; }
.cwin__head { display: flex; align-items: center; gap: 9px; padding: 9px 8px 9px 11px; background: var(--surface); cursor: pointer; border-bottom: 1px solid var(--hair); }
.cwin__nm { flex: 1 1 auto; min-width: 0; font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cwin__ic { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; color: var(--muted); background: none; border: 0; cursor: pointer; }
.cwin__ic:hover { background: var(--raised-2); color: var(--text); }
.cwin__ic .ic { width: 15px; height: 15px; }
.cwin__body { height: 258px; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; padding: 10px 0; display: flex; flex-direction: column; gap: 0; }
.cwin__body > .dmsg:first-child { margin-top: auto; }

/* ===== Discord-style DM rows: single column, avatar + name + time, grouped ===== */
.dmsg { position: relative; display: flex; gap: 11px; padding: 9px 12px 2px; }
.dmsg--grouped { padding-top: 1px; }
.dmsg:hover { background: rgba(255,255,255,0.035); }
.dmsg__gutter { width: 38px; flex: 0 0 auto; display: flex; justify-content: center; }
.dmsg__gtime { font-size: 9.5px; color: var(--muted); opacity: 0; line-height: 1.5; align-self: flex-start; padding-top: 2px; }
.dmsg--grouped:hover .dmsg__gtime { opacity: 1; }
.dmsg__main { flex: 1 1 auto; min-width: 0; }
.dmsg__head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 2px; }
.dmsg__name { font-size: 13.5px; font-weight: 700; color: var(--text); }
.dmsg__time { font-size: 10.5px; color: var(--muted); flex: 0 0 auto; }
.dmsg__content { font-size: 13.5px; line-height: 1.4; color: var(--text); overflow-wrap: anywhere; }
.dmsg__txt { color: var(--text); }
.dmsg__quote { display: flex; align-items: center; gap: 5px; font-size: 11.5px; color: var(--text-2); margin: 0 0 3px; min-width: 0; }
.dmsg__quote .ic { width: 12px; height: 12px; flex: 0 0 auto; transform: scaleX(-1); }
.dmsg__quote b { color: var(--text); flex: 0 0 auto; }
.dmsg__quote span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0.85; }
.dmsg__deleted { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-style: italic; font-size: 12.5px; }
.dmsg__deleted .ic { width: 13px; height: 13px; }
/* voice + cash get a visible card in the bubble-less layout */
.dmsg__content .cmsg__voice { background: rgba(255,255,255,0.07); border: 1px solid var(--border); border-radius: 12px; padding: 7px 13px 7px 9px; }
.dmsg__content .cmsg__cash { margin-top: 2px; }
.dmsg__content .cmsg__img { margin-top: 3px; }
/* floating hover toolbar at the row's top-right (Discord pattern) */
.dmsg__acts { position: absolute; top: -12px; right: 12px; display: flex; align-items: center; gap: 1px; padding: 2px; border-radius: 9px;
  background: var(--raised-2); border: 1px solid var(--border); box-shadow: 0 6px 18px rgba(0,0,0,0.45); opacity: 0; transition: opacity .1s; z-index: 5; }
.dmsg:hover .dmsg__acts, .dmsg:focus-within .dmsg__acts { opacity: 1; }
.dmsg__acts button { width: 27px; height: 27px; border-radius: 7px; border: 0; background: none; color: var(--text-2); display: grid; place-items: center; cursor: pointer; }
.dmsg__acts button:hover { background: rgba(255,255,255,0.1); color: var(--text); }
.dmsg__acts .ic { width: 15px; height: 15px; }
.dmsg__acts button:focus-visible { outline: 2px solid var(--text); outline-offset: 1px; }
.cwin__body::-webkit-scrollbar { width: 7px; }
.cwin__body::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.13); border-radius: 4px; }
.cwin__body::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.22); }
.cmsg { max-width: 82%; flex: 0 0 auto; padding: 7px 11px; border-radius: 13px; font-size: 13px; line-height: 1.35; }
.cmsg.them { align-self: flex-start; background: var(--raised-2); color: var(--text); border-bottom-left-radius: 5px; }
.cmsg.me { align-self: flex-end; background: rgba(255,255,255,0.12); color: var(--text); font-weight: 500; border-bottom-right-radius: 5px; }
.cwin__composer { display: flex; align-items: center; gap: 8px; padding: 8px 9px 9px; border-top: 1px solid var(--hair); }
.cwin__composer input { flex: 1 1 auto; min-width: 0; background: var(--input-bg); border: 1px solid var(--border); border-radius: 9px; height: 34px; padding: 0 11px; color: var(--text); font-size: 13px; font-family: inherit; outline: none; }
.cwin__composer input:focus { border-color: #3a4140; }
.cwin__send { width: 34px; height: 34px; border-radius: 9px; background: var(--raised-2); color: var(--text); display: grid; place-items: center; cursor: pointer; flex: 0 0 auto; border: 1px solid var(--border); padding: 0; }
.cwin__send:hover { background: #222827; }
.cwin__send .ic { width: 16px; height: 16px; }
.cwin.min { border-radius: 12px 12px 0 0; }
.cwin.min .cwin__body, .cwin.min .cwin__composer { display: none; }

/* mobile-style composer: + / input / mic↔send, with voice & photo messages */
.cwin__composer { position: relative; }
.cwin__plus, .cwin__mic {
  width: 34px; height: 34px; border-radius: 9px; flex: 0 0 auto; padding: 0;
  display: grid; place-items: center; cursor: pointer;
  background: var(--raised-2); border: 1px solid var(--border); color: var(--text-2);
  transition: background .15s, color .15s;
}
.cwin__plus:hover, .cwin__mic:hover { background: #222827; color: var(--text); }
.cwin__plus .ic, .cwin__mic .ic { width: 17px; height: 17px; }
.cwin__mic.rec { background: rgba(255,68,88,0.22); border-color: rgba(255,68,88,0.4); color: var(--red); }

.cwin__rec {
  flex: 1 1 auto; display: flex; align-items: center; gap: 9px; height: 34px; padding: 0 11px;
  border-radius: 9px; background: rgba(255,68,88,0.1); border: 1px solid rgba(255,68,88,0.28);
  color: var(--text); font-size: 13px; font-weight: 600;
}
.cwin__recdot { width: 9px; height: 9px; border-radius: 999px; background: var(--red); flex: 0 0 auto; animation: cwinrec 1s ease-in-out infinite; }
@keyframes cwinrec { 50% { opacity: 0.3; } }
.cwin__rechint { margin-left: auto; font-size: 11px; color: var(--muted); font-weight: 500; }

/* voice + photo bubbles */
.cmsg--voice { padding: 6px 12px 6px 9px !important; }
.cmsg__voice { display: inline-flex; align-items: center; gap: 9px; border: 0; background: none; color: inherit; font: inherit; padding: 0; cursor: pointer; }
.cmsg__voice .ic { width: 18px; height: 18px; flex: 0 0 auto; }
.cmsg__voice:hover .ic { opacity: 0.82; }
.cmsg__wave { display: inline-flex; align-items: center; gap: 2px; height: 18px; flex: 0 0 auto; }
.cmsg__wave i { width: 2px; min-height: 3px; border-radius: 2px; background: currentColor; opacity: 0.34; transition: opacity .12s; }
.cmsg__wave i.on { opacity: 0.95; }
.cmsg__voice.playing .cmsg__wave i { animation: cwvwave 0.9s ease-in-out infinite; }
.cmsg__wave i:nth-child(2n) { animation-delay: .12s; }
.cmsg__wave i:nth-child(3n) { animation-delay: .26s; }
@keyframes cwvwave { 0%, 100% { transform: scaleY(0.55); } 50% { transform: scaleY(1); } }
.cmsg--photo { padding: 0 !important; background: none !important; border-radius: 14px !important; overflow: hidden; }
.cmsg__img { display: block; width: 164px; aspect-ratio: 4 / 5; border: 0; padding: 0; border-radius: 14px; background-size: cover; background-position: center; cursor: zoom-in; }
.cmsg__link { color: var(--blue); text-decoration: underline; text-underline-offset: 2px; word-break: break-all; }
.cmsg-time { font-size: 10.5px; color: var(--muted); margin: 1px 6px 0; }

/* full-photo lightbox (opens over the whole app) */
.cwin-lightbox { position: fixed; inset: 0; z-index: 500; display: grid; place-items: center; cursor: zoom-out; background: rgba(0,0,0,0.86); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.cwin-lightbox__img { width: min(82vw, 430px); aspect-ratio: 4 / 5; max-height: 86vh; border-radius: 18px; background-size: cover; background-position: center; box-shadow: 0 30px 80px rgba(0,0,0,0.7); }
.cwin-lightbox__x { position: fixed; top: 22px; right: 26px; width: 42px; height: 42px; border-radius: 999px; border: 0; cursor: pointer; background: rgba(255,255,255,0.14); color: #fff; display: grid; place-items: center; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.cwin-lightbox__x .ic { width: 20px; height: 20px; }

/* ===== full DM chat: message rows, hover actions, reply/edit/delete/react ===== */
.cmsg-row { display: flex; flex: 0 0 auto; }
.cmsg-row.me { justify-content: flex-end; }
.cmsg-row.them { justify-content: flex-start; }
.cmsg-col { display: flex; flex-direction: column; max-width: 84%; min-width: 0; }
.cmsg-row.me .cmsg-col { align-items: flex-end; }
.cmsg-col .cmsg { max-width: 100%; margin: 0; }

.cmsg-quote { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--text-2); margin: 0 6px 2px; max-width: 100%; }
.cmsg-quote .ic { width: 12px; height: 12px; flex: 0 0 auto; transform: scaleX(-1); }
.cmsg-quote b { color: var(--text); flex: 0 0 auto; }
.cmsg-quote span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0.85; }

.cmsg-hover { position: relative; display: flex; align-items: center; gap: 3px; }
.cmsg-row.me .cmsg-hover { flex-direction: row-reverse; }
.cmsg__txt { display: inline; }
.cmsg__edited { font-size: 10px; color: var(--muted); margin-left: 6px; }

.cmsg-acts { display: flex; align-items: center; gap: 1px; flex: 0 0 auto; opacity: 0; transition: opacity .12s; }
.cmsg-hover:hover .cmsg-acts, .cmsg-hover:focus-within .cmsg-acts { opacity: 1; }
.cmsg-acts button { width: 26px; height: 26px; border-radius: 999px; border: 0; background: none; color: var(--text-2); display: grid; place-items: center; cursor: pointer; }
.cmsg-acts button:hover { background: rgba(255,255,255,0.08); color: var(--text); }
.cmsg-acts .ic { width: 15px; height: 15px; }

.cmsg-pick { z-index: 600; display: flex; gap: 1px; padding: 4px; border-radius: 999px; background: var(--raised); border: 1px solid var(--border); box-shadow: 0 10px 26px rgba(0,0,0,0.55); }
.cmsg-popscrim { position: fixed; inset: 0; z-index: 590; }
.cmsg-row.them .cmsg-pick { left: 0; }
.cmsg-row.me .cmsg-pick { right: 0; }
.cmsg-pick button { width: 28px; height: 28px; border-radius: 999px; border: 0; background: none; font-size: 16px; line-height: 1; cursor: pointer; transition: transform .12s, background .12s; }
.cmsg-pick button:hover { background: rgba(255,255,255,0.1); transform: scale(1.18); }

.cmsg-menuscrim { position: fixed; inset: 0; z-index: 590; }
.cmsg-menu { z-index: 600; min-width: 138px; display: flex; flex-direction: column; gap: 1px; padding: 5px; border-radius: 12px; background: var(--raised); border: 1px solid var(--border); box-shadow: 0 14px 32px rgba(0,0,0,0.55); }
.cmsg-row.them .cmsg-menu { left: 0; }
.cmsg-row.me .cmsg-menu { right: 0; }
.cmsg-menu button { display: flex; align-items: center; gap: 10px; padding: 8px 11px; border-radius: 9px; border: 0; background: none; color: var(--text); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; text-align: left; }
.cmsg-menu button:hover { background: var(--raised-2); }
.cmsg-menu button .ic { width: 15px; height: 15px; color: var(--text-2); flex: 0 0 auto; }
.cmsg-menu button.danger { color: var(--red); }
.cmsg-menu button.danger .ic { color: var(--red); }

.cmsg--deleted { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-style: italic; background: transparent !important; border: 1px dashed var(--border); }
.cmsg--deleted .ic { width: 13px; height: 13px; }

.cmsg-reacts { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 4px 0; }
.cmsg-react { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); background: var(--raised-2); color: var(--text-2); font-size: 11px; font-weight: 700; cursor: pointer; }
.cmsg-react.on { background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.3); color: var(--text); }

/* reply / edit context bar above the composer */
.cwin__contextbar { display: flex; align-items: center; gap: 8px; padding: 7px 11px; font-size: 12px; color: var(--text-2); border-top: 1px solid var(--hair); background: rgba(255,255,255,0.03); }
.cwin__ctxic { display: grid; flex: 0 0 auto; }
.cwin__ctxic .ic { width: 14px; height: 14px; }
.cwin__contextbar:not(.cwin__contextbar--edit) .cwin__ctxic .ic { transform: scaleX(-1); }
.cwin__ctxtxt { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cwin__contextbar b { color: var(--text); }
.cwin__contextbar button { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 999px; border: 0; background: none; color: var(--text-2); display: grid; place-items: center; cursor: pointer; }
.cwin__contextbar button:hover { color: var(--text); background: rgba(255,255,255,0.08); }
.cwin__contextbar button .ic { width: 13px; height: 13px; }

/* empty thread state */
.cwin__empty { margin: auto; color: var(--muted); font-size: 14px; font-weight: 500; }
/* visible keyboard focus across the chat (mouse clicks unaffected) */
.cwin__plus:focus-visible, .cwin__mic:focus-visible, .cwin__send:focus-visible,
.cwin__composer input:focus-visible, .cmsg-acts button:focus-visible,
.cmsg-menu button:focus-visible, .cmsg-pick button:focus-visible,
.cmsg-react:focus-visible, .cmsg__img:focus-visible, .cwin-lightbox__x:focus-visible {
  outline: 2px solid var(--text); outline-offset: 2px;
}

/* attach popover */
.cwin__attachscrim { position: fixed; inset: 0; z-index: 1; }
.cwin__attach {
  position: absolute; left: 9px; bottom: 50px; z-index: 2; min-width: 132px;
  display: flex; flex-direction: column; gap: 2px; padding: 5px; border-radius: 12px;
  background: var(--raised); border: 1px solid var(--border); box-shadow: 0 12px 30px rgba(0,0,0,0.5);
}
.cwin__attach button {
  display: flex; align-items: center; gap: 9px; padding: 9px 11px; border-radius: 9px;
  border: 0; background: none; color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; text-align: left;
}
.cwin__attach button:hover { background: var(--raised-2); }
.cwin__attach button .ic { width: 16px; height: 16px; color: var(--text-2); flex: 0 0 auto; }
.cwin__attachcash { display: grid; place-items: center; flex: 0 0 auto; }
.cwin__attachcash .ic { color: var(--green) !important; }

/* inline cash transfer card */
.cmsg--cash { padding: 0 !important; background: none !important; border: 0 !important; }
.cmsg__cash { display: inline-flex; align-items: center; gap: 11px; min-width: 158px; padding: 11px 14px; border-radius: 14px;
  background: linear-gradient(160deg, rgba(74,222,128,0.18), rgba(74,222,128,0.05)); border: 1px solid rgba(74,222,128,0.32); }
.cmsg__cashic { width: 32px; height: 32px; border-radius: 999px; display: grid; place-items: center; flex: 0 0 auto; background: rgba(74,222,128,0.2); color: var(--green); }
.cmsg__cashic .ic { width: 18px; height: 18px; }
.cmsg__cashcol { display: flex; flex-direction: column; gap: 1px; }
.cmsg__cashlbl { font-size: 10px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--text-2); }
.cmsg__cashamt { font-size: 15.5px; font-weight: 800; color: var(--green); }

/* send-cash amount modal */
.cwin-cashmodal { position: fixed; inset: 0; z-index: 520; display: grid; place-items: center; background: rgba(0,0,0,0.62); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.cwin__cash { width: min(92vw, 322px); border-radius: 18px; padding: 16px; display: flex; flex-direction: column; gap: 13px;
  background: var(--raised); border: 1px solid var(--border); box-shadow: 0 30px 72px rgba(0,0,0,0.7); }
.cwin__cashhd { display: flex; align-items: center; gap: 8px; }
.cwin__cashtitle { flex: 1 1 auto; min-width: 0; font-size: 15px; font-weight: 800; color: var(--text); }
.cwin__cashx { width: 28px; height: 28px; border-radius: 999px; border: 0; flex: 0 0 auto; cursor: pointer; display: grid; place-items: center; background: var(--fill); color: var(--text-2); }
.cwin__cashx:hover { background: var(--fill-hover); color: var(--text); }
.cwin__cashx .ic { width: 15px; height: 15px; }
.cwin__cashin { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 13px; background: rgba(74,222,128,0.08); border: 1px solid rgba(74,222,128,0.28); }
.cwin__cashsym { display: grid; flex: 0 0 auto; color: var(--green); }
.cwin__cashsym .ic { width: 22px; height: 22px; }
.cwin__cashin input { flex: 1 1 auto; min-width: 0; width: 100%; background: none; border: 0; outline: none; color: var(--text); font-size: 26px; font-weight: 800; font-family: inherit; }
.cwin__cashchips { display: flex; gap: 7px; }
.cwin__cashchips button { flex: 1 1 0; padding: 9px 0; border-radius: 10px; cursor: pointer; font-family: inherit; font-size: 13px; font-weight: 700;
  border: 1px solid var(--border); background: var(--raised-2); color: var(--text-2); }
.cwin__cashchips button:hover { background: var(--fill-hover); color: var(--text); }
.cwin__cashchips button.on { border-color: rgba(74,222,128,0.5); background: rgba(74,222,128,0.12); color: var(--green); }
.cwin__cashbal { text-align: center; font-size: 12px; color: var(--text-2); }
.cwin__cashsend { display: flex; align-items: center; justify-content: center; gap: 8px; height: 46px; border-radius: 13px; border: 0; cursor: pointer;
  font-family: inherit; font-size: 14.5px; font-weight: 800; color: var(--green-ink); background: var(--green); }
.cwin__cashsend:hover { filter: brightness(1.06); }
.cwin__cashsend:disabled { opacity: 0.4; cursor: not-allowed; filter: none; }
.cwin__cashsend .ic { width: 18px; height: 18px; }

/* ---- mobile: contain the live strip; polish messages ---- */
.m3 .strip { margin: 12px; padding: 12px 0 12px 12px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); }
.m3 .striphead { padding-right: 12px; }
.m3 .mstream { padding: 6px 6px 4px; }
.m3 .mstream .msg { padding: 7px 12px; border-radius: 11px; }
.m3 .mstream .sysmsg { margin: 4px 10px; padding: 8px 12px; border-radius: 11px; background: rgba(190,56,243,0.08); border: 1px solid rgba(190,56,243,0.2); }

.chat { position: relative; --newmsgbar-top: 64px; }
.chat--sheet { --newmsgbar-top: 12px; }
.stream { flex: 1 1 auto; min-height: 0; overflow-y: auto; overflow-x: hidden; padding: 14px 0 6px; overscroll-behavior: contain; }
.newmsgbar {
  position: absolute;
  left: 10px;
  right: 10px;
  top: var(--newmsgbar-top);
  z-index: 35;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 13px 0 16px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px;
  background: linear-gradient(90deg, #5865F2, #6D5BFF);
  color: #fff;
  box-shadow: 0 12px 30px rgba(0,0,0,0.42);
  font: inherit;
  font-size: 12.5px;
  font-weight: 760;
  letter-spacing: -0.01em;
  cursor: pointer;
}
.newmsgbar:hover { filter: brightness(1.04); }
.newmsgbar b {
  flex: 0 0 auto;
  color: #fff;
  font-size: 12px;
  font-weight: 850;
}
.newmsgbar span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.welcome { padding: 10px 18px 16px; }
.welcome .ball { width: 56px; height: 56px; border-radius: 17px; background: var(--raised-2); color: var(--text-2); display: grid; place-items: center; margin-bottom: 12px; }
.welcome .ball .ic { width: 28px; height: 28px; }
.welcome h3 { margin: 0 0 5px; font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.welcome p { margin: 0; color: var(--text-2); font-size: 14px; }

.msg { display: flex; gap: 14px; padding: 5px 18px; position: relative; }
.msg:hover { background: rgba(255,255,255,0.022); }
.msg__av { flex: 0 0 auto; margin-top: 2px; }
.msg__body { min-width: 0; flex: 1 1 auto; }
.msg { position: relative; }
/* mention / reply-to-you — yellow highlight (clear, intentional signal) */
.msg--mention { background: rgba(242,210,74,0.06); }
.msg--mention:hover { background: rgba(242,210,74,0.09); }
.msg--mention::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--gold); }
.mention { color: var(--text); background: var(--fill); border-radius: 5px; padding: 0 4px; font-weight: 600; }
.mention--self { color: var(--gold); background: rgba(242,210,74,0.15); font-weight: 700; }
.msg__head { display: flex; align-items: baseline; gap: 9px; margin-bottom: 3px; }
.msg__name { font-weight: 700; font-size: 14.5px; }
.msg__time { font-size: 11px; color: var(--muted); font-weight: 500; white-space: nowrap; }
.msg__actions { margin-left: auto; display: flex; gap: 2px; opacity: 0; transition: opacity .12s; }
.msg:hover .msg__actions { opacity: 1; }
.msg__actions button { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; background: var(--raised); border: 1px solid var(--border); color: var(--text-2); cursor: pointer; }
.msg__actions button:hover { background: var(--raised-2); color: var(--text); }
.msg__actions .ic { width: 15px; height: 15px; }
.msg__quote { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; font-size: 12px; color: var(--muted); }
.msg__quote .ic { width: 13px; height: 13px; flex: 0 0 auto; }
.msg__quote b { color: var(--text-2); font-weight: 600; }
.msg__quote span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 220px; }
.msg__line { font-size: 14.5px; line-height: 1.46; color: #e2e8e4; }
.reacts { display: flex; gap: 6px; margin-top: 7px; flex-wrap: wrap; }
.react { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; background: var(--raised); border: 1px solid var(--border); font-size: 12px; font-weight: 700; color: var(--text-2); cursor: pointer; }
.react:hover { background: var(--raised-2); }
.react .e { font-size: 13px; } .react.on { background: var(--raised-2); border-color: #3a4140; color: var(--text); }

/* long-press / right-click message menu */
.msgmenu-scrim { position: fixed; inset: 0; z-index: 70; }
.msgmenu { position: absolute; left: 54px; top: 100%; z-index: 71; margin-top: -6px; background: var(--raised-2); border: 1px solid var(--border); border-radius: 12px; padding: 6px; box-shadow: 0 16px 44px rgba(0,0,0,0.6); min-width: 180px; }
.msgmenu__quick { display: flex; gap: 2px; padding: 2px 2px 6px; border-bottom: 1px solid var(--divider); margin-bottom: 4px; }
.msgmenu__quick button { width: 34px; height: 34px; border-radius: 8px; background: none; border: 0; font-size: 17px; cursor: pointer; }
.msgmenu__quick button:hover { background: var(--raised); }
.msgmenu__row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 9px; border-radius: 8px; background: none; border: 0; color: var(--text); font-size: 13.5px; font-weight: 600; font-family: inherit; text-align: left; cursor: pointer; }
.msgmenu__row:hover { background: var(--raised); }
.msgmenu__row .ic { width: 17px; height: 17px; color: var(--text-2); }

/* reply bar above composer */
.replybar { display: flex; align-items: center; gap: 9px; margin: 0 18px; padding: 8px 12px; background: var(--raised); border: 1px solid var(--border); border-bottom: 0; border-radius: 11px 11px 0 0; font-size: 13px; color: var(--text-2); }
.replybar .ic { width: 15px; height: 15px; flex: 0 0 auto; }
.replybar b { color: var(--text); font-weight: 700; }
.replybar button { margin-left: auto; width: 24px; height: 24px; border-radius: 7px; display: grid; place-items: center; background: none; border: 0; color: var(--muted); cursor: pointer; }
.replybar button:hover { background: var(--raised-2); color: var(--text); }
.replybar button .ic { width: 14px; height: 14px; }
.stage .replybar { margin: 0 10px; }

.sysmsg { display: flex; align-items: center; gap: 11px; padding: 8px 18px; font-size: 13px; color: var(--text-2); }
.sysmsg .ic { width: 17px; height: 17px; flex: 0 0 auto; }
.sysmsg b { color: var(--text); font-weight: 600; }
.sysmsg.gift, .sysmsg.gift .ic { color: var(--purple); }
.sysmsg.live, .sysmsg.live .ic { color: var(--red); }
.sysmsg .pill2 { font-weight: 700; }

.composer { flex: 0 0 auto; padding: 6px 18px 18px; }
.cbox { display: flex; align-items: center; gap: 12px; background: var(--raised); border-radius: 13px; padding: 0 8px 0 14px; height: 48px; }
.cbox .gplus { width: 26px; height: 26px; border-radius: 999px; background: var(--fill); display: grid; place-items: center; color: var(--text-2); flex: 0 0 auto; }
.cbox .gplus .ic { width: 16px; height: 16px; }
.cbox input { flex: 1 1 auto; min-width: 0; background: none; border: 0; outline: none; color: var(--text); font-size: 14.5px; font-family: inherit; }
.cbox input::placeholder { color: var(--muted); }
.cbox .ctools { display: flex; align-items: center; gap: 2px; }
.cbox .ct { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); cursor: pointer; }
.cbox .ct:hover { background: var(--fill); color: var(--text); }
.cbox .ct .ic { width: 19px; height: 19px; }
.cbox .send { width: 36px; height: 36px; border-radius: 9px; background: var(--raised-2); color: var(--text); display: grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--border); padding: 0; cursor: pointer; }
.cbox .send:hover { background: #222827; }
.cbox .send .ic { width: 17px; height: 17px; }

/* ---------- MEMBER list (right) ---------- */
.mlist { width: 244px; flex: 0 0 auto; background: var(--side-bg); border-left: 1px solid var(--hair); padding: 12px 10px; overflow: hidden; }

/* minimize / expand toggle */
.mlist__min {
  margin-left: auto; width: 28px; height: 28px; border-radius: 9px; flex: 0 0 auto;
  background: var(--fill, rgba(255,255,255,0.06)); border: 1px solid var(--border);
  display: grid; place-items: center; color: var(--text-2); cursor: pointer;
  transition: background .12s, color .12s;
}
.mlist__min:hover { background: rgba(255,255,255,0.10); color: var(--text); }
.mlist__min .ic { width: 14px; height: 14px; }

/* minimized: avatar-only rail, like the app rail */
.mlist.mlist--min { width: 72px !important; padding: 12px 8px; }
.mlist.mlist--min .mlist__head { justify-content: center; padding: 4px 0 10px; margin-bottom: 4px; }
.mlist.mlist--min .mlist__min { margin: 0 auto; }
.mlist.mlist--min .gl, .stage .mlist.mlist--min .gl {
  font-size: 0; line-height: 0; height: 1px; padding: 0; margin: 9px 12px 7px;
  background: var(--hair); border-radius: 1px; overflow: hidden;
}
.mlist.mlist--min .frow { justify-content: center; padding: 5px 0; gap: 0; }
.mlist.mlist--min .frow .fnm { display: none; }
.mlist .gl { font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); padding: 13px 8px 6px; }
.mlist .gl:first-child { padding-top: 4px; }
.mlist__head { display: flex; align-items: center; gap: 9px; padding: 4px 8px 12px; margin-bottom: 2px; border-bottom: 1px solid var(--hair); }
.mlist__head .ic { width: 18px; height: 18px; color: var(--text-2); flex: 0 0 auto; }
.mlist__head h3 { margin: 0; font-size: 15px; font-weight: 800; letter-spacing: -0.01em; }
.mlist__head .cnt { font-size: 12.5px; color: var(--muted); font-weight: 700; }
.mlist__head .add { margin-left: auto; width: 30px; height: 30px; border-radius: 8px; background: var(--fill); border: 1px solid var(--border); display: grid; place-items: center; color: var(--text-2); cursor: pointer; transition: background .15s, color .15s; }
.mlist__head .add:hover { background: var(--fill-hover); color: var(--text); }
.mlist__head .add .ic { width: 16px; height: 16px; color: var(--text-2); }
.mem { display: flex; align-items: center; gap: 11px; padding: 6px 8px; border-radius: 8px; cursor: pointer; transition: background .12s; }
.mem:hover { background: var(--raised); }
.mem > div { min-width: 0; }
.mem .nm { font-size: 13.5px; font-weight: 600; color: var(--text); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mem .act { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mem .act .lz { color: var(--red); font-weight: 700; }
.mem.off { opacity: 0.4; }

/* ============================================================
   MOBILE — global chat screen
   ============================================================ */
.m3 { height: 100%; display: flex; flex-direction: column; background: var(--main-bg); position: relative; overflow: hidden; }
.m3 .menubtn { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: var(--text); background: none; border: 0; cursor: pointer; margin-left: -4px; flex: 0 0 auto; }
.m3 .menubtn:hover { background: var(--raised); }
.m3 .menubtn .ic { width: 22px; height: 22px; }
.m3 .mdrawer-scrim { position: absolute; inset: 0; background: rgba(0,0,0,0.55); display: none; z-index: 40; }
.m3 .mdrawer-scrim.open { display: block; }
.m3 .mdrawer { position: absolute; top: 0; left: 0; bottom: 0; width: 72px; display: flex; transform: translateX(-100%); z-index: 41; box-shadow: 0 16px 50px rgba(0,0,0,0.55); }
.m3 .mdrawer.open { transform: translateX(0); }
.m3 .top { height: 54px; flex: 0 0 auto; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-bottom: 1px solid var(--hair); }
.m3 .top .hash { color: var(--muted); display: grid; place-items: center; } .m3 .top .hash .ic { width: 19px; height: 19px; }
.m3 .top h2 { margin: 0; font-size: 16px; font-weight: 700; }
.m3 .top .acts { margin-left: auto; display: flex; gap: 4px; }
.m3 .top .ib { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); position: relative; } .m3 .top .ib .ic { width: 19px; height: 19px; }
.m3 .top .reddot { position: absolute; top: 4px; right: 5px; width: 8px; height: 8px; border-radius: 999px; background: var(--red); box-shadow: 0 0 0 2px var(--main-bg); }
.m3 .strip { flex: 0 0 auto; padding: 12px 0 12px 14px; border-bottom: 1px solid var(--hair); overflow: hidden; }
.m3 .strip .lbl { font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); margin-bottom: 11px; display: flex; align-items: center; gap: 6px; }
.m3 .striphead { display: flex; align-items: center; justify-content: space-between; padding-right: 14px; margin-bottom: 11px; }
.m3 .striphead .lbl { margin-bottom: 0; }
.m3 .mgolive { height: 28px; padding: 0 13px; border-radius: 8px; background: var(--red); color: #fff; font-size: 11.5px; font-weight: 800; letter-spacing: 0.01em; border: 0; cursor: pointer; white-space: nowrap; flex: 0 0 auto; }
.m3 .mgolive:active { transform: translateY(1px); }
.m3 .strip .lbl i { width: 7px; height: 7px; border-radius: 999px; background: var(--red); }
.m3 .strip .track { display: flex; gap: 14px; }
.m3 .av-strip { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 62px; flex: 0 0 auto; }
.m3 .av-strip .nm { font-size: 11px; font-weight: 600; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; text-align: center; }
.m3 .thumb-strip { width: 150px; flex: 0 0 auto; }
.m3 .thumb-strip .thumb { height: 84px; border-radius: 11px; position: relative; overflow: hidden; }
.m3 .thumb-strip .thumb .top2 { position: absolute; top: 7px; left: 7px; right: 7px; display: flex; justify-content: space-between; z-index: 2; }
.m3 .thumb-strip .ti { font-size: 12px; font-weight: 600; margin-top: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m3 .mstream { flex: 1 1 auto; overflow: hidden; padding: 12px 0 4px; }
.m3 .composer { padding: 8px 12px 12px; }
.m3 .tabbar { height: 60px; flex: 0 0 auto; display: grid; grid-template-columns: repeat(4,1fr); align-items: center; background: var(--side-bg); border-top: 1px solid var(--hair); }
.m3 .tb .ibell { position: relative; display: inline-grid; place-items: center; }
.m3 .tb .tdot { position: absolute; top: -2px; right: -4px; width: 8px; height: 8px; border-radius: 999px; background: var(--red); box-shadow: 0 0 0 2px var(--side-bg); }
.m3 .tb .tbadge { position: absolute; top: -7px; right: -9px; min-width: 15px; height: 15px; padding: 0 4px; border-radius: 999px; background: var(--red); color: #fff; font-size: 9px; font-weight: 700; line-height: 15px; text-align: center; box-shadow: 0 0 0 2px var(--side-bg); }
.m3 .tb { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--muted); font-size: 10px; font-weight: 600; position: relative; } .m3 .tb .ic { width: 23px; height: 23px; } .m3 .tb.on { color: var(--green); }
.m3 .tb .plus { width: 42px; height: 31px; border-radius: 11px; background: var(--green); color: var(--green-ink); display: grid; place-items: center; }
.m3 .tb .bd { position: absolute; top: -2px; right: 16px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--red); color: #fff; font-size: 9.5px; font-weight: 700; line-height: 16px; text-align: center; }
