/* Launcher theme tokens and the social UI. Dark by default; html.ls-light
   switches to the light theme. Shared by the launcher and game overlays. */
:root {
  --ls-bg: #0b1016;
  --ls-bg2: #10161e;
  --ls-panel: #141b24;
  --ls-panel2: #1a232f;
  --ls-panel3: #243041;
  --ls-hover: rgba(148, 196, 240, 0.07);
  --ls-active: rgba(102, 192, 244, 0.15);
  --ls-line: #212c39;
  --ls-text: #c9d5e0;
  --ls-strong: #f4f7fa;
  --ls-muted: #8191a3;
  --ls-accent: #66c0f4;
  --ls-accent2: #1a9fff;
  --ls-on-accent: #06121c;
  --ls-green: #5c9e1f;
  --ls-green2: #75b022;
  --ls-red: #d9443f;
  --ls-yellow: #e5b33a;
  --ls-mention: rgba(229, 179, 58, 0.1);
  --ls-mention-line: #e5b33a;
  --ls-shadow: 0 16px 48px rgba(0, 0, 0, 0.55), 0 2px 6px rgba(0, 0, 0, 0.3);
  --ls-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --ls-font: "Inter Variable", "Segoe UI", "Noto Sans", system-ui, -apple-system, Arial, sans-serif;
  --ls-radius: 8px;
  --ls-ring: 0 0 0 3px rgba(102, 192, 244, 0.28);
}
html.ls-light {
  --ls-bg: #e9edf2;
  --ls-bg2: #f2f4f7;
  --ls-panel: #ffffff;
  --ls-panel2: #f4f6f9;
  --ls-panel3: #e6ebf1;
  --ls-hover: rgba(23, 105, 170, 0.07);
  --ls-active: rgba(23, 105, 170, 0.14);
  --ls-line: #d5dce5;
  --ls-text: #29343f;
  --ls-strong: #0d1620;
  --ls-muted: #66737f;
  --ls-accent: #1769aa;
  --ls-accent2: #1769aa;
  --ls-on-accent: #ffffff;
  --ls-mention: rgba(229, 179, 58, 0.16);
  --ls-shadow: 0 12px 40px rgba(20, 30, 45, 0.18);
}

.ls-theme, .ls-social, .ls-modal-back, .ls-pop, .ls-toasts, .ls-fab, .ls-tip, .ls-emoji-picker { font-family: var(--ls-font); color: var(--ls-text); font-feature-settings: "cv11", "ss01"; }
.ls-svg { flex: none; display: block; }
.ls-social *, .ls-modal-back *, .ls-pop *, .ls-toasts *, .ls-fab * { box-sizing: border-box; }
.ls-social button, .ls-modal-back button, .ls-pop button, .ls-toasts button, .ls-fab { font: inherit; }
.ls-grow { flex: 1; min-width: 0; }
.ls-ell { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ls-click { cursor: pointer; }
.ls-sub { color: var(--ls-muted); font-size: 12.5px; }
.ls-name { font-weight: 600; color: var(--ls-strong); }
.ls-row { display: flex; align-items: center; gap: 10px; }
.ls-row-gap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ls-empty { padding: 40px 20px; text-align: center; color: var(--ls-muted); }
[hidden] { display: none !important; }

/* buttons */
.ls-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 16px; border: 0; border-radius: 6px;
  background: linear-gradient(180deg, #2aa8ff, #1577d0); color: #fff; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 1px 2px rgba(0, 0, 0, 0.35); transition: filter 0.12s, transform 0.06s; }
.ls-btn:active:not(:disabled) { transform: translateY(1px); }
.ls-btn:focus-visible, .ls-icon:focus-visible, .ls-round:focus-visible, .ls-chip:focus-visible { outline: none; box-shadow: var(--ls-ring); }
html.ls-light .ls-btn { background: var(--ls-accent); }
.ls-btn:hover { filter: brightness(1.12); }
.ls-btn:disabled { opacity: 0.5; cursor: default; filter: none; }
.ls-btn.grey { background: var(--ls-panel3); color: var(--ls-strong); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05); }
.ls-btn.green { background: linear-gradient(180deg, #82c42a, #4f9419); color: #fff; }
.ls-btn.red { background: linear-gradient(180deg, #e65450, #c23631); color: #fff; }
.ls-btn.small { padding: 5px 11px; font-size: 13px; border-radius: 5px; }
.ls-btn.wide { width: 100%; margin-top: 8px; }
.ls-link { background: none; border: 0; padding: 0; color: var(--ls-accent); cursor: pointer; }
.ls-link:hover { text-decoration: underline; }
.ls-icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border: 0; border-radius: 6px;
  background: none; color: var(--ls-muted); cursor: pointer; transition: background 0.12s, color 0.12s; }
.ls-icon:hover, .ls-icon.on { background: var(--ls-hover); color: var(--ls-strong); }
.ls-icon.danger { color: var(--ls-red); }
.ls-icon.danger:hover { background: rgba(217, 68, 63, 0.14); color: #ff6b66; }
.ls-round { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border: 0; border-radius: 50%;
  background: var(--ls-bg2); color: var(--ls-muted); cursor: pointer; transition: background 0.12s, color 0.12s; }
.ls-round:hover { color: var(--ls-strong); background: var(--ls-panel3); }
.ls-round.ok:hover { background: var(--ls-green); color: #fff; }
.ls-round.warn:hover { background: var(--ls-red); color: #fff; }
.ls-x { flex: none; display: inline-flex; align-items: center; justify-content: center; border: 0; background: none; color: var(--ls-muted); cursor: pointer; padding: 4px; border-radius: 5px; }
.ls-x:hover { color: var(--ls-strong); background: var(--ls-hover); }
.ls-input { width: 100%; padding: 9px 12px; border: 1px solid var(--ls-line); border-radius: 6px; background: var(--ls-bg); color: var(--ls-strong); font: inherit; outline: none; transition: border-color 0.12s, box-shadow 0.12s; }
.ls-input::placeholder { color: #66768a; }
.ls-input:focus { border-color: var(--ls-accent); box-shadow: var(--ls-ring); }
.ls-input:disabled { opacity: 0.6; }
textarea.ls-input { resize: vertical; }
.ls-pill { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--ls-red); color: #fff; font: 700 11px/18px var(--ls-font); text-align: center; }
.ls-pill.inline { flex: none; }
.ls-tab { padding: 5px 11px; border: 0; border-radius: 6px; background: none; color: var(--ls-muted); font-weight: 600; cursor: pointer; white-space: nowrap; }
.ls-tab:hover { background: var(--ls-hover); color: var(--ls-text); }
.ls-tab.on { background: var(--ls-active); color: var(--ls-strong); }
.ls-tab.add { background: var(--ls-green); color: #fff; }
.ls-tab.add.on { background: none; color: var(--ls-green2); }
.ls-seg { display: flex; flex-wrap: wrap; gap: 4px; }
.ls-seg-btn { padding: 7px 14px; border: 1px solid var(--ls-line); border-radius: 6px; background: var(--ls-bg); color: var(--ls-text); cursor: pointer; }
.ls-seg-btn.on { background: var(--ls-active); border-color: var(--ls-accent); color: var(--ls-strong); }
.ls-sect { display: flex; align-items: center; gap: 6px; padding: 16px 8px 6px; color: var(--ls-muted); font: 700 11px var(--ls-font); text-transform: uppercase; letter-spacing: 0.06em; }
.ls-sect-btn { margin-left: auto; display: inline-flex; border: 0; background: none; color: var(--ls-muted); cursor: pointer; padding: 2px; border-radius: 4px; }
.ls-sect-btn:hover { color: var(--ls-strong); }

/* avatars */
.ls-av { position: relative; flex: none; border-radius: 50%; }
.ls-av img, .ls-av-letter { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; }
.ls-av.speaking img, .ls-av.speaking .ls-av-letter { box-shadow: 0 0 0 2px var(--ls-panel), 0 0 0 4px var(--ls-green2); }
.ls-dot { position: absolute; right: -2px; bottom: -2px; width: 34%; height: 34%; min-width: 10px; min-height: 10px; max-width: 16px; max-height: 16px; border-radius: 50%; border: 3px solid var(--ls-panel); }
.ls-dot.static { position: static; flex: none; width: 10px; height: 10px; min-width: 0; min-height: 0; border: 0; margin-top: 4px; }
.ls-online { background: #4cb944; }
.ls-away { background: var(--ls-yellow); }
.ls-dnd { background: var(--ls-red); }
.ls-offline, .ls-invisible { background: #7d8792; }
.ls-sicon { flex: none; border-radius: 30%; object-fit: cover; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 15px; }

/* layout */
.ls-social { container-type: inline-size; display: grid; grid-template-columns: 72px 240px minmax(0, 1fr) 240px; height: 100%; min-height: 0;
  background: var(--ls-panel); position: relative; overflow: hidden; font-size: 14.5px; line-height: 1.4; }
.ls-social.no-members { grid-template-columns: 72px 240px minmax(0, 1fr); }
.ls-social.no-members .ls-members { display: none; }
.ls-rail { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 0; background: var(--ls-bg); overflow-y: auto; scrollbar-width: none; }
.ls-rail-item { position: relative; cursor: pointer; display: flex; }
.ls-rail-item > .ls-sicon, .ls-home-icon { width: 44px; height: 44px; border-radius: 50%; transition: border-radius 0.15s, background 0.15s; }
.ls-rail-item:hover > .ls-sicon, .ls-rail-item.on > .ls-sicon, .ls-rail-item:hover .ls-home-icon, .ls-rail-item.on .ls-home-icon { border-radius: 30%; }
.ls-home-icon { display: flex; align-items: center; justify-content: center; background: var(--ls-panel2); color: var(--ls-accent); }
.ls-rail-item.on .ls-home-icon, .ls-rail-item:hover .ls-home-icon { background: linear-gradient(135deg, #2a3a4f, #1b2634); }
.ls-rail-add .ls-home-icon { color: var(--ls-green2); }
.ls-rail-add:hover .ls-home-icon { background: var(--ls-green); color: #fff; }
.ls-rail-item::before { content: ""; position: absolute; left: -14px; top: 50%; width: 4px; height: 0; border-radius: 0 4px 4px 0; background: var(--ls-strong); transform: translateY(-50%); transition: height 0.15s; }
.ls-rail-item.unread::before { height: 8px; }
.ls-rail-item:hover::before { height: 20px; }
.ls-rail-item.on::before { height: 36px; }
.ls-rail-item .ls-pill { position: absolute; right: -4px; bottom: -4px; border: 3px solid var(--ls-bg); height: 22px; line-height: 16px; border-radius: 11px; }
.ls-rail-sep { width: 32px; height: 2px; border-radius: 1px; background: var(--ls-line); flex: none; }

.ls-side { display: flex; flex-direction: column; min-height: 0; background: var(--ls-bg2); }
.ls-side-head { display: flex; align-items: center; gap: 8px; height: 52px; flex: none; padding: 0 14px; border-bottom: 1px solid var(--ls-line); color: var(--ls-strong); box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); font-size: 15px; }
.ls-side-head.ls-click:hover { background: var(--ls-hover); }
.ls-side-list { flex: 1; overflow-y: auto; padding: 8px; }
.ls-side-row { display: flex; align-items: center; gap: 10px; padding: 6px 8px; margin: 1px 0; border-radius: 6px; color: var(--ls-muted); cursor: pointer; min-height: 36px; transition: background 0.1s, color 0.1s; }
.ls-side-row:hover { background: var(--ls-hover); color: var(--ls-text); }
.ls-side-row.on { background: var(--ls-active); color: var(--ls-strong); }
.ls-side-row.unread { color: var(--ls-strong); font-weight: 600; }
.ls-side-row.danger { color: var(--ls-red); }
.ls-side-row.ls-dm { min-height: 42px; }
.ls-side-icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 20px; color: var(--ls-muted); }
.ls-side-note { padding: 10px 8px; color: var(--ls-muted); font-size: 13px; }
.ls-row-gear { display: none; border: 0; background: none; color: var(--ls-muted); cursor: pointer; padding: 2px; border-radius: 4px; }
.ls-side-row:hover .ls-row-gear { display: inline-flex; }
.ls-row-gear:hover { color: var(--ls-strong); }
.ls-voice-member { display: flex; align-items: center; gap: 8px; padding: 3px 8px 3px 34px; border-radius: 4px; color: var(--ls-muted); cursor: pointer; font-size: 13.5px; }
.ls-voice-member:hover { background: var(--ls-hover); color: var(--ls-text); }
.ls-ic { display: inline-flex; color: var(--ls-muted); }
.ls-ic.red { color: var(--ls-red); }
.ls-row-ic { display: inline-flex; align-items: center; gap: 5px; }
.ls-row-ic .ls-svg { color: var(--ls-red); }
.ls-crown { display: inline-flex; margin-left: 5px; color: #f0b232; vertical-align: -1px; }
.ls-pinned-ic { display: inline-flex; color: var(--ls-yellow); }

.ls-voice-panel { flex: none; border-top: 1px solid var(--ls-line); background: var(--ls-bg); }
.ls-voice-panel:empty { display: none; }
.ls-voice-top { display: flex; align-items: center; gap: 8px; padding: 8px 10px; }
.ls-voice-ok { color: var(--ls-green2); font-weight: 700; font-size: 13.5px; }
.ls-voice-note { padding: 0 10px 8px; color: var(--ls-yellow); font-size: 12.5px; }
.ls-voice-err { display: flex; gap: 6px; align-items: flex-start; padding: 8px 10px; color: var(--ls-red); font-size: 13px; }
.ls-user-panel { position: relative; flex: none; display: flex; align-items: center; gap: 0; padding: 8px; background: var(--ls-bg); border-top: 1px solid var(--ls-line); }
.ls-user-panel .ls-icon { width: 32px; height: 32px; }
.ls-user-who { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; padding: 3px 6px 3px 3px; border-radius: 6px; line-height: 1.25; }
.ls-user-who:hover { background: var(--ls-hover); }
.ls-menu { position: absolute; z-index: 20; min-width: 240px; padding: 6px; background: var(--ls-bg); border: 1px solid var(--ls-line); border-radius: 10px; box-shadow: var(--ls-shadow); }
.ls-menu.static { position: static; box-shadow: none; border: 0; padding: 0; background: none; }
.ls-status-menu { left: 8px; bottom: 100%; margin-bottom: 6px; }
.ls-menu-item { display: flex; gap: 10px; align-items: center; width: 100%; padding: 8px 10px; border: 0; border-radius: 6px; background: none; color: var(--ls-text); text-align: left; cursor: pointer; }
.ls-menu-item .ls-svg { color: var(--ls-muted); }
.ls-menu-item:hover .ls-svg { color: inherit; }
.ls-menu-item.accent { color: var(--ls-accent); }
.ls-menu-item:hover { background: var(--ls-accent2); color: #fff; }
.ls-menu-item:hover .ls-sub { color: #e8f2ff; }
.ls-menu-item.danger { color: var(--ls-red); }
.ls-menu-item.danger:hover { background: var(--ls-red); color: #fff; }

.ls-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--ls-panel); }
.ls-main-head { display: flex; align-items: center; gap: 8px; height: 52px; flex: none; padding: 0 12px 0 16px; border-bottom: 1px solid var(--ls-line); color: var(--ls-strong); overflow: hidden; box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); font-size: 15px; z-index: 1; }
.ls-head-sep { width: 1px; height: 24px; background: var(--ls-line); margin: 0 6px; flex: none; }
.ls-drawer-btn { display: none; }
.ls-main-body { flex: 1; min-height: 0; overflow-y: auto; }
.ls-err { display: flex; gap: 8px; align-items: center; margin: 6px 12px; padding: 8px 10px; border-radius: 4px; background: rgba(217, 68, 63, 0.14); color: #ff8a85; font-size: 13.5px; }

.ls-friends { display: flex; min-height: 0; }
.ls-friend-list { padding: 8px 20px 20px; overflow-y: auto; }
.ls-friend-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-top: 1px solid var(--ls-line); border-radius: 8px; }
.ls-friend-row + .ls-friend-row.ls-click:hover, .ls-friend-row.ls-click:hover + .ls-friend-row { border-top-color: transparent; }
.ls-friend-row.ls-click:hover { background: var(--ls-hover); border-top-color: transparent; }
.ls-friend-row .ls-round { visibility: visible; }
.ls-add-friend { padding: 16px 0; }
.ls-add-friend h3 { margin: 0 0 4px; color: var(--ls-strong); }
.ls-add-row { display: flex; gap: 8px; margin-top: 12px; }
.ls-activity { width: 300px; flex: none; padding: 16px; border-left: 1px solid var(--ls-line); overflow-y: auto; }
.ls-activity h3 { margin: 0 0 12px; color: var(--ls-strong); font-size: 18px; }
.ls-activity-card { padding: 14px; margin-bottom: 10px; border-radius: 10px; background: var(--ls-panel2); border: 1px solid var(--ls-line); }

/* chat */
.ls-msgs { flex: 1; min-height: 0; overflow-y: auto; padding: 0 0 10px; display: flex; flex-direction: column; }
.ls-msgs::-webkit-scrollbar, .ls-side-list::-webkit-scrollbar, .ls-members::-webkit-scrollbar, .ls-main-body::-webkit-scrollbar, .ls-friend-list::-webkit-scrollbar { width: 10px; }
.ls-msgs::-webkit-scrollbar-thumb, .ls-side-list::-webkit-scrollbar-thumb, .ls-members::-webkit-scrollbar-thumb, .ls-main-body::-webkit-scrollbar-thumb, .ls-friend-list::-webkit-scrollbar-thumb { background: var(--ls-panel3); border-radius: 5px; border: 2px solid transparent; background-clip: padding-box; }
.ls-chat-start { margin-top: auto; padding: 24px 16px 8px; }
.ls-chat-start h2 { margin: 0 0 4px; color: var(--ls-strong); font-size: 26px; }
.ls-more { margin-top: auto; padding: 10px; text-align: center; color: var(--ls-muted); font-size: 12.5px; }
.ls-day { display: flex; align-items: center; margin: 20px 18px 4px; color: var(--ls-muted); font-size: 11.5px; font-weight: 600; letter-spacing: 0.02em; }
.ls-day::before, .ls-day::after { content: ""; flex: 1; height: 1px; background: var(--ls-line); }
.ls-day span { padding: 0 8px; }
.ls-msg { position: relative; padding: 3px 56px 3px 18px; margin-top: 14px; font-size: 15px; line-height: 22px; }
.ls-msg.cont { margin-top: 0; }
.ls-msg:hover { background: var(--ls-hover); }
.ls-msg.mention { background: var(--ls-mention); box-shadow: inset 2px 0 var(--ls-mention-line); }
.ls-msg.flash { background: var(--ls-active); transition: background 0.4s; }
.ls-msg-line { display: flex; gap: 16px; }
.ls-msg-av { flex: none; width: 40px; padding-top: 1px; }
.ls-msg-gutter { flex: none; width: 40px; text-align: right; }
.ls-msg-time { visibility: hidden; color: var(--ls-muted); font-size: 10.5px; line-height: 22px; font-variant-numeric: tabular-nums; }
.ls-msg:hover .ls-msg-time { visibility: visible; }
.ls-msg-head { display: flex; gap: 8px; align-items: baseline; line-height: 22px; }
.ls-msg-head .ls-sub { font-size: 12px; }
.ls-msg-head b { color: var(--ls-strong); font-weight: 600; }
.ls-msg-head b:hover { text-decoration: underline; }
.ls-msg-text { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ls-text); }
.ls-msg-text.jumbo { line-height: 52px; }
.ls-msg-text a { color: var(--ls-accent); }
.ls-msg-text code { padding: 1px 4px; border-radius: 3px; background: var(--ls-bg); font-family: Consolas, "Courier New", monospace; font-size: 0.9em; }
.ls-code { margin: 4px 0; padding: 8px 10px; border-radius: 4px; background: var(--ls-bg); border: 1px solid var(--ls-line); white-space: pre-wrap; font: 13px Consolas, "Courier New", monospace; color: var(--ls-text); }
.ls-mention { padding: 0 2px; border-radius: 3px; background: rgba(102, 192, 244, 0.18); color: var(--ls-accent); font-weight: 600; }
.ls-edited { color: var(--ls-muted); font-size: 11px; }
.ls-reply-ref { display: flex; align-items: center; gap: 4px; margin: 0 0 4px 20px; line-height: 18px; color: var(--ls-muted); font-size: 12.5px; cursor: pointer; overflow: hidden; }
.ls-reply-ref:hover { color: var(--ls-text); }
.ls-reply-curve { width: 30px; height: 10px; margin-top: 8px; border-left: 2px solid var(--ls-line); border-top: 2px solid var(--ls-line); border-top-left-radius: 6px; flex: none; }
.ls-tools { position: absolute; right: 14px; top: -18px; display: none; align-items: center; gap: 1px; padding: 3px; background: var(--ls-panel2); border: 1px solid var(--ls-line); border-radius: 9px; box-shadow: var(--ls-shadow-sm); z-index: 2; }
.ls-msg:hover .ls-tools { display: flex; }
.ls-tools button { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 30px; border: 0; background: none; color: var(--ls-muted); cursor: pointer; border-radius: 6px; }
.ls-tools button:hover { background: var(--ls-panel3); color: var(--ls-strong); }
.ls-tools .ls-tool-emoji .ls-emoji { width: 20px; height: 20px; margin: 0; vertical-align: 0; transition: transform 0.1s; }
.ls-tools .ls-tool-emoji:hover .ls-emoji { transform: scale(1.18); }
.ls-tools .ls-tool-danger:hover { color: #ff6b66; background: rgba(217, 68, 63, 0.14); }
.ls-tool-sep { width: 1px; height: 18px; margin: 0 3px; background: var(--ls-line); }
.ls-reacts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.ls-chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 9px 0 7px; border: 1px solid transparent; border-radius: 8px; background: var(--ls-panel2); color: var(--ls-text); cursor: pointer; font: 600 13px var(--ls-font); transition: border-color 0.1s, background 0.1s; }
.ls-chip .ls-emoji { width: 18px; height: 18px; margin: 0; vertical-align: 0; }
.ls-chip:hover { border-color: #3a4a5e; }
.ls-chip.mine { background: rgba(26, 159, 255, 0.14); border-color: rgba(102, 192, 244, 0.55); color: var(--ls-strong); }
.ls-chip-n { font-variant-numeric: tabular-nums; }
.ls-chip.add { padding: 0 7px; color: var(--ls-muted); opacity: 0; }
.ls-msg:hover .ls-chip.add, .ls-chip.add:focus-visible { opacity: 1; }
.ls-chip.add:hover { color: var(--ls-strong); }
.ls-img { display: block; max-width: min(100%, 420px); max-height: 320px; margin-top: 6px; border-radius: 8px; cursor: zoom-in; }
.ls-img.small { max-height: 120px; }
.ls-invite { display: flex; gap: 14px; align-items: center; max-width: 440px; margin-top: 6px; padding: 14px; border-radius: 10px; background: var(--ls-panel2); border: 1px solid var(--ls-line); line-height: 1.35; }
.ls-invite-art { width: 46px; height: 46px; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #2b6e1f, #4f9419); color: #fff; flex: none; }
.ls-blocked-msg { margin: 8px 16px 0 70px; color: var(--ls-muted); font-size: 12.5px; font-style: italic; }
.ls-seen { align-self: flex-end; color: var(--ls-muted); font-size: 11px; padding: 2px 16px; }
.ls-typing { height: 20px; flex: none; padding: 0 16px; color: var(--ls-text); font-size: 12.5px; }
.ls-composer { position: relative; flex: none; padding: 0 16px 16px; }
.ls-composer-box { display: flex; align-items: flex-end; gap: 2px; padding: 5px 6px; border-radius: 10px; background: var(--ls-panel2); border: 1px solid var(--ls-line); transition: border-color 0.12s; }
.ls-composer-box:focus-within { border-color: #33445a; }
.ls-composer-input { flex: 1; min-width: 0; max-height: 200px; padding: 7px 6px; border: 0; background: none; color: var(--ls-strong); font: 15px/22px var(--ls-font); outline: none; resize: none; }
.ls-composer-input::placeholder { color: #66768a; }
.ls-attach { border-radius: 50%; }
.ls-composer-input:disabled { color: var(--ls-muted); }
.ls-reply-bar { display: flex; align-items: center; gap: 8px; padding: 6px 10px; margin-bottom: -2px; border-radius: 8px 8px 0 0; background: var(--ls-panel3); color: var(--ls-muted); font-size: 13px; }
.ls-reply-bar b { color: var(--ls-strong); }
.ls-edit { margin-top: 4px; }
.ls-ac { position: absolute; left: 16px; right: 16px; bottom: calc(100% - 8px); padding: 6px; border-radius: 10px; background: var(--ls-panel2); border: 1px solid var(--ls-line); box-shadow: var(--ls-shadow); }
.ls-ac-title { padding: 4px 8px 6px; color: var(--ls-muted); font: 700 11px var(--ls-font); text-transform: uppercase; letter-spacing: 0.06em; }
.ls-ac-item { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 6px; cursor: pointer; }
.ls-ac-item .ls-emoji { width: 22px; height: 22px; margin: 0; vertical-align: 0; }
.ls-ac-hint { margin-left: auto; }
.ls-ac-item.on, .ls-ac-item:hover { background: var(--ls-active); color: var(--ls-strong); }

.ls-call-strip { flex: none; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 16px; background: var(--ls-bg); border-bottom: 1px solid var(--ls-line); }
.ls-call-tiles { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.ls-call-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.ls-voice-stage { display: flex; flex-direction: column; background: var(--ls-bg); }
.ls-stage-grid { flex: 1; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; padding: 16px; align-content: center; }
.ls-stage-tile { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 20px 12px; border-radius: 10px; background: var(--ls-panel); border: 2px solid transparent; }
.ls-stage-tile.speaking { border-color: var(--ls-green2); }
.ls-stage-bar { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px; }
.ls-range { width: 120px; accent-color: var(--ls-accent); }

.ls-members { min-height: 0; overflow-y: auto; padding: 0 8px 16px; background: var(--ls-bg2); border-left: 1px solid var(--ls-line); }
.ls-member { display: flex; align-items: center; gap: 10px; padding: 5px 8px; border-radius: 4px; cursor: pointer; color: var(--ls-text); }
.ls-member:hover { background: var(--ls-hover); }
.ls-member.off { opacity: 0.45; }
.ls-profile-col { padding: 0; }

/* profile */
.ls-profile { width: 300px; max-width: 100%; }
.ls-profile-col .ls-profile { width: 100%; }
.ls-profile-banner { height: 70px; }
.ls-profile-av { margin: -40px 0 0 14px; width: max-content; padding: 4px; border-radius: 50%; background: var(--ls-panel); }
.ls-profile-col .ls-profile-av { background: var(--ls-bg2); }
.ls-profile-name { padding: 4px 16px 0; font-size: 19px; color: var(--ls-strong); }
.ls-profile-status { padding: 0 16px; }
.ls-profile-extra { padding: 0 8px; }
.ls-profile-line { padding: 0 8px; white-space: pre-line; font-size: 13.5px; }
.ls-profile-actions { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 16px 4px; }
.ls-profile-actions:last-child { padding-bottom: 16px; }
.ls-role-chips { display: flex; flex-wrap: wrap; gap: 4px; padding: 2px 8px; }
.ls-role-chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px; border-radius: 4px; background: var(--ls-panel3); font-size: 12px; }
.ls-role-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }

/* popovers, modals, toasts */
.ls-pop { position: fixed; z-index: 2147483600; max-height: calc(100vh - 16px); overflow-y: auto; background: var(--ls-panel); border: 1px solid var(--ls-line); border-radius: 12px; box-shadow: var(--ls-shadow); animation: ls-pop 0.12s ease-out; }
.ls-pop > .ls-menu.static { padding: 6px; min-width: 220px; }
.ls-pins { width: 360px; max-width: calc(100vw - 32px); padding: 0 12px 12px; }
.ls-pin { padding: 8px 0; border-top: 1px solid var(--ls-line); }
.ls-modal-back { position: fixed; inset: 0; z-index: 2147483500; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, 0.6); }
.ls-modal { display: flex; flex-direction: column; width: min(480px, 100%); max-height: calc(100vh - 32px); background: var(--ls-panel); border: 1px solid var(--ls-line); border-radius: 12px; box-shadow: var(--ls-shadow); animation: ls-pop 0.16s ease-out; }
@keyframes ls-pop { from { opacity: 0; transform: scale(0.97); } }
.ls-modal.wide { width: min(920px, 100%); height: min(720px, calc(100vh - 32px)); }
.ls-modal-head { display: flex; align-items: center; gap: 8px; padding: 16px 18px; border-bottom: 1px solid var(--ls-line); }
.ls-modal-head h2 { margin: 0; font-size: 18px; color: var(--ls-strong); }
.ls-modal > .ls-form, .ls-modal > .ls-settings, .ls-modal > div:nth-child(2) { flex: 1; min-height: 0; overflow-y: auto; }
.ls-modal-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--ls-line); background: var(--ls-panel2); border-radius: 0 0 12px 12px; }
.ls-form { display: flex; flex-direction: column; gap: 10px; padding: 16px; }
.ls-form p { margin: 0; }
.ls-form-err { color: #ff8a85; font-size: 13.5px; }
.ls-form-err:empty { display: none; }
.ls-field { display: flex; flex-direction: column; gap: 5px; }
.ls-field-label { color: var(--ls-muted); font: 700 11.5px var(--ls-font); text-transform: uppercase; letter-spacing: 0.04em; }
.ls-check-list { display: flex; flex-direction: column; gap: 2px; }
.ls-check { display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-radius: 4px; cursor: pointer; }
.ls-check:hover { background: var(--ls-hover); }
.ls-perm { display: flex; align-items: center; gap: 12px; padding: 8px 4px; border-bottom: 1px solid var(--ls-line); cursor: pointer; }
.ls-perm.off { opacity: 0.55; cursor: default; }
.ls-switch { appearance: none; flex: none; width: 40px; height: 22px; border-radius: 11px; background: var(--ls-panel3); position: relative; cursor: pointer; transition: background 0.15s; }
.ls-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: left 0.15s; }
.ls-switch:checked { background: var(--ls-green2); }
.ls-switch:checked::after { left: 21px; }
.ls-switch:disabled { cursor: default; }
.ls-color { width: 60px; height: 34px; padding: 0; border: 1px solid var(--ls-line); border-radius: 4px; background: none; cursor: pointer; }
.ls-settings { display: flex; min-height: 0; height: 100%; }
.ls-settings-nav { width: 200px; flex: none; padding: 8px; background: var(--ls-bg2); overflow-y: auto; }
.ls-settings-pane { padding: 16px 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.ls-settings-pane h3 { margin: 4px 0 0; color: var(--ls-strong); }
.ls-roles { display: flex; gap: 16px; min-height: 0; }
.ls-role-list { width: 220px; flex: none; }
.ls-role-edit { display: flex; flex-direction: column; gap: 8px; }
.ls-ow { display: flex; gap: 16px; }
.ls-ow-list { width: 210px; flex: none; display: flex; flex-direction: column; gap: 4px; }
.ls-ow-edit { display: flex; flex-direction: column; }
.ls-ow-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--ls-line); }
.ls-tri { display: flex; border: 1px solid var(--ls-line); border-radius: 4px; overflow: hidden; }
.ls-tri button { width: 32px; height: 26px; border: 0; background: none; color: var(--ls-muted); cursor: pointer; }
.ls-tri button.on.deny { background: var(--ls-red); color: #fff; }
.ls-tri button.on.inherit { background: var(--ls-panel3); color: var(--ls-strong); }
.ls-tri button.on.allow { background: var(--ls-green); color: #fff; }
.ls-audit-row { padding: 8px 0; border-bottom: 1px solid var(--ls-line); }
.ls-icon-preview { display: flex; }
.ls-lightbox { flex-direction: column; gap: 12px; cursor: zoom-out; }
.ls-lightbox img { max-width: 92vw; max-height: 82vh; border-radius: 6px; }

.ls-toasts { position: fixed; top: 16px; left: 50%; z-index: 2147483640; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.ls-toast { display: flex; align-items: center; gap: 10px; max-width: min(520px, calc(100vw - 32px)); padding: 10px 10px 10px 16px; border-radius: 10px; background: var(--ls-panel2); color: var(--ls-strong);
  border: 1px solid var(--ls-line); box-shadow: var(--ls-shadow); pointer-events: auto; font-size: 14px; animation: ls-in 0.18s ease-out; }
.ls-toast.bad { border-color: rgba(217, 68, 63, 0.7); box-shadow: inset 3px 0 var(--ls-red), var(--ls-shadow); }
@keyframes ls-in { from { opacity: 0; transform: translateY(-6px); } }

/* game overlay */
.ls-overlay { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: center; justify-content: center; padding: 4vh 3vw; background: rgba(5, 8, 12, 0.55); backdrop-filter: blur(2px); }
.ls-overlay > .ls-social { width: min(1280px, 100%); height: min(860px, 100%); border-radius: 10px; border: 1px solid var(--ls-line); box-shadow: var(--ls-shadow); }
.ls-fab { position: fixed; right: 18px; bottom: 18px; z-index: 2147482000; display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border: 1px solid var(--ls-line); border-radius: 999px;
  background: var(--ls-panel2); color: var(--ls-strong); font-weight: 600; font-size: 14px; cursor: pointer; box-shadow: var(--ls-shadow); }
.ls-fab:hover { background: var(--ls-panel3); }
.ls-fab kbd { padding: 1px 6px; border-radius: 4px; background: var(--ls-bg); color: var(--ls-muted); font: 600 11px var(--ls-font); }
.ls-fab.in-voice { box-shadow: 0 0 0 2px var(--ls-green2), var(--ls-shadow); }

/* narrow screens (container queries so the overlay adapts too) */
@container (max-width: 1100px) { .ls-activity { display: none; } }
@media (max-width: 900px) {
  .ls-social, .ls-social.no-members { grid-template-columns: 72px 220px minmax(0, 1fr); }
  .ls-members { display: none; }
}
@media (max-width: 640px) {
  .ls-social, .ls-social.no-members { grid-template-columns: minmax(0, 1fr); }
  .ls-rail, .ls-side { position: absolute; top: 0; bottom: 0; z-index: 10; transform: translateX(-110%); transition: transform 0.2s; }
  .ls-rail { left: 0; width: 72px; }
  .ls-side { left: 72px; width: min(280px, calc(100% - 72px)); box-shadow: var(--ls-shadow); }
  .ls-social.drawer-open .ls-rail, .ls-social.drawer-open .ls-side { transform: none; }
  .ls-drawer-btn { display: inline-flex; }
  .ls-msg { padding-right: 12px; }
  .ls-settings { flex-direction: column; }
  .ls-settings-nav { width: auto; display: flex; flex-wrap: wrap; gap: 4px; }
  .ls-roles, .ls-ow { flex-direction: column; }
  .ls-role-list, .ls-ow-list { width: auto; }
  .ls-overlay { padding: 0; }
  .ls-overlay > .ls-social { border-radius: 0; }
}

/* emoji (Twemoji pictures) */
.ls-emoji { display: inline-block; width: 1.375em; height: 1.375em; margin: 0 0.06em; vertical-align: -0.32em; object-fit: contain; }
.ls-msg-text.jumbo .ls-emoji { width: 48px; height: 48px; margin: 0 2px 0 0; vertical-align: middle; }
.ls-emoji-big { display: block; width: 32px; height: 32px; flex: none; }
.ls-tip { position: fixed; z-index: 2147483645; max-width: 280px; padding: 9px 12px; border-radius: 10px; background: #05080c; color: #e9eef3; border: 1px solid #1d2733;
  font-size: 13px; line-height: 1.35; box-shadow: var(--ls-shadow); pointer-events: none; animation: ls-pop 0.1s ease-out; }
.ls-tip-react { display: flex; align-items: center; gap: 10px; }
.ls-tip-react b { color: #fff; }

.ls-emoji-picker { position: fixed; z-index: 2147483620; height: 400px; display: flex; flex-direction: column; background: var(--ls-panel2); border: 1px solid var(--ls-line);
  border-radius: 12px; box-shadow: var(--ls-shadow); overflow: hidden; animation: ls-pop 0.12s ease-out; }
.ls-emoji-search { margin: 10px 10px 6px; width: calc(100% - 20px); padding: 7px 10px; }
.ls-emoji-tabs { display: flex; gap: 2px; padding: 0 8px 6px; border-bottom: 1px solid var(--ls-line); }
.ls-emoji-tab { flex: 1; display: inline-flex; justify-content: center; padding: 5px 0; border: 0; border-radius: 6px; background: none; cursor: pointer; filter: grayscale(1); opacity: 0.7; }
.ls-emoji-tab:hover { filter: none; opacity: 1; background: var(--ls-panel3); }
.ls-emoji-tab .ls-emoji { width: 20px; height: 20px; margin: 0; vertical-align: 0; }
.ls-emoji-grid { flex: 1; min-height: 0; overflow-y: auto; padding: 0 6px 6px; }
.ls-emoji-sect { position: sticky; top: 0; z-index: 1; padding: 8px 4px 4px; background: var(--ls-panel2); color: var(--ls-muted); font: 700 11px var(--ls-font); text-transform: uppercase; letter-spacing: 0.06em; }
.ls-emoji-cells { display: grid; grid-template-columns: repeat(auto-fill, minmax(38px, 1fr)); }
.ls-emoji-cell { display: inline-flex; align-items: center; justify-content: center; height: 38px; border: 0; border-radius: 6px; background: none; cursor: pointer; }
.ls-emoji-cell:hover { background: var(--ls-panel3); }
.ls-emoji-cell .ls-emoji-big { width: 28px; height: 28px; }
.ls-emoji-empty { padding: 30px 10px; text-align: center; }
.ls-emoji-foot { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 8px 12px; border-top: 1px solid var(--ls-line); background: var(--ls-bg2); color: var(--ls-strong); font-weight: 600; font-size: 13.5px; }
.ls-emoji-foot-pic:empty { display: none; }
.ls-msg.cont { margin-top: 0; }
