/* SilverByte appearance engine. Layout and palette are independent account preferences. */
html[data-pos-appearance] { color-scheme: light; background:var(--bg-page); }
html[data-pos-appearance][data-theme="dark"] { color-scheme:dark; }
html[data-pos-appearance] body { margin:0; background:var(--bg-page)!important; color:var(--text-primary)!important; }
.pos-root.pos-shell { height:100dvh; width:100%; display:flex; flex-direction:column; overflow:hidden; background:var(--bg-page)!important; color:var(--text-primary); padding:12px; gap:0; font-size:14px; }
.pos-shell * { box-sizing:border-box; }
.pos-shell button,.pos-shell input,.pos-shell select { font:inherit; }
.pos-shell button { cursor:pointer; }
.pos-shell button:disabled { cursor:not-allowed; opacity:.48; }
.pos-shell button:focus-visible,.pos-shell input:focus-visible,.pos-shell select:focus-visible { outline:3px solid var(--brand-500); outline-offset:3px; }
.pos-header-legacy-controls { display:flex!important; gap:12px; height:auto!important; padding:0 0 0 10px!important; border:0!important; background:transparent!important; }
.pos-header-legacy-controls>div:first-child { max-width:115px; }
.pos-workspace { min-height:0; flex:1; display:grid; grid-template-columns:minmax(0,1fr) 360px; grid-template-rows:minmax(0,1fr); grid-template-areas:"menu cart"; border:1px solid var(--border-faint); border-top:0; border-radius:0 0 18px 18px; overflow:hidden; background:var(--bg-surface); }
.pos-menu-region { grid-area:menu; display:flex; flex-direction:column; min-width:0; min-height:0; overflow:hidden; background:var(--bg-page); }
.pos-selling-menu { display:flex; flex:1; min-height:0; min-width:0; }
.pos-root.pos-shell .pos-menu-pane { width:100%; min-width:0; min-height:0; display:flex; flex-direction:column; background:var(--bg-page)!important; }
.pos-menu-toolbar { display:flex; align-items:center; gap:9px; padding:14px 16px 8px; flex-shrink:0; }
.pos-menu-toolbar h2 { font-size:17px; font-weight:800; }
.pos-menu-display { display:flex; padding:3px; background:var(--bg-field); border:1px solid var(--border-faint); border-radius:9px; }
.pos-menu-display button { width:31px; height:33px; border:0; border-radius:6px; background:transparent; color:var(--text-muted); font-size:18px; }
.pos-menu-display button[aria-pressed="true"] { background:var(--bg-surface); color:var(--brand-600); box-shadow:0 1px 3px var(--shadow-card); }
.pos-density-picker select { max-width:100px; border:1px solid var(--border-faint); border-radius:9px; padding:10px 22px 10px 9px; background-color:var(--bg-surface); color:var(--text-muted); font-size:12px; }
.pos-menu-categories { display:flex; gap:7px; padding:8px 16px 12px; flex-shrink:0; overflow-x:auto; scrollbar-width:thin; }
.pos-menu-categories button { min-height:39px; border:1px solid var(--border-faint); color:var(--text-muted); background:var(--bg-surface); border-radius:10px; padding:9px 15px; white-space:nowrap; font-size:12px; font-weight:650; }
.pos-menu-categories [aria-pressed="true"] { color:var(--brand-ink); background:var(--brand-500); border-color:var(--brand-500); }
.pos-menu-scroll { flex:1; min-height:0; overflow:auto; padding:4px 16px 16px; scrollbar-width:thin; }
.pos-catalogue-grid { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:12px; align-content:start; }
.pos-product-group,.pos-group-products { display:contents; }
.pos-category-heading { display:none; }
.pos-menu-card { position:relative; min-width:0; border:1px solid var(--border-faint); border-radius:12px; overflow:hidden; background:var(--bg-surface); box-shadow:0 2px 5px var(--shadow-card); }
.pos-product-select { display:flex; flex-direction:column; width:100%; height:100%; padding:0; border:0; text-align:left; background:transparent; color:var(--text-primary); position:relative; }
.pos-product-select:hover { background:var(--brand-tint-bg); }
.pos-product-photo { display:block; width:100%; aspect-ratio:1.4; overflow:hidden; background:var(--bg-field); }
.pos-product-photo img { display:block; width:100%; height:100%; object-fit:cover; }
.pos-product-initial { display:grid; place-items:center; width:100%; height:100%; min-height:90px; font-size:40px; font-weight:800; color:var(--brand-500); background:var(--brand-tint-bg); }
.pos-product-copy { display:flex; flex-direction:column; gap:4px; padding:10px 39px 11px 11px; min-width:0; width:100%; }
.pos-product-copy strong { font-size:12px; font-weight:750; line-height:1.4; }
.pos-product-price { color:var(--brand-600); font-size:13px; font-weight:800; }
.pos-product-description { display:none; }
.pos-product-add { position:absolute; right:9px; bottom:12px; display:grid; place-items:center; height:28px; width:28px; border-radius:50%; background:var(--brand-500); color:var(--brand-ink); font-size:23px; line-height:1; }
.pos-product-count { position:absolute; top:7px; left:7px; border:2px solid var(--bg-surface); min-width:24px; height:24px; border-radius:12px; background:var(--brand-500); color:var(--brand-ink); text-align:center; font-size:11px; font-weight:800; line-height:20px; }
.pos-product-favourite { position:absolute; right:7px; top:7px; width:25px; height:25px; display:grid; place-items:center; border:0; border-radius:50%; background:var(--bg-surface); color:var(--text-muted); font-size:18px; opacity:.85; }
.pos-product-favourite[aria-pressed="true"] { color:var(--brand-600); background:var(--brand-tint-bg); }
.pos-sold-out .pos-product-select { opacity:.5; }
.pos-search-help { display:flex; gap:10px; padding:6px 16px; font-size:12px; color:var(--text-muted); }
.pos-search-help button { margin-left:auto; color:var(--brand-600); }
.pos-empty-catalogue { grid-column:1/-1; padding:40px 12px; color:var(--text-muted); }
.pos-shell[data-density="small"] .pos-catalogue-grid { grid-template-columns:repeat(6,minmax(0,1fr)); gap:9px; }
.pos-shell[data-density="large"] .pos-catalogue-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:15px; }
.pos-shell[data-menu-mode="list"] .pos-catalogue-grid { display:flex; flex-direction:column; gap:7px; }
.pos-shell[data-menu-mode="list"] .pos-product-select { flex-direction:row; align-items:center; min-height:68px; }
.pos-shell[data-menu-mode="list"] .pos-product-photo { width:62px; height:55px; aspect-ratio:auto; border-radius:8px; margin:8px; flex-shrink:0; }
.pos-shell[data-menu-mode="list"] .pos-product-initial { min-height:0; font-size:24px; }
.pos-shell[data-menu-mode="list"] .pos-product-copy { padding:10px 80px 10px 8px; display:grid; grid-template-columns:minmax(0,1fr) auto; gap:4px 15px; }
.pos-shell[data-menu-mode="list"] .pos-product-copy strong { grid-column:1; font-size:13px; }
.pos-shell[data-menu-mode="list"] .pos-product-price { grid-column:2; grid-row:1/3; align-self:center; }
.pos-shell[data-menu-mode="list"] .pos-product-description { display:block; grid-column:1; font-size:11px; color:var(--text-faint); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.pos-shell[data-menu-mode="list"] .pos-product-add { bottom:calc(50% - 14px); right:12px; }
.pos-shell[data-menu-mode="list"] .pos-product-favourite { right:47px; top:calc(50% - 12px); }
.pos-shell[data-menu-mode="tile"] .pos-catalogue-grid { grid-template-columns:repeat(4,minmax(0,1fr)); }
.pos-shell[data-menu-mode="tile"] .pos-product-photo { display:none; }
.pos-shell[data-menu-mode="tile"] .pos-product-select { min-height:155px; justify-content:center; }
.pos-shell[data-menu-mode="tile"] .pos-product-copy { padding:25px 18px; gap:15px; text-align:center; }
.pos-shell[data-menu-mode="tile"] .pos-product-copy strong { font-size:17px; }
.pos-shell[data-menu-mode="tile"] .pos-product-price { font-size:22px; }
.pos-shell[data-menu-mode="tile"] .pos-product-add { display:none; }
.pos-shell[data-menu-mode="tile"][data-density="small"] .pos-product-select { min-height:125px; }
.pos-shell[data-menu-mode="tile"][data-density="large"] .pos-catalogue-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }

/* The original payment and order components remain in use in every layout. */
.pos-root.pos-shell .pos-cart-col { grid-area:cart; width:100%; min-height:0; min-width:0; background:var(--bg-surface)!important; border-left:1px solid var(--border-faint)!important; }
.pos-cart-body { flex:1; min-height:0; }
.pos-cart-context { flex-shrink:0; padding:14px 14px 10px; }
.pos-cart-list-heading { display:flex; align-items:center; justify-content:space-between; padding:10px 14px 3px; flex-shrink:0; }
.pos-cart-list-heading strong { font-size:13px; }
.pos-cart-list-heading button { color:#dc4848; font-size:11px; }
.pos-cart-items { min-height:60px; }
.pos-shell .pos-cart-item-row { min-height:72px; }
.pos-shell .pos-cart-item-row button { min-width:27px; min-height:27px; }
.pos-root.pos-shell .pos-text-primary,.pos-root.pos-shell .pos-cart-item-name { color:var(--text-primary)!important; }
.pos-root.pos-shell .pos-text-muted,.pos-root.pos-shell .pos-text-faint,.pos-root.pos-shell .pos-text-dimmed { color:var(--text-muted)!important; }
.pos-root.pos-shell [style*="background:var(--bg-field)"],.pos-root.pos-shell [style*="background: var(--bg-field)"] { background:var(--bg-field)!important; }
.pos-root.pos-shell [style*="color:var(--text-primary)"],.pos-root.pos-shell [style*="color: var(--text-primary)"] { color:var(--text-primary)!important; }
.pos-root.pos-shell [style*="color:var(--text-muted)"],.pos-root.pos-shell [style*="color:var(--text-faint)"] { color:var(--text-muted)!important; }
.pos-root.pos-shell .pos-order-type-inactive,.pos-root.pos-shell .pos-table-btn-border { background:var(--bg-field)!important; color:var(--text-muted)!important; border-color:var(--border-subtle)!important; }
.pos-cart-notes,.pos-cart-totals,.pos-cart-actions { flex-shrink:0; border-color:var(--border-faint)!important; }
.pos-cart-totals .text-blue-500 { color:var(--brand-600)!important; font-size:25px; }
.pos-cart-actions button { min-height:36px; }
.pos-cart-actions .grid.grid-cols-4 { gap:7px; }
.pos-cart-local-nav { display:none!important; }
.pos-primary-checkout,.pos-save-appearance { border:0; border-radius:10px; background:var(--brand-600)!important; color:var(--brand-strong-ink)!important; font-weight:750; padding:12px 16px; }
.pos-cart-body>.pos-primary-checkout { margin:0 12px 12px; flex-shrink:0; display:flex; justify-content:space-between; align-items:center; min-height:42px; }
.pos-shell .pos-selected-cart-row { background:var(--brand-tint-bg); border-radius:7px; }
.pos-root.pos-shell .pos-options-sidebar,.pos-root.pos-shell .pos-options-header { background:var(--bg-surface)!important; }
.pos-root.pos-shell .pos-options-label { color:var(--text-primary)!important; }
.pos-root.pos-shell .pos-options-desc { color:var(--text-muted)!important; }
.pos-layout-navigation { grid-area:navigation; display:flex; flex-direction:column; align-items:stretch; gap:9px; width:76px; padding:14px 7px; background:var(--bg-surface); border-right:1px solid var(--border-faint); }
.pos-layout-navigation button { display:flex; flex-direction:column; gap:4px; align-items:center; justify-content:center; min-height:59px; border:0; border-radius:9px; color:var(--text-muted); font-size:21px; }
.pos-layout-navigation span { font-size:10px; }
.pos-layout-navigation button[aria-pressed="true"] { color:var(--brand-600); background:var(--brand-tint-bg); }
.pos-shell[data-navigation="rail"] .pos-workspace { grid-template-columns:76px minmax(0,1fr) 360px; grid-template-areas:"navigation menu cart"; }
.pos-shell[data-navigation="bottom"] .pos-workspace { grid-template-rows:minmax(0,1fr) 58px; grid-template-areas:"menu cart" "navigation navigation"; }
.pos-shell[data-navigation="bottom"] .pos-layout-navigation { flex-direction:row; align-items:center; width:100%; justify-content:space-around; border-top:1px solid var(--border-faint); border-right:0; padding:4px; }
.pos-shell[data-navigation="bottom"] .pos-layout-navigation button { flex-direction:row; min-height:40px; gap:9px; padding:7px 20px; }
.pos-shell[data-navigation="bottom"] .pos-layout-navigation span { font-size:12px; }
.pos-shell[data-layout="left-cart"] .pos-workspace,.pos-shell[data-layout="keypad"] .pos-workspace,.pos-shell[data-layout="right-categories"] .pos-workspace { grid-template-columns:360px minmax(0,1fr); grid-template-areas:"cart menu"; }
.pos-shell[data-layout="left-cart"] .pos-cart-col,.pos-shell[data-layout="keypad"] .pos-cart-col { border-left:0!important; border-right:1px solid var(--border-faint); }
.pos-open-orders,.pos-quick-keys { grid-area:extra; min-width:0; min-height:0; padding:16px 12px; overflow:auto; border-right:1px solid var(--border-faint); }
.pos-open-orders h2,.pos-quick-keys h2,.pos-secondary-menu h2 { font-size:17px; font-weight:800; margin:0 0 14px; }
.pos-muted-copy { color:var(--text-muted); font-size:12px; line-height:1.6; margin:8px 0 14px; }
.pos-order-queue-card { display:flex; flex-direction:column; width:100%; gap:7px; padding:13px; margin:12px 0; text-align:left; background:var(--bg-field); border:1px solid var(--border-faint); border-radius:10px; font-size:12px; }
.pos-order-queue-card small { color:var(--brand-600); }
.pos-secondary-button { display:block; padding:10px 12px; min-height:38px; border:1px solid var(--border-subtle); border-radius:8px; font-size:12px; background:var(--bg-field); color:var(--text-primary); }
.pos-shell[data-layout="open-orders"] .pos-workspace { grid-template-columns:210px minmax(0,1fr) 355px; grid-template-areas:"extra menu cart"; }
.pos-shell[data-layout="open-orders"] .pos-catalogue-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.pos-shell[data-layout="open-orders"] .pos-product-select { flex-direction:row; min-height:112px; }
.pos-shell[data-layout="open-orders"] .pos-product-photo { width:38%; height:110px; aspect-ratio:auto; flex-shrink:0; }
.pos-shell[data-layout="open-orders"] .pos-product-copy { padding:12px 20px 12px 10px; }
.pos-shell[data-layout="open-orders"] .pos-product-add { width:22px; height:22px; font-size:17px; right:5px; bottom:5px; }
.pos-shell[data-layout="category-list"] .pos-menu-pane,.pos-shell[data-layout="category-tiles"] .pos-menu-pane,.pos-shell[data-layout="right-categories"] .pos-menu-pane { display:grid; grid-template-columns:115px minmax(0,1fr); grid-template-rows:auto minmax(0,1fr); }
.pos-shell[data-layout="category-list"] .pos-menu-toolbar,.pos-shell[data-layout="category-tiles"] .pos-menu-toolbar,.pos-shell[data-layout="right-categories"] .pos-menu-toolbar { grid-column:1/-1; }
.pos-shell[data-layout="category-list"] .pos-menu-categories,.pos-shell[data-layout="category-tiles"] .pos-menu-categories,.pos-shell[data-layout="right-categories"] .pos-menu-categories { flex-direction:column; overflow:auto; padding:8px; grid-column:1; grid-row:2; }
.pos-shell[data-layout="category-list"] .pos-menu-categories button,.pos-shell[data-layout="category-tiles"] .pos-menu-categories button,.pos-shell[data-layout="right-categories"] .pos-menu-categories button { white-space:normal; min-height:60px; }
.pos-shell[data-layout="category-list"] .pos-menu-scroll,.pos-shell[data-layout="category-tiles"] .pos-menu-scroll,.pos-shell[data-layout="right-categories"] .pos-menu-scroll { grid-column:2; grid-row:2; }
.pos-shell[data-layout="right-categories"] .pos-menu-pane { grid-template-columns:minmax(0,1fr) 105px; }
.pos-shell[data-layout="right-categories"] .pos-menu-categories { grid-column:2; }
.pos-shell[data-layout="right-categories"] .pos-menu-scroll { grid-column:1; }
.pos-editor-zone { grid-area:editor; min-width:0; min-height:0; background:var(--bg-surface); border:1px solid var(--border-faint); overflow:hidden; z-index:20; }
.pos-item-editor { height:100%; min-height:0; }
.pos-editor-empty { height:100%; display:flex; flex-direction:column; align-items:center; justify-content:center; padding:24px; text-align:center; color:var(--text-muted); gap:10px; font-size:13px; }
.pos-editor-overlay { position:fixed; left:50%; top:85px; bottom:25px; transform:translateX(-50%); width:min(600px,calc(100vw - 32px)); border-radius:14px; box-shadow:0 15px 60px #00000050; z-index:60; }
.pos-shell[data-layout="modifiers"] .pos-workspace { grid-template-columns:minmax(0,1fr) minmax(280px,.7fr) 355px; grid-template-areas:"menu editor cart"; }
.pos-shell[data-layout="modifiers"] .pos-catalogue-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.pos-shell[data-layout="modifiers"] .pos-product-photo { max-height:110px; }
.pos-shell[data-layout="modifiers"] .pos-product-select { min-height:120px; }
.pos-shell[data-layout="modifiers"] .pos-product-copy strong { font-size:13px; }
.pos-shell[data-layout="modifiers"][data-menu-mode="tile"] .pos-product-copy { gap:10px; padding:25px 12px; }
.pos-shell[data-layout="modifiers"][data-menu-mode="tile"] .pos-product-price { font-size:17px; }
.pos-secondary-menu { grid-area:secondary; display:flex; flex-direction:column; min-width:0; min-height:0; padding-top:16px; }
.pos-secondary-menu>h2 { padding:0 16px; }
.pos-shell[data-layout="favourites"] .pos-workspace { grid-template-columns:minmax(230px,.8fr) minmax(300px,1fr) 355px; grid-template-areas:"extra menu cart"; }
.pos-quick-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.pos-quick-grid .pos-product-photo,.pos-quick-grid .pos-product-favourite,.pos-quick-grid .pos-product-add,.pos-quick-grid .pos-product-description { display:none!important; }
.pos-quick-grid .pos-product-select { min-height:145px!important; align-items:center; justify-content:center; }
.pos-quick-grid .pos-product-copy { display:flex!important; padding:22px 12px!important; text-align:center; gap:12px!important; }
.pos-quick-grid .pos-product-copy strong { font-size:15px!important; }
.pos-shell[data-layout="favourites"] .pos-menu-toolbar { flex-wrap:wrap; }
.pos-shell[data-layout="favourites"] .pos-density-picker { display:none; }
.pos-shell[data-layout="favourites"] .pos-menu-categories { padding:6px 10px; }
.pos-shell[data-layout="favourites"] .pos-product-photo { display:none; }
.pos-shell[data-layout="favourites"] .pos-product-copy { padding-right:65px; gap:5px; }
.pos-quantity-pad { padding:9px 12px; border-top:1px solid var(--border-faint); flex-shrink:0; }
.pos-quantity-pad>div:first-child { display:flex; align-items:center; gap:8px; font-size:12px; margin-bottom:6px; }
.pos-quantity-pad small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--text-muted); flex:1; }
.pos-quantity-pad output { min-width:25px; font-size:17px; font-weight:800; }
.pos-keypad-keys { display:grid; grid-template-columns:repeat(3,1fr); gap:5px; margin-bottom:6px; }
.pos-keypad-keys button { min-height:32px; border-radius:7px; background:var(--bg-field); border:1px solid var(--border-faint); font-size:15px; }
.pos-quantity-pad>.pos-secondary-button { width:100%; padding:5px; min-height:30px; }

/* Horizontal cart families keep an independently scrollable order list. */
.pos-shell:is([data-layout="bottom-cart"],[data-layout="category-board"]) .pos-workspace { grid-template-columns:minmax(0,1fr); grid-template-rows:minmax(0,1fr) 295px; grid-template-areas:"menu" "cart"; }
.pos-shell[data-layout="top-cart"] .pos-workspace { grid-template-columns:minmax(0,1fr); grid-template-rows:285px minmax(0,1fr); grid-template-areas:"cart" "menu"; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-body { display:grid!important; grid-template-columns:minmax(0,1fr) 295px; grid-template-rows:62px minmax(0,1fr) 45px; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-context { grid-column:1; grid-row:1; padding:7px 12px; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-header,.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-list-heading { display:none!important; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-items { grid-column:1; grid-row:2; display:flex; gap:10px; padding:4px 12px; overflow:auto; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"]) .pos-cart-item-row { flex:0 0 230px; padding:10px; border:1px solid var(--border-faint); border-radius:10px; min-height:90px; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-notes { grid-column:1; grid-row:3; padding:4px 12px; position:relative; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-notes>div:not(:first-child) { position:absolute; bottom:42px; left:10px; right:10px; z-index:25; padding:12px; background:var(--bg-surface); border:1px solid var(--border-faint); border-radius:10px; box-shadow:0 -3px 15px var(--shadow-card); }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-totals { grid-column:2; grid-row:1; border-left:1px solid var(--border-faint); }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-actions { grid-column:2; grid-row:2; overflow:auto; padding-top:4px; padding-bottom:3px; border-left:1px solid var(--border-faint); }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-actions button { min-height:30px; padding-top:4px; padding-bottom:4px; font-size:10px; }
.pos-shell:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-body>.pos-primary-checkout { grid-column:2; grid-row:3; margin:2px 12px 7px; min-height:32px; padding:6px 12px; }
.pos-shell[data-layout="category-board"] .pos-menu-categories { display:none!important; }
.pos-shell[data-layout="category-board"] .pos-catalogue-grid { display:flex; flex-direction:row; align-items:stretch; gap:12px; min-height:100%; }
.pos-shell[data-layout="category-board"] .pos-product-group.pos-category-column { display:flex; flex-direction:column; min-width:210px; flex:1; background:var(--bg-field); border-radius:10px; padding:10px; }
.pos-shell[data-layout="category-board"] .pos-group-products { display:flex; flex-direction:column; gap:9px; }
.pos-shell[data-layout="category-board"] .pos-category-heading { display:block; font-weight:750; margin:0 0 12px; }
.pos-shell[data-layout="category-board"] .pos-product-select { flex-direction:row; align-items:center; min-height:90px; }
.pos-shell[data-layout="category-board"] .pos-product-photo { width:66px; height:80px; flex-shrink:0; aspect-ratio:auto; }
.pos-shell[data-layout="category-board"] .pos-product-copy { padding-right:25px; }
.pos-shell[data-layout="category-board"] .pos-product-add { width:22px; height:22px; font-size:18px; right:4px; bottom:6px; }
.pos-shell[data-layout="category-board"] .pos-cart-items { flex-direction:column; gap:0; padding-top:0; padding-bottom:0; }
.pos-shell[data-layout="category-board"] .pos-cart-item-row { padding:2px 7px; min-height:43px; }
.pos-shell[data-layout="category-board"] .pos-cart-item-row>div:first-child { width:30px; height:30px; }
.pos-shell[data-layout="category-board"] .pos-cart-item-row>div:nth-child(2) { display:flex; align-items:center; gap:20px; }
.pos-shell[data-layout="category-board"] .pos-cart-item-row>div:nth-child(2)>div { margin:0; }
.pos-shared-payment-bar { grid-area:paybar; display:flex; align-items:center; gap:20px; padding:12px 18px; border-top:1px solid var(--border-faint); background:var(--bg-surface); position:relative; }
.pos-shared-actions { display:flex; gap:9px; }
.pos-shared-actions button { padding:12px 18px; border:1px solid var(--border-subtle); border-radius:9px; color:var(--text-muted); }
.pos-shared-total { margin-left:auto; display:flex; flex-direction:column; }
.pos-shared-total strong { font-size:25px; }
.pos-shared-total small { color:var(--text-muted); }
.pos-shared-payment-bar>.pos-primary-checkout { min-width:220px; min-height:52px; font-size:17px; }
.pos-payment-bar-popover { position:absolute; left:18px; bottom:80px; padding:16px; border:1px solid var(--border-faint); border-radius:12px; background:var(--bg-surface); box-shadow:0 0 20px var(--shadow-card); z-index:30; }
.pos-payment-bar-popover input,.pos-payment-bar-popover select { display:block; background:var(--bg-field); border:1px solid var(--border-subtle); padding:8px; border-radius:6px; margin:8px 0; color:var(--text-primary); }
/* Collection/refund panels always receive a full-height checkout column. */
.pos-shell:not([data-cart-view="cart"]) .pos-workspace,.pos-shell:not([data-main-tab="pos"]) .pos-workspace { grid-template-columns:minmax(0,1fr) 380px; grid-template-rows:minmax(0,1fr); grid-template-areas:"menu cart"; }
.pos-shell:not([data-cart-view="cart"]) :is(.pos-open-orders,.pos-quick-keys,.pos-secondary-menu,.pos-layout-navigation),.pos-shell:not([data-main-tab="pos"]) :is(.pos-open-orders,.pos-quick-keys,.pos-secondary-menu,.pos-layout-navigation,.pos-editor-zone) { display:none!important; }
.pos-shell:not([data-main-tab="pos"]) .pos-cart-body { display:flex!important; }
.pos-mobile-cart-toggle { display:none; }

/* Account appearance gallery. */
.pos-appearance-overlay { position:fixed; inset:0; z-index:150; display:flex; align-items:center; justify-content:center; background:#14203487; padding:22px; }
.pos-appearance-dialog { display:flex; flex-direction:column; width:min(1130px,100%); max-height:94dvh; border-radius:18px; background:var(--bg-surface); box-shadow:0 20px 70px #00000055; border:1px solid var(--border-subtle); overflow:hidden; }
.pos-appearance-dialog>header { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; padding:22px 26px 16px; }
.pos-appearance-dialog h2 { font-size:23px; font-weight:800; letter-spacing:-.5px; margin:0 0 5px; }
.pos-appearance-dialog header p { color:var(--text-muted); font-size:13px; margin:0; }
.pos-appearance-dialog header button { width:32px; min-height:32px; border:1px solid var(--border-subtle); border-radius:8px; font-size:22px; }
.pos-appearance-tabs { display:flex; gap:7px; padding:0 26px 14px; border-bottom:1px solid var(--border-faint); }
.pos-appearance-tabs button { padding:9px 15px; border-radius:8px; border:1px solid var(--border-faint); font-size:13px; font-weight:700; }
.pos-appearance-tabs button[aria-pressed="true"] { background:var(--brand-tint-bg); color:var(--brand-600); border-color:var(--brand-500); }
.pos-appearance-tabs span { font-size:10px; opacity:.65; }
.pos-appearance-content { flex:1; overflow:auto; padding:18px 26px 24px; min-height:0; }
.pos-gallery-toolbar { display:flex; align-items:center; justify-content:space-between; gap:18px; margin-bottom:16px; font-size:12px; color:var(--text-muted); }
.pos-gallery-toolbar input { background:var(--bg-field); border:1px solid var(--border-subtle); border-radius:8px; padding:9px 12px; color:var(--text-primary); }
.pos-design-gallery { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:15px; }
.pos-design-option { border:2px solid var(--border-faint); border-radius:12px; overflow:hidden; }
.pos-design-option.selected { border-color:var(--brand-500); }
.pos-design-option>button:first-child { display:flex; flex-direction:column; width:100%; text-align:left; padding:10px; }
.pos-design-option strong { margin:11px 2px 5px; font-size:13px; font-weight:750; }
.pos-design-option small { color:var(--text-muted); font-size:11px; min-height:31px; line-height:1.5; margin:0 2px; }
.pos-match-colours { display:block; width:100%; padding:9px; background:var(--bg-field); border-top:1px solid var(--border-faint); color:var(--brand-600); font-size:11px!important; }
.pos-design-thumbnail { width:100%; aspect-ratio:1.7; padding:7px; display:grid; grid-template-columns:1fr 34%; grid-template-rows:12px minmax(0,1fr); grid-template-areas:"head head" "menu cart"; gap:5px; background:var(--preview-bg); border-radius:7px; border:1px solid #17203315; }
.preview-header { grid-area:head; background:var(--preview-surface); border-radius:3px; }
.preview-menu { grid-area:menu; display:grid; grid-template-columns:repeat(3,1fr); gap:4px; }
.preview-menu i { border-radius:3px; background:var(--preview-surface); border-bottom:8px solid var(--preview-accent); opacity:.7; }
.preview-cart { grid-area:cart; display:flex; flex-direction:column; padding:6px; gap:5px; background:var(--preview-surface); border-radius:3px; }
.preview-cart i { height:5px; background:var(--preview-text); opacity:.15; }
.preview-cart b { height:13px; background:var(--preview-accent); margin-top:auto; border-radius:2px; }
.preview-extra { display:none; grid-area:extra; background:var(--preview-surface); border-radius:3px; }
[data-preview-family="left-cart"],[data-preview-family="keypad"],[data-preview-family="right-categories"] { grid-template-columns:34% 1fr; grid-template-areas:"head head" "cart menu"; }
[data-preview-family="bottom-cart"],[data-preview-family="category-board"] { grid-template-columns:1fr; grid-template-rows:12px 1fr 30%; grid-template-areas:"head" "menu" "cart"; }
[data-preview-family="top-cart"] { grid-template-columns:1fr; grid-template-rows:12px 30% 1fr; grid-template-areas:"head" "cart" "menu"; }
:is([data-preview-family="bottom-cart"],[data-preview-family="top-cart"],[data-preview-family="category-board"]) .preview-cart { flex-direction:row; align-items:center; }
:is([data-preview-family="bottom-cart"],[data-preview-family="top-cart"],[data-preview-family="category-board"]) .preview-cart b { width:25%; height:18px; margin-top:0; margin-left:auto; }
[data-preview-family="category-board"] .preview-menu { grid-template-columns:repeat(4,1fr); }
[data-preview-family="category-board"] .preview-menu i { border-top:7px solid var(--preview-accent); border-bottom:0; }
[data-preview-family="payment-bar"] { grid-template-rows:12px 1fr 17px; grid-template-areas:"head head" "menu cart" "extra extra"; }
[data-preview-family="payment-bar"] .preview-extra { display:block; background:var(--preview-accent); }
:is([data-preview-family="open-orders"],[data-preview-family="favourites"]) { grid-template-columns:22% 1fr 30%; grid-template-areas:"head head head" "extra menu cart"; }
:is([data-preview-family="open-orders"],[data-preview-family="favourites"],[data-preview-family="modifiers"],[data-preview-family="central-cart"]) .preview-extra { display:block; }
:is([data-preview-family="modifiers"],[data-preview-family="central-cart"]) { grid-template-columns:1fr 28% 30%; grid-template-areas:"head head head" "menu extra cart"; }
[data-preview-family="central-cart"] { grid-template-areas:"head head head" "menu cart extra"; }
[data-preview-view="list"] .preview-menu { display:flex; flex-direction:column; }
[data-preview-view="list"] .preview-menu i { min-height:8px; flex:1; border-bottom:0; border-left:8px solid var(--preview-accent); }
.pos-palette-gallery { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; }
.pos-palette-option { text-align:left; padding:12px; border:2px solid var(--border-faint); border-radius:10px; }
.pos-palette-option[aria-pressed="true"] { border-color:var(--brand-500); }
.pos-palette-swatches { display:flex; height:48px; border:1px solid #17203320; border-radius:7px; overflow:hidden; margin-bottom:10px; }
.pos-palette-swatches i { flex:1; }
.pos-palette-option strong { font-size:12px; }
.pos-custom-colours { margin-top:24px; padding:18px; border:1px solid var(--border-subtle); border-radius:10px; display:flex; align-items:center; flex-wrap:wrap; gap:16px; }
.pos-custom-colours legend { font-weight:750; padding:0 5px; }
.pos-custom-colours p { font-size:12px; color:var(--text-muted); width:100%; margin:0; }
.pos-custom-colours label { display:flex; align-items:center; gap:8px; font-size:12px; }
.pos-custom-colours input { width:43px; height:33px; padding:2px; border:1px solid var(--border-subtle); border-radius:5px; }
.pos-custom-colours button { font-size:12px; margin-left:auto; color:var(--brand-600); }
.pos-display-settings { max-width:600px; display:flex; flex-direction:column; gap:18px; padding:8px 0; }
.pos-display-settings label { display:flex; flex-direction:column; gap:7px; font-size:13px; font-weight:650; }
.pos-display-settings select { background:var(--bg-field); color:var(--text-primary); padding:10px; border:1px solid var(--border-subtle); border-radius:8px; }
.pos-display-settings p { color:var(--text-muted); font-size:12px; }
.pos-appearance-dialog>footer { display:flex; align-items:center; gap:9px; padding:14px 26px; border-top:1px solid var(--border-faint); }
.pos-appearance-dialog>footer>button { border:1px solid var(--border-subtle); padding:10px 13px; border-radius:8px; font-size:12px; white-space:nowrap; }
.pos-appearance-feedback { flex:1; font-size:12px; color:var(--brand-600); }
.pos-appearance-feedback small { color:var(--text-muted); font-size:11px; }
.pos-appearance-error { display:block; color:#dc4848; font-size:12px; }
.pos-inline-appearance-error { padding:9px 15px; font-size:12px; color:#b42330; background:#fff0f0; flex-shrink:0; }
.pos-inline-appearance-error button { text-decoration:underline; font-weight:700; }

@media (max-width:1199px) {
    .pos-header-legacy-controls>div:first-child { display:none; }
    .pos-shell[data-layout="open-orders"] .pos-workspace { grid-template-columns:165px minmax(0,1fr) 325px; }
    .pos-shell[data-layout="modifiers"] .pos-workspace { grid-template-columns:minmax(0,1fr) 270px 320px; }
    .pos-shell[data-layout="modifiers"] .pos-menu-display,.pos-shell[data-layout="modifiers"] .pos-density-picker { display:none; }
    .pos-shell[data-layout="favourites"] .pos-workspace { grid-template-columns:225px minmax(0,1fr) 325px; }
    .pos-catalogue-grid,.pos-shell[data-density="small"] .pos-catalogue-grid { grid-template-columns:repeat(4,minmax(0,1fr)); }
    .pos-shell[data-layout="open-orders"] .pos-catalogue-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .pos-shell[data-layout="favourites"] .pos-product-copy { display:flex!important; }
}
@media (max-width:960px) {
    .pos-root.pos-shell { padding:0; }
    .pos-header-legacy-controls { padding:0!important; }
    .pos-workspace { border-radius:0; }
    .pos-shell[data-layout="modifiers"] .pos-workspace { grid-template-columns:minmax(0,1fr) 320px; grid-template-areas:"menu cart"; }
    .pos-shell[data-layout="modifiers"] .pos-editor-docked { position:fixed; left:50%; top:70px; bottom:20px; width:min(550px,calc(100vw - 30px)); transform:translateX(-50%); z-index:60; border-radius:12px; box-shadow:0 5px 40px #00000055; }
    .pos-shell[data-layout="modifiers"] .pos-editor-docked:has(.pos-editor-empty) { display:none!important; }
    .pos-shell[data-layout="modifiers"] .pos-editor-docked:not(:has(.pos-editor-empty)) { display:flex; flex-direction:column; }
    .pos-shell[data-layout="favourites"] .pos-workspace { grid-template-columns:minmax(0,1fr) 325px; grid-template-areas:"menu cart"; }
    .pos-shell[data-layout="favourites"] .pos-quick-keys { display:none!important; }
    .pos-shell[data-layout="open-orders"] .pos-workspace { grid-template-columns:minmax(0,1fr) 325px; grid-template-areas:"menu cart"; }
    .pos-shell[data-layout="open-orders"] .pos-open-orders { display:none!important; }
    .pos-shell[data-navigation="rail"] .pos-workspace { grid-template-columns:65px minmax(0,1fr) 325px; }
    .pos-layout-navigation { width:65px; }
    .pos-menu-toolbar { flex-wrap:wrap; padding:10px; }
    .pos-menu-categories { padding:7px 10px; }
    .pos-menu-scroll { padding:4px 10px 12px; }
    .pos-density-picker { display:none; }
    .pos-catalogue-grid,.pos-shell[data-density="small"] .pos-catalogue-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
    .pos-shell[data-menu-mode="tile"] .pos-catalogue-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
    .pos-appearance-overlay { padding:12px; }
    .pos-design-gallery { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .pos-shared-actions { gap:5px; }
    .pos-shared-actions button { padding:10px; }
}
@media (max-width:700px) {
    .pos-header-legacy-controls { display:flex!important; gap:2px!important; }
    .pos-header-legacy-controls button[title="AI Assistant"] { display:none; }
    .pos-shell .pos-workspace { display:flex; flex-direction:column; padding-bottom:52px; }
    .pos-shell .pos-menu-region { flex:1; width:100%; }
    .pos-root.pos-shell .pos-cart-col { display:none; width:100%; flex:1; min-height:0; }
    .pos-shell.pos-mobile-cart-open .pos-cart-col { display:flex; }
    .pos-shell.pos-mobile-cart-open .pos-menu-region { display:none; }
    .pos-shell:not([data-cart-view="cart"]) .pos-cart-col { display:flex; }
    .pos-shell:not([data-cart-view="cart"]) .pos-menu-region { display:none; }
    .pos-shell .pos-layout-navigation,.pos-shell .pos-open-orders,.pos-shell .pos-quick-keys,.pos-shell .pos-secondary-menu,.pos-shell .pos-shared-payment-bar { display:none!important; }
    .pos-shell .pos-cart-body { display:flex!important; }
    .pos-shell .pos-cart-context { padding:10px 12px; }
    .pos-shell .pos-cart-items { display:block!important; }
    .pos-shell .pos-cart-item-row { min-height:70px; padding:10px; border:0; border-bottom:1px solid var(--border-faint); }
    .pos-shell .pos-cart-notes { position:static; }
    .pos-shell .pos-cart-totals,.pos-shell .pos-cart-actions,.pos-shell .pos-cart-body>.pos-primary-checkout { display:block!important; }
    .pos-shell .pos-cart-notes>div:not(:first-child) { position:static; }
    .pos-mobile-cart-toggle { display:block; position:fixed; bottom:8px; left:12px; right:12px; min-height:42px; border:0; border-radius:10px; background:var(--brand-600); color:var(--brand-strong-ink); z-index:55; font-size:14px; font-weight:750; }
    .pos-shell .pos-menu-pane { display:flex!important; }
    .pos-shell .pos-menu-categories { display:flex!important; flex-direction:row!important; padding:8px 10px!important; }
    .pos-shell .pos-menu-categories button { min-height:36px!important; padding:8px 11px; white-space:nowrap!important; }
    .pos-shell .pos-catalogue-grid,.pos-shell[data-density="small"] .pos-catalogue-grid,.pos-shell[data-menu-mode="tile"] .pos-catalogue-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .pos-shell[data-layout="category-board"] .pos-catalogue-grid { display:grid; }
    .pos-shell[data-layout="category-board"] .pos-product-group,.pos-shell[data-layout="category-board"] .pos-group-products { display:contents!important; }
    .pos-shell[data-layout="category-board"] .pos-category-heading { display:none; }
    .pos-shell[data-layout="category-board"] .pos-product-select { flex-direction:column; }
    .pos-shell[data-layout="category-board"] .pos-product-photo { width:100%; height:auto; aspect-ratio:1.4; }
    .pos-shell[data-layout="modifiers"] .pos-editor-zone { left:12px; right:12px; top:65px; bottom:60px; width:auto; transform:none; }
    .pos-shell .pos-editor-overlay { left:12px; right:12px; top:65px; bottom:60px; width:auto; transform:none; }
    .pos-appearance-overlay { padding:6px; }
    .pos-appearance-dialog { max-height:98dvh; border-radius:12px; }
    .pos-appearance-dialog>header { padding:17px 15px; }
    .pos-appearance-dialog h2 { font-size:19px; }
    .pos-appearance-dialog header p { font-size:11px; }
    .pos-appearance-tabs { padding:0 15px 12px; }
    .pos-appearance-content { padding:15px; }
    .pos-design-gallery,.pos-palette-gallery { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
    .pos-gallery-toolbar { flex-wrap:wrap; }
    .pos-appearance-dialog>footer { padding:10px 15px; flex-wrap:wrap; gap:7px; }
    .pos-appearance-feedback { flex-basis:100%; }
    .pos-appearance-dialog>footer>button { font-size:11px; padding:9px 10px; }
}
@media (prefers-reduced-motion:reduce) { .pos-shell * { animation:none!important; transition:none!important; scroll-behavior:auto!important; } }

/* Alpine visibility takes precedence over structural layout rules. */
.pos-shell [x-show][style*="display: none"] { display:none!important; }

/* Appending to an existing order uses the established full-height item controls. */
.pos-shell[data-append-mode="true"] .pos-workspace { grid-template-columns:minmax(0,1fr) 380px; grid-template-rows:minmax(0,1fr); grid-template-areas:"menu cart"; }
.pos-shell[data-append-mode="true"] :is(.pos-open-orders,.pos-quick-keys,.pos-secondary-menu,.pos-layout-navigation,.pos-editor-docked) { display:none!important; }
.pos-shell[data-append-mode="true"] .pos-cart-body { display:flex!important; }
.pos-shell[data-append-mode="true"] .pos-cart-items { display:block!important; }
.pos-shell[data-append-mode="true"] .pos-cart-item-row { min-height:72px; }
.pos-shell[data-append-mode="true"] .pos-cart-actions { display:block!important; }
.pos-shell[data-append-mode="true"] .pos-cart-notes>div:not(:first-child) { position:static; }
@media(max-width:700px) { .pos-shell[data-append-mode="true"] .pos-workspace { display:flex; } }

/* Item selector styles are independent of the menu layout and palette. */
.pos-editor-zone { container-type:inline-size; }
.pos-root.pos-shell .pos-editor-inline { grid-area:menu; position:relative; inset:auto; transform:none; width:100%; height:100%; border:0; border-radius:0; box-shadow:none; z-index:21; }
.pos-shell[data-editor-open="true"] .pos-workspace:has(>.pos-editor-inline)>.pos-menu-region { visibility:hidden; pointer-events:none; }
.pos-selector-body { flex:1; min-height:0; display:flex; flex-direction:column; }
.pos-selector-scroll { min-width:0; min-height:0; }
.pos-selector-tab { border:0; cursor:pointer; }
.pos-selector-tab[aria-selected="true"] { color:var(--brand-ink)!important; }
.pos-selector-additional[aria-selected="true"] { color:#fff!important; }
.pos-option-grid { grid-template-columns:repeat(4,minmax(0,1fr)); }
.pos-option-choice { min-width:0; }
.pos-option-choice>div { min-height:75px; }
.pos-option-choice:focus-within>div { outline:3px solid var(--brand-500); outline-offset:3px; }
.pos-option-heading { color:var(--text-primary); font-size:13px; font-weight:800; margin:0 0 12px; }
.pos-editor-price,.pos-editor-submit { color:var(--brand-strong-ink)!important; }
.pos-shell[data-selector="pill-tabs"] .pos-selector-tabs { align-items:center; gap:8px; padding:12px 14px; border-bottom:1px solid var(--border-faint)!important; }
.pos-shell[data-selector="pill-tabs"] .pos-selector-tab { border-radius:999px; padding:9px 17px; }
.pos-shell[data-selector="pill-tabs"] .pos-option-choice>div { border-radius:24px; }
.pos-shell[data-selector="underline-tabs"] .pos-selector-tabs { gap:12px; padding-top:5px; }
.pos-shell[data-selector="underline-tabs"] .pos-selector-tab { border-radius:0; border-bottom:3px solid transparent; padding:14px 7px 11px; background:transparent!important; color:var(--text-muted)!important; }
.pos-shell[data-selector="underline-tabs"] .pos-selector-tab[aria-selected="true"] { border-color:var(--brand-500); color:var(--brand-600)!important; }
.pos-shell[data-selector="underline-tabs"] .pos-option-choice>div { border-radius:7px; box-shadow:none!important; transform:none!important; }
.pos-shell[data-selector="side-tabs"] .pos-selector-body { display:grid; grid-template-columns:130px minmax(0,1fr); }
.pos-shell[data-selector="side-tabs"] .pos-selector-tabs { flex-direction:column; align-items:stretch; gap:5px; overflow:auto; padding:12px 8px; border-bottom:0!important; border-right:1px solid var(--border-faint); background:var(--bg-surface); }
.pos-shell[data-selector="side-tabs"] .pos-selector-tab { border-radius:8px; min-height:42px; padding:11px; text-align:left; }
.pos-shell[data-selector="segmented-tabs"] .pos-selector-tabs { margin:12px 14px 0; padding:4px; gap:3px; border:1px solid var(--border-faint)!important; border-radius:10px; background:var(--bg-field); }
.pos-shell[data-selector="segmented-tabs"] .pos-selector-tab { flex:1; justify-content:center; border-radius:7px; padding:10px 12px; }
.pos-shell:is([data-selector="pill-tabs"],[data-selector="side-tabs"],[data-selector="segmented-tabs"]) .pos-selector-tab[aria-selected="true"] { background:var(--brand-500)!important; color:var(--brand-ink)!important; }
.pos-shell[data-selector="segmented-tabs"] .pos-option-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.pos-shell[data-selector="segmented-tabs"] .pos-option-choice>div { flex-direction:row; justify-content:space-between; text-align:left; min-height:48px; border-radius:9px; padding:12px; box-shadow:none!important; transform:none!important; }
.pos-shell[data-selector="stacked"] .pos-option-panel { padding-top:18px; padding-bottom:18px; border-bottom:1px solid var(--border-faint); }
.pos-shell[data-selector="stacked"] .pos-option-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.pos-shell[data-selector="stacked"] .pos-option-choice>div { min-height:60px; border-radius:9px; transform:none!important; }
@container (max-width:430px) {
    .pos-option-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .pos-selector-tab { padding-left:10px; padding-right:10px; }
    .pos-shell[data-selector="side-tabs"] .pos-selector-body { grid-template-columns:100px minmax(0,1fr); }
    .pos-shell[data-selector="side-tabs"] .pos-option-grid,.pos-shell[data-selector="segmented-tabs"] .pos-option-grid { grid-template-columns:minmax(0,1fr); }
}

/* Selector previews use the same group positions as their full-size counterparts. */
.pos-selector-gallery { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:15px; }
.pos-selector-option { display:flex; flex-direction:column; gap:7px; text-align:left; padding:12px; border:2px solid var(--border-faint); border-radius:12px; background:var(--bg-surface); color:var(--text-primary); }
.pos-selector-option[aria-pressed="true"] { border-color:var(--brand-500); box-shadow:0 0 0 2px var(--brand-tint-bg); }
.pos-selector-option>strong { font-size:13px; margin-top:4px; }
.pos-selector-option>small { font-size:11px; color:var(--text-muted); line-height:1.6; }
.pos-selector-thumbnail { width:100%; height:150px; padding:10px; border:1px solid var(--border-faint); border-radius:8px; background:var(--bg-page); display:flex; flex-direction:column; gap:9px; font-size:8px; }
.selector-preview-header { display:flex; justify-content:space-between; font-size:10px; font-weight:750; padding-bottom:7px; border-bottom:1px solid var(--border-faint); }
.selector-preview-header b { color:var(--brand-600); }
.selector-preview-body { flex:1; min-height:0; display:flex; flex-direction:column; gap:9px; }
.selector-preview-tabs { display:flex; gap:4px; }
.selector-preview-tabs i { padding:5px 8px; border-radius:6px 6px 0 0; background:var(--bg-field); color:var(--text-muted); font-style:normal; }
.selector-preview-tabs i:first-child { background:var(--brand-500); color:var(--brand-ink); }
.selector-preview-options { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:5px; }
.selector-preview-options i { display:grid; place-items:center; height:32px; border:1px solid var(--border-faint); border-radius:7px; background:var(--bg-surface); font-style:normal; }
.selector-preview-options i:nth-child(2) { background:var(--brand-500); color:var(--brand-ink); }
.selector-preview-add { background:var(--brand-500); color:var(--brand-ink); border-radius:6px; text-align:center; padding:6px; font-weight:700; }
[data-selector-preview="pill-tabs"] .selector-preview-tabs i { border-radius:99px; }
[data-selector-preview="pill-tabs"] .selector-preview-options i { border-radius:13px; }
[data-selector-preview="underline-tabs"] .selector-preview-tabs i { background:transparent; color:var(--text-muted); border-radius:0; border-bottom:2px solid transparent; }
[data-selector-preview="underline-tabs"] .selector-preview-tabs i:first-child { border-color:var(--brand-500); color:var(--brand-600); }
[data-selector-preview="side-tabs"] .selector-preview-body { flex-direction:row; }
[data-selector-preview="side-tabs"] .selector-preview-tabs { flex-direction:column; gap:3px; }
[data-selector-preview="side-tabs"] .selector-preview-tabs i { border-radius:5px; padding:4px 8px; }
[data-selector-preview="side-tabs"] .selector-preview-options { flex:1; grid-template-columns:repeat(2,minmax(0,1fr)); }
[data-selector-preview="side-tabs"] .selector-preview-options i { height:auto; }
[data-selector-preview="segmented-tabs"] .selector-preview-tabs { padding:3px; gap:2px; background:var(--bg-field); border-radius:6px; }
[data-selector-preview="segmented-tabs"] .selector-preview-tabs i { flex:1; text-align:center; border-radius:4px; padding:4px; }
[data-selector-preview="segmented-tabs"] .selector-preview-options { grid-template-columns:repeat(2,minmax(0,1fr)); }
[data-selector-preview="segmented-tabs"] .selector-preview-options i { height:18px; }
[data-selector-preview="stacked"] .selector-preview-tabs { display:none; }
[data-selector-preview="stacked"] .selector-preview-options { grid-template-columns:repeat(2,minmax(0,1fr)); }
[data-selector-preview="stacked"] .selector-preview-options i { height:29px; }

/* Compact POS chrome gives the product catalogue more width and height. */
.pos-root.pos-shell[data-chrome="compact"] { padding:6px; }
.pos-shell[data-chrome="compact"] .pos-menu-toolbar { padding:9px 12px 5px; gap:7px; }
.pos-shell[data-chrome="compact"] .pos-menu-toolbar h2 { font-size:15px; }
.pos-shell[data-chrome="compact"] .pos-menu-display { padding:2px; }
.pos-shell[data-chrome="compact"] .pos-menu-display button { height:28px; width:28px; }
.pos-shell[data-chrome="compact"] .pos-density-picker select { padding:7px 22px 7px 8px; font-size:11px; }
.pos-shell[data-chrome="compact"] .pos-menu-categories { padding:5px 12px 9px; gap:6px; }
.pos-shell[data-chrome="compact"] .pos-menu-categories button { min-height:32px; padding:6px 12px; font-size:11px; border-radius:8px; }
.pos-shell[data-chrome="compact"] .pos-menu-scroll { padding:3px 12px 12px; }
.pos-shell[data-chrome="compact"] .pos-cart-header { padding:9px 12px; }
.pos-shell[data-chrome="compact"] .pos-cart-header h3 { font-size:13px; }
.pos-shell[data-chrome="compact"] .pos-cart-context { padding:8px 10px; }
.pos-shell[data-chrome="compact"] .pos-cart-context label { font-size:10px; margin-bottom:3px; }
.pos-shell[data-chrome="compact"] .pos-cart-context input,.pos-shell[data-chrome="compact"] .pos-cart-context button { padding-top:6px; padding-bottom:6px; font-size:12px; }
.pos-shell[data-chrome="compact"] .pos-cart-list-heading { padding:7px 11px 2px; }
.pos-shell[data-chrome="compact"] .pos-cart-list-heading strong { font-size:12px; }
.pos-shell[data-chrome="compact"] .pos-cart-item-row { min-height:59px; padding-top:7px; padding-bottom:7px; }
.pos-shell[data-chrome="compact"] .pos-cart-item-name { font-size:12px; }
.pos-shell[data-chrome="compact"] .pos-cart-notes { padding:5px 10px; }
.pos-shell[data-chrome="compact"] .pos-cart-totals { padding:7px 11px; }
.pos-shell[data-chrome="compact"] .pos-cart-totals .text-blue-500 { font-size:22px; }
.pos-shell[data-chrome="compact"] .pos-cart-actions { padding:6px 10px 8px; }
.pos-shell[data-chrome="compact"] .pos-cart-actions button { min-height:32px; padding-top:7px; padding-bottom:7px; font-size:11px; }
.pos-shell[data-chrome="compact"] .pos-cart-actions .grid.grid-cols-4 { gap:5px; }
.pos-shell[data-chrome="compact"] .pos-cart-actions .grid.grid-cols-4 button { min-height:47px; gap:3px; font-size:10px; }
.pos-shell[data-chrome="compact"] .pos-cart-actions .grid.grid-cols-4 svg { width:17px; height:17px; }
.pos-shell[data-chrome="compact"] .pos-cart-body>.pos-primary-checkout { margin:0 10px 9px; min-height:38px; padding:8px 12px; font-size:12px; }
.pos-shell[data-chrome="compact"] .pos-layout-navigation { width:64px; padding:10px 5px; gap:6px; }
.pos-shell[data-chrome="compact"] .pos-layout-navigation button { min-height:48px; }
.pos-shell[data-chrome="compact"] .pos-shared-payment-bar { padding:8px 13px; gap:14px; }
.pos-shell[data-chrome="compact"] .pos-shared-actions button { padding:9px 12px; font-size:12px; }
.pos-shell[data-chrome="compact"] .pos-shared-payment-bar>.pos-primary-checkout { min-height:43px; font-size:15px; }
@media(min-width:701px) {
    .pos-shell[data-chrome="compact"] .pos-workspace { grid-template-columns:minmax(0,1fr) 310px; }
    .pos-shell[data-chrome="compact"][data-navigation="rail"] .pos-workspace { grid-template-columns:64px minmax(0,1fr) 310px; }
    .pos-shell[data-chrome="compact"][data-layout="open-orders"] .pos-workspace { grid-template-columns:175px minmax(0,1fr) 310px; }
    .pos-shell[data-chrome="compact"][data-layout="modifiers"] .pos-workspace { grid-template-columns:minmax(0,1fr) minmax(270px,.65fr) 310px; }
    .pos-shell[data-chrome="compact"][data-layout="favourites"] .pos-workspace { grid-template-columns:minmax(200px,.65fr) minmax(0,1fr) 310px; }
    .pos-shell[data-chrome="compact"]:is([data-layout="bottom-cart"],[data-layout="category-board"]) .pos-workspace { grid-template-columns:minmax(0,1fr); grid-template-rows:minmax(0,1fr) 250px; }
    .pos-shell[data-chrome="compact"][data-layout="top-cart"] .pos-workspace { grid-template-columns:minmax(0,1fr); grid-template-rows:250px minmax(0,1fr); }
    .pos-shell[data-chrome="compact"]:is([data-layout="bottom-cart"],[data-layout="top-cart"],[data-layout="category-board"]) .pos-cart-body { grid-template-columns:minmax(0,1fr) 275px; grid-template-rows:53px minmax(0,1fr) 43px; }
    .pos-shell[data-chrome="compact"]:is([data-layout="category-list"],[data-layout="category-tiles"]) .pos-menu-pane { grid-template-columns:98px minmax(0,1fr); }
    .pos-shell[data-chrome="compact"][data-layout="right-categories"] .pos-menu-pane { grid-template-columns:minmax(0,1fr) 98px; }
    .pos-shell[data-chrome="compact"]:is([data-layout="category-list"],[data-layout="category-tiles"],[data-layout="right-categories"]) .pos-menu-categories button { min-height:47px; white-space:normal; padding:8px; }
    .pos-shell[data-chrome="compact"]:is([data-append-mode="true"],:not([data-main-tab="pos"]),:not([data-cart-view="cart"])) .pos-workspace { grid-template-columns:minmax(0,1fr) 340px; grid-template-rows:minmax(0,1fr); }
}
@media(max-width:960px) { .pos-selector-gallery { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:700px) {
    .pos-root.pos-shell[data-chrome="compact"] { padding:0; }
    .pos-shell[data-chrome="compact"] .pos-menu-display button { min-width:36px; height:36px; }
    .pos-shell .pos-workspace:has(>.pos-editor-inline)>.pos-menu-region { visibility:visible; }
    .pos-shell[data-editor-open="true"] .pos-workspace:has(>.pos-editor-inline)>.pos-menu-region { display:none!important; }
    .pos-root.pos-shell .pos-editor-inline { flex:1; min-height:0; }
    .pos-shell.pos-mobile-cart-open .pos-editor-inline { display:none!important; }
    .pos-shell[data-chrome="compact"] .pos-cart-item-row { min-height:67px; }
    .pos-shell[data-chrome="compact"] .pos-cart-actions button { min-height:40px; }
    .pos-root.pos-shell[data-layout] .pos-cart-body { display:flex!important; }
    .pos-root.pos-shell[data-layout][data-cart-view="cart"] .pos-cart-totals,.pos-root.pos-shell[data-layout][data-cart-view="cart"] .pos-cart-actions { display:block!important; }
    .pos-root.pos-shell[data-layout][data-cart-view="cart"] .pos-cart-body>.pos-primary-checkout { display:flex!important; }
    .pos-appearance-tabs { overflow-x:auto; flex-shrink:0; gap:5px; }
    .pos-appearance-tabs button { white-space:nowrap; padding:9px 10px; }
    .pos-selector-gallery { gap:10px; }
    .pos-selector-thumbnail { height:132px; padding:7px; font-size:7px; }
    .selector-preview-tabs i { padding:4px 5px; }
}
@media(pointer:coarse) {
    .pos-shell[data-chrome="compact"] .pos-menu-categories button,.pos-shell[data-chrome="compact"] .pos-cart-item-row button,.pos-shell[data-chrome="compact"] .pos-cart-actions button,.pos-selector-tab { min-height:44px!important; }
    .pos-shell[data-chrome="compact"] .pos-menu-display button { min-width:40px; min-height:40px; }
}
/* Keep Livewire/Alpine visibility authoritative over every style choice. */
.pos-shell [x-show][style*="display: none"] { display:none!important; }

/* Retained controls: dashboard, AI, tools and the original floor-plan data. */
.pos-dashboard-shortcut { display:inline-flex; align-items:center; gap:6px; min-height:34px; padding:7px 9px; border:1px solid var(--border-subtle); border-radius:8px; font-size:11px; color:var(--text-muted); white-space:nowrap; }
.pos-root.pos-shell .pos-header-legacy-controls .pos-ai-trigger { display:inline-flex!important; align-items:center; justify-content:center; min-width:32px; min-height:32px; }
.pos-ai-trigger::after { content:'AI'; font-size:10px; font-weight:750; margin-left:4px; }
.pos-tools-menu { position:relative; }
.pos-tools-menu>summary { cursor:pointer; list-style:none; min-height:32px; min-width:28px; display:grid; place-items:center; color:var(--text-muted); }
.pos-tools-popover { position:absolute; top:100%; right:0; min-width:185px; z-index:90; padding:6px; border:1px solid var(--border-subtle); border-radius:10px; background:var(--bg-surface); box-shadow:0 7px 25px #0002; }
.pos-tools-popover>* { display:block; width:100%; text-align:left; padding:9px 11px; border:0; border-radius:6px; font-size:12px; color:var(--text-primary); background:transparent; }
.pos-tools-popover>*:hover { background:var(--bg-field); }
.pos-item-instructions-field { order:-1; }
.pos-item-instructions-label { display:block; font-size:13px; font-weight:750; color:var(--text-primary); margin-bottom:9px; }
.pos-item-instructions-label span { color:var(--text-muted); font-size:11px; font-weight:400; }
.pos-item-instructions-input { display:block; width:100%; min-height:205px; padding:14px; border:1.5px solid var(--border-subtle); border-radius:12px; resize:vertical; background:var(--bg-surface); color:var(--text-primary); font:inherit; font-size:14px; line-height:1.7; }
.pos-item-instructions-input:focus { border-color:var(--brand-500); outline:2px solid var(--brand-tint-border); }
.pos-cash-label { display:block; margin-bottom:8px; font-size:12px; font-weight:750; color:var(--text-primary); }
.pos-cash-input { display:flex; align-items:center; gap:8px; padding:10px 12px; background:var(--bg-surface); border:1.5px solid var(--border-subtle); border-radius:10px; }
.pos-cash-input>span { color:var(--text-muted); font-size:20px; }
.pos-cash-input input { width:100%; min-width:0; padding:0; border:0; box-shadow:none; background:transparent; color:var(--text-primary); font-size:26px; font-weight:750; }
.pos-cash-presets { display:flex; gap:7px; flex-wrap:wrap; margin:10px 0 20px; }
.pos-cash-presets button { flex:1; padding:8px; font-size:11px; border:1px solid var(--border-subtle); border-radius:8px; background:var(--bg-field); }
.pos-cash-change { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:15px 12px; background:var(--brand-tint-bg); border-radius:10px; font-size:12px; color:var(--text-primary); }
.pos-cash-change strong { font-size:22px; color:var(--brand-600); }
.pos-cash-error { color:#d04747; font-size:12px; margin-top:10px; }
.pos-cash-panel-footer { padding:12px 14px; border-top:1px solid var(--border-faint); }
.pos-cash-panel-footer button { width:100%; min-height:44px; }
.pos-table-map-shortcut { flex-shrink:0; width:100%; padding:6px 10px; text-align:left; color:var(--brand-600); background:var(--brand-tint-bg); border-bottom:1px solid var(--border-faint); font-size:11px!important; }
.pos-table-picker { width:min(1100px,calc(100vw - 24px)); max-height:92dvh; overflow:hidden; background:var(--bg-surface); }
.pos-table-map-toolbar { display:flex; align-items:center; flex-wrap:wrap; gap:9px; padding:10px 16px; border-bottom:1px solid var(--border-faint); font-size:12px; }
.pos-table-map-toolbar>a { margin-left:auto; color:var(--brand-600); }
.pos-table-map-toolbar>button { padding:7px 10px; border:1px solid var(--border-subtle); border-radius:7px; }
.pos-table-map-modes { display:flex; gap:3px; padding:3px; background:var(--bg-field); border-radius:8px; }
.pos-table-map-modes button,.pos-table-map-floors button { padding:7px 11px; border:0; border-radius:6px; font-size:12px; color:var(--text-muted); }
.pos-table-map-modes button[aria-pressed=true],.pos-table-map-floors button[aria-pressed=true] { background:var(--brand-500); color:var(--brand-ink); }
.pos-table-map-body { flex:1; min-height:0; display:flex; flex-direction:column; }
.pos-table-map-floors { display:flex; gap:5px; flex-wrap:wrap; align-items:center; padding:8px 16px; background:var(--bg-surface); }
.pos-table-map-zoom { display:flex; margin-left:auto; gap:4px; }
.pos-table-map-zoom button { min-width:32px; border:1px solid var(--border-subtle); }
.pos-table-map-viewport { flex:1; min-height:300px; height:430px; overflow:auto; background-color:var(--bg-page); background-image:radial-gradient(var(--border-subtle) 1px,transparent 1px); background-size:20px 20px; position:relative; }
.pos-table-map-size { min-width:100%; min-height:100%; position:relative; }
.pos-table-map-world { transform-origin:top left; position:relative; }
.pos-map-table { position:absolute; background:transparent; border:0; overflow:visible; opacity:1!important; color:var(--text-primary); }
.pos-map-table:disabled { cursor:not-allowed; }
.pos-map-table-scene { display:block; position:absolute; inset:0; transform-style:preserve-3d; pointer-events:none; }
.pos-map-table-top { position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; padding:8px; border:2px solid #6abf94; border-radius:12px; background:#edf8f1; color:#24583b; box-shadow:0 4px 10px #0f172a18; }
.pos-map-table-top strong { font-size:16px; max-width:100%; overflow-wrap:anywhere; line-height:1.2; }
.pos-map-table-top small { font-size:11px; }
.pos-map-table[data-table-shape=circle] .pos-map-table-top { border-radius:50%; }
.pos-map-table[data-table-status=occupied] .pos-map-table-top { background:#fff0e0; color:#97420f; border-color:#e8a06b; }
.pos-map-table[data-table-status=bill_requested] .pos-map-table-top { background:#fcebf4; color:#a73369; border-color:#e596ba; }
.pos-map-table[data-table-status=reserved] .pos-map-table-top { background:#f1eafc; color:#6c3aa1; border-color:#b391df; }
.pos-map-table[aria-pressed=true] .pos-map-table-top { background:var(--brand-500); color:var(--brand-ink); border-color:var(--brand-600); }
.pos-map-seats { position:absolute; inset:0; transform-style:preserve-3d; }
.pos-map-seat { position:absolute; width:27px; height:24px; border:1px solid #667588; border-radius:5px; background:#c9d2dd; transform:translate(-50%,-50%) rotate(var(--seat-angle)); }
.pos-map-seat::before { content:''; position:absolute; top:-3px; left:-1px; right:-1px; height:35%; border-radius:3px; background:#667588; }
[data-map-mode="3d"] .pos-map-table-scene { transform:perspective(700px) rotateX(34deg) rotateZ(-24deg) scale(.85); }
[data-map-mode="3d"] .pos-map-table-top { transform:translateZ(14px); box-shadow:0 2px 0 #647184,0 4px 0 #647184,0 6px 0 #475569,7px 18px 14px #0f172a30; }
[data-map-mode="3d"] .pos-map-seat { transform:translate(-50%,-50%) translateZ(6px) rotate(var(--seat-angle)); box-shadow:0 3px 0 #475569,2px 7px 5px #0f172a30; }
.pos-table-map-legend { display:flex; flex-wrap:wrap; gap:16px; font-size:11px; padding:10px 16px; color:var(--text-muted); border-top:1px solid var(--border-faint); }
.pos-table-map-legend>span:nth-child(1) { color:#287851; }.pos-table-map-legend>span:nth-child(2) { color:#bd5e24; }.pos-table-map-legend>span:nth-child(3) { color:#b34279; }.pos-table-map-legend>span:nth-child(4) { color:#7f52ae; }
.pos-table-map-empty { padding:50px; text-align:center; color:var(--text-muted); }
@media(max-width:700px) { .pos-dashboard-shortcut span { display:none; }.pos-dashboard-shortcut { font-size:17px; padding:7px; }.pos-table-picker { width:100%; max-height:94dvh; }.pos-table-map-toolbar { padding:9px; }.pos-table-map-floors { padding:8px; }.pos-table-map-viewport { height:370px; min-height:240px; }.pos-item-instructions-input { font-size:16px; min-height:180px; } }
.pos-shell [x-show][style*="display: none"] { display:none!important; }
