/* gc-production-qc.css - extracted production/QC styles from index.html */
/* production-qc-main-css-split-v1: production/QC ledger CSS; no visual change intended. */
/* prodqc-taizhang-v1: 生产·QC 收货+QC台账(灰度 gc_prodqc_v2='on') */
.pq2-top{ display:flex; gap:9px; flex-wrap:wrap; margin:2px 0 16px; }
.pq2-st{ background:#fff; border:1px solid #e9e9ee; border-radius:12px; padding:8px 15px; min-width:96px; cursor:pointer; text-align:left; transition:background .15s,border-color .15s,box-shadow .15s,transform .15s; }
.pq2-st:hover{ background:#fbfdff; border-color:#cfe0ff; transform:translateY(-1px); }
.pq2-st.active{ background:#eef6ff; border-color:var(--apple-blue); box-shadow:0 0 0 3px rgba(0,122,255,.09); }
.pq2-st.all b{ color:#1c1c1e!important; }
.pq2-st b{ font-size:19px; font-weight:700; }
.pq2-st span{ display:block; font-size:11.5px; color:#6b6b70; }
.pq2-st .pq2-st-unit{ display:inline-flex; align-items:center; justify-content:center; margin:0 0 0 7px; padding:1px 7px; border-radius:999px; background:rgba(10,132,255,.10); color:#0a67d1; font-size:9.5px; font-style:normal; font-weight:760; vertical-align:1px; }
.pq2-report-btn{
  margin-left:auto;
  align-self:stretch;
  min-height:54px;
  font-family:inherit;
  font-size:12.5px;
  font-weight:800;
  color:var(--apple-blue);
  background:#fff;
  border:1px solid rgba(0,122,255,.32);
  border-radius:12px;
  padding:8px 14px;
  cursor:pointer;
  box-shadow:0 1px 2px rgba(0,0,0,.04);
}
.pq2-report-btn:hover{ background:rgba(0,122,255,.07); border-color:var(--apple-blue); transform:translateY(-1px); }
.pq2-grp{ margin-bottom:16px; }
.pq2-h{ display:flex; align-items:center; gap:9px; margin-bottom:8px; font-size:14.5px; font-weight:600; color:#1c1c1e; }
.pq2-section{ background:transparent; }
.pq2-section-head{ width:100%; border:0; background:transparent; padding:0; font:inherit; cursor:pointer; text-align:left; }
.pq2-section-body.is-collapsed{ display:none; }
.pq2-chevron{ width:16px; color:#8e8e93; font-size:12px; text-align:center; flex-shrink:0; }
.pq2-section-title{ font-weight:760; }
.pq2-dot{ width:9px; height:9px; border-radius:50%; flex-shrink:0; }
.pq2-cnt{ font-size:12px; font-weight:600; color:#6b6b70; background:#eee; border-radius:20px; padding:1px 9px; }
.pq2-act{ margin-left:auto; font-size:12px; color:#a0a0a8; font-weight:500; }
.pq2-week-group{ margin:0 0 12px 25px; }
.pq2-week-head{ width:100%; min-height:32px; display:flex; align-items:center; gap:8px; border:0; border-bottom:1px solid #ececf1; background:transparent; padding:0 4px 7px 0; color:#1c1c1e; font:inherit; cursor:pointer; text-align:left; }
.pq2-week-title{ font-size:13px; font-weight:760; }
.pq2-week-range{ font-size:11.5px; color:#8e8e93; font-weight:500; }
.pq2-week-head .pq2-cnt{ margin-left:auto; }
.pq2-week-body{ padding-top:8px; }
.pq2-week-body.is-collapsed{ display:none; }
@media (max-width:760px){
  .pq2-week-group{ margin-left:0; }
  .pq2-week-head{ padding-right:0; }
  .pq2-week-range{ font-size:11px; }
}
.pq2-po{ background:#fff; border:1px solid #e9e9ee; border-radius:12px; padding:11px 14px; margin-bottom:8px; display:flex; gap:12px; align-items:center; }
.pq2-po.pq2-flag-red{ border-color:#ffd2cc; background:#fffafa; }
.pq2-po.pq2-flag-rew{ border-color:#e5cdf2; background:#fdfaff; }
.pq2-img{ width:42px; height:42px; border-radius:9px; object-fit:cover; flex-shrink:0; }
.pq2-noimg{ background:#ececed; display:flex; align-items:center; justify-content:center; color:#b0b0b8; font-size:13px; }
.pq2-mid{ flex:1; min-width:0; }
.pq2-id{ font-size:13.5px; font-weight:600; color:#1c1c1e; }
.pq2-pono{ color:#a0a0a8; font-weight:500; font-size:12px; margin-left:7px; }
.pq2-sp{ font-size:10.5px; border-radius:5px; padding:1px 6px; margin-left:7px; background:#ecfdf3; color:#1a7f3c; white-space:nowrap; }
.pq2-meta{ font-size:11.5px; color:#a0a0a8; margin-top:1px; }
.pq2-mode{ display:inline-flex; align-items:center; width:fit-content; font-size:11px; font-weight:760; border-radius:999px; padding:2px 8px; margin-top:6px; border:1px solid transparent; }
.pq2-mode.arrival{ color:var(--apple-blue); background:rgba(0,122,255,.08); border-color:rgba(0,122,255,.18); }
.pq2-mode.qc{ color:#d70015; background:#fff0f0; border-color:#ffd2cc; }
.pq2-mode.done{ color:#1a7f3c; background:#ecfdf3; border-color:#c8efcf; }
.pq2-mode.rework{ color:#7a2fa0; background:rgba(175,82,222,.10); border-color:#e5cdf2; }
.pq2-dual{ margin-top:6px; display:flex; gap:6px; flex-wrap:wrap; }
.pq2-dual-chip{ font-size:11px; line-height:1.25; border-radius:999px; padding:2px 8px; background:#f5f5f7; color:#5f6368; border:1px solid #ececf1; }
.pq2-dual-chip b{ color:#1c1c1e; font-weight:760; }
.pq2-dual-chip.ok{ background:#edf8ef; border-color:#c8efcf; color:#1a7f3c; }
.pq2-dual-chip.warn,.pq2-dual-chip.part{ background:#fff7e8; border-color:#ffd99f; color:#9a5a00; }
.pq2-dual-chip.bad{ background:#fff0f0; border-color:#ffd2cc; color:#c0392b; }
.pq2-focus{ margin-top:7px; display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.pq2-fs{ font-size:13.5px; font-weight:600; }
.pq2-fs.bad{ color:#ff3b30; } .pq2-fs.rew{ color:#af52de; } .pq2-fs.part{ color:#ff9f0a; } .pq2-fs.wait{ color:#a0a0a8; } .pq2-fs.ok{ color:#1a7f3c; }
.pq2-cats{ display:flex; gap:5px; flex-wrap:wrap; }
.pq2-c{ font-size:11px; background:#fff; border:1px solid #ffd2cc; color:#c0392b; border-radius:6px; padding:1px 7px; }
.pq2-shortage,.prod-shortage-chip{ display:inline-flex; align-items:center; width:fit-content; border-radius:999px; padding:1px 7px; background:#fff7e8; border:1px solid #ffd99f; color:#9a5a00; font-weight:780; }
/* prod-qc-drawer-header-wrap-v1: QC 抽屉标题不受全站 section-title 大字号和分隔线影响。 */
.section-title.prod-qc-history-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 18px;
  font-family: var(--font-sans);
  font-size: 13px;
  line-height: 1.45;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
}
.section-title.prod-qc-history-title::after { display: none; }
.prod-qc-history-label {
  flex: 0 0 auto;
  font-weight: 700;
  white-space: nowrap;
}
.prod-qc-history-summary {
  display: flex;
  flex: 1 1 520px;
  align-items: center;
  flex-wrap: wrap;
  min-width: 0;
  gap: 6px 10px;
}
.prod-qc-history-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
}
.prod-qc-history-item + .prod-qc-history-item::before {
  content: '·';
  color: var(--ink-mute);
}
.prod-qc-history-status { color: var(--ok); font-weight: 700; }
.pq2-note{ font-size:11.5px; color:#6b6b70; font-style:italic; width:100%; }
.pq2-recv{ margin-top:6px; display:flex; align-items:center; gap:9px; }
.pq2-bar{ flex:1; max-width:150px; height:4px; background:#ececef; border-radius:4px; overflow:hidden; }
.pq2-bar i{ display:block; height:100%; background:var(--apple-blue); }
.pq2-bar i.full{ background:#34c759; } .pq2-bar i.part{ background:#ff9f0a; }
.pq2-q{ font-size:11px; color:#a0a0a8; white-space:nowrap; }
.pq2-acts{ display:flex; gap:6px; margin-top:8px; }
.pq2-chip{ font-size:11.5px; border-radius:7px; padding:3px 10px; border:1px solid; cursor:pointer; user-select:none; }
.pq2-chip.ship{ border-color:#bfeccd; background:#ecfdf3; color:#1a7f3c; }
.pq2-chip.rew{ border-color:#e5cdf2; background:rgba(175,82,222,.10); color:#7a2fa0; }
.pq2-right{ flex-shrink:0; display:flex; flex-direction:column; align-items:flex-end; gap:7px; min-width:62px; }
.pq2-ex{ text-align:right; line-height:1.15; }
.pq2-ex .n{ font-size:15px; font-weight:700; } .pq2-ex .l{ font-size:10.5px; color:#a0a0a8; }
.pq2-ex.over .n{ color:#ff3b30; } .pq2-ex.soon .n{ color:#ff9f0a; }
.pq2-ex.done .n{ color:#1a7f3c; } .pq2-ex.done .l{ color:#5fa873; }
.pq2-btn{ font-size:11.5px; border:1px solid var(--apple-blue); color:var(--apple-blue); background:rgba(0,122,255,.10); border-radius:8px; padding:4px 9px; white-space:nowrap; cursor:pointer; }
.pq2-arrival-btn{ appearance:none; min-height:34px; padding:0 13px; border-color:var(--apple-blue); background:var(--apple-blue); color:#fff; font-weight:720; box-shadow:none; }
.pq2-arrival-btn:hover{ background:#0071e3; border-color:#0071e3; }
.pq2-arrival-btn:focus-visible{ outline:3px solid rgba(10,132,255,.28); outline-offset:2px; }
.pq2-btn.qc{ border-color:#d70015; color:#d70015; background:#fff0f0; }
.pq2-btn.rework{ border-color:#af52de; color:#7a2fa0; background:rgba(175,82,222,.10); }

.prod-arrival-warning{ display:flex; flex-direction:column; gap:3px; margin:0 0 12px; padding:10px 12px; border:1px solid #f2c66d; border-radius:9px; background:#fff8e8; color:#7a4a00; font-size:12px; line-height:1.45; }
.prod-arrival-warning strong{ color:#9a5600; font-size:12.5px; }

@media (max-width: 767px){
  .pq2-act{ display:none; }
}

/* production-qc-defect-photo-css-split-v1: defect and batch photo CSS moved from index.html; no visual change. */
.defect-photo-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  background: var(--bg-elevated);
  border: 1px dashed var(--line-strong);
  border-radius: 6px;
  font-size: 12px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: background-color 0.1s, border-color 0.1s, color 0.1s, transform 0.1s, opacity 0.1s, box-shadow 0.1s;
}
.defect-photo-add-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.defect-photo-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.defect-photo-item {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.defect-photo-item.uploading {
  border-color: rgba(0,122,255, 0.45);
}
.defect-photo-item.failed {
  border-color: var(--danger);
}
.defect-photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.defect-photo-badge {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 2px 3px;
  background: rgba(0, 0, 0, 0.62);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
}
.defect-photo-remove {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(215, 0, 21, 0.92);
  color: white;
  border: none;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  z-index: 3;
  box-shadow: 0 1px 4px rgba(0,0,0,.22);
}
.prod-batch-photos {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.prod-batch-photos img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: transform 0.1s;
}
.prod-batch-photos img:hover {
  transform: scale(1.05);
}
.prod-batch-photo-wrap {
  position: relative;
  display: inline-flex;
}
.prod-batch-photo-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 26px;
  height: 26px;
  padding: 0;
  border-radius: 7px;
  border: 1px solid var(--line-strong, #D1D1D6);
  background: var(--bg-elevated, #FBFBFD);
  color: var(--danger, #D70015);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2;
  opacity: 0.94;
  box-shadow: var(--shadow-xs, 0 1px 2px rgba(0, 0, 0, 0.06));
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, opacity 0.15s, transform 0.15s;
}
.prod-batch-photo-remove:hover {
  border-color: var(--danger, #D70015);
  background: var(--danger, #D70015);
  color: var(--bg-elevated, #FBFBFD);
  opacity: 1;
}
.prod-batch-photo-remove:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring, 0 0 0 3px rgba(0, 122, 255, 0.4));
}
.prod-batch-photo-remove:active {
  transform: scale(0.96);
}
.prod-batch-photo-remove-icon {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}
@media (pointer: coarse) {
  .defect-photo-remove {
    width: 30px;
    height: 30px;
    font-size: 19px;
  }
  .prod-batch-photo-remove {
    top: 2px;
    right: 2px;
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }
  .prod-batch-photo-remove-icon {
    width: 16px;
    height: 16px;
  }
}
.prod-batch-meta {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-mute);
  letter-spacing: 0.02em;
}

/* production-qc-report-module-split-v1: report CSS; no visual change intended. */
#gcQcReportPreview .gc-rpt-shell {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
}
#gcQcReportPreview .gc-rpt-topbar {
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 18px;
  padding: 22px 18px;
  border-right: 1px solid #d6dbe5;
  border-bottom: 0;
  overflow: auto;
}
#gcQcReportPreview .gc-rpt-topbar-title strong { font-size: 18px; }
#gcQcReportPreview .gc-rpt-topbar-title span { margin-top: 6px; line-height: 1.45; }
#gcQcReportPreview .gc-rpt-controls {
  display: grid;
  gap: 14px;
  align-items: stretch;
  justify-content: stretch;
}
#gcQcReportPreview .gc-rpt-field-list,
#gcQcReportPreview .gc-rpt-quick-grid,
#gcQcReportPreview .gc-rpt-action-grid {
  display: grid;
  gap: 10px;
}
#gcQcReportPreview .gc-rpt-quick-grid,
#gcQcReportPreview .gc-rpt-action-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
#gcQcReportPreview .gc-rpt-field input,
#gcQcReportPreview .gc-rpt-field select {
  width: 100%;
  min-width: 0;
  height: 38px;
}
#gcQcReportPreview .gc-rpt-btn {
  width: 100%;
  height: 38px;
}
#gcQcReportPreview .gc-rpt-stage {
  padding: 28px 28px 46px;
}
.gc-qcrpt-sheet .gc-rpt-title h1 { color:#006eb8; }
.gc-qcrpt-score-row { grid-template-columns: repeat(6, 1fr); }
.gc-qcrpt-score-row .gc-rpt-score { min-height: 82px; padding: 11px 10px; }
.gc-qcrpt-score-row .gc-rpt-score .value { font-size: 25px; }
.gc-qcrpt-score-row .gc-rpt-score.good .value { color:#0f8b5f; }
.gc-qcrpt-score-row .gc-rpt-score.bad .value { color:#b91c1c; }
.gc-qcrpt-table th,
.gc-qcrpt-table td { font-size: 11.5px; }
.gc-qcrpt-table td.client { text-align:left; padding-left:10px; font-weight:900; }
.gc-qcrpt-muted { color:#667085; font-weight:650; }
.gc-qcrpt-empty {
  border:1px solid #d8deea;
  background:#f7f9fd;
  padding:16px;
  text-align:center;
  color:#667085;
  font-size:13px;
}
.gc-qcrpt-two-col { grid-template-columns: 0.95fr 1.05fr; }
.gc-qcrpt-bars { display:grid; gap:8px; }
.gc-qcrpt-bar-row { display:grid; grid-template-columns:72px 1fr 70px; align-items:center; gap:10px; font-size:12px; }
.gc-qcrpt-bar-row b { color:#172033; }
.gc-qcrpt-bar { height:9px; background:#e9edf5; overflow:hidden; }
.gc-qcrpt-bar span { display:block; height:100%; background:#b91c1c; }
.gc-qcrpt-alerts { display:grid; grid-template-columns:repeat(3, 1fr); gap:8px; }
.gc-qcrpt-alert { background:#fff7ed; border:1px solid #fed7aa; padding:9px 10px; }
.gc-qcrpt-alert b { display:block; color:#9a3412; font-size:18px; line-height:1; margin-bottom:4px; }
.gc-qcrpt-alert span { color:#7c2d12; font-size:12px; font-weight:800; }
.gc-qcrpt-appendix-page {
  width: 1120px;
  min-height: 790px;
  margin: 26px auto 0;
  padding: 32px 44px 34px;
  background:#fff;
  box-shadow:0 18px 60px rgba(20,29,43,.18);
  color:#121826;
  font-size:13px;
  line-height:1.45;
  break-before: page;
  page-break-before: always;
}
.gc-qcrpt-appendix-head {
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:20px;
  border-bottom:2px solid #e4e8f2;
  padding-bottom:12px;
  margin-bottom:16px;
}
.gc-qcrpt-appendix-head h2 { margin:0; color:#082f57; font-size:26px; line-height:1.1; }
.gc-qcrpt-appendix-head span { color:#667085; font-weight:800; }
.gc-qcrpt-defect-list { display:grid; gap:14px; }
.gc-qcrpt-defect-card {
  border:1px solid #d8deea;
  background:#fff;
  padding:14px;
  break-inside: avoid;
  page-break-inside: avoid;
}
.gc-qcrpt-defect-head {
  display:flex;
  justify-content:space-between;
  gap:18px;
  align-items:flex-start;
}
.gc-qcrpt-defect-title { font-size:15px; font-weight:900; color:#111827; }
.gc-qcrpt-defect-meta { margin-top:3px; color:#667085; font-size:12px; font-weight:700; }
.gc-qcrpt-defect-num { text-align:right; white-space:nowrap; font-size:12px; color:#667085; }
.gc-qcrpt-defect-num b { display:block; color:#b91c1c; font-size:20px; line-height:1.1; }
.gc-qcrpt-problems { margin-top:10px; color:#172033; font-weight:800; }
.gc-qcrpt-problems span { color:#b91c1c; }
.gc-qcrpt-note { margin-top:6px; color:#4d5b6d; font-size:12px; }
.gc-qcrpt-photo-grid {
  margin-top:11px;
  display:flex;
  flex-wrap:wrap;
  align-items:flex-start;
  justify-content:flex-start;
  gap:14px;
}
.gc-qcrpt-photo {
  min-height:0;
  border:0;
  background:transparent;
  overflow:visible;
  display:flex;
  align-items:flex-start;
  justify-content:flex-start;
  padding:0;
  flex:0 0 auto;
}
.gc-qcrpt-photo img {
  max-height:220px;
  width:auto;
  min-width:0;
  max-width:min(260px, 100%);
  height:auto;
  object-fit:contain;
  display:block;
}
.gc-qcrpt-more {
  display:flex;
  align-items:center;
  justify-content:center;
  height:132px;
  border:1px dashed #c8d0df;
  background:#f7f9fd;
  color:#667085;
  font-weight:800;
}
@media (max-width:1180px) {
  #gcQcReportPreview .gc-rpt-shell { grid-template-columns:1fr; }
  #gcQcReportPreview .gc-rpt-topbar {
    max-height:46vh;
    border-right:0;
    border-bottom:1px solid #d6dbe5;
  }
  .gc-qcrpt-score-row,
  .gc-qcrpt-two-col { grid-template-columns:1fr; }
  .gc-qcrpt-appendix-page { width:100%; }
}
@media print {
  body.gc-qcrpt-printing { margin:0!important; background:#fff!important; }
  body.gc-qcrpt-printing > *:not(#gcQcReportPreview) { display:none!important; }
  body.gc-qcrpt-printing #gcQcReportPreview {
    position:static!important;
    inset:auto!important;
    display:block!important;
    background:#fff!important;
    overflow:visible!important;
    z-index:auto!important;
  }
  body.gc-qcrpt-printing #gcQcReportPreview .gc-rpt-shell { display:block!important; }
  body.gc-qcrpt-printing #gcQcReportPreview .gc-rpt-topbar { display:none!important; }
  body.gc-qcrpt-printing #gcQcReportPreview .gc-rpt-stage {
    display:block!important;
    overflow:visible!important;
    min-height:auto!important;
    padding:0!important;
  }
  body.gc-qcrpt-printing #gcQcReportPreview .gc-rpt-sheet,
  body.gc-qcrpt-printing #gcQcReportPreview .gc-qcrpt-appendix-page {
    width:auto!important;
    min-height:auto!important;
    margin:0!important;
    padding:16mm 14mm 12mm!important;
    box-shadow:none!important;
  }
}

/* admin-ops-queues-v17 / admin-nine-workbench-final-v19:
   管理员生产 QC 收口为摘要栏 + 分组表头 + 连续列表行；业务桶、统计和动作保持原样。 */
@media (min-width: 901px) {
body.gc-admin-shell-pilot.today-prod-sub-active .pq2-top {
    display: grid;
    grid-template-columns: repeat(6, minmax(96px, 132px)) minmax(12px, 1fr);
    gap: 0;
    align-items: stretch;
    margin: 0 0 16px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st {
    min-width: 0;
    min-height: var(--gc-wb-summary-height, 64px);
    padding: 8px 12px;
    border-color: var(--gc-wb-line, rgba(60, 60, 67, 0.14));
    border-right-width: 0;
    border-radius: 0;
    background: var(--gc-wb-surface, #fff);
    box-shadow: none;
    transform: none;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st:first-child {
    border-radius: 10px 0 0 10px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st:nth-child(6) {
    border-right-width: 1px;
    border-radius: 0 10px 10px 0;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st:hover {
    background: var(--gc-wb-surface-muted, #f9f9fb);
    border-color: rgba(60, 60, 67, 0.20);
    transform: none;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st.active {
    position: relative;
    z-index: 1;
    background: var(--gc-wb-surface-selected, #e5f0ff);
    border-color: rgba(0, 122, 255, 0.45);
    box-shadow: inset 0 -2px var(--apple-blue);
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-st b {
    font-size: 20px;
    line-height: 1.05;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-report-btn {
    grid-column: -2 / -1;
    align-self: center;
    width: auto;
    height: 34px;
    min-height: 34px;
    margin-left: 12px;
    padding: 0 12px;
    border-radius: 9px;
    box-shadow: none;
    transform: none;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-grp {
    margin-bottom: 12px;
    border: 1px solid var(--gc-wb-line, rgba(60, 60, 67, 0.14));
    border-radius: 12px;
    background: var(--gc-wb-surface, #fff);
    overflow: hidden;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-h {
    min-height: var(--gc-wb-group-height, 44px);
    margin: 0;
    padding: 0 14px;
    gap: 8px;
    border-bottom: 1px solid var(--gc-wb-line, rgba(60, 60, 67, 0.14));
    background: var(--gc-wb-surface-muted, #f9f9fb);
    font-size: 13.5px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-section.is-collapsed .pq2-h {
    border-bottom-color: transparent;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-section-body {
    background: var(--gc-wb-surface, #fff);
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-po {
    min-height: 82px;
    margin: 0;
    padding: 10px 14px;
    gap: 10px;
    border: 0;
    border-bottom: 1px solid rgba(60, 60, 67, 0.12);
    border-radius: 0;
    background: #fff;
    box-shadow: none;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-po:last-child {
    border-bottom: 0;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-po.pq2-flag-red {
    background: #fff;
    box-shadow: inset 3px 0 #e5484d;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-po.pq2-flag-rew {
    background: #fff;
    box-shadow: inset 3px 0 #8e4ec6;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-img {
    width: 44px;
    height: 56px;
    border-radius: 8px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active :is(.pq2-mode, .pq2-dual-chip, .pq2-shortage, .prod-shortage-chip) {
    border-radius: 6px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-btn {
    min-height: 30px;
    padding: 0 10px;
    border-radius: 8px;
    box-shadow: none;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-arrival-btn {
    min-height: 36px;
    padding: 0 14px;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-week-group {
    margin: 0;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-week-head {
    min-height: 38px;
    padding: 0 14px;
    border-bottom-color: rgba(60, 60, 67, 0.12);
    background: #fbfbfc;
  }

  body.gc-admin-shell-pilot.today-prod-sub-active .pq2-week-body {
    padding-top: 0;
  }
}

/* production-qc-search-layout-v3: DESIGN.md 36px 控件、8px 间距、单层输入框。 */
.pq2-toolbar {
  --pq2-toolbar-control-height: calc(var(--gc-control-md, 40px) - var(--gc-space-1, 4px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--gc-space-3, 12px);
  width: 100%;
  margin: 0;
}

body.today-prod-sub-active .today-scroll-region {
  gap: var(--gc-space-4, 16px);
}

body.today-prod-sub-active :is(.pq2-top, .pq2-grp) {
  margin-bottom: 0;
}

.prod-qc-searchbar {
  display: flex !important;
  box-sizing: border-box;
  align-items: center;
  flex: 0 0 auto;
  gap: var(--gc-space-2, 8px);
  width: min(520px, 100%) !important;
  height: var(--pq2-toolbar-control-height);
  min-height: var(--pq2-toolbar-control-height);
  margin: 0 !important;
  padding: 0;
  border: 0;
  background: transparent;
}

.prod-qc-search-field {
  display: flex;
  box-sizing: border-box;
  align-items: center;
  flex: 1 1 auto;
  gap: var(--gc-space-2, 8px);
  min-width: 0;
  height: var(--pq2-toolbar-control-height);
  padding: 0 var(--gc-space-3, 12px);
  border: 1px solid var(--line, #E5E5EA);
  border-radius: var(--gc-radius-md, 8px);
  background: var(--bg-elevated, #FFFFFF);
  box-shadow: none;
  transition: border-color var(--gc-transition-fast, 150ms ease-in-out), box-shadow var(--gc-transition-fast, 150ms ease-in-out);
}

.prod-qc-search-field:hover {
  border-color: var(--line-strong, #D1D1D6);
}

.prod-qc-search-field:focus-within {
  border-color: var(--apple-blue);
  box-shadow: var(--focus-ring, 0 0 0 2px rgba(0, 122, 255, 0.18));
}

.prod-qc-search-icon {
  flex: 0 0 16px;
  color: var(--ink-mute);
}

html body .app-shell main#main .prod-qc-search-input {
  min-width: 0;
  height: calc(var(--pq2-toolbar-control-height) - 2px) !important;
  min-height: 0 !important;
  flex: 1 1 auto;
  padding: 0 !important;
  border: 0 !important;
  outline: 0 !important;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--gc-type-body, 13px);
  line-height: calc(var(--pq2-toolbar-control-height) - 2px);
  box-shadow: none !important;
}

html body .app-shell main#main .prod-qc-search-input:focus,
html body .app-shell main#main .prod-qc-search-input:focus-visible {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

.prod-qc-search-input::placeholder {
  color: var(--ink-mute);
}

.prod-qc-search-input::-webkit-search-cancel-button {
  display: none;
}

.prod-qc-search-field .today-search-result-info {
  flex: 0 0 auto;
  color: var(--ink-mute);
  font-size: var(--gc-type-label, 12px);
  white-space: nowrap;
}

.prod-qc-search-field .today-search-clear {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: var(--gc-radius-sm, 6px);
  background: transparent;
  color: var(--ink-mute);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.prod-qc-search-field .today-search-clear:hover {
  background: var(--bg-hover, #F9F9FB);
  color: var(--ink, #1D1D1F);
}

.prod-qc-search-submit {
  flex: 0 0 auto;
  min-width: 64px;
  height: var(--pq2-toolbar-control-height);
  min-height: var(--pq2-toolbar-control-height);
  padding: 0 var(--gc-space-4, 16px);
  border: 0;
  border-radius: var(--gc-button-radius, 8px);
  background: var(--apple-blue);
  color: #fff;
  font-family: var(--font-sans);
  font-size: var(--gc-type-body, 13px);
  font-weight: 650;
  cursor: pointer;
  box-shadow: none;
  transition: background-color var(--gc-transition-fast, 150ms ease-in-out), box-shadow var(--gc-transition-fast, 150ms ease-in-out);
}

.prod-qc-search-submit:hover {
  background: var(--apple-blue-hover, #0051D5);
}

.prod-qc-search-submit:focus-visible {
  outline: 2px solid rgba(0, 122, 255, 0.32);
  outline-offset: 2px;
}

html body.gc-admin-shell-pilot.today-prod-sub-active .pq2-toolbar .pq2-report-btn {
  grid-column: auto;
  align-self: center;
  width: auto;
  height: var(--pq2-toolbar-control-height);
  min-height: var(--pq2-toolbar-control-height);
  margin: 0 0 0 auto;
  padding: 0 var(--gc-space-3, 12px);
  border-radius: var(--gc-button-radius, 8px);
  font-size: var(--gc-type-label, 12px);
  font-weight: 650;
  box-shadow: none;
  transform: none;
}

@media (max-width: 767px) {
  .pq2-toolbar {
    --pq2-toolbar-control-height: var(--gc-control-lg, 44px);
    flex-wrap: wrap;
    margin-bottom: var(--gc-space-3, 12px);
  }

  .prod-qc-searchbar {
    width: 100% !important;
  }

  .prod-qc-search-submit {
    min-width: 60px;
    padding: 0 var(--gc-space-3, 12px);
  }

  html body.gc-admin-shell-pilot.today-prod-sub-active .pq2-toolbar .pq2-report-btn {
    margin-left: auto;
  }
}

#gcProdArrivalReportPreview .gc-rpt-shell {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
}
#gcProdArrivalReportPreview .gc-rpt-topbar {
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 18px;
  padding: 22px 18px;
  border-right: 1px solid #d6dbe5;
  border-bottom: 0;
  overflow: auto;
}
#gcProdArrivalReportPreview .gc-rpt-topbar-title strong { font-size: 18px; }
#gcProdArrivalReportPreview .gc-rpt-topbar-title span { margin-top: 6px; line-height: 1.45; }
#gcProdArrivalReportPreview .gc-rpt-controls,
#gcProdArrivalReportPreview .gc-rpt-field-list,
#gcProdArrivalReportPreview .gc-rpt-quick-grid,
#gcProdArrivalReportPreview .gc-rpt-action-grid {
  display: grid;
  gap: 10px;
  align-items: stretch;
  justify-content: stretch;
}
#gcProdArrivalReportPreview .gc-rpt-quick-grid,
#gcProdArrivalReportPreview .gc-rpt-action-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
#gcProdArrivalReportPreview .gc-rpt-field input,
#gcProdArrivalReportPreview .gc-rpt-field select {
  width: 100%;
  min-width: 0;
  height: 38px;
}
#gcProdArrivalReportPreview .gc-rpt-btn { width: 100%; height: 38px; }
#gcProdArrivalReportPreview .gc-rpt-stage { padding: 28px 28px 46px; }
.gc-prod-rpt-sheet .gc-rpt-title h1 { color:#0f5f8c; }
.gc-prod-rpt-score-row { grid-template-columns: repeat(5, 1fr); }
.gc-prod-rpt-score-row .gc-rpt-score .value { font-size: 27px; }
.gc-prod-rpt-score-row .gc-rpt-score.good .value { color:#0f8b5f; }
.gc-prod-rpt-score-row .gc-rpt-score.warn .value { color:#b25400; }
.gc-prod-rpt-table th,
.gc-prod-rpt-table td { font-size: 11.5px; }
.gc-prod-rpt-table td.left { text-align:left; padding-left:10px; }
.gc-prod-rpt-chip {
  display:inline-flex;
  align-items:center;
  min-height:18px;
  padding:1px 7px;
  border-radius:999px;
  font-weight:900;
  font-size:11px;
  background:#e8f2ff;
  color:#075ca8;
}
.gc-prod-rpt-chip.repeat { background:#f1e8ff; color:#6d28d9; }
.gc-prod-rpt-detail { margin-top:10px; }
.gc-prod-rpt-detail th,
.gc-prod-rpt-detail td { font-size:11px; }
.gc-prod-rpt-muted { color:#667085; font-weight:650; }
.gc-prod-rpt-empty {
  border:1px solid #d8deea;
  background:#f7f9fd;
  padding:16px;
  text-align:center;
  color:#667085;
  font-size:13px;
}
@media (max-width:1180px) {
  #gcProdArrivalReportPreview .gc-rpt-shell { grid-template-columns:1fr; }
  #gcProdArrivalReportPreview .gc-rpt-topbar {
    max-height:46vh;
    border-right:0;
    border-bottom:1px solid #d6dbe5;
  }
  .gc-prod-rpt-score-row { grid-template-columns:1fr; }
}
@media print {
  body.gc-prod-rpt-printing { margin:0!important; background:#fff!important; }
  body.gc-prod-rpt-printing > *:not(#gcProdArrivalReportPreview) { display:none!important; }
  body.gc-prod-rpt-printing #gcProdArrivalReportPreview {
    position:static!important;
    inset:auto!important;
    display:block!important;
    background:#fff!important;
    overflow:visible!important;
    z-index:auto!important;
  }
  body.gc-prod-rpt-printing #gcProdArrivalReportPreview .gc-rpt-shell { display:block!important; }
  body.gc-prod-rpt-printing #gcProdArrivalReportPreview .gc-rpt-topbar { display:none!important; }
  body.gc-prod-rpt-printing #gcProdArrivalReportPreview .gc-rpt-stage {
    display:block!important;
    overflow:visible!important;
    min-height:auto!important;
    padding:0!important;
  }
  body.gc-prod-rpt-printing #gcProdArrivalReportPreview .gc-rpt-sheet {
    width:auto!important;
    min-height:auto!important;
    margin:0!important;
    padding:16mm 14mm 12mm!important;
    box-shadow:none!important;
  }
}
/* drawer-flow-guard-v2-split-v1: drawer flow guard moved from index.html; no visual change. */
.drawer.open .drawer-body {
  position: relative !important;
  display: block !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  contain: none !important;
}
.drawer.open .drawer-body > .detail-top-section,
.drawer.open .drawer-body > .redo-card,
.drawer.open .drawer-body > .style-timeline-section,
.drawer.open .drawer-body > .spec-block,
.drawer.open .drawer-body > .wash-label-section,
.drawer.open .drawer-body > .size-sheet-section,
.drawer.open .drawer-body > .add-po-cta,
.drawer.open .drawer-body > .po-card,
.drawer.open .drawer-body > .qf-section,
.drawer.open .drawer-body > .deleted-po-card,
.drawer.open .drawer-body > .notes-section,
.drawer.open .drawer-body > .style-gallery-collapsible,
.drawer.open .drawer-body > .prod-receive-history {
  position: static !important;
  inset: auto !important;
  top: auto !important;
  right: auto !important;
  bottom: auto !important;
  left: auto !important;
  transform: none !important;
  translate: none !important;
  z-index: auto !important;
  float: none !important;
  clear: both !important;
  display: block !important;
  width: auto !important;
  max-width: 100% !important;
}

/* admin-layout-integrity-v20: QC 分组保持完整高度；只有外组有圆角，表头与连续行不再叠加圆弧。 */
@media (min-width: 901px) {
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-grp {
    flex: 0 0 auto;
    min-width: 0;
    border-radius: var(--gc-wb-group-radius, 10px);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-h {
    border-radius: 0;
  }
}

/* admin-ledger-language-v21:
   QC 跟船务台账使用同一层级：外组唯一圆角，组头和连续 PO 行均为平直分隔。 */
@media (min-width: 901px) {
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-grp {
    overflow: hidden;
    border: 1px solid var(--gc-wb-line, rgba(60, 60, 67, 0.14));
    border-radius: var(--gc-wb-group-radius, 10px);
    background: var(--gc-wb-surface, #fff);
    box-shadow: none;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-h {
    box-sizing: border-box;
    min-height: var(--gc-wb-group-height, 44px);
    margin: 0;
    padding: 0 14px;
    border: 0;
    border-left: 0;
    border-bottom: 1px solid var(--gc-wb-line, rgba(60, 60, 67, 0.14));
    border-radius: 0;
    background: var(--gc-wb-surface-muted, #f9f9fb);
    box-shadow: none;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-section.is-collapsed .pq2-h {
    border-bottom-color: transparent;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-cnt {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border: 0;
    border-radius: 6px;
    color: var(--gc-wb-text-secondary, #424248);
    background: #ededf0;
    box-shadow: none;
    font-size: 11px;
    font-weight: 650;
    line-height: 1;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-week-head {
    border-radius: 0;
    box-shadow: none;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-flag-red,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-flag-rew {
    margin: 0;
    border-left: 0;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
  }

html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po:hover {
    background: #fbfdff;
  }
}

/* qc-workbench-factory-language-v1: QC 接手工厂到货后的待检工作区，沿用工厂的层级、密度和状态色。 */
@media (min-width: 901px) {
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-st:nth-last-child(2),
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-st:last-child {
    border-right-width: 1px;
    border-radius: 0 10px 10px 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-st span {
    color: var(--gc-wb-text-secondary, #5f6368);
    font-size: var(--gc-type-label, 12px);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-section-title {
    color: var(--gc-wb-text-primary, #1d1d1f);
    font-size: var(--gc-type-ui, 13px);
    font-weight: 700;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-section-body {
    padding: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po {
    min-height: 88px;
    padding: 12px 16px;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-id {
    font-size: var(--gc-type-body, 13px);
    font-weight: 700;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-meta,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-dual-chip {
    font-size: var(--gc-type-label, 12px);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-fs {
    font-size: var(--gc-type-body, 13px);
  }
}

@media (max-width: 900px) {
  html body.today-prod-sub-active .pq2-section-body {
    padding: 0;
  }

  html body.today-prod-sub-active .pq2-po {
    min-height: 82px;
    padding: 10px 12px;
  }
}

/* qc-result-ui-v4: 五列台账内统一结果表达、交期对齐和 ERP 操作按钮。 */
@media (min-width: 901px) {
  .pq2-ledger-table .pq2-table-head,
  .pq2-ledger-table .pq2-po.pq2-ledger-row {
    display: grid;
    grid-template-columns: minmax(300px, 1.35fr) minmax(130px, .62fr) minmax(340px, 1.5fr) minmax(100px, .48fr) minmax(150px, .68fr);
    column-gap: var(--gc-space-3, 12px);
    align-items: center;
  }

  .pq2-ledger-table .pq2-ex-col {
    justify-self: start;
  }

  .pq2-ledger-table .pq2-ex-col .pq2-ex {
    text-align: left;
  }

  .pq2-ledger-table .pq2-action-col {
    justify-content: flex-start;
  }
}

.pq2-qc-col .pq2-focus {
  display: block;
}

.pq2-result {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--gc-space-1, 4px);
}

.pq2-result-main {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-soft, #424248);
  font-size: var(--gc-type-body, 13px);
  font-weight: 700;
  line-height: 1.3;
}

.pq2-result-main i {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: currentColor;
}

.pq2-result-main.is-pending { color: var(--apple-blue, #007aff); }
.pq2-result-main.is-warning { color: var(--warn, #b25400); }
.pq2-result-main.is-danger { color: var(--danger, #d70015); }
.pq2-result-main.is-rework { color: #7a2fa0; }
.pq2-result-main.is-success { color: var(--ok, #248a3d); }
.pq2-result-main.is-neutral { color: var(--ink-mute, #6b6b6e); }

.pq2-result-detail {
  max-width: 100%;
  color: var(--ink-soft, #424248);
  font-size: var(--gc-type-label, 12px);
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}

.pq2-result-note {
  max-width: 100%;
  overflow: hidden;
  color: var(--ink-mute, #6b6b6e);
  font-size: var(--gc-type-caption, 11px);
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pq2-action-group {
  display: flex;
  align-items: center;
  gap: var(--gc-space-1, 4px);
  white-space: nowrap;
}

.pq2-action-button {
  appearance: none;
  box-sizing: border-box;
  min-height: var(--gc-control-sm, 32px);
  padding: 0 9px;
  border: 1px solid var(--line-strong, #d1d1d6);
  border-radius: var(--gc-radius-md, 8px);
  color: var(--ink, #1d1d1f);
  background: var(--bg-elevated, #fbfbfd);
  font-family: var(--font-sans, -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif);
  font-size: var(--gc-type-label, 12px);
  font-weight: 650;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 150ms ease, background-color 150ms ease, color 150ms ease, transform 100ms ease-out;
}

.pq2-action-button:hover {
  border-color: var(--line-strong, #d1d1d6);
  background: var(--bg-hover, #f9f9fb);
}

.pq2-action-button:active {
  transform: scale(.98);
}

.pq2-action-button:focus-visible {
  outline: 0;
  box-shadow: var(--focus-ring, 0 0 0 2px rgba(0, 122, 255, .18));
}

.pq2-action-button.is-primary {
  border-color: var(--apple-blue, #007aff);
  color: var(--bg-elevated, #fbfbfd);
  background: var(--apple-blue, #007aff);
}

.pq2-action-button.is-primary:hover {
  border-color: var(--apple-blue-hover, #0051d5);
  background: var(--apple-blue-hover, #0051d5);
}

.pq2-action-button.is-secondary {
  color: var(--ink, #1d1d1f);
}

.pq2-action-button.is-success {
  border-color: rgba(36, 138, 61, .24);
  color: var(--ok, #248a3d);
  background: rgba(36, 138, 61, .08);
}

.pq2-action-button.is-rework {
  border-color: rgba(122, 47, 160, .22);
  color: #7a2fa0;
  background: rgba(175, 82, 222, .08);
}

@media (max-width: 900px) {
  .pq2-action-button {
    min-height: 44px;
    padding: 0 12px;
  }
}

/* qc-demo-preview-v1: 空台账允许查看不写入数据的 QC 示例状态。 */
.pq2-demo-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 38px;
  margin-bottom: var(--gc-space-3, 12px);
  padding: 0 var(--gc-space-3, 12px);
  border: 1px solid rgba(0, 122, 255, .22);
  border-radius: var(--gc-radius-md, 8px);
  background: rgba(0, 122, 255, .06);
  color: var(--ink-soft, #636366);
  font-size: var(--gc-type-label, 12px);
}
.pq2-demo-notice button,
.pq2-demo-trigger {
  appearance: none;
  border: 1px solid rgba(0, 122, 255, .34);
  border-radius: var(--gc-button-radius, 8px);
  background: #fff;
  color: var(--apple-blue, #007aff);
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}
.pq2-demo-notice button {
  flex: 0 0 auto;
  min-height: 30px;
  padding: 0 10px;
}
.pq2-demo-notice button:hover,
.pq2-demo-trigger:hover {
  background: rgba(0, 122, 255, .08);
}
.pq2-demo-trigger {
  min-height: 36px;
  margin-top: 14px;
  padding: 0 14px;
}
@media (max-width: 600px) {
  .pq2-demo-notice {
    align-items: flex-start;
    flex-direction: column;
    padding: 9px 12px;
  }
}

/* qc-factory-table-language-v1: QC 与工厂共用列头、表格节奏和信息分栏。 */
@media (min-width: 901px) {
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-top {
    grid-template-columns: repeat(5, minmax(112px, 132px)) minmax(12px, 1fr);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-st:last-child {
    border-right-width: 1px;
    border-radius: 0 10px 10px 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-st:nth-last-child(2) {
    border-right-width: 0;
    border-radius: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-table-head,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-factory-row {
    display: grid;
    grid-template-columns: minmax(300px, 1.35fr) minmax(130px, .62fr) minmax(360px, 1.55fr) minmax(118px, .55fr);
    column-gap: var(--gc-space-3, 12px);
    align-items: center;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-table-head {
    box-sizing: border-box;
    min-height: 36px;
    margin: 0 0 0;
    padding: 0 16px;
    border: 1px solid var(--gc-wb-line, rgba(60, 60, 67, .14));
    border-bottom: 0;
    border-radius: var(--gc-wb-group-radius, 10px) var(--gc-wb-group-radius, 10px) 0 0;
    color: var(--gc-wb-text-secondary, #5f6368);
    background: var(--gc-wb-surface-muted, #f9f9fb);
    font-size: var(--gc-type-label, 12px);
    font-weight: 650;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-factory-row {
    min-height: 96px;
    padding: 10px 16px;
    gap: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-style-col {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-style-copy,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-qc-col {
    min-width: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-img {
    width: 44px;
    height: 58px;
    border-radius: var(--gc-radius-sm, 6px);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-factory-col {
    min-width: 0;
    line-height: var(--gc-leading-body, 1.55);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-factory-name {
    overflow: hidden;
    color: var(--gc-wb-text-primary, #1d1d1f);
    font-size: var(--gc-type-body, 13px);
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-factory-meta {
    overflow: hidden;
    margin-top: 2px;
    color: var(--gc-wb-text-secondary, #5f6368);
    font-size: var(--gc-type-label, 12px);
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-qc-col {
    align-self: center;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-qc-col .pq2-mode {
    margin-top: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-qc-col .pq2-dual {
    margin-top: 4px;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-qc-col .pq2-focus {
    margin-top: 5px;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-right {
    justify-self: end;
    align-self: center;
    min-width: 92px;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ex .n {
    font-size: var(--gc-type-ui, 14px);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ex .l {
    font-size: var(--gc-type-caption, 11px);
  }
}

@media (max-width: 900px) {
  html body.today-prod-sub-active .pq2-table-head {
    display: none;
  }

  html body.today-prod-sub-active .pq2-po.pq2-factory-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px 12px;
  }

  html body.today-prod-sub-active .pq2-style-col,
  html body.today-prod-sub-active .pq2-qc-col {
    grid-column: 1 / -1;
  }

  html body.today-prod-sub-active .pq2-factory-col {
    grid-column: 1;
    min-width: 0;
  }

  html body.today-prod-sub-active .pq2-right {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
  }
}

/* qc-single-ledger-v2: QC 只展示 QC 结果，使用与工厂一致的单一连续台账。 */
.pq2-control-stack {
  overflow: hidden;
  border: 1px solid var(--line, #e5e5ea);
  border-radius: 16px;
  background: var(--bg-elevated, #fff);
}

.pq2-status-shell {
  display: flex;
  align-items: center;
  gap: var(--gc-space-3, 12px);
  min-height: 52px;
  padding: 7px 12px;
  border-bottom: 1px solid var(--line, #e5e5ea);
  background: var(--bg-sunken, #f5f5f7);
}

.pq2-status-label {
  flex: 0 0 auto;
  color: var(--ink-mute, #86868b);
  font-size: var(--gc-type-label, 12px);
  font-weight: 650;
  white-space: nowrap;
}

html body.today-prod-sub-active .pq2-status-shell .pq2-top {
  display: inline-flex;
  flex: 0 1 auto;
  gap: 2px;
  width: auto;
  margin: 0;
  padding: 3px;
  border: 0;
  border-radius: 10px;
  background: rgba(118, 118, 128, .12);
}

html body.today-prod-sub-active .pq2-status-shell .pq2-st {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: auto;
  min-width: 72px;
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  color: var(--ink-soft, #636366);
  background: transparent;
  box-shadow: none;
  transform: none;
  white-space: nowrap;
}

html body.today-prod-sub-active .pq2-status-shell .pq2-st:hover {
  border: 0;
  background: rgba(255, 255, 255, .64);
  transform: none;
}

html body.today-prod-sub-active .pq2-status-shell .pq2-st.active {
  color: #fff;
  background: var(--apple-blue, #007aff);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .10);
}

html body.today-prod-sub-active .pq2-status-shell .pq2-st span,
html body.today-prod-sub-active .pq2-status-shell .pq2-st b {
  display: inline;
  margin: 0;
  color: inherit !important;
  font-size: var(--gc-type-label, 12px);
  font-weight: 700;
  line-height: 1;
}

.pq2-control-stack .pq2-toolbar {
  min-height: 56px;
  padding: 10px 12px;
}

.pq2-ledger-table {
  overflow: hidden;
  border: 1px solid var(--line, #e5e5ea);
  border-radius: 16px;
  background: var(--bg-elevated, #fff);
}

/* qc-empty-shell-v1: 零数据时保留正式 QC 表格框架。 */
.pq2-ledger-empty.today-empty {
  box-sizing: border-box;
  display: grid;
  place-content: center;
  width: 100%;
  max-width: none;
  min-height: 220px;
  margin: 0;
  border: 0;
  border-radius: 0;
  text-align: center;
}

.pq2-ledger-empty.today-empty::after {
  content: none;
}

@media (min-width: 901px) {
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-table-head,
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-ledger-row {
    display: grid;
    grid-template-columns: minmax(300px, 1.35fr) minmax(130px, .62fr) minmax(340px, 1.5fr) minmax(100px, .48fr) minmax(150px, .68fr);
    column-gap: var(--gc-space-3, 12px);
    align-items: center;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-table-head {
    min-height: 38px;
    margin: 0;
    padding: 0 16px;
    border: 0;
    border-bottom: 1px solid var(--line, #e5e5ea);
    border-radius: 0;
    background: var(--bg-sunken, #f5f5f7);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-po.pq2-ledger-row {
    min-height: 86px;
    margin: 0;
    padding: 10px 16px;
    /* qc-ledger-column-gap-fix-v1: 表头与记录行必须使用同一横向列间距。 */
    row-gap: 0;
    column-gap: var(--gc-space-3, 12px);
    border: 0;
    border-bottom: 1px solid var(--line, #e5e5ea);
    border-radius: 0;
    background: var(--bg-elevated, #fff);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ledger-body .pq2-ledger-row:last-child {
    border-bottom: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ledger-row:hover {
    background: var(--bg-hover, #f9f9fb);
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ledger-row .pq2-focus {
    margin-top: 0;
  }

  /* qc-ledger-column-content-align-fix-v1: 高优先级规则也与表头左起点一致。 */
  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-ex-col {
    justify-self: start;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-action-col {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    min-width: 0;
  }

  html body.gc-admin-shell-pilot.peter-topbar-trial.today-prod-sub-active .pq2-action-col .pq2-acts {
    justify-content: flex-start;
    margin-top: 0;
  }
}

.pq2-qc-col .pq2-focus {
  align-items: flex-start;
  flex-direction: column;
  gap: 4px;
}

.pq2-qc-col .pq2-note {
  font-style: normal;
}

.pq2-no-action {
  color: var(--ink-mute, #86868b);
  font-size: var(--gc-type-label, 12px);
}

@media (max-width: 1160px) and (min-width: 901px) {
  .pq2-ledger-table {
    overflow-x: auto;
  }

  html body.today-prod-sub-active .pq2-table-head,
  html body.today-prod-sub-active .pq2-po.pq2-ledger-row {
    min-width: 980px;
  }
}

@media (max-width: 900px) {
  .pq2-status-shell {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
    padding: 9px 10px;
  }

  html body.today-prod-sub-active .pq2-status-shell .pq2-top {
    box-sizing: border-box;
    display: flex;
    width: 100%;
    overflow-x: auto;
  }

  html body.today-prod-sub-active .pq2-status-shell .pq2-st {
    flex: 1 0 auto;
    min-width: 68px;
  }

  .pq2-control-stack .pq2-toolbar {
    padding: 10px;
  }

  html body.today-prod-sub-active .pq2-po.pq2-ledger-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px 12px;
    margin: 0;
    border: 0;
    border-bottom: 1px solid var(--line, #e5e5ea);
    border-radius: 0;
  }

  html body.today-prod-sub-active .pq2-ledger-body .pq2-ledger-row:last-child {
    border-bottom: 0;
  }

  html body.today-prod-sub-active .pq2-ledger-row .pq2-style-col,
  html body.today-prod-sub-active .pq2-ledger-row .pq2-qc-col,
  html body.today-prod-sub-active .pq2-ledger-row .pq2-action-col {
    grid-column: 1 / -1;
  }

  html body.today-prod-sub-active .pq2-ledger-row .pq2-factory-col {
    grid-column: 1;
  }

  html body.today-prod-sub-active .pq2-ledger-row .pq2-ex-col {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
  }

  html body.today-prod-sub-active .pq2-ledger-row .pq2-action-col,
  html body.today-prod-sub-active .pq2-ledger-row .pq2-action-col .pq2-acts {
    justify-content: flex-start;
    margin-top: 0;
  }
}

/* qc-result-alignment-v4: 以台账自身为作用域，保证交期与操作和表头同起点。 */
@media (min-width: 901px) {
  .pq2-ledger-table .pq2-ledger-body .pq2-ledger-row .pq2-ex-col {
    justify-self: start;
  }

  .pq2-ledger-table .pq2-ledger-body .pq2-ledger-row .pq2-ex-col .pq2-ex {
    text-align: left;
  }

  .pq2-ledger-table .pq2-ledger-body .pq2-ledger-row .pq2-action-col {
    justify-content: flex-start;
  }
}

/* qc-scroll-compact-ui-v1:
   QC 是全账号共用页面。固定工作台内的控制区和台账保持真实高度，
   超出一屏时交给现有 today-scroll-region 局部滚动；顶部只保留紧凑分段控件。 */
@media (min-width: 901px) {
  body.today-prod-sub-active .today-scroll-region > .pq2-control-stack,
  body.today-prod-sub-active .today-scroll-region > .pq2-ledger-table {
    flex: 0 0 auto;
    min-width: 0;
  }

  body.today-prod-sub-active .pq2-control-stack {
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  body.today-prod-sub-active .pq2-status-shell {
    min-height: 36px;
    padding: 0;
    border: 0;
    background: transparent;
  }

  html body.today-prod-sub-active .pq2-status-shell .pq2-top {
    flex: 0 0 auto;
  }

  html body.today-prod-sub-active .pq2-status-shell .pq2-st {
    min-height: 30px;
    padding: 0 12px;
  }

  body.today-prod-sub-active .pq2-control-stack .pq2-toolbar {
    min-height: 46px;
    padding: 10px 0 0;
  }
}

/* peter-qc-workspace-parity-v1:
 * Peter QC 直接复用版房 / 采购 / 工厂的两行控制轨道、一级蓝线和唯一列表框。
 * 只改变展示层；普通账号继续原 QC 结构，真实筛选、表格字段和登记动作不变。 */
html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .today-scroll-region > .pq2-workspace.erp-workspace-shell {
  flex: 0 0 auto;
  min-width: 0;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-status-shell.erp-workspace-controls-main {
  justify-content: flex-start !important;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-status-field.pattern-control-group {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-status-label.pattern-control-label {
  color: var(--gc-wb-text-muted, #6e6e73);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-status-shell .pq2-top.pattern-segmented {
  box-sizing: border-box;
  height: 36px;
  min-height: 36px;
  padding: 3px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  border: 1px solid rgba(60, 60, 67, 0.08);
  border-radius: 10px;
  background: rgba(118, 118, 128, 0.12);
  overflow: visible;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-status-shell .pq2-st.pattern-segment {
  box-sizing: border-box;
  height: 30px;
  min-height: 30px;
  min-width: 90px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 600;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .prod-qc-searchbar.pattern-workspace-searchbar {
  flex: 0 1 430px !important;
  width: min(430px, 100%) !important;
  max-width: 430px;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-body.erp-workspace-body {
  min-width: 0;
  display: block;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-group {
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-stage-head.erp-workspace-stage-head {
  position: relative;
  min-height: 30px;
  padding: 0 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 0;
  color: var(--gc-wb-text, #1d1d1f);
  background: transparent;
  box-shadow: none;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-stage-head .pq2-dot {
  position: absolute;
  top: 4px;
  left: 0;
  width: 3px;
  height: 22px;
  border-radius: 3px;
  background: var(--gc-wb-primary, #007aff);
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-stage-head strong {
  font-size: 15px;
  font-weight: 700;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-stage-head .pq2-cnt {
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: #6e6e73;
  background: transparent;
  font-size: 12px;
  font-weight: 500;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-group > .pq2-ledger-table {
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid rgba(60, 60, 67, 0.12);
  border-radius: 12px;
  background: var(--gc-wb-surface, #fff);
  box-shadow: none;
}

html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
  .pq2-workspace-group > .pq2-ledger-table .pq2-table-head {
  min-height: 38px;
  border-top: 0;
  border-bottom-color: rgba(60, 60, 67, 0.12);
  border-radius: 0;
  color: #6e6e73;
  background: #f5f5f7;
  font-size: 11.5px;
  font-weight: 600;
}

@media (max-width: 900px) {
  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .pq2-status-shell.erp-workspace-controls-main {
    align-items: stretch;
  }

  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .pq2-status-field.pattern-control-group {
    width: 100%;
  }

  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .pq2-status-shell .pq2-top.pattern-segmented {
    max-width: 100%;
    overflow-x: auto;
  }

  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .prod-qc-searchbar.pattern-workspace-searchbar {
    flex-basis: 100% !important;
    width: 100% !important;
    max-width: none;
  }
}

@media (max-width: 720px) {
  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .pq2-status-field.pattern-control-group {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  html body.peter-qc-workspace-pilot.today-prod-sub-active main#main
    .pq2-status-shell .pq2-st.pattern-segment {
    min-width: 80px;
  }
}
/* peter-qc-workspace-parity-v1:end */
