/* Gửi xưởng (vendor-fulfill.js) + thanh trạng thái xưởng trong chi tiết đơn (app.js) */
.vendor-bar{display:flex;flex-wrap:wrap;align-items:center;gap:8px 16px;margin:0 0 10px;padding:10px 14px;border:1px solid #d6e2f5;border-radius:8px;background:#f5f9ff;font-size:13px;color:#33404f}
.vendor-bar.is-sent{background:#effaf3;border-color:#c5e8d3}
.vendor-bar small{color:#7a8592}
.vendor-send{margin-left:auto;height:34px;border:0;border-radius:7px;background:#e8590c;color:#fff;padding:0 16px;font:600 13px inherit;cursor:pointer}
.vendor-send:hover{background:#c94c0a}
.vendor-send:disabled{background:#c9ced6;cursor:not-allowed}
.vendor-sync{height:36px;border:1px solid var(--line,#dfe3e8);border-radius:8px;background:#fff;padding:0 12px;font:600 13px inherit;cursor:pointer;white-space:nowrap}
.vendor-sync:disabled{opacity:.5;cursor:wait}

.dialog.vf-dialog{width:min(980px,95vw);max-width:95vw}
.vf-addr{margin:0 0 12px;color:#53606d;font-size:13px}
.vf-vendor{display:grid;gap:6px;max-width:320px;margin-bottom:12px}
.vf-body{display:grid;gap:10px;max-height:52vh;overflow:auto}
.vf-item{border:1px solid var(--line,#dfe3e8);border-radius:8px;padding:12px}
.vf-item-head{display:grid;gap:3px;margin-bottom:10px}
.vf-item-head small{color:#6b7684;font-size:12px}
.vf-item-head .vf-custom{color:#33404f}
.vf-item-head a{color:#12824c;font-weight:600;font-size:12px;text-decoration:none}
.vf-missing{color:#c93632;font-size:12px;font-weight:600}
.vf-grid{display:grid;grid-template-columns:2fr 1.4fr 1fr 1.2fr;gap:8px}
.vf-grid select{width:100%}
.dialog .vf-remember,.dialog .vf-confirm{display:flex!important;align-items:center;gap:6px;font-size:12px;color:#53606d;margin-top:8px}
.dialog .vf-remember input,.dialog .vf-confirm input{width:auto;height:auto}
.vf-confirm{font-weight:600;color:#9a3412!important}
.vf-total{margin:12px 0 0;font-size:13px;font-weight:600;color:#33404f}
.vf-status{min-height:18px;margin:8px 0 0;font-size:13px;color:#46515f}
.vf-dialog menu .primary{background:#e8590c;border-color:#e8590c;color:#fff}
.vf-dialog menu button:disabled{opacity:.5;cursor:not-allowed}
@media(max-width:800px){.vf-grid{grid-template-columns:1fr 1fr}}

/* Nhãn trạng thái xưởng trong danh sách đơn */
.order-status.đã-gửi-xưởng{color:#1d4ed8;background:#e8efff}
.order-status.đang-sản-xuất{color:#7c3aed;background:#f1eafe}
.order-status.đang-giao{color:#0e7490;background:#e3f6fa}
.order-status.đã-giao{color:#12824c;background:#e8f8ef}
.order-status.xưởng-báo-lỗi{color:#c93632;background:#fdecec}
.order-status.đã-huỷ-ở-xưởng{color:#6b7280;background:#f1f2f4}

/* Gửi xưởng hàng loạt (VendorFulfill.openBulk) */
.bulk-fulfill{height:34px;border:0;border-radius:7px;background:#e8590c;color:#fff;padding:0 14px;font:600 13px inherit;cursor:pointer;margin-left:auto;margin-right:8px}
.bulk-fulfill:hover{background:#c94c0a}
.vf-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-bottom:10px}
.vf-summary article{border:1px solid var(--line,#dfe3e8);border-radius:8px;padding:8px 12px}
.vf-summary span{display:block;color:#6b7684;font-size:12px}
.vf-summary strong{font-size:16px}
.vf-skipped{margin-bottom:10px;font-size:12px;color:#53606d}
.vf-skipped summary{cursor:pointer;font-weight:600}
.vf-skipped ul{margin:6px 0 0;padding-left:18px;max-height:120px;overflow:auto}
.vf-hint{margin:0;font-size:12px;color:#53606d}
.vf-total.vf-over{color:#c93632}
.vf-progress{width:100%;height:10px;margin-top:10px}
.vf-results{font-size:13px;max-height:160px;overflow:auto}
.vf-results .vf-ok{color:#12824c;margin:8px 0 0}
.vf-results .vf-fail{color:#c93632;margin:8px 0 0;font-weight:600}
.vf-results ul{margin:4px 0 0;padding-left:18px}
@media(max-width:700px){.vf-summary{grid-template-columns:1fr}}

/* Khớp sản phẩm xưởng theo listing (VendorFulfill.openMapping) + trạng thái Sẵn sàng gửi */
.order-status.sẵn-sàng-gửi{color:#fff;background:#e8590c}
.dialog.vf-map-dialog{width:min(1100px,96vw)}
.vf-map-tools{display:flex;flex-wrap:wrap;align-items:end;gap:12px;margin:10px 0}
.vf-map-tools .vf-vendor{margin:0;min-width:220px}
.vf-search{height:38px;border:1px solid var(--line,#dfe3e8);border-radius:7px;padding:0 10px;font:13px inherit;min-width:260px;flex:1}
.vf-map-list{max-height:62vh}
.vf-map-head{display:flex;align-items:center;gap:10px;margin-bottom:10px}
.vf-map-head img,.vf-noimg{width:44px;height:44px;border-radius:6px;object-fit:cover;background:#f1f4f8;flex:none}
.vf-map-head>div{display:grid;gap:2px;min-width:0;flex:1}
.vf-map-head b{font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.vf-map-head small{color:#6b7684;font-size:12px}
.vf-badge{flex:none;border-radius:12px;padding:4px 10px;font-size:12px;font-weight:600}
.vf-badge.ok{background:#e8f8ef;color:#12824c}.vf-badge.warn{background:#fff3df;color:#9a5a00}.vf-badge.none{background:#f1f2f4;color:#6b7280}
.vf-map-grid{grid-template-columns:2fr 1fr 1.2fr}
.vf-sizes{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:8px;margin-top:10px}
.vf-sizes label{display:grid!important;gap:4px;font-size:12px}
.vf-sizes span{color:#53606d}
.vf-map-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:10px}
.vf-row-note{color:#53606d;font-size:12px}
.vf-save{height:32px;border:0;border-radius:7px;background:#2867d5;color:#fff;padding:0 18px;font:600 13px inherit;cursor:pointer}
.vf-save:disabled{opacity:.5}
#sendReady:disabled{background:#c9ced6;cursor:not-allowed}
@media(max-width:800px){.vf-map-grid{grid-template-columns:1fr}}
