/* Delta Demo — путь A */
:root {
  --bg: #10141a; --panel: #171d26; --panel2: #1d2530;
  --text: #e7edf5; --muted: #8b98a9; --accent: #43a047; --accent2: #2e7d32;
  --out: #245a86; --radius: 12px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--text); font: 14px/1.45 "Segoe UI", system-ui, sans-serif; }

header { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; background: var(--panel); border-bottom: 1px solid #26303d; }
.brand { font-weight: 700; }
.brand .tag { font-weight: 400; color: var(--muted); font-size: 12px; margin-left: 8px; }
.header-actions { display: flex; gap: 8px; align-items: center; }
select, input, button { background: var(--panel2); color: var(--text); border: 1px solid #2c3947; border-radius: 8px; padding: 6px 10px; font: inherit; }
button { cursor: pointer; }
button:hover { border-color: var(--accent); }
button.ghost { opacity: .7; }

main { flex: 1; display: flex; min-height: 0; }
aside { width: 300px; background: var(--panel); border-right: 1px solid #26303d; display: flex; flex-direction: column; min-height: 0; }
.aside-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; }
#chatList { flex: 1; overflow-y: auto; }
.chat-item { padding: 9px 12px; cursor: pointer; border-bottom: 1px solid #1e2733; }
.chat-item:hover { background: var(--panel2); }
.chat-item.active { background: var(--panel2); border-left: 3px solid var(--accent); }
.chat-item .name { font-weight: 600; display: flex; justify-content: space-between; gap: 6px; }
.chat-item .name .time { font-weight: 400; color: var(--muted); font-size: 11px; }
.chat-item .sum { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-item .fresh { background: var(--accent); color: #06220a; border-radius: 10px; padding: 0 7px; font-size: 11px; font-weight: 700; }
#inviteForm { padding: 8px 12px; border-bottom: 1px solid #1e2733; display: flex; flex-direction: column; gap: 6px; }
#inviteForm textarea { width: 100%; font-size: 11px; resize: vertical; }
#inviteForm .row { display: flex; gap: 6px; }
#inviteSvg svg { width: 100%; height: auto; background: #fff; border-radius: 8px; }
.hint { color: var(--muted); font-size: 11px; }
.me { padding: 8px 12px; color: var(--muted); font-size: 12px; border-top: 1px solid #1e2733; }

#chatPane { flex: 1; display: flex; min-width: 0; }
.empty { margin: auto; color: var(--muted); text-align: center; }
#chatView { flex: 1; display: flex; flex-direction: column; min-width: 0; }
#chatTitle { padding: 10px 16px; background: var(--panel); border-bottom: 1px solid #26303d; font-weight: 700; }
#msgList { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.msg { max-width: 68%; padding: 7px 11px; border-radius: var(--radius); background: var(--panel2); align-self: flex-start; }
.msg.out { align-self: flex-end; background: var(--out); }
.msg .t { font-size: 11px; color: var(--muted); margin-top: 3px; display: flex; gap: 8px; justify-content: flex-end; }
.msg .tick { color: #9fd0f5; }
#composer { display: flex; gap: 8px; padding: 12px 16px; background: var(--panel); border-top: 1px solid #26303d; }
#composer input { flex: 1; }
#sendBtn { padding: 6px 16px; background: var(--accent2); border-color: var(--accent); font-weight: 700; }
.lock { font-size: 11px; opacity: .85; }
.hidden { display: none !important; }
