  /* 商品上架页：页面级样式，保留内联但去除重复补丁层 */
  body.page-scrape {
    --scrape-bg: #f6f7fb;
    --scrape-card: #fff;
    --scrape-card-soft: #f7f8fc;
    --scrape-line: #e3e7ef;
    --scrape-line-soft: #edf0f5;
    --scrape-ink: #111827;
    --scrape-text: #172033;
    --scrape-muted: #64748b;
    --scrape-label: #475569;
    --scrape-faint: #94a3b8;
    --scrape-blue: #1677ff;
    --scrape-blue-dark: #0f5ed7;
    --scrape-red: #ef4444;
    --scrape-green: #16a34a;
    --scrape-warn: #f59e0b;
    --scrape-input-border: #dbe1ea;
    --scrape-radius: 12px;
    --scrape-radius-sm: 8px;
    --scrape-radius-lg: 16px;
    --scrape-radius-xl: 20px;
    --scrape-radius-pill: 999px;
    --scrape-space-xs: 4px;
    --scrape-space-sm: 8px;
    --scrape-space-md: 12px;
    --scrape-space-lg: 16px;
    --scrape-space-xl: 20px;
    --scrape-space-2xl: 24px;
    --scrape-shadow: 0 1px 3px rgba(15, 23, 42, .04);
    background: var(--scrape-bg) !important;
    color: var(--scrape-text);
    font-size: 13px;
    line-height: 1.45;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: geometricPrecision;
  }

  body.page-scrape * { box-sizing: border-box; }
  body.page-scrape .hidden { display: none !important; }
  /* 通用控件 */
  body.page-scrape .btn,
  body.page-scrape .wb-btn,
  body.page-scrape .action-btn,
  body.page-scrape .page-btn {
    height: 32px;
    min-height: 32px;
    border: 1px solid var(--scrape-line);
    border-radius: 9px;
    background: #fff;
    color: var(--scrape-text);
    padding: 0 12px;
    font-size: 13px;
    font-weight: 650;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    box-shadow: none;
    white-space: nowrap;
    transition: background .16s, border-color .16s, color .16s, transform .16s;
  }
  body.page-scrape .btn:hover,
  body.page-scrape .wb-btn:hover,
  body.page-scrape .action-btn:hover,
  body.page-scrape .page-btn:hover { background: #f8fafc; border-color: #cbd5e1; }
  body.page-scrape .btn-primary,
  body.page-scrape .wb-btn-primary,
  body.page-scrape .action-btn.is-primary { background: var(--scrape-blue); border-color: var(--scrape-blue); color: #fff; }
  body.page-scrape .btn-primary:hover,
  body.page-scrape .wb-btn-primary:hover,
  body.page-scrape .action-btn.is-primary:hover { background: var(--scrape-blue-dark); border-color: var(--scrape-blue-dark); }
  body.page-scrape .wb-btn-danger,
  body.page-scrape .btn-danger,
  body.page-scrape .action-btn.is-danger { background: #fff5f5; border-color: #fecaca; color: var(--scrape-red); }
  body.page-scrape .btn-ghost { background: #fff; color: #334155; }

  body.page-scrape input,
  body.page-scrape select,
  body.page-scrape textarea,
  body.page-scrape .input {
    border: 1px solid var(--scrape-line);
    border-radius: 9px;
    background: #fff;
    color: var(--scrape-text);
    font-size: 13px;
    outline: none;
    transition: border-color .16s, box-shadow .16s;
  }
  body.page-scrape input,
  body.page-scrape select,
  body.page-scrape .input { height: 34px; padding: 0 11px; }
  body.page-scrape textarea.input { height: auto; min-height: 96px; padding: 10px 11px; line-height: 1.5; }
  body.page-scrape input:focus-visible,
  body.page-scrape select:focus-visible,
  body.page-scrape textarea:focus-visible,
  body.page-scrape .input:focus-visible { border-color: var(--scrape-blue); box-shadow: 0 0 0 3px rgba(22,119,255,.10); }
  body.page-scrape label { color: #334155; font-size: 12px; font-weight: 700; }

  /* 顶部操作区 & 筛选区 */
  body.page-scrape .erp-toolbar { background: transparent !important; border: 0 !important; box-shadow: none !important; padding: 0 !important; margin: 0 0 14px !important; }

  /* 筛选区与状态 */
  body.page-scrape .erp-row-bottom { display: block !important; padding: 0 !important; margin: 0 !important; background: transparent !important; border: 0 !important; box-shadow: none !important; }
  body.page-scrape .filter-shell {
    width: 100% !important;
    margin: 0 !important;
    padding: 16px 18px !important;
    background: var(--scrape-card) !important;
    border: 1px solid var(--scrape-line) !important;
    border-radius: 14px !important;
    box-shadow: var(--scrape-shadow) !important;
  }
  /* ⚠️ 2026-10-20：每列第一个参数是「最小宽度」，原来是 360/150/150/160/160/170/220 = 1370px，
     加上 filter-shell 的左右 padding(36px) 和 6 个列间距(84px) = 1490px。
     1440px 视口下容器只有 1404px ⇒ 整行撑出 72px，右侧「重置」和「采集日期」跑到屏幕外。
     （1280px 反而正常，因为它命中了下面的 4 列断点，8 列只在 1400px 以上才生效 —— 这类
      「大屏才溢出」的问题在窄屏测试里根本发现不了。）
     修法：把下限压到 0/极小值，让 fr 真正起作用；列宽比例不变，宽屏观感一致。 */
  body.page-scrape .filter-grid.filter-grid-one-line {
    display: grid !important;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, .58fr) minmax(0, .58fr) minmax(0, .62fr) minmax(0, .62fr) minmax(0, .65fr) minmax(0, .75fr);
    grid-template-areas:
      "search platform moq store group biz price"
      "sales sales date date . . .";
    gap: 12px 14px !important;
    align-items: end !important;
    min-width: 0;
  }
  body.page-scrape .filter-block { min-width: 0; }
  body.page-scrape .filter-block-search { grid-area: search; }
  body.page-scrape .filter-block-platform { grid-area: platform; }
  body.page-scrape .filter-block-moq { grid-area: moq; }
  body.page-scrape .filter-block-store { grid-area: store; }
  body.page-scrape .filter-block-group { grid-area: group; }
  body.page-scrape .filter-block-collector { grid-area: collector; }
  body.page-scrape .filter-block-biz { grid-area: biz; }
  body.page-scrape .filter-block-price { grid-area: price; }
  body.page-scrape .filter-block-sales { grid-area: sales; }
  body.page-scrape .filter-block-date { grid-area: date; }
  body.page-scrape .store-filter-combobox { position: relative; min-width: 0; }
  body.page-scrape .store-filter-combobox input { padding-right: 34px !important; }
  body.page-scrape .store-filter-toggle {
    position: absolute;
    top: 0;
    right: 0;
    width: 34px;
    height: 100%;
    border: 0;
    background: transparent;
    color: #64748b;
    cursor: pointer;
  }
  body.page-scrape .store-filter-options {
    position: absolute;
    z-index: 80;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    max-height: 240px;
    overflow-y: auto;
    padding: 4px;
    border: 1px solid var(--scrape-line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .14);
  }
  body.page-scrape .store-filter-options[hidden] { display: none !important; }
  body.page-scrape .store-filter-option {
    display: block;
    width: 100%;
    min-height: 32px;
    padding: 7px 9px;
    overflow: hidden;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: #1e293b;
    font-family: inherit;
    font-size: 13px;
    font-weight: 400;
    text-align: left;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
  }
  body.page-scrape .store-filter-option:hover,
  body.page-scrape .store-filter-option.is-active { background: #eff6ff; color: #1d4ed8; }
  body.page-scrape .store-filter-empty { padding: 10px 9px; color: #94a3b8; font-family: inherit; font-size: 13px; font-weight: 400; }
  /* 同上：8 列版最小宽度合计 330+140*4+150+170+210 = 1420px，比 7 列版更容易溢出。
     下限一律压到 0，只保留 fr 比例。 */
  body.page-scrape .filter-grid.filter-grid-one-line.has-collector-filter {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, .52fr) minmax(0, .52fr) minmax(0, .52fr) minmax(0, .52fr) minmax(0, .56fr) minmax(0, .62fr) minmax(0, .72fr);
    grid-template-areas:
      "search group collector platform moq store biz price"
      "sales sales date date . . . .";
    min-width: 0;
  }
  body.page-scrape .filter-block label { display: block; margin: 0 0 6px; color: #334155; font-size: 12px; font-weight: 750; }
  body.page-scrape .filter-search { display: flex; align-items: center; gap: 8px; min-width: 0; }
  body.page-scrape .filter-search-box {
    flex: 1 1 auto;
    min-width: 0;
    height: 34px;
    display: flex;
    align-items: center;
    overflow: hidden;
    border: 1px solid var(--scrape-line);
    border-radius: 9px;
    background: #fff;
  }
  body.page-scrape .filter-search-box .fa,
  body.page-scrape .filter-search-box .fas { display: none !important; }
  body.page-scrape .filter-search-box input {
    width: 100%;
    height: 100%;
    min-width: 0;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 11px !important;
    background: transparent !important;
    line-height: 34px;
  }
  body.page-scrape .filter-range { display: grid; grid-template-columns: minmax(0, 1fr) 12px minmax(0, 1fr); gap: 8px; align-items: center; }
  body.page-scrape .filter-range span { color: var(--scrape-muted); text-align: center; }
  body.page-scrape .filter-range input { width: 100%; min-width: 0; }
  body.page-scrape .filter-status-tabs { margin: 14px 0 0 !important; padding: 0 !important; background: transparent !important; border: 0 !important; box-shadow: none !important; }
  body.page-scrape .tabs-box {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    background: #fff;
    border: 1px solid var(--scrape-line);
    border-radius: var(--scrape-radius-pill);
    box-shadow: 0 1px 3px rgba(15,23,42,.05);
  }
  body.page-scrape .tabs-box .tab {
    height: 28px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0 14px;
    border-radius: var(--scrape-radius-pill);
    color: var(--scrape-muted);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
  }
	  body.page-scrape .tabs-box .tab.active { background: var(--scrape-blue); color: #fff; }
	  body.page-scrape .tabs-box .muted { font-size: 12px; font-weight: 700; color: var(--scrape-label); opacity: 1; }
	  body.page-scrape .tabs-box .tab.active .muted { color: rgba(255,255,255,0.82); }
	  /* 表格 */
  body.page-scrape .table-card {
    margin-top: 18px !important;
    overflow: hidden;
    background: var(--scrape-card);
    border: 1px solid var(--scrape-line);
    border-radius: 14px;
    box-shadow: var(--scrape-shadow);
  }
  body.page-scrape .table-scroll { overflow-x: auto; }
  body.page-scrape .board-table { width: 100%; min-width: 1680px; border-collapse: separate; border-spacing: 0; font-size: 13px; }
  body.page-scrape .board-table th {
    height: 42px;
    padding: 10px 10px;
    background: #f8fafc;
    border-bottom: 1px solid var(--scrape-line);
    color: var(--scrape-label);
    font-size: 12px;
    font-weight: 800;
    text-align: center;
    white-space: nowrap;
  }
  body.page-scrape .board-table td { padding: 12px 10px; border-bottom: 1px solid var(--scrape-line-soft); vertical-align: middle; }
  body.page-scrape .board-table tbody tr:hover td { background: #fbfdff; }
  body.page-scrape .td-center { text-align: center; }
  body.page-scrape .td-left { text-align: left; }
  body.page-scrape .th-check { width: 42px; }
  body.page-scrape .th-img { width: 86px; }
  body.page-scrape .th-info { width: 420px; }
  body.page-scrape .th-sku { width: 140px; }
  body.page-scrape .th-sales { width: 76px; }
  body.page-scrape .th-store { width: 170px; }
  body.page-scrape .th-group { width: 82px; }
  body.page-scrape .th-stock { width: 250px; }
  body.page-scrape .th-price { width: 140px; }
  body.page-scrape .th-status { width: 140px; }
  body.page-scrape .th-time { width: 122px; }
  body.page-scrape .th-action { width: 132px; }
  body.page-scrape .product-thumb {
    width: 64px;
    height: 64px;
    margin: 0 auto;
    border-radius: 10px;
    border: 1px solid var(--scrape-line-soft);
    background: #f8fafc;
    display: grid;
    place-items: center;
    overflow: hidden;
    position: relative;
    color: var(--scrape-faint);
    font-size: 12px;
  }
  body.page-scrape .product-thumb-img,
  body.page-scrape .product-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; background: #fff; }
  body.page-scrape .product-thumb-error { display: none; position: absolute; inset: 0; align-items: center; justify-content: center; padding: 6px; background: #fef2f2; color: #b91c1c; font-size: 11px; text-align: center; }
  body.page-scrape .product-thumb.is-error .product-thumb-img { display: none; }
  body.page-scrape .product-thumb.is-error .product-thumb-error { display: flex; }
  body.page-scrape .product-title {
    max-width: 430px;
    margin-bottom: 6px;
    color: #0f172a;
    font-size: 13px;
    line-height: 1.42;
    font-weight: 800;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  body.page-scrape .product-source { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; color: var(--scrape-muted); font-size: 12px; }
  body.page-scrape .product-source a { color: #2563eb; text-decoration: none; font-weight: 700; }
  body.page-scrape .source-id,
  body.page-scrape .source-min-order-badge,
  body.page-scrape .scraper-badge,
  body.page-scrape .group-empty { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: var(--scrape-radius-pill); background: #f1f5f9; color: var(--scrape-label); font-size: 11px; font-weight: 700; }
  body.page-scrape .source-min-order-badge.is-warning { background: #fffbeb; color: #92400e; }
  body.page-scrape .source-min-order-badge.is-danger { background: #fef2f2; color: #b91c1c; }
  body.page-scrape .sku-attr { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; min-width: 118px; padding: 8px 9px; border-radius: 10px; border: 1px solid #bbf7d0; background: #f0fdf4; vertical-align: middle; }
  body.page-scrape .sku-attr-main { width: 100%; color: #0f172a; font-size: 12px; font-weight: 800; margin-bottom: 3px; text-align: center; }
  body.page-scrape .sku-attr-line,
  body.page-scrape .sku-attr-meta { width: 100%; color: var(--scrape-muted); font-size: 11px; line-height: 1.35; text-align: center; }
  body.page-scrape .sku-attr.is-all-out { background: #fef2f2; border-color: #fecaca; }
  body.page-scrape .sku-attr.is-partial-out { background: #fffbeb; border-color: #fde68a; }
  body.page-scrape .sales-num { color: #0f172a; font-size: 14px; font-weight: 850; }
  body.page-scrape .sales-label,
  body.page-scrape .time-clock,
  body.page-scrape .store-name { max-width: 132px; margin: 0 auto 5px; color: #0f172a; font-weight: 750; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  body.page-scrape .cat-row { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; margin-bottom: 6px; }
  body.page-scrape .cat-name,
  body.page-scrape .cat-missing { max-width: 120px; color: #0f172a; font-size: 12px; font-weight: 750; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  body.page-scrape .cat-missing { color: #d97706; }
  body.page-scrape .cat-meta { display: inline-flex; align-items: center; min-height: 18px; padding: 1px 5px; border-radius: 5px; font-size: 10px; font-weight: 750; white-space: nowrap; }
  body.page-scrape .cat-meta-warning { background: #fff7ed; border: 1px solid #fed7aa; color: #c2410c; }
  body.page-scrape .cat-meta-ai { background: #eef2ff; color: #4338ca; }
  body.page-scrape .cat-meta-manual { background: #ecfdf5; color: #047857; }
  body.page-scrape .cat-meta-pending { background: #f1f5f9; color: #64748b; }
  body.page-scrape .cell-stock-line { display: flex; align-items: center; flex-wrap: wrap; gap: 1px; color: #475569; font-size: 11px; line-height: 1.45; }
  body.page-scrape .cell-sep { color: #cbd5e1; margin: 0 3px; user-select: none; }
  body.page-scrape .dims-sep { margin-left: 5px; }
  body.page-scrape .cell-wh { max-width: 110px; color: #334155; font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  body.page-scrape .cell-no-wh { color: #ef4444; font-weight: 650; }
  body.page-scrape .cell-qty { color: #475569; }
  body.page-scrape .cell-dims { color: #94a3b8; }
  body.page-scrape .price-main { color: #0f172a; font-weight: 850; line-height: 1.35; }
  body.page-scrape .ozon-price-source-lines { margin-top: 3px; color: #64748b; font-size: 11px; line-height: 1.45; }
  body.page-scrape .ozon-price-source-line { display: block; white-space: nowrap; }
  body.page-scrape .ozon-price-amount { white-space: nowrap; }
  body.page-scrape .status-badge { display: inline-flex; align-items: center; min-height: 24px; padding: 3px 10px; border-radius: var(--scrape-radius-pill); font-size: 12px; font-weight: 800; }
  body.page-scrape .status-pending { background: #eaf3ff; color: #1d4ed8; }
  body.page-scrape .status-publishing { background: #fff7ed; color: #c2410c; }
  body.page-scrape .status-failed { background: #fef2f2; color: #b91c1c; }
  body.page-scrape .status-published { background: #ecfdf5; color: #047857; }
  body.page-scrape .status-review-low { background: #fff7ed; color: #9a3412; border-color: #fdba74; }
  body.page-scrape .status-review-violation { background: #fef2f2; color: #991b1b; border-color: #fecaca; }
  body.page-scrape .manual-review-summary { display: grid; gap: 2px; max-width: 190px; margin-top: 5px; color: #64748b; font-size: 11px; line-height: 1.4; overflow-wrap: anywhere; }
  body.page-scrape .manual-review-summary strong { color: #334155; font-weight: 750; }
  body.page-scrape .publish-error-info { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; font-size: 11px; line-height: 1.4; max-width: 160px; }
  body.page-scrape .publish-error-type { display: inline-block; padding: 1px 6px; border-radius: 3px; font-weight: 700; font-size: 10px; white-space: nowrap; width: fit-content; }
  body.page-scrape .publish-error-type.err-type-title { background: #fee2e2; color: #991b1b; }
  body.page-scrape .publish-error-type.err-type-image { background: #fce7f3; color: #9d174d; }
  body.page-scrape .publish-error-type.err-type-attr { background: #fef3c7; color: #92400e; }
  body.page-scrape .publish-error-type.err-type-price { background: #e0e7ff; color: #3730a3; }
  body.page-scrape .publish-error-type.err-type-stock { background: #dbeafe; color: #1e40af; }
  body.page-scrape .publish-error-type.err-type-sku { background: #f3e8ff; color: #6b21a8; }
  body.page-scrape .publish-error-type.err-type-cat { background: #fce7f3; color: #9d174d; }
  body.page-scrape .publish-error-type.err-type-auth { background: #fee2e2; color: #7f1d1d; }
  body.page-scrape .publish-error-type.err-type-rate { background: #fef3c7; color: #854d0e; }
  body.page-scrape .publish-error-type.err-type-net { background: #e0e7ff; color: #3730a3; }
  body.page-scrape .publish-error-type.err-type-api { background: #f1f5f9; color: #475569; }
  body.page-scrape .publish-error-type.err-type-unknown { background: #f1f5f9; color: #64748b; }
  body.page-scrape .publish-error-msg { color: #64748b; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  body.page-scrape .publish-error-action { color: #2563eb; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  /* 「图片待人工处理」提示条：说明这件商品为什么被 Ozon 拒图。
     口径的真源是 ozon-backend/src/services/imageReviewSignal.js，改那里要回来看这条。 */
  body.page-scrape .image-review-strip { display: grid; gap: 2px; margin-top: 5px; padding: 5px 7px; max-width: 190px; border: 1px solid #fbcfe8; border-radius: 6px; background: #fdf2f8; font-size: 11px; line-height: 1.4; }
  body.page-scrape .image-review-strip-title { color: #9d174d; font-weight: 800; }
  body.page-scrape .image-review-strip-signal { color: #9d174d; opacity: .85; overflow-wrap: anywhere; }
  body.page-scrape .image-review-strip-message { color: #64748b; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
  /* 下面的中文提示来自后端静态俄→中词表（ozon-backend/src/services/ozonMessageGlossary.js）：
     俄文原文照旧保留在上面（证据不能丢），中文只是并排的「这句话在说什么」。
     词表没命中时后端返回空串，这一行根本不会渲染。 */
  body.page-scrape .image-review-strip-message-zh { color: #334155; font-weight: 600; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
  /* 「失败归因」提示条：告诉运营这件失败商品该去改哪里（标题/描述/图片），
     以及「仅看标题/描述类」筛选项筛的是同一份口径。
     口径真源是 ozon-backend/src/services/failureAttributionSignal.js，改那里要回来看这条。
     后端只在失败桶页签（发布失败 / 部分 SKU 审核失败等）补 failure_attribution 字段，
     其他页签与已上架商品不会出现这条；与上面粉色的「图片待人工处理」条同位置、颜色区分。 */
  body.page-scrape .failure-attribution-strip { display: grid; gap: 2px; margin-top: 5px; padding: 5px 7px; max-width: 190px; border: 1px solid #fde68a; border-radius: 6px; background: #fffbeb; font-size: 11px; line-height: 1.4; }
  body.page-scrape .failure-attribution-strip-title { color: #92400e; font-weight: 800; }
  body.page-scrape .failure-attribution-strip-signal { color: #92400e; opacity: .85; overflow-wrap: anywhere; }
  body.page-scrape .failure-attribution-strip-message { color: #64748b; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
  /* 中文提示同上（同一份后端静态词表）；俄文原文保留为证据，未命中时不渲染。 */
  body.page-scrape .failure-attribution-strip-message-zh { color: #334155; font-weight: 600; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
  body.page-scrape .action-btn-group { display: grid; grid-template-columns: repeat(2, 58px); justify-content: center; gap: 5px; }
  body.page-scrape .action-btn {
    width: 58px;
    min-width: 0;
    padding-left: 4px;
    padding-right: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: clip;
  }
  body.page-scrape .action-btn.is-wide {
    grid-column: span 2;
    width: 100%;
  }
  body.page-scrape .table-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 16px; background: #fff; border-top: 1px solid var(--scrape-line); }
  body.page-scrape .table-footer-left,
  body.page-scrape .table-pagination,
  body.page-scrape .page-jumper { display: flex; align-items: center; gap: 8px; color: var(--scrape-muted); }
  body.page-scrape .page-size-select { width: 72px; height: 30px; }
  body.page-scrape .page-jump-input { width: 64px; height: 30px; }
  body.page-scrape .page-btn.active { background: var(--scrape-blue); border-color: var(--scrape-blue); color: #fff; pointer-events: none; }

  /* 弹窗通用 */
  body.page-scrape #globalModal.modal-overlay { position: fixed; inset: 0; z-index: 10000; background: rgba(15,23,42,.42); backdrop-filter: none; display: flex; align-items: center; justify-content: center; padding: 24px; }
  body.page-scrape #globalModal.hidden { display: none !important; }
  body.page-scrape #globalModal .modal-container { max-width: calc(100vw - 48px); max-height: 88vh; overflow: hidden; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--scrape-line); border-radius: 16px; box-shadow: 0 24px 70px rgba(15,23,42,.24); }
  body.page-scrape #globalModal .modal-header { flex: 0 0 54px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 18px; border-bottom: 1px solid var(--scrape-line); background: #fff; }
  body.page-scrape #globalModal .modal-title { color: #0f172a; font-size: 16px; font-weight: 850; }
  body.page-scrape #globalModal .modal-title small { display: block; margin-top: 2px; color: var(--scrape-muted); font-size: 12px; font-weight: 500; }
  body.page-scrape #globalModal .modal-close { width: 32px; height: 32px; border: 0; border-radius: 9px; background: #f1f5f9; color: var(--scrape-label); font-size: 20px; cursor: pointer; }
  body.page-scrape #globalModal .modal-body { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 16px; background: #f8fafc; }
  body.page-scrape #globalModal .modal-footer-bar { flex: 0 0 auto; display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 16px; background: #fff; border-top: 1px solid var(--scrape-line); }
  body.page-scrape #imageToolsModal.modal-overlay { position: fixed; inset: 0; z-index: 10040; background: rgba(15,23,42,.42); display: flex; align-items: center; justify-content: center; padding: 24px; }
  body.page-scrape #imageToolsModal.hidden { display: none !important; }
  body.page-scrape #imageToolsModal .modal-container { width: min(1080px, calc(100vw - 48px)); max-width: calc(100vw - 48px); height: 90vh; max-height: 90vh; overflow: hidden; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--scrape-line); border-radius: 16px; box-shadow: 0 24px 70px rgba(15,23,42,.24); }
  body.page-scrape #imageToolsModal .modal-header { flex: 0 0 54px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 18px; border-bottom: 1px solid var(--scrape-line); background: #fff; cursor: move; touch-action: none; user-select: none; }
  body.page-scrape #imageToolsModal.is-dragging .modal-header { cursor: grabbing; }
  body.page-scrape #imageToolsModal .modal-title { color: #0f172a; font-size: 16px; font-weight: 850; }
  body.page-scrape #imageToolsModal .modal-title small { display: block; margin-top: 2px; color: var(--scrape-muted); font-size: 12px; font-weight: 500; }
  body.page-scrape #imageToolsModal .modal-close { width: 32px; height: 32px; border: 0; border-radius: 9px; background: #f1f5f9; color: var(--scrape-label); font-size: 20px; cursor: pointer; }
  body.page-scrape #imageToolsModal .modal-body { flex: 1 1 auto; min-height: 0; overflow: hidden; padding: 14px 16px 16px; background: #f8fafc; }
  body.page-scrape #imageToolsModal .modal-footer-bar { flex: 0 0 auto; display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 16px; background: #fff; border-top: 1px solid var(--scrape-line); }

  /* 编辑弹窗 */
  body.page-scrape #globalModal.erp-edit-modal .modal-container { width: min(1120px, calc(100vw - 48px)) !important; }
  body.page-scrape .edit-tabs { display: flex; gap: 6px; margin: -2px 0 12px; padding: 4px; width: fit-content; background: #fff; border: 1px solid var(--scrape-line); border-radius: var(--scrape-radius-pill); }
  body.page-scrape .edit-tab { height: 30px; padding: 0 14px; display: inline-flex; align-items: center; border-radius: var(--scrape-radius-pill); color: var(--scrape-muted); font-size: 13px; font-weight: 800; cursor: pointer; }
  body.page-scrape .edit-tab.active { background: var(--scrape-blue); color: #fff; }
  body.page-scrape .edit-tab-content:not(.active) { display: none; }
  body.page-scrape .erp-edit-card,
  body.page-scrape .erp-sku-card { margin-bottom: 12px; padding: 12px; background: #fff; border: 1px solid var(--scrape-line); border-radius: 12px; box-shadow: 0 1px 2px rgba(15,23,42,.03); }
  body.page-scrape .erp-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
  body.page-scrape .erp-card-title { font-size: 14px; font-weight: 850; color: #0f172a; }
  body.page-scrape .erp-card-subtitle,
  body.page-scrape .erp-help { color: var(--scrape-muted); font-size: 12px; }
  body.page-scrape .erp-grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; }
  body.page-scrape .erp-title-block { display: grid; gap: 6px; margin-bottom: 10px; }
  body.page-scrape .erp-image-grid { display: flex; gap: 10px; flex-wrap: wrap; }
  body.page-scrape .erp-image-item,
  body.page-scrape .erp-image-add { width: 82px; height: 82px; border-radius: 12px; border: 1px solid var(--scrape-line); overflow: hidden; background: #f8fafc; position: relative; display: grid; place-items: center; cursor: pointer; }
  body.page-scrape .erp-image-item img { width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; user-select: none; -webkit-user-drag: none; }
  body.page-scrape .erp-image-remove,
  body.page-scrape .sku-img-del { position: absolute; top: 5px; right: 5px; width: 20px; height: 20px; display: grid; place-items: center; border-radius: var(--scrape-radius-pill); background: rgba(239,68,68,.92); color: #fff; font-weight: 800; cursor: pointer; }
  body.page-scrape .erp-video-section { min-height: 60px; }
  body.page-scrape .erp-video-item { display: flex; align-items: flex-start; gap: 12px; }
  body.page-scrape .erp-video-actions { display: flex; flex-direction: column; gap: 6px; }
  body.page-scrape .erp-video-empty { display: flex; flex-direction: column; align-items: flex-start; }
  body.page-scrape .erp-video-add { width: 160px; height: 100px; border-radius: 12px; border: 2px dashed var(--scrape-line); background: #f8fafc; display: grid; place-items: center; cursor: pointer; color: var(--scrape-label); font-size: 13px; transition: border-color .2s; }
  body.page-scrape .erp-video-add:hover { border-color: var(--primary); color: var(--primary); }
  body.page-scrape .erp-sku-wrap { overflow: auto; border: 1px solid var(--scrape-line); border-radius: 12px; }
  body.page-scrape .erp-sku-table { width: 100%; border-collapse: collapse; font-size: 12px; }
  body.page-scrape .erp-sku-table th { padding: 9px 10px; background: #f8fafc; color: var(--scrape-label); border-bottom: 1px solid var(--scrape-line); text-align: left; }
  body.page-scrape .erp-sku-table td { padding: 8px 10px; border-bottom: 1px solid var(--scrape-line-soft); }
  body.page-scrape .sku-img-box { width: 48px; height: 48px; border-radius: 9px; border: 1px solid var(--scrape-line); overflow: hidden; background: #f8fafc; position: relative; }
  body.page-scrape .sku-img-preview { width: 100%; height: 100%; object-fit: cover; }
  body.page-scrape .quick-sku-name { min-width: 220px; }
  body.page-scrape .quick-sku-price { width: 110px; }
  body.page-scrape .rich-editor,
  body.page-scrape .desc-editor,
  body.page-scrape [contenteditable="true"] { background: #fff; border: 1px solid var(--scrape-line); border-radius: 12px; min-height: 320px; padding: 12px; }
  body.page-scrape .rich-editor img,
  body.page-scrape .desc-editor img,
  body.page-scrape [contenteditable="true"] img { max-width: 100%; height: auto; display: block; margin: 8px 0; }

  /* 发布弹窗 */
  body.page-scrape #globalModal.wiz-enterprise-modal .modal-container { width: min(1160px, calc(100vw - 48px)) !important; }
  body.page-scrape .wiz-root { display: grid; gap: 12px; color: #0f172a; }
  body.page-scrape .page-desc { margin: 0; color: var(--scrape-muted); font-size: 12px; }
  body.page-scrape .wiz-hero,
  body.page-scrape .wiz-plan-shell,
  body.page-scrape .wiz-subcard,
  body.page-scrape .wiz-panel { background: #fff; border: 1px solid var(--scrape-line); border-radius: 12px; box-shadow: 0 1px 2px rgba(15,23,42,.03); }
  body.page-scrape .wiz-hero { padding: 12px; }
  body.page-scrape .wiz-hero-top { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(240px, 1fr) minmax(220px, .9fr); gap: 12px; align-items: end; }
  body.page-scrape .wiz-hero-title,
  body.page-scrape .wiz-toggle-title,
  body.page-scrape .wiz-subcard-title { color: #0f172a; font-size: 14px; font-weight: 850; }
  body.page-scrape .wiz-hero-note,
  body.page-scrape .wiz-toggle-note,
  body.page-scrape .wiz-inline-hint { color: var(--scrape-muted); font-size: 12px; }
  body.page-scrape .wiz-field-label,
  body.page-scrape .wiz-field-mini,
  body.page-scrape .wiz-card-label { margin-bottom: 5px; color: var(--scrape-label); font-size: 12px; font-weight: 800; }
  body.page-scrape .wiz-store-select,
  body.page-scrape .wiz-input-sm { height: 32px; }
  body.page-scrape .wiz-plan-shell { padding: 10px; }
  body.page-scrape .wiz-plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; }
  body.page-scrape .wiz-plan-tile { padding: 9px 10px; border-radius: 10px; background: #f8fafc; border: 1px solid var(--scrape-line); }
  body.page-scrape .wiz-plan-title { color: var(--scrape-muted); font-size: 12px; font-weight: 800; }
  body.page-scrape .wiz-plan-desc { margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #0f172a; font-size: 13px; font-weight: 850; }
  body.page-scrape .wiz-plan-status,
  body.page-scrape .wiz-status-pill { display: inline-flex; align-items: center; min-height: 20px; margin-top: 5px; padding: 2px 7px; border-radius: var(--scrape-radius-pill); background: #eff6ff; color: #1d4ed8; font-size: 11px; font-weight: 800; }
  body.page-scrape .wiz-section-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 12px; align-items: start; }
  body.page-scrape .wiz-col { display: grid; gap: 12px; min-width: 0; }
  body.page-scrape .wiz-panel,
  body.page-scrape .wiz-subcard { padding: 12px; }
  body.page-scrape .wiz-toggle-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
  body.page-scrape .wiz-toggle-switch { display: inline-flex; align-items: center; gap: 6px; padding: 4px 8px; border-radius: var(--scrape-radius-pill); background: #f1f5f9; color: var(--scrape-label); font-size: 12px; font-weight: 800; }
  body.page-scrape .wiz-section-body { display: grid; gap: 10px; }
  body.page-scrape .wiz-search-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
  body.page-scrape .wiz-grow { flex: 1 1 auto; min-width: 0; }
  body.page-scrape .wiz-form-grid { display: grid; gap: 10px; }
  body.page-scrape .wiz-form-grid-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  body.page-scrape .wiz-form-grid-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
  body.page-scrape .wiz-form-grid-4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
  body.page-scrape .wiz-tip-box { padding: 8px 10px; border-radius: 10px; border: 1px solid var(--scrape-line); background: #f8fafc; color: var(--scrape-label); font-size: 12px; line-height: 1.45; }
  body.page-scrape .wiz-tone-ok { background: #f0fdf4; border-color: #bbf7d0; color: #166534; }
  body.page-scrape .wiz-tone-warn { background: #fffbeb; border-color: #fde68a; color: #92400e; }
  body.page-scrape .wiz-tone-error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
  body.page-scrape .source-min-order-confirm-overlay {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .42);
  }
  body.page-scrape .source-min-order-confirm {
    width: min(620px, calc(100vw - 48px));
    max-height: min(78vh, 720px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--scrape-line);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(15,23,42,.24);
  }
  body.page-scrape .source-min-order-confirm-head,
  body.page-scrape .source-min-order-confirm-actions {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    background: #fff;
  }
  body.page-scrape .source-min-order-confirm-head { border-bottom: 1px solid var(--scrape-line); }
  body.page-scrape .source-min-order-confirm-title { color: #0f172a; font-size: 16px; font-weight: 850; }
  body.page-scrape .source-min-order-confirm-close {
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 8px;
    background: #f1f5f9;
    color: var(--scrape-label);
    font-size: 20px;
    cursor: pointer;
  }
  body.page-scrape .source-min-order-confirm-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    display: grid;
    gap: 12px;
    padding: 14px 16px;
    background: #f8fafc;
  }
  body.page-scrape .source-min-order-confirm-desc { color: var(--scrape-label); font-size: 13px; line-height: 1.5; }
  body.page-scrape .source-min-order-risk-list { display: grid; gap: 8px; }
  body.page-scrape .source-min-order-risk-item {
    display: grid;
    gap: 6px;
    min-width: 0;
    padding: 10px 0;
    border: 0;
    border-top: 1px solid #edf2f7;
    border-radius: 0;
    background: transparent;
  }
  body.page-scrape .source-min-order-risk-group-title + .source-min-order-risk-item { border-top: 0; }
  body.page-scrape .source-min-order-risk-item.is-warning { color: #92400e; }
  body.page-scrape .source-min-order-risk-item.is-danger { color: #991b1b; }
  body.page-scrape .source-min-order-risk-item.is-unknown { color: #475569; }
  body.page-scrape .source-min-order-risk-group { display: grid; gap: 8px; }
  body.page-scrape .source-min-order-risk-group + .source-min-order-risk-group { margin-top: 4px; }
  body.page-scrape .source-min-order-risk-group-title { font-size: 12px; font-weight: 850; }
  body.page-scrape .source-min-order-risk-group-title.is-warning { color: #92400e; }
  body.page-scrape .source-min-order-risk-group-title.is-danger { color: #991b1b; }
  body.page-scrape .source-min-order-risk-group-title.is-unknown { color: #475569; }
  body.page-scrape .source-min-order-risk-title {
    min-width: 0;
    color: #0f172a;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.38;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
  body.page-scrape .source-min-order-risk-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px 10px;
    min-width: 0;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
  }
  body.page-scrape .source-min-order-risk-meta span {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.page-scrape .source-min-order-risk-item.is-danger .source-min-order-risk-meta span:nth-child(3) { color: #b91c1c; }
  body.page-scrape .source-min-order-risk-item.is-warning .source-min-order-risk-meta span:nth-child(3) { color: #b45309; }
  body.page-scrape .source-min-order-risk-more { color: var(--scrape-muted); font-size: 12px; }
  body.page-scrape .violation-precheck-detail { display: grid; gap: 10px; padding-top: 10px; border-top: 1px solid #e2e8f0; }
  body.page-scrape .violation-precheck-counts { display: flex; flex-wrap: wrap; gap: 6px 12px; color: #475569; font-size: 12px; font-weight: 650; }
  body.page-scrape .violation-precheck-product { display: grid; gap: 5px; padding: 10px 0; border-top: 1px solid #edf2f7; }
  body.page-scrape .violation-precheck-title { color: #0f172a; font-size: 13px; font-weight: 800; overflow-wrap: anywhere; }
  body.page-scrape .violation-precheck-meta,
  body.page-scrape .violation-precheck-issue,
  body.page-scrape .violation-precheck-outcome,
  body.page-scrape .violation-precheck-empty,
  body.page-scrape .violation-precheck-disclaimer { color: #64748b; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
  body.page-scrape .violation-precheck-issue { display: grid; gap: 2px; padding-left: 10px; border-left: 2px solid #fca5a5; }
  body.page-scrape .violation-precheck-outcome { color: #9a3412; font-weight: 700; }
  body.page-scrape .violation-precheck-disclaimer { margin-top: 10px; padding-top: 8px; border-top: 1px solid #e2e8f0; }
  body.page-scrape .source-min-order-confirm-actions { justify-content: flex-end; border-top: 1px solid var(--scrape-line); }
  body.page-scrape .wiz-moq-precheck {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    position: relative;
    background: transparent;
  }
  body.page-scrape .wiz-moq-precheck[open] {
    display: inline-flex;
  }
  body.page-scrape .wiz-moq-summary {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 8px;
    border: 1px solid #dbeafe;
    border-radius: var(--scrape-radius-pill);
    background: #eff6ff;
    color: #1d4ed8;
    cursor: pointer;
    font-size: 11px;
    font-weight: 850;
    line-height: 1.2;
    white-space: nowrap;
    list-style: none;
  }
  body.page-scrape .wiz-moq-summary::-webkit-details-marker { display: none; }
  body.page-scrape .wiz-moq-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  body.page-scrape .wiz-moq-title { color: #0f172a; font-size: 12px; font-weight: 850; }
  body.page-scrape .wiz-moq-count { color: var(--scrape-muted); font-size: 12px; font-weight: 700; }
  body.page-scrape .wiz-moq-chips { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
  body.page-scrape .wiz-moq-chip {
    display: inline-flex;
    align-items: center;
    min-height: 20px;
    padding: 2px 7px;
    border: 1px solid var(--scrape-line);
    border-radius: var(--scrape-radius-pill);
    background: #f8fafc;
    color: var(--scrape-label);
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
  }
  body.page-scrape .wiz-moq-chip.is-warning { border-color: #fde68a; background: #fffbeb; color: #92400e; }
  body.page-scrape .wiz-moq-chip.is-danger { border-color: #fecaca; background: #fef2f2; color: #991b1b; }
  body.page-scrape .wiz-moq-chip.is-unknown { border-color: #e2e8f0; background: #f8fafc; color: #475569; }
  body.page-scrape .wiz-moq-detail {
    display: grid;
    gap: 10px;
    min-width: 360px;
    padding: 12px;
    border: 1px solid #dfe7f1;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 14px 34px rgba(15, 23, 42, .14);
  }
  body.page-scrape .wiz-moq-secondary {
    border-top: 1px dashed #e2e8f0;
    padding-top: 8px;
  }
  body.page-scrape .wiz-moq-secondary summary {
    cursor: pointer;
    color: #2563eb;
    font-size: 12px;
    font-weight: 800;
    list-style: none;
  }
  body.page-scrape .wiz-moq-secondary summary::-webkit-details-marker { display: none; }
  body.page-scrape .wiz-moq-secondary-body {
    display: grid;
    gap: 10px;
    padding-top: 8px;
  }
  body.page-scrape .wiz-ai-failure-warning { margin-bottom: 10px; }
  body.page-scrape .wiz-quick-category-list { display: flex; flex-wrap: wrap; gap: 6px; max-height: none; overflow: visible; }
  body.page-scrape .wiz-quick-category-list .btn { max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  body.page-scrape .wiz-cat-suggest { display: grid; gap: 8px; }
  body.page-scrape .wiz-cat-item,
  body.page-scrape .category-result-item { padding: 9px 10px; border: 1px solid var(--scrape-line); border-radius: 10px; background: #fff; }
  body.page-scrape .wiz-offer-table-wrap { max-height: 240px; overflow: auto; border: 1px solid var(--scrape-line); border-radius: 10px; }
  body.page-scrape .wiz-offer-table { width: 100%; border-collapse: collapse; font-size: 12px; }
  body.page-scrape .wiz-offer-table th,
  body.page-scrape .wiz-offer-table td { padding: 8px 10px; border-bottom: 1px solid var(--scrape-line-soft); }
  body.page-scrape .wiz-title-table-wrap { max-height: 300px; overflow: auto; border: 1px solid var(--scrape-line); border-radius: 10px; }
  body.page-scrape .wiz-title-table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 12px; table-layout: fixed; }
  body.page-scrape .wiz-title-table th,
  body.page-scrape .wiz-title-table td { padding: 8px 10px; border-bottom: 1px solid var(--scrape-line-soft); vertical-align: top; }
  body.page-scrape .wiz-title-table th { background: #f8fafc; color: var(--scrape-label); font-weight: 850; text-align: left; white-space: nowrap; }
  body.page-scrape .wiz-title-table th:nth-child(1),
  body.page-scrape .wiz-title-table td:nth-child(1) { width: 170px; }
  body.page-scrape .wiz-title-table th:nth-child(2),
  body.page-scrape .wiz-title-table td:nth-child(2) { width: 100px; }
  body.page-scrape .wiz-title-table th:nth-child(3),
  body.page-scrape .wiz-title-table td:nth-child(3) { width: 78px; }
  body.page-scrape .wiz-title-table th:nth-child(4),
  body.page-scrape .wiz-title-table td:nth-child(4) { width: 118px; }
  body.page-scrape .wiz-title-table th:nth-child(6),
  body.page-scrape .wiz-title-table td:nth-child(6) { width: 150px; }
  body.page-scrape .wiz-title-product-row td { background: #f8fafc; }
  body.page-scrape .wiz-title-product-meta { display: flex; flex-wrap: wrap; gap: 8px; color: #334155; font-size: 11px; font-weight: 850; }
  body.page-scrape .wiz-title-base { margin-top: 4px; color: #475569; overflow-wrap: anywhere; line-height: 1.45; }
  body.page-scrape .wiz-title-offer,
  body.page-scrape .wiz-title-final { overflow-wrap: anywhere; line-height: 1.45; }
  body.page-scrape .wiz-title-final { color: #0f172a; font-weight: 750; }
  body.page-scrape .wiz-title-muted { color: var(--scrape-muted); }
  body.page-scrape .wiz-title-warning,
  body.page-scrape .wiz-title-preview-error { color: #991b1b; }
  body.page-scrape .wiz-title-blocked-alert { margin-bottom: 8px; }
  body.page-scrape .wiz-title-blocked-msg { font-weight: 750; }
  body.page-scrape .wiz-title-blocked-detail { margin-top: 4px; font-size: 11px; opacity: 0.85; }
  body.page-scrape .wiz-title-blocked-reasons { margin-top: 4px; font-size: 11px; display: flex; flex-direction: column; gap: 2px; }
  body.page-scrape .wiz-title-status-tag { display: inline-block; font-size: 10px; padding: 1px 5px; border-radius: 3px; font-weight: 750; }
  body.page-scrape .wiz-title-tag-cjk { background: #fee2e2; color: #991b1b; }
  body.page-scrape .wiz-title-tag-untranslated { background: #ffedd5; color: #9a3412; }
  body.page-scrape .wiz-title-tag-no-ts { background: #e0e7ff; color: #3730a3; }
  body.page-scrape .wiz-title-row-blocked { background: #fff5f5; }
  body.page-scrape .wiz-title-base-blocked { color: #991b1b; }
  body.page-scrape .wiz-title-final-blocked { color: #991b1b; text-decoration: line-through; text-decoration-color: #dc2626; text-decoration-thickness: 2px; }
  body.page-scrape .wiz-title-product-warnings { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 4px; }
  body.page-scrape .wiz-title-warn-tag { display: inline-block; font-size: 10px; padding: 2px 6px; border-radius: 3px; background: #fee2e2; color: #991b1b; font-weight: 750; }
  body.page-scrape .wiz-title-product-blocked { color: #991b1b; }

  /* AI 翻译确认弹窗 */
  body.page-scrape .wiz-ai-confirm-wrap { display: flex; flex-direction: column; gap: 10px; }
  body.page-scrape .wiz-ai-confirm-section { display: flex; align-items: flex-start; gap: 8px; }
  body.page-scrape .wiz-ai-confirm-label { min-width: 80px; font-size: 12px; color: var(--scrape-label); font-weight: 750; padding-top: 3px; }
  body.page-scrape .wiz-ai-confirm-value { font-size: 13px; color: #0f172a; line-height: 1.45; flex: 1; }
  body.page-scrape .wiz-ai-confirm-stats { display: flex; flex-wrap: wrap; gap: 4px; }
  body.page-scrape .wiz-stat-item { display: inline-block; font-size: 11px; padding: 1px 6px; border-radius: 3px; background: #f1f5f9; color: #475569; }
  body.page-scrape .wiz-stat-warn { background: #fef3c7; color: #92400e; }
  body.page-scrape .wiz-stat-ok { background: #d1fae5; color: #065f46; }
  body.page-scrape .wiz-ai-recommend-name { font-weight: 750; }
  body.page-scrape .wiz-ai-recommend-reason { display: block; font-size: 11px; color: var(--scrape-muted); margin-top: 2px; }
  body.page-scrape .wiz-ai-sample-titles { margin-top: 2px; }
  body.page-scrape .wiz-ai-sample-title { font-size: 11px; color: #64748b; padding: 2px 0; border-bottom: 1px dotted var(--scrape-line-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  body.page-scrape .wiz-ai-overwrite-warn { font-size: 12px; line-height: 1.5; }
  body.page-scrape .wiz-ai-will-translate-hint { margin-bottom: 8px; font-size: 13px; }

  /* 商品设置小弹窗 */
  body.page-scrape .erp-simple-modal,
  body.page-scrape .stock-bulk-panel,
  body.page-scrape .warehouse-panel,
  body.page-scrape .price-bulk-panel,
  body.page-scrape .category-modal-panel { background: #fff; border: 1px solid var(--scrape-line); border-radius: 12px; padding: 12px; }
  body.page-scrape .scrape-field,
  body.page-scrape .stock-form-row,
  body.page-scrape .warehouse-form-row { display: grid; gap: 6px; margin-bottom: 10px; }
  body.page-scrape .scrape-field-title,
  body.page-scrape .stock-form-label,
  body.page-scrape .logistics-label { color: #334155; font-size: 12px; font-weight: 800; }

      /* ===== 20260521 页面总宽度与其他工作台页面统一 ===== */
      body.page-scrape .erp-main {
        width: 100%;
        max-width: 1800px;
        margin: 0 auto;
        padding: 16px 16px 80px !important;
      }

      /* ===== 20260521 表格列宽与顶部操作模块收口 ===== */
      body.page-scrape .erp-row-top {
        display: flex !important;
        flex-wrap: wrap;
        align-items: center;
        gap: 8px !important;
        margin: 0 0 14px !important;
      }

      body.page-scrape .action-module,
      body.page-scrape .action-module:nth-child(n) {
        grid-column: auto !important;
        width: auto;
        max-width: 100%;
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 8px 10px;
      }

      body.page-scrape .module-title {
        font-size: 12px;
        line-height: 1;
      }

      body.page-scrape .module-btns {
        flex: 0 0 auto;
        flex-wrap: nowrap;
        gap: 6px;
      }

      body.page-scrape .module-btns .wb-btn {
        height: 30px;
        padding: 0 10px;
      }

      body.page-scrape .tabs-box .tab {
        height: 34px;
        padding: 0 15px;
        font-size: 13px;
        line-height: 34px;
      }

      body.page-scrape .tabs-box .muted {
        font-size: 12px;
      }

      body.page-scrape .board-table {
        min-width: 1580px;
        table-layout: fixed;
      }

      body.page-scrape .th-check,
      body.page-scrape .board-table th:nth-child(1),
      body.page-scrape .board-table td:nth-child(1) { width: 42px; }
      body.page-scrape .th-img,
      body.page-scrape .board-table th:nth-child(2),
      body.page-scrape .board-table td:nth-child(2) { width: 82px; }
      body.page-scrape .th-info,
      body.page-scrape .board-table th:nth-child(3),
      body.page-scrape .board-table td:nth-child(3) { width: 450px; }
      body.page-scrape .th-sku,
      body.page-scrape .board-table th:nth-child(4),
      body.page-scrape .board-table td:nth-child(4) { width: 148px; }
      body.page-scrape .th-sales,
      body.page-scrape .board-table th:nth-child(5),
      body.page-scrape .board-table td:nth-child(5) { width: 62px; }
      body.page-scrape .th-store,
      body.page-scrape .board-table th:nth-child(6),
      body.page-scrape .board-table td:nth-child(6) { width: 155px; }
      body.page-scrape .th-group,
      body.page-scrape .board-table th:nth-child(7),
      body.page-scrape .board-table td:nth-child(7) { width: 74px; }
      body.page-scrape .th-stock,
      body.page-scrape .board-table th:nth-child(8),
      body.page-scrape .board-table td:nth-child(8) { width: 184px; }
      body.page-scrape .th-price,
      body.page-scrape .board-table th:nth-child(9),
      body.page-scrape .board-table td:nth-child(9) { width: 94px; }
      body.page-scrape .th-status,
      body.page-scrape .board-table th:nth-child(10),
      body.page-scrape .board-table td:nth-child(10) { width: 108px; }
      body.page-scrape .th-time,
      body.page-scrape .board-table th:nth-child(11),
      body.page-scrape .board-table td:nth-child(11) { width: 164px; }
      body.page-scrape .th-action,
      body.page-scrape .board-table th:nth-child(12),
      body.page-scrape .board-table td:nth-child(12) { width: 120px; }

      body.page-scrape .lifecycle-times {
        display: grid;
        gap: 4px;
        min-width: 142px;
        text-align: left;
      }

      body.page-scrape .lifecycle-time {
        display: grid;
        grid-template-columns: 30px minmax(0, 1fr);
        align-items: center;
        gap: 5px;
        min-height: 18px;
        color: #475569;
        font-size: 11px;
        line-height: 1.2;
        white-space: nowrap;
      }

      body.page-scrape .lifecycle-time-label {
        color: #64748b;
        font-weight: 700;
      }

      body.page-scrape .lifecycle-time-value {
        overflow: hidden;
        text-overflow: ellipsis;
      }

      body.page-scrape .lifecycle-time.is-created.is-reached .lifecycle-time-label,
      body.page-scrape .lifecycle-time.is-created.is-reached .lifecycle-time-value {
        color: #047857;
      }

      body.page-scrape .lifecycle-time.is-pending .lifecycle-time-value {
        color: #94a3b8;
      }

      /* ===== 20260522 批量发布弹窗视觉优化 ===== */
      body.page-scrape #globalModal.erp-modal-scope.wiz-enterprise-modal .modal-container {
        max-height: min(92vh, 980px);
        border: 1px solid #dfe4ec;
        border-radius: 20px;
        box-shadow: 0 24px 70px rgba(15, 23, 42, .18), 0 8px 22px rgba(15, 23, 42, .08);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-header {
        flex-basis: auto;
        min-height: 68px;
        padding: 14px 26px;
        border-bottom-color: #e8ebf1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-title {
        color: #111827;
        font-size: 19px;
        font-weight: 760;
        letter-spacing: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-close {
        width: 36px;
        height: 36px;
        border-radius: 10px;
        background: #f4f6fa;
        color: var(--scrape-label);
      }

      body.page-scrape #globalModal.erp-modal-scope.wiz-enterprise-modal .modal-body {
        padding: 20px 24px;
        background: #f6f7fb;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar {
        gap: 10px;
        min-height: 71px;
        padding: 15px 26px;
        border-top-color: #e8ebf1;
        align-items: center;
        flex-wrap: nowrap;
        justify-content: flex-end;
      }

      /* 发布弹窗底部只保留主按钮，提交中/失败时显示单行小提示 */
      .publish-footer-status {
        flex: 0 1 auto;
        min-width: 0;
        max-width: min(360px, 58vw);
        padding: 0;
        margin: 0 4px 0 auto;
        font-size: 12px;
        line-height: 1.25;
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        gap: 6px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }
      .publish-footer-status.hidden { display: none !important; }
      .publish-footer-status--info { color: #475569; }
      .publish-footer-status--ok    { color: #166534; }
      .publish-footer-status--warn  { color: #92400e; }
      .publish-footer-status--error { color: #b91c1c; }

      .publish-footer-status-msg {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        font-weight: 500;
      }
      .publish-footer-status-detail {
        font-size: 12px;
        opacity: .78;
        overflow: hidden;
        text-overflow: ellipsis;
      }
      .publish-footer-status-detail + .publish-footer-status-detail::before {
        content: " · ";
        opacity: .5;
      }

      /* 右侧按钮区域：主提交按钮右对齐，不再居中大蓝按钮 */
      body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar > #modalSaveBtn {
        flex: 0 0 auto;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar > .modal-cancel-btn {
        display: none !important;
      }

      .publish-footer-actions {
        display: none !important;
      }
      .publish-footer-actions .btn {
        font-size: 13px;
        height: 34px;
        min-height: 34px;
        padding-left: 16px;
        padding-right: 16px;
        border-radius: 8px;
      }

      /* 紧凑 footer：主按钮尺寸统一 */
      body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar #modalSaveBtn {
        height: 40px;
        min-height: 40px;
        min-width: 104px;
        padding: 0 24px;
        font-size: 14px;
        border-radius: var(--scrape-radius-pill);
        font-weight: 760;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
        white-space: nowrap;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar .modal-cancel-btn {
        height: 40px;
        min-height: 40px;
        padding: 0 24px;
        font-size: 14px;
        border-radius: var(--scrape-radius-pill);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-root {
        display: flex;
        flex-direction: column;
        gap: 18px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .page-desc {
        line-height: 1.35;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-publish-overview {
        display: grid;
        padding: 12px;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
        box-shadow: var(--scrape-shadow);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-overview-main {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 12px;
        align-items: stretch;
        /* 2026-11-04 第十二轮：不再写死高度（原 --publish-overview-height: 148px）。
           「新增 N · 修改 N」从底行挪进标题行后内容自然高度 106px，
           三张卡等高改由 align-items: stretch 提供，谁的内容高按谁，不会裁字。 */
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-basic-store-card {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 6px;
        align-items: stretch;
        min-width: 0;
        padding: 14px 16px;
        border: 1px solid #e7eaf0;
        border-radius: 10px;
        background: #f5f6f8;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-hero-copy {
        align-self: center;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-hero-title {
        font-size: 14px;
        line-height: 1.2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-hero-note {
        margin-top: 2px;
        line-height: 1.25;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-store-field {
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-store-field-combined {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
        align-content: center;
        align-items: stretch;
        min-height: 100%;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-store-heading {
        color: #111827;
        line-height: 1.3;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-store-note {
        display: none;
        margin: 0;
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 500;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-field-label,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-card-label {
        margin-bottom: 0;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-field-label.wiz-store-heading {
        margin-bottom: 0;
        color: #0f172a;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-overview-title,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-head .wiz-overview-title {
        color: #111827;
        font-size: 14px;
        line-height: 1.25;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-store-select {
        height: 38px;
        min-height: 38px;
        border-radius: 8px;
        border-color: var(--scrape-input-border);
        font-size: 13px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-input-sm {
        height: 34px;
        min-height: 34px;
        border-radius: 8px;
        border-color: var(--scrape-input-border);
        font-size: 13px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-top-card,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-shell {
        display: block;
        min-width: 0;
        position: relative;
        padding: 14px 16px;
        border: 1px solid #e7eaf0;
        border-radius: 10px;
        background: #f5f6f8;
        overflow: visible;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #productLimitContent {
        min-height: 0;
        height: 100%;
        max-height: none;
        overflow: visible;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-card {
        --wiz-limit-label-col: 36px;
        /* 右半区让走 80 多像素后左半边会收窄：数值列要能跟着收，
           但「85/100」这类读数不能被省略号吃掉，所以下限留 52px。 */
        --wiz-limit-value-col: minmax(52px, 1fr);
        /* 余量列已在 2026-11-04 第四轮去掉；这个变量只剩加载态表头的「检查中」徽标在用 */
        --wiz-limit-head-extra-col: auto;
        /* 2026-11-04 第八轮：标签与数字之间的列距 8 → 16px（表头、额度行、右半区共用） */
        --wiz-limit-col-gap: 16px;
        /* 2026-11-04 第十四轮：右半区两列的宽度拿出来当公用变量，标题行的
           「新增 N | 修改 N」也用这一套。
           第十六轮：数字列改回 max-content —— 之前把它锁成 39px（按五位数字算的），
           实际额度是四位数时右对齐会在数字左边多留 8.3px，
           看起来「基础限额→1594」的间距比「上架→0/100」大；
           跟着内容走之后标签→数字始终是 16px，数字末位也仍然贴右沿。
           标签列是「基础限额」四个字的宽度（13px 下 52px）。
           第十七轮：标签列改 minmax(52px, max-content) —— 摘要的「新增 N」以前被死死按在
           52px 里，计数多一点就就地省略；用户明确说计数不会超过 3 位（「新增 999」= 50.55px，
           仍在 52px 内），而且宁可整块拉长也不要省略。改成下限 52px、上限跟着内容走：
           3 位以内宽度不变（和「基础限额」的对齐不变），更长就整块向左长，不再裁字。
           额度块那一列不受影响 —— 它的标签最长就是「基础限额」，max-content 正好 52px。 */
        --wiz-limit-extra-label-col: minmax(52px, max-content);
        --wiz-limit-extra-value-col: max-content;
        display: grid;
        grid-template-rows: auto minmax(0, 1fr);
        gap: 10px;
        height: 100%;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-head {
        display: grid;
        /* 第三列曾固定 64px，「每日额度预警」6 个字有 72px，会溢出卡片右沿；改成可按内容放宽 */
        grid-template-columns: var(--wiz-limit-label-col) var(--wiz-limit-value-col) minmax(var(--wiz-limit-head-extra-col), max-content);
        align-items: center;
        column-gap: var(--wiz-limit-col-gap);
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-summary {
        /* 2026-11-04 第十二轮：摘要从底行挪到标题行右侧，卡片因此少一行 */
        grid-column: 3;
        justify-self: end;
        /* 2026-11-04 第十四轮：和下面「基础限额 / 21169」排同一套两列、同一个列距。
           第十五轮：两段都贴各自格子的左沿 —— 「新增」的「新」和「基础限额」的「基」
           落在同一条竖线上，「修改 N」从数字列起点开始；数字列本身仍然贴右。 */
        display: grid;
        grid-template-columns: var(--wiz-limit-extra-label-col) var(--wiz-limit-extra-value-col);
        justify-items: stretch;
        column-gap: var(--wiz-limit-col-gap);
        min-width: 0;
        overflow: hidden;
        white-space: nowrap;
        color: #64748b;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 400;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-summary-part {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        /* 撑满自己的格子再左对齐：位数一多就地在格子里省略，
           不会像以前那样往左顶到「发布额度」标题上、也不会压到「修改」 */
        text-align: left;
      }

      /* 只有一段（「待确认」）时占满两列、整体贴右 */
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-summary-part:only-child {
        grid-column: 1 / -1;
        text-align: right;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-title {
        grid-column: 1 / 3;
        min-width: 0;
        color: #111827;
        /* 2026-11-04 第十轮：和「发布前检查」标题（.wiz-precheck-head .wiz-overview-title）相同，
           14px / 1.25 / 600 / #111827，两张卡并排时标题一样大。 */
        font-size: 14px;
        line-height: 1.25;
        font-weight: 600;
        line-height: 1.25;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-status {
        grid-column: 3;
        /* 与「余 …」「基础限额 / 附加」同一条右沿：整张卡右侧只留一条竖线 */
        justify-self: end;
        color: #2563eb;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 600;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-status.is-ok {
        color: #166534;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-status.is-warn {
        color: #b45309;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-status.is-error {
        color: #b91c1c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-body {
        display: grid;
        grid-template-rows: auto;
        gap: 8px;
        align-content: start;
        min-width: 0;
      }

      /* 2026-11-04 第三轮：模块分成左右两份 —— 左半边「上架 / 修改」，
         右半边「基础限额 / 附加」，在右半区里居左（不是贴右沿）。 */
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-main {
        display: grid;
        /* 两半：余量列去掉后左半区只要放得下「上架 85/100」，两列等分即可；
           右半区的「基础限额 / 附加」从它自己的左沿开始排。 */
        grid-template-columns: minmax(96px, 1fr) minmax(0, 1fr);
        column-gap: 12px;
        align-items: start;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-quota {
        /* 2026-11-04 第九轮：用户要求「21169 和右边的间距，和上架的左边距一样」——
           贴右排。卡片内容左右都没有内边距，外壳有 17px，所以右半区靠到内容右沿时，
           数字到白框右沿的留白正好等于「上架」到左沿的 17px。 */
        justify-self: end;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-lines {
        display: grid;
        gap: 6px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line {
        display: grid;
        /* 2026-11-04 第四轮：用户要求去掉「余 15 / 余 5000」，额度行只剩标签 + 已用/总量；
           第七轮：标签列按内容收紧（原来固定 36px，「上架」只有 26px，数字前实际空了 18px），
           这样列距 16px 就是眼睛看到的间距，和右半区一致。 */
        grid-template-columns: max-content var(--wiz-limit-value-col);
        column-gap: var(--wiz-limit-col-gap);
        align-items: center;
        min-width: 0;
        min-height: 22px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line-label {
        color: #64748b;
        /* 2026-11-04 第十轮：标签与数字一起定为 13px */
        font-size: 13px;
        line-height: 1.25;
        font-weight: 400;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line-value {
        min-width: 0;
        color: #0f172a;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 700;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line.is-ok .wiz-limit-line-value {
        color: #166534;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line.is-warn .wiz-limit-line-value {
        color: #b45309;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-line.is-error .wiz-limit-line-value {
        color: #b91c1c;
      }

      /* 后台真实额度（基础限额 / 附加）：右半区的两行两列，行高与「上架 / 修改」对齐
         （22px 行 + 6px 行距），数值列对齐，整体在右半区居左。 */
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra {
        display: grid;
        grid-template-columns: var(--wiz-limit-extra-label-col) var(--wiz-limit-extra-value-col);
        grid-auto-rows: 22px;
        /* 标签与数字之间留出和左边「上架    85/100」一样的列距（16px） */
        column-gap: var(--wiz-limit-col-gap);
        row-gap: 6px;
        align-items: center;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra-label {
        color: #64748b;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 400;
        /* 2026-11-04 第七轮：两行标签右对齐，「附加」的右沿落在「基础限额」的右沿上，
           数字前的间距因此也是 16px，不再是 26+16=42px */
        justify-self: end;
        text-align: right;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra-value {
        /* 数字列锁了宽度，靠右对齐保证末位仍然贴住卡片右沿；「—」这种短值也一并贴右 */
        justify-self: end;
        color: #0f172a;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 700;
        font-variant-numeric: tabular-nums;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra-value.is-ok {
        color: #166534;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra-value.is-warn {
        color: #b45309;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-extra-value.is-error {
        color: #b91c1c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-empty {
        display: flex;
        align-items: center;
        min-width: 0;
        min-height: 0;
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.4;
        font-weight: 400;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-grid-compact {
        grid-template-columns: minmax(0, 1fr);
        gap: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-tile {
        padding: 9px 10px;
        border-radius: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-inner {
        min-height: 38px;
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
          "title status"
          "desc desc";
        column-gap: 6px;
        row-gap: 3px;
        align-items: center;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-title {
        grid-area: title;
        font-size: 11px;
        line-height: 1.2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-desc {
        grid-area: desc;
        margin-top: 0;
        font-size: 12px;
        line-height: 1.25;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-plan-status {
        grid-area: status;
        min-height: 18px;
        margin-top: 0;
        padding: 1px 6px;
        font-size: 10px;
        line-height: 1.1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-compact {
        display: grid;
        /* 2026-11-06：三张卡是 align-items: stretch 等高的，这张原来的自然高度
           148px（含采购风险徽标时）比「发布额度」的 106px 高，会把整行顶开。
           这里把「详情」上提到标题行右侧，状态徽标独占第二行拿满整宽：
           徽标列从 267px 变成 319px，稳定排两行，卡片自然高度 96px。
           注意别再让标题去挤徽标那一行——v21 那样做徽标列只剩 189px，
           四个徽标挤成四行，卡片反而涨到 128px。 */
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-rows: auto auto;
        gap: 5px 8px;
        align-items: stretch;
        min-width: 0;
        position: relative;
        padding: 9px 16px;
        border: 1px solid #e7eaf0;
        border-radius: 10px;
        background: #f5f6f8;
        overflow: visible;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-head {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 6px;
        margin-bottom: 0;
        min-width: 0;
        grid-column: 1;
        grid-row: 1;
        align-self: center;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-head .wiz-subcard-title {
        flex: 1 1 auto;
        min-width: 52px;
        font-size: 14px;
        line-height: 1.25;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-summary {
        /* 2026-11-06：拆成 contents，徽标块与「详情」各自成为卡片的栅格项 */
        display: contents;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chips {
        display: flex;
        align-items: center;
        align-content: flex-start;
        flex-wrap: wrap;
        gap: 5px;
        grid-column: 1 / -1;
        grid-row: 2;
        min-width: 0;
        max-width: 100%;
        overflow: visible;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 0;
        max-width: 100%;
        min-height: 22px;
        padding: 2px 8px;
        border: 1px solid #dbeafe;
        border-radius: var(--scrape-radius-pill);
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
        line-height: 1.15;
        font-weight: 600;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-source-stock,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-image-check,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-violation-check {
        flex: 0 1 auto;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-violation-check-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 5px;
        min-width: 68px;
        min-height: 22px;
        padding: 2px 7px;
        border: 1px solid #cbd5e1;
        border-radius: 4px;
        background: #fff;
        color: #334155;
        font-size: 12px;
        line-height: 1.2;
        cursor: pointer;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-violation-check-btn:hover {
        border-color: #2563eb;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-violation-check-btn:disabled {
        cursor: wait;
        opacity: .65;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip-purchase {
        flex: 0 1 auto;
        min-width: 0;
        justify-content: flex-start;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.hidden {
        display: none;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-source-stock.wiz-tone-ok {
        border-color: #a7f3d0;
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-source-stock.wiz-tone-warn,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-image-check.wiz-tone-warn {
        border-color: #fed7aa;
        background: #fff7ed;
        color: #c2410c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.wiz-tone-error {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-danger {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-warning {
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-chip.is-unknown {
        border-color: #e2e8f0;
        background: #f8fafc;
        color: #475569;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-summary .wiz-moq-precheck {
        grid-column: 2;
        grid-row: 1;
        align-self: center;
        justify-self: end;
        margin-left: auto;
        flex: 0 0 auto;
        max-width: 100%;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-summary .wiz-moq-precheck[open] {
        flex: 0 0 auto;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-summary .wiz-moq-summary {
        min-height: 22px;
        padding: 2px 9px;
        border-color: #cbd5e1;
        background: #fff;
        color: #2563eb;
        font-size: 12px;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-summary .wiz-moq-detail {
        position: absolute;
        top: calc(100% + 8px);
        right: 0;
        z-index: 30;
        width: min(560px, calc(100vw - 96px));
        max-height: 260px;
        overflow: auto;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-brief {
        display: none;
        grid-column: 1 / -1;
        min-height: 0;
        padding: 0;
        border: 0;
        background: transparent;
        color: #64748b;
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-tip-compact {
        padding: 8px 11px;
        border: 0;
        border-radius: 10px;
        font-size: 12px;
        line-height: 1.45;
        min-height: 70px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #wizPrecheckDetail.wiz-precheck-brief {
        display: none;
        min-height: 0;
        padding: 0;
        border: 0;
        background: transparent;
        color: #64748b;
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #wizSkuDimensionWarning {
        grid-column: 1 / -1;
        margin-top: 6px;
        min-height: 0;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal #wizSkuDimensionWarning:not(.hidden) {
        margin-top: 6px;
        min-height: 34px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #publishSubmitStatus {
        grid-column: 1 / -1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-section-grid,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-col {
        gap: 14px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-panel {
        padding: 0;
        border: 1px solid var(--scrape-line);
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 1px 3px rgba(15, 23, 42, .04);
        transition: border-color .16s, box-shadow .16s, opacity .16s;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-panel:hover {
        border-color: #d7deea;
        box-shadow: 0 8px 22px rgba(15, 23, 42, .07);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-head {
        min-height: 68px;
        margin-bottom: 0;
        padding: 14px 18px;
        border-bottom: 1px solid #edf0f5;
        background: #fff;
        cursor: pointer;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-title {
        color: #111827;
        font-size: 15px;
        line-height: 1.25;
        font-weight: 760;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-copy {
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-note {
        display: block;
        margin-top: 3px;
        color: var(--scrape-muted);
        line-height: 1.35;
        font-weight: 500;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch {
        flex: 0 0 auto;
        min-height: 30px;
        padding: 0 11px;
        border: 1px solid #dbeafe;
        background: #eff6ff;
        color: #1d4ed8;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch input {
        accent-color: var(--scrape-blue);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-section-body,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-inline {
        gap: 12px;
        padding: 16px 18px 18px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-panel.is-disabled {
        opacity: .66;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-panel.is-failed-ai-context.is-disabled {
        opacity: 1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-compact {
        display: grid;
        gap: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-line {
        display: grid;
        gap: 10px;
        align-items: end;
        padding: 12px 0;
        border-radius: 0;
        background: transparent;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-row {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
        align-items: end;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-row > :first-child {
        grid-column: span 2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-unified .input {
        width: 100%;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-toggle {
        display: flex;
        align-items: end;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-toggle .btn {
        width: 100%;
        height: 40px;
        min-height: 40px;
        min-width: 0;
        font-size: 13px;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-settings-panel {
        display: grid;
        gap: 12px;
        min-width: 0;
        margin-top: 2px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-config-section {
        display: grid;
        gap: 10px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-rule-summary {
        min-height: 0;
        padding: 10px 14px;
        border: 1px solid #bfdbfe;
        border-radius: 8px;
        background: #f8fbff;
        color: #1e40af;
        font-size: 12px;
        line-height: 1.35;
        display: grid;
        gap: 3px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-section {
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-source {
        color: #1d4ed8;
        font-weight: 800;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-formula {
        color: #334155;
        font-weight: 650;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-line {
        grid-column: 1 / -1;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        justify-content: start;
        gap: 10px;
        align-items: end;
        max-width: none;
        padding: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-rule-line {
        grid-template-columns: minmax(270px, .92fr) minmax(100px, .34fr) minmax(112px, .38fr);
        justify-content: start;
        gap: 10px;
        align-items: end;
        padding: 0;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-rule-line > :first-child {
        grid-column: auto;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field {
        min-width: 0;
        display: grid;
        gap: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field .input,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field select,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-tail .input,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-decimals .input {
        width: 100%;
        min-width: 0;
        height: 40px;
        min-height: 40px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-round .wiz-radio-row-inline {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 5px;
        width: 100%;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-field.is-round .wiz-pill-radio {
        min-height: 36px;
        padding: 0 7px;
        border-radius: 7px;
        font-size: 12px;
        justify-content: center;
        text-align: center;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-round-action-row {
        grid-column: 1 / -1;
        display: block;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-action-row {
        grid-column: 1 / -1;
        display: flex;
        align-items: center;
        justify-content: flex-end;
        gap: 0;
        min-width: 0;
        padding-top: 0;
        border-top: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-action-title {
        display: none;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-actions {
        display: flex;
        gap: 8px;
        align-items: center;
        justify-content: flex-end;
        flex-wrap: wrap;
        min-width: 0;
      }

      /* === 价格规则参数网格 === */

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-grid {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 12px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell {
        display: grid;
        gap: 4px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell .input,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell select {
        width: 100%;
        height: 40px;
        min-height: 40px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-head {
        display: flex;
        align-items: center;
        gap: 10px;
        flex-wrap: wrap;
        margin-top: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-label {
        font-size: 12px;
        color: #475569;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-cost {
        width: 120px;
        min-width: 0;
        height: 32px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-body {
        display: grid;
        gap: 4px;
        min-width: 0;
        margin-top: 4px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-final {
        font-size: 16px;
        font-weight: 800;
        color: #1d4ed8;
        word-break: break-all;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-steps {
        display: grid;
        gap: 3px;
        font-size: 12px;
        color: #475569;
        line-height: 1.45;
        margin-top: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-steps-muted {
        color: #94a3b8;
        font-weight: 500;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-step {
        display: grid;
        grid-template-columns: 48px 1fr;
        gap: 6px;
        align-items: baseline;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-step-label {
        color: #64748b;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-step-detail {
        color: #334155;
        word-break: break-all;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-error {
        font-size: 13px;
        color: #b91c1c;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-grid-five {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        align-items: end;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell-round {
        grid-column: span 3;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell-round .wiz-radio-row-inline {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-cell-round .wiz-pill-radio {
        width: 100%;
        height: 40px;
        min-height: 40px;
        padding: 0 4px;
        font-size: 12px;
        justify-content: center;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-tail-hint {
        font-size: 11px;
        color: #b45309;
        background: #fffbeb;
        border: 1px solid #fde68a;
        border-radius: 6px;
        padding: 4px 7px;
        line-height: 1.4;
      }

      /* === 价格计算卡片（左侧两行 2/5 + 右侧公式 3/5） === */

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-card {
        border: 1px solid #bfdbfe;
        border-radius: 8px;
        background: #eff6ff;
        padding: 10px 14px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-grid {
        display: grid;
        grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
        gap: 14px;
        align-items: stretch;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-left {
        display: grid;
        grid-template-columns: minmax(0, max-content) minmax(0, 1fr);
        grid-auto-rows: 40px;
        gap: 8px 14px;
        align-items: center;
        justify-items: stretch;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-cost-row,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-final-row {
        display: contents;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-cost-row > span,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-final-row > span {
        font-size: 12px;
        font-weight: 600;
        color: var(--scrape-muted, #64748b);
        white-space: nowrap;
        text-align: left;
        justify-self: start;
        display: flex;
        align-items: center;
        height: 40px;
        line-height: 1.2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-cost {
        width: 100%;
        max-width: 100%;
        text-align: center;
        font-size: 12px;
        height: 40px;
        min-height: 40px;
        padding: 0 8px;
        appearance: textfield;
        -moz-appearance: textfield;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-cost::-webkit-outer-spin-button,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-preview-cost::-webkit-inner-spin-button {
        -webkit-appearance: none;
        margin: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-final-row strong {
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 16px;
        font-weight: 700;
        line-height: 1.2;
        color: var(--scrape-blue, #2563eb);
        text-align: center;
        white-space: nowrap;
        height: 40px;
        width: 100%;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-error-text {
        color: #b91c1c;
        font-size: 12px;
        font-weight: 600;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-right {
        min-width: 0;
        border-left: 1px solid #bfdbfe;
        padding-left: 14px;
        display: flex;
        flex-direction: column;
        justify-content: center;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-detail {
        display: grid;
        gap: 4px;
        font-size: 12px;
        line-height: 1.45;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-step {
        display: grid;
        grid-template-columns: 40px 1fr;
        gap: 6px;
        align-items: baseline;
        min-width: 0;
        color: #1e40af;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-step-label {
        color: #1d4ed8;
        font-weight: 600;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-step-detail {
        word-break: break-all;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-step-muted .wiz-price-calc-step-detail {
        color: #93c5fd;
      }

      @media (max-width: 720px) {
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-grid {
          grid-template-columns: 1fr;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-calc-right {
          border-left: 0;
          border-top: 1px solid #bfdbfe;
          padding-left: 0;
          padding-top: 12px;
        }
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-action-separator {
        display: none;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-field .input,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-field select {
        width: 100%;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-radio-row-inline {
        display: flex;
        flex-wrap: nowrap;
        gap: 8px;
        align-items: center;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-pill-radio {
        flex: 1;
        min-height: 40px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0;
        padding: 0 12px;
        border: 1px solid var(--scrape-input-border);
        border-radius: 8px;
        background: #fff;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
        white-space: nowrap;
        cursor: pointer;
        transition: background .15s, border-color .15s, color .15s;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-pill-radio input[type="radio"] {
        display: none;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-pill-radio:has(:checked) {
        background: var(--scrape-blue);
        border-color: var(--scrape-blue);
        color: #fff;
        z-index: 1;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-pill-radio:hover {
        border-color: var(--scrape-blue);
        z-index: 1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-stock-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px;
        max-width: none;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-stock-grid > * {
        grid-column: span 2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-tools-grid {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
        align-items: stretch;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-search-row .btn {
        height: 40px;
        min-height: 40px;
        border-radius: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-btn-solid-teal {
        border-color: var(--scrape-blue);
        background: var(--scrape-blue);
        color: #fff;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-btn-solid-teal:hover {
        border-color: var(--scrape-blue-dark);
        background: var(--scrape-blue-dark);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-tools-grid.is-multi {
        grid-template-columns: minmax(0, 1fr);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-module {
        min-width: 0;
        padding: 10px 12px;
        border: 0;
        border-radius: 10px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-cat-item.is-active,
      body.page-scrape #globalModal.wiz-enterprise-modal .category-result-item.is-active {
        border-color: #b8d4ff;
        background: #eff6ff;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-category-box {
        grid-column: 1 / -1;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-module .wiz-subcard-title,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-module .wiz-inline-zero {
        color: #0f172a;
        font-size: 13px;
        line-height: 1.25;
        font-weight: 850;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-module .wiz-inline-hint:not(.wiz-inline-zero) {
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.35;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recent-category-box {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: 8px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-nowrap {
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-inline-zero {
        min-width: max-content;
        line-height: 1.35;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-quick-category-list {
        min-width: 0;
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        /* 不限高：快捷类目全部平铺出来（用户 2026-11-01：不要滚动，直接拉长）。
           数量靠 40 的上限兜住，外层弹窗列本来就能滚。 */
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-quick-category-chip {
        height: 30px;
        max-width: 190px;
        border-radius: var(--scrape-radius-pill);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recommend-panel {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 10px;
        align-items: start;
        padding: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-current-box {
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-current-box .wiz-inline-hint {
        display: block;
        margin-top: 4px;
        line-height: 1.35;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-current-box .wiz-selected-category-line {
        font-size: 14px;
        font-weight: 700;
        line-height: 1.4;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-current-box .wiz-selected-category-line.wiz-tone-ok {
        background: transparent;
        border-color: transparent;
        color: #1677FF;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recommend-actions {
        display: flex;
        justify-content: flex-end;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recommend-btn {
        height: 30px;
        padding: 0 12px;
        border-color: #b8d4ff;
        border-radius: var(--scrape-radius-pill);
        background: #fff;
        color: var(--scrape-blue);
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recommend-btn:hover {
        border-color: #8ab8ff;
        background: #eff6ff;
        color: var(--scrape-blue-dark);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-module-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        margin-bottom: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #wizCategoryRecommendBox {
        display: grid;
        gap: 8px;
        grid-column: auto;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-card {
        display: grid;
        gap: 4px;
        padding: 11px 13px;
        border: 1px solid var(--scrape-line);
        border-radius: 12px;
        background: #fff;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-title {
        color: #111827;
        font-size: 13px;
        line-height: 1.35;
        font-weight: 760;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-path {
        color: #0f172a;
        font-size: 12px;
        line-height: 1.4;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-parent,
      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-reason {
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.4;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-panel {
        /* 与其他 wiz-panel 统一，不额外覆盖背景和边框 */
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-integrated {
        gap: 12px;
        padding: 16px 18px 18px;
        border: 0;
        border-radius: 0;
        background: transparent;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px;
        align-items: end;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid > :first-child {
        grid-column: span 2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-field {
        min-width: 0;
        display: grid;
        gap: 4px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions {
        display: flex;
        gap: 8px;
        align-items: end;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions .wiz-full-btn {
        width: 100%;
        min-width: 0;
        height: 40px;
        min-height: 40px;
        padding: 0 9px;
        font-size: 13px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-danger-btn {
        border-color: #fecaca;
        color: #b91c1c;
        background: #fef2f2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-template-block {
        display: grid;
        gap: 6px;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-textarea {
        width: 100%;
        min-height: 180px;
        height: 180px;
        max-height: 420px;
        padding: 12px 13px;
        border-color: #cbd5e1;
        background: #fff;
        color: #111827;
        font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
        font-size: 12px;
        line-height: 1.55;
        resize: vertical;
        white-space: pre-wrap;
      }


      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-dimension-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px;
        max-width: none;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-dimension-grid .input {
        width: 100%;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-stock-grid .input,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-dimension-grid .input {
        width: 100%;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-collapse {
        margin-top: 0;
        border: 1px solid var(--scrape-line);
        border-radius: 12px;
        background: var(--scrape-card-soft);
        overflow: hidden;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-collapse-summary {
        min-height: 40px;
        display: flex;
        align-items: center;
        padding: 9px 12px;
        color: #0f172a;
        font-size: 13px;
        font-weight: 760;
        cursor: pointer;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-toolbar {
        display: flex;
        justify-content: flex-end;
        padding: 8px 10px 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-reset-btn {
        height: 32px;
        padding: 0 12px;
        border-radius: 9px;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #wizOfferPreviewBox {
        padding: 8px 0 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #wizTitlePreviewBox {
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-inline {
        display: grid;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-inline-head {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        gap: 10px;
        min-height: 30px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-inline-head .wiz-subcard-title {
        margin: 0;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-empty-hint {
        padding: 10px 12px;
        border: 1px dashed #cbd5e1;
        border-radius: 10px;
        background: #fff;
        color: var(--scrape-muted);
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-tone-info {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-offer-table-wrap {
        margin-top: 12px;
        border-color: var(--scrape-line);
        border-radius: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-offer-table th {
        background: var(--scrape-card-soft);
        color: var(--scrape-muted);
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-offer-input {
        height: 36px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-cancel-btn,
      body.page-scrape #globalModal.wiz-enterprise-modal #modalSaveBtn {
        height: 40px;
        min-height: 40px;
        border-radius: var(--scrape-radius-pill);
        font-size: 14px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .modal-cancel-btn {
        display: none !important;
        min-width: 82px;
        padding: 0 24px;
        border-color: #d5dbe5;
        background: #fff;
        color: #334155;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal #modalSaveBtn {
        min-width: 104px;
        padding: 0 24px;
        font-weight: 760;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
        white-space: nowrap;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal #modalSaveBtn.hidden {
        display: none;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal #modalSaveBtn:disabled,
      body.page-scrape #globalModal.wiz-enterprise-modal #modalSaveBtn.is-publish-blocked {
        cursor: not-allowed;
        opacity: .72;
        box-shadow: none;
      }

      @media (max-width: 1100px) {
        body.page-scrape #globalModal.wiz-enterprise-modal .modal-body {
          padding: 18px;
        }

        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-overview-main,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-section-grid {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-basic-store-card,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-top-card,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-limit-shell,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-precheck-compact {
          min-height: 0;
        }
      }

      body.page-scrape #globalModal.erp-modal-scope .modal-container {
        width: min(860px, calc(100vw - 48px));
        border-radius: 14px;
        box-shadow: 0 18px 42px rgba(15, 23, 42, .18);
      }

      body.page-scrape #globalModal.erp-modal-scope .modal-body {
        background: #f8fafc;
        color: #0f172a;
        -webkit-font-smoothing: antialiased;
        text-rendering: geometricPrecision;
      }

      body.page-scrape .queue-status-shell,
      body.page-scrape .queue-publish-shell,
      body.page-scrape .stock-modal-shell,
      body.page-scrape .stats-loading-shell {
        display: grid;
        gap: 12px;
      }

      body.page-scrape .queue-publish-summary {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
      }

      body.page-scrape .queue-summary-card {
        padding: 12px 14px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
      }

      body.page-scrape .queue-summary-card.is-processing {
        border-color: #fed7aa;
        background: #fff7ed;
      }

      body.page-scrape .queue-summary-card.is-success {
        border-color: #bbf7d0;
        background: #f0fdf4;
      }

      body.page-scrape .queue-summary-card.is-failed {
        border-color: #fecaca;
        background: #fef2f2;
      }

      body.page-scrape .queue-summary-label {
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 750;
      }

      body.page-scrape .queue-summary-value {
        margin-top: 4px;
        color: #0f172a;
        font-size: 22px;
        font-weight: 850;
        line-height: 1.1;
      }

      body.page-scrape .queue-summary-value.is-time {
        font-size: 16px;
      }

      body.page-scrape .queue-status-card {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 12px;
        align-items: center;
        padding: 12px 14px;
        border: 1px solid #dbeafe;
        border-radius: 12px;
        background: #eff6ff;
        color: #1e40af;
      }

      body.page-scrape .queue-status-card.is-idle {
        border-color: #bbf7d0;
        background: #f0fdf4;
        color: #166534;
      }

      body.page-scrape .queue-label,
      body.page-scrape .queue-metric-title,
      body.page-scrape .queue-section-title {
        font-size: 13px;
        font-weight: 800;
        color: #0f172a;
      }

      body.page-scrape .queue-count {
        font-size: 18px;
        font-weight: 850;
      }

      body.page-scrape .queue-state {
        display: inline-flex;
        align-items: center;
        height: 24px;
        padding: 0 8px;
        border-radius: var(--scrape-radius-pill);
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .queue-state.is-processing {
        background: #fff7ed;
        color: #c2410c;
      }

      body.page-scrape .queue-state.is-idle {
        background: #dcfce7;
        color: #166534;
      }

      body.page-scrape .queue-state.is-paused {
        background: #fff1f2;
        color: #be123c;
      }

      body.page-scrape .queue-progress-shell {
        height: 8px;
        overflow: hidden;
        border-radius: var(--scrape-radius-pill);
        background: #e2e8f0;
      }

      body.page-scrape .queue-progress-bar {
        height: 100%;
        min-width: 24px;
        border-radius: var(--scrape-radius-pill);
        background: #2563eb;
        color: transparent;
        transition: width .2s ease;
      }

      body.page-scrape .queue-metric-grid,
      body.page-scrape .stats-grid {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
      }

      body.page-scrape .stats-grid-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }

      /* 「官方额度（辅助）」第二行：后台真实值（基础限额/附加） */
      body.page-scrape .quota-auxiliary-grid {
        margin-top: 10px;
      }

      body.page-scrape .queue-metric-card,
      body.page-scrape .stats-card {
        padding: 12px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
      }

      body.page-scrape .queue-metric-meta,
      body.page-scrape .stats-sub,
      body.page-scrape .quota-footnote {
        margin-top: 5px;
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.35;
      }

      body.page-scrape .queue-section,
      body.page-scrape .queue-warning-panel,
      body.page-scrape .quota-table-wrap,
      body.page-scrape .stats-table-wrap,
      body.page-scrape .warehouse-list {
        margin-top: 12px;
        overflow: auto;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
      }

      body.page-scrape .queue-section {
        padding: 12px;
      }

      body.page-scrape .queue-section-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        margin-bottom: 8px;
      }

      body.page-scrape .queue-refresh-hint {
        color: #94a3b8;
        font-size: 12px;
      }

      body.page-scrape .queue-task-actions {
        display: inline-flex;
        align-items: center;
        gap: 8px;
      }

      body.page-scrape .queue-manual-refresh-btn,
      body.page-scrape .queue-row-action {
        height: 30px;
        padding: 0 10px;
        border-radius: 8px;
        font-size: 12px;
        font-weight: 750;
        background: #fff;
      }

      body.page-scrape .queue-pause-btn {
        height: 30px;
        padding: 0 11px;
        border-radius: 8px;
        border: 1px solid #fecaca;
        background: #fff1f2;
        color: #be123c;
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .queue-pause-btn.is-paused {
        border-color: #bbf7d0;
        background: #f0fdf4;
        color: #15803d;
      }

      body.page-scrape .queue-pause-btn:disabled {
        opacity: .6;
        cursor: not-allowed;
      }

      body.page-scrape .queue-paused-banner {
        display: flex;
        align-items: center;
        gap: 8px;
        margin: 0 0 10px;
        padding: 9px 11px;
        border: 1px solid #fecdd3;
        border-radius: 9px;
        background: #fff1f2;
        color: #9f1239;
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape #globalModal .stats-refresh-btn {
        height: 32px;
        padding: 0 12px;
        border-radius: 9px;
        font-size: 12px;
        font-weight: 750;
        color: var(--scrape-ink);
        border: 1px solid #e2e8f0;
        background: #fff;
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        margin-left: auto;
        transition: border-color .15s, background-color .15s, color .15s;
      }

      body.page-scrape #globalModal .stats-refresh-btn:hover {
        border-color: #cbd5e1;
        background: #f8fafc;
      }

      body.page-scrape #globalModal .stats-refresh-btn:disabled {
        opacity: .6;
        cursor: not-allowed;
      }

      body.page-scrape #globalModal .stats-refresh-btn.is-refreshing i {
        animation: fa-spin 1s linear infinite;
      }

      body.page-scrape .queue-row-action {
        height: 28px;
        min-width: 52px;
      }

      body.page-scrape .queue-table,
      body.page-scrape .stats-table,
      body.page-scrape .quota-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 12px;
      }

      body.page-scrape .quota-table {
        table-layout: fixed;
        font-family: inherit;
        font-size: 12px;
        font-style: normal;
        font-weight: 400;
        line-height: 1.4;
      }

      body.page-scrape .quota-table.quota-table-4 col.quota-col-primary,
      body.page-scrape .quota-table.quota-table-3 col.quota-col-primary {
        width: 28%;
      }

      body.page-scrape .quota-table.quota-table-5 col.quota-col-primary {
        width: 24%;
      }

      body.page-scrape .quota-table.quota-table-4 col.quota-col-metric {
        width: 24%;
      }

      body.page-scrape .quota-table.quota-table-3 col.quota-col-metric {
        width: 36%;
      }

      body.page-scrape .quota-table.quota-table-5 col.quota-col-metric {
        width: 21%;
      }

      body.page-scrape .quota-table.quota-table-5 col.quota-col-browser {
        width: 17%;
      }

      /* 余额 tab（2026-11-15：采集时间独立成列并放最后一列，共 6 列）
         店铺 / 当前余额 / 已应计本月 / 待打款 / 打款日期 / 采集时间 */
      body.page-scrape .quota-table.quota-table-balance col.quota-col-primary {
        width: 30%;
      }

      body.page-scrape .quota-table.quota-table-balance col.quota-col-metric {
        width: 14%;
      }

      body.page-scrape .quota-table.quota-table-balance col.quota-col-time {
        width: 14%;
      }

      body.page-scrape .queue-table th,
      body.page-scrape .queue-table td,
      body.page-scrape .stats-table th,
      body.page-scrape .stats-table td,
      body.page-scrape .quota-table th,
      body.page-scrape .quota-table td {
        padding: 8px 10px;
        border-bottom: 1px solid #edf2f7;
        vertical-align: middle;
      }

      body.page-scrape .quota-table th,
      body.page-scrape .quota-table td {
        font-family: inherit;
        font-size: 12px;
        font-style: normal;
        line-height: 1.4;
      }

      body.page-scrape .quota-table td .quota-muted {
        font-size: 12px;
        line-height: 1.4;
      }

      body.page-scrape .queue-table th,
      body.page-scrape .stats-table th,
      body.page-scrape .quota-table th {
        background: #f8fafc;
        color: var(--scrape-label);
        font-weight: 800;
        text-align: left;
      }

      body.page-scrape .queue-table tr:last-child td,
      body.page-scrape .stats-table tr:last-child td,
      body.page-scrape .quota-table tr:last-child td {
        border-bottom: 0;
      }

      body.page-scrape .queue-th-xs { width: 44px; }
      body.page-scrape .queue-th-check { width: 40px; text-align: center !important; }
      body.page-scrape .queue-th-sm { width: 78px; text-align: center !important; }
      body.page-scrape .queue-th-type { width: 84px; }
      body.page-scrape .queue-th-time { width: 92px; }
      body.page-scrape .queue-th-status { width: 92px; }
      body.page-scrape .queue-th-action { width: 82px; text-align: center !important; }
      body.page-scrape .queue-td-center,
      body.page-scrape .stats-cell-center { text-align: center !important; }
      body.page-scrape .queue-subtext,
      body.page-scrape .quota-muted { color: var(--scrape-muted); font-size: 11px; }
      body.page-scrape .queue-product-id,
      body.page-scrape .quota-name { font-weight: 800; color: #0f172a; }
      body.page-scrape .queue-time-cell {
        white-space: nowrap;
        color: var(--scrape-muted);
      }

      body.page-scrape .queue-result-cell {
        max-width: 260px;
        color: #334155;
        line-height: 1.4;
      }

      body.page-scrape .queue-select-cell {
        width: 40px;
        padding-left: 6px !important;
        padding-right: 6px !important;
      }

      body.page-scrape .queue-product-cell {
        display: flex;
        align-items: center;
        gap: 9px;
        min-width: 260px;
        max-width: 430px;
      }

      body.page-scrape .queue-product-thumb {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        object-fit: contain;
        border: 1px solid #e2e8f0;
        border-radius: 7px;
        background: #f8fafc;
      }

      body.page-scrape .queue-product-thumb.is-empty {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        color: #94a3b8;
      }

      body.page-scrape .queue-product-meta {
        min-width: 0;
      }

      body.page-scrape .queue-product-title {
        display: -webkit-box;
        overflow: hidden;
        color: #0f172a;
        font-weight: 750;
        line-height: 1.35;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
      }

      body.page-scrape .queue-product-sub {
        margin-top: 3px;
        color: #64748b;
        font-size: 11px;
        line-height: 1.35;
      }

      body.page-scrape .queue-cancel-selected-btn {
        height: 30px;
        padding: 0 11px;
        border-radius: 8px;
        border: 1px solid #fecaca;
        background: #fff;
        color: #b91c1c;
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .queue-cancel-selected-btn:disabled {
        opacity: .55;
        cursor: not-allowed;
      }

      body.page-scrape .queue-cancelable,
      body.page-scrape .queue-locked {
        font-size: 11px;
        font-weight: 750;
        white-space: nowrap;
      }

      body.page-scrape .queue-cancelable { color: #b91c1c; }
      body.page-scrape .queue-locked { color: #94a3b8; }

      body.page-scrape .queue-status-pill {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 58px;
        height: 24px;
        padding: 0 9px;
        border-radius: var(--scrape-radius-pill);
        font-size: 12px;
        font-weight: 800;
        white-space: nowrap;
      }

      body.page-scrape .queue-status-pill.is-pending {
        background: #f1f5f9;
        color: #475569;
      }

      body.page-scrape .queue-status-pill.is-processing {
        background: #fff7ed;
        color: #c2410c;
      }

      body.page-scrape .queue-status-pill.is-success {
        background: #dcfce7;
        color: #166534;
      }

      body.page-scrape .queue-status-pill.is-warning {
        background: #fef3c7;
        color: #92400e;
      }

      body.page-scrape .queue-status-pill.is-failed {
        background: #fee2e2;
        color: #b91c1c;
      }

      body.page-scrape .queue-type-badge {
        display: inline-flex;
        align-items: center;
        height: 22px;
        padding: 0 8px;
        border-radius: var(--scrape-radius-pill);
        font-size: 11px;
        font-weight: 800;
      }

      body.page-scrape .queue-type-badge.is-publish {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .queue-type-badge.is-task {
        background: #f1f5f9;
        color: var(--scrape-label);
      }

      body.page-scrape .queue-warning-panel {
        padding: 12px;
        border-color: #fde68a;
        background: #fffbeb;
      }

      body.page-scrape .queue-warning-text {
        margin: 0 0 8px;
        color: #92400e;
        font-size: 12px;
      }

      body.page-scrape .queue-cleanup-btn {
        height: 32px;
        border-color: #fcd34d;
        color: #92400e;
        background: #fff;
      }

      body.page-scrape .queue-diagnostics {
        margin-top: 12px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
      }

      body.page-scrape .queue-diagnostics summary {
        cursor: pointer;
        padding: 10px 12px;
        color: #475569;
        font-size: 13px;
        font-weight: 800;
        list-style-position: inside;
      }

      body.page-scrape .queue-diagnostics[open] {
        padding-bottom: 12px;
      }

      body.page-scrape .queue-diagnostics[open] > .queue-status-shell,
      body.page-scrape .queue-diagnostics[open] > .queue-metric-grid,
      body.page-scrape .queue-diagnostics[open] > .queue-section {
        margin-right: 12px;
        margin-left: 12px;
      }

      @media (max-width: 760px) {
        body.page-scrape .queue-publish-summary {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }

        body.page-scrape .queue-section-head {
          align-items: flex-start;
          flex-direction: column;
        }

        body.page-scrape .queue-task-actions {
          width: 100%;
          justify-content: space-between;
        }
      }

      body.page-scrape .stock-toolbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 10px 12px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
      }

      body.page-scrape .stock-sync-btn,
      body.page-scrape .stock-apply-btn {
        height: 32px;
        border-radius: 8px;
        font-weight: 800;
      }

      body.page-scrape .stock-sync-btn {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .stock-sync-state {
        color: var(--scrape-muted);
        font-size: 12px;
      }

      body.page-scrape .stock-sync-state.is-warning {
        color: #b45309;
      }

      body.page-scrape .stock-bulk-panel {
        padding: 12px;
        border: 1px solid #dbeafe;
        border-radius: 12px;
        background: #eff6ff;
      }

      body.page-scrape .stock-bulk-title,
      body.page-scrape .warehouse-section-title {
        margin-bottom: 8px;
        color: #0f172a;
        font-size: 13px;
        font-weight: 850;
      }

      body.page-scrape .stock-form-row {
        display: grid;
        grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.2fr) 110px auto;
        gap: 10px;
        align-items: end;
        margin-bottom: 0;
      }

      body.page-scrape .stock-form-field {
        min-width: 0;
      }

      body.page-scrape .stock-form-label {
        display: block;
        margin-bottom: 5px;
      }

      body.page-scrape .stock-form-control {
        width: 100%;
        height: 34px;
      }

      body.page-scrape .stock-apply-btn {
        padding: 0 14px;
        border-color: #16a34a;
        background: #16a34a;
        color: #fff;
      }

      body.page-scrape .stock-hint {
        padding: 10px 12px;
        border: 1px solid #fde68a;
        border-radius: 12px;
        background: #fffbeb;
        color: #92400e;
        font-size: 13px;
      }

      body.page-scrape .warehouse-list {
        max-height: 340px;
      }

      body.page-scrape .warehouse-store {
        padding: 10px 12px;
        border-bottom: 1px solid #edf2f7;
      }

      body.page-scrape .warehouse-store:last-child {
        border-bottom: 0;
      }

      body.page-scrape .warehouse-store-title {
        margin-bottom: 6px;
        color: #0f172a;
        font-size: 13px;
        font-weight: 850;
      }

      body.page-scrape .warehouse-badge-list {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
      }

      body.page-scrape .warehouse-badge {
        display: inline-flex;
        align-items: center;
        min-height: 24px;
        padding: 2px 8px;
        border: 1px solid #e2e8f0;
        border-radius: var(--scrape-radius-pill);
        background: #f8fafc;
        color: var(--scrape-label);
        font-size: 12px;
      }

      body.page-scrape .stats-loading {
        min-height: 120px;
        display: grid;
        place-items: center;
        gap: 8px;
        padding: 24px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #fff;
        color: var(--scrape-muted);
      }

      body.page-scrape .stats-spinner {
        color: #2563eb;
        font-size: 22px;
      }

      body.page-scrape .stats-label,
      body.page-scrape .quota-section-title {
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .stats-value {
        margin-top: 4px;
        color: #0f172a;
        font-size: 24px;
        line-height: 1.1;
        font-weight: 900;
      }

      body.page-scrape .stats-card.is-create .stats-value,
      body.page-scrape .quota-value.is-create {
        color: #1d4ed8;
      }

      body.page-scrape .stats-card.is-update .stats-value,
      body.page-scrape .quota-value.is-update {
        color: #047857;
      }

      /* 额度色统一到批量发布弹窗口径：绿=正常、橙=<50 紧张、红=已满/不足 */
      body.page-scrape .quota-value.is-ok {
        color: #166534;
      }

      body.page-scrape .quota-value.is-warn {
        color: #b45309;
      }

      body.page-scrape .quota-value.is-error {
        color: #b91c1c;
      }

      body.page-scrape .quota-section-title {
        margin: 14px 0 8px;
        color: #0f172a;
        font-size: 13px;
      }

      body.page-scrape .quota-scope-note {
        margin-top: 8px;
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.5;
      }

      body.page-scrape .quota-head-note {
        display: block;
        min-height: 1.2em;
        font-family: inherit;
        color: #94a3b8;
        font-size: 10px;
        font-style: normal;
        font-weight: 600;
        line-height: 1.2;
        white-space: nowrap;
      }

      body.page-scrape .quota-head-label {
        display: block;
        min-height: 1.2em;
        font-family: inherit;
        font-size: 12px;
        font-style: normal;
        font-weight: 800;
        line-height: 1.2;
        white-space: nowrap;
      }

      body.page-scrape .quota-table th {
        height: 48px;
        box-sizing: border-box;
      }

      body.page-scrape .quota-value {
        font-family: inherit;
        font-size: 12px;
        font-style: normal;
        font-weight: 900;
        line-height: 1.4;
      }

      body.page-scrape .quota-row-error {
        background: #fff7ed;
      }

      body.page-scrape .quota-tabs {
        display: flex;
        gap: 4px;
        margin: 14px 0 10px;
        padding: 4px;
        overflow-x: auto;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #f8fafc;
      }

      body.page-scrape .quota-tab {
        flex: 1 1 0;
        min-width: 132px;
        min-height: 34px;
        padding: 6px 12px;
        border: 0;
        border-radius: 9px;
        background: transparent;
        color: var(--scrape-muted);
        cursor: pointer;
        font: inherit;
        font-size: 12px;
        font-weight: 800;
        white-space: nowrap;
      }

      body.page-scrape .quota-tab:hover {
        color: #1d4ed8;
        background: #eff6ff;
      }

      body.page-scrape .quota-tab.is-active {
        color: #1d4ed8;
        background: #fff;
        box-shadow: 0 1px 3px rgba(15, 23, 42, .10);
      }

      body.page-scrape .quota-tab-panel[hidden] {
        display: none;
      }

      body.page-scrape .quota-tab-empty {
        padding: 24px 14px;
        border: 1px dashed #cbd5e1;
        border-radius: 12px;
        background: #f8fafc;
        color: var(--scrape-muted);
        font-size: 12px;
        text-align: center;
      }

      body.page-scrape .daily-publish-loading {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 9px;
        padding: 10px 14px;
        border: 1px dashed #cbd5e1;
        border-radius: 10px;
        background: #f8fafc;
        color: var(--scrape-muted);
        font-size: 12px;
      }

      body.page-scrape .daily-publish-loading .stats-spinner,
      body.page-scrape .daily-publish-inline-loading i {
        color: #2563eb;
        font-size: 14px;
      }

      body.page-scrape .daily-publish-loading.is-error {
        border-color: #fecaca;
        background: #fff7f7;
        color: #b91c1c;
      }

      body.page-scrape .daily-publish-loading.is-error i {
        color: #dc2626;
      }

      body.page-scrape .daily-publish-row-loading td {
        background: #fbfdff;
        color: var(--scrape-muted);
      }

      body.page-scrape .daily-publish-inline-loading {
        display: inline-flex;
        align-items: center;
        gap: 7px;
        color: var(--scrape-muted);
        font-size: 11px;
      }

      body.page-scrape .daily-publish-toggle {
        display: inline-flex;
        align-items: center;
        gap: 7px;
        min-width: 126px;
        min-height: 28px;
        padding: 0;
        border: 0;
        background: transparent;
        color: #0f172a;
        cursor: pointer;
        font: inherit;
        font-weight: 800;
        text-align: left;
      }

      body.page-scrape .daily-publish-toggle::before {
        content: '';
        display: inline-block;
        width: 7px;
        height: 7px;
        margin: 0 4px 0 3px;
        border-right: 2px solid #64748b;
        border-bottom: 2px solid #64748b;
        transform: rotate(-45deg);
        transition: transform .16s ease, border-color .16s ease;
      }

      body.page-scrape .daily-publish-toggle.is-open::before,
      body.page-scrape .daily-publish-toggle:hover::before {
        border-color: #2563eb;
      }

      body.page-scrape .daily-publish-toggle.is-open::before {
        transform: rotate(45deg);
      }

      body.page-scrape .daily-publish-detail-row[hidden] {
        display: none;
      }

      body.page-scrape .quota-error,
      body.page-scrape .stats-error {
        margin-top: 4px;
        color: #b91c1c;
        font-size: 11px;
      }

      body.page-scrape .stats-error,
      body.page-scrape .stats-empty {
        padding: 18px;
        border: 1px solid #fecaca;
        border-radius: 12px;
        background: #fef2f2;
        color: #b91c1c;
      }

      /* ===== 20260918 上架统计：失效店铺行内标记 + 表格加载骨架 ===== */
      /* 上架统计弹窗单独放开高度：其它 erp-simple-modal 弹窗内容少，min(92vh,980px) 够用；
         这个弹窗「各店铺额度详情」有 25 家店铺（整表约 1230px），沿用旧上限只能看到一半。
         这里放长到整个视口（遮罩本来就留了 24px 上下内边距），内容少时依旧是内容高度。
         必须带上 erp-modal-scope.erp-simple-modal 以压过上面的旧规则。 */
      body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal.publish-stats-modal .modal-container {
        max-height: calc(100vh - 48px);
      }

      /* 1080p 屏要一次看完「各店铺额度详情」的 25 家店铺：整表 1230px、可用高度只有 875px，
         差 355px。高度已经放到整屏上限，剩下的只能靠收紧留白：
         弹窗内的边距 / 卡片 / 分组条各收一点，店铺表的行高再压到 22px（12px 字号不变）。 */
      body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal.publish-stats-modal .modal-body {
        padding: 12px 20px;
      }

      body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal.publish-stats-modal .modal-body > * + * {
        margin-top: 8px;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-section-title {
        margin: 6px 0;
      }

      body.page-scrape #globalModal.publish-stats-modal .stats-card {
        padding: 8px;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-scope-note {
        margin-top: 4px;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-tabs {
        margin: 8px 0;
      }

      /* ===== 2026-11-15 官方额度辅助区压成一行 =====
         改前：标题 + 2 张大卡 + 3 张大卡两行，纵向吃掉约 195px，余额表因此只能
         在 640px 面板里滚动。用户要求「把这块内容再压缩点，把余额全部店铺都显示出来」。
         改后：一行 5 格（今日可创建 / 今日可更改 / 基础限额 / 附加 / 总额度），
         去掉大标题（标签本身已说明），采集时间并进底部小字。省出约 135px。 */
      body.page-scrape .quota-aux-strip {
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        background: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
        overflow: hidden;
      }

      body.page-scrape .quota-aux-cell {
        display: flex;
        flex-direction: column;
        gap: 1px;
        min-width: 0;
        padding: 6px 10px;
      }

      body.page-scrape .quota-aux-cell + .quota-aux-cell {
        border-left: 1px solid #eef2f7;
      }

      body.page-scrape .quota-aux-label {
        color: var(--scrape-muted);
        font-size: 11px;
        font-weight: 800;
        line-height: 1.2;
      }

      body.page-scrape .quota-aux-value {
        color: #0f172a;
        font-size: 17px;
        font-weight: 900;
        line-height: 1.15;
        font-variant-numeric: tabular-nums;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      body.page-scrape .quota-aux-value.is-create {
        color: #1d4ed8;
      }

      body.page-scrape .quota-aux-value.is-update {
        color: #047857;
      }

      body.page-scrape .quota-aux-sub {
        color: #94a3b8;
        font-size: 10px;
        line-height: 1.2;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      /* ===== 2026-11-15 上架统计四个 tab 统一视觉节奏 =====
         改前：stores / 余额两张表被单独压成 th 38px、行高 22px，daily / 分组是 48px / 34px，
         两套节奏并排看就像两个产品；四个 panel 高度 185 / 319 / 611 / 611，
         每切一次 tab 整个弹窗跟着弹一下。

         改后：
           1) 四张表共用一套节奏 —— th 42px、td padding 6px 10px、行高 1.35
           2) panel 固定 430px 高、内部滚动，切 tab 时弹窗高度不动
           3) scrollbar-gutter: stable —— 店铺多的 tab 出现滚动条时内容宽度不变

         为什么 42px：daily 的日期是 28px 展开按钮，加 6×2 padding 正好 41px，
         取 42px 让四张表的表头和行都对齐在这一个值上。 */
      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-table th {
        height: 42px;
        padding: 6px 10px;
      }

      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-table td {
        padding: 5px 10px;
      }

      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-table td,
      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-value,
      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-muted,
      body.page-scrape #globalModal.publish-stats-modal [data-quota-panel] .quota-name-text {
        line-height: 1.35;
      }

      /* 切 tab 的尺寸由 queue-tools.js 的 lockPublishStatsHeight() 实时算：
         面板留 height:auto，JS 按当前 tab 的自然高度写 inline max-height；
         容器高度同步写 inline height，并带 180ms 缓动。

         为什么不是 flex:1 吃满剩余高度：短表（分组统计只有 6 组）会被拉满，
         表格和底部说明之间空出一大块 —— 就是用户报的「大间距」。
         为什么不是把四个 tab 统一锁成最高那个：同一个问题，短表留白 400+ px。
         所以按当前 tab 算高度，跳动用缓动化解。 */
      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel {
        height: auto;
        max-height: 460px;   /* 首帧占位；JS 量到真实高度后覆盖成 inline 值 */
        overflow-y: auto;
        overflow-x: hidden;
        scrollbar-gutter: stable;
      }

      /* 余额 22 家 / 额度详情 25 家，在小屏上物理上放不下，滚动条去不掉。
         那就把它做细、做淡，别跟主内容抢注意力（macOS 风格 6px 圆角滑块）。 */
      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel::-webkit-scrollbar {
        width: 6px;
        height: 6px;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel::-webkit-scrollbar-track {
        background: transparent;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel::-webkit-scrollbar-thumb {
        border-radius: 999px;
        background: #cbd5e1;
      }

      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel::-webkit-scrollbar-thumb:hover {
        background: #94a3b8;
      }

      /* 弹窗高度的 180ms 缓动由 queue-tools.js 的 lockPublishStatsHeight() 临时挂上、
         动画结束后摘掉 —— 不常驻 transition，避免数据刷新时的正常增高也被拖成慢动作。 */

      /* 面板里第一张表不要再顶 12px 外距 —— tab 条和表之间就是纯粹的 8px 间距 */
      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel > .quota-table-wrap:first-child {
        margin-top: 0;
      }

      /* 表头吸附在滚动容器顶部，滚动时列名不跑掉。 */
      body.page-scrape #globalModal.publish-stats-modal .quota-tab-panel .quota-table thead th {
        position: sticky;
        top: 0;
        z-index: 1;
        background: #f8fafc;
        box-shadow: inset 0 -1px 0 #edf2f7;
      }

      body.page-scrape .quota-name-text {
        display: inline;
      }

      /* 失效原因缩成店名后面的小标记（完整原因在 title 里），不再单独占一行撑高行距 */
      body.page-scrape .quota-name-badge {
        display: inline-block;
        margin-left: 6px;
        padding: 0 6px;
        border: 1px solid #e2e8f0;
        border-radius: 999px;
        background: #f8fafc;
        color: #475569;
        font-family: inherit;
        font-size: 10px;
        font-weight: 700;
        line-height: 16px;
        vertical-align: middle;
        white-space: nowrap;
        cursor: help;
      }

      body.page-scrape .quota-name-badge.is-error {
        border-color: #fed7aa;
        background: #fff7ed;
        color: #b45309;
      }

      body.page-scrape .quota-name-badge.is-blocked {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .quota-name-badge.is-disabled {
        border-color: #cbd5e1;
        background: #f1f5f9;
        color: #475569;
      }

      body.page-scrape .quota-loading-note {
        display: flex;
        align-items: center;
        gap: 6px;
        /* 加载提示挂在骨架表下方（放在表头上方会把表头下压 30px，数据到达时上窜），
           所以间距改为上 2px / 下 10px */
        padding: 2px 12px 10px;
        color: var(--scrape-muted);
        font-size: 12px;
      }

      /* 骨架行高与真实行对齐：统一节奏后 td padding 6px*2 + 12px × 1.35 行高 + 1px 边框 ≈ 29px。
         这里给 42px 是因为骨架行要跟 daily 的 42px 一起对齐（daily 有 28px 的按钮撑着），
         四个 tab 的骨架与真实行都取同一个值，加载态→真实数据不会跳。 */
      body.page-scrape .quota-skeleton-row td {
        height: 42px;
        box-sizing: border-box;
      }

      body.page-scrape .quota-skeleton-bar {
        display: block;
        width: 52%;
        height: 10px;
        margin: 0 auto;
        border-radius: 999px;
        background: linear-gradient(90deg, #eef2f7 0%, #dde5ee 50%, #eef2f7 100%);
        background-size: 200% 100%;
        animation: quota-skeleton-shimmer 1.4s ease-in-out infinite;
      }

      body.page-scrape .quota-skeleton-bar.is-primary {
        width: 64%;
        margin: 0;
      }

      /* 每日发布统计的真实行高由 .daily-publish-toggle 的 28px 最小高度决定
         （28 + 6×2 padding + 1px 边框 = 41px，统一节奏后 td padding 是 6px）。
         骨架行和「加载中」行取同样高度，这样打开弹窗、后台补数、数据到达三个阶段都不跳。 */
      body.page-scrape .quota-table.daily-publish-table .quota-skeleton-row td,
      body.page-scrape .quota-table.daily-publish-table .daily-publish-row-loading td {
        height: 42px;
        box-sizing: border-box;
      }

      @keyframes quota-skeleton-shimmer {
        0% { background-position: 200% 0; }
        100% { background-position: -200% 0; }
      }

      /* ===== 20260522 编辑商品弹窗视觉优化 ===== */
      body.page-scrape #globalModal.erp-modal-scope.erp-edit-modal .modal-container {
        width: min(1160px, calc(100vw - 48px)) !important;
        max-height: min(92vh, 980px);
        border: 1px solid #dfe4ec;
        border-radius: 20px;
        box-shadow: 0 24px 70px rgba(15, 23, 42, .18), 0 8px 22px rgba(15, 23, 42, .08);
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-header {
        flex-basis: auto;
        min-height: 68px;
        padding: 14px 26px;
        border-bottom-color: #e8ebf1;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-title {
        color: #111827;
        font-size: 19px;
        line-height: 1.25;
        font-weight: 760;
        letter-spacing: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-title small {
        margin-top: 4px;
        color: var(--scrape-muted);
        font-weight: 500;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-close {
        width: 36px;
        height: 36px;
        border-radius: 10px;
        background: #f4f6fa;
        color: var(--scrape-label);
      }

      body.page-scrape #globalModal.erp-modal-scope.erp-edit-modal .modal-body {
        padding: 20px 24px;
        background: #f6f7fb;
        color: #0f172a;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-footer-bar {
        gap: 10px;
        padding: 15px 26px;
        border-top-color: #e8ebf1;
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tabs {
        width: fit-content;
        max-width: 100%;
        gap: 5px;
        margin: 0 0 16px;
        padding: 5px;
        overflow: auto;
        border-color: var(--scrape-line);
        border-radius: var(--scrape-radius-pill);
        box-shadow: 0 1px 3px rgba(15, 23, 42, .04);
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tab {
        height: 36px;
        padding: 0 17px;
        color: var(--scrape-muted);
        font-weight: 760;
        white-space: nowrap;
        transition: background .16s, color .16s;
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tab:hover {
        color: #1d4ed8;
        background: #f4f7fd;
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tab.active {
        background: var(--scrape-blue);
        color: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tab-content.active {
        display: grid;
        gap: 16px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-edit-card,
      body.page-scrape #globalModal.erp-edit-modal .erp-sku-card {
        margin-bottom: 0;
        padding: 18px;
        border: 1px solid var(--scrape-line);
        border-radius: 16px;
        box-shadow: 0 1px 3px rgba(15, 23, 42, .04);
        transition: border-color .16s, box-shadow .16s;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-edit-card:hover {
        border-color: #d7deea;
        box-shadow: 0 8px 22px rgba(15, 23, 42, .07);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-card-head {
        align-items: flex-start;
        margin-bottom: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-card-title {
        color: #111827;
        font-size: 15px;
        line-height: 1.25;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-card-subtitle,
      body.page-scrape #globalModal.erp-edit-modal .erp-help {
        margin-top: 3px;
        color: var(--scrape-muted);
        line-height: 1.4;
        font-weight: 500;
      }

      body.page-scrape #globalModal.erp-edit-modal label {
        display: block;
        margin-bottom: 6px;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .input,
      body.page-scrape #globalModal.erp-edit-modal select {
        min-height: 40px;
        height: 40px;
        border-color: var(--scrape-input-border);
        border-radius: 10px;
        font-size: 13px;
      }

      body.page-scrape #globalModal.erp-edit-modal textarea.input {
        height: auto;
        min-height: 112px;
        padding-top: 10px;
        padding-bottom: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-title-block {
        gap: 0;
        margin-bottom: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-grid-4 {
        gap: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-edit-card {
        border-color: #cfe0f6;
        background: #fbfdff;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid {
        grid-template-columns: minmax(210px, 1.2fr) minmax(180px, 1fr) minmax(132px, .55fr) minmax(120px, .55fr);
        align-items: end;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-align-end {
        display: flex;
        align-items: flex-end;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-field-offset {
        margin-top: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-template-textarea {
        min-height: 180px;
        max-height: 520px;
        padding: 12px 13px;
        border-color: #cbd5e1;
        background: #fff;
        color: #111827;
        font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
        font-size: 12px;
        line-height: 1.55;
        resize: vertical;
        white-space: pre-wrap;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-form-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-top: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-form-actions {
        margin-top: 14px;
        padding-top: 2px;
      }

      body.page-scrape #globalModal.erp-edit-modal .btn {
        min-height: 38px;
        border-radius: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-full-btn {
        width: 100%;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-grid {
        gap: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-item,
      body.page-scrape #globalModal.erp-edit-modal .erp-image-add {
        width: 92px;
        height: 92px;
        border-color: var(--scrape-input-border);
        border-radius: 13px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-add {
        border-style: dashed;
        color: var(--scrape-muted);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-remove,
      body.page-scrape #globalModal.erp-edit-modal .sku-img-del {
        top: 5px;
        right: 5px;
        width: 22px;
        height: 22px;
        line-height: 22px;
        border: 2px solid #fff;
        box-shadow: 0 2px 6px rgba(15, 23, 42, .18);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-count {
        display: inline-flex;
        align-items: center;
        min-height: 28px;
        padding: 0 10px;
        border: 1px solid #dbeafe;
        border-radius: var(--scrape-radius-pill);
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-panel {
        padding: 12px 14px;
        border: 0;
        border-radius: 12px;
        background: var(--scrape-card-soft);
        color: var(--scrape-label);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-gap {
        margin-bottom: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-spaced {
        margin: 12px 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-panel.is-warning {
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-panel-title {
        color: #111827;
        font-size: 13px;
        line-height: 1.3;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-panel.is-warning .erp-status-panel-title {
        color: #92400e;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-status-panel-desc {
        margin-top: 4px;
        color: inherit;
        font-size: 12px;
        line-height: 1.42;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-meta span {
        min-height: 26px;
        display: inline-flex;
        align-items: center;
        padding: 4px 9px;
        border: 1px solid var(--scrape-line);
        border-radius: var(--scrape-radius-pill);
        background: #fff;
        color: var(--scrape-label);
        font-size: 12px;
        line-height: 1.25;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-section {
        margin-top: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-media-grid,
      body.page-scrape #globalModal.erp-edit-modal .ozon-source-video-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
        gap: 10px;
        margin-top: 8px;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-image {
        width: 100%;
        aspect-ratio: 3 / 4;
        overflow: hidden;
        padding: 0;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
        cursor: zoom-in;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-image img {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: cover;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-desc-image-list {
        margin-top: 8px;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-desc-image-link {
        display: block;
        margin-bottom: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-desc-image-link img {
        display: block;
        max-width: 100%;
        height: auto;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-video {
        overflow: hidden;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-video video {
        width: 100%;
        aspect-ratio: 16 / 9;
        display: block;
        background: #0f172a;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-video a {
        min-height: 32px;
        display: flex;
        align-items: center;
        padding: 0 10px;
        color: var(--scrape-blue);
        font-size: 12px;
        font-weight: 700;
        text-decoration: none;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-attrs {
        margin-top: 8px;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
        overflow: hidden;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-attr-row {
        display: grid;
        grid-template-columns: minmax(160px, .36fr) minmax(0, 1fr);
        gap: 12px;
        padding: 10px 12px;
        border-bottom: 1px solid var(--scrape-line-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-attr-row:last-child {
        border-bottom: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-attr-name {
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .ozon-source-attr-values {
        min-width: 0;
        color: var(--scrape-text);
        font-size: 13px;
        line-height: 1.42;
        overflow-wrap: anywhere;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-sku-wrap {
        border-color: var(--scrape-line);
        border-radius: 12px;
        background: #fff;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-sku-table th {
        padding: 10px 12px;
        background: var(--scrape-card-soft);
        border-bottom-color: var(--scrape-line);
        color: var(--scrape-muted);
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-sku-table td {
        padding: 10px 12px;
        vertical-align: middle;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-sku-group-row td {
        background: #fbfcfe;
        color: #334155;
        font-size: 12px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-row.is-failed td {
        background: #fff8f8;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-row.is-out-of-stock td {
        background: #f8fafc;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-img-box {
        width: 58px;
        height: 58px;
        border-color: var(--scrape-input-border);
        border-radius: 10px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .quick-sku-name,
      body.page-scrape #globalModal.erp-edit-modal .quick-sku-price {
        min-height: 38px;
        height: 38px;
      }

      body.page-scrape #globalModal.erp-edit-modal .quick-sku-name {
        display: none;
      }

      body.page-scrape #globalModal.erp-edit-modal .td-sku-title {
        min-width: 280px;
        max-width: 560px;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-title-cell {
        min-width: 0;
        overflow-wrap: anywhere;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-title-badges {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 5px;
        margin-bottom: 5px;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-title-state {
        display: inline-flex;
        align-items: center;
        min-height: 22px;
        padding: 2px 8px;
        border-radius: var(--scrape-radius-pill);
        font-size: 11px;
        font-weight: 760;
        line-height: 1.25;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-title-state.is-uploaded {
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-title-state.is-empty {
        background: #f8fafc;
        color: #64748b;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-title-state.is-preview {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-title-text {
        color: var(--scrape-text);
        font-size: 13px;
        font-weight: 680;
        line-height: 1.45;
        overflow-wrap: anywhere;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-offer {
        display: flex;
        flex-wrap: wrap;
        align-items: baseline;
        gap: 5px;
        margin-top: 5px;
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.35;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-offer code {
        color: var(--scrape-label);
        font-family: inherit;
        overflow-wrap: anywhere;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-title-note {
        margin-top: 5px;
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.35;
        overflow-wrap: anywhere;
      }

      body.page-scrape #globalModal.erp-edit-modal .sku-publish-title-note.is-warning {
        color: #b45309;
      }

      body.page-scrape #globalModal.erp-edit-modal .quick-sku-price {
        width: 116px;
      }

      body.page-scrape #globalModal.erp-edit-modal .source-stock-cell {
        display: inline-flex;
        align-items: center;
        min-height: 25px;
        padding: 2px 9px;
        border-radius: var(--scrape-radius-pill);
        background: #f1f5f9;
        color: var(--scrape-label);
        font-size: 11px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .source-stock-cell.is-ok {
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape #globalModal.erp-edit-modal .source-stock-cell.is-warning,
      body.page-scrape #globalModal.erp-edit-modal .source-stock-cell.is-loading {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.erp-edit-modal .source-stock-cell.is-empty {
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-shell {
        overflow: hidden;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-toolbar {
        display: flex;
        flex-wrap: wrap;
        gap: 7px;
        padding: 10px;
        border-bottom: 1px solid #edf0f5;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-toolbar button {
        min-height: 34px;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 0 11px;
        border: 1px solid var(--scrape-input-border);
        border-radius: 9px;
        background: #fff;
        color: #334155;
        font-size: 12px;
        font-weight: 700;
        cursor: pointer;
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-toolbar button:hover {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-toolbar .is-danger {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape #globalModal.erp-edit-modal .rich-editor-content {
        min-height: 340px;
        padding: 16px;
        border: 0;
        border-radius: 0;
        line-height: 1.55;
      }

      body.page-scrape #globalModal.erp-edit-modal .desc-image-editor img {
        max-width: min(100%, 420px);
        border-radius: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .desc-image-editor img.selected {
        outline: 3px solid rgba(22, 119, 255, .26);
        outline-offset: 2px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-recommend-box {
        display: grid;
        gap: 10px;
        margin-bottom: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-card {
        display: grid;
        gap: 7px;
        padding: 13px 14px;
        border: 1px solid var(--scrape-line);
        border-radius: 13px;
        background: #fff;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-title {
        color: #111827;
        font-size: 13px;
        line-height: 1.35;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-path {
        color: #0f172a;
        font-size: 13px;
        line-height: 1.42;
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-meta,
      body.page-scrape #globalModal.erp-edit-modal .cat-rec-reason,
      body.page-scrape #globalModal.erp-edit-modal .cat-rec-attrs {
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.42;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-error,
      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-error {
        color: #b91c1c;
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-warn,
      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-warn {
        color: #92400e;
        font-size: 12px;
        font-weight: 600;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-btn.is-low,
      body.page-scrape #globalModal.wiz-enterprise-modal .cat-rec-btn.is-low {
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-fold {
        display: grid;
        gap: 10px;
        padding: 11px;
        border: 1px solid var(--scrape-line);
        border-radius: 13px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-fold-summary {
        color: #334155;
        font-size: 12px;
        font-weight: 760;
        cursor: pointer;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-low-confidence {
        border-color: #fcd34d;
        background: #fffbeb;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-low-note {
        margin-top: 6px;
        color: #92400e;
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual {
        display: grid;
        gap: 8px;
        padding: 12px;
        border: 1px dashed var(--scrape-line);
        border-radius: 13px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-head {
        color: #334155;
        font-size: 12px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-row {
        display: flex;
        align-items: center;
        gap: 8px;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-row .input {
        flex: 1;
        min-width: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-results {
        display: grid;
        gap: 6px;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-item {
        display: grid;
        gap: 3px;
        width: 100%;
        padding: 9px 10px;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
        text-align: left;
        cursor: pointer;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-item:hover {
        border-color: #93c5fd;
        background: #f8fbff;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-name {
        color: #0f172a;
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-meta,
      body.page-scrape #globalModal.erp-edit-modal .cat-rec-manual-empty {
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.4;
      }

      body.page-scrape #globalModal.erp-edit-modal #dynamicAttrsBox {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
        margin-top: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal #dynamicAttrsBox > .erp-status-panel,
      body.page-scrape #globalModal.erp-edit-modal #dynamicAttrsBox > .erp-loading-state,
      body.page-scrape #globalModal.erp-edit-modal #dynamicAttrsBox > .erp-error-text {
        grid-column: 1 / -1;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-card {
        padding: 13px;
        border: 0;
        border-radius: 12px;
        background: var(--scrape-card-soft);
        box-shadow: none;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-card:hover {
        border-color: transparent;
        box-shadow: none;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-label {
        margin-bottom: 4px;
        color: #111827;
        font-size: 13px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-help {
        min-height: 34px;
        margin: 0 0 9px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-required {
        color: #dc2626;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-attr-dict {
        display: inline-flex;
        align-items: center;
        min-height: 21px;
        padding: 0 7px;
        border-radius: var(--scrape-radius-pill);
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 11px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-loading-state,
      body.page-scrape #globalModal.erp-edit-modal .erp-error-text {
        display: flex;
        align-items: center;
        gap: 7px;
        min-height: 48px;
        padding: 12px 14px;
        border-radius: 12px;
        font-size: 12px;
        line-height: 1.42;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-loading-state {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-error-text {
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-cancel-btn,
      body.page-scrape #globalModal.erp-edit-modal #modalSaveBtn {
        height: 40px;
        min-height: 40px;
        border-radius: var(--scrape-radius-pill);
        font-size: 14px;
      }

      body.page-scrape #globalModal.erp-edit-modal .modal-cancel-btn {
        min-width: 82px;
        border-color: #d5dbe5;
        background: #fff;
        color: #334155;
      }

      body.page-scrape #globalModal.erp-edit-modal #modalSaveBtn {
        min-width: 104px;
        padding: 0 24px;
        font-weight: 760;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
      }

      @media (max-width: 980px) {
        body.page-scrape #globalModal.erp-modal-scope.erp-edit-modal .modal-body {
          padding: 18px;
        }

        body.page-scrape #globalModal.erp-edit-modal #dynamicAttrsBox {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }
      }

      @media (max-width: 720px) {
        body.page-scrape #globalModal.erp-edit-modal .modal-header,
        body.page-scrape #globalModal.erp-edit-modal .modal-footer-bar {
          padding-left: 16px;
          padding-right: 16px;
        }

        body.page-scrape #globalModal.erp-modal-scope.erp-edit-modal .modal-body {
          padding: 14px;
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-edit-card,
        body.page-scrape #globalModal.erp-edit-modal .erp-sku-card {
          padding: 14px;
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-card-head,
        body.page-scrape #globalModal.erp-edit-modal .cat-rec-head {
          flex-direction: column;
        }

        body.page-scrape #globalModal.erp-edit-modal .modal-title {
          font-size: 18px;
        }

        body.page-scrape #globalModal.erp-edit-modal .rich-editor-content {
          min-height: 280px;
          padding: 12px;
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid {
          grid-template-columns: minmax(0, 1fr);
        }

        /* 发布向导 */
        body.page-scrape #globalModal.wiz-enterprise-modal .modal-header,
        body.page-scrape #globalModal.wiz-enterprise-modal .modal-footer-bar {
          padding-left: 16px;
          padding-right: 16px;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .modal-body {
          padding: 14px;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-section-body,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-sku-inline {
          padding: 14px;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-tools-grid,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-tools-grid.is-multi,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-row,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-line,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-rule-line,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-round-action-row,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-stock-grid,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid {
          grid-template-columns: minmax(0, 1fr);
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-summary-row > :first-child {
          grid-column: auto;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions {
          flex-wrap: wrap;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions .wiz-full-btn {
          flex: 1 1 56px;
          height: 40px;
          min-height: 40px;
          font-size: 13px;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-param-section {
          grid-template-columns: minmax(0, 1fr);
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-action-row {
          justify-content: flex-end;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-actions {
          display: grid;
          grid-template-columns: repeat(3, minmax(0, 1fr));
          width: 100%;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-actions .btn {
          width: auto;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-actions .btn {
          padding-left: 8px;
          padding-right: 8px;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-delete-action {
          grid-column: auto;
          justify-self: stretch;
          margin-left: 0;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-dimension-grid {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-head,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-recommend-panel {
          grid-template-columns: minmax(0, 1fr);
          align-items: flex-start;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-head {
          flex-direction: column;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch {
          align-self: flex-start;
        }
      }

      /* ===== 20260522 商品上架页统一视觉风格 ===== */
      body.page-scrape .erp-main {
        padding: 20px 18px 80px !important;
      }

      /* ⚠️ 2026-10-20：必须显式写 grid-template-columns: minmax(0, 1fr)。
         原来只有 display:grid + gap，隐式单列的轨道宽度按 min-content 计算，
         而 .scrape-action-bar 里 5 个按钮组是 flex: 0 0 auto（不肯收缩），
         于是轨道被撑成「所有按钮 min-content 之和」：
           视口 820px  → 轨道 1012px（溢出 204px）
           视口 1440px → 轨道 1509px（溢出 87px）
         结果是整页横向滚动、右侧「筛选/重置」和日期筛选跑到屏幕外。
         minmax(0, 1fr) 把轨道下限压到 0，配合 .scrape-action-bar 已有的
         flex-wrap: wrap，按钮组在窄屏下才会换行而不是把整页撑宽。
         实测（CDP，视口 820/1024/1440 溢出像素）：修复前 204 / 6 / 87 → 修复后 0 / 0 / 0。 */
      body.page-scrape .erp-toolbar {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
        margin-bottom: 14px !important;
        min-width: 0;
      }

      /* 同理：filter-grid-one-line 的 grid-template-columns 里有 minmax(360px, 1.35fr)
         等固定下限，窄屏下总和超过视口也会把父容器撑宽。给它一个可收缩的下限，
         并允许窄屏改成多行（下面 @media 里已有单列规则，这里只保证不溢出）。 */
      body.page-scrape .filter-shell {
        min-width: 0;
      }

      body.page-scrape .scrape-action-bar {
        width: 100%;
        min-height: 72px;
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 10px 12px;
        margin: 0 !important;
        padding: 10px 12px;
        border: 1px solid var(--scrape-line);
        border-radius: 12px;
        background: #fff;
        box-shadow: 0 2px 8px rgba(15, 23, 42, .05);
        overflow: visible;
      }

      body.page-scrape .scrape-action-group {
        min-width: 0;
        display: flex;
        align-items: center;
        gap: 8px;
      }

      body.page-scrape .scrape-action-group:first-child {
        flex: 0 0 auto;
      }

      body.page-scrape .scrape-action-group:nth-child(2) {
        flex: 0 0 auto;
      }

      body.page-scrape .scrape-action-group + .scrape-action-group,
      body.page-scrape .scrape-action-dropdown {
        padding-left: 12px;
        border-left: 1px solid #e5e7eb;
      }

      body.page-scrape .scrape-action-title {
        flex: 0 0 auto;
        color: var(--scrape-label);
        font-size: 11px;
        line-height: 1;
        font-weight: 800;
        white-space: nowrap;
      }

      body.page-scrape .scrape-action-buttons {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        min-width: 0;
        gap: 6px;
      }

      body.page-scrape .scrape-action-bar .wb-btn,
      body.page-scrape .filter-search .btn,
      body.page-scrape .page-btn {
        height: 36px;
        min-height: 36px;
        border-radius: 10px;
      }

      body.page-scrape .scrape-action-bar .wb-btn {
        flex: 0 0 auto;
        padding: 0 10px;
      }

      body.page-scrape .scrape-action-bar .wb-btn:not(.wb-btn-primary):not(.wb-btn-danger) {
        border-color: var(--scrape-input-border);
        background: var(--scrape-card-soft);
        color: #1f2937;
      }

      body.page-scrape .scrape-action-bar .wb-btn:not(.wb-btn-primary):not(.wb-btn-danger):hover {
        border-color: #cbd5e1;
        background: #fff;
      }

      body.page-scrape .scrape-action-bar .wb-btn-primary {
        box-shadow: 0 1px 2px rgba(0, 102, 204, .18);
      }

      body.page-scrape .scrape-action-dropdown {
        flex: 0 0 auto;
        margin-left: 0;
        position: relative;
        overflow: visible;
        z-index: 20;
      }

      body.page-scrape .scrape-action-dropdown[open] {
        z-index: 80;
      }

      body.page-scrape .scrape-advanced-toggle {
        height: 36px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 98px;
        padding: 0 12px;
        border: 1px solid var(--scrape-input-border);
        border-radius: 10px;
        background: #fff;
        color: #334155;
        font-size: 13px;
        font-weight: 800;
        cursor: pointer;
        list-style: none;
        user-select: none;
      }

      body.page-scrape .scrape-advanced-toggle::-webkit-details-marker {
        display: none;
      }

      body.page-scrape .scrape-action-dropdown .advanced-summary-open {
        display: inline;
      }

      body.page-scrape .scrape-action-dropdown .advanced-summary-closed {
        display: none;
      }

      body.page-scrape .scrape-action-dropdown:not([open]) .advanced-summary-open {
        display: none;
      }

      body.page-scrape .scrape-action-dropdown:not([open]) .advanced-summary-closed {
        display: inline;
      }

      body.page-scrape .scrape-advanced-menu .wb-btn {
        width: 100%;
        min-width: 0;
      }

      body.page-scrape .scrape-action-dropdown:not([open]) .scrape-advanced-menu {
        display: none;
      }

      body.page-scrape .scrape-action-dropdown[open] .scrape-advanced-menu {
        position: absolute;
        top: calc(100% + 8px);
        right: 0;
        z-index: 90;
        width: 400px;
        min-width: 360px;
        max-width: min(420px, calc(100vw - 36px));
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
        padding: 10px;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
        box-shadow: 0 12px 28px rgba(15, 23, 42, .14);
      }

      body.page-scrape .scrape-advanced-menu .scrape-menu-wide {
        grid-column: 1 / -1;
      }

      body.page-scrape .filter-shell {
        display: grid;
        gap: 12px;
        padding: 14px !important;
        border: 1px solid var(--scrape-line) !important;
        border-radius: 8px !important;
        background: #fff !important;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .04) !important;
      }

      body.page-scrape .status-tabs-row {
        margin: 12px 0 0;
        overflow: hidden;
      }

      body.page-scrape .filter-head {
        min-width: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding-bottom: 2px;
      }

      body.page-scrape .filter-summary {
        min-width: 0;
        color: #334155;
        font-size: 12px;
        font-weight: 650;
        line-height: 1.35;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      body.page-scrape .filter-count {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        min-height: 26px;
        padding: 0 9px;
        border: 1px solid #dbeafe;
        border-radius: 8px;
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
        font-weight: 750;
        white-space: nowrap;
      }

      body.page-scrape .filter-count span {
        margin: 0 3px;
        font-variant-numeric: tabular-nums;
      }

      body.page-scrape .filter-search {
        width: 100%;
        max-width: none;
        display: grid;
        grid-template-columns: minmax(260px, 1fr) auto auto;
        align-items: stretch;
        gap: 10px;
        margin: 0;
      }

      body.page-scrape .filter-search-box {
        min-width: 0;
        height: 42px;
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 0 11px;
        overflow: hidden;
        border: 1px solid var(--scrape-input-border);
        border-radius: 8px;
        background: #f8fafc;
        transition: background .16s, border-color .16s, box-shadow .16s;
      }

      body.page-scrape .filter-search-box:focus-within {
        background: #fff;
        border-color: var(--scrape-blue);
        box-shadow: 0 0 0 3px rgba(22, 119, 255, .10);
      }

      body.page-scrape .filter-search-box .fa,
      body.page-scrape .filter-search-box .fas {
        width: 16px;
        margin: 0;
        display: inline-flex !important;
        flex: 0 0 16px;
        align-items: center;
        justify-content: center;
        color: #94a3b8;
        font-size: 13px;
      }

      body.page-scrape .filter-search-box input {
        flex: 1 1 auto;
        width: auto;
        min-width: 0;
        height: 40px;
        min-height: 40px;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0;
        background: transparent !important;
        box-shadow: none !important;
        color: #0f172a;
        font-size: 14px;
        line-height: 40px;
      }

      body.page-scrape .filter-search-box input::placeholder {
        color: #94a3b8;
        font-weight: 400;
      }

      body.page-scrape .filter-search-clear {
        flex: 0 0 auto;
        width: 28px;
        height: 28px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0;
        border: 0;
        border-radius: 8px;
        background: transparent;
        color: #94a3b8;
        cursor: pointer;
        transition: background .16s, color .16s;
      }

      body.page-scrape .filter-search-clear:hover {
        background: #e2e8f0;
        color: #334155;
      }

      body.page-scrape .filter-search .btn.filter-search-btn {
        width: auto;
        min-width: 88px;
        height: 42px;
        min-height: 42px;
        padding: 0 18px;
        border: 1px solid var(--scrape-blue);
        border-radius: 8px;
        background: var(--scrape-blue);
        color: #fff;
        font-size: 14px;
        font-weight: 750;
        line-height: 1;
        box-shadow: 0 1px 2px rgba(22, 119, 255, .18);
      }

      body.page-scrape .filter-search .btn.filter-search-btn:hover {
        border-color: var(--scrape-blue-dark);
        background: var(--scrape-blue-dark);
        transform: none;
        box-shadow: 0 2px 6px rgba(22, 119, 255, .22);
      }

      body.page-scrape .filter-search .btn.filter-reset-btn {
        width: auto;
        min-width: 86px;
        height: 42px;
        min-height: 42px;
        padding: 0 14px;
        border-color: var(--scrape-input-border);
        border-radius: 8px;
        background: #fff;
        color: #475569;
        font-size: 14px;
        font-weight: 700;
        line-height: 1;
        box-shadow: none;
      }

      body.page-scrape .filter-search .btn.filter-reset-btn .fas {
        font-size: 12px;
      }

      body.page-scrape .filter-search .btn.filter-reset-btn:hover {
        border-color: #cbd5e1;
        background: #f8fafc;
        color: #0f172a;
        transform: none;
      }

      body.page-scrape .filter-block-sales,
      body.page-scrape .filter-block-date {
        width: 100%;
      }

      /* ⚠️ 2026-10-20：这套 8 列规则位于文件靠后位置，会覆盖 124 行那条（同权重、后出现者胜）。
         原来每列的最小宽度是 130/130/140/150/175/210/210/250 = 1395px，
         加 filter-shell 左右 padding 36px + 7 个间距 84px = 1515px。
         1440px 视口下容器只有 1404px ⇒ 撑出 72px，右侧「重置」和「采集日期」跑到屏幕外。
         为什么窄屏测不出来：1320px 以下命中了 repeat(4/2, minmax(0,1fr)) 的断点，
         8 列只在 >1320px 生效 —— 属于「大屏才溢出」，只有真在 1440 宽度下量才会发现。
         修法：下限一律压到 0，只保留 fr 比例（宽屏视觉比例不变）。
         实测（CDP，视口 1440）：修复前 docScrollW=1512（溢出 72）→ 修复后 1440（溢出 0）。 */
      body.page-scrape .filter-grid.filter-grid-one-line {
        width: 100%;
        display: grid !important;
        grid-template-columns:
          minmax(0, .68fr)
          minmax(0, .68fr)
          minmax(0, .72fr)
          minmax(0, .8fr)
          minmax(0, .95fr)
          minmax(0, 1.08fr)
          minmax(0, 1.08fr)
          minmax(0, 1.25fr);
        grid-template-areas: "group platform moq store biz price sales date";
        gap: 12px !important;
        align-items: end !important;
        min-width: 0;
      }

      /* 同上（9 列版）：最小宽度合计 120+140+130+140+150+175+200+200+240 = 1495px，更容易溢出。 */
      body.page-scrape .filter-grid.filter-grid-one-line.has-collector-filter {
        grid-template-columns:
          minmax(0, .62fr)
          minmax(0, .72fr)
          minmax(0, .66fr)
          minmax(0, .72fr)
          minmax(0, .8fr)
          minmax(0, .95fr)
          minmax(0, 1.02fr)
          minmax(0, 1.02fr)
          minmax(0, 1.18fr);
        grid-template-areas: "group collector platform moq store biz price sales date";
        min-width: 0;
      }

      body.page-scrape .filter-block {
        min-width: 0;
        display: grid;
        gap: 6px;
      }

      body.page-scrape .filter-block label {
        margin: 0;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 750;
        line-height: 1.2;
      }

      body.page-scrape .filter-block input,
      body.page-scrape .filter-block select {
        width: 100%;
        height: 40px;
        min-height: 40px;
        border-color: var(--scrape-input-border);
        border-radius: 8px;
        background-color: #fff;
      }

      body.page-scrape .page-size-select,
      body.page-scrape .page-jump-input {
        height: 40px;
        min-height: 40px;
        border-color: var(--scrape-input-border);
        border-radius: 10px;
      }

      body.page-scrape .filter-status-tabs {
        margin-top: 16px !important;
      }

      body.page-scrape .filter-range {
        width: 100%;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 12px minmax(0, 1fr);
        gap: 8px;
        align-items: center;
      }

      body.page-scrape .filter-range span {
        color: #94a3b8;
        text-align: center;
        line-height: 40px;
      }

      body.page-scrape .tabs-box {
        max-width: 100%;
        gap: 5px;
        padding: 5px;
        overflow: auto;
        border-color: var(--scrape-line);
        box-shadow: var(--scrape-shadow);
        scrollbar-width: none;
      }

      body.page-scrape .tabs-box::-webkit-scrollbar {
        display: none;
      }

      body.page-scrape .tabs-box .tab {
        height: 36px;
        padding: 0 17px;
        color: var(--scrape-muted);
        font-weight: 760;
      }

      body.page-scrape .tabs-box .tab.active {
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
      }

      body.page-scrape .table-card {
        margin-top: 0 !important;
        border-color: var(--scrape-line);
        border-radius: 18px;
        box-shadow: var(--scrape-shadow);
        contain: layout style;
      }

      body.page-scrape .td-stock {
        text-align: center !important;
      }

      body.page-scrape .td-sku {
        padding-left: 8px;
        padding-right: 8px;
        text-align: center !important;
      }

      body.page-scrape .td-stock .cat-row {
        justify-content: center;
        text-align: center;
        margin-bottom: 7px;
      }

      body.page-scrape .td-stock .cat-name,
      body.page-scrape .td-stock .cat-missing {
        max-width: 150px;
      }

      body.page-scrape .td-stock .cell-stock-line {
        justify-content: center;
        text-align: center;
      }

      body.page-scrape .td-stock .cell-dims-line {
        color: #64748b;
        font-weight: 650;
      }

      body.page-scrape .td-stock .cell-dims {
        color: #64748b;
      }

      body.page-scrape .board-table {
        font-size: 13px;
      }

      body.page-scrape .board-table th {
        height: 48px;
        background: var(--scrape-card-soft);
        border-bottom-color: var(--scrape-line);
        color: var(--scrape-muted);
        font-weight: 700;
      }

      body.page-scrape .board-table td {
        padding-top: 14px;
        padding-bottom: 14px;
      }

      body.page-scrape .board-table tbody tr:last-child td {
        border-bottom: 0;
      }

      body.page-scrape .product-row:hover td {
        background: #fbfcff;
      }

      body.page-scrape .product-thumb {
        width: 72px;
        height: 72px;
        border-color: var(--scrape-input-border);
        border-radius: 13px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape .product-title {
        color: var(--scrape-ink);
        font-size: 14px;
        font-weight: 760;
      }

      body.page-scrape .source-id,
      body.page-scrape .source-min-order-badge,
      body.page-scrape .scraper-badge,
      body.page-scrape .group-badge,
      body.page-scrape .group-empty {
        display: inline-flex;
        align-items: center;
        min-height: 23px;
        padding: 2px 8px;
        border: 1px solid #e2e8f0;
        border-radius: var(--scrape-radius-pill);
        background: #f8fafc;
        color: var(--scrape-label);
        font-size: 11px;
        font-weight: 700;
      }

      body.page-scrape .source-min-order-badge.is-warning {
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape .source-min-order-badge.is-danger {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .group-badge {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        border-color: #dbeafe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .sku-attr {
        box-sizing: border-box;
        width: 124px;
        max-width: 100%;
        min-width: 0;
        min-height: 78px;
        margin: 0 auto;
        border-color: #dbeafe;
        border-radius: 12px;
        background: #f7faff;
      }

      body.page-scrape .sku-attr.is-all-in {
        border-color: #bbf7d0;
        background: #f0fdf4;
      }

      body.page-scrape .sku-attr.is-empty,
      body.page-scrape .sku-attr.is-unknown {
        border-color: #e2e8f0;
        background: #f8fafc;
      }

      body.page-scrape .cat-meta,
      body.page-scrape .stock-warning,
      body.page-scrape .stock-pending,
      body.page-scrape .stock-synced,
      body.page-scrape .stock-exhausted {
        display: inline-flex;
        align-items: center;
        min-height: 23px;
        padding: 2px 8px;
        border-radius: var(--scrape-radius-pill);
        font-size: 11px;
        line-height: 1.3;
        font-weight: 700;
      }

      body.page-scrape .cat-meta-pending,
      body.page-scrape .stock-pending {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .stock-synced {
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape .stock-exhausted {
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .stock-box {
        display: grid;
        gap: 4px;
        padding: 9px 10px;
        border: 1px solid #dbeafe;
        border-radius: 12px;
        background: #f7faff;
        color: #334155;
        text-align: left;
      }

      body.page-scrape .stock-line,
      body.page-scrape .store-published,
      body.page-scrape .price-source,
      body.page-scrape .price-pending,
      body.page-scrape .sales-empty {
        color: var(--scrape-muted);
        font-size: 11px;
        line-height: 1.4;
      }

      body.page-scrape .store-published {
        max-width: 100%;
        margin-top: 6px;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      body.page-scrape .store-publish-target {
        display: inline-flex;
        max-width: 100%;
        margin-top: 6px;
        padding: 2px 7px;
        border-radius: var(--scrape-radius-pill);
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 11px;
        line-height: 1.4;
        font-weight: 700;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      body.page-scrape .store-publish-target.is-unknown {
        background: #f1f5f9;
        color: #64748b;
      }

      body.page-scrape .status-badge {
        border: 1px solid transparent;
        font-weight: 760;
      }

      body.page-scrape .status-pending {
        border-color: #bfdbfe;
      }

      body.page-scrape .status-publishing {
        border-color: #fed7aa;
      }

      body.page-scrape .status-failed {
        border-color: #fecaca;
      }

      body.page-scrape .publish-error-info {
        max-width: 100%;
        font-size: 12px;
      }

      body.page-scrape .status-published {
        border-color: #a7f3d0;
      }

      body.page-scrape .action-btn-group {
        gap: 6px;
      }

      body.page-scrape .action-btn {
        height: 32px;
        min-height: 32px;
        border-radius: 9px;
        font-weight: 700;
      }

      body.page-scrape .action-btn.is-secondary {
        background: #fff;
        color: #334155;
      }

      body.page-scrape .action-btn.is-warning {
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape .table-footer {
        padding: 16px 18px;
        border-top-color: var(--scrape-line);
      }

      body.page-scrape .table-footer-left,
      body.page-scrape .table-pagination,
      body.page-scrape .page-jumper {
        flex-wrap: wrap;
      }

      body.page-scrape .erp-empty-state {
        min-height: 180px;
        display: grid;
        place-items: center;
        padding: 28px;
        background: #fff;
        color: var(--scrape-muted);
        font-size: 14px;
      }

      body.page-scrape input[type="checkbox"],
      body.page-scrape input[type="radio"] {
        accent-color: var(--scrape-blue);
      }

      body.page-scrape .img-preview-modal {
        background: rgba(15, 23, 42, .72);
      }

      body.page-scrape .img-preview-modal img {
        border: 1px solid rgba(255, 255, 255, .36);
        border-radius: 18px;
        box-shadow: 0 24px 70px rgba(15, 23, 42, .36);
      }

      body.page-scrape #globalModal.modal-overlay {
        background: rgba(15, 23, 42, .34);
      }

      body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal .modal-container {
        max-height: min(92vh, 980px);
        border: 1px solid #dfe4ec;
        border-radius: 20px;
        box-shadow: 0 24px 70px rgba(15, 23, 42, .18), 0 8px 22px rgba(15, 23, 42, .08);
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-header {
        flex-basis: auto;
        min-height: 68px;
        padding: 14px 26px;
        border-bottom-color: #e8ebf1;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-title {
        color: var(--scrape-ink);
        font-size: 19px;
        line-height: 1.25;
        font-weight: 760;
        letter-spacing: 0;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-title small {
        margin-top: 4px;
        color: var(--scrape-muted);
        font-weight: 500;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-close {
        width: 36px;
        height: 36px;
        border-radius: 10px;
        background: #f4f6fa;
        color: var(--scrape-label);
      }

      body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal .modal-body {
        padding: 20px 24px;
        background: var(--scrape-bg);
        color: #0f172a;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-footer-bar {
        gap: 10px;
        padding: 15px 26px;
        border-top-color: #e8ebf1;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-body > * + * {
        margin-top: 14px;
      }

      body.page-scrape #globalModal.erp-simple-modal .input,
      body.page-scrape #globalModal.erp-simple-modal select {
        min-height: 40px;
        height: 40px;
        border-color: var(--scrape-input-border);
        border-radius: 10px;
      }

      body.page-scrape #globalModal.erp-simple-modal textarea.input {
        min-height: 112px;
        height: auto;
      }

      body.page-scrape #globalModal.erp-simple-modal .btn {
        min-height: 38px;
        border-radius: 10px;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-cancel-btn,
      body.page-scrape #globalModal.erp-simple-modal #modalSaveBtn {
        height: 40px;
        min-height: 40px;
        border-radius: var(--scrape-radius-pill);
        font-size: 14px;
      }

      body.page-scrape #globalModal.erp-simple-modal .modal-cancel-btn {
        min-width: 82px;
        border-color: #d5dbe5;
        background: #fff;
        color: #334155;
      }

      body.page-scrape #globalModal.erp-simple-modal #modalSaveBtn {
        min-width: 112px;
        padding: 0 24px;
        font-weight: 760;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
      }

      body.page-scrape .scrape-field-title,
      body.page-scrape .action-label,
      body.page-scrape .logistics-label {
        display: block;
        margin-bottom: 7px;
        color: var(--scrape-label);
        font-size: 12px;
        line-height: 1.35;
        font-weight: 700;
      }

      body.page-scrape .scrape-field-title.is-spaced {
        margin-top: 14px;
      }

      body.page-scrape .scrape-inline-row {
        display: flex;
        align-items: center;
        gap: 9px;
      }

      body.page-scrape .scrape-flex-input {
        flex: 1 1 auto;
        min-width: 0;
      }

      body.page-scrape .scrape-select-tall {
        min-height: 210px !important;
        height: 210px !important;
        padding: 8px;
      }

      body.page-scrape .logistics-dim-row {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 12px;
        padding: 14px;
        border-radius: 14px;
        background: #fff;
        border: 1px solid var(--scrape-line);
      }

      body.page-scrape .logistics-weight {
        padding: 14px;
        border-radius: 14px;
        background: #fff;
        border: 1px solid var(--scrape-line);
      }

      body.page-scrape .logistics-label.is-required {
        color: #b91c1c;
      }

      body.page-scrape .action-select-shell,
      body.page-scrape .action-field {
        display: grid;
        gap: 8px;
      }

      body.page-scrape .action-tip,
      body.page-scrape .action-note,
      body.page-scrape .action-progress,
      body.page-scrape .action-error-list {
        padding: 12px 14px;
        border: 1px solid #dbeafe;
        border-radius: 13px;
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
        line-height: 1.5;
      }

      body.page-scrape .action-tip.is-warning,
      body.page-scrape .action-note {
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape .action-tip.is-danger,
      body.page-scrape .action-error-list {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .action-tip.is-primary {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .action-help {
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.42;
      }

      body.page-scrape .action-help.is-block {
        margin-bottom: 2px;
      }

      body.page-scrape .action-textarea {
        min-height: 132px !important;
      }

      body.page-scrape .action-progress-text {
        display: flex;
        align-items: center;
        gap: 7px;
      }

      body.page-scrape .action-result {
        display: grid;
        gap: 10px;
      }

      body.page-scrape .action-result-card {
        padding: 13px 14px;
        border: 1px solid #bbf7d0;
        border-radius: 13px;
        background: #f0fdf4;
        color: #166534;
      }

      body.page-scrape .action-result-card.is-error {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .action-result-title {
        margin-bottom: 5px;
        font-size: 13px;
        font-weight: 760;
      }

      body.page-scrape .action-result-body {
        font-size: 12px;
        line-height: 1.5;
      }

      body.page-scrape .scrape-group-shell {
        display: grid;
        gap: 12px;
      }

      body.page-scrape .scrape-group-title {
        color: var(--scrape-ink);
        font-size: 15px;
        font-weight: 760;
      }

      body.page-scrape .scrape-group-card,
      body.page-scrape .scrape-group-remove-panel {
        display: grid;
        gap: 10px;
        padding: 14px;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
      }

      body.page-scrape .scrape-group-state {
        padding: 10px 12px;
        border-radius: 11px;
        background: var(--scrape-card-soft);
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape .scrape-group-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) 42px;
        gap: 8px;
      }

      body.page-scrape .scrape-group-delete-btn {
        width: 42px;
        padding: 0;
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .scrape-group-remove-btn {
        justify-content: flex-start;
        min-height: 42px !important;
        border-color: #fde68a;
        background: #fffbeb;
        color: #92400e;
      }

      body.page-scrape .template-shell {
        display: grid;
        gap: 13px;
      }

      body.page-scrape .template-toolbar {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
        padding: 13px;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
      }

      body.page-scrape .template-toolbar-label {
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape .template-select {
        flex: 1 1 180px;
        min-width: 0;
      }

      body.page-scrape .template-save-btn {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .template-delete-btn {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .template-price-row,
      body.page-scrape .template-option-row {
        display: flex;
        align-items: center;
        gap: 9px;
        flex-wrap: wrap;
        padding: 13px 14px;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
      }

      body.page-scrape .template-price-row.is-spaced {
        align-items: flex-start;
      }

      body.page-scrape .template-price-label,
      body.page-scrape .template-option-label {
        color: #334155;
        font-size: 13px;
        font-weight: 760;
      }

      body.page-scrape .template-formula {
        display: flex;
        align-items: center;
        gap: 8px;
        flex: 1 1 360px;
        flex-wrap: wrap;
      }

      body.page-scrape .template-chip,
      body.page-scrape .template-addon-label {
        display: inline-flex;
        align-items: center;
        min-height: 32px;
        padding: 0 9px;
        border-radius: 9px;
        background: var(--scrape-card-soft);
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape .template-operator {
        color: var(--scrape-muted);
        font-size: 14px;
        font-weight: 760;
      }

      body.page-scrape .template-input-addon {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        min-width: 0;
      }

      body.page-scrape .template-number-sm {
        width: 88px;
      }

      body.page-scrape .template-number-xs {
        width: 82px;
      }

      body.page-scrape .template-flex-input {
        flex: 1 1 180px;
        min-width: 0;
      }

      body.page-scrape .template-radio {
        display: inline-flex;
        align-items: center;
        gap: 0;
        min-height: 34px;
        padding: 0 12px;
        border: 1px solid var(--scrape-input-border);
        border-radius: var(--scrape-radius-pill);
        background: #fff;
        color: var(--scrape-label);
        cursor: pointer;
      }
      body.page-scrape .template-radio input[type="radio"] {
        display: none;
      }

      body.page-scrape .template-formula.is-muted,
      body.page-scrape .template-input-addon.is-muted {
        opacity: .58;
      }

      body.page-scrape .image-tools-shell {
        display: grid;
        grid-template-rows: auto minmax(0, 1fr);
        /* 2026-10-23 十五轮（用户截图确认：带子在「四个 tab 按钮」与「SKU 图标题」之间）：
           这里原来是 gap: 10px，加上另一条同选择器的 gap: 0px 规则，
           两处间隙都露出弹窗灰底 #f3f6f9，形成一条明显的灰带。
           CDP 实测 content.top - modes.bottom = 14px，归零后 = 0px。 */
        gap: 0;
        height: 100%;
        min-height: 0;
      }

      body.page-scrape .image-tools-modes {
        display: inline-flex;
        width: fit-content;
        gap: 6px;
        padding: 4px;
        border: 1px solid var(--scrape-line);
        border-radius: 8px;
        background: #fff;
      }

      body.page-scrape .image-tools-mode {
        height: 32px;
        padding: 0 16px;
        border: 0;
        border-radius: 6px;
        background: transparent;
        color: var(--scrape-muted);
        font-size: 13px;
        font-weight: 800;
        cursor: pointer;
      }

      body.page-scrape .image-tools-mode.active {
        background: var(--scrape-blue);
        color: #fff;
      }

      /* 2026-10-23：这条原来写 overflow-y: auto（把 content 当滚动容器）。
         滚动容器已经定在 .image-tools-settings-column（中间列自己滚），
         这里改成 overflow-y: hidden 保持一致 —— 否则源码里两条规则打架，
         测试 100 会读到这条的 auto 而误判。 */
      body.page-scrape .image-tools-content {
        min-height: 0;
        overflow-y: hidden;
        padding-right: 3px;
      }

      body.page-scrape #imageToolsModal[data-active-image-tool-tab="watermark"] .image-tools-content {
        overflow: hidden;
        padding-right: 0;
      }

      body.page-scrape .image-tools-panel {
        display: none;
        min-height: 100%;
      }

      body.page-scrape .image-tools-panel.active {
        display: block;
      }

      body.page-scrape .white-bg-panel {
        display: grid;
        gap: 12px;
        height: 100%;
      }

      body.page-scrape .white-bg-topbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 14px;
        border: 1px solid var(--scrape-line);
        border-radius: 14px;
        background: #fff;
      }

      body.page-scrape .white-bg-title {
        color: var(--scrape-ink);
        font-size: 14px;
        font-weight: 850;
      }

      body.page-scrape .white-bg-subtitle {
        margin-top: 4px;
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape .white-bg-progress {
        min-width: 72px;
        min-height: 30px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0 10px;
        border: 1px solid #dbeafe;
        border-radius: var(--scrape-radius-pill);
        background: #eff6ff;
        color: #1d4ed8;
        font-size: 12px;
        font-weight: 850;
      }

      body.page-scrape .white-bg-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: wrap;
        padding: 10px;
        border: 1px solid var(--scrape-line);
        border-radius: 8px;
        background: #fff;
      }

      body.page-scrape #whiteBgGenerateBtn.is-loading::before {
        content: '';
        width: 13px;
        height: 13px;
        border: 2px solid rgba(255, 255, 255, .45);
        border-top-color: #fff;
        border-radius: 50%;
        animation: white-bg-button-spin .8s linear infinite;
      }

      @keyframes white-bg-button-spin {
        to { transform: rotate(360deg); }
      }

      body.page-scrape .white-bg-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
        gap: 10px;
        max-height: 430px;
        overflow: auto;
        padding-right: 4px;
      }

      /* ===== 2026-10-12 四个 tab 左栏「选图区」统一：第一代旧卡片规则清理 =====
         删图 tab 左栏此前被 .image-delete-image-grid 的紧凑规则漏到过（见
         test/image-tools-thumbnail-grid-cascade.test.js 里的说明），修完之后四个 tab 的
         卡片其实已经都吃共用规则了，但这三块第一代规则（.white-bg-image-card /
         .ai-image-card / .watermark-image-choice）还留着互不相同的旧数值：

           旧规则（权重 0,2,1）            共用规则（权重 0,2,1，源序更靠后）
           padding: 10px / 5px        ->  .image-tools-thumbnail-card { padding: 6px }
           gap: 7px / 4px             ->  gap: 6px
           border-radius: 12px / 8px  ->  border-radius: 7px
           grid-template-rows（无）    ->  auto 24px（信息行高度）
           thumb 的 border-radius      ->  .image-tools-thumbnail { border-radius: 5px }
           勾选框 24px@9px / 20px@10px ->  18px @ top/left 8px

         同权重 → 源序靠后的共用规则全胜，所以旧数值一个都没生效；但留着就是
         「谁往前面插一条更具体的选择器，或者把顺序一动，四个 tab 就又各长一样」的地雷。
         本次把已经被共用规则完全覆盖的尺寸/外观声明删掉，四个 tab 只留共用规则一个真源。
         有意保留的：卡片选中态 / hover 的配色（各 tab 语义不同）、
         .watermark-image-choice 自己还在生效的 color / font-size / font-weight（见下方）。 */

      body.page-scrape .white-bg-image-card:has(input[type="checkbox"]:checked) {
        border-color: #60a5fa;
        background: #eff6ff;
        box-shadow: 0 0 0 2px rgba(37, 99, 235, .1);
      }

      body.page-scrape .white-bg-image-card:hover {
        border-color: #93c5fd;
      }

      /* .white-bg-thumb / .white-bg-thumb img 的尺寸与圆角（aspect-ratio 1/1、
         border-radius 10px、img object-fit: cover）与 .ai-image-thumb / .white-bg-thumb 一样
         已被共用规则 body.page-scrape .image-tools-thumbnail（aspect-ratio 1/1 /
         border-radius 5px）与 .image-tools-thumbnail img 完全接管，属于第一代遗留，已删除。
         卡片渲染时这两个 class 与 .image-tools-thumbnail 同时挂在同一个 <span> 上
         （scrape/template-tools.js 的 white-bg 卡片模板）。 */

      body.page-scrape .white-bg-image-meta {
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .white-bg-image-card.is-generated-white-bg {
        border-color: #bfdbfe;
        background: #f8fbff;
      }

      body.page-scrape .image-tools-autosave-note {
        margin-right: auto;
        color: var(--scrape-muted);
        font-size: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .edit-tab-content.active {
        gap: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-edit-card,
      body.page-scrape #globalModal.erp-edit-modal .erp-sku-card {
        padding: 15px;
        border-radius: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-card-head {
        align-items: center;
        margin-bottom: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-title-ai-card {
        display: grid;
        gap: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-title-ai-card .erp-card-head,
      body.page-scrape #globalModal.erp-edit-modal .erp-title-ai-card .erp-title-block {
        margin-bottom: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-compact-row {
        display: grid;
        grid-template-columns: minmax(190px, 1.2fr) minmax(130px, .55fr) minmax(145px, .65fr) max-content;
        align-items: end;
        gap: 9px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-smart-row {
        grid-template-columns: minmax(0, 1fr) max-content;
        align-items: center;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-smart-note {
        display: grid;
        gap: 4px;
        min-width: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-smart-title {
        color: #0f172a;
        font-size: 13px;
        font-weight: 760;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-smart-desc {
        color: var(--scrape-muted);
        font-size: 12px;
        line-height: 1.45;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-inline-actions {
        display: flex;
        align-items: center;
        gap: 7px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-result-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) max-content;
        align-items: end;
        gap: 6px 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-result-row label {
        grid-column: 1 / -1;
        margin-bottom: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-result-row .erp-help {
        max-width: 330px;
        margin: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-dimensions-row {
        padding-top: 2px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-item {
        cursor: grab;
        transition: opacity .15s, transform .15s, box-shadow .15s, border-color .15s;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-item.is-dragging {
        cursor: grabbing;
        opacity: .5;
        transform: scale(.97);
        box-shadow: 0 8px 20px rgba(15, 23, 42, .18);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-image-item.is-drop-target {
        border-color: #2563eb;
        box-shadow: inset 0 0 0 2px #2563eb, 0 4px 12px rgba(37, 99, 235, .16);
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-section {
        min-height: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-item {
        align-items: center;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-item video {
        width: min(160px, 100%);
        max-height: 220px;
        border-radius: 8px;
        background: #000;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-actions {
        flex-direction: row;
        flex-wrap: wrap;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-empty {
        width: 100%;
        flex-direction: row;
        align-items: center;
        gap: 10px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-add {
        width: 130px;
        height: 42px;
        flex: 0 0 auto;
        border-width: 1px;
        border-radius: 9px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-url-row {
        display: flex;
        align-items: center;
        gap: 8px;
        flex: 1 1 320px;
        min-width: 0;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-video-url-row .input {
        flex: 1 1 auto;
        min-width: 0;
      }

      @media (max-width: 900px) {
        body.page-scrape #globalModal.erp-edit-modal .erp-ai-compact-row {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-ai-smart-row {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-ai-inline-actions {
          flex-wrap: wrap;
        }
      }

      @media (max-width: 640px) {
        body.page-scrape #globalModal.erp-edit-modal .erp-ai-compact-row,
        body.page-scrape #globalModal.erp-edit-modal .erp-ai-result-row,
        body.page-scrape #globalModal.erp-edit-modal .erp-grid-4 {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-ai-result-row .erp-help {
          max-width: none;
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-video-empty {
          align-items: stretch;
          flex-direction: column;
        }

        body.page-scrape #globalModal.erp-edit-modal .erp-video-add {
          width: 100%;
        }
      }

      body.page-scrape .white-bg-status {
        width: fit-content;
        min-height: 24px;
        display: inline-flex;
        align-items: center;
        padding: 0 8px;
        border-radius: var(--scrape-radius-pill);
        background: #f1f5f9;
        color: #475569;
        font-size: 11px;
        font-weight: 850;
      }

      body.page-scrape .white-bg-status.is-processing {
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .white-bg-status.is-success {
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape .white-bg-status.is-failed {
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .white-bg-error {
        color: #b91c1c;
        font-size: 11px;
        line-height: 1.35;
        overflow-wrap: anywhere;
      }

      body.page-scrape .white-bg-empty {
        min-height: 360px;
        display: grid;
        align-content: center;
        justify-items: center;
        gap: 12px;
        padding: 28px;
        border: 1px dashed var(--scrape-line);
        border-radius: 14px;
        background: #fff;
        color: var(--scrape-muted);
        text-align: center;
        font-size: 13px;
      }

      body.page-scrape .ai-image-status {
        min-height: 38px;
        display: flex;
        align-items: center;
        padding: 9px 12px;
        border: 1px solid var(--scrape-line);
        border-radius: 8px;
        background: #f8fafc;
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape .ai-image-status.is-loading {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape .ai-image-status.is-success {
        border-color: #bbf7d0;
        background: #f0fdf4;
        color: #047857;
      }

      body.page-scrape .ai-image-status.is-error {
        border-color: #fecaca;
        background: #fef2f2;
        color: #b91c1c;
      }

      body.page-scrape .ai-image-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
        gap: 10px;
        max-height: 405px;
        overflow: auto;
        padding-right: 4px;
      }

      /* .ai-image-card 的 position/display/gap 7px/padding 10px/border/border-radius 8px/
         background/cursor 已被共用规则 body.page-scrape .image-tools-thumbnail-card
         （gap 6px / padding 6px / border-radius 7px）完全覆盖，第一代遗留，已删除。
         卡片渲染时 .ai-image-card 与 .image-tools-thumbnail-card 同时挂在同一个 <label> 上
         （scrape/template-tools.js 的 AI 生图三组卡片模板）。 */

      body.page-scrape .ai-image-card:hover,
      body.page-scrape .ai-image-card.is-selected {
        border-color: #60a5fa;
      }

      body.page-scrape .ai-image-card.is-selected {
        background: #eff6ff;
        box-shadow: 0 0 0 2px rgba(37, 99, 235, .1);
      }

      /* 这里原来有一条 body.page-scrape .ai-image-card input[type="radio"]（20px @ top/left 10px）。
         AI 生图 tab 已经从单选改成多选，卡片里的控件是 <input type="checkbox">，
         所以那条规则根本不再匹配任何元素 —— 结果是 AI 生图的勾选框一条样式都没吃到，
         只能退回 body.page-scrape input 的 height: 34px / padding: 0 11px，并且因为
         position 不是 absolute 而留在网格流里，把卡片顶成了三行（勾选框占掉一行），
         这正是运营看到的「AI 生图的卡片明显更高、缩略图上方留白更多」。
         现在四个 tab 的勾选框统一由文件后段的一条共用规则接管（18px @ top/left 8px），
         这条 radio 规则已删除。 */

      /* .ai-image-thumb / .ai-image-thumb img 同 .white-bg-thumb：尺寸与圆角已被共用规则
         body.page-scrape .image-tools-thumbnail / .image-tools-thumbnail img 完全接管，已删除。 */

      body.page-scrape .ai-image-card-label {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 6px;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 800;
      }

      body.page-scrape .ai-image-card-type {
        flex: 0 0 auto;
        padding: 2px 6px;
        border-radius: 4px;
        background: #f1f5f9;
        color: #64748b;
        font-size: 11px;
        font-weight: 700;
      }

      body.page-scrape .ai-image-card.is-generated .ai-image-card-type {
        background: #ecfdf5;
        color: #047857;
      }

      body.page-scrape .erp-image-tools-btn {
        flex: 0 0 auto;
        white-space: nowrap;
      }

      body.page-scrape .watermark-selected-note {
        padding: 12px 14px;
        border: 1px solid #bbf7d0;
        border-radius: 13px;
        background: #f0fdf4;
        color: #166534;
        font-size: 13px;
        font-weight: 700;
      }

      body.page-scrape .watermark-shell {
        display: grid;
        gap: 12px;
      }

      body.page-scrape .watermark-image-list {
        display: grid;
        grid-template-columns: repeat(auto-fill, 64px);
        gap: 8px;
        overflow: visible;
        padding: 1px;
      }

      /* position/display/gap 4px/padding 5px/border/border-radius 7px/background/cursor 同样
         已被共用规则 body.page-scrape .image-tools-thumbnail-card 覆盖，第一代遗留，已删除。
         只有 color / font-size / font-weight 没有被共用规则声明，仍在这里生效：
         卡片内所有文字都在 .image-tools-thumbnail-meta 里，而它自带 color #475569 /
         font-size 11px / font-weight 800，所以这三个值实际不产生可见差异，
         但删掉会改变计算样式，本次按「只删已被覆盖的尺寸声明」处理，原样保留。 */
      body.page-scrape .watermark-image-choice {
        color: var(--scrape-label);
        font-size: 11px;
        font-weight: 700;
      }

      body.page-scrape .watermark-image-choice.is-selected {
        border-color: #60a5fa;
        background: #eff6ff;
      }

      /* .watermark-image-choice input（18px @ top/left 8px，z-index 1）与
         .watermark-image-choice img（52px 方图）都已由文件后段的共用勾选框规则
         与共用缩略图规则接管，第一代遗留，已删除。 */

      body.page-scrape .watermark-apply-btn {
        width: 100%;
        justify-content: center;
      }

      body.page-scrape .watermark-live-canvas {
        position: relative;
        width: min(100%, 238px);
        aspect-ratio: 3 / 4;
        margin: 0 auto;
        overflow: hidden;
        border: 1px solid var(--scrape-input-border);
        border-radius: 16px;
        background: var(--scrape-card-soft);
      }

      body.page-scrape .watermark-live-image-wrap,
      body.page-scrape .watermark-live-image,
      body.page-scrape .watermark-live-border {
        position: absolute;
        inset: 0;
      }

      body.page-scrape .watermark-live-image-wrap {
        display: grid;
        place-items: center;
        overflow: hidden;
      }

      body.page-scrape .watermark-live-image {
        display: grid;
        place-items: center;
        background: #f8fafc;
        color: #94a3b8;
        font-size: 13px;
        transform-origin: center;
      }

      body.page-scrape .watermark-live-image img {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: contain;
      }

      body.page-scrape .watermark-live-border {
        z-index: 1;
        pointer-events: none;
      }

      body.page-scrape .watermark-live-text {
        position: absolute;
        z-index: 2;
        max-width: 80%;
        overflow-wrap: anywhere;
        font-weight: 800;
        line-height: 1.15;
        text-shadow: 0 1px 2px rgba(255, 255, 255, .36);
        pointer-events: none;
      }

      body.page-scrape .queue-status-shell,
      body.page-scrape .stock-modal-shell,
      body.page-scrape .stats-loading-shell {
        gap: 14px;
      }

      body.page-scrape .queue-status-card,
      body.page-scrape .queue-metric-card,
      body.page-scrape .stats-card,
      body.page-scrape .stock-toolbar,
      body.page-scrape .stock-bulk-panel,
      body.page-scrape .stats-loading {
        border-radius: 14px;
        box-shadow: var(--scrape-shadow);
      }

      body.page-scrape .queue-status-card {
        padding: 15px 16px;
      }

      body.page-scrape .queue-section,
      body.page-scrape .queue-warning-panel,
      body.page-scrape .quota-table-wrap,
      body.page-scrape .stats-table-wrap,
      body.page-scrape .warehouse-list {
        border-color: var(--scrape-line);
        border-radius: 14px;
      }

      body.page-scrape .stock-bulk-panel {
        border-color: #dbeafe;
        background: #f7faff;
      }

      body.page-scrape .stock-form-control {
        min-height: 40px;
        height: 40px;
        border-radius: 10px;
      }

      body.page-scrape .warehouse-empty,
      body.page-scrape .queue-empty {
        padding: 18px;
        color: var(--scrape-muted);
        text-align: center;
        font-size: 12px;
      }

      @media (max-width: 1320px) {
        body.page-scrape .filter-grid.filter-grid-one-line {
          grid-template-columns: repeat(4, minmax(0, 1fr));
          grid-template-areas:
            "group platform moq store"
            "biz price sales date";
        }

        body.page-scrape .filter-grid.filter-grid-one-line.has-collector-filter {
          grid-template-areas:
            "group collector platform moq"
            "store biz price sales"
            "date date date date";
        }
      }

	      @media (max-width: 1180px) {
	        body.page-scrape .erp-row-top {
	          grid-template-columns: repeat(2, minmax(0, 1fr));
	        }

        body.page-scrape .filter-grid.filter-grid-one-line {
          grid-template-columns: repeat(2, minmax(0, 1fr));
          grid-template-areas:
            "group platform"
            "moq store"
            "biz price"
            "sales date";
        }

        body.page-scrape .filter-grid.filter-grid-one-line.has-collector-filter {
          grid-template-areas:
            "group collector"
            "platform moq"
            "store biz"
            "price sales"
            "date date";
        }

        body.page-scrape .filter-block-sales,
        body.page-scrape .filter-block-date {
          width: 100%;
        }

        body.page-scrape .watermark-layout {
          grid-template-columns: minmax(0, 1fr) 230px;
        }

        body.page-scrape .watermark-setup-row {
          grid-template-columns: minmax(0, 1fr) minmax(330px, .7fr);
        }

        body.page-scrape .white-bg-grid {
          max-height: 380px;
        }
      }

      @media (max-width: 820px) {
        body.page-scrape .erp-main {
          padding: 14px 12px 72px !important;
        }

        body.page-scrape .filter-shell {
          padding: 12px !important;
          border-radius: 8px !important;
        }

	        body.page-scrape .erp-row-top {
	          padding: 0 !important;
	          grid-template-columns: minmax(0, 1fr);
	        }

        body.page-scrape .action-module,
        body.page-scrape .action-module:nth-child(n) {
          flex-basis: 100%;
          min-width: 0;
        }

        body.page-scrape .filter-grid.filter-grid-one-line {
          grid-template-columns: repeat(2, minmax(0, 1fr));
          grid-template-areas:
            "group platform"
            "moq store"
            "biz price"
            "sales date";
        }

        body.page-scrape .filter-grid.filter-grid-one-line.has-collector-filter {
          grid-template-areas:
            "group collector"
            "platform moq"
            "store biz"
            "price sales"
            "date date";
        }

        body.page-scrape .filter-block {
          width: 100% !important;
        }

        body.page-scrape .filter-head {
          align-items: flex-start;
          flex-direction: column;
          gap: 8px;
        }

        body.page-scrape .filter-summary {
          width: 100%;
          white-space: normal;
        }

        body.page-scrape .filter-search {
          grid-template-columns: minmax(0, 1fr) minmax(0, auto) minmax(0, auto);
        }

        body.page-scrape .filter-search .btn.filter-reset-btn,
        body.page-scrape .filter-search .btn.filter-search-btn {
          padding-left: 14px;
          padding-right: 14px;
        }

        body.page-scrape .scrape-inline-row {
          flex-wrap: wrap;
        }

        body.page-scrape #imageToolsModal.modal-overlay {
          padding: 12px;
        }

        body.page-scrape #imageToolsModal .modal-container {
          width: calc(100vw - 24px) !important;
          max-width: calc(100vw - 24px);
          height: calc(100vh - 24px);
          max-height: calc(100vh - 24px);
        }

        body.page-scrape #globalModal.erp-modal-scope.erp-simple-modal .modal-body {
          padding: 14px;
        }

        body.page-scrape #globalModal.erp-simple-modal .modal-header,
        body.page-scrape #globalModal.erp-simple-modal .modal-footer-bar {
          padding-left: 16px;
          padding-right: 16px;
        }

        body.page-scrape .logistics-dim-row,
        body.page-scrape .stock-form-row,
        body.page-scrape .queue-metric-grid,
        body.page-scrape .stats-grid,
        body.page-scrape .white-bg-grid,
        body.page-scrape .ai-image-grid {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape .image-tools-shell {
          height: 100%;
          min-height: 0;
        }

        body.page-scrape .image-tools-modes {
          width: 100%;
          display: grid;
          grid-template-columns: repeat(4, minmax(0, 1fr));
          overflow: hidden;
        }

        body.page-scrape .image-tools-mode {
          min-width: 0;
          padding: 0 8px;
        }

        body.page-scrape #imageToolsModal[data-active-image-tool-tab="watermark"] .image-tools-content {
          overflow-y: auto;
        }

        body.page-scrape .image-tools-panel {
          min-height: 500px;
        }

        body.page-scrape .white-bg-topbar,
        body.page-scrape .white-bg-actions {
          align-items: stretch;
          flex-direction: column;
        }

        body.page-scrape .template-price-row,
        body.page-scrape .template-option-row,
        body.page-scrape .template-formula {
          align-items: stretch;
          flex-direction: column;
        }

        body.page-scrape .template-number-sm,
        body.page-scrape .template-number-xs,
        body.page-scrape .template-flex-input,
        body.page-scrape .template-input-addon {
          width: 100%;
        }

        body.page-scrape .template-input-addon {
          align-items: stretch;
          flex-direction: column;
        }
      }

      @media (max-width: 620px) {
        body.page-scrape .filter-search {
          grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
          gap: 8px;
        }

        body.page-scrape .filter-search-box {
          grid-column: 1 / -1;
        }

        body.page-scrape .filter-search .btn.filter-reset-btn,
        body.page-scrape .filter-search .btn.filter-search-btn {
          width: 100%;
        }

        body.page-scrape .filter-grid.filter-grid-one-line {
          grid-template-columns: minmax(0, 1fr);
          grid-template-areas:
            "group"
            "platform"
            "moq"
            "store"
            "biz"
            "price"
            "sales"
            "date";
        }
      }

      @media (max-width: 560px) {
        body.page-scrape .erp-row-top {
          grid-template-columns: minmax(0, 1fr);
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-action-row {
          align-items: stretch;
        }
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-price-template-actions {
          grid-template-columns: minmax(0, 1fr);
        }
      }

      /* AI 翻译模板：统一企业后台样式 */
      body.page-scrape .ai-template-modal-shell {
        display: grid;
        gap: 0px;
        min-width: 0;
      }

      body.page-scrape .ai-template-run-panel,
      body.page-scrape .ai-template-settings-panel {
        min-width: 0;
        padding: 16px;
        border: 1px solid var(--scrape-line);
        border-radius: 10px;
        background: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .03);
      }

      body.page-scrape .ai-template-run-panel {
        gap: 12px;
        background: #fbfdff;
      }

      body.page-scrape .ai-template-settings-panel {
        display: grid;
        gap: 12px;
      }

      body.page-scrape .ai-template-settings-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 12px;
        min-width: 0;
      }

      body.page-scrape .ai-template-section-title {
        line-height: 1.25;
      }

      body.page-scrape .ai-template-help {
        color: var(--scrape-muted);
        font-size: 12px;
        font-weight: 500;
        line-height: 1.45;
      }

      body.page-scrape .ai-template-settings-grid {
        display: grid;
        grid-template-columns: minmax(180px, 1fr) minmax(220px, 1.2fr) minmax(130px, .58fr);
        gap: 14px;
        align-items: end;
      }

      body.page-scrape .ai-template-field {
        display: grid;
        gap: 6px;
        min-width: 0;
        margin: 0;
      }

      body.page-scrape .ai-template-field .wiz-ai-confirm-label {
        min-width: 0;
        padding-top: 0;
        color: var(--scrape-label);
        font-size: 12px;
        font-weight: 750;
      }

      body.page-scrape .ai-template-field .input,
      body.page-scrape .ai-template-field select {
        width: 100%;
        min-width: 0;
        height: 34px;
      }

      body.page-scrape .ai-template-settings-textarea {
        width: 100%;
        min-height: 240px;
        max-height: min(42vh, 360px);
        padding: 11px 12px;
        border-color: var(--scrape-input-border);
        border-radius: 9px;
        background: #fff;
        color: #111827;
        font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
        font-size: 12px;
        line-height: 1.55;
        resize: vertical;
        white-space: pre-wrap;
      }

      body.page-scrape .ai-template-settings-actions {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        flex-wrap: wrap;
        gap: 8px;
      }

      body.page-scrape .ai-template-settings-actions .btn {
        min-width: 0;
        height: 34px;
        min-height: 34px;
        padding: 0 12px;
        border-radius: 8px;
        font-size: 13px;
        white-space: nowrap;
      }

      body.page-scrape .ai-template-settings-actions [data-ai-template-action="save"] {
        min-width: 0;
      }

      body.page-scrape .ai-template-settings-actions [data-ai-template-action="delete"],
      body.page-scrape .wiz-danger-btn {
        border-color: #f1c9c9;
        background: #fff;
        color: #b42318;
      }

      body.page-scrape .ai-template-settings-actions [data-ai-template-action="delete"]:hover,
      body.page-scrape .wiz-danger-btn:hover {
        border-color: #efb4b4;
        background: #fff7f7;
        color: #991b1b;
      }

      body.page-scrape .ai-template-inline-toggle {
        border-color: #cfd8e6;
        background: #fff;
        color: #1f3f6f;
        font-weight: 750;
      }

      body.page-scrape .ai-template-inline-toggle:hover {
        border-color: #b8c7dc;
        background: #f8fbff;
      }

      body.page-scrape .ai-template-run-grid {
        display: grid;
        grid-template-columns: minmax(96px, .6fr) minmax(150px, .9fr) minmax(240px, 1.5fr) minmax(130px, .65fr);
        gap: 14px 14px;
        align-items: end;
      }

      body.page-scrape .ai-template-run-grid .wiz-ai-confirm-section,
      body.page-scrape .ai-template-run-meta .wiz-ai-confirm-section {
        display: grid;
        gap: 6px;
      }

      body.page-scrape .ai-template-run-grid .wiz-ai-confirm-label,
      body.page-scrape .ai-template-run-meta .wiz-ai-confirm-label {
        min-width: 0;
        padding-top: 0;
      }

      body.page-scrape .ai-template-run-template select {
        margin-top: 6px;
      }

      body.page-scrape .ai-template-run-meta {
        display: grid;
        gap: 8px;
        padding-top: 2px;
      }

      body.page-scrape .ai-template-sample-row {
        grid-template-columns: 74px minmax(0, 1fr);
        align-items: start;
      }

      body.page-scrape .ai-template-sample-row .wiz-ai-sample-titles {
        margin-top: 0;
      }

      body.page-scrape .ai-template-sample-row .wiz-ai-sample-title {
        max-width: 100%;
      }

      body.page-scrape .wiz-ai-confirm-value select,
      body.page-scrape .wiz-ai-confirm-value input {
        width: 100%;
      }

      body.page-scrape .ai-template-settings-modal .ai-template-settings-textarea {
        min-height: 280px;
        max-height: min(46vh, 340px);
      }

      body.page-scrape .ai-template-settings-modal .ai-template-settings-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
      }

      body.page-scrape .ai-template-settings-modal .ai-template-settings-grid > :first-child {
        grid-column: span 2;
      }

      body.page-scrape #globalModal .ai-template-settings-panel .ai-template-settings-textarea {
        min-height: 240px;
        max-height: min(42vh, 360px);
      }

      body.page-scrape #globalModal .ai-template-settings-modal .ai-template-settings-textarea {
        min-height: 280px;
        max-height: min(46vh, 340px);
      }

      body.page-scrape .ai-template-settings-edit {
        margin-top: 12px;
        padding: 14px;
        border-color: #d9e3ef;
        background: #f6f8fb;
      }

      body.page-scrape .ai-template-settings-edit .ai-template-settings-textarea {
        min-height: 240px;
        max-height: min(38vh, 300px);
      }

      body.page-scrape #globalModal.erp-edit-modal .ai-template-settings-edit .ai-template-settings-textarea {
        min-height: 240px;
        max-height: min(38vh, 300px);
      }

      body.page-scrape .ai-template-settings-wizard {
        margin-top: 2px;
        padding: 14px;
        border-color: #dce5ef;
        background: #f7f9fc;
      }

      body.page-scrape .ai-template-settings-wizard .ai-template-settings-textarea {
        min-height: 220px;
        max-height: min(34vh, 280px);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-textarea {
        min-height: 220px;
        max-height: min(34vh, 280px);
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard {
        border: none;
        background: transparent;
        padding: 0 0 10px 0;
        box-shadow: none;
        min-width: 0;
        overflow: visible;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-grid > :first-child {
        grid-column: span 2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-textarea {
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-actions {
        flex-wrap: wrap;
        gap: 8px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-actions .btn {
        font-size: 13px;
        padding: 0 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-edit-card {
        border-color: #d8e3f0;
        background: #fbfcfe;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid {
        grid-template-columns: minmax(240px, 1.35fr) minmax(150px, .62fr) minmax(150px, .58fr);
        gap: 12px;
      }

      body.page-scrape #globalModal.erp-edit-modal .erp-ai-form-actions {
        margin-top: 12px;
        padding-top: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-integrated {
        gap: 10px;
        padding: 12px 18px 18px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
      }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid > :first-child {
        grid-column: span 2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions {
        justify-content: flex-end;
        align-items: end;
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-template-actions .wiz-full-btn {
        width: 100%;
        min-width: 0;
        height: 40px;
        min-height: 40px;
        padding: 0 9px;
        font-size: 13px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch {
        border: 1px solid #d5deea;
        background: #f8fafc;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch.is-on {
        border-color: #bfdbfe;
        background: #eff6ff;
        color: #1d4ed8;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-toggle-switch.is-off {
        border-color: #d5deea;
        background: #f8fafc;
        color: #64748b;
      }

      body.page-scrape #globalModal.low-price-confirm-modal .modal-body {
        padding: 0;
      }

      body.page-scrape .low-price-confirm-root {
        display: grid;
        gap: 16px;
        padding: 18px;
      }

      body.page-scrape .low-price-alert {
        padding: 14px 16px;
        border: 1px solid #f5c2c7;
        border-radius: 6px;
        background: #fff5f5;
        color: #7f1d1d;
        line-height: 1.5;
      }

      body.page-scrape .low-price-alert-title {
        margin-bottom: 4px;
        color: #991b1b;
        font-size: 16px;
        font-weight: 800;
      }

      body.page-scrape .low-price-safe-summary {
        margin-top: 6px;
        color: #475569;
      }

      body.page-scrape .low-price-product-list {
        display: grid;
        gap: 10px;
        max-height: min(56vh, 560px);
        overflow-y: auto;
        padding-right: 4px;
      }

      body.page-scrape .low-price-product {
        overflow: hidden;
        border: 1px solid #dfe5ee;
        border-radius: 6px;
        background: #fff;
      }

      body.page-scrape .low-price-product-head {
        padding: 11px 14px;
        border-bottom: 1px solid #edf0f5;
        background: #f8fafc;
      }

      body.page-scrape .low-price-product-title {
        color: #172033;
        font-size: 14px;
        font-weight: 750;
        line-height: 1.4;
      }

      body.page-scrape .low-price-product-id,
      body.page-scrape .low-price-sku-id {
        margin-top: 2px;
        color: #64748b;
        font-size: 12px;
      }

      body.page-scrape .low-price-sku-list {
        display: grid;
      }

      body.page-scrape .low-price-sku-row {
        display: grid;
        grid-template-columns: 56px minmax(0, 1fr) auto;
        align-items: center;
        gap: 12px;
        min-height: 72px;
        padding: 8px 14px;
        border-bottom: 1px solid #edf0f5;
      }

      body.page-scrape .low-price-sku-row:last-child {
        border-bottom: 0;
      }

      body.page-scrape .low-price-thumb {
        display: grid;
        place-items: center;
        width: 56px;
        height: 56px;
        overflow: hidden;
        border: 1px solid #e2e8f0;
        border-radius: 6px;
        background: #f8fafc;
        color: #94a3b8;
      }

      body.page-scrape .low-price-thumb img {
        width: 100%;
        height: 100%;
        object-fit: contain;
      }

      body.page-scrape .low-price-sku-copy {
        min-width: 0;
      }

      body.page-scrape .low-price-sku-name {
        overflow-wrap: anywhere;
        color: #1e293b;
        font-size: 14px;
        font-weight: 700;
      }

      body.page-scrape .low-price-value {
        min-width: 86px;
        color: #b91c1c;
        font-size: 18px;
        font-weight: 850;
        text-align: right;
      }

      body.page-scrape .low-price-action-status {
        padding: 10px 12px;
        border-radius: 6px;
        background: #f1f5f9;
        color: #334155;
        font-size: 13px;
      }

      body.page-scrape .low-price-actions {
        display: flex;
        justify-content: flex-end;
        gap: 10px;
      }

      body.page-scrape .low-price-actions .btn {
        min-width: 132px;
      }

      body.page-scrape .low-price-approve-btn {
        border-color: #dc2626;
        background: #fff;
        color: #b91c1c;
      }

      body.page-scrape .low-price-approve-btn:hover {
        background: #fef2f2;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight {
        min-width: 0;
        margin-top: 10px;
        border: 1px solid #dbe3ee;
        border-radius: 6px;
        background: #fff;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        min-height: 40px;
        padding: 8px 10px;
        border-bottom: 1px solid #e5eaf1;
        color: #475569;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-check-all {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        color: #0f172a;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table-wrap {
        max-height: 360px;
        overflow: auto;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table {
        width: 100%;
        min-width: 760px;
        border-collapse: collapse;
        table-layout: fixed;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table th,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table td {
        padding: 9px 8px;
        border-bottom: 1px solid #edf0f4;
        text-align: left;
        vertical-align: middle;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table th:first-child,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table td:first-child {
        width: 34px;
        text-align: center;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table th:nth-child(2) { width: 25%; }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table th:nth-child(3) { width: 90px; }
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-table th:nth-child(4) { width: 36%; }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-product-title {
        overflow: hidden;
        color: #172033;
        font-weight: 700;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-product-id,
      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-template-route {
        margin-top: 3px;
        color: #64748b;
        line-height: 1.35;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-status {
        display: inline-flex;
        align-items: center;
        min-height: 24px;
        padding: 3px 8px;
        border-radius: 4px;
        font-weight: 750;
        white-space: nowrap;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-status.is-ready {
        background: #ecfdf3;
        color: #157f3d;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-status.is-confirm {
        background: #fff7e6;
        color: #9a5b00;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-status.is-manual {
        background: #fff1f2;
        color: #b4233c;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-confirm-summary {
        display: flex;
        flex-direction: column;
        gap: 6px;
        padding: 14px 12px;
        border: 1px solid #dbe3ee;
        border-radius: 6px;
        background: #f8fafc;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-confirm-summary-title {
        color: #0f172a;
        font-size: 13px;
        font-weight: 750;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-confirm-summary-line {
        color: #475569;
        font-size: 12px;
        line-height: 1.5;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-list {
        display: flex;
        flex-direction: column;
        gap: 10px;
        max-height: 420px;
        overflow: auto;
        padding: 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-row {
        border: 1px solid #e2e8f0;
        border-radius: 6px;
        background: #fff;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-head {
        display: flex;
        align-items: baseline;
        justify-content: space-between;
        gap: 10px;
        padding: 8px 10px;
        border-bottom: 1px solid #eef2f7;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-body {
        padding: 8px 10px 10px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-meta {
        margin-bottom: 6px;
        color: #b4233c;
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-search {
        display: flex;
        gap: 6px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-search .wiz-grow {
        min-width: 0;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-result {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        margin-top: 8px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-result .wiz-cat-item {
        flex: 0 1 auto;
        min-width: 180px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-selected {
        margin-top: 8px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-missing-category-chosen {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 5px 8px;
        border-radius: 4px;
        background: #ecfdf3;
        color: #157f3d;
        font-size: 12px;
        font-weight: 700;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-title {
        color: #0f172a;
        font-size: 13px;
        font-weight: 750;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-note {
        color: #64748b;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-category-preflight-foot {
        padding: 8px 10px;
        border-top: 1px solid #e5eaf1;
        color: #64748b;
        font-size: 12px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-advanced-settings {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 14px;
      }

      body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-auto-template {
        display: flex;
        align-items: center;
        min-height: 40px;
        padding: 0 11px;
        border: 1px solid #cfd8e6;
        border-radius: 6px;
        background: #f8fafc;
        color: #172033;
        font-size: 13px;
        font-weight: 700;
      }

      @media (max-width: 920px) {
        body.page-scrape .ai-template-run-grid,
        body.page-scrape .ai-template-settings-grid,
        body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }
      }

      @media (max-width: 640px) {
        body.page-scrape .low-price-sku-row {
          grid-template-columns: 48px minmax(0, 1fr);
        }
        body.page-scrape .low-price-thumb {
          width: 48px;
          height: 48px;
        }
        body.page-scrape .low-price-value {
          grid-column: 2;
          min-width: 0;
          text-align: left;
        }
        body.page-scrape .low-price-actions {
          flex-direction: column;
        }
        body.page-scrape .low-price-actions .btn {
          width: 100%;
        }
        body.page-scrape .ai-template-run-grid,
        body.page-scrape .ai-template-settings-grid,
        body.page-scrape #globalModal.erp-edit-modal .erp-ai-template-grid,
        body.page-scrape #globalModal.wiz-enterprise-modal .wiz-ai-grid {
          grid-template-columns: minmax(0, 1fr);
        }

        body.page-scrape #globalModal.wiz-enterprise-modal .ai-template-settings-wizard .ai-template-settings-grid > :first-child {
          grid-column: auto;
        }

        body.page-scrape .ai-template-settings-head {
          display: grid;
        }

        body.page-scrape .ai-template-settings-actions {
          justify-content: flex-start;
        }

        body.page-scrape .ai-template-sample-row {
          grid-template-columns: minmax(0, 1fr);
        }
      }
.violation-observation-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    margin-top: 6px;
    padding: 3px 6px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    background: #f8fafc;
    color: #475569;
    font: inherit;
    font-size: 11px;
    line-height: 1.35;
}

button.violation-observation-badge { cursor: pointer; }
.violation-observation-badge.is-passed { border-color: #86efac; background: #f0fdf4; color: #166534; }
.violation-observation-badge.is-review,
.violation-observation-badge.is-documents,
.violation-observation-badge.is-warning { border-color: #fcd34d; background: #fffbeb; color: #92400e; }
.violation-observation-badge.is-blocked { border-color: #fca5a5; background: #fef2f2; color: #991b1b; }
.violation-observation-badge.is-checking { border-color: #93c5fd; background: #eff6ff; color: #1d4ed8; }

.violation-observation-detail { display: grid; gap: 10px; font-size: 13px; color: #334155; }
.violation-observation-notice { padding: 10px 12px; border-left: 3px solid #2563eb; background: #eff6ff; color: #1e3a8a; }
.violation-observation-detail-item { padding-top: 10px; border-top: 1px solid #e2e8f0; }
.violation-observation-empty { color: #64748b; }

/* ===== 20260725 natural image processing center ===== */
/* 2026-10-23 修：这里原来是 height: auto —— 它把上面第 446 行设的 90vh 覆盖掉了
   （选择器权重相同、这条在后面），于是容器高度完全由内容决定：
   白底图的缩略图列表一长，整个弹窗就长到 2518px，而删图/水印内容少就只到 444px。
   这就是「白底图和删图高度不一样、切 tab 会跳动」的真正根因（CDP 实测：容器 444px vs 2518px）。
   现在改成 height: 90vh 与第 446 行一致，四个 tab 的弹窗高度恒定。 */
body.page-scrape #imageToolsModal .modal-container {
  width: min(1280px, calc(100vw - 48px));
  height: 90vh;
  max-height: 90vh;
}

/* 2026-10-23 最终修复：modal-body 必须是 **flex 容器**，它的子级 content 的
   `height: 100%` 才有参照高度。
   前几轮一直没生效的原因就在这里：这条规则只写了 overflow / padding / background，
   没写 display，于是 modal-body 保持默认 block —— block 父级下子元素的 height: 100%
   会退化成按内容算，实测 content 被撑到 9691px，然后 panel/workspace/settings 全部跟着
   9691px，设置列 scrollH === clientH 不滚，modal-body 又 hidden 裁掉 ——
   用户看到的就是「下面的图看不到、也没有滚动条」。
   现在 modal-body 是 flex 列 + min-height: 0，content 作为 flex 子项被正确限高，
   由 content 自己的 overflow-y: auto 滚动（滚动条在弹窗内容区内部，看得见也拖得动）。 */
body.page-scrape #imageToolsModal .modal-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  padding: 12px 14px 16px;
  background: #f3f6f9;
}

/* 2026-10-25 十七轮（用户截图：三列只到内容高度，下面空出一大片灰底，问「要不要顶到最底下」）：
   这条规则原来写 height: auto —— 它是 7 月做「图片处理中心」时留下的（blame: 885dd68），
   当时 modal-body 还不是 flex 容器，写 auto 是为了让弹窗按内容长。
   但第 7759 行已经把 modal-body 改成 `display: flex; flex-direction: column`，
   而这条（同选择器、源序在后）又把 shell 的高度退回内容高，于是：
     modal-body 588px → shell 只有内容那么高 → content/panel/workspace/三列全部跟着内容高
   → 三列底边在 410~732px 之间各自打住，剩下的灰底就是这么来的（CDP 实测 ai-batch 差 178px）。
   改回 height: 100%（与第 6014 行一致）后，shell 作为 flex 子项吃满 modal-body 的可用高度，
   整条链才真正贯通：modal-body → shell → content → panel → workspace → 三列 → 卡片底部。
   gap 仍归零（灰带问题见第 6017 行的注释）。 */
body.page-scrape .image-tools-shell {
  height: 100%;
  min-height: 0;
  gap: 0px;
}

body.page-scrape .image-tools-modes {
  width: min(100%, 546px);
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border: 1px solid #dce3eb;
  border-radius: 8px;
  background: #e9eef4;
}

body.page-scrape .image-tools-mode {
  width: 132px;
  height: 40px;
  flex: 0 1 132px;
  padding: 0 14px;
  border-radius: 6px;
  background: rgba(255,255,255,.72);
  color: #475569;
  letter-spacing: 0;
}

body.page-scrape .image-tools-mode:hover:not(.active) {
  background: #fff;
  color: #1e293b;
}

body.page-scrape .image-tools-mode.active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 1px 2px rgba(37,99,235,.2);
}

/* 2026-10-23 五轮定案：这条原来把 content / panel 一起设成 height:auto + overflow:visible，
   与文件末尾的新架构（content 限高不滚、panel 限高不裁、只有设置列滚）直接冲突 ——
   测试 100 读到的 content overflow 一直是 auto，就是被这条盖住的。
   现在只保留 panel 的 visible（它必须不裁子元素滚动条），content 交给文件末尾那条统一管。 */
body.page-scrape .image-tools-panel,
body.page-scrape .image-tools-panel.active {
  overflow: visible;
  padding-right: 0;
}

/* 2026-10-13：四个 tab 的工作区四列改成等高（stretch）。
   2026-10-23 五轮定案：height 从 auto 改成 **100%** —— 这是「只有中间列滚」的必要条件：
   工作区拿到 panel 的确定高度后，三列才能各自 height: 100%，
   中间列才有确定的可视高度、才能触发自己的 overflow-y: auto。
   之前 auto 时列高跟着内容长，中间列的 scrollH === clientH，永远不滚。 */
body.page-scrape .image-tools-workspace {
  display: grid;
  align-items: stretch;
  gap: 12px;
  width: 100%;
  height: 100%;
  min-height: 0;
}

/* 左栏「选择图片」卡片的高度上限 = 工作区可用高度本身。
   为什么必须有这一条：工作区只有一行（grid-template-columns 三个轨道），行高是 auto，
   而 auto 轨道的基准尺寸取各列的 max-content —— 哪一列的内容最高，整行就被顶到多高。
   改成 stretch 之后 AI 生图 tab 左栏那三组（商品图限高 440 + SKU + 描述）叠起来仍有
   机会超过工作区高度，一旦超过就把这一行顶高，四个 tab 的底边又不一样了。
   给卡片一个 max-height 等于工作区高度，它的 max-content 贡献就被这一条夹住，
   行高稳定等于工作区高度；卡片内部超出的部分由 .ai-image-group 自己滚动（见下面
   .ai-image-group 那条），不会再溢到卡片外面。
   数值与 #imageToolsModal .image-tools-content 的 height 逐字对齐（min(720px, calc(100vh - 210px))
   + min-height: 420px 兜底），test/image-tools-thumbnail-grid-cascade.test.js 会断言两者相等，
   改一处不改另一处会被测试抓住。
   删图 tab 的左栏也是这个 class，但它的内容（序号 chip 网格，限高 min(440px, calc(100vh - 270px))）
   本来就够不到这个上限，所以对它没有任何可见影响。
   2026-10-22：数值改为与内容区同源 —— 内容区现在是 height: 100%（弹窗 90vh 减去头部与内边距），
   所以左栏上限也用 100% 跟随，不再写死 720px。 */
body.page-scrape .image-tools-selection-card {
  max-height: 100%;
}

body.page-scrape .ai-image-panel.image-tools-workspace {
  grid-template-columns: 220px minmax(420px, 1fr) 360px;
}

body.page-scrape .white-bg-panel.image-tools-workspace {
  grid-template-columns: 220px minmax(420px, 1fr) 360px;
}

body.page-scrape .watermark-shell.image-tools-workspace {
  grid-template-columns: 220px minmax(420px, 1fr) 360px;
}

body.page-scrape .image-delete-shell.image-tools-workspace {
  grid-template-columns: 220px minmax(420px, 1fr) 360px;
}

body.page-scrape .image-tools-column-card,
body.page-scrape .image-tools-settings-column {
  min-width: 0;
  border: 1px solid #dce3eb;
  border-radius: 8px;
  background: #fff;
}

body.page-scrape .image-tools-column-card {
  display: flex;
  flex-direction: column;
  gap: 11px;
  height: auto;
  min-height: 0;
  padding: 14px;
}

/* 2026-10-23 五轮定案（最终）：**只有中间列滚**，左右两列固定 —— 与删图观感一致。
   完整链条（每一层都必须成立，缺一层就会退化成「弹窗最右侧那条」）：
     modal-body        display: flex + min-height: 0   （给子级百分比高度参照）
       content         flex: 1 1 0 + overflow: hidden  （只当限高容器，不滚）
         panel         height: 100% + overflow: visible（限高、不裁子元素滚动条）
           workspace   height: 100%（grid，align-items: stretch）
             左栏/右栏  height: 100% + overflow: hidden（固定，不滚）
             设置列     height: 100% + overflow-y: auto ← 唯一滚动容器
   ⚠️ 设置列不能写 height: auto：那样列高会跟着内容长，滚不动（前几轮踩过）。 */
body.page-scrape .image-tools-settings-column {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  /* 2026-10-23 十一轮：上下 padding 从 4px 改成 **0**。
     原来 4px 的上内边距导致两个问题：
       1) 标题条吸顶时上方永远留一条缝（用户截图里那条红线）；
       2) 为了补这条缝用负 margin 硬顶，又造成「刚开始滚动时 1px 跳动」
          （CDP 实测 scrollTop=0 时 head 相对 top=1px，scrollTop≥1 时变 0px）。
     现在上下不留 padding，section 自己也没有 padding-top（见下），
     标题条不需要任何负 margin 就能严丝合缝贴住列顶，滚动时也一动不动。
     左右 16px 保留 —— 那是列的正常内边距，标题条用负 margin 单独吃掉它。 */
  padding: 0 16px;
  /* 2026-10-23 十二轮：去掉顶部边框。那 1px 浅灰线（#dce3eb）贴在标题条上方，
     视觉上就是用户说的「还有一条缝隙」—— 其实不是空隙，是边框。
     去掉顶边后标题条与列顶严丝合缝，左右下三边保留（列的轮廓仍然完整）。 */
  border-top: 0;
}

/* 左右两列固定：内容再多也不滚（与删图一致 —— 只中间列滚）。 */
body.page-scrape .image-tools-column-card {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

/* 2026-10-23 九轮修（用户截图反馈「SKU 图没有完全覆盖，上左右都有小缝隙漏出背景」）：
   缝隙来源已用 CDP 量清楚 ——
     左 17px = settings 的 padding-left 16px + 1px 边框（这是列内边距，正常）
     右 32px = **form 的 max-width: 720px 把内容截断了**（settings 648 宽、form 只有 599）
     上 23px = settings 的 padding-top 4px + section 的 padding-top 18px
   所以真正该修的是右侧那条：去掉 form 的 720px 上限，让它铺满设置列。
   （左/上那两处是正常的列内边距，标题条与 form 同宽，不是「没覆盖」。） */
body.page-scrape #imageToolsModal .image-tools-form {
  display: block;
  width: 100%;
  max-width: none;
}

/* 2026-10-23 四轮定案：这条原来给白底图最后一个 section 设了
   `flex: 1 1 0 + overflow: hidden`，本意是让列表在 section 内部滚。
   但滚动容器已经上移给「设置列」了，section 再 hidden 就变成**把内容裁掉**：
   CDP 实测 sec2 clientH=725 / scrollH=2677 / overflowY=hidden ——
   用户看到的就是「没有滚动条、下面的图也看不到、滚不动」。
   现在 section 恢复成普通块（自然高度，不裁内容），
   滚动交给设置列（它的 overflow-y: auto 在 panel 可见区内，滚动条看得见也拖得动）。 */
body.page-scrape #imageToolsModal .image-tools-form--white-bg > .image-tools-section:last-child {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  /* 2026-10-24 十六轮定案（穷举扫描 253 个滚动位置后精确定位）：
     只有 scrollTop≈8880~8917（接近内容末尾）这两处出现缝，
     且 75/75 个全宽采样点都异常 —— 说明是整条结构性的空隙，不是零星透色。
     放大 5 倍截图看到：上方内容已结束 → 一条灰线 → 下方才是标题条。

     来源：最后一个 section 的 padding-bottom（继承自 .image-tools-section 的 18px），
     滚到底部时这段 padding 露出 modal-body 的灰底 #f3f6f9。
     归零后，列表最后一行紧贴容器底部，不再留出可透色的空隙。 */
  padding-bottom: 0;
}

/* 2026-10-22 修：删掉 .image-tools-form--white-bg 的 max-width: 560px。
   原来这条把白底图表单钉在 560px，而它所在的设置列在宽屏下是 646px（内容区 612px），
   于是「处理范围 / 写回方式 / 处理说明」这些 section 只能铺到 560px，右侧空出 52px；
   而同一个面板里不在 form 内的勾选框、提示框又能用满 612px —— 底部各块宽度不统一，
   看起来就是「样式乱了」（用户 2026-10-22 反馈，3440 带鱼屏实测 section 560 vs 容器 646）。
   现在统一走上面 .image-tools-form 的 width:100% + max-width:720px，四列收口由
   .image-tools-workspace 的 220px minmax(420px,1fr) 360px 决定，form 不再单独设窄上限。 */

body.page-scrape #imageToolsModal .image-tools-section {
  display: grid;
  gap: 16px;
  min-width: 0;
  padding: 18px 0;
}

/* 2026-10-23 十一轮：白底图第一个 section（SKU 图那段）去掉上 padding。
   原因同上：section 的 18px padding-top 会让 sticky 标题条吸顶时上方留缝，
   而用负 margin 去补又会引入「滚动开始瞬间 1px 跳动」。
   去掉之后标题条 margin-top 可以是 0，吸附时严丝合缝、滚动时零位移。 */
body.page-scrape #imageToolsModal .image-tools-form--white-bg > .image-tools-section:first-child {
  padding-top: 0;
}

/* ===== 2026-10-22 批量白底图：处理范围合成一行四选 =====
   原来「处理范围（radio 二选）」「SKU 独立图片」「商品描述图片」是三个独立分区，
   运营要上下找才知道能处理哪几类图。现在改成一行四个 chip：主图 / 商品附图 / SKU 图 / 描述图，
   每个 chip 后面直接跟该类图的张数，一眼看完。
   语义没变：主图恒选（disabled），商品附图 = scope all，SKU 图 / 描述图各自独立开关。
   flex-wrap 保证窄屏（<=1399px 设置列约 290px）下自动换行不溢出。 */
/* 隐藏的 scope=main radio：只承载语义，不参与视觉（getScope 读 :checked 的 value）。 */
body.page-scrape .white-bg-scope-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

body.page-scrape .white-bg-scope-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  position: relative;
}

body.page-scrape .white-bg-scope-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #dbe2ea;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  user-select: none;
  transition: border-color .15s, background .15s;
}

body.page-scrape .white-bg-scope-chip:hover {
  border-color: #93b4f7;
  background: #f8fbff;
}

body.page-scrape .white-bg-scope-chip:has(input:checked) {
  border-color: #2563eb;
  background: #eff5ff;
  color: #1d4ed8;
}

body.page-scrape .white-bg-scope-chip:has(input:disabled) {
  cursor: not-allowed;
  opacity: .62;
}

/* 主图那一格是「恒选且不可改」的静态 chip：没有 input，靠 is-static 保持选中配色。 */
body.page-scrape .white-bg-scope-chip.is-static {
  border-color: #2563eb;
  background: #eff5ff;
  color: #1d4ed8;
  cursor: default;
}

body.page-scrape .white-bg-scope-chip.is-static b {
  background: #dbeafe;
  color: #1d4ed8;
}

body.page-scrape .white-bg-scope-chip input {
  margin: 0;
  accent-color: #2563eb;
}

body.page-scrape .white-bg-scope-chip b {
  min-width: 18px;
  padding: 1px 5px;
  border-radius: 999px;
  background: #eef2f7;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

body.page-scrape .white-bg-scope-chip:has(input:checked) b {
  background: #dbeafe;
  color: #1d4ed8;
}

body.page-scrape .white-bg-scope-summary {
  color: #64748b;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}

/* 「处理范围」标题行：左边标题、右边「本次处理 N 张」，一行说完不再单独占一行。 */
body.page-scrape .white-bg-scope-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

body.page-scrape #imageToolsModal .image-tools-section + .image-tools-section {
  border-top: 1px solid #e5eaf0;
}

body.page-scrape .image-tools-card-head,
body.page-scrape #imageToolsModal .image-tools-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-section-head--compact {
  justify-content: flex-start;
  gap: 16px;
}

body.page-scrape .image-tools-card-title,
body.page-scrape .watermark-preview-title,
body.page-scrape #imageToolsModal .image-tools-section-title {
  color: #0f172a;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 800;
  letter-spacing: 0;
}

/* .image-tools-selection-meta / .image-tools-single-hint（AI 生图标题旁那个「多选」小标签
   及其 flex 容器）随标签一起去掉了：四个 tab 的左栏标题行现在结构完全相同，
   只有标题 + 计数两个元素。多选已经是四个 tab 的默认能力，单独标一个 tab 反而显得不统一。 */

body.page-scrape .image-tools-selection-count,
body.page-scrape .white-bg-progress {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 7px;
  border-radius: 5px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
}

body.page-scrape .image-tools-bulk-actions {
  display: flex;
  gap: 6px;
}

body.page-scrape .image-tools-bulk-actions .btn {
  min-width: 0;
  height: 30px;
  flex: 1 1 0;
  justify-content: center;
  padding: 0 7px;
  border-color: #d7dee8;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
}

body.page-scrape .image-tools-thumbnail-grid,
body.page-scrape .ai-image-grid.image-tools-thumbnail-grid,
body.page-scrape .white-bg-grid.image-tools-thumbnail-grid,
body.page-scrape .watermark-image-list.image-tools-thumbnail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: start;
  gap: 8px;
  min-height: 0;
  max-height: min(440px, calc(100vh - 270px));
  overflow-x: hidden;
  overflow-y: auto;
  padding: 1px 3px 1px 1px;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
}

body.page-scrape .image-tools-thumbnail-card {
  position: relative;
  display: grid;
  grid-template-rows: auto 24px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  align-content: start;
  gap: 6px;
  padding: 6px;
  border: 1px solid #dfe5ec;
  border-radius: 7px;
  background: #fff;
  box-shadow: none;
  cursor: pointer;
}

body.page-scrape .ai-image-card.is-selected,
body.page-scrape .white-bg-image-card:has(input[type="checkbox"]:checked),
body.page-scrape .watermark-image-choice.is-selected {
  border-color: #3b82f6;
  background: #eff6ff;
  box-shadow: 0 0 0 2px rgba(37,99,235,.09);
}

body.page-scrape .image-tools-thumbnail {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: block;
  overflow: hidden;
  border: 1px solid #e5eaf0;
  border-radius: 5px;
  background: #f8fafc;
}

body.page-scrape .image-tools-thumbnail img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

/* ===== 2026-10-12 四个 tab 左栏勾选框统一（唯一真源） =====
   在此之前四个 tab 的勾选框是四种状态：
     AI 生图  —— 一条规则都没命中。旧规则写的是 .ai-image-card input[type="radio"]，
                 但 AI 生图已从单选改成多选，卡片里是 checkbox，于是它退回
                 body.page-scrape input 的 height: 34px / padding: 0 11px 且留在网格流里，
                 把卡片顶成三行 —— 这就是运营看到的「AI 生图卡片明显更高」。
     白底图   —— 自己一套 24px @ top/left 9px + appearance: none + 自绘对勾。
     水印     —— 18px @ top/left 8px（z-index 1）。
     删图     —— 18px @ top/left 8px（z-index 2），但没有摘掉 body.page-scrape input
                 的 border / border-radius / background，且 accent-color 是红色。
   现在四个 tab 的卡片勾选框全部由下面这一条规则接管：同样的尺寸、同样的位置、
   同样的外观重置。选择器显式列出四个 tab 的卡片 class，不写裸 input，
   所以弹窗里其它 input（文本框 / 数字框 / 单选）不受影响。 */
body.page-scrape .ai-image-card input[type="checkbox"],
body.page-scrape .white-bg-image-card input[type="checkbox"],
body.page-scrape .watermark-image-choice input[type="checkbox"],
body.page-scrape .image-delete-image-card input[type="checkbox"] {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  width: 18px;
  height: 18px;
  margin: 0;
  appearance: auto;
  border: 0;
  border-radius: 0;
  background: initial;
  box-shadow: none;
  cursor: pointer;
}

/* 键盘聚焦环也让四个 tab 一致（此前只有白底图 tab 有）。 */
body.page-scrape .ai-image-card input[type="checkbox"]:focus-visible,
body.page-scrape .white-bg-image-card input[type="checkbox"]:focus-visible,
body.page-scrape .watermark-image-choice input[type="checkbox"]:focus-visible,
body.page-scrape .image-delete-image-card input[type="checkbox"]:focus-visible {
  outline: 3px solid rgba(37, 99, 235, .28);
  outline-offset: 2px;
}

/* 勾选框颜色是四个 tab 里唯一有意保留的差异：AI 生图 / 白底图 / 水印用品牌蓝，
   删图 tab 是破坏性操作，沿用既有的红色（它连卡片选中态都是 #ef4444 / #fef2f2）。
   尺寸与位置仍然完全相同。 */
body.page-scrape .ai-image-card input[type="checkbox"],
body.page-scrape .white-bg-image-card input[type="checkbox"],
body.page-scrape .watermark-image-choice input[type="checkbox"] {
  accent-color: #2563eb;
}

body.page-scrape .image-delete-image-card input[type="checkbox"] {
  accent-color: #dc2626;
}

body.page-scrape .image-tools-thumbnail-meta {
  min-width: 0;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
}

body.page-scrape .image-tools-thumbnail-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .image-tools-thumbnail-badge {
  min-width: 0;
  min-height: 19px;
  max-width: 58px;
  height: 19px;
  display: inline-flex;
  align-items: center;
  overflow: hidden;
  padding: 0 5px;
  border-radius: 4px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 10px;
  line-height: 19px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .white-bg-localize-hint {
  display: none;
}

body.page-scrape #imageToolsModal .image-tools-choice-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 24px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-choice {
  width: auto;
  max-width: 100%;
  box-sizing: border-box;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  padding: 0 11px;
  border: 1px solid #dfe5ec;
  border-radius: 6px;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  cursor: pointer;
}

body.page-scrape #imageToolsModal .image-tools-choice:has(input:checked) {
  border-color: #93b4ee;
  background: #eff6ff;
  color: #1e40af;
}

body.page-scrape #imageToolsModal .image-tools-choice input,
body.page-scrape #imageToolsModal .image-tools-switch input {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin: 0;
  accent-color: #2563eb;
}

body.page-scrape .image-tools-field-label,
body.page-scrape #imageToolsModal .image-tools-compact-field,
body.page-scrape #imageToolsModal .image-tools-switch {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

body.page-scrape .image-tools-info-block {
  display: grid;
  gap: 4px;
  padding: 11px 12px;
  border-radius: 7px;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  line-height: 1.45;
}

body.page-scrape .image-tools-info-block strong {
  color: #334155;
}

body.page-scrape #imageToolsModal .image-tools-field,
body.page-scrape #imageToolsModal .image-tools-field-stack {
  display: grid;
  gap: 7px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-field-stack {
  gap: 16px;
}

body.page-scrape #imageToolsModal .image-tools-text-input,
body.page-scrape #imageToolsModal .image-tools-textarea {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 1px solid #d7dee8;
  border-radius: 6px;
  background: #fff;
  color: #1e293b;
  font: inherit;
  font-size: 13px;
  outline: 0;
}

body.page-scrape #imageToolsModal .image-tools-text-input {
  height: 36px;
  padding: 0 11px;
}

body.page-scrape #imageToolsModal .image-tools-textarea {
  min-height: 138px;
  max-height: 240px;
  padding: 10px 11px;
  resize: vertical;
  line-height: 1.5;
}

body.page-scrape #imageToolsModal .image-tools-text-input:focus,
body.page-scrape #imageToolsModal .image-tools-textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37,99,235,.1);
}

body.page-scrape .ai-image-character-count {
  color: #94a3b8;
  font-size: 11px;
  font-weight: 700;
}

/* 2026-10-25 十七轮：height 从 auto 改回 100%。
   这条与第 7917 行 `.image-tools-column-card { height: 100% }` 选择器权重相同
   （0,2,0 vs 0,2,0）而源序在后，于是左右两列里凡是挂了 .image-tools-operation-card /
   .watermark-preview-pane 的卡片，高度又退回内容高 —— 与 shell 那条是同一个毛病：
   网格行拉伸（align-items: stretch）已经给了满高，卡片自己却声明 auto。
   改回 100% 后卡片吃满网格行高，主按钮才有地方用 margin-top: auto 钉到底。 */
body.page-scrape .image-tools-operation-card,
body.page-scrape .watermark-preview-pane {
  width: 100%;
  height: 100%;
  min-height: 0;
}

body.page-scrape .image-tools-preview-frame,
body.page-scrape .watermark-live-canvas {
  width: 100%;
  height: 290px;
  flex: 0 0 290px;
  display: grid;
  place-items: center;
  margin: 0;
  overflow: hidden;
  border: 1px solid #dce3eb;
  border-radius: 8px;
  background: #f8fafc;
  color: #94a3b8;
  font-size: 12px;
}

body.page-scrape .image-tools-preview-frame img,
body.page-scrape .watermark-live-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

body.page-scrape .image-tools-preview-empty {
  display: grid;
  place-items: center;
  gap: 7px;
  padding: 20px;
  color: #94a3b8;
  text-align: center;
}

body.page-scrape .image-tools-preview-empty i {
  font-size: 30px;
  color: #b4c0ce;
}

body.page-scrape .image-tools-preview-empty strong {
  color: #475569;
  font-size: 13px;
}

body.page-scrape .image-tools-preview-empty span,
body.page-scrape .image-tools-action-note {
  color: #94a3b8;
  font-size: 11px;
}

body.page-scrape .image-tools-primary-action,
body.page-scrape .watermark-apply-btn {
  width: 100%;
  min-height: 42px;
  flex: 0 0 42px;
  justify-content: center;
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
  font-weight: 800;
}

/* 2026-10-25 十七轮：三列撑满弹窗之后，卡片内部也要把富余高度分配掉。
   改之前（CDP 实测 1400×1000 / 容器 900px）：卡片 732px，内容全挤在顶部，
   白底图批量的「生成白底图」按钮离卡片底还有 410px、水印 245px ——
   用户截图里那片空白，一半在列外（shell 没撑满，已由第 7768 行修掉），
   另一半就是这里：卡片已经 732px 了，子元素却都是内容高，多余的空间没人认领。

   分配规则（三个 tab、五个右栏一致）：
     结果列表   flex: 1 1 auto  —— 唯一可伸缩项，吃掉富余高度（上限仍是它自己的 max-height）
     主按钮     margin-top: auto —— 即使列表已经顶到上限、还有富余，按钮也贴卡片底
   为什么主按钮不用 flex: 1：按钮被拉高会变成一个巨型色块，且各栏按钮高度会不一致。
   为什么列表不用 flex: 1 1 0：basis 0 会让空态/少量结果时列表塌到 min-height，
   富余全跑到按钮上方，看起来像「列表和按钮之间断开一截」。 */
body.page-scrape .image-tools-result-operation-card > .image-tools-result-list {
  flex: 1 1 auto;
}

/* 主按钮贴底：它是卡片里最后一个「动作」，上面留白、下面贴边。
   选择器用 .image-tools-operation-card（不是 .image-tools-result-operation-card）——
   白底图单商品那一栏没有结果列表，也就没挂 result-operation-card，
   用窄的会漏掉它，那一栏的按钮会独自悬在中间（CDP 实测离底 345px）。 */
body.page-scrape .image-tools-operation-card > .image-tools-primary-action {
  margin-top: auto;
}

/* 白底图单商品：没有结果列表可撑，富余高度交给预览框（预览图更大更好认）。
   注意预览框外面还包了一层 [data-white-bg-preview-shell]（用来整块显隐），
   所以两条规则都要写：外层当 flex 容器并吸收富余，内层预览框跟着长。
   上限 420px —— 不设的话 1080p 下它会从 290px 长到 600px，图被放大到发虚。 */
body.page-scrape .image-tools-operation-card:not(.image-tools-result-operation-card) > [data-white-bg-preview-shell] {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

body.page-scrape .image-tools-operation-card:not(.image-tools-result-operation-card) > [data-white-bg-preview-shell] > .image-tools-preview-frame {
  flex: 1 1 290px;
  max-height: 420px;
  /* 2026-10-25 十九轮：矮视口（1080p 笔记本把窗口压矮时 90vh 只有 ~630px）下，
     卡片里「预览框 290 + 汇总行 34 + 列表 min-height 180 + 状态行 + 按钮」叠起来会超，
     超出部分被卡片的 overflow: hidden 裁掉 —— 实测 AI 生图单商品按钮被裁到卡片外 153px、
     水印 25~71px。这里允许预览框收缩（flex-shrink 生效），下限 150px 保证还能看清图。 */
  min-height: 150px;
}

/* AI 生图单商品：预览框是直接子元素，同样吸收富余（上限一致）。
   矮视口下同样允许收缩到 150px，理由见上面白底图那条。

   ⚠️ 这条**不能**带 :not(.image-tools-result-operation-card) ——
   AI 生图单商品的右栏同时挂了 image-tools-result-operation-card
   （它有结果列表，符合那个 class 的语义），带 :not 就整条失效，
   预览框会一直停在 flex: 0 0 290px、矮视口下按钮被裁出卡片 153px（踩过）。 */
body.page-scrape .image-tools-operation-card > .image-tools-preview-frame {
  flex: 1 1 290px;
  max-height: 420px;
  min-height: 150px;
}

/* 水印右栏没有结果列表（预览画布是固定 290px），富余高度只能靠主按钮吃掉。 */
body.page-scrape .watermark-preview-pane > .watermark-apply-btn {
  margin-top: auto;
}

/* 矮视口下水印画布要能收缩：它写的是 flex: 0 0 290px（完全不参与收缩），
   1080p 笔记本把窗口压矮时（90vh ≈ 630px）卡片只剩 ~460px，
   「模板条 46 + 标题 24 + 画布 290 + 汇总 34 + 按钮 42」叠起来就超了，
   实测按钮被裁到卡片外 25~71px。改成可收缩、下限 150px（与预览框一致），
   高度够时仍然是 290px 不动。 */
body.page-scrape .watermark-preview-pane > .watermark-live-canvas {
  flex: 0 1 290px;
  min-height: 150px;
}

/* 2026-10-25 十九轮：极端矮窗口（窗口高度 < 620px，90vh ≈ 558px 以下）的兜底。
   卡片里的固定项 —— 标题 24 + 预览 150 + 汇总 34 + 状态 37 + 主按钮 42 + 二级 36
   + gap 54 + padding 28 = 405px —— 已经压无可压，结果列表早就缩到 0 了。
   这时不再硬塞，改成让右栏整体可滚动：按钮至少能滚到，而不是被 overflow: hidden
   无声裁掉（520px 容器实测 AI 生图单商品被裁 47px、水印 -33px）。
   ⚠️ 阈值取 620px：630px 容器（700px 窗口）实测已经全部干净，不需要滚动。 */
@media (max-height: 620px) {
  body.page-scrape .image-tools-workspace > .image-tools-operation-card {
    overflow-y: auto;
  }

  body.page-scrape .image-tools-operation-card > .image-tools-preview-frame,
  body.page-scrape .image-tools-operation-card:not(.image-tools-result-operation-card) > [data-white-bg-preview-shell] > .image-tools-preview-frame {
    min-height: 120px;
  }

  body.page-scrape .watermark-preview-pane > .watermark-live-canvas {
    min-height: 120px;
  }
}

/* 有二级按钮（「仅重试失败」/「一键全部应用」）时它排在主按钮之后，
   主按钮的 margin-top: auto 推的是「主 + 二级」这一整块，二级按钮贴卡片底（15px 内边距），
   主按钮在它上方 9px —— 这正是想要的效果，不需要额外规则。
   （CDP 实测：white-batch-done / ai-single-done 主按钮离底 60px = 15 + 36 + 9，对得上。） */

body.page-scrape .image-tools-primary-action:disabled,
body.page-scrape .watermark-apply-btn:disabled,
body.page-scrape .image-tools-bulk-actions .btn:disabled {
  cursor: not-allowed;
  opacity: .52;
}

body.page-scrape .ai-image-status {
  min-height: 36px;
  flex: 0 0 auto;
  border-radius: 7px;
}

body.page-scrape .image-tools-run-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 34px;
  padding: 7px 9px;
  border: 1px solid #e5eaf0;
  border-radius: 7px;
  background: #f8fafc;
  color: #64748b;
  font-size: 11px;
  line-height: 1.35;
}

body.page-scrape .image-tools-run-summary strong {
  color: #0f172a;
  font-variant-numeric: tabular-nums;
}

body.page-scrape .image-tools-run-summary.is-compact {
  min-height: 30px;
  padding: 6px 8px;
}

body.page-scrape .image-tools-result-operation-card {
  gap: 9px;
}

/* 2026-10-25 十九轮（用户截图：「既然按钮已经扩到底下了，这个具体处理内容应该也一并
   扩充到下面吧」）：max-height 原来是 min(360px, calc(100vh - 310px)) ——
   360px 这条硬上限在 1080p 下先命中，于是结果列表只长到 360px 就停住，
   卡片明明还有 400 多 px 空着（截图里红框下面那片白）。
   改成「吃满卡片剩余高度」：上限交给 max-height: 100% + flex: 1 1 auto
   （父级 .image-tools-result-operation-card 已经撑满网格行，见上面那条规则），
   列表自己 overflow-y: auto，条目再多也是它内部滚，不会把按钮顶出卡片。
   保留 min-height —— 内容少时（空态 / 只有一两条）不至于塌成一条缝。
   但它必须是可收缩的下限：矮视口下卡片只剩 ~460px，而「预览框 150 + 汇总行 34 +
   状态行 37 + 按钮 42 + 二级按钮 36 + gap 54 + padding 28」这些固定项已经占掉 405px，
   列表若还硬占 180px，总高 585px 就超出卡片，多出来的被 overflow: hidden 裁掉，
   主按钮直接看不见（AI 生图单商品实测 -65px）。
   所以这里不给死下限：靠上面的 flex: 1 1 auto 在空间富余时自然长到 530px+，
   空间不够时跟着缩到 0，把位置让给按钮。 */
body.page-scrape .image-tools-result-list {
  display: grid;
  gap: 8px;
  /* ⚠️ 必须有：Grid 的 align-content 默认是 stretch，而本列表外层是 flex:1 1 auto 会吃满
     面板高度 —— 容器比内容高时，自动尺寸的行会被【拉伸铺满容器】，于是每张结果卡都被
     拉得极高、内容挤在顶部、下面全空白（运营 2026-10-27 反馈「哪有这么高的显示」）。
     start 让行按内容高度排列，富余高度留在列表底部；主按钮有 margin-top:auto 仍然贴底。 */
  align-content: start;
  min-height: 0;
  max-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 2px;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
}

body.page-scrape .image-tools-result-list.is-single {
  min-height: 0;
  max-height: 158px;
  overflow: visible;
}

body.page-scrape .image-tools-result-card {
  display: grid;
  gap: 7px;
  padding: 8px;
  border: 1px solid #dfe5ec;
  border-radius: 7px;
  background: #fff;
}

body.page-scrape .image-tools-result-card.is-success {
  border-color: #bbf7d0;
  background: #f8fff9;
}

body.page-scrape .image-tools-result-card.is-failed {
  border-color: #fecaca;
  background: #fffafa;
}

body.page-scrape .image-tools-result-card.is-processing {
  border-color: #bfdbfe;
  background: #f8fbff;
}

body.page-scrape .image-tools-batch-bulk {
  display: grid;
  gap: 7px;
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 7px;
  background: #f8fbff;
}

body.page-scrape .image-tools-batch-bulk[hidden] {
  display: none;
}

body.page-scrape .image-tools-batch-select-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #334155;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

body.page-scrape .image-tools-batch-bulk-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}

body.page-scrape .image-tools-batch-bulk-actions .btn {
  min-height: 26px;
  height: 26px;
  padding: 0 8px;
  font-size: 11px;
}

body.page-scrape .image-tools-result-card.is-batch-selected {
  border-color: #60a5fa;
  box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.14);
}

body.page-scrape .image-tools-result-check {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: fit-content;
  color: #475569;
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
}

body.page-scrape .image-tools-result-media {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr);
  align-items: center;
  gap: 5px;
  min-width: 0;
}

body.page-scrape .image-tools-result-thumb {
  position: relative;
  min-width: 0;
  height: 92px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) 20px;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e5eaf0;
  border-radius: 6px;
  background: #f8fafc;
  color: #64748b;
  font: inherit;
  cursor: zoom-in;
}

body.page-scrape .image-tools-result-thumb img {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: block;
  object-fit: contain;
  background: #fff;
}

body.page-scrape .image-tools-result-thumb small {
  display: grid;
  place-items: center;
  min-width: 0;
  padding: 0 4px;
  border-top: 1px solid #edf1f5;
  background: #f8fafc;
  color: #64748b;
  font-size: 10px;
  font-weight: 700;
  line-height: 20px;
}

body.page-scrape .image-tools-result-thumb.is-empty {
  place-items: center;
  grid-template-rows: 1fr auto;
  cursor: default;
}

body.page-scrape .image-tools-result-thumb.is-empty i {
  align-self: end;
  margin-bottom: 6px;
  color: #b4c0ce;
  font-size: 22px;
}

body.page-scrape .image-tools-result-thumb.is-empty small {
  width: 100%;
  align-self: end;
}

body.page-scrape .image-tools-result-arrow {
  color: #94a3b8;
  font-size: 16px;
  font-weight: 800;
  text-align: center;
}

body.page-scrape .image-tools-result-meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: #64748b;
  font-size: 10px;
}

body.page-scrape .image-tools-result-meta strong {
  min-width: 0;
  overflow: hidden;
  color: #334155;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .image-tools-result-status {
  min-height: 19px;
  display: inline-flex;
  align-items: center;
  padding: 0 5px;
  border-radius: 4px;
  background: #f1f5f9;
  color: #64748b;
  font-weight: 800;
  white-space: nowrap;
}

body.page-scrape .image-tools-result-status.is-success {
  background: #dcfce7;
  color: #166534;
}

body.page-scrape .image-tools-result-status.is-failed {
  background: #fee2e2;
  color: #991b1b;
}

body.page-scrape .image-tools-result-status.is-processing {
  background: #dbeafe;
  color: #1d4ed8;
}

body.page-scrape .image-tools-result-elapsed {
  color: #64748b;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

body.page-scrape .image-tools-result-message {
  overflow-wrap: anywhere;
  color: #64748b;
  font-size: 10px;
  line-height: 1.4;
}

body.page-scrape .image-tools-result-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  padding-top: 2px;
}

body.page-scrape .image-tools-result-actions .btn {
  min-height: 25px;
  height: 25px;
  padding: 0 8px;
  font-size: 11px;
}

body.page-scrape .image-tools-result-decision {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: fit-content;
  min-height: 25px;
  padding: 0 8px;
  border: 1px solid #bbf7d0;
  border-radius: 5px;
  background: #f0fdf4;
  color: #166534;
  font-size: 11px;
  font-weight: 700;
}

body.page-scrape .image-tools-result-card.is-failed .image-tools-result-message {
  color: #b91c1c;
}

body.page-scrape .image-tools-result-empty {
  min-height: 180px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 7px;
  padding: 16px;
  border: 1px dashed #dce3eb;
  border-radius: 7px;
  background: #f8fafc;
  color: #94a3b8;
  text-align: center;
}

body.page-scrape .image-tools-result-empty i {
  color: #b4c0ce;
  font-size: 28px;
}

body.page-scrape .image-tools-result-empty strong {
  color: #475569;
  font-size: 12px;
}

body.page-scrape .image-tools-result-empty span {
  font-size: 10px;
}

/* ===== 图片处理 · 删图面板 ===== */
body.page-scrape .image-delete-shell .image-tools-selection-card,
body.page-scrape .image-delete-shell .image-tools-settings-column,
body.page-scrape .image-delete-shell .image-tools-operation-card {
  min-width: 0;
}

body.page-scrape .image-delete-position-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}

body.page-scrape .image-delete-position-chip {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 4px;
  border: 1px solid #dfe5ec;
  border-radius: 7px;
  background: #fff;
  cursor: pointer;
}

body.page-scrape .image-delete-position-chip.is-muted {
  background: #f8fafc;
  color: #94a3b8;
}

body.page-scrape .image-delete-position-chip.is-selected {
  border-color: #ef4444;
  background: #fef2f2;
  box-shadow: 0 0 0 2px rgba(239,68,68,.09);
}

body.page-scrape .image-delete-position-chip input {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: #dc2626;
  cursor: pointer;
}

body.page-scrape .image-delete-position-number {
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
  line-height: 1.1;
}

body.page-scrape .image-delete-position-chip.is-selected .image-delete-position-number {
  color: #b91c1c;
}

body.page-scrape .image-delete-position-label {
  max-width: 100%;
  overflow: hidden;
  color: #64748b;
  font-size: 10px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .image-delete-image-card:has(input[type="checkbox"]:checked) {
  border-color: #ef4444;
  background: #fef2f2;
  box-shadow: 0 0 0 2px rgba(239,68,68,.09);
}

/* 删图 tab 卡片勾选框原来自己一条（18px @ top/left 8px + accent-color 红）。
   几何与位置已并入文件前段「四个 tab 左栏勾选框统一」那条共用规则，
   这里只留颜色差异（破坏性操作沿用红色），见那条规则后面的说明。 */

body.page-scrape .image-delete-result-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px 9px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
}

body.page-scrape .image-delete-result-card.is-success {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

body.page-scrape .image-delete-result-card.is-warning {
  border-color: #fed7aa;
  background: #fff7ed;
}

body.page-scrape .image-delete-result-card.is-failed {
  border-color: #fecaca;
  background: #fef2f2;
}

body.page-scrape .image-delete-result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #334155;
  font-size: 12px;
}

body.page-scrape .image-delete-result-status {
  flex: 0 0 auto;
  padding: 1px 6px;
  border-radius: 4px;
  background: #f1f5f9;
  color: #475569;
  font-size: 10px;
  font-weight: 800;
}

body.page-scrape .image-delete-result-status.is-success {
  background: #dcfce7;
  color: #15803d;
}

body.page-scrape .image-delete-result-status.is-warning {
  background: #ffedd5;
  color: #c2410c;
}

body.page-scrape .image-delete-result-status.is-failed {
  background: #fee2e2;
  color: #b91c1c;
}

body.page-scrape .image-delete-result-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

body.page-scrape .image-delete-result-thumb {
  position: relative;
  width: 52px;
  height: 52px;
  display: block;
  overflow: hidden;
  padding: 0;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  cursor: zoom-in;
}

body.page-scrape .image-delete-result-thumb img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

body.page-scrape .image-delete-result-thumb span {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: 1px 0;
  background: rgba(15,23,42,.68);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  text-align: center;
}

body.page-scrape .image-delete-result-detail {
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.45;
}

body.page-scrape .image-delete-result-message {
  color: #b91c1c;
  font-size: 11px;
  line-height: 1.45;
}

body.page-scrape .image-delete-result-more {
  padding: 6px 0;
  color: #94a3b8;
  font-size: 11px;
  text-align: center;
}

body.page-scrape .image-delete-shell .image-tools-primary-action.wb-btn-danger {
  background: #dc2626;
  border-color: #dc2626;
  color: #fff;
}

body.page-scrape .image-delete-shell .image-tools-primary-action.wb-btn-danger:hover:not(:disabled) {
  background: #b91c1c;
  border-color: #b91c1c;
}

@media (max-width: 720px) {
  body.page-scrape .image-delete-position-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

body.page-scrape .image-tools-secondary-action {
  width: 100%;
  min-height: 36px;
  justify-content: center;
  border-color: #d7dee8;
  background: #fff;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
}

body.page-scrape .image-tools-operation-card.has-image-result .image-tools-preview-frame {
  height: 210px;
  flex-basis: 210px;
}

body.page-scrape .image-tools-operation-card.has-image-result .image-tools-result-thumb {
  height: 74px;
}

body.page-scrape .image-tools-empty,
body.page-scrape .white-bg-empty.image-tools-empty {
  min-height: 160px;
  height: auto;
  padding: 18px;
  border-radius: 7px;
}

body.page-scrape #imageToolsModal .image-tools-field-row {
  display: grid;
  align-items: center;
  grid-template-columns: 72px minmax(0, auto);
  gap: 10px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-field-row--range {
  grid-template-columns: 72px minmax(228px, 336px);
  justify-content: start;
}

body.page-scrape #imageToolsModal .image-tools-switch,
body.page-scrape #imageToolsModal .image-tools-compact-field {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  min-height: 36px;
}

body.page-scrape #imageToolsModal .image-tools-switch {
  color: #334155;
  cursor: pointer;
}

body.page-scrape #imageToolsModal .image-tools-wrap-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 24px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-range {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 62px;
  align-items: center;
  gap: 8px;
  width: min(100%, 280px);
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"] {
  width: 100%;
  min-width: 0;
  height: 18px;
  margin: 0;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"]:disabled {
  cursor: not-allowed;
  opacity: .45;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: #dbe3ec;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"]::-webkit-slider-thumb {
  width: 16px;
  height: 16px;
  margin-top: -6px;
  appearance: none;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #2563eb;
  box-shadow: 0 0 0 1px #2563eb;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"]::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: #dbe3ec;
}

body.page-scrape #imageToolsModal .image-tools-range input[type="range"]::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #2563eb;
  box-shadow: 0 0 0 1px #2563eb;
}

body.page-scrape #imageToolsModal .image-tools-range-value {
  width: 62px;
  height: 30px;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #64748b;
}

body.page-scrape #imageToolsModal .image-tools-range-number {
  width: 42px;
  min-width: 42px;
  height: 28px;
  box-sizing: border-box;
  padding: 0 3px;
  border: 1px solid #d7dee8;
  border-radius: 5px;
  outline: 0;
  background: #fff;
  color: #334155;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
}

body.page-scrape #imageToolsModal .image-tools-range-number:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37,99,235,.1);
}

body.page-scrape #imageToolsModal .image-tools-range-number:disabled {
  cursor: not-allowed;
  opacity: .45;
}

body.page-scrape #imageToolsModal .image-tools-range-number::-webkit-inner-spin-button,
body.page-scrape #imageToolsModal .image-tools-range-number::-webkit-outer-spin-button {
  margin: 0;
  appearance: none;
}

body.page-scrape #imageToolsModal .image-tools-range-number[type="number"] {
  appearance: textfield;
}

body.page-scrape #imageToolsModal .image-tools-range-unit {
  color: #334155;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

body.page-scrape #imageToolsModal .image-tools-color-input {
  width: 32px;
  min-width: 32px;
  height: 32px;
  padding: 3px;
  border: 1px solid #d7dee8;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
}

body.page-scrape #imageToolsModal .image-tools-form--watermark .image-tools-section {
  gap: 12px;
  padding: 14px 0;
}

body.page-scrape #imageToolsModal .image-tools-section-control {
  width: min(100%, 312px);
}

body.page-scrape #imageToolsModal .image-tools-border-settings {
  display: grid;
  grid-template-columns: minmax(0, 312px) 60px;
  align-items: start;
  gap: 8px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-setting-row,
body.page-scrape #imageToolsModal .image-tools-editor-row {
  display: flex;
  align-items: center;
  column-gap: 8px;
  row-gap: 0;
  min-width: 0;
  min-height: 36px;
}

body.page-scrape #imageToolsModal .image-tools-setting-row > .image-tools-field-label,
body.page-scrape #imageToolsModal .image-tools-editor-row > .image-tools-field-label {
  flex: 0 0 auto;
  width: auto;
}

body.page-scrape #imageToolsModal .image-tools-setting-row > .image-tools-range,
body.page-scrape #imageToolsModal .image-tools-editor-row > .image-tools-range,
body.page-scrape #imageToolsModal .image-tools-editor-row > .image-tools-text-input {
  flex: 0 1 auto;
}

body.page-scrape #imageToolsModal .image-tools-compact-range-row .image-tools-range {
  width: min(100%, 280px);
}

body.page-scrape #imageToolsModal .image-tools-border-color-field {
  align-self: end;
  gap: 4px;
}

body.page-scrape #imageToolsModal .image-tools-watermark-editor {
  display: grid;
  grid-template-columns: minmax(280px, 312px) 156px;
  grid-template-rows: repeat(3, 36px);
  grid-template-areas:
    "text position"
    "size position"
    "opacity position";
  align-items: center;
  gap: 8px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-editor-text-line {
  grid-area: text;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

body.page-scrape #imageToolsModal .image-tools-editor-text {
  min-width: 0;
  flex: 0 1 auto;
}

body.page-scrape #imageToolsModal .image-tools-editor-text .image-tools-text-input {
  width: min(100%, 160px);
  height: 30px;
  box-sizing: border-box;
  padding: 0 8px;
  border-radius: 5px;
  font-size: 12px;
  line-height: 28px;
}

body.page-scrape #imageToolsModal .image-tools-editor-text .image-tools-text-input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37,99,235,.1);
}

body.page-scrape #imageToolsModal .image-tools-editor-size {
  grid-area: size;
}

body.page-scrape #imageToolsModal .image-tools-editor-opacity {
  grid-area: opacity;
}

body.page-scrape #imageToolsModal .image-tools-editor-range .image-tools-range {
  width: min(100%, 280px);
}

body.page-scrape #imageToolsModal .image-tools-editor-color {
  flex: 0 0 auto;
  align-self: center;
  gap: 4px;
  transform: translateX(-15px);
}

body.page-scrape #imageToolsModal .image-tools-position-field {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
}

body.page-scrape #imageToolsModal .image-tools-editor-position {
  grid-area: auto;
  grid-column: 2;
  grid-row: 1 / 4;
  align-self: stretch;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: 156px;
  min-width: 156px;
  height: 124px;
}

body.page-scrape #imageToolsModal .image-tools-editor-position > .image-tools-field-label {
  padding-top: 8px;
}

body.page-scrape #imageToolsModal .image-tools-position-grid {
  width: 124px;
  min-width: 124px;
  height: 124px;
  display: grid;
  grid-template-columns: repeat(3, 36px);
  grid-template-rows: repeat(3, 36px);
  grid-auto-flow: row;
  gap: 8px;
}

body.page-scrape #imageToolsModal .image-tools-position-grid label {
  position: relative;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid #d7dee8;
  border-radius: 5px;
  background: #fff;
  cursor: pointer;
}

body.page-scrape #imageToolsModal .image-tools-position-grid input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

body.page-scrape #imageToolsModal .image-tools-position-grid span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #94a3b8;
}

body.page-scrape #imageToolsModal .image-tools-position-grid label:has(input:checked) {
  border-color: #2563eb;
  background: #eff6ff;
}

body.page-scrape #imageToolsModal .image-tools-position-grid input:checked + span {
  background: #2563eb;
}

body.page-scrape .watermark-template-tools {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 6px;
  padding-bottom: 11px;
  border-bottom: 1px solid #e5eaf0;
}

body.page-scrape .watermark-template-tools label {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

body.page-scrape .watermark-template-tools .template-select {
  width: 100%;
  min-width: 0;
}

body.page-scrape .watermark-template-tools .btn {
  min-width: 0;
  height: 34px;
  justify-content: center;
  padding: 0 8px;
  font-size: 11px;
  white-space: nowrap;
}

body.page-scrape .watermark-template-tools .watermark-delete-btn {
  border-color: #fecaca;
  background: #fff;
  color: #b91c1c;
}

body.page-scrape .image-tools-action-note {
  margin-top: -5px;
  text-align: center;
}

body.page-scrape .watermark-selected-note {
  border-radius: 7px;
  font-size: 12px;
  line-height: 1.5;
}

body.page-scrape #globalModal.erp-edit-modal .erp-image-tools-btn {
  min-height: 38px;
  padding: 0 14px;
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
  box-shadow: 0 4px 12px rgba(37,99,235,.2);
  font-size: 13px;
  font-weight: 800;
}

body.page-scrape #globalModal.erp-edit-modal .erp-image-tools-btn:hover {
  border-color: #1d4ed8;
  background: #1d4ed8;
}

@media (max-width: 1399px) {
  body.page-scrape .ai-image-panel.image-tools-workspace {
    grid-template-columns: 200px minmax(360px, 1fr) 290px;
  }

  body.page-scrape .white-bg-panel.image-tools-workspace {
    grid-template-columns: 200px minmax(360px, 1fr) 290px;
  }

  body.page-scrape .watermark-shell.image-tools-workspace {
    grid-template-columns: 200px minmax(360px, 1fr) 290px;
  }

  body.page-scrape .image-delete-shell.image-tools-workspace {
    grid-template-columns: 200px minmax(360px, 1fr) 290px;
  }

  body.page-scrape .image-tools-preview-frame,
  body.page-scrape .watermark-live-canvas {
    height: 260px;
    flex-basis: 260px;
  }
}

@media (min-width: 641px) and (max-width: 1199px) {
  body.page-scrape #imageToolsModal .image-tools-watermark-editor {
    grid-template-columns: minmax(280px, 312px) 156px;
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-border-settings {
    grid-template-columns: minmax(0, 312px) 60px;
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-setting-row,
  body.page-scrape #imageToolsModal .image-tools-editor-row {
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-editor-text .image-tools-text-input {
    max-width: 160px;
  }
}

@media (max-width: 1099px) {
  body.page-scrape .ai-image-panel.image-tools-workspace,
  body.page-scrape .white-bg-panel.image-tools-workspace,
  body.page-scrape .watermark-shell.image-tools-workspace,
  body.page-scrape .image-delete-shell.image-tools-workspace {
    grid-template-columns: 210px minmax(0, 1fr);
  }

  body.page-scrape .image-tools-workspace > .image-tools-operation-card {
    grid-column: 2;
  }

  /* 2026-10-25 十七轮：这一档右栏被 grid-column: 2 挤到第二行，只有约 360px 高，
     而卡片里「标题 + 预览框 290 + 汇总行 + 状态行 + 主按钮」叠起来约 470px，
     超出部分被 .image-tools-column-card 的 overflow: hidden 直接裁掉 ——
     实测 AI 生图单商品按钮被裁到卡片外 225px（点不到），水印 97px。
     这是本轮之前就有的老问题（把本轮所有改动临时回退后数字一致），
     只是本轮在量「撑到底」时一并量了出来，顺手修掉：
     窄屏下让右栏自己滚，按钮至少能滚到、能点到。宽屏（>1099px）三列并排、高度足够，不受影响。 */
  body.page-scrape .image-tools-workspace > .image-tools-operation-card,
  body.page-scrape .image-tools-workspace > .watermark-preview-pane {
    overflow-y: auto;
  }

}

@media (max-width: 899px) {
  body.page-scrape #imageToolsModal.modal-overlay {
    padding: 12px;
  }

  body.page-scrape #imageToolsModal .modal-container {
    width: calc(100vw - 24px) !important;
    max-width: calc(100vw - 24px);
    height: auto;
    max-height: calc(100vh - 24px);
  }

  body.page-scrape .ai-image-panel.image-tools-workspace,
  body.page-scrape .white-bg-panel.image-tools-workspace,
  body.page-scrape .watermark-shell.image-tools-workspace,
  body.page-scrape .image-delete-shell.image-tools-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  body.page-scrape .image-tools-workspace > .image-tools-operation-card {
    grid-column: auto;
  }

  body.page-scrape .image-tools-selection-card {
    width: min(100%, 270px);
  }

  body.page-scrape .image-tools-thumbnail-grid,
  body.page-scrape .ai-image-grid.image-tools-thumbnail-grid,
  body.page-scrape .white-bg-grid.image-tools-thumbnail-grid,
  body.page-scrape .watermark-image-list.image-tools-thumbnail-grid {
    grid-template-columns: repeat(2, minmax(96px, 112px));
    justify-content: start;
    max-height: 380px;
  }
}

@media (max-width: 640px) {
  body.page-scrape #imageToolsModal .image-tools-watermark-editor {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-template-areas:
      "text"
      "size"
      "opacity"
      "position";
  }

  body.page-scrape #imageToolsModal .image-tools-editor-position {
    grid-area: position;
    width: 156px;
    min-width: 156px;
    height: 124px;
  }

  body.page-scrape #imageToolsModal .image-tools-editor-row {
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-setting-row {
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-border-settings {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
}

@media (max-width: 560px) {
  body.page-scrape .image-tools-modes {
    width: 100%;
  }

  body.page-scrape .image-tools-mode {
    min-width: 0;
    flex: 1 1 0;
    padding: 0 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-field-row--range {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
  }

  body.page-scrape #imageToolsModal .image-tools-setting-row {
    gap: 8px;
  }

  body.page-scrape #imageToolsModal .image-tools-choice-group,
  body.page-scrape #imageToolsModal .image-tools-wrap-row {
    gap: 8px 12px;
  }

  body.page-scrape .watermark-template-tools {
    grid-template-columns: auto minmax(0, 1fr);
  }

  body.page-scrape .watermark-template-tools .btn {
    grid-row: 2;
  }

  body.page-scrape #globalModal.erp-edit-modal .erp-card-head {
    align-items: stretch;
    flex-direction: column;
  }

  body.page-scrape #globalModal.erp-edit-modal .erp-image-tools-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ===== 20260827 image tools background jobs + wider image chooser ===== */
body.page-scrape .white-bg-panel.image-tools-workspace {
  grid-template-columns: 300px minmax(340px, 1fr) 360px;
}

body.page-scrape .white-bg-target-heading {
  grid-column: 1 / -1;
  padding: 5px 2px 2px;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

body.page-scrape .white-bg-image-card.is-sku-image .image-tools-thumbnail-name {
  color: #7c3aed;
}

body.page-scrape .image-task-persistent-notices {
  position: fixed;
  top: 72px;
  right: 18px;
  z-index: 10080;
  display: grid;
  width: min(360px, calc(100vw - 36px));
  gap: 10px;
  pointer-events: none;
}

body.page-scrape .image-task-persistent-notice {
  pointer-events: auto;
  display: grid;
  gap: 7px;
  padding: 12px 13px;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #2563eb;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(15, 23, 42, .2);
  color: #334155;
  font-size: 12px;
  line-height: 1.45;
}

body.page-scrape .image-task-persistent-notice.is-success { border-left-color: #16a34a; }
body.page-scrape .image-task-persistent-notice.is-warning { border-left-color: #d97706; }
body.page-scrape .image-task-persistent-notice.is-error { border-left-color: #dc2626; }

body.page-scrape .image-task-persistent-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #0f172a;
}

body.page-scrape .image-task-persistent-head strong {
  min-width: 0;
  font-size: 13px;
  font-weight: 900;
}

body.page-scrape .image-task-persistent-close {
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border: 0;
  border-radius: 7px;
  background: #f1f5f9;
  color: #64748b;
  cursor: pointer;
  font-size: 17px;
  line-height: 1;
}

body.page-scrape .image-task-persistent-detail { font-weight: 700; }
body.page-scrape .image-task-persistent-meta { color: #64748b; }

@media (max-width: 1399px) {
  body.page-scrape .white-bg-panel.image-tools-workspace {
    grid-template-columns: 260px minmax(300px, 1fr) 290px;
  }
}

@media (max-width: 1099px) {
  body.page-scrape .white-bg-panel.image-tools-workspace {
    grid-template-columns: 240px minmax(0, 1fr);
  }
}

@media (max-width: 899px) {
  body.page-scrape .white-bg-panel.image-tools-workspace {
    grid-template-columns: minmax(0, 1fr);
  }
  body.page-scrape .image-task-persistent-notices {
    top: 12px;
    right: 12px;
    width: min(360px, calc(100vw - 24px));
  }
}


/* ===== 2026-09-19 图片处理：四个 tab 统一高度，切换不再跳动 =====
   2026-10-23 关键修复（真实 DOM 实测出来的）：content 必须**自己就是滚动容器**。
   原因链：modal-body 是 flex: 1 1 auto + overflow: hidden（979px），
   而 content 只写 height: 100% —— 在「父级是 hidden 的 flex 子项」这种情况下，
   子元素的 100% 会退化成按内容算，实测 content 被撑到 **9833px**，
   然后 panel / workspace / settings 全部跟着 9833px，设置列的 scrollH === clientH 于是不滚，
   modal-body 又 hidden 裁掉 —— 结果就是「看不到下面的图、也没有滚动条」。
   现在给 content 同时写 height: 100% + max-height: 100% + overflow-y: auto：
   它成为弹窗内部唯一的长滚动容器，四个 tab 的高度都锁在 modal-body 里。 */
body.page-scrape #imageToolsModal .image-tools-content,
/* 水印 tab 有一条专属规则 #imageToolsModal[data-active-image-tool-tab="watermark"] .image-tools-content
   把高度顶回 auto，这里用同样的权重 + 更靠后的位置覆盖它 */
body.page-scrape #imageToolsModal[data-active-image-tool-tab="watermark"] .image-tools-content {
  flex: 1 1 0;
  height: 100%;
  max-height: 100%;
  /* min-height: 360px 保留（测试 100 守着「小屏兜底」）；同时靠 flex: 1 1 0 让它
     在 flex 父级里可收缩，两者不冲突 —— flex-basis: 0 决定了收缩基准，
     min-height 只是下限保护，真实高度仍由父级（modal-body）的可用空间决定。 */
  min-height: 360px;
  /* 2026-10-23 五轮定案：content **不滚**（overflow-y: hidden），只当限高容器。
     滚动条要出现在「中间列（处理范围）右边缘」而不是弹窗最右侧，
     所以滚动容器必须是 .image-tools-settings-column（见下面那条）。
     content 只负责把高度钉在 modal-body 内，让下面三列拿到确定的 100%。 */
  overflow-y: hidden;
  overflow-x: hidden;
  padding-right: 0;
}

/* 2026-10-23 最终形态：滚动容器是 **.image-tools-content**（弹窗内容区本身）。
   panel 必须限高（height: 100%）+ 不裁（overflow: visible），
   这样它的子级 .image-tools-workspace 才能拿到确定的 100% 高度，
   三列才能各自 height: 100%、由中间那一列自己滚。
   ⚠️ panel 不能写 overflow: hidden —— 会把中间列的滚动条裁掉（前几轮踩过）。 */
body.page-scrape #imageToolsModal .image-tools-panel {
  height: 100%;
  min-height: 0;
  overflow: visible;
}

/* 批量进度：一行紧凑信息，替代原来基本空着的大预览框。
   2026-10-25 四栏统一：它占的就是另外三栏「汇总行」那一格，所以尺寸/配色向
   .image-tools-run-summary 看齐（min-height 34 / padding 7px 9px / 圆角 7 /
   11px / #64748b）—— 原来 12px + 8px 圆角 + 8px 内边距，并排看会显得比别栏「胖一圈」。 */
body.page-scrape .image-tools-progress-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 7px 9px;
  border: 1px solid #e5eaf0;
  border-radius: 7px;
  background: #f8fafc;
  font-size: 11px;
  line-height: 1.35;
  color: #64748b;
}

/* ===== 2026-09-19 四列宽统一收口（放在文件末尾，覆盖各面板历史上的专属宽度） ===== */
body.page-scrape .ai-image-panel.image-tools-workspace,
body.page-scrape .white-bg-panel.image-tools-workspace,
body.page-scrape .watermark-shell.image-tools-workspace,
body.page-scrape .image-delete-shell.image-tools-workspace {
  grid-template-columns: 220px minmax(420px, 1fr) 360px;
}

@media (max-width: 1399px) {
  body.page-scrape .ai-image-panel.image-tools-workspace,
  body.page-scrape .white-bg-panel.image-tools-workspace,
  body.page-scrape .watermark-shell.image-tools-workspace,
  body.page-scrape .image-delete-shell.image-tools-workspace {
    grid-template-columns: 200px minmax(360px, 1fr) 290px;
  }
}

/* ⚠️ 2026-10-20 补：899px 这一档必须在这里重复一遍。
   这段「四列宽统一收口」放在文件末尾、选择器权重与前面各面板的响应式规则相同，
   于是它按源序把前面所有断点一起盖掉了 —— 原来只写了 1399px 一档，
   结果视口 820px / 900px 时仍是 `200px minmax(360px,1fr) 290px` 三列固定，
   横向溢出 211px，「批量结果」列和「开始批量生成白底图」按钮被挤出屏幕外点不到。
   实测（CDP，视口 820）：修复前 gridTemplateColumns = 200px 360px 290px、按钮 right=901 > vw 820；
   修复后 = 单列、按钮 right=763 < 820 可点。
   ⚠️ 只补 899 这一档，**不要**把 1099 也改成两列：`image-tools-thumbnail-grid-cascade.test.js`
   断言四个 tab 在 1399px 及以下必须是 `200px minmax(360px, 1fr) 290px`（三列），
   加 1099 两列会让 3 条守卫测试变红（2026-10-20 实测踩过）。 */
@media (max-width: 899px) {
  body.page-scrape .ai-image-panel.image-tools-workspace,
  body.page-scrape .white-bg-panel.image-tools-workspace,
  body.page-scrape .watermark-shell.image-tools-workspace,
  body.page-scrape .image-delete-shell.image-tools-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  /* 单列时把前面 1099px 断点留下的 `grid-column: 2` 一起清掉：
     单列只有 1 条轨道，`grid-column: 2` 会隐式生成第 2 条轨道，
     结果卡被挤到右半屏、和设置列重叠（实测 820px 下「批量规则」压住「处理范围」）。
     用 `> *` 兜底，避免以后新增子元素又漏掉。 */
  body.page-scrape .image-tools-workspace > .image-tools-operation-card,
  body.page-scrape .image-tools-workspace > * {
    grid-column: auto;
  }
}

/* ===== 2026-10-10 「删图」面板紧凑化：同样的信息占更少纵向空间 =====
   选择器全部带 .image-delete-shell / .image-delete-image-grid / .image-delete-image-card。
   .image-delete-image-grid 现在只用在「描述图」网格上（删图 tab 右侧 data-image-delete-desc-grid
   + 失败详情 / 图片待人工处理两处入口共用的那个网格）；左侧「商品图片」网格改用了
   .image-delete-product-grid，两边不共用 class，所以下面这批压缩不会漏到左栏。
   AI 图 / 白底图 / 水印三个 tab 沿用的 .image-tools-* 共用规则一律不动。
   放在文件末尾是为了在同等权重下靠后生效。
   2026-10-10 回退 1：这里原先还给 .image-delete-position-* 加过一批 chip 压缩（chip 内边距
   6px 4px -> 4px 3px、序号 15px -> 13px 等），结果只有删图 tab 的「商品图片」那块变紧、
   与其它 tab 不一致，整批已移除；序号 chip 一律沿用它自己的 .image-delete-position-* 原有
   规则，本文件不再覆盖它。
   2026-10-10 回退 2：左侧「商品图片」网格原来也用 .image-delete-image-grid，于是
   gap 8px -> 6px、padding 1px 3px 1px 1px -> 1px 2px 1px 1px、以及 >=900px 的
   grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) 一起漏到了左栏
   （选择器同权重 0,2,1，只靠源序取胜）。现在左侧容器不再匹配下面任何一条，
   网格回到 .image-tools-thumbnail-grid 共用规则，卡片回到 .image-tools-thumbnail-card
   共用数值，与 AI 图 / 白底图 / 水印完全一致；右侧描述图的紧凑效果原样保留。 */

/* 设置列与分区：原来的 18px/16px 上下留白收掉。
   2026-10-24 与白底图 tab 统一格式：左右从 14px 改成 16px、上下从 2px 改成 0 ——
   删图中间列现在也有吸顶大标题（.white-bg-picker-section-head 那一套），
   它靠 margin: 0 -16px 吃掉列的左右内边距，并且要求列顶没有 padding，
   否则标题条吸顶时上方会留一条缝（白底图那一轮已经踩过、注释里写清楚了）。 */
body.page-scrape .image-delete-shell .image-tools-settings-column {
  padding: 0 16px;
}

/* 2026-10-24 用户反馈「描述图和下面标题的间距和白底图不一样」——
   删图这边原来有一条紧凑档覆盖 gap: 9px / padding: 11px 0，白底图走的是共用规则的
   16px / 18px 0。实测标题条下沿到第一张图：删图 17px（8px margin-bottom + 9px gap），
   白底图 24px。中间列既然已经换成白底图那套吸顶标题，段内疏密也得是同一套，
   否则同一套标题配两种留白，看起来就是「这里比那里紧」。
   处理方式是把那条覆盖**整条删掉**，而不是改成和共用规则一样的值 ——
   同一个数值写在两处，下次任何一边调整都会重新分叉，这次的差异就是这么来的。
   删图现在直接吃 `body.page-scrape #imageToolsModal .image-tools-section`（16px / 18px 0），
   与 AI 图 / 白底图 / 水印三个 tab 同源。 */

/* 第一段去掉上内边距：吸顶标题条要严丝合缝贴住列顶（与白底图同一条规则）。 */
body.page-scrape #imageToolsModal .image-tools-form--delete > .image-tools-section:first-child {
  padding-top: 0;
}

/* ===== 2026-10-24 删图左栏三个模块（与白底图 tab 同一套读法）=====
   用户要求「和白底图 tab 统一格式，包括文案精简」。白底图左栏是三个带标题的模块
   （可处理图片 / 处理范围 / 写回方式），这里照搬成（可处理图片 / 删除范围 / 同步方式）：
     · 模块壳 = .image-tools-info-block.image-delete-left-block（灰底 + 圆角 + 11px 12px 内边距）；
     · 模块标题 = .image-delete-left-block-title，与 .white-bg-left-block-title 逐属性一致
       （36px 高 / 13px / 850 字重 / 左侧 3px 蓝竖条），运营在两个 tab 之间切换时看到的是同一个标题。 */
body.page-scrape .image-delete-left-block {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 11px 12px;
  border-radius: 7px;
  background: #f8fafc;
}

/* 2026-11-16 用户：「间距有问题，和ai生图的不一样」。
   删图「可处理图片」这块同时挂着 .image-tools-info-block（gap 4px）与
   .image-delete-left-block（gap 8px，后者在文件里更靠后、同权重胜出），所以它的四行读数
   比 AI 生图 / 白底图那两块（只有 .image-tools-info-block）松一倍。四行内容已经逐行对齐了，
   行距也得一样 —— 只收这一块，下面「删除范围 / 同步方式」的按钮与 chip 仍按 8px。 */
body.page-scrape .image-delete-left-block[data-image-delete-plan-info] {
  gap: 4px;
}

body.page-scrape .image-delete-left-block-title {
  display: flex;
  align-items: center;
  min-height: 36px;
  margin: 0;
  padding: 0 0 0 8px;
  border-left: 3px solid #2563eb;
  color: #334155;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .2px;
}

/* 左栏「删除范围」里的三个模式 + 「同步方式」那一项：左栏只有 220px，一行一个纵向排。
   2026-10-24 用户要求「删除范围和同步方式中的选择框里的文字大小和样式，
   和白底图中的处理范围模块里的文字统一」——
   逐属性对齐白底图「处理范围」里的 .white-bg-scope-chip（13px / 600 / #334155 /
   1px #dbe2ea / 圆角 8 / 白底 / 30px 高 / 左右 10px / gap 6 / 勾选框 14px），
   所以这里只保留「选择器要落在删图左栏」这一条差异，视觉数值全部与白底图相同。 */
/* 选择器里多带一层 .image-delete-shell 不是装饰：文件更靠后的
   `.image-delete-shell .image-tools-choice`（11.5px / 30px / 9px，0,3,1）
   和这里同权重，靠源序会赢 —— 少了这一层，字号就还是 11.5px。
   带上 shell 后是 0,4,1，无论后面再加什么紧凑规则都稳。 */
body.page-scrape #imageToolsModal .image-delete-shell .image-delete-left-block .image-tools-choice-group {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}

body.page-scrape #imageToolsModal .image-delete-shell .image-delete-left-block .image-tools-choice {
  min-height: 30px;
  gap: 6px;
  padding: 0 10px;
  border-color: #dbe2ea;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

body.page-scrape #imageToolsModal .image-delete-shell .image-delete-left-block .image-tools-choice input[type="checkbox"] {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  margin: 0;
}

/* 模块一「批量商品 / 选择图片」：这一块原来是直接贴在卡片上的标题行 + 按钮行，
   2026-10-24 用户要求它和另外三个模块同一层级，所以也套了 .image-delete-left-block。
   标题沿用共用的 .image-tools-card-title（不改共用规则），只在删图左栏里补上
   与模块标题完全一致的蓝竖条 / 字号 / 字重 —— 四个模块的标题看起来是同一种东西。 */
body.page-scrape .image-delete-left-block--select .image-tools-card-head {
  min-width: 0;
}

body.page-scrape .image-delete-left-block--select .image-tools-card-title {
  min-height: 36px;
  display: flex;
  align-items: center;
  padding: 0 0 0 8px;
  border-left: 3px solid #2563eb;
  color: #334155;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .2px;
}

/* 左栏商品图序号 chip：中间列那档是「5 列 + 大序号 + 主图/第 N 张标签」，
   在 220px 的左栏里每格只剩 28px，勾选框会盖住序号、标签会被省略号吃掉。
   这里换成**纯序号方块**：5 列 × 2 行（10 个序号 = 61px 高，原来竖排要 170px），
   序号 12px 居中，勾选框隐掉（整块 chip 就是 <label>，点一下即勾选），
   选中态沿用 .image-delete-position-chip.is-selected 的红框红底 —— 一眼看出会删哪几张。
   标签（主图 / 第 N 张）不丢：它仍在 title 里，鼠标停一下就能看到。 */
body.page-scrape .image-delete-left-block .image-delete-position-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 5px;
}

body.page-scrape .image-delete-left-block .image-delete-position-chip {
  flex-direction: row;
  justify-content: center;
  gap: 0;
  min-height: 28px;
  padding: 0;
}

/* 勾选框只承载状态，不参与视觉：chip 本身就是 <label>，点哪儿都能勾上。 */
body.page-scrape .image-delete-left-block .image-delete-position-chip input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

body.page-scrape .image-delete-left-block .image-delete-position-number {
  font-size: 12px;
  line-height: 1;
}

/* 左栏放不下「主图 / 第 N 张」这行小字，隐掉（title 里仍然有），
   换来的是一屏能看全 10 个序号，不用滚左栏。 */
body.page-scrape .image-delete-left-block .image-delete-position-label {
  display: none;
}

/* 左栏里的风险提示 / 统一序号说明：220px 宽，收成一行浅色说明条，
   不再占中间列那种 6px 9px + 边框的醒目块（那会把左栏顶得很高）。
   文字仍然完整可见 —— 这两条是拦不可逆误操作的，不能裁。 */
body.page-scrape .image-delete-left-block .image-delete-risk-note {
  padding: 5px 8px;
  border-radius: 6px;
  font-size: 10.5px;
  line-height: 1.45;
}

body.page-scrape .image-delete-left-block .image-delete-advanced-note {
  padding: 5px 8px;
  border-radius: 6px;
  background: #fff;
  font-size: 10.5px;
  line-height: 1.45;
}

/* 说明区（读取中 / 删除后说明）：行高与内边距一起收。
   2026-10-24：把左栏那三个模块（.image-delete-left-block）排除在外 —— 它们也是
   .image-tools-info-block，但走的是白底图那套模块壳（11px 12px / gap 8px）。
   不排除的话这条（源序更晚、权重 0,3,1）会把模块壳压成 7px 9px / gap 2px，
   左栏看起来就比白底图紧一圈。 */
body.page-scrape .image-delete-shell .image-tools-info-block:not(.image-delete-left-block) {
  gap: 2px;
  padding: 7px 9px;
  font-size: 11px;
  line-height: 1.4;
}

/* 风险提示条：沿用共用组件的琥珀色警示配色，只占一行 */
body.page-scrape .image-delete-risk-note {
  padding: 6px 9px;
  border: 1px solid #fcd34d;
  border-radius: 6px;
  background: #fffbeb;
  color: #92400e;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.45;
}

/* 三个复选框那一块：38px 的胶囊收到 30px，换行间距一起收 */
body.page-scrape #imageToolsModal .image-delete-shell .image-tools-choice-group {
  gap: 6px 14px;
}

body.page-scrape #imageToolsModal .image-delete-shell .image-tools-choice {
  min-height: 30px;
  gap: 6px;
  padding: 0 9px;
  font-size: 11.5px;
}

body.page-scrape #imageToolsModal .image-delete-shell .image-tools-choice input {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
}

/* 缩略图网格：间距与卡片内边距收小，元信息行 24px -> 20px，角标 19px -> 17px。
   选择器只认 .image-delete-image-grid（= 描述图网格），左侧「商品图片」网格用的是
   .image-delete-product-grid，这里和下面四条都不会命中它。 */
body.page-scrape .image-delete-image-grid {
  gap: 6px;
  padding: 1px 2px 1px 1px;
}

body.page-scrape .image-delete-image-grid .image-delete-image-card.image-tools-thumbnail-card {
  grid-template-rows: auto 20px;
  gap: 4px;
  padding: 5px;
}

body.page-scrape .image-delete-image-grid .image-delete-image-card .image-tools-thumbnail-meta {
  height: 20px;
  gap: 3px;
  font-size: 10.5px;
}

body.page-scrape .image-delete-image-grid .image-delete-image-card .image-tools-thumbnail-badge {
  min-height: 17px;
  height: 17px;
  max-width: 52px;
  padding: 0 4px;
  font-size: 9.5px;
  line-height: 17px;
}

body.page-scrape .image-delete-image-grid .image-delete-image-card input[type="checkbox"] {
  top: 6px;
  left: 6px;
  width: 16px;
  height: 16px;
}

/* 缩略图尺寸收敛 = 一屏更多张：按可用宽度自适应多列，单列下限 150px 保证
   「第 N 张描述图 + 角标」不截断；>=900px 才生效，<=899px 沿用既有的两列小图规则。
   只作用于描述图网格（.image-delete-image-grid），不要用到左侧 .image-delete-product-grid，
   左栏轨道只有 220px，装不下两列 150px 会变成一整列大图。 */
@media (min-width: 900px) {
  body.page-scrape .image-delete-image-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  }
}

/* ===== 2026-10-18 「删图」批量模式：逐个商品看到真实描述图并分别勾选 =====
   改之前批量模式左栏只有一句「批量模式按序号统一删除」，一张图都看不到，
   运营只能按统一序号盲删（勾「2」= 删每个商品的第 2 张）。
   现在中间设置列按商品分组列出**每个商品自己的**描述图缩略图，看着图逐张勾选，
   提交时映射成 descriptionTargets: [{ productId, positions }]。
   下面这批只命中 .image-delete-batch-*，不碰 AI 图 / 白底图 / 水印三个 tab 的共用规则，
   也不改 .image-delete-shell 的三列宽度 —— 缩略图铺在 minmax(420px, 1fr) 那一条轨道上，
   150px 起跳的 .image-delete-image-grid 在这里能铺 2~3 列。 */

/* 进度行：已读取 x/N 个商品（含读取失败数）。失败必须写出来，不能只显示「已读取」。 */
body.page-scrape .image-delete-batch-summary {
  padding: 6px 9px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.45;
}

/* 2026-10-24 与白底图批量选图区统一（用户要求「和白底图 tab 统一格式」）：
   列表**不再自己滚**、不再限高 —— 滚动只留设置列一处（它的 overflow-y: auto 是共用规则）。
   原来这里是 min(420px, calc(100vh - 330px)) + overflow-y: auto，而设置列从 2026-10-23 起
   也已经是滚动容器，于是变成「框里套框」：滑到底先卡住、再滑外层，运营体感就是卡顿。
   白底图那一轮同样改成「列表 overflow: visible」，这里逐属性对齐。 */
body.page-scrape .image-delete-batch-list {
  display: grid;
  gap: 7px;
  max-height: none;
  overflow-x: visible;
  overflow-y: visible;
  padding-right: 0;
  scrollbar-gutter: auto;
  scrollbar-width: auto;
}

/* 商品分组去掉外框（原来是 border + 圆角 + 白底），与白底图一致：
   只留一条淡淡的下分隔线 + 一点内边距，视觉上从「三层框」降到「一层框」（只有图片自己有框）。 */
body.page-scrape .image-delete-batch-product {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 2px 0 12px;
  border: 0;
  border-bottom: 1px solid #eef2f7;
  border-radius: 0;
  background: transparent;
}

/* 最后一组不再画分隔线，避免列表底部多一条线。 */
body.page-scrape .image-delete-batch-product:last-child {
  border-bottom: 0;
  padding-bottom: 2px;
}

body.page-scrape .image-delete-batch-product-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

/* 组标题 = 「#商品ID 商品标题」：标题可能很长，收成一行带省略号，完整内容在 title 属性里 */
body.page-scrape .image-delete-batch-product-title {
  min-width: 0;
  overflow: hidden;
  color: #0f172a;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .image-delete-batch-product-count {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 10.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* 组头右侧那一小块：小号「全选 / 取消全选」按钮 + 计数角标。
   按钮只作用于**这个商品自己的**描述图勾选框（见 template-tools.js 的
   buildBatchDescriptionPickerHtml / syncBatchGroupSelectAllUi）。 */
body.page-scrape .image-delete-batch-product-tools {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

/* 必须是"小号"：组头这一行的高度由标题决定（11.5px 单行），照左栏
   .image-tools-bulk-actions 的 30px 写会把组头撑高、把标题挤成两行 ——
   左栏/设置列的宽度一直很紧，这正是切 tab 时跳动的一个来源。
   所以显式给 20px 高：通用 .btn 的 32px 在这里必须被压掉（本规则在文件里更靠后，
   同特异度，靠后生效）。 */
body.page-scrape .image-delete-batch-product-select-all {
  height: 20px;
  min-width: 0;
  flex: 0 0 auto;
  justify-content: center;
  padding: 0 6px;
  border-color: #d7dee8;
  border-radius: 5px;
  background: #f8fafc;
  color: #1d4ed8;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

body.page-scrape .image-delete-batch-product-select-all:disabled {
  cursor: not-allowed;
  opacity: .52;
}

/* 组内状态块：读取中 / 这个商品没有描述图 / 这个商品的描述图读取失败。
   与设置列那份说明区同样收着排（11px / 7px 内边距），免得每组都被状态块撑高。 */
body.page-scrape .image-delete-batch-product .image-tools-info-block {
  gap: 2px;
  padding: 6px 8px;
  font-size: 11px;
  line-height: 1.4;
}

body.page-scrape .image-delete-batch-product .image-tools-info-block.is-pending {
  border-color: #e2e8f0;
  background: #f8fafc;
  color: #64748b;
}

/* 读取失败必须一眼看出来：它和「这个商品没有描述图」是完全不同的两件事，
   画成同一个灰盒子等于静默少算。 */
body.page-scrape .image-delete-batch-product .image-tools-info-block.is-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
  font-weight: 600;
}

/* 「按序号删除商品图（便捷方式）」：批量模式下它是次要入口，说明文字比上面淡一档 */
body.page-scrape .image-delete-advanced-note {
  padding: 5px 8px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #f8fafc;
  color: #64748b;
  font-size: 10.5px;
  line-height: 1.45;
}

/* ===== 2026-10-11 「AI 生图」tab 左栏选图区：商品图 / SKU 独立图 / 描述图 三组并存 + 多选 =====
   三组各用一个 role class，只共用 .image-tools-thumbnail-grid 这一个基类：
     商品图片   .ai-image-grid.image-tools-thumbnail-grid        （原样保留，尺寸仍 100% 吃共用规则）
     SKU 独立图 .ai-image-sku-grid.image-tools-thumbnail-grid
     描述图片   .ai-image-desc-grid.image-tools-thumbnail-grid
   下面每一条都只命中 .ai-image-sku-* / .ai-image-desc-* / .ai-image-group-* / .ai-image-card.is-unavailable，
   不写任何裸 .image-tools-thumbnail-grid 或 .ai-image-grid 选择器，所以：
     - 商品图那一组的 display / grid-template-columns / gap / padding / max-height 等仍然全部来自
       共用规则，与白底图 / 水印 / 删图三个 tab 逐属性一致（test/image-tools-thumbnail-grid-cascade.test.js 会锁住）；
     - 也不会重演 2026-10-10 删图 tab 那次事故：当时描述图的
       @media (min-width: 900px) { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
       漏到了左栏商品图，左栏轨道只有 220px（<=1399px 是 200px）装不下两列 150px，缩略图被炸成一整列大图。
   窄屏那份共用规则副本（@media (max-width: 899px) 里的 .image-tools-thumbnail-grid 一组）这次不需要同步改：
   新加的类只覆盖 max-height，而 max-height 是按 role 分开写的；窄屏副本照旧只负责两组新网格的
   grid-template-columns / justify-content，和新规则没有交集。 */
body.page-scrape .ai-image-group {
  display: grid;
  gap: 4px;
  min-width: 0;
  /* 2026-10-13 四列等高之后，这一块是左栏的「列内滚动」容器：
     三组（商品图 / SKU 独立图 / 描述图）叠起来比左栏可用高度高时，由这里滚，
     而不是把卡片顶高、进而把工作区那一行顶高。
     min-height: 0 必须有：它是 .image-tools-selection-card（flex 列）的子项，
     flex 子项默认 min-height: auto，不给 0 就压不下去、滚动条不会出现。 */
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

body.page-scrape .ai-image-group-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 5px 2px 1px;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

body.page-scrape .ai-image-group-heading span {
  color: #64748b;
  font-size: 10.5px;
  font-weight: 700;
}

body.page-scrape .ai-image-group-note {
  padding: 5px 7px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
  color: #64748b;
  font-size: 10.5px;
  line-height: 1.4;
}

/* 三组各自成网格、各自限高，叠起来不能顶穿弹窗。
   限高只写在 SKU / 描述两组自己的 role class 上，商品图那组继续用共用规则的
   min(440px, calc(100vh - 270px)) / 窄屏 380px，一个像素都不动
   （四个 tab 的「商品图片」网格逐属性同值就靠这条共用规则，test 会锁死）。

   2026-10-13 四列等高，这两条限高重新核算过：
   左栏可用高度 = 工作区高度 H - 卡片上下内边距 28px - 卡片上下边框 2px
                  - 卡片头 24px - 两处 flex gap 22px - 全选按钮行 30px
                = H - 106px
   再减掉三个组标题（各 20.3px）与组内 5 个 gap（各 4px）＝ 81px，
   留给三个网格的总高度只有 H - 187px：
     H = 720px（100vh >= 930px，面板取到上限）时约 533px
     H = 420px（小屏兜底）时约 233px
   而商品图那一组的限高被共用规则锁死在 min(440px, calc(100vh - 270px))，动不了，
   所以「三组同时装满」时总和必然超过 533px —— 这正是 .ai-image-group 要自己滚的原因。
   这两条 role 限高现在的职责是：单组图片很多时别把另外两组挤没，
   并给每组一个「一屏能看几行」的合理上限，同时用 max() 兜一个下限，
   避免 100vh 变小时 calc() 算成 0 或负数、整组直接塌成 0 高度。
   SKU 240px / 描述 200px 是按「两组加起来约 440px、与商品图那组同量级」取的。 */
body.page-scrape .ai-image-sku-grid.image-tools-thumbnail-grid {
  max-height: min(240px, max(150px, calc(100vh - 460px)));
}

body.page-scrape .ai-image-desc-grid.image-tools-thumbnail-grid {
  max-height: min(200px, max(120px, calc(100vh - 500px)));
}

/* SKU 卡片标题用紫色（与白底图 tab 的 .white-bg-image-card.is-sku-image 同一套视觉），
   描述图卡片标题用青色。role class 只挂在各自网格里，不会串到商品图。 */
body.page-scrape .ai-image-sku-card .image-tools-thumbnail-name {
  color: #7c3aed;
}

body.page-scrape .ai-image-desc-card .image-tools-thumbnail-name {
  color: #0f766e;
}

/* 主图不在 images 列里的历史数据：后端回传 index=null，前端不可勾选，压暗 + 不给手型。 */
body.page-scrape .ai-image-card.is-unavailable {
  cursor: not-allowed;
  opacity: .62;
}

/* ===== 2026-10-13 图片处理：四个 tab 工作区高度统一 + 滚动条槽位常驻（切 tab 不再跳动） =====
   运营反馈两件事：「AI 生图 / 白底图 / 水印左边的选择图片模块会跳动」、「右边的预览效果和
   删除结果的宽度也都不一样」。两个现象是同一个来源：
     1) .image-tools-workspace 原来是 height: auto + align-items: start，工作区高度 = 最高那一列
        的内容高度。AI 生图左栏是「商品图片 + SKU 独立图片 + 描述图片」三组，比只有一组的水印
        高出一倍，于是切 tab 时工作区高度跟着内容一起变；
     2) .image-tools-panel 是 height: 100% + overflow-y: auto 的滚动容器，内容高的 tab 才长出
        滚动条 —— 滚动条占掉横向宽度，工作区的可用宽度在四个 tab 之间不等（三栏里中间那列是
        minmax(420px, 1fr)，宽度差全被它吸走），整块布局跟着左右位移。

   这一轮（2026-10-13）做三件事，一栏宽度一个字都没动：
     1) 工作区高度变成确定值：height: 100% 吃满面板。面板高度 = 100% of .image-tools-content，
        而后者是 min(720px, calc(100vh - 210px))（min-height: 420px 兜底）。四个 tab 命中同一条
        规则、同一个声明值，随视口自适应，不再随内容变化。
     2) 面板常驻滚动条槽位（scrollbar-gutter: stable）：滚动条的有无不再改变工作区宽度。
        于是四个 tab 的三栏轨道宽度、右栏卡片实际宽度，在任何内容高度下都相同。
     3) 四列改成等高（align-items: stretch，见上面 L7752 那条）+ 左栏卡片加 max-height。
        上一轮保留了 start，理由是「stretch 会把内容少的列拉出一大片空白 / 按内容限高又会把
        AI 生图左栏三组压到每组只剩一两行」。这一轮运营明确要求「四个 tab 左栏统一成三组、
        并且底边一动不动」，于是接受了「内容少的列下半部分是留白」这个代价：
          - 三组统一之后，四个 tab 的左栏内容量本来就接近了（删图 tab 除外，它的左栏是序号 chip）；
          - 真正会把这一行顶高的只有 AI 生图左栏那三组，所以用
            .image-tools-selection-card { max-height: <工作区高度> } 把它的 max-content 贡献夹住；
          - 卡片内部超出部分交给 .ai-image-group 自己滚（列内滚动），不再溢到卡片外面。
        高度预算（H = 工作区高度）：
          卡片内可用 = H - 28(padding) - 2(border) - 24(卡片头) - 22(两处 gap) - 30(全选行) = H - 106
          再减三组标题与组内 gap 81px ⇒ 三个网格总共只有 H - 187px。
          H = 720px 时约 533px；H = 420px 时约 233px。
          商品图那一组的限高被共用规则锁在 min(440px, calc(100vh - 270px))（动它会连带改删图 tab，
          且四个 tab 商品图网格逐属性同值这条保证会破），所以三组同时装满时总和一定超，
          这就是必须给它一个列内滚动容器的根本原因。SKU / 描述两条 role 限高按这个预算
          重算成 240px / 200px（原值 300px / 220px 是按「内容高度、只有 AI 一个 tab 在叠」写的），
          并各加一个 max() 下限防止小视口下 calc() 归零。

   三栏宽度 220px / minmax(420px, 1fr) / 360px（<=1399px 200px / minmax(360px, 1fr) / 290px）
   一个字都没动。 */

body.page-scrape .image-tools-workspace {
  height: 100%;
  min-height: 0;
}

/* 2026-10-22 修：滚动时三列被一起滚出视口，下面露出大片空白（用户 3440 带鱼屏实测）。
   复现：批量白底图中间列内容 1524px、面板 720px，滚动 500px 后三列的 getBoundingClientRect().top
   全部变成 -115 —— 整块工作区被当成一个长文档滚走了。

   ⚠️ 约束（test/image-tools-thumbnail-grid-cascade.test.js 守着，别绕）：
   - 四个 tab 的工作区**不许**加 max-height / overflow / overflow-y / padding
     （测试原文：内容高的时候由面板滚，工作面本身不被裁剪）；
   - 左栏卡片**不许**自己滚（测试 127）。
   所以修法不能动工作区，只能动**列**：让会超长的那一列自己滚，工作区靠列高被压住，
   不再被内容撑高，面板就没有可滚的余量了。 */

/* 只有设置列自己滚：它是唯一会超长的列（批量白底图的 SKU/描述图分组列表）。
   左右两列不加 overflow，保持「左栏卡片不该自己滚」的约定。
   配合下面 .image-tools-column-card 的 min-height: 0 —— grid 子项的 min-height 默认是 auto，
   不归零的话它会被内容顶到 1524px，列内滚动根本不会触发。 */
body.page-scrape .image-tools-settings-column {
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

/* 2026-10-23 改：scrollbar-gutter: stable → auto。
   原来设 stable 是为了「滚动条的有无不改变工作区宽度」（防切 tab 时三栏左右位移）。
   但副作用是：**内容根本没有超出时也会常驻一条灰色滚动条槽**（CDP 实测 panel
   clientH === scrollH === 901、canScroll=false，但 barWidth=15，说明槽位照样占着），
   用户看到的就是「白底图又多了一条滚动条」。
   2026-10-23 二轮：这条保持 stable（测试 101 守着「滚动条有无不改变工作区宽度」），
   但 panel 本身已经改成 overflow: hidden（见上面 .image-tools-panel 那条）——
   不产生滚动条时 scrollbar-gutter 根本不起作用，所以它不再画出那条多余的空槽；
   而一旦将来某个 tab 真的溢出、panel 需要滚，stable 又能保证宽度不跳。两者不冲突。 */
body.page-scrape #imageToolsModal .image-tools-panel {
  scrollbar-gutter: stable;
}

/* 「选择图片」标题行：标题和计数胶囊都锁成单行。
   换行会把卡片头从 24px 撑成两行、进而把整列顶高 —— 删图 tab 的计数原本文案是
   「N 张商品图 · M 张描述图」，在 220px 的左栏里必然折成两行（连标题都被挤成两行）。
   现在四个 tab 的计数都是「已选 N/M」短文案，两个元素都锁成单行，卡片头恒为一行。
   flex-shrink: 0 让计数胶囊保持完整，宽度不够时由标题先让位（标题同样 nowrap，
   两者都放不下时才会溢出，而实测最长的「已选 10/10」+「选择图片」≈130px < 190px 可用宽度）。 */
body.page-scrape .image-tools-card-title,
body.page-scrape .image-tools-selection-count {
  white-space: nowrap;
}

body.page-scrape .image-tools-selection-count {
  flex-shrink: 0;
}

/* ===== 2026-10-18 「删图」批量选图区瘦身：只留一层滚动 + 缩略图缩小 =====
   运营对着截图说的三条（选择逻辑不动，这一轮一个字都没碰）：
     1) 「框里套一个了，然后里面再套一个」—— 批量选图区当时有两层滚动条；
     2) 「图片看下能不能缩小点，让一个商品尽量一行显示多一点商品」——
        >=900px 的列宽是 minmax(150px, 1fr)，中间那条轨道上实测一行只排得下 3 个；
     3) 「描述图不需要放大，方便我选择」—— 小图更好勾，不要大图。

   为什么必须按 role 分 class，不能改共用规则：
     .image-delete-image-grid 在**单商品删图模式**下也在用（那里它是右侧描述图网格，
     自带限高 + 内滚动是有用的），.image-tools-thumbnail-grid 更是四个 tab 共用。
     所以批量模式的网格在 data-image-delete-batch-grid 之外多挂一个自己的 role class
     .image-delete-batch-desc-grid，下面每一条选择器都带它，且权重都高于共用规则：
       网格      body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid
                 = (0,3,1) > 共用基类 (0,2,1)、单商品描述图网格 (0,2,1)、
                   以及窄屏那份共用副本 @media (max-width:899px)（同样是 0,2,1）
       卡片/元信息/角标/勾选框 再多带 .image-delete-batch-desc-grid 与卡片 class，
                 权重 (0,5,1)~(0,5,2)，都高于单商品模式那几条 (0,4,1)/(0,4,2)。
     于是既不靠源序取胜，也不可能漏到单商品模式 / AI 生图 / 白底图 / 水印四个地方。
     三栏宽度 220px / minmax(420px, 1fr) / 360px（<=1399px 200/1fr/290）一个字没动，
     grid-template-columns 也只写在带 role class 的选择器里（历史上共用 class 把左栏
     220px 炸成一整列大图那次事故就是这么来的）。 */

/* ① 网格不再自己滚、不再自己限高：滚动只留外层 .image-delete-batch-list 一处。
   以下取值对**所有**宽度生效（写在 media query 外面），所以窄屏那份共用副本
   （@media (max-width:899px) 的 max-height: 380px + repeat(2, minmax(96px,112px))）
   也一并被覆写，不会再走回「每个商品一条内滚动条」。
   列宽改成 minmax(80px, 1fr)：自适应列数，不写死列数；配 5px 间距后实测
     中间轨道 ~620px（>=1400px 视口）→ 6 列
     中间轨道 ~720px（<=1399px / <=1099px 两栏）→ 7~8 列
     中间轨道 ~800px（<=899px 单栏，表单 720px 上限吃满）→ 8 列
   对照改之前：同样的轨道用 minmax(150px, 1fr) 只排得下 3 列。 */
body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid {
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 5px;
  max-height: none;
  overflow-x: visible;
  overflow-y: visible;
  padding: 0;
  scrollbar-gutter: auto;
  scrollbar-width: auto;
}

/* ② 卡片、缩略图、序号角标、勾选框一起缩小（仍然只命中批量选图区）。
   卡片高度 = 上下内边距 4+4 + 缩略图(方图，等于卡片内容宽) + 间距 3 + 元信息行 16 + 边框 2，
   一行 6 列时约 110px；改之前一行 3 列、每张约 211px。
   勾选框给 15px：比原来的 16px 小一档，但整张卡片是 <label>，点卡片任意位置都能勾上，
   不存在「小到点不准」——鼠标与触摸的实际命中区是整个卡片。 */
body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid .image-delete-image-card.image-tools-thumbnail-card {
  grid-template-rows: auto 16px;
  gap: 3px;
  padding: 4px;
  border-radius: 6px;
}

body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid .image-delete-image-card .image-tools-thumbnail-meta {
  height: 16px;
  gap: 2px;
  font-size: 9.5px;
}

/* 序号角标（「描述图」）跟着缩：字号 9.5 -> 8.5、高度 17 -> 14、最大宽度 52 -> 40。
   留出宽度给左边的「第 N 张描述图」——运营在这里靠序号确认删的是哪一张。 */
body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid .image-delete-image-card .image-tools-thumbnail-badge {
  min-height: 14px;
  height: 14px;
  max-width: 40px;
  padding: 0 3px;
  font-size: 8.5px;
  line-height: 14px;
}

body.page-scrape .image-delete-batch-product .image-delete-batch-desc-grid .image-delete-image-card input[type="checkbox"] {
  top: 4px;
  left: 4px;
  width: 15px;
  height: 15px;
}

/* ③ 左栏那张卡片跟着面板一起滚，不再被滚成一片空白。
   运营截图里「左边那一栏整块空白」不是没渲染（标题「批量商品」、计数「已选 N/M」、
   全选/取消全选、说明块在 DOM 里都在），而是滚动位置造成的：
     - 工作区 align-items: stretch，三个栅格区域等高，行高由**中间那一列**决定；
       批量模式中间列（逐商品分组列表 420px 上限 + 下面两个分区）约 930px，
       比面板高（面板 = .image-tools-content 的 min(720px, calc(100vh - 210px))，420px 兜底），
       于是 .image-tools-panel（height: 100% + overflow-y: auto）要滚 200~370px；
     - 左栏卡片的 max-height 与面板高度**同源同值**（都是 max(420px, min(720px, 100vh - 210px))，
       test/image-tools-thumbnail-grid-cascade.test.js 里有对账断言），所以它被夹在面板高度上、
       顶在网格行顶部；运营为了挑商品往下滚面板时，卡片本身不动，卡片里那 186px 内容
       （卡片头 24 + 全选行 30 + 说明块 80 + 内边距）先被滚出视口，剩下整片白底。
   给它 position: sticky; top: 0 之后：sticky 的活动范围正是「行高 - 卡片高」= 面板的滚动范围，
   而卡片高度恒等于面板高度，所以**任意滚动位置下卡片都刚好铺满面板**，标题 /
   全选 / 取消全选 / 说明块再也不会被滚走（内容装不下时卡片自己也不会滚：它没有 overflow 声明）。
   只作用于批量模式（.image-delete-shell--batch）：单商品删图模式与另外三个 tab 一个字不动。 */
body.page-scrape .image-delete-shell--batch .image-tools-selection-card {
  position: sticky;
  top: 0;
  /* 2026-10-24 与白底图批量左栏对齐：卡片内边距 14px -> 10px、模块间距 11px -> 10px。
     两个 tab 的左栏都是「三个模块铺满卡片宽」，卡片自己再留 14px 就等于三层嵌套很挤；
     白底图那一轮已经收到 10px，这里跟上，运营切 tab 时左栏宽度与呼吸感一致。 */
  gap: 10px;
  padding: 10px;
}

/* 三个模块在批量左栏里铺满整宽、彼此间距 10px（与白底图同一条规则）。 */
body.page-scrape .image-delete-shell--batch .image-tools-selection-card > .image-delete-left-block {
  width: 100%;
  margin: 0;
}

/* ===== 2026-10-18 批量白底图：SKU 图 / 描述图 缩略图预览 + 逐张勾选 =====
   运营原话：「白底图能不能做 sku 图片预览，还有描述图预览 …… 也是勾选可以批量操作」。
   改造前中间列只有两个「全有或全无」的开关（同时处理 SKU 独立图片 / 同时处理描述图），
   运营看不见是哪些图、也不能挑 —— 91 张 SKU 图里只想处理 20 张是做不到的。

   作用域：这一节只命中 .white-bg-batch-picker-*，一条都不碰 .image-delete-*、
   .image-tools-thumbnail-grid、左栏那套 .image-tools-bulk-actions，也不改 .white-bg-panel
   的三列模板（缩略图铺在中间那条 minmax(420px, 1fr) 轨道上）。

   为什么**不**给网格挂 .image-tools-thumbnail-grid：那条共用规则自带
   max-height + overflow-y: auto + 固定 grid-template-columns。删图批量模式当时正是因为
   共用了它才出现「框里套框」，又因为与描述图网格共用 .image-delete-image-grid 而吃到
   150px 起跳的列宽，把 220px 的左栏炸成一整列大图（2026-10-10 那次事故，
   test/image-tools-thumbnail-grid-cascade.test.js 就是为它建的）。
   这里给网格换成**自己的** class，列宽 / 间距 / 内边距 / 限高 / 滚动全部只由下面这一条
   role 链决定，从根上不可能再串到别的 tab 上。
   卡片仍然复用 .image-tools-thumbnail-card / .image-tools-thumbnail /
   .image-tools-thumbnail-meta / .image-tools-thumbnail-badge —— 那几条是**不挂在网格基类下**
   的独立规则，复用它们不会带来网格层面的耦合。

   窄屏副本：这一节没有任何 @media 变体，所以不存在「@media (max-width:899px) 里还有一份
   要同步改的副本」——那份副本（第 9295 行起）只覆盖 .image-tools-thumbnail-grid 这一个
   网格基类，本节的网格不使用它。列宽用 auto-fill 自适应，窄屏自然变少列。 */

/* 每个 role 一行：左边「全部勾上 / 全部取消」，右边「已选 M / K 张」。
   这是勾选数的**唯一权威读数** —— 上面那个开关的勾选态是从它推导的（见 template-tools.js
   里 syncPickerUi 的注释），所以这里不存在「开关勾了但其实只处理一部分」的歧义。 */
/* 左栏「已选 N/M」与「已显示 X/Y」两行（2026-10-22 从中间列搬过来）。
   固定占位（JS 空时填 &nbsp;），字号与上面的统计行一致，颜色略淡表示是辅助读数。 */
body.page-scrape .white-bg-left-stat {
  color: #475569;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 旧的中位列 picker-bar 相关样式（全选/清空按钮 + 进度 + 已选计数）已随 DOM 一起移除。
   保留 .white-bg-batch-picker-all 一条：组内那个「全选」小按钮还在用（每商品分组头上）。 */

/* 必须是「小号」按钮（20px）：这一行与上面的开关挤在设置列里，照 .btn 的 32px
   会把分区明显撑高、间距也变得很难看。与删图批量模式组内那个全选按钮同一种处理。 */
body.page-scrape .white-bg-batch-picker-all {
  height: 20px;
  min-width: 0;
  flex: 0 0 auto;
  justify-content: center;
  padding: 0 6px;
  border-color: #d7dee8;
  border-radius: 5px;
  background: #f8fafc;
  color: #1d4ed8;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

body.page-scrape .white-bg-batch-picker-all:disabled {
  cursor: not-allowed;
  opacity: .52;
}

body.page-scrape .white-bg-batch-picker-picked {
  flex: 0 0 auto;
  /* 2026-10-22：固定最小宽度 + tabular-nums，数字从「0 / 9」涨到「144 / 144」时
     右侧这块不推挤中间的进度文字，整行宽度也不变（用户要求「尽量保持不跳动」）。 */
  min-width: 88px;
  color: #0f172a;
  font-size: 10.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-align: right;
}

/* 进度 / 口径提示：2026-10-22 起它是 picker-bar 里的**行内一段文字**，
   不再是自己占一整行的带边框盒子。原来那种块状样式会让这一行在「有提示/无提示」之间
   高度从 20px 跳到 40px，把下面的缩略图列表整体顶下去（用户要求「尽量保持不跳动」）。
   现在：
     · flex: 1 1 auto + min-width: 0 → 吃掉中间剩余宽度；
     · overflow: hidden + text-overflow: ellipsis + white-space: nowrap → 超长省略不换行，
       行高恒为一行；
     · 文案为空时 JS 会填 &nbsp;（不是 hidden），所以**永远占位**，不会塌陷也不会跳动。
   内容：其中 N 张已是白底图自动跳过 · F 个商品清单读取失败（未计入）· 已显示 x/N 个商品的缩略图。
   读取失败必须写出来，不能静默算成「这个商品本来就没有图」。 */
body.page-scrape .white-bg-batch-picker-progress {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 8px;
  color: #64748b;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 20px;
  text-align: right;
}

/* 2026-10-23 四轮定案（最终形态，别再改）：
   滚动容器 = **设置列本身**，列表不自己滚。理由：
     · panel 是 overflow: hidden（为了消掉弹窗最右侧那条常驻槽），
       而 hidden 会**裁掉子元素的滚动条** —— 让列表自己滚的话，
       它的滚动条画在自己右边缘、正好被 panel 裁掉，结果「能滚但看不见也拖不动」
       （CDP 实测：list clientH 689 / scrollH 2641 / canScroll=true，但 barW 被裁成 0）。
     · 设置列是 panel 的直接子级，它的滚动条画在列自己的右边缘、在 panel 可见区内，
       所以看得见也拖得动 —— 位置正好在中间列内部右侧，与删图观感一致。
   配套：列表必须 overflow: visible（不自己滚），否则两层滚动条叠一起。 */
body.page-scrape .white-bg-batch-picker-list {
  display: grid;
  gap: 7px;
  max-height: none;
  overflow-x: visible;
  overflow-y: visible;
  padding-right: 0;
  scrollbar-gutter: auto;
  scrollbar-width: auto;
}

/* 2026-10-23 八轮收口：去掉商品分组这层外框（原来是 border + 圆角 + 白底），
   用户反馈「本身这个图片一个框，图片外面一个框，然后标题外面再一个框，就很不好看」。
   现在改成：**只有图片自己有框**，商品分组只留一条淡淡的下分隔线 + 一点内边距，
   视觉上从「三层框」降到「一层框」，列表也显得更通透。 */
body.page-scrape .white-bg-batch-picker-product {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 2px 0 12px;
  border: 0;
  border-bottom: 1px solid #eef2f7;
  border-radius: 0;
  background: transparent;
}

/* 最后一组不再画分隔线，避免列表底部多一条线。 */
body.page-scrape .white-bg-batch-picker-product:last-child {
  border-bottom: 0;
  padding-bottom: 2px;
}

body.page-scrape .white-bg-batch-picker-product-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

/* 组标题 =「#商品ID 商品标题」：标题可能很长，收成一行带省略号，完整内容在 title 属性里。 */
body.page-scrape .white-bg-batch-picker-product-title {
  min-width: 0;
  overflow: hidden;
  color: #0f172a;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .white-bg-batch-picker-product-count {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 10.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

body.page-scrape .white-bg-batch-picker-product-tools {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

/* 组内「全选 / 取消全选」：只作用于**这个商品自己的**这一 role 的图。
   同样必须 20px 高 —— 组头那一行的高度由标题（11.5px 单行）决定，
   照 .btn 的 32px 写会把组头撑高、把标题挤成两行。 */
body.page-scrape .white-bg-batch-picker-product-select-all {
  height: 20px;
  min-width: 0;
  flex: 0 0 auto;
  justify-content: center;
  padding: 0 6px;
  border-color: #d7dee8;
  border-radius: 5px;
  background: #f8fafc;
  color: #1d4ed8;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

body.page-scrape .white-bg-batch-picker-product-select-all:disabled {
  cursor: not-allowed;
  opacity: .52;
}

/* 组内状态块：滚到这里时显示 / 这个商品没有这一类的图 / 这个商品清单读取失败。 */
body.page-scrape .white-bg-batch-picker-product .image-tools-info-block {
  gap: 2px;
  padding: 6px 8px;
  font-size: 11px;
  line-height: 1.4;
}

body.page-scrape .white-bg-batch-picker-product .image-tools-info-block.is-pending {
  border-color: #e2e8f0;
  background: #f8fafc;
  color: #64748b;
}

/* 读取失败必须一眼看出来：它和「这个商品没有这一类的图」是完全不同的两件事，
   画成同一个灰盒子等于静默少算（运营会以为这个商品本来就没有图）。 */
body.page-scrape .white-bg-batch-picker-product .image-tools-info-block.is-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
  font-weight: 600;
}

/* ① 缩略图网格：列宽 / 间距 / 内边距 / 限高 / 滚动全部只在这一条 role 链上。
   不内滚动、不限高（滚动只留外层 .white-bg-batch-picker-list 一处），
   列宽 80px 起跳、一行 5~8 个 —— 与删图批量模式同一档密度（运营要「一行看到多一点」）。 */
body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  align-content: start;
  gap: 5px;
  min-height: 0;
  max-height: none;
  overflow-x: visible;
  overflow-y: visible;
  padding: 0;
  scrollbar-gutter: auto;
  scrollbar-width: auto;
}

/* ② 卡片：批量选图区要密（元信息行 16px / 间距 3px / 内边距 4px）。
   卡片本身仍是 .image-tools-thumbnail-card，缩略图与信息行的共用规则一律保留。 */
body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card.image-tools-thumbnail-card {
  grid-template-rows: auto 16px;
  gap: 3px;
  padding: 4px;
}

body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card .image-tools-thumbnail-meta {
  height: 16px;
  font-size: 9.5px;
}

body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card .image-tools-thumbnail-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card .image-tools-thumbnail-badge {
  height: 14px;
  max-width: 44px;
  overflow: hidden;
  font-size: 8.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ③ 勾选框 15px @ top/left 4px。body.page-scrape input[type="checkbox"] 给了
   height: 34px + border + background，这里是卡片内的小勾选框，必须逐条重置掉
   （与四个 tab 左栏那条共用规则同一份清单）。整张卡片是 <label>，
   所以点卡片任意位置都能勾上，缩小勾选框不会点不准。 */
body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card input[type="checkbox"] {
  position: absolute;
  top: 4px;
  left: 4px;
  z-index: 2;
  width: 15px;
  height: 15px;
  margin: 0;
  appearance: auto;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  accent-color: #2563eb;
  cursor: pointer;
}

/* ④ 选中态：与白底图 tab 左栏同一套（品牌蓝描边 + 浅蓝底），
   一眼看出**实际会处理哪几张**。 */
body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card:has(input[type="checkbox"]:checked) {
  border-color: #3b82f6;
  background: #eff6ff;
  box-shadow: 0 0 0 2px rgba(37,99,235,.09);
}

/* ⑤ 已经是 white-bg 产物的 SKU 图：画出来但不可勾（勾选框 disabled），
   压暗一档 + 角标「已跳过」+ title 里写明原因。运营一眼知道「这张不会被处理」，
   不会出现「勾了却没反应」那种对不上的感觉。 */
body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card.is-skipped {
  opacity: .55;
  cursor: default;
}

body.page-scrape .white-bg-batch-picker-product .white-bg-batch-picker-grid .white-bg-batch-picker-card.is-skipped input[type="checkbox"] {
  cursor: not-allowed;
}

/* ⑥ 左栏那张卡片跟着面板一起滚（与删图批量模式同一处修复）。
   批量白底图的中间列现在多出两个分组列表（各 300px 上限），列高会明显超过面板高度，
   面板要滚 —— 不 sticky 的话左栏卡片里那点内容会先被滚出视口，只剩一片白底。
   只作用于批量模式（.white-bg-panel[data-white-bg-batch="1"]）：
   单商品白底图面板与另外三个 tab 一个字不动
   （test/image-tools-thumbnail-grid-cascade.test.js 断言过另外三个 tab 的
    左栏卡片没有 position 声明 —— 它的目标 shell 不带 data-white-bg-batch，所以不会命中）。 */
/* 2026-10-23 十一轮（用户要求）：「将左栏三个模块再扩到外部层级来」。
   原来左栏卡片 padding 14px + 每个模块自己再 padding 11px 12px，三层嵌套很挤。
   现在卡片 padding 收到 10px，三个模块**直接铺满卡片宽度**（模块自身仍保留内边距，
   那是内容与模块框之间的呼吸，不是浪费）。 */
body.page-scrape .white-bg-panel[data-white-bg-batch="1"] .image-tools-selection-card {
  position: sticky;
  top: 0;
  gap: 10px;
  padding: 10px;
}

/* 三个模块在左栏里铺满整宽、彼此间距 10px。 */
body.page-scrape .white-bg-panel[data-white-bg-batch="1"] .image-tools-selection-card > .image-tools-info-block {
  width: 100%;
  margin: 0;
}

/* ===== 2026-10-22 七轮收口：「写回方式」并入处理范围区块 =====
   原来它在面板最底部（缩略图列表下方），要滚到底才能选。现在跟四个 chip 放在同一个
   section 里，一行显示：左侧标签 + 两个 radio。窄屏自动换行。 */
body.page-scrape .white-bg-mode-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  min-width: 0;
  padding-top: 4px;
  border-top: 1px solid #eef2f7;
}

body.page-scrape .white-bg-mode-label {
  flex: 0 0 auto;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
}

/* ===== 2026-10-22 六轮收口：左栏「已选 / 进度」两行读数 =====
   从中间列搬过来（中间列的「全选/清空」按钮与 chip 重复，已删）。
   每行内部两个 role 并排，各自超长省略，行高固定 —— 不随文案变化跳动。 */
body.page-scrape .white-bg-left-stat {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  min-width: 0;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
}

body.page-scrape .white-bg-left-stat > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ===== 2026-10-23 八轮收口：左栏「处理范围」=====
   从中间列搬过来的四个 chip + 写回方式。左栏只有 220px，chip 必须能换行且不被裁，
   所以这里比中间列那版更紧凑（字号 12px、内边距 8px、gap 6px）。 */
/* ===== 2026-10-23 十轮收口：左栏三个模块的标题统一 =====
   用户要求：「处理范围、写回方式和可处理图片的文字大小和样式应该完全一致，
   分成三个模块，并且处理范围和写回方式里的字体大小应该都一致，高度我觉得至少 36px」。

   三个模块 = 「可处理图片」「处理范围」「写回方式」，都用 .white-bg-left-block-title：
     高度 36px、字号 13px、字重 850、颜色 #334155，左侧一条 3px 蓝色竖条做模块标识。
   之前的问题：.image-tools-info-block 的 strong 只设了颜色（字号继承 12px），
   而写回方式用的是 .white-bg-mode-label（13px/800）—— 三者字号字重都不一样。 */
body.page-scrape .white-bg-left-block-title {
  display: flex;
  align-items: center;
  min-height: 36px;
  margin: 0;
  padding: 0 0 0 8px;
  border-left: 3px solid #2563eb;
  color: #334155;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .2px;
}

/* 三个模块本身也要有统一的外框与间距（原来「可处理图片」有灰底、
   「处理范围」也是灰底但多了 gap: 8px 的网格，「写回方式」却没有独立框）。 */
body.page-scrape .white-bg-left-scope {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 11px 12px;
  border-radius: 7px;
  background: #f8fafc;
}

/* 写回方式这一行在模块内不再单独画分隔线（模块自己有框了）。 */
body.page-scrape .white-bg-left-scope {
  display: grid;
  gap: 8px;
  min-width: 0;
}

body.page-scrape .white-bg-left-scope .white-bg-scope-row {
  /* 2026-10-23 九轮修（用户反馈「处理范围的内容有必要那么挤在一起吗？明显空间还有那么多」）：
     之前为了塞 2×2 两列把字号压到 11.5px、行高 24px，改回单列后其实**空间是够的** ——
     CDP 实测左栏卡片可用宽 170px，chip 只需 146px。所以尺寸恢复成常规档：
     字号 13px（与中间列那版一致）、行高 30px、内边距 10px。 */
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}

body.page-scrape .white-bg-left-scope .white-bg-scope-chip {
  min-height: 30px;
  padding: 0 10px;
  gap: 6px;
  font-size: 13px;
  justify-content: flex-start;
  white-space: nowrap;
  overflow: hidden;
}

/* chip 里的勾选框恢复正常大小（之前 12px 太小，不好点）。 */
body.page-scrape .white-bg-left-scope .white-bg-scope-chip input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin: 0;
  flex: 0 0 auto;
}

/* 张数徽标贴最右，等宽数字避免跳动。 */
body.page-scrape .white-bg-left-scope .white-bg-scope-chip b {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
}

/* ===== 2026-10-23 八轮收口：SKU 图 / 描述图两段的大标题 =====
   用户反馈「SKU 图和描述图没有区分，滑到底也不知道切换到了描述图还是 SKU 图」。
   做法：每段开头一条醒目标题条 —— 左侧 4px 色条 + 加粗标题 + 张数，
   SKU 段用蓝色、描述图段用紫色，滚动时一眼能看出当前在哪一段。
   position: sticky 让它吸附在滚动容器（设置列）顶部，滑到底也始终能看到当前段名。 */
body.page-scrape .white-bg-picker-section-head {
  position: sticky;
  top: 0;
  z-index: 10;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 -16px 8px;
  padding: 10px 16px 10px 12px;
  border-left: 4px solid #2563eb;
  border-radius: 0;
  background: #eff6ff;
  /* 2026-10-24 十七轮定案（用户描述：「就像是 sku 图悬浮在半空中一样」——
     即标题条上方那条空间里露出了下面的缩略图）。

     根因：sticky 元素的背景**只覆盖自己的 border box**（38px 高）。
     滚动时它吸在列顶，但「列顶 → 标题条上沿」这一段如果存在任何间隙
     （亚像素取整、gap、上一段滚上来的内容边缘），下面的内容就会从那里透出来，
     视觉上标题条就像浮在空中、上下都漏。

     修法：用 ::before 从标题条上沿**再往上铺满一整屏高度的同色背景**。
        · bottom: 100% 让它紧贴标题条上沿往上长；
        · height 取 200vh，足够覆盖任何滚动位置；
        · background: inherit 自动跟随 SKU 蓝 / 描述紫两套配色；
        · z-index 继承标题条的 10，高于所有卡片内容；
        · pointer-events: none 不挡点击。
     这样无论上面有什么，都会被同色块盖住 —— 结构性兜底，不依赖 sticky 的吸附精度。
     注意：它会被设置列的 overflow 裁掉，不会溢出到列外。 */
}

body.page-scrape .white-bg-picker-section-head::before {
  content: '';
  position: absolute;
  /* 2026-10-24 十九轮修（用户反馈「sku 图的文字都消失了」）：
     上一版写了 z-index: 0 —— 绝对定位伪元素在层叠顺序里绘制在**行内文字之后**，
     所以整块背景把「SKU 图」「204 张」全盖住了。

     正确写法：z-index: -1 + 父级 isolation: isolate。
     父级建立层叠上下文后，z-index: -1 的子元素绘制在
     「父级背景之上、父级文字之下」——正好是我们想要的：
     背景块向外扩一圈盖住亚像素缝，文字仍然完整可见。 */
  inset: -6px -2px -3px -2px;
  background: inherit;
  pointer-events: none;
  z-index: -1;
}


body.page-scrape .white-bg-picker-section-head.is-desc {
  border-left-color: #7c3aed;
  background: #f5f3ff;
}

body.page-scrape .white-bg-picker-section-title {
  color: #1d4ed8;
  font-size: 14px;
  font-weight: 850;
  line-height: 1.3;
}

body.page-scrape .white-bg-picker-section-head.is-desc .white-bg-picker-section-title {
  color: #6d28d9;
}

body.page-scrape .white-bg-picker-section-meta {
  flex: 0 0 auto;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  white-space: nowrap;
}

body.page-scrape .white-bg-picker-section-meta b {
  color: #0f172a;
  font-weight: 850;
}

/* ===== 2026-10-23 十轮收口：「写回方式」独立模块 =====
   ⚠️ 选择器必须带 #imageToolsModal：上面 body.page-scrape #imageToolsModal .image-tools-choice
   那条（L8282 附近）权重更高，不带 ID 的话 font-size 会被它按回 12px（实测踩过）。
   与「可处理图片」「处理范围」并列，三者外框、内边距、标题样式完全一致。
   里面的两个 radio 纵向排列，高度 36px（与 chip 对齐，方便点）。 */
body.page-scrape .white-bg-left-mode {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 11px 12px;
  border-radius: 7px;
  background: #f8fafc;
}

body.page-scrape .white-bg-left-mode .white-bg-mode-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  padding-top: 0;
  border-top: 0;
}

body.page-scrape #imageToolsModal .white-bg-left-mode .image-tools-choice {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid #dbe2ea;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  transition: border-color .15s, background .15s;
}

body.page-scrape #imageToolsModal .white-bg-left-mode .image-tools-choice:hover {
  border-color: #93b4f7;
  background: #f8fbff;
}

/* 选中态：与 chip 的选中态同一套蓝色，保持左栏视觉一致。 */
body.page-scrape #imageToolsModal .white-bg-left-mode .image-tools-choice:has(input:checked) {
  border-color: #2563eb;
  background: #eff6ff;
  color: #1d4ed8;
}

body.page-scrape #imageToolsModal .white-bg-left-mode .image-tools-choice input[type="radio"] {
  width: 14px;
  height: 14px;
  margin: 0;
  flex: 0 0 auto;
}

/* ===== 2026-10-25 十八轮：AI 生图 · 批量左栏并进「三模块」=====
   用户要求：「左侧是不是要调整一下和白底图的样式一样…做成三模块这样」。

   改之前：左栏是「卡片头（批量范围 + 已选 N）+ 一个透明 .image-tools-form 里套两个
   .image-tools-section」。section 没有外框、标题是 12px 小字，与白底图 / 删图左栏那种
   「灰底模块 + 36px 蓝竖条标题」并排看完全是两套东西。

   改之后三个模块都用 .image-tools-info-block + .image-tools-left-block-title，
   数值逐条抄自白底图 .white-bg-left-scope / .white-bg-left-block-title
   （灰底 #f8fafc / 7px 圆角 / 11px 12px 内边距 / gap 8px；
    标题 36px 高 / 13px / 850 / #334155 / 左侧 3px #2563eb 竖条 / letter-spacing .2px）。

   为什么新起一个 .image-tools-left-block 而不是复用 .white-bg-left-scope：
   那个名字的规则里还挂着白底图专属的东西（.white-bg-scope-row 的网格、
   .white-bg-left-mode 的行内布局），AI 这栏一旦复用，以后改白底图会连带改到它。
   这里只共享 .image-tools-info-block 这层公共壳，模块标题类也单列一条，
   但数值与白底图 / 删图**逐属性相同** —— 这是「看起来一样」的保证。 */
body.page-scrape .image-tools-left-block {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 11px 12px;
  border-radius: 7px;
  background: #f8fafc;
}

/* 2026-11-15（用户反馈「处理范围里的按钮也没有铺满」）：AI 批量这栏用的是
   .image-tools-left-block，不带 .white-bg-left-scope，所以上面第 11366 行那条
   「单列网格 + chip 撑满 + 徽标贴右」的规则没落到它身上 —— 四格按内容宽显示，
   主图那格只剩一枚小胶囊的样子，另外三格也长短不齐。
   这里补一条同值规则，只按 AI 左栏模块类限定，不动白底图那条。 */
body.page-scrape .image-tools-left-block .white-bg-scope-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}

body.page-scrape .image-tools-left-block .white-bg-scope-chip {
  min-height: 30px;
  padding: 0 10px;
  gap: 6px;
  font-size: 13px;
  justify-content: flex-start;
  white-space: nowrap;
  overflow: hidden;
}

body.page-scrape .image-tools-left-block .white-bg-scope-chip input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin: 0;
  flex: 0 0 auto;
}

/* 张数徽标贴最右，等宽数字避免跳动（与白底图 .white-bg-left-scope 那条同值）。 */
body.page-scrape .image-tools-left-block .white-bg-scope-chip b {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
}

/* 模块一（批量范围）：里面装的是共用的 .image-tools-card-head，
   它的标题走 .image-tools-card-title。这里把标题调成与另外两个模块的
   .image-tools-left-block-title 同值（删图的 .image-delete-left-block--select 同一做法），
   否则「批量范围」会比「处理类型 / 处理范围」矮一截、字也小一号。 */
body.page-scrape .image-tools-left-block--select .image-tools-card-title {
  min-height: 36px;
  display: flex;
  align-items: center;
  padding: 0 0 0 8px;
  border-left: 3px solid #2563eb;
  color: #334155;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .2px;
}

body.page-scrape .image-tools-left-block-title {
  display: flex;
  align-items: center;
  min-height: 36px;
  margin: 0;
  padding: 0 0 0 8px;
  border-left: 3px solid #2563eb;
  color: #334155;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .2px;
}

/* 模块里的选项：与白底图「处理范围」的 chip 同档
   （13px / 30px 高 / 左右 10px / gap 6 / 勾选框 14px）。
   选择器要盖过 .image-tools-choice 的默认档，所以带上 #imageToolsModal 与模块类。 */
body.page-scrape #imageToolsModal .image-tools-left-block .image-tools-choice-group {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}

body.page-scrape #imageToolsModal .image-tools-left-block .image-tools-choice {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #dbe2ea;
  border-radius: 8px;
  background: #fff;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
}

body.page-scrape #imageToolsModal .image-tools-left-block .image-tools-choice:has(input:checked) {
  border-color: #2563eb;
  background: #eff6ff;
  color: #1d4ed8;
}

body.page-scrape #imageToolsModal .image-tools-left-block .image-tools-choice input[type="radio"] {
  width: 14px;
  height: 14px;
  margin: 0;
  flex: 0 0 auto;
}

/* 「处理类型」下面那句说明。原来套的是 .image-tools-run-summary.is-compact
   （那是给「总耗时 / 成功失败」数字读数用的灰条），在 220px 的左栏里
   会被拉成一条带边框的窄条，和模块里的选项挤在一起看不清是说明还是读数。
   改成无框的说明文字：与模块同宽、11px、行高 1.45。 */
body.page-scrape .image-tools-left-block .image-tools-left-note {
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  color: #64748b;
  font-size: 11px;
  line-height: 1.45;
  white-space: normal;
}

/* 左栏卡片：内边距与模块间距向白底图批量对齐（14px/11px -> 10px/10px）。
   两个 tab 的左栏都是「三个灰底模块铺满卡片宽」，卡片再留 14px 就等于三层嵌套。 */
body.page-scrape .ai-batch-panel .image-tools-selection-card {
  gap: 10px;
  padding: 10px;
}

/* 2026-11-15：采集时间从「店铺名下方单独一行」改成「跟在店铺名右边」。
   原因：每个店铺行被时间撑到 45px，余额表一屏只能看 10 家（用户反馈）。
   改 inline 后行高回到 30px，同一块面板能看 17 家。
   display:flex 会独占一行，所以这里必须是 inline。 */
body.page-scrape .quota-table td .quota-meta {
  display: inline;
  margin: 0 0 0 6px;
  font-family: inherit;
  font-size: 11px;
  font-weight: 400;
  line-height: 1.3;
  white-space: nowrap;
}
body.page-scrape .quota-table td .quota-meta-time {
  display: inline;
  color: var(--scrape-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* 余额表「采集时间」列：整格单行，绝不换行 —— 这列独立之后就没有挤到两行的可能了 */
body.page-scrape .quota-table.quota-table-balance td .quota-meta-time,
body.page-scrape .quota-table.quota-table-balance tfoot td.quota-muted {
  white-space: nowrap;
}
body.page-scrape .quota-table td .quota-meta-flag {
  display: inline-flex;
  flex: none;
  vertical-align: middle;
  align-items: center;
  padding: 0 5px;
  border: 1px solid #fecaca;
  border-radius: 999px;
  background: #fef2f2;
  color: #b91c1c;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
}

/* 2026-11-14 表格加载/错误态占位（追加在末尾：必须压过 .board-table td 的 padding）
   现象：切页签时 tbody 先换成一行「正在拉取数据…」，整块高度和
   「暂无符合条件的采集数据」对不上，切换时上下跳一下。

   根因两条：
   1) .table-feedback 之前**没有任何样式**（全仓只在 JS 里出现），加载文案是默认小字，
      行高只有十几像素；
   2) 第一次修的时候把规则插在 .board-table td 之前，两者特异性相同（0,2,2），
      后出现的 padding: 12px 10px 把它盖掉了 —— 所以 td 上下各多 12px，
      占位块 204px，而空态 .erp-empty-state 是 180px，差 24px 就是那下跳动。

   修法：选择器提到 .board-table .table-feedback-row > td（0,3,2）必定胜出，
   并放在文件末尾；内层 180px 与空态 min-height 逐像素对齐。
   三个状态的高度：加载 = 空态 = 180px，有数据按实际行数（这部分天然会变，
   属于翻页/切页签的必然结果，不是抖动）。 */
body.page-scrape .board-table .table-feedback-row > td {
  padding: 0;
  border-bottom: 0;
  background: #fff;
}
body.page-scrape .board-table .table-feedback {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 180px;
  padding: 28px;
  color: var(--scrape-muted);
  font-size: 14px;
}
body.page-scrape .board-table .table-feedback.is-error {
  color: #b91c1c;
}
body.page-scrape .board-table .table-feedback i {
  font-size: 14px;
}
