/* Accessories (配件), the product library, product designs; sheets that stay put on phones. */
html.modal-open, html.modal-open body { overflow: hidden; overscroll-behavior: none; }
.modal-card.sheet { display: flex; flex-direction: column; gap: 0; padding: 0; max-height: calc(var(--vvh, 100dvh) - 40px); overflow: hidden; }
.modal-card.sheet > * { flex-shrink: 0; min-width: 0; }
.modal-card.sheet .m-head { padding: 18px 22px 12px; display: grid; gap: 6px; border-bottom: 1px solid var(--line); }
.modal-card.sheet .m-body { flex: 1 1 auto; flex-shrink: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 14px 22px; display: grid; gap: 14px; align-content: start; }
.modal-card.sheet .modal-actions { padding: 12px 22px; border-top: 1px solid var(--line); background: var(--surface); }
.modal-card .err { color: var(--crit); font-size: 13px; overflow-wrap: anywhere; }
.modal-card .err:empty { display: none; }
.modal-card.wide.sheet { width: min(720px, 100%); }
.hint { font-size: 12px; font-weight: 400; color: var(--muted); overflow-wrap: anywhere; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; cursor: pointer; }
.check input { width: 18px; height: 18px; flex: none; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.acc-set { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px 14px; margin: 0; display: grid; gap: 12px; min-width: 0; }
.acc-set legend { padding: 0 6px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.field > span:first-child { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.qty-row { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; }
.qty-row > select.input, .qty-row > .input { flex: 1 1 140px; min-width: 0; width: auto; }
.qty-params { display: flex; gap: 8px; flex-wrap: wrap; flex: 2 1 200px; }
.mini { display: grid; gap: 3px; font-size: 11.5px; color: var(--muted); font-weight: 600; flex: 1 1 110px; }
.photo-pick { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.seg > a { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: 7px; font-weight: 600; font-size: 12.5px; color: var(--muted); }
.seg > a:hover { color: var(--ink); text-decoration: none; }
.seg > a.on { background: var(--surface); color: var(--primary-ink); box-shadow: var(--shadow-sm); }
.seg.wide { display: flex; }
.seg.wide > button { flex: 1; justify-content: center; }
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.input.search { width: min(320px, 100%); }
.acc-panel { gap: 10px; }
.acc-head { display: grid; gap: 6px; padding: 12px; }
.acc-slot { padding: 12px 14px; display: grid; gap: 8px; border-left: 3px solid var(--line-2); }
.acc-slot.todo { border-left-color: var(--crit); }
.acc-slot-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.acc-slot-head h2 { font-size: 16px; }
.acc-slot .req { color: var(--crit); margin-left: -4px; }
.acc-answer { display: grid; gap: 4px; padding: 8px 10px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--line); min-width: 0; }
.acc-answer.warn { background: var(--warn-soft); }
.acc-answer .muted.small { overflow-wrap: anywhere; }
.acc-answer-actions { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.acc-line { display: flex; align-items: center; gap: 10px; min-width: 0; }
.acc-line .grow { overflow-wrap: anywhere; }
.acc-line.small { font-size: 12.5px; }
.acc-photo { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; flex: none; background: var(--surface-3); border: 1px solid var(--line); }
.acc-photo.none { display: grid; place-items: center; color: var(--faint); }
.acc-photo.lg { width: 72px; height: 72px; }
.acc-photo.xl { width: 100%; height: auto; max-height: 280px; aspect-ratio: 1; object-fit: contain; }
.acc-mention { display: flex; align-items: flex-start; gap: 8px; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); flex-wrap: wrap; }
.acc-mention .grow { display: grid; gap: 2px; min-width: 180px; overflow-wrap: anywhere; }
.acc-mention.sel { border-color: var(--warn); box-shadow: 0 0 0 3px color-mix(in srgb, var(--warn) 20%, transparent); }
.acc-mention.not_accessory { opacity: .7; }
.mention-text { font-size: 13px; }
.chips-row { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.chip-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--surface); font-weight: 600; font-size: 12.5px; color: var(--ink-2); }
.chip-btn.on { border-color: var(--primary); color: var(--primary-ink); background: var(--primary-soft); }
.chip-btn:hover { text-decoration: none; }
.chip-btn .n { font-size: 11px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; display: inline-grid; place-items: center; background: var(--crit-soft); color: var(--crit); }
.chip-check { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 10px; border-radius: 99px; border: 1px solid var(--line-2); font-size: 12.5px; cursor: pointer; }
.chip-check input { width: 16px; height: 16px; }
.pick-list { display: grid; gap: 6px; max-height: 320px; overflow-y: auto; overscroll-behavior: contain; }
.modal-card.sheet .pick-list { max-height: 40vh; }
.pick { display: grid; gap: 4px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; }
.pick:hover { border-color: var(--line-2); }
.pick.on { border-color: var(--primary); box-shadow: var(--ring); }
label.pick { display: flex; align-items: center; gap: 10px; }
label.pick input { width: 18px; height: 18px; flex: none; }
.acc-card { padding: 16px; display: grid; gap: 10px; margin-bottom: 14px; }
.acc-card h2 { font-size: 16px; }
.kv-inline { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 13.5px; align-items: center; }
.kv-inline i { font-style: normal; color: var(--muted); font-size: 12px; margin-right: 6px; }
.section-title { font-size: 16px; margin: 6px 0 10px; }
.acc-detail { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 14px; }
select.input.todo { border-color: var(--warn); background: var(--warn-soft); }
.input.saved { border-color: var(--ok); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 18%, transparent); }
.q-list { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 2px; font-size: 13px; }
.matrix td.mx { text-align: center; }
.matrix td.mx input { width: 18px; height: 18px; }
@media (max-width: 900px) {
  .acc-detail { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .input, select.input, textarea.input, .input.sm { font-size: 16px; }
  .grid2 { grid-template-columns: 1fr; }
  .btn.sm, .chip-btn, .chip-check { min-height: 44px; }
  .modal-back { padding: 0; align-items: end; }
  .modal-card.sheet { width: 100%; border-radius: 16px 16px 0 0; max-height: calc(var(--vvh, 100dvh) - 12px); }
  .modal-card.sheet .m-head, .modal-card.sheet .m-body, .modal-card.sheet .modal-actions { padding-left: 16px; padding-right: 16px; }
}
.input:disabled, select.input:disabled { background: var(--surface-2); color: var(--ink-2); border-color: var(--line); box-shadow: none; opacity: 1; }
[hidden] { display: none !important; }
/* Product library: 品类 → 小类 → 系列 */
.lib { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 14px; align-items: start; }
.lib-main { min-width: 0; }
.lib-tree { padding: 8px; display: grid; gap: 2px; position: sticky; top: calc(var(--top) + 12px); }
.tree-row { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 34px; padding: 4px 10px; border: 0; border-radius: 8px; background: none; color: var(--ink-2); font: inherit; font-size: 13.5px; font-weight: 600; text-align: left; cursor: pointer; }
.tree-row:hover { background: var(--hover); }
.tree-row.on { background: var(--primary-soft); color: var(--primary-ink); }
.tree-row.sub { padding-left: 24px; font-weight: 500; font-size: 13px; }
.tree-n { font-size: 12px; color: var(--muted); font-weight: 500; }
.tree-note { padding: 6px 10px; }
.tree-series { padding: 8px 4px 2px; }
.input.filter { width: auto; max-width: 200px; }
.row-check { width: 18px; height: 18px; }
.bulk-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 14px; margin-bottom: 10px; }
.req-set { display: grid; gap: 6px; }
.req-set summary { cursor: pointer; font-size: 13.5px; display: list-item; }
.req-items { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 4px; font-size: 13px; }
.req-items li { display: flex; gap: 8px; align-items: flex-start; min-width: 0; overflow-wrap: anywhere; }
.req-items .ico { width: 15px; height: 15px; flex: none; margin-top: 2px; }
.req-items li.ok .ico { color: var(--ok); }
.req-items li.bad .ico { color: var(--crit); }
.req-items li.warn .ico { color: var(--warn); }
.image-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.image-grid img { width: 100%; height: 120px; object-fit: contain; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); }
/* Product design */
.opt { display: grid; gap: 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.opt-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.opt-head > .input { flex: 1 1 160px; min-width: 0; width: auto; font-weight: 600; }
.opt-choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; }
.opt-choice { display: flex; gap: 6px; align-items: center; min-width: 0; }
.opt-choice .input { flex: 1 1 0; min-width: 0; width: auto; }
.opt-choice [data-ccode] { flex: 0 0 76px; font-family: var(--mono); }
.code-preview { padding: 10px 14px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--line); font-size: 15px; font-weight: 700; overflow-wrap: anywhere; }
.code-sep { max-width: 120px; }
.seg-list { display: grid; gap: 6px; }
.seg-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.seg-row .input { flex: 1 1 auto; min-width: 0; width: auto; }
.seg-row b { overflow-wrap: anywhere; }
.price-head { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.sub-title { font-size: 13.5px; margin: 4px 0 0; font-weight: 700; }
.table.compact td, .table.compact th { padding: 6px 10px; }
.table.compact .input.num { width: 90px; }
.num-cell { text-align: right; white-space: nowrap; }
.table tr.total-row td { border-top: 2px solid var(--line-2); }
.table tr.warn-row td { background: var(--warn-soft); }
.len-rule { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; }
.trial-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.file-card { display: flex; align-items: center; gap: 10px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.file-card img, .file-ico { width: 56px; height: 56px; border-radius: 7px; object-fit: cover; flex: none; background: var(--surface-2); display: grid; place-items: center; color: var(--muted); }
.file-meta { display: grid; gap: 2px; flex: 1 1 auto; min-width: 0; font-size: 13px; }
/* Review of cleaned records */
.c-blue { color: var(--primary-ink); font-weight: 600; }
.c-crit { color: var(--crit); font-weight: 600; }
.acc-readonly { margin: -6px 0 12px; }
.review-note { display: grid; gap: 4px; }
.review-note b { overflow-wrap: anywhere; }
.review-note .quote { overflow-wrap: anywhere; white-space: pre-wrap; }
.diff-card { padding: 12px 14px; display: grid; gap: 8px; }
.diff-card h3 { font-size: 13.5px; margin: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.diff-list { display: grid; gap: 4px; font-size: 13px; }
.diff-list > div { display: grid; grid-template-columns: minmax(84px, 130px) minmax(0, 1fr); gap: 8px; }
.diff-list .was { color: var(--muted); text-decoration: line-through; overflow-wrap: anywhere; }
.diff-list .now { font-weight: 600; overflow-wrap: anywhere; }
.tab .n.blue { background: var(--primary-soft); color: var(--primary-ink); }
.tab .n.crit { background: var(--crit-soft); color: var(--crit); }
.panel-foot { flex-wrap: wrap; }
.panel-foot .grow { min-width: 120px; }
@media (max-width: 640px) {
  .panel-foot .btn, .modal-card.sheet .modal-actions .btn { min-height: 44px; }
  .lib { grid-template-columns: 1fr; }
  .lib-tree { position: static; }
  .tree-row { min-height: 44px; }
  .price-head { grid-template-columns: 1fr; }
  .icon-btn { min-width: 44px; min-height: 44px; }
}
@media (max-width: 640px) {
  .mode-bar .seg > button { padding: 0 6px; white-space: nowrap; font-size: 13px; }
  .mode-bar .seg > button .ico { display: none; }
}
.trial-grid .qty-row { flex-wrap: nowrap; }
.trial-grid .qty-row > .input { flex: 1 1 60px; }
.trial-grid .qty-row > select.input { flex: 0 0 78px; }
.opt > .btn, #pricing > .btn { justify-self: start; }
@media (max-width: 640px) {
  /* The header never widens the page: the menu scrolls inside it. */
  .top { gap: 8px; padding: 0 12px; }
  .top .brand { flex: none; }
  .top .brand > span:last-child, .top .env, .top > .grow, .top .who-btn .name { display: none; }
  .top .nav { flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; overscroll-behavior-x: contain; }
  .top .nav::-webkit-scrollbar { display: none; }
  .top .nav a { flex: none; min-height: 44px; }
  .top .who { flex: none; }
}
/* How accessories and products relate: one colour and one word per relation, everywhere */
:root { --rel-c: #6d3fd4; --rel-c-soft: #f1ecfd; }
@media (prefers-color-scheme: dark) { :root { --rel-c: #c4b0f7; --rel-c-soft: #2a2140; } }
.rel { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 5px; font-size: 12px; font-weight: 700; white-space: nowrap; flex: none; }
.rel-included { color: var(--ok); background: var(--ok-soft); }
.rel-required { color: var(--primary-ink); background: var(--primary-soft); }
.rel-optional { color: var(--ink-2); background: var(--surface-3); }
.rel-companion { color: var(--rel-c); background: var(--rel-c-soft); }
.rel-none { color: var(--muted); background: var(--surface-2); }
.rel-line { display: flex; align-items: center; gap: 6px; min-width: 0; margin-bottom: 3px; }
.rel-line .mono { overflow-wrap: anywhere; }
.rel-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12.5px; }
.rel-legend > span { display: inline-flex; align-items: center; gap: 5px; }
.use-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 8px; min-width: 0; }
.use-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--ink); }
.use-chip b { font-weight: 600; font-family: var(--mono); font-size: .95em; }
.use-chip:hover { text-decoration: none; }
.use-chip:hover b { text-decoration: underline; }
/* 配件组成 on the product page */
.comp { gap: 12px; }
.comp-counts { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; font-size: 13px; margin-left: 6px; }
.comp-count { display: inline-flex; align-items: center; gap: 4px; }
.comp-head, .comp-row { display: grid; grid-template-columns: minmax(200px, 2.2fr) minmax(70px, .8fr) minmax(100px, 1.2fr) minmax(100px, 1.1fr) minmax(110px, 1.2fr) 68px; gap: 12px; align-items: center; }
.comp-head { padding: 0 12px 0 15px; font-size: 12px; color: var(--muted); font-weight: 600; }
.comp-group { display: grid; gap: 2px; padding: 8px 12px; border-left: 3px solid var(--line-2); border-radius: 0 8px 8px 0; background: var(--surface-2); min-width: 0; }
.comp-included { border-left-color: var(--ok); }
.comp-required { border-left-color: var(--primary); }
.comp-optional { border-left-color: var(--faint, var(--line-2)); }
.comp-companion { border-left-color: var(--rel-c); }
.comp-group h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 4px; font-size: 13px; font-weight: 400; }
.comp-choice + .comp-choice { margin-top: 6px; }
.comp-choice-name { display: flex; align-items: baseline; gap: 8px; font-size: 13px; font-weight: 700; padding: 2px 0; }
.comp-row { padding: 6px 0; border-top: 1px solid var(--line); font-size: 13px; min-width: 0; }
.comp-acc { display: flex; align-items: center; gap: 10px; min-width: 0; color: var(--ink); }
.comp-acc:hover { text-decoration: none; }
.comp-acc:hover b { text-decoration: underline; }
.comp-acc .grow, .comp-cell { min-width: 0; overflow-wrap: anywhere; }
.comp-actions { display: flex; justify-content: flex-end; gap: 2px; }
.comp-note { grid-column: 1 / -1; padding-left: 46px; }
.also a { font-family: var(--mono); font-size: .95em; }
.comp-other { display: flex; align-items: center; gap: 8px; padding: 4px 0; border-top: 1px solid var(--line); font-size: 13px; min-width: 0; overflow-wrap: anywhere; }
.comp-other > span { flex: 1 1 auto; min-width: 0; }
.comp-other .ico { width: 15px; height: 15px; color: var(--muted); flex: none; }
.comp-other b { flex: none; }
/* Accessories by model */
.matrix-box { padding: 12px; display: grid; gap: 10px; }
.matrix-wrap { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; }
.relation-matrix { width: auto; min-width: 100%; }
.relation-matrix th, .relation-matrix td { padding: 6px 10px; }
.relation-matrix .mx-first { position: sticky; left: 0; z-index: 1; background: var(--surface); min-width: 170px; max-width: 220px; }
.relation-matrix .mx-col { min-width: 84px; text-align: center; white-space: nowrap; font-family: var(--mono); font-size: 12.5px; }
.relation-matrix .mx-cell { text-align: center; vertical-align: middle; }
.mx-qty { font-size: 11px; color: var(--muted); margin-top: 2px; white-space: nowrap; }
.relation-matrix .mx-count { text-align: center; color: var(--muted); font-size: 12.5px; }
.tree-gap { height: 6px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
@media (max-width: 900px) {
  .comp-head { display: none; }
  .comp-row { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; padding: 8px 0; }
  .comp-acc { grid-column: 1; }
  .comp-actions { grid-column: 2; grid-row: 1; }
  .comp-cell { grid-column: 1 / -1; display: flex; gap: 8px; }
  .comp-cell::before { content: attr(data-label); flex: 0 0 48px; color: var(--muted); font-size: 12px; }
  .comp-note { padding-left: 0; }
}
/* Choosing the categories before cleaning */
.classify-intro { padding: 14px 16px; display: grid; gap: 8px; }
.classify-intro h2 { font-size: 16px; margin: 0; }
.classify-intro p { margin: 0; }
.chip-btn.quiet { color: var(--muted); }
.classify .panel-body { display: grid; gap: 10px; align-content: start; }
/* Where everything on the spec went */
.region-hint { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--warn-soft); font-size: 13px; font-weight: 600; }
.region-hint > span { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.region-hint .ico { color: var(--warn); }
.region-text { padding: 8px 10px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--line); font-size: 13px; white-space: pre-wrap; overflow-wrap: anywhere; font-weight: 400; }
.mem-chip { border: 0; cursor: pointer; font: inherit; font-size: 11.5px; }
.product-bar { padding: 8px 12px 0; }
.product-bar .chip-btn { gap: 6px; }
.content-panel { display: grid; gap: 12px; align-content: start; }
.cov-card { padding: 12px 14px; display: grid; gap: 8px; border-left: 3px solid var(--line-2); border-radius: 0 10px 10px 0; }
.cov-card.todo { border-left-color: var(--warn); }
.cov-card.done { border-left-color: var(--ok); }
.cov-card h2 { font-size: 15px; margin: 0; }
.cov-card p { margin: 0; }
.cov-bar { height: 6px; border-radius: 3px; background: var(--surface-3); overflow: hidden; }
.cov-bar i { display: block; height: 100%; background: var(--ok); }
.cov-lines { display: grid; gap: 2px; max-height: 260px; overflow-y: auto; overscroll-behavior: contain; }
.cov-line { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; min-width: 0; padding: 2px 0; }
.cov-line input { width: 16px; height: 16px; flex: none; margin-top: 2px; }
.page-tag { flex: none; font-size: 11.5px; color: var(--muted); min-width: 22px; margin-top: 1px; }
.link-btn { border: 0; background: none; padding: 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; overflow-wrap: anywhere; min-width: 0; }
.link-btn:hover { color: var(--primary-ink); text-decoration: underline; }
.value-chips { display: flex; flex-wrap: wrap; gap: 5px 6px; align-items: center; }
.value-chip { display: inline-flex; align-items: baseline; gap: 5px; padding: 2px 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); font: inherit; font-size: 12.5px; color: var(--ink); overflow-wrap: anywhere; }
button.value-chip { cursor: pointer; }
button.value-chip:hover { border-color: var(--line-2); }
.value-chip i { font-style: normal; color: var(--muted); font-size: 11.5px; }
.value-chip.var { background: var(--primary-soft); border-color: transparent; }
.var-name { font-size: 12.5px; color: var(--muted); font-weight: 600; min-width: 56px; }
.sku-table td, .sku-table th { white-space: nowrap; }
.other-row { display: flex; align-items: flex-start; gap: 8px; padding: 5px 0; border-top: 1px solid var(--line); font-size: 13px; min-width: 0; overflow-wrap: anywhere; }
.data-table { display: grid; gap: 6px; padding: 8px 0; border-top: 1px solid var(--line); min-width: 0; }
.data-table-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.data-table-head [data-title] { flex: 1 1 160px; width: auto; min-width: 0; font-weight: 600; }
.data-table-head [data-kind] { flex: 0 1 170px; width: auto; }
.input.cell { min-width: 70px; width: 100%; }
.row-x { width: 30px; }
.data-table > .btn { justify-self: start; }
.match-group { display: grid; gap: 6px; }
.match-group h3 { margin: 0; font-size: 13.5px; font-weight: 700; }
.match-group + .match-group { padding-top: 8px; border-top: 1px solid var(--line); }

/* the review page on a phone: nothing wider than the screen, long bars scroll inside themselves */
@media (max-width: 900px) {
  .review { grid-template-columns: minmax(0, 1fr); }
  .review > * { min-width: 0; }
  .viewer-bar { overflow-x: auto; scrollbar-width: none; }
  .viewer-bar > * { flex: none; }
}
@media (max-width: 640px) {
  .review-head { flex-wrap: wrap; gap: 8px; padding: 8px 12px; }
  .review-head > .grow { flex: 1 1 calc(100% - 56px); }
  .review-head > .btn { flex: 1 1 auto; min-height: 44px; justify-content: center; }
  .mode-bar .seg { overflow-x: auto; scrollbar-width: none; }
  .mode-bar .seg > button { flex: 1 0 auto; padding: 0 10px; min-height: 44px; }
  .rec-meta { display: grid; gap: 8px; }
  .rec-meta label { display: grid; grid-template-columns: 40px minmax(0, 1fr); align-items: center; white-space: nowrap; }
  .rec-meta select, .rec-meta input { width: 100%; min-width: 0; font-size: 16px; min-height: 44px; }
}

/* the mode bar never breaks a word: narrow panels drop the icons, then the bar scrolls inside itself */
.mode-bar { container-type: inline-size; }
.mode-bar .seg { overflow-x: auto; scrollbar-width: none; }
.mode-bar .seg > button { flex: 1 0 auto; white-space: nowrap; }
@container (max-width: 560px) {
  .mode-bar .seg > button { padding: 0 8px; }
  .mode-bar .seg > button .ico { display: none; }
}
.rec-meta label { white-space: nowrap; }

/* entering the products of a spec */
.plan-card { padding: 12px 14px; display: grid; gap: 10px; border-left: 4px solid var(--pc, var(--line-2)); border-radius: 0 10px 10px 0; }
.plan-card.other { --pc: var(--line-2); }
.plan-card.todo { background: color-mix(in srgb, var(--warn) 5%, var(--surface)); }
.plan-head { display: flex; align-items: center; gap: 8px; min-height: 28px; }
.plan-no { font-weight: 700; color: var(--pc); font-size: 13.5px; }
.plan-row, .plan-page-row { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; align-items: start; }
.plan-page-row { grid-template-columns: 64px minmax(0, 1fr); }
.plan-label { font-size: 13px; color: var(--muted); line-height: 30px; }
.plan-add { justify-self: start; }
.page-chip { --dot: transparent; display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-width: 34px; min-height: 30px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface); font: inherit; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.page-chip.on { background: var(--pc); border-color: var(--pc); color: #fff; font-weight: 700; }
.page-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--dot); }
.region-chip { display: inline-flex; align-items: center; gap: 2px; padding-left: 10px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 13px; }
.region-chip .icon-btn { width: 28px; height: 28px; }
.hl.planned { border: 2px solid var(--hl); background: color-mix(in srgb, var(--hl) 8%, transparent); }
.hl.planned span { background: var(--hl); }
.hl.planned.whole { background: none; }
.hl.planned.sel { box-shadow: 0 0 0 4px color-mix(in srgb, var(--hl) 28%, transparent); }
/* content several products share: dashed, so it reads as "also goes to …" */
.hl.planned.dashed { border-style: dashed; background: color-mix(in srgb, var(--hl) 5%, transparent); }
.hl.planned.muted { border-color: color-mix(in srgb, var(--faint) 55%, transparent); background: none; }
.hl.planned.muted span { background: var(--faint); }
.plan-card.focus { box-shadow: 0 0 0 2px color-mix(in srgb, var(--pc, var(--primary)) 45%, transparent); }
.plan-card.shared { --pc: #334155; }
.plan-reason { display: flex; gap: 6px; align-items: flex-start; margin: 0; font-size: 13px; color: var(--ink-2); background: var(--surface-2); border-radius: 8px; padding: 8px 10px; }
.plan-reason .ico { flex: none; margin-top: 2px; color: var(--muted); }
.model-chip { padding: 0 0 0 10px; font-weight: 600; }
.model-add { width: 150px; min-height: 30px; padding: 0 10px; font-size: 13px; }
.chip-btn .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.remark-history { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 13px; }
.remark-history li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; padding: 8px 10px; border-radius: 8px; background: var(--surface-2); }
.remark-history li.you { background: var(--primary-soft); }
.remark-history b { white-space: nowrap; }
.plan-card.remark textarea { width: 100%; resize: vertical; min-height: 72px; font: inherit; }
.panel-body.busy .plan-card:not(.remark) { opacity: 0.55; pointer-events: none; }
.rec-cat { font-size: 13px; color: var(--muted); }
.rec-cat b { color: var(--ink-2); }
.move-list { display: grid; gap: 8px; }
.move-list .btn { justify-content: space-between; min-height: 44px; }
@media (max-width: 640px) {
  .page-chip { min-width: 44px; min-height: 44px; }
  .region-chip .icon-btn { width: 44px; height: 44px; }
  .plan-label { line-height: 44px; }
  .plan-row { grid-template-columns: 40px minmax(0, 1fr); }
  .plan-card .input { font-size: 16px; min-height: 44px; }
  .model-add { width: 100%; }
}

/* the left and right sides answer each other */
.mark.here { --c: #0ea5e9; }
.other-row[data-loc], .cov-line, .sku-model, .req-items li[data-focus] { cursor: pointer; }
.other-row[data-loc]:hover { background: var(--surface-2); }
.panel .req-items li[data-focus]:hover { background: var(--surface-2); }
.plain-h { font: inherit; color: inherit; padding: 0; }
.sku-model { white-space: nowrap; }
.flash { animation: flash 1.2s ease-out; }
@keyframes flash { 0%, 40% { background: color-mix(in srgb, var(--primary) 22%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 30%, transparent); } 100% { background: transparent; box-shadow: 0 0 0 0 transparent; } }
@media (prefers-reduced-motion: reduce) { .flash { animation: none; outline: 2px solid var(--primary); } }
.viewer { scroll-margin-top: var(--top); }
@media (max-width: 640px) {
  .plan-add, .region-chip .link-btn, .plain-h { min-height: 44px; }
}

/* 新清洗 (spec cleaning M4): every value of a model, its state and where it is printed */
.clean-model { border-top: 1px solid var(--line); padding-top: 10px; display: grid; gap: 8px; }
.clean-fields { width: 100%; border-collapse: collapse; font-size: 13px; }
.clean-fields td { padding: 6px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.clean-fields tr { cursor: pointer; }
.clean-fields tr:hover td { background: var(--surface-2); }
.clean-fields tr.nopos { cursor: default; }
.clean-fields td.st { width: 44px; }
.clean-fields td.k { width: 32%; color: var(--ink-2); }
.clean-fields td.n { width: 72px; text-align: right; white-space: nowrap; }
.clean-fields td.v b { font-weight: 600; overflow-wrap: anywhere; }
@media (max-width: 640px) {
  .clean-fields td.k { width: auto; }
  .clean-fields td.n { display: none; }
}

/* 复核与签发 (spec cleaning M5): one model's values with their screenshots, the three actions, approval */
.review-panel .card h3 { font-size: 14px; margin: 0 0 8px; }
.rv-head { display: grid; gap: 10px; }
.rv-progress { display: flex; align-items: center; gap: 10px; }
.rv-progress .bar { flex: 1; height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.rv-progress .bar i { display: block; height: 100%; background: var(--ok); }
.rv-block { display: grid; gap: 8px; }
.rv-field { display: grid; gap: 5px; padding: 9px 10px 9px 12px; border: 1px solid var(--line); border-left: 3px solid var(--line); border-radius: 8px; cursor: pointer; }
.rv-field:hover { background: var(--surface-2); }
.rv-field.red { border-left-color: var(--crit); }
.rv-field.yellow, .rv-field.source_unclear { border-left-color: var(--warn); }
.rv-field.green { border-left-color: color-mix(in srgb, var(--ok) 45%, var(--line)); }
.rv-field.confirmed, .rv-field.corrected { border-left-color: var(--ok); }
.rv-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; }
.rv-val { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; font-size: 13.5px; overflow-wrap: anywhere; }
.rv-val b { font-weight: 600; }
.rv-shots { display: flex; gap: 6px; flex-wrap: wrap; }
.rv-shots .shot { padding: 0; border: 1px solid var(--line); border-radius: 6px; background: #fff; cursor: zoom-in; max-width: 100%; }
.rv-shots img { display: block; max-width: min(100%, 420px); max-height: 120px; object-fit: contain; }
.rv-acts { display: flex; gap: 6px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.rv-part { border-top: 1px solid var(--line); padding: 8px 0; display: grid; gap: 6px; }
.rv-part ol, .rv-part ul { margin: 4px 0 0 18px; padding: 0; }
.rv-thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.rv-thumbs figure { margin: 0; width: 120px; }
.rv-thumbs img { width: 120px; height: 90px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.rv-att { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.review-panel .tag { font-size: 11px; padding: 1px 6px; border-radius: 4px; background: var(--surface-2); color: var(--ink-2); }
.review-panel .tag.crit { background: var(--crit-soft); color: var(--crit); }
.review-panel select.input.sm { width: auto; min-width: 120px; }
.modal-card label.check { display: flex; align-items: center; gap: 6px; margin: 6px 0; }
@media (max-width: 640px) {
  .rv-acts .btn, .rv-part .btn { min-height: 44px; }
  .rv-shots img { max-height: 100px; }
}

/* 新规格书: every model's new spec sheets at the top of the 新清洗 tab */
.new-sheets h3 { font-size: 15px; margin: 0 0 4px; }
.ns-list { display: grid; gap: 0; margin-top: 8px; }
.ns-row { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; padding: 10px 0; border-top: 1px solid var(--line); }
.ns-name { min-width: 0; overflow-wrap: anywhere; }
.ns-acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; align-items: center; }
@media (max-width: 640px) {
  .ns-row { flex-direction: column; }
  .ns-acts { justify-content: flex-start; }
  .ns-acts .btn { min-height: 44px; }
}

/* the new flow (flow.js): steps, the category menu, the two parts of the values */
.review.flow { grid-template-rows: auto auto minmax(0, 1fr); }
.fsteps { grid-column: 1 / -1; display: flex; gap: 4px; overflow-x: auto; padding: 8px 16px; background: var(--surface); border-bottom: 1px solid var(--line); }
.fstep { flex: none; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.fstep.done { color: var(--ok); }
.fstep.on { background: var(--primary-soft); color: var(--primary-ink); font-weight: 600; }
.flow .pmain { overflow: auto; padding: 14px; gap: 12px; }
.flow .pmain > .card, .fparams > .card { padding: 14px 16px; display: grid; gap: 10px; }
.flow .card h2 { font-size: 16px; margin: 0; }
.flow .card h3 { font-size: 14px; margin: 0; }
.flow .card p { margin: 0; }
.fsteps .fsteps-restart { margin-left: auto; white-space: nowrap; }
/* one column that never grows past the panel: a wide row (the buttons at the bottom) wraps instead of pushing every card off the right edge */
.fparams { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.fparams > .banner { margin: 0; }
/* the back office changing data on 后台审核 (flow.js startEditing): a bar saying so, the way back */
.fparams > .card.fedit-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; border-left: 3px solid var(--primary); background: var(--primary-soft); }
.fedit-bar > .ico { color: var(--primary); flex: none; }
.fedit-bar .grow { flex: 1 1 240px; display: grid; gap: 2px; }
.fedit-entry { border-left: 3px solid var(--primary); }
.fedit-entry h3, .fparams > .card > .plan-head > h3 { white-space: nowrap; }
.fparams > .card > .plan-head { flex-wrap: wrap; }
.fcats { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.fcat { display: grid; gap: 4px; text-align: left; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--surface); }
.fcat:hover:not(:disabled) { border-color: var(--primary); box-shadow: var(--ring); }
.fcat.guess { border-color: var(--primary); }
.fcat.on { border-color: var(--primary); background: var(--primary-soft); box-shadow: var(--ring); }
/* category, then 小类 */
.fchoose { display: grid; gap: 10px; }
.fchoose-step { display: flex; align-items: center; gap: 8px; margin: 6px 0 0; font-size: 14px; }
.fchoose-step b { width: 22px; height: 22px; border-radius: 11px; display: inline-grid; place-items: center; background: var(--primary-soft); color: var(--primary-ink); font-size: 12px; }
.fsubs { display: flex; flex-wrap: wrap; gap: 8px; }
.fsub { height: 36px; padding: 0 16px; border: 1px solid var(--line-2); border-radius: 99px; background: var(--surface); font-weight: 600; font-size: 13.5px; cursor: pointer; }
.fsub:hover { border-color: var(--primary); }
.fsub.on { border-color: var(--primary); background: var(--primary-soft); color: var(--primary-ink); }
.fchoose .fnext { position: static; margin-top: 6px; padding: 0; background: none; }
.frules-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; justify-content: space-between; }
.fsubline { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 600; }
.fsubline select { height: 30px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--surface); padding: 0 8px; font: inherit; color: var(--ink); }
/* the values in the order of the sheet's sections */
.fgroup + .fgroup { margin-top: 14px; }
.fgroup-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 6px 0 4px; border-bottom: 2px solid var(--line-2); font-size: 13.5px; }
.fp-row.empty .fk { color: var(--muted); }
.fmatrix .fgroup-row th { background: var(--surface-2); font-size: 12.5px; color: var(--ink-2); padding-top: 8px; }
.fcell .dot.empty { background: transparent; }
.fcat.off { opacity: .55; cursor: not-allowed; background: var(--surface-2); }
.fcat .chip { justify-self: start; }
.frules { border-left: 3px solid var(--warn); }
.frules.ok { border-left-color: var(--ok); }
.frules b .ico, .fp-row .ico, .fmatrix .ico { width: 15px; height: 15px; vertical-align: -3px; }
.fp-row { display: grid; grid-template-columns: minmax(110px, 170px) minmax(0, 1fr); gap: 6px 12px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line); }
.fp-row.red { box-shadow: inset 3px 0 0 var(--crit); padding-left: 10px; }
.fp-row.yellow { box-shadow: inset 3px 0 0 var(--warn); padding-left: 10px; }
.fp-row .fk { display: grid; gap: 1px; font-weight: 600; font-size: 13px; }
.fp-row .fv { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.fp-row .fa { grid-column: 2; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.fp-row .tag { justify-self: start; font-size: 11px; padding: 0 6px; border-radius: 4px; background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.fmatrix-wrap { overflow-x: auto; margin: 0 -16px; padding: 0 16px; }
.fmatrix { border-collapse: collapse; font-size: 13px; min-width: 100%; }
.fmatrix th, .fmatrix td { border-bottom: 1px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; }
.fmatrix thead th { position: sticky; top: 0; background: var(--surface-2); font-size: 12px; white-space: nowrap; }
.fmatrix tbody th { font-weight: 600; min-width: 120px; }
.fmatrix td.red { background: var(--crit-soft); }
.fmatrix td.yellow { background: var(--warn-soft); }
.fcell { display: inline-flex; align-items: center; gap: 6px; text-align: left; padding: 2px 4px; border-radius: 6px; font-weight: 600; overflow-wrap: anywhere; }
.fcell:hover { background: var(--hover); }
.fcell .dot { width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--faint); }
.fcell .dot.red { background: var(--crit); }
.fcell .dot.yellow { background: var(--warn); }
.fcell .dot.green, .fcell .dot.confirmed, .fcell .dot.corrected { background: var(--ok); }
.fnext { position: sticky; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; padding: 10px 0 2px; background: linear-gradient(transparent, var(--bg) 30%); }
.fnext > .small { flex: 1 1 180px; min-width: 0; text-align: right; }
.fnext .btn { min-height: 40px; }
.freturned { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-left: 3px solid var(--crit); background: var(--crit-soft); }
.freturned > .ico { color: var(--crit); flex: none; margin-top: 2px; }
.fworking { display: flex; align-items: center; gap: 8px; color: var(--primary-ink); font-weight: 600; }
.fhint { display: grid; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.fhint.open.crit { box-shadow: inset 3px 0 0 var(--crit); padding-left: 10px; }
.fhint.open.warn { box-shadow: inset 3px 0 0 var(--warn); padding-left: 10px; }
.fhint:not(.open) { opacity: .8; }
.fhint-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.fcmp { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.fcmp > div { display: grid; gap: 2px; min-width: 0; align-content: start; }
.fcmp mark { background: var(--warn-soft); color: var(--ink); padding: 2px 6px; border-radius: 4px; overflow-wrap: anywhere; font-weight: 600; }
.fcmp mark.orig { background: var(--primary-soft); }
.fdone { margin-top: 6px; }
.fdone > summary { cursor: pointer; color: var(--muted); padding: 4px 0; }
.fsheet { display: grid; gap: 6px; padding: 8px 0; border-top: 1px solid var(--line); }
.flogo { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.flogo .field { flex: 1 1 180px; }
textarea.input.area { height: auto; padding: 8px 12px; resize: vertical; }
@media (max-width: 640px) {
  .fcmp { grid-template-columns: 1fr; }
  .fp-row { grid-template-columns: 1fr; }
  .fp-row .fa { grid-column: 1; }
  .fp-row .fa .btn, .fcat { min-height: 44px; }
}

/* an old document while the new flow is on (review.js) */
.review.has-old { grid-template-rows: auto auto minmax(0, 1fr); }
.oldflow { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; padding: 10px 16px; background: var(--primary-soft); border-bottom: 1px solid var(--line); }
.oldflow > .ico { color: var(--primary); flex: none; }
.oldflow .grow { min-width: 0; }
@media (max-width: 900px) {
  .review.has-old { grid-template-rows: auto auto 45vh minmax(0, 1fr); }
  .oldflow { flex-wrap: wrap; }
}

/* the two-way link between the original and the right (link.js): yellow highlighter on both sides */
.lk-layer { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.lk { position: absolute; border-radius: 2px; background: rgb(250 204 21 / 0.22); outline: 1.5px solid rgb(234 179 8 / 0.5); }
.lk.sel { background: rgb(250 204 21 / 0.38); outline: 2.5px solid #eab308; animation: lk-ring 0.8s ease-out 2; }
.lk.whole { background: none; outline: 3px solid #eab308; outline-offset: -3px; }
.lk span { position: absolute; left: -2px; bottom: 100%; margin-bottom: 4px; padding: 0 6px; height: 18px; line-height: 18px; font-size: 11px; font-weight: 700; color: #1b1f24; background: #facc15; border-radius: 4px; white-space: nowrap; }
.lk.whole span { left: 6px; top: 6px; bottom: auto; margin: 0; }
@keyframes lk-ring { 0% { box-shadow: 0 0 0 0 rgb(234 179 8 / 0.7); } 100% { box-shadow: 0 0 0 16px rgb(234 179 8 / 0); } }
.panel [data-src-page], .panel [data-src-text] { cursor: pointer; }
.panel .fsrc, .panel .fp-row[data-src-text], .panel .fp-row[data-src-page], .panel .fhint[data-src-page], .panel .fhint[data-src-text], .panel .ftable td, .panel .ftable th { transition: background-color 0.12s; }
.panel .fsrc:hover, .panel .fp-row[data-src-page]:hover, .panel .fp-row[data-src-text]:hover, .panel .fcell:hover, .panel .model-chip:hover, .panel .ftable td[data-src-text]:hover, .panel .ftable th[data-src-text]:hover { background-color: rgb(250 204 21 / 0.16); }
.lk-term { border-bottom: 1.5px dotted #ca8a04; }
.lk-term:hover { background: rgb(250 204 21 / 0.25); }
.lk-on { background-color: rgb(250 204 21 / 0.28) !important; box-shadow: inset 3px 0 0 #eab308; }
.card.lk-on, .plan-card.lk-on { background-color: var(--surface) !important; box-shadow: 0 0 0 3px #eab308; }
.lk-flash { animation: lk-flash 1.3s ease-out 1; }
.card.lk-flash, .plan-card.lk-flash { animation: none; }
@keyframes lk-flash { 0%, 35% { background-color: rgb(250 204 21 / 0.65); } }
.linkbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 12px; background: color-mix(in srgb, #facc15 16%, var(--surface)); border-bottom: 1px solid color-mix(in srgb, #eab308 45%, var(--line)); font-size: 13px; }
.linkbar[hidden] { display: none; }
.linkbar > .ico { color: #ca8a04; flex: none; }
.linkbar .grow { flex: 1 1 200px; min-width: 0; overflow-wrap: anywhere; }
.linkbar .small { color: var(--muted); }
/* the cleaned parts that are not values (flow.js contentCard) */
.fcontent { border-top: 1px solid var(--line); }
.fcontent summary { display: flex; align-items: center; gap: 8px; padding: 9px 0; cursor: pointer; }
.fcontent-body { display: grid; gap: 2px; padding: 0 0 10px; font-size: 13px; }
.fsrc { padding: 4px 6px; border-radius: 6px; overflow-wrap: anywhere; }
.fsrc-head { margin-top: 6px; }
.ftable td, .ftable th { white-space: nowrap; }
.fcell { cursor: pointer; }
.fmatrix td .link-btn { margin-left: 4px; }
/* every content line can be deleted (flow.js contentCard → content_remove) */
.fdelrow { display: flex; align-items: baseline; gap: 8px; }
.fdelrow > .grow { flex: 1; min-width: 0; }
.link-btn.fdel { flex: none; display: inline-flex; align-items: center; gap: 3px; color: var(--muted); font-weight: 500; }
.link-btn.fdel:hover { color: var(--crit); }
.fdel .ico { width: 13px; height: 13px; }
.fcontent-add { padding-top: 8px; border-top: 1px solid var(--line); }

/* 图片归属 (flow.js picturesCard): every picture has a place */
.fpics { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; margin-top: 8px; }
.fpic { display: grid; grid-template-rows: 140px auto; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--surface); }
.fpic.todo { border-color: var(--warn); box-shadow: 0 0 0 1px var(--warn); }
.fpic.unsure { border-color: var(--crit); box-shadow: 0 0 0 1px var(--crit); }
.fpic.unused { opacity: 0.6; }
.fpic-img { display: grid; place-items: center; background: var(--surface-2); border-bottom: 1px solid var(--line); overflow: hidden; }
.fpic-img img { max-width: 100%; max-height: 140px; object-fit: contain; }
.fpic-body { display: grid; gap: 6px; padding: 8px 10px 10px; min-width: 0; }
.fpic-head { display: flex; align-items: center; gap: 6px; justify-content: space-between; }
.fpic .field { margin: 0; }
.fpic-models summary { cursor: pointer; overflow-wrap: anywhere; }
.fpic-models[open] { display: grid; gap: 2px; max-height: 180px; overflow-y: auto; padding-bottom: 4px; }
.fpic .chips-row { gap: 4px; }
.fpic-how .ico, .fcontent-add .ico { width: 14px; height: 14px; vertical-align: -2px; margin-right: 3px; }
.fpic-filter { min-height: 28px; }
.fpic-filter .dot { background: var(--faint); }
.fpic-filter .dot.warn { background: var(--warn); }
.fpic-filter .dot.crit { background: var(--crit); }
.fpic-filter .dot.ok { background: var(--ok); }

/* the knowledge base (kb.js): tidy and easy to read — one page width, one section style, one rhythm */
.kb.page { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; max-width: 1240px; margin: 0 auto; padding: 28px 20px 60px; }
.kb.page > *, .kb-cols > * { min-width: 0; }
/* actions written as links look like links; a form's send button keeps its own width */
.kb .link-btn { color: var(--primary-ink); font-weight: 600; }
.kb .card > p.small { max-width: 44em; line-height: 1.6; text-wrap: pretty; }
/* a section: padding inside, title with its count and its action on the right, description right under the title */
.kb .card { padding: 16px 20px; display: grid; gap: 12px; align-content: start; }
.kb .card > h3 { display: flex; align-items: baseline; gap: 8px; margin: 0; font-size: 16px; line-height: 1.4; }
.kb .card > h3 .small.muted { font-weight: 500; }
.kb .card > h3 + p.small { margin-top: -8px; }
.sec-act { margin-left: auto; font-size: 13px; font-weight: 600; color: var(--primary-ink); }
.sec-act:hover { text-decoration: underline; }
.kb .card h4 { margin: 4px 0 0; font-size: 14px; }
.kb-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 16px; align-items: start; }
.kb-cols.three { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
/* list rows */
.kb-row { display: flex; align-items: center; gap: 8px; padding: 10px 4px; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.kb-row:hover { background: var(--hover); text-decoration: none; }
.kb-row .grow { display: grid; gap: 2px; min-width: 0; flex: 1; overflow-wrap: anywhere; }
.kb-ctx { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; font-size: 13.5px; }
.kb-ctx dt { color: var(--muted); }
.kb-ctx dd { margin: 0; overflow-wrap: anywhere; }
.kb-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kb-form { display: grid; gap: 10px; }
.kb-scope { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: grid; gap: 8px; margin: 0; }
.kb-kinds { margin-bottom: 4px; }
.kb-btn.open { border-color: var(--warn); color: var(--warn-ink); }
.fmatrix th .kb-btn { display: inline-flex; margin-top: 2px; }
/* the overview table: names left, counts right-aligned in even columns, zeros quiet */
.kb-table { table-layout: auto; }
.kb-table th, .kb-table td { padding: 10px 10px; vertical-align: middle; }
.kb-table .kb-num { text-align: right; width: 72px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.kb-table .kb-zero { color: var(--faint); }
.kb-table .kb-name { min-width: 180px; }
.kb-table .kb-name .small { display: block; }
.kb-table .kb-flagcell { min-width: 160px; }
.kb-table .kb-when { white-space: nowrap; color: var(--muted); font-size: 12.5px; }
.kb-table .chips-row { gap: 4px; }
/* flags */
.kb-where { margin-bottom: 4px; }
.kb-where-fixed { display: flex; align-items: center; gap: 6px; margin: 0; }
.modal-card.sheet .modal-actions { flex-wrap: wrap; }
/* asking in a sentence, statistics, several at once, pictures and tables in knowledge */
.kb-ask-row { display: flex; gap: 8px; flex-wrap: wrap; }
.kb-ask-row .input { flex: 1 1 260px; min-width: 0; }
#askOut { display: grid; gap: 8px; }
#askOut:empty { display: none; }
.kb-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.kb-kpis > div { display: grid; gap: 2px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; }
.kb-kpis b { font-size: 20px; font-variant-numeric: tabular-nums; }
.kb-stats { display: grid; gap: 10px; }
.kb-pics { display: flex; flex-wrap: wrap; gap: 8px; }
.kb-pics img { max-width: 160px; max-height: 120px; border-radius: 8px; border: 1px solid var(--line); object-fit: contain; background: #fff; }
.kb-pic-ids, #googleBox code, .kb-pic-ids code { overflow-wrap: anywhere; word-break: break-all; }
#googleBox { line-height: 1.6; max-width: 46em; }
#googleBox > p { margin: 0 0 10px; }
.md { display: grid; gap: 8px; overflow-wrap: anywhere; line-height: 1.6; }
.md p, .md ul, .md ol { margin: 0; }
.md ul, .md ol { padding-left: 20px; }
.md-img { max-width: 100%; max-height: 360px; border-radius: 8px; border: 1px solid var(--line); background: #fff; }
.md-h { margin: 6px 0 0; }
/* the count beside 知识库 in the menu: a small pill after the label, never on top of it */
.nav-badge { display: inline-block; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 2px; border-radius: 9px; background: #dc2626; color: #fff;
  font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; font-variant-numeric: tabular-nums; }
@media (max-width: 700px) {
  .kb.page { padding: 20px 16px 48px; gap: 14px; }
  .kb .card { padding: 14px 16px; }
  .kb-two { grid-template-columns: 1fr; }
  .kb-cols, .kb-cols.three { grid-template-columns: 1fr; }
  .modal-card.sheet .modal-actions .btn { flex: 1 1 auto; }
}

/* review round: one tab style, the base page's two columns, crumbs, rows that read top to bottom */
.kb-file { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.kb-file input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.kb-file:focus-within .btn { box-shadow: var(--ring); }
.field > span:first-child { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.kb-table .kb-flagcell { min-width: 300px; }
.kb-table .kb-flagcell .chip { white-space: nowrap; }

@media (max-width: 700px) {
  .kb-table .kb-flagcell { display: none; }
  .top { gap: 8px; }
  .top .nav { flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
  .top .nav::-webkit-scrollbar { display: none; }
}

@media (max-width: 900px) { .review.flow { grid-template-rows: auto auto 45vh minmax(0, 1fr); } }

/* the spec sheet's sections on the cleaning page (sections.js, owner 2026-11-18) */
.fgroup-head { align-items: center; flex-wrap: wrap; }
.fgroup-head .grow { flex: 1; }
.fsec-off { font-size: 11.5px; font-weight: 600; color: var(--warn-ink); background: var(--warn-soft); padding: 1px 7px; border-radius: 5px; }
.fmatrix .fgroup-row th .fgroup-head { border-bottom: 0; padding: 0; font-size: 12.5px; }
.fmatrix td { min-width: 150px; max-width: 280px; }
.fmatrix td .fcell { max-height: 7.6em; overflow: hidden; align-items: flex-start; }   /* long values: the section window shows them whole */
.fmove { cursor: grab; }
.fmove:active { cursor: grabbing; }
.fmove .ico, .fmove-lock .ico { width: 14px; height: 14px; }
.fmove-lock { display: inline-flex; align-items: center; gap: 3px; }
.fmatrix th .fmove { margin-left: 6px; }
[data-drop].drop-on { outline: 2px dashed var(--primary); outline-offset: 2px; background: var(--primary-soft); }
.fmenu { position: fixed; z-index: 55; min-width: 230px; max-height: 70vh; overflow: auto; padding: 6px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); display: grid; gap: 2px; }
.fmenu-head { padding: 6px 8px 4px; color: var(--muted); }
.fmenu-item { display: flex; justify-content: space-between; align-items: center; gap: 10px; min-height: 34px; padding: 6px 9px; border-radius: 8px; border: 0; background: none; text-align: left; font: inherit; color: var(--ink); cursor: pointer; }
.fmenu-item:hover, .fmenu-item:focus-visible { background: var(--hover); outline: none; }
.fmenu-item.on { background: var(--primary-soft); color: var(--primary-ink); font-weight: 600; }
.fmenu-item .ico { width: 15px; height: 15px; }
.fdropbar { position: fixed; top: calc(var(--top) + 8px); left: 50%; transform: translateX(-50%); z-index: 46; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; max-width: min(92vw, 920px); padding: 8px 10px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); }
.fdrop { padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line-2); font-size: 13px; font-weight: 600; background: var(--surface-2); }
.fdrop.off { border-style: dashed; color: var(--muted); }
/* the map is big enough to read: every page whole (they wrap), names on their own line, never cut to "项目信…" */
.fmap-how { line-height: 1.65; }
.fmap-how a { display: inline-flex; align-items: center; gap: 3px; font-weight: 600; color: var(--primary-ink); }
.fmap-how .ico { width: 14px; height: 14px; }
.fmap-pages { display: flex; flex-wrap: wrap; gap: 16px; padding: 2px 2px 6px; }
.fmap-page { display: grid; gap: 4px; justify-items: center; flex: none; }
.fmap-paper { position: relative; width: 210px; aspect-ratio: 180 / 255.5; border: 1px solid var(--line-2); border-radius: 4px; background: var(--surface); box-shadow: var(--shadow-sm); }
.fmap-sec { position: absolute; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 3px 5px; margin: 0; border: 1px solid var(--line-2); border-radius: 3px; background: var(--surface-2); font: 600 11px/1.25 var(--font); color: var(--ink-2); overflow: hidden; cursor: pointer; text-align: left; box-shadow: inset 0 0 0 1px var(--surface); }
.fmap-sec:hover, .fmap-sec:focus-visible { border-color: var(--primary); outline: none; }
.fmap-sec.none { color: var(--faint); background: var(--surface); }
.fmap-name { white-space: normal; overflow-wrap: anywhere; max-width: 100%; }
.fmap-n { font-weight: 700; color: var(--primary-ink); white-space: nowrap; }
.fmap-sec.none .fmap-n { color: var(--faint); font-weight: 600; }
[data-drag-item] { cursor: grab; }
[data-drag-item]:active { cursor: grabbing; }
@media (max-width: 520px) { .fmap-paper { width: min(42vw, 210px); } }
.fmap-lost { margin-top: 10px; display: grid; gap: 6px; }
.fmap-lost b .ico { width: 15px; height: 15px; vertical-align: -3px; }
.fmap-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 9px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); font-size: 12.5px; }
.ftable-place { display: flex; align-items: center; gap: 8px; margin: 2px 0 6px; }

/* one section in a window of its own: names stay put, the view zooms and is dragged around */
.zoomwin-back { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; padding: 16px; background: rgba(15,23,42,.45); }
/* over the right-hand panel only: the original stays in view beside it (left ↔ right link) */
.zoomwin-back.in-host { inset: auto; padding: 8px; background: rgba(15,23,42,.18); }
.zoomwin-back.in-host .zoomwin { width: 100%; height: 100%; }
.ztable td[data-src-page], .ztable td[data-src-text] { cursor: pointer; }
.zoomwin { width: min(1440px, 100%); height: min(92vh, 100%); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-lg); overflow: hidden; }
.zoomwin-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.zoomwin-titles { display: grid; gap: 1px; min-width: 0; }
.zoomwin-title { font-size: 16px; }
.zoomwin-tools { display: flex; gap: 4px; align-items: center; }
.zoomwin-tools .ico { width: 15px; height: 15px; }
.zoomwin-pct { min-width: 64px; justify-content: center; font-variant-numeric: tabular-nums; }
.zoomwin-body { overflow: auto; background: var(--surface-3); cursor: grab; outline: none; overscroll-behavior: contain; }
.zoomwin-body:focus-visible { box-shadow: inset var(--ring); }
.zoomwin-body.panning { cursor: grabbing; user-select: none; }
.zoomwin-content { padding: 16px; width: max-content; min-width: 100%; }
.zoomwin-foot { padding: 8px 14px; border-top: 1px solid var(--line); }
.zblock + .zblock { margin-top: 20px; }
.zblock h4 { margin: 0 0 6px; font-size: 13.5px; }
.ztable { border-collapse: separate; border-spacing: 0; font-size: 13px; background: var(--surface); border: 1px solid var(--line-2); border-radius: 8px; }
.ztable th, .ztable td { padding: 8px 10px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; min-width: 180px; max-width: 340px; overflow-wrap: anywhere; background: var(--surface); }
.ztable thead th { position: sticky; top: 0; z-index: 2; background: var(--surface-2); font-size: 12.5px; white-space: nowrap; }
.ztable tbody th { position: sticky; left: 0; z-index: 1; background: var(--surface-2); font-weight: 600; min-width: 150px; max-width: 220px; }
.ztable thead th:first-child { left: 0; z-index: 3; }
.ztable tbody th small { display: block; font-weight: 400; color: var(--muted); font-size: 11.5px; }
.ztable td.red { background: var(--crit-soft); }
.ztable td.yellow { background: var(--warn-soft); }
.ztable td[data-zedit] { cursor: cell; }
.ztable td[data-zedit]:hover { box-shadow: inset 0 0 0 2px var(--primary-soft-2); }
.zshared { display: block; margin-top: 3px; font-size: 11px; font-weight: 400; color: var(--muted); }
.zpics { display: flex; flex-wrap: wrap; gap: 12px; }
.zpics figure { margin: 0; display: grid; gap: 4px; background: var(--surface); padding: 8px; border-radius: 8px; border: 1px solid var(--line); }
.zpics img { max-width: 320px; max-height: 260px; object-fit: contain; }
.zpics figcaption { font-size: 12px; color: var(--muted); }
.zempty { padding: 24px; max-width: 520px; }
@media (max-width: 700px) { .zoomwin-back { padding: 0; } .zoomwin { height: 100%; border-radius: 0; } }

/* 我的公司 (company.js) */
.co-card { display: grid; gap: 14px; }
.co-card + .co-card { margin-top: 16px; }
.co-head { display: flex; flex-wrap: wrap; gap: 16px 32px; align-items: flex-end; justify-content: space-between; }
.co-head h2 { margin: 0; }
.co-code { display: grid; gap: 2px; justify-items: start; }
.co-code b { font: 700 20px/1.2 var(--mono); letter-spacing: .06em; padding: 2px 10px; border-radius: 8px; background: var(--primary-soft); color: var(--primary-ink); }
.co-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px 14px; }
.co-form .wide { grid-column: 1 / -1; }
.co-person { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--line); }
.co-person .grow { flex: 1; min-width: 220px; }
.co-person .chip { margin-left: 8px; }
.co-ways { display: flex; flex-wrap: wrap; gap: 2px 14px; font-size: 13px; margin-top: 2px; }
.co-left summary { cursor: pointer; color: var(--muted); }

/* SuppLux 产品代码 (flow.js skuCard): the code gets its own full-width line under the supplier's model, so a narrow side panel never squeezes it */
.fsku-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "model act" "name name" "why why"; gap: 6px 14px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.fsku-model { grid-area: model; display: grid; gap: 1px; min-width: 0; overflow-wrap: anywhere; }
/* every segment with its meaning under it; segments wrap as whole units, a caption never runs out of its segment */
.fsku-name { grid-area: name; min-width: 0; display: flex; flex-wrap: wrap; align-items: flex-start; gap: 6px 0; font: 600 13px/1.6 var(--mono); }
.fsku-seg { display: inline-flex; flex-direction: column; align-items: center; gap: 1px; min-width: 0; max-width: 100%; }
.fsku-cap { max-width: 100%; font: 500 10.5px/1.3 var(--font); color: var(--muted); text-align: center; white-space: normal; overflow-wrap: anywhere; }
.fsku-part { display: inline-block; max-width: 100%; padding: 0 5px; border-radius: 5px; border: 1px solid transparent; background: var(--surface-2); color: var(--ink); font: inherit; overflow-wrap: anywhere; }
.fsku-part.diff { background: var(--ok-soft); color: var(--ok-ink); border-color: color-mix(in srgb, var(--ok-ink) 25%, transparent); }
.fsku-intro { margin: 4px 0 2px; font-size: 12.5px; color: var(--muted); overflow-wrap: anywhere; }
button.fsku-part { cursor: pointer; border-color: var(--line-2); }
button.fsku-part:hover { border-color: var(--primary); }
.fsku-part.miss { background: var(--crit-soft); color: var(--crit-ink); border-color: color-mix(in srgb, var(--crit) 35%, transparent); font-family: var(--font); }
.fsku-part.typed { background: var(--warn-soft); color: var(--warn-ink); }
.fsku-part.auto { color: var(--primary-ink); background: var(--primary-soft); }
.fsku-part.rel { color: var(--muted); background: none; border: 1px dashed var(--line-2); font-family: var(--font); font-weight: 500; }
.fsku-done { margin-top: 2px; font-size: 12.5px; overflow-wrap: anywhere; }
.fsku-done b { font-family: var(--mono); }
@media (max-width: 520px) { .fsku-row { grid-template-columns: 1fr; grid-template-areas: "model" "act" "name" "why"; }}

.fsku .plan-head { flex-wrap: wrap; }
.fsku .plan-head h3 { white-space: nowrap; }

/* English only: a value translated from another language (specclean/english.py) */
.ftr { display: inline-block; margin-top: 2px; padding: 1px 6px; border-radius: 6px; background: #fff4e5; color: #b54708; }
.ftr.pending { background: #fef3f2; color: #b42318; }

/* 数据 / 标注 on the new flow's cleaning page (owner 2026-11-19: the earlier extraction tools there too) */
.flow .fpane-tabs { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 14px; border-bottom: 1px solid var(--line); background: var(--surface); }
.flow .fpane-tabs > .muted { min-width: 0; overflow-wrap: anywhere; }
.flow #pnotes { overflow: auto; }
.flow #pnotes > .panel-body { overflow: visible; }
.ann-topics { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.ann-saved-list { display: grid; gap: 8px; padding: 12px 14px; }
.ann-saved-head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ann-saved { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; line-height: 1.5; }
.ann-saved > .grow { min-width: 0; overflow-wrap: anywhere; }

/* 重复检测 (dups.js) */
.dup-card { border: 1px solid var(--warn, #f79009); background: var(--warn-soft, #fffaeb); display: grid; gap: 8px; padding: 14px 16px; }
.dup-card h2 { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 16px; }
.dup-row { display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap; padding: 8px 0; border-top: 1px solid var(--line); }
.dup-row > .grow { min-width: 0; overflow-wrap: anywhere; }
.cmp-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.cmp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cmp-col { min-width: 0; display: grid; gap: 4px; align-content: start; }
.cmp-col canvas { border: 1px solid var(--line); background: #fff; }
.cmp-label { font-weight: 600; font-size: 13px; overflow-wrap: anywhere; }
.dup-diff { width: 100%; border-collapse: collapse; font-size: 12.5px; margin-top: 6px; }
.dup-diff th, .dup-diff td { border: 1px solid var(--line); padding: 4px 8px; text-align: left; }
@media (max-width: 720px) { .cmp-grid { grid-template-columns: 1fr; } }

/* 定价 (pricing.js) */
.price-card { display: grid; gap: 8px; padding: 14px 16px; border: 1px solid var(--accent, #2e90fa); }
.price-card h2 { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 16px; }
.price-body { display: grid; gap: 18px; align-content: start; }
.price-top h2 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; }
.price-series { font: 700 15px/1.4 var(--mono); padding: 1px 8px; border-radius: 6px; background: var(--primary-soft); color: var(--primary-ink); letter-spacing: 0.5px; }
.price-top [data-status] { align-self: center; }
.price-rule { display: flex; gap: 8px; align-items: flex-start; margin: 0; padding: 10px 12px; border-radius: 8px; background: var(--surface-2, #f6f8fb); font-size: 13px; color: var(--ink-2); }
.price-rule .ico { flex-shrink: 0; margin-top: 2px; color: var(--primary); }
.price-sec { display: grid; gap: 10px; min-width: 0; }
.price-sec-head { display: flex; align-items: center; gap: 10px; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.price-sec-head h3, .price-sec > summary { margin: 0; font-size: 15px; font-weight: 650; }
.price-sec-head .chip { margin-left: auto; }
.price-row { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: flex-end; }
.price-row label, .price-acc-grid label, .price-model-own { display: grid; gap: 4px; font-size: 12.5px; color: var(--muted); min-width: 0; }
.price-row label > .input, .price-row label > select { min-width: 110px; }
.price-body .input.sm { width: 120px; max-width: 100%; color: var(--ink); }
.price-models { display: grid; gap: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.price-model { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr) minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px 12px; }
.price-model + .price-model { border-top: 1px solid var(--line); }
.price-model-name { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.price-model-name b { font: 700 14px/1.3 var(--mono); letter-spacing: 0.4px; }
.price-model-base { display: grid; gap: 2px; }
.price-more > summary { cursor: pointer; font-size: 13.5px; font-weight: 600; color: var(--primary-ink); padding: 4px 0; }
.price-more[open] > summary { margin-bottom: 8px; }
.price-more { display: grid; gap: 8px; }
.price-var { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: grid; gap: 10px; min-width: 0; }
.price-var.todo { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); background: color-mix(in srgb, var(--warn-soft) 55%, transparent); }
.price-var-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.price-var-head > .grow { flex: 1 1 200px; min-width: 0; overflow-wrap: anywhere; }
.price-yn { display: inline-flex; flex-shrink: 0; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; }
.price-yn label { position: relative; display: inline-flex; align-items: center; min-height: 32px; padding: 0 14px; font-size: 13px; cursor: pointer; color: var(--ink-2); }
.price-yn label + label { border-left: 1px solid var(--line-2); }
.price-yn input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.price-yn label.on, .price-yn label:has(input:checked) { background: var(--primary); color: #fff; }
.price-yn label:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: -2px; }
.price-vals { display: grid; gap: 6px; }
.price-val { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; padding: 6px 0; border-top: 1px dashed var(--line); }
.price-val:first-child { border-top: 0; padding-top: 0; }
.price-val-name { flex: 0 0 140px; font-weight: 600; font-size: 13px; overflow-wrap: anywhere; }
.price-val label { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.price-val .input.sm { width: 90px; }
.price-val-says { font-size: 12.5px; color: var(--muted); }
.price-acc { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: grid; gap: 10px; min-width: 0; }
.price-acc.todo { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); }
.price-acc-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.price-acc-head > .grow { flex: 1 1 200px; min-width: 0; overflow-wrap: anywhere; }
.price-acc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px 14px; }
.price-acc-grid .wide { grid-column: 1 / -1; display: grid; gap: 4px; }
.price-inline { display: inline-flex; flex-wrap: nowrap; align-items: center; gap: 6px; color: var(--muted); }
.price-inline.wrap { flex-wrap: wrap; gap: 6px 14px; }
.price-inline .input.sm { width: 76px; }
.price-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-2); cursor: pointer; min-height: 32px; }
.price-check input { width: 16px; height: 16px; }
.price-rule.warn { background: color-mix(in srgb, var(--warn-soft) 70%, transparent); }
.price-rule.warn .ico { color: var(--warn); }
.price-val.todo .price-val-says { color: var(--warn); font-weight: 600; }
.price-val.todo .input.sm:placeholder-shown { border-color: color-mix(in srgb, var(--warn) 60%, var(--line)); }
.price-id { margin-left: 6px; font: 500 11.5px/1.4 var(--mono); color: var(--muted); }
.price-ids { margin: 0; overflow-wrap: anywhere; }
.price-ids [translate="no"] { font-family: var(--mono); word-spacing: 6px; }
.price-acc-grid .input.sm[data-aq$="|mode"], .price-acc-grid .input.sm[data-aq$="|expr"] { width: 100%; }
.price-acc-kind { display: flex; flex-wrap: wrap; gap: 0 18px; }
.price-acc-kind input { width: 16px; height: 16px; }
.price-conflict { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; padding: 8px 10px; border-radius: 8px; font-size: 12.5px;
  background: color-mix(in srgb, var(--warn-soft) 60%, transparent); color: var(--ink-2); }
@media (max-width: 640px) {
  .price-model { grid-template-columns: 1fr 1fr; }
  .price-model-name { grid-column: 1 / -1; }
  .price-val-name { flex-basis: 100%; }
  .price-yn label, .price-check { min-height: 44px; }
  .price-acc-kind { flex-direction: column; }
}

/* the SuppLux code under a model's column head; 定价 in the step bar */
.fcode { font-size: 11.5px; font-weight: 600; color: var(--accent, #1570ef); margin-top: 2px; letter-spacing: 0.2px; }
.fsteps .fstep-price { border: 1px dashed var(--accent, #2e90fa); background: transparent; cursor: pointer; font-family: inherit; }
.fsteps .fstep-price.done { border-style: solid; }
.fsteps .fstep-price:disabled { opacity: 0.5; cursor: default; }

/* the products' SuppLux codes in the page head (flow.js markCodes) */
.fhead-codes { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; max-width: 52%; flex-shrink: 0; }
.fhead-codes b { font: 700 13px/1.5 var(--mono); padding: 1px 8px; border-radius: 6px; background: var(--primary-soft); color: var(--primary-ink); letter-spacing: 0.5px; }
@media (max-width: 760px) { .fhead-codes { display: none; } }
.fsku-name { gap: 6px 4px; }

/* the original's (supplier's) model number: a small back-office reference beside the SuppLux code, never on a sheet */
.forig { font-size: 11px; font-weight: 400; color: var(--faint, #94a3b8); margin-top: 1px; overflow-wrap: anywhere; }
.fmatrix th .fcode, .ztable th .fcode { display: inline-block; font: 700 13px/1.4 var(--mono); color: var(--primary-ink, #1e40af); letter-spacing: 0.4px; margin: 0; }

/* 配件核对 (acccheck.js) */
.acc-check .acc-row { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line, #e5e7eb); }
.acc-check .acc-row > .grow { flex: 1 1 240px; min-width: 0; }
.acc-check .acc-row:first-child { border-top: 0; }
.acc-check .acc-row.todo b { color: var(--warn, #b45309); }
.acc-check .acc-row select.input { max-width: 200px; }
.acc-check .acc-sub { margin: 14px 0 2px; font-size: 13px; color: var(--muted, #64748b); font-weight: 600; }
.acc-check .acc-list { margin-top: 6px; }
.acc-form { display: grid; gap: 10px; }
@media (max-width: 640px) { .acc-check .acc-row { flex-wrap: wrap; } .acc-check .acc-row select.input { max-width: none; width: 100%; } }

/* the code read out in plain words, under its segments */
.fsku-say { flex-basis: 100%; font: 400 12.5px/1.5 var(--sans, system-ui); color: var(--muted); margin-top: 2px; }

/* 改 / 填: units, preview, a value worked out */
.vh-units { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: -2px 0 8px; }
.vh-preview { min-height: 18px; margin-bottom: 8px; }
.vh-derived { margin-bottom: 8px; }
.fderive { color: var(--accent, #1d4ed8); margin-left: 6px; }

/* 标记错误 (flags.js, owner 2026-11-21): a handed-in product's supplier marks what is wrong; the back office fixes it */
.fflags .plan-head { margin-bottom: 4px; }
.fflag-data { margin: 8px 0; border: 1px solid var(--line, #e5e7eb); border-radius: 8px; padding: 6px 10px; }
.fflag-data summary { cursor: pointer; padding: 2px 0; }
.fflag-group { margin: 8px 0 4px; }
.fflag-row { display: flex; align-items: center; gap: 10px; padding: 5px 0; border-top: 1px solid var(--line, #f1f5f9); }
.fflag-row:first-of-type { border-top: 0; }
.fflag-row .grow { min-width: 0; overflow-wrap: anywhere; }
.fflag-val { display: inline-block; margin-left: 8px; padding: 0 6px; border-radius: 4px; background: #f1f5f9; font-variant-numeric: tabular-nums; }
.fflag-mine { margin-top: 10px; display: grid; gap: 8px; }
.fflag-item { padding: 8px 10px; border-radius: 8px; background: #f8fafc; display: grid; gap: 4px; }
.fflag-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fflag-answer { color: #166534; }
.fflag-card { margin-bottom: 10px; }
.fflag-how { margin-left: 8px; }
.fflag-should { margin-left: 8px; }
.fflag-answer { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
