/* Workshop product entry and summary only. Do not restyle other sections. */
.workshop-page .dynamic-product-entry{display:flex!important;flex-flow:row nowrap!important;gap:8px;align-items:center;margin-bottom:8px}
.workshop-page .dynamic-product-entry input{flex:1 1 0;width:0!important;min-width:0}
.workshop-page .dynamic-product-entry button{flex:0 0 auto;white-space:nowrap}
.workshop-page .workshop-discount-table{max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;padding-bottom:4px}
.workshop-page .workshop-discount-table table{width:100%;min-width:920px;table-layout:fixed;border-collapse:collapse}
.workshop-page .workshop-discount-table th:first-child{width:auto}
.workshop-page .workshop-discount-table th:nth-child(2){width:42px}
.workshop-page .workshop-discount-table th:nth-child(3){width:68px}
.workshop-page .workshop-discount-table th:nth-child(4){width:58px}
.workshop-page .workshop-discount-table th:nth-child(5){width:94px}
.workshop-page .workshop-discount-table th:nth-child(6){width:120px}
.workshop-page .workshop-discount-table th:nth-child(7){width:50px}
.workshop-page .workshop-discount-table th:nth-child(8){width:112px}
.workshop-page .workshop-discount-table th:last-child{width:56px}
.workshop-page .workshop-discount-table th{font-size:.72rem;line-height:1.25;white-space:normal;padding:7px 4px}
.workshop-page .workshop-discount-table td{vertical-align:middle;padding:6px 4px;overflow-wrap:break-word}
.workshop-page .workshop-discount-table td:first-child strong{display:block;font-size:.8rem;line-height:1.35;overflow-wrap:break-word}
.workshop-page .workshop-discount-table td small{display:block;font-size:.72rem;line-height:1.35;margin-top:3px}
.workshop-page .workshop-discount-table td:nth-child(2),.workshop-page .workshop-discount-table td:nth-child(3){white-space:nowrap}
.workshop-page .workshop-discount-table td input{width:100%;min-width:0!important;min-height:30px;text-align:right;padding:5px;font-size:.76rem;font-variant-numeric:tabular-nums}
.workshop-page .workshop-discount-table td select{width:100%;min-width:0;min-height:30px;padding:4px;font-size:.75rem}
.workshop-page .workshop-discount-table input[readonly]{background:var(--optical-theme-info-soft, #f7fafb);border-color:transparent;font-weight:600}
.workshop-page .workshop-discount-table input.workshop-calculation-pending{font-size:.7rem;color:var(--optical-theme-muted, #536974);font-weight:400}
.workshop-page .workshop-discount-table .workshop-clear-product{min-width:24px;padding:2px;font-size:20px}
.workshop-page .workshop-line-gst{text-align:right;white-space:nowrap;font-size:.75rem;font-weight:600}
.workshop-page .workshop-discount-table .workshop-power-pending{display:inline-block;width:fit-content;background:var(--optical-theme-warning-soft, #fff1c6);color:var(--optical-theme-warning, #815108);border-radius:4px;padding:2px 5px;font-size:.68rem}
.workshop-page .workshop-discount-input{display:flex;gap:0;align-items:stretch;min-width:0}
.workshop-page .workshop-discount-input input{flex:1 1 0;min-width:0!important;width:0!important;text-align:right;font-variant-numeric:tabular-nums}
.workshop-page .workshop-discount-input select{flex:0 0 42px;width:42px!important;min-width:42px;max-width:42px;padding:3px 2px!important;min-height:30px;font-size:.75rem}
.workshop-page .workshop-discount-input input[aria-invalid=true]{border-color:#c52929}
.workshop-page .final-side .workshop-pricing-summary{grid-template-columns:minmax(0,1fr) minmax(125px,145px)}
.workshop-page .workshop-pricing-summary dd:has(.workshop-discount-input){min-width:125px}
.workshop-page .workshop-gst-table{width:100%;border-collapse:collapse;font-size:.75rem;margin-top:7px}
.workshop-page .workshop-gst-table th,.workshop-page .workshop-gst-table td{padding:6px 5px;border-bottom:1px solid var(--optical-theme-border, #e0eaee);text-align:right}
.workshop-page .workshop-gst-table th:first-child,.workshop-page .workshop-gst-table td:first-child{text-align:left}
.workshop-page .workshop-gst-table thead,.workshop-page .workshop-gst-total{background:var(--optical-theme-info-soft, #f0f6f7)}
.workshop-page .workshop-gst-total{font-weight:700}

/* Keep utility columns compact; spare desktop width belongs to the product. */
.workshop-page .final-workspace{grid-template-columns:minmax(0,1fr) 320px}
.workshop-page .workshop-discount-table th:nth-child(n+4):not(:last-child){text-align:right}
.workshop-page .workshop-discount-table th:nth-child(2),
.workshop-page .workshop-discount-table td:nth-child(2),
.workshop-page .workshop-discount-table th:last-child,
.workshop-page .workshop-discount-table td:last-child{text-align:center}
.workshop-page .workshop-discount-table td:first-child{padding-right:12px}
.workshop-page .workshop-discount-table td:nth-child(4) input[type=number]{appearance:textfield;-moz-appearance:textfield}
.workshop-page .workshop-discount-table td:nth-child(4) input::-webkit-inner-spin-button,
.workshop-page .workshop-discount-table td:nth-child(4) input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.workshop-page .final-side .workshop-card{padding:10px;margin-bottom:8px}
.workshop-page .final-side .workshop-pricing-summary{grid-template-columns:minmax(0,1fr) 126px;gap:4px 8px}
.workshop-page .final-side .workshop-pricing-summary dd>input{width:100%!important}
.workshop-page .final-side .workshop-discount-input{width:100%;height:31px}
.workshop-page .final-side .workshop-discount-input input{height:31px;box-sizing:border-box}
.workshop-page .final-side .workshop-discount-input select{height:31px;box-sizing:border-box}
.workshop-page .workshop-gst-table{table-layout:fixed;font-variant-numeric:tabular-nums;margin-top:3px}
.workshop-page .workshop-gst-table th:first-child{width:24%}
.workshop-page .workshop-gst-table th:nth-child(2),
.workshop-page .workshop-gst-table th:nth-child(3){width:38%}
.workshop-page .workshop-gst-table th,.workshop-page .workshop-gst-table td{padding:5px 3px;overflow-wrap:normal}
.workshop-page .workshop-summary-gst{margin-top:8px;padding-top:3px}
.workshop-page #workshop-payments .final-payment-fields{grid-template-columns:minmax(0,1fr) auto;gap:6px}
.workshop-page #workshop-payments .collection-options{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin-top:6px}
.workshop-page #workshop-payments label{margin:0}
.workshop-page #workshop-payments>button{margin-top:6px}
.workshop-page .final-side textarea[aria-label="Order notes / discount reason"]{height:58px;min-height:58px;resize:vertical;margin-top:3px;box-sizing:border-box}
@media(max-width:1100px){
 .workshop-page .final-workspace{grid-template-columns:minmax(0,1fr)}
 .workshop-page .final-side{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;align-items:start}
 .workshop-page .final-side .workshop-card{margin-bottom:0}
}
@media(max-width:650px){
 .workshop-page .final-side{display:block}
 .workshop-page .final-side .workshop-card{margin-bottom:8px}
 .workshop-page .dynamic-product-entry{gap:6px}
 .workshop-page .dynamic-product-entry button{padding-inline:8px}
}

.workshop-page .workshop-discount-table:focus-visible{outline:2px solid #078579;outline-offset:2px}

/* Paint reference: two top columns, full-width products, tax and remarks below. */
.workshop-page .workshop-arranged{grid-template-columns:minmax(0,1fr) minmax(300px,340px);gap:10px 12px}
.workshop-page .workshop-products-wide,.workshop-page .workshop-bottom{grid-column:1/-1;min-width:0}
.workshop-page .workshop-products-wide fieldset{border:0;padding:0;margin:0;min-width:0}
.workshop-page .workshop-arranged .final-main .workshop-card:last-child,
.workshop-page .workshop-arranged .final-side .workshop-card:last-child,
.workshop-page .workshop-products-wide .workshop-card{margin-bottom:0}
.workshop-page .workshop-bottom{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:12px;align-items:start}
.workshop-page .workshop-tax-card .workshop-summary-gst{margin:0;padding:0;border:0}
.workshop-page .workshop-tax-identity{display:flex;flex-wrap:wrap;gap:4px 18px;font-size:.75rem;margin:3px 0 8px}
.workshop-page .workshop-tax-identity strong{font-weight:600}
.workshop-page .workshop-tax-scroll{max-width:100%;overflow-x:auto;overscroll-behavior-x:contain}
.workshop-page .workshop-detailed-gst{min-width:650px;table-layout:auto}
.workshop-page .workshop-detailed-gst th:first-child,
.workshop-page .workshop-detailed-gst th:nth-child(2),
.workshop-page .workshop-detailed-gst th:nth-child(3){width:auto}
.workshop-page .workshop-detailed-gst th,.workshop-page .workshop-detailed-gst td{padding:6px;white-space:nowrap}
.workshop-page .workshop-detailed-gst td small{display:block;font-size:.7rem;color:var(--z-text-muted,#536974)}
.workshop-page .workshop-remarks textarea{display:block;width:100%;height:86px;min-height:58px;resize:vertical;box-sizing:border-box;margin-top:5px}
.workshop-page .workshop-tax-scroll:focus-visible{outline:2px solid #078579;outline-offset:2px}
@media(max-width:1100px){
 .workshop-page .workshop-arranged{grid-template-columns:minmax(0,1fr) 300px}
 .workshop-page .workshop-arranged .final-side{display:block}
 .workshop-page .workshop-arranged .final-side .workshop-card{margin-bottom:8px}
 .workshop-page .workshop-bottom{grid-template-columns:minmax(0,2fr) minmax(240px,1fr)}
}
@media(max-width:850px){
 .workshop-page .workshop-arranged{grid-template-columns:minmax(0,1fr)}
 .workshop-page .workshop-bottom{grid-template-columns:minmax(0,1fr)}
}

/* Frames & Lenses reference: image and description share one generous product column. */
.workshop-page .workshop-discount-table table{min-width:1080px}
.workshop-page .workshop-discount-table th:first-child{width:32px}
.workshop-page .workshop-discount-table th:nth-child(2){width:auto;text-align:left}
.workshop-page .workshop-discount-table th:nth-child(3){width:50px;text-align:center}
.workshop-page .workshop-discount-table th:nth-child(4){width:70px;text-align:center}
.workshop-page .workshop-discount-table th:nth-child(5){width:58px;text-align:center}
.workshop-page .workshop-discount-table th:nth-child(6){width:102px;text-align:right}
.workshop-page .workshop-discount-table th:nth-child(7){width:126px;text-align:center}
.workshop-page .workshop-discount-table th:nth-child(8){width:60px;text-align:center}
.workshop-page .workshop-discount-table th:nth-child(9){width:116px;text-align:right}
.workshop-page .workshop-discount-table th:last-child{width:64px;text-align:center}
.workshop-page .workshop-discount-table th{background:var(--optical-theme-info-soft, #f0f4f5);color:var(--optical-theme-text, #425563);font-size:.74rem;font-weight:700;text-transform:uppercase;padding:11px 6px;line-height:1.4;letter-spacing:0}
.workshop-page .workshop-discount-table td{padding:9px 6px;border-bottom:1px solid var(--optical-theme-border, #e3ebef);background:var(--z-surface,#fff)}
.workshop-page .workshop-discount-table td:first-child{padding-right:6px;text-align:center;font-size:.82rem}
.workshop-page .workshop-discount-table td:nth-child(2){white-space:normal;text-align:left}
.workshop-page .workshop-discount-table td:nth-child(3),
.workshop-page .workshop-discount-table td:nth-child(4),
.workshop-page .workshop-discount-table td:nth-child(5){text-align:center}
.workshop-page .workshop-product-detail{display:flex;gap:14px;align-items:center;min-width:0}
.workshop-page .workshop-product-thumbnail{display:flex;flex:0 0 64px;width:64px;height:64px;align-items:center;justify-content:center;border:1px solid var(--optical-theme-border, #dbe5eb);border-radius:6px;background:var(--optical-theme-surface, #fbfdfe);color:var(--optical-theme-muted, #9bb4bf);overflow:hidden}
.workshop-page .workshop-product-thumbnail img{display:block;width:100%;height:100%;object-fit:contain}
.workshop-page .workshop-product-thumbnail>svg{width:48px;height:40px}
.workshop-page .workshop-product-copy{min-width:0}
.workshop-page .workshop-product-copy strong{display:block;font-size:.85rem;line-height:1.4;color:var(--z-text,#142c40);overflow-wrap:anywhere}
.workshop-page .workshop-product-copy small{font-size:.75rem;color:var(--z-text-muted,#536974);line-height:1.4;margin-top:2px}
.workshop-page .workshop-product-copy .workshop-power-pending{font-size:.73rem;color:var(--optical-theme-warning, #936000);background:var(--optical-theme-warning-soft, #fff0c6);border-radius:4px;padding:2px 6px}
.workshop-page .workshop-discount-table td input,
.workshop-page .workshop-discount-table td select{height:34px!important;min-height:34px!important;font-size:.82rem;border:1px solid var(--optical-theme-border, #d4dfe7);border-radius:5px;padding:5px 7px!important;box-sizing:border-box}
.workshop-page .workshop-discount-table td:nth-child(5) input{appearance:textfield;-moz-appearance:textfield;text-align:center}
.workshop-page .workshop-discount-table td:nth-child(5) input::-webkit-inner-spin-button,
.workshop-page .workshop-discount-table td:nth-child(5) input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.workshop-page .workshop-discount-table input[readonly]{background:var(--z-surface,#fff);border-color:var(--optical-theme-border, #d4dfe7);font-weight:400}
.workshop-page .workshop-discount-table .workshop-discount-input select{background:var(--optical-theme-info-soft, #edf0f4);padding:4px 2px!important;border-radius:0 5px 5px 0}
.workshop-page .workshop-discount-table .workshop-discount-input input{border-radius:5px 0 0 5px}
.workshop-page .workshop-discount-table .workshop-line-gst{text-align:center;font-size:.8rem;font-weight:500}
.workshop-page .workshop-discount-table .workshop-line-gst:before{content:none}
.workshop-page .workshop-discount-table .workshop-clear-product{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;padding:6px!important;border:1px solid var(--optical-theme-border, #e9b5b5);border-radius:5px;background:var(--optical-theme-surface, #fff);color:var(--optical-theme-muted, #e22c32)}
.workshop-page .workshop-discount-table .workshop-clear-product:hover:not(:disabled){background:var(--optical-theme-danger-soft, #fff2f2);border-color:#df555b}
.workshop-page .workshop-discount-table .workshop-clear-product:disabled{opacity:.35}
.workshop-page .workshop-product-search-button{display:inline-flex;align-items:center;justify-content:center;background:#337fc8;color:white;border:1px solid #337fc8;border-radius:5px;min-width:42px;height:32px;padding:4px 10px}
.workshop-page .workshop-product-search-button:focus-visible{outline:2px solid #174a7c;outline-offset:2px}
.workshop-page .workshop-product-search-button:disabled{opacity:.5}
@media(max-width:650px){.workshop-page .dynamic-product-entry{gap:4px}.workshop-page .dynamic-product-entry .workshop-product-search-button{min-width:32px;padding-inline:5px}}

.workshop-page .workshop-settlement-payment{display:grid;grid-template-columns:1fr 1fr 1fr;gap:10px;margin:10px 0}.workshop-operation-dialog h3{font-size:.9rem;margin:12px 0 6px}.workshop-page .workshop-settlement-payment label{min-width:0}.workshop-page .workshop-settlement-payment input,.workshop-page .workshop-settlement-payment select{width:100%;box-sizing:border-box;min-height:34px}@media(max-width:650px){.workshop-page .workshop-settlement-payment{grid-template-columns:1fr}}

.workshop-page .workshop-payment-buttons{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.workshop-page .workshop-payment-totals{font-variant-numeric:tabular-nums;align-items:center}
.workshop-page .workshop-payment-history-dialog{width:1100px;max-width:calc(100vw - 32px);padding:0!important;overflow:hidden;display:flex;flex-direction:column}
.workshop-page .workshop-history-body{padding:16px;min-height:0;overflow:auto}
.workshop-page .workshop-history-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:0 0 14px}
.workshop-page .workshop-history-summary>div{background:var(--optical-theme-info-soft, #f0f7f7);border:1px solid var(--optical-theme-border, #d9e9e9);border-radius:6px;padding:9px 12px}
.workshop-page .workshop-history-summary dt{font-size:.78rem;color:var(--optical-theme-muted, #536974)}.workshop-page .workshop-history-summary dd{margin:4px 0 0;font-weight:700;font-variant-numeric:tabular-nums}
.workshop-page .workshop-history-scroll{max-height:48vh;overflow:auto;overscroll-behavior:contain}
.workshop-page .workshop-history-table{width:100%;min-width:1000px;border-collapse:collapse;font-size:.8rem}
.workshop-page .workshop-history-table th,.workshop-page .workshop-history-table td{padding:9px 8px;vertical-align:top;border-bottom:1px solid var(--optical-theme-border, #e1ebee)}
.workshop-page .workshop-history-table thead{position:sticky;top:0;background:var(--optical-theme-info-soft, #eff5f6);z-index:1}
.workshop-page .workshop-history-table th{font-weight:700;text-align:left}
.workshop-page .workshop-history-table th:nth-child(5),.workshop-page .workshop-history-money{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}
.workshop-page .workshop-history-table td:nth-child(2),.workshop-page .workshop-history-table button{white-space:nowrap}
.workshop-page .workshop-history-remarks{min-width:170px;max-width:260px;white-space:pre-wrap;overflow-wrap:anywhere}
.workshop-page .workshop-history-empty{text-align:center;padding:24px!important}
.workshop-page .workshop-history-table tfoot{background:var(--optical-theme-info-soft, #eff5f6);font-weight:700}
.workshop-page .workshop-history-scroll:focus-visible{outline:2px solid #078579;outline-offset:2px}
@media(max-width:650px){.workshop-page .workshop-history-summary{gap:6px}.workshop-page .workshop-history-summary>div{padding:8px 6px}.workshop-page .workshop-history-summary dd{font-size:.82rem}.workshop-page .workshop-history-body{padding:12px}}

.workshop-page .workshop-collect-dialog,.workshop-page .workshop-account-dialog{padding:0!important;overflow:hidden;display:flex;flex-direction:column;max-width:calc(100vw - 32px)}
.workshop-page .workshop-collect-dialog{width:760px}.workshop-page .workshop-account-dialog{width:1100px}
.workshop-page .workshop-payment-remarks{display:block;margin-top:10px;font-size:.85rem}
.workshop-page .workshop-payment-remarks textarea{display:block;box-sizing:border-box;width:100%;min-height:64px;resize:vertical;margin-top:5px}
.workshop-page .workshop-account-table{width:100%;min-width:720px;border-collapse:collapse;font-size:.8rem;table-layout:auto}
.workshop-page .workshop-account-table th,.workshop-page .workshop-account-table td{padding:9px 8px;text-align:left;border-bottom:1px solid var(--optical-theme-border, #dfe9ec);vertical-align:top}
.workshop-page .workshop-account-table thead{background:var(--optical-theme-info-soft, #eff5f6);position:sticky;top:0;z-index:1}
.workshop-page .workshop-account-table th:nth-child(3),.workshop-page .workshop-account-table th:nth-child(4),.workshop-page .workshop-account-table td:nth-child(3),.workshop-page .workshop-account-table td:nth-child(4){text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}
.workshop-page .workshop-account-table small{display:block;margin-top:3px;font-size:.72rem}
.workshop-page .workshop-account-table .workshop-history-remarks{min-width:120px;max-width:220px}
.workshop-page .workshop-account-actions{display:flex;gap:5px;flex-wrap:wrap}.workshop-page .workshop-account-actions button{white-space:nowrap}
.workshop-page .workshop-account-context{font-size:.8rem;color:var(--optical-theme-muted, #536974);margin:0 0 12px}

.workshop-page .workshop-account-table td{overflow-wrap:anywhere}

.workshop-stock-popup .workshop-category-shortcuts{display:flex;flex-wrap:wrap;gap:5px;padding:6px 10px;flex-shrink:0}.workshop-category-shortcuts button{border:1px solid var(--optical-theme-border, #bed8dc);border-radius:5px;padding:5px 12px;background:var(--optical-theme-surface, white);color:var(--optical-theme-accent, #16474c);font-size:.85rem}.workshop-category-shortcuts button.active{background:#087f79;border-color:#087f79;color:white}

@media(max-height:600px){.workshop-page .final-dialog.workshop-stock-popup{gap:4px}.workshop-stock-popup>.optical-popup-header{padding:4px 10px}.workshop-stock-popup .optical-popup-icon{width:26px;height:26px;flex-basis:26px}.workshop-stock-popup .workshop-category-shortcuts{padding:0;gap:4px}.workshop-stock-popup .workshop-category-shortcuts button{padding:3px 9px}.workshop-stock-popup .catalogue-search-footer{padding:4px 8px}}

/* Workshop catalogue: filters/results left, session and active selection right.
   This file is loaded by App.razor; keep popup-only rules here rather than relying on an unlinked scoped stylesheet. */
.final-overlay:has(.workshop-stock-popup){position:fixed;inset:0;padding:8px;display:flex;align-items:stretch;justify-content:stretch;overflow:hidden;box-sizing:border-box}
.workshop-page .final-dialog.workshop-stock-popup,.final-dialog.workshop-stock-popup{width:100%;max-width:100%;height:100%;max-height:100%;min-width:0;min-height:0;margin:0;padding:10px 12px;gap:10px;border:1px solid var(--z-border,#c9dce1);border-radius:8px;display:flex;flex-direction:column;overflow:hidden;box-sizing:border-box;background:var(--z-surface,#fff)}
.workshop-stock-popup>.optical-popup-header{flex:none;min-width:0;margin:0}
.workshop-stock-popup .catalogue-popup-body{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,3fr);gap:14px;flex:1 1 0;min-width:0;min-height:0;overflow:hidden}
.workshop-stock-popup .catalogue-browse-panel{display:flex;flex-direction:column;gap:8px;min-width:0;min-height:0;overflow:hidden}
.workshop-stock-popup .catalogue-browse-panel>.workshop-category-shortcuts{flex:none;display:flex;flex-wrap:wrap;gap:4px;padding:0;margin:0;min-width:0}
.workshop-stock-popup .workshop-category-shortcuts button{padding:5px 9px;white-space:nowrap}
.workshop-stock-popup .catalogue-browse-panel>.product-popup-search{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,3fr);gap:8px;flex:none;margin:0;min-width:0}
.workshop-stock-popup label{display:flex;flex-direction:column;gap:4px;min-width:0;font-size:.8rem;font-weight:600}
.workshop-stock-popup input,.workshop-stock-popup select{width:100%;min-width:0;max-width:100%;box-sizing:border-box;min-height:34px;padding:6px 8px}
.workshop-stock-popup .catalogue-browse-panel>.workshop-product-picker{display:flex;flex-direction:column;gap:5px;flex:1 1 0;min-width:0;min-height:0;max-height:none;overflow:hidden}
.workshop-stock-popup .workshop-search-results{display:flex;flex-direction:column;gap:5px;flex:1 1 0;min-width:0;min-height:0;max-height:none;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;padding:1px}
.workshop-stock-popup .workshop-product-result-with-view{display:flex;min-width:0;max-width:100%;flex:none;box-sizing:border-box}
.workshop-stock-popup .workshop-search-choice{align-items:start;padding:7px 8px;gap:8px;font-size:.82rem;min-width:0;max-width:100%;box-sizing:border-box;background:var(--z-surface,#fff);color:var(--z-text,#17383d)}
.workshop-stock-popup .workshop-search-choice>span:first-child{min-width:0;overflow-wrap:anywhere}
.workshop-stock-popup .workshop-search-choice>span:last-child{flex:none;font-size:.75rem;max-width:36%;text-align:right;white-space:normal}
.workshop-stock-popup .workshop-search-choice small{font-size:.72rem;margin-top:2px}
.workshop-stock-popup .workshop-search-choice.selected{background:color-mix(in srgb,var(--z-primary,#008579) 10%,var(--z-surface,#fff));border-color:var(--z-primary,#008579)}
.workshop-stock-popup .catalogue-added-badge{display:inline-block;padding:2px 5px;border:1px solid var(--z-border,#b3d7d0);border-radius:4px;color:var(--z-primary,#007a70);font-weight:700}
.workshop-stock-popup .catalogue-product-pagination{display:flex;align-items:center;gap:6px;flex:none;min-width:0;padding-top:4px;font-size:.78rem}
.workshop-stock-popup .catalogue-product-pagination span{margin-right:auto}
.workshop-stock-popup .catalogue-product-pagination button{min-width:0;padding:5px 10px}
.workshop-stock-popup .catalogue-selection-panel{display:flex;flex-direction:column;gap:10px;min-width:0;min-height:0;overflow:hidden;border-left:1px solid var(--z-border,#d6e4e5);padding-left:14px}
.workshop-stock-popup .catalogue-session-items{flex:none;min-width:0;border:1px solid color-mix(in srgb,var(--z-primary,#008579) 45%,var(--z-border,#d6e4e5));border-radius:7px;padding:0;overflow:hidden;font-size:.78rem}
.workshop-stock-popup .catalogue-session-items header{padding:7px 10px;background:color-mix(in srgb,var(--z-primary,#008579) 8%,var(--z-surface,#fff))}
.workshop-stock-popup .catalogue-session-items>small,.workshop-stock-popup .catalogue-session-empty{display:block;margin:0;padding:6px 10px}
.workshop-stock-popup .catalogue-selection-details{display:flex;flex-direction:column;gap:8px;flex:1 1 0;min-width:0;min-height:0;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;padding:0 2px 0 0}
.workshop-stock-popup .catalogue-selection-details>*{flex-shrink:0;min-width:0;max-width:100%;box-sizing:border-box;overflow-wrap:anywhere}
.workshop-stock-popup .workshop-selected-product{margin:0;padding:9px 10px;background:color-mix(in srgb,var(--z-primary,#008579) 7%,var(--z-surface,#fff))}
.workshop-stock-popup .workshop-selected-product strong{overflow-wrap:anywhere}
.workshop-stock-popup .catalogue-selection-hint{margin:4px 0;color:var(--z-muted,#546c73)}
.workshop-stock-popup .frame-choice-controls{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,2fr);gap:8px}
.workshop-stock-popup .lens-choice-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px 8px}
.workshop-stock-popup .lens-choice-note{grid-column:1/-1}
.workshop-stock-popup .lens-power-availability{flex:none;min-height:0;max-height:none;overflow:visible;margin:0;padding:4px 0}
.workshop-stock-popup .lens-stock-table-scroll{min-height:0;max-height:27vh;overflow:auto}
.workshop-stock-popup .lens-stock-table-scroll table{width:100%;min-width:0;table-layout:fixed;margin:0}
.workshop-stock-popup .lens-stock-table-scroll :is(th,td){padding:5px 4px;font-size:.75rem;white-space:normal;overflow-wrap:anywhere}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(-n+4){width:9%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(5){width:15%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(6){width:31%}
.workshop-stock-popup .lens-stock-table-scroll th:last-child{width:18%}
.workshop-stock-popup .lens-stock-table-scroll button{max-width:100%;min-width:0;padding:5px 7px}
.workshop-stock-popup .catalogue-add-success,.workshop-stock-popup .catalogue-pending-stock{padding:6px 8px;border:1px solid var(--z-border,#aad7ca);border-radius:5px;background:color-mix(in srgb,var(--z-primary,#008579) 7%,var(--z-surface,#fff));color:var(--z-text,#17383d);font-size:.8rem}
.workshop-stock-popup .catalogue-selection-actions{display:flex;justify-content:flex-end;position:sticky;bottom:0;z-index:1;padding:7px 0 1px;background:var(--z-surface,#fff);margin-top:0}
.workshop-stock-popup .catalogue-selection-actions button{min-width:132px;padding:9px 18px}
.workshop-stock-popup .catalogue-search-footer{display:flex;align-items:center;position:relative;bottom:auto;flex:none;min-width:0;margin:0;padding:6px 0 0;gap:8px;background:var(--z-surface,#fff);border-top:1px solid var(--z-border,#d6e4e5);box-sizing:border-box}
.workshop-stock-popup .catalogue-search-footer small{font-size:.75rem;color:var(--z-muted,#546c73)}
.workshop-stock-popup .catalogue-search-footer .catalogue-cancel{margin-left:auto;flex:none;white-space:nowrap;padding:6px 18px}
@media(max-width:750px){.workshop-stock-popup .catalogue-popup-body{gap:8px}.workshop-stock-popup .catalogue-selection-panel{padding-left:8px}.workshop-stock-popup .product-popup-search{grid-template-columns:minmax(0,1fr)}.workshop-stock-popup .workshop-search-choice{flex-direction:column}.workshop-stock-popup .workshop-search-choice>span:last-child{max-width:100%;text-align:left}.workshop-stock-popup .lens-choice-controls{grid-template-columns:repeat(2,minmax(0,1fr))}}

.workshop-other-branch-stock{flex:none;border:1px solid var(--optical-theme-border, #c8dce3);border-radius:6px;padding:8px 10px;background:var(--optical-theme-info-soft, #f3f8fb);display:flex;flex-direction:column;gap:5px;font-size:.8rem}.workshop-other-branch-stock:empty{display:none}.workshop-other-branch-stock ul{list-style:none;margin:0;padding:0;max-height:100px;overflow:auto}.workshop-other-branch-stock li{display:flex;justify-content:space-between;gap:10px;padding:4px 0}.workshop-other-branch-stock li strong{white-space:nowrap}

/* Approved Workshop catalogue layout: presentation only. */
.workshop-stock-popup .catalogue-popup-body{grid-template-columns:minmax(0,45fr) minmax(0,55fr);gap:12px}
.workshop-stock-popup .catalogue-selection-panel{gap:10px;padding-left:12px}
.workshop-stock-popup .catalogue-selection-details{border:1px solid var(--z-border,#d6e4e5);border-radius:8px;padding:0 10px 10px;gap:8px}
.workshop-stock-popup .workshop-selected-product{display:flex;align-items:center;gap:12px;margin:0 -10px;padding:12px;background:color-mix(in srgb,var(--z-primary,#008579) 8%,var(--z-surface,#fff));border-radius:0;max-width:none}
.selector-selected-icon,.selector-session-icon{display:grid;place-items:center;background:var(--z-surface,#fff);border:1px solid var(--z-border,#d6e4e5);border-radius:7px;color:var(--z-primary,#008579);flex:none}
.selector-selected-icon{width:54px;height:58px}.selector-selected-icon svg{width:43px;height:38px}.selector-session-icon{width:30px;height:30px}.selector-session-icon svg{width:26px;height:25px}
.selector-selected-copy{flex:1;min-width:0}.selector-selected-copy>strong{display:block;font-size:.95rem}.selector-selected-copy small{display:block;margin-top:3px}.selector-selected-price{flex:none;text-align:right;font-size:.82rem}.selector-selected-price small{display:block;margin-top:7px}
.selector-stock-dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:4px}.selector-stock-dot.in-stock{background:#15a65b}.selector-stock-dot.no-stock{background:#b76666}.selector-out-label{color:var(--z-danger,#b34e4e)}
.workshop-stock-popup .workshop-search-choice{padding:9px 10px;border-radius:5px;min-height:70px}.workshop-stock-popup .workshop-search-choice.selected{border-left:3px solid var(--z-primary,#008579)}.selector-card-copy>strong{font-size:.84rem;line-height:1.3}.selector-card-power,.selector-prescription{color:var(--z-primary,#007c72)}
.workshop-stock-popup .selector-active-action{flex:none;min-height:0}.workshop-stock-popup .catalogue-selection-actions{position:static;padding:0;justify-content:flex-end}.workshop-stock-popup .catalogue-selection-actions button{min-width:145px}.workshop-stock-popup .lens-choice-note{font-size:.7rem}.workshop-stock-popup .lens-power-availability>strong{font-size:.84rem}.workshop-stock-popup .lens-stock-table-scroll{max-height:180px}.workshop-stock-popup .workshop-selection-requirement{font-size:.74rem}.workshop-stock-popup .workshop-other-branch-stock{font-size:.73rem;padding:7px}.workshop-stock-popup .catalogue-selection-hint{padding:16px 2px;font-size:.9rem}

.workshop-stock-popup .catalogue-selection-details:has(.frame-choice-controls),.workshop-stock-popup .catalogue-selection-details:has(.catalogue-selection-hint){flex:0 1 auto}
.workshop-stock-popup .catalogue-selection-details:has(.workshop-selected-product){border-bottom:0;border-radius:8px 8px 0 0}
.workshop-stock-popup .selector-active-action:has(button){margin-top:-10px;padding:8px 10px 10px;border:1px solid var(--z-border,#d6e4e5);border-top:0;border-radius:0 0 8px 8px;background:var(--z-surface,#fff)}
 .workshop-stock-popup .frame-choice-controls:not(:has(select)){grid-template-columns:minmax(120px,220px)}

/* Session amounts reuse Workshop grid values; only the rows scroll. */
.workshop-stock-popup .catalogue-session-scroll{max-height:clamp(105px,23vh,230px);overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain}
.workshop-stock-popup .catalogue-session-table{width:100%;min-width:0;table-layout:fixed;border-collapse:collapse;font-size:.75rem}
.catalogue-session-table .session-product-col{width:43%}.catalogue-session-table .session-price-col{width:17%}.catalogue-session-table .session-qty-col{width:7%}.catalogue-session-table .session-total-col{width:20%}.catalogue-session-table .session-remove-col{width:13%}
.workshop-stock-popup .catalogue-session-table th{position:sticky;top:0;background:var(--z-surface,#fff);z-index:1;font-size:.7rem;font-weight:700;text-transform:none;letter-spacing:normal}
.workshop-stock-popup .catalogue-session-table :is(th,td){padding:6px 7px;border-bottom:1px solid var(--z-border,#d6e4e5);vertical-align:middle;overflow-wrap:anywhere}
.workshop-stock-popup .catalogue-session-table .session-money{text-align:right;font-variant-numeric:tabular-nums}
.workshop-stock-popup .selector-session-product{display:flex;align-items:center;gap:6px;min-width:0}
.workshop-stock-popup .catalogue-session-table .selector-session-copy strong{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;line-height:1.25;font-size:.74rem}
.workshop-stock-popup .catalogue-session-table .selector-session-copy small{font-size:.68rem;line-height:1.25}
.workshop-stock-popup .catalogue-session-table .selector-session-icon{width:25px;height:27px}
.workshop-stock-popup .catalogue-session-table .selector-session-remove{max-width:100%;padding:4px 5px!important;min-width:0;font-size:.68rem}
.workshop-stock-popup .catalogue-session-subtotal{display:flex;justify-content:space-between;gap:8px;padding:7px 10px;background:color-mix(in srgb,#8750c8 6%,var(--z-surface,#fff));font-variant-numeric:tabular-nums}

.workshop-stock-popup .catalogue-session-items{border-color:color-mix(in srgb,#8750c8 55%,var(--z-border,#d6e4e5));border-radius:8px}
.workshop-stock-popup .catalogue-session-items header{background:color-mix(in srgb,#8750c8 12%,var(--z-surface,#fff));font-size:.85rem;padding:9px 10px}
.selector-session-copy{flex:1;font-size:.78rem}.selector-session-copy small{display:block;font-size:.7rem;margin-top:3px}.selector-session-remove{font-size:.72rem;padding:4px 7px!important;flex:none;color:var(--z-danger,#b34e4e)}
@media(max-height:800px){.workshop-stock-popup .workshop-selected-product{padding:9px 10px}.selector-selected-icon{width:43px;height:46px}.workshop-stock-popup .catalogue-selection-details{gap:6px}.workshop-stock-popup .lens-stock-table-scroll{max-height:140px}}

/* Compact Workshop-only session grid. Monetary values remain bound to the parent grid. */
.workshop-stock-popup .catalogue-popup-body{grid-template-columns:minmax(0,45fr) minmax(0,55fr)}
.workshop-stock-popup .catalogue-session-scroll{max-height:min(360px,48vh)}
.workshop-stock-popup .catalogue-session-table{font-size:.75rem}
.workshop-stock-popup .session-product-col{width:27%}.workshop-stock-popup .session-price-col{width:11%}.workshop-stock-popup .session-qty-col{width:5%}.workshop-stock-popup .session-total-col{width:12%}.workshop-stock-popup .session-spec-col{width:24%}.workshop-stock-popup .session-stock-col{width:13%}.workshop-stock-popup .session-remove-col{width:8%}
.workshop-stock-popup .catalogue-session-table :is(th,td){padding:5px 4px;overflow-wrap:normal;word-break:normal}
.workshop-stock-popup .catalogue-session-table .selector-session-icon{display:none}
.workshop-stock-popup .catalogue-session-table .selector-session-copy strong{font-size:.75rem;line-height:1.3;overflow-wrap:break-word}
.workshop-stock-popup .session-spec,.workshop-stock-popup .session-stock{font-size:.72rem;line-height:1.35;overflow-wrap:break-word!important}
.workshop-stock-popup .session-stock span{color:var(--z-primary,#0f766e)}
.workshop-stock-popup .catalogue-session-table .session-money{white-space:nowrap}
.workshop-stock-popup .catalogue-session-items>small{padding:4px 8px}
.workshop-stock-popup .catalogue-session-items header{padding:7px 9px}
.workshop-stock-popup .catalogue-add-success{flex:none;margin:0;padding:5px 8px;font-size:.8rem;border-radius:6px;background:var(--optical-theme-success-soft, #e8f6f1);color:var(--optical-theme-accent, #0f665c)}
.workshop-stock-popup .catalogue-selection-details[hidden]{display:none}
.workshop-stock-popup .workshop-search-choice{min-height:56px;padding:7px 9px}
.workshop-stock-popup .catalogue-selection-actions button{min-height:36px}
.workshop-stock-popup .catalogue-search-footer{flex:none}

/* Compact summary and one optional read/edit session dialog. */
.workshop-stock-popup .catalogue-session-summary{flex:none;min-width:0;border:1px solid var(--optical-theme-border, #d4bce8);border-radius:8px;overflow:hidden;font-size:.8rem}
.catalogue-session-summary>header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 9px;background:color-mix(in srgb,#8750c8 10%,var(--z-surface,#fff))}
.catalogue-session-summary .session-key-items{padding:5px 9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.catalogue-session-summary button{padding:4px 10px;min-height:32px}
.workshop-stock-popup .catalogue-selection-details{flex:1 1 auto}
.workshop-stock-popup .session-items-overlay{position:absolute;inset:0;z-index:20;background:#12333d66;display:flex;align-items:center;justify-content:center;padding:16px}
.workshop-stock-popup{position:relative}
.workshop-stock-popup .session-items-dialog{width:min(1120px,100%);max-height:100%;display:flex;flex-direction:column;min-height:0;background:var(--z-surface,#fff);border-radius:10px;box-shadow:0 12px 36px #153c4d33;overflow:hidden}
.session-items-dialog>header,.session-items-dialog>footer{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:10px 14px;flex:none}
.session-items-dialog h3{margin:0;font-size:1.05rem}
.workshop-stock-popup .session-items-dialog .catalogue-session-items{flex:1 1 auto;display:flex;flex-direction:column;min-height:0;margin:0 12px}
.workshop-stock-popup .session-items-dialog .catalogue-session-scroll{max-height:60vh;min-height:0;overflow:auto}
.session-items-dialog .catalogue-session-table{font-size:.82rem}
.session-focus-guard{position:absolute;opacity:0;width:1px;height:1px;padding:0;border:0}
.selector-branch-context{color:var(--z-text-muted,#526b76)}
.selector-source-stock{font-size:.8rem;border:1px solid var(--z-border,#d6e4e5);border-radius:6px;padding:7px}
.selector-source-stock>div{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap;margin-top:4px}
/* Nine exact-stock columns; the details panel owns vertical scrolling. */
.workshop-stock-popup .lens-stock-table-scroll{max-height:none;overflow:visible;flex:none}
.workshop-stock-popup .lens-stock-table-scroll table{height:auto;table-layout:fixed}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(-n+3){width:8%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(4){width:7%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(5),.workshop-stock-popup .lens-stock-table-scroll th:nth-child(6),.workshop-stock-popup .lens-stock-table-scroll th:nth-child(7){width:10%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(8){width:27%}
.workshop-stock-popup .lens-stock-table-scroll th:last-child{width:12%}
.workshop-stock-popup .lens-stock-table-scroll :is(th,td){padding:5px 4px;font-size:.75rem;line-height:1.35;overflow-wrap:break-word;word-break:normal;height:auto}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(-n+4){width:7%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(5),.workshop-stock-popup .lens-stock-table-scroll th:nth-child(6),.workshop-stock-popup .lens-stock-table-scroll th:nth-child(7){width:12%}
.workshop-stock-popup .lens-stock-table-scroll th:nth-child(8){width:24%}
.workshop-stock-popup .lens-stock-table-scroll th{white-space:nowrap;text-transform:none;letter-spacing:normal}

/* Existing product-details shell; branch reports are read-only. */
.workshop-page .workshop-product-details-overlay>.optical-product-details{flex-basis:1080px;width:min(1080px,calc(100vw - 28px));max-width:1080px}
.optical-product-details .workshop-product-details-values{gap:8px 16px;margin-top:12px}
.product-details-stock{margin-top:14px;border:1px solid var(--z-border,#d6e4e5);border-radius:7px;padding:8px}
.product-details-stock h3{font-size:.95rem;margin:0 0 5px}
.product-details-stock>small{display:block;font-size:.78rem;margin-bottom:6px}
.product-details-stock table{width:100%;table-layout:fixed;border-collapse:collapse;font-size:.8rem}
.product-details-stock th,.product-details-stock td{padding:6px 7px;border-bottom:1px solid var(--z-border,#d6e4e5);text-align:left;vertical-align:top;overflow-wrap:break-word}
.product-details-stock th{background:var(--z-bg,#f7f9fb)}
.product-details-stock :is(th,td):first-child{width:27%}
.product-details-stock :is(th,td):nth-child(2),.product-details-stock :is(th,td):nth-child(3),.product-details-stock :is(th,td):nth-child(4){width:13%;text-align:right;font-variant-numeric:tabular-nums}
.product-details-stock td small{display:block;color:var(--z-primary,#0f766e)}
.details-current-branch{background:color-mix(in srgb,var(--z-primary,#0f766e) 8%,var(--z-surface,#fff))}
.details-power{font-size:.82rem;font-weight:600;margin:8px 0}

.workshop-split-toggle{display:flex!important;align-items:center;gap:6px;margin:5px 0;font-size:.82rem}
.workshop-split-toggle input{width:auto!important;min-height:0!important}
.workshop-split-fields{display:grid;gap:6px;min-width:0}
.workshop-split-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:7px}
.workshop-split-row label{display:flex;flex-direction:column;gap:3px;font-size:.8rem}
.workshop-split-row input{height:36px;width:100%;min-width:0;box-sizing:border-box}
.workshop-split-totals{display:flex;flex-wrap:wrap;justify-content:space-between;gap:5px;padding:7px;background:var(--z-bg,#f7f9fb);font-size:.8rem}
.workshop-split-totals strong{font-variant-numeric:tabular-nums;display:block}

.workshop-payment-rows{display:grid;gap:7px;min-width:0}
.workshop-payment-row{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr) 32px;gap:5px 7px;align-items:end;min-width:0}
.workshop-payment-row label{display:flex;flex-direction:column;gap:3px;font-size:.8rem;min-width:0}
.workshop-payment-row :is(input,select){height:36px;min-width:0;width:100%;box-sizing:border-box}
.workshop-payment-row .payment-row-remove{height:36px;padding:3px;min-width:0}
.workshop-payment-row .payment-row-reference{grid-column:1/-1}
.add-payment-row{justify-self:start;min-height:32px}
@media(max-width:420px){.workshop-payment-row{grid-template-columns:minmax(0,1fr) minmax(72px,.8fr) 30px;gap:5px}}

.workshop-stock-popup .lens-eye-panels{grid-column:1/-1;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
.workshop-stock-popup .lens-eye-panel{display:flex;flex-direction:column;gap:5px;padding:7px;border:1px solid var(--z-border,#d6e4e5);border-radius:6px;min-width:0;background:var(--z-surface,#fff)}
.lens-eye-prescription{font-size:.76rem;line-height:1.4;overflow-wrap:break-word}
.workshop-stock-popup .lens-eye-panel label{font-size:.76rem}
.workshop-stock-popup .lens-eye-panel small{font-size:.75rem;color:var(--z-primary,#0f766e)}
.lens-stock-source{display:block;font-size:.7rem;color:var(--z-text-muted,#526b76);margin-top:3px;overflow-wrap:anywhere}
@media(max-width:750px){.workshop-stock-popup .lens-eye-panels{grid-template-columns:minmax(0,1fr)}}

.workshop-counter-next{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 16px;border:1px solid var(--optical-theme-border, #b9ddd7);border-left:4px solid var(--z-primary,#0f766e);border-radius:8px;background:var(--optical-theme-info-soft, #eff8f6);margin:0 0 12px;min-width:0}.workshop-counter-next h2{font-size:15px;margin:0 0 4px;color:var(--optical-theme-accent, #114c49)}.workshop-counter-next p{font-size:13px;line-height:1.4;margin:0}.workshop-counter-next small{display:block;font-size:12px;margin-top:4px;color:var(--optical-theme-warning, #6b4c21)}.workshop-counter-next button{min-height:36px;flex-shrink:0;white-space:nowrap}@media(max-width:700px){.workshop-counter-next{align-items:flex-start;flex-direction:column}.workshop-counter-next button{align-self:flex-end}}

/* One compact manual collection row; all supplied references are retained. */
.workshop-payment-row{grid-template-columns:minmax(0,1.1fr) minmax(80px,.8fr) minmax(0,1fr) 32px}.workshop-payment-row .payment-row-reference{grid-column:3;grid-row:1}.workshop-payment-row .payment-row-remove{grid-column:4;grid-row:1}
@media(max-width:600px){.workshop-payment-row{grid-template-columns:minmax(0,1fr) minmax(80px,.8fr) 32px}.workshop-payment-row .payment-row-remove{grid-column:3}.workshop-payment-row .payment-row-reference{grid-column:1/-1;grid-row:2}}

/* DIA review reuses current stock data; technical details stay optional. */
.lens-dia-guidance{grid-column:1/-1;color:var(--optical-theme-muted, #52687b);font-size:12px;line-height:17px}.lens-batch-secondary{font-size:12px;margin-top:3px}.lens-power-availability>summary,.product-details-stock>summary{font-weight:650;cursor:pointer}.details-stock-options{display:flex;flex-wrap:wrap;gap:12px;margin:5px 0}.details-stock-options label{display:flex;align-items:center;gap:5px;font-size:12px}.product-details-stock td:nth-child(n+2){font-variant-numeric:tabular-nums}.product-details-stock table{width:100%;table-layout:auto}

/* Compact stock review: one body scrollbar, fixed identity and actions. */
.workshop-page .workshop-product-details-overlay>.optical-product-details{max-height:calc(100dvh - 28px);display:flex;flex-direction:column;overflow:hidden}
.optical-product-details>.optical-popup-header{padding:10px 14px;gap:10px;flex:none}
.optical-product-details>.optical-popup-header>div{min-width:0}.optical-product-details>.optical-popup-header h2{font-size:16px;line-height:21px;overflow-wrap:break-word}.optical-product-details>.optical-popup-header p{font-size:12px;line-height:17px;margin:2px 0 0}
.optical-product-details>.optical-popup-body{padding:10px 14px;min-height:0;overflow:auto;flex:1 1 auto}.optical-product-details>.optical-popup-footer{padding:8px 14px;flex:none}
.optical-product-details .details-header-price{margin-left:auto;text-align:right;flex:none}.details-header-price small,.details-header-price strong{display:block}.details-header-price strong{font-size:18px;white-space:nowrap}.details-header-price small{font-size:11px}
.details-stock-cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.details-stock-cards>div{padding:7px 10px;border:1px solid var(--optical-theme-border, #d6e4e5);border-radius:7px;background:var(--optical-theme-info-soft, #f4f9fa)}.details-stock-cards span{font-size:12px}.details-stock-cards strong{display:block;font-size:21px;line-height:26px}.details-stock-cards>div:nth-child(3){background:var(--optical-theme-success-soft, #ecf9f1);color:var(--optical-theme-success, #086b45)}.details-stock-cards>div:nth-child(4){background:var(--optical-theme-warning-soft, #fff8eb)}.details-stock-scope{display:block;font-size:12px;margin:4px 0;color:var(--optical-theme-muted, #52687b)}
.optical-product-details .product-details-stock{margin-top:8px;padding:7px 9px}.optical-product-details .product-details-stock h3{font-size:14px;margin-bottom:4px}.details-eye-matches{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.details-eye-matches>div{border:1px solid var(--optical-theme-border, #d6e4e5);border-radius:6px;padding:6px 8px}.details-eye-matches strong,.details-eye-matches span{display:block}.details-eye-matches small{font-size:12px;line-height:17px}.details-eye-matches .details-supplier-required{color:var(--optical-theme-warning, #9b4d00)}
.optical-product-details .details-section-heading{display:flex;align-items:center;justify-content:space-between;gap:8px}.optical-product-details .details-stock-options label,.optical-product-details .details-section-heading label{display:flex!important;flex-direction:row!important;align-items:center;gap:6px;font-size:12px;line-height:18px;margin:0;width:auto}.optical-product-details .details-stock-options input[type=checkbox],.optical-product-details .details-section-heading input[type=checkbox]{width:15px!important;height:15px!important;min-height:0!important;padding:0!important;flex:none;margin:0}
.optical-product-details .details-power-stock :is(th,td){width:auto;text-align:left;padding:5px 6px}.optical-product-details .details-power-stock :is(th,td):nth-child(5){text-align:right}.optical-product-details .details-power-stock :is(th,td):last-child{width:38%}
.lens-eye-panels{gap:7px}.lens-eye-panel{padding:7px!important}.lens-eye-prescription{line-height:17px}.lens-choice-controls{gap:6px!important}.lens-choice-note,.lens-dia-guidance{margin:0;line-height:16px}.lens-choice-controls select{min-width:0;max-width:100%}.catalogue-selection-details .workshop-selected-product{padding:7px!important}.catalogue-selection-details .selector-selected-price{max-width:47%}
@media(max-width:650px){.details-stock-cards{grid-template-columns:repeat(2,minmax(0,1fr))}.details-eye-matches{grid-template-columns:1fr}.optical-product-details .details-header-price strong{font-size:15px}.optical-product-details .optical-popup-icon{display:none}}
/* Selected Products: compact readable columns; existing selection and totals are unchanged. */
.workshop-stock-popup .session-items-dialog{width:min(1320px,100%);color:var(--z-text,#17383d)}
.workshop-stock-popup .session-items-dialog .catalogue-session-table{width:100%;min-width:0;table-layout:fixed;font-size:.82rem}
.workshop-stock-popup .session-items-dialog .session-product-col{width:27%}
.workshop-stock-popup .session-items-dialog .session-price-col{width:9%}
.workshop-stock-popup .session-items-dialog .session-qty-col{width:5%}
.workshop-stock-popup .session-items-dialog .session-total-col{width:10%}
.workshop-stock-popup .session-items-dialog .session-spec-col{width:26%}
.workshop-stock-popup .session-items-dialog .session-stock-col{width:17%}
.workshop-stock-popup .session-items-dialog .session-remove-col{width:6%}
.workshop-stock-popup .session-items-dialog .catalogue-session-table :is(th,td){padding:10px 9px;vertical-align:middle}
.workshop-stock-popup .session-items-dialog .catalogue-session-table th{font-size:.76rem;line-height:1.35;white-space:normal}
.workshop-stock-popup .session-items-dialog .selector-session-copy strong{display:block;-webkit-line-clamp:unset;font-size:.84rem;line-height:1.4;overflow:visible;overflow-wrap:anywhere}
.workshop-stock-popup .session-items-dialog .selector-session-copy small{display:block;margin-top:3px;color:var(--z-text-muted,#59707c);overflow-wrap:anywhere;font-size:.73rem}
.workshop-stock-popup .session-items-dialog .session-prescription{display:flex;flex-direction:column;gap:4px;font-size:.78rem;line-height:1.5}
.workshop-stock-popup .session-items-dialog .session-prescription small{font-size:.75rem;color:var(--z-text-muted,#59707c)}
.workshop-stock-popup .session-items-dialog .session-status{display:inline-flex;align-items:center;gap:6px;max-width:100%;box-sizing:border-box;padding:5px 8px;border:1px solid var(--z-border,#d2e1e6);border-radius:6px;background:color-mix(in srgb,var(--z-primary,#007d73) 8%,var(--z-surface,#fff));color:var(--z-text,#17383d);font-size:.74rem;line-height:1.4;word-break:normal;overflow-wrap:normal}
.workshop-stock-popup .session-items-dialog .selector-session-remove{width:32px;height:32px;color:var(--z-danger,#be303c);margin:auto}
.workshop-stock-popup .session-items-dialog .catalogue-session-subtotal{padding:10px 12px;font-size:.88rem;flex:none}
.workshop-stock-popup .session-items-dialog .catalogue-session-scroll{overflow-y:auto;overflow-x:hidden}
@media(max-width:760px){
.workshop-stock-popup .session-items-overlay{padding:8px}
.workshop-stock-popup .session-items-dialog .catalogue-session-table colgroup{display:none}
.workshop-stock-popup .session-items-dialog .catalogue-session-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.workshop-stock-popup .session-items-dialog .catalogue-session-table tbody tr{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));border-bottom:1px solid var(--z-border,#d2e1e6);padding:6px 0}
.workshop-stock-popup .session-items-dialog .catalogue-session-table td{display:block;border:0;min-width:0;padding:6px 8px}
.workshop-stock-popup .session-items-dialog .catalogue-session-table td:first-child,.workshop-stock-popup .session-items-dialog .session-spec{grid-column:1/-1}
.workshop-stock-popup .session-items-dialog .session-stock{grid-column:1/3}
.workshop-stock-popup .session-items-dialog .session-money:before{content:attr(data-label);display:block;white-space:normal;font-size:.7rem;color:var(--z-text-muted,#59707c);margin-bottom:3px}
.session-items-dialog>footer{flex-wrap:wrap}
}

/* Compact Workshop entry controls; existing handlers and monetary formatting are retained. */
:is(.workshop-page,.repair-entry) .workshop-fitting-choice{border:0;padding:0;margin:0 0 10px;min-width:0}
.workshop-fitting-choice legend{font-size:.78rem;color:var(--z-text-muted);margin-bottom:5px}
.workshop-fitting-options{display:grid;grid-template-columns:1fr 1fr;gap:8px}
:is(.workshop-page,.repair-entry) .workshop-fitting-card{display:flex;align-items:flex-start;gap:8px;padding:9px;border:1px solid var(--optical-theme-border,#cfe1e7);border-radius:8px;background:var(--z-surface,#fff);cursor:pointer;min-width:0}
.workshop-fitting-card>span:not(.fitting-check){min-width:0;flex:1}.workshop-fitting-card strong{display:block;font-size:.82rem}.workshop-fitting-card small{display:block;font-size:.72rem;line-height:1.35;margin-top:3px;color:var(--z-text-muted,#536974)}
:is(.workshop-page,.repair-entry) .workshop-fitting-card input{width:16px;height:16px!important;min-height:16px!important;margin:2px 0 0;flex:none;accent-color:var(--z-primary,#0f766e)}
:is(.workshop-page,.repair-entry) .workshop-fitting-card.is-selected{border-color:var(--optical-theme-accent,#0f766e);background:var(--optical-theme-success-soft,#e5f6f0);box-shadow:inset 0 0 0 1px var(--optical-theme-accent,#0f766e)}
.workshop-fitting-card:focus-within{outline:2px solid var(--z-primary,#0f766e);outline-offset:2px}.fitting-check{width:16px;color:var(--optical-theme-accent,#0f766e);font-weight:700}.workshop-fitting-choice:disabled .workshop-fitting-card{cursor:default;opacity:.75}
.workshop-page .workshop-discount-table table{width:100%;min-width:940px;table-layout:fixed}
.workshop-page .workshop-discount-table th:first-child{width:28px}.workshop-page .workshop-discount-table th:nth-child(2){width:auto}.workshop-page .workshop-discount-table th:nth-child(3){width:38px}.workshop-page .workshop-discount-table th:nth-child(4){width:62px}.workshop-page .workshop-discount-table th:nth-child(5){width:48px}.workshop-page .workshop-discount-table th:nth-child(6){width:90px}.workshop-page .workshop-discount-table th:nth-child(7){width:112px}.workshop-page .workshop-discount-table th:nth-child(8){width:44px}.workshop-page .workshop-discount-table th:nth-child(9){width:100px}.workshop-page .workshop-discount-table th:last-child{width:44px}
.workshop-page .workshop-discount-table th,.workshop-page .workshop-discount-table td{padding:6px 4px}.workshop-page .workshop-product-thumbnail{flex-basis:44px;width:44px;height:44px}.workshop-page .workshop-product-detail{gap:8px}.workshop-page .workshop-product-copy strong{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;font-size:.81rem}.workshop-page .workshop-product-copy small{overflow-wrap:anywhere}
.workshop-entry-feedback{display:flex;align-items:flex-start;gap:10px;margin:0 0 10px;position:static;overflow-wrap:anywhere}.workshop-entry-feedback>span{flex:1;min-width:0}.workshop-entry-feedback button{background:transparent;border:0;color:inherit;font-size:18px;cursor:pointer;flex:none}.workshop-entry-feedback button:focus-visible{outline:2px solid var(--z-primary,#0f766e)}
@media(max-width:650px){.workshop-fitting-options{grid-template-columns:1fr}}

.workshop-page .workshop-discount-table th{white-space:normal;overflow-wrap:anywhere}

/* Shared compact catalogue. Keep the detail card content-sized and scroll it when needed. */
.workshop-stock-popup.catalogue-compact .catalogue-selection-details {
    flex: 0 1 auto;
    gap: 6px;
    padding-block-end: 6px;
}
.workshop-stock-popup.catalogue-compact .selector-active-action:has(button) {
    padding-block: 6px 8px;
}
.workshop-stock-popup.catalogue-compact .catalogue-selection-actions button {
    min-height: 34px;
    padding-block: 6px;
}
.workshop-stock-popup.catalogue-compact .product-popup-search input,
.workshop-stock-popup.catalogue-compact .lens-choice-controls :is(input, select) {
    min-height: 32px;
    border: 1px solid var(--z-border);
    border-radius: 5px;
    background: var(--z-surface);
    color: var(--z-text);
}
.workshop-stock-popup.catalogue-compact .lens-choice-controls select:disabled {
    background: var(--z-surface-alt, var(--z-surface));
}
.workshop-stock-popup.catalogue-compact .lens-stock-table-scroll :is(th, td) {
    padding-block: 4px;
}
.workshop-stock-popup.catalogue-compact .catalogue-search-footer {
    padding-block: 6px 0;
}

.workshop-stock-popup .workshop-search-choice.catalogue-keyboard-focused {
    outline: 2px solid var(--z-primary);
    outline-offset: -2px;
}

.workshop-stock-popup .catalogue-selector-host { display: contents; }
