:root{
  --bg:#FFFFFF; --bg-alt:#F6F3F3; --surface:#FFFFFF; --surface-2:#F7F3F3;
  --border:#E6DDDD; --border-strong:#D4C6C6;
  --ink:#1E1516; --ink-soft:#5C4849; --muted:#8F7A7B;
  --accent:#D2232A; --accent-hover:#AD1B21; --accent-ink:#FFFFFF; --accent-soft:#FBE1E2;
  --success:#2E7D46; --success-soft:#E3F1E5; --success-ink:#1B4A28;
  --warning:#96660A; --warning-soft:#F6EAD3; --warning-ink:#5C3E06;
  --danger:#8C2C2C; --danger-hover:#742323; --danger-soft:#F3E0E0; --danger-ink:#6B1F1F;
  --shadow-s:0 1px 2px rgba(30,21,22,.08);
  --shadow-m:0 4px 16px rgba(30,21,22,.10);
  --shadow-l:0 12px 40px rgba(30,21,22,.20);
  --font-ui:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --font-mono:ui-monospace,"SF Mono","Cascadia Mono","Roboto Mono",Menlo,Consolas,monospace;
  --radius-s:9px; --radius-m:13px; --radius-l:20px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark){
  :root{
    --bg:#181213; --bg-alt:#1F1717; --surface:#231A1B; --surface-2:#291F20;
    --border:#3A2C2D; --border-strong:#4A3838;
    --ink:#F5EEEE; --ink-soft:#C9B7B7; --muted:#8A7576;
    --accent:#FF5A5F; --accent-hover:#FF7276; --accent-ink:#1E0A0A; --accent-soft:#4A2224;
    --success:#7BC98F; --success-soft:#20321F; --success-ink:#C4E8C9;
    --warning:#E0B15C; --warning-soft:#3A2E15; --warning-ink:#F2D5A0;
    --danger:#E58A8A; --danger-hover:#EDA0A0; --danger-soft:#3E2323; --danger-ink:#F5CFCF;
    --shadow-s:0 1px 2px rgba(0,0,0,.5); --shadow-m:0 4px 18px rgba(0,0,0,.4); --shadow-l:0 16px 48px rgba(0,0,0,.55);
    color-scheme: dark;
  }
}
:root[data-theme="dark"]{
  --bg:#181213; --bg-alt:#1F1717; --surface:#231A1B; --surface-2:#291F20;
  --border:#3A2C2D; --border-strong:#4A3838;
  --ink:#F5EEEE; --ink-soft:#C9B7B7; --muted:#8A7576;
  --accent:#FF5A5F; --accent-hover:#FF7276; --accent-ink:#1E0A0A; --accent-soft:#4A2224;
  --success:#7BC98F; --success-soft:#20321F; --success-ink:#C4E8C9;
  --warning:#E0B15C; --warning-soft:#3A2E15; --warning-ink:#F2D5A0;
  --danger:#E58A8A; --danger-hover:#EDA0A0; --danger-soft:#3E2323; --danger-ink:#F5CFCF;
  --shadow-s:0 1px 2px rgba(0,0,0,.5); --shadow-m:0 4px 18px rgba(0,0,0,.4); --shadow-l:0 16px 48px rgba(0,0,0,.55);
  color-scheme: dark;
}
:root[data-theme="light"]{
  --bg:#FFFFFF; --bg-alt:#F6F3F3; --surface:#FFFFFF; --surface-2:#F7F3F3;
  --border:#E6DDDD; --border-strong:#D4C6C6;
  --ink:#1E1516; --ink-soft:#5C4849; --muted:#8F7A7B;
  --accent:#D2232A; --accent-hover:#AD1B21; --accent-ink:#FFFFFF; --accent-soft:#FBE1E2;
  --success:#2E7D46; --success-soft:#E3F1E5; --success-ink:#1B4A28;
  --warning:#96660A; --warning-soft:#F6EAD3; --warning-ink:#5C3E06;
  --danger:#8C2C2C; --danger-hover:#742323; --danger-soft:#F3E0E0; --danger-ink:#6B1F1F;
  --shadow-s:0 1px 2px rgba(30,21,22,.08); --shadow-m:0 4px 16px rgba(30,21,22,.10); --shadow-l:0 12px 40px rgba(30,21,22,.20);
  color-scheme: light;
}

*,*::before,*::after{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0; background:var(--bg); color:var(--ink);
  font-family:var(--font-ui); font-size:15px; line-height:1.45;
  -webkit-font-smoothing:antialiased;
}
h1,h2,h3,h4{ margin:0; text-wrap:balance; letter-spacing:-0.01em; }
p{ margin:0; }
button{ font-family:inherit; }
input,select,textarea{ font-family:inherit; font-size:15px; }
::selection{ background:var(--accent-soft); }
.num{ font-family:var(--font-mono); font-variant-numeric:tabular-nums; }
svg{ width:1em; height:1em; display:inline-block; vertical-align:-0.15em; flex:none; }

:focus-visible{ outline:2px solid var(--accent); outline-offset:2px; border-radius:4px; }

@media (prefers-reduced-motion: reduce){
  *{ animation-duration:0.001ms !important; transition-duration:0.001ms !important; }
}

/* ---------- Login page ---------- */
.login-wrap{ min-height:100vh; display:flex; align-items:center; justify-content:center; padding:20px; background:var(--bg-alt); }
.login-card{ width:100%; max-width:380px; background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-l); box-shadow:var(--shadow-m); padding:32px 28px; }
.login-brand{ display:flex; align-items:center; gap:12px; margin-bottom:24px; }
.login-title{ font-size:20px; font-weight:800; }
.login-sub{ color:var(--muted); font-size:13px; margin-top:2px; }
.login-error{ background:var(--danger-soft); color:var(--danger-ink); border-radius:var(--radius-s); padding:11px 14px; font-size:13.5px; font-weight:600; margin-bottom:14px; display:none; }
.login-error.show{ display:block; }
.login-hint{ margin-top:18px; font-size:12px; color:var(--muted); text-align:center; }

/* ---------- App shell ---------- */
#app{ min-height:100%; display:flex; }

.sidebar{
  width:224px; flex:none; background:var(--surface); border-right:1px solid var(--border);
  display:flex; flex-direction:column; padding:22px 16px; gap:22px; position:sticky; top:0; height:100vh;
}
.brand{ display:flex; align-items:center; gap:10px; padding:0 8px; }
.brand-mark{
  width:34px; height:34px; border-radius:9px; background:var(--accent); color:var(--accent-ink);
  display:flex; align-items:center; justify-content:center; font-weight:800; font-size:15px; flex:none;
}
.brand-name{ font-weight:800; font-size:16.5px; letter-spacing:-0.01em; }
.brand-sub{ font-size:11.5px; color:var(--muted); margin-top:-2px; }

.nav{ display:flex; flex-direction:column; gap:4px; }
.nav-btn{
  display:flex; align-items:center; gap:12px; padding:11px 12px; border-radius:var(--radius-s);
  border:none; background:transparent; color:var(--ink-soft); cursor:pointer; text-align:left;
  font-size:14.5px; font-weight:600; position:relative;
}
.nav-btn:hover{ background:var(--surface-2); color:var(--ink); }
.nav-btn.active{ background:var(--accent-soft); color:var(--accent); }
.nav-btn svg{ width:19px; height:19px; flex:none; }
.nav-badge{
  position:absolute; right:10px; top:8px; background:var(--danger); color:#fff; font-size:10.5px;
  font-weight:700; border-radius:999px; min-width:16px; height:16px; padding:0 4px; display:flex;
  align-items:center; justify-content:center; font-family:var(--font-mono);
}
.sidebar-foot{ margin-top:auto; display:flex; flex-direction:column; gap:10px; }
.user-badge{ display:flex; align-items:center; gap:10px; padding:9px 10px; border-radius:var(--radius-s); background:var(--surface-2); }
.user-avatar{ width:32px; height:32px; border-radius:999px; background:var(--accent-soft); color:var(--accent); display:flex; align-items:center; justify-content:center; font-weight:800; font-size:13px; flex:none; }
.user-name{ font-size:13px; font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.role-pill{ display:inline-block; font-size:10.5px; font-weight:700; text-transform:uppercase; letter-spacing:.03em; padding:1px 7px; border-radius:999px; margin-top:1px; }
.role-pill.admin{ background:var(--accent-soft); color:var(--accent); }
.role-pill.user{ background:var(--surface-2); color:var(--ink-soft); border:1px solid var(--border-strong); }
.ghost-link{
  background:none; border:none; color:var(--muted); font-size:12.5px; cursor:pointer; text-align:left;
  padding:6px 8px; border-radius:6px;
}
.ghost-link:hover{ background:var(--surface-2); color:var(--ink-soft); }

.main{ flex:1; min-width:0; display:flex; flex-direction:column; }
.topbar{
  display:none; align-items:center; justify-content:space-between; padding:14px 16px;
  background:var(--surface); border-bottom:1px solid var(--border); position:sticky; top:0; z-index:20;
}
.topbar-title{ font-weight:800; font-size:17px; }
.content{ flex:1; padding:26px 30px 100px; max-width:1180px; width:100%; margin:0 auto; }

.tabbar{
  display:none; position:fixed; left:0; right:0; bottom:0; z-index:30; background:var(--surface);
  border-top:1px solid var(--border); padding:6px 6px calc(6px + env(safe-area-inset-bottom));
  gap:2px;
}
.tabbar-btn{
  flex:1; display:flex; flex-direction:column; align-items:center; gap:3px; padding:8px 4px 7px;
  background:none; border:none; color:var(--muted); font-size:11.5px; font-weight:700; border-radius:10px;
  position:relative;
}
.tabbar-btn svg{ width:22px; height:22px; }
.tabbar-btn.active{ color:var(--accent); }
.tabbar-btn .nav-badge{ top:2px; right:22%; }

@media (max-width:860px){
  .sidebar{ display:none; }
  .topbar{ display:flex; }
  .tabbar{ display:flex; }
  .content{ padding:18px 14px 90px; }
}

/* ---------- Generic bits ---------- */
.section-head{ display:flex; align-items:flex-end; justify-content:space-between; gap:14px; margin-bottom:18px; flex-wrap:wrap; }
.section-head h1{ font-size:23px; }
.section-head .hint{ color:var(--muted); font-size:13px; margin-top:3px; }
.row{ display:flex; align-items:center; gap:10px; }
.spacer{ flex:1; }

.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px; border:1px solid transparent;
  border-radius:var(--radius-s); padding:11px 18px; font-size:14.5px; font-weight:700; cursor:pointer;
  min-height:44px; white-space:nowrap; transition:background .12s,border-color .12s,transform .05s;
}
.btn:active{ transform:scale(.98); }
.btn-primary{ background:var(--accent); color:var(--accent-ink); }
.btn-primary:hover{ background:var(--accent-hover); }
.btn-primary:disabled{ background:var(--border-strong); color:var(--muted); cursor:not-allowed; transform:none; }
.btn-secondary{ background:var(--surface); color:var(--ink); border-color:var(--border-strong); }
.btn-secondary:hover{ background:var(--surface-2); }
.btn-danger{ background:var(--danger); color:#fff; }
.btn-danger:hover{ background:var(--danger-hover); }
.btn-ghost{ background:none; color:var(--ink-soft); border-color:transparent; }
.btn-ghost:hover{ background:var(--surface-2); }
.btn-sm{ padding:7px 12px; min-height:34px; font-size:13px; border-radius:8px; }
.btn-icon{ padding:0; width:44px; min-height:44px; }
.btn-block{ width:100%; }
.btn[disabled]{ opacity:.6; cursor:not-allowed; }

.input, .select, .textarea{
  width:100%; padding:10px 12px; border-radius:var(--radius-s); border:1px solid var(--border-strong);
  background:var(--surface); color:var(--ink); min-height:42px;
}
.textarea{ min-height:64px; resize:vertical; }
.input::placeholder{ color:var(--muted); }
.field{ display:flex; flex-direction:column; gap:6px; }
.field label{ font-size:12.5px; font-weight:700; color:var(--ink-soft); text-transform:uppercase; letter-spacing:.03em; }
.field-row{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }

.card{ background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-m); }
.search-wrap{ position:relative; max-width:340px; width:100%; }
.search-wrap svg{ position:absolute; left:12px; top:50%; transform:translateY(-50%); width:16px; height:16px; color:var(--muted); }
.search-wrap input{ padding-left:36px; }

.chip{ display:inline-flex; align-items:center; gap:5px; padding:3px 9px; border-radius:999px; font-size:12px; font-weight:700; font-family:var(--font-mono); }
.chip-ok{ background:var(--success-soft); color:var(--success-ink); }
.chip-low{ background:var(--warning-soft); color:var(--warning-ink); }
.chip-out{ background:var(--danger-soft); color:var(--danger-ink); }
.chip-neutral{ background:var(--surface-2); color:var(--ink-soft); }
.chip-role{ font-family:var(--font-ui); }

.empty{ text-align:center; padding:50px 20px; color:var(--muted); }
.empty svg{ width:38px; height:38px; margin-bottom:10px; opacity:.6; }

.loading-row{ display:flex; align-items:center; justify-content:center; padding:40px; color:var(--muted); gap:10px; font-size:13.5px; }
.spinner{ width:18px; height:18px; border-radius:999px; border:2px solid var(--border-strong); border-top-color:var(--accent); animation:spin .7s linear infinite; }
@keyframes spin{ to{ transform:rotate(360deg); } }

/* ---------- Toast ---------- */
#toasts{ position:fixed; left:50%; bottom:22px; transform:translateX(-50%); z-index:200; display:flex; flex-direction:column; gap:8px; align-items:center; width:calc(100% - 32px); max-width:420px; }
@media (max-width:860px){ #toasts{ bottom:78px; } }
.toast{
  background:var(--ink); color:var(--bg); padding:12px 18px; border-radius:999px; font-size:13.5px; font-weight:600;
  box-shadow:var(--shadow-l); display:flex; align-items:center; gap:8px; animation:toastIn .18s ease-out;
}
.toast svg{ width:16px; height:16px; flex:none; }
.toast.danger{ background:var(--danger); color:#fff; }
@keyframes toastIn{ from{ opacity:0; transform:translateY(8px);} to{ opacity:1; transform:translateY(0);} }

/* ---------- Modal ---------- */
.modal-overlay{
  position:fixed; inset:0; background:rgba(15,17,19,.5); z-index:100; display:flex; align-items:center;
  justify-content:center; padding:20px; backdrop-filter:blur(1px);
}
.modal{
  background:var(--surface); border-radius:var(--radius-l); box-shadow:var(--shadow-l); width:100%; max-width:520px;
  max-height:88vh; display:flex; flex-direction:column; animation:modalIn .16s ease-out;
}
@keyframes modalIn{ from{ opacity:0; transform:translateY(10px) scale(.98);} to{ opacity:1; transform:translateY(0) scale(1);} }
.modal-head{ display:flex; align-items:center; justify-content:space-between; padding:18px 20px; border-bottom:1px solid var(--border); flex:none; }
.modal-head h2{ font-size:17px; }
.modal-body{ padding:20px; overflow-y:auto; display:flex; flex-direction:column; gap:16px; }
.modal-foot{ padding:16px 20px; border-top:1px solid var(--border); display:flex; justify-content:flex-end; gap:10px; flex:none; }
.modal-sm .modal-body{ gap:12px; }
.modal-close{ background:none; border:none; color:var(--muted); cursor:pointer; width:32px; height:32px; border-radius:8px; display:flex; align-items:center; justify-content:center; }
.modal-close:hover{ background:var(--surface-2); }
.form-error{ background:var(--danger-soft); color:var(--danger-ink); border-radius:8px; padding:9px 12px; font-size:13px; font-weight:600; }

/* ---------- Products view ---------- */
.product-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(210px,1fr)); gap:14px; }
.p-card{ overflow:hidden; display:flex; flex-direction:column; }
.p-thumb{ width:100%; aspect-ratio:1/1; object-fit:cover; background:var(--surface-2); display:block; }
.p-thumb-empty{ width:100%; aspect-ratio:1/1; background:var(--surface-2); display:flex; align-items:center; justify-content:center; color:var(--muted); }
.p-thumb-empty svg{ width:30px; height:30px; }
.p-body{ padding:12px 13px 13px; display:flex; flex-direction:column; gap:8px; flex:1; }
.p-name{ font-weight:700; font-size:14.5px; }
.p-desc{ font-size:12.5px; color:var(--muted); overflow:hidden; text-overflow:ellipsis; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; min-height:0; }
.p-prices{ display:flex; align-items:baseline; gap:8px; }
.p-price-sale{ font-family:var(--font-mono); font-weight:700; font-size:15px; }
.p-price-buy{ font-family:var(--font-mono); font-size:12px; color:var(--muted); }
.p-variants{ display:flex; flex-wrap:wrap; gap:5px; }
.p-actions{ display:flex; gap:8px; margin-top:auto; padding-top:4px; }
.p-actions .btn{ flex:1; }

.variant-rows{ display:flex; flex-direction:column; gap:8px; }
.variant-row{ display:flex; gap:8px; align-items:center; }
.variant-row .input{ flex:none; }
.variant-row .v-name{ width:38%; }
.variant-row .v-stock{ width:110px; }
.quick-sizes{ display:flex; flex-wrap:wrap; gap:6px; }
.quick-size-btn{ padding:6px 12px; border-radius:8px; border:1px solid var(--border-strong); background:var(--surface); color:var(--ink-soft); font-size:12.5px; font-weight:700; cursor:pointer; }
.quick-size-btn:hover{ background:var(--surface-2); }
.quick-size-btn.added{ background:var(--accent-soft); color:var(--accent); border-color:transparent; }
.img-upload{ display:flex; gap:12px; align-items:center; }
.img-preview{ width:64px; height:64px; border-radius:10px; object-fit:cover; background:var(--surface-2); flex:none; }
.img-preview-empty{ width:64px; height:64px; border-radius:10px; background:var(--surface-2); flex:none; display:flex; align-items:center; justify-content:center; color:var(--muted); }

/* ---------- Warehouse / Users / Logs tables ---------- */
.low-banner{
  display:flex; align-items:center; gap:12px; background:var(--warning-soft); color:var(--warning-ink);
  border-radius:var(--radius-m); padding:13px 16px; margin-bottom:18px; font-size:13.5px; font-weight:600;
}
.low-banner svg{ width:20px; height:20px; flex:none; }
.wh-table{ width:100%; border-collapse:collapse; }
.wh-table th{ text-align:left; font-size:11.5px; text-transform:uppercase; letter-spacing:.03em; color:var(--muted); padding:10px 14px; border-bottom:1px solid var(--border); }
.wh-table td{ padding:11px 14px; border-bottom:1px solid var(--border); font-size:14px; vertical-align:middle; }
.wh-table tr:last-child td{ border-bottom:none; }
.wh-prod{ display:flex; align-items:center; gap:10px; }
.wh-prod img, .wh-prod .p-thumb-empty{ width:34px; height:34px; border-radius:7px; flex:none; }
.wh-prod .p-thumb-empty svg{ width:16px; height:16px; }
.stock-adjust{ display:flex; align-items:center; gap:6px; justify-content:flex-end; }
@media (max-width:760px){
  .wh-table thead{ display:none; }
  .wh-table, .wh-table tbody, .wh-table tr, .wh-table td{ display:block; width:100%; }
  .wh-table tr{ padding:12px 4px; border-bottom:1px solid var(--border); }
  .wh-table td{ border:none; padding:3px 4px; }
  .stock-adjust{ justify-content:flex-start; margin-top:6px; }
}
.history-list{ display:flex; flex-direction:column; }
.history-item{ display:flex; gap:12px; padding:12px 4px; border-bottom:1px solid var(--border); align-items:center; }
.history-item:last-child{ border-bottom:none; }
.history-dot{ width:9px; height:9px; border-radius:999px; flex:none; }
.history-main{ flex:1; min-width:0; }
.history-title{ font-size:13.5px; font-weight:600; }
.history-sub{ font-size:12px; color:var(--muted); margin-top:1px; }
.history-change{ font-family:var(--font-mono); font-weight:700; font-size:14px; flex:none; }

/* ---------- POS / Sales ---------- */
.pos-layout{ display:grid; grid-template-columns:1fr 360px; gap:20px; align-items:flex-start; }
@media (max-width:980px){ .pos-layout{ grid-template-columns:1fr; } }
.pos-product{ cursor:pointer; text-align:left; border:1px solid var(--border); background:var(--surface); }
.pos-product:hover{ border-color:var(--border-strong); }
.pos-product.disabled{ opacity:.45; cursor:not-allowed; }
.pos-product .p-body{ padding:10px 11px 11px; gap:6px; }
.cart-panel{ position:sticky; top:20px; display:flex; flex-direction:column; max-height:calc(100vh - 40px); }
.cart-head{ padding:16px 18px 12px; border-bottom:1px solid var(--border); }
.cart-items{ overflow-y:auto; padding:8px 10px; flex:1; min-height:60px; }
.cart-item{ display:flex; gap:10px; align-items:center; padding:9px 8px; border-radius:10px; }
.cart-item:hover{ background:var(--surface-2); }
.cart-item-info{ flex:1; min-width:0; }
.cart-item-name{ font-size:13.5px; font-weight:600; }
.cart-item-sub{ font-size:11.5px; color:var(--muted); }
.cart-item-extra .cart-item-name::after{ content:"ręczna pozycja"; margin-left:6px; font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.03em; color:var(--accent); background:var(--accent-soft); padding:2px 6px; border-radius:5px; }
.qty-stepper{ display:flex; align-items:center; gap:0; border:1px solid var(--border-strong); border-radius:8px; overflow:hidden; flex:none; }
.qty-stepper button{ width:26px; height:26px; border:none; background:var(--surface-2); color:var(--ink); font-size:15px; cursor:pointer; line-height:1; }
.qty-stepper button:hover{ background:var(--border); }
.qty-stepper span{ width:28px; text-align:center; font-family:var(--font-mono); font-size:13px; font-weight:700; }
.cart-line-price{ width:64px; text-align:right; font-family:var(--font-mono); font-size:13px; font-weight:700; flex:none; }
.cart-remove{ background:none; border:none; color:var(--muted); cursor:pointer; width:26px; height:26px; border-radius:6px; flex:none; }
.cart-edit{ background:none; border:none; color:var(--muted); cursor:pointer; width:26px; height:26px; border-radius:6px; flex:none; }
.cart-edit:hover{ background:var(--accent-soft); color:var(--accent); }
.price-changed{ font-size:10px; font-weight:700; text-transform:uppercase; letter-spacing:.03em; color:var(--accent); background:var(--accent-soft); padding:2px 6px; border-radius:5px; margin-left:6px; }
.cart-remove:hover{ background:var(--danger-soft); color:var(--danger); }
.cart-foot{ padding:14px 18px 18px; border-top:1px solid var(--border); display:flex; flex-direction:column; gap:10px; }
.totals-row{ display:flex; justify-content:space-between; font-size:13.5px; color:var(--ink-soft); }
.totals-row.grand{ font-size:18px; font-weight:800; color:var(--ink); padding-top:6px; border-top:1px dashed var(--border); }
.totals-row .num{ font-weight:600; }
.discount-row{ display:flex; gap:8px; align-items:center; }
.seg{ display:flex; border:1px solid var(--border-strong); border-radius:8px; overflow:hidden; flex:none; }
.seg button{ padding:9px 11px; border:none; background:var(--surface); color:var(--ink-soft); font-size:12.5px; font-weight:700; cursor:pointer; }
.seg button.active{ background:var(--accent); color:var(--accent-ink); }

.fab-cart{ display:none; position:fixed; right:16px; bottom:78px; z-index:40; }
@media (max-width:980px){
  .fab-cart.show{ display:flex; }
  .cart-panel{ position:fixed; inset:0; top:auto; z-index:60; max-height:88vh; border-radius:20px 20px 0 0; box-shadow:var(--shadow-l); transform:translateY(105%); transition:transform .22s ease; }
  .cart-panel.open{ transform:translateY(0); }
  .cart-scrim{ display:none; position:fixed; inset:0; background:rgba(15,17,19,.45); z-index:55; }
  .cart-scrim.show{ display:block; }
}
.fab-cart button{ box-shadow:var(--shadow-l); border-radius:999px; padding:13px 20px; }

.sales-subnav{ display:flex; gap:6px; margin-bottom:16px; flex-wrap:wrap; }
.subnav-btn{ padding:8px 14px; border-radius:999px; border:1px solid var(--border-strong); background:var(--surface); color:var(--ink-soft); font-weight:700; font-size:13px; cursor:pointer; display:inline-flex; align-items:center; gap:6px; }
.subnav-btn.active{ background:var(--ink); color:var(--bg); border-color:var(--ink); }

.sale-card{ padding:14px 16px; margin-bottom:10px; cursor:pointer; }
.sale-card-head{ display:flex; justify-content:space-between; align-items:center; }
.sale-card-date{ font-size:12.5px; color:var(--muted); }
.sale-card-total{ font-family:var(--font-mono); font-weight:800; font-size:16px; }
.sale-detail{ margin-top:10px; padding-top:10px; border-top:1px solid var(--border); font-size:13px; display:flex; flex-direction:column; gap:5px; }
.sale-detail-row{ display:flex; justify-content:space-between; color:var(--ink-soft); }

.confirm-icon{ width:44px; height:44px; border-radius:12px; background:var(--danger-soft); color:var(--danger); display:flex; align-items:center; justify-content:center; flex:none; }
.confirm-icon svg{ width:22px; height:22px; }
