:root {
  --bg: #f5f6f8;
  --panel: #ffffff;
  --border: #dfe3e8;
  --text: #1f2430;
  --muted: #6b7280;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --danger: #dc2626;
  --ok: #16a34a;
  --warn: #d97706;
  --gray: #6b7280;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  background: var(--bg);
  color: var(--text);
}

header {
  padding: 24px 32px 16px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
}

.top-nav {
  display: flex;
  gap: 4px;
  margin-bottom: 12px;
}

.top-nav a {
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 6px;
}

.top-nav a:hover { background: var(--bg); }

.top-nav a.active {
  color: var(--primary);
  background: #eff6ff;
}

.nav-spacer {
  flex: 1;
}

.current-user-label {
  font-size: 13px;
  color: var(--muted);
  align-self: center;
  margin-right: 4px;
}

.login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}

.login-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  width: 100%;
  max-width: 360px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.login-card h1 {
  font-size: 20px;
  margin-bottom: 4px;
}

.login-card form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 16px;
}

.login-card label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}

.login-card input {
  font-size: 14px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.login-error {
  color: var(--danger);
  font-size: 13px;
  margin: 0;
}

h1 {
  margin: 0 0 8px;
  font-size: 22px;
}

.badge {
  font-size: 12px;
  font-weight: 600;
  color: var(--warn);
  border: 1px solid var(--warn);
  border-radius: 4px;
  padding: 2px 6px;
  vertical-align: middle;
}

/* 商品管理トップのブランド表示(STG CONTROL ROOM / eBay Operations System)。2行をひとまとまりに詰める。 */
.brand { margin: 0 0 16px; }
.brand-title { margin: 0; line-height: 1.2; }
.brand-sub { margin: 2px 0 0; font-size: 12px; color: var(--gray); letter-spacing: 0.02em; }

.notice {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--muted);
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 6px;
  padding: 8px 12px;
  max-width: 720px;
}

main {
  padding: 24px 32px;
}

.search-bar {
  margin-bottom: 12px;
}

.search-bar input {
  width: 100%;
  max-width: 480px;
  font-family: inherit;
  font-size: 14px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  background: var(--panel);
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

th, td {
  padding: 10px 12px;
  text-align: left;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th {
  background: #fafbfc;
  font-weight: 600;
  color: var(--muted);
}

tr:last-child td {
  border-bottom: none;
}

td a {
  color: var(--primary);
  text-decoration: none;
  word-break: break-all;
}

td a:hover { text-decoration: underline; }

.cell-sub {
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.status-pill {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.status-在庫あり { background: #dcfce7; color: var(--ok); }
.status-売り切れ { background: #fee2e2; color: var(--danger); }
.status-ページ削除 { background: #e5e7eb; color: var(--gray); }
.status-判定不能 { background: #fef3c7; color: var(--warn); }
.status-在庫切れ { background: #fee2e2; color: var(--danger); }

.check-note {
  color: var(--muted);
  font-size: 11px;
  margin-top: 4px;
  max-width: 220px;
}

.check-note.ebay-zero-alert {
  color: var(--danger);
}

/* 要再照合のまま仕入れ元が在庫あり(販売機会損失): 行全体と目立つピルで知らせる */
tr.row-sales-loss td {
  background: #fff1f2;
  border-top: 2px solid var(--danger);
  border-bottom: 2px solid var(--danger);
}

.sales-loss-pill {
  display: inline-block;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--danger);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
}

.count-pill.count-zero-alert { background: #fee2e2; color: var(--danger); }
.count-pill.count-zero-alert.count-sales-loss { background: var(--danger); color: #ffffff; }
.count-pill[hidden] { display: none; }

button {
  font-family: inherit;
  font-size: 13px;
  border-radius: 6px;
  padding: 7px 14px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: var(--panel);
}

button.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
  font-weight: 600;
}

button.primary:hover { background: var(--primary-hover); }

button.secondary { background: var(--panel); color: var(--text); }

button.small {
  padding: 4px 8px;
  font-size: 12px;
  margin-right: 4px;
  margin-bottom: 4px;
}

button.danger-text { color: var(--danger); border-color: #fecaca; }

button.danger {
  background: var(--danger);
  border-color: var(--danger);
  color: white;
  font-weight: 600;
}

button.danger:hover { background: #b91c1c; }

.modal-small { max-width: 360px; }

.actions-cell { min-width: 140px; }

.empty-msg {
  text-align: center;
  color: var(--muted);
  padding: 40px 0;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.modal-backdrop[hidden] {
  display: none;
}

.modal {
  background: var(--panel);
  border-radius: 10px;
  padding: 24px;
  width: 420px;
  max-width: 90vw;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.modal h2 {
  margin: 0 0 16px;
  font-size: 17px;
}

.mode-switch {
  display: flex;
  gap: 4px;
  margin: -8px 0 16px;
  background: var(--bg);
  border-radius: 8px;
  padding: 4px;
}

.mode-switch[hidden] {
  display: none;
}

.mode-switch .mode-btn {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  border-radius: 6px;
}

.mode-switch .mode-btn.active {
  background: var(--panel);
  color: var(--primary);
  box-shadow: 0 1px 2px rgba(0,0,0,0.08);
}

.modal form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: var(--muted);
  flex: 1;
}

.modal input, .modal select {
  font-family: inherit;
  font-size: 14px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
}

.modal .row {
  display: flex;
  gap: 12px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

.warning-banner {
  margin: 16px 32px 0;
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #991b1b;
  border-radius: 8px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
}

.panel {
  margin: 16px 32px 0;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px 20px;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.panel-header h2 {
  margin: 0;
  font-size: 16px;
}

.section-title {
  margin: 28px 0 12px;
  font-size: 16px;
}

.toggle-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}

.panel-sub {
  margin: 6px 0 14px;
  font-size: 12px;
  color: var(--muted);
}

.monitor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px 20px;
  margin: 0 0 14px;
}

.monitor-grid dt {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 2px;
}

.monitor-grid dd {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
}

#monitor-running-badge.badge-running { color: var(--warn); }
#monitor-running-badge.badge-idle { color: var(--ok); }

.monitor-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.count-pill {
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f1f5f9;
  color: var(--text);
}

.count-pill.count-ok { background: #dcfce7; color: var(--ok); }
.count-pill.count-warn { background: #fee2e2; color: var(--danger); }
.count-pill.count-unknown { background: #fef3c7; color: var(--warn); }
.count-pill.count-error { background: #ede9fe; color: #6d28d9; }

.count-pill-clickable {
  cursor: pointer;
  border: 1px solid transparent;
}
.count-pill-clickable:hover { filter: brightness(0.96); }
.count-pill-clickable.active {
  border-color: currentColor;
  font-weight: 700;
}

tr.row-warning td {
  background: #fef2f2;
}

tr.row-unknown td {
  background: #fffbeb;
}

/* --- PROFIT CALCULATOR (profit.html) ---------------------------------- */
.profit-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
@media (max-width: 800px) {
  .profit-layout { grid-template-columns: minmax(0, 1fr); }
}
.profit-inputs form { display: flex; flex-direction: column; gap: 10px; }
.profit-inputs label, .profit-shipping label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.profit-inputs input, .profit-inputs select, .profit-shipping input, .profit-shipping select { padding: 8px; font-size: 14px; width: 100%; box-sizing: border-box; }
.profit-inputs .row, .profit-shipping .row { display: flex; gap: 10px; flex-wrap: wrap; }
.profit-inputs .row > label, .profit-shipping .row > label { flex: 1 1 140px; }
.profit-group { margin: 14px 0 0; font-size: 13px; color: var(--gray); }
.profit-hint { margin: 0; font-size: 12px; color: var(--gray); }
.profit-fixed { margin: 0; display: grid; gap: 4px; font-size: 13px; }
.profit-fixed div { display: flex; justify-content: space-between; gap: 12px; }
.profit-fixed dt { color: var(--gray); }
.profit-fixed dd { margin: 0; text-align: right; }
.profit-message { color: var(--gray); font-size: 14px; }
.profit-message-error { color: var(--danger); }
.profit-warnings {
  background: #fef3c7; color: var(--warn); border-radius: 6px;
  padding: 8px 12px; margin-bottom: 12px; font-size: 13px; font-weight: 600;
}
.profit-summary { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.profit-kpi {
  flex: 1 1 140px; border: 1px solid var(--border, #e5e7eb); border-radius: 8px;
  padding: 10px 14px; display: flex; flex-direction: column; gap: 4px;
}
.profit-kpi-label { font-size: 12px; color: var(--gray); }
.profit-kpi b { font-size: 24px; color: var(--ok); }
.profit-kpi b.profit-negative { color: var(--danger); }
.profit-table { width: 100%; }
.profit-table th { font-weight: normal; text-align: left; }
.profit-table td { text-align: right; white-space: nowrap; }
.profit-table .profit-sect th { font-weight: 700; background: var(--bg); }
.profit-table .profit-strong th, .profit-table .profit-strong td { font-weight: 700; }

/* --- スマホ幅: ナビの折り返し(全ページ共通) ------------------------------
   リンクが増えて1行に収まらないとき、リンク内の文字が1文字ずつ改行されて
   潰れていたため、ナビ全体は折り返し可・各項目は途中で改行しない。
   PC幅(>600px)には適用されない。 */
@media (max-width: 600px) {
  .top-nav { flex-wrap: wrap; row-gap: 4px; }
  .top-nav a,
  .top-nav .current-user-label,
  .top-nav button { white-space: nowrap; }
}

/* PROFIT CALCULATOR: DDP専用の入力欄(DDU時は非表示) */
.profit-ddp-fields { display: flex; flex-direction: column; gap: 10px; }
.profit-ddp-fields[hidden] { display: none; }
.profit-tentative {
  display: inline-block; margin-left: 4px; padding: 1px 6px; border-radius: 4px;
  font-size: 11px; font-weight: 600; background: #fef3c7; color: var(--warn);
}

/* --- PROFIT CALCULATOR: 送料計算機パネル ------------------------------- */
.profit-right { min-width: 0; }
.profit-shipping { margin: 16px 32px 0; border: 1px solid var(--border); border-radius: 8px; padding: 16px 20px; background: var(--panel); }
.profit-shipping > summary { cursor: pointer; font-size: 13px; font-weight: 600; color: var(--primary); }
.profit-ship-body { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }
.profit-ship-scroll { overflow-x: auto; }
.profit-ship-table th { white-space: nowrap; }
.profit-ship-table td { text-align: left; vertical-align: top; white-space: normal; }
.profit-ship-table td:first-child { min-width: 130px; }
.profit-ship-table td.ship-price-cell { text-align: center; white-space: nowrap; }
.ship-price { font-weight: 700; font-size: 15px; margin-bottom: 4px; }
.ship-use-btn { white-space: nowrap; }
.profit-ship-table tr.ship-ineligible { color: var(--muted); }
.profit-ship-table tr.ship-ineligible .ship-price { color: var(--muted); font-weight: 600; }
.profit-ship-table tr.ship-selected { background: #eff6ff; }
.ship-name { font-weight: 600; }
.ship-badge { margin-left: 6px; padding: 1px 6px; border-radius: 4px; font-size: 11px; background: #dcfce7; color: var(--ok); }
.ship-sub, .ship-line { font-size: 12px; color: var(--muted); }
.ship-estimate { font-size: 11px; font-weight: 600; color: var(--warn); white-space: nowrap; }
.ship-warn { font-size: 12px; color: var(--warn); }
.ship-reason { font-size: 12px; color: var(--danger); font-weight: 600; }
.profit-ship-applied { margin: 0; font-size: 12px; font-weight: 600; color: var(--ok); }

/* スマホ幅: 送料比較の表をカード形式にする(表を横に切らない) */
@media (max-width: 600px) {
  .profit-ship-table thead { display: none; }
  .profit-ship-table, .profit-ship-table tbody, .profit-ship-table tr, .profit-ship-table td { display: block; width: 100%; box-sizing: border-box; }
  .profit-ship-table tr { border-bottom: 1px solid var(--border); padding: 8px 4px; }
  .profit-ship-table td { border: none; padding: 2px 4px; text-align: left; }
  .profit-ship-table td:first-child { min-width: 0; }
  .profit-ship-table td.ship-price-cell { display: flex; align-items: center; gap: 12px; white-space: nowrap; text-align: left; }
  .ship-price { margin-bottom: 0; }
}

/* 出品（Phase 1） */
.listing-layout { display: flex; flex-direction: column; gap: 16px; max-width: 900px; margin: 0 auto; }
.listing-layout form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.listing-layout form label { flex: 1 1 320px; }
.listing-body { display: flex; gap: 20px; flex-wrap: wrap; }
.listing-images { display: flex; flex-wrap: wrap; gap: 8px; flex: 1 1 320px; }
.listing-images img { width: 120px; height: 120px; object-fit: cover; border-radius: 6px; border: 1px solid var(--border); }
.listing-facts { flex: 1 1 260px; margin: 0; display: grid; gap: 6px; font-size: 13px; }
.listing-facts div { display: flex; justify-content: space-between; gap: 12px; }
.listing-facts dt { color: var(--gray); }
.listing-facts dd { margin: 0; text-align: right; word-break: break-all; }
.listing-description { white-space: pre-wrap; font-family: inherit; font-size: 13px; background: var(--panel); border: 1px solid var(--border); border-radius: 6px; padding: 10px; }

/* 出品（Phase 2: eBay出品データ編集フォーム） */
#listing-draft label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; margin-bottom: 10px; }
#listing-draft input, #listing-draft select, #listing-draft textarea { padding: 8px; font-size: 14px; width: 100%; box-sizing: border-box; font-family: inherit; }
#listing-draft .row > label { flex: 1 1 200px; margin-bottom: 0; }
.listing-char-count { margin: -6px 0 10px; font-size: 12px; color: var(--gray); text-align: right; }
.listing-specifics { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.listing-specifics-row { display: flex; gap: 8px; align-items: center; }
.listing-specifics-row input { flex: 1 1 auto; }

/* 出品（Phase 3: Discogs複数候補の手動選択） */
.listing-discogs-candidates { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 14px; }
.listing-discogs-candidate { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 10px; border: 1px solid var(--border); border-radius: 6px; background: var(--panel); font-size: 12px; }
.listing-discogs-candidate span { flex: 1 1 auto; }

/* 下書き一覧・編集(drafts.html) */
.drafts-layout { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); align-items: start; }
@media (max-width: 900px) { .drafts-layout { grid-template-columns: 1fr; } }
.drafts-list-panel { margin-right: 0; }
.drafts-table { width: 100%; font-size: 13px; }
.drafts-row { cursor: pointer; }
.drafts-row:hover td { background: var(--bg); }
.drafts-row.active td { background: #dbeafe; }
.drafts-warn-text { color: var(--warn); font-weight: 600; }
.drafts-editor h3 { margin: 20px 0 8px; font-size: 14px; }
.drafts-editor label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; margin-bottom: 8px; }
.drafts-editor .toggle-label { flex-direction: row; }
.drafts-editor input[type=text], .drafts-editor input[type=url], .drafts-editor input[type=number],
.drafts-editor select, .drafts-editor textarea { padding: 8px; font-size: 14px; width: 100%; box-sizing: border-box; font-family: inherit; }
.drafts-editor .row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.drafts-editor [hidden] { display: none !important; }
.drafts-editor .row > label { flex: 1 1 200px; }
.drafts-inline-actions { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.drafts-source { margin: 8px 0 0; }
.drafts-checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; font-size: 13px; }
.drafts-checks ul { margin: 0; padding-left: 18px; }
.drafts-review { background: #fef3c7; border-radius: 6px; padding: 8px 12px; font-size: 13px; margin-bottom: 8px; }
.drafts-review p { margin: 0 0 6px; }
.drafts-specific-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr) auto; gap: 6px; margin-bottom: 6px; }
.drafts-specific-required .drafts-specific-name { font-weight: 600; }
.drafts-specific-required .drafts-specific-value:placeholder-shown { border-color: #d97706; background: #fffbeb; }
.drafts-preview { width: 100%; min-height: 140px; border: 1px solid var(--border); border-radius: 6px; margin-top: 8px; background: #fff; }
.drafts-images { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 8px; }
.drafts-image-card { width: 132px; display: flex; flex-direction: column; gap: 4px; }
.drafts-image-card img { width: 132px; height: 132px; object-fit: cover; border: 1px solid var(--border); border-radius: 6px; background: var(--bg); }
.drafts-image-buttons { display: flex; gap: 4px; }
.drafts-image-buttons button { padding: 2px 6px; }
.drafts-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 20px; padding-top: 12px; border-top: 1px solid var(--border); }
.drafts-status-draft { background: #e5e7eb; color: var(--gray); }
.drafts-status-ready { background: #dcfce7; color: var(--ok); }
.drafts-status-error { background: #fee2e2; color: var(--danger); }
.drafts-preview-box { border: 1px solid var(--border); border-radius: 6px; padding: 10px 14px; margin-top: 8px; background: var(--bg); font-size: 13px; }
.drafts-preview-box h4 { margin: 10px 0 4px; font-size: 13px; }
.drafts-preview-box ul { margin: 0; padding-left: 18px; }
.drafts-preview-box pre { background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 8px; overflow-x: auto; font-size: 12px; white-space: pre-wrap; word-break: break-all; }
.drafts-preview-ok { color: var(--ok); font-weight: 600; }
.drafts-preview-ng { color: var(--danger); font-weight: 600; }
.drafts-tracklist { list-style: none; margin: 0 0 8px; padding: 0; font-size: 13px; columns: 2; }
.drafts-tracklist .drafts-subtrack { padding-left: 1.5em; }

/* アパレルの下書き編集 */
.drafts-apparel { border: 1px solid #d6dbe6; border-radius: 8px; padding: 8px 12px 12px; margin-bottom: 16px; }
.drafts-aspects-table { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 13px; }
.drafts-aspects-table th, .drafts-aspects-table td { border-bottom: 1px solid #e3e6ee; padding: 4px 6px; text-align: left; }
.drafts-auto-mark { background: #e3f4e6; color: #1d6b2e; border-radius: 4px; padding: 0 5px; font-size: 12px; }
.drafts-need-mark { background: #fde8e8; color: #a12020; border-radius: 4px; padding: 0 5px; font-size: 12px; }
.drafts-manual-mark { background: #eef0f5; color: #3b4254; border-radius: 4px; padding: 0 5px; font-size: 12px; }
.drafts-measure-row { display: flex; gap: 6px; align-items: center; margin-bottom: 4px; flex-wrap: wrap; }
.drafts-measure-row input[type=number] { width: 90px; }

/* 仕入れ価格の変更(/price-watch と商品管理のピル)。値上がり = 赤系、値下がり = 青系、種別変更 = 紫系 */
.pw-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.pw-badge.pw-up, .count-pill.pw-up { background: #fee2e2; color: var(--danger); }
.pw-badge.pw-down, .count-pill.pw-down { background: #dbeafe; color: var(--primary-hover); }
.pw-badge.pw-switch, .count-pill.pw-switch { background: #ede9fe; color: #6d28d9; }
.pw-badge.pw-open { background: #fef3c7; color: var(--warn); }
.pw-event { margin-bottom: 6px; }
.pw-diff { font-weight: 700; }
.pw-mode-badge { font-size: 12px; color: var(--muted); }
.pw-actions button { margin: 0 4px 4px 0; }
tr.pw-row-open td { background: #fffbeb; }
.pw-history-modal { max-width: 960px; width: 94%; max-height: 86vh; overflow: auto; }
a.count-pill { text-decoration: none; }
.count-pill.count-price-watch.pw-has-open { background: #fef3c7; color: var(--warn); font-weight: 700; }
#pw-table th { white-space: nowrap; }
#pw-table td a { white-space: nowrap; }
