.warehouse-page{align-items:start}.warehouse-cabinet{width:min(1440px,100%);margin:0 auto}.warehouse-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:24px}.warehouse-heading h1{max-width:none;font-family:Inter,system-ui,sans-serif;font-size:clamp(34px,4vw,54px)}.warehouse-heading p{margin:10px 0 0;color:var(--muted)}.warehouse-profile{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:26px 0}.warehouse-profile div{padding:16px 18px;border:1px solid var(--line);border-radius:14px;background:rgba(255,255,255,.9)}.warehouse-profile dt{color:var(--muted);font-size:12px;font-weight:800;text-transform:uppercase;letter-spacing:.08em}.warehouse-profile dd{margin:5px 0 0;font-weight:750}.warehouse-tabs{display:flex;gap:8px;margin:0 0 18px;border-bottom:1px solid var(--line)}.warehouse-tab{margin:0 0 -1px;padding:12px 16px;border:0;border-bottom:3px solid transparent;background:transparent;color:var(--muted);font:inherit;font-weight:800;cursor:pointer}.warehouse-tab.is-active{border-bottom-color:var(--green);color:var(--green)}.warehouse-panel[hidden]{display:none}.warehouse-tools{display:grid;grid-template-columns:minmax(280px,2fr) minmax(260px,1fr) auto;align-items:end;gap:12px;padding:16px;border:1px solid var(--line);border-radius:14px;background:var(--white)}.warehouse-tools label{font-size:13px;font-weight:750}.warehouse-tools input,.warehouse-tools select,.warehouse-delivery-context select{width:100%;min-height:46px;margin-top:6px;padding:10px 12px;border:1px solid #bfc9c3;border-radius:9px;background:#fff;color:var(--ink);font:inherit}.warehouse-section-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:16px}.warehouse-section-heading h2{margin:4px 0 0;font-size:clamp(28px,3vw,40px)}.warehouse-section-heading p{margin:8px 0 0;color:var(--muted)}.warehouse-delivery-context{display:grid;grid-template-columns:minmax(240px,1fr) repeat(2,minmax(240px,1fr));gap:12px;padding:16px;border:1px solid var(--line);border-radius:14px;background:var(--white)}.warehouse-delivery-context>div,.warehouse-delivery-context label{font-size:13px;font-weight:750}.warehouse-delivery-context>div{display:flex;flex-direction:column;justify-content:center;gap:8px}.warehouse-delivery-context span{color:var(--muted)}.warehouse-delivery-context strong{font-size:16px}.warehouse-bulk{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:14px 0}.warehouse-bulk strong{margin-right:auto}.warehouse-bulk .button{padding:8px 11px;font-size:13px}.warehouse-message{min-height:46px;margin:10px 0 16px;padding:11px 14px;border:1px solid var(--line);border-radius:10px;color:var(--muted);background:#f7faf8}.warehouse-message.is-error{border-color:#efb6b2;color:var(--error);background:#fff1f0}.warehouse-table-wrap{overflow:auto;border:1px solid var(--line);border-radius:14px;background:var(--white);box-shadow:0 10px 30px rgba(18,49,39,.06)}.warehouse-table{width:100%;min-width:980px;border-collapse:collapse}.warehouse-delivery-table{min-width:760px}.warehouse-table th,.warehouse-table td{padding:13px 12px;border-bottom:1px solid #e8ece9;text-align:left;vertical-align:middle}.warehouse-table th{position:sticky;top:0;z-index:1;background:#f8faf8;color:var(--muted);font-size:12px;text-transform:uppercase;letter-spacing:.04em}.warehouse-table tbody tr:last-child td{border-bottom:0}.warehouse-table tbody tr.is-dirty{background:#fffaf0}.warehouse-table input[type=checkbox]{width:20px;height:20px;accent-color:var(--green)}.warehouse-product{font-weight:750}.warehouse-state{display:inline-block;padding:5px 9px;border-radius:99px;background:#eef2ef;font-size:12px;font-weight:800}.warehouse-state.available{color:#176139;background:#e3f2e8}.warehouse-state.unconfigured{color:#755916;background:#fff0d8}.warehouse-reset{min-height:34px;padding:5px 8px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--ink);font:inherit;font-size:12px;font-weight:700;cursor:pointer}.warehouse-savebar{position:sticky;bottom:14px;display:flex;align-items:center;justify-content:space-between;gap:20px;margin-top:16px;padding:14px 16px;border:1px solid var(--line);border-radius:14px;background:rgba(255,255,255,.96);box-shadow:0 12px 35px rgba(18,49,39,.14)}.warehouse-savebar .button{min-width:220px}.warehouse-savebar .button:disabled{cursor:not-allowed;opacity:.55}@media(max-width:900px){.warehouse-profile{grid-template-columns:1fr}.warehouse-tools,.warehouse-delivery-context{grid-template-columns:1fr}.warehouse-heading{align-items:flex-start}.warehouse-savebar{bottom:8px}.warehouse-savebar .button{min-width:0}}@media(max-width:600px){.warehouse-heading,.warehouse-section-heading{display:grid}.warehouse-bulk strong{width:100%}.warehouse-savebar{align-items:stretch;flex-direction:column}.warehouse-savebar .button{width:100%}}
.warehouse-savebar[hidden]{display:none}

.warehouse-tab-archive{margin-left:auto;color:#7b8580}.warehouse-summary-list{display:grid;gap:12px}.warehouse-summary-card{padding:18px;border:1px solid var(--line);border-radius:14px;background:#fff;box-shadow:0 8px 24px rgba(18,49,39,.06)}.warehouse-summary-list.is-archive .warehouse-summary-card{background:#f7f8f7;box-shadow:none}.warehouse-summary-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}.warehouse-summary-head>div{display:flex;align-items:center;flex-wrap:wrap;gap:9px}.warehouse-summary-head strong{font-size:17px}.warehouse-summary-version,.warehouse-summary-status{display:inline-flex;padding:5px 9px;border-radius:999px;font-size:12px;font-weight:800}.warehouse-summary-version{color:#4f5c56;background:#edf1ef}.warehouse-summary-status.is-pending{color:#755916;background:#fff0d8}.warehouse-summary-status.is-in_work{color:#176139;background:#e3f2e8}.warehouse-summary-status.is-rejected{color:#8a2d25;background:#fff0ef}.warehouse-summary-meta{margin:10px 0;color:var(--muted)}.warehouse-summary-reason{margin:10px 0;padding:10px 12px;border-left:3px solid #b64740;background:#fff4f3;color:#7d2a25}.warehouse-summary-actions{display:flex;flex-wrap:wrap;gap:9px;margin-top:14px}.warehouse-summary-actions .button{min-width:160px;text-align:center}.warehouse-summary-actions a[aria-disabled=true]{pointer-events:none;opacity:.55}.button-danger{border-color:#d98e88;color:#8a2d25;background:#fff}.warehouse-summary-empty{padding:28px;border:1px dashed var(--line);border-radius:14px;color:var(--muted);background:#fff;text-align:center}.warehouse-guard-dialog{width:min(500px,calc(100% - 32px));padding:0;border:0;border-radius:18px;color:var(--ink);box-shadow:0 26px 80px rgba(10,30,23,.35)}.warehouse-guard-dialog::backdrop{background:rgba(18,30,25,.62);backdrop-filter:blur(6px)}.warehouse-guard-dialog form{position:relative;display:grid;gap:15px;padding:28px}.warehouse-guard-dialog h2,.warehouse-guard-dialog p{margin:0}.warehouse-guard-dialog label{display:grid;gap:7px;font-weight:750}.warehouse-guard-dialog input{min-height:46px;padding:10px 12px;border:1px solid #bfc9c3;border-radius:9px;font:inherit}.warehouse-dialog-close{position:absolute;top:12px;right:14px;width:38px;height:38px;border:0;border-radius:50%;background:#edf2ef;color:var(--ink);font-size:27px;line-height:1;cursor:pointer}.warehouse-guard-dialog.is-success h2{color:#176139}.warehouse-guard-dialog [hidden]{display:none!important}@media(max-width:760px){.warehouse-tabs{overflow:auto}.warehouse-tab{white-space:nowrap}.warehouse-tab-archive{margin-left:0}.warehouse-summary-head{display:grid}.warehouse-summary-actions .button{width:100%}}
.warehouse-summary-partner-id{color:var(--green);font-size:13px;font-weight:800}.warehouse-preview-dialog{width:min(920px,calc(100% - 32px));max-height:calc(100vh - 32px);padding:0;border:0;border-radius:18px;color:var(--ink);box-shadow:0 26px 80px rgba(10,30,23,.35)}.warehouse-preview-dialog::backdrop{background:rgba(18,30,25,.62);backdrop-filter:blur(6px)}.warehouse-preview-shell{position:relative;display:grid;gap:16px;padding:28px}.warehouse-preview-shell h2,.warehouse-preview-shell p{margin:0}.warehouse-preview-meta{margin-top:7px!important;color:var(--muted)}.warehouse-preview-message{min-height:22px;color:var(--muted)}.warehouse-preview-message.is-error{color:var(--error)}.warehouse-preview-message.is-success{color:#176139}.warehouse-preview-table-wrap{overflow:auto;border:1px solid var(--line);border-radius:12px}.warehouse-preview-table{width:100%;min-width:660px;border-collapse:collapse}.warehouse-preview-table th,.warehouse-preview-table td{padding:12px;border-bottom:1px solid #e8ece9;text-align:right;vertical-align:top}.warehouse-preview-table th:first-child,.warehouse-preview-table td:first-child{text-align:left}.warehouse-preview-table thead th{background:#f7faf8;color:var(--muted);font-size:12px;text-transform:uppercase;letter-spacing:.04em}.warehouse-preview-table tbody th{font-weight:700}.warehouse-preview-table tfoot th,.warehouse-preview-table tfoot td{border-bottom:0;background:#eef5f1;font-weight:800}.warehouse-preview-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:10px}.warehouse-preview-actions .button{min-width:190px}.warehouse-preview-dialog [hidden]{display:none!important}.warehouse-receipt-dialog{width:min(1000px,calc(100% - 32px))}.warehouse-receipt-image,.warehouse-receipt-pdf{display:block;width:100%;height:min(70vh,760px);border:1px solid var(--line);border-radius:12px;background:#f7faf8}.warehouse-receipt-image{object-fit:contain}@media(max-width:600px){.warehouse-preview-shell{padding:22px 16px 16px}.warehouse-preview-shell>div:first-of-type{padding-right:38px}.warehouse-preview-actions{display:grid}.warehouse-preview-actions .button{width:100%;min-width:0}.warehouse-receipt-image,.warehouse-receipt-pdf{height:65vh}}
.warehouse-preview-post{max-height:56vh;overflow:auto;margin:0;padding:20px;border:1px solid var(--line);border-radius:12px;background:#fff;color:var(--ink);font:16px/1.5 Arial,sans-serif;white-space:pre-wrap;overflow-wrap:anywhere;user-select:text}
.warehouse-copy-toast{position:fixed;z-index:4;left:50%;bottom:32px;transform:translateX(-50%);padding:13px 20px;border-radius:12px;background:#176139;color:#fff;box-shadow:0 12px 34px rgba(10,30,23,.32);font-weight:800;pointer-events:none}
.warehouse-summary-status.is-rejection_notification_pending{color:#755916;background:#fff0d8}.warehouse-archive-group{margin-top:24px}.warehouse-archive-group h3{margin:0 0 8px;font-size:21px}.warehouse-archive-group>p{margin:0 0 10px;color:var(--muted)}
.warehouse-summary-refresh.is-update-available{border-color:#b96d12;color:#fff;background:#b96d12;box-shadow:0 0 0 3px rgba(185,109,18,.18)}.warehouse-summary-refresh.is-update-available:hover{border-color:#99580d;background:#99580d}
.warehouse-tab.is-update-available{border-radius:9px 9px 0 0;color:#99580d;background:#fff0d8}.warehouse-tab.is-update-available::after{content:" •";color:#b96d12}.warehouse-tab.is-active.is-update-available{border-bottom-color:#b96d12;color:#99580d}
.warehouse-preview-message.is-error{padding:10px 12px;border:1px solid #efb6b2;border-radius:10px;color:var(--error);background:#fff1f0;font-weight:750}
/* Новые окна уведомления и фиксации отправки. */
.warehouse-cabinet { min-width: 0; }
#warehouseTelegramText,
#warehouseShipmentTracking,
#warehouseShipmentComment {
  box-sizing: border-box;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}
#warehouseTelegramText, #warehouseShipmentComment { resize: vertical; }
#shippingNotificationFilters { margin-bottom: 16px; border: 1px solid var(--line); border-radius: 10px; }
#shippingNotificationFilters label { display: inline-flex; align-items: center; gap: 6px; margin: 8px 12px 8px 0; }
#shippingNotificationFilters input { width: auto; }
.warehouse-summary-card.is-split { border-left: 6px solid #174b35; }
.warehouse-shipment-part { background: #edf7d9; border: 1px solid #b8d992; border-radius: 10px; padding: 12px; margin: 10px 0; color: #173b2a; }
.warehouse-shipment-quantity { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px; align-items: center; margin: 10px 0; }
.warehouse-shipment-quantity input { width: 90px; }
.warehouse-print-frame { display: none; }
body.warehouse-shipment-print { font: 14px Arial, sans-serif; margin: 24px; color: #111; background: white; }
.warehouse-shipment-print table { width: 100%; border-collapse: collapse; }
.warehouse-shipment-print td, .warehouse-shipment-print th { border: 1px solid #777; padding: 8px; text-align: left; }
.warehouse-shipment-print h1 { font-size: 22px; }
@media print { body.warehouse-shipment-print { margin: 0; } }
.individual-order-reports { border-top:1px solid var(--ui-line,#ddd); margin-top:20px; padding-top:16px; font-size:16px; }
.individual-order-reports > section { border:1px solid var(--ui-line,#ddd); padding:14px; border-radius:10px; margin:14px 0; }
.individual-order-reports .button { margin:4px 8px 4px 0; }
.individual-shipment-form { display:grid; gap:14px; margin-top:20px; }
.individual-shipment-row { display:grid; grid-template-columns:minmax(0,2fr) repeat(2,minmax(0,1fr)); align-items:center; gap:14px; padding:12px; border:1px solid var(--ui-line,#ddd); border-radius:10px; }
.individual-shipment-form label { display:flex; flex-direction:column; gap:6px; }
.individual-shipment-form input,.individual-shipment-form textarea { box-sizing:border-box; width:100%; min-height:44px; padding:10px; font:inherit; }
@media(max-width:640px) { .individual-shipment-row { grid-template-columns:1fr 1fr; }.individual-shipment-row strong { grid-column:1/-1; } }
.warehouse-report-filters{display:flex;flex-wrap:wrap;align-items:flex-end;gap:14px;margin:20px 0}.warehouse-report-filters label{display:grid;gap:6px;max-width:100%;font-weight:700}.warehouse-report-filters input,.warehouse-report-filters select{min-width:0;max-width:100%;padding:10px 12px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--ink);font:inherit}.warehouse-report-section{margin-top:14px;padding-top:12px;border-top:1px solid var(--line);min-width:0}.warehouse-report-section h3{font-size:22px;margin:0 0 8px}.warehouse-report-section h4{font-size:18px;margin:20px 0 10px}.warehouse-report-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-bottom:10px}.warehouse-report-totals>div{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 8px;padding:9px 12px;border:1px solid var(--line);border-radius:12px;background:#fff;overflow-wrap:anywhere}.warehouse-report-totals span,.warehouse-report-totals small{color:var(--muted)}.warehouse-report-totals strong{font-size:18px}.warehouse-report-table{min-width:680px}.warehouse-report-table th,.warehouse-report-table td{white-space:normal;overflow-wrap:anywhere}.warehouse-report-table th:not(:first-child),.warehouse-report-table td:not(:first-child){text-align:right}.warehouse-report-table th:first-child,.warehouse-report-table td:first-child{min-width:160px}.warehouse-report-empty{padding:18px;border:1px dashed var(--line);border-radius:12px;background:#fff;color:var(--muted)}.warehouse-report-documents{margin-top:6px}.warehouse-report-documents>summary{cursor:pointer;font-weight:700;padding:6px 0}.warehouse-report-warning{margin:8px 0;padding:7px 10px;background:#fff7df;color:#654e15;border:1px solid #ddce9d;border-radius:10px;overflow-wrap:anywhere}.warehouse-report-title h3{margin:22px 0 6px}.warehouse-report-title p{margin:0;color:var(--muted)}
.warehouse-report-shipment-dialog{width:min(720px,calc(100% - 32px))}.warehouse-report-shipment-fields{display:grid;grid-template-columns:155px minmax(0,1fr);gap:12px 18px;margin:20px 0 26px}.warehouse-report-shipment-fields dt{color:var(--muted)}.warehouse-report-shipment-fields dd{margin:0;font-weight:600;overflow-wrap:anywhere;white-space:pre-wrap;user-select:text}.warehouse-report-shipment-dialog .warehouse-preview-actions svg{vertical-align:middle;margin-right:7px}@media(max-width:600px){.warehouse-report-shipment-fields{grid-template-columns:1fr;gap:5px}.warehouse-report-shipment-fields dd{margin-bottom:10px}}
.warehouse-report-shipment-dialog{max-height:calc(100dvh - 32px);padding:0}.warehouse-report-shipment-dialog .warehouse-preview-shell{max-height:calc(100dvh - 32px);overflow-y:auto;position:relative}.warehouse-report-shipment-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;position:sticky;top:0;background:#fff;z-index:1}.warehouse-report-shipment-heading h2{margin:0;font-size:24px}.warehouse-report-shipment-dialog .warehouse-preview-close{flex:0 0 36px;display:grid;place-items:center;width:36px;height:36px;padding:0;border:0;border-radius:8px;background:var(--surface-soft,#edf3ef);color:var(--ink);font:24px/1 Arial,sans-serif;cursor:pointer}.warehouse-report-shipment-dialog .warehouse-message:empty{display:none}
@media(max-width:600px){.warehouse-report-totals{grid-template-columns:1fr}.warehouse-report-filters>*{width:100%;min-width:0}.warehouse-report-filters .action-help-wrap>.button{width:100%}.warehouse-report-totals strong{font-size:20px}}
@media print{body.warehouse-report-print{background:#fff!important;color:#000!important}body.warehouse-report-print>header,body.warehouse-report-print>footer,body.warehouse-report-print>dialog,body.warehouse-report-print .warehouse-tabs,body.warehouse-report-print .warehouse-cabinet> :not(#monthlyReportPanel),body.warehouse-report-print main> :not(#cabinetView),body.warehouse-report-print .warehouse-report-filters,body.warehouse-report-print #monthlyReportMessage,body.warehouse-report-print .action-help-icon{display:none!important}body.warehouse-report-print main,body.warehouse-report-print #cabinetView,body.warehouse-report-print #monthlyReportPanel{width:100%!important;max-width:none!important;margin:0!important;padding:0!important;box-shadow:none!important}body.warehouse-report-print .warehouse-report-table{min-width:0;width:100%;font-size:10px}body.warehouse-report-print .warehouse-report-table th:first-child,body.warehouse-report-print .warehouse-report-table td:first-child{min-width:0}body.warehouse-report-print .warehouse-table-wrap{overflow:visible}body.warehouse-report-print .warehouse-report-totals{grid-template-columns:repeat(3,minmax(0,1fr))}body.warehouse-report-print .warehouse-report-documents{display:none}body.warehouse-report-print .warehouse-report-totals>div,body.warehouse-report-print tr{break-inside:avoid}}

.warehouse-report-explanation{font-size:14px;color:var(--muted);margin:6px 0}.warehouse-report-explanation>summary{cursor:pointer}.warehouse-report-explanation p{margin:6px 0;line-height:1.4}

.warehouse-shipment-print{overflow-wrap:anywhere}.warehouse-shipment-print table{table-layout:fixed}.warehouse-shipment-print th:first-child{width:50%}.warehouse-shipment-print thead{display:table-header-group}.warehouse-shipment-print tr,.warehouse-shipment-print .signatures{break-inside:avoid}
@page warehouse-shipment{size:A4;margin:15mm 11mm 20mm}body.warehouse-shipment-print{page:warehouse-shipment}

.warehouse-shipment-print img{display:block;width:180px;height:60px;object-fit:contain;object-position:left center;margin:0 0 6px}
.warehouse-shipment-actions{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px;margin-top:12px}
.individual-order-reports .warehouse-shipment-actions .button{margin:0}
.warehouse-partial-label{display:block;color:#b42318;margin:.5rem 0;font-weight:800}
.warehouse-remainder-section{margin:1rem 0;padding:1rem;border:1px solid #d5a548;border-left:4px solid #b42318;border-radius:10px;background:#fff8eb;color:#173c36}
.warehouse-order-documents{margin-top:1rem;border-top:1px solid #b9d3cd;padding-top:.75rem}
.warehouse-order-documents summary{cursor:pointer;margin-bottom:.75rem}
.warehouse-physical-confirm{display:flex;gap:.65rem;align-items:flex-start;padding:1rem;background:#fff3e0;color:#173c36;border:1px solid #c69a47;border-radius:8px;margin:1rem 0}
.warehouse-physical-confirm input{width:auto;flex:none;margin-top:.25rem}
#warehouseShipmentForm fieldset{border:1px solid #9bbdb3;border-radius:8px;margin:1rem 0;padding:1rem;min-width:0}
#warehouseShipmentForm fieldset button{margin:.4rem .4rem 0 0}
#warehouseShipmentForm h2{padding-right:2rem;overflow-wrap:anywhere}
#warehouseShipmentDialog.warehouse-shipment-choice{width:min(580px,calc(100% - 24px));border-radius:10px}
#warehouseShipmentDialog.warehouse-shipment-choice #warehouseShipmentForm{gap:0;padding:0;background:var(--ui-panel,#fff);color:var(--ui-ink,var(--ink))}
#warehouseShipmentDialog.warehouse-shipment-choice h2{margin:0;padding:20px 70px 20px 20px;border-bottom:1px solid var(--ui-line,var(--line));font-size:16px;line-height:1.4}
#warehouseShipmentDialog.warehouse-shipment-choice .warehouse-dialog-close{top:10px;right:14px;border-radius:6px;width:42px;height:42px}
.warehouse-shipment-choices{display:flex;flex-wrap:wrap;gap:12px;padding:24px 20px}
#warehouseShipmentForm .warehouse-shipment-choices>.button{display:flex;flex:1 1 220px;flex-direction:column;align-items:flex-start;justify-content:center;gap:4px;margin:0;padding:14px;white-space:normal;text-align:left;line-height:1.5}
.warehouse-shipment-choices span{font-size:13px}
.warehouse-shipment-choice-footer{padding:14px 20px;border-top:1px solid var(--ui-line,var(--line))}
#warehouseShipmentDialog.warehouse-shipment-choice [role=status]:empty{display:none}
#warehouseShipmentDialog.warehouse-shipment-choice [role=status]:not(:empty){padding:0 20px 20px;overflow-wrap:anywhere}
@media(max-width:420px){.warehouse-shipment-choices{padding:18px 14px}.warehouse-shipment-choice-footer{padding:14px}#warehouseShipmentDialog.warehouse-shipment-choice h2{padding-left:14px}#warehouseShipmentForm .warehouse-shipment-choices>.button{min-height:44px}}
.warehouse-shipment-quantity{display:grid;grid-template-columns:minmax(0,1.2fr) repeat(2,minmax(0,1fr));gap:.75rem;align-items:start;margin:1rem 0}
.warehouse-shipment-quantity label,#warehouseShipmentForm>label{display:flex;flex-direction:column;gap:.4rem;min-width:0}
.warehouse-remainder-table{width:100%;border-collapse:collapse;table-layout:fixed}
.warehouse-remainder-table caption{text-align:left;font-weight:700;padding-bottom:8px}
.warehouse-remainder-table th,.warehouse-remainder-table td{padding:8px 6px;border-bottom:1px solid var(--line);text-align:right;overflow-wrap:anywhere}
.warehouse-remainder-table th:first-child{width:48%;text-align:left}
.warehouse-remainder-table thead th{font-size:.85em;color:var(--muted)}
.warehouse-quantity-error{color:var(--error,#b42318);font-size:.85em;line-height:1.3}
#warehouseShipmentForm input[aria-invalid=true]{border-color:var(--error,#b42318)}
#warehouseShipmentForm>label{margin:1rem 0}
#warehouseShipmentForm input,#warehouseShipmentForm textarea{box-sizing:border-box;min-width:0;min-height:44px;width:100%;padding:.65rem;border:1px solid var(--line,#b9d3cd);border-radius:8px;font:inherit;color:inherit;background:transparent}
#warehouseShipmentForm textarea{min-height:5rem;resize:vertical}
@media(max-width:600px){#warehouseShipmentForm .warehouse-preview-actions{display:flex;flex-direction:column;align-items:stretch}.warehouse-shipment-quantity{grid-template-columns:1fr}.warehouse-remainder-section{padding:.75rem}}

/* Compact shipment cards for summary and independent orders. */
.warehouse-shipment-part{padding:9px 10px;margin:8px 0;line-height:1.22}
.warehouse-shipment-part>p{margin:4px 0;line-height:1.22}
.warehouse-shipment-part>.warehouse-partial-label{display:block;margin:0 0 4px}
.warehouse-shipment-actions{gap:8px;margin-top:8px}
@media(min-width:1000px){
 .warehouse-shipment-part>.warehouse-shipment-actions{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);align-items:stretch;column-gap:8px}
 .warehouse-shipment-part>.warehouse-shipment-actions>:is(.button,.action-help-wrap){min-width:0;max-width:100%;margin:0}
 .warehouse-shipment-part>.warehouse-shipment-actions .button{width:100%!important;min-width:0!important;height:100%;white-space:normal;line-height:1.15;padding-inline:6px}
}

.warehouse-shipment-progress{display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;margin:6px 0;font-size:12px;color:var(--muted)}
.warehouse-shipment-markers{display:flex;flex-wrap:wrap;gap:6px}
.warehouse-shipment-marker{position:relative;width:32px;height:32px;padding:0;border:2px solid;border-radius:6px;cursor:pointer;font:inherit;flex:none}
.warehouse-shipment-marker small{position:absolute;top:1px;left:3px;font-size:10px;line-height:1}
.warehouse-shipment-marker span{display:block;font-size:21px;line-height:28px;text-align:center}
.warehouse-shipment-marker.is-partial{border-color:#b42318;background:#b42318;color:#fff}
.warehouse-shipment-marker.is-closing{border-color:#18724c;background:#18724c;color:#fff}
.warehouse-shipment-marker.is-prepared{border-color:#64748b;background:transparent;color:#475569}
.warehouse-shipment-marker:focus-visible,.warehouse-shipment-target:focus-visible{outline:3px solid #117a72;outline-offset:3px}
/* Correction comparisons keep each product and its changed quantities together. */
.shipment-adjustment-status{margin:8px 0;padding:8px 10px;border:1px solid var(--ui-line,#ccd9d4);border-radius:6px}
.shipment-adjustment-status p{margin:0 0 6px}
.shipment-adjustment-status.is-pending{background:#fff1d6;color:#593c00;border-left:3px solid #b06b00}

.shipment-adjustment-history{background:var(--ui-panel,#fff);border-color:var(--ui-line,#ccd9d4)}

/* Scoped controls for the read-only warehouse filters. */
.warehouse-filter-dialog{max-height:90dvh;overflow:auto}.warehouse-filter-dialog fieldset{display:grid;gap:8px;min-width:0;border:1px solid var(--line);border-radius:8px}.warehouse-filter-dialog fieldset label{display:flex;align-items:center;gap:8px;font-weight:400}.warehouse-filter-dialog fieldset input{min-height:0;width:18px;height:18px;padding:0;flex:none}.warehouse-filter-pages[hidden]{display:none}.warehouse-filter-controls button[aria-pressed="true"]{outline:2px solid currentColor;outline-offset:2px}
.warehouse-compact-actions{display:flex;align-items:center;gap:.5rem;flex-wrap:wrap}
.warehouse-actions-menu{position:relative;display:inline-block;max-width:100%;color:var(--ui-ink,#203c3b)}
.warehouse-actions-menu>summary{list-style:none;cursor:pointer;white-space:nowrap;border:1px solid var(--workspace-accent,#167e70)}
.warehouse-actions-menu>summary::-webkit-details-marker{display:none}
.warehouse-actions-menu-panel{position:absolute;right:0;top:calc(100% + 5px);z-index:80;box-sizing:border-box;width:22rem;height:fit-content;min-height:0;max-width:calc(100vw - 3rem);padding:.4rem;border:1px solid var(--workspace-accent,#167e70);border-radius:7px;background:var(--ui-panel,#fff);box-shadow:0 5px 16px #0a272b26;overflow:auto;overscroll-behavior:contain;text-align:left;font-weight:400}
.warehouse-actions-menu.opens-up>.warehouse-actions-menu-panel{top:auto;bottom:calc(100% + 5px)}
.warehouse-actions-menu-panel>.button,.warehouse-actions-menu-panel>button,.warehouse-actions-menu-panel>a{display:block;box-sizing:border-box;width:100%;margin:0;text-align:left;white-space:normal;background:transparent;color:var(--ui-ink,#203c3b);border:0;border-radius:4px;box-shadow:none}
.warehouse-actions-menu-panel>.button:hover,.warehouse-actions-menu-panel>button:hover,.warehouse-actions-menu-panel>a:hover{background:var(--ui-soft,#e9f3ef)}
.warehouse-actions-menu-panel details{margin:.25rem 0;padding:.25rem;border:0}
.warehouse-actions-menu-panel details>summary{padding:.5rem;cursor:pointer;color:var(--ui-ink,#203c3b)}
.warehouse-actions-menu-panel p{white-space:normal;overflow-wrap:anywhere}
.warehouse-actions-menu-panel [hidden]{display:none!important}
.warehouse-actions-menu:not([open])>.warehouse-actions-menu-panel{display:none}
.warehouse-actions-menu[hidden]{display:none!important}
.warehouse-preview-actions>.warehouse-actions-menu,.warehouse-summary-actions>.warehouse-actions-menu{margin-left:auto}
.warehouse-summary-actions:has(>.warehouse-actions-menu){align-items:flex-start}
/* Compact action rows and separated menu items override the existing shipment grid. */
:root[data-color-profile] body.workspace-cabinet :is(.warehouse-summary-actions,.warehouse-shipment-actions,.warehouse-preview-actions){display:flex;flex-wrap:wrap;align-items:flex-start;gap:8px;grid-auto-flow:initial;grid-auto-columns:initial}
:root[data-color-profile] body.workspace-cabinet #warehouseShipmentForm .warehouse-preview-actions{flex-direction:row;align-items:flex-start}
:root[data-color-profile] body.workspace-cabinet :is(.warehouse-summary-actions,.warehouse-shipment-actions,.warehouse-preview-actions,.warehouse-primary-actions)>:is(.button,.action-help-wrap,.warehouse-actions-menu){flex:0 1 auto;width:auto!important;min-width:0!important;max-width:100%;margin:0}
:root[data-color-profile] body.workspace-cabinet :is(.warehouse-summary-actions,.warehouse-shipment-actions,.warehouse-preview-actions,.warehouse-primary-actions)>.action-help-wrap>.button{width:auto!important;min-width:0!important;max-width:100%;height:auto;white-space:normal;padding:8px 12px}
.warehouse-primary-actions{display:contents}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-actions:has(>.warehouse-primary-actions>.action-help-wrap){padding-top:18px}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu>summary{width:auto!important;min-width:0!important;max-width:100%;padding:8px 12px;background:var(--ui-panel,#fff);color:var(--ui-ink,#203c3b);border:1px solid var(--ui-primary,#167e70)}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel{display:flex;flex-direction:column;gap:6px;padding:8px;border-color:var(--ui-primary,#167e70)}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel :is(.button,button):not(.cabinet-help-open):not(.action-help-icon){display:block;box-sizing:border-box;width:100%!important;min-width:0!important;max-width:100%;height:auto;min-height:36px;padding:8px 10px;margin:0;white-space:normal;text-align:left;background:var(--ui-panel,#fff);color:var(--ui-ink,#203c3b);border:1px solid var(--ui-line,#d4e2dd);border-radius:4px;box-shadow:none}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel :is(.button,button):not(.cabinet-help-open):not(.action-help-icon):hover{background:var(--ui-soft,#e9f3ef);border-color:var(--ui-primary,#167e70)}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel .action-help-wrap{display:block;box-sizing:border-box;flex:0 0 auto;width:100%;min-width:0;max-width:100%;margin:0}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel>details+details{padding-top:8px;border-top:1px solid var(--ui-line,#d4e2dd)}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu:not([open])>.warehouse-actions-menu-panel{display:none}
:root[data-color-profile] body.workspace-cabinet .warehouse-actions-menu-panel details>:is(.button,.action-help-wrap){margin-top:6px!important}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-actions>.warehouse-actions-menu{margin-left:auto}
:root[data-color-profile] body.workspace-cabinet .warehouse-preview-actions>.warehouse-actions-menu{margin-left:0}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head>div{display:grid;align-items:start;gap:4px;min-width:0;flex:1}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head .leader-summary-identity{font:inherit;line-height:1.45}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head>div>p{margin:0;font:inherit;line-height:1.45;overflow-wrap:anywhere}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head strong{font:inherit;font-weight:700}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-meta{font:inherit;line-height:1.45}

.warehouse-actions-menu-panel>*{flex-shrink:0}
.warehouse-subscription-settings{display:grid;gap:12px;min-width:0;margin:16px 0;padding:18px;border:1px solid var(--ui-line,var(--line));border-radius:12px;background:var(--ui-panel,#fff)}
.warehouse-subscription-settings :is(h3,p){margin:0}
.warehouse-subscription-settings label{display:grid;gap:7px;min-width:0}
.warehouse-subscription-settings input{box-sizing:border-box;width:100%;min-width:0;max-width:100%;padding:10px 12px;border:1px solid var(--ui-line,var(--line));border-radius:8px;color:var(--ui-ink,var(--ink));background:var(--ui-panel,#fff);font:inherit}
.warehouse-inline-order-text{white-space:pre-wrap;overflow-wrap:anywhere;margin:12px 0;line-height:1.5}
.warehouse-inline-preview{min-width:0;overflow-wrap:anywhere}
.warehouse-inline-preview>.button{display:block;margin-top:8px}
.warehouse-summary-head.compact-order-heading{align-items:center;justify-content:initial}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head.compact-order-heading>.order-compact-identity{display:flex;flex:1 1 360px;align-items:center;flex-wrap:wrap;gap:10px 20px}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head.compact-order-heading>.order-card-status{display:flex;flex:0 0 auto;align-items:center;gap:8px}
:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head.compact-order-heading>.warehouse-shipment-markers{display:flex;gap:6px;flex:0 0 auto;align-items:center;max-width:100%}
@media(max-width:600px){:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head.compact-order-heading>.order-compact-identity{flex-basis:calc(100% - 52px);flex-direction:column;align-items:flex-start}:root[data-color-profile] body.workspace-cabinet .warehouse-summary-head.compact-order-heading>.order-card-status{flex-basis:100%;width:100%}}

/* Compact warehouse header and settings. */
:root[data-color-profile] body.workspace-cabinet .warehouse-heading{display:flex;align-items:center;flex-wrap:wrap;gap:10px 16px;margin:0 0 12px}
:root[data-color-profile] body.workspace-cabinet .warehouse-heading .warehouse-profile{display:flex;align-items:center;flex-wrap:wrap;gap:8px 20px;margin:0;padding:0}
:root[data-color-profile] body.workspace-cabinet .warehouse-profile>div{display:flex;align-items:center;gap:6px}
:root[data-color-profile] body.workspace-cabinet .warehouse-profile dt{font-size:13px;text-transform:none;letter-spacing:0}
:root[data-color-profile] body.workspace-cabinet .warehouse-profile dd{margin:0;font-size:13px}
:root[data-color-profile] body.workspace-cabinet .warehouse-heading .actions{margin:0 0 0 auto;gap:8px}
.warehouse-heading>[hidden],.warehouse-profile>[hidden]{display:none!important}
#warehouseSettingsNavigation{display:grid;grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);align-items:start;gap:12px}
#warehouseSettingsNavigation[hidden]{display:none!important}
#warehouseSettingsNavigation>*{grid-column:1/-1;min-width:0}
#warehouseSettingsNavigation>.warehouse-panel:first-child{padding:12px;border-radius:8px}
#warehouseSettingsNavigation .warehouse-section-heading{align-items:center;gap:8px;margin:0 0 6px}
#warehouseSettingsNavigation .warehouse-section-heading h2{margin:0;font-size:18px}
#warehouseSettingsNavigation>.warehouse-panel:first-child>p{margin:0;font-size:13px;line-height:1.4}
#warehouseShippingSettings,#warehouseTelegramSubscription{display:grid;align-content:start;gap:8px;margin:0;padding:12px;border:1px solid #d4e2dd;border-radius:8px;background:#f5f8f7;color:#111;min-height:0}
#warehouseShippingSettings{grid-column:1}
#warehouseTelegramSubscription{grid-column:2}
#warehouseShippingSettings :is(h3,p,label),#warehouseTelegramSubscription :is(h3,p,label){margin:0;color:#111;line-height:1.4}
#warehouseShippingSettings h3,#warehouseTelegramSubscription h3{font-size:16px}
#warehouseShippingSettings :is(p,label),#warehouseTelegramSubscription :is(p,label){font-size:13px}
#warehouseShippingSettings label{display:flex;align-items:flex-start;gap:8px}
#warehouseRequireTracking{flex:none;width:18px;height:18px;min-height:18px;margin:0;accent-color:var(--workspace-accent,#167e70)}
#warehouseSettingsNavigation .button{width:auto!important;min-width:0;min-height:36px;height:auto;margin:0;padding:7px 12px;white-space:normal}
#warehouseShippingSettingsSave{justify-self:start}
#warehouseTelegramSubscription label{gap:4px}
#warehouseSubscriptionUrl{min-height:36px;padding:7px 10px;background:#fff;color:#111}
#warehouseTelegramSubscription .warehouse-preview-actions{display:flex;flex-wrap:wrap;gap:8px;margin:0}

/* Keep the sole More menu beside the fulfillment block on desktop. */
@media(min-width:761px){
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu:only-child){display:grid;grid-template-columns:minmax(0,1fr) max-content;gap:8px 12px;align-content:start}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu:only-child)>*{grid-column:1/-1;min-width:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu:only-child)>.order-fulfillment{grid-column:1;grid-row:2;margin:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu:only-child)>.warehouse-summary-actions{grid-column:2;grid-row:2;align-self:center;margin:0}
}
/* Mobile cards keep More beside the totals; primary actions follow below. */
@media screen and (max-width:760px){
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu){display:grid;grid-template-columns:minmax(0,1fr) max-content;gap:6px 8px;align-content:start}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu)>*{grid-column:1/-1;min-width:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card:has(>.warehouse-summary-actions>.warehouse-actions-menu)>.order-fulfillment{grid-column:1;grid-row:2;margin:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card>.warehouse-summary-actions:has(>.warehouse-actions-menu){display:contents}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card>.warehouse-summary-actions>.warehouse-actions-menu{grid-column:2;grid-row:2;align-self:center;margin:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card>.warehouse-summary-actions>:not(.warehouse-actions-menu){grid-column:1/-1;min-width:0;justify-self:start}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card>.warehouse-summary-actions>.warehouse-actions-menu>summary{min-height:44px}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-card>.warehouse-summary-actions>.warehouse-primary-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;justify-self:stretch;padding:0}
 :root[data-color-profile] body.workspace-cabinet .warehouse-primary-actions>*{width:100%!important;min-height:44px;white-space:normal}
 :root[data-color-profile] body.workspace-cabinet .warehouse-primary-actions>.action-help-wrap{display:flex;align-items:stretch;gap:4px}
 :root[data-color-profile] body.workspace-cabinet .warehouse-summary-actions .warehouse-primary-actions .button{flex:1;min-height:44px;height:100%;width:100%!important;padding:8px 6px;font-size:13px;line-height:1.25;white-space:normal}
 :root[data-color-profile] body.workspace-cabinet .warehouse-primary-actions .action-help-icon{position:static;transform:none;margin:0;align-self:center;flex:none}
}
#warehouseShippingSettingsStatus,#warehouseSubscriptionStatus{min-height:0;margin:0;padding:6px 8px;font-size:13px;line-height:1.4}
#warehouseShippingSettingsStatus:empty,#warehouseSubscriptionStatus:empty{display:none}
@media(max-width:800px){#warehouseSettingsNavigation{grid-template-columns:minmax(0,1fr)}#warehouseShippingSettings,#warehouseTelegramSubscription{grid-column:1/-1}}
@media(max-width:600px){#warehouseSettingsNavigation .button{min-height:44px}#warehouseSettingsNavigation .warehouse-section-heading{display:flex;flex-wrap:wrap}}

/* Preparation quantities: compact product cards and distinct categories. */
#warehouseShipmentForm .warehouse-shipment-quantity{grid-template-columns:minmax(0,1.3fr) repeat(2,minmax(0,1fr));align-items:center;gap:10px;margin:8px 0;padding:10px;border:1px solid #d4dfe6;border-radius:10px;background:var(--ui-panel,#fff);min-width:0}
#warehouseShipmentForm .warehouse-shipment-quantity.is-single-quantity{grid-template-columns:minmax(0,1fr) minmax(220px,280px)}
#warehouseShipmentForm .warehouse-shipment-quantity>strong{min-width:0;font-size:14px;line-height:1.35;overflow-wrap:anywhere}
#warehouseShipmentForm .warehouse-preparation-footer{box-sizing:border-box;width:100%;justify-content:flex-end;margin:12px 0 0;padding-top:12px;border-top:1px solid var(--ui-line,#d4dfe6)}
.warehouse-filter-controls .warehouse-sort-control{display:inline-flex;align-items:center;flex-wrap:wrap;gap:6px;margin:0;font-size:13px;max-width:100%}
.warehouse-filter-controls .warehouse-sort-control select{width:auto;max-width:100%;min-height:36px;margin:0;padding:6px 8px;font:inherit}
#warehouseShipmentForm .warehouse-preparation-footer[hidden],#warehouseShipmentForm>p[role=status]:empty{display:none!important}
@media(max-width:600px){#warehouseShipmentForm .warehouse-preparation-footer>button{width:100%}}
#warehouseShipmentForm .warehouse-quantity-field{display:grid;grid-template-columns:minmax(0,1fr) 88px;align-items:center;gap:2px 8px;margin:0;padding:8px;border:1px solid #bed1ec;border-radius:8px;background:#eef5ff;color:#1c2a32;min-width:0}
#warehouseShipmentForm .warehouse-quantity-field.is-gift{border-color:#e4ce9b;background:#fff7e5}
#warehouseShipmentForm .warehouse-quantity-field[hidden]{display:none!important}
#warehouseShipmentForm .warehouse-quantity-kind{grid-column:1;font-size:12px;font-weight:700;line-height:1.3}
#warehouseShipmentForm .warehouse-quantity-remaining{grid-column:1;font-size:12px;font-weight:400;line-height:1.35}
#warehouseShipmentForm .warehouse-quantity-field input{grid-column:2;grid-row:1/span 2;width:88px;max-width:100%;min-height:44px;padding:6px 8px;background:#fff;color:#111;font-size:15px;font-weight:700}
#warehouseShipmentForm .warehouse-quantity-error{grid-column:1/-1;font-size:12px;line-height:1.35}
@media(max-width:800px){#warehouseShipmentForm .warehouse-shipment-quantity{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}#warehouseShipmentForm .warehouse-shipment-quantity>strong{grid-column:1/-1}#warehouseShipmentForm .warehouse-shipment-quantity.is-single-quantity{grid-template-columns:minmax(0,1fr)}}
@media(max-width:480px){#warehouseShipmentForm .warehouse-shipment-quantity:not(.is-single-quantity) .warehouse-quantity-field{grid-template-columns:minmax(0,1fr);gap:4px}#warehouseShipmentForm .warehouse-shipment-quantity:not(.is-single-quantity) .warehouse-quantity-field input{grid-column:1;grid-row:auto;width:100%;max-width:110px}}

/* Shared screen layout and palette only. Warehouse identity remains fixed. */
.order-card-status{flex-wrap:wrap;max-width:100%}
.order-card-status .order-closed-at{font-size:12px;font-weight:400;color:var(--ui-muted,#526b6a);white-space:nowrap}
:root[data-color-profile] body.cabinet-settings-page :is(h1,h2,h3,h4,button,input,select,textarea) { font-family:inherit; }
:root[data-color-profile] .cabinet-settings-header { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:14px; padding:16px 0; min-width:0; }
:root[data-color-profile] .desktop-app .cabinet-settings-header { padding:16px 24px; }
:root[data-color-profile] .cabinet-settings-header .brand,:root[data-color-profile] .cabinet-settings-header .service-brand { max-width:210px; min-width:0; }
:root[data-color-profile] .cabinet-settings-header > .site-header-actions { display:none; }
.cabinet-settings-header > :is(.order-context,.cabinet-settings-identity) { min-width:0; overflow-wrap:anywhere; font-size:14px; }
:root[data-color-profile] .cabinet-settings-page .warehouse-tabs { display:flex; flex-wrap:wrap; }
.cabinet-settings-controls { grid-column:3; display:flex; align-items:center; justify-content:flex-end; gap:12px; min-width:0; }
:root[data-color-profile] .cabinet-settings-controls > .cabinet-runtime-refresh { box-sizing:border-box; max-width:100%; min-height:36px; padding:6px 8px; white-space:normal; font:inherit; font-size:13px; font-weight:800; }
:root[data-color-profile] .cabinet-settings-controls .cabinet-settings-version { margin:0; font:inherit; font-size:12px; line-height:1.4; white-space:normal; overflow-wrap:anywhere; text-align:right; }
:root[data-color-profile] .cabinet-settings-open { display:inline-flex; align-items:center; gap:6px; margin:0; white-space:nowrap; font:inherit; font-size:15px; padding:7px 12px; min-height:36px; }
:root[data-color-profile] .cabinet-settings-dialog { box-sizing:border-box; width:min(760px,calc(100vw - 24px)); max-width:760px; max-height:calc(100dvh - 24px); padding:20px; border:1px solid var(--ui-line); border-radius:12px; color:var(--ui-ink); background:var(--ui-panel); font:inherit; font-size:15px; line-height:1.45; overflow:hidden; }
.cabinet-settings-dialog[open] { display:grid; grid-template-rows:auto minmax(0,1fr) auto; }
.cabinet-settings-dialog::backdrop { background:rgba(18,29,42,.45); }
.cabinet-settings-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; padding-bottom:12px; }
.cabinet-settings-heading h2 { margin:0; font-size:20px; }
.cabinet-settings-content { min-height:0; overflow:auto; overflow-wrap:anywhere; }
.cabinet-settings-content > section { padding:14px 0; }
.cabinet-settings-content h3 { margin:0 0 10px; font-size:16px; }
.cabinet-settings-actions { display:flex; flex-wrap:wrap; align-items:center; gap:10px; }
.cabinet-settings-footer { display:flex; flex-wrap:wrap; justify-content:space-between; gap:12px; border-top:1px solid var(--ui-line); padding-top:14px; }
:root[data-color-profile] .cabinet-settings-dialog :is(button,a.button,.link-button,.text-action) { box-sizing:border-box; max-width:100%; white-space:normal; font:inherit; font-size:15px; padding:8px 12px; border:1px solid var(--ui-line); border-radius:var(--ui-button-radius); background:var(--ui-panel); color:var(--ui-ink); cursor:pointer; }
:root[data-color-profile] .cabinet-settings-dialog .color-profile-control { display:grid; width:100%; max-width:none; gap:6px; font-size:14px; }
:root[data-color-profile] .cabinet-settings-dialog .color-profile-control select { width:100%; font:inherit; }
:root[data-color-profile] body .cabinet-help-dialog { max-width:1100px; width:min(1100px,calc(100% - 24px)); font-family:inherit; }
:root[data-color-profile] body .cabinet-help-dialog button { font:inherit; font-size:15px; padding:8px 12px; border:1px solid var(--ui-line); border-radius:var(--ui-button-radius); background:var(--ui-panel); color:var(--ui-ink); cursor:pointer; }
:root[data-color-profile] body .cabinet-help-dialog .cabinet-help-header h2 { font-size:22px; }
.cabinet-help-roles[hidden] { display:none!important; }
.cabinet-help-footer { display:flex; justify-content:flex-end; position:sticky; bottom:-24px; padding:12px 0; background:var(--ui-panel); border-top:1px solid var(--ui-line); }
@media(max-width:1050px) {
  :root[data-color-profile] .cabinet-settings-header { grid-template-columns:minmax(0,1fr) auto; gap:10px; }
  .cabinet-settings-controls { grid-column:2; grid-row:1; flex-wrap:wrap; max-width:280px; }
  .cabinet-settings-header > :is(.order-context,.cabinet-settings-identity,.individual-header > span:not(.service-brand)) { grid-column:1 / -1; grid-row:2; }
}
@media(max-width:600px) {
  :root[data-color-profile] .cabinet-settings-header .brand,:root[data-color-profile] .cabinet-settings-header .service-brand { max-width:140px; }
  .cabinet-settings-controls { max-width:145px; gap:6px; }
  :root[data-color-profile] .cabinet-settings-dialog { padding:14px; }
  .cabinet-settings-footer { display:grid; }
}
:root[data-color-profile] {
  --ui-bg:#f3f6f2; --ui-panel:#fff; --ui-ink:#193f32; --ui-muted:#5e7167;
  --ui-line:#cedbd2; --ui-primary:#194c39; --ui-soft:#e6f3e9; --ui-on-primary:#fff;
  --ui-success-bg:#e6f3e9; --ui-success-ink:#226443;
  --ui-button-font-size:15px; --ui-button-min-height:36px; --ui-button-padding-block:6px;
  --ui-action-font-size:13px; --ui-action-min-height:30px; --ui-action-padding-block:4px;
  --ui-button-radius:3px;
  --ink:var(--ui-ink); --muted:var(--ui-muted); --line:var(--ui-line);
  --green:var(--ui-primary); --green-dark:var(--ui-primary);
  --green-soft:var(--ui-soft); --green-pale:var(--ui-bg);
  --background:var(--ui-bg); --cream:var(--ui-bg); --paper:var(--ui-panel); --white:var(--ui-panel);
  color-scheme:light; background:var(--ui-bg); color:var(--ui-ink);
}
:root[data-color-profile=lavender] { --ui-bg:#f5f6f9; --ui-ink:#242334; --ui-muted:#666578; --ui-line:#dfdce8; --ui-primary:#7c3aed; --ui-soft:#f1ebff; }
:root[data-color-profile=sapphire] { --ui-bg:#f0f3f7; --ui-ink:#202b3b; --ui-muted:#5e6a7c; --ui-line:#d4dce6; --ui-primary:#244b79; --ui-soft:#e9eff7; }
:root[data-color-profile=pearl] { --ui-bg:#f5f1e9; --ui-panel:#fffdf8; --ui-ink:#37332e; --ui-muted:#72695e; --ui-line:#ddd4c7; --ui-primary:#6e5940; --ui-soft:#eee6d8; }
:root[data-color-profile=emerald] { --ui-bg:#eef5f3; --ui-ink:#173d39; --ui-muted:#526f6b; --ui-line:#ccddd8; --ui-primary:#086b60; --ui-soft:#e0f0ea; }
:root[data-color-profile=plum] { color-scheme:dark; --ui-bg:#19151f; --ui-panel:#272130; --ui-ink:#f3edf5; --ui-muted:#c5b9cd; --ui-line:#55445e; --ui-primary:#78509f; --ui-soft:#362b43; --ui-success-bg:#233e32; --ui-success-ink:#b7e2c6; }
:root[data-color-profile] body { background:var(--ui-bg); color:var(--ui-ink); font-size:17px; }
:root[data-color-profile] :where(.site-header,.individual-header,.page,.page-shell,.individual-order-page,.app-shell,.page-footer) { width:min(1500px,94%); margin-inline:auto; }
:root[data-color-profile] .individual-header { background:var(--ui-panel); color:var(--ui-ink); }
:root[data-color-profile] .page-shell { padding-inline:0; }
:root[data-color-profile] .application { width:min(1500px,94%); margin-inline:auto; }
:root[data-color-profile] :where(.auth-panel.leader-cabinet-layout,.auth-panel.leader-summary-layout,.auth-panel.leader-availability-layout) { width:100%; max-width:1500px; }
:root[data-color-profile] :where(.auth-card,.leader-orders,.leader-order-card,.leader-summary-group,.link-box,.summary-section,.summary-delivery-dialog,.order-correction-dialog,.individual-order-card,.form-section,.order-card,.topbar,.filters,.table-wrap,.login-panel,.action-dialog) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] :where(input,select,textarea) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); font-size:16px; }
:root[data-color-profile] :where(.button,.primary,.secondary,.actions button,.action-dialog button,.order-action-button) { font-size:var(--ui-button-font-size); min-height:var(--ui-button-min-height); padding-block:var(--ui-button-padding-block); line-height:1.25; }
:root[data-color-profile] .desktop-app .actions button { font-size:var(--ui-action-font-size); min-height:var(--ui-action-min-height); padding:var(--ui-action-padding-block) 8px; line-height:1.2; }
:root[data-color-profile] :is(button,.button,.warehouse-tab) { border-radius:var(--ui-button-radius); }
:root[data-color-profile] [hidden] { display:none!important; }
:root[data-color-profile] .uniform-actions { flex-wrap:wrap; }
:root[data-color-profile] .last-login-value { white-space:pre; }
:root[data-color-profile] #warehouse-accounts-table { table-layout:fixed; min-width:900px; }
:root[data-color-profile] #warehouse-accounts-table td { min-width:0; overflow-wrap:anywhere; }
:root[data-color-profile] #warehouse-accounts-table th:nth-child(5) { width:104px; }
:root[data-color-profile] #warehouse-accounts-table th:nth-child(6) { width:116px; }
:root[data-color-profile] #warehouse-accounts-table th:last-child { width:212px; min-width:0; }
:root[data-color-profile] .field-tools { display:flex; gap:5px; align-items:center; margin-top:6px; }
:root[data-color-profile] .field-tools button { margin-top:0!important; width:30px; min-height:30px; padding:4px; }
:root[data-color-profile] #saveSummary:not(:disabled) { background:#194c39; border-color:#194c39; color:#fff; }
:root[data-color-profile] #saveSummary.needs-check:not(:disabled) { animation:summary-check-hint 2.8s ease-in-out infinite; }
:root[data-color-profile] #finalizeSummary:disabled { background:#eceff1; color:#647078; border-color:#ccd2d5; opacity:1; }
:root[data-color-profile=plum] #finalizeSummary:disabled { background:#39343f; color:#c1bac7; border-color:#625b68; }
@keyframes summary-check-hint { 50% { box-shadow:0 0 0 4px rgba(25,76,57,.14); } }
@media(prefers-reduced-motion:reduce) { :root[data-color-profile] #saveSummary.needs-check:not(:disabled) { animation:none; } }
:root[data-color-profile] .telegram-settings-card { display:grid; grid-template-columns:minmax(0,1fr) 230px; gap:20px; align-items:start; }
:root[data-color-profile] .telegram-card-content { min-width:0; display:grid; justify-items:start; align-content:start; gap:8px; line-height:1.3; }
:root[data-color-profile] .telegram-card-content > :is(p,h3,h4) { margin:0; }
:root[data-color-profile] .desktop-app .workspace > aside { background:var(--ui-primary); color:var(--ui-on-primary); }
:root[data-color-profile] .desktop-app .workspace > aside :is(.nav-link,.nav-title,.nav-disabled) { color:var(--ui-on-primary); }
:root[data-color-profile] .desktop-app .workspace > aside .nav-active { background:var(--ui-panel); color:var(--ui-ink); }
:root[data-color-profile] #product-id-tools { margin:18px 0; padding:14px; border:1px solid var(--ui-line); border-radius:3px; }
:root[data-color-profile] #product-id-tools > summary { cursor:pointer; }
:root[data-color-profile] #product-id-tools > :is(a,label,button) { display:inline-block; margin:6px 12px 10px 0; }
:root[data-color-profile] .desktop-app .catalog-intro { max-width:none; width:100%; }
:root[data-color-profile] :is(#catalog-table,#delivery-table) :is(th,td) { padding:8px 14px; line-height:1.25; vertical-align:middle; }
:root[data-color-profile] #catalog-table :is(.leader-name,.status) { font-weight:400; }
:root[data-color-profile] #delivery-table input[type=checkbox] { margin:0; padding:0; min-height:20px; }
:root[data-color-profile] .product-id-controls { display:flex; flex-wrap:wrap; align-items:end; gap:12px; margin:14px 0; }
:root[data-color-profile] .product-id-controls > :is(a,button) { display:inline-flex; align-items:center; justify-content:center; min-height:38px; padding:8px 14px; line-height:20px; text-decoration:none; border-radius:3px; }
:root[data-color-profile] .product-id-controls > label { flex:1 1 320px; max-width:500px; }
:root[data-color-profile] .product-id-controls input[type=file] { min-height:38px; height:38px; padding:5px 10px; margin-top:6px; }
:root[data-color-profile] #accounts-message:empty { display:none; }
:root[data-color-profile] .desktop-app :is(.summary-card,.catalog-tab,.delivery-selectors,.system-card,.cabinet-runtime-refresh) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] .desktop-app .catalog-tab.active { background:var(--ui-primary); color:var(--ui-on-primary); border-color:var(--ui-primary); }
:root[data-color-profile] .desktop-app :is(.admin-order-facts div,.admin-order-totals,.admin-order-comment,.nav-active span) { background:var(--ui-soft); color:var(--ui-ink); }
:root[data-color-profile] .desktop-app :is(.cabinet-runtime-refresh,.password-toggle):hover { background:var(--ui-soft); color:var(--ui-ink); }
:root[data-color-profile] { --ui-success-bg:var(--ui-soft); --ui-success-ink:var(--ui-ink); }
:root[data-color-profile] :is(.status.approved,.status.order-new,.status.order-sent,.availability-state,.warehouse-state.available,.warehouse-summary-status.is-in_work,.summary-warehouse-feedback.is-in_work,.review-match,.review-warehouse-badge,.summary-coverage-badge,.review-warehouse-card.is-selected .review-warehouse-badge,.summary-coverage-card.is-selected .summary-coverage-badge,.message-success) { background:var(--ui-soft); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] :is(.summary-version-current,.summary-coverage-ok,.review-warehouse-ok,.form-message.is-success,.summary-delivery-dialog.is-success h2,.warehouse-guard-dialog.is-success h2,.warehouse-preview-message.is-success) { color:var(--ui-ink); }
:root[data-color-profile] :is(.customer-card,.review-details,.review-warehouse-card,.summary-coverage-card,.summary-delivery-recipients,.leader-rejected-action,.leader-availability-tools,.leader-availability-message:not(.is-error),.leader-availability-savebar,.warehouse-profile div,.warehouse-savebar,.warehouse-summary-card,.warehouse-summary-empty,.warehouse-preview-post) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] :is(.review-warehouse-card.is-missing,.summary-coverage-card.is-missing,.leader-summary-group.is-rejected) { background:#fff6f4; color:#741919; border-color:#e3b3af; }
:root[data-color-profile] :is(.summary-help-button,.warehouse-dialog-close,.warehouse-summary-version,.warehouse-receipt-image,.warehouse-receipt-pdf,.product-row.is-unavailable,.order-completion>p:last-child,.warehouse-summary-list.is-archive .warehouse-summary-card) { background:var(--ui-soft); color:var(--ui-ink); }
:root[data-color-profile] :is(.help,.button.primary,.warehouse-copy-toast) { background:var(--ui-primary); color:var(--ui-on-primary); border-color:var(--ui-primary); }
:root[data-color-profile] :is(.button.secondary,.warehouse-reset,.cabinet-runtime-refresh) { background:var(--ui-panel); color:var(--ui-ink); }
:root[data-color-profile] :is(.individual-header span,.lead,.hint,.version,.review-list .is-empty,.summary-version-superseded,.warehouse-tab-archive,.state-card p:not(.eyebrow)) { color:var(--ui-muted); }
:root[data-color-profile] .individual-order-card .eyebrow { color:var(--ui-ink); }
:root[data-color-profile] :is(.summary-card:hover,.summary-card.active,.review-warehouse-card.is-selected,input:focus,select:focus,textarea:focus) { border-color:var(--ui-primary); }
:root[data-color-profile] :is(.action-help-tooltip,.action-help-tooltip small) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] #catalog-message:empty { display:none; }
:root[data-color-profile] .telegram-settings-card[data-verified=true] { border-left-color:var(--ui-primary)!important; }
:root[data-color-profile] .telegram-settings-card[data-verified=true] .telegram-check-status { background:var(--ui-soft)!important; color:var(--ui-ink)!important; }
:root[data-color-profile] .summary-coverage-guidance:not(.is-warning) { background:var(--ui-soft); color:var(--ui-ink); }
:root[data-color-profile] :is(dialog,.link-box input) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] button.action-help-icon { color:var(--ui-muted); border-color:var(--ui-muted); }
:root[data-color-profile] .telegram-card-content > :first-child { margin-top:0; }
:root[data-color-profile] .telegram-card-content > :last-child { margin-bottom:0; }
:root[data-color-profile] .telegram-card-actions { display:flex; flex-direction:column; align-items:stretch; gap:6px; }
:root[data-color-profile] .telegram-card-actions > .actions { margin-bottom:8px; }
:root[data-color-profile] .telegram-card-actions small { flex-basis:100%; color:var(--ui-muted); }
:root[data-color-profile] .telegram-channel-menu { position:relative; align-self:start; }
:root[data-color-profile] .telegram-channel-menu>summary { list-style:none; cursor:pointer; padding:8px 12px; border:1px solid var(--ui-primary); border-radius:6px; background:var(--ui-primary); color:var(--ui-primary-contrast,#fff); }
:root[data-color-profile] .telegram-channel-menu>summary::-webkit-details-marker { display:none; }
:root[data-color-profile] .telegram-channel-menu>.telegram-card-actions { position:absolute; z-index:50; right:0; top:calc(100% + 6px); box-sizing:border-box; width:280px; max-width:calc(100vw - 64px); padding:8px; border:1px solid var(--ui-line); border-radius:8px; background:var(--ui-panel); box-shadow:0 5px 16px #0a272b26; flex-direction:column; flex-wrap:nowrap; }
:root[data-color-profile] .telegram-channel-menu:not([open])>.telegram-card-actions { display:none; }
:root[data-color-profile] .telegram-channel-menu>.telegram-card-actions>button { width:100%; margin:0; text-align:left; white-space:normal; padding:8px 10px; border:1px solid var(--ui-line); background:var(--ui-panel); color:var(--ui-ink); }
:root[data-color-profile] .telegram-secret-row { margin-top:12px; }
@media(max-width:1100px) {
  :root[data-color-profile] .telegram-settings-card { grid-template-columns:minmax(0,1fr); gap:12px; }
  :root[data-color-profile] .telegram-card-actions { flex-direction:row; flex-wrap:wrap; }
}
:root[data-color-profile] :where(.button-primary,.primary) { background:var(--ui-primary); color:var(--ui-on-primary); border-color:var(--ui-primary); }
:root[data-color-profile] :where(.button-secondary,.secondary) { background:var(--ui-panel); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] :where(.leader-orders-tabs button,.warehouse-tab) { font-size:17px; min-height:44px; }
:root[data-color-profile] .leader-orders-tabs button[aria-selected=true] { background:var(--ui-primary); color:var(--ui-on-primary); }
:root[data-color-profile] :where(.status-badge:not(.is-blocked),.leader-warehouse-feedback.is-in_work) { background:var(--ui-success-bg); color:var(--ui-success-ink); }
:root[data-color-profile] :where(th,.review-list li,.review-details,.review-warehouse-card,.summary-coverage) { background:var(--ui-soft); color:var(--ui-ink); }
:root[data-color-profile] .site-header { flex-wrap:wrap; gap:20px; }
:root[data-color-profile] .cabinet-runtime { flex-wrap:wrap; gap:10px; }
:root[data-color-profile] .leader-header-profile { flex:1 1 300px; font-size:16px; line-height:1.5; overflow-wrap:anywhere; }
:root[data-color-profile] .leader-header-profile strong { font-size:17px; }
:root[data-color-profile] .leader-header-profile .status-badge { padding:4px 8px; }
:root[data-color-profile] .leader-header-profile[hidden] { display:none; }
:root[data-color-profile] :where(.cabinet-runtime #logoutButton,.cabinet-runtime-version,.cabinet-runtime-refresh,.secure-label,.leader-header-profile .status-badge) { font-size:16px; }
:root[data-color-profile] .cabinet-runtime-refresh { min-height:44px; }
:root[data-color-profile] .color-profile-control { display:inline-flex; flex-wrap:wrap; align-items:center; gap:8px; font-size:16px; color:var(--ui-muted); }
:root[data-color-profile] .color-profile-control select { width:auto; max-width:100%; min-height:44px; margin:0; padding:7px 10px; border:1px solid var(--ui-line); border-radius:8px; font-size:16px; }
:root[data-color-profile] #partnerInviteDialog { width:min(1120px,94vw); max-width:1120px; }
:root[data-color-profile] #partnerInvite { position:relative; display:grid; gap:10px; padding:24px; }
:root[data-color-profile] #partnerInvite > * { min-width:0; margin:0; }
:root[data-color-profile] #partnerInvite [hidden] { display:none; }
:root[data-color-profile] #partnerInvite #closePartnerInvite { position:absolute; top:12px; right:12px; width:44px; height:44px; padding:0; font-size:28px; }
:root[data-color-profile] #partnerInviteTitle { padding-right:48px; font-size:24px; line-height:1.2; }
:root[data-color-profile] #partnerInvite :where(label,p,input,.button) { font-size:17px; line-height:1.25; }
:root[data-color-profile] #partnerInvite .link-box-warning { font-size:16px; }
:root[data-color-profile=plum] #partnerInvite .link-box-warning { color:#ffaaa0!important; }
:root[data-color-profile] .partner-invite-content { display:grid; grid-template-columns:minmax(0,1fr) 270px; gap:24px; align-items:start; margin-top:8px!important; }
:root[data-color-profile] #partnerInvite #partnerQrCanvas { align-self:start; margin:0; width:270px; max-width:100%; border-radius:12px; }
:root[data-color-profile] #partnerInviteText { font-size:17px; line-height:1.25; overflow-wrap:anywhere; border:1px solid var(--ui-line); border-radius:12px; padding:12px 16px; user-select:none; }
:root[data-color-profile] #partnerInviteText.is-manual-copy { user-select:text; }
:root[data-color-profile] #partnerInviteText > * { display:block; margin:0 0 6px; }
:root[data-color-profile] #partnerInviteText .partner-invite-url { color:#065acb; text-decoration:underline; }
:root[data-color-profile=plum] #partnerInviteText .partner-invite-url { color:#8bbcff; }
:root[data-color-profile] .partner-invite-message > .partner-invite-actions { margin-top:8px; }
:root[data-color-profile] #partnerInvite :where(.partner-invite-separate p,.partner-invite-message > p) { margin:0; }
:root[data-color-profile] .partner-invite-separate { border-top:1px solid var(--ui-line); padding-top:10px; display:grid; gap:8px; }
:root[data-color-profile] .partner-invite-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
:root[data-color-profile] .partner-invite-actions .button { width:100%; height:44px; min-height:44px; box-sizing:border-box; margin:0; padding:8px 10px; }
:root[data-color-profile] #partnerInviteStatus:empty { display:none; }
:root[data-color-profile] #partnerQrCanvas { background:#fff; }
:root[data-color-profile] :focus-visible { outline:3px solid var(--ui-primary); outline-offset:3px; }
@media(min-width:1000px) {
  :root[data-color-profile] :where(.button,.cabinet-runtime-refresh) { white-space:nowrap; }
  :root[data-color-profile] .leader-order-actions > :where(details,.button) { flex:1 0 max-content; }
  :root[data-color-profile] .leader-order-actions summary.button { width:100%; box-sizing:border-box; }
  :root[data-color-profile] .leader-order-actions > details[open] { flex-basis:100%; }
  :root[data-color-profile] .desktop-app { max-width:1600px; margin:auto; }
  :root[data-color-profile] .content { padding:28px; }
  :root[data-color-profile] .topbar { height:auto; min-height:72px; flex-wrap:wrap; gap:12px; padding:16px 28px; }
}
@media(max-width:650px) {
  :root[data-color-profile] #partnerInvite { padding:18px; gap:12px; }
  :root[data-color-profile] .partner-invite-content { grid-template-columns:minmax(0,1fr); gap:12px; }
  :root[data-color-profile] .partner-invite-actions { grid-template-columns:1fr; }
  :root[data-color-profile] #partnerInvite #partnerQrCanvas { justify-self:center; width:260px; }
  :root[data-color-profile] body { font-size:16px; }
  :root[data-color-profile] .leader-header-profile { flex-basis:100%; }
  :root[data-color-profile] .site-header-actions { width:100%; flex-wrap:wrap; }
  :root[data-color-profile] .color-profile-control { max-width:100%; }
}

:root[data-color-profile] .action-help-wrap { position:relative; display:inline-flex; align-items:center; margin-top:18px; max-width:100%; vertical-align:middle; }
:root[data-color-profile] .action-help-row { padding-top:18px; row-gap:26px; flex-wrap:wrap; }
:root[data-color-profile] .action-help-row > .action-help-wrap { margin-top:0; }
:root[data-color-profile] :is(.site-header,.individual-header,.topbar):has(.action-help-wrap) { padding-top:24px; }
:root[data-color-profile] :is(.site-header,.individual-header,.topbar) .action-help-row { padding-top:0; }
:root[data-color-profile] .action-help-wide { width:100%; }
:root[data-color-profile] .warehouse-tabs { flex-wrap:wrap; overflow:visible; }
:root[data-color-profile] .warehouse-tabs .action-help-wrap { min-width:0; }
:root[data-color-profile] .warehouse-tabs .warehouse-tab { max-width:100%; white-space:normal; overflow-wrap:anywhere; }
:root[data-color-profile] .action-help-wrap:has(> [hidden]) { display:none!important; }
:root[data-color-profile] button.action-help-icon { position:absolute; width:16px!important; min-width:16px!important; height:16px; min-height:16px; padding:0!important; margin:0; border:1px solid #a1a9ac; background:transparent; color:#667276; font:600 11px/14px Arial,sans-serif; cursor:help; box-shadow:none; }
:root[data-color-profile=plum] button.action-help-icon { color:#c5cbd0; border-color:#818b94; }
.action-help-tooltip { position:fixed; z-index:10000; pointer-events:none; width:360px; max-width:calc(100vw - 16px); box-sizing:border-box; padding:12px 14px; border:1px solid #929da3; border-radius:3px; background:#fff; color:#193f32; font-size:15px; line-height:1.4; box-shadow:0 4px 18px #0003; }
.action-help-tooltip small { display:block; margin-top:8px; font-size:12px; color:#59666e; }
:root[data-color-profile] .cabinet-help-dialog { width:min(880px,calc(100% - 24px)); max-height:calc(100dvh - 24px); box-sizing:border-box; overflow:auto; padding:24px; border:1px solid var(--ui-line); border-radius:3px; background:var(--ui-panel); color:var(--ui-ink); font-size:17px; line-height:1.5; }
.cabinet-help-dialog::backdrop { background:#0007; }
.cabinet-help-header { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.cabinet-help-header h2 { margin:0; }
.cabinet-help-version { color:var(--ui-muted); font-size:13px; }
.cabinet-help-roles { display:flex; flex-wrap:wrap; gap:8px; margin:16px 0; }
:root[data-color-profile] .cabinet-help-roles button[aria-pressed=true] { background:var(--ui-primary); color:var(--ui-on-primary); }
.cabinet-help-dialog label { display:block; }
.cabinet-help-dialog input { display:block; box-sizing:border-box; width:100%; margin-top:6px; padding:10px; color:var(--ui-ink); background:var(--ui-panel); border:1px solid var(--ui-line); border-radius:3px; }
.cabinet-help-sections > section,.cabinet-help-context { margin-top:20px; padding:16px; border:1px solid var(--ui-line); border-radius:3px; overflow-wrap:anywhere; }
.cabinet-help-context { background:var(--ui-soft); }
.cabinet-help-dialog h3 { margin:0 0 10px; font-size:19px; }
.cabinet-help-dialog ol { margin:0; padding-left:24px; }
.cabinet-help-dialog li + li { margin-top:10px; }
@media(max-width:650px) { :root[data-color-profile] .cabinet-help-dialog { padding:16px; } .cabinet-help-header { align-items:flex-start; } .cabinet-help-roles { display:grid; grid-template-columns:1fr; } }

/* Approved workspace: dark shell, angled tabs, light operational blocks. */
:root[data-color-profile] body.workspace-cabinet {
  --workspace-shell:#143e2c; --workspace-deep:#0b251d; --workspace-accent:#27734f; --workspace-canvas:#f0f5f2;
  --ui-panel:#fff; --ui-ink:#203c3b; --ui-muted:#536c69; --ui-line:#d4e2dd;
  --ui-primary:var(--workspace-accent); --ui-on-primary:#fff; --ui-soft:#eaf2ef;
  --ui-success-bg:#e6f3e9; --ui-success-ink:#226443;
  --ink:var(--ui-ink); --muted:var(--ui-muted); --line:var(--ui-line); --white:#fff;
  --green:var(--workspace-accent); --green-dark:var(--workspace-accent); --green-soft:var(--ui-soft);
  --ui-button-font-size:14px; --ui-button-radius:6px;
  color-scheme:light; color:var(--ui-ink); font:14px/1.48 Arial,sans-serif;
  background:var(--workspace-canvas);
}
:root[data-color-profile] body.workspace-cabinet .workspace-frame { box-sizing:border-box; width:min(1440px,94%); min-height:0; margin:24px auto; padding:0 20px 16px; border-radius:14px; background:var(--workspace-shell); background-image:repeating-linear-gradient(90deg,transparent,transparent 3px,#ffffff03 4px,transparent 5px),radial-gradient(ellipse at 90% 0%,color-mix(in srgb,var(--workspace-accent) 65%,transparent),transparent 58%),linear-gradient(138deg,var(--workspace-deep),var(--workspace-shell) 62%,var(--workspace-deep)); }
:root[data-color-profile] body.workspace-cabinet .workspace-frame > :is(.site-header,.page-shell,.page,.site-footer) { width:100%; margin-inline:0; }
:root[data-color-profile=lavender] body.workspace-cabinet { --workspace-shell:#3a3158; --workspace-deep:#252039; --workspace-accent:#7962a5; --workspace-canvas:#f3f0f7; --ui-soft:#f1edf6; }
:root[data-color-profile=sapphire] body.workspace-cabinet { --workspace-shell:#1b394e; --workspace-deep:#10212f; --workspace-accent:#326b9b; --workspace-canvas:#f0f3f7; --ui-soft:#eaf1f7; }
:root[data-color-profile=pearl] body.workspace-cabinet { --workspace-shell:#514434; --workspace-deep:#302b25; --workspace-accent:#916f43; --workspace-canvas:#f5f1e9; --ui-soft:#f4efe7; }
:root[data-color-profile=emerald] body.workspace-cabinet { --workspace-shell:#103e39; --workspace-deep:#0a272b; --workspace-accent:#167e70; --workspace-canvas:#eef5f3; --ui-soft:#e9f3ef; }
:root[data-color-profile=plum] body.workspace-cabinet { --workspace-shell:#422d4b; --workspace-deep:#291e31; --workspace-accent:#865e9b; --workspace-canvas:#f3eff5; --ui-soft:#f2edf5; }
:root[data-interface-role=warehouse] body.workspace-cabinet { --workspace-shell:#103e39; --workspace-deep:#0a272b; --workspace-accent:#167e70; --ui-soft:#e9f3ef; }
:root[data-color-profile] body.workspace-cabinet :is(button,input,select,textarea,h1,h2,h3,h4) { font-family:inherit; }
:root[data-color-profile] body.workspace-cabinet :is(.site-header,.page-shell,.site-footer) { width:min(1440px,94%); margin-inline:auto; }
:root[data-color-profile] body.workspace-cabinet .site-header { background:transparent; border:0; color:#f0faf7; padding-block:20px; }
:root[data-color-profile] body.workspace-cabinet .service-brand::after { background:#eefaf6; }
:root[data-color-profile] body.workspace-cabinet .site-header :is(.leader-header-profile,.cabinet-settings-identity) { color:#f0faf7; font-size:14px; }
:root[data-color-profile] body.workspace-cabinet .site-header :is(.cabinet-runtime-version,.leader-header-profile>div) { color:#d1e4de; }
:root[data-color-profile] body.workspace-cabinet .site-header .status-badge { color:#bcf1d2; background:transparent; padding:0; }
:root[data-color-profile] body.workspace-cabinet .site-header .cabinet-runtime-version { font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .site-header .cabinet-runtime-version strong { color:#f0faf7; }
:root[data-color-profile] body.workspace-cabinet :is(.button,button.text-action,.cabinet-runtime-refresh,.cabinet-help-open,.warehouse-dialog-close,.warehouse-preview-close,.password-toggle) { background:var(--ui-primary); color:var(--ui-on-primary); border:1px solid transparent; border-radius:6px; font-size:14px; line-height:1.3; }
:root[data-color-profile] body.workspace-cabinet :is(.button-secondary,.cabinet-help-open) { background:var(--ui-soft); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] body.workspace-cabinet .site-header :is(button,.button) { background:var(--workspace-accent); color:#fff; border-color:#ffffff30; font-size:13px; }
:root[data-color-profile] body.workspace-cabinet :is(.leader-settings-heading,.cabinet-settings-heading)>button,
:root[data-color-profile] body.workspace-cabinet :is(.warehouse-dialog-close,.warehouse-preview-close,#closePartnerInvite) { background:var(--workspace-accent); color:#fff; border-color:transparent; min-width:36px; min-height:36px; font:22px/1 Arial,sans-serif; }
:root[data-color-profile] body.workspace-cabinet button:disabled { cursor:not-allowed; }
:root[data-color-profile] body.workspace-cabinet .leader-tracking-confirmation input:checked { appearance:none; border:0; border-radius:3px; background:#238149; opacity:1; }
:root[data-color-profile] body.workspace-cabinet .leader-tracking-confirmation input:checked::after { content:'✓'; display:block; color:#fff; font:700 13px/18px Arial,sans-serif; text-align:center; }
:root[data-color-profile] body.workspace-cabinet #leaderSettingsActionControls :is(.button,.cabinet-help-open) { background:var(--ui-soft); color:var(--ui-ink); border-color:var(--ui-line); }
:root[data-color-profile] body.workspace-cabinet .page-shell { padding-block:4px 28px; min-height:0; align-items:start; }
:root[data-color-profile] body.workspace-cabinet .auth-panel.leader-cabinet-layout>.auth-card { padding:0; border:0; box-shadow:none; background:transparent; }
:root[data-color-profile] body.workspace-cabinet .leader-orders { padding:0; border:0; border-radius:0; gap:0; background:transparent; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-heading { align-items:center; padding:12px 2px 16px; color:#f0faf7; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-heading .eyebrow { display:none; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-heading h2 { color:inherit; font-size:21px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-heading>p { color:#d1e4de; font-size:12px; max-width:380px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-tabs,
:root[data-color-profile] body.workspace-cabinet .warehouse-tabs { display:flex; flex-wrap:wrap; gap:5px; padding:0; margin:0; border:0; background:transparent; }
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) [role=tab] { position:relative; isolation:isolate; min-width:0; min-height:45px; margin:0; padding:10px 24px 10px 14px; border:0; border-radius:0; background:transparent; color:#e1eeea; font:700 13px/1.35 Arial,sans-serif; white-space:normal; box-shadow:none; }
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) [role=tab]::before { content:''; position:absolute; inset:0; z-index:-1; background:#ffffff1c; border-radius:7px 0 0 0; clip-path:polygon(0 0,calc(100% - 19px) 0,100% 100%,0 100%); }
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) [role=tab][aria-selected=true] { color:var(--workspace-accent); background:transparent; }
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) [role=tab][aria-selected=true]::before { background:#f5f8f7; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-tabs span { display:inline-block; margin-left:5px; padding:2px 6px; border-radius:4px; background:#ffffff18; color:inherit; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-tabs [aria-selected=true] span { background:var(--workspace-accent); color:#fff; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-workspace { display:grid; gap:12px; padding:16px; border-radius:0 9px 9px 9px; background:#f5f8f7; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-search { gap:5px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-search label { font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-search input { border-radius:6px; min-height:40px; padding:9px 12px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-message { min-height:0; font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .leader-orders-list { gap:12px; }
:root[data-color-profile] body.workspace-cabinet .leader-order-card { gap:10px; padding:16px; border-radius:8px; border-left:3px solid var(--workspace-accent); background:var(--ui-panel); box-shadow:none; }
:root[data-color-profile] body.workspace-cabinet .leader-order-card-heading { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:4px 12px; align-items:start; }
:root[data-color-profile] body.workspace-cabinet .leader-order-card-heading>strong { color:var(--workspace-accent); font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .leader-order-card-heading>.leader-order-partner { grid-column:1; grid-row:2; min-width:0; font-size:15px; }
:root[data-color-profile] body.workspace-cabinet .leader-order-card-heading>time { grid-column:2; grid-row:1/3; color:var(--ui-muted); font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .leader-order-totals { font-size:13px; }
:root[data-color-profile] body.workspace-cabinet .leader-summary-group { padding:14px; border-radius:8px; background:var(--ui-panel); }
:root[data-color-profile] body.workspace-cabinet .summary-warehouse-feedback { padding:10px 12px; border-radius:5px; font-size:13px; }
:root[data-color-profile] body.workspace-cabinet .summary-warehouse-feedback.is-pending { color:#755916; background:#fff0d8; }
:root[data-color-profile] body.workspace-cabinet .summary-warehouse-feedback.is-in_work { color:#176139; background:#e3f2e8; }
:root[data-color-profile] body.workspace-cabinet .summary-warehouse-feedback.is-rejected { color:#8a2d25; background:#fff0ef; }
:root[data-color-profile] body.workspace-cabinet #partnerInviteFooter { border-top:1px solid #ffffff25; padding-top:16px; margin-top:16px; color:#d1e4de; }
:root[data-color-profile] body.workspace-cabinet #partnerInviteFooter p { color:inherit; }
:root[data-color-profile] body.workspace-cabinet .warehouse-cabinet { border:0; box-shadow:none; padding:0; background:transparent; gap:0; }
:root[data-color-profile] body.workspace-cabinet .warehouse-heading { color:#f0faf7; margin-bottom:8px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-heading :is(h1,.eyebrow) { color:inherit; }
:root[data-color-profile] body.workspace-cabinet .warehouse-heading p { color:#d1e4de; font-size:13px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-profile { display:flex; flex-wrap:wrap; gap:12px 30px; padding:0 0 16px; margin:0; background:transparent; border:0; }
:root[data-color-profile] body.workspace-cabinet .warehouse-profile>div { padding:0; border:0; }
:root[data-color-profile] body.workspace-cabinet .warehouse-profile>div { background:transparent; border-radius:0; }
:root[data-color-profile] body.workspace-cabinet .warehouse-heading h1 { font-size:26px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-panel h2 { font-size:22px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-profile dt { color:#c4ded5; font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-profile dd { color:#f0faf7; font-size:14px; }
:root[data-color-profile] body.workspace-cabinet .warehouse-panel { padding:20px; border-radius:0 9px 9px 9px; background:#f5f8f7; }
:root[data-color-profile] body.workspace-cabinet :is(.warehouse-summary-card,.individual-order-card,.warehouse-report-document) { background:#fff; border-radius:8px; border-color:var(--ui-line); box-shadow:none; }
:root[data-color-profile] body.workspace-cabinet .site-footer { color:#d1e4de; border-color:#ffffff25; font-size:12px; }
:root[data-color-profile] body.workspace-cabinet .site-footer a { color:#e3f2ec; }
:root[data-color-profile] body.workspace-cabinet .desktop-app.workspace-frame { max-width:1440px; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .topbar { color:#f0faf7; background:transparent; border:0; padding:20px 0; }
:root[data-color-profile] body.workspace-cabinet .topbar :is(.cabinet-settings-identity,.cabinet-runtime-version,.cabinet-runtime-version strong) { color:#e3f2ec; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .workspace { min-height:0; background:transparent; grid-template-columns:210px minmax(0,1fr); gap:16px; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .workspace>aside { background:transparent; color:#e3f2ec; padding:16px 0; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .workspace>aside :is(.nav-link,.nav-title,.nav-disabled) { color:#e3f2ec; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .workspace>aside .nav-active { background:var(--ui-panel); color:var(--ui-ink); border-radius:6px; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .content { min-width:0; padding:24px; border-radius:9px; background:#f5f8f7; color:var(--ui-ink); }
:root[data-color-profile] body.workspace-cabinet .desktop-app :is(h1,h2) { font-size:24px; }
:root[data-color-profile] body.workspace-cabinet .desktop-app :is(.primary,.secondary,.actions button,.link-button) { background:var(--workspace-accent); color:#fff; border:1px solid transparent; border-radius:6px; font-family:inherit; }
:root[data-color-profile] body.workspace-cabinet .desktop-app .actions button.danger { background:#fff0ef; color:#8a2d25; border-color:#e3b3af; }
/* Partner order uses the same bounded workspace; steps remain progress indicators. */
:root[data-color-profile] body.partner-order-workspace .page { min-height:0; padding:4px 0 28px; }
:root[data-color-profile] body.partner-order-workspace .application { width:100%; grid-template-columns:minmax(0,1fr); gap:0; align-items:start; }
:root[data-color-profile] body.partner-order-workspace .application .intro { display:grid; grid-template-columns:minmax(0,1fr) minmax(280px,.85fr); gap:8px 28px; width:100%; max-width:none; align-items:start; }
:root[data-color-profile] body.partner-order-workspace .intro :is(.eyebrow,h1,.lead) { grid-column:1; color:#f0faf7; }
:root[data-color-profile] body.partner-order-workspace .intro .eyebrow { grid-row:1; font-size:12px; margin:4px 0 0; }
:root[data-color-profile] body.partner-order-workspace .intro h1 { grid-row:2; font-size:28px; line-height:1.2; letter-spacing:normal; }
:root[data-color-profile] body.partner-order-workspace .intro .lead { grid-row:3; max-width:56ch; margin:0; color:#d1e4de; font-size:14px; }
:root[data-color-profile] body.partner-order-workspace .leader-route-note { grid-column:2; grid-row:1/4; gap:6px; margin:0; padding:14px 16px; border:1px solid #ffffff30; border-left:3px solid var(--workspace-accent); border-radius:8px; background:var(--ui-soft); color:var(--ui-ink); font-size:13px; line-height:1.45; }
:root[data-color-profile] body.partner-order-workspace .leader-route-note .leader-route-heading { font-size:14px; margin-bottom:2px; }
:root[data-color-profile] body.partner-order-workspace .application .steps { grid-column:1/-1; grid-row:4; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:6px; margin:14px 0 0; align-self:stretch; }
:root[data-color-profile] body.partner-order-workspace .steps li { display:flex; align-items:center; gap:8px; padding:12px 22px 12px 14px; border-radius:6px 0 0 0; clip-path:polygon(0 0,calc(100% - 18px) 0,100% 100%,0 100%); color:#d1e4de; background:#ffffff18; font-size:14px; }
:root[data-color-profile] body.partner-order-workspace .steps li::before { display:none; }
:root[data-color-profile] body.partner-order-workspace .steps span { display:inline-grid; flex:0 0 22px; height:22px; place-items:center; border-radius:4px; background:#ffffff20; font-size:12px; }
:root[data-color-profile] body.partner-order-workspace .steps strong { overflow:visible; text-overflow:clip; overflow-wrap:anywhere; }
:root[data-color-profile] body.partner-order-workspace .steps .is-complete { background:#ffffff28; color:#f0faf7; }
:root[data-color-profile] body.partner-order-workspace .steps .is-current { background:#f5f8f7; color:var(--workspace-accent); }
:root[data-color-profile] body.partner-order-workspace .steps .is-current span { background:var(--workspace-accent); color:#fff; }
:root[data-color-profile] body.partner-order-workspace .application .form-column { max-width:none; width:100%; min-width:0; justify-self:stretch; padding:20px; border-radius:0 9px 9px 9px; background:#f5f8f7; }
:root[data-color-profile] body.partner-order-workspace :is(.order-card,.state-card) { border-radius:8px; background:var(--ui-panel); color:var(--ui-ink); box-shadow:none; }
:root[data-color-profile] body.partner-order-workspace :is(.order-card,.state-card) h2 { font-size:22px; color:var(--ui-ink); }
:root[data-color-profile] body.partner-order-workspace .site-header :is(.order-context,.secure-label,.public-version) { color:#d1e4de; }
:root[data-color-profile] body.partner-order-workspace .site-header .public-version strong { color:#f0faf7; }
:root[data-color-profile] body.partner-order-workspace .site-footer { margin-block:0; min-height:0; padding-block:16px; border-top:1px solid #ffffff25; }
:root[data-color-profile] body.partner-order-workspace :is(.submit-button,.secondary-button) { font-size:14px; border-radius:6px; }
:root[data-color-profile] body.partner-order-workspace .secondary-button { padding:10px 16px; border:1px solid var(--ui-line); background:var(--ui-soft); color:var(--workspace-accent); text-decoration:none; }
@media(min-width:901px) {
  :root[data-color-profile] body.partner-order-workspace #orderForm fieldset { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px 24px; }
  :root[data-color-profile] body.partner-order-workspace #orderForm fieldset > :not(.field) { grid-column:1/-1; }
  :root[data-color-profile] body.partner-order-workspace #orderForm .field { margin-bottom:0; }
}
@media(max-width:800px) {
  :root[data-color-profile] body.partner-order-workspace .application .intro { grid-template-columns:minmax(0,1fr); gap:10px; }
  :root[data-color-profile] body.partner-order-workspace .leader-route-note { grid-column:1; grid-row:4; }
  :root[data-color-profile] body.partner-order-workspace .application .steps { grid-row:5; grid-template-columns:repeat(2,minmax(0,1fr)); margin-top:6px; }
  :root[data-color-profile] body.partner-order-workspace .application .form-column { padding:12px; border-radius:8px; }
  :root[data-color-profile] body.partner-order-workspace :is(.order-card,.state-card) { padding:16px; }
  :root[data-color-profile] body.partner-order-workspace .steps li { padding:10px 20px 10px 10px; gap:5px; font-size:12px; }
}
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs)>.action-help-wrap { flex:0 1 auto; margin-top:16px; background:transparent; }
:root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) .action-help-icon { color:#d1e4de; }
@media(max-width:900px) {
  :root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); }
  :root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) [role=tab] { font-size:12px; padding:10px 20px 10px 10px; }
}
@media(max-width:600px) {
  :root[data-color-profile] body.workspace-cabinet .workspace-frame { margin:12px auto; padding:0 12px 12px; border-radius:10px; }
  :root[data-color-profile] body.workspace-cabinet .site-header { padding-block:14px; }
  :root[data-color-profile] body.workspace-cabinet .leader-orders-heading { flex-direction:column; align-items:start; gap:5px; }
  :root[data-color-profile] body.workspace-cabinet :is(.leader-orders-tabs,.warehouse-tabs) { grid-template-columns:repeat(2,minmax(0,1fr)); gap:4px; padding-bottom:6px; }
  :root[data-color-profile] body.workspace-cabinet .leader-orders-tabs [data-order-status=sent] { grid-column:1/-1; }
  :root[data-color-profile] body.workspace-cabinet .leader-orders-tabs>.action-help-wrap:has([data-order-status=sent]) { grid-column:1/-1; }
  :root[data-color-profile] body.workspace-cabinet :is(.leader-orders-workspace,.warehouse-panel) { padding:12px; border-radius:8px; }
  :root[data-color-profile] body.workspace-cabinet .leader-order-card { padding:12px; }
  :root[data-color-profile] body.workspace-cabinet .leader-order-card-heading { grid-template-columns:minmax(0,1fr); }
  :root[data-color-profile] body.workspace-cabinet .leader-order-card-heading>time { grid-column:1; grid-row:auto; }
  :root[data-color-profile] body.workspace-cabinet :is(.button,input,select,textarea) { max-width:100%; }
  :root[data-color-profile] body.workspace-cabinet :is(input,select,textarea) { font-size:16px; }
  :root[data-color-profile] body.workspace-cabinet .site-footer { padding-block:16px; }
}
@media(pointer:coarse) { :root[data-color-profile] body.workspace-cabinet :is(.button,button.text-action,.cabinet-settings-button,.warehouse-dialog-close) { min-height:44px; } }
@media screen and (min-width:1024px) {
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-orders-list { gap:8px; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-card { gap:6px; padding:10px 12px; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-card-heading {
    display:flex; flex-wrap:wrap; align-items:baseline; justify-content:flex-start; gap:4px 12px;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-card-heading>.leader-order-partner {
    flex:0 1 auto; overflow:visible; text-overflow:clip; white-space:normal; overflow-wrap:anywhere;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-card-heading>time {
    flex:0 0 auto; padding:2px 7px; border:1px solid var(--ui-line); border-radius:5px;
    background:color-mix(in srgb,var(--ui-ink) 5%,var(--ui-panel)); white-space:nowrap;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-correction-note {
    grid-column:auto; font-size:13px; line-height:1.4;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-identity {
    display:flex; flex-wrap:wrap; align-items:baseline; gap:3px 16px;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-identity>details[open] { flex-basis:100%; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-group { padding:10px 12px; gap:6px; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-group>:is(.summary-version-history,.summary-warehouse-feedback) { margin:0; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-actions:empty { display:none; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-group-heading {
    display:flex; flex-wrap:wrap; align-items:baseline; gap:3px 12px;
  }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-group-heading>h3 { font-size:16px; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-summary-group-heading>:is(.leader-summary-identity,.leader-summary-group-scope) { flex-basis:100%; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .summary-warehouse-feedback { padding:6px 10px; }
  :root[data-color-profile] body.workspace-cabinet .leader-cabinet-layout .leader-order-actions { margin-top:0; }
}
@media print {
  :root[data-color-profile] body.workspace-cabinet { background:#fff!important; color:#000; }
  :root[data-color-profile] body.workspace-cabinet .workspace-frame { width:100%; margin:0; padding:0; border-radius:0; background:#fff; }
  :root[data-color-profile] body.workspace-cabinet :is(.site-header,.site-footer,.leader-orders-tabs,.warehouse-tabs) { display:none; }
  :root[data-color-profile] body.partner-order-workspace .intro :is(.eyebrow,h1,.lead) { color:#000; }
  :root[data-color-profile] body.partner-order-workspace .application .steps { display:none; }
}

@media(min-width:1024px){
 :root[data-color-profile] body.partner-order-workspace .application .intro{grid-template-columns:minmax(200px,.65fr) minmax(0,1.75fr);gap:8px 24px}
 :root[data-color-profile] body.partner-order-workspace .leader-route-note{line-height:1.32;gap:5px}
}

.shipment-adjustment-comparison,.shipment-adjustment-items{min-width:0;margin:12px 0}
.shipment-adjustment-comparison h3,.shipment-adjustment-items h3{margin:0 0 8px}
.shipment-adjustment-comparison table{width:100%;min-width:0;table-layout:fixed;border-collapse:collapse;font:inherit}
.shipment-adjustment-comparison th,.shipment-adjustment-comparison td{padding:8px;border:1px solid var(--ui-line,#ccd9d4);text-align:left;vertical-align:top;overflow-wrap:anywhere}
.shipment-adjustment-comparison th:first-child{width:40%}
.shipment-adjustment-comparison th[scope=row]{font-weight:400;text-transform:none;letter-spacing:normal}
.shipment-adjustment-comparison th[scope=col]{background:var(--ui-soft,#edf4f0)}
.shipment-adjustment-comparison tr.shipment-adjustment-changed>*{background:#fff1d6;color:#593c00}
.shipment-adjustment-comparison .shipment-adjustment-changed th[scope=row]{border-left:3px solid #b06b00;font-weight:700}
.shipment-adjustment-changed>span,.shipment-adjustment-changed th>span{display:block;font-weight:700;font-size:12px}
.shipment-adjustment-items ul{display:grid;gap:6px;list-style:none;padding:0;margin:0}
.shipment-adjustment-items li{min-width:0;padding:8px;border:1px solid var(--ui-line,#ccd9d4);overflow-wrap:anywhere}
.shipment-adjustment-items li.shipment-adjustment-changed{border-left:3px solid #b06b00;background:#fff1d6;color:#593c00}
.shipment-adjustment-changed small{display:block;font-weight:400;font-size:12px}

/* Shared read-only parcel marks; colors match the warehouse marks. */
.order-company-number{flex-basis:100%}
.order-parcel-markers{display:inline-flex;gap:6px;flex-wrap:wrap;margin:6px 0}
.order-parcel-marker{position:relative;width:32px;height:32px;padding:0;border:2px solid;border-radius:6px;cursor:pointer;font:inherit;flex:none}
.order-parcel-marker small{position:absolute;top:1px;left:3px;font-size:10px;line-height:1}
.order-parcel-marker span{display:block;font-size:21px;line-height:28px;text-align:center}
.order-parcel-marker.is-partial{border-color:#b42318;background:#b42318;color:#fff}
.order-parcel-marker.is-closing{border-color:#18724c;background:#18724c;color:#fff}
.order-parcel-marker.is-prepared{border-color:#64748b;background:transparent;color:#475569}
.order-parcel-marker:focus-visible{outline:3px solid var(--accent,#117a72);outline-offset:3px}
.compact-order-heading{display:flex;flex-wrap:wrap;align-items:center;gap:10px 16px;margin-bottom:12px}
.compact-order-heading>.order-parcel-markers{margin:0}
.compact-order-heading>.order-compact-identity{display:flex;flex:1 1 360px;align-items:center;justify-content:space-between;gap:10px 20px;min-width:0}
.order-compact-identity>*{overflow-wrap:anywhere;min-width:0}
.order-card-status{display:flex;flex-wrap:wrap;align-items:center;gap:8px;flex:none;color:var(--ui-ink,var(--ink))}
.order-card-state{display:inline-flex;align-items:center;box-sizing:border-box;min-height:32px;padding:4px 10px;border:1px solid var(--ui-line,#ccd9d4);border-radius:6px;background:var(--ui-soft,#edf3ef);color:var(--ui-ink,var(--ink));font-size:14px;line-height:22px;white-space:nowrap}
.order-card-state.is-partial,.order-card-state.is-rejected{border-color:#b42318;background:#b42318;color:#fff}
.order-card-state.is-closing,.order-card-state.is-shipped{border-color:#18724c;background:#18724c;color:#fff}
.order-fulfillment{margin:12px 0;padding:14px;border:1px solid #d5b878;border-radius:8px;background:#fff8eb;color:#173c36;overflow-wrap:anywhere}
.order-fulfillment p{margin:0 0 8px}.order-fulfillment p:last-child{margin-bottom:0}.order-fulfillment ol{margin:8px 0 0;padding-left:22px}.order-fulfillment li+li{margin-top:6px}
@media(max-width:600px){.compact-order-heading>.order-compact-identity{flex-basis:calc(100% - 52px);flex-direction:column;align-items:flex-start}.compact-order-heading>.order-card-status{width:100%}}
.order-field-dialog{width:min(92vw,420px);max-height:85vh;overflow:auto;border:1px solid var(--accent,#117a72);border-radius:12px;padding:20px;color:var(--ui-ink,var(--ink,#163b3a));background:var(--ui-panel,#fff)}
.order-field-dialog::backdrop{background:#0008}
.order-field-dialog form,.order-field-dialog label{display:grid;gap:6px}
.order-field-dialog form{gap:12px}

.order-field-dialog :is(input,select){box-sizing:border-box;width:100%;min-width:0;min-height:40px;padding:8px 10px;border:1px solid var(--ui-line,var(--line,#bfc9c3));border-radius:6px;font:inherit;color:var(--ui-ink,var(--ink,#163b3a));background:var(--ui-panel,#fff)}
.order-field-dialog h2{margin:0;font-size:20px}

/* Completed state is a label; parcel squares retain their delivery semantics. */
.order-card-state.is-closing,.order-card-state.is-shipped{min-height:0;padding:0;border:0;border-radius:0;background:transparent;color:#18724c;font-weight:700;box-shadow:none;cursor:default}
.leader-shipment-heading{display:flex;align-items:center;gap:10px;margin:14px 0 4px;font-size:15px;font-weight:800}
.leader-shipment-heading .order-parcel-markers{margin:0}
.leader-shipment-heading .order-parcel-marker{cursor:default}
.leader-shipment-heading+.leader-order-totals{margin:0 0 8px}

.order-card-state.is-partial{min-height:0;padding:0;border:0;border-radius:0;background:transparent;color:#b42318;font-weight:700;box-shadow:none;cursor:default}

/* Desktop reading density; print and smaller viewports retain their existing layout. */
@media screen and (min-width:1024px){
 :root[data-color-profile]{--ui-space-text:6px;--ui-space-field:10px;--ui-space-section:12px;--ui-space-panel:16px}
 :root[data-color-profile] body :is(h1,h2,h3,h4,h5,h6){margin-block:0 8px}
 :root[data-color-profile] body p{margin-block:var(--ui-space-text);line-height:1.4}
 :root[data-color-profile] body :is(ul,ol){margin-block:var(--ui-space-text)}
 :root[data-color-profile] body li{line-height:1.4}
 :root[data-color-profile] body li+li{margin-top:4px}
 :root[data-color-profile] body :is(#mainTotal,#giftTotal){margin-block:var(--ui-space-text)}
 :root[data-color-profile] body :is(th,td){padding-block:6px;line-height:1.4}
 :root[data-color-profile] body :is(th,td)>:is(p,ul,ol):first-child{margin-top:0}
 :root[data-color-profile] body :is(th,td)>:is(p,ul,ol):last-child{margin-bottom:0}
 :root[data-color-profile] body :is(.auth-card,.individual-order-card,.order-card,.state-card,.login-panel,.summary-section,.form-section,.link-box){padding:var(--ui-space-panel)}
 :root[data-color-profile] body .auth-card{min-height:0}
 :root[data-color-profile] body :is(.individual-order-card,.login-panel){margin-block:16px}
 :root[data-color-profile] body :is(.page,.page-shell,.individual-order-page){padding-block:16px 24px}
 :root[data-color-profile] body :is(.site-header,.individual-header){padding-block:12px}
 :root[data-color-profile] body .desktop-app :is(.content,aside){padding-block:var(--ui-space-panel)}
 :root[data-color-profile] body form{row-gap:var(--ui-space-section)}
 :root[data-color-profile] body :is(.auth-panel,.application){row-gap:var(--ui-space-section)}
 :root[data-color-profile] body :is(.summary-fields,.form-grid,.field-grid){gap:var(--ui-space-field)}
 :root[data-color-profile] body :is(.form-section,.summary-section){margin-block:var(--ui-space-section)}
 :root[data-color-profile] body .summary-form>.summary-section{margin:0}
 :root[data-color-profile] body :is(.button-row,.actions,.summary-heading-actions,.summary-delivery-actions,.finance-actions,.finance-export-actions){row-gap:8px}
 :root[data-color-profile] body .finance-actions{gap:var(--ui-space-section)}
 :root[data-color-profile] body .finance-terms-grid{gap:var(--ui-space-section);align-items:start}
 :root[data-color-profile] body .finance-choices{align-items:start}
 :root[data-color-profile] body .finance-terms-warning{padding:var(--ui-space-section);margin-block:var(--ui-space-section)}
 :root[data-color-profile] body :is(.filters,.system-section){margin-block:var(--ui-space-section)}
 :root[data-color-profile] body :is(#pageLead,#orderLead,.catalog-lead,.preview-lead,#warehouseSummaryPreviewMeta){margin-block:var(--ui-space-text)}
 :root[data-color-profile] body #previewState{padding:var(--ui-space-panel)}
 :root[data-color-profile] body.workspace-cabinet .warehouse-panel{padding:var(--ui-space-section)}
 :root[data-color-profile] body .filters{padding:var(--ui-space-section);gap:var(--ui-space-field)}
 :root[data-color-profile] body .login-panel form{margin-top:var(--ui-space-section)}
 :root[data-color-profile] body :is(.product-row,.summary-product-row){margin-block:6px;padding-block:8px}
 :root[data-color-profile] body :is(.summary-products,.product-list){row-gap:8px}
 :root[data-color-profile] body :is(.message,.form-message,.warehouse-message):empty{display:none}
 :root[data-color-profile] body :is(.message,.form-message,.warehouse-message):not(:empty){min-height:0;margin-block:6px;padding-block:6px}
 :root[data-color-profile] body dialog{padding:var(--ui-space-panel)}
 :root[data-color-profile] body dialog:has(>form:only-child){padding:0}
 :root[data-color-profile] body dialog>form:only-child{padding:var(--ui-space-panel)}
 :root[data-color-profile] body dialog>form:not(:only-child){padding:0}
 /* The existing final-review builder supplies these four values inline. */
 :root[data-color-profile] body dialog.vip-final-review{padding:var(--ui-space-panel)!important}
 :root[data-color-profile] body .vip-final-review>h2{margin-bottom:8px!important}
 :root[data-color-profile] body .vip-final-review>div:first-of-type{gap:var(--ui-space-section)!important;align-items:start}
 :root[data-color-profile] body .vip-final-review>p{margin-block:var(--ui-space-text)!important}
 :root[data-color-profile] body #warehouseRefusalDialog{padding:var(--ui-space-panel)!important}
 :root[data-color-profile] body #warehouseRefusalTitle{margin-bottom:8px!important}
 :root[data-color-profile] body :is(.cabinet-settings-heading,.summary-delivery-dialog-heading,.warehouse-section-heading){margin-block:0 8px;padding-bottom:8px}
 :root[data-color-profile] body :is(.cabinet-settings-content>section,.leader-settings-content>section){padding-block:var(--ui-space-section)}
 :root[data-color-profile] body :is(.cabinet-settings-footer,.warehouse-preparation-footer){margin-top:var(--ui-space-section);padding-top:var(--ui-space-section)}
 :root[data-color-profile] body :is(.warehouse-report-section,.warehouse-remainder-section){margin-block:var(--ui-space-section);padding:var(--ui-space-section)}
 :root[data-color-profile] body .warehouse-report-section :is(h3,h4){margin-block:0 8px}
 :root[data-color-profile] body .warehouse-report-section>p{margin-block:6px}
 :root[data-color-profile] body .warehouse-report-section details{margin-block:4px}
 :root[data-color-profile] body .warehouse-report-section summary{line-height:1.4}
 :root[data-color-profile] body .order-fulfillment{padding:var(--ui-space-section)}
 :root[data-color-profile] body .order-fulfillment p:last-child{margin-bottom:0}
 :root[data-color-profile] body .order-fulfillment li+li{margin-top:4px}
 /* Dynamic leader cards: grid gaps and child margins must not add up. */
 :root[data-color-profile] body.workspace-cabinet .leader-order-card{align-content:start}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card>.compact-order-heading{margin-block:0}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card>.order-fulfillment{margin-block:0;padding:8px 10px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card>.order-fulfillment>p:first-child{margin-top:0}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-actions{margin-top:0;padding-top:0;row-gap:6px;align-items:start}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-actions .action-help-wrap{margin-top:0;gap:6px;align-items:center}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-actions .action-help-icon{position:static;transform:none;margin:0;flex:none}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card details[open]{padding-top:6px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card details[open]>summary{margin-bottom:6px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card details p{margin-block:4px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card details time{display:block;margin-block:4px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-contact{margin-block:6px;gap:8px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-contact dd{margin-top:2px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card details h4{margin-block:6px 4px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-items{margin-block:4px 6px;gap:0}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-items li{padding-block:3px}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card .leader-order-items li+li{margin-top:0}
}

/* Shared compact cards on desktop and mobile; retain printable layouts. */
@media screen{
 :root[data-color-profile] body.workspace-cabinet :is(.leader-order-card,.warehouse-summary-card):has(>.compact-order-heading){padding:10px 12px}
 :root[data-color-profile] body.workspace-cabinet :is(.leader-order-card,.warehouse-summary-card)>.compact-order-heading{margin:0;gap:6px 12px}
 :root[data-color-profile] body.workspace-cabinet :is(.leader-order-card,.warehouse-summary-card)>.order-fulfillment{display:flex;flex-wrap:wrap;align-items:center;gap:4px 20px;margin-block:0;padding:7px 10px}
 :root[data-color-profile] body.workspace-cabinet :is(.leader-order-card,.warehouse-summary-card)>.order-fulfillment>p{margin:0}
 :root[data-color-profile] body.workspace-cabinet :is(.leader-order-card,.warehouse-summary-card)>.order-fulfillment>:is(strong,ol){flex-basis:100%;margin-block:0}
}

/* One details control beside the totals, with its content below the card row. */
@media screen{
 :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details{grid-template-columns:minmax(0,1fr) max-content;align-items:start}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details>*{grid-column:1/-1;min-width:0}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details>.order-fulfillment{grid-column:1;grid-row:2;align-self:stretch}
 :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details>.leader-order-details-toggle{grid-column:2;grid-row:2;align-self:center;width:auto;white-space:nowrap;margin:0}
 :root[data-color-profile] body.workspace-cabinet .leader-order-actions:has(>details:only-child:not([open])){display:none}
 .leader-order-actions>details>summary[hidden]{display:none}
 .leader-order-details-short{display:none}
 @media(max-width:600px){
  :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details{grid-template-columns:minmax(0,1fr) 76px}
  :root[data-color-profile] body.workspace-cabinet .leader-order-card.has-inline-details>.leader-order-details-toggle{grid-column:2;grid-row:2;justify-self:stretch;width:100%;min-width:0;min-height:44px;padding:6px 4px;font-size:13px;line-height:1.2;white-space:normal}
  .leader-order-details-label{display:none}
  .leader-order-details-short{display:inline}
 }
}
