:root {
  --bg: #0a0a0b;
  --bg-elev: #111114;
  --bg-card: #15151a;
  --bg-hover: #1c1c22;
  --bg-active: #23232c;
  --border: #232329;
  --border-strong: #2e2e36;
  --text: #ececf1;
  --text-muted: #8b8b95;
  --text-dim: #5d5d68;

  --accent: #7c83ff;       /* indigo */
  --accent-hover: #9298ff;
  --accent-soft: rgba(124, 131, 255, 0.12);
  --success: #34d399;
  --success-soft: rgba(52, 211, 153, 0.12);
  --warning: #fbbf24;
  --warning-soft: rgba(251, 191, 36, 0.12);
  --danger: #f87171;
  --danger-soft: rgba(248, 113, 113, 0.12);
  --info: #60a5fa;
  --info-soft: rgba(96, 165, 250, 0.12);

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;

  --shadow-card: 0 1px 0 rgba(255,255,255,0.02), 0 6px 20px -10px rgba(0,0,0,0.6);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.005em;
}
button { font-family: inherit; font-size: inherit; cursor: pointer; }
input { font-family: inherit; }
svg { width: 14px; height: 14px; flex-shrink: 0; }

.app {
  display: grid;
  grid-template-columns: 248px 1fr;
  height: 100vh;
}

/* ===== SIDEBAR ===== */
.sidebar {
  background: var(--bg-elev);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 14px 10px;
  gap: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px;
}
.brand-mark {
  width: 28px; height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, #7c83ff 0%, #5e63d6 100%);
  display: grid; place-items: center;
  color: #fff; font-weight: 700; font-size: 14px;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.06) inset;
}
.brand-name { font-weight: 600; font-size: 13px; }
.brand-sub { font-size: 11px; color: var(--text-muted); margin-top: 1px; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 8px;
  padding: 6px 10px;
  background: var(--success-soft);
  color: var(--success);
  border: 1px solid rgba(52,211,153,0.2);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 500;
}
.dot { width: 6px; height: 6px; border-radius: 50%; }
.dot-ok { background: var(--success); box-shadow: 0 0 6px var(--success); }
.dot-warn { background: var(--warning); }
.dot-bad { background: var(--danger); }

.usage-pill {
  margin: 4px 6px 8px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-elev);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.usage-pill-head { display: flex; justify-content: space-between; align-items: baseline; }
.usage-pill-label { font-size: 11px; color: var(--text-muted); font-weight: 500; letter-spacing: 0.02em; }
.usage-pill-pct { font-size: 13px; font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.usage-pill-bar {
  height: 4px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
  overflow: hidden;
}
.usage-pill-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--success);
  transition: width 400ms ease, background-color 200ms ease;
}
.usage-pill-bar-fill.warn { background: var(--warning); }
.usage-pill-bar-fill.bad  { background: var(--danger); }
.usage-pill-sub { font-size: 10px; color: var(--text-muted); }

.sidebar-action {
  margin: 0 6px 8px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-elev);
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: background 120ms ease, border-color 120ms ease;
}
.sidebar-action:hover:not(:disabled) { background: var(--bg-elev-2, var(--bg-elev)); border-color: var(--border-strong, var(--border)); }
.sidebar-action:disabled { opacity: 0.6; cursor: progress; }
.sidebar-action svg { width: 14px; height: 14px; flex-shrink: 0; }
.sidebar-action-label { flex: 1; }
.sidebar-action-status {
  font-size: 10px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.nav { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  user-select: none;
  transition: background 80ms, color 80ms;
}
.nav-item:hover { background: var(--bg-hover); color: var(--text); }
.nav-item.active { background: var(--bg-active); color: var(--text); }
.nav-item svg { color: var(--text-muted); }
.nav-item.active svg { color: var(--accent); }
.nav-item span:nth-of-type(1) { flex: 1; }
.nav-count {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-dim);
  background: var(--bg-card);
  padding: 1px 6px;
  border-radius: 999px;
  min-width: 20px;
  text-align: center;
}
.nav-item.active .nav-count { color: var(--text-muted); background: var(--bg); }

.sidebar-footer { margin-top: auto; padding: 4px 6px; border-top: 1px solid var(--border); padding-top: 12px; }
.user { display: flex; align-items: center; gap: 10px; padding: 4px; }
.avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  display: grid; place-items: center;
  color: #fff; font-weight: 600; font-size: 11px;
}
.user-name { font-weight: 500; font-size: 13px; }
.user-sub { font-size: 11px; color: var(--text-muted); }

/* ===== MAIN ===== */
.main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}
.view {
  display: none;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}
.view.active { display: flex; }

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  height: 44px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.page-title { font-size: 16px; font-weight: 600; margin: 0; letter-spacing: -0.01em; }
.brand .dot { margin-left: auto; width: 7px; height: 7px; }
.ws-avatar {
  width: 18px; height: 18px;
  border-radius: 5px;
  background: linear-gradient(135deg, #2dd4bf, #0891b2);
  color: #fff; font-weight: 700; font-size: 10px;
  display: grid; place-items: center;
}
.bc-muted { color: var(--text-muted); }
.bc-sep { color: var(--text-dim); }
.bc-active { font-weight: 500; }
.page-actions { display: flex; gap: 6px; align-items: center; }

/* Sub-header */
.sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  gap: 12px;
}
.tabs { display: flex; gap: 2px; }
.tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-weight: 500;
  font-size: 12px;
}
.tab:hover { background: var(--bg-hover); color: var(--text); }
.tab.active { background: var(--bg-active); color: var(--text); }
.tab-count {
  font-size: 11px;
  color: var(--text-dim);
  background: var(--bg-card);
  padding: 1px 6px;
  border-radius: 999px;
}
.tab.active .tab-count { color: var(--text-muted); background: var(--bg); }
.filters { display: flex; gap: 6px; align-items: center; }

.search {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 5px 10px;
  width: 240px;
  color: var(--text-muted);
  transition: border-color 80ms;
}
.search:focus-within { border-color: var(--border-strong); }
.search svg { color: var(--text-dim); width: 13px; height: 13px; }
.search input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-size: 12px;
}
.search input::placeholder { color: var(--text-dim); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  font-weight: 500;
  font-size: 12px;
  transition: background 80ms, border-color 80ms, color 80ms;
}
.btn-ghost { color: var(--text-muted); }
.btn-ghost:hover { background: var(--bg-hover); color: var(--text); }
.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-outline {
  background: var(--bg-card);
  border-color: var(--border);
  color: var(--text-muted);
}
.btn-outline:hover { background: var(--bg-hover); border-color: var(--border-strong); color: var(--text); }
.btn-play {
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid rgba(124,131,255,0.25);
}
.btn-play:hover { background: rgba(124,131,255,0.18); }
.btn-icon { padding: 5px; }

/* ===== TICKETS BOARD ===== */
.board {
  flex: 1;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 1fr);
  gap: 14px;
  padding: 14px;
  overflow-x: auto;
  align-items: stretch;
}
.lane {
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 0;
}
.lane-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-card);
}
.lane-status-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  border: 1.6px solid var(--text-dim);
  background: transparent;
  flex-shrink: 0;
}
.status-backlog .lane-status-dot,
.status-dot.status-backlog { border-color: var(--text-dim); }
.status-inprogress .lane-status-dot,
.status-dot.status-inprogress {
  border-color: var(--warning);
  background: conic-gradient(var(--warning) 50%, transparent 50%);
}
.status-inreview .lane-status-dot,
.status-dot.status-inreview {
  border-color: var(--success);
  background: conic-gradient(var(--success) 80%, transparent 80%);
}
.status-done .lane-status-dot,
.status-dot.status-done {
  border-color: var(--success);
  background: var(--success);
}
.lane-title {
  font-weight: 600;
  font-size: 13px;
  flex: 1;
  color: var(--text);
}
.lane-count {
  font-size: 11px;
  color: var(--text-dim);
  background: var(--bg-active);
  padding: 1px 7px;
  border-radius: 999px;
  font-weight: 500;
}
.lane-add {
  display: grid;
  place-items: center;
  width: 22px; height: 22px;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-dim);
}
.lane-add:hover { background: var(--bg-active); color: var(--text); }
.lane-body {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: pointer;
  transition: border-color 80ms, transform 80ms;
}
.card:hover { border-color: var(--border-strong); }
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.card-id {
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}
.card-title {
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  line-height: 1.35;
}
.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
}
.card-labels {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.card-actions {
  display: flex;
  gap: 4px;
  margin-top: 4px;
  border-top: 1px dashed var(--border);
  padding-top: 8px;
  opacity: 0;
  transition: opacity 80ms;
}
.card:hover .card-actions { opacity: 1; }
.card-actions .btn {
  flex: 1;
  justify-content: center;
  padding: 4px 8px;
  font-size: 11px;
}
.card-actions .btn-icon { flex: 0 0 auto; }

.label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 500;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.label-auto-implement { color: var(--accent); border-color: rgba(124,131,255,0.3); background: var(--accent-soft); }
.label-to-enrich { color: var(--info); border-color: rgba(96,165,250,0.3); background: var(--info-soft); }
.label-clarified { color: var(--success); border-color: rgba(52,211,153,0.3); background: var(--success-soft); }
.label-bug { color: var(--danger); border-color: rgba(248,113,113,0.3); background: var(--danger-soft); }

.priority-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-active);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.priority-urgent { color: var(--danger); background: var(--danger-soft); }
.priority-high { color: var(--warning); background: var(--warning-soft); }
.priority-medium { color: var(--text-muted); }
.priority-low { color: var(--text-dim); }

/* ===== AGENTS ===== */
.agent-grid {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 12px;
  align-content: start;
}
.agent-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  transition: border-color 80ms, transform 80ms;
  box-shadow: var(--shadow-card);
}
.agent-card:hover { border-color: var(--border-strong); }
.agent-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.agent-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  font-family: 'Geist Mono', ui-monospace, monospace;
}
.agent-name .ns { color: var(--text-dim); }
.agent-kind {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 500;
  background: var(--bg-active);
  color: var(--text-muted);
}
.agent-kind-builtin { color: var(--info); background: var(--info-soft); }
.agent-kind-user { color: var(--accent); background: var(--accent-soft); }

.agent-triggers {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
}
.agent-trigger {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: 'Geist Mono', ui-monospace, monospace;
}
.agent-trigger svg { color: var(--text-dim); }
.agent-trigger code {
  background: var(--bg-active);
  padding: 1px 5px;
  border-radius: 4px;
  color: var(--text);
  font-size: 11px;
}

.agent-marker {
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11px;
  color: var(--text-dim);
  padding: 6px 8px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.agent-marker .key { color: var(--text-muted); }

.agent-recent {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}
.recent-meta { font-size: 11px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; }
.spark { display: flex; gap: 2px; align-items: end; height: 14px; }
.spark span {
  width: 3px;
  border-radius: 1px;
  background: var(--success);
  opacity: 0.55;
}
.spark span.fail { background: var(--danger); opacity: 0.7; }
.spark span.skip { background: var(--text-dim); opacity: 0.5; }

.agent-actions { display: flex; gap: 6px; }

/* ===== RUNS ===== */
.run-list {
  flex: 1;
  overflow-y: auto;
  padding: 0;
}
.run-row {
  display: grid;
  grid-template-columns: 86px 200px 90px 240px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  cursor: pointer;
  transition: background 80ms;
}
.run-row:hover { background: var(--bg-hover); }
.run-row.head {
  cursor: default;
  font-weight: 500;
  color: var(--text-dim);
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.06em;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border-strong);
}
.run-row.head:hover { background: var(--bg-elev); }
.run-time { color: var(--text-muted); font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11px; }
.run-agent { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 12px; color: var(--text); display: flex; align-items: center; gap: 6px; }
.run-trigger { color: var(--text-muted); font-size: 11px; }
.run-id { color: var(--text-muted); font-size: 11px; min-width: 0; }
.run-id-ident { font-family: 'Geist Mono', ui-monospace, monospace; color: var(--text-muted); }
.run-id-title {
  margin-top: 2px;
  color: var(--text-dim);
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.run-duration { color: var(--text-muted); font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11px; }
.run-summary { color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.outcome-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.outcome-success { background: var(--success-soft); color: var(--success); }
.outcome-no-marker { background: var(--warning-soft); color: var(--warning); }
.outcome-crashed { background: var(--danger-soft); color: var(--danger); }
.outcome-killed { background: var(--danger-soft); color: var(--danger); }
.outcome-idle-timeout { background: var(--warning-soft); color: var(--warning); }
.outcome-circuit-broken { background: var(--danger-soft); color: var(--danger); }
.outcome-skipped-overlap { background: var(--bg-active); color: var(--text-muted); }
.outcome-running { background: var(--info-soft); color: var(--info); }
.outcome-paused { background: var(--warning-soft); color: var(--warning); }
.outcome-stale { background: var(--bg-active); color: var(--text-muted); opacity: 0.75; }
.outcome-done { background: var(--success-soft); color: var(--success); }

.stale-marker, .paused-marker {
  display: inline-block;
  margin-left: 4px;
  font-size: 11px;
  opacity: 0.7;
}
.text-stale { color: var(--text-muted); font-style: italic; }
.text-paused { color: var(--warning); font-weight: 500; }

.run-row.stale { opacity: 0.6; }
.run-row.paused { background: rgba(255, 184, 0, 0.04); }

/* Active period filter button (Today / This week) — same visual
   treatment as `.tab.active` so the period filter and the bucket
   filter look consistent. */
.btn.btn-ghost.active {
  background: var(--bg-active);
  color: var(--text);
}
.btn.btn-ghost.active:hover {
  background: var(--bg-active);
  color: var(--text);
}

.run-outcome-cell {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.row-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border-radius: 4px;
  border: 1px solid var(--border, rgba(255,255,255,0.1));
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.row-action svg { width: 12px; height: 12px; }
.row-action:hover { background: var(--bg-active); color: var(--text); }
.row-action:disabled { opacity: 0.4; cursor: not-allowed; }
.row-action-stop:hover { color: var(--danger); border-color: var(--danger); }
.row-action-retry:hover { color: var(--info); border-color: var(--info); }

.agent-pill {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 500;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: 'Geist Mono', ui-monospace, monospace;
  letter-spacing: 0.01em;
}

/* ===== SETTINGS ===== */
.settings-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  max-width: 720px;
}
.setting-row {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}
.setting-label { font-weight: 500; }
.setting-help { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.input {
  width: 100%;
  padding: 7px 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 12px;
  outline: none;
  font-family: inherit;
}
.input:focus { border-color: var(--accent); }
.input::placeholder { color: var(--text-dim); }

/* ===== DRAWER (RUN DETAIL) ===== */
.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: 720px;
  max-width: 92vw;
  background: var(--bg-elev);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  box-shadow: -20px 0 60px -20px rgba(0,0,0,0.6);
  z-index: 50;
  animation: drawer-in 180ms ease-out;
}
@keyframes drawer-in {
  from { transform: translateX(20px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}
.drawer[hidden] { display: none; }
.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.drawer-eyebrow { display: flex; gap: 6px; margin-bottom: 6px; }
.drawer-title h2 {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 4px 0;
  letter-spacing: -0.01em;
}
.drawer-meta { font-size: 11px; color: var(--text-muted); font-family: 'Geist Mono', ui-monospace, monospace; }
.drawer-actions { display: flex; gap: 4px; }

.drawer-tabs {
  display: flex;
  gap: 2px;
  padding: 6px 12px;
  border-bottom: 1px solid var(--border);
}
.drawer-tab {
  background: transparent;
  border: none;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
}
.drawer-tab:hover { background: var(--bg-hover); color: var(--text); }
.drawer-tab.active { background: var(--bg-active); color: var(--text); }

.drawer-body { flex: 1; overflow-y: auto; }
.drawer-pane { display: none; padding: 14px 18px; }
.drawer-pane.active { display: block; }

/* Floating jump-to-bottom button — positioned absolutely inside the drawer
   (which is `position: fixed`), so it sits over the lower-right corner of
   the visible drawer body regardless of scroll position. Visible only when
   the operator is more than 120px above the bottom of the stream — see
   updateScrollToBottomVisibility in app.js. */
.scroll-to-bottom {
  position: absolute;
  bottom: 18px;
  right: 22px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-strong);
  background: var(--bg-elev);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.35);
  z-index: 6;
  transition: background 0.12s, transform 0.12s;
}
.scroll-to-bottom[hidden] { display: none; }
.scroll-to-bottom:hover { background: var(--bg-hover); transform: translateY(-1px); }
.scroll-to-bottom svg { width: 16px; height: 16px; }

/* Inline links rendered inside chat / tool-result text. Keep the underline
   so URLs read as clickable even inside the dense stream-json view, and use
   the accent color to distinguish from regular muted text. */
.event-body a,
.user-prompt a,
.tool-result a {
  color: var(--accent);
  text-decoration: underline;
  word-break: break-all;
}
.event-body a:hover,
.user-prompt a:hover,
.tool-result a:hover { color: var(--accent-hover); }

.codeblock {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
}

/* ===== STREAM-JSON RENDER ===== */
.stream {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.event {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  overflow: hidden;
}
.event-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
}
.event-head .role-dot { width: 6px; height: 6px; border-radius: 50%; }
.event-head .role-system { background: var(--text-dim); }
.event-head .role-user { background: var(--info); }
.event-head .role-assistant { background: var(--accent); }
.event-head .role-tool { background: var(--warning); }
.event-head .role-result { background: var(--success); }
.event-head .turn { margin-left: auto; color: var(--text-dim); font-weight: 500; font-family: 'Geist Mono', ui-monospace, monospace; }
.event-body { padding: 10px 12px; font-size: 13px; line-height: 1.55; color: var(--text); }
.event-body p { margin: 0 0 6px 0; }
.event-body p:last-child { margin-bottom: 0; }

.thinking {
  background: rgba(124,131,255,0.04);
  border-left: 2px solid var(--accent);
  padding: 8px 10px;
  margin: 0 0 8px 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-muted);
  font-style: italic;
  font-size: 12px;
}

.tool-block {
  margin-top: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
}
.tool-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  font-size: 11px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
}
.tool-head .tool-name { color: var(--accent); font-weight: 600; }
.tool-head .tool-id { color: var(--text-dim); margin-left: auto; }
.tool-head .chev { color: var(--text-dim); transition: transform 100ms; }
.tool-block.open .tool-head .chev { transform: rotate(90deg); }
.tool-args {
  display: none;
  padding: 10px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11px;
  white-space: pre-wrap;
  color: var(--text-muted);
  word-break: break-word;
}
.tool-block.open .tool-args { display: block; }
.tool-result {
  display: none;
  border-top: 1px dashed var(--border);
  padding: 10px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11px;
  white-space: pre-wrap;
  color: var(--text-dim);
  background: rgba(0,0,0,0.2);
  word-break: break-word;
  max-height: 300px;
  overflow-y: auto;
}
.tool-block.open .tool-result { display: block; }
.tool-result.error { color: var(--danger); }

.event-result {
  border-color: rgba(52,211,153,0.3);
}
.event-result .event-head { color: var(--success); }
.event-result-body {
  padding: 10px 12px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 11px;
  color: var(--text-muted);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
}
.event-result-body .k { color: var(--text-dim); }
.event-result-body .v { color: var(--text); }
.event-result-body .v.success { color: var(--success); }

.user-prompt {
  font-style: italic;
  color: var(--text-muted);
}

/* ===== EMPTY STATES ===== */
.empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text-muted);
}
.empty svg { width: 28px; height: 28px; color: var(--text-dim); }

/* ===== FILTER SELECTS (page-actions) ===== */
.filter-select {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: inherit;
  font-size: 12px;
  padding: 5px 24px 5px 10px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2210%22%20height%3D%2210%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%238b8b95%22%20stroke-width%3D%222%22%3E%3Cpath%20d%3D%22m6%209%206%206%206-6%22%2F%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  cursor: pointer;
}
.filter-select:hover { border-color: var(--border-strong); }
.filter-select:focus { outline: none; border-color: var(--accent); }

.filter-toggle {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.filter-toggle:hover { background: var(--bg-hover); border-color: var(--border-strong); color: var(--text); }
.filter-toggle.active {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: rgba(124,131,255,0.35);
}
.filter-toggle.active svg { color: var(--accent); }

/* ===== AGENT DESCRIPTION ===== */
.agent-description {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.45;
  margin: -4px 0 0 0;
}

/* ===== TOAST ===== */
#toast-host {
  position: fixed;
  bottom: 18px;
  right: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 200;
  pointer-events: none;
}
.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 10px 14px;
  font-size: 13px;
  color: var(--text);
  min-width: 240px;
  max-width: 360px;
  box-shadow: 0 10px 30px -10px rgba(0,0,0,0.7);
  animation: toast-in 160ms ease-out;
  transition: opacity 280ms, transform 280ms;
  pointer-events: auto;
}
.toast.out { opacity: 0; transform: translateX(20px); }
.toast-success { border-left: 3px solid var(--success); }
.toast-error   { border-left: 3px solid var(--danger); color: var(--text); }
.toast-info    { border-left: 3px solid var(--accent); }
@keyframes toast-in {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ===== AGENT MODAL ===== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  display: grid;
  place-items: center;
  z-index: 100;
  animation: fade-in 120ms ease-out;
}
.modal-backdrop[hidden] { display: none; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

.modal {
  width: 720px;
  max-width: 92vw;
  max-height: 88vh;
  background: var(--bg-elev);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px -10px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.02);
  animation: modal-in 180ms ease-out;
}
@keyframes modal-in {
  from { transform: translateY(8px) scale(0.99); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px 14px;
  border-bottom: 1px solid var(--border);
}
.modal-eyebrow {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 4px;
}
.modal-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 4px 0;
  letter-spacing: -0.01em;
}
.modal-sub {
  font-size: 11px;
  color: var(--text-muted);
  font-family: 'Geist Mono', ui-monospace, monospace;
}
.modal-sub code, .modal-sub span { color: var(--text); }

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 20px 16px;
}
.form-section { margin-top: 16px; }
.form-section:first-child { margin-top: 4px; }
.form-section-title {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px dashed var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}
.form-section-hint {
  font-weight: 500;
  text-transform: none;
  letter-spacing: normal;
  color: var(--text-dim);
  font-size: 10px;
}
.form-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}
.form-row label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
}
.form-row .form-help {
  font-size: 11px;
  color: var(--text-muted);
}
.form-row .form-help code {
  background: var(--bg-active);
  padding: 1px 5px;
  border-radius: 4px;
  font-family: 'Geist Mono', ui-monospace, monospace;
  color: var(--text);
  font-size: 10.5px;
}
.form-row-grid-2 {
  flex-direction: row;
  gap: 12px;
}
.form-row-grid-2 > div { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.form-row-inline { flex-direction: row; align-items: center; gap: 12px; }
.form-row-inline .form-help { flex: 1; text-align: right; }

.input.mono { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 12px; }
.prompt-area {
  font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 12px;
  line-height: 1.55;
  resize: vertical;
  min-height: 200px;
  padding: 10px 12px;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text);
}
.checkbox input { accent-color: var(--accent); width: 14px; height: 14px; }

.modal-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
.modal-foot .spacer { flex: 1; }
.modal-foot #modal-delete { color: var(--danger); }
.modal-foot #modal-delete:hover { background: var(--danger-soft); color: var(--danger); }

/* ===== LIVE INDICATORS ===== */
.live-pulse, .live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 0 rgba(52,211,153,0.5);
  animation: pulse 1.6s ease-out infinite;
  vertical-align: middle;
}
.live-dot { margin-left: 4px; }
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0   rgba(52,211,153,0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(52,211,153,0); }
  100% { box-shadow: 0 0 0 0   rgba(52,211,153,0); }
}
.run-row.inflight {
  background: rgba(96,165,250,0.04);
  border-left: 2px solid var(--info);
}
.run-row.inflight .run-time { color: var(--success); }
.text-live { color: var(--success); font-weight: 500; }

/* ===== SCROLLBARS ===== */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 999px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

/* Operator prompt bar — sticky-top inside the stream pane so the input
   stays in reach while the live tail scrolls underneath. Hidden whenever
   the run isn't an in-flight ship-flow (see updatePromptBar in app.js). */
.prompt-bar {
  position: sticky;
  top: 0;
  z-index: 5;
  margin: -14px -18px 14px;
  padding: 12px 18px;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.prompt-bar[hidden] { display: none; }
.prompt-bar textarea {
  width: 100%;
  resize: vertical;
  min-height: 48px;
  max-height: 240px;
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  line-height: 1.45;
}
.prompt-bar textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent-soft);
}
.prompt-bar-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.prompt-status {
  font-size: 12px;
  color: var(--text-muted);
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.prompt-status-ok   { color: var(--success); }
.prompt-status-warn { color: var(--warning); }
.prompt-status-err  { color: var(--danger); }

/* Daemon view — small status dot on the nav item, then the body which is
   a 2-column card grid with two wide cards spanning both columns. */
.nav-item .nav-dot {
  width: 8px; height: 8px; border-radius: 50%;
  margin-left: auto;
  background: var(--text-dim);
}
.nav-dot-ok   { background: var(--success) !important; }
.nav-dot-warn { background: var(--warning) !important; }
.nav-dot-bad  { background: var(--danger)  !important; }

.daemon-body { padding: 18px 24px; }
.daemon-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.daemon-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 16px;
}
.daemon-card-wide { grid-column: 1 / -1; }
.daemon-card-warn { border-color: var(--warning); background: var(--warning-soft); }
.daemon-card h3 {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 8px;
}
.daemon-card .kv {
  margin: 0;
  display: grid;
  grid-template-columns: 160px 1fr;
  row-gap: 6px;
  column-gap: 12px;
  font-size: 13px;
}
.daemon-card .kv dt { color: var(--text-muted); }
.daemon-card .kv dd { margin: 0; word-break: break-all; }
.daemon-card .kv dd code { font-size: 12px; }
.daemon-card .muted { color: var(--text-muted); }

.daemon-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.daemon-table th, .daemon-table td {
  text-align: left;
  padding: 6px 10px;
  border-bottom: 1px solid var(--border);
}
.daemon-table th { color: var(--text-muted); font-weight: 500; }

.status-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.status-ok  { background: var(--success-soft); color: var(--success); }
.status-bad { background: rgba(248, 113, 113, 0.12); color: var(--danger); }

.env-present { color: var(--success); }
.env-absent  { color: var(--text-muted); }

/* ===== MOBILE (≤ 768px) =====
   Collapses the fixed 248px sidebar into a horizontal top bar, stacks all
   2-col layouts (board lanes, daemon-grid, setting-row, daemon-card .kv,
   form-row-grid-2), and switches .run-row from CSS grid to a stacked card.
   Desktop layout is preserved above this breakpoint. */
@media (max-width: 768px) {
  /* App shell: sidebar sits on top, main flows below. */
  .app {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    height: 100vh;
  }

  /* Sidebar → horizontal top bar. */
  .sidebar {
    flex-direction: row;
    align-items: center;
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 8px 10px;
    gap: 8px;
    overflow-x: auto;
  }
  .brand {
    padding: 0;
    gap: 6px;
    flex-shrink: 0;
  }
  .brand-text { display: none; }
  .brand .dot { margin-left: 0; }

  .nav {
    flex-direction: row;
    gap: 2px;
    margin-top: 0;
    flex: 1;
    justify-content: space-around;
    min-width: 0;
  }
  .nav-item {
    flex-direction: column;
    gap: 2px;
    padding: 6px 8px;
    font-size: 11px;
    flex: 1;
    text-align: center;
    justify-content: center;
    min-width: 0;
  }
  .nav-item span:nth-of-type(1) {
    flex: 0;
    font-size: 10px;
  }
  .nav-count {
    padding: 0 5px;
    min-width: 16px;
    font-size: 10px;
  }
  .nav-item .nav-dot { margin-left: 0; }
  .sidebar-footer { display: none; }

  /* Page header: allow wrapping so the filter selects / search / buttons
     don't overflow horizontally. */
  .page-header {
    flex-wrap: wrap;
    height: auto;
    min-height: 44px;
    padding: 8px 12px;
    gap: 8px;
  }
  .page-actions {
    flex-wrap: wrap;
    gap: 6px;
  }
  .sub-header {
    flex-wrap: wrap;
    padding: 8px 12px;
    gap: 8px;
  }
  .filters { width: 100%; }
  .search {
    width: 100%;
    min-width: 0;
  }
  .filter-select { flex: 1; min-width: 0; }

  /* Tickets board: stack lanes vertically instead of horizontal scroll. */
  .board {
    grid-auto-flow: row;
    grid-auto-columns: auto;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 10px;
    overflow-x: hidden;
    overflow-y: auto;
  }
  .lane {
    min-height: auto;
  }
  .lane-body {
    /* Cap each lane so a single huge backlog doesn't push everything else
       off-screen. Tap the lane title to scroll within. */
    max-height: 50vh;
  }
  /* Card actions always visible on mobile — no hover state to reveal them. */
  .card-actions { opacity: 1; }

  /* Agents grid: already responsive via auto-fill minmax(320px, 1fr), but
     320px is too wide on a narrow phone — let cards drop to single col. */
  .agent-grid {
    grid-template-columns: 1fr;
    padding: 10px;
    gap: 10px;
  }

  /* Runs list: rebuild .run-row as a stacked card. The grid columns
     (time | agent | trigger | id | duration | summary | outcome) wrap to
     a stacked layout. The desktop header row (.run-row.head) is hidden —
     each cell gets an inline ::before label instead, so users can tell which
     value is which without a fixed column header. */
  .run-row.head { display: none; }
  .run-row {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 12px;
  }
  .run-row > * { width: auto; }
  .run-summary {
    white-space: normal;
    word-break: break-word;
    width: 100%;
  }
  /* Inline per-cell labels — the same shorthand the desktop header row
     uses, prefixed before each value in a muted uppercase style. */
  .run-row .run-time::before    { content: "Started "; }
  .run-row .run-trigger::before { content: "Trigger "; }
  .run-row .run-id::before      { content: "Session "; }
  .run-row .run-duration::before { content: "Duration "; }
  .run-row .run-time::before,
  .run-row .run-trigger::before,
  .run-row .run-id::before,
  .run-row .run-duration::before {
    color: var(--text-dim);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-right: 4px;
  }

  /* Daemon view: single-column grid, label/value stack inside cards. */
  .daemon-body { padding: 10px; }
  .daemon-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .daemon-card { padding: 12px; }
  .daemon-card .kv {
    grid-template-columns: 1fr;
    row-gap: 2px;
  }
  .daemon-card .kv dt {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
  }
  .daemon-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }

  /* Settings: stack label/help above input. */
  .settings-body { padding: 16px; }
  .setting-row {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 12px 0;
  }

  /* Drawer (run detail): full viewport. */
  .drawer {
    width: 100%;
    max-width: 100%;
    border-left: none;
  }
  .drawer-head { padding: 12px; }
  .drawer-pane { padding: 12px; }
  .scroll-to-bottom {
    bottom: 14px;
    right: 14px;
  }

  /* Modal (agent editor): tighter padding + full-bleed footer. */
  .modal {
    max-height: 96vh;
    border-radius: var(--radius);
  }
  .modal-head { padding: 14px; }
  .modal-body { padding: 10px 14px 14px; }
  .modal-foot {
    padding: 10px 14px;
    flex-wrap: wrap;
  }
  .modal-foot .spacer { flex-basis: 100%; height: 0; }
  .form-row-grid-2 { flex-direction: column; gap: 12px; }
  .form-row-inline { flex-direction: column; align-items: flex-start; gap: 6px; }
  .form-row-inline .form-help { text-align: left; }

  /* Toast positioning: nudge above the bottom edge so it doesn't collide
     with browser chrome on iOS Safari. */
  #toast-host {
    bottom: 12px;
    right: 12px;
    left: 12px;
  }
  .toast {
    min-width: 0;
    max-width: 100%;
  }
}

/* ===== PHONE-ONLY (≤ 480px) =====
   Tightens spacing and hides nav item labels (icons only). Count badges
   stay visible because the Tickets view has no other count surface in its
   page-header — hiding them would lose the only ticket-total signal there
   (Agents + Runs still expose counts via tab badges). */
@media (max-width: 480px) {
  .nav-item span:nth-of-type(1) { display: none; }
  .nav-count {
    padding: 0 4px;
    min-width: 14px;
    font-size: 9px;
    line-height: 1.4;
  }
  .page-title { font-size: 14px; }
  .breadcrumb { font-size: 12px; }
  .board { padding: 8px; gap: 8px; }
  .lane-body { padding: 6px; }
  .card { padding: 8px 10px; }
}
