/* AmSpec v389 — linked highlights, product quality groups and compact photo controls. */
.fert-draft-preview-table th,
.fert-draft-preview-table td,
.fert-draft-preview-table th *,
.fert-draft-preview-table td *,
.fert-draft-table th,
.fert-draft-table td,
.fert-draft-table input,
.fert-draft-table strong { text-align: center !important; vertical-align: middle !important; }

.fert-highlight-choice-copy em { display:block; margin-top:3px; color:#8A2A2B; font-size:.68rem; font-style:normal; font-weight:750; }

.fert-quality-product-toolbar { display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; margin:10px 0 8px; }
.fert-quality-product-tabs { display:flex; gap:7px; flex-wrap:wrap; }
.fert-quality-product-tab { border:1px solid #cbd5e1; border-radius:8px; background:#fff; color:#253247; padding:8px 13px; font-weight:850; cursor:pointer; }
.fert-quality-product-tab.is-active { background:#8A2A2B; border-color:#8A2A2B; color:#fff; }
.fert-quality-product-card { display:grid; grid-template-columns:minmax(190px,1fr) minmax(260px,2fr) auto; gap:12px; align-items:end; border:1px solid #d8e0e8; border-radius:10px; padding:11px 12px; background:#f8fafc; margin-bottom:10px; }
.fert-quality-product-card label>span,.fert-quality-hold-assignment>span { display:block; color:#475569; font-size:.7rem; font-weight:850; margin-bottom:5px; }
.fert-quality-product-card input[type="text"],.fert-quality-product-card input:not([type]) { width:100%; }
.fert-quality-hold-assignment>div { display:flex; gap:6px; flex-wrap:wrap; }
.fert-quality-hold-assignment label { display:inline-flex; align-items:center; gap:4px; padding:5px 7px; border:1px solid #d8e0e8; border-radius:7px; background:#fff; font-size:.72rem; font-weight:750; }
.fert-quality-composite-tab { border-style:dashed !important; }
.fert-quality-card-list { display:grid; gap:9px; }
.fert-quality-parameter-card { border:1px solid #d8e0e8; border-radius:10px; padding:10px; background:#fff; box-shadow:0 1px 2px rgba(15,23,42,.04); }
.fert-quality-parameter-card header { display:flex; gap:8px; align-items:center; margin-bottom:8px; }
.fert-quality-param-name { flex:1; min-width:0; font-weight:900; text-align:left !important; }
.fert-quality-remove-row { width:30px; height:30px; border:1px solid #e2b9b9; border-radius:7px; background:#fff5f5; color:#8A2A2B; font-weight:900; cursor:pointer; }
.fert-quality-parameter-meta,.fert-quality-parameter-results { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:7px; }
.fert-quality-parameter-results { margin-top:8px; grid-template-columns:repeat(3,minmax(0,1fr)); }
.fert-quality-parameter-results.is-composite { grid-template-columns:minmax(180px,1fr); max-width:300px; }
.fert-quality-parameter-card label span { display:block; margin-bottom:3px; color:#64748b; font-size:.67rem; font-weight:850; text-transform:uppercase; }
.fert-quality-parameter-card input { width:100% !important; min-width:0 !important; box-sizing:border-box; text-align:center !important; }
.fert-quality-value-wrap { display:block; }
.fert-quality-value-wrap.is-off-spec input { background:#FCE8E8 !important; color:#8A2A2B !important; font-weight:900; }
.fert-quality-value-wrap small { display:block; margin-top:2px; color:#8A2A2B; font-size:.62rem; }
.fert-quality-active-label { display:flex; justify-content:space-between; align-items:center; gap:8px; }
.fert-quality-product-heading { text-align:center; font-size:7pt; font-weight:900; color:#8A2A2B; margin:0 0 1mm; letter-spacing:.02em; }
.fert-quality-report-block+.fert-quality-report-block { margin-top:2.5mm; }

.fert-photo-highlight-toggle { top:6px !important; right:47px !important; width:27px !important; height:27px !important; padding:0 !important; border-radius:50% !important; justify-content:center !important; background:rgba(255,255,255,.9) !important; box-shadow:0 1px 3px rgba(0,0,0,.12); }
.fert-photo-highlight-toggle input { position:absolute !important; opacity:0 !important; pointer-events:none; }
.fert-photo-highlight-toggle span { display:flex; align-items:center; justify-content:center; width:100%; height:100%; font-size:.67rem; font-weight:950; color:#64748b; }
.fert-photo-highlight-toggle:has(input:checked) { background:#FCE8E8 !important; border-color:#8A2A2B !important; }
.fert-photo-highlight-toggle:has(input:checked) span { color:#8A2A2B; }

@media (max-width:900px) {
  .fert-quality-product-card { grid-template-columns:1fr; }
  .fert-quality-parameter-meta { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:560px) {
  .fert-quality-parameter-results { grid-template-columns:1fr; }
}
