:root {
  --bg: #f4f6fa;
  --card: #ffffff;
  --line: #e5e9f0;
  --text: #1f2937;
  --muted: #8a94a6;
  --accent: #2563eb;
  --accent-soft: #eff4ff;
  --red: #e04050;
  --green: #12a670;
  --amber: #d97706;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
/* min-height 而不是 height：让 body 在内容多时自然撑高，浏览器可滚动 */
html, body { min-height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px;
  overflow-y: auto;       /* 内容多时 body 自己滚，不要把滚动限制在 .main 内 */
}
a { text-decoration: none; color: inherit; }
img { referrerpolicy: no-referrer; }

.layout { display: flex; min-height: 100vh; }

/* ---------- 侧栏 ---------- */
.sidebar {
  width: 220px; flex-shrink: 0; background: #101a2e; color: #cbd5e1;
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
}
.logo { display: flex; gap: 10px; align-items: center; padding: 20px 18px; border-bottom: 1px solid rgba(255,255,255,.08); }
.logo-icon {
  width: 38px; height: 38px; border-radius: 10px; background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 17px;
}
.logo-title { color: #fff; font-weight: 600; font-size: 15px; }
.logo-sub { font-size: 11px; color: #64748b; margin-top: 2px; }
.nav { padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.nav a {
  display: flex; align-items: center; padding: 10px 14px; border-radius: 8px;
  color: #94a3b8; font-size: 14px; transition: all .15s;
}
.nav a:hover { background: rgba(255,255,255,.06); color: #e2e8f0; }
.nav a.active { background: var(--accent); color: #fff; font-weight: 500; }
.nav .ico { display: none; }
.sidebar-foot { padding: 14px 18px; border-top: 1px solid rgba(255,255,255,.08); }
.sync-dot { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #64748b; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #475569; display: inline-block; }
.sync-dot.running .dot { background: #f59e0b; animation: pulse 1s infinite; }
.sync-dot.done .dot { background: var(--green); }
@keyframes pulse { 50% { opacity: .3; } }

/* ---------- 主区 ---------- */
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 60px; background: var(--card); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
  position: sticky; top: 0; z-index: 10;
}
.topbar-left { display: flex; align-items: center; gap: 14px; }
.topbar h1 { font-size: 17px; font-weight: 600; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.last-sync { color: var(--muted); font-size: 12px; }
.view { padding: 24px; }

/* ---------- 通用 ---------- */
.btn {
  border: 1px solid var(--line); background: var(--card); color: var(--text);
  padding: 7px 14px; border-radius: 8px; cursor: pointer; font-size: 13px; transition: all .15s;
}
.btn:hover { border-color: #c3cbd9; background: #f8fafc; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: #1d4ed8; }
.btn-danger { color: var(--red); }
.btn-danger:hover { border-color: var(--red); background: #fef2f3; }
.btn-sm { padding: 4px 10px; font-size: 12px; border-radius: 6px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.card + .card { margin-top: 16px; }
.grid-2 > .card { margin-top: 0; }   /* grid 内第二个 card 不要上下 margin，否则 cell 起点错位 */
.card-title { font-size: 15px; font-weight: 600; margin-bottom: 16px; display: flex; justify-content: space-between; align-items: center; }
.card-title .more { font-size: 12px; color: var(--muted); font-weight: 400; }

.tag {
  display: inline-block; padding: 1px 8px; border-radius: 5px; font-size: 11px;
  background: #f1f5f9; color: #64748b; margin-right: 4px; vertical-align: middle;
}
.tag-blue { background: var(--accent-soft); color: var(--accent); }
.tag-purple { background: #f5f3ff; color: #7c3aed; }
.tag-green { background: #ecfdf5; color: var(--green); }
.tag-red { background: #fef2f2; color: var(--red); }
.tag-amber { background: #fffbeb; color: var(--amber); }
.form-title { font-weight: 600; color: var(--text); white-space: nowrap; }
.src-badge {
  position: absolute; left: 14px; top: 10px; z-index: 1;
  font-size: 11px; padding: 1px 8px; border-radius: 5px; color: #fff;
}
.src-badge.sc { background: rgba(37, 99, 235, .85); }
.src-badge.cb { background: rgba(124, 58, 237, .85); }
.price { color: var(--red); font-weight: 700; }
.muted { color: var(--muted); }
.empty { text-align: center; color: var(--muted); padding: 48px 0; }

/* ---------- 统计卡片 ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; }
.stat-card .label { color: var(--muted); font-size: 12px; margin-bottom: 8px; }
.stat-card .value { font-size: 26px; font-weight: 700; letter-spacing: -.5px; }
.stat-card .sub { font-size: 11px; color: var(--muted); margin-top: 6px; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: stretch; }
.grid-2 > * { min-width: 0; height: 100%; box-sizing: border-box; }   /* 强制 grid 子项 stretch 到 cell 高度 */
/* 让 .card / 子 div 在 grid cell 内 stretch 到 cell 全高 */
.grid-2 > .card,
.grid-2 > div:not(.detail-grid):not(.config-chips) { display: flex; flex-direction: column; }
@media (max-width: 1000px) { .grid-2 { grid-template-columns: 1fr; } }

/* ---------- 条形图 ---------- */
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.bar-row.clickable { cursor: pointer; border-radius: 6px; }
.bar-row.clickable:hover { background: #f1f5fd; }
.bar-row.clickable:hover .bar-fill { background: linear-gradient(90deg, #2563eb, #1d4ed8); }
.vbar.clickable { cursor: pointer; }
.vbar.clickable:hover .col { background: linear-gradient(180deg, #2563eb, #1e40af); }
.vbar.clickable:hover .num { color: var(--accent); font-weight: 700; }
.stat-card.clickable { cursor: pointer; transition: all .15s; }
.stat-card.clickable:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(16,24,40,.12); border: 1px solid #dbe4f5; }
.clickable-sub { cursor: pointer; color: var(--accent); }
.clickable-sub:hover { text-decoration: underline; }
.filter-chips { margin-bottom: 10px; }
.fchip { font-size: 12px; cursor: default; }
.fchip .x { cursor: pointer; font-weight: 700; margin-left: 4px; }
.fchip .x:hover { color: var(--red); }
.bar-row .bar-label { width: 90px; text-align: right; color: #475569; font-size: 12px; flex-shrink: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-row .bar-track { flex: 1; background: #f1f5f9; border-radius: 5px; height: 18px; overflow: hidden; }
.bar-row .bar-fill { height: 100%; border-radius: 5px; background: linear-gradient(90deg, #3b82f6, #2563eb); min-width: 2px; }
.bar-row .bar-val { width: 46px; font-size: 12px; color: #475569; flex-shrink: 0; }

.vbar-chart { display: flex; align-items: flex-end; gap: 12px; height: 160px; padding-top: 10px; }
.vbar { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.vbar .col { width: 100%; max-width: 46px; border-radius: 6px 6px 0 0; background: linear-gradient(180deg, #60a5fa, #2563eb); min-height: 3px; }
.vbar .num { font-size: 12px; color: #475569; }
.vbar .lbl { font-size: 11px; color: var(--muted); white-space: nowrap; }

/* ---------- 表格 ---------- */
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left; font-size: 12px; color: var(--muted); font-weight: 500;
  padding: 10px 12px; border-bottom: 1px solid var(--line); background: #fafbfd;
}
.table td { padding: 10px 12px; border-bottom: 1px solid #f1f4f8; font-size: 13px; }
.table tr:last-child td { border-bottom: none; }
.table tr.clickable { cursor: pointer; }
.table tr.clickable:hover td { background: #f8fafd; }
/* §111 B 端详情页「价格历史」表格：强调变动幅度列 */
.price-history-table { margin-top: 12px; }
.price-history-table th { background: #fef9f4; }
.price-history-table td { font-variant-numeric: tabular-nums; }
.price-history-table tr:hover td { background: #fafbfd; }
.price-history-table b { font-weight: 600; color: #1f1f1f; }
.price-history-table s.muted { color: #94a3b8; }

/* ---------- 车源卡片 ---------- */
.car-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.car-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  overflow: hidden; cursor: pointer; transition: transform .15s, box-shadow .15s;
  display: flex; flex-direction: column;
}
.car-card:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(16,24,40,.1); }
.car-card .img-box { position: relative; aspect-ratio: 4/3; background: #eef1f6; overflow: hidden; }
.car-card .img-box img { width: 100%; height: 100%; object-fit: cover; display: block; }
.car-card .off-badge {
  position: absolute; top: 8px; left: 8px; background: rgba(15,23,42,.7); color: #cbd5e1;
  font-size: 11px; padding: 2px 8px; border-radius: 5px;
}
.car-card .body { padding: 12px 14px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.car-card .title { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.car-card .subtitle { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.car-card .meta { display: flex; flex-wrap: wrap; gap: 4px; }
.car-card .foot { display: flex; justify-content: space-between; align-items: baseline; margin-top: auto; }
.car-card .price { font-size: 17px; }
.car-card .price small { font-size: 11px; font-weight: 400; }
.car-card .guide { color: var(--muted); font-size: 11px; }
/* 2026-10-13: 列表底部追加「最新拉取/最新调价」时间痕迹（label + 值，读得懂）*/
.car-card .time-trace {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed #e8e8e8;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 11px;
  color: var(--muted);
}
.car-card .time-trace .time-row { display: flex; gap: 6px; align-items: baseline; }
.car-card .time-trace i {
  font-style: normal;
  color: #94a3b8;
  min-width: 36px;
  text-align: right;
  flex-shrink: 0;
}
.car-card .time-trace .chg-down { color: var(--green); font-weight: 500; }
.car-card .time-trace .chg-up   { color: var(--red); font-weight: 500; }

/* ---------- 筛选栏 ---------- */
.filter-bar {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 14px 16px; margin-bottom: 16px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
}
.filter-bar select, .filter-bar input {
  border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; font-size: 13px;
  background: #fff; color: var(--text); min-width: 90px; outline: none;
}
.filter-bar select:focus, .filter-bar input:focus { border-color: var(--accent); }
.filter-bar input.price-input { width: 80px; }
.filter-spacer { flex: 1; }

.pager { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 18px; }
.pager .info { color: var(--muted); font-size: 12px; margin: 0 8px; }

/* ---------- 门店 ---------- */
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.shop-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.shop-card .banner { height: 110px; background: linear-gradient(135deg, #1e3a8a, #2563eb); position: relative; background-size: cover; background-position: center; }
.shop-card .banner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(13,22,44,.15), rgba(13,22,44,.65)); }
.shop-card .banner .name {
  position: absolute; left: 16px; right: 76px; bottom: 10px; color: #fff; font-weight: 600;
  font-size: 15px; z-index: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.shop-card .banner .code { position: absolute; right: 14px; top: 10px; z-index: 1; background: rgba(255,255,255,.2); backdrop-filter: blur(4px); color: #fff; font-size: 11px; padding: 2px 8px; border-radius: 5px; }
.shop-card .inner { padding: 14px 16px; }
.shop-card .row { display: flex; gap: 8px; margin-bottom: 6px; font-size: 12px; color: #475569; align-items: baseline; }
.shop-card .row .k { color: var(--muted); flex-shrink: 0; width: 60px; }
.shop-card .nums { display: flex; gap: 18px; margin: 10px 0; }
.shop-card .nums .n { font-size: 20px; font-weight: 700; }
.shop-card .nums .l { font-size: 11px; color: var(--muted); }
.shop-card .ops { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }

.add-shop-bar {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 14px 16px; margin-bottom: 16px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
}
.add-shop-bar input { flex: 1; min-width: 200px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; font-size: 13px; outline: none; }
.add-shop-bar input:focus { border-color: var(--accent); }
.hint { font-size: 12px; color: var(--muted); }

/* ---------- 品牌 ---------- */
.brand-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; }
.brand-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px 8px;
  text-align: center; cursor: pointer; transition: all .15s;
}
.brand-card:hover { border-color: var(--accent); box-shadow: 0 4px 12px rgba(37,99,235,.12); }
.brand-card.active { border-color: var(--accent); background: var(--accent-soft); }
.brand-card img { width: 48px; height: 48px; object-fit: contain; margin-bottom: 8px; }
.brand-card .name { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-card .count { font-size: 11px; color: var(--muted); margin-top: 4px; }
.series-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.series-chip {
  display: inline-flex; align-items: center; gap: 6px; background: #f8fafc; border: 1px solid var(--line);
  border-radius: 18px; padding: 5px 12px; font-size: 12px; cursor: pointer; color: #334155;
}
.series-chip:hover { border-color: var(--accent); color: var(--accent); }
.series-chip .cnt { background: #e2e8f0; border-radius: 9px; padding: 0 6px; font-size: 11px; }

/* ---------- 车辆详情页 ---------- */
.detail-hero { padding: 24px; }
.detail-hero-main { display: flex; gap: 24px; align-items: stretch; }
.detail-img { flex-shrink: 0; width: 460px; max-width: 45%; border-radius: 12px; overflow: hidden; background: #eef1f6; aspect-ratio: 4/3; }
.detail-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.desc-text { white-space: pre-wrap; color: #475569; line-height: 1.8; font-size: 13px; }
/* 右侧信息：stretch 跟主图同高，flex column 让 chips 区占满剩余空间 */
.detail-hero-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.detail-hero-info h2 { font-size: 24px; margin-top: 10px; }
/* 2026-10-14: 详情页头部加品牌 logo（48x48 圆角方图，跟 h2 baseline 对齐） */
.detail-title-row { display: flex; align-items: center; gap: 14px; margin-top: 10px; }
.brand-logo-lg {
  width: 48px; height: 48px;
  border-radius: 6px;
  overflow: hidden;
  background: #f5f5f5;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 600; color: #555;
  border: 1px solid #ececec;
  flex-shrink: 0;
}
.brand-logo-lg img { width: 100%; height: 100%; object-fit: contain; }
.detail-title-row h2 { margin: 0; }
/* §110 老板原话：「第一行品牌/车型/车款，下面就应该是哪家店」
   hero 右侧信息流：标题行 → 商家条（可点击跳车源列表） → 车况描述 → 价格 → keyinfo */
.detail-hero-shop {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0 12px;
  padding: 8px 14px;
  border-radius: 6px;
  background: #f5f7fa;
  border: 1px solid #e6eaf0;
  cursor: pointer;
  font-size: 13px;
  color: #1f1f1f;
  align-self: flex-start;
  max-width: 100%;
  transition: background .15s ease;
}
.detail-hero-shop:hover { background: #eaf0f8; }
.detail-hero-shop__label { color: #64748b; font-size: 11px; flex-shrink: 0; letter-spacing: .5px; }
.detail-hero-shop__name { font-weight: 600; max-width: 380px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail-hero-shop__sep, .detail-hero-shop__city { color: #94a3b8; font-size: 12px; flex-shrink: 0; }
.detail-hero-shop__cta { margin-left: auto; color: #2563eb; font-size: 12px; flex-shrink: 0; }
/* 2026-10-14 §48: 详情页右上「车况描述」卡片（紧跟标题，下方价格+keyinfo 之前）
   上限高度 + 滚动，防止 hero 卡被长 desc 撑高失衡 */
.detail-desc {
  margin: 12px 0 4px;
  padding: 10px 14px;
  background: #fafbfc;
  border: 1px solid #eef0f3;
  border-radius: 6px;
  max-height: 240px;
  overflow-y: auto;
}
.detail-desc-label {
  font-size: 11px;
  color: #909399;
  font-weight: 600;
  letter-spacing: .5px;
  margin-bottom: 6px;
}
.detail-desc-body {
  white-space: pre-wrap;
  color: #475569;
  line-height: 1.7;
  font-size: 12px;
  word-break: break-word;
}
.detail-price { font-size: 30px; font-weight: 700; color: var(--red); letter-spacing: -.5px; }
/* 2026-10-13: 「最新拉取」跟价格同一行 baseline 对齐，横排在右侧 */
.detail-price-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}
.detail-pull-time {
  font-size: 13px;
  color: var(--muted);
}
.detail-pull-time i {
  font-style: normal;
  color: #94a3b8;
  margin-right: 4px;
}
/* 关键参数：行内平铺，纯文字 + | 分隔，无 chip 底色 */
.detail-keyinfo { margin-top: 12px; color: #475569; font-size: 13px; line-height: 1.7; }
.detail-keyinfo .sep { color: #d4dae3; margin: 0 8px; }
.detail-keyinfo .status-on { color: var(--green); font-weight: 500; }
.detail-keyinfo .status-off { color: var(--red); font-weight: 500; }

/* 2026-10-13: hero 底下加「什么时候拉取」「最近变化」显眼行，老板一打开详情立刻能看到 */
.detail-time-trace {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: #475569;
  line-height: 1.5;
}
.detail-time-trace > span { display: flex; gap: 10px; align-items: baseline; }
.detail-time-trace i {
  font-style: normal;
  color: #94a3b8;
  min-width: 70px;
  flex-shrink: 0;
  text-align: right;
}
.detail-time-trace b {
  font-weight: 600;
  color: var(--text);
}
.detail-time-trace .chg-down b { color: var(--green); }
.detail-time-trace .chg-up   b { color: var(--red); }
/* 亮点配置：单层 chips，不加框、不加灰底；用 flex:1 撑满右侧剩余空间 */
.detail-hero-config { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.detail-hero-config .config-chips-wrap { max-height: 100%; overflow-y: auto; }
.detail-hero-config .config-chips-wrap::-webkit-scrollbar { width: 6px; }
.detail-hero-config .config-chips-wrap::-webkit-scrollbar-thumb { background: #d4dae3; border-radius: 3px; }
@media (max-width: 900px) { .detail-hero-main { flex-direction: column; } .detail-img { width: 100%; max-width: 100%; } }

.src-flag {
  display: inline-block; align-self: flex-start; padding: 3px 12px; border-radius: 6px;
  font-size: 13px; font-weight: 600; color: #fff;
}
.src-flag.sc { background: var(--accent); }
.src-flag.cb { background: #7c3aed; }
.src-flag.sm { font-size: 11px; padding: 1px 8px; }

.qr-area { display: flex; gap: 18px; align-items: center; }
.qr-box {
  width: 150px; height: 150px; flex-shrink: 0; border: 2px dashed #c3ccd9; border-radius: 12px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  color: #94a3b8; font-size: 12px; background: repeating-linear-gradient(45deg, #fafbfd, #fafbfd 8px, #f3f6fa 8px, #f3f6fa 16px);
}
.qr-box .qr-icon { font-size: 34px; color: #b6c0cf; }
.qr-desc { font-size: 13px; color: #475569; line-height: 1.7; }
@media (max-width: 700px) { .qr-area { flex-direction: column; align-items: flex-start; } }

/* 详情页底部扫码看车：inline 横向一行，不再独占一卡 */
.qr-inline {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px;
  border-top: 1px solid var(--line);
  font-size: 12px; color: var(--muted);
}
.qr-inline .qr-placeholder {
  width: 40px; height: 40px; flex-shrink: 0; border: 1.5px dashed #c3ccd9; border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center; font-size: 10px; color: #94a3b8;
  background: repeating-linear-gradient(45deg, #fafbfd, #fafbfd 4px, #f3f6fa 4px, #f3f6fa 8px);
}
.qr-inline .qr-text { line-height: 1.5; }
.qr-inline .qr-text b { color: var(--text); font-weight: 500; }

/* ---------- 详情页图片：方图平铺，最多 3 行，超出上下滑动（2026-10-13 老板要求） ---------- */
.pic-grid-wrap {
  max-height: 540px;          /* 3 行方图：160*3 + 8*2 + 12 ≈ 508，最多 3 行可见 */
  overflow-y: auto;
  padding: 2px;
  border-radius: 10px;
}
.pic-grid-wrap::-webkit-scrollbar { width: 8px; }
.pic-grid-wrap::-webkit-scrollbar-thumb { background: #c3ccd9; border-radius: 4px; }
.pic-grid-wrap::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 4px; }
.pic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
}
.pic-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;        /* 强制方图，禁止长条 */
  object-fit: cover;
  border-radius: 8px;
  cursor: zoom-in;
  background: #eef1f6;
  display: block;
  transition: transform .15s;
}
.pic-grid img:hover { transform: scale(1.02); }

.lightbox {
  position: fixed; inset: 0; background: rgba(8, 12, 20, .95); z-index: 300;
  display: none; align-items: center; justify-content: center;
}
.lightbox.show { display: flex; }
.lightbox img {
  max-width: 94vw; max-height: 90vh; object-fit: contain; display: block;
  user-select: none; -webkit-user-drag: none;
}
.lb-close {
  position: absolute; top: 18px; right: 26px; width: 42px; height: 42px;
  border: none; border-radius: 50%; background: rgba(255,255,255,.14); color: #fff;
  font-size: 26px; line-height: 1; cursor: pointer;
}
.lb-close:hover { background: rgba(255,255,255,.28); }
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 52px; height: 76px; border: none; cursor: pointer;
  background: rgba(255,255,255,.10); color: #fff;
}
.lb-nav:hover { background: rgba(255,255,255,.22); }
.lb-prev { left: 0; border-radius: 0 10px 10px 0; }
.lb-next { right: 0; border-radius: 10px 0 0 10px; }
.lb-prev::before, .lb-next::before {
  content: ""; display: block; width: 14px; height: 14px; margin: auto;
  border-top: 3px solid #fff; border-right: 3px solid #fff;
}
.lb-prev::before { transform: rotate(225deg); margin-left: 20px; }
.lb-next::before { transform: rotate(45deg); margin-right: 20px; }
.lb-counter {
  position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%);
  color: #cbd5e1; font-size: 13px; background: rgba(255,255,255,.1);
  padding: 4px 14px; border-radius: 12px;
}
/* chips 由 JS packChipsInto 预算每行后分块渲染，每行强制单行不要让浏览器再分 row */
.config-chips { display: block; }
.config-chips .chip-row {
  display: block;
  white-space: nowrap;      /* 保证算法预设的每行就一行 */
  overflow: hidden;         /* 万一算法漏了，行内截断不溢出容器 */
  text-overflow: ellipsis;
}
.config-chips .chip-row + .chip-row { margin-top: 6px; }
.config-chips .tag {
  font-size: 12px; padding: 4px 10px; min-height: 22px;
  display: inline-flex; align-items: center;
  white-space: nowrap; max-width: 100%;
  margin-right: 6px;
  vertical-align: middle;
}
.config-chips .tag:last-child { margin-right: 0; }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(15,23,42,.5); display: none;
  align-items: flex-start; justify-content: center; z-index: 100; padding: 40px 16px; overflow-y: auto;
}
.modal-mask.show { display: flex; }
.modal {
  background: #fff; border-radius: 14px; width: 720px; max-width: 100%;
  box-shadow: 0 20px 60px rgba(15,23,42,.3); overflow: hidden;
}
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 16px; }
.modal-close { border: none; background: none; font-size: 20px; color: var(--muted); cursor: pointer; line-height: 1; }
.modal-body { padding: 20px; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 24px; }
.detail-item .k { font-size: 11px; color: var(--muted); margin-bottom: 3px; }
.detail-item .v { font-size: 14px; }

/* 去 AI 味重构：详情页下半部分用 section + border 分隔，零嵌套 card
   唯一保留的 card = 上方 hero (主图必须装在卡) + 横滑图片区 (多图必须装在卡) */
.sec {
  margin-top: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}
.sec:last-of-type { border-bottom: none; padding-bottom: 8px; }
.sec-title {
  margin: 0 0 14px;
  font-size: 16px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.sec-sub {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
}
.kv-grid { display: grid; gap: 10px 24px; align-items: start; }
.kv-grid-wide   { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.kv-grid-narrow { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
/* k/v 在 .detail-item 里：原来是 grid item 单 cell，新机制下 .kv-grid 自己就是 grid，
   每 cell 是 .detail-item */
.kv-grid .detail-item { min-width: 0; }

.loading { text-align: center; padding: 60px 0; color: var(--muted); }
.spin {
  display: inline-block; width: 26px; height: 26px; border: 3px solid #e2e8f0;
  border-top-color: var(--accent); border-radius: 50%; animation: rot .8s linear infinite; margin-bottom: 10px;
}
@keyframes rot { to { transform: rotate(360deg); } }

.toast {
  position: fixed; top: 20px; left: 50%; transform: translateX(-50%);
  background: #1f2937; color: #fff; padding: 10px 20px; border-radius: 8px; font-size: 13px;
  z-index: 200; opacity: 0; transition: opacity .25s; pointer-events: none;
}
.toast.show { opacity: .95; }

/* ---------- 商家详情：变更面板 ---------- */
.changes-panel {
  margin-top: 12px;
  padding: 10px 12px;
  border-top: 1px solid #f1f5f9;
  background: #fafbfc;
  border-radius: 0 0 6px 6px;
}
.changes-panel[hidden] { display: none; }
.chg-run + .chg-run { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #e5e7eb; }
.chg-run-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; margin-bottom: 6px;
}
.chg-run-head .tag { font-size: 10px; padding: 1px 6px; }
.chg-group { margin-bottom: 8px; }
.chg-title {
  font-size: 12px; font-weight: 600; color: #475569;
  margin: 4px 0 4px;
}
.chg-row {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; padding: 4px 0;
  border-bottom: 1px dotted #eef2f7;
}
.chg-row:last-child { border-bottom: none; }
.chg-row .chg-car {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  margin-right: 8px;
}
.chg-row.new .chg-car { color: #0f766e; }
.chg-row.new span b, .chg-row.drop span b { color: #b91c1c; }
.chg-row.rise span b { color: #b45309; }
.chg-row.off .chg-car { color: #6b7280; text-decoration: line-through; }
.chg-row.off span { color: #9ca3af; }
.chg-row.drop .chg-car { color: #b91c1c; }

/* ---------- 商家变更明细弹窗 ---------- */
.chg-modal {
  position: fixed; inset: 0; z-index: 250;
  display: flex; align-items: center; justify-content: center;
}
.chg-modal[hidden] { display: none; }
.chg-modal-mask {
  position: absolute; inset: 0;
  background: rgba(8, 12, 20, .55);
  backdrop-filter: blur(2px);
}
.chg-modal-box {
  position: relative;
  width: min(960px, calc(100vw - 32px));
  max-height: calc(100vh - 64px);
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .25);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.chg-modal-head {
  display: flex; align-items: center; gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid #e8e8e8;
  background: #fafbfc;
}
.chg-modal-title { font-size: 16px; font-weight: 600; }
.chg-modal-sub { font-size: 12px; margin-top: 2px; }
.chg-modal-body {
  flex: 1; min-height: 0;
  padding: 18px 24px;
  overflow-y: auto;
}
.chg-modal-stats {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding-bottom: 14px; margin-bottom: 14px;
  border-bottom: 1px solid #f1f5f9;
}
.chg-modal-stats .tag { font-size: 12px; padding: 3px 10px; }
.chg-modal-stats .tag.tag-green { background: #d1fae5; color: #065f46; }
.chg-modal-stats .tag.tag-red { background: #fee2e2; color: #b91c1c; }
.chg-modal-stats .tag.tag-orange { background: #fed7aa; color: #c2410c; }
.chg-modal-stats .tag.tag-gray { background: #e5e7eb; color: #4b5563; }
.chg-run {
  border: 1px solid #f1f5f9; border-radius: 8px;
  background: #fff;
  margin-bottom: 10px;
  overflow: hidden;
}
.chg-run-head {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  background: #fafbfc;
  font-size: 13px;
}
.chg-run-time { font-weight: 500; color: #1f2937; }
.chg-toggle { margin-left: 10px; }
.chg-run-body { padding: 8px 16px 14px; }
.chg-run-body[hidden] { display: none; }
.chg-empty { padding: 12px 0; font-size: 12px; }

.chg-group { margin-top: 10px; }
.chg-group:first-child { margin-top: 0; }
.chg-group-title {
  font-size: 13px; font-weight: 600; color: #475569;
  padding: 6px 0;
  border-bottom: 1px dotted #e5e7eb;
  margin-bottom: 4px;
}
.chg-item {
  display: flex; align-items: center; gap: 14px;
  padding: 8px 0;
  font-size: 13px;
  border-bottom: 1px dotted #f1f5f9;
}
.chg-item:last-child { border-bottom: none; }
.chg-item .chg-car {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: #1f2937;
}
.chg-item .chg-price {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.chg-item .chg-price.chg-down { color: #b91c1c; font-weight: 500; }
.chg-item .chg-price.chg-up { color: #c2410c; font-weight: 500; }
.chg-item.new .chg-car { color: #0f766e; }
.chg-item.off .chg-car { color: #9ca3af; text-decoration: line-through; }
.chg-item.off .chg-price { color: #9ca3af; }
.chg-time { font-size: 12px; min-width: 36px; text-align: right; }

/* ---------- 详情页「比价 N 台」徽章 ---------- */
.compare-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 12px;
  color: #6b7280;
  background: #f1f5f9;
  cursor: default;
}
.compare-badge.compare-active {
  color: #0c4a6e;
  background: #e0f2fe;
  cursor: pointer;
  font-weight: 500;
}
.compare-badge.compare-active:hover { background: #bae6fd; }
.compare-badge.compare-empty { color: #9ca3af; }

/* ---------- 同款比价视图 ---------- */
.pc-head { padding: 20px 24px; }
.pc-title { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.pc-meta {
  display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
  margin-bottom: 10px;
}
.pc-meta .tag { font-size: 12px; padding: 2px 10px; background: #f1f5f9; color: #475569; }
.pc-hint { font-size: 12px; }

.pc-list { margin-top: 16px; background: #fff; border: 1px solid #e8e8e8; border-radius: 6px; overflow: hidden; }
.pc-row {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 18px;
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
  transition: background .12s;
}
.pc-row:last-child { border-bottom: none; }
.pc-row:hover { background: #fafbfc; }
.pc-row.current {
  background: #eff6ff;
  border-left: 3px solid #2563eb;
  padding-left: 15px;
}
.pc-img {
  width: 96px; height: 64px; border-radius: 6px; overflow: hidden;
  background: #eef1f6; flex-shrink: 0;
}
.pc-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-info { flex: 1; min-width: 0; }
.pc-line1 { font-size: 18px; }
.pc-line1 b { font-size: 20px; color: #b91c1c; margin-right: 8px; }
.pc-line1 .tag { font-size: 11px; padding: 1px 8px; vertical-align: middle; }
.pc-line2, .pc-line3 { font-size: 12px; margin-top: 4px; }
.pc-line2 .sep, .pc-line3 .sep { color: #d1d5db; margin: 0 6px; }
.pc-rank {
  font-size: 13px; color: #94a3b8; flex-shrink: 0; min-width: 32px;
  text-align: right; font-variant-numeric: tabular-nums;
}

/* ---------- 同款比价弹窗：按店铺分组（2026-10-13 老板要求展示「家/车/公里/价」） ---------- */
.compare-shop-groups { display: flex; flex-direction: column; gap: 20px; }
.compare-shop-group {}
.compare-shop-name {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 8px 0; padding: 0 0 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px; font-weight: 600; color: #1f1f1f;
}
.compare-shop-rank {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  background: #2563eb; color: #fff;
  border-radius: 50%;
  font-size: 12px; font-weight: 600;
}
.compare-shop-num { margin-left: auto; font-weight: normal; font-size: 12px; }
.compare-shop-group .pc-list { margin-top: 0; }
.brands-two-col {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 16px;
  height: calc(100vh - 200px);
  min-height: 600px;
}
/* 3 列 master-detail（2026-10-13 §45 老板需求：品牌 → 车系 → 细分款） */
.brands-three-col {
  display: grid;
  grid-template-columns: 320px 320px 1fr;
  gap: 16px;
  height: calc(100vh - 200px);
  min-height: 600px;
}

/* 5 列 master-detail — 同款比价 (§113 老板 2026-10-16 改造; §114 布局重写)
 *  列 1 品牌 / 列 2 车系 / 列 3 型号 / 列 4 年款 / 列 5 车辆
 *  §114: 顶部大卡 head 砍掉换成一行面包屑 → 5 列高度吃回 calc(100vh - 170px)
 */
.pc-crumb {
  font-size: 13px;
  color: #6b7280;
  padding: 2px 4px 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pc-crumb b { color: #1f1f1f; font-weight: 600; }
.pc-crumb .pc-crumb-cur { color: #9ca3af; margin-left: 10px; font-size: 12px; }
.brands-five-col {
  display: grid;
  /* §115: 前三列 minmax 弹性（小屏收缩到 130/150/200，大屏撑到 200/220/320），年款窄固定，车辆列吃剩余 */
  grid-template-columns: minmax(130px, 1fr) minmax(150px, 1.1fr) minmax(200px, 1.6fr) 110px minmax(260px, 2.4fr);
  gap: 10px;
  height: calc(100vh - 170px);
  min-height: 560px;
}
/* 列 5 车辆列：专属紧凑行（§114，不再复用老 pc-row 大图行） */
.brands-col-cars .col-body {
  overflow-y: auto;
  padding: 0;
}
.pc-mini-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-bottom: 1px solid #f3f4f6;
  cursor: pointer;
  transition: background .12s;
}
.pc-mini-row:hover { background: #f9fafb; }
.pc-mini-row.current { background: #eff6ff; box-shadow: inset 2px 0 0 #2563eb; }
.pc-mini-img {
  width: 64px; height: 48px;
  border-radius: 4px; overflow: hidden;
  background: #eef1f6; flex-shrink: 0;
}
.pc-mini-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-mini-main { flex: 1; min-width: 0; }
.pc-mini-price { font-size: 15px; color: #b91c1c; font-weight: 700; line-height: 1.2; }
.pc-mini-price .u { font-size: 11px; font-weight: 400; color: #b91c1c; margin-left: 1px; }
.pc-mini-tag {
  display: inline-block; font-size: 10px; font-weight: 400;
  color: #2563eb; border: 1px solid #bfdbfe; border-radius: 3px;
  padding: 0 4px; margin-left: 6px; vertical-align: 1px;
}
.pc-mini-tag.off { color: #9ca3af; border-color: #e5e7eb; }
.pc-mini-meta, .pc-mini-shop {
  font-size: 11px; color: #9ca3af;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  margin-top: 2px;
}
.pc-cars-list { background: transparent; border: none; }
.brands-five-col .model-row {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 14px;
}
.brands-five-col .model-row .model-name {
  font-size: 13px;
  font-weight: 500;
  color: #1f1f1f;
  width: 100%;
}
.brands-five-col .model-row .model-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: #909399;
  width: 100%;
}
.brands-five-col .model-row .model-meta .price {
  color: #d44a4a;
  font-weight: 500;
}
.brands-three-col .row-logo-sm {
  width: 36px; height: 36px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #f5f5f5;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; color: #555;
  border: 1px solid #ececec;
}
.brands-three-col .row-logo-sm img { width: 100%; height: 100%; object-fit: cover; }
.brands-three-col .model-row {
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 14px;
}
.brands-three-col .model-row .model-name {
  font-size: 13px;
  font-weight: 500;
  color: #1f1f1f;
  width: 100%;
}
.brands-three-col .model-row .model-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: #909399;
  width: 100%;
}
.brands-three-col .model-row .model-meta .price {
  color: #d44a4a;
  font-weight: 500;
}
.brands-col {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.brands-col .col-head {
  padding: 12px 18px;
  border-bottom: 1px solid #f0f0f0;
  font-weight: 600;
  font-size: 14px;
  color: #1f1f1f;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.brands-col .col-head-sub {
  margin-left: auto;
  font-size: 12px;
  font-weight: 400;
}
.brands-col .col-body {
  flex: 1;
  overflow-y: auto;
  padding: 6px;
}
.list-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.12s;
}
.list-row:hover { background: #f5f7fa; }
.list-row.active {
  background: #eff6ff;
  border-left: 3px solid #2563eb;
  padding-left: 9px;
}
/* §115: 5 列比价视图的 facets 专用行——纯文字、单行省略、右侧数量。
 * 窄列（<200px）绝不再塞 36px logo 方块 + 双行文案（老板骂"第二列啥了"的真凶） */
.pc-facet-row {
  gap: 8px;
  padding: 7px 10px;
  display: flex;
  align-items: center;
}
.pc-facet-row .row-main { flex: 1; min-width: 0; }
.pc-facet-row .row-name {
  font-size: 13px;
  color: #1f1f1f;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pc-facet-row .row-count {
  font-size: 11px;
  color: #9ca3af;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}
.pc-facet-row.active .row-name { color: #1d4ed8; font-weight: 600; }
.list-row .row-logo {
  width: 36px; height: 36px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: #555;
  font-weight: 600;
  border: 1px solid #ececec;
}
.list-row .row-logo img {
  width: 100%; height: 100%; object-fit: contain;
}
.list-row .row-main { flex: 1; min-width: 0; }
.list-row .row-name {
  font-size: 14px;
  font-weight: 500;
  color: #1f1f1f;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.list-row .row-count {
  font-size: 12px;
  color: #888;
  margin-top: 2px;
}
.list-row .row-arrow {
  font-size: 16px;
  color: #ccc;
  flex-shrink: 0;
}

.empty-hint {
  padding: 80px 24px;
  text-align: center;
  color: #888;
  font-size: 14px;
}
.empty-hint .lh-arrow {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.35;
  color: #2d6cdf;
  line-height: 1;
}

/* ---------- 同款比价总览（2026-10-13） ---------- */
.uc-row-img {
  width: 64px; height: 44px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #f5f5f5;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; color: #555; font-weight: 600;
  border: 1px solid #ececec;
}
.uc-row-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.uc-row-sub { font-size: 11px; margin-top: 1px; }
.uc-row-meta {
  display: flex; align-items: center; gap: 8px;
  margin-top: 4px;
  font-size: 11px;
}
.uc-row-meta .tag { font-size: 10px; padding: 1px 6px; }
.uc-row-meta .uc-pricerange { font-size: 11px; }

.uc-title {
  font-size: 15px;
  font-weight: 600;
  color: #1f1f1f;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 60%;
}
.uc-sub {
  font-size: 11px;
  margin-top: 2px;
}

.uc-car-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  cursor: pointer;
  border-bottom: 1px solid #f1f5f9;
  transition: background 0.12s;
}
.uc-car-row:last-child { border-bottom: none; }
.uc-car-row:hover { background: #fafbfc; }
.uc-car-img {
  width: 96px; height: 64px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #f5f5f5;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: #555; font-weight: 600;
  border: 1px solid #ececec;
}
.uc-car-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.uc-car-main { flex: 1; min-width: 0; }
.uc-car-shop {
  font-size: 13px;
  color: #1f1f1f;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.uc-car-meta { font-size: 11px; margin-top: 2px; }
.uc-car-price {
  font-size: 16px;
  color: #b91c1c;
  font-weight: 600;
  flex-shrink: 0;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ---------- 同款比价 v2（2026-10-13 §39 老板要求：筛选条 + 多信息 + 店名图顶对齐） ---------- */
.uc-page { display: flex; flex-direction: column; gap: 12px; }

.uc-filters {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 16px;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 6px;
  flex-wrap: wrap;
}
.uc-filters-label { font-size: 13px; flex-shrink: 0; }
.uc-filter {
  height: 30px; padding: 4px 10px;
  border: 1px solid #d4d4d4; border-radius: 4px;
  background: #fff; font-size: 13px; color: #1f1f1f;
  cursor: pointer; min-width: 120px;
  transition: border-color .12s;
}
.uc-filter:hover { border-color: #2563eb; }
.uc-filter:focus { outline: none; border-color: #2563eb; }
.uc-filter:disabled { background: #f5f5f5; color: #999; cursor: not-allowed; }
.uc-filter-reset {
  height: 30px; padding: 4px 14px;
  background: #fff; border: 1px solid #d4d4d4; border-radius: 4px;
  font-size: 13px; color: #475569; cursor: pointer;
}
.uc-filter-reset:hover { background: #f1f5f9; border-color: #94a3b8; }
.uc-filters-result { font-size: 12px; margin-left: auto; }

/* 右列每行重设计：3 行信息 + 店名与图片顶部对齐（修复老板反馈的对齐问题） */
.uc-car-row {
  /* v2 重设：align-items flex-start 让 main 跟 img 顶对齐 */
  align-items: flex-start;
  padding: 12px 14px;
}
.uc-car-row .uc-car-price {
  align-self: center;  /* 价格仍与图片中线对齐 */
}
.uc-car-line1 {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px;
  flex-wrap: wrap;
}
.uc-car-shop { font-weight: 600; color: #1f1f1f; }
.uc-car-city { font-size: 12px; }
.uc-car-sep { color: #d1d5db; margin: 0 4px; font-size: 11px; }
.uc-car-line2 {
  font-size: 12px;
  margin-top: 4px;
}
.uc-car-line3 {
  font-size: 11px;
  margin-top: 2px;
}
.uc-car-price-unit { font-size: 12px; margin-left: 2px; }

/* 标签色块 */
.uc-tag {
  display: inline-block;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 8px;
  font-weight: 500;
  margin-left: 4px;
}
.uc-tag-on { background: #d1fae5; color: #065f46; }
.uc-tag-off { background: #e5e7eb; color: #6b7280; }
.uc-tag-video { background: #ddd6fe; color: #5b21b6; }

.uc-pricerange {
  font-size: 11px;
  color: #888;
  padding: 8px 14px;
  background: #fafbfc;
  border-bottom: 1px solid #f1f5f9;
}

/* ---------- 同步日志列表（2026-10-13 §44） ---------- */
.log-list { display: flex; flex-direction: column; }
.log-row {
  padding: 12px 0;
  border-bottom: 1px solid var(--border, #ececec);
}
.log-row:last-child { border-bottom: none; }
.log-row-head {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.log-row-head .log-shop {
  font-size: 13px; font-weight: 600; color: var(--text, #303133);
}
.log-row-head .log-src { font-size: 11px; }
.log-row-head .log-time { font-size: 11px; margin-left: auto; }
.log-row-head .log-dur { font-size: 11px; }
.log-row.fail .log-shop { color: #c45656; }
.log-row-body {
  display: flex; align-items: center; gap: 18px; margin-top: 8px; font-size: 12px;
}
.log-row-body .log-num { display: inline-flex; align-items: baseline; gap: 4px; }
.log-row-body .log-num b { font-size: 15px; font-weight: 600; color: var(--text, #303133); }
.log-row-body .log-num i { font-style: normal; color: var(--muted, #909399); font-size: 11px; }
.log-row-msg { margin-top: 6px; font-size: 11px; line-height: 1.5; }


/* ---------- admin 鉴权（2026-10-14 §49） ---------- */
.admin-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 0 10px;
  font-size: 12px;
  color: #555;
}
.admin-name { font-weight: 600; color: #1f2937; }
.admin-role {
  padding: 2px 6px; border-radius: 3px; font-size: 11px;
  background: #f1f5f9; color: #475569;
}
.admin-role.role-super_admin { background: #fef2f2; color: #b91c1c; }
.admin-role.role-shop_admin { background: #eff4ff; color: #1d4ed8; }
.admin-role.role-readonly { background: #f1f5f9; color: #475569; }

/* ---------- 用户管理 + 审计日志（super_admin） ---------- */
.user-list, .audit-list { display: flex; flex-direction: column; }
.user-row, .audit-row {
  display: grid;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 13px;
  gap: 12px;
}
.user-row-head, .audit-row-head {
  font-size: 12px;
  color: #888;
  background: #fafbfc;
  font-weight: 600;
}
.user-row {
  grid-template-columns: 50px 180px 80px 60px 140px 100px 1fr;
}
.audit-row {
  grid-template-columns: 150px 60px 140px 120px 1fr 100px;
}
.audit-detail { font-size: 11px; word-break: break-all; }
.user-row-actions { display: flex; gap: 6px; }
.user-row-actions .btn-sm { font-size: 11px; padding: 3px 8px; }

/* tag 变体（用户管理用） */
.tag.tag-blue { background: #eff4ff; color: #1d4ed8; }
.tag.tag-gray { background: #f1f5f9; color: #64748b; }
.tag.tag-red { background: #fef2f2; color: #b91c1c; }
.tag.tag-green { background: #ecfdf5; color: #047857; }
