@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Inter:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;
  --bg: #090c10;
  --panel: #0f141b;
  --panel-2: #121922;
  --panel-3: #171f2a;
  --line: #25303d;
  --line-soft: #1a232e;
  --text: #eef4f7;
  --muted: #8996a5;
  --faint: #596675;
  --accent: #55e6a5;
  --accent-strong: #2bd98c;
  --accent-soft: rgba(85, 230, 165, .11);
  --blue: #61a9ff;
  --blue-soft: rgba(97, 169, 255, .11);
  --orange: #ffb86a;
  --red: #ff6b78;
  --shadow: 0 24px 70px rgba(0, 0, 0, .28);
  --radius: 14px;
  --mono: 'DM Mono', ui-monospace, SFMono-Regular, Consolas, monospace;
  --sans: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html[data-theme='light'] {
  color-scheme: light;
  --bg: #edf1f4;
  --panel: #ffffff;
  --panel-2: #f7f9fa;
  --panel-3: #edf2f4;
  --line: #d9e0e5;
  --line-soft: #e9eef1;
  --text: #15202b;
  --muted: #64717e;
  --faint: #97a2ab;
  --accent: #06965d;
  --accent-strong: #04794c;
  --accent-soft: rgba(6, 150, 93, .09);
  --blue: #277bd6;
  --blue-soft: rgba(39, 123, 214, .09);
  --orange: #bd6b16;
  --red: #db3d50;
  --shadow: 0 24px 70px rgba(41, 57, 69, .10);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; overflow: hidden; background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 14px; }
button, input, textarea, select { color: inherit; font: inherit; }
button, a, label { -webkit-tap-highlight-color: transparent; }
button { border: 0; cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
button:disabled { cursor: not-allowed; opacity: .42; }
a { color: inherit; text-decoration: none; }

.app-shell { height: 100dvh; min-height: 0; display: flex; flex-direction: column; }
.topbar { width: 100%; height: 56px; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; background: transparent; position: absolute; inset: 0 0 auto; z-index: 10; pointer-events: none; }
.brand { display: flex; gap: 11px; align-items: center; }
.brand, .topbar-actions { pointer-events: auto; }
.brand-mark { width: 34px; height: 34px; border: 1px solid color-mix(in srgb, var(--accent) 60%, var(--line)); border-radius: 9px; display: grid; place-items: center; position: relative; background: var(--accent-soft); box-shadow: inset 0 0 20px rgba(85,230,165,.06); }
.brand-mark i { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.brand-mark i:nth-child(1) { transform: translate(-7px, -4px); }
.brand-mark i:nth-child(2) { transform: translate(7px, 4px); }
.brand-mark i:nth-child(3) { width: 13px; height: 1px; transform: rotate(29deg); border-radius: 0; }
.brand > span:last-child { display: flex; flex-direction: column; gap: 1px; }
.brand strong { font-size: 15px; letter-spacing: -.01em; }
.brand small { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .16em; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.connection-chip { height: 31px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 600; }
.connection-chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--faint); }
.connection-chip.open { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 35%, var(--line)); background: var(--accent-soft); }
.connection-chip.open i { background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.connection-chip.connecting i { background: var(--orange); animation: pulse 1s infinite; }
.icon-button { min-width: 34px; height: 34px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); color: var(--muted); display: inline-grid; place-items: center; transition: .18s ease; }
.icon-button:hover { color: var(--text); border-color: var(--faint); background: var(--panel-3); }
.danger-hover:hover { color: var(--red); }

.workspace { width: 100%; margin: 0; padding: 0 10px 10px; flex: 1 1 auto; min-height: 0; display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 10px; }
.panel { border: 1px solid var(--line-soft); border-top: 0; border-radius: 0 0 10px 10px; background: var(--panel); box-shadow: var(--shadow); overflow: hidden; }
.sidebar { height: 100%; min-height: 0; padding: 72px 18px 18px; display: flex; flex-direction: column; overflow: auto; }
.panel-heading, .content-header, .dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.panel-heading { margin-bottom: 22px; }
.eyebrow { color: var(--accent); font: 500 9px/1 var(--mono); letter-spacing: .2em; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 19px; margin-top: 5px; letter-spacing: -.03em; }
h2 { font-size: 18px; letter-spacing: -.02em; }
h3 { font-size: 13px; }
.field-label { display: flex; justify-content: space-between; margin: 0 0 7px; color: var(--muted); font-size: 11px; font-weight: 600; }
.field-label em { color: var(--faint); font-style: normal; font-weight: 400; }
.url-field { height: 43px; display: flex; align-items: center; border: 1px solid var(--line); border-radius: 9px; background: var(--panel-2); overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.url-field:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.url-field span { height: 100%; display: grid; place-items: center; padding: 0 10px; border-right: 1px solid var(--line); color: var(--accent); font: 500 10px var(--mono); background: var(--accent-soft); }
.url-field input { min-width: 0; width: 100%; height: 100%; padding: 0 11px; border: 0; outline: 0; background: transparent; font: 12px var(--mono); }
.button-row { display: flex; gap: 8px; }
.connection-actions { margin-top: 10px; }
.primary-button, .secondary-button, .send-button { min-height: 39px; padding: 0 15px; border-radius: 8px; font-size: 12px; font-weight: 650; display: inline-flex; justify-content: center; align-items: center; gap: 8px; transition: .18s ease; }
.primary-button { background: var(--accent); color: #06160f; }
.primary-button:hover { background: var(--accent-strong); transform: translateY(-1px); }
.secondary-button { border: 1px solid var(--line); background: var(--panel-2); color: var(--muted); }
.secondary-button:hover:not(:disabled) { color: var(--text); border-color: var(--faint); }
.compact { min-height: 30px; padding: 0 11px; }
.ghost-button, .text-button { background: transparent; color: var(--muted); font-size: 11px; }
.ghost-button:hover, .text-button:hover { color: var(--accent); }
.connection-actions .primary-button { flex: 1; }
.button-led { width: 6px; height: 6px; border-radius: 50%; background: #071b12; }

.connection-facts { margin: 19px 0 15px; display: grid; grid-template-columns: repeat(3, 1fr); padding: 13px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.connection-facts div { padding: 0 9px; border-right: 1px solid var(--line-soft); min-width: 0; }
.connection-facts div:first-child { padding-left: 0; }
.connection-facts div:last-child { border: 0; padding-right: 0; }
.connection-facts span, .connection-facts strong { display: block; }
.connection-facts span { color: var(--faint); font-size: 9px; margin-bottom: 5px; }
.connection-facts strong { color: var(--muted); font: 500 10px var(--mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.connection-facts strong.online { color: var(--accent); }

.settings-block { margin-bottom: 16px; border-bottom: 1px solid var(--line-soft); }
.settings-block summary { padding: 4px 0 14px; color: var(--muted); cursor: pointer; display: flex; justify-content: space-between; font-size: 11px; font-weight: 600; list-style: none; }
.settings-block summary::-webkit-details-marker { display: none; }
.settings-block[open] summary span { transform: rotate(180deg); }
.settings-content { padding-bottom: 16px; }
.text-input { width: 100%; height: 37px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; background: var(--panel-2); font: 11px var(--mono); }
.text-input:focus { border-color: var(--accent); }
.two-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.switch-row { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; cursor: pointer; }
.switch-row span { display: flex; flex-direction: column; gap: 2px; }
.switch-row strong { font-size: 11px; }
.switch-row small { color: var(--faint); font-size: 9px; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch-row i { width: 35px; height: 20px; border-radius: 999px; background: var(--panel-3); border: 1px solid var(--line); position: relative; transition: .2s; }
.switch-row i::after { content: ''; position: absolute; width: 14px; height: 14px; left: 2px; top: 2px; border-radius: 50%; background: var(--muted); transition: .2s; }
.switch-row input:checked + i { background: var(--accent-soft); border-color: var(--accent); }
.switch-row input:checked + i::after { background: var(--accent); transform: translateX(15px); }
.notice-card { display: flex; gap: 10px; padding: 11px; border: 1px solid color-mix(in srgb, var(--orange) 25%, var(--line)); border-radius: 9px; background: color-mix(in srgb, var(--orange) 6%, var(--panel-2)); color: var(--muted); }
.notice-icon { flex: 0 0 18px; width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; color: var(--orange); border: 1px solid var(--orange); font: 500 10px var(--mono); }
.notice-card p { font-size: 9px; line-height: 1.65; }
.notice-card strong { color: var(--orange); font-size: 10px; }
.mini-console { margin-top: auto; padding-top: 20px; min-height: 160px; }
.section-title { margin-bottom: 9px; display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; font-weight: 650; }
.section-title button { background: none; color: var(--faint); font-size: 9px; }
.event-list { height: 122px; overflow: auto; padding: 9px; border: 1px solid var(--line-soft); border-radius: 8px; background: var(--bg); font: 9px/1.8 var(--mono); }
.event-line { display: grid; grid-template-columns: 48px 42px 1fr; gap: 5px; color: var(--muted); }
.event-line time { color: var(--faint); }.event-line b { color: var(--blue); font-weight: 500; }.event-line.success b { color: var(--accent); }.event-line.error b { color: var(--red); }.event-line.warn b { color: var(--orange); }

.main-panel { height: 100%; min-height: 0; max-height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.tabs { height: 56px; flex: 0 0 56px; padding: 0 22px; display: flex; align-items: end; border-bottom: 1px solid var(--line-soft); }
.tab { align-self: stretch; padding: 2px 17px 0; background: transparent; color: var(--muted); font-size: 12px; font-weight: 600; border-bottom: 2px solid transparent; }
.tab:hover { color: var(--text); }.tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab span { margin-left: 5px; padding: 1px 5px; border-radius: 6px; background: var(--panel-3); color: var(--faint); font: 9px var(--mono); }.tab.active span { background: var(--accent-soft); color: var(--accent); }
.tab-panel { display: none; min-height: 0; flex: 1; }.tab-panel.active { display: flex; flex-direction: column; overflow: hidden; }
.toolbar { min-height: 55px; padding: 10px 18px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--line-soft); }
.toolbar-spacer { flex: 1; }
.segmented { display: flex; padding: 3px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); }
.segmented button, .mode-tabs button { min-height: 26px; padding: 0 11px; border-radius: 5px; background: transparent; color: var(--muted); font-size: 10px; }
.segmented button.active, .mode-tabs button.active { background: var(--panel-3); color: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,.15); }
.search-field { width: 180px; height: 34px; display: flex; align-items: center; gap: 5px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); padding: 0 9px; color: var(--faint); }
.search-field:focus-within { border-color: var(--accent); }.search-field input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 10px; }
.message-default-control { height: 34px; display: flex; align-items: center; gap: 6px; padding: 0 5px 0 9px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-2); color: var(--faint); white-space: nowrap; font-size: 9px; }
.message-default-control select { height: 25px; padding: 0 20px 0 7px; border: 0; border-radius: 5px; outline: 0; background: var(--panel-3); color: var(--text); font-size: 9px; cursor: pointer; }.message-default-control:focus-within { border-color: var(--accent); }
.message-list { min-height: 0; flex: 1 1 0; overflow: auto; overscroll-behavior: contain; position: relative; background: var(--panel); }
.empty-state { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; background: color-mix(in srgb, var(--panel) 91%, transparent); }.empty-state[hidden] { display: none; }
.empty-state h2 { margin-top: 22px; font-size: 15px; }.empty-state p { margin-top: 7px; color: var(--muted); font-size: 10px; }.empty-state > div:last-child { margin-top: 19px; color: var(--faint); display: flex; align-items: center; gap: 6px; font-size: 9px; }
kbd { padding: 3px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; background: var(--panel-2); color: var(--muted); font: 9px var(--mono); }
.empty-orbit { width: 64px; height: 64px; border: 1px solid var(--line); border-radius: 50%; display: grid; place-items: center; position: relative; color: var(--accent); font-size: 25px; }
.empty-orbit::before { content: ''; position: absolute; inset: 10px; border: 1px dashed var(--line); border-radius: 50%; }.empty-orbit i { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }.empty-orbit i:nth-child(1){top:-2px}.empty-orbit i:nth-child(2){right:2px;bottom:10px}.empty-orbit i:nth-child(3){left:4px;bottom:8px;background:var(--blue)}
.message-item { padding: 13px 18px; border-bottom: 1px solid var(--line-soft); background: color-mix(in srgb, var(--panel) 94%, transparent); animation: message-in .2s ease both; transition: padding .18s ease, background .18s ease; }
.message-item:hover { background: color-mix(in srgb, var(--panel-2) 96%, transparent); }
.message-meta { display: flex; align-items: center; gap: 8px; min-width: 0; cursor: default; }.direction-icon { width: 19px; height: 19px; display: grid; place-items: center; border-radius: 5px; background: var(--blue-soft); color: var(--blue); font-size: 11px; }.message-item.out .direction-icon { background: var(--accent-soft); color: var(--accent); }.message-item.system .direction-icon { background: color-mix(in srgb, var(--orange) 10%, transparent); color: var(--orange); }
.direction-label { font-size: 10px; color: var(--blue); }.message-item.out .direction-label { color: var(--accent); }.message-item.system .direction-label { color: var(--orange); }
.message-meta time, .message-size { color: var(--faint); font: 9px var(--mono); }.kind-badge { padding: 2px 5px; border-radius: 4px; background: var(--panel-3); color: var(--muted); font: 8px var(--mono); text-transform: uppercase; }.collapse-message, .copy-message { background: none; color: var(--muted); font-size: 9px; opacity: .72; }.collapse-message { margin-left: auto; }.copy-message { opacity: 0; }.message-item:hover .copy-message, .message-item:hover .collapse-message { opacity: 1; }.collapse-message:hover, .copy-message:hover { color: var(--accent); }
.message-item pre { margin: 8px 0 0 27px; color: var(--text); font: 10px/1.65 var(--mono); white-space: pre-wrap; word-break: break-word; max-height: 220px; overflow: auto; transition: max-height .18s ease, margin .18s ease, opacity .18s ease; }
.message-item.collapsed { padding-top: 7px; padding-bottom: 7px; }
.message-item.collapsed pre { margin-top: 3px; max-height: 16px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; opacity: .62; }
.message-item.collapsed .direction-icon { width: 17px; height: 17px; }
.json-key { color: #7fc8ff; }.json-string { color: #8ee6b5; }.json-number { color: #d8a8ff; }.json-literal { color: #ffb86a; }
html[data-theme='light'] .json-key { color: #1268a8; }html[data-theme='light'] .json-string { color: #087b4d; }html[data-theme='light'] .json-number { color: #7d39a8; }html[data-theme='light'] .json-literal { color: #a44f00; }
.message-item.filtered { display: none; }

.composer { height: var(--composer-height, 220px); min-height: 170px; max-height: min(62vh, 560px); flex: 0 0 auto; border-top: 1px solid var(--line); background: var(--panel-2); display: flex; flex-direction: column; position: relative; }
.composer-resize-handle { height: 11px; flex: 0 0 11px; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--line-soft); background: var(--panel); cursor: ns-resize; user-select: none; color: var(--faint); overflow: hidden; }
.composer-resize-handle i { width: 34px; height: 3px; border-radius: 999px; background: var(--line); transition: .15s ease; }.composer-resize-handle span { position: absolute; right: 13px; opacity: 0; font: 8px var(--mono); transition: .15s ease; }.composer-resize-handle:hover i, .composer-resize-handle:focus-visible i, .resizing-composer .composer-resize-handle i { width: 48px; background: var(--accent); }.composer-resize-handle:hover span, .composer-resize-handle:focus-visible span, .resizing-composer .composer-resize-handle span { opacity: 1; }.resizing-composer { cursor: ns-resize; user-select: none; }
.composer-topline { min-height: 39px; padding: 6px 15px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line-soft); }
.mode-tabs { display: flex; gap: 2px; }.composer-tools { display: flex; align-items: center; gap: 3px; }.composer-tools button, .file-button { padding: 5px 7px; border-radius: 5px; background: transparent; color: var(--faint); font-size: 9px; cursor: pointer; }.composer-tools button:hover, .file-button:hover { color: var(--text); background: var(--panel-3); }.file-button input { display: none; }
.editor-wrap { position: relative; flex: 1 1 auto; min-height: 45px; }.editor-wrap textarea { width: 100%; height: 100%; resize: none; padding: 13px 18px 26px; border: 0; outline: 0; background: transparent; color: var(--text); font: 11px/1.65 var(--mono); }
.payload-size { position: absolute; right: 15px; bottom: 7px; color: var(--faint); font: 8px var(--mono); }
.composer-footer { min-height: 52px; padding: 7px 15px; display: flex; align-items: center; gap: 8px; border-top: 1px solid var(--line-soft); }
.checkbox-label { color: var(--muted); font-size: 9px; }.checkbox-label input { accent-color: var(--accent); vertical-align: -2px; }
.send-button { min-width: 132px; background: var(--accent); color: #06160f; }.send-button:hover:not(:disabled) { background: var(--accent-strong); }.send-button kbd { border-color: rgba(0,0,0,.22); background: rgba(0,0,0,.08); color: #06160f; }
.interval-bar { min-height: 46px; padding: 7px 15px; border-top: 1px solid var(--line-soft); align-items: center; gap: 16px; color: var(--muted); font-size: 9px; }.interval-bar:not([hidden]) { display: flex; }.interval-bar input { width: 80px; height: 29px; margin-left: 5px; padding: 0 7px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }.interval-bar em { color: var(--faint); font-style: normal; }.interval-bar span { flex: 1; color: var(--faint); }

.content-header { padding: 24px; border-bottom: 1px solid var(--line-soft); align-items: center; }.content-header p { margin-top: 5px; color: var(--muted); font-size: 10px; }.template-grid { padding: 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; overflow: auto; }.template-card { padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }.template-card header { display: flex; align-items: center; gap: 8px; }.template-card h3 { flex: 1; }.template-card .kind-badge { color: var(--accent); }.template-card pre { height: 90px; overflow: auto; margin: 12px 0; padding: 9px; border-radius: 7px; background: var(--bg); color: var(--muted); font: 9px/1.55 var(--mono); white-space: pre-wrap; word-break: break-word; }.template-card footer { display: flex; justify-content: flex-end; gap: 7px; }.template-card footer button { min-height: 28px; padding: 0 9px; }
.stats-grid { padding: 20px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 11px; }.stats-grid article { min-width: 0; padding: 17px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); display: flex; gap: 12px; align-items: center; }.stats-grid article > span { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font: 15px var(--mono); }.stats-grid article div { min-width: 0; display: flex; flex-direction: column; gap: 3px; }.stats-grid small { color: var(--muted); font-size: 9px; }.stats-grid strong { font: 500 19px var(--mono); overflow: hidden; text-overflow: ellipsis; }.stats-grid em { color: var(--faint); font: normal 8px var(--mono); }.session-details { margin: 0 20px 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); overflow: hidden; }.session-details h3 { padding: 14px 16px; border-bottom: 1px solid var(--line-soft); }.session-details dl { margin: 0; }.session-details dl div { min-height: 42px; padding: 10px 16px; display: grid; grid-template-columns: 110px 1fr; align-items: center; border-bottom: 1px solid var(--line-soft); }.session-details dl div:last-child { border: 0; }.session-details dt { color: var(--muted); font-size: 9px; }.session-details dd { margin: 0; font: 10px var(--mono); word-break: break-all; }

footer { min-height: 22px; flex: 0 0 22px; padding: 0 16px; display: flex; justify-content: flex-end; align-items: center; gap: 18px; color: var(--faint); font: 8px var(--mono); } footer span:first-child { margin-right: auto; } footer a:hover { color: var(--accent); }
.toast-stack { position: fixed; right: 14px; top: 66px; z-index: 50; display: flex; flex-direction: column; gap: 8px; }.toast { max-width: 340px; padding: 11px 14px; border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 8px; background: var(--panel-2); box-shadow: var(--shadow); color: var(--text); font-size: 10px; animation: toast-in .25s ease both; }.toast.error { border-left-color: var(--red); }.toast.warn { border-left-color: var(--orange); }
dialog { width: min(430px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--line); border-radius: 13px; background: var(--panel); color: var(--text); box-shadow: var(--shadow); }dialog::backdrop { background: rgba(2,5,8,.72); backdrop-filter: blur(4px); }dialog form { padding: 21px; }.dialog-heading { margin-bottom: 21px; }.dialog-heading h2 { margin-top: 5px; }.dialog-heading > button { width: 28px; height: 28px; background: transparent; color: var(--muted); font-size: 20px; }.template-field-label { margin-top: 14px; }.template-content-input { width: 100%; min-height: 150px; resize: vertical; padding: 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; background: var(--panel-2); font: 11px/1.6 var(--mono); }.template-content-input:focus { border-color: var(--accent); }.dialog-actions { margin-top: 18px; display: flex; justify-content: flex-end; gap: 8px; }.shortcut-list { display: grid; gap: 1px; border: 1px solid var(--line-soft); border-radius: 8px; overflow: hidden; }.shortcut-list div { padding: 11px; display: flex; justify-content: space-between; align-items: center; background: var(--panel-2); color: var(--muted); font-size: 10px; }

::-webkit-scrollbar { width: 7px; height: 7px; }::-webkit-scrollbar-track { background: transparent; }::-webkit-scrollbar-thumb { background: var(--line); border-radius: 999px; }::-webkit-scrollbar-thumb:hover { background: var(--faint); }
@keyframes pulse { 50% { opacity: .3; transform: scale(.75); } }@keyframes message-in { from { opacity: 0; transform: translateY(4px); } }@keyframes toast-in { from { opacity: 0; transform: translateX(12px); } }

@media (max-width: 1050px) {
  .workspace { grid-template-columns: 280px minmax(0, 1fr); padding: 0 8px 8px; gap: 8px; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .search-field { width: 140px; }
}

@media (max-width: 780px) {
  body { overflow: auto; }.app-shell { height: auto; min-height: 100dvh; }
  .topbar { height: 60px; flex: 0 0 60px; padding: 0 14px; border-bottom: 1px solid var(--line-soft); background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(16px); position: sticky; pointer-events: auto; }.github-link, #shortcutsButton { display: none; }.connection-chip span { display: none; }.connection-chip { width: 31px; padding: 0; justify-content: center; }
  .workspace { display: block; flex: none; padding: 0 8px 8px; }.sidebar { height: auto; min-height: auto; padding: 16px; margin-bottom: 8px; overflow: visible; }.mini-console { min-height: 0; }.event-list { height: 90px; }.main-panel { min-height: 720px; height: calc(100dvh - 72px); max-height: none; }
  .tabs { height: 49px; flex-basis: 49px; padding: 0 5px; }.tab { flex: 1; padding-left: 5px; padding-right: 5px; font-size: 11px; }.toolbar { padding: 8px; flex-wrap: wrap; }.segmented { order: 2; }.search-field { flex: 1; width: auto; }.message-default-control { order: 2; }.toolbar-spacer { display: none; }
  .message-list { min-height: 230px; }.composer { max-height: 55vh; }.composer-topline { padding: 5px 8px; }.composer-tools button { display: none; }.editor-wrap textarea { padding-left: 12px; }.composer-footer { padding: 7px 8px; flex-wrap: wrap; }.composer-footer .toolbar-spacer { display: block; }.checkbox-label, #saveTemplateButton, #pingButton { display: none; }.send-button { min-width: 110px; }.interval-bar:not([hidden]) { flex-wrap: wrap; gap: 8px; }.interval-bar span { flex-basis: 100%; order: 3; }
  .stats-grid { padding: 12px; grid-template-columns: 1fr 1fr; }.stats-grid article { padding: 12px; }.stats-grid article > span { display: none; }.session-details { margin: 0 12px 12px; }.template-grid { grid-template-columns: 1fr; padding: 12px; }.content-header { padding: 16px; }
  footer { padding: 0 12px; } footer span:nth-child(2) { display: none; }
}

@media (max-width: 420px) {
  .connection-facts { grid-template-columns: 1fr 1fr 1fr; }.sidebar { border-radius: 0 0 10px 10px; }.main-panel { border-radius: 10px; }.mode-tabs button { padding: 0 8px; }.stats-grid { grid-template-columns: 1fr; }.message-item { padding-left: 12px; padding-right: 12px; }.message-item pre { margin-left: 0; }.message-size { display: none; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
