/* 造每供应商工作台 · 网页版（ops/catalog/SUPPLY_WEB.md，布局第 2 版）。纸感：纸色底、相纸白的卡、墨色字；状态色只有四种——
   进行中（墨色）、要处理（橙）、异常（红）、完成（灰）。不自造颜色：下面这一段 token 和小程序 miniprogram/app.wxss 同名同值。 */
:root {
  /* tokens:app.wxss —— 同名搬过来：颜色、字体原样；rpx 按 2rpx = 1px；字号取小程序里封顶的那个值。test/web/supplier.js 逐个核对，别手改数值 */
  --paper: #F6F0E6;
  --card: #FFFDF8;
  --stage: #EFE9DF;
  --line: #E6DCCB;
  --line-strong: #8E7D6F;
  --ink: #3A2C24;
  --ink-muted: #6B5A4D;
  --primary: #3A2C24;
  --on-primary: #FFF8EE;
  --accent: #D9652B;
  --accent-ink: #A84A1A;
  --accent-soft: #F8E3D3;
  --sage: #7F8F65;
  --sage-soft: #E7EBDD;
  --success: #2E7D32;
  --warning: #A35F00;
  --danger: #B3261E;
  --scrim: linear-gradient(180deg, rgba(42, 31, 25, 0.2) 0%, rgba(42, 31, 25, 0.46) 100%);
  --sheet-panel: rgba(255, 253, 248, 0.97);
  --font-sans: -apple-system, "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-display: "ZaomeeSerif", "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", serif;
  --fs-micro: 11.5px;
  --fs-caption: 12.5px;
  --fs-note: 14px;
  --fs-body-s: 15px;
  --fs-body: 16px;
  --fs-title-s: 18px;
  --fs-lead: 19px;
  --fs-title-m: 23.5px;
  --fs-title-l: 27.5px;
  --radius-xs: 4px;
  --radius-s: 8px;
  --radius-m: 12px;
  --radius-l: 16px;
  --radius-xl: 22px;
  --radius-pill: 499.5px;
  --glass: rgba(255, 253, 248, 0.64);
  --glass-strong: rgba(255, 253, 248, 0.86);
  --glass-dark: rgba(58, 44, 36, 0.9);
  --glass-edge: rgba(58, 44, 36, 0.1);
  --glass-float: 0 6px 16px rgba(58, 44, 36, 0.1), 0 1px 3px rgba(58, 44, 36, 0.05);
  --glass-float-s: 0 3px 9px rgba(58, 44, 36, 0.1), 0 0.5px 1.5px rgba(58, 44, 36, 0.06);
  --shadow-photo: 0 2px 8px rgba(58, 44, 36, 0.18);
  /* tokens:end */
  /* 只有网页有的版面尺寸（不是颜色） */
  --web-side: 200px;
  --web-top: 56px;
  --web-gutter: 28px;
  --web-hit: 36px;
  --web-row: 46px;
  --web-drawer: 460px;
  --web-quote: 320px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font-sans); font-size: var(--fs-body); line-height: 1.55; -webkit-font-smoothing: antialiased; }
body.has-layer { overflow: hidden; }
h1, h2, h3, h4, p, ol { margin: 0; padding: 0; }
ol { list-style: none; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: 0.5; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.hide { display: none; }
.mono { font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }
.noscript { padding: 40px; text-align: center; }

/* 状态色四种：进行中（墨色）、要处理（橙）、异常（红）、完成（灰）。橙色只给「要你处理的」 */
.tone-todo { color: var(--accent-ink); }
.tone-bad { color: var(--danger); }
.tone-done { color: var(--ink-muted); }

/* ---- 外壳：左侧导航（带数字角标）+ 顶栏 + 内容 ---- */
.app { display: grid; grid-template-columns: var(--web-side) minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; align-self: start; height: 100vh; padding: 18px 12px; border-right: 1px solid var(--line); background: var(--stage); display: flex; flex-direction: column; gap: 18px; }
.brand { display: flex; flex-direction: column; gap: 2px; padding: 4px 10px; text-decoration: none; }
.brand-mark { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-title-m); line-height: 1.2; }
.brand-sub { font-size: var(--fs-note); color: var(--ink-muted); }
.nav { flex: 1; display: flex; flex-direction: column; justify-content: space-between; gap: 16px; }
.nav-group { display: flex; flex-direction: column; gap: 4px; }
.nav-label { padding: 0 12px 2px; font-size: var(--fs-note); color: var(--ink-muted); letter-spacing: 0.06em; }
.nav-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 40px; padding: 0 12px; border-radius: var(--radius-m); text-decoration: none; color: var(--ink); font-size: var(--fs-body); }
.nav-item:hover { background: var(--glass); }
.nav-item.is-on { background: var(--card); font-weight: 500; box-shadow: var(--glass-float-s); }
.nav-item.is-soon { min-height: 34px; color: var(--ink-muted); font-size: var(--fs-body); }
.nav-badge { min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-primary); font-size: var(--fs-note); line-height: 22px; text-align: center; font-variant-numeric: tabular-nums; }
.main { min-width: 0; display: flex; flex-direction: column; }
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--web-top); padding: 8px var(--web-gutter); background: var(--glass-strong); backdrop-filter: blur(20px) saturate(1.25); -webkit-backdrop-filter: blur(20px) saturate(1.25); border-bottom: 1px solid var(--glass-edge); }
.top-shop { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 0 1 auto; }
.top-shop-text { display: flex; flex-direction: column; min-width: 0; }
.top-shop-state { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-shop-sub { font-size: var(--fs-note); color: var(--ink-muted); overflow-wrap: anywhere; }
.top-who { display: flex; align-items: center; justify-content: flex-end; gap: 10px; min-width: 0; flex: 1 1 0; }
.top-who .btn { flex: none; white-space: nowrap; }
.top-name { flex: 0 1 auto; min-width: 0; font-size: var(--fs-body); color: var(--ink-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 28vw; }
.switch { flex: none; position: relative; width: 52px; height: 32px; padding: 0; border: 0; border-radius: var(--radius-pill); background: var(--line-strong); transition: background 0.18s ease; }
.switch::after { content: ""; position: absolute; inset: -6px -4px; }
.switch.is-on { background: var(--sage); }
.switch-knob { position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: var(--card); box-shadow: var(--shadow-photo); transition: transform 0.18s ease; }
.switch.is-on .switch-knob { transform: translateX(20px); }
.view { flex: 1; min-width: 0; padding: 22px var(--web-gutter) 0; outline: none; }
.boot { min-height: 100vh; display: flex; align-items: center; justify-content: center; }

/* ---- 每一页：页头一行（标题 + 一句现状 + 最多一个主按钮）→ 内容（最多两栏）→ 底部操作条 ---- */
.page { display: flex; flex-direction: column; gap: 16px; max-width: 880px; min-height: calc(100vh - var(--web-top) - 22px); padding-bottom: 40px; }
.page-wide { max-width: 1320px; }
.is-busy { pointer-events: none; opacity: 0.7; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px 20px; }
.head-main { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 16px; min-width: 0; }
.crumb { flex: 0 0 100%; display: flex; align-items: center; gap: 6px; font-size: var(--fs-note); color: var(--ink-muted); }
.crumb-link { color: var(--ink-muted); text-underline-offset: 3px; }
.page-title { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-title-l); line-height: 1.25; }
.head-line { font-size: var(--fs-body); color: var(--ink-muted); }
.head-line.tone-todo { color: var(--accent-ink); }
.head-action { flex: none; display: flex; gap: 8px; }
.head-action:empty { display: none; }
.page-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 32px; }
.page-foot-note { font-size: var(--fs-note); color: var(--ink-muted); }
.note { white-space: pre-line; font-size: var(--fs-body); color: var(--ink-muted); }
.note.tone-todo { color: var(--accent-ink); }
.note.tone-bad { color: var(--danger); }
.link { color: var(--accent-ink); text-underline-offset: 3px; }
.link-btn { padding: 0; border: 0; background: transparent; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; font-size: var(--fs-body); white-space: nowrap; }
.row-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; }
.sec { display: flex; flex-direction: column; gap: 10px; }
.sec-title { font-size: var(--fs-body); font-weight: 500; color: var(--ink-muted); }
/* 吸底操作条：选了东西、或有改动时才出现（不插在表格上面） */
.bar { position: sticky; bottom: 12px; z-index: 4; margin-top: auto; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 16px; padding: 10px 12px 10px 18px; border-radius: var(--radius-l); background: var(--sheet-panel); border: 1px solid var(--glass-edge); box-shadow: var(--glass-float); }
.bar-text { font-size: var(--fs-body); font-weight: 500; min-width: 0; overflow-wrap: anywhere; }
.bar-acts { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.nav-item.is-soon .nav-badge { background: var(--stage); color: var(--ink-muted); box-shadow: inset 0 0 0 1px var(--line); }
.todo-row.is-away .todo-dot { background: var(--line-strong); } /* 这里办不了的：不用橙色催 */
.todo-hint { flex: none; max-width: 46%; font-size: var(--fs-body); color: var(--ink-muted); text-align: right; }
.top[hidden], .ck-must[hidden], .price-kids[hidden], .bar[hidden], .nav-badge[hidden], .input[hidden], .field[hidden], .grp-acts[hidden], .link-btn[hidden] { display: none; }
.ck-secs, .grp-extra { display: contents; }
.note[hidden], .sec[hidden], .qa[hidden], .fold-body[hidden], .q-num[hidden], .q-file[hidden], .q-old[hidden], .q-tip[hidden] { display: none; }
/* 问工厂的几项：一排小按钮单选，数字带单位，下面一行小字说「这会用在」哪 */
.qa { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); }
.sec > .qa:first-of-type, .q-more > .qa:first-of-type, .join-q-one:first-of-type > .qa { border-top: 0; padding-top: 0; }
.q-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.ask-one { display: grid; gap: 16px; }
.meas-row .cell-sub { white-space: nowrap; }
.meas { display: grid; grid-template-columns: 220px 1fr; gap: 20px; align-items: start; }
.meas-pic { width: 100%; border-radius: 12px; background: var(--card); }
.meas-rows { display: grid; gap: 8px; }
.meas-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.meas-row[hidden] { display: none; }
.meas-code { min-width: 72px; }
.meas-row .input-num { width: 88px; }
.meas-row .note { flex-basis: 100%; }
@media (max-width: 720px) { .meas { grid-template-columns: 1fr; } .meas-pic { max-width: 260px; } }
.set-group { display: grid; gap: 8px; }
.set-group-title { font-size: var(--fs-body); font-weight: 500; color: var(--ink-muted); }
.set-rows, .set-todo { display: grid; border-radius: 14px; background: var(--card); overflow: hidden; }
.set-todo:empty { display: none; }
.set-fold + .set-fold { border-top: 1px solid var(--line); }
.set-fold-head { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 52px; padding: 0 16px; background: none; border: 0; font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.set-name { flex: none; }
.set-value { flex: 1; min-width: 0; text-align: right; color: var(--ink-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.set-more { flex: none; color: var(--ink-muted); transition: transform 0.2s; }
.set-fold.is-open .set-more { transform: rotate(90deg); }
.set-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.set-dot[hidden] { display: none; }
.set-fold-body { display: grid; gap: 12px; padding: 4px 16px 18px; }
.set-fold-body[hidden] { display: none; }
.set-fold-body > .sec:first-child > .sec-title { display: none; }
.diff-own { display: grid; gap: 8px; margin-top: 8px; }
.diff-own[hidden] { display: none; }
.diff-nums { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.diff-nums .input-num { width: 88px; }
.pref-row { display: grid; gap: 6px; margin-top: 14px; }
.q-opt { min-height: 36px; padding: 0 14px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--card); color: var(--ink); font: inherit; font-size: var(--fs-body); cursor: pointer; }
.q-opt:hover { border-color: var(--line-strong); }
.q-opt.is-on { border-color: var(--sage); background: var(--sage-soft); font-weight: 500; }
.q-extra { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.q-extra:empty { display: none; }
.q-num { display: inline-flex; align-items: center; gap: 8px; }
.q-num .input { width: 96px; }
.q-unit { font-size: var(--fs-body); color: var(--ink-muted); white-space: nowrap; }
.q-file { display: inline-flex; align-items: center; gap: 10px; }
.q-file-n { font-size: var(--fs-body); color: var(--ink-muted); }
.q-use, .q-old { font-size: var(--fs-note); color: var(--ink-muted); }
.q-tip { font-size: var(--fs-body); color: var(--ink-muted); }
.q-tip.tone-todo { color: var(--accent-ink); }
.q-more { display: flex; flex-direction: column; }
.fold-body:empty { display: none; }

/* 按钮、胶囊、输入。一屏只有一个深色主按钮 */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; min-width: 64px; padding: 0 16px; border: 1px solid var(--glass-edge); border-radius: var(--radius-pill); background: var(--card); color: var(--ink); font-size: var(--fs-body); white-space: nowrap; text-decoration: none; }
.btn:hover:not(:disabled) { box-shadow: var(--glass-float-s); }
.btn-primary { background: var(--glass-dark); border-color: transparent; color: var(--on-primary); font-weight: 500; }
.btn-small { min-height: var(--web-hit); padding: 0 14px; }
.btn-quiet { background: transparent; border-color: transparent; color: var(--ink-muted); }
.btn-danger { background: var(--danger); color: var(--on-primary); }
.chip { display: inline-flex; align-items: center; justify-content: center; min-height: 24px; padding: 0 10px; border-radius: var(--radius-pill); background: var(--stage); color: var(--ink); font-size: var(--fs-note); white-space: nowrap; }
.chip.tone-todo { background: var(--accent-soft); color: var(--accent-ink); }
.chip.tone-bad { background: var(--card); color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); }
.chip.tone-done { color: var(--ink-muted); }
.input { width: 100%; min-height: 40px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-m); background: var(--card); color: var(--ink); caret-color: var(--accent); }
.input:focus { border-color: var(--line-strong); outline: none; box-shadow: 0 0 0 3px var(--sage-soft); }
.input:disabled { background: var(--stage); color: var(--ink-muted); }
.input-money, .input-num { width: 96px; text-align: right; font-variant-numeric: tabular-nums; }
.input-big { width: 100%; min-height: 52px; font-size: var(--fs-title-m); font-weight: 500; }
.area { resize: vertical; min-height: 96px; line-height: 1.5; }
.copy-box { min-height: 160px; }
.check { width: 18px; height: 18px; margin: 0; accent-color: var(--ink); flex: none; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-label { font-size: var(--fs-body); color: var(--ink-muted); }
.field-hint { font-size: var(--fs-note); color: var(--ink-muted); }
.x { flex: none; width: 36px; height: 36px; border: 0; border-radius: 50%; background: transparent; color: var(--ink-muted); font-size: 22px; line-height: 1; }
.x:hover { background: var(--stage); color: var(--ink); }

/* 在准备、空的、出错 */
.state { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 160px; color: var(--ink-muted); font-size: var(--fs-body); }
.state-glow { width: 10px; height: 10px; border-radius: 50%; background: var(--line-strong); animation: glow 1.2s ease-in-out infinite; }
@keyframes glow { 0%, 100% { opacity: 0.25; transform: scale(0.8); } 50% { opacity: 0.9; transform: scale(1); } }
.state-empty { flex-direction: column; gap: 10px; padding: 40px 24px; border-radius: var(--radius-l); background: var(--glass); text-align: center; }
.state-title { font-size: var(--fs-title-s); color: var(--ink); font-weight: 500; }
.state-sub { max-width: 520px; font-size: var(--fs-body); color: var(--ink-muted); }
.state-soon { align-items: center; }
.banner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 18px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.banner-title { font-size: var(--fs-body); font-weight: 500; color: var(--ink); }
.banner.tone-bad .banner-title { color: var(--danger); }
.banner-sub { font-size: var(--fs-body); color: var(--ink-muted); }

/* ---- 今天：现在要做的（最多 5 行）→ 订单概况 → 进度 ---- */
.todo { display: flex; flex-direction: column; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.todo-row { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px 14px 8px 18px; }
.todo-row + .todo-row { border-top: 1px solid var(--line); }
.todo-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.todo-row.tone-bad .todo-dot { background: var(--danger); }
.todo-text { flex: 1; min-width: 0; font-size: var(--fs-body); color: var(--ink); overflow-wrap: anywhere; }
.todo-row.tone-bad .todo-text { color: var(--danger); }
.todo-more { padding: 8px 18px 12px; font-size: var(--fs-note); color: var(--ink-muted); }
.todo-none { padding: 22px 18px; color: var(--ink-muted); font-size: var(--fs-body); }
.strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); overflow: hidden; }
.strip-item { display: flex; align-items: baseline; gap: 8px; padding: 12px 18px; text-decoration: none; color: var(--ink); }
.strip-item + .strip-item { border-left: 1px solid var(--line); }
.strip-item:hover { background: var(--paper); }
.strip-n { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-title-m); font-variant-numeric: tabular-nums; }
.strip-t { font-size: var(--fs-body); color: var(--ink-muted); }
.strip-item.is-zero .strip-n { color: var(--ink-muted); }
.steps { display: flex; flex-direction: column; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.step { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 8px 18px; }
.step + .step { border-top: 1px solid var(--line); }
.step-t { font-weight: 500; }
.kv { display: flex; align-items: baseline; gap: 16px; padding: 8px 0; border-top: 1px solid var(--line); font-size: var(--fs-body); }
.sec > .kv:first-of-type { border-top: 0; }
.kv-k { flex: none; width: 34%; max-width: 180px; color: var(--ink-muted); overflow-wrap: anywhere; }
.kv-v { flex: 1; min-width: 0; color: var(--ink); overflow-wrap: anywhere; }
.kv-v.tone-bad { color: var(--danger); }

/* ---- 表格：行高 44–48，数字右对齐等宽，状态用四色胶囊 ---- */
.seg { display: inline-flex; gap: 4px; padding: 3px; border-radius: var(--radius-pill); background: var(--stage); }
.seg-item { display: inline-flex; align-items: center; gap: 6px; min-height: var(--web-hit); padding: 0 16px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--ink-muted); font-size: var(--fs-body); white-space: nowrap; }
.seg-item.is-on { background: var(--card); color: var(--ink); font-weight: 500; box-shadow: var(--glass-float-s); }
.seg-n { font-size: var(--fs-note); font-variant-numeric: tabular-nums; }
.toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px 12px; }
.search-box { display: flex; align-items: center; gap: 6px; }
.search { width: 260px; min-height: var(--web-hit); border-radius: var(--radius-pill); padding: 6px 16px; }
.quick { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.quick:empty { display: none; }
.tbl-wrap { border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); overflow: hidden; }
.tbl { width: 100%; border-collapse: collapse; font-size: var(--fs-body); }
.tbl th { padding: 10px 12px; text-align: left; font-weight: 500; font-size: var(--fs-note); color: var(--ink-muted); background: var(--stage); white-space: nowrap; }
.tbl td { height: var(--web-row); padding: 6px 12px; border-top: 1px solid var(--line); vertical-align: middle; overflow-wrap: anywhere; }
.tbl .row { cursor: pointer; }
.tbl .row:hover td, .tbl .row:focus-visible td { background: var(--paper); }
.tbl .is-picked td { background: var(--sage-soft); }
.tbl th.col-num, .tbl td.col-num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.col-check { width: 44px; text-align: center; }
.col-no { white-space: nowrap; }
.col-no .chip { margin-left: 6px; }
.col-due { white-space: nowrap; }
.col-due .cell-sub { display: inline; margin-left: 8px; }
.col-to { white-space: nowrap; color: var(--ink-muted); }
.col-ship { white-space: nowrap; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.cell-main { display: block; color: var(--ink); }
.cell-sub { display: block; font-size: var(--fs-note); color: var(--ink-muted); }
.cell-sub.tone-bad { color: var(--danger); }
.cell-none { color: var(--ink-muted); }
.tbl-orders .cell-main, .tbl-orders .col-spec .cell-sub { display: inline; }
.tbl-orders .col-spec .cell-sub::before { content: " · "; }
.sect th { padding: 8px 12px; background: var(--card); border-top: 1px solid var(--line); }
.sect-title { font-size: var(--fs-body); font-weight: 500; color: var(--ink); }
.sect-title.tone-todo { color: var(--accent-ink); }
.sect-title.tone-bad { color: var(--danger); }
.sect-n { margin-left: 8px; font-size: var(--fs-note); color: var(--ink-muted); font-weight: 400; }
.tbl-tight td, .tbl-tight th { padding: 6px 10px; }
.tbl-tight .row { cursor: default; }
.tbl-tight .input { min-height: 34px; padding: 4px 10px; }

/* ---- 品类总表：供货价、周期、运费直接在格子里填 ---- */
.cats-host, .check-host { display: flex; flex-direction: column; gap: 12px; }
.tbl-cats td { white-space: nowrap; }
.cell-in { display: inline-block; width: 84px; min-height: 34px; padding: 4px 8px; }
.cell-in-s { width: 52px; }
select.cell-in { width: 88px; text-align: left; }
.cell-pre, .cell-post { margin: 0 4px; color: var(--ink-muted); font-size: var(--fs-note); }
.cell-ref { margin-left: 8px; color: var(--ink-muted); font-size: var(--fs-note); }
.col-shipfee .input-money { margin-left: 6px; width: 64px; }
.cat-row.is-dirty td { background: var(--paper); }
.cat-row.is-dirty .col-cat .cell-main::after { content: " · 改了没存"; color: var(--accent-ink); font-size: var(--fs-note); }
.cat-row.is-err .col-price .input { border-color: var(--danger); }
.col-need { max-width: 260px; white-space: normal; }
.need { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; padding: 4px 10px; border: 0; border-radius: var(--radius-pill); background: var(--accent-soft); color: var(--accent-ink); font-size: var(--fs-note); text-align: left; }
.need.tone-bad { background: var(--card); color: var(--danger); box-shadow: inset 0 0 0 1px var(--danger); }
.need-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.need-go { flex: none; font-weight: 500; }
.col-go { text-align: right; }

/* ---- 核对页：主栏核对品规 + 右栏报价面板 ---- */
.ck-layout { display: grid; grid-template-columns: minmax(0, 1fr) var(--web-quote); gap: 20px; align-items: start; }
.ck-main-col { display: flex; flex-direction: column; gap: 22px; min-width: 0; padding: 0 22px 22px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.ck-sum { position: sticky; top: var(--web-top); z-index: 3; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; margin: 0 -22px; padding: 12px 22px; border-bottom: 1px solid var(--line); border-radius: var(--radius-l) var(--radius-l) 0 0; background: var(--sheet-panel); }
.ck-sum-text { font-size: var(--fs-body); font-weight: 500; font-variant-numeric: tabular-nums; }
.ck-only { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-body); color: var(--ink-muted); cursor: pointer; }
.ck-q { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.sec > .ck-q:first-of-type { border-top: 0; padding-top: 0; }
.ck-q-text { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: var(--fs-body); }
.ck-must { padding: 0 8px; border-radius: var(--radius-pill); background: var(--accent-soft); color: var(--accent-ink); font-size: var(--fs-note); line-height: 20px; }
.grp { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 6px 12px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line); }
.grp-head { display: flex; flex-direction: column; gap: 2px; padding-top: 4px; }
.grp-name { font-weight: 500; font-size: var(--fs-body); }
.grp-n { font-size: var(--fs-note); color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.grp-vals { display: flex; flex-wrap: wrap; gap: 6px; }
.grp-acts { display: flex; gap: 12px; padding-top: 6px; }
.val { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 12px; border: 1px solid transparent; border-radius: var(--radius-pill); background: var(--paper); color: var(--ink-muted); font-size: var(--fs-body); text-decoration: line-through; white-space: nowrap; }
.val.is-on { background: var(--sage-soft); color: var(--ink); text-decoration: none; }
.val.is-soon { background: transparent; border: 1px dashed var(--line-strong); text-decoration: none; }
.val.is-soon.is-on { background: var(--sage-soft); border-style: solid; }
.val-soon { font-size: var(--fs-note); color: var(--ink-muted); }
.val.is-on .val-soon { display: none; }
.add-row, .grp-extra > .note { grid-column: 2 / -1; }
.add-row { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.add-one { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-note); color: var(--ink-muted); }
.add-one .input { width: 68px; min-height: 30px; padding: 2px 8px; }
.fold { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-radius: var(--radius-m); background: var(--paper); font-size: var(--fs-body); }
.tbl-same { border: 1px solid var(--line); border-radius: var(--radius-m); border-collapse: separate; border-spacing: 0; overflow: hidden; }
.tbl-same th { background: var(--paper); }
.tbl-same td { height: auto; min-height: var(--web-row); padding: 8px 12px; vertical-align: top; }
.tbl-same tr.is-diff td { background: var(--paper); }
.col-same { width: 190px; }
.same-cell { display: flex; flex-direction: column; gap: 6px; }
.same-seg { display: inline-flex; gap: 2px; padding: 2px; border-radius: var(--radius-pill); background: var(--stage); align-self: flex-start; }
.same-opt { min-height: 30px; padding: 0 12px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--ink-muted); font-size: var(--fs-note); white-space: nowrap; }
.same-opt.is-on { background: var(--card); color: var(--ink); font-weight: 500; box-shadow: var(--glass-float-s); }
.same-opt.is-on.is-diff { background: var(--accent-soft); color: var(--accent-ink); }
.same-cell .input { min-height: 34px; padding: 4px 10px; font-size: var(--fs-body); }
.quote { position: sticky; top: calc(var(--web-top) + 12px); display: flex; flex-direction: column; gap: 14px; max-height: calc(100vh - var(--web-top) - 24px); overflow: auto; padding: 18px 20px 20px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.quote-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.quote-title { font-size: var(--fs-body); font-weight: 500; margin-right: auto; }
.quote-cell, .pills { display: flex; flex-direction: column; gap: 8px; }
.pills .affix[hidden] { display: none; }
/* 确认一屏（7n）：一行一样，改过的标出来 */
.sure-rows { flex: none; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.sure-row { flex: none; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 10px 14px; border: 0; background: var(--card); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.sure-rows > :not(:first-child) { border-top: 1px solid var(--line); }
.sure-which { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 14px; background: var(--paper); }
.sure-which[hidden] { display: none; }
.sure-row:hover { background: var(--paper); }
.sure-t { flex: none; width: 7em; display: flex; flex-direction: column; color: var(--ink-muted); font-size: var(--fs-body); }
.sure-v { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.sure-tag { padding: 0 8px; border-radius: var(--radius-pill); background: var(--accent-soft); color: var(--accent-ink); font-size: var(--fs-note); }
.sure-list { display: grid; gap: 10px; }
.sure-li { display: flex; flex-direction: column; }
.quote-acts { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
.quote-acts .btn-primary { min-height: 46px; font-size: var(--fs-body); }
.quote-sample { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: var(--radius-m); background: var(--accent-soft); }
.thumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.thumb { position: relative; width: 72px; height: 72px; border-radius: var(--radius-m); overflow: hidden; background: var(--stage); box-shadow: var(--shadow-photo); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .x { position: absolute; top: 2px; right: 2px; width: 28px; height: 28px; background: var(--glass-strong); font-size: 18px; }
.thumb-wide { width: 200px; height: 140px; }

/* ---- 入驻 ---- */
.join-top { display: flex; flex-direction: column; gap: 12px; }
.join-steps { display: flex; flex-wrap: wrap; gap: 8px; }
.join-step { display: inline-flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 14px 0 5px; border-radius: var(--radius-pill); background: var(--glass); color: var(--ink-muted); font-size: var(--fs-body); }
.join-step-in { display: inline-flex; align-items: center; gap: 8px; color: inherit; text-decoration: none; white-space: nowrap; }
.join-step-n { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: var(--stage); font-size: var(--fs-note); font-variant-numeric: tabular-nums; }
.join-step.is-on { background: var(--card); color: var(--ink); font-weight: 500; box-shadow: var(--glass-float-s); }
.join-step.is-on .join-step-n, .join-step.is-done .join-step-n { background: var(--ink); color: var(--on-primary); }
.join-body { display: flex; flex-direction: column; gap: 16px; }
.join-form { display: flex; flex-direction: column; gap: 20px; max-width: 760px; padding: 20px 24px 24px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.join-q { display: flex; flex-direction: column; }
.join-q + .join-q { margin-top: 12px; }
.join-q-cat { font-size: var(--fs-body); font-weight: 500; margin-bottom: 4px; }
.join-q > .ck-q:first-of-type { border-top: 0; padding-top: 0; }
/* ---- 设置 › 接单方式（4c） ---- */
.set-body { display: flex; flex-direction: column; gap: 20px; }
.modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.mode { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--card); text-align: left; cursor: pointer; font: inherit; color: var(--ink); }
.mode:hover { border-color: var(--line-strong); }
.mode.is-on { border-color: var(--ink); box-shadow: var(--glass-float-s); }
.mode-t { font-size: var(--fs-body); font-weight: 500; }
.mode-d { font-size: var(--fs-body); color: var(--ink-muted); line-height: 1.6; }
.fmts { display: flex; flex-direction: column; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.fmt { display: flex; align-items: center; gap: 12px; padding: 4px 16px 4px 4px; }
.fmt + .fmt { border-top: 1px solid var(--line); }
.fmt-pick { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; min-height: var(--web-row); padding: 8px 12px 8px 36px; border: 0; background: transparent; text-align: left; cursor: pointer; font: inherit; color: var(--ink); position: relative; }
.fmt-pick::before { content: ""; position: absolute; left: 12px; top: 50%; width: 14px; height: 14px; margin-top: -8px; border: 1px solid var(--line-strong); border-radius: 50%; }
.fmt.is-on .fmt-pick::before { border: 5px solid var(--ink); width: 6px; height: 6px; }
.fmt-name { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: var(--fs-body); font-weight: 500; }
.fmt-hint { font-size: var(--fs-note); color: var(--ink-muted); }
.fmt-acts { flex: none; display: flex; align-items: center; gap: 14px; }
.set-file { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-body); color: var(--ink-muted); white-space: nowrap; }
.fmt-cols { display: flex; flex-direction: column; gap: 6px; }
.fmt-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) 32px; gap: 8px; align-items: center; }
.fmt-head { font-size: var(--fs-note); color: var(--ink-muted); }
.fmt-what { display: flex; gap: 6px; min-width: 0; }
.fmt-what .input { min-width: 0; flex: 1; }
.fmt-row.is-blank .fmt-what select { color: var(--accent-ink); }
.fmt-preview { display: flex; flex-direction: column; gap: 8px; }
.tbl-scroll { overflow-x: auto; }
.tbl-preview td, .tbl-preview th { white-space: nowrap; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.code { margin: 0; padding: 10px 12px; border-radius: var(--radius-m); background: var(--stage); font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, monospace); font-size: var(--fs-note); line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.set-token { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: var(--fs-body); }
.set-token-k { color: var(--ink-muted); }
.set-token-v { overflow-wrap: anywhere; }
.set-try { display: flex; flex-direction: column; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.set-test { display: flex; flex-direction: column; gap: 6px; }
.cell-in-code { width: 104px; }
.input-code { width: 96px; }
.quote-codes { display: flex; flex-direction: column; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.ship-from .note { line-height: 1.7; }
.join-agree { display: flex; align-items: center; gap: 10px; font-size: var(--fs-body); }
.terms { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px 16px; }
.spec-actions { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 4px; }
.doc { display: flex; flex-direction: column; gap: 8px; font-size: var(--fs-body); line-height: 1.7; }
.doc-h { margin-top: 8px; font-size: var(--fs-body); font-weight: 500; }
.doc-p { color: var(--ink); }

/* ---- 弹层：居中的面板、右边的抽屉 ---- */
.scrim { position: fixed; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; background: var(--scrim); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.layer-panel { display: flex; flex-direction: column; width: min(480px, calc(100vw - 32px)); max-height: calc(100vh - 48px); border-radius: var(--radius-xl); background: var(--sheet-panel); box-shadow: 0 -10px 32px rgba(58, 44, 36, 0.2); }
.layer-wide { width: min(760px, calc(100vw - 32px)); }
.layer-drawer { position: absolute; top: 0; right: 0; bottom: 0; width: min(var(--web-drawer), 100vw); max-height: none; border-radius: var(--radius-xl) 0 0 var(--radius-xl); }
.layer-drawer.layer-wide { width: min(720px, 100vw); }
.layer-panel.is-busy { pointer-events: none; opacity: 0.75; }
.layer-head { display: flex; align-items: center; gap: 12px; padding: 16px 12px 12px 24px; }
.layer-title { flex: 1; min-width: 0; font-size: var(--fs-title-s); font-weight: 500; overflow-wrap: anywhere; }
.layer-body { flex: 1; min-height: 0; overflow: auto; display: flex; flex-direction: column; gap: 14px; padding: 4px 24px 20px; }
.layer-foot { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; padding: 12px 24px 20px; }
.layer-foot:empty { display: none; }
.choices { display: flex; flex-direction: column; gap: 8px; }
.choice { min-height: 48px; padding: 0 16px; border: 1px solid var(--glass-edge); border-radius: var(--radius-m); background: var(--card); text-align: left; font-size: var(--fs-body); }
.choice:has(.choice-note) { padding-block: 10px; }
.choice-note { display: block; margin-top: 2px; font-size: var(--fs-note); color: var(--ink-muted); font-weight: 400; }
.choice:hover { border-color: var(--ink); }
.detail { display: flex; flex-direction: column; gap: 20px; }
.detail-top { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.links { display: flex; flex-direction: column; gap: 8px; }
.ship-top { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 12px 20px; }
.ship-top .field { width: 200px; }
.ship-extra { display: flex; flex-direction: column; gap: 8px; }
.ship-extra:empty, .ship-bad:empty, .ship-miss:empty { display: none; }
.ship-rows { border: 1px solid var(--line); border-radius: var(--radius-m); overflow: auto; }
.toasts { position: fixed; left: 50%; bottom: 84px; z-index: 40; display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateX(-50%); pointer-events: none; }
.toast { max-width: min(560px, calc(100vw - 32px)); padding: 10px 18px; border-radius: var(--radius-pill); background: var(--glass-dark); color: var(--on-primary); font-size: var(--fs-body); box-shadow: var(--glass-float); transition: opacity 0.22s ease, transform 0.22s ease; }
.toast-out { opacity: 0; transform: translateY(6px); }

/* ---- 登录 ---- */
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { display: flex; flex-direction: column; align-items: center; gap: 20px; width: min(420px, 100%); padding: 36px 32px; border-radius: var(--radius-xl); background: var(--card); box-shadow: var(--glass-float); text-align: center; }
.brand-big { align-items: center; padding: 0; }
.login-box { display: flex; flex-direction: column; align-items: center; gap: 14px; width: 100%; }
.login-title { font-size: var(--fs-title-s); font-weight: 500; }
.login-qr { width: 220px; height: 220px; border-radius: var(--radius-m); background: var(--stage); }
.login-code { display: flex; gap: 8px; }
.login-digit { display: flex; align-items: center; justify-content: center; width: 44px; height: 56px; border-radius: var(--radius-m); background: var(--paper); font-family: var(--font-display); font-weight: 700; font-size: var(--fs-title-l); font-variant-numeric: tabular-nums; }
.login-left { font-size: var(--fs-note); color: var(--ink-muted); min-height: 20px; }
.login-alt { font-size: var(--fs-note); color: var(--ink-muted); }

/* ---- 打印生产单 ---- */
.print-root { display: none; }
@media print {
  body { background: #FFFFFF; }
  .app, .scrim, .toasts, .login, .boot { display: none !important; }
  .print-root { display: block; color: #000000; font-size: 12pt; }
  .print-head { display: flex; justify-content: space-between; padding-bottom: 6pt; border-bottom: 1pt solid #000000; font-weight: 700; }
  .print-card { padding: 10pt 0; border-bottom: 0.5pt solid #000000; break-inside: avoid; }
  .print-top { display: flex; flex-wrap: wrap; gap: 4pt 14pt; margin-bottom: 4pt; }
  .print-no { font-weight: 700; font-size: 14pt; }
  .print-item { margin-top: 3pt; }
  .print-sheets { break-before: page; font-size: 0; }
  .print-sheet { display: inline-block; width: 49%; margin: 0 1% 4mm 0; break-inside: avoid; border: 0.5pt solid #999999; }
  .print-name { font-weight: 700; }
  .print-labels, .print-labels * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .lb-page { background: #FFFFFF; color: #000000; }
  .lb-thermal { outline: 0.15mm dashed #000000; } /* 剪开的线；A4 用裁好的不干胶，不画 */
}

/* 标签（7w）：一件一张。尺寸和 js/labels-model.js 一样（用例核）；热敏按 203 点，纯黑白。屏幕上只有样张用得到 */
@page lb-a4 { size: 210mm 297mm; margin: 0; }
@page lb-thermal { size: 100mm 150mm; margin: 0; }
.lb-page { display: grid; align-content: start; overflow: hidden; break-after: page; font-family: var(--font-sans); }
.lb-page-a4 { page: lb-a4; width: 210mm; height: 297mm; grid-template-columns: repeat(3, 70mm); grid-auto-rows: 37mm; }
.lb-page-thermal { page: lb-thermal; width: 100mm; height: 150mm; grid-template-columns: repeat(2, 50mm); grid-auto-rows: 37.5mm; }
.lb { position: relative; display: grid; overflow: hidden; line-height: 1.25; }
.lb-qr { display: block; width: 100%; height: 100%; }
.lb-pic { object-fit: cover; }
.lb-name { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.lb-spec { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.lb-foot { display: flex; flex-wrap: wrap; gap: 0 2mm; }
.lb-a4 { width: 70mm; height: 37mm; grid-template: "c t" 1fr "c f" auto / 24.6mm 1fr; gap: 0 1mm; padding: 4mm 4mm 4mm 2mm; align-items: start; }
.lb-a4 .lb-code-box { grid-area: c; width: 24.6mm; height: 24.6mm; align-self: center; }
.lb-a4 .lb-text { grid-area: t; padding-right: 15mm; min-width: 0; }
.lb-a4 .lb-foot { grid-area: f; font-size: 8pt; }
.lb-a4 .lb-name { font-size: 10pt; }
.lb-a4 .lb-spec { font-size: 8pt; }
.lb-a4 .lb-pic { position: absolute; top: 4mm; right: 4mm; width: 14mm; height: 14mm; }
.lb-thermal { width: 50mm; height: 37.5mm; grid-template: "c t" 1fr "f f" auto / 20.5mm 1fr; gap: 0 1mm; padding: 2mm 2.5mm 2mm 1.5mm; }
.lb-thermal .lb-code-box { grid-area: c; width: 20.5mm; height: 20.5mm; }
.lb-thermal .lb-text { grid-area: t; padding-top: 14.5mm; min-width: 0; }
.lb-thermal .lb-foot { grid-area: f; font-size: 8pt; font-weight: 700; }
.lb-thermal .lb-name { font-size: 9pt; }
.lb-thermal .lb-spec { font-size: 7.5pt; -webkit-line-clamp: 3; }
.lb-thermal .lb-pic { position: absolute; top: 2mm; left: 23mm; width: 14mm; height: 14mm; filter: grayscale(1) contrast(1.25); }
/* 打包扫袋（7w） */
.tone-ok { color: var(--success); }
.check-row { display: flex; align-items: center; gap: 10px; min-height: 44px; }
.pack { display: flex; flex-direction: column; gap: 14px; max-width: 720px; }
.pack-scan { display: flex; gap: 10px; }
.pack-scan .input { flex: 1; min-height: 52px; font-size: var(--fs-title-s); }
.pack-last .btn { flex: none; white-space: nowrap; }
.pack-last { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; padding: 14px 16px; border-radius: var(--radius-l); background: var(--glass-strong); border: 1px solid var(--line); }
.pack-last.is-ok { background: var(--sage-soft); }
.pack-last.is-full { background: var(--success); color: var(--paper); }
.pack-last.is-todo { background: var(--accent-soft); }
.pack-last.is-bad { background: var(--danger); color: var(--paper); }
.pack-last-pic { width: 84px; height: 84px; flex: none; object-fit: cover; border-radius: var(--radius-m); background: var(--paper); }
.pack-last-t { flex: 1 1 150px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pack-last-big { font-size: var(--fs-title-s); font-weight: 700; }
.pack-list { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-m); overflow: hidden; background: var(--glass); }
.pack-row { display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 8px 12px; border-top: 1px solid var(--line); }
.pack-row:first-child { border-top: 0; }
.pack-row.is-ok { background: var(--sage-soft); }
.pack-row-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pack-ship { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: var(--radius-l); border: 1px solid var(--line); background: var(--glass-strong); }
.pack-ship .input { min-height: 52px; font-size: var(--fs-title-s); }
.cam { min-height: 120px; display: flex; flex-direction: column; gap: 10px; }
.cam-video { width: 100%; max-height: 60vh; border-radius: var(--radius-m); background: var(--ink); object-fit: cover; }
.cam-say { min-height: 24px; font-size: var(--fs-title-s); font-weight: 600; }

/* ---- 窄一点的电脑（1280 以下）：收紧间距，表格不换成卡 ---- */
@media (max-width: 1280px) {
  :root { --web-side: 176px; --web-gutter: 20px; --web-quote: 292px; }
  .tbl th, .tbl td { padding-left: 8px; padding-right: 8px; }
  .cell-ref { display: block; margin: 2px 0 0 18px; }
  .col-need { max-width: 200px; }
}

/* ---- 手机（390 宽也能用）：导航横着放在上面，表格一行一张卡，热区 44px，报价面板收成底部一行 ---- */
@media (max-width: 760px) {
  :root { --web-gutter: 16px; --web-hit: 44px; }
  .app { display: block; }
  .side { position: static; height: auto; padding: 6px 8px; border-right: 0; border-bottom: 1px solid var(--line); }
  .side.is-one { display: none; }
  .join-steps { flex-wrap: nowrap; gap: 4px; }
  .join-step { padding: 0 10px 0 4px; }
  .join-step-in { gap: 5px; }
  /* 手机上六个页签要放得下：「造每」两个字不占地方，一格一份，角标压在右上 */
  .brand, .nav-label { display: none; }
  .nav { flex: none; }
  .nav-group { flex-direction: row; gap: 2px; }
  .nav-item, .nav-item.is-soon { position: relative; flex: 1 1 0; min-width: 0; min-height: 44px; padding: 0 2px; justify-content: center; }
  .nav-badge { position: absolute; top: 1px; right: 0; min-width: 18px; height: 18px; padding: 0 4px; line-height: 18px; }
  .top { padding: 8px 16px; gap: 10px; }
  .top-shop { flex: 0 0 auto; max-width: 64%; gap: 8px; }
  .top-name { max-width: none; }
  .todo-hint { max-width: none; flex: 1 0 100%; text-align: left; padding-left: 18px; }
  .view { padding: 16px 16px 0; }
  .page-title { font-size: var(--fs-title-m); }
  .page-head { flex-direction: column; align-items: stretch; }
  /* 整页唯一的主按钮：固定在底部整宽，热区 52px */
  .head-action { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--sheet-panel); border-top: 1px solid var(--line); }
  .head-action .main-act { flex: 1; min-height: 52px; min-width: 0; white-space: normal; }
  .head-action .main-sub { flex: none; min-height: 52px; max-width: 42%; white-space: normal; }
  .page { padding-bottom: 96px; }
  .bar { bottom: 84px; }
  .btn { min-height: 44px; }
  .strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip-item:nth-child(3) { border-left: 0; }
  .strip-item:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .todo-row { flex-wrap: wrap; }
  .seg { display: flex; width: 100%; }
  .seg-item { flex: 1; justify-content: center; padding: 0 6px; }
  .search-box { width: 100%; }
  .search { flex: 1; width: auto; }
  .bar { bottom: 8px; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 8px; padding: 10px 12px; }
  .bar-acts { flex-wrap: nowrap; overflow-x: auto; min-width: 0; }
  .bar-acts .btn { flex: none; }
  .bar-acts .btn-primary { flex: 1 0 auto; }
  .tbl-wrap { background: transparent; box-shadow: none; overflow: visible; }
  .tbl thead { display: none; }
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; }
  .tbl tr { position: relative; margin-bottom: 10px; padding: 10px 12px 10px 48px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
  .tbl td { height: auto; padding: 2px 0; border: 0; white-space: normal; }
  .tbl td[data-label]::before { content: attr(data-label) " "; color: var(--ink-muted); font-size: var(--fs-note); }
  .tbl td.col-check { position: absolute; left: 0; top: 0; bottom: 0; width: 48px; display: flex; align-items: center; justify-content: center; }
  .tbl td.col-check .check { width: 22px; height: 22px; }
  .tbl th.col-num, .tbl td.col-num { text-align: left; }
  .tbl .is-picked { background: var(--sage-soft); }
  .tbl tr.sect { margin: 14px 0 6px; padding: 0; background: transparent; box-shadow: none; }
  .tbl tr.sect th { display: block; padding: 0; border: 0; background: transparent; }
  .col-due .cell-sub, .cell-main, .cell-sub { display: inline; }
  .tbl-tight tr { padding-left: 12px; }
  /* 品类总表：每类一张卡——名字 · 能做几项 · 状态 / 供货价 · 周期 / 运费 · 核对；有事要做才多一行。价格、周期仍可直接填 */
  .tbl-cats tr { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 10px; align-items: center; }
  /* 每个框都有标题：供货价、几天发货、运费、你们的编号一行一格；名字、能做几种、状态在顶上一行 */
  .tbl-cats td[data-label]::before { display: block; content: attr(data-label); }
  .tbl-cats .col-cat[data-label]::before, .tbl-cats .col-num[data-label]::before, .tbl-cats .col-status[data-label]::before { content: none; }
  .tbl-cats .col-cat { grid-column: 1; grid-row: 1; font-weight: 500; }
  .tbl-cats .col-num { grid-column: 2; grid-row: 1; color: var(--ink-muted); font-size: var(--fs-note); }
  .tbl-cats .col-status { grid-column: 3; grid-row: 1; justify-self: end; }
  .tbl-cats .col-price { grid-column: 1 / -1; grid-row: 2; }
  .tbl-cats .col-days { grid-column: 1 / 3; grid-row: 3; }
  .tbl-cats .col-shipfee { grid-column: 3; grid-row: 3; }
  .tbl-cats .col-code { grid-column: 1 / 3; grid-row: 4; }
  .tbl-cats .col-go { grid-column: 3; grid-row: 4; justify-self: end; align-self: end; }
  .tbl-cats .col-code .cell-in-code { width: 160px; }
  .tbl-cats .col-need { grid-column: 1 / -1; grid-row: 5; max-width: none; }
  .modes { grid-template-columns: minmax(0, 1fr); }
  .fmt { flex-direction: column; align-items: stretch; padding: 4px; }
  .fmt-acts { padding: 0 12px 10px 36px; }
  .fmt-row { grid-template-columns: minmax(0, 1fr) 32px; }
  .fmt-row .fmt-what { grid-column: 1 / -1; grid-row: 2; }
  .fmt-head span:nth-child(2) { display: none; }
  .tbl-cats .col-need.is-none { display: none; }
  .tbl-cats .cell-in { min-height: 44px; }
  .cell-ref { display: inline; margin: 0 0 0 8px; }
  .tbl-same tr { padding-left: 12px; }
  .col-same { width: auto; }
  .ck-layout { grid-template-columns: minmax(0, 1fr); }
  .ck-main-col { padding: 0 14px 16px; }
  .ck-sum { margin: 0 -14px; padding: 10px 14px; }
  .grp { grid-template-columns: minmax(0, 1fr) auto; }
  .grp-head { flex-direction: row; align-items: baseline; gap: 8px; }
  .grp-vals, .add-row, .grp-extra > .note { grid-column: 1 / -1; }
  .grp-acts { grid-column: 2; grid-row: 1; padding-top: 0; }
  .val, .q-opt { min-height: 40px; }
  .quote { position: static; order: -1; width: auto; max-height: none; }
  .layer-panel { width: calc(100vw - 16px); max-height: calc(100vh - 16px); }
  .layer-drawer, .layer-drawer.layer-wide { width: 100vw; max-height: none; border-radius: 0; }
  .layer-drawer .layer-foot .btn-primary { flex: 1; min-height: 52px; }
  .ship-top .field { width: 100%; }
  .join-form { padding: 16px; }
  .kv-k { width: 38%; }
  .login-card { padding: 28px 20px; }
  .login-digit { width: 40px; height: 52px; }
  .toasts { bottom: 96px; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* 订单详情顶上的图案：生产文件那张图，透明的地方看得出来 */
.pics { display: flex; flex-wrap: wrap; gap: 12px; }
.pic { margin: 0; display: flex; flex-direction: column; gap: 4px; }
.pic img { width: 168px; height: 168px; object-fit: contain; border-radius: var(--radius-m); background: var(--stage); }
.pic figcaption { font-size: var(--fs-note); color: var(--ink-muted); }

/* 整页唯一的主按钮（SUPPLY_WEB 7h）：电脑固定在右上（页头跟着滚的时候留在顶上），颜色全站只给它用 */
.head-action .btn-primary.main-act { min-height: 48px; padding: 0 26px; font-size: var(--fs-title-s); }
.head-action .main-sub { min-height: 48px; }
@media (min-width: 761px) { .no-top .page-head { top: 0 !important; } .page-head { position: sticky; top: var(--web-top); z-index: 3; padding: 10px 0; background: var(--paper); } }
.todo-go { flex: none; max-width: 46%; color: var(--ink-muted); text-align: right; }
button.todo-row { width: 100%; border: 0; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
button.todo-row + button.todo-row { border-top: 1px solid var(--line); }
.waits { display: flex; flex-direction: column; gap: 6px; }
.bill-sum { font-variant-numeric: tabular-nums; }
.bill-line { padding: 6px 0; border-top: 1px solid var(--line); }
.bill-q { padding: 8px 0; }
.card { padding: 16px 18px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.after { display: flex; flex-direction: column; gap: 10px; }
.after-text { font-size: var(--fs-title-s); overflow-wrap: anywhere; }
/* 10 秒内可撤回 */
.hold { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 8; display: flex; align-items: center; gap: 14px; max-width: calc(100vw - 32px); padding: 10px 14px 10px 20px; border-radius: var(--radius-l); background: var(--sheet-panel); border: 1px solid var(--glass-edge); box-shadow: var(--glass-float); }
.hold-text { font-weight: 500; font-variant-numeric: tabular-nums; }
.hold-acts { display: flex; gap: 8px; }
.row.is-ok td { background: var(--sage-soft); }
/* 入驻：点图选 */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 12px; }
.tile { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 12px; border: 2px solid transparent; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); color: var(--ink); font: inherit; cursor: pointer; }
.tile.is-on { border-color: var(--sage); background: var(--sage-soft); }
.tile { position: relative; }
.tile-ok { position: absolute; top: 8px; right: 8px; width: 26px; height: 26px; border-radius: 50%; background: var(--sage); color: var(--on-primary); font-weight: 700; line-height: 26px; text-align: center; }
.tiles-more { align-self: flex-start; min-height: 44px; }
.tile-pics { display: flex; justify-content: center; gap: 4px; height: 96px; }
.tile-pics img { width: 96px; max-width: 50%; height: 96px; object-fit: contain; }
img.is-wait { background: var(--stage); border-radius: var(--radius-m); }
.tile-pics img:only-child { max-width: 100%; }
.tile-t { font-size: var(--fs-title-s); font-weight: 500; }
.tile-sub { font-size: var(--fs-note); color: var(--ink-muted); text-align: center; }
.prices { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 12px; }
.price-card { display: flex; flex-direction: column; gap: 10px; }
.price-head { display: flex; align-items: center; gap: 12px; }
.price-cell { display: flex; flex-direction: column; gap: 4px; }
.price-pic { flex: none; width: 64px; height: 64px; object-fit: contain; }
.price-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.affix { display: flex; align-items: center; gap: 6px; }
.affix-t { flex: none; color: var(--ink-muted); }
.affix .input { flex: 0 1 auto; }
.price-qs:empty { display: none; }
.price-kids { max-width: 760px; display: flex; flex-direction: column; gap: 8px; }
.price-name { font-size: var(--fs-title-s); font-weight: 500; }
.scope { display: flex; flex-direction: column; gap: 8px; padding: 4px 2px; }
.scope-row { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; }
@media (max-width: 760px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .prices { grid-template-columns: minmax(0, 1fr); } }
/* 1366 宽：总表九列放得下（参考价换到下一行、内边距收一点），再窄就横着滚，「看规格」不被切掉 */
@media (min-width: 761px) and (max-width: 1440px) {
  .tbl-cats th, .tbl-cats td { padding-left: 7px; padding-right: 7px; }
  .tbl-cats .cell-ref { display: block; margin: 2px 0 0 18px; }
  .tbl-cats .cell-in { width: 74px; }
  .tbl-cats .cell-in-s { width: 46px; }
  .tbl-cats select.cell-in { width: 80px; }
  .tbl-cats .cell-in-code { width: 88px; }
  .tbl-cats .col-need { max-width: 190px; }
  .cats-host .tbl-wrap { overflow-x: auto; }
}
.what-sub { font-size: var(--fs-note); color: var(--ink-muted); }
/* 订单：图和颜色尺码一眼看到；正在发的变灰 */
.what { display: flex; flex-direction: column; gap: 8px; }
.what-one { display: flex; align-items: center; gap: 12px; min-width: 0; }
.what-pic { flex: none; width: 56px; height: 56px; object-fit: contain; border-radius: var(--radius-m); }
.what-pic.is-real { object-fit: cover; background: var(--stage); }
.what-t { display: flex; flex-direction: column; min-width: 0; }
.what-big { font-size: var(--fs-title-s); font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; white-space: normal; }
.row.is-going { opacity: 0.5; }
@media (max-width: 760px) {
  .tbl-orders td.col-num, .tbl-orders td.col-no, .tbl-orders td.col-to, .tbl-orders td.col-file, .tbl-orders td.col-ship { display: none; }
  .tbl-orders td.col-due { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
  .tbl-orders td.col-due[data-label]::before { content: none; }
  .tbl-orders .what-pic { width: 96px; height: 96px; }
  .tbl-orders .what-big { font-size: var(--fs-title-m); }
}
/* 交样品：一屏一句话、照片格、一个主按钮 */
.shots { display: flex; flex-wrap: wrap; gap: 12px; }
.shot { position: relative; width: 148px; height: 148px; padding: 0; border: 0; border-radius: var(--radius-l); overflow: hidden; background: var(--stage); }
.shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot .x { position: absolute; top: 4px; right: 4px; width: 44px; height: 44px; background: var(--glass-strong); }
.shot-add, .thumb-add { border: 2px dashed var(--line-strong); background: transparent; color: var(--ink-muted); font-size: 32px; cursor: pointer; }
@media (max-width: 760px) { .shots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); } .shot { width: auto; height: auto; aspect-ratio: 1; } }
/* 今天：那一句话是主角 */
.head-line.tone-bad { color: var(--danger); }
.page-sample .head-main, .page-today .head-main { flex-direction: column; gap: 2px; }
.page-sample .page-title, .page-today .page-title { font-size: var(--fs-body); font-family: inherit; font-weight: 400; color: var(--ink-muted); }
.page-sample .head-line, .page-today .head-line { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-title-l); line-height: 1.35; color: var(--ink); }
.page-today .head-line.tone-bad { color: var(--danger); }
.page-today .head-line.tone-todo { color: var(--accent-ink); }
@media (max-width: 760px) { .hold { bottom: 92px; width: calc(100vw - 32px); justify-content: space-between; } }
.val.is-only { padding: 0 2px; background: transparent; color: var(--ink-muted); cursor: default; }
/* 小程序里（7k）：扫一下和单号框并排；看大图 */
.scan-row { display: flex; gap: 8px; align-items: center; }
.scan-row .input { flex: 1 1 auto; min-width: 0; }
.big-pic { display: block; max-width: 100%; margin: 0 auto; }
.members .kv-k { display: flex; gap: 8px; align-items: center; }
/* 地址改过：发货前再核一次（7l） */
.addr-ok { display: flex; gap: 8px; align-items: center; margin-top: 4px; font-size: var(--fs-note); color: var(--accent-ink); }
.bank-pick { display: flex; flex-direction: column; gap: 8px; }
.price-cell .field .link-btn { align-self: flex-start; padding-left: 0; padding-right: 0; text-align: left; }
.price-fold { display: flex; flex-direction: column; gap: 12px; padding-top: 4px; }
.price-fold[hidden] { display: none; }
.scrim .login-qr { display: block; margin: 0 auto; }
.tier-cells { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px 16px; align-items: end; }
.tier-cells[hidden] { display: none; }
.tier-cell, .tier-diff { display: flex; flex-direction: column; gap: 4px; }
.tier-diff { grid-column: 1 / -1; }
.tier-diff .q-opts { align-items: center; }
.tier-diff .tier-in { width: 84px; }
.tier-fold { grid-column: 1 / -1; }
.tile.is-off { opacity: .55; }

/* 商品页三层（7u）：货 / 价 / 做法 */
.ck-tabs { margin: 0; align-self: flex-start; }
.ck-tabs .seg-item { min-width: 92px; justify-content: center; }
.tab-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.ck-layout.is-tabs { grid-template-columns: minmax(0, 1fr); }
.ck-layout.is-tabs > [hidden] { display: none; }
.ck-layout.is-tabs .quote { position: static; width: auto; max-width: 640px; max-height: none; }
.ck-layout.is-tabs .ck-main-col { padding-top: 16px; }
.ck-body { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.ck-body[hidden], .ck-fold[hidden] { display: none; }
.ck-gauge { display: flex; flex-direction: column; gap: 6px; }
.ck-gauge:empty { display: none; }
.tab-dot[hidden], .ck-tabs [hidden] { display: none; }
.goods-box { min-width: 0; }
.goods { display: flex; flex-direction: column; gap: 14px; max-width: 760px; padding: 16px 18px 20px; border-radius: var(--radius-l); background: var(--card); box-shadow: var(--glass-float-s); }
.g-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.g-top .cell-sub { min-width: 0; }
.g-tbl { width: 100%; border-collapse: separate; border-spacing: 5px; table-layout: fixed; }
.g-corner { width: 68px; }
.g-head { display: block; width: 100%; min-height: 34px; padding: 4px 2px; border: 0; background: none; font: inherit; font-size: var(--fs-note); color: var(--ink-muted); text-align: center; }
button.g-head { cursor: pointer; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.g-tbl tbody .g-head { text-align: left; color: var(--ink); }
.g-cell { width: 100%; min-height: 40px; padding: 0 4px; border: 1.5px solid transparent; border-radius: var(--radius-s); font: inherit; font-size: var(--fs-note); cursor: pointer; background: var(--sage-soft); color: var(--ink-muted); }
.g-cell.is-out, .g-cell.is-mix { background: var(--accent-soft); color: var(--accent-ink); font-weight: 500; }
.g-cell.is-out { padding: 0; white-space: nowrap; }
.g-after { scroll-margin-bottom: 24px; }
.g-cell.is-no { background: transparent; color: var(--ink-muted); }
.g-cell.is-pick { border-color: var(--ink); color: var(--ink); font-weight: 500; }
.g-list { display: flex; flex-direction: column; gap: 6px; }
.g-row { display: grid; grid-template-columns: minmax(0, 1fr) 132px; align-items: center; gap: 12px; min-height: 44px; }
.g-when, .g-after, .g-in { display: flex; flex-direction: column; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.g-q { font-size: var(--fs-body); font-weight: 500; }
.g-date { max-width: 200px; }
.g-date[hidden] { display: none; }
.g-hands { display: flex; flex-direction: column; gap: 4px; padding: 0; list-style: none; font-size: var(--fs-note); }
.g-code { min-height: 38px; padding: 0 6px; font-size: var(--fs-note); text-align: center; }
.g-code.is-new { border-color: var(--sage); background: var(--sage-soft); }
.g-paste { min-height: 84px; padding: 10px 12px; resize: vertical; }
.goods .quote-codes { padding-top: 12px; }
@media (min-width: 900px) {
  .goods { display: grid; grid-template-columns: minmax(0, 1fr) 300px; column-gap: 24px; align-items: start; max-width: 1040px; }
  .goods > .g-top, .goods > .q-opts, .goods > .g-in, .goods > .note, .goods > .quote-codes { grid-column: 1; }
  .goods > .g-tbl, .goods > .g-list { grid-column: 1; }
  .goods > .g-when, .goods > .g-after { grid-column: 2; grid-row: 1 / span 4; position: sticky; top: calc(var(--web-top) + 12px); padding: 0 0 0 24px; border-top: 0; border-left: 1px solid var(--line); }
  .g-cell { min-height: 34px; }
  .g-head { min-height: 28px; }
}
@media (max-width: 760px) {
  .ck-tabs { align-self: stretch; }
  .ck-tabs .seg-item { min-width: 0; }
  .goods { padding: 14px 12px 18px; }
  .g-tbl { border-spacing: 3px; }
  .g-corner { width: 52px; }
  .g-cell { min-height: 36px; scroll-margin: 76px 0 270px; }
  .g-head { min-height: 30px; }
  .g-when { position: sticky; bottom: 84px; z-index: 2; margin: 0 -12px; padding: 12px 12px 10px; background: var(--card); box-shadow: var(--glass-float); border-radius: var(--radius-m) var(--radius-m) 0 0; }
}

.ask-words { display: flex; flex-direction: column; gap: 16px; }
.ask-word { display: flex; flex-direction: column; gap: 8px; }
/* 在取生产文件：一条进度 */
.get-bar { display: block; width: 100%; height: 8px; accent-color: var(--ink); }
