:root {
  color-scheme: dark;
  --bg: #111111;
  --sidebar: #0e0e0e;
  --surface: #1c1c1f;
  --raised: #252529;
  --line: #2b2b2b;
  --border: #404045;
  --text: #f1f1f3;
  --muted: #a9a9b1;
  --accent: #e7ece4;
  --accent-ink: #192019;
  --ok: #c0dcb3;
  --warn: #f1ca95;
  --danger: #efb3ac;
  font: 15px/1.5 Inter, "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: var(--bg);
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; width: 100%; height: 100%; }
body { overscroll-behavior: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { border: none; background: none; cursor: pointer; }
button:disabled { opacity: .45; cursor: not-allowed; }
button, input, select, textarea { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
input, select, textarea { min-width: 0; background: #171719; border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; }
input::placeholder, textarea::placeholder { color: #9c9ca4; }
input:focus-visible, textarea:focus-visible, select:focus-visible { outline-offset: 1px; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex: none; vertical-align: middle; }
.svg-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
::selection { color: white; background: #607d52; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #414146; border-radius: 12px; border: 2px solid var(--bg); }
strong { font-weight: 600; }
p { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 620; letter-spacing: -.025em; }
.muted { color: var(--muted); font-size: 12px; line-height: 1.55; }
.primary, .secondary, .icon-button, .text-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 9px; padding: 10px 14px; font-size: 13px; font-weight: 600; line-height: 1.3; min-height: 38px; }
.primary { color: var(--accent-ink); background: var(--accent); border: 1px solid var(--accent); }
.primary:hover:not(:disabled) { background: #d7eacb; }
.secondary { background: #202023; border: 1px solid var(--border); color: #e0e0e4; }
.secondary:hover:not(:disabled) { background: #303034; }
.icon-button { padding: 8px; width: 38px; height: 38px; color: var(--muted); }
.icon-button:hover:not(:disabled), .text-button:hover:not(:disabled) { background: var(--raised); color: var(--text); }
.text-button { justify-content: flex-start; color: #d4d4d9; padding: 5px 8px; min-height: 30px; }
.text-button svg { width: 15px; height: 15px; }
.eyebrow { color: #9c9ca5; font-size: 10px; font-weight: 680; text-transform: uppercase; letter-spacing: .115em; }
.online-dot { width: 7px; height: 7px; background: #acc89e; display: inline-block; border-radius: 50%; flex: none; }
.mark { background: var(--accent); color: var(--accent-ink); width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; flex: none; }
.mark svg { width: 23px; height: 23px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand strong, .brand span:not(.mark) { display: block; }
.brand strong { font-size: 14px; line-height: 1.45; letter-spacing: -.025em; }
.brand span:not(.mark) { color: var(--muted); font-size: 11px; }
.login-view { min-height: 100%; display: grid; place-items: center; padding: 24px; background: radial-gradient(ellipse at center top, #252e24 0%, var(--bg) 62%); }
.login-card { width: min(100%, 440px); border: 1px solid #373a35; background: #1c1c1e; border-radius: 22px; padding: 33px; box-shadow: 0 25px 100px #0007; }
.login-card .brand { margin-bottom: 44px; }
.login-card h1 { font-size: 29px; line-height: 1.17; margin: 10px 0 13px; }
.login-card > p { font-size: 13px; color: var(--muted); }
.login-card form { margin-top: 26px; }
.login-card label { display: block; font-weight: 600; margin-bottom: 8px; }
.login-card input { width: 100%; min-height: 46px; }
.login-submit { width: 100%; min-height: 44px; margin: 12px 0 0; }
.login-submit svg { margin-left: auto; }
.login-foot { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 16px; color: var(--muted); display: flex; gap: 7px; align-items: center; font-size: 12px; }
.login-foot svg { width: 14px; height: 14px; color: var(--accent); }
.form-message { margin: 0; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.form-message:not(:empty) { margin-top: 10px; }
.form-message[data-tone="error"] { color: var(--danger); }
.form-message[data-tone="ok"] { color: var(--ok); }
.app {
  --sidebar-width: clamp(270px, 24vw, 410px);
  --details-width: clamp(290px, 22vw, 380px);
  --chat-width: 1100px;
  height: 100%; height: 100dvh; display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr); overflow: hidden;
}
.app.collapsed { --sidebar-width: 84px; }
.app.agent-open { grid-template-columns: var(--sidebar-width) minmax(0, 1fr) var(--details-width); }
.sidebar { background: var(--sidebar); border-right: 1px solid #222; padding: 16px 15px; display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.sidebar-toolbar, .account-line, .top-actions, .title-cluster { display: flex; align-items: center; }
.sidebar-toolbar { gap: 8px; min-height: 44px; }
.sidebar-title { font-size: 15px; font-weight: 600; margin-right: auto; }
.round-button { display: inline-grid; place-items: center; width: 40px; height: 40px; flex: none; border: 1px solid #323232; background: #202020; color: #f1f1ef; border-radius: 50%; }
.round-button:hover, .agent-tabs button:hover { background: #303030; }
.round-button svg { width: 18px; height: 18px; }
.search { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: #1a1a1a; border-radius: 14px; padding: 0 12px; color: var(--muted); margin-top: 12px; }
.search:focus-within { border-color: var(--muted); }
.search input { border: 0; background: transparent; outline: none; width: 100%; }
.bot-entry { align-self: center; position: relative; display: grid; place-items: center; gap: 8px; margin: 28px 0 32px; padding: 12px 15px; min-width: 110px; background: #222; border: 1px solid #292929; border-radius: 17px; }
.bot-entry strong { font-size: 15px; }
.bot-entry:hover { background: #2b2b2b; }
.avatar { display: inline-grid; place-items: center; position: relative; flex: none; width: 52px; height: 52px; border-radius: 50%; background: #eef0e9; color: #25382c; }
.avatar svg { width: 30px; height: 30px; stroke-width: 1.65; }
.hotel-marker { position: absolute; right: 0; bottom: 0; width: 14px; height: 14px; border: 3px solid #222; border-radius: 50%; background: #c1d7a9; }
.section-title { display: flex; justify-content: space-between; color: var(--muted); font-size: 12px; font-weight: 550; padding: 0 9px 7px; }
.chat-nav { min-height: 0; flex: 1; overflow: auto; }
.chat-list { list-style: none; padding: 0; margin: 0; }
.chat-entry { width: 100%; display: flex; gap: 12px; align-items: center; min-height: 64px; padding: 10px; border-radius: 13px; text-align: left; }
.chat-entry:hover, .nav-button:hover { background: #212121; }
.chat-entry[aria-current=true] { background: #1b1b1b; }
.chat-entry > svg { width: 32px; height: 32px; padding: 7px; border-radius: 11px; background: #292e2a; color: #dce6d7; }
.chat-copy { flex: 1; min-width: 0; }
.chat-copy strong, .chat-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-copy strong { font-size: 15px; }
.chat-copy small, .list-empty { color: var(--muted); font-size: 12px; }
.list-empty { padding: 12px; }
.sidebar-foot { margin-top: auto; padding-top: 10px; }
.nav-button { display: flex; gap: 10px; align-items: center; width: 100%; padding: 10px 14px; text-align: left; min-height: 44px; border: 1px solid var(--line); background: #1c1c1c; border-radius: 24px; }
.account-line { gap: 10px; margin-top: 10px; }
.account-line .mark { width: 32px; height: 32px; border-radius: 50%; background: #c6d8be; }
.account-line .mark svg { width: 19px; }
.account-name { color: #ccc; flex: 1; font-size: 13px; }
.mobile-only, .mobile-backdrop, .agent-backdrop { display: none; }
.main { min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 0 clamp(14px, 3vw, 44px); min-height: 70px; }
.title-cluster { min-width: 0; max-width: min(75%, 650px); gap: 20px; padding: 12px 12px 10px 20px; background: linear-gradient(#151515, #1d1d1d); border: 1px solid #282828; border-top: 0; border-radius: 0 0 24px 24px; }
.session-title { font-weight: 500; letter-spacing: 0; color: #b4b4b4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.agent-pill { display: flex; align-items: center; gap: 9px; flex: none; padding: 4px 11px 4px 6px; min-height: 39px; border: 1px solid #373737; border-radius: 23px; background: #252525; }
.agent-pill:hover, .agent-pill[aria-expanded=true] { background: #333; }
.agent-pill .avatar { width: 28px; height: 28px; }
.agent-pill .avatar svg { width: 18px; height: 18px; }
.agent-arrow { width: 14px; height: 14px; }
.agent-pill[data-paused=true] { border-color: #937853; }
.top-actions { flex: none; gap: 6px; padding-top: 10px; }
.sim { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; font-size: 12px; color: #c4c4bf; }
.version, .agent-caption { font-size: 12px; color: var(--muted); }
.agent-caption[data-paused=true] { color: var(--warn); }
.chat-frame { display: flex; flex: 1; flex-direction: column; min-height: 0; position: relative; }
.app-notice { margin: 12px auto 0; width: min(calc(100% - 40px), 840px); border: 1px solid #535348; border-radius: 10px; padding: 8px 8px 8px 13px; background: #272721; color: #dad5b2; display: flex; gap: 6px; align-items: center; justify-content: space-between; font-size: 13px; }
.app-notice[data-tone="error"] { border-color: #684844; background: #2b2222; color: var(--danger); }
.app-notice .icon-button { flex: none; height: 29px; width: 29px; min-height: 29px; padding: 4px; }
.chat-scroll { overflow: auto; min-height: 0; flex: 1; overscroll-behavior: contain; }
.thread { min-height: 100%; max-width: var(--chat-width); margin: 0 auto; padding: 24px clamp(16px, 3.8vw, 64px) 16px; display: flex; flex-direction: column; }
.day-divider { color: #aaa; align-self: center; font-size: 13px; margin: 0 0 24px; }
.pause-notice { margin: 0 0 18px; padding: 9px 14px; color: var(--warn); background: #2b261f; border-radius: 13px; }
.welcome { align-self: center; text-align: center; margin: auto 0; width: min(100%, 610px); padding: 16px 0; }
.welcome-icon { display: grid; place-items: center; margin: 0 auto 18px; width: 62px; height: 62px; border-radius: 50%; background: #e8ece4; color: #293a2e; }
.welcome-icon svg { width: 34px; height: 34px; }
.welcome h2 { font-size: clamp(26px, 3vw, 36px); line-height: 1.25; margin-bottom: 7px; }
.welcome > p { color: var(--muted); }
.suggestion-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 26px 0 12px; }
.suggestion { display: flex; align-items: center; gap: 11px; text-align: left; padding: 12px 15px; border: 1px solid #303030; border-radius: 16px; background: #1b1b1b; }
.suggestion:hover { background: #252525; }
.suggestion > svg:first-child { color: #c6d8be; }
.suggestion > svg:last-child { margin-left: auto; width: 13px; color: var(--muted); }
.suggestion strong, .suggestion small { display: block; }
.suggestion strong { font-size: 14px; }
.suggestion small { font-size: 12px; color: var(--muted); }
.message { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; min-width: 0; margin-bottom: 20px; }
.message.user { align-items: flex-end; }
.message-label, .message-meta { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.message-label { padding: 0 4px; }
.bubble { width: fit-content; max-width: min(86%, 700px); white-space: pre-wrap; overflow-wrap: anywhere; padding: 11px 15px; border: 1px solid #2a2a2a; background: #202020; color: #f3f3f3; border-radius: 19px 19px 19px 5px; font-size: 16px; line-height: 1.55; }
.user .bubble { background: #353535; border-color: #414141; border-radius: 19px 19px 5px 19px; }
.message-meta .text-button { font-size: 11px; min-height: 26px; }
.event-note { display: flex; align-items: flex-start; gap: 10px; padding: 12px; background: #1c1f1c; border: 1px solid #364133; border-radius: 11px; margin-bottom: 21px; color: #cdd5c8; overflow-wrap: anywhere; }
.event-note > svg { color: #aec7a4; margin-top: 3px; }
.event-note[data-state="failed"] { border-color: #684844; background: #271f1f; color: var(--danger); }
.event-note[data-state="failed"] > svg { color: var(--danger); }
.event-note[data-state="pending"] { border-color: #514a36; background: #25231d; color: var(--warn); }
.event-note[data-state="pending"] > svg { color: var(--warn); }
.event-note-copy { flex: 1; min-width: 0; }
.event-note-copy > strong { display: block; font-size: 12px; margin-bottom: 5px; }
.event-note-copy > p { font-size: 13px; white-space: pre-wrap; }
.event-note-copy .text-button { padding-left: 0; }
.status { background: #283127; color: var(--ok); border: 1px solid #475e40; border-radius: 20px; padding: 4px 8px; white-space: nowrap; font-size: 10px; font-weight: 650; flex: none; line-height: 1.2; }
.status[data-state="pending"] { background: #302a20; border-color: #625237; color: var(--warn); }
.status[data-state="failed"] { background: #382825; border-color: #74514b; color: var(--danger); }
.inline-suggestions { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin: 0 0 8px; }
.suggestion-tip { color: var(--warn); font-size: 13px; }
.chip { background: #202020; color: #dededc; border: 1px solid #353535; border-radius: 20px; padding: 7px 13px; font-size: 13px; }
.chip:hover { background: #2c2c2c; }
.composer-wrap { flex: none; background: var(--bg); padding: 8px clamp(16px, 3.8vw, 64px) max(16px, env(safe-area-inset-bottom)); }
.composer-inner { max-width: calc(var(--chat-width) - 2 * clamp(16px, 3.8vw, 64px)); margin: 0 auto; }
.composer { display: flex; align-items: flex-end; gap: 10px; padding: 7px 8px; min-height: 53px; border: 1px solid #424242; border-radius: 27px; background: #202020; }
.composer:focus-within { border-color: #767673; }
.composer textarea { flex: 1; align-self: center; height: auto; min-height: 29px; max-height: 116px; field-sizing: content; resize: none; border: 0; background: transparent; border-radius: 0; padding: 3px 0; font-size: 16px; line-height: 1.5; }
.composer textarea:focus-visible { outline: none; }
.composer .round-button, .send-button { flex: none; width: 36px; height: 36px; border-radius: 50%; }
.composer .round-button { background: #292929; }
.send-button { display: grid; place-items: center; background: #ececea; color: #202020; }
.send-button:hover:not(:disabled) { background: #fff; }
.char-count { align-self: center; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.panel-dialog { margin: auto; padding: 0; width: min(640px, calc(100% - 30px)); max-height: min(90dvh, 850px); background: #1a1a1d; border: 1px solid #444449; border-radius: 18px; color: var(--text); box-shadow: 0 20px 80px #0009; }
.panel-dialog::backdrop { background: #080809b8; }
.panel-dialog .dialog-content { display: flex; flex-direction: column; max-height: min(90dvh, 850px); min-height: 0; }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 23px 24px 17px; border-bottom: 1px solid var(--line); flex: none; }
.dialog-head h2 { font-size: 21px; line-height: 1.25; margin: 6px 0; }
.dialog-head p { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.dialog-head .icon-button { flex: none; margin: -5px -5px 0 0; }
.dialog-body { padding: 21px 24px; min-height: 0; overflow: auto; overscroll-behavior: contain; }
.dialog-form { min-height: 0; display: flex; flex-direction: column; }
.group-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; gap: 10px; }
.group-heading h3 { font-size: 15px; }
.spaced { margin-top: 26px; }
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px 14px; margin-top: 20px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; font-size: 13px; font-weight: 550; }
.field code { color: var(--muted); font: 10px/1.4 ui-monospace, "Cascadia Mono", monospace; }
.field input, .field select { min-height: 42px; font-weight: 400; width: 100%; }
.neutral-badge { font-size: 10px; color: #b9b9c1; white-space: nowrap; display: inline-flex; gap: 4px; align-items: center; }
.neutral-badge svg { width: 13px; height: 13px; }
.module-card { display: flex; align-items: center; gap: 11px; margin-top: 10px; padding: 12px; background: #202023; border: 1px solid #37373c; border-radius: 11px; cursor: pointer; }
.module-icon { display: grid; place-items: center; width: 33px; height: 33px; border-radius: 9px; background: #30372e; color: var(--accent); flex: none; }
.module-copy { flex: 1; min-width: 0; }
.module-copy strong, .module-copy small { display: block; }
.module-copy strong { font-size: 13px; }
.module-copy small { font-size: 11px; color: var(--muted); }
.toggle { width: 18px; height: 18px; accent-color: var(--accent); padding: 0; flex: none; }
.dialog-foot { border-top: 1px solid var(--line); padding: 14px 24px 17px; flex: none; }
.dialog-foot .form-message:not(:empty) { margin: 0 0 10px; }
.foot-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
.event-state { color: #cbd8c5; display: flex; align-items: center; gap: 9px; padding: 12px; background: #222a21; border: 1px solid #384737; border-radius: 10px; margin-bottom: 21px; font-size: 12px; }
.event-state[data-paused="true"] { color: var(--warn); background: #2b261d; border-color: #534631; }
.event-state[data-paused="true"] .online-dot { background: var(--warn); }
.event-field { margin-top: 23px; }
.event-field + .muted, .field + .muted { margin-top: 8px; }
.result-card { border-radius: 11px; padding: 14px; border: 1px solid #3d4e39; background: #232b21; margin-top: 21px; overflow-wrap: anywhere; }
.result-card[data-state="failed"] { border-color: #684844; background: #2b2222; }
.result-card p { margin: 7px 0 5px; white-space: pre-wrap; font-size: 13px; }
.result-card .text-button { margin-left: -8px; font-size: 12px; }
.logs-dialog { width: min(720px, calc(100% - 30px)); }
.runs-body { min-height: min(180px, 35dvh); }
.run-filter { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; color: var(--muted); font-size: 12px; }
.run-filter select { padding: 7px 9px; }
.run-list { list-style: none; padding: 0; margin: 0; }
.run-list-item { display: block; border-radius: 11px; border: 1px solid #3b3b40; background: #242427; padding: 13px; text-align: left; margin-bottom: 9px; width: 100%; overflow-wrap: anywhere; }
.run-list-item:hover { background: #2c2e2b; border-color: #687860; }
.run-line { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.run-line strong { font-size: 13px; overflow-wrap: anywhere; }
.run-list-item p { margin: 7px 0; color: #c3c3c9; font-size: 12px; }
.run-id-line { color: var(--muted); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; font-size: 10px; }
.run-back { margin: -2px 0 15px -8px; color: var(--accent); }
.run-detail-title { display: flex; justify-content: space-between; align-items: center; gap: 9px; margin-bottom: 4px; }
.run-detail-title h3 { font-size: 20px; }
.detail-result { margin: 17px 0; }
.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin: 12px 0 16px; }
.detail-cell { padding: 11px; border: 1px solid #37373a; background: #222225; border-radius: 9px; min-width: 0; overflow-wrap: anywhere; }
.detail-cell small, .detail-cell strong { display: block; font-size: 12px; }
.detail-cell small { color: var(--muted); font-size: 10px; margin-bottom: 3px; }
details { border: 1px solid #3a3a40; border-radius: 10px; padding: 0 12px; margin: 10px 0; }
details > summary { cursor: pointer; padding: 12px 0; color: #d8d8dd; font-size: 13px; font-weight: 550; }
details[open] > summary { margin-bottom: 5px; }
.trace { list-style: none; margin: 0 0 10px; padding: 0; }
.trace li { display: flex; align-items: flex-start; gap: 10px; position: relative; padding: 4px 0 16px; }
.trace li:not(:last-child)::before { content: ""; position: absolute; left: 12px; top: 29px; bottom: 0; width: 1px; background: #454741; }
.trace-index { width: 25px; height: 25px; display: grid; place-items: center; border: 1px solid #4a5d43; color: var(--accent); background: #293226; border-radius: 50%; font-size: 10px; flex: none; }
.trace-copy { min-width: 0; flex: 1; }
.trace-copy strong { font-size: 12px; }
.trace-copy p { color: var(--muted); margin: 3px 0; font-size: 12px; white-space: pre-wrap; overflow-wrap: anywhere; }
.trace-copy small { color: var(--muted); font-size: 11px; }
pre { max-height: 360px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; background: #121214; color: #d0dacc; border: 1px solid #343436; border-radius: 8px; padding: 12px; font: 11px/1.6 ui-monospace, "Cascadia Mono", Consolas, monospace; margin: 0 0 12px; }
.detail-loading { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 16px 0; color: var(--muted); }
.agent-panel { min-width: 0; display: flex; flex-direction: column; align-items: stretch; overflow: auto; padding: 16px; border-left: 1px solid #292929; background: var(--bg); }
.agent-panel-head { display: flex; }
.agent-panel-profile { display: grid; justify-items: center; gap: 8px; margin: 24px 2px 18px; }
.panel-avatar { width: 72px; height: 72px; margin-bottom: 8px; }
.panel-avatar svg { width: 40px; height: 40px; }
.agent-panel-profile h2 { font-size: 22px; }
.profile-meta { display: flex; align-items: center; gap: 8px; }
.agent-tabs { display: flex; justify-content: center; gap: 3px; margin-bottom: 20px; }
.agent-tabs button { border-radius: 22px; padding: 7px 13px; color: var(--muted); font-size: 14px; }
.agent-tabs button[aria-selected=true] { background: #252525; color: #fff; }
.panel-links { display: grid; gap: 10px; }
.panel-link { width: 100%; padding: 14px; background: #202020; border: 1px solid #2b2b2b; border-radius: 15px; display: flex; align-items: center; text-align: left; gap: 12px; }
.panel-link:hover:not(:disabled) { background: #292929; }
.panel-link > svg:last-child { margin-left: auto; width: 14px; }
.panel-link strong, .panel-link small { display: block; }
.panel-link strong, .panel-group { font-size: 15px; }
.panel-link small { margin-top: 3px; color: var(--muted); font-size: 12px; }
.panel-group { margin: 12px 3px 0; font-weight: 500; }
.module-summary { margin: 0; padding: 0 14px; background: #202020; border: 1px solid #2b2b2b; border-radius: 15px; }
.module-summary div { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; }
.module-summary div + div { border-top: 1px solid var(--line); }
.module-summary dd { margin: 0; color: #c3d4ba; }
@media (min-width: 721px) {
  .sidebar.collapsed { align-items: center; padding-inline: 8px; }
  .sidebar.collapsed .sidebar-toolbar { flex-direction: column; gap: 7px; }
  .sidebar.collapsed .sidebar-title, .sidebar.collapsed .bot-entry strong, .sidebar.collapsed .section-title,
  .sidebar.collapsed .chat-nav, .sidebar.collapsed .nav-button span, .sidebar.collapsed .account-name, .sidebar.collapsed .account-line .mark { display: none; }
  .sidebar.collapsed .bot-entry { order: -1; min-width: 0; margin: 6px 0 18px; padding: 7px; border-radius: 14px; }
  .sidebar.collapsed .bot-entry .avatar { width: 40px; height: 40px; }
  .sidebar.collapsed .bot-entry .avatar svg { width: 23px; height: 23px; }
  .sidebar.collapsed .sidebar-foot { display: grid; justify-items: center; }
  .sidebar.collapsed .nav-button { width: 40px; height: 40px; padding: 8px; justify-content: center; }
}
@media (max-width: 1080px) {
  .app { --sidebar-width: 250px; }
  .app.collapsed { --sidebar-width: 76px; }
  .app.agent-open { grid-template-columns: var(--sidebar-width) minmax(0, 1fr); }
  .agent-panel { position: fixed; z-index: 6; right: 0; top: 0; bottom: 0; width: min(360px, calc(100% - 28px)); box-shadow: -8px 0 35px #0007; }
  .agent-backdrop:not([hidden]) { display: block; position: fixed; z-index: 5; inset: 0; background: #0008; }
}
@media (max-width: 720px) {
  .app, .app.agent-open { display: block; }
  .main { height: 100%; }
  .mobile-only, .mobile-backdrop:not([hidden]) { display: inline-flex; }
  .sidebar { position: fixed; top: 0; bottom: 0; left: 0; width: min(340px, calc(100% - 32px)); z-index: 4; visibility: hidden; transform: translateX(-100%); }
  .sidebar.open { visibility: visible; transform: translateX(0); }
  .desktop-toggle { display: none; }
  .mobile-backdrop { position: fixed; z-index: 3; inset: 0; background: #0008; width: 100%; }
  .topbar { min-height: 60px; padding: 0 8px; gap: 6px; align-items: center; }
  .title-cluster { min-width: 0; max-width: none; padding: 0; border: 0; background: transparent; }
  .session-title { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .top-actions { padding: 0; gap: 4px; }
  .sim { font-size: 10px; gap: 3px; }
  .top-actions .icon-button { width: 34px; }
  .thread { padding: 14px 14px 8px; }
  .composer-wrap { padding: 4px 10px max(10px, env(safe-area-inset-bottom)); }
  .bubble { font-size: 15px; max-width: 92%; }
  .welcome { padding: 10px 0; }
  .suggestion-grid { margin-top: 16px; }
  .suggestion { padding: 10px; gap: 6px; }
  .suggestion > svg:last-child { display: none; }
}
@media (max-width: 460px) {
  .login-card { padding: 24px; }
  .login-card .brand { margin-bottom: 30px; }
  .suggestion-grid { grid-template-columns: 1fr; }
  .suggestion strong, .suggestion small { display: inline; }
  .suggestion small { margin-left: 6px; }
  .panel-dialog { border-radius: 15px; width: calc(100% - 16px); max-height: 94dvh; }
  .panel-dialog .dialog-content { max-height: 94dvh; }
  .dialog-head { padding: 18px 16px 14px; }
  .dialog-body, .dialog-foot { padding: 15px; }
  .field-grid { gap: 12px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
