.pos-launch{padding:var(--space-section);display:flex;align-items:center;gap:var(--space-fields);flex-wrap:wrap}.pos-launch>.icon{width:36px;height:36px;color:var(--text-link)}.pos-launch>div{flex:1;min-width:180px}.pos-launch h2{font-size:var(--type-section-title);margin:0 0 4px}.pos-launch p{font-size:var(--type-description);color:var(--text-secondary);margin:0}
body.in-workspace dialog.pos-terminal{position:fixed;inset:0;margin:0;width:100%;max-width:none;height:100dvh;max-height:none;padding:0;border:0;border-radius:0;box-sizing:border-box;background:var(--surface-page);color:var(--text-primary);display:none;flex-direction:column;overflow:hidden;font-size:var(--type-body)}body.in-workspace dialog.pos-terminal[open]{display:flex}.pos-terminal [hidden],.pos-dialog [hidden]{display:none!important}.pos-header{display:flex;align-items:center;gap:var(--space-fields);padding:var(--space-fields) max(var(--space-section),env(safe-area-inset-right)) var(--space-fields) max(var(--space-section),env(safe-area-inset-left));border-bottom:1px solid var(--line);background:var(--surface-field);flex:none}.pos-brand{display:grid;place-items:center;width:44px;height:44px;background:var(--accent-soft);color:var(--text-link);border-radius:var(--action-radius);flex-shrink:0}.pos-brand>.icon{width:22px;height:22px}.pos-identity{display:grid;gap:3px;min-width:0;flex:1}.pos-identity strong{font-size:var(--type-section-title)}.pos-identity>span{font-size:var(--type-meta);color:var(--text-secondary);overflow-wrap:anywhere}.pos-cash-status{font-size:var(--type-meta);color:var(--text-secondary);padding:6px 8px;border:1px solid var(--line);border-radius:var(--action-radius)}.pos-cash-status[data-open=true]{color:var(--text-success);background:var(--surface-success);border-color:var(--text-success)}.pos-tools{display:flex;gap:var(--space-inline);align-items:center}.pos-icon{width:var(--control-target);height:var(--control-target);flex-shrink:0;box-shadow:none}.pos-icon>span{display:none}.pos-content{display:grid;grid-template-columns:minmax(0,1fr) minmax(320px,38%);gap:var(--space-section);padding:var(--space-section);flex:1;min-height:0;overflow:hidden}.pos-catalog{display:flex;flex-direction:column;min-height:0;min-width:0;gap:var(--space-fields)}.pos-search{display:grid;grid-template-columns:minmax(0,1fr) var(--control-target) minmax(100px,150px);align-items:end;gap:var(--space-inline)}.pos-search :is(input,select){height:44px}.pos-search>select,.pos-history-filters>select{border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);color:var(--text-primary);padding:8px;min-width:0;min-height:44px}.pos-catalog>.os-note{margin:0;font-size:var(--type-meta)}.pos-products{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:var(--space-inline);align-content:start;overflow:auto;min-height:0;padding:2px}.pos-product{font:inherit;display:grid;gap:5px;align-content:start;text-align:left;min-height:130px;min-width:0;padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);color:var(--text-primary);background:var(--surface-field);box-shadow:none;cursor:pointer;overflow-wrap:anywhere}.pos-product:hover{background:var(--surface-hover)}.pos-product:active{background:var(--surface-pressed);transform:none}.pos-product:disabled{opacity:.55;cursor:default}.pos-product strong{font-size:var(--type-body);line-height:1.4}.pos-product small{font-size:var(--type-meta);color:var(--text-secondary)}.pos-product-icon{color:var(--text-link)}.pos-product-icon>.icon{width:20px;height:20px}.pos-price{font-weight:650;font-size:var(--type-body)}.pos-ticket{display:flex;flex-direction:column;gap:var(--space-fields);min-width:0;min-height:0;padding:var(--space-section);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);overflow:auto}.pos-ticket-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.pos-ticket-head h2{font-size:var(--type-section-title);margin:0}.pos-count{font-size:var(--type-meta);color:var(--text-secondary)}.pos-customer{display:flex;gap:var(--space-inline);min-width:0}.pos-customer>button:first-child{flex:1;min-width:0;justify-content:flex-start;text-align:left}.pos-customer>button:first-child>span{overflow-wrap:anywhere}.pos-lines{display:grid;gap:var(--space-inline);align-content:start;min-height:0;flex:1;overflow:auto;padding:2px}.pos-line{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:var(--space-inline);padding-block:var(--space-inline);border-bottom:1px solid var(--line);align-items:start}.pos-line-info{display:grid;gap:3px;min-width:0;overflow-wrap:anywhere}.pos-line-info strong{font-size:var(--type-body)}.pos-line-info small{font-size:var(--type-meta);color:var(--text-secondary)}.pos-line-total{font-size:var(--type-body);white-space:nowrap;font-variant-numeric:tabular-nums}.pos-line-actions{grid-column:1/-1;display:flex;align-items:center;gap:var(--space-inline)}.pos-line-actions input{box-sizing:border-box;width:68px;height:44px;min-width:44px;min-height:44px;border:1px solid var(--line);border-radius:var(--action-radius);padding:8px;text-align:center;background:var(--surface-page);color:var(--text-primary)}.pos-line-actions>button:last-child{margin-left:auto}.pos-adjust{display:grid;grid-template-columns:minmax(90px,1fr) minmax(0,1.5fr);gap:var(--space-inline)}.pos-totals{display:grid;gap:8px;border-top:1px solid var(--line);padding-top:var(--space-fields)}.pos-totals>div{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap}.pos-totals>div:first-child{font-size:var(--type-meta);color:var(--text-secondary)}.pos-grand-total{font-size:var(--type-section-title);align-items:center}.pos-grand-total>strong{font-size:var(--type-page-title);font-variant-numeric:tabular-nums;color:var(--text-primary)}.pos-cart-empty{display:grid;place-items:center;align-content:center;text-align:center;gap:8px;padding:var(--space-section);color:var(--text-secondary);min-height:120px}.pos-cart-empty>.icon{width:32px;height:32px;color:var(--text-link)}.pos-cart-empty p{font-size:var(--type-meta);margin:0}.pos-footer{display:flex;gap:var(--space-inline);align-items:center;justify-content:flex-end;padding:var(--space-fields) max(var(--space-section),env(safe-area-inset-right)) max(var(--space-fields),env(safe-area-inset-bottom)) max(var(--space-section),env(safe-area-inset-left));border-top:1px solid var(--line);background:var(--surface-field);flex:none}.pos-footer>button{width:auto;flex:0 0 auto}.pos-shortcuts{margin-right:auto;color:var(--text-secondary);font-size:var(--type-meta)}.pos-error,.pos-recovery{margin:8px var(--space-section) 0;padding:var(--space-inline);flex:none}.pos-recovery{display:flex;align-items:center;justify-content:space-between;gap:8px;border:1px solid var(--border-warning);color:var(--text-warning);background:var(--surface-warning);border-radius:var(--action-radius)}.pos-dialog{width:640px;color:var(--text-primary)}.pos-modal-body{display:grid;gap:var(--space-fields);min-width:0}.pos-payment-total,.pos-cash-summary{display:grid;gap:4px;padding-block:8px}.pos-payment-total>strong,.pos-cash-summary>strong{font-size:var(--type-page-title);font-variant-numeric:tabular-nums}.pos-payment-total>span,.pos-cash-summary>span{font-size:var(--type-meta);color:var(--text-secondary)}.pos-payments{display:grid;gap:var(--space-fields)}.pos-payment-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 44px;gap:var(--space-inline);align-items:end}.pos-payment-summary{margin:0;color:var(--text-link);font-size:var(--type-body)}.pos-history-filters{display:grid;grid-template-columns:minmax(0,1fr) minmax(100px,1fr);align-items:end;gap:var(--space-inline)}.pos-history-list{display:grid;gap:var(--space-inline)}.pos-history-item{display:flex;align-items:center;gap:var(--space-inline);justify-content:space-between;padding:var(--space-inline);border:1px solid var(--line);border-radius:var(--action-radius)}.pos-history-item>div{display:grid;gap:4px;min-width:0;overflow-wrap:anywhere}.pos-history-item small{font-size:var(--type-meta);color:var(--text-secondary)}.pos-sale-heading{display:flex;gap:8px;flex-wrap:wrap;justify-content:space-between}.pos-cash-total{display:flex;justify-content:space-between;gap:var(--space-inline);font-size:var(--type-body);min-width:0;overflow-wrap:anywhere}.pos-print-frame{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}.pos-calculator{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--space-inline)}.pos-calculator>button:last-child{grid-column:span 2}.pos-terminal :is(button,input,select):focus-visible,.pos-product:focus-visible{outline:2px solid var(--text-link);outline-offset:2px}.pos-terminal :is(button,.glass-button,.submit-button):active,.pos-dialog :is(button,.glass-button,.submit-button):active{transform:none}.pos-terminal :is(.pos-lines,.pos-products,.pos-ticket,.pos-content){scrollbar-width:thin;scrollbar-color:var(--scroll-thumb) transparent}
@media(max-width:700px){.pos-header{flex-wrap:wrap;padding-top:max(var(--space-inline),env(safe-area-inset-top));gap:var(--space-inline)}.pos-brand{display:none}.pos-cash-status{margin-left:auto}.pos-tools{width:100%;justify-content:flex-end}.pos-tools>button:first-child{margin-right:auto}.pos-content{display:flex;flex-direction:column;padding:var(--space-inline);gap:var(--space-inline);overflow:auto}.pos-catalog{flex:none;min-height:190px;max-height:34dvh}.pos-search{grid-template-columns:minmax(0,1fr) 44px}.pos-search>select{grid-column:1/-1}.pos-products{grid-template-columns:repeat(auto-fill,minmax(135px,1fr));max-height:220px;flex:1}.pos-product{min-height:105px;padding:var(--space-inline);gap:3px}.pos-product-icon{display:none}.pos-catalog>.os-note{display:none}.pos-ticket{flex:1 0 auto;min-height:240px;padding:var(--space-inline);overflow:visible}.pos-lines{flex:1 0 auto;max-height:300px;overflow:auto}.pos-cart-empty{min-height:80px}.pos-footer{flex-wrap:wrap;padding:var(--space-inline);padding-bottom:max(var(--space-inline),env(safe-area-inset-bottom))}.pos-footer>button{flex:1}.pos-shortcuts{display:none}.pos-payment-row{grid-template-columns:minmax(0,1fr) 44px}.pos-payment-row>.os-field:first-child{grid-column:1/-1}.pos-payment-row>.os-field:nth-child(2){grid-column:1}.pos-adjust{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.pos-line-total{white-space:normal;overflow-wrap:anywhere;max-width:105px}.pos-grand-total>strong{font-size:var(--type-page-title)}.pos-recovery{flex-wrap:wrap}.pos-error,.pos-recovery{margin-inline:var(--space-inline)}.pos-launch>button{width:100%}}
@media(max-height:500px) and (min-width:701px){.pos-content{padding:var(--space-inline)}.pos-ticket{gap:var(--space-inline);padding:var(--space-inline)}.pos-shortcuts{display:none}}

.pos-cash-ledger{font-size:var(--type-label);min-width:0}.pos-cash-ledger>summary{min-height:44px;display:flex;align-items:center;cursor:pointer;color:var(--text-link)}.pos-cash-ledger>div{max-height:200px;overflow:auto;display:grid;gap:var(--space-inline);padding:2px;scrollbar-width:thin;scrollbar-color:var(--scroll-thumb) transparent}.pos-cash-ledger .pos-cash-total{border-top:1px solid var(--line);padding-top:var(--space-inline)}.pos-cash-ledger .pos-cash-total>span{min-width:0;display:grid;gap:3px}.pos-cash-ledger small{font-size:var(--type-meta);color:var(--text-secondary);overflow-wrap:anywhere}

:root dialog.pos-terminal>.mobile-notifications.is-dialog-notifications{bottom:calc(var(--pos-footer-height,68px) + var(--space-inline));max-height:calc(100% - var(--pos-footer-height,68px) - 16px)}

.pos-product-media{display:grid;place-items:center;position:relative;width:100%;height:110px;overflow:hidden;border-radius:var(--action-radius);background:var(--surface-page);color:var(--text-link)}.pos-product-media>.icon{width:28px;height:28px}.pos-product-media>img{display:block;width:100%;height:100%;min-width:0;object-fit:contain}.pos-product-media.has-photo>.icon{display:none}@media(max-width:700px){.pos-product-media{height:80px}}

body.in-workspace .pos-search>.os-field{margin:0}body.in-workspace .pos-search :is(input,select,button){box-sizing:border-box;height:var(--control-target);min-height:var(--control-target);margin:0}

.pos-products{grid-auto-rows:max-content}.pos-product{height:auto;align-self:stretch}@media(max-width:700px){.pos-catalog{max-height:45dvh}}

body.in-workspace dialog.pos-cash-dialog{width:480px;padding:var(--space-section)}
.pos-cash-dialog .pos-modal-body{gap:var(--space-fields)}
.pos-cash-overview{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline)}
.pos-cash-overview .pos-cash-summary{padding:0;min-width:0}
.pos-cash-form{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:var(--space-fields)}
body.in-workspace .pos-cash-form>.os-field{margin:0;min-width:0}
.pos-cash-reason{grid-column:1/-1}
.pos-cash-dialog .os-note{margin:0;font-size:var(--type-meta)}
.pos-cash-methods{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-inline);padding-block:var(--space-inline);border-block:1px solid var(--line)}
.pos-cash-methods .pos-cash-total{font-size:var(--type-meta);flex-wrap:wrap}
.pos-cash-dialog .feedback{margin:0}
@media(max-width:360px){.pos-cash-form{grid-template-columns:minmax(0,1fr)}.pos-cash-methods{grid-template-columns:minmax(0,1fr)}}

body.in-workspace dialog.pos-payment-dialog{width:520px;padding:var(--space-section)}
body.in-workspace dialog.pos-order-payment-dialog{width:540px;padding:var(--space-section)}
.pos-order-payment-dialog .pos-modal-body{gap:var(--space-fields);min-width:0}
.pos-order-payment-dialog .os-field,.pos-order-payment-dialog .os-note{margin:0;min-width:0;overflow-wrap:anywhere}
.pos-order-summary{display:grid;gap:var(--space-inline);padding-block:var(--space-inline);border-block:1px solid var(--line)}
.pos-order-settlement{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline);padding-block:var(--space-inline);border-bottom:1px solid var(--line)}
.pos-order-settlement>span{display:grid;gap:var(--space-inline);min-width:0;overflow-wrap:anywhere}
.pos-order-settlement small{font-size:var(--type-meta);color:var(--muted)}
.pos-order-payment-dialog .pos-cash-total{flex-wrap:wrap;gap:var(--space-inline)}
.pos-order-payment-dialog .modal-action-footer{display:flex;flex-wrap:wrap;gap:var(--space-inline)}
.pos-order-payment-dialog .modal-action-footer>.pos-icon{flex:0 0 var(--control-target);width:var(--control-target)}
.pos-order-payment-dialog .modal-action-footer>button:not(.pos-icon){flex:1 1 auto}
@media(max-width:430px){body.in-workspace dialog.pos-order-checkout .customer-dialog-actions{display:flex;flex-direction:column;align-items:stretch}body.in-workspace dialog.pos-order-checkout .customer-dialog-actions>button{width:100%;flex:none}.pos-order-payment-dialog .modal-action-footer>.submit-button{flex-basis:100%}}
body.in-workspace dialog.pos-history-dialog{width:600px;padding:var(--space-section)}
.pos-payment-dialog .pos-payment-total{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline);padding:0 0 var(--space-fields);border-bottom:1px solid var(--line);flex-wrap:wrap}
body.in-workspace .pos-payment-row>.os-field,body.in-workspace .pos-history-filters>.os-field{margin:0;min-width:0}
body.in-workspace :is(.pos-payment-row,.pos-history-filters) :is(input,select){height:var(--control-target);min-height:var(--control-target);box-sizing:border-box;margin:0}
.pos-payment-row{padding:var(--space-inline);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
.pos-payment-tools{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline);flex-wrap:wrap}
.pos-payment-tools>button{width:auto;flex:none}
.pos-payment-summary{display:grid;gap:3px;text-align:right;margin-left:auto;font-variant-numeric:tabular-nums}
.pos-payment-summary>span{font-size:var(--type-meta);color:var(--text-secondary)}
.pos-payment-summary>strong{font-size:var(--type-section-title);color:var(--text-primary)}
.pos-payment-dialog .os-note{margin:0;font-size:var(--type-meta)}
.pos-payment-dialog .feedback,.pos-history-dialog .feedback{margin:0}
body.in-workspace button.pos-history-item{display:grid;grid-template-columns:minmax(0,1fr) auto 16px;gap:var(--space-inline);width:100%;min-height:var(--control-target);margin:0;padding:var(--space-fields);text-align:left;font:inherit;color:var(--text-primary);background:var(--surface-field);box-shadow:none;cursor:pointer;align-items:center}
body.in-workspace button.pos-history-item:hover{background:var(--surface-hover);border-color:var(--text-link)}
body.in-workspace button.pos-history-item:active{background:var(--surface-pressed);transform:none}
.pos-history-copy{display:grid;gap:var(--space-inline);min-width:0;overflow-wrap:anywhere}
.pos-history-copy>strong,.pos-history-amount{font-size:var(--type-body);font-weight:650}
.pos-history-meta{display:flex;align-items:center;gap:var(--space-inline);flex-wrap:wrap;font-size:var(--type-meta);color:var(--text-secondary);font-weight:400}
.pos-history-status{padding:3px 6px;border:1px solid var(--line);border-radius:6px;line-height:1.3;background:var(--surface-page)}
.pos-history-status[data-status=completed]{color:var(--text-success);background:var(--surface-success)}
.pos-history-status[data-status=parked]{color:var(--text-link);background:var(--accent-soft)}
.pos-history-amount{text-align:right;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;max-width:140px}
.pos-history-arrow{display:flex;color:var(--text-secondary)}
.pos-history-arrow>.icon{width:16px;height:16px}
.pos-dialog button.pos-history-item:focus-visible{outline:2px solid var(--text-link);outline-offset:2px}
@media(max-width:360px){.pos-history-filters{grid-template-columns:minmax(0,1fr)}body.in-workspace button.pos-history-item{grid-template-columns:minmax(0,1fr) auto}.pos-history-arrow{display:none}.pos-history-amount{max-width:90px}}

/* Closed register blocks the operational surface while retaining navigation and history. */
.pos-closed-gate{position:absolute;inset:var(--pos-header-height,76px) 0 0;z-index:2;display:grid;place-items:center;padding:var(--space-section);overflow:auto;background:color-mix(in srgb,var(--surface-page) 35%,transparent)}
.pos-terminal[data-register-closed=true]>.pos-content,.pos-terminal[data-register-closed=true]>.pos-footer{filter:blur(5px);pointer-events:none;user-select:none}
.pos-closed-card{width:min(100%,340px);box-sizing:border-box;padding:var(--space-section);display:grid;justify-items:center;gap:var(--space-fields);text-align:center;border:1px solid var(--line);border-radius:var(--action-radius);color:var(--text-primary);background:var(--surface-field)}
.pos-closed-icon{display:grid;place-items:center;width:44px;height:44px;color:var(--text-link);background:var(--accent-soft);border-radius:var(--action-radius)}
.pos-closed-icon>.icon{width:22px;height:22px}
.pos-closed-card h2{margin:0;font-size:var(--type-section-title)}
.pos-closed-card p{margin:0;font-size:var(--type-description);color:var(--text-secondary);overflow-wrap:anywhere}
.pos-closed-actions{display:flex;gap:var(--space-inline);max-width:100%}
.pos-recovery{position:relative;z-index:3}
.pos-cash-approval{display:grid;gap:var(--space-fields);padding-top:var(--space-fields);border-top:1px solid var(--line);min-width:0}
.pos-cash-approval>strong{font-size:var(--type-label)}
body.in-workspace .pos-cash-approval>.os-field{margin:0;min-width:0}
.pos-product strong{font-size:var(--type-label);font-weight:600}
body.in-workspace dialog.pos-calculator-dialog{width:320px;padding:var(--space-section)}
.pos-calculator-screen{display:grid;gap:4px;padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);min-width:0;text-align:right}
.pos-calculator-screen>span,.pos-calculator-expression{font-size:var(--type-meta);color:var(--text-secondary)}
.pos-calculator-expression{margin:0;min-height:1.3em;overflow-wrap:anywhere}
.pos-calculator-display{display:block;font-size:var(--type-page-title);line-height:1.2;font-weight:650;color:var(--text-primary);font-variant-numeric:tabular-nums;overflow-wrap:anywhere;min-width:0}
.pos-calculator-dialog .pos-calculator{gap:var(--space-inline)}
.pos-calculator-dialog .pos-calculator>button{box-shadow:none;margin:0;padding:var(--space-inline);min-width:44px;min-height:44px;border:1px solid var(--line);font-size:var(--type-control)}
.pos-calculator-dialog [data-key=C],.pos-calculator-dialog [data-key="⌫"],.pos-calculator-dialog [data-key="%"]{background:var(--surface-page);color:var(--text-secondary)}
.pos-calculator-dialog [aria-pressed]{background:var(--accent-soft);color:var(--text-link)}
.pos-calculator-dialog [aria-pressed=true]{outline:1px solid var(--text-link);outline-offset:-2px}
.pos-calculator-dialog .pos-calculator>.glass-button:hover{background:var(--surface-hover)}
.pos-calculator-dialog .pos-calculator>.glass-button:active{background:var(--surface-pressed)}

.pos-calculator-display:focus-visible{outline:2px solid var(--text-link);outline-offset:2px;border-radius:4px}

.pos-cash-approval[hidden]{display:none}

body.in-workspace .pos-cancel-dialog{width:480px}.pos-cancel-dialog .os-field{margin:0;min-width:0}

body.in-workspace .pos-authorizations-dialog{width:860px}.pos-authorization-filters{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) minmax(0,1.6fr) 44px;gap:var(--space-inline);align-items:end}.pos-authorization-filters>.os-field{margin:0;min-width:0}.pos-authorization-list{display:grid;gap:var(--space-inline);min-width:0}.pos-authorization-card{border:1px solid var(--line);border-radius:var(--action-radius);padding:var(--space-fields);display:grid;gap:var(--space-inline);background:var(--surface-field);overflow-wrap:anywhere;min-width:0}.pos-authorization-heading,.pos-authorization-meta{display:flex;justify-content:space-between;gap:var(--space-inline);flex-wrap:wrap}.pos-authorization-heading{font-size:var(--type-label)}.pos-authorization-meta,.pos-authorization-mode{font-size:var(--type-meta);color:var(--text-secondary)}.pos-authorization-people{margin:0;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:var(--space-inline);font-size:var(--type-body)}.pos-authorization-people dt{font-size:var(--type-meta);color:var(--text-secondary)}.pos-authorization-people dd{margin:0}.pos-authorization-reason{margin:0;font-size:var(--type-body);white-space:pre-wrap}.pos-authorization-reason>span{color:var(--text-secondary)}@media(max-width:700px){.pos-authorization-filters{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.pos-authorization-filters>.os-field:nth-child(3){grid-column:1/-1;grid-row:2;padding-right:52px}.pos-authorization-filters>button{grid-column:2;grid-row:2;justify-self:end;align-self:end}.pos-authorization-card{padding:var(--space-inline)}}

.pos-authorization-card{grid-template-columns:minmax(0,1fr) 44px;gap:var(--space-inline);padding:var(--space-inline);align-items:center}.pos-authorization-view{appearance:none;border:0;background:transparent;color:inherit;padding:var(--space-inline);margin:0;min-width:0;min-height:var(--control-target);text-align:start;border-radius:var(--action-radius);cursor:pointer;white-space:normal}.pos-authorization-view:hover{background:var(--surface-hover)}.pos-authorization-view:active{background:var(--surface-pressed)}.pos-authorization-content{display:grid;gap:4px;min-width:0;overflow-wrap:anywhere}.pos-authorization-operation{display:flex;align-items:center;gap:var(--space-inline);min-width:0}.pos-authorization-symbol{display:grid;place-items:center;width:28px;height:28px;flex-shrink:0;background:var(--accent-soft);color:var(--text-link);border-radius:var(--action-radius)}.pos-authorization-symbol .icon{width:16px;height:16px}.pos-authorization-meta{justify-content:flex-start;align-items:center;gap:4px var(--space-inline)}.pos-authorization-mode{border:1px solid var(--line);border-radius:var(--action-radius);padding:2px 6px}.pos-authorization-people{font-size:var(--type-label);gap:4px var(--space-inline)}.pos-authorization-people>div{min-width:0}.pos-authorization-people dt,.pos-authorization-people dd{display:inline;font-size:inherit}.pos-authorization-reason{font-size:var(--type-label);line-height:1.4}.pos-authorization-reason.is-preview{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.pos-authorization-share{width:44px;min-width:44px;align-self:center}.pos-authorization-view:focus-visible{outline:2px solid var(--text-link);outline-offset:2px}body.in-workspace .pos-authorization-details{width:600px}@media(max-width:700px){.pos-authorization-people{grid-template-columns:minmax(0,1fr)}.pos-authorization-heading{align-items:center}.pos-authorization-card{padding:4px var(--space-inline)}.pos-authorization-view{padding:4px}.pos-authorization-share{align-self:start;margin-top:4px}}

/* Footer actions share the same row without the primary button's form margin. */
body.in-workspace dialog.pos-terminal .pos-footer>button{margin:0;align-self:stretch}

/* Separate original-style controls, with smaller visible surfaces and 44px targets. */
body.in-workspace dialog.pos-terminal .pos-line-actions{align-items:center;gap:var(--space-inline)}
.pos-quantity-stepper{display:inline-flex;align-items:center;flex:none;gap:0;height:var(--control-target)}
body.in-workspace dialog.pos-terminal .pos-line-actions button{box-sizing:border-box;width:var(--control-target);height:var(--control-target);min-height:var(--control-target);flex:0 0 var(--control-target);padding:0;margin-block:0;border:0;background:transparent;box-shadow:none;backdrop-filter:none;position:relative;isolation:isolate}
body.in-workspace dialog.pos-terminal .pos-quantity-stepper>button:last-child{margin-left:0}
body.in-workspace dialog.pos-terminal .pos-line-actions button>.icon{width:16px;height:16px}
.pos-quantity-field{display:inline-flex;position:relative;flex:none;min-width:var(--control-target);height:var(--control-target);isolation:isolate}
body.in-workspace dialog.pos-terminal .pos-quantity-field>input{box-sizing:border-box;width:100%;min-width:var(--control-target);height:var(--control-target);min-height:var(--control-target);flex-shrink:0;margin:0;padding:0 4px;text-align:center;font-variant-numeric:tabular-nums;border:0;border-radius:0;background:transparent;box-shadow:none;appearance:textfield;-moz-appearance:textfield}
body.in-workspace dialog.pos-terminal .pos-quantity-field>input::-webkit-inner-spin-button,body.in-workspace dialog.pos-terminal .pos-quantity-field>input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
body.in-workspace dialog.pos-terminal .pos-quantity-field>input:focus-visible{outline:0}
.pos-quantity-field::before,body.in-workspace dialog.pos-terminal .pos-line-actions button::before{content:'';position:absolute;inset:6px;z-index:-1;border:1px solid var(--line);border-radius:8px;pointer-events:none}
.pos-quantity-field::before{background:var(--surface-page)}
body.in-workspace dialog.pos-terminal .pos-line-actions button::before{background:var(--surface-field);box-shadow:0 2px 6px color-mix(in srgb,var(--text-primary) 6%,transparent)}
.pos-quantity-field:focus-within::before{border-color:var(--text-link);box-shadow:0 0 0 2px var(--accent-ring)}
body.in-workspace dialog.pos-terminal .pos-line-actions button:hover::before{background:var(--surface-hover)}
body.in-workspace dialog.pos-terminal .pos-line-actions button:active::before{background:var(--surface-pressed)}
/* Keep the order selector refresh action alongside its filters. */
.pos-tools>.submit-button{width:auto;margin:0}
body.in-workspace .pos-order-filters{grid-template-columns:minmax(0,1fr) minmax(110px,1fr) var(--control-target)}
body.in-workspace .pos-order-filters>button{width:var(--control-target);height:var(--control-target);margin:0}
body.in-workspace button.pos-order-item{grid-template-columns:minmax(0,1fr);gap:var(--space-inline)}
.pos-order-copy{display:grid;gap:4px;min-width:0;overflow-wrap:anywhere}
.pos-order-copy>strong{font-size:var(--type-body)}
.pos-order-copy>small{font-size:var(--type-meta);color:var(--text-secondary)}
@media(max-width:430px){body.in-workspace .pos-order-filters{grid-template-columns:minmax(0,1fr) var(--control-target)}.pos-order-filters>.os-field:first-child{grid-column:1;grid-row:1}.pos-order-filters>.os-field:nth-child(2){grid-column:1/-1;grid-row:2}.pos-order-filters>button{grid-column:2;grid-row:1}}

body.in-workspace .pos-order-filters{grid-template-columns:minmax(0,1fr) minmax(0,1.5fr) var(--control-target)}
.pos-order-status-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-inline);min-width:0}
.pos-order-status-filters>.os-field{margin:0;min-width:0}
.pos-order-status-filters select{min-width:0;width:100%;min-height:var(--control-target)}
@media(max-width:600px){body.in-workspace .pos-order-filters{grid-template-columns:minmax(0,1fr) var(--control-target)}.pos-order-status-filters{grid-column:1/-1;grid-row:2}.pos-order-filters>button{grid-column:2;grid-row:1}}

.pos-tools .pos-order-count{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;min-width:20px;height:20px;box-sizing:border-box;padding:0 5px;border-radius:999px;border:1px solid currentColor;background:color-mix(in srgb,currentColor 12%,transparent);font-size:var(--type-meta);font-weight:650;line-height:1;font-variant-numeric:tabular-nums}
@media(max-width:700px){.pos-tools{flex-wrap:wrap}.pos-tools>button{flex:0 0 auto}.pos-tools>button>span:not(.pos-order-count){white-space:nowrap}}

/* Semantic terminal actions approved independently from the personal accent palette. */
.pos-footer .pos-pay-action{--pos-action-bg:#12613f;--pos-action-text:#fff;--pos-action-border:#12613f}
.pos-footer .pos-park-action{--pos-action-bg:#fff0d5;--pos-action-text:#8a4b0f;--pos-action-border:#e9bd7b}
.pos-footer .pos-clear-action{--pos-action-bg:#fce8e8;--pos-action-text:#a33f46;--pos-action-border:#e9b9bc}
:root[data-theme=dark] .pos-footer .pos-pay-action{--pos-action-bg:#176d49;--pos-action-border:#49976b}
:root[data-theme=dark] .pos-footer .pos-park-action{--pos-action-bg:#453321;--pos-action-text:#ffd29a;--pos-action-border:#8c6541}
:root[data-theme=dark] .pos-footer .pos-clear-action{--pos-action-bg:#44292d;--pos-action-text:#ffc2c7;--pos-action-border:#8a525b}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action{color:var(--pos-action-text);background:var(--pos-action-bg);border-color:var(--pos-action-border);box-shadow:0 2px 6px #0000000a;filter:none}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(:disabled):hover{color:var(--pos-action-text);background:color-mix(in srgb,var(--surface-hover) 12%,var(--pos-action-bg));border-color:var(--pos-action-border);filter:none}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(:disabled):active{color:var(--pos-action-text);background:color-mix(in srgb,var(--surface-pressed) 20%,var(--pos-action-bg));border-color:var(--pos-action-border)}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:focus-visible{outline-color:var(--pos-action-border)}
@media(max-width:700px){.pos-footer>button.pos-footer-action{flex:1 1 auto}.pos-footer>button.pos-footer-action>span{white-space:nowrap}}

/* Quiet functional colors keep the OS action as the primary header emphasis. */
.pos-tools .pos-cash-action{--pos-tool-bg:#e2f3ef;--pos-tool-text:#175f55;--pos-tool-border:#a6cec4}
.pos-tools .pos-sales-action{--pos-tool-bg:#e7efff;--pos-tool-text:#345b96;--pos-tool-border:#b4c8ec}
.pos-tools .pos-calculator-action{--pos-tool-bg:#edf0f4;--pos-tool-text:#526074;--pos-tool-border:#c8d0da}
:root[data-theme=dark] .pos-tools .pos-cash-action{--pos-tool-bg:#223b37;--pos-tool-text:#a5dfd1;--pos-tool-border:#476f64}
:root[data-theme=dark] .pos-tools .pos-sales-action{--pos-tool-bg:#263447;--pos-tool-text:#b8d0f8;--pos-tool-border:#4b6588}
:root[data-theme=dark] .pos-tools .pos-calculator-action{--pos-tool-bg:#303236;--pos-tool-text:#d4dae2;--pos-tool-border:#5c636d}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action{background:var(--pos-tool-bg);color:var(--pos-tool-text);border-color:var(--pos-tool-border);box-shadow:0 2px 6px #00000008;filter:none}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):hover{background:color-mix(in srgb,var(--surface-hover) 12%,var(--pos-tool-bg));color:var(--pos-tool-text);border-color:var(--pos-tool-border)}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):active{background:color-mix(in srgb,var(--surface-pressed) 20%,var(--pos-tool-bg));color:var(--pos-tool-text);border-color:var(--pos-tool-border)}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:focus-visible{outline-color:var(--pos-tool-text)}

/* Clearer functional contrast and visible interaction for the terminal actions. */
dialog.pos-terminal{--pos-clear-background:#fce8e8;--pos-clear-foreground:#8f323d;--pos-clear-border:#e9b9bc}
:root[data-theme=dark] dialog.pos-terminal{--pos-clear-background:#44292d;--pos-clear-foreground:#ffc2c7;--pos-clear-border:#8a525b}
.pos-footer .pos-clear-action{--pos-action-bg:var(--pos-clear-background);--pos-action-text:var(--pos-clear-foreground);--pos-action-border:var(--pos-clear-border)}
:root[data-theme=dark] .pos-footer .pos-clear-action{--pos-action-bg:var(--pos-clear-background);--pos-action-text:var(--pos-clear-foreground);--pos-action-border:var(--pos-clear-border)}
.pos-tools .pos-exit-action{--pos-tool-bg:var(--pos-clear-background);--pos-tool-text:var(--pos-clear-foreground);--pos-tool-border:var(--pos-clear-border)}
.pos-tools .pos-cash-action{--pos-tool-bg:#fff2d8;--pos-tool-text:#80521b;--pos-tool-border:#dfc18b}
:root[data-theme=dark] .pos-tools .pos-cash-action{--pos-tool-bg:#423523;--pos-tool-text:#f4d3a1;--pos-tool-border:#80673e}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):hover{background:color-mix(in srgb,var(--surface-hover) 45%,var(--pos-tool-border));border-color:var(--pos-tool-text);box-shadow:0 0 0 2px color-mix(in srgb,var(--pos-tool-border) 32%,transparent),0 4px 10px #00000014}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):active{background:color-mix(in srgb,var(--surface-pressed) 35%,var(--pos-tool-border));border-color:var(--pos-tool-text);box-shadow:inset 0 1px 3px #00000018}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(:disabled):hover{box-shadow:0 0 0 2px color-mix(in srgb,var(--pos-action-border) 35%,transparent),0 4px 10px #00000014}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(.pos-pay-action):not(:disabled):hover{background:color-mix(in srgb,var(--surface-hover) 45%,var(--pos-action-border));border-color:var(--pos-action-text)}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(.pos-pay-action):not(:disabled):active{background:color-mix(in srgb,var(--surface-pressed) 35%,var(--pos-action-border));border-color:var(--pos-action-text)}
:root body.in-workspace dialog.pos-terminal .pos-tools>.submit-button:not(:disabled):hover{box-shadow:0 0 0 2px var(--accent-ring),0 4px 10px #00000014}
.pos-order-live-notice{margin:0;padding:var(--space-inline);font-size:var(--type-label);overflow-wrap:anywhere}

/* Opaque semantic bases prevent translucent hover tokens from washing out the text. */
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):hover{background:linear-gradient(var(--surface-hover),var(--surface-hover)),color-mix(in srgb,var(--pos-tool-bg) 55%,var(--pos-tool-border))}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action:not(:disabled):active{background:linear-gradient(var(--surface-pressed),var(--surface-pressed)),color-mix(in srgb,var(--pos-tool-bg) 35%,var(--pos-tool-border))}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(.pos-pay-action):not(:disabled):hover{background:linear-gradient(var(--surface-hover),var(--surface-hover)),color-mix(in srgb,var(--pos-action-bg) 55%,var(--pos-action-border))}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-footer-action:not(.pos-pay-action):not(:disabled):active{background:linear-gradient(var(--surface-pressed),var(--surface-pressed)),color-mix(in srgb,var(--pos-action-bg) 35%,var(--pos-action-border))}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-pay-action:not(:disabled):hover{background:linear-gradient(var(--surface-hover),var(--surface-hover)),color-mix(in srgb,var(--pos-action-bg) 90%,var(--surface-field))}
:root body.in-workspace dialog.pos-terminal .pos-footer>button.pos-pay-action:not(:disabled):active{background:linear-gradient(var(--surface-pressed),var(--surface-pressed)),color-mix(in srgb,var(--pos-action-bg) 90%,var(--surface-field))}

.pos-payment-order-balance{display:grid;grid-template-columns:minmax(0,1fr) auto var(--control-target);gap:var(--space-inline);align-items:center;font-size:var(--type-label);color:var(--text-secondary);min-width:0}
.pos-payment-order-balance>strong{color:var(--text-primary);font-variant-numeric:tabular-nums}
.pos-payment-order-balance>button{margin:0}

.pos-cash-overview{flex-wrap:wrap}.pos-cash-overview .pos-cash-summary{flex:1 1 160px;overflow-wrap:anywhere}.pos-cash-figures{display:grid;gap:var(--space-inline);min-width:0}.pos-cash-figures:empty{display:none}.pos-cash-live-notice{margin:0;overflow-wrap:anywhere}

@media(max-width:430px){.pos-cash-overview .pos-cash-summary{flex-basis:100%}.pos-cash-overview{justify-content:flex-start}}

.pos-order-receipt-dialog .pos-receipt-delivery-row{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline)}.pos-order-receipt-dialog .pos-receipt-delivery{flex:1;min-width:0}
@media(max-width:430px){.pos-order-receipt-dialog .modal-action-footer>.submit-button:not(.pos-icon){flex-basis:100%;width:100%;grid-column:1/-1}}

/* Histórico do PDV: ritmo compacto sem reduzir os alvos das ações. */
body.in-workspace dialog.pos-authorizations-dialog{width:720px;padding:var(--space-panel)}
body.in-workspace .pos-authorizations-dialog>.mobile-dialog-scroll{padding:0}
body.in-workspace .pos-authorizations-dialog .modal-content-scroll{gap:var(--space-inline)}
body.in-workspace .pos-authorizations-dialog .customer-dialog-header{margin-bottom:0}
body.in-workspace .pos-authorizations-dialog .pos-modal-body{gap:var(--space-inline)}
.pos-authorizations-dialog .os-note{margin:0;font-size:var(--type-meta)}
.pos-authorizations-dialog .pos-authorization-card{padding:var(--space-inline);gap:var(--space-inline);align-items:start;transition:background-color .15s,border-color .15s}
.pos-authorizations-dialog .pos-authorization-view{padding:0;border-radius:4px}
:root body.in-workspace .pos-authorizations-dialog .pos-authorization-view:is(:hover,:active,:focus){background:transparent;color:inherit;box-shadow:none;transform:none}
@media(hover:hover){.pos-authorizations-dialog .pos-authorization-card:hover{background:var(--surface-hover)}}
.pos-authorizations-dialog .pos-authorization-card:has(>.pos-authorization-view:active){background:var(--surface-pressed)}
.pos-authorizations-dialog .pos-authorization-card:has(>:focus-visible){border-color:var(--text-link)}
.pos-authorizations-dialog .pos-authorization-content{gap:4px}
.pos-authorizations-dialog .pos-authorization-symbol{width:24px;height:24px}
:root body.in-workspace .pos-authorizations-dialog button.pos-authorization-share{margin:0;align-self:start;background:transparent;color:var(--text-secondary);border:1px solid var(--line);box-shadow:none}
:root body.in-workspace .pos-authorizations-dialog button.pos-authorization-share:hover{background:var(--surface-hover);color:var(--text-primary);box-shadow:none}
:root body.in-workspace .pos-authorizations-dialog button.pos-authorization-share:active{background:var(--surface-pressed);color:var(--text-primary);transform:none}
@media(prefers-reduced-motion:reduce){.pos-authorizations-dialog .pos-authorization-card{transition:none}}
.pos-authorizations-dialog .pos-authorization-card:not(:has(>.pos-authorization-share)){grid-template-columns:minmax(0,1fr)}

/* Parcelamento do crédito e carrinho mobile, com estado único do terminal. */
.pos-payment-installments{grid-column:1/3}
.pos-payment-installments[hidden]{display:none!important}
.pos-mobile-checkout{display:none}
body.in-workspace dialog.pos-cart-panel{box-sizing:border-box;position:fixed;inset:0 0 0 auto;margin:0;width:min(480px,100%);max-width:100%;height:100dvh;max-height:100dvh;padding:0;border:1px solid var(--line);border-radius:0;background:var(--surface-page);color:var(--text-primary);overflow:hidden}
.pos-cart-panel[open]{display:flex;flex-direction:column}
.pos-cart-panel::backdrop{background:#0006;backdrop-filter:blur(5px)}
.pos-cart-header{display:flex;align-items:center;justify-content:space-between;gap:var(--space-inline);padding:var(--space-panel);padding-top:max(var(--space-panel),env(safe-area-inset-top));border-bottom:1px solid var(--line);flex:none}
.pos-cart-header h2{margin:0;font-size:var(--type-section-title)}
.pos-cart-body{display:flex;flex-direction:column;gap:var(--space-inline);flex:1;min-height:0;overflow:auto;padding:var(--space-inline);scrollbar-width:thin;scrollbar-color:var(--scroll-thumb) transparent;overscroll-behavior:contain}
.pos-cart-body>.pos-ticket{flex:1 0 auto;min-height:0;overflow:visible}
.pos-cart-body>.pos-ticket>.pos-lines{flex:1 0 auto;max-height:none;overflow:visible}
.pos-cart-body>.pos-ticket>.pos-cart-empty{min-height:100px}
.pos-cart-panel>.pos-footer{flex:none;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-inline);padding:var(--space-inline);padding-bottom:max(var(--space-inline),env(safe-area-inset-bottom))}
.pos-cart-panel>.pos-footer>.pos-pay-action{grid-column:1/-1;grid-row:1}
.pos-cart-panel>.pos-footer>button{width:100%;min-width:0}
.pos-cart-panel .pos-shortcuts{display:none}
@media(max-width:700px){
 .pos-terminal>.pos-content>.pos-ticket,.pos-terminal>.pos-footer{display:none}
 .pos-terminal>.pos-content{overflow:hidden;flex:1;min-height:0}
 .pos-terminal .pos-catalog{flex:1;min-height:0;max-height:none}
 .pos-terminal .pos-products{max-height:none;min-height:0;overflow:auto;flex:1}
 .pos-terminal>.pos-mobile-checkout{display:flex;flex:none;padding:var(--space-inline);padding-bottom:max(var(--space-inline),env(safe-area-inset-bottom));border-top:1px solid var(--line);background:var(--surface-field)}
 .pos-mobile-checkout>button{display:flex;align-items:center;gap:var(--space-inline);width:100%;min-width:0;margin:0;padding:var(--action-padding-block) var(--action-padding-inline)}
 .pos-mobile-cart-summary{margin-left:auto;display:grid;gap:2px;text-align:end;min-width:0;font-size:var(--type-meta)}
 .pos-mobile-cart-summary strong{font-size:var(--type-section-title);font-variant-numeric:tabular-nums}
 .pos-payment-installments{grid-column:1/-1}
}

.pos-installment-values,.pos-installment-rules{display:block;font-size:var(--type-meta);font-weight:400;line-height:1.45;color:var(--text-secondary);overflow-wrap:anywhere;min-width:0}
.pos-installment-values[hidden]{display:none!important}

.pos-limit-notice{display:flex;align-items:center;gap:var(--space-inline);min-width:0}
.pos-limit-notice[hidden]{display:none!important}
.pos-limit-notice>.feedback{margin:0;flex:1;min-width:0;font-size:var(--type-meta);overflow-wrap:anywhere}
.pos-limit-notice>.pos-icon{flex:none}

.pos-installment-rules{white-space:pre-line}

.pos-payment-interest{font-size:var(--type-meta);color:var(--text-secondary);white-space:pre-line;overflow-wrap:anywhere}

.pos-installment-values{white-space:pre-line}

.pos-cash-breakdown .pos-cash-total:last-child{grid-column:1/-1;border-top:1px solid var(--line);padding-top:var(--space-inline)}.pos-cash-card-costs>.os-note{grid-column:1/-1;display:block;margin:0;font-size:var(--type-meta);color:var(--text-secondary);line-height:1.45;overflow-wrap:anywhere}

.pos-cash-breakdown,.pos-cash-card-costs{grid-template-columns:minmax(0,1fr)}.pos-cash-breakdown .pos-cash-total,.pos-cash-card-costs .pos-cash-total{display:grid;grid-template-columns:minmax(0,1fr) max-content;align-items:start}.pos-cash-breakdown .pos-cash-total>strong,.pos-cash-card-costs .pos-cash-total>strong{white-space:nowrap;text-align:right}

/* Normal POS dialogs share the financial modal finish. Terminal, cart, customer
   selection and the printed receipt retain their own geometry. */
:root body.in-workspace dialog.pos-dialog{border:1px solid var(--line);border-radius:20px;color:var(--text-primary)}
:root body.in-workspace .pos-dialog .customer-dialog-header{margin:0;padding:0 0 var(--space-inline);gap:var(--space-fields);align-items:flex-start}
:root body.in-workspace .pos-dialog .customer-dialog-header h2{margin:0;font-size:var(--type-dialog-title);line-height:1.3}
:root body.in-workspace .pos-dialog .modal-close-control{width:var(--control-target);height:var(--control-target);min-width:var(--control-target);min-height:var(--control-target);margin:0;padding:var(--action-padding-block);border:1px solid var(--line);border-radius:var(--action-radius);box-shadow:none;flex:none}
:root body.in-workspace .pos-dialog .modal-action-footer{gap:var(--space-inline);padding-top:var(--space-fields);border-top:1px solid var(--line);flex-wrap:wrap}
:root body.in-workspace .pos-dialog .modal-action-footer>button{min-height:var(--control-target);margin:0;font-size:var(--type-action)}
:root body.in-workspace .pos-dialog :is(button,input,select,textarea):focus-visible{outline:2px solid var(--text-link);outline-offset:2px}
.pos-dialog .pos-modal-body{align-content:start}
.pos-dialog .pos-modal-body>.os-field{margin:0;min-width:0}
.pos-dialog .pos-modal-body>.os-note{margin:0;line-height:1.5;overflow-wrap:anywhere}
.pos-dialog :is(.pos-payment-total,.pos-cash-overview){padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
.pos-dialog .pos-payment-total>strong,.pos-dialog .pos-cash-summary>strong{font-size:var(--type-page-title);line-height:1.3;overflow-wrap:anywhere}
.pos-dialog .pos-cash-total{align-items:baseline}
.pos-dialog .pos-cash-total>span{min-width:0;color:var(--text-secondary)}
.pos-dialog .pos-cash-total>strong{min-width:0;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;text-align:right}
.pos-dialog .pos-order-summary{padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
:root body.in-workspace dialog.pos-sale-details,:root body.in-workspace dialog.pos-cash-report{width:720px}
.pos-sale-heading{align-items:center;padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
.pos-sale-heading>strong:first-child{font-size:var(--type-section-title)}
.pos-sale-heading>strong:last-child{margin-left:auto;font-size:var(--type-page-title);font-variant-numeric:tabular-nums;overflow-wrap:anywhere;min-width:0}
.pos-detail-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-fields);min-width:0;align-items:start}
.pos-detail-columns>.pos-detail-section:only-child{grid-column:1/-1}
.pos-detail-section{display:grid;gap:var(--space-inline);padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);min-width:0}
:root body.in-workspace .pos-detail-section>h3{margin:0 0 4px;padding-bottom:var(--space-inline);border-bottom:1px solid var(--line);font-size:var(--type-section-title)}
.pos-detail-section>.pos-receipt-line{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:var(--space-inline);font-size:var(--type-body);line-height:1.5;align-items:baseline}
.pos-detail-section>.pos-receipt-line>span{color:var(--text-secondary);overflow-wrap:anywhere}
.pos-detail-section>.pos-receipt-line>strong{color:var(--text-primary);font-variant-numeric:tabular-nums;text-align:right;overflow-wrap:anywhere;min-width:0}
.pos-detail-section>.pos-cash-total{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);line-height:1.5}
.pos-detail-note{white-space:pre-wrap}
@media(max-width:700px){.pos-detail-columns{grid-template-columns:minmax(0,1fr)}}
.pos-cash-dialog .pos-modal-body{gap:var(--space-inline)}
.pos-cash-dialog .pos-cash-overview{padding:var(--space-inline)}

.pos-cash-report .pos-detail-section:not(.pos-detail-people)>.pos-cash-total{grid-template-columns:minmax(0,1fr) auto}
@media(max-width:360px){.pos-detail-people>.pos-cash-total{grid-template-columns:minmax(0,1fr);gap:4px}.pos-detail-people>.pos-cash-total>strong{text-align:left}}

/* Keep the existing OS shortcut reachable beside receivable payments on small screens. */
@media(max-width:700px){.pos-tools>.pos-orders-shortcut>span:not(.pos-order-count){display:none}.pos-tools>.pos-orders-shortcut{min-width:var(--control-target)}}

/* Select an existing receivable without mixing account and payment metadata. */
:root body.in-workspace dialog.pos-receivables-dialog{width:min(560px,calc(100vw - 24px));box-sizing:border-box}
.pos-receivables-dialog .pos-modal-body{display:grid;gap:var(--space-fields);min-width:0}
.pos-receivables-dialog .pos-modal-body>.os-note{font-size:var(--type-meta);line-height:1.5;margin:0;overflow-wrap:anywhere}
:root body.in-workspace .pos-receivables-dialog .pos-history-filters{display:grid;grid-template-columns:minmax(0,1fr) var(--control-target);align-items:end;gap:var(--space-inline);min-width:0}
.pos-receivables-dialog .pos-history-filters input{width:100%;box-sizing:border-box}
.pos-receivables-dialog .pos-history-list{display:grid;gap:var(--space-inline);min-width:0}
:root body.in-workspace .pos-receivables-dialog button.pos-history-item{grid-template-columns:minmax(0,1fr) minmax(120px,auto) 16px;border:1px solid var(--line);border-radius:var(--action-radius);gap:var(--space-fields);padding:var(--space-fields);align-items:center;min-width:0}
.pos-receivables-dialog .pos-history-copy{gap:4px}
.pos-receivables-dialog .pos-history-copy>strong{font-size:var(--type-body);line-height:1.5}
.pos-receivable-meta,.pos-receivable-source,.pos-receivable-value small{font-size:var(--type-meta);font-weight:400;line-height:1.5;color:var(--text-secondary);overflow-wrap:anywhere}
.pos-receivable-source{justify-self:start;padding:2px var(--space-inline);border:1px solid var(--line);border-radius:6px;margin-top:4px}
.pos-receivable-value{display:grid;gap:2px;min-width:0;text-align:right;font-variant-numeric:tabular-nums}
.pos-receivable-value>strong{font-size:var(--type-section-title);line-height:1.5;overflow-wrap:anywhere}
.pos-receivable-arrow{display:grid;place-items:center;color:var(--text-secondary)}
.pos-receivable-arrow>.icon{width:16px;height:16px}
.pos-receivables-dialog .pos-history-list>.os-note{padding:var(--space-fields);margin:0;border:1px dashed var(--line);border-radius:var(--action-radius);color:var(--text-secondary);font-size:var(--type-body);line-height:1.5}
@media(max-width:430px){
 :root body.in-workspace .pos-receivables-dialog button.pos-history-item{grid-template-columns:minmax(0,1fr) 16px;gap:var(--space-inline)}
 .pos-receivables-dialog .pos-history-copy{grid-column:1/-1}
 .pos-receivable-value{text-align:left;border-top:1px solid var(--line);padding-top:var(--space-inline)}
}

/* POS header: stable identity and a compact operational toolbar. */
.pos-tool-short-label{display:none}
.pos-header>.pos-exit-action{flex:0 0 var(--control-target);width:var(--control-target);height:var(--control-target);padding:var(--space-inline);box-shadow:none;background:transparent;border:1px solid var(--line);color:var(--text-secondary)}
.pos-header>.pos-exit-action:hover{background:var(--surface-hover)}
.pos-header>.pos-exit-action:active{background:var(--surface-pressed)}
.pos-tools{min-width:0}
@media(max-width:1100px){
 :root body.in-workspace .pos-header{display:grid;grid-template-columns:var(--control-target) minmax(0,1fr) auto var(--control-target);gap:var(--space-inline);align-items:center}
 .pos-header>.pos-brand{grid-column:1;grid-row:1}
 .pos-header>.pos-identity{grid-column:2;grid-row:1}
 .pos-header>.pos-cash-status{grid-column:3;grid-row:1;margin:0;max-width:100%;overflow-wrap:anywhere}
 .pos-header>.pos-exit-action{grid-column:4;grid-row:1}
 .pos-header>.pos-tools{grid-column:1/-1;grid-row:2;width:100%;flex-wrap:nowrap;justify-content:flex-end}
 .pos-tools>button:first-child{margin-right:0}
}
@media(max-width:700px){
 :root body.in-workspace .pos-header{grid-template-columns:minmax(0,1fr) var(--control-target);padding: max(var(--space-inline),env(safe-area-inset-top)) max(var(--space-inline),env(safe-area-inset-right)) var(--space-inline) max(var(--space-inline),env(safe-area-inset-left))}
 .pos-header>.pos-identity{grid-column:1;grid-row:1}
 .pos-header>.pos-exit-action{grid-column:2;grid-row:1;align-self:start}
 .pos-header>.pos-cash-status{grid-column:1/-1;grid-row:2;justify-self:start;padding:4px var(--space-inline);font-size:var(--type-meta);line-height:1.4}
 .pos-header>.pos-tools{grid-row:3;display:flex;gap:var(--space-inline);border-top:1px solid var(--line);padding-top:var(--space-inline);align-items:stretch}
 :root body.in-workspace dialog.pos-terminal .pos-tools>button{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;flex:1 1 0;min-width:var(--control-target);width:0;min-height:52px;height:auto;padding:var(--space-inline) 4px!important;gap:4px!important;margin:0;box-shadow:none}
 .pos-tools>button>span:not(.pos-tool-short-label):not(.pos-order-count){display:none}
 :root body.in-workspace .pos-tools>button>.pos-tool-short-label{display:block;white-space:normal;overflow-wrap:anywhere;font-size:var(--type-meta);line-height:1.3;font-weight:500}
 .pos-tools>.pos-icon>.icon,.pos-tools>button>.icon{width:18px;height:18px;flex:none}
 .pos-tools .pos-order-count{position:absolute;top:-5px;right:0;min-width:16px;height:16px;padding:0 4px;font-size:var(--type-eyebrow);background:var(--surface-field);color:var(--text-primary);border-color:var(--line)}
}

.pos-header>.pos-cash-status{display:inline-flex;align-items:center;gap:var(--space-inline);line-height:1.4}
.pos-header>.pos-cash-status::before{content:'';width:6px;height:6px;border-radius:50%;background:var(--text-secondary);flex:none}
.pos-header>.pos-cash-status[data-open=true]::before{background:var(--text-success)}
:root[data-theme=dark] .pos-tools .pos-tool-action{--pos-tool-bg:var(--surface-field);--pos-tool-text:var(--text-secondary);--pos-tool-border:var(--line)}

.pos-header>.pos-identity>strong{overflow-wrap:anywhere;line-height:1.4}

@media(min-width:480px) and (max-width:700px){
 :root body.in-workspace .pos-header{grid-template-columns:minmax(0,1fr) auto var(--control-target)}
 .pos-header>.pos-cash-status{grid-column:2;grid-row:1;justify-self:end}
 .pos-header>.pos-exit-action{grid-column:3;grid-row:1}
 .pos-header>.pos-tools{grid-row:2}
}

/* Compact catalog cards retain full names and one large touch target. */
.pos-terminal .pos-products{gap:var(--space-inline);grid-auto-rows:max-content}
:root body.in-workspace .pos-terminal button.pos-product{display:grid;grid-template-rows:auto 1fr auto;gap:var(--space-inline);min-height:0;padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);color:var(--text-primary);box-shadow:none;align-content:start;text-align:start}
:root body.in-workspace .pos-terminal button.pos-product:not(:disabled):hover{background:var(--surface-hover);border-color:var(--text-link)}
:root body.in-workspace .pos-terminal button.pos-product:not(:disabled):active{background:var(--surface-pressed);transform:none}
.pos-terminal .pos-product-media{height:88px;border-radius:8px;color:var(--text-secondary)}
.pos-terminal .pos-product-media>.icon{width:24px;height:24px}
.pos-product-copy{display:grid;align-content:start;gap:4px;min-width:0}
.pos-terminal .pos-product-copy>strong{font-size:var(--type-label);line-height:1.4;font-weight:600;overflow-wrap:anywhere}
.pos-terminal .pos-product-copy>small{font-size:var(--type-meta);line-height:1.4;color:var(--text-secondary);overflow-wrap:anywhere}
.pos-product-bottom{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:4px var(--space-inline);min-width:0;padding-top:var(--space-inline);border-top:1px solid var(--line)}
.pos-product-bottom .pos-price{font-size:var(--type-body);line-height:1.4;font-weight:650;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.pos-product-stock{display:inline-flex;align-items:center;gap:4px;max-width:100%;padding:2px 4px;border:1px solid var(--line);border-radius:6px;font-size:var(--type-meta);line-height:1.4;color:var(--text-secondary);overflow-wrap:anywhere}
.pos-product-stock>.icon{width:12px;height:12px;flex:none}
.pos-product-add{position:absolute;right:4px;top:4px;display:grid;place-items:center;width:22px;height:22px;border:1px solid var(--line);border-radius:7px;background:var(--surface-field);color:var(--text-secondary);pointer-events:none}
.pos-product-add>.icon{width:14px;height:14px}
:root body.in-workspace .pos-terminal button.pos-product:disabled{opacity:1;cursor:default}
.pos-product:disabled .pos-product-add{display:none}
.pos-product.is-unavailable .pos-product-media{opacity:.55}
.pos-product.is-unavailable .pos-product-copy>strong,.pos-product.is-unavailable .pos-price{color:var(--text-secondary)}
.pos-product.is-unavailable .pos-product-stock{color:var(--text-warning);border-color:var(--border-warning,var(--line))}
.pos-terminal button.pos-product:focus-visible{outline:2px solid var(--text-link);outline-offset:-3px}
@media(max-width:700px){
 :root body.in-workspace .pos-terminal button.pos-product{padding:var(--space-inline)}
 .pos-terminal .pos-product-media{height:72px}
}
@media(max-width:430px){
 .pos-terminal .pos-products{grid-template-columns:repeat(2,minmax(0,1fr))}
 .pos-terminal .pos-product-media{height:64px}
}

/* Ticket and mobile cart share compact, readable item cards. */
.pos-ticket{gap:var(--space-inline)}
.pos-ticket .pos-customer>button{box-shadow:none;border:1px solid var(--line);background:var(--surface-field)}
.pos-ticket .pos-customer>button:hover{background:var(--surface-hover)}
.pos-ticket .pos-customer>button:active{background:var(--surface-pressed)}
.pos-ticket .pos-line{display:grid;grid-template-columns:minmax(0,1fr);gap:var(--space-inline);padding:var(--space-inline);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);min-width:0}
.pos-ticket .pos-line-info{gap:4px}
.pos-ticket .pos-line-info>strong{font-size:var(--type-label);font-weight:600;line-height:1.4}
.pos-ticket .pos-line-info>small{font-size:var(--type-meta);line-height:1.4}
.pos-line-footer{display:flex;flex-wrap:wrap;align-items:center;gap:var(--space-inline);min-width:0}
.pos-ticket .pos-line-actions{flex:1 0 auto;min-width:0}
.pos-ticket .pos-line-total{margin-left:auto;max-width:100%;font-size:var(--type-body);line-height:1.4;white-space:normal;overflow-wrap:anywhere;text-align:right}
.pos-ticket .pos-adjust{padding-top:var(--space-inline);border-top:1px solid var(--line)}
.pos-ticket .pos-adjust>.os-field{margin:0;min-width:0}
.pos-ticket .pos-totals{padding-top:var(--space-inline)}
.pos-totals .pos-grand-total>strong{font-size:var(--type-dialog-title);line-height:1.4}
.pos-cart-panel .pos-cart-header{padding:var(--space-fields);padding-top:max(var(--space-fields),env(safe-area-inset-top));background:var(--surface-field)}
.pos-cart-panel .pos-cart-header>button{box-shadow:none}
.pos-cart-body>.pos-ticket{flex:0 0 auto;padding:0;border:0;border-radius:0;background:transparent;gap:var(--space-inline)}
.pos-cart-body>.pos-ticket>.pos-lines{flex:0 0 auto;padding:0;gap:var(--space-inline)}
.pos-cart-panel .pos-ticket-head h2{font-size:var(--type-section-title)}
:root body.in-workspace .pos-cart-panel>.pos-footer{display:grid;grid-template-columns:var(--control-target) var(--control-target) minmax(0,1fr);gap:var(--space-inline);align-items:stretch}
.pos-cart-panel>.pos-footer>.pos-totals{grid-column:1/-1;grid-row:1;gap:4px;margin:0;padding:0 0 var(--space-inline);border-top:0;border-bottom:1px solid var(--line);min-width:0}
.pos-cart-panel>.pos-footer>.pos-clear-action{grid-column:1;grid-row:2}
.pos-cart-panel>.pos-footer>.pos-park-action{grid-column:2;grid-row:2}
.pos-cart-panel>.pos-footer>.pos-pay-action{grid-column:3;grid-row:2}
:root body.in-workspace .pos-cart-panel>.pos-footer>:is(.pos-clear-action,.pos-park-action){width:var(--control-target);min-width:var(--control-target);padding:var(--space-inline)}
.pos-cart-panel>.pos-footer>:is(.pos-clear-action,.pos-park-action)>span{display:none}
.pos-cart-panel>.pos-footer>.pos-pay-action{min-width:0;margin:0}
.pos-cart-panel .pos-totals>div{gap:var(--space-inline);font-variant-numeric:tabular-nums}

@media(max-height:500px) and (min-width:701px){
 .pos-terminal>.pos-content>.pos-ticket>.pos-lines{flex:0 0 auto;max-height:none;overflow:visible}
 .pos-terminal>.pos-content>.pos-ticket>*{flex-shrink:0}
}

/* Shared desktop/mobile hierarchy: neutral tools, soft receivable emphasis. */
:root body.in-workspace dialog.pos-terminal .pos-tools>button:is(.pos-tool-action,.pos-orders-shortcut,.pos-pending-action){background:transparent;color:var(--text-secondary);border:1px solid var(--line);box-shadow:none;filter:none;backdrop-filter:none}
:root body.in-workspace dialog.pos-terminal .pos-tools>button:is(.pos-tool-action,.pos-orders-shortcut,.pos-pending-action):not(:disabled):hover{background:var(--surface-hover);color:var(--text-primary);border-color:var(--line);box-shadow:none}
:root body.in-workspace dialog.pos-terminal .pos-tools>button:is(.pos-tool-action,.pos-orders-shortcut,.pos-pending-action):not(:disabled):active{background:var(--surface-pressed);color:var(--text-primary);border-color:var(--line);box-shadow:none}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-pending-action{background:var(--accent-soft);color:var(--text-link);border-color:var(--accent-ring);font-weight:600}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-pending-action:not(:disabled):hover{background:var(--surface-hover);color:var(--text-link);border-color:var(--text-link);box-shadow:none}
:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-pending-action:not(:disabled):active{background:var(--surface-pressed);color:var(--text-link);border-color:var(--text-link);box-shadow:none}
@media(min-width:701px){
 .pos-header>.pos-tools{gap:4px;width:auto;padding:4px;border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
 :root body.in-workspace dialog.pos-terminal .pos-tools>button{min-height:var(--control-target);margin:0}
 :root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-tool-action,:root body.in-workspace dialog.pos-terminal .pos-tools>button.pos-orders-shortcut{border-color:transparent}
 .pos-tools>.pos-cash-action{order:0}.pos-tools>.pos-sales-action{order:1}.pos-tools>.pos-orders-shortcut{order:2}.pos-tools>.pos-calculator-action{order:3}.pos-tools>.pos-pending-action{order:4;margin-left:var(--space-inline)}
 .pos-header>.pos-exit-action{position:relative;margin-left:var(--space-inline)}
 .pos-header>.pos-exit-action::before{content:'';position:absolute;left:calc(-1 * var(--space-inline));top:10px;bottom:10px;width:1px;background:var(--line);pointer-events:none}
}
@media(min-width:1101px){.pos-header>.pos-identity{flex:0 1 auto}.pos-header>.pos-cash-status{margin-right:auto}}

/* Toolbar focus uses the current palette instead of legacy per-action colors. */
:root body.in-workspace dialog.pos-terminal .pos-tools>button:is(.pos-tool-action,.pos-orders-shortcut,.pos-pending-action):focus-visible{outline:2px solid var(--text-link);outline-offset:-3px}

/* The initial context target is not an interactive control. */
:root body.in-workspace dialog.pos-terminal .pos-header>.pos-identity:focus{outline:none;box-shadow:none}

/* Closing report: fixed navigation and a single reading surface. */
:root body.in-workspace dialog.pos-cash-report{width:min(720px,calc(100vw - 24px))}
.pos-cash-report .pos-report-heading{display:grid;gap:var(--space-inline);min-width:0}
.pos-cash-report .pos-report-context{margin:0;font-size:var(--type-meta);color:var(--text-secondary)}
.pos-cash-report .customer-dialog-header{margin-bottom:var(--space-fields)}
:root body.in-workspace .pos-cash-report .pos-report-tabs{flex-shrink:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));margin-bottom:var(--space-fields)}
:root body.in-workspace .pos-cash-report .pos-report-tabs>button{min-width:0;min-height:var(--control-target);padding:var(--space-inline);font-size:var(--type-action);white-space:normal;overflow-wrap:anywhere}
.pos-cash-report .pos-report-panel{display:grid;gap:var(--space-section);min-width:0;padding:var(--space-fields);background:var(--surface-field);border:1px solid var(--line);border-radius:var(--action-radius)}
.pos-cash-report .pos-detail-section{background:transparent;border:0;border-radius:0;padding:0;gap:var(--space-inline)}
:root body.in-workspace .pos-cash-report .pos-detail-section>h3{font-size:var(--type-label);padding-bottom:var(--space-inline);margin:0}
.pos-cash-report .pos-report-overview>h3{display:none}
.pos-report-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--space-fields);margin:0;min-width:0;padding-bottom:var(--space-section);border-bottom:1px solid var(--line)}
.pos-report-metric{display:flex;flex-direction:column;justify-content:space-between;gap:var(--space-inline);min-width:0}
.pos-report-metric dt{font-size:var(--type-meta);color:var(--text-secondary);line-height:1.4}
.pos-report-metric dd{margin:0;font-size:var(--type-section-title);line-height:1.4;font-weight:650;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.pos-report-metric[data-difference=true] dd{color:var(--text-warning)}
.pos-cash-report .pos-detail-columns{align-items:start;gap:var(--space-section)}
.pos-cash-report :is(.pos-cash-breakdown,.pos-cash-card-costs){padding:0;margin:0;border:0;gap:var(--space-inline);grid-template-columns:minmax(0,1fr)}
.pos-cash-report .pos-cash-total{font-size:var(--type-meta);line-height:1.5;gap:var(--space-inline)}
.pos-cash-report .pos-cash-total>strong{white-space:normal;overflow-wrap:anywhere}
.pos-cash-report .pos-detail-section:not(.pos-detail-people)>.pos-cash-total{grid-template-columns:minmax(0,1fr) minmax(0,auto)}
.pos-cash-report .pos-cash-card-costs>.os-note{padding-top:var(--space-inline);border-top:1px solid var(--line)}
.pos-report-people{min-width:0;border-top:1px solid var(--line);padding-top:var(--space-inline)}
.pos-report-people>summary{min-height:var(--control-target);display:list-item;align-content:center;font-size:var(--type-label);font-weight:600;cursor:pointer}
.pos-report-people>summary:focus-visible{outline:2px solid var(--text-link);outline-offset:-2px}
.pos-report-people-body{display:grid;gap:var(--space-inline);min-width:0}
.pos-report-people-body>.pos-cash-total{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
.pos-cash-report .pos-detail-note{margin:0;font-size:var(--type-meta);line-height:1.5}
.pos-report-secondary{display:grid;gap:var(--space-fields);min-width:0}
.pos-report-secondary:only-child{grid-column:1/-1}
.pos-cash-report .pos-cash-ledger{padding:0;border:0;background:transparent}
.pos-cash-report .pos-cash-ledger>summary{display:list-item;align-content:center;color:var(--text-primary);font-size:var(--type-label);font-weight:600}
.pos-cash-report .pos-cash-ledger>div{max-height:none}
.pos-cash-report .pos-cash-ledger>summary:focus-visible{outline:2px solid var(--text-link);outline-offset:-2px}
@media(max-width:700px){.pos-report-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:360px){.pos-report-people-body>.pos-cash-total{grid-template-columns:minmax(0,1fr);gap:4px}.pos-report-people-body>.pos-cash-total>strong{text-align:left}}

@media(max-width:700px){:root body.in-workspace .pos-cash-report .pos-report-tabs{grid-template-columns:.9fr 1.4fr .9fr}:root body.in-workspace .pos-cash-report .pos-report-tabs>button{padding-inline:4px;overflow-wrap:normal}}

/* Cash control follows the report: focused operation, separate consultation tabs. */
:root body.in-workspace dialog.pos-cash-dialog{width:min(620px,calc(100vw - 24px))}
.pos-cash-dialog .customer-dialog-header{margin-bottom:var(--space-fields)}
:root body.in-workspace .pos-cash-dialog .pos-cash-tabs{display:grid;grid-template-columns:1fr .9fr 1.4fr;flex-shrink:0;margin-bottom:var(--space-fields)}
:root body.in-workspace .pos-cash-dialog .pos-cash-tabs>button{min-width:0;min-height:var(--control-target);padding:var(--space-inline);font-size:var(--type-action);white-space:normal;overflow-wrap:normal}
.pos-cash-dialog .pos-modal-body{gap:var(--space-fields)}
.pos-cash-dialog .pos-cash-pane{display:grid;gap:var(--space-fields);min-width:0;padding:var(--space-fields);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field)}
:root body.in-workspace .pos-cash-dialog .pos-cash-overview{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;padding:var(--space-fields);gap:var(--space-inline);background:transparent;border:0;border-radius:0}
.pos-cash-tools{display:flex;align-items:center;gap:var(--space-inline);min-width:0}
.pos-cash-tools>button{flex:0 0 var(--control-target);width:var(--control-target);height:var(--control-target);padding:var(--space-inline);box-shadow:none}
.pos-cash-dialog .pos-cash-tools .icon{width:18px;height:18px}
:root body.in-workspace .pos-cash-dialog .pos-cash-summary>strong{font-size:var(--type-section-title)}
.pos-cash-dialog .pos-cash-pane>.os-note{margin:0;font-size:var(--type-meta);line-height:1.5}
.pos-cash-dialog .pos-detail-section{padding:0;border:0;border-radius:0;background:transparent}
:root body.in-workspace .pos-cash-dialog .pos-detail-section>h3{font-size:var(--type-label);margin:0}
.pos-cash-dialog :is(.pos-cash-breakdown,.pos-cash-card-costs){padding:0;margin:0;border:0}
.pos-cash-dialog .pos-cash-analysis>.pos-detail-section{border-top:1px solid var(--line);padding-top:var(--space-fields)}
.pos-cash-dialog .pos-cash-total{font-size:var(--type-meta);line-height:1.5}
.pos-cash-dialog .pos-cash-analysis .pos-detail-section>.pos-cash-total{grid-template-columns:minmax(0,1fr) minmax(0,auto)}
.pos-cash-dialog .pos-cash-ledger{border:0;padding:0;margin:0}
.pos-cash-dialog .pos-cash-ledger>div{max-height:none}
.pos-cash-dialog .pos-cash-ledger>summary{font-size:var(--type-label);color:var(--text-primary)}
@media(max-width:360px){:root body.in-workspace .pos-cash-dialog .pos-cash-tabs>button{padding-inline:4px}.pos-cash-tools{gap:4px}}

/* Session-scoped POS window; child operations remain native modal dialogs. */
:root body.in-workspace dialog.pos-terminal.pos-window{inset:84px 16px 16px auto;width:min(1400px,calc(100vw - 32px));height:calc(100dvh - 100px);max-height:none;border:1px solid var(--line);border-radius:var(--space-section);z-index:1100;box-shadow:0 16px 48px #0003}
:root body.in-workspace dialog.pos-terminal.pos-window.is-maximized{inset:0;width:100%;height:100dvh;border-radius:0}
:root body.in-workspace dialog.pos-terminal[hidden],:root .pos-window-dock[hidden]{display:none!important}
.pos-window-controls{display:flex;align-items:center;gap:var(--space-inline);flex:none}
:root body.in-workspace .pos-window-controls>button{width:var(--control-target);height:var(--control-target);min-width:var(--control-target);padding:var(--action-padding-block);margin:0;box-shadow:none}
:root body.in-workspace .pos-window-dock{position:fixed;left:var(--space-section);bottom:calc(var(--mobile-nav-height,0px) + env(safe-area-inset-bottom) + var(--space-inline));z-index:1100;display:flex;align-items:center;gap:var(--space-inline);width:auto;max-width:calc(100vw - 100px);min-height:var(--control-target);padding:var(--action-padding-block) var(--action-padding-inline);margin:0;border:1px solid var(--accent-ring);border-radius:var(--action-radius);background:var(--surface-field);color:var(--text-primary);box-shadow:0 8px 24px #0002;font-size:var(--type-action)}
.pos-window-dock>span:not(.pos-dock-copy){display:none}.pos-dock-copy{display:grid;gap:4px;text-align:left;min-width:0}.pos-dock-copy>span{font-size:var(--type-meta);color:var(--text-secondary)}.pos-dock-copy>strong{font-size:var(--type-label);font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.pos-window-dock>.icon{width:20px;height:20px;flex:none}.pos-window-dock:hover{background:var(--surface-hover)}.pos-window-dock:active{background:var(--surface-pressed)}.pos-window-dock:focus-visible{outline:2px solid var(--text-link);outline-offset:2px}
@media(max-width:1100px){.pos-window .pos-header{flex-wrap:wrap}.pos-window .pos-window-controls{margin-left:auto}.pos-window .pos-header>.pos-tools{order:5;width:100%;justify-content:flex-start;overflow:auto}.pos-window .pos-header>.pos-exit-action{margin-left:0}.pos-window .pos-header>.pos-exit-action::before{display:none}}
@media(max-width:700px){:root body.in-workspace dialog.pos-terminal.pos-window{inset:0;width:100%;height:100dvh;border:0;border-radius:0}.pos-window-controls>button:last-child{display:none}.pos-window .pos-identity{flex:1 1 calc(100% - 112px)}.pos-window .pos-cash-status{order:4;margin:0}.pos-window .pos-header>.pos-tools{order:5}.pos-window .pos-header>.pos-exit-action{order:3}.pos-window .pos-window-controls{order:2}.pos-window .pos-cash-status{width:100%;box-sizing:border-box}.pos-window .pos-header>.pos-tools{padding:0;border:0}.pos-window .pos-tools>button{flex-shrink:0}}
@media(prefers-reduced-motion:reduce){.pos-window,.pos-window-dock{animation:none!important;transition:none!important}}

@media(min-width:701px) and (max-width:1100px){:root body.in-workspace .pos-window .pos-header{grid-template-columns:var(--control-target) minmax(0,1fr) auto auto var(--control-target)}.pos-window .pos-header>.pos-window-controls{grid-column:4;grid-row:1}.pos-window .pos-header>.pos-exit-action{grid-column:5;grid-row:1}}
@media(max-width:700px){:root body.in-workspace .pos-window .pos-header{grid-template-columns:minmax(0,1fr) var(--control-target) var(--control-target)}.pos-window .pos-header>.pos-identity{grid-column:1;grid-row:1}.pos-window .pos-header>.pos-window-controls{grid-column:2;grid-row:1;margin:0;align-self:start}.pos-window .pos-header>.pos-exit-action{grid-column:3;grid-row:1}.pos-window .pos-header>.pos-cash-status{grid-column:1/-1;grid-row:2;width:auto;justify-self:start}.pos-window .pos-header>.pos-tools{grid-column:1/-1;grid-row:3}}

/* The same four window actions as chat; floating layout follows its own width. */
:root body.in-workspace dialog.pos-terminal.pos-window{container:pos-window / inline-size}
:root body.in-workspace .pos-window-controls{gap:0;margin-left:var(--space-inline)}
:root body.in-workspace .pos-window-controls>button{display:flex;align-items:center;justify-content:center;border:0;background:transparent;color:var(--text-secondary);border-radius:var(--action-radius);box-shadow:none}
:root body.in-workspace .pos-window-controls>button:hover{background:var(--surface-hover);color:var(--text-primary)}
:root body.in-workspace .pos-window-controls>button:active{background:var(--surface-pressed)}
:root body.in-workspace .pos-window-controls>button>.icon{width:18px;height:18px}
.pos-window-resize{touch-action:none;cursor:nwse-resize}.pos-window .pos-identity,.pos-window .pos-brand{touch-action:none;cursor:move}.pos-window.is-maximized .pos-identity,.pos-window.is-maximized .pos-brand{cursor:grab}.pos-window.is-window-adjusting{user-select:none}
.pos-window-settings{position:absolute;z-index:6;top:calc(var(--pos-header-height,80px) + var(--space-inline));right:var(--space-inline);max-width:calc(100% - 16px);padding:var(--space-inline);border:1px solid var(--line);border-radius:var(--action-radius);background:var(--surface-field);box-shadow:0 8px 24px #0002}
:root body.in-workspace .pos-window-settings>button{width:auto;min-height:var(--control-target);padding:var(--action-padding-block) var(--action-padding-inline);font-size:var(--type-action);margin:0;box-shadow:none}
.pos-window-edge{position:absolute;z-index:5;touch-action:none}.pos-window-edge-n,.pos-window-edge-s{left:12px;right:12px;height:7px;cursor:ns-resize}.pos-window-edge-n{top:0}.pos-window-edge-s{bottom:0}.pos-window-edge-e,.pos-window-edge-w{top:12px;bottom:12px;width:7px;cursor:ew-resize}.pos-window-edge-e{right:0}.pos-window-edge-w{left:0}.pos-window-edge-ne,.pos-window-edge-nw,.pos-window-edge-se,.pos-window-edge-sw{width:12px;height:12px}.pos-window-edge-ne{right:0;top:0;cursor:nesw-resize}.pos-window-edge-nw{left:0;top:0;cursor:nwse-resize}.pos-window-edge-se{right:0;bottom:0;cursor:nwse-resize}.pos-window-edge-sw{left:0;bottom:0;cursor:nesw-resize}.pos-window.is-maximized>.pos-window-edge{display:none}
@container pos-window (max-width:1200px){
 :root body.in-workspace .pos-window>.pos-header{display:grid;grid-template-columns:var(--control-target) minmax(0,1fr) auto auto;gap:var(--space-inline)}
 .pos-window>.pos-header>.pos-brand{display:grid;grid-column:1;grid-row:1}.pos-window>.pos-header>.pos-identity{grid-column:2;grid-row:1}.pos-window>.pos-header>.pos-cash-status{grid-column:3;grid-row:1;margin:0;width:auto}.pos-window>.pos-header>.pos-window-controls{grid-column:4;grid-row:1;margin:0}.pos-window>.pos-header>.pos-tools{grid-column:1/-1;grid-row:2;width:100%;justify-content:flex-start;overflow:auto}
}
@container pos-window (max-width:700px){
 :root body.in-workspace .pos-window>.pos-header{grid-template-columns:minmax(0,1fr) auto}.pos-window>.pos-header>.pos-brand{display:none}.pos-window>.pos-header>.pos-identity{grid-column:1;grid-row:1}.pos-window>.pos-header>.pos-window-controls{grid-column:2;grid-row:1}.pos-window>.pos-header>.pos-cash-status{grid-column:1/-1;grid-row:2;justify-self:start}.pos-window>.pos-header>.pos-tools{grid-column:1/-1;grid-row:3}
}
@media(max-width:700px){:root body.in-workspace .pos-window-controls>:is(.pos-window-resize,.pos-window-maximize){display:none}:root body.in-workspace .pos-window .pos-identity{cursor:default}.pos-window>.pos-window-edge{display:none}}

.pos-window-dock{touch-action:none;user-select:none;--pos-safe-top:env(safe-area-inset-top,0px);--pos-safe-right:env(safe-area-inset-right,0px);--pos-safe-bottom:env(safe-area-inset-bottom,0px);--pos-safe-left:env(safe-area-inset-left,0px)}.pos-window-dock.is-dragging{cursor:grabbing;transition:none!important}.pos-window-dock:not(.is-dragging){cursor:grab}

:root body.in-workspace .pos-window-dock{transform:none}

:root body.in-workspace .pos-window-dock{z-index:90}

/* Consulta de venda: identificação, composição e atalhos agrupados. */
:root body.in-workspace dialog.pos-sale-details{width:min(680px,calc(100vw - 24px))}
.pos-sale-details .os-body{gap:var(--space-fields)}.pos-sale-details .pos-sale-heading{box-shadow:none;padding:var(--space-fields)}
.pos-sale-details .pos-sale-heading>strong:last-child{font-size:var(--type-section-title)}
.pos-sale-context{display:flex;flex-wrap:wrap;justify-content:space-between;gap:var(--space-inline);color:var(--text-secondary);font-size:var(--type-meta)}.pos-sale-context>span{display:flex;align-items:center;gap:var(--space-inline);min-width:0;overflow-wrap:anywhere}.pos-sale-context .icon{width:16px;height:16px;flex:none}
.pos-sale-details .pos-detail-section{background:var(--surface-field)}
.pos-sale-note{border-left:2px solid var(--line);padding-left:var(--space-fields);font-size:var(--type-meta);color:var(--text-secondary)}.pos-sale-note p{margin:4px 0 0;overflow-wrap:anywhere}
.pos-sale-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-inline);padding-top:var(--space-fields);border-top:1px solid var(--line)}.pos-sale-actions>button{justify-content:flex-start;text-align:left;white-space:normal;min-width:0;box-shadow:none}.pos-sale-actions .icon{flex:none}
@media(max-width:480px){.pos-sale-details .pos-detail-columns{grid-template-columns:1fr}.pos-sale-details .pos-sale-heading>strong:last-child{flex-basis:100%;margin:0}.pos-sale-details .modal-action-footer>button{flex:1}}
