/* Baseplate — component stylesheet. Loaded after tokens.css; every value is a token. */

.bp-root,
.bp-scope {
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 20px;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
.bp-scope *,
.bp-scope *::before,
.bp-scope *::after { box-sizing: border-box; }

.bp-scope :focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.bp-mono { font-family: var(--font-mono); font-size: 13px; line-height: 18px; }
.bp-num { font-variant-numeric: tabular-nums; }
.bp-muted { color: var(--ink-muted); }
.bp-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bp-vh {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

/* ---------- Button ---------- */
.bp-btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--space-1);
  height: var(--control-md);
  padding: 0 var(--space-3);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font: inherit; font-size: 13px; line-height: 18px; font-weight: 500;
  white-space: nowrap; cursor: pointer;
  text-decoration: none;
  background: transparent; color: var(--ink);
}
.bp-btn--primary { background: var(--accent); color: var(--on-accent); box-shadow: var(--shadow-xs); }
.bp-btn--primary:hover { background: var(--accent-hover); }
.bp-btn--secondary {
  background: var(--surface); color: var(--ink);
  border-color: var(--border); box-shadow: var(--shadow-xs);
}
.bp-btn--secondary:hover { background: var(--surface-hover); border-color: var(--border-strong); }
.bp-btn--ghost { background: transparent; color: var(--ink-muted); }
.bp-btn--ghost:hover { background: var(--surface-hover); color: var(--ink); }
.bp-btn--danger { background: var(--danger); color: var(--on-danger); }
.bp-btn--danger:hover { filter: saturate(1.1) brightness(0.94); }
.bp-btn--sm { height: var(--control-sm); padding: 0 var(--space-2); font-size: 12px; }
.bp-btn--lg { height: var(--control-lg); padding: 0 var(--space-4); font-size: 14px; }
.bp-btn--block { width: 100%; }
.bp-btn--icon { width: var(--control-md); padding: 0; }
.bp-btn--icon.bp-btn--sm { width: var(--control-sm); }
.bp-btn[disabled], .bp-btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; }
.bp-btn .bp-i { width: var(--icon-md); height: var(--icon-md); flex: none; }
.bp-btn--sm .bp-i { width: var(--icon-sm); height: var(--icon-sm); }

/* ---------- Field, Input, Select, Textarea ---------- */
.bp-field { display: flex; flex-direction: column; gap: var(--space-1); }
.bp-label {
  font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--ink-muted);
}
.bp-req { color: var(--danger); }
.bp-input, .bp-select, .bp-textarea {
  width: 100%;
  min-height: var(--control-md);
  padding: 0 var(--space-3);
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font: inherit; font-size: 14px; line-height: 20px;
}
.bp-textarea { padding: var(--space-2) var(--space-3); min-height: 84px; resize: vertical; }
.bp-input::placeholder, .bp-textarea::placeholder { color: var(--ink-faint); }
.bp-input:hover, .bp-select:hover, .bp-textarea:hover { border-color: var(--border-strong); }
.bp-select {
  appearance: none;
  padding-right: var(--space-8);
  background-image: linear-gradient(transparent, transparent);
}
.bp-field--lg .bp-input, .bp-field--lg .bp-select { min-height: var(--control-lg); }
.bp-field[data-invalid="true"] .bp-input,
.bp-field[data-invalid="true"] .bp-select { border-color: var(--danger); }
.bp-hint { font-size: 13px; line-height: 18px; color: var(--ink-muted); }
.bp-error { font-size: 13px; line-height: 18px; color: var(--danger); display: flex; gap: var(--space-1); }
.bp-input-wrap { position: relative; display: flex; align-items: center; }
.bp-input-wrap .bp-i {
  position: absolute; left: var(--space-3); width: var(--icon-md); height: var(--icon-md);
  color: var(--ink-faint); pointer-events: none;
}
.bp-input-wrap .bp-input { padding-left: var(--space-8); }
.bp-select-wrap { position: relative; display: flex; align-items: center; }
.bp-select-wrap .bp-caret {
  position: absolute; right: var(--space-3); width: var(--icon-sm); height: var(--icon-sm);
  color: var(--ink-muted); pointer-events: none;
}

/* ---------- Checkbox, Switch ---------- */
.bp-check { display: inline-flex; align-items: center; gap: var(--space-2); cursor: pointer; }
.bp-check input { position: absolute; opacity: 0; width: 0; height: 0; }
.bp-check__box {
  width: 16px; height: 16px; flex: none;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  display: grid; place-items: center;
  color: var(--on-accent);
}
.bp-check__box svg { width: 12px; height: 12px; opacity: 0; }
.bp-check input:checked + .bp-check__box,
.bp-check input:indeterminate + .bp-check__box { background: var(--accent); border-color: var(--accent); }
.bp-check input:checked + .bp-check__box svg { opacity: 1; }
.bp-check input:focus-visible + .bp-check__box { outline: 2px solid var(--focus); outline-offset: 2px; }
.bp-check__label { font-size: 14px; line-height: 20px; }

.bp-switch { display: inline-flex; align-items: center; gap: var(--space-2); cursor: pointer; }
.bp-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.bp-switch__track {
  width: 34px; height: 20px; flex: none;
  border-radius: var(--radius-pill);
  background: var(--surface-sunken);
  border: 1px solid var(--border-strong);
  position: relative;
}
.bp-switch__track::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 14px; height: 14px; border-radius: var(--radius-pill);
  background: var(--border-strong);
}
.bp-switch input:checked + .bp-switch__track { background: var(--accent); border-color: var(--accent); }
.bp-switch input:checked + .bp-switch__track::after { left: 16px; background: var(--on-accent); }
.bp-switch input:focus-visible + .bp-switch__track { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ---------- Badge ---------- */
.bp-badge {
  display: inline-flex; align-items: center; gap: var(--space-1);
  height: 20px; padding: 0 var(--space-2);
  border-radius: var(--radius-sm);
  font-size: 12px; line-height: 16px; font-weight: 500;
  background: var(--surface-sunken); color: var(--ink-muted);
  white-space: nowrap;
}
.bp-badge--accent { background: var(--accent-soft); color: var(--accent-ink); }
.bp-badge--success { background: var(--success-soft); color: var(--success-ink); }
.bp-badge--warning { background: var(--warning-soft); color: var(--warning-ink); }
.bp-badge--danger { background: var(--danger-soft); color: var(--danger-ink); }
.bp-badge__dot { width: 6px; height: 6px; border-radius: var(--radius-pill); background: currentColor; flex: none; }

/* ---------- Avatar ---------- */
.bp-avatar {
  width: 28px; height: 28px; flex: none;
  border-radius: var(--radius-pill);
  background: var(--accent-soft); color: var(--accent-ink);
  display: inline-grid; place-items: center;
  font-size: 11px; font-weight: 600; letter-spacing: 0.02em;
  text-transform: uppercase;
}
.bp-avatar--sm { width: 22px; height: 22px; font-size: 10px; }
.bp-avatar--lg { width: 40px; height: 40px; font-size: 14px; }
.bp-avatar-stack { display: inline-flex; }
.bp-avatar-stack .bp-avatar + .bp-avatar { margin-left: -6px; box-shadow: 0 0 0 2px var(--surface); }

/* ---------- Card ---------- */
.bp-card {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.bp-card__head {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
}
.bp-card__title { font-size: 16px; line-height: 22px; font-weight: 600; margin: 0; }
.bp-card__sub { font-size: 13px; line-height: 18px; color: var(--ink-muted); margin: 2px 0 0; }
.bp-card__body { padding: var(--space-5); }
.bp-card__body--flush { padding: 0; }
.bp-card__foot {
  padding: var(--space-3) var(--space-5);
  border-top: 1px solid var(--border-subtle);
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
}

/* ---------- Stat tile ---------- */
.bp-stat { display: flex; flex-direction: column; gap: var(--space-1); padding: var(--space-4) var(--space-5); }
.bp-stat__label {
  font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--ink-muted);
}
.bp-stat__value {
  font-size: 24px; line-height: 30px; font-weight: 600; letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.bp-stat__row { display: flex; align-items: baseline; gap: var(--space-2); flex-wrap: wrap; }
.bp-stat__delta { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; line-height: 18px; font-weight: 500; }
.bp-stat__delta--up { color: var(--success); }
.bp-stat__delta--down { color: var(--danger); }
.bp-stat__delta--flat { color: var(--ink-muted); }
.bp-stat__note { font-size: 12px; line-height: 16px; color: var(--ink-muted); }

/* ---------- Table ---------- */
.bp-table-wrap { width: 100%; overflow: auto; }
.bp-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14px; }
.bp-table th {
  position: sticky; top: 0; z-index: 2;
  background: var(--surface-sunken);
  text-align: left; font-size: 12px; line-height: 16px; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-muted);
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}
.bp-table td {
  padding: var(--space-3);
  height: var(--row-comfortable);
  border-bottom: 1px solid var(--border-subtle);
  vertical-align: middle;
}
.bp-table--compact td { padding: var(--space-2) var(--space-3); height: var(--row-compact); }
.bp-table tbody tr:hover td { background: var(--surface-hover); }
.bp-table tbody tr[aria-selected="true"] td { background: var(--accent-soft); }
.bp-table tbody tr:last-child td { border-bottom: 0; }
.bp-th--num, .bp-td--num { text-align: right; font-variant-numeric: tabular-nums; }
.bp-td--mono { font-family: var(--font-mono); font-size: 13px; }
.bp-th--select, .bp-td--select { width: 40px; padding-right: 0; }
.bp-td--actions { width: 1%; white-space: nowrap; text-align: right; }
.bp-sort {
  display: inline-flex; align-items: center; gap: var(--space-1);
  background: none; border: 0; padding: 0; margin: 0; cursor: pointer;
  font: inherit; color: inherit; text-transform: inherit; letter-spacing: inherit;
}
.bp-sort .bp-i { width: 12px; height: 12px; opacity: 0; }
.bp-sort[aria-sort="ascending"], .bp-sort[aria-sort="descending"] { color: var(--ink); }
.bp-sort[aria-sort="ascending"] .bp-i, .bp-sort[aria-sort="descending"] .bp-i { opacity: 1; }
.bp-cell-primary { font-weight: 600; }
.bp-cell-sub { font-size: 12px; line-height: 16px; color: var(--ink-muted); }

/* ---------- Toolbar, filter chips, bulk bar ---------- */
.bp-toolbar {
  display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap;
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
}
.bp-toolbar__spacer { flex: 1 1 auto; }
.bp-chip {
  display: inline-flex; align-items: center; gap: var(--space-1);
  height: var(--control-sm); padding: 0 var(--space-2) 0 var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--accent-soft); color: var(--accent-ink);
  border: 1px solid transparent;
  font-size: 12px; line-height: 16px; font-weight: 500;
}
.bp-chip--muted { background: var(--surface); color: var(--ink-muted); border-color: var(--border); }
.bp-chip__x {
  display: grid; place-items: center; width: 16px; height: 16px;
  border: 0; background: none; color: inherit; cursor: pointer; padding: 0;
  border-radius: var(--radius-pill);
}
.bp-bulkbar {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  background: var(--surface-inverse); color: var(--ink-inverse);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  font-size: 13px;
}
.bp-bulkbar .bp-btn { color: var(--ink-inverse); }
.bp-bulkbar .bp-btn:hover { background: rgba(255,255,255,0.12); }

/* ---------- Tabs ---------- */
.bp-tabs { display: flex; gap: var(--space-4); border-bottom: 1px solid var(--border-subtle); }
.bp-tab {
  appearance: none; background: none; border: 0; cursor: pointer;
  padding: var(--space-3) 0; margin-bottom: -1px;
  font: inherit; font-size: 13px; font-weight: 500;
  color: var(--ink-muted);
  border-bottom: 2px solid transparent;
  display: inline-flex; align-items: center; gap: var(--space-2);
}
.bp-tab:hover { color: var(--ink); }
.bp-tab[aria-selected="true"] { color: var(--accent); border-bottom-color: var(--accent); }
.bp-tab__count {
  font-size: 11px; padding: 0 5px; border-radius: var(--radius-sm);
  background: var(--surface-sunken); color: var(--ink-muted);
}

/* ---------- Inline alert ---------- */
.bp-alert {
  display: flex; gap: var(--space-3); align-items: flex-start;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--surface-sunken); color: var(--ink);
  font-size: 13px; line-height: 18px;
}
.bp-alert__icon { width: var(--icon-md); height: var(--icon-md); flex: none; margin-top: 1px; }
.bp-alert__title { font-weight: 600; margin: 0 0 2px; }
.bp-alert--info { background: var(--accent-soft); color: var(--accent-ink); }
.bp-alert--success { background: var(--success-soft); color: var(--success-ink); }
.bp-alert--warning { background: var(--warning-soft); color: var(--warning-ink); }
.bp-alert--danger { background: var(--danger-soft); color: var(--danger-ink); }

/* ---------- Empty state ---------- */
.bp-empty {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  gap: var(--space-3); padding: var(--space-12) var(--space-6);
}
.bp-empty__mark {
  width: 44px; height: 44px; border-radius: var(--radius-lg);
  background: var(--surface-sunken); color: var(--ink-muted);
  display: grid; place-items: center;
}
.bp-empty__title { font-size: 16px; line-height: 22px; font-weight: 600; margin: 0; }
.bp-empty__body { font-size: 15px; line-height: 22px; color: var(--ink-muted); margin: 0; max-width: 46ch; }
.bp-empty__actions { display: flex; gap: var(--space-2); margin-top: var(--space-1); }

/* ---------- Pagination ---------- */
.bp-pager {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-4); font-size: 13px; color: var(--ink-muted);
}
.bp-pager__pages { display: flex; align-items: center; gap: var(--space-1); }
.bp-pager__page {
  min-width: var(--control-sm); height: var(--control-sm);
  padding: 0 var(--space-2);
  display: inline-grid; place-items: center;
  border: 1px solid transparent; border-radius: var(--radius-md);
  background: none; color: var(--ink-muted); font: inherit; font-size: 13px; cursor: pointer;
}
.bp-pager__page:hover { background: var(--surface-hover); color: var(--ink); }
.bp-pager__page[aria-current="page"] {
  background: var(--accent-soft); color: var(--accent-ink); font-weight: 600;
}

/* ---------- Meter ---------- */
.bp-meter { display: flex; flex-direction: column; gap: var(--space-2); }
.bp-meter__head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); font-size: 13px; }
.bp-meter__value { font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.bp-meter__track {
  height: 8px; border-radius: var(--radius-pill);
  background: var(--surface-sunken); overflow: hidden;
}
.bp-meter__fill { height: 100%; background: var(--accent); border-radius: var(--radius-pill); }
.bp-meter--warning .bp-meter__fill { background: var(--warning); }
.bp-meter--danger .bp-meter__fill { background: var(--danger); }

/* ---------- Modal ---------- */
.bp-scrim {
  position: absolute; inset: 0; background: var(--scrim);
  display: grid; place-items: center; padding: var(--space-6);
}
.bp-modal {
  width: 100%; max-width: 440px;
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.bp-modal__head { padding: var(--space-5) var(--space-5) var(--space-3); }
.bp-modal__title { font-size: 16px; line-height: 22px; font-weight: 600; margin: 0; }
.bp-modal__body { padding: 0 var(--space-5) var(--space-5); font-size: 14px; line-height: 20px; color: var(--ink-muted); }
.bp-modal__foot {
  display: flex; justify-content: flex-end; gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  border-top: 1px solid var(--border-subtle);
}

/* ---------- Menu ---------- */
.bp-menu {
  min-width: 200px; padding: var(--space-1);
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}
.bp-menu__item {
  display: flex; align-items: center; gap: var(--space-2);
  width: 100%; padding: var(--space-2) var(--space-3);
  border: 0; background: none; border-radius: var(--radius-sm);
  font: inherit; font-size: 13px; color: var(--ink); text-align: left; cursor: pointer;
}
.bp-menu__item:hover { background: var(--surface-hover); }
.bp-menu__item--danger { color: var(--danger); }
.bp-menu__sep { height: 1px; background: var(--border-subtle); margin: var(--space-1) 0; }

/* ---------- Sidebar navigation ---------- */
.bp-sidebar {
  width: var(--sidebar-w); flex: none;
  background: var(--surface);
  border-right: 1px solid var(--border-subtle);
  display: flex; flex-direction: column;
  padding: var(--space-3);
  gap: var(--space-3);
}
.bp-brand { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2); }
.bp-brand__mark {
  width: 24px; height: 24px; border-radius: var(--radius-sm);
  background: var(--accent); color: var(--on-accent);
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
}
.bp-brand__name { font-size: 14px; font-weight: 600; }
.bp-nav { display: flex; flex-direction: column; gap: 2px; }
.bp-nav__group {
  font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--ink-muted);
  padding: var(--space-3) var(--space-2) var(--space-1);
}
.bp-nav__item {
  display: flex; align-items: center; gap: var(--space-2);
  padding: var(--space-2); border-radius: var(--radius-md);
  color: var(--ink-muted); text-decoration: none; font-size: 13px; font-weight: 500;
}
.bp-nav__item:hover { background: var(--surface-hover); color: var(--ink); }
.bp-nav__item[aria-current="page"] { background: var(--accent-soft); color: var(--accent-ink); }
.bp-nav__item .bp-i { width: var(--icon-md); height: var(--icon-md); flex: none; }
.bp-nav__count { margin-left: auto; font-size: 12px; font-variant-numeric: tabular-nums; }

/* ---------- Application shell (screens) ---------- */
.bp-shell { display: flex; min-height: 100%; background: var(--canvas); }
.bp-shell__main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.bp-topbar {
  display: flex; align-items: center; gap: var(--space-3);
  height: 52px; padding: 0 var(--space-6);
  border-bottom: 1px solid var(--border-subtle);
  background: var(--surface);
}
.bp-search { flex: 0 1 320px; }
.bp-content { padding: var(--space-6) var(--space-8) var(--space-8); display: flex; flex-direction: column; gap: var(--space-6); }
.bp-pagehead { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-4); }
.bp-pagehead__title { font-size: 20px; line-height: 28px; font-weight: 600; margin: 0; }
.bp-pagehead__sub { font-size: 13px; line-height: 18px; color: var(--ink-muted); margin: 2px 0 0; }
.bp-crumbs { display: flex; align-items: center; gap: var(--space-2); font-size: 12px; color: var(--ink-muted); }
.bp-grid { display: grid; gap: var(--space-4); }
.bp-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.bp-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.bp-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.bp-split { display: grid; grid-template-columns: minmax(0, 1fr) var(--rail-w); gap: var(--space-6); align-items: start; }
.bp-stack { display: flex; flex-direction: column; gap: var(--space-4); }
.bp-row { display: flex; align-items: center; gap: var(--space-2); }

/* ---------- Detail rail, key/value, timeline ---------- */
.bp-kv { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: var(--space-2) var(--space-3); font-size: 13px; }
.bp-kv dt { color: var(--ink-muted); }
.bp-kv dd { margin: 0; }
.bp-timeline { display: flex; flex-direction: column; gap: var(--space-4); }
.bp-tl { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: var(--space-3); position: relative; }
.bp-tl::before {
  content: ""; position: absolute; left: 13px; top: 28px; bottom: calc(var(--space-4) * -1);
  width: 1px; background: var(--border-subtle);
}
.bp-tl:last-child::before { display: none; }
.bp-tl__body { font-size: 13px; line-height: 18px; }
.bp-tl__meta { font-size: 12px; line-height: 16px; color: var(--ink-muted); margin-top: 2px; }
.bp-tl__note {
  margin-top: var(--space-2); padding: var(--space-3);
  background: var(--surface-sunken); border-radius: var(--radius-md);
  font-size: 13px; line-height: 18px;
}

/* ---------- Checklist (onboarding) ---------- */
.bp-checklist { display: flex; flex-direction: column; }
.bp-checklist__item {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
}
.bp-checklist__item:last-child { border-bottom: 0; }
.bp-checklist__mark {
  width: 20px; height: 20px; flex: none; border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong); display: grid; place-items: center;
  color: var(--ink-faint);
}
.bp-checklist__item[data-done="true"] .bp-checklist__mark {
  background: var(--success); border-color: var(--success); color: var(--surface);
}
.bp-checklist__title { font-size: 14px; font-weight: 500; }
.bp-checklist__item[data-done="true"] .bp-checklist__title { color: var(--ink-muted); text-decoration: line-through; }
.bp-checklist__sub { font-size: 12px; color: var(--ink-muted); }

/* ---------- Auth / centred panel ---------- */
.bp-auth { min-height: 100%; display: grid; place-items: center; background: var(--canvas); padding: var(--space-8); }
.bp-panel {
  width: 100%; max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}
.bp-panel__title { font-size: 24px; line-height: 30px; font-weight: 600; letter-spacing: -0.01em; margin: 0 0 var(--space-2); }
.bp-panel__sub { font-size: 15px; line-height: 22px; color: var(--ink-muted); margin: 0 0 var(--space-6); }
.bp-divider { display: flex; align-items: center; gap: var(--space-3); color: var(--ink-faint); font-size: 12px; margin: var(--space-4) 0; }
.bp-divider::before, .bp-divider::after { content: ""; height: 1px; flex: 1; background: var(--border-subtle); }

/* ---------- Skeleton ---------- */
.bp-skel { background: var(--surface-sunken); border-radius: var(--radius-sm); height: 12px; }
.bp-skel--text { width: 60%; }
.bp-skel--wide { width: 90%; }
.bp-skel--pill { border-radius: var(--radius-pill); height: 20px; width: 72px; }

/* ---------- Chart primitives ---------- */
.bp-chart { width: 100%; display: block; }
.bp-chart .bp-axis { font-size: 12px; fill: var(--ink-muted); font-variant-numeric: tabular-nums; }
.bp-chart .bp-grid-line { stroke: var(--chart-grid); stroke-width: 1; }
.bp-legend { display: flex; flex-wrap: wrap; gap: var(--space-4); font-size: 13px; color: var(--ink-muted); }
.bp-legend__item { display: inline-flex; align-items: center; gap: var(--space-2); }
.bp-legend__swatch { width: 10px; height: 10px; border-radius: 2px; flex: none; }
