:root {
  --bg: #f7f5f0;
  --bg-card: #ffffff;
  --bg-sidebar: #f0ede6;
  --fg: #1a1714;
  --fg-muted: #6b6560;
  --fg-dim: #9e9890;
  --border: rgba(0,0,0,0.08);
  --accent: #c8522a;
  --accent-bg: rgba(200,82,42,0.08);
  --green: #2e7d4f;
  --green-bg: rgba(46,125,79,0.08);
  --nav-h: 56px;
  --sidebar-w: 320px;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #12100e;
    --bg-card: #1c1a17;
    --bg-sidebar: #161411;
    --fg: #f0ede6;
    --fg-muted: #9e9890;
    --fg-dim: #6b6560;
    --border: rgba(255,255,255,0.07);
    --accent: #e06b3a;
    --accent-bg: rgba(224,107,58,0.12);
    --green: #4caf78;
    --green-bg: rgba(76,175,120,0.12);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #12100e;
  --bg-card: #1c1a17;
  --bg-sidebar: #161411;
  --fg: #f0ede6;
  --fg-muted: #9e9890;
  --fg-dim: #6b6560;
  --border: rgba(255,255,255,0.07);
  --accent: #e06b3a;
  --accent-bg: rgba(224,107,58,0.12);
  --green: #4caf78;
  --green-bg: rgba(76,175,120,0.12);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.5;
  min-height: 100vh;
  padding-left: max(0px, env(safe-area-inset-left, 0px));
  padding-right: max(0px, env(safe-area-inset-right, 0px));
}

/* NAV */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 max(20px, env(safe-area-inset-left, 0px)) 0 max(20px, env(safe-area-inset-right, 0px));
  gap: 12px;
  z-index: 100;
}
.nav-logo {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.nav-freshness {
  font-size: 12px;
  color: var(--fg-dim);
  margin-right: 4px;
  white-space: nowrap;
}

.nav-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 14px;
  font: 500 13px var(--font-body);
  color: var(--fg);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.nav-btn:hover { border-color: var(--accent); background: var(--accent-bg); }
.add-btn {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.add-btn:hover { opacity: 0.88; background: var(--accent); }
.btn-donate {
  background: none;
  border: 1px solid rgba(46,125,79,0.3);
  color: var(--green);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  padding: 6px 14px;
  border-radius: 6px;
  transition: background .15s, border-color .15s;
  white-space: nowrap;
}

.btn-notify {
  background: none;
  border: 1px solid rgba(200,82,42,0.3);
  color: var(--accent);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 6px;
  transition: background .15s, border-color .15s;
  white-space: nowrap;
}
.btn-notify:hover { background: var(--accent-bg); border-color: var(--accent); }

/* LAYOUT */

/* SIDEBAR */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border);
  position: fixed;
  top: var(--nav-h);
  bottom: 0;
  left: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
.sidebar-header {
  padding: 20px 20px 12px;
  border-bottom: 1px solid var(--border);
}
.sidebar-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-dim);
}
.sidebar-count {
  font-size: 13px;
  color: var(--fg-muted);
  margin-top: 2px;
}
.book-list {
  list-style: none;
  padding: 8px 0;
  flex: 1;
}
.book-item {
  padding: 10px 16px;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: background 0.12s, border-color 0.12s;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.book-item:hover { background: var(--border); }
.book-item.active {
  background: var(--accent-bg);
  border-left-color: var(--accent);
}
.book-cover-thumb {
  width: 38px;
  flex-shrink: 0;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 3px;
  background: var(--border);
  margin-top: 2px;
}
.book-cover-placeholder {
  width: 38px;
  flex-shrink: 0;
  aspect-ratio: 2/3;
  background: var(--border);
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  margin-top: 2px;
}
.book-item-info { flex: 1; min-width: 0; }
.book-item-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--fg);
  line-height: 1.3;
  margin-bottom: 5px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.book-item-prices {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.price-current {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: 14px;
  color: var(--fg);
}
.price-mrp {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--fg-dim);
  text-decoration: line-through;
}
.discount-badge {
  font-size: 10px;
  font-weight: 600;
  background: var(--green-bg);
  color: var(--green);
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}

/* MAIN */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 32px max(32px, env(safe-area-inset-right, 0px)) 48px 32px;
  min-width: 0;
}

/* EMPTY STATE */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  text-align: center;
  gap: 12px;
  color: var(--fg-muted);
}
.empty-icon {
  font-size: 48px;
  opacity: 0.3;
  margin-bottom: 8px;
}
.empty-title {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--fg);
}
.empty-sub { font-size: 14px; max-width: 300px; }

/* BOOK DETAIL */
.book-detail { display: flex; flex-direction: column; gap: 28px; }

.detail-header { display: flex; flex-direction: column; gap: 8px; }
.detail-eyebrow {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-dim);
}
.detail-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  line-height: 1.2;
  text-wrap: balance;
  color: var(--fg);
}
.detail-header-row {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}
.detail-cover {
  width: 80px;
  flex-shrink: 0;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 5px;
  background: var(--border);
  margin-top: 4px;
}
.detail-cover-placeholder {
  width: 80px;
  flex-shrink: 0;
  aspect-ratio: 2/3;
  background: var(--border);
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-top: 4px;
}
.detail-header-text { flex: 1; min-width: 0; }
.bw-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font: 500 12px var(--font-body);
  color: var(--accent);
  background: var(--accent-bg);
  border: 1px solid rgba(200,82,42,0.2);
  border-radius: 6px;
  padding: 5px 12px;
  text-decoration: none;
  transition: opacity 0.15s;
  margin-top: 4px;
}
.bw-btn:hover { opacity: 0.8; }

/* STAT ROW */
.stat-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.stat-tile {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 22px;
  flex: 1;
  min-width: 130px;
}
.stat-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--fg-dim);
  margin-bottom: 6px;
}
.stat-value {
  font-variant-numeric: tabular-nums;
  font-size: 26px;
  font-weight: 600;
  color: var(--fg);
  line-height: 1;
}

.stat-sub {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 4px;
}

/* CHART SECTION */
.chart-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
}
.chart-section-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 20px;
}
.chart-wrap {
  overflow-x: auto;
  position: relative;
}
svg.price-chart {
  display: block;
  width: 100%;
  min-width: 320px;
}

/* CHART TOOLTIP */
.chart-tooltip {
  position: fixed;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 13px;
  color: var(--fg);
  pointer-events: none;
  z-index: 999;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  white-space: nowrap;
  display: none;
}
.chart-tooltip-price {
  font-weight: 600;
  font-size: 15px;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.chart-tooltip-date {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 2px;
}

/* ── CHART TIMELINE BUTTONS ── */

/* LOADING */
.loading {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fg-muted);
  font-size: 14px;
  padding: 60px 0;
  justify-content: center;
}

/* ADD MODAL */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay[hidden] { display: none !important; }
.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
  width: 100%;
  max-width: 440px;
  position: relative;
}
.modal-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 6px;
}
.modal-sub { font-size: 13px; color: var(--fg-muted); margin-bottom: 20px; }
.modal-input {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font: 14px var(--font-body);
  color: var(--fg);
  outline: none;
  transition: border-color 0.15s;
  margin-bottom: 16px;
}
.modal-input:focus { border-color: var(--accent); }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; }
.modal-cancel {
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 18px;
  font: 14px var(--font-body);
  color: var(--fg-muted);
  cursor: pointer;
}
.modal-submit {
  background: var(--accent);
  border: none;
  border-radius: 8px;
  padding: 9px 18px;
  font: 500 14px var(--font-body);
  color: #fff;
  cursor: pointer;
  opacity: 1;
  transition: opacity 0.15s;
}
.modal-submit:hover { opacity: 0.85; }
.modal-close {
  position: absolute;
  top: 12px; right: 14px;
  background: none;
  border: none;
  color: var(--fg-muted);
  font-size: 1.1rem;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  border-radius: 4px;
  transition: color .15s;
}

.modal-note {
  font-size: 13px;
  color: var(--fg-dim);
  margin-bottom: 16px;
  background: var(--accent-bg);
  border-radius: 6px;
  padding: 10px 12px;
  line-height: 1.5;
}

/* DONATE MODAL */
.donate-modal-content {
  text-align: center;
}
.donate-modal-content h3 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}
.donate-modal-content p {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: 24px;
}

.donate-chip {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color .15s, color .15s;
  font-variant-numeric: tabular-nums;
}

.donate-btn-main {
  width: 100%;
  background: var(--green);
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  font: 600 15px var(--font-body);
  color: #fff;
  cursor: pointer;
  transition: opacity .15s;
  margin-bottom: 12px;
}

.donate-note-small {
  font-size: 12px;
  color: var(--fg-dim);
}

/* ERROR BANNER */
.error-banner {
  background: var(--accent-bg);
  border: 1px solid rgba(200,82,42,0.2);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 13px;
  color: var(--accent);
  margin-bottom: 16px;
}

/* NO HISTORY */
.no-history {
  text-align: center;
  padding: 40px 20px;
  color: var(--fg-muted);
  font-size: 14px;
}

/* FOOTER */
.dashboard-footer {
  margin-left: var(--sidebar-w);
  border-top: 1px solid var(--border);
  padding: 20px max(32px, env(safe-area-inset-right, 0px)) 20px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--fg-muted);
}
.footer-support {
  font-size: 13px;
  color: var(--fg-dim);
}

/* ── ALERT SECTION ── */
.alert-section {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
}
.alert-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 14px;
}
.alert-active-info {
  background: var(--green-bg);
  border: 1px solid rgba(46,125,79,.2);
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 14px;
  color: var(--fg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.alert-active-price { color: var(--green); font-weight: 600; }
.alert-remove-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 13px;
  color: var(--fg-muted);
  cursor: pointer;
  transition: color .15s, border-color .15s;
}
.alert-remove-btn:hover { color: var(--accent); border-color: var(--accent); }
.alert-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-end; }
.alert-form-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 140px;
}
.alert-form-label { font-size: 12px; color: var(--fg-muted); font-weight: 500; letter-spacing: .04em; }
.alert-input {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 12px;
  font: 14px var(--font-body);
  color: var(--fg);
  outline: none;
  transition: border-color .15s;
  width: 100%;
}
.alert-input:focus { border-color: var(--accent); }
.alert-save-btn {
  background: var(--accent);
  border: none;
  border-radius: 8px;
  padding: 9px 18px;
  font: 500 14px var(--font-body);
  color: #fff;
  cursor: pointer;
  opacity: 1;
  transition: opacity .15s;
  white-space: nowrap;
  align-self: flex-end;
}
.alert-save-btn:hover { opacity: .85; }
.alert-hint { font-size: 13px; color: var(--fg-dim); margin-top: 10px; line-height: 1.6; }
.alert-delivery {
  font-size: 12px;
  color: var(--fg-dim);
  margin-top: 6px;
}
.alert-delivery strong { color: var(--fg-muted); font-weight: 500; }

/* Stack layout for tablets and folds */
@media (max-width: 1024px) {
  .layout {
    flex-direction: column;
  }
  .sidebar {
    position: relative;
    top: auto; bottom: auto; left: auto;
    width: 100%;
    height: auto;
    max-height: 50vh;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .main {
    margin-left: 0;
    padding: 24px;
  }
  .dashboard-footer {
    margin-left: 0;
    padding: 20px 24px;
  }
}

/* Phone-specific tweaks */
@media (max-width: 768px) {
  .sidebar {
    max-height: 60vh;
  }
  
  .sidebar form,
  #watchlist-search,
  #sort-select {
    display: none;
  }

  .nav-search {
    display: block !important;
    width: 140px !important;
  }
  
  .nav-freshness, 
  .nav-user,
  .btn-donate { 
    display: none; 
  }

  .stat-row { gap: 8px; }
  .stat-tile { padding: 12px 14px; min-width: 100px; }
  .stat-value { font-size: 20px; }
  .main { padding: 16px; }
}

/* ── Added: alert options, settings dialog ─────────────────────────────── */
h1.detail-title, h2.alert-section-title, h2.chart-section-title { margin: 0; }
h2.alert-section-title { margin-bottom: 12px; }
.alert-form-grid { flex-direction: column; align-items: stretch; gap: 14px; }
.alert-options { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--fg); }
.alert-options legend { margin-bottom: 6px; padding: 0; }
.alert-options label { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; cursor: pointer; }
.alert-options input[type=checkbox] { accent-color: var(--accent); }
.alert-input.alert-pct { width: 70px; padding: 4px 8px; }
.alert-form-grid .alert-save-btn { align-self: flex-start; }
.br-verdict { margin: 16px 0; }
.book-item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

.settings-modal { max-width: 520px; width: 100%; text-align: left; max-height: calc(100vh - 32px); overflow-y: auto; position: relative; }
.settings-section { padding: 16px 0; border-top: 1px solid var(--border); }
.settings-section:first-child { border-top: 0; padding-top: 4px; }
.settings-section h3 { font-size: 15px; margin: 0 0 8px; }
.settings-toggle { display: flex; gap: 10px; align-items: center; font-size: 14px; cursor: pointer; }
.settings-toggle input { accent-color: var(--accent); width: 16px; height: 16px; }
.settings-hint { font-size: 12.5px; color: var(--fg-muted); margin: 6px 0 10px; line-height: 1.5; }
.settings-hint a { color: var(--accent); }
.share-row { display: flex; gap: 8px; }
.share-row .modal-input { flex: 1; margin: 0; }
.share-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.followed-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.followed-list li { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 14px; }
.followed-list a { color: var(--fg); }
.alert-active-info { margin-bottom: 14px; }
/* The clickable part of each watchlist row is a real button (keeps list semantics) */
.book-item-btn {
  display: flex; gap: 12px; align-items: flex-start; width: 100%; padding: 0; margin: 0;
  background: none; border: 0; color: inherit; font: inherit; text-align: left; cursor: pointer;
}
.book-item-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }

/* Detail header: bigger cover, centred against the title + buttons */
.detail-header-row { align-items: center; }
.detail-cover, .detail-cover-placeholder { width: 112px; margin-top: 0; border-radius: 6px; box-shadow: 0 2px 10px rgba(0,0,0,.12); }
@media (max-width: 600px) { .detail-cover, .detail-cover-placeholder { width: 88px; } }

/* Settings: password / delete account */
.settings-form { display: flex; flex-direction: column; gap: 8px; }
.settings-form .modal-input { margin: 0; }
.settings-form .settings-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.settings-msg { font-size: 12.5px; }
.settings-msg.err { color: var(--accent); }
.settings-msg.ok { color: var(--green); }
.danger-btn { background: none; border: 1px solid var(--accent); color: var(--accent); border-radius: 6px;
  padding: 8px 14px; font: 600 13px var(--font-body, inherit); cursor: pointer; }
.danger-btn:hover { background: var(--accent-bg); }

/* Navbar actions: inline on wide screens, a ☰ menu below 1200px (they don't all fit before that) */
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-menu-btn { display: none; font-size: 16px; line-height: 1; padding: 6px 12px; }
@media (max-width: 1200px) {
  nav { gap: 10px; }
  .nav-search { flex: 1 1 auto; min-width: 0; width: auto !important; margin-left: 4px !important; }
  .nav-menu-btn { display: inline-flex; }
  .nav-actions {
    display: none; position: absolute; top: calc(var(--nav-h) - 4px); right: 12px; z-index: 200;
    flex-direction: column; align-items: stretch; gap: 6px; min-width: 210px; padding: 10px;
    background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,.25);
  }
  .nav-actions.open { display: flex; }
  .nav-actions > * { width: 100%; justify-content: flex-start; text-align: left; padding: 10px 14px; font-size: 14px; }
  .nav-actions [hidden] { display: none !important; }
  .nav-actions .nav-label { display: inline !important; }
  .nav-actions .btn-donate { display: block; }      /* reachable from the menu on phones */
  .nav-actions .nav-user:empty { display: none; }
}

.dash-footer-links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 12px; }
.dash-footer-links a { color: var(--fg-muted); text-decoration: none; }
.dash-footer-links a:hover { color: var(--accent); text-decoration: underline; }

/* ── Select multiple (remove several books at once) ───────────────────────── */
.pick-toggle {
  font: 500 12px var(--font-body); padding: 5px 10px; border-radius: 6px; cursor: pointer;
  background: var(--bg-card); color: var(--fg); border: 1px solid var(--border);
}
.pick-toggle:hover { border-color: var(--accent); color: var(--accent); }
.pick-toggle[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.pick-box {
  width: 18px; height: 18px; flex-shrink: 0; margin-top: 2px; border-radius: 4px; border: 1.5px solid var(--border);
  background: var(--bg-card); display: grid; place-items: center; font-size: 12px; color: transparent;
}
.book-item.picked { background: var(--accent-bg); }
.book-item.picked .pick-box { background: var(--accent); border-color: var(--accent); color: #fff; }
.pick-bar {
  position: sticky; bottom: 0; z-index: 2;
  flex: none; display: flex; align-items: center; gap: 8px; padding: 10px 14px;
  border-top: 1px solid var(--border); background: var(--bg-sidebar);
}
.pick-bar[hidden] { display: none; }
.pick-count { flex: 1; font-size: 13px; color: var(--fg-muted); }
.pick-btn {
  font: 500 12px var(--font-body); padding: 6px 10px; border-radius: 6px; cursor: pointer;
  background: var(--bg-card); color: var(--fg); border: 1px solid var(--border);
}
.pick-btn:disabled { opacity: .45; cursor: not-allowed; }
.pick-remove:not(:disabled) { background: var(--red, #c0392b); border-color: var(--red, #c0392b); color: #fff; }
