html.pq-dialog-windows :is(.pq-popup-maximize,.pq-popup-close-proxy,.pq-popup-window-actions,.pq-popup-resize-handle){display:none}
/* Popup geometry controls apply to SaaS windows in both visual themes; never to printed documents. */
@layer pq-desktop-ui {
@media screen and (min-width:761px) and (any-pointer:fine) {
html.pq-dialog-windows [data-pq-popup-static]{position:relative!important}
html.pq-dialog-windows [data-pq-popup-moved]{translate:calc(var(--pq-popup-base-x,0px) + var(--pq-popup-x,0px)) calc(var(--pq-popup-base-y,0px) + var(--pq-popup-y,0px))!important}
html.pq-dialog-windows [data-pq-popup-handle]{cursor:grab!important;column-gap:6px!important}
html.pq-dialog-windows[data-pq-popup-gesture]{user-select:none!important}
html.pq-dialog-windows[data-pq-popup-gesture="move"],html.pq-dialog-windows[data-pq-popup-gesture="move"] *{cursor:grabbing!important}
html.pq-dialog-windows [data-pq-popup-handle] :is(button,input,select,textarea,a,label,[contenteditable="true"]){cursor:auto}
html.pq-dialog-windows :is(.pq-popup-maximize,.pq-popup-close-proxy){display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 24px!important;width:24px!important;min-width:24px!important;height:24px!important;min-height:24px!important;margin:0 4px!important;padding:0!important;border:1px solid #cbd5e1!important;border-radius:4px!important;background:#fff!important;color:#536780!important;font:15px/1 system-ui,"Microsoft YaHei",sans-serif!important;cursor:pointer!important;white-space:nowrap!important}
html.pq-dialog-windows .pq-popup-maximize+button{margin-left:0!important}
html.pq-dialog-windows .pq-popup-maximize:hover{background:#edf4ff!important;border-color:#93b4e7!important}
html.pq-dialog-windows :is(.pq-popup-maximize,.pq-popup-close-proxy){align-self:center!important}
html.pq-dialog-windows .pq-popup-maximize{margin-left:auto!important;margin-right:0!important}
html.pq-dialog-windows .pq-popup-maximize:focus-visible{outline:2px solid #3b82f6;outline-offset:1px}
html.pq-dialog-windows .pq-popup-window-actions{display:flex!important;align-items:center;gap:4px;margin-left:auto}
html.pq-dialog-windows .pq-popup-window-actions[data-pq-popup-floating]{position:absolute!important;top:8px;right:8px;z-index:20}
html.pq-dialog-windows [data-pq-popup-heading-only]{padding-right:76px!important}
html.pq-dialog-windows[data-interface-style="online"] #schedule-order-modal #orders-drawer>.order-detail-header[data-pq-popup-handle]{grid-template-columns:minmax(120px,1fr) max-content max-content 60px!important}
html.pq-dialog-windows[data-interface-style="online"] #schedule-order-modal .order-detail-header>.pq-popup-maximize{grid-area:close!important;justify-self:start!important;margin:0!important;align-self:center}
html.pq-dialog-windows .pq-popup-resize-handle{display:block!important;position:absolute!important;z-index:25!important;box-sizing:border-box!important;margin:0!important;padding:0!important;touch-action:none}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="n"]{top:0;left:12px;right:12px;height:5px;cursor:ns-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="s"]{bottom:0;left:12px;right:12px;height:5px;cursor:ns-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="e"]{top:12px;bottom:12px;right:6px;width:5px;cursor:ew-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="w"]{top:12px;bottom:12px;left:0;width:5px;cursor:ew-resize}
html.pq-dialog-windows .pq-popup-resize-handle:is([data-pq-popup-edge="nw"],[data-pq-popup-edge="ne"],[data-pq-popup-edge="se"],[data-pq-popup-edge="sw"]){width:12px;height:12px}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="nw"]{top:0;left:0;cursor:nwse-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="ne"]{top:0;right:0;cursor:nesw-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="sw"]{bottom:0;left:0;cursor:nesw-resize}
html.pq-dialog-windows .pq-popup-resize-handle[data-pq-popup-edge="se"]{bottom:5px;right:7px;cursor:nwse-resize;background:repeating-linear-gradient(135deg,transparent 0 3px,#8da1ba 3px 4px,transparent 4px 6px);clip-path:polygon(100% 0,100% 100%,0 100%);opacity:.75}
}
@media print {
html.pq-dialog-windows :is(.pq-popup-maximize,.pq-popup-close-proxy,.pq-popup-window-actions,.pq-popup-resize-handle){display:none!important}
}
}

@layer pq-desktop-ui {
/* Quick-order display adapters keep the original data-action, allocation values and pricing handlers. */
html.pq-dialog-windows #quick-order-entry .qoe-supplier-allocation{container-type:inline-size;container-name:pq-supplier-allocation}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-rows{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-row.is-removable{grid-template-columns:auto minmax(0,1fr) max-content minmax(88px,1.1fr) 26px!important;gap:4px!important;min-width:0}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-row>.qoe-supplier-picker{min-width:0!important}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-picker select{padding-right:22px!important;text-overflow:ellipsis!important}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-row>b{min-width:0!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
html.pq-dialog-windows #quick-order-entry .qoe-supplier-row>em{white-space:nowrap!important}
html.pq-dialog-windows #quick-order-entry .pq-quick-delete{display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 26px!important;width:26px!important;min-width:26px!important;height:26px!important;min-height:26px!important;padding:0!important;border:1px solid #fecaca!important;border-radius:5px!important;background:#fff5f5!important;color:#dc2626!important;font:18px/1 Arial,sans-serif!important;white-space:nowrap!important;word-break:keep-all!important;cursor:pointer!important}
html.pq-dialog-windows #quick-order-entry .pq-quick-delete:hover{background:#fee2e2!important;border-color:#f87171!important}
html.pq-dialog-windows #quick-order-entry .qoe-cost-calc{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:40px!important;box-sizing:border-box!important;padding:0 5px!important;font-size:11px!important;line-height:1.2!important;white-space:nowrap!important;word-break:keep-all!important}
@container pq-supplier-allocation (max-width:480px){
 html.pq-dialog-windows #quick-order-entry .qoe-supplier-rows{grid-template-columns:minmax(0,1fr)!important}
}
@container pq-supplier-allocation (max-width:400px){
 html.pq-dialog-windows #quick-order-entry .qoe-supplier-row.is-removable{grid-template-columns:auto minmax(0,1fr) max-content 26px!important}
 html.pq-dialog-windows #quick-order-entry .qoe-supplier-row.is-removable>.qoe-supplier-picker{grid-column:1/4!important;grid-row:2!important}
 html.pq-dialog-windows #quick-order-entry .qoe-supplier-row.is-removable>.pq-quick-delete{grid-column:4!important;grid-row:2!important}
}

}


@layer pq-desktop-ui {
/* The original history action needs its own intrinsic column, including native UI fonts. */
html.pq-dialog-windows #quick-order-entry .qoe-history-list{container-type:inline-size;container-name:pq-quick-history}
html.pq-dialog-windows #quick-order-entry .qoe-history-card{box-sizing:border-box;min-width:0;grid-template-columns:minmax(0,.8fr) minmax(0,1fr) minmax(115px,max-content) max-content!important}
html.pq-dialog-windows #quick-order-entry .qoe-history-card>:is(.qoe-history-top,.qoe-history-product,.qoe-history-detail,.qoe-history-price){min-width:0;overflow:hidden}
html.pq-dialog-windows #quick-order-entry .qoe-history-top b,html.pq-dialog-windows #quick-order-entry .qoe-history-top span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html.pq-dialog-windows #quick-order-entry .qoe-history-detail-button{box-sizing:border-box;min-width:74px!important;width:auto!important;max-width:none!important;justify-self:end;align-self:center;white-space:nowrap!important}
@container pq-quick-history (max-width:480px){
html.pq-dialog-windows #quick-order-entry .qoe-history-card{grid-template-columns:minmax(0,1fr) max-content!important}
html.pq-dialog-windows #quick-order-entry .qoe-history-top{grid-column:1;grid-row:1}
html.pq-dialog-windows #quick-order-entry .qoe-history-product{grid-column:1;grid-row:2}
html.pq-dialog-windows #quick-order-entry .qoe-history-detail{grid-column:1;grid-row:3}
html.pq-dialog-windows #quick-order-entry .qoe-history-price{grid-column:1;grid-row:4;text-align:left}
html.pq-dialog-windows #quick-order-entry .qoe-history-detail-button{grid-column:2;grid-row:1/5}
}
}
