.prep-stats { display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin-bottom:23px; }
.prep-stat { background:white; border:1px solid var(--line); border-radius:10px; padding:20px 22px; text-align:left; color:var(--ink); }
.prep-stat span { display:block; font-size:11px; color:#87979e; }
.prep-stat strong { display:block; font-size:25px; margin:10px 0 5px; font-weight:600; }
.prep-stat small { font-size:10px; color:#a0adb0; }
.prep-stat:hover { border-color:#a8cbbd; }
.prep-stat.warning strong { color:#bc8644; }
.prep-stat.success strong { color:var(--green); }
.view-tabs { display:flex; gap:24px; }
.view-tab { padding:5px 0; background:none; font-size:13px; color:#91a0a5; position:relative; }
.view-tab.active { color:var(--green); font-weight:600; }
.view-tab.active:after { content:""; height:2px; background:var(--green); position:absolute; bottom:-20px; left:0; right:0; }
.prep-table th { font-size:11px; }
.prep-table td { padding-top:20px; padding-bottom:20px; vertical-align:top; }
.prep-title { max-width:250px; overflow:hidden; text-overflow:ellipsis; display:block; margin-bottom:8px; font-size:13px; }
.prep-code { font-size:10px; color:#96a5ab; margin-bottom:9px; }
.task-person { font-size:10px; color:#95a2a7; margin-top:8px; }
.status-badge { display:inline-flex; align-items:center; padding:5px 8px; border-radius:5px; font-size:10px; white-space:nowrap; }
.state-pending { background:#f1f4f5; color:#91a0a7; }
.state-working,.state-preparing { background:#eef3fa; color:#748eac; }
.state-needs_info,.state-review { background:#fff4e7; color:#b98543; }
.state-done,.state-ready { background:#eaf5ee; color:#398a68; }
.state-listed { background:#eef1f5; color:#7b8799; }
.is-overdue { color:#bd7259; font-size:11px; margin-top:8px; }
.prep-footnote { font-size:11px; color:#99a9ae; padding:20px 3px; line-height:1.8; }
.prep-dialog { width:630px; }
.prep-detail { width:1120px; max-height:calc(100vh - 36px); }
.prep-detail .modal-head { position:sticky; top:0; z-index:2; background:white; }
.detail-top-actions { display:flex; gap:10px; align-items:center; }
.prep-detail-title { max-width:640px; overflow-wrap:anywhere; line-height:1.7; }
.prep-detail-code { font-size:10px; color:#94a6a9; margin-bottom:5px; }
.detail-body { padding:24px; }
.detail-summary { display:flex; gap:15px; flex-wrap:wrap; align-items:center; font-size:11px; color:#8b9da4; margin-bottom:15px; }
.detail-notes { white-space:pre-wrap; overflow-wrap:anywhere; font-size:12px; color:#637f87; line-height:1.9; margin-bottom:20px; padding:14px 17px; border:1px solid #e9eeec; background:#f9fbfa; border-radius:8px; }
.detail-actions { display:flex; gap:9px; flex-wrap:wrap; padding-bottom:22px; border-bottom:1px solid var(--line); margin-bottom:23px; }
.detail-flow { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; margin-bottom:23px; }
.flow-step { border:1px solid var(--line); border-radius:9px; background:#fbfcfc; padding:14px 15px; }
.flow-step h3 { font-size:12px; margin-bottom:9px; }
.flow-step p { font-size:10px; margin:9px 0 0; color:#93a4a8; }
.flow-step.done { border-color:#d7e7de; background:#f4f9f6; }
.detail-grid { display:grid; grid-template-columns:minmax(0,1fr) 285px; gap:22px; align-items:start; }
.task-tabs { display:flex; border-bottom:1px solid var(--line); padding:0 20px; gap:25px; }
.task-tab { padding:17px 0; background:none; font-size:12px; color:#91a1a6; border-bottom:2px solid transparent; }
.task-tab.active { color:var(--green); border-bottom-color:var(--green); }
.task-body { padding:20px; }
.task-body .form-field { margin-bottom:17px; }
.processing-formula { display:grid; grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr) 24px minmax(0,1fr); gap:12px; align-items:center; border:1px solid #e1ece6; background:#f7fbf8; border-radius:9px; padding:20px; }
.processing-formula .form-field { min-width:0; margin:0; }
.processing-symbol { color:#92a89b; font-size:21px; text-align:center; padding-top:18px; }
.processing-value { display:block; min-height:40px; padding:10px 0; font-size:14px; font-variant-numeric:tabular-nums; }
.processing-result { color:#137c70; font-weight:650; font-size:19px; overflow-wrap:anywhere; }
.legacy-pricing { margin:18px 0; border:1px solid #e7edeb; padding:13px; border-radius:7px; font-size:11px; color:#8d9e97; }
.legacy-pricing summary { cursor:pointer; }
.prep-row-actions { display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.prep-row-actions .delete-preparation { color:#b77c70; }
.btn.btn-danger { background:#b66c5f; color:#fff; }
.btn.btn-danger:hover { background:#9e584c; }
.delete-preparation-title { color:#607870; overflow-wrap:anywhere; }
.state-deleted { background:#f3f0ee; color:#a28b82; }
.selling-components,.selling-inputs { display:grid; grid-template-columns:1fr 1fr; gap:18px; margin-bottom:20px; }
.selling-component { border:1px solid #e3ece7; border-radius:8px; padding:17px; background:#f8fbf9; }
.selling-component span { color:#90a298; font-size:11px; display:block; margin-bottom:12px; }
.selling-component strong { color:#527966; font-size:18px; font-variant-numeric:tabular-nums; }
.selling-total { display:flex; justify-content:space-between; align-items:center; gap:15px; padding:22px 0; border-top:1px solid #e2ebe6; border-bottom:1px solid #e2ebe6; color:#63806d; }
.selling-total small { margin-left:8px; color:#99aaa0; font-size:10px; }
.selling-total strong { color:#137c70; font-size:25px; font-variant-numeric:tabular-nums; }
@media(max-width:620px) { .selling-components,.selling-inputs { grid-template-columns:1fr; gap:12px; } .selling-total strong { font-size:20px; } }
@media(max-width:620px) { .processing-formula { grid-template-columns:minmax(0,1fr) 15px minmax(0,1fr); gap:8px; padding:14px; } .processing-formula>.processing-symbol:nth-child(4) { display:none; } .processing-formula>.form-field:last-child { grid-column:1/-1; padding-top:10px; border-top:1px solid #e3ece6; } .processing-result { font-size:21px; } }
.task-tabs { overflow-x:auto; white-space:nowrap; }
.task-tab { flex-shrink:0; }
.fabric-cost-toolbar { display:flex; justify-content:space-between; gap:10px; flex-wrap:wrap; margin-bottom:15px; }
.fabric-cost-row { border:1px solid #e2ebe7; border-radius:9px; padding:16px; margin-bottom:15px; background:#fbfdfc; }
.fabric-row-heading { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; font-size:12px; }
.fabric-cost-fields { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:0 14px; }
.fabric-cost-fields .form-field { min-width:0; }
.fabric-cost-fields label { min-height:17px; }
.fabric-snapshot { font-size:10px; color:#8ca099; line-height:1.8; margin:-6px 0 16px; overflow-wrap:anywhere; }
.fabric-value { display:block; min-height:38px; padding:10px 0; font-size:12px; font-variant-numeric:tabular-nums; color:#59716a; }
.fabric-cost-number { color:#137c70; font-weight:600; }
.fabric-row-footer { display:flex; justify-content:space-between; align-items:center; gap:10px; flex-wrap:wrap; border-top:1px solid #e8efeb; padding-top:10px; }
.fabric-row-footer small { font-size:10px; color:#97a8a0; }
.selected-price-grid { display:grid; grid-template-columns:1fr 1fr; gap:15px; margin:16px 0; }
.selected-price-grid span { font-size:10px; color:#91a49a; display:block; margin-bottom:8px; }
.selected-price-grid strong { font-size:14px; color:#527f68; font-variant-numeric:tabular-nums; }
.estimate-section-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:8px; }
.estimate-section-heading h3 { margin:0; }
.estimate-processing-heading { margin:27px 0 15px; }
.estimate-total { display:flex; align-items:center; justify-content:space-between; gap:15px; padding:23px 0; margin:16px 0; border-bottom:1px solid #e2ebe6; color:#67816d; }
.estimate-total small { display:block; color:#9aaba1; font-size:10px; margin-top:8px; }
.estimate-total strong { color:#137c70; font-size:22px; font-variant-numeric:tabular-nums; }
.fabric-total { display:flex; align-items:center; justify-content:space-between; gap:15px; padding:20px 0 15px; border-bottom:1px solid #e5ede8; margin-bottom:15px; color:#5a796d; }
.fabric-total small { font-size:10px; color:#98aaa2; margin-left:8px; }
.fabric-total strong { color:#137c70; font-size:21px; font-variant-numeric:tabular-nums; }
@media(max-width:620px) { .fabric-cost-fields { grid-template-columns:repeat(2,minmax(0,1fr)); } .fabric-cost-row { padding:12px; } .fabric-total strong { font-size:17px; } }
.task-context { display:flex; justify-content:space-between; gap:15px; align-items:center; margin-bottom:16px; font-size:11px; color:#90a2a9; }
.task-message { border-radius:7px; background:#fff6e9; color:#ad8957; padding:12px 14px; font-size:11px; line-height:1.9; white-space:pre-wrap; margin-bottom:15px; }
.task-buttons { display:flex; gap:9px; flex-wrap:wrap; margin-top:20px; padding-top:17px; border-top:1px solid var(--line); }
textarea { font:inherit; font-size:12px; border:1px solid #dde5e8; border-radius:6px; padding:11px; min-height:85px; width:100%; color:#405460; resize:vertical; line-height:1.8; }
textarea:focus { border-color:#72ae9d; outline:2px solid #72ae9d22; }
.two-columns { display:grid; grid-template-columns:1fr 1fr; gap:0 18px; }
.two-columns .form-field { min-width:0; }
.prep-form-note { padding:13px 15px; background:#f2f7f4; border-radius:7px; color:#7d998a; font-size:11px; line-height:1.9; margin:0 0 20px; }
.grid-editor { width:100%; white-space:normal; }
.grid-editor th { font-size:10px; padding:9px 5px; height:auto; }
.grid-editor td { padding:7px 4px; }
.grid-editor input { height:34px; padding:0 6px; font-size:11px; min-width:64px; }
.grid-editor input[data-key="note"] { min-width:90px; }
.grid-editor .remove-row { background:none; color:#b2bec2; height:28px; width:20px; padding:0; }
.row-add { margin-top:14px; }
.readonly-table td { overflow-wrap:anywhere; font-size:11px; }
.empty-note { padding:20px; color:#a0afb3; font-size:11px; line-height:1.9; text-align:center; }
.image-gallery { display:grid; grid-template-columns:repeat(3,1fr); gap:11px; margin-bottom:17px; }
.prep-image { border:1px solid var(--line); border-radius:7px; overflow:hidden; background:#fbfcfc; }
.prep-image img { width:100%; height:135px; object-fit:contain; display:block; background:#f4f6f6; }
.prep-image .image-meta { padding:9px; font-size:10px; color:#8ca0a5; overflow-wrap:anywhere; }
.prep-image .image-meta label { display:flex; align-items:center; gap:7px; margin-top:7px; color:#618574; }
.prep-image input[type="checkbox"] { width:13px; height:13px; accent-color:var(--green); }
.file-input-label { display:inline-flex; cursor:pointer; }
.file-input-label input { display:none; }
.image-section-label { font-size:11px; color:#7d939a; margin:18px 0 11px; }
.reference-strip { display:flex; gap:8px; flex-wrap:wrap; margin-bottom:14px; }
.reference-strip img { height:62px; width:62px; object-fit:contain; border-radius:6px; border:1px solid var(--line); }
.reference-strip a { display:block; }
.events-panel .panel-head { padding:17px; }
.events-list { max-height:520px; overflow:auto; padding:16px; }
.event-item { border-left:1px solid #e2e9e6; padding:0 0 18px 13px; position:relative; }
.event-item:before { content:""; position:absolute; width:5px; height:5px; background:#b4cfc2; border-radius:50%; left:-3px; top:4px; }
.event-item:last-child { padding-bottom:0; }
.event-item strong { font-size:10px; color:#6a8790; }
.event-item p { font-size:10px; color:#93a5aa; white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.8; margin:5px 0; }
.event-item small { font-size:9px; color:#acb8bd; }
.detail-reference { margin-bottom:20px; }
.listing-record { border:1px solid #d8e9df; background:#f3f9f5; border-radius:8px; padding:14px 16px; color:#668b76; margin-bottom:20px; font-size:12px; line-height:1.9; white-space:pre-wrap; }
button:disabled,a.disabled { opacity:.45; cursor:not-allowed; }
@media(max-width:1100px) { .detail-grid { grid-template-columns:1fr; } .events-list { max-height:230px; } .prep-detail { width:920px; } }
@media(max-width:840px) { .prep-stats { grid-template-columns:repeat(2,1fr); } .detail-flow { grid-template-columns:repeat(2,1fr); } .detail-body { padding:18px; } }
@media(max-width:620px) { .prep-stat { padding:16px; } .prep-stat strong { font-size:22px; } .prep-stats { gap:11px; } .prep-detail { max-width:calc(100vw - 14px); max-height:calc(100vh - 16px); } .detail-body { padding:14px; } .prep-detail .modal-head { padding:14px; } .detail-top-actions { gap:5px; } .detail-top-actions .status-badge { display:none; } .two-columns { grid-template-columns:1fr; gap:0; } .task-body { padding:14px; } .task-tabs { padding:0 14px; gap:20px; } .task-tab { font-size:11px; } .image-gallery { grid-template-columns:repeat(2,1fr); } .prep-image img { height:125px; } .view-tab { font-size:12px; } .detail-actions .btn { font-size:10px; padding:0 10px; } .detail-flow { gap:9px; } .flow-step { padding:12px; } .prep-detail-title { font-size:14px; } .task-buttons .btn { font-size:11px; } }
