/* Simple editable sheet; full calculators remain supporting tools. */
:root{--m3-primary:#07533e;--m3-on-primary:#fff;--m3-primary-container:#e2eee7;--m3-on-primary-container:#123d2f;--m3-secondary-container:#edf2ee;--m3-on-secondary-container:#23382e;--m3-surface:#fff;--m3-surface-container-lowest:#fff;--m3-surface-container-low:#f5f7f5;--m3-surface-container:#edf2ee;--m3-surface-container-high:#e6eee8;--m3-on-surface:#192c23;--m3-on-surface-variant:#52635a;--m3-outline:#728278;--m3-outline-variant:#d6dfd8;--m3-success:#216647;--m3-success-container:#e1f0e5;--m3-warning:#895100;--m3-warning-container:#fff2d8;--m3-error:#b3261e;--m3-error-container:#fbe6e3;--bg:#f5f7f5;--card-bg:#fff;--card-border:#d6dfd8;--text-primary:#192c23;--text-secondary:#52635a;--text-tertiary:#627167;--accent:#07533e;--accent2:#1c6d52;--accent3:#44896a;--accent-soft:#e2eee7;--primary:#07533e;--primary-color:#07533e;--primary-light:#e2eee7;--radius-sm:6px;--radius-md:8px;--radius-lg:10px;--radius-xl:12px;--radius-2xl:12px}
html{background:var(--bg);scroll-padding-top:72px}body{padding:56px 0 0;background:var(--bg);color:var(--text-primary);font-family:Inter,"Microsoft YaHei","PingFang SC",sans-serif;font-size:14px}
*{scrollbar-color:#b3c2b8 #edf2ee;scrollbar-width:thin}::selection{background:#cce3d5;color:#123d2f}input,select,textarea{caret-color:var(--accent)}
body .app-shell,body .background-mesh,body .hero-glow,body .hero::before,body .hero::after,body .task-home{display:none!important}
.cockpit-topbar{position:fixed;inset:0 0 auto;height:56px;display:flex;align-items:center;gap:16px;padding:0 24px;background:#fff;border-bottom:1px solid #d6dfd8;z-index:70;color:#52635a}
.sheet-brand{font-size:18px;font-weight:650;color:#194832;background:none;border:0;padding:8px 0;white-space:nowrap}.sheet-local-note{font-size:12px;color:#627167;margin-right:auto}
.sheet-return{border:1px solid #b4c6b9;border-radius:6px;padding:7px 14px;background:white;color:#23513a;font-size:13px}body[data-workspace=products] .sheet-return{display:none}
.cockpit-topbar .language-switch{position:static;display:flex;background:#f0f4f1;padding:2px;border:0;border-radius:6px;box-shadow:none;backdrop-filter:none}.cockpit-topbar .lang-option{width:34px;min-width:34px;height:28px;min-height:28px;padding:0;color:#52635a;background:transparent;border-radius:4px;font-size:12px}.cockpit-topbar .lang-option.active{background:#deebe1;color:#123d2f;box-shadow:none}#measurementToolState{font-size:12px;color:#52635a}
body .hero,body .container,body .profit-section,body .workbench,body #productWorkbench{max-width:none;width:auto;margin-left:24px;margin-right:24px}body .hero{padding:24px 0;gap:16px}
body .hero-title,body .profit-title{font-size:30px;line-height:1.25;background:none;-webkit-text-fill-color:currentColor;color:#192c23}body .hero-subtitle,body .profit-subtitle{font-size:14px;color:#52635a}
body .input-card,body .profit-card,body .profit-chart-card,body .vc-card,body .decision-command-bar,body .profit-field-group,body .result-card,body .preview-card{background:#fff;border-color:#d6dfd8;border-radius:10px;box-shadow:none;backdrop-filter:none}
body .btn-primary{background:#07533e;color:#fff;border:1px solid #07533e;border-radius:6px;box-shadow:none}body .btn-primary:not(:disabled):hover{background:#03422f}
body .btn-outlined{background:#fff;color:#24533c;border:1px solid #b3c5b8;border-radius:6px;box-shadow:none}body .btn-tonal,body .page-new-calculation{background:#e2eee7;color:#173e2e;border-radius:6px}
body .btn-ghost,body .btn-text,body .icon-action,body .m3-result-action,body .summary-action-link,body .profit-analysis-tab{color:#07533e}body .profit-analysis-tabs{background:#f1f5f1;border-radius:8px}body .profit-analysis-tab.active{background:#e2eee7;color:#173e2e;box-shadow:none}
body input,body select,body textarea{border-color:#c4d0c7;border-radius:6px}body input:focus,body select:focus,body textarea:focus{outline:none;box-shadow:none;border-color:#07533e}body .input-wrapper:focus-within,body .profit-input-wrap:focus-within{border-color:#07533e;box-shadow:none}
body button:focus-visible,body a:focus-visible,body summary:focus-visible,body [tabindex]:focus-visible{outline:2px solid #267253;outline-offset:2px}body button:disabled{opacity:.45;cursor:not-allowed}body .modal-card,body .workbench-drawer{border-radius:10px;border-color:#d6dfd8;background:#fff}body .profit-input-column,body .profit-output-column,body .input-grid{min-width:0}
body #productWorkbench{padding:24px 0 0}body[data-workspace=products]>.app-footer{display:none}
#measurementStatus{font-size:13px;color:#8b4d08;line-height:1.6;margin:12px 0}.ledger-legacy-note{font-size:13px;color:#627167;margin:0 0 16px}
.sheet-dialog,.ledger-dialog{position:fixed;inset:0;margin:auto;width:min(480px,calc(100vw - 32px));max-height:calc(100dvh - 48px);overflow:auto;padding:0;border:1px solid #becfc2;border-radius:12px;background:#fff;color:#223d2f;box-shadow:0 16px 48px #18372633}.sheet-dialog::backdrop,.ledger-dialog::backdrop{background:#16322359}
.ledger-panel>header{display:flex;align-items:center;justify-content:space-between;padding:20px 24px 8px}.ledger-panel h2,.sheet-analysis-head h2{font-size:20px;line-height:1.4;margin:0;font-weight:650}.ledger-panel>header>button,.sheet-analysis-head>button{border:0;background:transparent;font-size:26px;color:#52635a;width:36px;height:36px;flex-shrink:0}
.ledger-panel>p{padding:0 24px 16px;margin:0;font-size:12px;color:#627167;border-bottom:1px solid #e1e9e3}.ledger-panel-fields{padding:20px 24px}.ledger-panel fieldset{padding:0;margin:0;border:0;display:grid;gap:16px;min-width:0}.ledger-panel label{display:grid;gap:6px;font-size:13px;min-width:0}.ledger-panel input:not([type=checkbox]):not([type=file]),.ledger-panel select{width:100%;height:40px;min-height:40px;padding:8px 10px;border:1px solid #c4d0c7;background:#fff;color:#223d2f;font-size:14px;border-radius:6px}.ledger-panel fieldset>p{font-size:12px;color:#627167;line-height:1.7;margin:0}
.ledger-panel>footer{padding:16px 24px;display:flex;justify-content:flex-end;gap:8px;border-top:1px solid #e1e9e3}.ledger-panel>footer>button,.ledger-panel .btn-outlined{padding:8px 16px;height:40px;min-height:40px;width:auto;margin:0;font-size:13px}.ledger-panel .ledger-check{display:flex;align-items:center;gap:8px}.ledger-check input{width:16px;height:16px;accent-color:#216647}
#measurementPanelError{font-size:13px;color:#a32e23;margin:0;line-height:1.5}#measurementPanelError:not(:empty){margin-top:16px}
.sheet-expense-row{display:grid;grid-template-columns:1.5fr 1fr;gap:12px}.sheet-net-output{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;border-top:1px solid #dde7df;padding-top:16px}.sheet-net-output>div{display:grid;gap:8px;font-size:12px}.sheet-net-output strong{font-size:17px;font-variant-numeric:tabular-nums}
.ledger-image-tools{display:flex;align-items:stretch;gap:16px}.ledger-image-preview{width:80px;min-height:100px;flex-shrink:0;border:1px solid #dde6df;border-radius:6px;display:flex;align-items:center;justify-content:center}.ledger-drop{border:1px dashed #9bb4a4;border-radius:6px;padding:16px;display:flex!important;flex:1;align-items:center;justify-content:center;text-align:center;gap:8px!important;cursor:pointer;font-size:12px;line-height:1.6}.ledger-drop:hover{background:#f1f6f1}.ledger-drop input{position:absolute;width:1px;height:1px;opacity:0}.ledger-drop small{font-size:11px;color:#627167}.ledger-image-section>button{border:0;background:none;color:#86500b;font-size:12px;padding:8px 0}
.ledger-image-preview img,.sheet-analysis-image img{width:100%;height:100%;object-fit:contain}
.ledger-dialog{padding:24px}.ledger-dialog h2{font-size:22px;margin-bottom:20px}.ledger-dialog label{display:grid;gap:8px;margin:16px 0}.ledger-dialog input,.ledger-dialog select{width:100%;height:40px;padding:8px}.ledger-dialog p{font-size:13px;color:#627167;line-height:1.6}.ledger-dialog footer{display:flex;justify-content:flex-end;gap:8px;margin-top:24px}.ledger-dialog button{padding:8px 16px;border:1px solid #c4d0c7;border-radius:6px;font-size:14px}
.sheet-analysis-dialog{width:min(880px,calc(100vw - 32px));padding:24px}.sheet-analysis-head{display:flex;align-items:center;gap:16px;margin-bottom:24px}.sheet-analysis-head>div{flex:1;min-width:0}.sheet-analysis-head h2{overflow-wrap:anywhere}.sheet-analysis-head p{font-size:12px;color:#627167;margin:6px 0 0}.sheet-analysis-image{width:52px;height:60px;display:flex;align-items:center;justify-content:center;border:1px solid #e1e8e2;border-radius:6px;flex-shrink:0}
.sheet-analysis-metrics{display:grid;grid-template-columns:repeat(3,1fr);border:1px solid #dfe8e1;border-radius:8px;overflow:hidden}.sheet-analysis-metrics>div{display:grid;gap:8px;padding:20px;background:#f5f8f4;min-width:0}.sheet-analysis-metrics>div+div{border-left:1px solid #dfe8e1}.sheet-analysis-metrics span{font-size:13px;color:#52635a}.sheet-analysis-metrics strong{font-size:30px;font-weight:650;line-height:1.25;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.sheet-analysis-metrics small{font-size:12px;color:#627167}.sheet-risk{font-size:13px;color:#52635a;line-height:1.6;margin:16px 0 24px}
.sheet-analysis-tabs{display:flex;border-bottom:1px solid #dfe8e1;margin-bottom:24px;gap:24px}.sheet-analysis-tabs button{border:0;border-bottom:2px solid transparent;background:none;padding:12px 0;font-size:14px;color:#627167}.sheet-analysis-tabs button[aria-selected=true]{border-bottom-color:#216647;color:#145b37;font-weight:650}
#sheetAnalysisContent{min-height:240px;font-size:14px;line-height:1.8}#sheetAnalysisContent .profit-cost-visual{background:transparent}#sheetAnalysisContent ul{padding-left:20px}#sheetAnalysisContent li{margin-bottom:16px}.sheet-basis dt{font-size:12px;color:#627167;margin-top:16px}.sheet-basis dd{margin:4px 0 0;overflow-wrap:anywhere}.sheet-analysis-empty{padding:24px 0;color:#627167;line-height:1.7}
@media(max-width:839px){.cockpit-topbar{padding:0 16px;gap:12px}.sheet-local-note{display:none}.sheet-brand{margin-right:auto;font-size:17px}#measurementToolState{display:none}body .hero,body .container,body .profit-section,body .workbench,body #productWorkbench{margin-left:16px;margin-right:16px}body #productWorkbench{padding-top:16px}.sheet-analysis-dialog{padding:20px}.sheet-analysis-head{gap:12px;margin-bottom:16px}.sheet-analysis-head h2{font-size:18px}.sheet-analysis-metrics>div{padding:12px 8px;gap:8px}.sheet-analysis-metrics strong{font-size:21px}.sheet-analysis-metrics span,.sheet-analysis-metrics small{font-size:11px}.sheet-analysis-tabs{gap:20px}.sheet-analysis-tabs button{font-size:13px}.ledger-panel>header{padding:16px 20px 8px}.ledger-panel>p{padding:0 20px 16px}.ledger-panel-fields{padding:16px 20px}.ledger-panel>footer{padding:16px 20px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;animation:none!important;transition:none!important}}
.sheet-fba-method{display:flex;gap:8px;margin-bottom:4px}.sheet-fba-method>button{border:0;border-radius:5px;background:transparent;color:#52635a;padding:7px 12px;font-size:12px}.sheet-fba-method>button[aria-pressed=true]{background:#e2eee7;color:#174b33;font-weight:650}
.sheet-package-dimensions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.sheet-package-main{display:grid;grid-template-columns:1fr 1.4fr;gap:16px}.sheet-package-more summary{cursor:pointer;font-size:12px;color:#52635a;padding:4px 0}.sheet-package-more>div{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:12px}
#measurementPanel .sheet-package-precise{font-size:12px;font-variant-numeric:tabular-nums}
#measurementPanel .sheet-package-dimensions input{appearance:textfield;padding-left:6px;padding-right:6px}
#measurementPanel .sheet-package-dimensions input::-webkit-inner-spin-button,#measurementPanel .sheet-package-dimensions input::-webkit-outer-spin-button{appearance:none;margin:0}
.sheet-fba-estimate{border-top:1px solid #d6dfd8;padding-top:20px;margin-top:4px}.sheet-fba-estimate>div{display:flex;align-items:baseline;justify-content:space-between;gap:16px}.sheet-fba-estimate strong{font-size:16px}.sheet-fba-estimate strong+strong{font-size:26px;font-variant-numeric:tabular-nums}.sheet-fba-estimate p{font-size:12px;line-height:1.6;color:#627167;margin:8px 0 0}.sheet-fba-estimate .sheet-fee-warning{color:#895100}
.sheet-composition-note{font-size:12px;line-height:1.7;color:#52635a;margin:16px 0 0}.sheet-composition-note.is-loss{color:#ac2e24}

.sheet-column-dialog{width:min(440px,calc(100vw - 32px));padding:24px}.sheet-column-dialog header,.sheet-templates-dialog>header{display:flex;align-items:center;justify-content:space-between;gap:16px}.sheet-column-dialog h2,.sheet-templates-dialog h2{font-size:20px;margin:0}.sheet-column-dialog header button,.sheet-templates-dialog>header>button{width:36px;height:36px;border:0;background:none;color:#52635a;font-size:24px}.sheet-column-sort{display:flex;gap:8px;flex-wrap:wrap;margin:16px 0}.sheet-column-sort button{padding:8px 12px;border:1px solid #c4d0c7;background:#f5f8f4;color:#23513a;border-radius:6px;font-size:13px}.sheet-column-dialog p{font-size:12px;line-height:1.7;color:#52635a}.sheet-column-dialog label{display:grid;gap:8px;font-size:13px;margin:16px 0}.sheet-column-dialog input:not([type=checkbox]),.sheet-column-dialog select{width:100%;height:40px;border:1px solid #c4d0c7;padding:8px;border-radius:6px;background:white}.sheet-filter-range{display:grid;grid-template-columns:1fr 1fr;gap:16px}.sheet-filter-choices{border:1px solid #d6dfd8;border-radius:8px;padding:8px 16px;display:grid;grid-template-columns:1fr 1fr;gap:0 16px}.sheet-filter-choices legend{font-size:12px;color:#52635a}.sheet-filter-choices label{display:flex;align-items:center;gap:8px;margin:8px 0}.sheet-column-dialog footer{display:flex;justify-content:space-between;gap:8px;margin-top:24px}.sheet-column-dialog footer button{font-size:13px;border:1px solid #c4d0c7;padding:8px 12px;border-radius:6px}.sheet-column-error,.sheet-template-error{color:#a32e23!important;line-height:1.6}
.sheet-templates-dialog{width:min(960px,calc(100vw - 32px))}.sheet-templates-dialog>header{padding:20px 24px;border-bottom:1px solid #dfe7e1}.sheet-template-layout{display:grid;grid-template-columns:240px minmax(0,1fr)}.sheet-template-layout>aside{padding:16px;border-right:1px solid #dfe7e1;background:#f8faf7;display:flex;flex-direction:column;gap:24px}.sheet-template-list{display:grid;gap:8px;max-height:420px;overflow:auto}.sheet-template-list button{border:1px solid transparent;border-radius:6px;padding:12px;text-align:left;background:none;color:#223d2f;display:grid;gap:6px;overflow-wrap:anywhere;min-height:48px}.sheet-template-list button[aria-pressed=true]{background:#e2eee7;border-color:#c5d7ca}.sheet-template-list small{font-size:12px;color:#52635a}.sheet-template-actions{display:flex;gap:8px;margin-top:auto;flex-wrap:wrap}.sheet-template-actions button{border:0;background:none;font-size:13px;color:#23513a;padding:8px 4px}.sheet-template-layout form{padding:24px;min-width:0}.sheet-template-layout form>label,.sheet-template-fields label{display:grid;gap:8px;font-size:13px}.sheet-template-layout input:not([type=checkbox]){width:100%;height:40px;border:1px solid #c4d0c7;border-radius:6px;padding:8px 12px;font-size:14px;color:#223d2f;background:white}.sheet-template-layout input[readonly]{background:#f5f7f5;color:#52635a}.sheet-template-fields{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:24px}.sheet-template-total{display:flex;gap:16px;align-items:center;flex-wrap:wrap;padding:16px;background:#f1f6ef;border-radius:8px;margin-top:24px;font-size:13px}.sheet-template-total strong{font-size:20px;color:#23513a}.sheet-template-total small{margin-left:auto;color:#52635a;font-size:12px}.sheet-template-layout form p{font-size:12px;line-height:1.7;color:#627167;margin-top:16px}.sheet-template-layout form footer{display:flex;align-items:center;gap:8px;margin-top:24px;flex-wrap:wrap}.sheet-template-default{display:flex;align-items:center;gap:8px;font-size:12px;margin-right:auto}.sheet-template-layout form footer button{font-size:13px;padding:8px 12px;height:40px;min-height:40px;width:auto;margin-bottom:0}.sheet-template-default input{accent-color:#216647;width:16px;height:16px}
.sheet-image-dialog{width:min(720px,calc(100vw - 32px))}.sheet-image-dialog .ledger-image-tools{display:grid;gap:16px}.sheet-image-dialog .ledger-image-preview{width:100%;height:clamp(220px,48dvh,520px);border:0;background:#f8faf7;border-radius:8px;overflow:hidden}.sheet-image-dialog .ledger-image-preview>svg{width:48px;height:48px;color:#8b9e90}.sheet-image-dialog .ledger-drop{min-height:72px;flex-direction:row;flex-wrap:wrap;padding:12px}.sheet-image-dialog .ledger-drop small{width:100%}.sheet-image-dialog .ledger-image-section>button{color:#a32e23}.sheet-analysis-head>.sheet-analysis-image{width:80px;height:80px;padding:0;border:1px solid #dfe7e1;border-radius:8px;background:#fff;overflow:hidden}.sheet-analysis-image>span{width:100%;height:100%;display:flex;align-items:center;justify-content:center}.sheet-analysis-head>.sheet-analysis-close{width:36px;height:36px}.sheet-analysis-dialog .profit-donut-center strong{white-space:normal;overflow-wrap:anywhere;font-size:clamp(16px,2vw,24px);line-height:1.25;max-width:100%}.sheet-composition-heading{font-size:12px;color:#52635a;text-align:right;margin:0 0 12px}.sheet-analysis-dialog .profit-donut-tooltip{width:224px;font-size:12px}.sheet-analysis-dialog .profit-donut-tooltip strong{white-space:normal;overflow-wrap:anywhere}.sheet-analysis-dialog .profit-donut-tooltip b{white-space:nowrap}.sheet-analysis-dialog .profit-chart-legend-row small{min-width:64px}
.sheet-template-layout form footer button,.sheet-column-dialog footer button{display:inline-flex;align-items:center;justify-content:center;margin:0;line-height:20px;min-height:40px;box-sizing:border-box}.sheet-template-layout form footer .btn-primary{margin:0}.sheet-column-dialog footer .btn-primary{margin:0;width:auto}.sheet-column-dialog footer{align-items:center}
@media(max-width:839px){.sheet-template-layout{grid-template-columns:1fr}.sheet-template-layout>aside{border-right:0;border-bottom:1px solid #dfe7e1;gap:12px;padding:16px}.sheet-template-list{display:flex;overflow:auto;max-height:none}.sheet-template-list button{min-width:150px;max-width:200px;flex-shrink:0}.sheet-template-actions{margin:0}.sheet-template-layout form{padding:20px}.sheet-template-fields{gap:16px 12px}.sheet-template-total{gap:8px 16px}.sheet-template-total small{width:100%;margin:0}.sheet-analysis-head>.sheet-analysis-image{width:64px;height:64px}.sheet-analysis-dialog .profit-chart-legend-row{grid-template-columns:10px minmax(50px,1fr) auto 64px;gap:8px}}
/* One table system. Column widths live in measurements.js, not positional selectors. */
body[data-workspace=products]{background:#f6f7f8}
.cockpit-topbar .sheet-brand{font-family:inherit;font-size:18px;font-weight:650;line-height:24px;display:flex;align-items:center;gap:10px}
.sheet-brand-mark{display:inline-flex;color:#146347}.sheet-brand-mark svg{width:24px;height:24px}
#productWorkbench{--sheet-font:14px;--sheet-label:13px;--sheet-note:12px;--sheet-row:80px;--sheet-header:48px;--sheet-control:36px;--sheet-ink:#26342e;--sheet-muted:#606e66;--sheet-grid:#e7ece8;--sheet-surface:#fff;--sheet-result:#f3f7f4;color:var(--sheet-ink)}
#productWorkbench button,#productWorkbench input,#productWorkbench select,#productWorkbench summary{font-family:inherit;letter-spacing:normal;text-transform:none}
#productWorkbench .sheet-toolbar{display:flex;align-items:center;justify-content:space-between;gap:24px;min-height:48px;margin-bottom:16px}
#productWorkbench .sheet-toolbar>input{width:min(360px,30vw);height:var(--sheet-control);min-height:var(--sheet-control);padding:8px 12px;margin:0;border:1px solid #ced7d1;border-radius:8px;background:#fff;font-size:14px;line-height:20px}
#productWorkbench .sheet-toolbar-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
#productWorkbench .sheet-toolbar-actions>button,#productWorkbench .ledger-tools>summary{display:inline-flex;align-items:center;justify-content:center;gap:8px;width:auto;height:var(--sheet-control);min-height:var(--sheet-control);padding:7px 14px;margin:0;font-size:14px;line-height:20px;font-weight:500;box-shadow:none}
#productWorkbench .sheet-save-state{font-size:12px;line-height:20px;color:var(--sheet-muted);white-space:nowrap}
#productWorkbench .ledger-tools{position:relative}
#productWorkbench .ledger-tools>summary{list-style:none;cursor:pointer;border:1px solid #ced7d1;border-radius:6px;background:#fff;color:var(--sheet-ink)}
#productWorkbench summary::-webkit-details-marker{display:none}
#productWorkbench .ledger-tools>div{position:absolute;right:0;top:calc(100% + 8px);min-width:180px;padding:8px;background:#fff;border:1px solid #d5ded8;border-radius:8px;box-shadow:0 8px 24px #1837261c;z-index:35}
#productWorkbench .ledger-tools>div>button,.sheet-row-menu>button{display:block;width:100%;min-height:36px;padding:8px 12px;border:0;border-radius:4px;background:none;color:#26342e;text-align:left;font-size:14px;line-height:20px;white-space:nowrap}
#productWorkbench .ledger-tools>div>button:hover,.sheet-row-menu>button:hover{background:#f0f5f1}
#productWorkbench .sheet-ad-editor{display:flex;align-items:center;gap:4px;min-width:0;width:100%}
#productWorkbench .sheet-ad-editor>.sheet-amount{flex:1;min-width:0}
#productWorkbench .sheet-ad-helper{flex:none;width:24px;min-width:24px;min-height:36px;padding:2px;border:0;background:none;color:#547467;display:flex;align-items:center;justify-content:center}
#productWorkbench .sheet-ad-helper svg{width:16px;height:16px}
.sheet-ad-allocation{margin-top:16px}.sheet-ad-allocation>summary{cursor:pointer;color:#146347;font-size:14px}.sheet-ad-allocation>div{display:grid;gap:16px;padding-top:16px}
#profitAdUnitWrap:not([hidden]){display:flex;gap:8px;align-items:center}#profitAdUnitWrap input{min-width:0;flex:1}#profitAdUnitWrap select{width:96px;flex:none}
@media(max-width:839px){#productWorkbench .sheet-toolbar-actions{position:relative}#productWorkbench .ledger-tools{position:static}}
.sheet-row-menu{position:fixed;inset:auto;margin:0;min-width:180px;max-width:calc(100vw - 24px);padding:8px;background:#fff;border:1px solid #d5ded8;border-radius:8px;box-shadow:0 8px 24px #1837261c;font-family:inherit;color:#26342e}
#productWorkbench .ledger-table-panel{border:1px solid #d9e1dc;border-radius:8px;background:#fff;overflow:visible}
#productWorkbench .ledger-scroll{overflow:auto;max-height:calc(100dvh - 210px);min-height:240px;border-radius:8px 8px 0 0}
#productWorkbench .ledger-table{width:100%;min-width:var(--sheet-table-width);border-collapse:separate;border-spacing:0;table-layout:fixed;font-size:var(--sheet-font);font-variant-numeric:tabular-nums}
#productWorkbench .ledger-table th,#productWorkbench .ledger-table td{box-sizing:border-box;height:var(--sheet-row);padding:11px 12px;border-right:1px solid var(--sheet-grid);border-bottom:1px solid var(--sheet-grid);background:#fff;color:var(--sheet-ink);vertical-align:middle;text-align:left;font-family:inherit;font-size:var(--sheet-font);line-height:20px;font-weight:400;overflow:visible}
#productWorkbench .ledger-table thead th{position:sticky;top:0;z-index:6;height:var(--sheet-header);padding:0;background:#f5f7f6;text-align:center;font-size:var(--sheet-label);line-height:20px;font-weight:600;white-space:nowrap}
#productWorkbench .ledger-table thead th>button{position:relative;display:flex;align-items:center;justify-content:center;width:100%;height:calc(var(--sheet-header) - 1px);min-height:calc(var(--sheet-header) - 1px);padding:0 24px;border:0;border-radius:0;margin:0;background:transparent;color:inherit;font-family:inherit;font-size:var(--sheet-label);line-height:20px;font-weight:600;text-align:center;box-shadow:none}
#productWorkbench .sheet-header-label{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#productWorkbench .sheet-header-indicator{position:absolute;right:6px;top:50%;display:flex;align-items:center;justify-content:center;width:16px;height:16px;transform:translateY(-50%);color:#66756c;pointer-events:none}
#productWorkbench .sheet-header-indicator svg{width:14px;height:14px}
#productWorkbench .ledger-table thead th>button:hover{background:#eaf0ec}
#productWorkbench .ledger-table thead th>button.is-filtered{color:#07533e}
#productWorkbench .ledger-table thead th>button.is-filtered .sheet-header-indicator{color:#07533e}
#productWorkbench .ledger-table .ledger-product{position:sticky;left:0;z-index:3;border-right-color:#d9e1dc}
#productWorkbench .ledger-table thead .ledger-product{z-index:9}
#productWorkbench .ledger-table .sheet-row-number{padding:0 4px;font-size:12px;color:var(--sheet-muted);text-align:center}
#productWorkbench .ledger-table tbody tr:hover>td,#productWorkbench .ledger-table tbody tr:hover>th{background:#f8faf8}
#productWorkbench .ledger-table tbody tr.is-dirty>.sheet-row-number{background:#eaf3ec;color:#07533e;font-weight:600}
#productWorkbench .sheet-cell{display:grid;grid-template-rows:36px 20px;width:100%;min-width:0;height:56px;align-content:center}
#productWorkbench .sheet-cell-main{display:flex;align-items:center;justify-content:flex-start;gap:0;min-width:0;height:36px;white-space:nowrap}
#productWorkbench .sheet-cell-note{height:20px;min-width:0;overflow:hidden;font-size:var(--sheet-note);font-weight:400;line-height:20px;color:var(--sheet-muted);white-space:nowrap;text-overflow:ellipsis}
#productWorkbench .ledger-number .sheet-cell-main{justify-content:flex-end}
#productWorkbench .ledger-number .sheet-cell-note{text-align:right}
#productWorkbench .sheet-center .sheet-cell-main,#productWorkbench .sheet-cell-main:has(>.sheet-muted){justify-content:center}
#productWorkbench .sheet-center .sheet-cell-note{text-align:center}
#productWorkbench .ledger-product-wrap{display:flex;align-items:center;gap:12px;min-width:0;height:56px}
#productWorkbench .ledger-product-wrap>.sheet-cell{flex:1}
#productWorkbench .ledger-thumbnail{display:flex;align-items:center;justify-content:center;flex:0 0 48px;width:48px;height:48px;padding:0;border:1px solid #e2e8e3;border-radius:6px;background:#f7f9f7;color:#74877b}
#productWorkbench .ledger-thumbnail>span{display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;border-radius:5px}
#productWorkbench .ledger-thumbnail img{width:100%;height:100%;object-fit:contain}
#productWorkbench .ledger-table input,#productWorkbench .ledger-table select{box-sizing:border-box;width:100%;min-width:0;height:var(--sheet-control);min-height:var(--sheet-control);padding:6px 8px;margin:0;border:0;border-radius:4px;background-color:transparent;box-shadow:none;color:var(--sheet-ink);font-family:inherit;font-size:var(--sheet-font);line-height:24px;font-weight:400;letter-spacing:normal}
#productWorkbench .ledger-table input{outline:1px solid transparent;outline-offset:-1px}
#productWorkbench .ledger-table input::placeholder{color:#66756c;opacity:1}
#productWorkbench .ledger-table input:focus{background-color:#fff;outline-color:#146347;box-shadow:none}
#productWorkbench .ledger-product input{font-weight:600;text-align:left;text-overflow:ellipsis;padding-left:0}
#productWorkbench .ledger-table input[type=number]{appearance:textfield;text-align:right}
#productWorkbench .ledger-table input::-webkit-inner-spin-button,#productWorkbench .ledger-table input::-webkit-outer-spin-button{appearance:none;margin:0}
#productWorkbench .ledger-table select{appearance:none;padding-right:24px;outline:1px solid transparent;outline-offset:-1px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m5 6 3 3 3-3' fill='none' stroke='%2366756c' stroke-width='1.5'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 6px center;background-size:14px}
#productWorkbench .ledger-table select:focus{outline-color:#146347;background-color:#fff}
#productWorkbench [data-column=market] select{text-align:center;text-align-last:center}
#productWorkbench .ledger-table .sheet-mode{width:100%;height:28px;min-height:28px;padding-top:2px;padding-bottom:2px;font-size:12px;font-weight:500;text-align:center;text-align-last:center;border-radius:5px}
#productWorkbench .sheet-mode.sc{background-color:#eaf0f7;color:#345375}
#productWorkbench .sheet-mode.vc{background-color:#efebf5;color:#61477d}
#productWorkbench .sheet-mode-fba,#productWorkbench .sheet-muted{font-size:13px;color:var(--sheet-muted)}
#productWorkbench .sheet-amount{position:relative;width:100%;min-width:0;height:36px;outline:1px solid transparent;outline-offset:-1px;border-radius:4px}
#productWorkbench .sheet-amount-display{display:flex;align-items:center;justify-content:flex-end;height:36px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:var(--sheet-font);line-height:24px;pointer-events:none}
#productWorkbench .sheet-amount-editor{position:absolute;inset:0;display:grid;grid-template-columns:1fr;align-items:center;min-width:0;height:36px}
#productWorkbench .sheet-amount-editor>input{width:100%;height:36px;opacity:0;cursor:text}
#productWorkbench .sheet-amount-editor>select,#productWorkbench .sheet-amount-editor>small{display:none}
#productWorkbench .sheet-amount:hover{background:#f0f5f1}
#productWorkbench .sheet-amount:focus-within{outline-color:#146347;background:#fff}
#productWorkbench .sheet-amount:focus-within .sheet-amount-display{visibility:hidden}
#productWorkbench .sheet-amount:focus-within .sheet-amount-editor{grid-template-columns:minmax(0,1fr) 48px}
#productWorkbench .sheet-amount.has-unit:focus-within .sheet-amount-editor{grid-template-columns:minmax(0,1fr) 16px}
#productWorkbench .sheet-amount:focus-within .sheet-amount-editor>input{opacity:1;outline:none;background:transparent;padding:6px}
#productWorkbench .sheet-amount:focus-within .sheet-amount-editor>select{display:block;padding:6px 12px 6px 2px;font-size:12px;background-position:right 0 center;background-size:12px}
#productWorkbench .sheet-amount:focus-within .sheet-amount-editor>small{display:block;font-size:12px;text-align:center}
#productWorkbench .ledger-cell-button{display:flex;align-items:center;justify-content:flex-end;gap:8px;width:100%;min-width:0;height:36px;min-height:36px;padding:0;border:0;border-radius:4px;margin:0;background:transparent;color:var(--sheet-ink);font-family:inherit;font-size:var(--sheet-font);line-height:24px;font-weight:400;text-align:right;box-shadow:none}
#productWorkbench .ledger-cell-button>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#productWorkbench .ledger-cell-button>svg{width:14px;height:14px;flex-shrink:0;color:#687b6e}
#productWorkbench .ledger-cell-button:hover{background:#edf4ef}
#productWorkbench .sheet-other-button:hover{outline:1px solid #c6d8cc;outline-offset:-1px}
#productWorkbench .sheet-invoice-button{display:block;width:100%;height:20px;min-height:20px;margin:0;padding:0;border:0;border-radius:0;background:none;font-size:12px;line-height:20px;font-weight:400;color:var(--sheet-muted);text-align:right;text-decoration:none;box-shadow:none}
#productWorkbench .sheet-invoice-button:hover{text-decoration:underline;text-underline-offset:3px;color:#07533e}
#productWorkbench .sheet-contract-select{text-align:left;text-align-last:left;padding-left:0}
#productWorkbench .sheet-contract-cell .sheet-cell-note{text-align:left}
#productWorkbench .ledger-operations .sheet-cell-main{gap:4px}
#productWorkbench .ledger-operations .sheet-cell-main>button{height:36px;min-height:36px;margin:0;padding:6px 4px;border:0;border-radius:4px;background:none;color:#24533c;font-size:14px;font-weight:400;line-height:24px}
#productWorkbench .ledger-operations .sheet-row-more{display:flex;align-items:center;justify-content:center;width:28px;height:36px;padding:0;border:0;background:transparent}
#productWorkbench .sheet-row-more svg{width:18px;height:18px}
#productWorkbench .ledger-table .sheet-gross-result,#productWorkbench .ledger-table .sheet-margin-result{position:sticky;z-index:4;background:var(--sheet-result)}
#productWorkbench .ledger-table .sheet-gross-result{right:128px;border-left:1px solid #d4e0d8}
#productWorkbench .ledger-table .sheet-margin-result{right:0}
#productWorkbench .ledger-table thead .sheet-gross-result,#productWorkbench .ledger-table thead .sheet-margin-result{z-index:9;background:#eff4f0;font-size:var(--sheet-label);font-weight:600}
#productWorkbench .ledger-table tbody tr:hover>.sheet-gross-result,#productWorkbench .ledger-table tbody tr:hover>.sheet-margin-result{background:#edf4ee}
#productWorkbench .sheet-outcome{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;font-size:16px;font-weight:650;line-height:24px;color:var(--sheet-ink)}
#productWorkbench .sheet-outcome.loss,#productWorkbench .sheet-outcome.is-loss,#productWorkbench .is-loss{color:#b3261e}
#productWorkbench .sheet-outcome.risk,#productWorkbench .sheet-outcome.low{color:#895100}
#productWorkbench .sheet-add-row td{height:48px;padding:6px 12px;text-align:left}
#productWorkbench .sheet-add-row button{display:inline-flex;align-items:center;gap:8px;height:36px;padding:6px 8px;margin:0;border:0;border-radius:4px;background:none;color:#146347;font-size:14px;font-weight:500;line-height:24px}
#productWorkbench .sheet-empty{height:80px;padding:24px;text-align:left;color:var(--sheet-muted)}
#productWorkbench .ledger-table-panel>footer{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:52px;padding:12px 16px;font-size:12px;line-height:20px;color:var(--sheet-muted)}
#productWorkbench .ledger-table-panel>footer>div{display:flex;align-items:center;gap:12px}
#productWorkbench .ledger-table-panel>footer button{min-height:28px;padding:3px 8px;border:1px solid #d9e1dc;border-radius:4px;background:#fff;color:var(--sheet-muted);font-size:12px}
#productWorkbench .sheet-filter-status{display:flex;align-items:center;gap:12px;margin:-4px 0 12px;font-size:12px;line-height:20px;color:var(--sheet-muted)}
#productWorkbench .sheet-filter-status button{border:0;background:none;color:#07533e;text-decoration:underline;padding:4px}
#productWorkbench #measurementStatus{color:var(--sheet-muted)}
@media(max-width:1199px){#productWorkbench .ledger-table .sheet-gross-result,#productWorkbench .ledger-table .sheet-margin-result{position:static}}
@media(max-width:839px){#productWorkbench .sheet-toolbar{align-items:stretch;flex-direction:column;gap:12px}#productWorkbench .sheet-toolbar>input{width:100%}#productWorkbench .sheet-toolbar-actions{gap:8px}#productWorkbench .sheet-save-state{margin-left:auto}#productWorkbench .ledger-scroll{max-height:calc(100dvh - 280px)}#productWorkbench .ledger-table-panel>footer{flex-direction:column;align-items:flex-start;gap:8px;padding:12px 16px}}
@media(max-width:600px){#productWorkbench .sheet-toolbar-actions{display:grid;grid-template-columns:1fr 1fr auto}#productWorkbench .sheet-toolbar-actions>button,#productWorkbench .ledger-tools>summary{padding:7px 10px;font-size:13px}#productWorkbench .sheet-save-state{grid-column:1;margin:0}#productWorkbench .sheet-toolbar-actions>.btn-primary{grid-column:2;width:100%}#productWorkbench .sheet-toolbar-actions>.ledger-tools{grid-column:3}}

/* Brand ribbon: one quiet moving surface, spreadsheet remains a flat work area. */
body[data-workspace=products] #productWorkbench{margin:0;padding:0}
body[data-workspace=products] .cockpit-topbar,
#productWorkbench .sheet-toolbar,.sheet-analysis-head{position:relative;isolation:isolate;background:#064a38;color:#fff}
body[data-workspace=products] .cockpit-topbar{position:fixed;border-bottom:0}
body[data-workspace=products] .cockpit-topbar::before,
#productWorkbench .sheet-toolbar::before,.sheet-analysis-head::before{content:"";position:absolute;inset:0;z-index:-1;background:url("assets/profit-ribbons.svg?v=20261106-contours") center top/120% 128px no-repeat;animation:sheet-ribbons 48s ease-in-out infinite alternate;pointer-events:none}
#productWorkbench .sheet-toolbar::before{--ribbon-y:-56px}
.sheet-analysis-head::before{background-image:url("assets/profit-card-ribbons.svg?v=20261106-contours");background-size:110% 100%}
@keyframes sheet-ribbons{from{background-position:42% var(--ribbon-y,0px)}to{background-position:58% var(--ribbon-y,0px)}}
body[data-workspace=products] .cockpit-topbar .sheet-brand,
body[data-workspace=products] .sheet-brand-mark{color:#fff}
body[data-workspace=products] .sheet-local-note{color:#d1e6dc}
body[data-workspace=products] .cockpit-topbar .language-switch{border-radius:24px;background:#ffffff1a;border:1px solid #accabd}
body[data-workspace=products] .cockpit-topbar .lang-option{color:#e2efe8;border-radius:20px}
body[data-workspace=products] .cockpit-topbar .lang-option.active{background:#fff;color:#164633}
#productWorkbench .sheet-toolbar{z-index:20;min-height:56px;padding:8px 24px 16px;margin:0;gap:16px}
#productWorkbench .sheet-toolbar>input{width:min(300px,25vw);background:#fff;border-color:#fff;border-radius:24px}
#productWorkbench .sheet-toolbar-actions{gap:8px}
#productWorkbench .sheet-toolbar-actions>button,#productWorkbench .ledger-tools>summary{border-radius:24px;border:1px solid #b5cfc0;background:#ffffff10;color:#fff}
#productWorkbench .sheet-toolbar-actions>.btn-primary{background:#fff;border-color:#fff;color:#064a38;font-weight:650}
#productWorkbench .sheet-toolbar-actions>.btn-primary:disabled{background:#ffffff12;color:#c7ded1;opacity:.7}
#productWorkbench .sheet-toolbar-actions>button:hover:not(:disabled),#productWorkbench .ledger-tools>summary:hover{background:#e6f0e9;color:#064a38}
#productWorkbench .sheet-toolbar-actions>.sheet-delete-selected{background:#fff3ed;color:#a12e23;border-color:#f0d6cc}
#productWorkbench .sheet-save-state{color:#d6e8de;margin:0 4px}
#productWorkbench .ledger-table-panel{margin:16px 24px 0}
#productWorkbench .sheet-filter-status,#productWorkbench .ledger-legacy-note,#productWorkbench #measurementStatus{margin:12px 24px}
#productWorkbench .ledger-scroll{max-height:calc(100dvh - 212px)}
#productWorkbench .ledger-table tbody tr.is-selected>td,#productWorkbench .ledger-table tbody tr.is-selected>th{background:#eaf3ed}
#productWorkbench .sheet-row-select{position:relative;display:flex;align-items:center;justify-content:center;height:36px;cursor:pointer}
#productWorkbench .sheet-row-select input[type=checkbox]{position:absolute;inset:10px auto auto;width:16px;height:16px;min-height:16px;padding:0;opacity:0;accent-color:#146347;cursor:pointer}
#productWorkbench .sheet-row-select:has(:checked)>span,#productWorkbench tr:hover .sheet-row-select>span,#productWorkbench .sheet-row-select:focus-within>span{visibility:hidden}
#productWorkbench .sheet-row-select input:checked,#productWorkbench tr:hover .sheet-row-select input,#productWorkbench .sheet-row-select input:focus-visible{opacity:1}
#productWorkbench input[data-select-page]{width:16px;height:16px;min-height:16px;padding:0;accent-color:#146347}
#productWorkbench .sheet-row-select input:disabled{display:none}

/* Read-only analysis deck. Back cards are decorative and never intercept input. */
.sheet-analysis-dialog{width:min(764px,calc(100vw - 32px));max-height:calc(100dvh - 24px);padding:28px 72px 8px;background:transparent;border:0;box-shadow:none;overflow:visible}
.sheet-analysis-dialog::backdrop{backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
.freight-method{margin-bottom:24px}
.freight-template-picker{display:flex;gap:16px;align-items:end;margin-bottom:24px}
.freight-template-picker>label{flex:1}.freight-template-picker>span{flex:1;font-size:13px;color:#52635a;line-height:1.6}
.freight-template-picker>button{border:0;background:none;color:#07533e;min-height:48px;padding:8px;white-space:nowrap}
.freight-body{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:24px}
.sheet-freight-dialog .freight-body fieldset{align-content:start;display:block}.freight-body fieldset>label{margin-bottom:16px}
.freight-body legend,.freight-output h3{font-size:18px;font-weight:650;padding:0;margin:0 0 16px;color:#07533e}
.freight-output{min-width:0;padding-left:24px;border-left:1px solid #d6dfd8}
.freight-dimensions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:16px}
.freight-pair,.freight-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.freight-help,.freight-output p,.freight-rules p{font-size:12px;line-height:1.7;color:#52635a;margin:16px 0}
.freight-rules{border-top:1px solid #d6dfd8;margin-top:16px;padding-top:16px}
.freight-rules summary{color:#07533e;cursor:pointer;min-height:32px;font-size:14px;font-weight:650}
.freight-outcome{display:grid;gap:8px;margin-bottom:16px}

#freightResult>div:not(.freight-outcome){display:flex;justify-content:space-between;gap:16px;padding:12px 0;border-bottom:1px solid #e1e9e3;font-size:13px;line-height:1.5}
#freightResult>div>strong{text-align:right;font-variant-numeric:tabular-nums}
#freightResult>.freight-outcome>strong{text-align:left}
.freight-expired{display:flex!important;align-items:start;grid-template-columns:20px 1fr;gap:8px!important;padding:12px;background:#fff2d8;color:#895100;font-size:12px!important;line-height:1.6}
.sheet-freight-dialog .freight-expired input{margin:3px 0 0;width:16px;height:16px;min-height:16px;flex-shrink:0;accent-color:#07533e}
.freight-manager{display:grid;grid-template-columns:180px minmax(0,1fr);gap:24px}
.freight-manager aside{min-width:0;border-right:1px solid #d6dfd8;padding-right:16px}
.freight-template-list{display:grid;gap:8px;margin-bottom:16px;max-height:420px;overflow:auto}
.freight-template-list button{display:grid;gap:8px;text-align:left;border:0;border-radius:8px;background:transparent;color:#223d2f;padding:12px;overflow-wrap:anywhere}
.freight-template-list button[aria-pressed=true]{background:#e2eee7}.freight-template-list small{font-size:12px;color:#52635a}
.freight-manager form{min-width:0}.freight-manager form>label{margin-top:16px}
.freight-manager-actions{display:flex;gap:8px;justify-content:flex-end;flex-wrap:wrap;margin-top:24px}
.freight-manager-actions button,.freight-manager aside>.btn-outlined{min-height:48px;padding:8px 16px;white-space:nowrap}
#freightTemplateError{font-size:13px;line-height:1.6;color:#895100;margin-top:16px}
@media(max-width:719px){.freight-method{margin-bottom:16px}.freight-template-picker{gap:8px;margin-bottom:16px}.freight-body{grid-template-columns:1fr}.freight-output{padding:24px 0 0;border-left:0;border-top:1px solid #d6dfd8}.freight-manager{grid-template-columns:1fr;gap:16px}.freight-manager aside{border-right:0;border-bottom:1px solid #d6dfd8;padding:0 0 16px}.freight-template-list{display:flex;max-height:none;overflow:auto}.freight-template-list button{min-width:150px;max-width:190px;flex-shrink:0}.freight-dimensions{gap:8px}.freight-grid{gap:16px 12px}}
.sheet-analysis-deck{position:relative;isolation:isolate;min-width:0}
.sheet-analysis-deck::before,.sheet-analysis-deck::after{content:"";position:absolute;inset:20px 0 16px;z-index:-1;border:1px solid #92b2a1;border-radius:24px;background:#fff url("assets/profit-card-ribbons.svg?v=20261106-contours") center top/100% 172px no-repeat;box-shadow:0 8px 24px #153d2b26;outline:1px solid transparent;backface-visibility:hidden;pointer-events:none}
.sheet-analysis-deck::before{transform:translate3d(-44px,0,0) rotate(-6deg)}
.sheet-analysis-deck::after{transform:translate3d(44px,0,0) rotate(6deg)}
.sheet-analysis-card{position:relative;display:grid;grid-template-rows:auto minmax(0,1fr);height:min(900px,calc(100dvh - 96px));overflow:hidden;border:1px solid #a7c1b1;border-radius:24px;background:#fff;box-shadow:0 16px 48px #153d2b40}
.sheet-analysis-outgoing{position:absolute;inset:0;z-index:1;width:100%;pointer-events:none}
.sheet-analysis-head{padding:24px;min-height:172px;margin:0;gap:20px;overflow:hidden;border-radius:23px 23px 0 0}
.sheet-analysis-head h2{font-size:26px;color:#fff;line-height:1.4}
.sheet-analysis-head p{color:#daebe1;line-height:1.6;font-size:14px}
.sheet-analysis-head>.sheet-analysis-image{width:104px;height:104px;padding:8px;border:1px solid #ffffff45;border-radius:12px;background:#fff;flex-shrink:0}
.sheet-analysis-head>.sheet-analysis-close{color:#fff;align-self:flex-start;border-radius:50%;background:#ffffff14}
.sheet-analysis-head>.sheet-analysis-close:hover{background:#ffffff30}
.sheet-analysis-body{padding:24px;min-height:0;overflow:auto;scrollbar-gutter:stable;display:flex;flex-direction:column}
.sheet-analysis-body>#sheetAnalysisContent{display:flex;flex-direction:column;flex:1}
.sheet-analysis-metrics{border:0;background:#f2f6f2;border-radius:12px}
.sheet-analysis-metrics>div{background:none;padding:14px 12px;gap:6px}
.sheet-analysis-metrics span,.sheet-analysis-metrics small{font-size:12px;line-height:18px}
.sheet-analysis-metrics strong{font-size:28px;white-space:nowrap;overflow-wrap:normal;letter-spacing:-.02em}
.sheet-analysis-metrics .is-loss{color:#b3261e}
.sheet-analysis-controls{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #dfe8e1;margin-bottom:20px;flex-wrap:wrap}
.sheet-analysis-tabs{margin:0;border:0;gap:20px}
.sheet-analysis-tabs button{font-size:13px}
.sheet-analysis-body .sheet-risk{font-size:12px;margin:14px 0 22px}
.sheet-analysis-mode{display:flex;align-items:center;gap:0;flex-shrink:0}
.sheet-analysis-mode button{height:32px;min-height:32px;padding:4px 14px;border:1px solid #a3b9ab;border-radius:20px 0 0 20px;background:#fff;color:#345243;font-size:13px}
.sheet-analysis-mode button+button{border-left:0;border-radius:0 20px 20px 0}
.sheet-analysis-mode button[aria-pressed=true]{background:#07533e;color:#fff}
.sheet-analysis-mode small{font-size:12px;color:#627167;margin-left:8px}
.sheet-analysis-dialog[data-mode=vc] .sheet-analysis-head::before{animation-direction:alternate-reverse}
.sheet-analysis-navigation{height:24px;text-align:center;font-size:12px;color:#fff}
.sheet-analysis-navigation>button{position:absolute;z-index:2;top:50%;width:44px;height:44px;min-height:44px;padding:10px;border:1px solid #cadbd1;border-radius:50%;background:#fff;color:#07533e;box-shadow:0 4px 16px #153d2b20}
.sheet-analysis-navigation>.sheet-analysis-prev{left:-56px}.sheet-analysis-navigation>.sheet-analysis-next{right:-56px}
.sheet-analysis-navigation svg{width:22px;height:22px;transform:rotate(-90deg)}
.sheet-analysis-navigation>button:hover:not(:disabled){background:#e6f0e9}
.sheet-analysis-navigation>button:disabled{opacity:.4}
.sheet-analysis-dialog .profit-cost-visual{grid-template-columns:200px minmax(0,1fr);gap:20px;flex:1;align-items:center}
.sheet-analysis-dialog .profit-donut-shell{width:200px;height:200px}
.sheet-analysis-dialog .profit-chart-legend{gap:0}
.sheet-analysis-dialog .sheet-composition-heading{margin-bottom:8px}
.sheet-analysis-dialog .profit-donut-center strong{white-space:nowrap;overflow:visible;text-overflow:clip;overflow-wrap:normal;line-height:1.3;max-width:100%;font-variant-numeric:tabular-nums}
.sheet-analysis-dialog .profit-donut-center span{font-size:12px;white-space:nowrap}
.sheet-analysis-dialog .profit-donut-tooltip{display:none}
.sheet-analysis-dialog .profit-chart-legend-row{grid-template-columns:10px minmax(56px,1fr) auto 64px;gap:8px;min-height:36px;padding:4px 6px;font-size:13px;line-height:20px}
.sheet-analysis-dialog .profit-chart-legend-row strong,.sheet-analysis-dialog .profit-chart-legend-row small{white-space:nowrap;font-size:13px}
.sheet-composition-note{font-size:12px;color:#52635a;line-height:1.7;margin-top:16px}
.sheet-photo-dialog{width:min(800px,calc(100vw - 32px));padding:16px}
.sheet-photo-dialog header{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:16px}
.sheet-photo-dialog header button{border:0;background:#edf3ef;border-radius:50%;width:36px;height:36px;font-size:24px;color:#244a36}
.sheet-photo-dialog [data-image-key]{display:flex;align-items:center;justify-content:center;min-height:220px}
.sheet-photo-dialog img{max-width:100%;max-height:calc(100dvh - 160px);object-fit:contain}
@media(max-width:999px){.sheet-analysis-navigation>.sheet-analysis-prev{left:0}.sheet-analysis-navigation>.sheet-analysis-next{right:0}}
@media(min-width:840px) and (max-height:800px){.sheet-analysis-dialog{width:min(684px,calc(100vw - 32px))}.sheet-analysis-head{min-height:148px}.sheet-analysis-deck::before,.sheet-analysis-deck::after{background-size:100% 148px}.sheet-analysis-head>.sheet-analysis-image{width:88px;height:88px}.sheet-analysis-dialog .profit-cost-visual{grid-template-columns:172px minmax(0,1fr);gap:16px}.sheet-analysis-dialog .profit-donut-shell{width:172px;height:172px}}
@media(max-width:839px){
  body[data-workspace=products] .cockpit-topbar::before,#productWorkbench .sheet-toolbar::before{background-size:120% 208px}
  #productWorkbench .sheet-toolbar{padding:8px 16px 16px;gap:12px}
  #productWorkbench .sheet-toolbar>input{width:100%}
  #productWorkbench .sheet-toolbar-actions{display:flex;flex-wrap:wrap;gap:8px}
  #productWorkbench .sheet-toolbar-actions>.btn-primary{width:auto}
  #productWorkbench .sheet-toolbar-actions>.sheet-save-state{margin-left:auto}
  #productWorkbench .ledger-table-panel{margin:16px 16px 0}
  #productWorkbench .ledger-scroll{max-height:calc(100dvh - 280px)}
  .sheet-analysis-dialog{width:calc(100vw - 24px);padding:0;max-height:calc(100dvh - 24px)}
  .sheet-analysis-deck::before,.sheet-analysis-deck::after{display:none}
  .sheet-analysis-card{height:calc(100dvh - 76px);border-radius:16px}
  .sheet-analysis-head{padding:20px 16px;min-height:112px;border-radius:15px 15px 0 0;gap:12px}
  .sheet-analysis-head h2{font-size:20px}
  .sheet-analysis-head p{font-size:12px}
  .sheet-analysis-head>.sheet-analysis-image{width:72px;height:72px;padding:4px}
  .sheet-analysis-body{padding:20px 16px;min-height:0;display:block}
  .sheet-analysis-metrics>div{padding:12px 8px}
  .sheet-analysis-metrics strong{font-size:clamp(15px,4.5vw,24px)}
  .sheet-analysis-metrics span,.sheet-analysis-metrics small{font-size:12px;line-height:1.5}
  .sheet-analysis-controls{gap:12px;padding-bottom:12px}
  .sheet-analysis-tabs{gap:20px}
  .sheet-analysis-navigation{position:relative;display:flex;align-items:center;justify-content:space-between;height:44px;margin-bottom:8px;padding:0 4px}
  .sheet-analysis-navigation>button{position:static;box-shadow:none;width:40px;height:40px;min-height:40px;padding:8px}
  .sheet-analysis-dialog .profit-cost-visual{grid-template-columns:1fr;gap:16px}
  .sheet-analysis-dialog .profit-donut-shell{width:224px;height:224px;margin:auto}
  .sheet-analysis-dialog .profit-chart-legend-row{grid-template-columns:10px minmax(50px,1fr) auto 66px;gap:8px;min-height:44px}
}
@media(hover:none){#productWorkbench .sheet-row-select>span{display:none}#productWorkbench .sheet-row-select input[type=checkbox]{opacity:1}}
/* Product details own gross analysis and an in-place SC net-profit form. */
#productWorkbench .sheet-toolbar-actions>*{flex-shrink:0}
.sheet-filter-column{display:grid;gap:8px;margin:0 24px 16px;font-size:14px}
.sheet-filter-column select{width:100%;height:40px}
.sheet-analysis-card{grid-template-rows:auto minmax(0,1fr) auto}
.sheet-analysis-card>.sheet-detail-actions{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0;padding:16px 24px;border-top:1px solid #dfe8e1;background:#fff}
.sheet-detail-actions>small{font-size:12px;line-height:1.5;color:#526b5c;max-width:28ch}
.sheet-detail-actions>div{display:flex;gap:12px;flex-shrink:0}
.sheet-detail-actions button{display:inline-flex;align-items:center;justify-content:center;width:auto;height:44px;min-height:44px;margin:0;padding:8px 16px;border-radius:8px;font-size:13px;line-height:20px;white-space:nowrap}
.sheet-analysis-workspace{display:grid;grid-template-columns:minmax(0,1fr);min-width:0;min-height:0;overflow:hidden}
.sheet-analysis-dialog{max-width:calc(100vw - 24px)}
.sheet-gross-pane{min-width:0;min-height:0}
.sheet-net-pane{min-width:0;min-height:0;overflow:auto;overscroll-behavior:contain;padding:24px;border-left:1px solid #dfe8e1;background:#fff;scrollbar-gutter:stable}
.sheet-net-pane[hidden]{display:none}
.sheet-analysis-dialog.is-net-expanded{width:min(1360px,calc(100vw - 64px));padding-left:56px;padding-right:56px}
.is-net-expanded .sheet-analysis-workspace{grid-template-columns:minmax(0,1fr) minmax(0,1.1fr)}
.is-net-expanded .sheet-analysis-deck::before{transform:translate3d(-12px,0,0) rotate(-1.5deg)}
.is-net-expanded .sheet-analysis-deck::after{transform:translate3d(12px,0,0) rotate(1.5deg)}
.is-net-expanded .sheet-analysis-head::before{background-size:cover;background-position:right center}
.is-net-expanded .sheet-detail-actions>small{max-width:none}
.sheet-net-pane fieldset{padding:0;margin:0;border:0;min-width:0}
.sheet-net-advanced{margin-top:12px;border-top:1px solid #e2e9e4;padding-top:12px}
.sheet-net-advanced>summary{cursor:pointer;font-size:13px;color:#07533e;min-height:32px}
.sheet-net-heading{margin-bottom:16px}
.sheet-net-heading>button{border:0;background:transparent;color:#07533e;padding:0;min-height:32px;font-size:13px}
.sheet-net-heading h3{margin:4px 0;font-size:22px;line-height:1.4}
.sheet-net-heading p{margin:0;font-size:12px;line-height:1.5;color:#526b5c}
.sheet-net-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-bottom:16px}
.sheet-net-metrics strong{font-size:clamp(17px,2vw,25px)}
#sheetDetailNetForm label{display:grid;gap:6px;margin:0;font-size:12px;font-weight:500;color:#284b38;min-width:0}
#sheetDetailNetForm input,#sheetDetailNetForm select{box-sizing:border-box;width:100%;height:40px;min-height:40px;padding:8px 10px;border:1px solid #becfc2;border-radius:8px;background:#fff;color:#203e2d;font-size:14px;font-weight:400;font-variant-numeric:tabular-nums}
#sheetDetailNetForm input:focus,#sheetDetailNetForm select:focus{border-color:#07533e;outline:2px solid #07533e;outline-offset:2px;box-shadow:none}
.sheet-net-plan{display:grid;grid-template-columns:1fr 1fr 1fr;gap:12px;padding:0 0 16px;margin-bottom:8px;border-bottom:1px solid #e2e9e4}
.sheet-detail-expense{display:grid;grid-template-columns:minmax(0,1fr) 130px;align-items:end;gap:12px;margin:8px 0}
.sheet-detail-expense>label:first-child{display:grid!important;grid-template-columns:106px minmax(0,1fr);align-items:center;gap:8px!important}
.sheet-detail-expense>label:nth-child(2)>span{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.sheet-net-summary{display:grid;gap:8px;padding-top:16px;font-size:13px}
.sheet-net-summary>div{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 10px;border-radius:8px;background:#eef4ef}
.sheet-net-summary strong{font-variant-numeric:tabular-nums;text-align:right}
.sheet-net-summary p{font-size:12px;color:#526b5c;line-height:1.6;margin:0}
#sheetDetailNetError,#sheetDetailNetStatus{font-size:12px;line-height:1.6;margin:8px 0 0}
#sheetDetailNetError{color:#a12e23}
#sheetDetailNetStatus{color:#07533e}
@media(max-width:839px){
 .sheet-analysis-card>.sheet-detail-actions{padding:12px 16px;flex-direction:column;align-items:stretch;gap:8px}
 .sheet-detail-actions>small{max-width:none}
 .sheet-detail-actions>div{justify-content:flex-end;gap:8px}
 .sheet-detail-actions button{min-height:44px;padding:8px 12px}
 .sheet-net-plan{grid-template-columns:1fr 1fr}
 .sheet-net-plan>label:last-child{grid-column:1/-1;grid-template-columns:1fr 1fr;align-items:center}
 .sheet-detail-expense{grid-template-columns:minmax(0,1fr) 104px;gap:8px}
 .sheet-detail-expense>label:first-child{grid-template-columns:78px minmax(0,1fr)}
 .sheet-net-metrics>div{padding:12px 6px}
 .sheet-net-metrics strong{font-size:clamp(15px,4vw,22px)}
 .sheet-net-summary>div{align-items:flex-start}
}
@media(max-width:1099px){
 .sheet-analysis-dialog.is-net-expanded{width:min(764px,calc(100vw - 24px));padding-left:0;padding-right:0}
 .is-net-expanded .sheet-analysis-workspace{display:block;overflow:auto;overscroll-behavior:contain}
 .is-net-expanded .sheet-gross-pane,.is-net-expanded .sheet-net-pane{overflow:visible;min-height:0;height:auto}
 .sheet-net-pane{border-left:0;border-top:1px solid #dfe8e1}
}
@media(max-width:839px){.sheet-net-pane{padding:20px 16px}.is-net-expanded .sheet-detail-actions>div{flex-wrap:wrap}.is-net-expanded .sheet-detail-actions>div>[data-ledger-action=detail-table]{display:none}}
@media(prefers-reduced-motion:reduce){body[data-workspace=products] .cockpit-topbar::before,#productWorkbench .sheet-toolbar::before,.sheet-analysis-head::before{animation:none}.sheet-analysis-dialog *{transition:none!important;animation:none!important}}

/* One input-dialog system. Product-analysis cards and the account drawer are excluded. */
:root{--input-dialog-small:560px;--input-dialog-standard:720px;--input-dialog-wide:960px;--input-dialog-radius:20px;--input-control-height:48px;--input-control-radius:8px;--input-dialog-gap:16px}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog){padding:0;border:1px solid #becfc2;border-radius:var(--input-dialog-radius);background:#fff;color:#223d2f;box-shadow:0 16px 48px #18372633;max-height:calc(100dvh - 48px);overflow:hidden}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog)::backdrop{background:#16322359;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
#sheetInputDialog{--input-dialog-width:var(--input-dialog-small);width:min(var(--input-dialog-width),calc(100vw - 32px))}
#sheetInputDialog[data-input-size=standard]{--input-dialog-width:var(--input-dialog-standard)}
#sheetInputDialog[data-input-size=wide]{--input-dialog-width:var(--input-dialog-wide)}
#sheetTemplatesDialog{width:min(var(--input-dialog-wide),calc(100vw - 32px))}
#sheetColumnDialog,#measurementSaveDialog{width:min(var(--input-dialog-small),calc(100vw - 32px))}
#sheetInputDialog .ledger-panel{display:flex;flex-direction:column;max-height:calc(100dvh - 50px)}
#sheetInputDialog .ledger-panel>header,#sheetTemplatesDialog>header,#measurementSaveDialog .input-dialog-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:24px 24px 8px;flex-shrink:0}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) h2{font-size:20px;font-weight:650;line-height:28px;margin:0;color:#223d2f}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) header>button{display:grid;place-items:center;width:44px;height:44px;min-height:44px;min-width:44px;padding:0;margin:0;flex:0 0 44px;border:0;border-radius:50%;background:transparent;color:#52635a}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) header>button:hover{background:#edf2ee}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) header>button svg{width:22px;height:22px}
#sheetInputDialog .ledger-panel>p{font-size:14px;line-height:22px;color:#627167;padding:0 24px 24px;margin:0;flex-shrink:0;border-bottom:1px solid #e1e9e3}
#sheetInputDialog :is(.ledger-panel-fields,[data-freight-helper]){padding:24px;overflow:auto;min-height:0}
#sheetInputDialog .ledger-panel fieldset{gap:var(--input-dialog-gap)}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) label{font-size:14px;line-height:20px;gap:8px;color:#223d2f}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) :is(input:not([type=checkbox]):not([type=file]),select){height:var(--input-control-height);min-height:var(--input-control-height);width:100%;min-width:0;padding:8px 12px;border:1px solid #c4d0c7;border-radius:var(--input-control-radius);background:#fff;color:#223d2f;font-size:14px;line-height:20px;box-shadow:none}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) :is(input:not([type=checkbox]),select):focus{border-color:#07533e;outline:none;box-shadow:none}
#sheetInputDialog .sheet-package-dimensions input{padding-left:8px;padding-right:8px}
#sheetInputDialog :is(.sheet-fba-method,.freight-method){display:flex;gap:4px;padding:4px;background:#edf2ee;border-radius:12px}
#sheetInputDialog :is(.sheet-fba-method,.freight-method)>button{flex:1;min-width:0;min-height:48px;padding:8px 12px;border:0;border-radius:8px;background:transparent;color:#52635a;font-size:14px;font-weight:500;line-height:20px}
#sheetInputDialog :is(.sheet-fba-method,.freight-method)>button[aria-pressed=true]{background:#dbeadf;color:#07533e;font-weight:650}
#sheetInputDialog :is(.sheet-package-more,.sheet-ad-allocation,.freight-rules)>summary{font-size:14px;line-height:22px;min-height:40px;padding:8px 0;color:#07533e}
#sheetInputDialog :is(.sheet-fba-estimate,.freight-outcome){padding:20px;border:0;border-radius:12px;background:#edf4ef;color:#223d2f}
#sheetInputDialog .sheet-fba-estimate>div{display:grid;gap:8px}
#sheetInputDialog .sheet-fba-estimate>div>strong:first-child,#sheetInputDialog .freight-outcome>span{font-size:14px;font-weight:500;line-height:22px}
#sheetInputDialog .sheet-fba-estimate>div>strong+strong,#sheetInputDialog .freight-outcome>strong{font-size:32px;line-height:40px;font-weight:650;font-variant-numeric:tabular-nums;color:#07533e;text-align:left;white-space:normal;overflow-wrap:anywhere}
#sheetInputDialog :is(.sheet-fba-estimate p,.freight-help,.freight-rules p,.freight-output p,.ledger-panel fieldset>p){font-size:12px;line-height:20px;color:#52635a}
#sheetInputDialog .sheet-fba-estimate .sheet-fee-warning{color:#895100}
#sheetInputDialog[data-input-size=small] .freight-body{grid-template-columns:1fr;gap:24px}
#sheetInputDialog[data-input-size=small] .freight-output{border-left:0;padding-left:0;padding-top:0}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-template-picker{margin-bottom:16px;align-items:center}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-template-picker>button{min-height:40px}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-template-picker>span{font-size:12px;line-height:20px}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-body{gap:16px}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-body legend{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-body fieldset>label:last-child{margin-bottom:0}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog .freight-output h3{display:none}
#sheetInputDialog[data-input-size=small].sheet-freight-dialog #freightResult>div:not(.freight-outcome){display:none}
#sheetInputDialog .ledger-panel>footer,#measurementSaveDialog form>footer{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-shrink:0;padding:16px 24px;margin:0;border-top:1px solid #e1e9e3;background:#fff}
#sheetInputDialog .ledger-panel>footer>small{margin-right:auto;max-width:48%;font-size:12px;line-height:20px;color:#52635a}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) footer button,#sheetInputDialog .freight-manager-actions button{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;height:48px;min-height:48px;min-width:88px;width:auto;max-width:100%;margin:0;padding:8px 24px;border:1px solid #b3c5b8;border-radius:24px;background:#fff;color:#24533c;font-size:14px;line-height:20px;font-weight:650;white-space:nowrap}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) footer .btn-primary,#sheetInputDialog .freight-manager-actions .btn-primary{background:#07533e;color:#fff;border-color:#07533e}
:is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog) footer .btn-primary:not(:disabled):hover,#sheetInputDialog .freight-manager-actions .btn-primary:not(:disabled):hover{background:#03422f}
#sheetTemplatesDialog[open]{display:flex;flex-direction:column}
#sheetTemplatesDialog>header{padding-bottom:16px;border-bottom:1px solid #e1e9e3}
#sheetTemplatesDialog .sheet-template-layout{min-height:0;overflow:auto}
#sheetTemplatesDialog .sheet-template-fields{gap:16px;margin-top:24px}
#sheetTemplatesDialog .sheet-template-layout form{padding:24px}
#sheetTemplatesDialog .sheet-template-layout form footer,#sheetInputDialog .freight-manager-actions{position:sticky;bottom:0;background:#fff;border-top:1px solid #e1e9e3;padding:16px 0;z-index:1}
#sheetTemplatesDialog .sheet-template-total{border-radius:12px;background:#edf4ef}
#sheetColumnDialog>form{padding:24px;display:grid;gap:16px;max-height:calc(100dvh - 50px);overflow:auto}
#sheetColumnDialog header{padding:0 0 16px;border-bottom:1px solid #e1e9e3}
#sheetColumnDialog :is(label,p,.sheet-column-sort){margin:0}
#sheetColumnDialog .sheet-column-sort{gap:8px}
#sheetColumnDialog .sheet-column-sort button{min-height:40px;border-radius:20px;background:#edf2ee;font-size:14px}
#sheetColumnDialog .sheet-filter-choices label{display:flex;gap:8px;margin:8px 0}
#sheetColumnDialog footer{position:sticky;bottom:0;background:#fff;padding:16px 0;margin:0;border-top:1px solid #e1e9e3;justify-content:flex-end}
#measurementSaveDialog>form{display:flex;flex-direction:column;max-height:calc(100dvh - 50px)}
#measurementSaveDialog .input-dialog-header{padding-bottom:16px;border-bottom:1px solid #e1e9e3}
#measurementSaveDialog .input-dialog-body{display:grid;gap:16px;padding:24px;min-height:0;overflow:auto}
#measurementSaveDialog .input-dialog-body :is(label,p){margin:0}
#measurementSaveDialog .ledger-save-error{color:#b3261e}
#exchangeRateModal{background:#16322359;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
#exchangeRateModal>.modal-card{width:min(var(--input-dialog-standard),calc(100vw - 32px));max-height:calc(100dvh - 48px);padding:0;display:flex;flex-direction:column;overflow:hidden;border:1px solid #becfc2;border-radius:20px;box-shadow:0 16px 48px #18372633;background:#fff}
#exchangeRateModal .modal-head{padding:24px;gap:16px;flex-shrink:0;border-bottom:1px solid #e1e9e3}
#exchangeRateModal h3{margin:0;font-size:20px;line-height:28px;font-weight:650;color:#223d2f}
#exchangeRateModal .modal-kicker{margin:8px 0 0;font-size:14px;line-height:22px;color:#627167}
#exchangeRateModal .modal-x{width:44px;height:44px;min-width:44px;min-height:44px;padding:0;display:grid;place-items:center;border:0;border-radius:50%;color:#52635a;background:transparent}
#exchangeRateModal .modal-x:hover{background:#edf2ee}
#exchangeRateModal .modal-body{padding:24px;min-height:0;overflow:auto;gap:16px}
#exchangeRateModal .exchange-rate-grid{gap:16px}
#exchangeRateModal :is(.exchange-rate-grid,.exchange-rate-meta-fields)>label{font-size:14px;line-height:20px;gap:8px;color:#223d2f}
#exchangeRateModal .exchange-rate-grid label>div{height:48px;min-height:48px;padding:0 12px;gap:8px;border:1px solid #c4d0c7;border-radius:8px;background:#fff}
#exchangeRateModal .exchange-rate-grid input{height:46px;min-height:46px;padding:0;border:0;border-radius:0;font-size:14px;outline:0;box-shadow:none}
#exchangeRateModal .exchange-rate-grid label>div:focus-within{border-color:#07533e;box-shadow:none}
#exchangeRateModal .exchange-rate-grid :is(strong,em){font-size:12px}
#exchangeRateModal .exchange-rate-meta-fields{margin:0;gap:16px}
#exchangeRateModal .exchange-rate-meta-fields>label{border:0;padding:0}
#exchangeRateModal .exchange-rate-meta-fields input{height:48px;min-height:48px;padding:8px 12px;border:1px solid #c4d0c7;border-radius:8px;background:#fff;font-size:14px}
#exchangeRateModal .exchange-rate-meta-fields input:focus{border-color:#07533e;outline:none;box-shadow:none}
#exchangeRateModal .modal-foot{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:8px;margin:0;padding:16px 24px;border-top:1px solid #e1e9e3;flex-shrink:0;background:#fff}
#exchangeRateModal .modal-foot button{width:auto;min-width:88px;max-width:100%;height:48px;min-height:48px;padding:8px 16px;margin:0;border-radius:24px;font-size:14px;line-height:20px;box-shadow:none}
#exchangeRateModal .modal-foot .btn-primary{background:#07533e;color:#fff}
@media(max-width:719px){
 :is(#sheetInputDialog,#sheetTemplatesDialog,#sheetColumnDialog,#measurementSaveDialog){width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}
 #sheetInputDialog .ledger-panel,#measurementSaveDialog>form,#sheetColumnDialog>form{max-height:calc(100dvh - 26px)}
 #sheetInputDialog .ledger-panel>header,#sheetTemplatesDialog>header,#measurementSaveDialog .input-dialog-header{padding:16px 16px 8px}
 #sheetTemplatesDialog>header,#measurementSaveDialog .input-dialog-header{padding-bottom:16px}
 #sheetInputDialog .ledger-panel>p{padding:0 16px 16px}
 #sheetInputDialog :is(.ledger-panel-fields,[data-freight-helper]),#measurementSaveDialog .input-dialog-body,#sheetTemplatesDialog .sheet-template-layout form,#sheetColumnDialog>form{padding:16px}
 #sheetInputDialog :is(.sheet-fba-method,.freight-method)>button{padding:8px 4px;font-size:13px}
 #sheetInputDialog .sheet-package-dimensions:has(.sheet-package-precise){grid-template-columns:repeat(2,minmax(0,1fr))}
 #sheetInputDialog .sheet-package-dimensions:has(.sheet-package-precise)>label:last-child{grid-column:1/-1}
 #sheetInputDialog .ledger-panel>footer,#measurementSaveDialog form>footer{padding:12px 16px;flex-wrap:wrap}
 #sheetInputDialog .ledger-panel>footer>small{width:100%;max-width:none}
 #sheetTemplatesDialog .sheet-template-layout form footer,#sheetColumnDialog footer{bottom:0}
 #sheetTemplatesDialog .sheet-template-layout form footer{gap:8px}
 #sheetTemplatesDialog .sheet-template-default{width:100%}
 #exchangeRateModal>.modal-card{width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}
 #exchangeRateModal :is(.modal-head,.modal-body){padding:16px}
 #exchangeRateModal :is(.exchange-rate-grid,.exchange-rate-meta-fields){grid-template-columns:1fr}
 #exchangeRateModal .modal-foot{padding:12px 16px}
}

