/* The preparation workspace is private and scoped to this component. */
.preparation-center{max-width:100%;min-width:0;color:var(--brand-text);font-size:14px}
.preparation-center *{box-sizing:border-box}.preparation-center [hidden]{display:none!important}
.preparation-center h2{font-size:25px;margin:0 0 4px;line-height:1.2}.preparation-center h3{font-size:20px;margin:0 0 10px;line-height:1.25}.preparation-center h4{font-size:16px;margin:18px 0 10px}.preparation-center p{line-height:1.45;margin:6px 0 12px}.preparation-center small{display:block;color:var(--brand-muted);line-height:1.4;font-size:12px}.preparation-center strong,.preparation-center td,.preparation-center label{overflow-wrap:anywhere}
.preparation-center button,.preparation-center input,.preparation-center select{min-height:44px}.preparation-center button{white-space:normal;line-height:1.3;font-size:13px;max-width:100%;cursor:pointer}.preparation-center button:disabled{opacity:.55;cursor:default}.preparation-center button:focus-visible,.preparation-center input:focus-visible,.preparation-center select:focus-visible,.preparation-center textarea:focus-visible,.preparation-center summary:focus-visible{outline:3px solid var(--brand-focus);outline-offset:2px}
.prep-header,.prep-section-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin:14px 0}.prep-header>div,.prep-section-head>div{min-width:0}.prep-header p{color:var(--brand-muted);margin-bottom:0}.prep-navigation{display:flex;gap:6px;flex-wrap:wrap;margin:16px 0}.prep-navigation .selected,.prep-count.selected{background:var(--brand-primary);border-color:var(--brand-primary);color:var(--brand-on-primary)}
.prep-feedback{padding:12px;border:1px solid var(--brand-border);border-radius:10px;line-height:1.5;overflow-wrap:anywhere}.prep-feedback.error{color:#76290f;background:#fff2ed;border-color:#c95a38}.prep-feedback.notice{background:var(--brand-secondary);color:var(--brand-text)}
.prep-counts{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));gap:7px;margin:14px 0}.prep-count{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;background:var(--brand-surface);border:1px solid var(--brand-border);border-radius:10px;padding:10px;gap:5px;text-align:left;min-width:0}.prep-count strong{font-size:24px;line-height:1.1}.prep-count span{font-size:11px;line-height:1.35}
.prep-filters{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));align-items:end;gap:12px;background:var(--brand-surface);border:1px solid var(--brand-border);border-radius:12px;padding:14px;margin:12px 0}.preparation-center label{display:grid;gap:5px;min-width:0;font-size:12px;font-weight:650}.preparation-center input:not([type=checkbox]),.preparation-center select,.preparation-center textarea{border:1px solid var(--brand-border);border-radius:7px;background:var(--brand-surface);color:var(--brand-text);padding:9px;width:100%;max-width:100%;min-width:0;font:inherit;font-size:14px}.preparation-center textarea{resize:vertical}.prep-filter-actions{display:flex;gap:6px;align-items:stretch}.prep-filter-actions>*{flex:1;min-width:0}
.prep-main-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:14px 0 8px}.prep-main-actions button{font-weight:750}.prep-selection,.prep-batch-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:10px 0}.prep-selection strong{margin-right:auto;font-size:13px}.prep-selection .link-button{padding:6px 8px}.prep-help{font-size:12px;color:var(--brand-muted);line-height:1.45}.prep-warning{color:#8a350b!important;font-size:12px;font-weight:650}
.prep-scroll-hint{display:none;font-size:12px;color:var(--brand-muted)}
.prep-table-wrap{max-width:100%;overflow-x:auto;border:1px solid var(--brand-border);border-radius:10px;background:var(--brand-surface);margin:12px 0}.preparation-center table{border-collapse:collapse;width:100%;min-width:0;font-size:13px}.preparation-center th{text-align:left;font-size:11px;font-weight:750;background:var(--brand-secondary);color:var(--brand-text);padding:10px;border-bottom:1px solid var(--brand-border);white-space:normal}.preparation-center td{padding:9px;vertical-align:top;border-bottom:1px solid var(--brand-border);white-space:normal}.preparation-center tr:last-child td{border-bottom:0}.prep-orders td>span,.prep-orders td>strong{display:block}.prep-orders td:first-child{width:46px;padding:4px}.prep-check{display:inline-flex!important;align-items:center;justify-content:center;width:44px;height:44px}.prep-check input,.prep-reviewed input{width:20px;height:20px;min-height:20px;accent-color:var(--brand-primary)}.prep-status{display:inline-block!important;max-width:100%;border:1px solid var(--brand-border);background:var(--brand-secondary);color:var(--brand-text);border-radius:6px;padding:4px 6px;font-size:11px;font-weight:700}.prep-money{font-weight:750;white-space:nowrap!important}.prep-pagination{display:flex;justify-content:center;align-items:center;gap:10px;margin:14px 0}.prep-pagination span{font-size:12px;text-align:center}
.preparation-center details{margin-top:6px;min-width:0}.preparation-center summary{cursor:pointer;min-height:36px;padding:8px 0;font-size:12px;font-weight:650;overflow-wrap:anywhere}.preparation-center ul{margin:7px 0;padding-left:18px}.preparation-center li{margin-bottom:6px;line-height:1.4}.prep-panel{background:var(--brand-surface);border:1px solid var(--brand-border);padding:16px;border-radius:12px;margin:14px 0;min-width:0}.prep-consolidated th:first-child{width:32%}.prep-consolidated td input{min-width:80px;max-width:100px}.prep-consolidated td button{padding:8px;font-size:12px}.prep-order-details>details{border:1px solid var(--brand-border);border-radius:10px;padding:10px;margin:10px 0;background:var(--brand-background)}.prep-order-details>details>summary{font-size:14px;min-height:44px}.prep-order-details>details>summary span{font-size:11px;color:var(--brand-muted)}.prep-item{display:grid;grid-template-columns:2fr 1fr 1fr auto;gap:10px;align-items:center;background:var(--brand-surface);border-top:1px solid var(--brand-border);padding:12px 0}.prep-item>div{min-width:0}.prep-item .prep-substitution{grid-column:1/-1}.prep-reviewed{display:flex!important;gap:8px;align-items:center;min-height:44px;line-height:1.4;font-weight:500!important}.prep-substitution{padding:8px;background:var(--brand-background);border-radius:8px}.prep-substitution>label{margin:10px 0}.prep-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.prep-list-card{display:flex;flex-direction:column;gap:8px;padding:14px;border:1px solid var(--brand-border);border-radius:10px;min-width:0}.prep-list-card button{margin-top:auto}
.prep-money-summary{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}.prep-money-summary>span{display:flex;flex-direction:column;gap:4px;flex:1 1 140px;background:var(--brand-secondary);padding:12px;border-radius:9px;font-size:12px}.prep-money-summary strong{font-size:18px}.prep-stop{display:flex;justify-content:space-between;gap:14px;align-items:center;padding:14px 0;border-bottom:1px solid var(--brand-border)}.prep-stop:last-child{border:0}.prep-stop>div{min-width:0}.prep-stop h4{margin-top:0}.prep-stop-actions{display:flex;flex-direction:column;gap:6px;flex:0 0 150px}.prep-stop p{font-size:12px}.prep-dialog{border:2px solid var(--brand-primary);border-radius:12px;background:var(--brand-surface);padding:16px;margin:16px 0;scroll-margin-top:110px}.prep-dialog-top{display:flex;justify-content:flex-end;margin-bottom:8px}.prep-dialog form{display:grid;gap:13px;max-width:760px;margin:auto}.prep-dialog h3{margin:0}.prep-dialog p{margin:0}.prep-document-actions{display:flex;gap:8px;flex-wrap:wrap}.prep-document-actions button{flex:1 1 150px}.prep-delivery-line{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;padding:12px 0;border-bottom:1px solid var(--brand-border)}.prep-delivery-line>strong,.prep-delivery-line>.prep-reviewed{grid-column:1/-1}
@media(max-width:1000px){.prep-counts{grid-template-columns:repeat(4,minmax(0,1fr))}.prep-filters{grid-template-columns:repeat(3,minmax(0,1fr))}.prep-cards{grid-template-columns:repeat(2,minmax(0,1fr))}.prep-item{grid-template-columns:2fr 1fr 1fr}.prep-item>.prep-reviewed{grid-column:1/-1}}
@media(max-width:600px){.prep-scroll-hint{display:block}.preparation-center h2{font-size:22px}.preparation-center h3{font-size:18px}.prep-panel{padding:10px}.prep-filters{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;padding:10px}.prep-filter-actions{grid-column:1/-1}.prep-counts{gap:5px}.prep-count{padding:8px}.prep-count strong{font-size:21px}.prep-count span{font-size:10px}.prep-main-actions{gap:5px}.prep-main-actions button{padding:8px 5px;font-size:12px;min-height:52px}.prep-selection{gap:4px}.prep-selection strong{flex:1 1 100%}.prep-navigation{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.prep-cards{grid-template-columns:minmax(0,1fr)}.prep-header{align-items:center}.prep-header>button{padding:8px;font-size:12px}.prep-section-head{flex-direction:column}.prep-section-head>button{width:100%}.prep-orders thead{display:none}.prep-orders tbody{display:block}.prep-orders tr{display:grid;grid-template-columns:44px minmax(0,1fr) minmax(0,1fr);padding:10px 0;border-bottom:1px solid var(--brand-border);gap:5px}.prep-orders td{display:block;border:0;padding:4px;font-size:12px}.prep-orders td:first-child{grid-column:1;grid-row:1/4}.prep-orders td:nth-child(2){grid-column:2/-1}.prep-orders td:nth-child(3){grid-column:2/-1}.prep-orders td:nth-child(4){grid-column:2}.prep-orders td:nth-child(5){grid-column:3;text-align:right}.prep-orders td:nth-child(6){grid-column:2/-1}.prep-orders td:nth-child(6) small{display:inline-block;margin:4px}.prep-consolidated{min-width:590px!important}.prep-table-wrap{overscroll-behavior-x:contain}.prep-item{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.prep-item>div{grid-column:1/-1}.prep-item>.prep-reviewed{grid-column:1/-1}.prep-stop{display:block}.prep-stop-actions{display:flex;flex-direction:row;flex-wrap:wrap;margin-top:12px}.prep-stop-actions button{flex:1 1 130px}.prep-dialog{padding:10px}.prep-money-summary>span{flex:1 1 115px}.prep-money-summary strong{font-size:16px}.prep-batch-actions button{flex:1 1 130px}.prep-pagination{gap:6px}.prep-pagination button{padding:8px;font-size:12px}}
@media print{.preparation-center button,.prep-navigation,.prep-filters,.prep-selection,.prep-dialog-top{display:none!important}.prep-panel{border:0}.prep-table-wrap{overflow:visible;border:0}.preparation-center table{font-size:10px}.preparation-center tr{break-inside:avoid}}

.prep-substitution-note{font-size:12px;padding:8px;background:var(--brand-secondary);border-left:3px solid var(--brand-primary);border-radius:4px}
