:root {
  --blue: #1f93ff;
  --blue-soft: #e8f3ff;
  --text: #3c4858;
  --muted: #6f767e;
  --line: #e4e8eb;
  --bg: #f4f6fb;
  --bubble-in: #f1f5f8;
  --bubble-out: #d3e9ff;
  --green: #2bcc91;
  color: var(--text);
  background: #fff;
  font: 14px/1.45 Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html.authed #login { display: none !important; }
html.authed #shell { display: flex !important; }
html, body { height: 100%; }
body { margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, p { margin: 0; }

.mark {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: url("/desk/mark.svg?v=20261026-filter5") center / contain no-repeat;
  flex: none;
}

.login {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #f4f7fd;
  padding: 24px;
}
.logo-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 20px;
  font-weight: 650;
}
.login-title { font-size: 28px; font-weight: 700; margin-bottom: 20px; }
.login-card {
  width: min(420px, 100%);
  background: #fff;
  border-radius: 8px;
  padding: 28px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .06);
}
.login-card label { display: block; font-size: 13px; font-weight: 600; margin: 0 0 14px; }
.login-card input, .settings-body input, .settings-body textarea, .settings-body select {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  border: 0;
  border-radius: 6px;
  background: var(--bg);
  font-weight: 400;
}
.login-card button, .primary {
  border: 0;
  background: var(--blue);
  color: #fff;
  border-radius: 6px;
  height: 40px;
  padding: 0 14px;
  font-weight: 600;
}
.login-card button { width: 100%; margin-top: 8px; }
button:disabled { opacity: 0.6; cursor: default; }
.error { color: #c2410c; }
.banner { margin: 0 16px 8px; }

.shell { height: 100%; display: flex; flex-direction: row; }
.nav {
  width: 224px;
  flex: 0 0 224px;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  background: #fff;
  min-width: 224px;
}
.brand {
  height: 56px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  font-weight: 650;
}
.search-pill {
  margin: 0 12px 12px;
  height: 36px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--muted);
}
.search-pill input {
  flex: 1;
  border: 0;
  outline: 0;
  min-width: 0;
  background: transparent;
  color: var(--text);
}
.menu { flex: 1; padding: 4px 10px; }
.menu button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  height: 36px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  border-radius: 8px;
}
.menu button.on, .menu button[aria-selected="true"] {
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 600;
}
.agent {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  position: relative;
}
.agent-btn { border: 0; background: none; padding: 0; position: relative; flex: none; }
.agent-meta { min-width: 0; flex: 1; }
.agent-meta strong, .agent-meta small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.agent-meta small { color: var(--muted); font-size: 12px; }
.ava {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  background: #7b8cff;
}
.dot {
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #98a2b3;
  border: 2px solid #fff;
}
.dot.online { background: var(--green); }
.dot.busy { background: #f5a524; }
.menu-pop button.picked { color: var(--blue); font-weight: 700; }
.menu-pop {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 58px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  z-index: 5;
}
.menu-pop button {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: #fff;
  padding: 8px 12px;
}
.menu-pop button:hover { background: var(--bg); }

.list-pane {
  width: 360px;
  flex: none;
  height: 100%;
  min-height: 0;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  background: #fff;
  position: relative;
}
.list-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px 8px;
}
.list-head h1 { font-size: 17px; flex: 1; min-width: 2em; }
.date-ctrl { display: flex; align-items: center; gap: 2px; flex: none; white-space: nowrap; }
.date-btn {
  height: 28px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-radius: 6px;
  font-size: 13px;
}
.date-btn:hover { background: var(--bg); color: var(--text); }
.date-btn.on { color: var(--blue); background: var(--blue-soft); font-weight: 650; }
.date-btn svg { flex: none; }
select.source-select {
  appearance: none;
  -webkit-appearance: none;
  display: inline-block;
  width: 6.8em;
  height: 28px;
  line-height: 28px;
  padding: 0 18px 0 8px;
  background-color: transparent;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'><path fill='none' stroke='%236b7280' stroke-width='1.4' d='M1 1l4 4 4-4'/></svg>");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 10px 6px;
  cursor: pointer;
}
select.source-select.on {
  font-weight: 400;
  background: var(--blue-soft) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'><path fill='none' stroke='%231f93ff' stroke-width='1.4' d='M1 1l4 4 4-4'/></svg>") no-repeat right 6px center / 10px 6px;
}
.cal {
  position: absolute;
  top: 48px;
  right: 12px;
  z-index: 8;
  width: 280px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 32px rgba(16, 24, 40, .10);
  padding: 12px;
}
.cal-head { display: flex; align-items: center; gap: 4px; margin-bottom: 8px; }
.cal-head b { flex: 1; text-align: center; font-size: 13px; font-weight: 650; }
.cal-nav {
  width: 28px;
  height: 28px;
  border: 0;
  background: var(--bg);
  border-radius: 6px;
  color: var(--muted);
}
.cal-week, .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal-week span {
  height: 24px;
  display: grid;
  place-items: center;
  font-size: 11px;
  color: var(--muted);
}
.cal-grid button {
  height: 32px;
  border: 0;
  background: transparent;
  border-radius: 6px;
  font-size: 13px;
}
.cal-grid button:hover:not(:disabled) { background: var(--bg); }
.cal-grid button:disabled { color: #c5cad1; }
.cal-grid button.today { color: var(--blue); font-weight: 650; }
.cal-grid button.pick { background: var(--blue); color: #fff; font-weight: 650; }
.cal-grid button.pick:hover { background: var(--blue); color: #fff; }
.cal-quick {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.cal-quick button {
  flex: 1;
  height: 28px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
  font-size: 12px;
}
.tabs { display: flex; gap: 16px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.tabs button {
  border: 0;
  background: none;
  padding: 10px 0;
  color: var(--muted);
  position: relative;
}
.tabs button[aria-selected="true"] { color: var(--blue); font-weight: 650; }
.tabs button[aria-selected="true"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: var(--blue);
}
.rows { overflow: auto; flex: 1; min-height: 0; }
.row {
  width: 100%;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 10px;
  padding: 12px 16px;
  border: 0;
  background: #fff;
  text-align: left;
  border-bottom: 1px solid #f2f4f7;
  align-items: start;
}
.row:focus { outline: none; }
.row.active { background: #f5f7fb; }
.row.flash { animation: incoming-flash 1.2s ease; }
.row.active.flash { animation-name: incoming-flash-active; }
@keyframes incoming-flash {
  0% { background: #fff4e8; }
  100% { background: #fff; }
}
@keyframes incoming-flash-active {
  0% { background: #fff4e8; }
  100% { background: #f5f7fb; }
}
.row .ava { width: 36px; height: 36px; }
.ava.wide { font-size: 11px; letter-spacing: -0.04em; }
.row .content {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.row .main {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-rows: 19px minmax(18px, auto);
  gap: 2px;
}
.row-title {
  font-weight: 650;
  line-height: 1.35;
  overflow: visible;
  white-space: normal;
  word-break: break-all;
}
.row-company {
  min-height: 18px;
  font-size: 13px;
  line-height: 1.35;
  color: var(--text);
  overflow: visible;
  white-space: normal;
}
.row .meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.row .meta-extra {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  min-height: 18px;
}
.row-time { font-size: 12px; text-align: right; color: var(--muted); white-space: nowrap; }
.unread {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-top: 6px;
  border-radius: 9px;
  background: var(--green);
  color: #fff;
  font-size: 11px;
}
.row .meta .unread { margin-top: 0; }
.chip {
  display: inline-block;
  margin-top: 4px;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 4px;
  background: #f2f4f7;
  color: var(--muted);
}
.row .meta .chip { margin-top: 0; }
.row .flag { margin-left: 0; }
.chip.queue { background: #fff4ed; color: #c2410c; }
.chip.help { background: var(--blue-soft); color: var(--blue); }
.empty-list { color: var(--muted); padding: 24px 16px; }

.main-pane { flex: 1; min-width: 0; display: flex; background: #fff; }
.empty, .thread, .settings { flex: 1; min-width: 0; }
.empty { display: grid; place-content: center; justify-items: center; color: var(--muted); gap: 12px; }
.blob {
  width: 88px;
  height: 72px;
  border-radius: 40px 40px 18px 40px;
  background: #eef3fb;
}
.thread { display: flex; flex-direction: column; min-height: 0; }
.thread-head {
  min-height: 56px;
  height: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
}
.who { flex: 1; min-width: 0; }
.thread-head h1 {
  font-size: 14px;
  line-height: 1.35;
  overflow: visible;
  white-space: normal;
  word-break: break-all;
}
.thread-head p { color: var(--muted); font-size: 12px; line-height: 1.35; white-space: normal; }
.flag { color: #c2410c; font-weight: 500; margin-left: 8px; font-size: 12px; }
.ghost {
  height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
}
.thread-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  flex: 1 1 auto;
}
.thread-actions .primary { height: 32px; }
.thread-actions .status-note { color: var(--muted); font-size: 12px; }
.thread-back { display: none; }
.messages { flex: 1; overflow: auto; padding: 16px 20px; display: flex; flex-direction: column; gap: 10px; }
.bubble {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: min(62%, 520px);
  padding: 10px 12px;
  border-radius: 12px;
  white-space: pre-wrap;
  word-break: break-word;
}
/* Flex item: min-width auto would keep a long URL from wrapping inside the bubble. */
.bubble-text {
  min-width: 0;
  max-width: 100%;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.bubble-text a {
  color: #1f93ff;
  text-decoration: underline;
}
.bubble.customer { align-self: flex-start; background: var(--bubble-in); }
.bubble.agent { align-self: flex-end; background: var(--bubble-out); }
.bubble.system {
  align-self: center;
  background: #f2f4f7;
  color: var(--muted);
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 12px;
  max-width: 80%;
}
.bubble time { display: block; margin-top: 6px; font-size: 12px; color: var(--muted); }
.bubble.system time { display: none; }
.bubble.recalled {
  align-self: center;
  max-width: 80%;
  background: #f2f4f7;
  color: var(--muted);
  font-size: 12px;
  padding: 4px 10px;
}
.msg-menu {
  position: fixed;
  z-index: 40;
  min-width: 160px;
  background: #fff;
  border-radius: 8px;
  padding: 4px 0;
  box-shadow: 0 10px 32px rgba(16, 24, 40, .14), 0 0 0 1px rgba(16, 24, 40, .05);
}
.msg-menu button {
  display: block;
  width: 100%;
  height: 38px;
  border: 0;
  background: transparent;
  text-align: left;
  padding: 0 18px;
  font-size: 14px;
  color: #1d2129;
}
.msg-menu button:hover,
.msg-menu button:focus-visible { background: #f5f7fb; }
.quote-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 4px 8px;
  padding: 6px 8px;
  border-radius: 7px;
  background: #eef1f6;
  color: #667085;
  font-size: 13px;
}
.quote-bar[hidden] { display: none !important; }
.quote-bar-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.quote-bar-text b { font-weight: 650; }
.quote-bar button {
  flex: none;
  border: 0;
  background: transparent;
  color: #667085;
  padding: 4px 6px;
  line-height: 1;
}
.quote-chip {
  display: block;
  width: max-content;
  max-width: 100%;
  margin-bottom: 4px;
  padding: 2px 6px;
  border: 0;
  border-radius: 6px;
  background: rgba(16, 24, 40, 0.08);
  color: #667085;
  font-size: 12px;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bubble.agent .quote-chip,
.bubble.internal .quote-chip { background: rgba(31, 147, 255, 0.14); }
.bubble img, .bubble video {
  display: block;
  max-width: 240px;
  max-height: 180px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  margin-top: 6px;
}
.bubble img { cursor: zoom-in; }
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(16, 24, 40, 0.72);
}
.lightbox img {
  max-width: min(80vw, 1100px);
  max-height: 80vh;
  border-radius: 8px;
}
.lightbox p {
  position: absolute;
  bottom: 16px;
  left: 0;
  right: 0;
  margin: 0;
  text-align: center;
  color: #fff;
  font-size: 13px;
}
.bubble.internal {
  align-self: flex-end;
  background: #fff8eb;
  border: 1px dashed #e8c56b;
  color: #7a5b12;
}
.bubble .tag { display: inline-block; margin-bottom: 4px; font-size: 11px; font-weight: 700; }
.bubble .ai-label { color: var(--text); font-size: 12px; }
.composer-card.drag { border-color: var(--blue); background: var(--blue-soft); }
#pending img,
.pending img {
  display: block;
  max-width: 120px;
  max-height: 80px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  outline: 1px solid var(--line);
  background: var(--bg);
}
.pending-wrap { position: relative; display: inline-block; margin: 8px 0; }
.pending-x {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 18px;
  height: 18px;
  border: 0;
  border-radius: 50%;
  background: #1d2129;
  color: #fff;
  font-size: 12px;
  line-height: 18px;
  padding: 0;
}
.video-chip { display: inline-block; margin: 8px 0; padding: 4px 8px; border-radius: 6px; background: var(--bg); font-size: 12px; color: var(--muted); }
.file-card {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 6px;
  padding: 8px 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: inherit;
  text-decoration: none;
}
.file-kind {
  flex: none;
  font-size: 11px;
  font-weight: 700;
  color: #c2410c;
  background: #fff4ed;
  border-radius: 4px;
  padding: 2px 6px;
}
.file-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
}

.composer {
  position: relative;
  z-index: 2;
  flex: none;
  max-height: 42vh;
  overflow: visible;
  padding: 0 16px 16px;
}
.composer-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px 8px;
  background: #fff;
}
.reply-tab {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 12px;
  background: #f2f4f7;
  font-size: 13px;
  font-weight: 600;
}
.composer textarea {
  display: block;
  width: 100%;
  margin-top: 8px;
  border: 0;
  outline: 0;
  resize: none;
  min-height: 72px;
  background: transparent;
}
.composer-bar { display: flex; align-items: center; gap: 8px; }
.icon {
  width: 32px;
  height: 32px;
  border: 0;
  background: var(--bg);
  border-radius: 8px;
}
.composer-bar button[type="submit"] {
  margin-left: auto;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
}
.file-name { color: var(--muted); font-size: 12px; }
.pop {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 100%;
  margin-bottom: 8px;
  max-height: 220px;
  overflow: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  z-index: 3;
}
.pop button { display: block; width: 100%; text-align: left; border: 0; background: #fff; padding: 8px 12px; }
.pop button:hover { background: var(--bg); }
.emoji-pop { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; }
.emoji-pop button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  text-align: center;
  font-size: 22px;
  line-height: 1;
}

.settings { display: flex; min-height: 0; }
.settings-nav {
  width: 220px;
  border-right: 1px solid var(--line);
  padding: 16px 12px;
}
.settings-nav h2 { font-size: 16px; margin: 8px 10px 12px; }
.settings-nav button {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 8px 10px;
  border-radius: 8px;
}
.settings-nav button[aria-selected="true"] { background: var(--blue-soft); color: var(--blue); }
.settings-body { flex: 1; overflow: auto; padding: 28px 40px 48px; max-width: 720px; }
.settings-body h2 { font-size: 22px; margin-bottom: 24px; }
.settings-body label { display: block; font-size: 13px; font-weight: 650; margin: 0 0 16px; }
.settings-body label.check { display: flex; align-items: center; gap: 8px; }
.settings-body label.check input { width: auto; margin: 0; }
.settings-body textarea { min-height: 72px; }
.settings-body small { display: block; margin: 6px 0 0; font-weight: 400; }
.data { flex: 1; min-width: 0; overflow: auto; padding: 28px 32px 48px; }
.data-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.data-head h1 { font-size: 22px; }
.ranges { display: flex; gap: 8px; }
.ranges button {
  height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
}
.ranges button.on { background: var(--blue-soft); color: var(--blue); border-color: transparent; font-weight: 650; }
.stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.stat-grid.two { grid-template-columns: repeat(2, minmax(0, 280px)); }
.stat { border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; }
.stat span, .stat small, .stat p, .muted { color: var(--muted); }
.stat b { display: block; font-size: 22px; margin: 4px 0; color: var(--text); }
.stat p { margin-top: 8px; font-size: 12px; }
.data-empty { margin-top: 24px; }
.data-table { margin-top: 24px; overflow-x: auto; }
.data-table table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.data h2 { font-size: 16px; margin: 24px 0 8px; }
.reviews { list-style: none; padding: 0; margin: 0; }
.reviews li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.reviews time { color: var(--muted); margin-left: 8px; }
#data-retry { margin-top: 12px; }
@media (max-width: 800px) {
  .shell { flex-direction: column; height: 100dvh; }
  .nav { width: 100%; min-width: 0; flex: 0 0 auto; border-right: 0; }
  .brand { height: 44px; }
  .nav .menu { display: flex; gap: 4px; flex: none; }
  .nav .menu button { width: auto; }
  .nav .agent { padding: 8px 14px; }
  .nav .agent-meta small { display: none; }
  .list-pane { width: 100%; height: auto; flex: 1; border-right: 0; }
  .shell:not(.conversation-open):not(.settings-on):not(.data-on) .main-pane { display: none; }
  .shell.conversation-open .nav, .shell.conversation-open .list-pane { display: none; }
  .main-pane { min-height: 0; }
  .thread-back { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; }
  .thread-head { padding: 8px; gap: 8px; }
  .thread-head .ava { display: none; }
  .thread-actions { flex: 1 1 100%; }
  .thread-actions button { min-height: 40px; }
  .messages { padding: 12px; }
  .bubble { max-width: 90%; }
  .composer { padding: 8px; }
  .composer textarea, .login input { font-size: 16px; }
  .stat-grid, .stat-grid.two { grid-template-columns: 1fr; }
  .data { padding: 20px 16px 32px; }
}
.agent-row, .canned-row {
  display: grid;
  grid-template-columns: 1.2fr 1.4fr 120px auto;
  gap: 8px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.canned-row { grid-template-columns: 1fr auto; }
.agent-row button, .canned-row button {
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
}
.agent-row button.primary {
  border: 0;
  background: var(--blue);
  color: #fff;
}
.actions { margin-top: 8px; }
.toast {
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  background: #1f2937;
  color: #fff;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 13px;
}
.more {
  display: block;
  width: calc(100% - 24px);
  margin: 8px 12px 16px;
  height: 32px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 6px;
  color: var(--muted);
}
.dialog {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dialog .login-card { width: 360px; }
.dialog h2 { font-size: 18px; margin-bottom: 12px; }
.dialog .ghost { width: 100%; height: 40px; margin-top: 8px; }
.transfer-card {
  width: 360px;
  max-width: calc(100% - 32px);
  max-height: min(80vh, 560px);
  overflow: auto;
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, .06);
}
#transfer-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 320px;
  overflow: auto;
}
.pick {
  width: 100%;
  display: grid;
  grid-template-columns: 10px 1fr;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: #fff;
  text-align: left;
}
.pick:hover { background: var(--bg); }
.pick.on { background: var(--blue-soft); }
.pick .name { display: block; font-weight: 600; }
.pick .sub { display: block; color: var(--muted); font-size: 12px; }
.pick-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #c5cdd6;
}
.pick-dot.online { background: var(--green); }
.pick-dot.busy { background: #f5a524; }
.pick-dot.offline { background: #c5cdd6; }
#transfer-box .primary {
  width: 100%;
  height: 40px;
  margin-top: 8px;
}
#transfer-error { margin: 8px 0 0; }
.shell.settings-on .list-pane, .shell.data-on .list-pane { display: none; }
