:root {
  color-scheme: light;
  font-family: Arial, Helvetica, sans-serif;
  --ink: #17201f;
  --muted: #65706d;
  --line: #dbe1df;
  --paper: #fbfcfb;
  --soft: #eef5f2;
  --green: #147a55;
  --blue: #255da8;
  --amber: #a56010;
  --red: #b51d26;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
}
.startup-loading {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  background: var(--paper);
}
.app-starting .startup-loading {
  display: flex;
}
.app-starting #app {
  visibility: hidden;
}
.startup-loading-box {
  display: grid;
  gap: 8px;
  min-width: 180px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  text-align: center;
  box-shadow: 0 12px 36px rgba(23, 32, 31, 0.12);
}
.startup-loading-box strong {
  font-size: 1.25rem;
}
.startup-loading-box span {
  color: var(--muted);
}
button, input, select {
  font: inherit;
}
button {
  border: 1px solid var(--line);
  background: white;
  border-radius: 6px;
  padding: 10px 12px;
  cursor: pointer;
}
button:hover { border-color: var(--green); }
button:disabled {
  cursor: not-allowed;
  background: #eeeeee;
  border-color: #d2d8d6;
  color: #858d8a;
}
button:disabled:hover {
  border-color: #d2d8d6;
}
button.primary {
  background: var(--green);
  border-color: var(--green);
  color: white;
  font-weight: 700;
}
button.primary:disabled {
  background: #eeeeee;
  border-color: #d2d8d6;
  color: #858d8a;
}
#deleteStockItem {
  color: var(--red);
}
button.ghost { background: transparent; }
a.ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 41px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 12px;
  color: inherit;
  text-decoration: none;
  background: transparent;
}
a.ghost:hover { border-color: var(--green); }
input, select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  background: white;
}
input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
textarea {
  width: 100%;
  min-height: 94px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  resize: vertical;
  font: inherit;
}
label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}
table {
  width: 100%;
  border-collapse: collapse;
}
th, td {
  border-bottom: 1px solid var(--line);
  padding: 10px 8px;
  text-align: left;
  vertical-align: middle;
}
tbody tr {
  cursor: pointer;
}
tbody tr.selected {
  background: #fff2a8;
  outline: 2px solid #d29b00;
  outline-offset: -2px;
}
tbody tr.frozen-account,
tbody tr.frozen-account.selected,
.picker-row.frozen-account,
.picker-row.frozen-account.active {
  background: #eeeeee;
  color: #5f6664;
}
tbody tr.frozen-account.selected,
.picker-row.frozen-account.active {
  outline: 2px solid #aeb6b3;
  outline-offset: -2px;
  border-color: #aeb6b3;
}
.picker-row.frozen-account span {
  color: #707876;
}
th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}
.stock-list-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.stock-list-title-row h3 {
  margin-right: 2px;
}
.stock-column-button {
  min-width: 42px;
  padding: 5px 8px;
  font-size: 12px;
  line-height: 1.2;
}
.stock-filter-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.stock-filter-button.active {
  border-color: var(--green);
  background: #eefaf3;
  color: var(--green);
}
.stock-filter-count {
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 999px;
  padding: 0 5px;
  background: var(--green);
  color: #fff;
  font-size: 11px;
  line-height: 1;
}
.stock-column-card {
  max-width: 760px;
}
.stock-filter-card {
  width: min(920px, calc(100vw - 24px));
  max-height: min(760px, calc(100vh - 24px));
}
.stock-filter-card header div {
  display: grid;
  gap: 3px;
}
.stock-filter-card header small {
  color: var(--muted);
  font-size: 12px;
  text-transform: none;
}
.stock-advanced-filter-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  min-height: 0;
  max-height: min(560px, calc(100vh - 190px));
  overflow: auto;
  padding: 2px;
}
.stock-filter-group {
  display: grid;
  gap: 8px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fbfdfc;
}
.stock-filter-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.stock-filter-group-head strong {
  color: var(--ink);
  font-size: 13px;
}
.stock-filter-group-head button {
  padding: 4px 7px;
  font-size: 12px;
}
.stock-filter-options {
  display: grid;
  gap: 5px;
  max-height: 132px;
  overflow: auto;
}
.stock-filter-option {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: var(--ink);
}
.stock-filter-option input {
  width: 13px;
  height: 13px;
  margin: 0;
}
.stock-filter-option span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.stock-filter-options p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.stock-filter-range {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.stock-filter-range label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 12px;
}
.stock-filter-range input {
  width: 100%;
}
.stock-column-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 8px 14px;
  padding: 4px 0;
}
.stock-column-list label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-size: 14px;
}
.stock-column-list input {
  width: auto;
}
.filter-row th {
  padding: 6px;
  background: #f6faf8;
}
.filter-row input {
  min-width: 110px;
  padding: 7px;
}
.hidden { display: none !important; }
.topbar, .screen-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 28px;
  border-bottom: 1px solid var(--line);
  background: white;
}
.topbar h1, .screen-head h2 {
  margin: 0;
  letter-spacing: 0;
}
.eyebrow {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 700;
}
.session-user {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.top-actions {
  display: grid;
  gap: 10px;
  min-width: min(760px, 100%);
}
.database-panel, .rate-panel {
  display: flex;
  align-items: end;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.connection-panel {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}
.connection-panel span,
.status-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 10px;
  background: #f8fbfa;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}
.status-badge.online,
.status-badge.synced {
  border-color: #b8d8c9;
  color: var(--green);
}
.status-badge.offline {
  border-color: #e2c0c2;
  color: var(--red);
}
.status-badge.syncing {
  border-color: #e4c489;
  color: var(--amber);
}
.status-badge.has-queue::after {
  content: attr(data-queued);
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 1px solid #fff;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--amber);
  color: #fff;
  font-size: 10px;
  line-height: 1;
  font-weight: 800;
  box-shadow: 0 1px 4px rgba(20, 24, 28, 0.18);
}
.database-panel label {
  min-width: 150px;
}
.pos-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}
.maintenance-panel {
  display: grid;
  gap: 16px;
}
.maintenance-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 12px;
}
.maintenance-grid .checkbox-field {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  min-height: 38px;
  align-items: center;
  gap: 8px;
  align-self: end;
}
.maintenance-grid .checkbox-field input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}
.transfer-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}
.transfer-options.compact {
  grid-template-columns: 1fr;
  padding: 10px;
}
.transfer-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
}
.transfer-options input {
  width: auto;
}
.database-maintenance-modal {
  gap: 14px;
}
.database-maintenance-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 10px;
}
.database-maintenance-actions button {
  min-height: 46px;
  text-align: left;
}
.database-changes-modal {
  gap: 12px;
}
.database-changes-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.database-changes-list {
  display: grid;
  gap: 8px;
  max-height: min(58vh, 560px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px;
  background: #f8fbfa;
}
.database-change-row {
  display: grid;
  grid-template-columns: 24px 1fr;
  align-items: start;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}
.database-change-row input {
  width: auto;
  margin-top: 3px;
}
.database-change-row span {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.database-change-row strong,
.database-change-row em,
.database-change-row small {
  overflow-wrap: anywhere;
}
.database-change-row em {
  color: var(--ink);
  font-style: normal;
}
.database-change-row small {
  color: var(--muted);
}
.database-change-details {
  display: grid;
  gap: 4px;
  margin-top: 5px;
}
.database-change-details div {
  display: grid;
  grid-template-columns: minmax(130px, 0.8fr) minmax(120px, 1fr) minmax(120px, 1fr);
  gap: 8px;
  align-items: start;
  padding: 5px 0;
  border-top: 1px solid #edf2ef;
  font-size: 12px;
}
.database-change-details b {
  color: var(--ink);
  font-weight: 700;
}
.database-change-details span {
  color: var(--muted);
  overflow-wrap: anywhere;
}
.database-change-details span:last-child {
  color: var(--ink);
}
.database-history-panel {
  display: grid;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.database-history-panel h4 {
  margin: 0;
}
.database-history-list {
  max-height: 340px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}
.database-history-row {
  display: grid;
  grid-template-columns: minmax(150px, 190px) minmax(130px, 170px) 1fr minmax(90px, 120px);
  gap: 10px;
  padding: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.database-history-row:last-child {
  border-bottom: 0;
}
.database-history-row strong {
  color: var(--ink);
}
.database-history-row span {
  color: var(--muted);
}
.home-grid {
  min-height: calc(100vh - 86px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  padding: 28px;
}
.module-tile {
  min-height: 320px;
  padding: 26px;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: white;
  border: 0;
  position: relative;
  overflow: hidden;
  background-position: center;
  background-size: cover;
  box-shadow: inset 0 -170px 120px rgba(0, 0, 0, 0.66);
  isolation: isolate;
}
.module-tile::before,
.pos-menu-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.68));
  transition: opacity .18s ease;
}
.module-tile:hover::before,
.pos-menu-tile:hover::before {
  opacity: .82;
}
.module-tile span {
  font-size: 42px;
  font-weight: 800;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.52);
}
.module-tile small {
  font-size: 17px;
  line-height: 1.45;
  max-width: 330px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}
.module-tile.pos { background-image: url("assets/menu-pos.svg"); }
.module-tile.erp { background-image: url("assets/menu-erp.svg"); }
.module-tile.store {
  background-image: url("assets/menu-store.svg");
  color: #07120f;
  box-shadow: inset 0 -170px 120px rgba(255, 255, 255, 0.8);
}
.module-tile.store::before {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.82));
}
.module-tile.store span,
.module-tile.store small {
  text-shadow: 0 2px 14px rgba(255, 255, 255, 0.78);
}
.module-tile.stock-collector-tile {
  background: linear-gradient(135deg, #155e75, #2f855a);
}
.module-tile.price-checker-tile {
  background: linear-gradient(135deg, #7c2d12, #0f766e);
}
.scanner-role .topbar {
  display: none;
}
.scanner-screen {
  min-height: 100dvh;
  background: #f6f7f3;
  color: #15201b;
}
.scanner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1rem;
  background: #ffffff;
  border-bottom: 1px solid #dce3dc;
  position: sticky;
  top: 0;
  z-index: 3;
}
.scanner-top h2 {
  margin: 0;
  font-size: 1.35rem;
}
.scanner-back {
  min-width: 3.5rem;
}
.scanner-settings {
  display: grid;
  gap: 0.85rem;
  padding: 1rem;
  background: #eef4ef;
  border-bottom: 1px solid #d4dfd7;
}
.scanner-settings label,
.stock-collector-entry label {
  display: grid;
  gap: 0.35rem;
  font-weight: 800;
}
.scanner-camera-wrap {
  position: relative;
  min-height: 34vh;
  background: #111;
  overflow: hidden;
}
.scanner-video {
  width: 100%;
  min-height: 34vh;
  object-fit: cover;
  display: block;
}
.scanner-status {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  padding: 0.65rem 0.8rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  font-weight: 800;
}
.scanner-manual,
.price-checker-input,
.stock-collector-entry {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.65rem;
  padding: 1rem;
  background: #ffffff;
}
.price-checker-input {
  grid-template-columns: 1fr;
}
.scanner-manual input,
.price-checker-input input,
.stock-collector-entry input {
  font-size: 1.1rem;
  min-height: 3rem;
}
.scanner-product-card {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: start;
  gap: 0.85rem;
  padding: 1rem;
  background: #ffffff;
  border-top: 1px solid #e1e6e0;
  border-bottom: 1px solid #e1e6e0;
}
.scanner-product-media {
  width: 96px;
}
.scanner-product-media img,
.scanner-image-placeholder {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  border-radius: 8px;
  background: #edf1ed;
}
.scanner-image-placeholder {
  display: grid;
  place-items: center;
  font-size: 2.5rem;
  font-weight: 900;
  color: #52615a;
}
.scanner-detail-list {
  display: grid;
  gap: 0.45rem;
}
.scanner-detail-row {
  display: grid;
  gap: 0.15rem;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  background: #f2f5f0;
}
.scanner-detail-row span {
  display: block;
  font-size: 0.72rem;
  font-weight: 900;
  color: #657269;
  text-transform: uppercase;
}
.scanner-detail-row strong {
  display: block;
  font-size: 1rem;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.scanner-empty,
.price-checker-idle {
  grid-column: 1 / -1;
  min-height: 10rem;
  display: grid;
  place-items: center;
  text-align: center;
  font-weight: 900;
  color: #52615a;
}
.scanner-empty.error,
.price-checker-idle.error {
  color: #b42318;
}
.stock-collector-list {
  padding: 1rem;
}
.stock-collector-list-head,
.stock-collector-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.stock-collector-list-head {
  padding-bottom: 0.65rem;
  border-bottom: 1px solid #dce3dc;
}
.stock-collector-line {
  padding: 0.8rem 0;
  border-bottom: 1px solid #e5e9e4;
}
.stock-collector-line div {
  display: grid;
  gap: 0.15rem;
}
.stock-collector-line span {
  color: #657269;
  font-size: 0.82rem;
}
.stock-collector-line b {
  font-size: 1.45rem;
}
.price-checker-screen {
  background: #0e1713;
  color: #ffffff;
}
.price-checker-top,
.price-checker-input {
  background: #101d18;
  border-color: #294138;
}
.price-checker-top .ghost {
  color: #ffffff;
}
.price-checker-result {
  min-height: calc(100dvh - 9rem);
  display: grid;
}
.price-checker-result .scanner-product-card {
  grid-template-columns: 120px minmax(0, 1fr);
  align-items: start;
  background: #0e1713;
  color: #ffffff;
  border: 0;
  padding: clamp(1rem, 4vw, 3rem);
}
.price-checker-result .scanner-product-media {
  width: 120px;
}
.price-checker-result .scanner-detail-row {
  background: #172720;
  border: 1px solid #294138;
}
.price-checker-result .scanner-detail-row span {
  color: #a8beb2;
}
.price-checker-result .scanner-detail-row strong {
  font-size: clamp(1.25rem, 3vw, 2.4rem);
}
.price-checker-idle {
  min-height: 100%;
  font-size: clamp(3rem, 13vw, 9rem);
  color: #d7e4dc;
}
.stock-collector-import-preview {
  grid-column: 1 / -1;
  max-height: 45vh;
  overflow: auto;
}
@media (max-width: 720px) {
  .scanner-product-card {
    grid-template-columns: 82px minmax(0, 1fr);
  }
  .scanner-product-media {
    width: 82px;
  }
  .price-checker-result .scanner-product-card {
    grid-template-columns: 96px minmax(0, 1fr);
  }
  .price-checker-result .scanner-product-media {
    width: 96px;
  }
}
.screen { min-height: 100vh; }
.pos-layout {
  display: grid;
  grid-template-columns: 320px minmax(480px, 1fr) 320px;
  gap: 16px;
  padding: 16px;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}
.panel h3 { margin: 0 0 12px; }
.input-row, .invoice-toolbar, .checkout, .control-band, .subnav {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.pos-price-mode {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.pos-price-mode .switch {
  min-height: 30px;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}
.control-band #newAccount,
.control-band #editAccount,
.control-band #freezeAccount,
.control-band #deleteAccount {
  background: #ffe2bd;
  border-color: #f3b465;
  color: #5d3510;
  font-weight: 700;
}
.control-band [data-erp-transaction="sales"],
.control-band [data-erp-transaction="returnSales"],
.control-band [data-erp-transaction="purchase"],
.control-band [data-erp-transaction="returnPurchase"],
.control-band #adjustStockIn,
.control-band #adjustStockOut {
  background: #d9efff;
  border-color: #91c8ed;
  color: #174b75;
  font-weight: 700;
}
.control-band [data-erp-transaction="pay"],
.control-band [data-erp-transaction="receipt"],
.control-band [data-erp-transaction="debitNote"],
.control-band [data-erp-transaction="creditNote"] {
  background: #fff4b8;
  border-color: #e6ca55;
  color: #625111;
  font-weight: 700;
}
.control-band #deleteAccount,
.control-band [data-erp-transaction="returnSales"],
.control-band [data-erp-transaction="returnPurchase"],
.control-band #adjustStockOut {
  color: var(--red);
}
.input-row input { flex: 1; }
.search-results, .invoice-list, #itemStatement {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}
.old-invoice-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 240px));
  gap: 0;
  margin: 14px 0 10px;
}
.old-invoice-tab {
  min-height: 58px;
  border-radius: 0;
  background: #fff;
  color: #0f181c;
  font-weight: 800;
  text-align: left;
}
.old-invoice-tab.active {
  background: #f7fbff;
  box-shadow: inset 0 0 0 999px rgba(42, 128, 96, 0.08);
}
.invoice-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(140px, auto) auto;
  gap: 8px;
  margin-bottom: 8px;
}
.close-summary-line {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f6faf8;
  font-weight: 800;
}
.result-row, .invoice-row, .statement-row {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  background: var(--soft);
}
.openable-row {
  cursor: zoom-in;
}
.openable-row:hover {
  outline: 2px solid rgba(42, 128, 96, 0.28);
  outline-offset: -2px;
}
.statement-context-menu {
  position: fixed;
  z-index: 1000;
  display: grid;
  min-width: 238px;
  padding: 8px;
  border: 1px solid #b7c2ca;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(17, 32, 31, 0.2);
}
.statement-context-menu.hidden {
  display: none;
}
.statement-context-menu button {
  justify-content: flex-start;
  min-height: 36px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  text-align: left;
}
.statement-context-menu button:hover:not(:disabled) {
  background: #e6f3ee;
}
.statement-context-menu button:disabled {
  color: #9aa4ac;
  cursor: not-allowed;
}
.result-row button, .invoice-row button { margin-top: 8px; }
.old-invoice-version-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.scan-status-icon {
  display: inline-grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  font-weight: 900;
  font-size: 36px;
  line-height: 1;
  opacity: 0;
  flex: 0 0 auto;
  border: 3px solid transparent;
  transform: scale(0.78);
  transition: opacity 120ms ease, transform 120ms ease, box-shadow 120ms ease;
}
.scan-status-icon.show {
  opacity: 1;
  transform: scale(1);
  animation: scanStatusPulse 650ms ease 2;
}
.scan-status-icon.success {
  background: #d9fbe8;
  border-color: #12a657;
  color: #08753a;
  box-shadow: 0 0 0 5px rgba(18, 166, 87, 0.18), 0 12px 28px rgba(8, 117, 58, 0.26);
}
.scan-status-icon.error {
  background: #ffe0dc;
  border-color: #e12d1f;
  color: #b31910;
  box-shadow: 0 0 0 6px rgba(225, 45, 31, 0.22), 0 12px 30px rgba(179, 25, 16, 0.32);
}
.erp-save-feedback-dialog {
  width: min(600px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  max-height: calc(100vh - 48px);
  margin: 8vh auto auto;
  border: 0;
  padding: 0;
  background: transparent;
  overflow-x: hidden;
  overflow-y: visible;
}
.erp-save-feedback-modal {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  max-height: calc(100vh - 64px);
  align-items: center;
  text-align: center;
  gap: 16px;
  padding: 28px;
  background: #ffffff;
  color: #101820;
  border: 1px solid rgba(16, 24, 32, 0.14);
  border-radius: 10px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  overflow-x: hidden;
  overflow-y: auto;
}
.erp-save-feedback-modal strong {
  max-width: 100%;
  font-size: 24px;
  line-height: 1.25;
  color: #101820;
  overflow-wrap: anywhere;
}
.erp-save-feedback-reason {
  box-sizing: border-box;
  width: 100%;
  margin: -4px 0 0;
  padding: 12px 14px;
  border: 1px solid #f0b6ad;
  border-radius: 8px;
  background: #fff6f4;
  color: #4d1510;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
}
.erp-save-feedback-icon {
  display: inline-grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  font-size: 44px;
  font-weight: 900;
  line-height: 1;
  animation: scanStatusPulse 650ms ease 2;
}
.erp-save-feedback-icon.success {
  background: #d9fbe8;
  border: 4px solid #12a657;
  color: #08753a;
  box-shadow: 0 0 0 7px rgba(18, 166, 87, 0.18), 0 16px 36px rgba(8, 117, 58, 0.24);
}
.erp-save-feedback-icon.error {
  background: #ffe0dc;
  border: 4px solid #e12d1f;
  color: #b31910;
  box-shadow: 0 0 0 8px rgba(225, 45, 31, 0.22), 0 16px 38px rgba(179, 25, 16, 0.3);
}
.erp-save-feedback-icon.loading {
  border: 5px solid #dbe1df;
  border-top-color: #147a55;
  animation: saveFeedbackSpin 850ms linear infinite;
}
.erp-save-feedback-dialog.loading .erp-save-feedback-modal {
  border-top: 6px solid #147a55;
}
.erp-save-feedback-dialog.success .erp-save-feedback-modal {
  border-top: 6px solid #12a657;
}
.erp-save-feedback-dialog.error .erp-save-feedback-modal {
  border-top: 6px solid #e12d1f;
}
@keyframes scanStatusPulse {
  0%, 100% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.16);
  }
}
@keyframes saveFeedbackSpin {
  to {
    transform: rotate(360deg);
  }
}
.tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.tabs button.active, .subnav button.active, .subnav .erp-menu.active > .erp-menu-button, .account-types button.active {
  border-color: var(--green);
  background: var(--soft);
  color: var(--green);
  font-weight: 700;
}
.item-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.item-menu button {
  min-height: 74px;
  text-align: left;
}
.item-menu .menu-item-card {
  align-content: space-between;
  gap: 8px;
  min-height: 96px;
  overflow: hidden;
  padding: 10px 12px;
}
.item-menu .menu-item-card strong {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-height: 1.15;
  max-width: 100%;
  overflow: hidden;
  overflow-wrap: anywhere;
}
.item-menu .menu-item-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}
.item-menu .menu-item-meta span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  min-width: 0;
  overflow-wrap: anywhere;
}
.item-menu .menu-item-meta span:last-child {
  text-align: right;
}
.pos-menu-panel {
  min-height: calc(100vh - 96px);
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 16px;
  padding: 16px;
}
.pos-menu-tile {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: left;
  position: relative;
  overflow: hidden;
  background: white;
  background-position: center;
  background-size: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: white;
  box-shadow: inset 0 -130px 100px rgba(0, 0, 0, 0.7);
  isolation: isolate;
}
.pos-menu-tile strong {
  font-size: 28px;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.58);
}
.pos-menu-tile span {
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.45;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
}
.pos-menu-sales { background-image: url("assets/pos-sales.svg"); }
.pos-menu-invoices { background-image: url("assets/pos-old-invoices.svg"); }
.pos-menu-settings { background-image: url("assets/pos-settings.svg"); }
.pos-menu-logout { background-image: url("assets/pos-logout.svg"); }
.pos-section-panel {
  margin: 16px;
}
.section-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.section-title-row h3 {
  margin: 0;
}
.invoice-sections, .settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 14px;
}
.pos-section-panel .invoice-sections {
  grid-template-columns: 1fr;
}
.settings-grid {
  grid-template-columns: repeat(2, minmax(220px, 1fr)) auto;
  align-items: end;
}
.pos-settings-grid {
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  align-items: start;
}
.settings-group {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
}
.settings-group h4 {
  margin: 0 0 2px;
  color: var(--ink);
  font-size: 15px;
}
.settings-group label {
  display: grid;
  gap: 6px;
  min-height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
}
.settings-group label:has(input[type="checkbox"]) {
  grid-template-columns: 18px 1fr;
  align-items: center;
  gap: 8px;
  color: var(--ink);
}
.settings-group input,
.settings-group select {
  width: 100%;
}
.qty-settings-group {
  max-width: 240px;
}
.pos-settings-actions {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
}
.pos-settings-actions button {
  min-width: 220px;
}
.settings-save-status {
  min-height: 24px;
  font-weight: 800;
  opacity: 0;
  transition: opacity 160ms ease;
}
.settings-save-status.show {
  opacity: 1;
}
.settings-save-status.success {
  color: var(--green);
}
.settings-save-status.error {
  color: #c42f24;
}
.printer-setting {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}
.printer-setting strong {
  color: var(--ink);
  font-size: 14px;
}
.printer-setting span {
  min-height: 40px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--soft);
  padding: 10px;
}
.wide-action {
  width: 100%;
  margin-top: 8px;
}
.status-note {
  margin: 8px 0 14px;
  color: var(--green);
  font-weight: 700;
}
.picker-dialog {
  width: min(860px, calc(100vw - 24px));
}
#reportStockPickerDialog {
  width: min(1220px, calc(100vw - 24px));
}
#reportStockPickerDialog .modal.wide {
  width: 100%;
}
#reportStockPickerDialog .picker-list {
  max-height: min(66vh, 650px);
}
#reportStockPickerDialog .report-stock-table-wrap {
  width: 100%;
}
#reportStockPickerDialog .report-stock-picker-table {
  min-width: 1120px;
  user-select: none;
}
.picker-dialog.fullscreen-picker {
  width: calc(100vw - 24px);
  max-width: none;
}
.picker-dialog.fullscreen-picker .modal.wide {
  width: calc(100vw - 48px);
  min-height: calc(100vh - 48px);
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
}
.picker-list {
  display: grid;
  gap: 8px;
  max-height: min(58vh, 540px);
  overflow: auto;
  padding-right: 4px;
}
.fullscreen-picker .picker-list {
  max-height: none;
  align-content: start;
}
.fullscreen-picker .report-stock-table-wrap {
  max-height: none;
  height: 100%;
}
.report-stock-picker-table tbody tr.selected,
.report-stock-picker-table tbody tr.selected:nth-child(even) {
  background: #e6f3ee;
  color: var(--green);
  font-weight: 800;
}
.report-stock-picker-table .statement-col-selected {
  text-align: center;
}
#reportStockShowZeroField {
  margin-right: auto;
  color: var(--ink);
  font-weight: 700;
}
#reportStockShowZeroField input {
  width: auto;
}
.picker-row {
  display: grid;
  gap: 4px;
  width: 100%;
  text-align: left;
  background: var(--soft);
  user-select: none;
}
.fullscreen-picker .picker-row {
  grid-template-columns: minmax(120px, 0.22fr) minmax(220px, 1fr) minmax(120px, 0.25fr) minmax(120px, 0.25fr) minmax(80px, 0.16fr);
  align-items: center;
  gap: 12px;
}
.picker-row.active {
  border-color: var(--green);
  background: #e6f3ee;
  color: var(--green);
}
.picker-row span {
  color: var(--muted);
  line-height: 1.35;
}
.picker-row small {
  color: var(--muted);
  font-weight: 700;
  overflow-wrap: anywhere;
}
.checkbox-line {
  display: flex;
  align-items: center;
  gap: 8px;
}
.lookup-select-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
  align-items: center;
}
.lookup-select-field select {
  min-width: 0;
}
.lookup-select-field button {
  min-width: 38px;
  padding-inline: 10px;
}
.multi-item-print-modal {
  max-height: calc(100vh - 40px);
}
.multi-item-print-results:empty {
  display: none;
}
.multi-item-print-table-wrap {
  max-height: min(42vh, 360px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.multi-item-print-table {
  width: 100%;
  border-collapse: collapse;
}
.multi-item-print-table th,
.multi-item-print-table td {
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}
.multi-item-print-table th {
  background: var(--soft);
  color: var(--muted);
  font-size: 13px;
}
.multi-item-print-table tr:last-child td {
  border-bottom: 0;
}
.multi-item-print-table input {
  width: 82px;
}
.pos-account-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.8fr);
  gap: 14px;
}
.receipt-panel {
  display: grid;
  gap: 12px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fff;
}
.account-balance {
  margin: 0;
  color: var(--green);
  font-size: 24px;
  font-weight: 800;
}
.mini-statement {
  display: grid;
  gap: 8px;
  max-height: 230px;
  overflow: auto;
}
.popup-menu {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-height: min(58vh, 520px);
  overflow: auto;
}
.invoice-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.invoice-credit-account {
  display: block;
  margin-top: 4px;
  color: var(--green);
  font-weight: 700;
}
.credit-customer-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.credit-customer-wrap span {
  color: var(--green);
  font-weight: 700;
}
.credit-account-list {
  min-height: 280px;
}
.pos-draft-switcher {
  display: grid;
  gap: 8px;
}
.pos-draft-switcher button {
  width: 100%;
  text-align: left;
  background: var(--soft);
}
.pos-draft-switcher button.active {
  border-color: var(--green);
  background: #e6f3ee;
  color: var(--green);
  font-weight: 700;
}
.switch {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
}
.switch input { width: auto; }
.totals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.totals div {
  background: var(--soft);
  border-radius: 6px;
  padding: 12px;
}
.totals span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 4px;
}
.totals strong { font-size: 22px; }
.subnav {
  padding: 6px 16px;
  border-bottom: 1px solid var(--line);
  background: white;
}
.erp-menubar {
  align-items: stretch;
  gap: 0;
  min-height: 39px;
  border-top: 1px solid #d9edf8;
  background: #f9fbfd;
  flex-wrap: wrap;
}
.erp-menubar > button,
.erp-menu-button {
  min-height: 32px;
  padding: 6px 12px;
  border: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  color: #14202a;
}
.erp-menubar > button:hover,
.erp-menu:hover > .erp-menu-button,
.erp-menu-button:focus {
  border-color: #9ec3dc;
  background: #e6f2fb;
}
.erp-menu {
  position: relative;
  display: flex;
}
.erp-menu-dropdown {
  position: absolute;
  top: calc(100% - 1px);
  left: 0;
  z-index: 20;
  display: none;
  min-width: 190px;
  padding: 4px;
  border: 1px solid #9eb5c6;
  background: #fff;
  box-shadow: 0 12px 26px rgba(23, 32, 31, 0.18);
}

.voucher-panel .button-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.todo-panel {
  display: grid;
  gap: 14px;
}

.todo-calendar {
  display: grid;
  gap: 12px;
}

.todo-day {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  overflow: hidden;
}

.todo-day-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: #eef7fc;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}

.todo-list {
  display: grid;
}

.todo-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.todo-row:last-child {
  border-bottom: 0;
}

.todo-row.done {
  color: var(--muted);
  background: #f5f7f7;
}

.todo-row.due {
  background: #fff7d6;
}

.todo-time {
  font-weight: 700;
  color: #0b558b;
}

.todo-title {
  display: block;
  margin-bottom: 4px;
}

.todo-meta {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.todo-note {
  margin: 6px 0 0;
  white-space: pre-wrap;
}

.todo-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.todo-empty {
  padding: 16px;
  color: var(--muted);
}

.todo-card-dialog {
  width: min(720px, calc(100vw - 24px));
}

.todo-card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 18px;
}

.todo-card-grid .wide-field {
  grid-column: 1 / -1;
}

.todo-card-grid textarea {
  resize: vertical;
}

.todo-reminder-dialog {
  width: min(520px, calc(100vw - 24px));
}

.todo-reminder-content {
  display: grid;
  gap: 10px;
  padding: 18px;
  background: white;
}

.todo-reminder-content h3 {
  margin: 0;
}

.todo-reminder-content p {
  margin: 0;
  white-space: pre-wrap;
}

#voucherCodeRows tr {
  cursor: pointer;
}

#voucherCodeRows tr.selected {
  background: #fff2a8;
  outline: 2px solid #d8a600;
  outline-offset: -2px;
}

.store-voucher-field {
  display: grid;
  gap: 6px;
}

.store-voucher-field > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.store-voucher-field small {
  min-height: 18px;
  color: var(--muted);
  font-size: 12px;
}

.store-voucher-field small.error {
  color: #d00000;
  font-size: 12px;
}

.store-voucher-field small.success {
  color: #00815f;
}
.erp-menu:hover > .erp-menu-dropdown,
.erp-menu:focus-within > .erp-menu-dropdown {
  display: grid;
}
.erp-menubar:hover > .erp-menu:not(:hover) > .erp-menu-dropdown {
  display: none;
}
.erp-submenu {
  position: relative;
}
.erp-submenu-dropdown {
  position: absolute;
  top: -5px;
  left: calc(100% - 1px);
  z-index: 25;
  display: none;
  min-width: 150px;
  padding: 4px;
  border: 1px solid #9eb5c6;
  background: #fff;
  box-shadow: 0 12px 26px rgba(23, 32, 31, 0.18);
}
.erp-submenu:hover > .erp-submenu-dropdown,
.erp-submenu:focus-within > .erp-submenu-dropdown {
  display: grid;
}
.erp-submenu-button::after {
  content: ">";
  float: right;
  margin-left: 16px;
  color: #52616d;
}
.erp-menu-dropdown button {
  width: 100%;
  min-height: 30px;
  justify-content: flex-start;
  padding: 6px 10px;
  border: 0;
  border-radius: 0;
  background: white;
  color: #14202a;
  text-align: left;
}
.erp-menu-dropdown button:hover,
.erp-menu-dropdown button.active {
  background: #e6f2fb;
  color: #0b558b;
}
.file-import-input {
  display: none;
}
.erp-panel { padding: 16px; }
.control-band {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 16px;
}
.inline-date-filter {
  display: inline-grid;
  width: min(180px, 100%);
}
#journalPanel .control-band {
  align-items: end;
  flex-wrap: nowrap;
  overflow-x: auto;
}
#journalPanel .control-band > button {
  flex: 0 0 auto;
}
.journal-date-filter-row {
  display: inline-flex;
  align-items: end;
  gap: 12px;
  flex: 0 0 auto;
}
.journal-date-filter-row .inline-date-filter {
  min-width: 225px;
}
.journal-table-wrap {
  max-height: 580px;
  padding: 0;
}
.journal-by-date-table {
  min-width: 1920px;
}
.journal-by-date-table th,
.journal-by-date-table td {
  padding: 5px 7px;
  font-size: 12px;
}
.journal-by-date-table th {
  background: #b8d4ef;
  color: #0b3152;
  text-transform: none;
}
.journal-by-date-table td {
  background: #fff;
}
.journal-by-date-table td:nth-child(8),
.journal-by-date-table td:nth-child(15) {
  white-space: normal;
  min-width: 170px;
}
.journal-by-date-table td:nth-child(9),
.journal-by-date-table td:nth-child(10),
.journal-by-date-table td:nth-child(11),
.journal-by-date-table td:nth-child(12),
.journal-by-date-table td:nth-child(13),
.journal-by-date-table td:nth-child(14) {
  text-align: right;
}
.journal-lock-cell {
  text-align: center;
}
.journal-lock-cell input {
  width: 14px;
  height: 14px;
  padding: 0;
}
.journal-total-row td {
  background: #f6faf8;
  font-weight: 700;
  border-top: 2px solid var(--line);
}
.account-types {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.table-search {
  margin-bottom: 10px;
}
.two-column {
  display: grid;
  grid-template-columns: minmax(380px, 0.85fr) minmax(620px, 1.4fr);
  gap: 16px;
}
.two-column > .panel {
  min-width: 0;
  overflow-x: auto;
}
.company-panel {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}
.company-logo-preview {
  width: 180px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: var(--muted);
  overflow: hidden;
}
.company-logo-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: white;
}
.company-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 14px;
}
.company-form button {
  align-self: end;
}
.statement-panel {
  min-width: 0;
}
.statement-panel > .statement-head {
  position: sticky;
  top: 0;
  z-index: 30;
  background: #ffffff;
  padding: 10px 0 12px;
  margin-top: -10px;
}
.statement-panel > .statement-summary {
  position: sticky;
  top: 86px;
  z-index: 25;
  background: #ffffff;
  padding: 8px 0;
}
.stock-list-panel {
  overflow: hidden;
}
.stock-list-scroll {
  width: 100%;
  max-height: 520px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.erp-subtabs {
  display: flex;
  gap: 4px;
  margin: 10px 0 0;
  border-bottom: 1px solid var(--line);
}
.erp-subtabs button {
  min-height: 34px;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  background: #eef5fb;
}
.erp-subtabs button.active {
  background: white;
  border-color: var(--line);
  border-bottom-color: white;
  color: var(--green);
}
.erp-subpane {
  padding-top: 12px;
}
.statement-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 12px;
}
.statement-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}
.statement-actions input {
  width: min(280px, 100%);
}
.statement-print-dropdown {
  flex: 0 0 auto;
}
.statement-account {
  margin: -6px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.statement-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.statement-summary div {
  border: 1px solid var(--line);
  background: #f8fbfc;
  border-radius: 6px;
  padding: 8px 10px;
}
.statement-summary span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.statement-summary strong {
  display: block;
  margin-top: 3px;
  white-space: nowrap;
}
.statement-table-wrap {
  border: 1px solid var(--line);
  border-radius: 8px;
  max-height: 470px;
  overflow: auto;
}
.statement-table {
  min-width: 1260px;
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 12px;
}
.account-list-table {
  table-layout: fixed;
  border-collapse: collapse;
}
#stockListTable {
  table-layout: fixed;
  border-collapse: collapse;
}
.account-list-table th,
.account-list-table td {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-list-table .filter-row input {
  width: 100%;
  min-width: 0;
}
.statement-table th,
.statement-table td {
  border: 1px solid #c7d4dc;
  padding: 7px 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.statement-table th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: #d7e9f6;
  color: #0f3554;
}
.statement-table th.filterable-th,
.account-list-table th.filterable-th {
  padding: 4px 24px 4px 8px;
  position: sticky;
  vertical-align: middle;
}
.statement-table th.filterable-th.open,
.account-list-table th.filterable-th.open {
  z-index: 50;
  overflow: visible;
}
.statement-table th.statement-draggable-th,
.account-list-table th.statement-draggable-th {
  min-width: 54px;
  cursor: grab;
  user-select: none;
}
.statement-table th.statement-draggable-th {
  position: sticky;
  top: 0;
  z-index: 3;
}
.account-list-table th.statement-draggable-th {
  position: relative;
}
.statement-table th.statement-draggable-th.open {
  z-index: 50;
}
.statement-table th.statement-draggable-th:active,
.account-list-table th.statement-draggable-th:active {
  cursor: grabbing;
}
.statement-table th.statement-draggable-th.dragging,
.account-list-table th.statement-draggable-th.dragging {
  opacity: .55;
}
.statement-table th.statement-draggable-th.drag-over,
.account-list-table th.statement-draggable-th.drag-over {
  box-shadow: inset 3px 0 0 #0f6ca5;
}
.statement-table th.statement-draggable-th.resizing,
.account-list-table th.statement-draggable-th.resizing {
  cursor: col-resize;
}
.statement-column-resizing,
.statement-column-resizing * {
  cursor: col-resize !important;
  user-select: none !important;
}
.statement-column-resize-handle {
  position: absolute;
  top: 0;
  right: -6px;
  width: 13px;
  height: 100%;
  cursor: col-resize;
  z-index: 4;
}
.statement-column-resize-handle::after {
  content: "";
  position: absolute;
  top: 5px;
  bottom: 5px;
  left: 6px;
  width: 1px;
  background: rgba(15, 53, 84, .32);
}
.statement-column-resize-handle:hover::after,
.statement-table th.statement-draggable-th.resizing .statement-column-resize-handle::after,
.account-list-table th.statement-draggable-th.resizing .statement-column-resize-handle::after {
  background: #0f6ca5;
}
.column-filter-button {
  position: absolute;
  right: 3px;
  top: 3px;
  width: 17px;
  height: 17px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #6d8aa0;
  border-radius: 2px;
  padding: 0;
  background: #eff7fc;
  color: #0f3554;
  font-size: 10px;
  line-height: 1;
  cursor: pointer;
}
.column-filter-button.active {
  background: #0f6ca5;
  border-color: #0f6ca5;
  color: #fff;
}
.column-filter-menu {
  position: fixed;
  width: 260px;
  max-width: calc(100vw - 16px);
  max-height: min(320px, calc(100vh - 16px));
  display: flex;
  flex-direction: column;
  border: 1px solid #202b33;
  background: #fff;
  box-shadow: 0 10px 26px rgba(10, 31, 45, .24);
  color: #111;
  text-align: left;
  z-index: 1000;
}
.column-filter-actions {
  display: flex;
  gap: 4px;
  padding: 5px;
  border-bottom: 1px solid #d6dee5;
  background: #edf3f7;
  position: sticky;
  top: 0;
  z-index: 1;
}
.column-filter-actions button {
  flex: 1;
  border: 1px solid #9fb1bf;
  border-radius: 2px;
  padding: 3px 5px;
  background: #fff;
  color: #0f3554;
  font-size: 11px;
}
.column-filter-custom-summary {
  padding: 5px 7px;
  border-bottom: 1px solid #d6dee5;
  background: #fffbe8;
  color: #5b4300;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.column-filter-options {
  min-height: 0;
  flex: 1;
  overflow: auto;
  padding: 4px 0;
}
.column-filter-options label,
.column-filter-options .column-filter-option {
  display: grid !important;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: center;
  justify-content: start;
  justify-items: start;
  column-gap: 8px;
  width: 100%;
  box-sizing: border-box;
  min-height: 22px;
  padding: 2px 6px;
  font-weight: 400;
  color: #111;
  direction: ltr;
  text-align: left;
}
.column-filter-options label:hover {
  background: #dbeefa;
}
.column-filter-options input,
.column-filter-options .column-filter-option input {
  grid-column: 1;
  width: 13px;
  height: 13px;
  margin: 0;
}
.column-filter-options span,
.column-filter-options .column-filter-option-text {
  grid-column: 2;
  display: block;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
  color: #111 !important;
  opacity: 1;
  visibility: visible;
  text-align: left;
}
.column-filter-options p {
  margin: 8px;
  color: var(--muted);
  font-weight: 400;
}
.column-customize-card {
  width: 100%;
  min-width: 0;
  gap: 10px;
}
.column-customize-rules {
  display: grid;
  gap: 8px;
}
.column-customize-match {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}
.column-customize-rule {
  display: grid;
  grid-template-columns: minmax(150px, 1.05fr) minmax(0, 1fr) 34px;
  gap: 8px;
  align-items: center;
}
.column-customize-card label {
  display: grid;
  gap: 5px;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}
.column-customize-card select,
.column-customize-card input,
.column-customize-rule button {
  width: 100%;
  min-height: 34px;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 7px 9px;
  font: inherit;
}
.column-customize-rule button {
  display: inline-grid;
  place-items: center;
  padding: 0;
  font-weight: 800;
}
.statement-table .statement-col-note {
  white-space: normal;
  min-width: 220px;
}
.stock-statement-table .statement-col-transactionRef {
  white-space: normal;
  min-width: 190px;
}
.debit-row,
.statement-table .debit-row {
  background: #fff8cf;
}
.credit-row,
.statement-table .credit-row {
  background: #dcf8df;
}
.journal-entry-row,
.statement-table .journal-entry-row {
  background: #ffffff;
}
.adjust-stock-row,
.statement-table .adjust-stock-row {
  background: #ffffff;
  box-shadow: inset 4px 0 0 #111;
}
.closed-row,
.statement-table .closed-row {
  background: #ffdede;
}
.stock-statement-head {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
  padding: 10px 12px;
  background: #eef5f2;
  border: 1px solid var(--line);
  border-radius: 6px;
}
#itemStatement > .stock-statement-head {
  position: sticky;
  top: 86px;
  z-index: 25;
}
.stock-statement-head strong {
  font-size: 16px;
}
.stock-statement-head span {
  color: var(--muted);
  font-weight: 700;
}
.stock-statement-table {
  min-width: 980px;
}
.warehouse-card {
  width: min(980px, 96vw);
}
.warehouse-table-wrap {
  max-height: 62vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.warehouse-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
  font-size: 13px;
}
.warehouse-table th,
.warehouse-table td {
  border: 1px solid #c7d4dc;
  padding: 5px;
}
.warehouse-table th {
  background: #d7e9f6;
  color: #0f3554;
}
.warehouse-table input {
  width: 100%;
  box-sizing: border-box;
}
.warehouse-table input[type="checkbox"] {
  width: auto;
}
.warehouse-qty-table {
  min-width: 560px;
}
.warehouse-qty-table tfoot td {
  font-weight: 800;
  background: #f1f7fb;
}
.stock-statement-summary {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
  padding: 8px;
  background: #f1f1f1;
  border-radius: 6px;
  color: var(--muted);
  font-size: 12px;
}
.stock-statement-summary span {
  min-width: 90px;
}
.negative { color: var(--red); font-weight: 700; }
.report-grid, .store-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.control-band [data-report-section].active {
  background: #e6f3ee;
  border-color: var(--green);
  color: var(--green);
  font-weight: 800;
}
.report-dialog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  gap: 12px;
}
.simple-report {
  position: relative;
  box-sizing: border-box;
  width: 210mm;
  min-height: 0;
  padding: 18mm 15mm;
  color: #000;
  background: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
}
.simple-report-head {
  position: relative;
  min-height: 30mm;
  text-align: center;
}
.simple-report-head h1,
.simple-report-head h2,
.simple-report-head p {
  margin: 0;
}
.simple-report-head h1 {
  font-size: 16px;
  font-weight: 800;
}
.simple-report-head h2 {
  margin-top: 2mm;
  font-size: 18px;
  font-weight: 800;
}
.simple-report-note {
  margin-top: 2mm !important;
  color: #f00;
  font-size: 18px;
  font-weight: 800;
}
.simple-report-dates {
  position: absolute;
  left: 0;
  top: 14mm;
  display: grid;
  gap: 1mm;
  text-align: left;
  font-size: 9px;
}
.simple-report-rule {
  width: 82%;
  margin: 0 auto 8mm;
  border-top: 1px solid #000;
}
.simple-table-report table,
.account-balance-report table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.simple-table-report th,
.simple-table-report td,
.account-balance-report th,
.account-balance-report td {
  border: 1px solid #000;
  padding: 4mm 2mm;
  text-align: left;
  vertical-align: middle;
}
.simple-table-report th,
.account-balance-report th {
  font-weight: 400;
}
.simple-table-report tfoot td {
  color: #f00;
  font-size: 16px;
  font-weight: 800;
}
.simple-table-report tfoot td:first-child {
  text-align: right;
}
.profit-guide-report table {
  width: 86%;
  margin: 6mm auto 0;
}
.report-guide-note {
  width: 86%;
  margin: 0 auto 6mm;
  line-height: 1.35;
}
.report-guide-note h3 {
  margin: 0 0 2mm;
  font-size: 13px;
}
.report-guide-note p {
  margin: 0 0 1.5mm;
}
.sale-qty-report table {
  width: 96%;
  margin: 0 auto;
}
.account-balance-report table {
  width: 86%;
  margin: 8mm auto 0;
}
.account-balance-report th,
.account-balance-report td {
  padding: 2.5mm 3mm;
  text-align: center;
}
.cash-flow-sheet {
  font-size: 11px;
}
.cash-flow-sheet .simple-report-head {
  min-height: 26mm;
}
.cash-flow-sheet .simple-report-rule {
  margin-bottom: 11mm;
}
.cash-flow-sheet h3 {
  margin: 7mm 0 5mm;
  text-align: center;
  font-size: 14px;
}
.cash-flow-sheet table {
  border-collapse: collapse;
  table-layout: fixed;
}
.cash-flow-sheet th,
.cash-flow-sheet td {
  border: 1px solid #000;
  padding: 3mm 2mm;
  text-align: center;
  vertical-align: middle;
}
.profit-sales-table {
  width: 82%;
  margin: 0 auto 8mm;
}
.cash-flow-narrow-table {
  width: 78%;
  margin: 0 auto 9mm;
}
.cash-flow-result-amount {
  margin: 4mm 0 0;
  color: #f00;
  text-align: center;
  font-size: 34px;
  font-weight: 900;
  line-height: 1.15;
}
.cash-flow-summary {
  margin: 9mm 0 0;
  font-size: 10px;
  line-height: 1.3;
  text-align: left;
  clear: both;
}
.cash-flow-result-table {
  width: 82%;
  margin: 10mm auto 0;
}
.cash-flow-result-table td {
  padding: 2mm;
  text-align: left;
}
.cash-flow-result-table td:first-child {
  width: 46%;
}
.cash-flow-total-row td {
  font-size: 18px;
  font-weight: 900;
  text-align: center;
}
.cash-flow-total-row td:last-child {
  color: #f00;
}
.pricelist-report .simple-report-head {
  min-height: 27mm;
}
.pricelist-report,
.warehouse-qty-report {
  min-height: 297mm;
  padding-bottom: 32mm;
}
.pricelist-lines {
  width: 82%;
  margin: 0 auto;
  display: grid;
  gap: 1.5mm;
}
.pricelist-row {
  display: grid;
  grid-template-columns: minmax(36mm, 1fr) minmax(32mm, 0.9fr) minmax(28mm, 0.8fr);
  gap: 4mm;
  font-size: 14px;
  font-weight: 800;
}
.pricelist-row span {
  overflow: hidden;
  white-space: nowrap;
}
.pricelist-row span:not(:last-child)::after {
  content: " ................................";
  letter-spacing: 1px;
  font-weight: 400;
}
.pricelist-table {
  width: 88%;
  margin: 0 auto;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 10px;
}
.pricelist-table th,
.pricelist-table td {
  border: 1px solid #000;
  padding: 2mm;
  text-align: left;
  vertical-align: middle;
}
.pricelist-table th {
  font-weight: 800;
}
.pricelist-table th:nth-child(1),
.pricelist-table td:nth-child(1) {
  width: 24%;
}
.pricelist-table th:nth-child(2),
.pricelist-table td:nth-child(2) {
  width: 36%;
}
.pricelist-table th:nth-child(3),
.pricelist-table td:nth-child(3) {
  width: 10%;
  text-align: right;
}
.pricelist-table th:nth-child(4),
.pricelist-table td:nth-child(4),
.pricelist-table th:nth-child(5),
.pricelist-table td:nth-child(5) {
  width: 15%;
  text-align: right;
}
.simple-report-footer {
  position: absolute;
  left: 24mm;
  right: 24mm;
  bottom: 16mm;
  margin: 0;
  display: grid;
  gap: 1mm;
  font-size: 10px;
}
.warehouse-qty-report-head {
  min-height: 28mm;
}
.warehouse-qty-report-warehouse {
  margin-top: 7mm;
  text-align: center;
  font-size: 10px;
}
.warehouse-qty-report-table {
  width: 82%;
  margin: 0 auto;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 10px;
}
.warehouse-qty-report-table th,
.warehouse-qty-report-table td {
  border: 1px solid #000;
  padding: 2mm;
  text-align: left;
  vertical-align: middle;
}
.warehouse-qty-report-table th {
  font-weight: 400;
}
.warehouse-qty-report-table th:first-child,
.warehouse-qty-report-table td:first-child {
  width: 34%;
}
.warehouse-qty-report-table th:last-child,
.warehouse-qty-report-table td:last-child {
  width: 34%;
}
.warehouse-qty-category-group {
  width: 82%;
  margin: 0 auto 7mm;
  break-inside: avoid;
  page-break-inside: avoid;
}
.warehouse-qty-category-group h3 {
  margin: 0 0 2mm;
  padding: 1.5mm 2mm;
  border: 1px solid #000;
  background: #f1f1f1;
  font-size: 12px;
  font-weight: 800;
}
.warehouse-qty-category-group .warehouse-qty-report-table {
  width: 100%;
}
.warehouse-qty-empty {
  width: 82%;
  margin: 0 auto;
  text-align: center;
}
.store-grid { padding: 16px; }
.store-settings-panel {
  margin: 16px;
}
.store-settings-open .store-settings-panel {
  margin: 0;
  min-height: calc(100vh - 116px);
  border-radius: 0;
  border-left: 0;
  border-right: 0;
}
.store-settings-open .store-screen-head {
  display: none;
}
.store-settings-database {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.store-admin-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: calc(100vh - 98px);
}
.store-admin-shell.menu-collapsed {
  grid-template-columns: minmax(0, 1fr);
}
.store-admin-shell.menu-collapsed .store-admin-menu {
  display: none;
}
.store-admin-menu {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 16px;
  background: #eef4f1;
  border-right: 1px solid var(--line);
}
.store-admin-menu button {
  text-align: left;
  background: transparent;
}
.store-admin-menu button.active {
  background: white;
  border-color: var(--green);
  font-weight: 800;
}
.store-admin-menu button.has-notice {
  border-color: #e7b64a;
  background: #fff8df;
}
.store-order-badge {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  margin-left: 6px;
  border-radius: 999px;
  background: #e24b45;
  color: white;
  font-size: 12px;
  font-weight: 900;
}
.store-admin-content {
  min-width: 0;
}
.store-admin-toolbar,
.storefront-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: white;
  border-bottom: 1px solid var(--line);
}
.hamburger-button {
  display: inline-grid;
  gap: 4px;
  width: 38px;
  min-width: 38px;
  height: 34px;
  padding: 8px;
}
.hamburger-button span {
  display: block;
  height: 2px;
  background: currentColor;
}
.store-admin-panel {
  padding: 16px;
}
.store-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 12px;
}
.store-metrics div,
.store-category-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  padding: 14px;
}
.store-metrics span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.store-metrics strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
}
.store-dashboard-filters {
  margin-top: 16px;
}
.store-dashboard-charts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.store-dashboard-chart {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 260px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.store-dashboard-chart header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}
.store-dashboard-chart h3,
.store-dashboard-chart p {
  margin: 0;
}
.store-dashboard-chart h3 {
  font-size: 16px;
}
.store-dashboard-chart p {
  color: var(--muted);
  font-size: 12px;
}
.store-dashboard-chart-types {
  display: inline-grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  flex: 0 0 auto;
  padding: 2px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7faf9;
}
.store-dashboard-chart-types button {
  min-width: 48px;
  padding: 6px 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font-size: 12px;
}
.store-dashboard-chart-types button.active {
  background: #277d61;
  color: white;
}
.store-dashboard-chart-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(120px, 2fr) minmax(92px, auto);
  gap: 10px;
  align-items: center;
}
.store-dashboard-chart-row strong,
.store-dashboard-chart-row small {
  display: block;
}
.store-dashboard-chart-row strong {
  overflow-wrap: anywhere;
}
.store-dashboard-chart-row small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}
.store-dashboard-chart-row b {
  text-align: right;
  white-space: nowrap;
}
.store-dashboard-bar {
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #edf1f0;
}
.store-dashboard-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #277d61, #f0b34b);
}
.store-dashboard-pie-wrap {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}
.store-dashboard-pie {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  border: 1px solid var(--line);
  box-shadow: inset 0 0 0 28px white;
}
.store-dashboard-pie-legend {
  display: grid;
  gap: 7px;
}
.store-dashboard-pie-legend-row {
  display: grid;
  grid-template-columns: 14px minmax(80px, 1fr) auto;
  gap: 8px;
  align-items: center;
}
.store-dashboard-pie-legend-row span {
  width: 14px;
  height: 14px;
  border-radius: 4px;
}
.store-dashboard-pie-legend-row strong {
  overflow-wrap: anywhere;
}
.store-dashboard-pie-legend-row small {
  color: var(--muted);
  white-space: nowrap;
}
.store-dashboard-line-wrap {
  display: grid;
  gap: 8px;
}
.store-dashboard-line {
  width: 100%;
  height: 150px;
  overflow: visible;
}
.store-dashboard-line polyline {
  fill: none;
  stroke: #277d61;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.store-dashboard-line circle {
  fill: #f0b34b;
  stroke: white;
  stroke-width: 2;
}
.store-dashboard-line text {
  fill: #263b35;
  font-size: 11px;
  text-anchor: middle;
}
.store-dashboard-line-labels {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
}
.store-dashboard-line-labels span {
  min-width: 0;
  max-width: 90px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.store-notice-metric {
  border-color: #e7b64a !important;
  background: #fff8df !important;
}
.store-category-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}
.store-admin-panel textarea {
  min-height: 120px;
}
.store-status-message-table {
  table-layout: fixed;
}
.store-status-message-table th:nth-child(1),
.store-status-message-table td:nth-child(1) {
  width: 190px;
}
.store-status-message-table th:nth-child(3),
.store-status-message-table td:nth-child(3) {
  width: 110px;
}
.store-status-message-table textarea {
  width: 100%;
  min-height: 86px;
  resize: vertical;
}
.store-status-message-table input {
  width: 100%;
}
.store-sales-filters,
.store-builder-add {
  display: flex;
  align-items: end;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.store-chart-layout {
  display: grid;
  grid-template-columns: 230px minmax(220px, 1fr);
  gap: 18px;
  align-items: center;
}
.store-pie-chart {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 1px solid var(--line);
  box-shadow: inset 0 0 0 34px white;
}
.store-chart-legend {
  display: grid;
  gap: 8px;
}
.store-chart-legend-row {
  display: grid;
  grid-template-columns: 16px minmax(90px, 1fr) auto;
  gap: 8px;
  align-items: center;
}
.store-chart-legend-row span {
  width: 16px;
  height: 16px;
  border-radius: 4px;
}
.store-builder {
  display: grid;
  gap: 14px;
}
.store-builder table {
  table-layout: fixed;
}
.store-builder th:nth-child(1),
.store-builder td:nth-child(1) {
  width: 60px;
}
.store-builder th:nth-child(2),
.store-builder td:nth-child(2) {
  width: 88px;
}
.store-builder th:nth-child(4),
.store-builder td:nth-child(4) {
  width: 116px;
}
.store-builder th:nth-child(5),
.store-builder td:nth-child(5) {
  width: 92px;
}
.store-builder-value {
  max-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.store-category-editor {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}
.store-category-editor h4,
.store-category-editor p {
  margin: 0;
}
.store-category-editor input[type="number"] {
  max-width: 90px;
}
.store-builder-add input {
  min-width: 220px;
}
.store-builder-preview {
  width: 96px;
  height: 42px;
  object-fit: contain;
  background: #eef2f0;
  border-radius: 6px;
  border: 1px solid var(--line);
}
.store-builder-pill {
  display: inline-block;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fbfa;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.store-items-table img,
.store-items-table .image span {
  width: 58px;
  height: 58px;
}
.store-items-table input {
  width: min(520px, 100%);
}
.store-stock-list {
  display: grid;
  gap: 14px;
}
.store-stock-list-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(150px, 210px) minmax(150px, 210px);
  gap: 12px;
  align-items: center;
}
.store-orders-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(3, minmax(140px, 180px)) repeat(2, minmax(130px, 160px)) repeat(3, auto);
  gap: 10px;
  align-items: end;
  margin-bottom: 10px;
}
.store-orders-toolbar label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.store-orders-toolbar button {
  min-height: 38px;
}
.store-stock-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.store-stock-table {
  min-width: 920px;
  border-collapse: collapse;
}
.store-customers-table {
  min-width: 1080px;
  border-collapse: collapse;
}
.store-stock-table th,
.store-stock-table td,
.store-customers-table th,
.store-customers-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}
.store-stock-table th,
.store-customers-table th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.store-customers-table tr.active {
  background: #eef8f3;
}
.store-customers-table small {
  color: var(--muted);
}
.store-customers-layout {
  display: grid;
  gap: 16px;
}
.store-customers-list,
.store-customer-statement {
  display: grid;
  gap: 12px;
}
.store-customer-statement {
  scroll-margin-top: 86px;
}
.store-customer-statement.focused {
  animation: storeStatementFocus 1.2s ease;
}
@keyframes storeStatementFocus {
  0%, 100% { box-shadow: none; }
  20%, 70% { box-shadow: 0 0 0 4px rgba(39, 125, 97, 0.18); }
}
.store-customer-profile-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 10px;
}
.store-customer-profile-card div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.store-customer-profile-card span,
.store-customer-profile-card strong {
  display: block;
}
.store-customer-profile-card span {
  color: var(--muted);
  font-size: 12px;
}
.store-customer-profile-card strong {
  margin-top: 4px;
  overflow-wrap: anywhere;
}
.store-wallet-admin-add {
  display: grid;
  grid-template-columns: minmax(160px, 220px) minmax(200px, 1fr) auto;
  gap: 10px;
  align-items: end;
}
.store-customer-statement-table {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.store-customer-statement-table table {
  min-width: 820px;
  border-collapse: collapse;
}
.store-customer-statement-table th,
.store-customer-statement-table td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}
.store-customer-statement-table th {
  color: var(--muted);
  font-size: 12px;
}
.store-admin-item-product {
  display: grid;
  grid-template-columns: 58px minmax(150px, 1fr);
  gap: 12px;
  align-items: center;
}
.store-admin-item-product .image {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}
.store-admin-item-product strong,
.store-admin-item-product small {
  display: block;
}
.store-admin-item-product small {
  margin-top: 4px;
  color: var(--muted);
}
.store-stock-qty {
  font-weight: 800;
}
.store-stock-qty.ok { color: #158457; }
.store-stock-qty.warn { color: #b57a18; }
.store-stock-qty.danger { color: #c43c4d; }
.store-stock-status {
  display: inline-flex;
  min-width: 92px;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
}
.store-stock-status.in {
  background: #eaf8f0;
  color: #158457;
}
.store-stock-status.low {
  background: #fff6df;
  color: #b57a18;
}
.store-stock-status.out {
  background: #fff0f2;
  color: #c43c4d;
}
.store-admin-item-card {
  width: min(820px, 94vw);
}
.store-admin-item-editor {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 18px;
}
.store-admin-item-preview {
  width: 150px;
  height: 150px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}
.store-admin-item-preview img,
.store-admin-item-preview span {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.store-admin-item-preview span {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 42px;
  font-weight: 800;
}
.store-admin-item-fields,
.store-admin-image-editor {
  display: grid;
  gap: 10px;
}
.store-admin-item-fields {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.store-admin-image-editor {
  grid-column: 1 / -1;
}
.store-admin-item-card input[readonly] {
  background: #f6f8f8;
  color: var(--muted);
}
.storefront-shell {
  position: relative;
  background: #f7f8f8;
}
body.storefront-role > #app > .topbar {
  display: none;
}
body.storefront-role #storeView {
  min-height: 100vh;
}
.storefront-toolbar {
  position: sticky;
  top: 0;
  z-index: 12;
  display: grid;
  grid-template-columns: minmax(172px, auto) minmax(0, 1fr) auto;
  min-height: 68px;
}
.storefront-toolbar h3 {
  margin: 0;
}
.store-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.storefront-logo {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  overflow: hidden;
  border-radius: 50%;
  background: #111;
  color: white;
  font-weight: 900;
}
.storefront-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.store-image-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-width: 36px;
  min-height: 36px;
  border-radius: inherit;
  background: #eef2f0;
  color: var(--green);
  font-weight: 900;
}
.store-wallet-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 112px;
  height: 42px;
  padding: 0 10px;
  border-color: #d6e3dd;
  background: white;
  color: #243b34;
}
.store-wallet-button strong {
  max-width: 92px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}
.store-wallet-icon {
  position: relative;
  display: inline-block;
  width: 22px;
  min-width: 22px;
  height: 18px;
  border: 2px solid currentColor;
  border-radius: 5px;
}
.store-wallet-icon::before {
  content: "";
  position: absolute;
  left: 3px;
  top: -6px;
  width: 14px;
  height: 8px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 5px 5px 0 0;
}
.store-wallet-icon::after {
  content: "";
  position: absolute;
  right: 3px;
  top: 6px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}
.store-wallet-icon.large {
  width: 46px;
  min-width: 46px;
  height: 36px;
}
.store-wallet-icon.large::before {
  left: 6px;
  top: -12px;
  width: 30px;
  height: 14px;
}
.store-wallet-icon.large::after {
  top: 14px;
  right: 8px;
  width: 7px;
  height: 7px;
}
.store-title-wrap {
  min-width: 0;
  text-align: center;
}
.store-title-wrap h3 {
  font-size: 24px;
  font-weight: 900;
}
.store-title-wrap .status-note {
  margin: 2px 0 0;
}
.storefront-actions {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 8px;
}
.store-currency-button {
  min-width: 58px;
  height: 42px;
  padding: 0 12px;
  border-color: var(--green);
  background: #eef7f1;
  color: var(--green);
  font-weight: 900;
}
.store-profile-button {
  position: relative;
  width: 42px;
  min-width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 50%;
  font-weight: 900;
}
.store-profile-button::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 8px;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-radius: 50%;
}
.store-profile-button::after {
  content: "";
  position: absolute;
  left: 9px;
  bottom: 8px;
  width: 22px;
  height: 13px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 14px 14px 0 0;
}
.store-profile-button.signed-in {
  border-color: var(--green);
  background: #eaf6f0;
  color: var(--green);
}
.store-cart-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  min-width: 46px;
  height: 42px;
  padding: 0;
}
.store-cart-button #storeCartCount {
  position: absolute;
  top: -7px;
  right: -6px;
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: #f0b34b;
  color: #0f181c;
  font-size: 12px;
  font-weight: 900;
}
.store-wishlist-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  min-width: 46px;
  height: 42px;
  padding: 0;
  color: var(--red);
  font-size: 20px;
  font-weight: 900;
}
.store-wishlist-button.active {
  border-color: #efb0ad;
  background: #fff0ef;
}
.store-wishlist-button #storeWishlistCount {
  position: absolute;
  top: -7px;
  right: -6px;
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 50%;
  background: var(--red);
  color: white;
  font-size: 12px;
  font-weight: 900;
}
.store-cart-icon {
  position: relative;
  width: 24px;
  height: 21px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 3px 3px 6px 6px;
}
.store-cart-icon::before {
  content: "";
  position: absolute;
  left: 4px;
  top: -8px;
  width: 12px;
  height: 10px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
}
.store-hero-carousel {
  overflow: hidden;
  padding: 14px 16px 4px;
}
.store-hero-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: 14px;
  scrollbar-width: none;
}
.store-hero-track::-webkit-scrollbar {
  display: none;
}
.store-hero-slide {
  flex: 0 0 min(680px, calc(100vw - 32px));
  position: relative;
  aspect-ratio: 16 / 5;
  overflow: hidden;
  border-radius: 8px;
  background: #0f1414;
  scroll-snap-align: start;
}
.store-hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.store-hero-slide strong {
  display: none !important;
}
.store-hero-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding-top: 8px;
}
.store-hero-dots span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #cfd8d5;
}
.store-hero-dots span.active {
  width: 20px;
  background: var(--green);
}
.store-hero-uploader {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(160px, 220px);
  gap: 10px;
  margin-bottom: 12px;
}
.store-hero-uploader label {
  display: grid;
  gap: 5px;
  font-weight: 700;
}
.store-hero-uploader span {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 12px;
}
.store-products-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 0;
}
.store-search-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 14px 16px 0;
}
.store-products-head h3,
.store-products-head p {
  margin: 0;
}
.store-page-blocks {
  display: grid;
  gap: 10px;
  padding: 12px 16px 0;
}
.store-home-page.account-open > :not(#storeCustomerPanel) {
  display: none;
}
.store-customer-panel {
  display: grid;
  gap: 12px;
  margin: 14px 16px 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 12px 30px rgba(24, 34, 36, 0.08);
}
.store-customer-panel h3,
.store-customer-panel h4 {
  margin: 0;
}
.store-wallet-empty,
.store-wallet-summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.store-wallet-empty {
  flex-direction: column;
  text-align: center;
}
.store-wallet-empty p {
  margin: 0;
}
.store-wallet-empty .small {
  min-height: 34px;
  padding: 7px 12px;
}
.store-wallet-summary span,
.store-wallet-summary strong,
.store-wallet-summary small {
  display: block;
}
.store-wallet-summary span,
.store-wallet-summary small {
  color: var(--muted);
  font-size: 12px;
}
.store-wallet-summary strong {
  margin: 2px 0;
  font-size: 24px;
}
.store-wallet-history {
  display: grid;
  gap: 8px;
}
.store-wallet-history article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.store-wallet-history span,
.store-wallet-history small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.store-customer-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 8px;
}
.store-customer-form.single {
  grid-template-columns: minmax(180px, 420px) auto;
  align-items: end;
}
.store-customer-field {
  display: grid;
  gap: 5px;
  font-weight: 800;
}
.store-customer-field span,
.store-customer-field small {
  color: var(--muted);
  font-size: 12px;
}
.store-customer-field.invalid input {
  border-color: var(--red);
  box-shadow: 0 0 0 2px rgba(198, 40, 40, 0.1);
}
.store-customer-status {
  display: none;
  grid-column: 1 / -1;
  margin: 0;
  padding: 9px 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
}
.store-customer-status.error {
  display: block;
  border: 1px solid #efb0ad;
  background: #fff0ef;
  color: var(--red);
}
.store-customer-status.success {
  display: block;
  border: 1px solid #b8d9c6;
  background: #eef8f2;
  color: var(--green);
}
.store-customer-form .primary {
  justify-self: start;
}
.store-profile-actions {
  display: flex;
  gap: 8px;
}
.store-order-history {
  display: grid;
  gap: 8px;
}
.store-order-history article {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(140px, auto) minmax(100px, auto) auto;
  gap: 8px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.store-order-history span {
  color: var(--muted);
}
.store-order-history-invoice {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.store-order-status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 5px 9px;
  border-radius: 999px;
  background: #eef7f1;
  color: var(--green) !important;
  font-size: 12px;
  font-weight: 900;
}
.store-category-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 12px;
  padding: 16px 16px 0;
}
.store-category-card {
  display: grid;
  gap: 8px;
  min-height: 138px;
  align-content: start;
  text-align: left;
  background: white;
}
.store-category-card.active {
  border-color: var(--green);
  box-shadow: 0 0 0 2px rgba(39, 125, 97, 0.12);
}
.store-category-card div {
  display: grid;
  place-items: center;
  height: 76px;
  overflow: hidden;
  border-radius: 6px;
  background: #eef2f0;
}
.store-category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.store-category-card div span {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: white;
  color: var(--green);
  font-weight: 900;
}
.store-category-card strong,
.store-category-card small {
  display: block;
}
.store-category-card small {
  color: var(--muted);
}
.store-cart-panel .store-page-blocks {
  padding: 12px 0 0;
}
.store-custom-label {
  margin: 0;
  font-weight: 700;
}
.store-custom-button {
  display: inline-flex;
  width: fit-content;
  min-height: 38px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid var(--green);
  border-radius: 6px;
  background: var(--green);
  color: white;
  font-weight: 800;
  text-decoration: none;
}
.store-custom-input {
  display: grid;
  gap: 5px;
  max-width: 480px;
}
.store-custom-image {
  margin: 0;
}
.store-custom-image img {
  display: block;
  width: min(560px, 100%);
  max-height: 260px;
  object-fit: cover;
  border-radius: 8px;
}
.store-custom-image figcaption {
  margin-top: 6px;
  color: var(--muted);
}
.store-custom-ad {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid #e1c068;
  border-radius: 8px;
  background: #fff7d6;
}
.store-custom-ad strong {
  color: #5f4a06;
}
.store-category-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 16px 0;
}
.store-category-tabs button.active {
  background: var(--green);
  color: white;
  border-color: var(--green);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.store-products-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  padding: 4px 2px 0;
}
.store-products-head h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}
.store-products-head span {
  color: var(--muted);
  font-weight: 700;
}
.store-empty-state {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
  justify-items: start;
  padding: 28px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}
.store-empty-state strong {
  font-size: 18px;
}
.store-empty-state p {
  margin: 0;
  color: var(--muted);
}
.store-catalog-status {
  display: grid;
}
.store-catalog-status:empty {
  display: none;
}
.store-catalog-message {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border: 1px solid #dfc982;
  border-radius: 8px;
  background: #fff9e8;
  color: #4b3a09;
}
.store-catalog-message.loading {
  border-color: #cfe0f2;
  background: #f1f7fd;
  color: #1d4269;
}
.store-catalog-message.error {
  border-color: #efb0ad;
  background: #fff0ef;
  color: var(--red);
}
.store-catalog-message div {
  display: grid;
  gap: 3px;
}
.store-catalog-message strong {
  font-size: 14px;
}
.store-catalog-message p,
.store-catalog-message small {
  margin: 0;
  color: inherit;
}
.store-catalog-message button {
  min-height: 40px;
  border-radius: 6px;
  background: white;
}
.store-products-pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 2px 0;
  color: var(--muted);
  font-weight: 800;
}
.store-products-pager div {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.store-products-pager button {
  min-width: 74px;
  min-height: 40px;
  padding: 8px 12px;
  border-radius: 6px;
}
.store-products-pager strong {
  color: var(--text);
  font-size: 13px;
}
.store-contact-footer {
  display: grid;
  gap: 12px;
  margin-top: 24px;
  padding: 18px 0 6px;
  border-top: 1px solid var(--line);
  color: #31413d;
}
.store-contact-footer:empty {
  display: none;
}
.store-contact-footer section {
  display: grid;
  gap: 4px;
}
.store-contact-footer strong {
  font-size: 16px;
}
.store-contact-footer span {
  color: var(--muted);
  font-size: 13px;
}
.store-contact-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.store-contact-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid #d7e4de;
  border-radius: 6px;
  background: white;
  color: var(--green);
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}
.store-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: white;
  box-shadow: 0 8px 18px rgba(24, 34, 36, 0.05);
  cursor: pointer;
}
.store-card.unavailable {
  border-color: #e4ddd0;
  background: #fbfaf7;
}
.store-card.unavailable .image {
  opacity: 0.72;
}
.store-card .image {
  display: grid;
  place-items: center;
  height: 170px;
  overflow: hidden;
  padding: 10px;
  background: #fff;
}
.store-card .image img {
  display: block;
  width: auto !important;
  height: auto !important;
  max-width: 100%;
  max-height: 150px;
  object-fit: contain !important;
  object-position: center center;
}
.store-items-table img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.store-card .image span,
.store-items-table .image span {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: white;
  color: var(--green);
  font-size: 30px;
  font-weight: 900;
}
.store-card div:last-child {
  position: relative;
  padding: 14px;
}
.store-wishlist-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  min-width: 40px;
  min-height: 40px;
  padding: 7px 10px;
  border-color: #efc4be;
  border-radius: 6px;
  background: white;
  color: var(--red);
  font-weight: 900;
}
.store-wishlist-toggle.saved {
  background: #fff0ef;
}
.store-wishlist-toggle span[aria-hidden="true"] {
  font-size: 18px;
  line-height: 1;
}
.store-card .store-wishlist-toggle {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  min-width: 40px;
  padding: 0;
  margin: 0;
}
.store-card h3 {
  padding-right: 44px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.store-price {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  line-height: 1.2;
}
.store-price-main {
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 7px;
}
.store-price s {
  color: var(--muted);
  font-size: 13px;
}
.store-price strong {
  color: inherit;
  font-size: 16px;
  font-weight: 900;
  white-space: nowrap;
}
.store-price.sale strong {
  color: var(--red);
  font-size: 20px;
}
.store-price.compact {
  gap: 4px;
}
.store-price.compact .store-price-main {
  display: grid;
  gap: 2px;
}
.store-price.compact s {
  font-size: 11px;
}
.store-price.compact strong {
  font-size: 13px;
}
.store-price.compact.sale strong {
  font-size: 14px;
}
.store-discount-badge {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 3px 6px;
  border-radius: 4px;
  background: var(--red);
  color: white;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}
.store-stock-badge,
.store-detail-stock {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  margin-top: 10px;
  padding: 4px 7px;
  border-radius: 4px;
  border: 1px solid #cfe5d8;
  background: #f0faf4;
  color: #1d6b3d;
  font-size: 12px;
  font-weight: 900;
}
.store-stock-badge.out-of-stock,
.store-detail-stock.out-of-stock {
  border-color: #efc4be;
  background: #fff1ef;
  color: var(--red);
}
.store-detail-stock {
  margin-top: 0;
}
.store-card button {
  margin-top: 12px;
  width: 100%;
}
.store-card .store-wishlist-toggle {
  margin-top: 0;
  width: 40px;
}
.store-cart-panel {
  position: fixed;
  right: 16px;
  top: 96px;
  z-index: 20;
  width: min(720px, calc(100vw - 32px));
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  overflow-x: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 24px 70px rgba(17, 32, 31, 0.25);
  padding: 14px;
}
.store-cart-line {
  display: grid;
  grid-template-columns: 22px 52px minmax(0, 1fr) 70px minmax(82px, auto) minmax(96px, auto) 38px;
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}
.store-cart-line > span:not(.store-price) {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.store-cart-line small {
  color: var(--muted);
  white-space: nowrap;
}
.store-cart-line > strong {
  white-space: nowrap;
}
.store-cart-thumb {
  width: 52px;
  height: 52px;
  overflow: hidden;
  border-radius: 6px;
  background: #eef2f0;
}
.store-cart-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.store-cart-thumb span {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  font-weight: 900;
  color: var(--green);
}
.store-cart-qty {
  width: 70px;
}
.store-cart-remove {
  position: relative;
  width: 34px;
  min-width: 34px;
  height: 34px;
  padding: 0;
  border-color: #efb0ad;
  color: var(--red);
  background: #fff0ef;
}
.store-cart-remove::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 12px;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 1px 1px 3px 3px;
}
.store-cart-remove::after {
  content: "";
  position: absolute;
  left: 9px;
  top: 8px;
  width: 15px;
  height: 2px;
  background: currentColor;
  box-shadow: 3px -3px 0 -1px currentColor;
}
.store-cart-total {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  padding: 10px 0;
  border-top: 2px solid var(--line);
  font-weight: 900;
}
.store-cart-total div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.store-checkout-form {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.store-checkout-form .store-page-blocks {
  padding: 0;
}
.store-checkout-field {
  display: grid;
  gap: 5px;
  font-weight: 800;
}
.store-checkout-field span {
  color: var(--muted);
  font-size: 12px;
}
.store-checkout-field.invalid input,
.store-checkout-field.invalid textarea {
  border-color: var(--red);
  box-shadow: 0 0 0 2px rgba(198, 40, 40, 0.1);
}
.store-checkout-status {
  display: none;
  margin: 0;
  padding: 9px 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
}
.store-checkout-status.error {
  display: block;
  border: 1px solid #efb0ad;
  background: #fff0ef;
  color: var(--red);
}
.store-checkout-status.success {
  display: block;
  border: 1px solid #b8d9c6;
  background: #eef8f2;
  color: var(--green);
}
.store-checkout-customer-summary {
  display: grid;
  gap: 3px;
  padding: 10px;
  border: 1px solid #c7dfd3;
  border-radius: 6px;
  background: #eef8f2;
}
.store-checkout-customer-summary span {
  color: var(--muted);
}
.store-checkout-form #backToStoreCart {
  justify-self: start;
  padding: 8px 10px;
  font-size: 13px;
}
.store-checkout-options {
  display: grid;
  gap: 8px;
  margin: 2px 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.store-checkout-options legend {
  padding: 0 4px;
  color: var(--muted);
  font-weight: 800;
}
.store-checkout-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
}
.store-checkout-options label.disabled {
  color: var(--muted);
  opacity: 0.62;
}
.store-wallet-only-note {
  display: grid;
  gap: 4px;
  margin: 4px 0 0;
  color: #c62828;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 700;
}
.store-checkout-options input {
  width: auto;
}
.store-order-edit-line {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) 70px auto;
  gap: 8px;
  align-items: center;
  margin-bottom: 6px;
}
.store-order-edit-line input {
  width: 70px;
}
.store-mail-link {
  display: inline-block;
  margin-top: 6px;
  font-size: 12px;
  color: var(--green);
  font-weight: 800;
}
.store-item-dialog {
  width: min(760px, calc(100vw - 24px));
}
.store-invoice-dialog {
  width: min(760px, calc(100vw - 24px));
}
.store-invoice-print-action {
  position: absolute;
  right: 54px;
  top: 12px;
  z-index: 1;
}
.store-invoice-sheet {
  position: relative;
  display: grid;
  min-height: min(760px, calc(100vh - 96px));
  gap: 18px;
  padding: 22px;
  background: white;
  color: #050505;
  align-content: start;
}
.store-invoice-sheet header {
  display: grid;
  justify-items: center;
  gap: 4px;
  text-align: center;
}
.store-invoice-logo {
  display: grid;
  place-items: center;
  width: 58px;
  height: 42px;
  overflow: hidden;
  font-size: 12px;
}
.store-invoice-logo img {
  max-width: 58px;
  max-height: 42px;
  object-fit: contain;
}
.store-invoice-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.store-invoice-meta p {
  margin: 3px 0;
}
.store-invoice-meta span {
  font-weight: 800;
}
.store-invoice-table {
  width: 100%;
  border-collapse: collapse;
}
.store-invoice-table th,
.store-invoice-table td {
  border: 1px solid #050505;
  padding: 6px;
  text-align: left;
  vertical-align: middle;
}
.store-invoice-picture {
  width: 64px;
  height: 44px;
}
.store-invoice-picture img,
.store-invoice-picture span {
  display: grid;
  place-items: center;
  width: 48px;
  height: 36px;
  object-fit: contain;
  font-size: 11px;
  font-weight: 800;
}
.store-invoice-total-label {
  text-align: right !important;
}
.store-invoice-total {
  color: var(--red);
  font-weight: 900;
}
.store-invoice-sheet footer {
  align-self: end;
  margin-top: auto;
  font-size: 11px;
}
.store-invoice-sheet footer p {
  margin: 2px 0;
}
.store-invoice-sheet footer strong {
  display: block;
  margin-top: 16px;
  text-align: center;
  font-size: 16px;
  font-style: italic;
}
.store-invoice-printable {
  page: invoicePage;
  width: 210mm;
}
.store-invoice-printable .store-invoice-sheet {
  box-sizing: border-box;
  min-height: 0;
  width: 210mm;
  padding: 18mm;
}
.store-item-detail {
  position: relative;
  grid-template-columns: minmax(220px, 0.9fr) minmax(240px, 1.1fr);
  align-items: start;
}
.store-dialog-close {
  position: absolute;
  right: 12px;
  top: 12px;
  width: 34px;
  height: 34px;
  padding: 0;
  z-index: 1;
}
.store-detail-image {
  min-height: 300px;
  overflow: hidden;
  border-radius: 8px;
  background: #eef2f0;
}
.store-detail-image img {
  width: 100%;
  height: 100%;
  min-height: 300px;
  object-fit: contain;
}
.store-detail-image span {
  display: grid;
  min-height: 300px;
  place-items: center;
  font-size: 54px;
  font-weight: 900;
  color: var(--green);
}
.store-detail-info {
  display: grid;
  gap: 10px;
}
.store-detail-info h3 {
  margin: 0;
  padding-right: 34px;
}
.store-detail-info p {
  display: grid;
  gap: 3px;
  margin: 0;
}
.store-detail-info p > span:first-child {
  color: var(--muted);
  font-size: 12px;
}
.store-variant-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.store-variant-field select {
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
}
button.danger {
  border-color: #efb0ad;
  background: #fff0ef;
  color: var(--red);
}
dialog {
  border: 0;
  border-radius: 8px;
  padding: 0;
  width: min(460px, calc(100vw - 24px));
}
dialog::backdrop { background: rgba(0, 0, 0, 0.35); }
.modal {
  display: grid;
  gap: 14px;
  padding: 18px;
}
.modal.wide { width: min(760px, calc(100vw - 24px)); }
.erp-stock-picker-dialog {
  width: min(1380px, calc(100vw - 16px));
}
.stock-picker-modal {
  width: min(760px, calc(100vw - 24px));
}
.erp-stock-picker-dialog .stock-picker-modal {
  width: min(1320px, calc(100vw - 24px));
}
.stock-picker-layout {
  display: grid;
  gap: 12px;
}
.erp-stock-picker-dialog .stock-picker-layout {
  grid-template-columns: minmax(280px, 0.52fr) minmax(0, 1fr);
  align-items: start;
}
.stock-picker-statement:empty {
  display: none;
}
.stock-picker-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}
.stock-picker-item-head {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.stock-picker-item-head span {
  color: var(--muted);
}
.stock-picker-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.stock-picker-metrics div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  padding: 9px 10px;
  min-width: 0;
}
.stock-picker-metrics span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.stock-picker-metrics strong {
  display: block;
  overflow-wrap: anywhere;
}
.stock-picker-statement-wrap {
  max-height: min(44vh, 440px);
}
.stock-picker-statement-wrap .statement-table {
  min-width: 880px;
}
.stock-picker-list-table-wrap {
  border: 1px solid var(--line);
  border-radius: 8px;
  max-height: min(58vh, 540px);
  overflow: auto;
}
.stock-picker-list-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 12px;
}
.stock-picker-list-table th,
.stock-picker-list-table td {
  border: 1px solid #c7d4dc;
  padding: 7px 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.stock-picker-list-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #d7e9f6;
  color: #0f3554;
  text-align: left;
}
.stock-picker-list-table th.filterable-th {
  padding: 4px 24px 4px 8px;
}
.stock-picker-list-table th.filterable-th.open {
  z-index: 50;
  overflow: visible;
}
.stock-picker-list-table tbody tr {
  cursor: pointer;
  background: #fff;
}
.stock-picker-list-table tbody tr:nth-child(even) {
  background: var(--soft);
}
.stock-picker-list-table tbody tr:hover,
.stock-picker-list-table tbody tr:focus-within {
  background: #e6f3ee;
  color: var(--green);
}
.stock-picker-list-table .statement-col-qty,
.stock-picker-list-table .statement-col-price,
.stock-picker-list-table [data-statement-column="qty"],
.stock-picker-list-table [data-statement-column="price"] {
  text-align: right;
}
.stock-picker-modal menu {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 0;
}
.stock-picker-feedback {
  margin-right: auto;
  color: var(--green);
  font-weight: 800;
}
.stock-picker-feedback.flash {
  animation: stock-picker-feedback-flash 700ms ease;
}
@keyframes stock-picker-feedback-flash {
  0% { opacity: 0; transform: translateY(3px); }
  35% { opacity: 1; transform: translateY(0); }
  70% { opacity: 1; }
  100% { opacity: 1; }
}
@media (max-width: 860px) {
  .fullscreen-picker .picker-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .erp-stock-picker-dialog .stock-picker-layout {
    grid-template-columns: 1fr;
  }
  .stock-picker-metrics {
    grid-template-columns: 1fr;
  }
}
.referred-accounts-modal {
  width: min(900px, calc(100vw - 24px));
}
.referred-accounts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 12px 16px;
  max-height: min(560px, calc(100vh - 210px));
  overflow: auto;
  padding-right: 4px;
}
.referred-accounts-grid label {
  display: grid;
  gap: 6px;
}
#closeDialog {
  width: min(760px, calc(100vw - 24px));
}
.closing-sheet {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.closing-heading {
  display: grid;
  gap: 4px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.closing-heading strong {
  font-size: 16px;
  font-weight: 900;
}
.closing-heading span {
  color: var(--muted);
  font-weight: 700;
}
.closing-line, .closing-total {
  display: grid;
  grid-template-columns: minmax(150px, 0.9fr) minmax(220px, 1.1fr);
  gap: 12px;
  align-items: center;
}
.closing-line span {
  color: var(--muted);
  font-weight: 700;
}
.closing-line strong {
  font-weight: 700;
}
.closing-total {
  padding: 10px 0;
  border-top: 2px solid var(--line);
}
.closing-total span {
  color: var(--red);
  font-size: 18px;
  font-weight: 900;
  text-transform: uppercase;
}
.closing-total strong {
  font-size: 20px;
}
.closing-total.difference {
  border-bottom: 2px solid var(--line);
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 6px;
  text-align: center;
}
.closing-line.formula strong,
.closing-total.difference strong {
  font-size: 16px;
}
.closing-total.difference strong {
  font-size: 24px;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.closing-lists {
  display: grid;
  gap: 6px;
}
.closing-lists h4 {
  margin: 8px 0 0;
}
.closing-lists p {
  margin: 0;
}
.card-dialog {
  width: min(1120px, calc(100vw - 24px));
  max-height: calc(100vh - 24px);
  overflow: auto;
  background: #f7faf9;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(17, 32, 31, 0.25);
}
.column-customize-dialog {
  width: min(430px, calc(100vw - 24px));
}
.user-card-dialog {
  width: min(980px, calc(100vw - 24px));
}
.erp-invoice-dialog {
  width: min(1480px, calc(100vw - 16px));
}
.transaction-viewer-dialog {
  width: min(1120px, calc(100vw - 16px));
}
.erp-profit-checker-dialog {
  width: min(1040px, calc(100vw - 16px));
}
.transaction-viewer-card {
  min-width: 0;
}
.erp-profit-checker-card {
  min-width: 0;
}
.erp-profit-checker-wrap {
  margin: 16px;
  max-height: min(62vh, 560px);
  overflow: auto;
}
.erp-profit-checker-table {
  min-width: 820px;
}
.erp-profit-checker-table th:nth-child(3),
.erp-profit-checker-table th:nth-child(4),
.erp-profit-checker-table th:nth-child(5),
.erp-profit-checker-table th:nth-child(6),
.erp-profit-checker-table td:nth-child(3),
.erp-profit-checker-table td:nth-child(4),
.erp-profit-checker-table td:nth-child(5),
.erp-profit-checker-table td:nth-child(6) {
  text-align: right;
}
.transaction-meta,
.transaction-totals {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 8px;
  padding: 16px;
}
.transaction-meta div,
.transaction-totals div {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  padding: 9px 10px;
}
.transaction-meta span,
.transaction-totals span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.transaction-meta strong,
.transaction-totals strong {
  display: block;
  margin-top: 4px;
}
.transaction-note {
  margin: 0 16px 16px;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffdf5;
  padding: 10px;
}
.transaction-table-wrap {
  margin: 0 16px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.transaction-table {
  min-width: 820px;
}
.transaction-table th {
  background: #d7e9f6;
}
.data-card {
  background: #f7faf9;
  color: var(--ink);
  font-size: 14px;
}
.data-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  background: white;
  border-bottom: 1px solid var(--line);
}
.data-card header strong {
  font-size: 20px;
}
.data-card header button {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 6px;
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 12px;
  align-content: start;
}
#voucherCodeDialog {
  overflow-x: hidden;
}
#voucherCodeForm {
  min-width: 0;
}
#voucherCodeForm .card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 18px;
}
#voucherCodeForm .card-grid > * {
  min-width: 0;
}
#voucherCodeForm .card-grid > label {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  min-height: 38px;
  color: var(--ink);
  font-size: 14px;
}
#voucherCodeForm .card-grid > label input[type="checkbox"] {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin: 0;
}
.account-card-grid {
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  padding: 18px;
  gap: 14px;
}
.journal-entry-dialog {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  margin: 0;
  border-radius: 0;
}
.journal-entry-card {
  min-height: 100vh;
  max-height: 100vh;
  display: flex;
  flex-direction: column;
}
.journal-entry-head {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 12px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
  background: #eef5f7;
}
.journal-entry-table-wrap {
  flex: 1;
  overflow-x: auto;
  overflow-y: auto;
  padding: 0 18px 18px;
}
.journal-entry-table {
  min-width: 1680px;
}
.journal-entry-table .active-journal-entry-row td {
  background: #f8fbfb;
}
.journal-entry-table input {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 6px 8px;
}
.journal-entry-table input[type="number"] {
  -moz-appearance: textfield;
}
.journal-entry-table input[type="number"]::-webkit-outer-spin-button,
.journal-entry-table input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.journal-account-picker {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 34px;
  align-items: center;
  gap: 6px;
}
.journal-entry-table input.journal-account-label {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 7px 8px;
  background: #f8fbfb;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.journal-account-search-button {
  position: relative;
  min-width: 34px;
  width: 34px;
  min-height: 34px;
  padding: 0;
}
.journal-account-search-button::before {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border: 2px solid currentColor;
  border-radius: 50%;
  left: 8px;
  top: 7px;
}
.journal-account-search-button::after {
  content: "";
  position: absolute;
  width: 9px;
  height: 2px;
  background: currentColor;
  transform: rotate(45deg);
  left: 19px;
  top: 21px;
}
.journal-entry-table .journal-line-remove {
  min-width: 36px;
}
.journal-account-balance-row td {
  padding: 0 8px 8px;
  background: #f8fbfb;
}
.journal-account-balance-label {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  max-width: 100%;
  padding: 7px 10px;
  border: 1px solid #b7d5dd;
  border-radius: 6px;
  background: #eef8fb;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.25;
}
.journal-account-balance-label span {
  white-space: nowrap;
}
.journal-entry-card footer #addJournalEntryLine {
  min-width: 72px;
  font-size: 22px;
  font-weight: 800;
}
.journal-entry-card footer #addJournalEntryLine:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.erp-new-same-button {
  min-width: 42px;
  font-size: 22px;
  font-weight: 800;
}
.erp-close-on-save {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
}
.erp-close-on-save input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}
.erp-invoice-head,
.erp-line-entry {
  display: grid;
  grid-template-columns: repeat(6, minmax(120px, 1fr));
  gap: 10px;
  padding: 14px 18px;
  background: #d8ecff;
  border-bottom: 1px solid var(--line);
}
.erp-line-entry {
  grid-template-columns: minmax(150px, 1fr) minmax(260px, 2fr) minmax(90px, 0.7fr) minmax(120px, 1fr) minmax(180px, 1.4fr) minmax(120px, 1fr) auto;
  align-items: end;
  background: #eef5f7;
}
.cash-transaction-field {
  display: none;
}
.cash-transaction-mode .cash-transaction-field {
  display: grid;
}
.cash-transaction-mode [data-invoice-only],
.cash-transaction-mode .invoice-transaction-field,
.cash-transaction-mode .item-transaction-field,
.cash-transaction-mode .amount-transaction-field,
.cash-transaction-mode .erp-line-entry,
.cash-transaction-mode .erp-invoice-table-wrap,
.cash-transaction-mode .erp-invoice-bottom,
.cash-transaction-mode #addErpInvoiceLine {
  display: none !important;
}
.erp-line-entry button {
  min-height: 38px;
}
.erp-item-picker-field {
  grid-template-columns: 1fr;
}
.erp-item-picker-field button {
  width: 100%;
}
.erp-selected-item {
  grid-column: 1 / -1;
  min-height: 32px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.erp-invoice-table-wrap {
  min-height: 280px;
  overflow: auto;
  background: white;
  border-bottom: 1px solid var(--line);
}
.erp-invoice-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
}
.erp-invoice-table th,
.erp-invoice-table td {
  border: 1px solid #b9c4ca;
  padding: 6px 8px;
  text-align: left;
  white-space: nowrap;
}
.erp-invoice-table th {
  background: #cfe2f3;
  font-size: 12px;
}
.erp-line-input {
  width: 86px;
  min-height: 28px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 3px 6px;
}
.erp-invoice-bottom {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 0.35fr);
  gap: 16px;
  padding: 14px 18px;
  background: #d8ecff;
}
.erp-invoice-bottom label {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  color: var(--ink);
  font-weight: 700;
}
.erp-invoice-bottom input {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 6px 8px;
}
.erp-invoice-totals {
  display: grid;
  border: 1px solid #aeb8bd;
  background: white;
}
.erp-invoice-totals div {
  display: grid;
  grid-template-columns: 120px 1fr;
  border-bottom: 1px solid #aeb8bd;
}
.erp-invoice-totals div:last-child {
  border-bottom: 0;
}
.erp-invoice-totals span {
  padding: 8px 10px;
  background: #ffd9d9;
  font-weight: 700;
}
.erp-invoice-totals strong {
  padding: 8px 10px;
  text-align: right;
}
.print-dropdown {
  position: relative;
}
.erp-print-menu {
  position: absolute;
  right: 0;
  bottom: calc(100% + 8px);
  z-index: 20;
  display: grid;
  min-width: 220px;
  padding: 8px;
  border: 1px solid #b7c2ca;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 14px 36px rgba(17, 32, 31, 0.2);
}
.erp-print-menu.hidden {
  display: none;
}
.erp-print-menu button {
  justify-content: flex-start;
  border: 0;
  border-radius: 4px;
  background: transparent;
  text-align: left;
}
.erp-print-menu button:hover {
  background: #e6f3ee;
}
.erp-print-menu.account-statement-print-menu {
  top: calc(100% + 8px);
  bottom: auto;
}
.erp-utilities-menu {
  left: 0;
  right: auto;
  bottom: calc(100% + 8px);
}
.erp-print-menu .erp-utilities-submenu > .erp-submenu-button {
  width: 100%;
  justify-content: flex-start;
}
.erp-print-menu .erp-utilities-submenu > .erp-submenu-dropdown {
  top: 0;
  left: calc(100% + 8px);
  min-width: 230px;
}
.erp-print-menu .erp-utilities-submenu > .erp-submenu-dropdown button {
  width: 100%;
  min-height: 34px;
}
.stock-manager-query-menu {
  top: calc(100% + 8px);
  bottom: auto;
  left: 0;
  right: auto;
}
.stock-shelf-label-menu {
  top: 0;
  bottom: auto;
  left: calc(100% + 8px);
  right: auto;
}
.stock-print-menu,
.stock-export-menu {
  top: calc(100% + 8px);
  bottom: auto;
  left: 0;
  right: auto;
}
.stock-print-menu > button,
.stock-export-menu > button,
.stock-print-submenu-wrap > button {
  width: 100%;
  min-height: 38px;
}
.stock-print-dropdown > button::after,
.stock-export-dropdown > button::after {
  content: "v";
  display: inline-block;
  margin-left: 8px;
  color: #52616d;
  font-size: 12px;
  line-height: 1;
}
.stock-print-submenu-wrap > button::after {
  content: ">";
  float: right;
  margin-left: 18px;
  color: #52616d;
  font-size: 12px;
}
.stock-print-submenu-wrap {
  position: relative;
}
.account-statement-print-menu button {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 38px;
  line-height: 1.2;
}
.user-card-grid {
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  padding: 18px;
}
.permission-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 10px 14px;
  grid-column: 1 / -1;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}
.permission-group > .section-row {
  grid-column: 1 / -1;
}
.permission-subgroup {
  display: grid;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  gap: 8px 14px;
  align-content: start;
  min-width: 0;
  padding: 10px 12px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfc;
}
.permission-subtitle {
  grid-column: 1 / -1;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}
.permission-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  color: var(--ink);
  font-weight: 600;
}
.permission-group input {
  width: auto;
}
@media (max-width: 720px) {
  .user-card-grid,
  .permission-group,
  .permission-subgroup {
    grid-template-columns: 1fr;
  }
}
.field-row {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.field-row label,
.barcode-grid label,
.section-row {
  min-height: auto;
  padding: 0;
  background: transparent;
  border: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}
.field-row.cyan label {
  background: transparent;
}
.field-row input,
.field-row select,
.field-row textarea,
.barcode-grid input {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fff;
  color: var(--ink);
}
.barcode-generate-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: stretch;
  gap: 6px;
}
.barcode-generate-field input {
  width: 100%;
}
.barcode-generate-field button {
  min-width: 34px;
  width: 34px;
  min-height: 34px;
  padding: 0;
  border-radius: 6px;
  opacity: 0;
  font-weight: 700;
  line-height: 1;
  transition: opacity 0.15s ease;
}
.barcode-generate-field:hover button,
.barcode-generate-field:focus-within button {
  opacity: 1;
}
.wide-field {
  grid-column: 1 / -1;
}
.checkbox-field {
  align-content: start;
}
.field-row input[type="checkbox"] {
  width: auto;
  justify-self: start;
  align-self: center;
}
.section-row {
  grid-column: 1 / -1;
  background: #e9f2ef;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px 12px;
  text-align: left;
  color: var(--green);
  font-weight: 700;
  margin-top: 6px;
}
.custom-report-layout {
  display: grid;
  grid-template-columns: minmax(220px, 0.35fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.custom-report-layout h4 {
  margin: 0 0 10px;
}
.custom-report-list {
  display: grid;
  gap: 8px;
}
.custom-report-form {
  display: grid;
  gap: 12px;
}
.custom-report-form textarea {
  width: 100%;
  min-height: 180px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  resize: vertical;
}
.custom-report-form menu {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin: 0;
  padding: 0;
}
.custom-report-designer {
  display: grid;
  grid-template-columns: 180px minmax(360px, 1fr);
  gap: 12px;
  align-items: start;
}
.custom-report-palette {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}
.custom-report-palette button {
  justify-content: flex-start;
  min-height: 30px;
  padding: 6px 8px;
}
.custom-report-palette select,
.custom-report-palette input {
  width: 100%;
}
.formula-operator-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}
.formula-operator-bar button {
  justify-content: center;
  min-height: 28px;
  padding: 4px;
}
.custom-report-canvas-wrap {
  display: grid;
  justify-items: center;
  gap: 6px;
}
.custom-report-toolbar {
  width: min(100%, 840px);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: end;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}
.custom-report-toolbar label {
  display: grid;
  gap: 3px;
  font-size: 11px;
  font-weight: 700;
}
.custom-report-toolbar input,
.custom-report-toolbar select,
.custom-report-toolbar button {
  min-height: 30px;
}
.custom-report-toolbar input[type="number"] {
  width: 58px;
}
.custom-report-toolbar input[type="color"] {
  width: 44px;
  padding: 2px;
}
.custom-report-toolbar #designerText,
.custom-report-toolbar #designerFormula {
  width: 150px;
}
.custom-report-toolbar button.active {
  border-color: var(--green);
  background: #e8f6ef;
  color: var(--green);
  font-weight: 800;
}
.custom-report-ruler {
  width: min(100%, 520px);
  color: var(--muted);
  font-size: 12px;
  text-align: left;
}
.custom-report-paper {
  position: relative;
  display: grid;
  grid-template-rows: var(--custom-report-header-height, 22mm) minmax(0, 1fr) var(--custom-report-footer-height, 12mm);
  width: min(100%, 520px);
  aspect-ratio: 210 / 297;
  overflow: hidden;
  border: 1px solid #9eb5c6;
  background: #fff;
  box-shadow: 0 10px 24px rgba(20, 32, 42, 0.12);
}
.custom-report-zone {
  position: relative;
  box-sizing: border-box;
  overflow: hidden;
  background:
    linear-gradient(#edf2f5 1px, transparent 1px),
    linear-gradient(90deg, #edf2f5 1px, transparent 1px),
    #fff;
  background-size: 18px 18px;
}
.custom-report-zone::before {
  content: attr(data-zone-label);
  position: absolute;
  left: 6px;
  top: 4px;
  z-index: 3;
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.86);
  color: #536677;
  font-size: 10px;
  font-weight: 800;
  pointer-events: none;
}
.custom-report-zone.active-zone {
  outline: 2px solid #008060;
  outline-offset: -2px;
}
.custom-report-header-zone,
.custom-report-footer-zone {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8mm;
  padding: 4mm 8mm;
  color: #111;
}
.custom-report-header-zone {
  border-bottom: 2px solid #d33232;
}
.custom-report-footer-zone {
  border-top: 2px solid #d33232;
}
.custom-report-header-zone.hidden-zone,
.custom-report-footer-zone.hidden-zone {
  color: transparent;
}
.custom-report-header-zone img {
  max-width: 32mm;
  max-height: 14mm;
  object-fit: contain;
}
.custom-report-content-zone {
  position: relative;
  border-top: 2px solid #18a83a;
  border-bottom: 2px solid #18a83a;
  background:
    linear-gradient(#edf2f5 1px, transparent 1px),
    linear-gradient(90deg, #edf2f5 1px, transparent 1px),
    #fff;
  background-size: 18px 18px;
}
.custom-report-zone .designer-element {
  z-index: 2;
}
.custom-report-zone-resize {
  position: absolute;
  left: 0;
  z-index: 6;
  width: 100%;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: rgba(0, 128, 96, 0.12);
  cursor: ns-resize;
}
.custom-report-zone-resize.header {
  bottom: -4px;
}
.custom-report-zone-resize.footer {
  top: -4px;
}
.custom-report-zone-resize:hover {
  background: rgba(0, 128, 96, 0.28);
}
.designer-element {
  position: absolute;
  display: grid;
  align-items: center;
  min-width: 12px;
  min-height: 12px;
  padding: 2px 4px;
  border: 1px dashed rgba(11, 85, 139, 0.45);
  background: rgba(230, 242, 251, 0.72);
  color: #111;
  cursor: move;
  overflow: hidden;
  line-height: 1.1;
}
.designer-element.box {
  background: transparent;
  border: 1px solid #111;
}
.designer-element.line {
  height: 2px !important;
  min-height: 2px;
  padding: 0;
  border: 0;
  border-top: 2px solid currentColor;
  background: transparent;
}
.designer-element.table {
  display: block;
  padding: 0;
  background: rgba(255, 255, 255, 0.92);
}
.designer-element.image {
  display: grid;
  place-items: center;
  padding: 0;
  background: rgba(255, 255, 255, 0.92);
}
.designer-element.selected {
  outline: 2px solid var(--green);
  outline-offset: 1px;
  overflow: visible;
}
.designer-resize-handle {
  position: absolute;
  z-index: 5;
  width: 8px;
  height: 8px;
  border: 1px solid #fff;
  background: var(--green);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.24);
}
.designer-resize-handle.nw { left: -5px; top: -5px; cursor: nwse-resize; }
.designer-resize-handle.ne { right: -5px; top: -5px; cursor: nesw-resize; }
.designer-resize-handle.sw { left: -5px; bottom: -5px; cursor: nesw-resize; }
.designer-resize-handle.se { right: -5px; bottom: -5px; cursor: nwse-resize; }
.designer-resize-handle.e {
  right: -5px;
  top: 50%;
  transform: translateY(-50%);
  cursor: ew-resize;
}
.designer-resize-handle.s {
  left: 50%;
  bottom: -5px;
  transform: translateX(-50%);
  cursor: ns-resize;
}
.designer-cell-resize-handle {
  position: absolute;
  z-index: 4;
  background: var(--green);
}
.designer-cell-resize-handle.e {
  right: -3px;
  top: 0;
  width: 6px;
  height: 100%;
  cursor: ew-resize;
}
.designer-cell-resize-handle.s {
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 6px;
  cursor: ns-resize;
}
.custom-report-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.designer-image-placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border: 1px dashed #9eb5c6;
  color: var(--muted);
  font-size: 12px;
}
.designer-report-table {
  width: 100%;
  height: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: inherit;
  background: #fff;
}
.designer-report-table th,
.designer-report-table td {
  border: 1px solid #5d6b75;
  padding: 3px 5px;
  overflow-wrap: anywhere;
  vertical-align: middle;
  line-height: 1.2;
}
.designer-report-table th {
  background: #eef3f6;
  font-weight: 800;
}
.designer-report-table tfoot td,
.designer-report-table .report-engine-total {
  background: #f7faf8;
  border-top: 2px solid #26343d;
  font-weight: 800;
}
.designer-report-table .report-engine-empty {
  color: var(--muted);
  text-align: center;
  padding: 8px;
}
.custom-report-print-page {
  position: relative;
  width: 180mm;
  height: 260mm;
  margin: 0 auto;
}
.custom-report-print-element {
  position: absolute;
  display: grid;
  align-items: center;
  overflow: hidden;
  line-height: 1.1;
}
.custom-report-print-element.box {
  border: 1px solid #000;
}
.custom-report-print-element.line {
  height: 0 !important;
  border-top: 2px solid currentColor;
}
.custom-report-print-element.table {
  display: block;
  overflow: visible;
}
.custom-report-print-element.image {
  display: block;
}
.custom-report-print table {
  width: 86%;
  margin: 8mm auto 0;
  border-collapse: collapse;
  table-layout: fixed;
}
.custom-report-print th,
.custom-report-print td {
  border: 1px solid #000;
  padding: 2mm;
  text-align: left;
  vertical-align: middle;
  overflow-wrap: anywhere;
  page-break-inside: avoid;
  break-inside: avoid;
}
.custom-report-print th:nth-child(2),
.custom-report-print td:nth-child(2) {
  width: 34%;
  text-align: right;
}
.custom-report-designed-print .custom-report-print-page {
  min-height: 260mm;
  height: auto;
}
.custom-report-master-header,
.custom-report-master-footer {
  display: none;
}
.custom-report-master-section {
  position: relative;
  width: 100%;
  height: 100%;
}
.custom-report-master-section .custom-report-print-element {
  position: absolute;
}
.custom-report-designed-print .report-engine-table {
  width: 100%;
  height: auto;
  margin: 0;
  table-layout: fixed;
  page-break-inside: auto;
}
.custom-report-designed-print .report-engine-table tr {
  page-break-inside: avoid;
  break-inside: avoid;
}
.custom-report-designed-print .report-engine-table thead {
  display: table-header-group;
}
.custom-report-designed-print .report-engine-table tfoot {
  display: table-footer-group;
}
.data-card footer {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  padding: 14px 18px;
  background: white;
  border-top: 1px solid var(--line);
  position: sticky;
  bottom: 0;
}
.data-card footer label {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 5px;
  color: #07121d;
}
.data-card footer span { flex: 1; }
.data-card footer input {
  width: auto;
}
.stock-data-card {
  min-width: 0;
}
.mini-tabs {
  display: flex;
  gap: 8px;
  padding: 14px 18px 0;
  background: #f7faf9;
}
.mini-tabs span {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--green);
  font-weight: 700;
}
.stock-card-grid {
  display: grid;
  grid-template-columns: 1fr 1.45fr 0.95fr;
  align-items: start;
  gap: 14px;
  padding: 18px;
}
.stock-card-grid > .card-grid,
.barcode-grid {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}
.stock-card-grid > .stock-card-section {
  align-content: start;
  border-width: 4px;
}
.item-identity-section {
  border-color: #f0a000;
}
.selling-package-section {
  border-color: #6b20e8;
}
.stock-card-image-editor {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  gap: 8px 12px;
  align-items: end;
}
.stock-card-image-editor > label,
.stock-card-image-editor > .status-note {
  grid-column: 1 / -1;
}
.stock-card-image-controls {
  display: grid;
  gap: 8px;
}
.stock-card-image-preview {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}
.stock-card-image-preview img,
.stock-card-image-preview span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.stock-card-image-preview span {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 30px;
  font-weight: 800;
}
.costs-section {
  border-color: #8a5a34;
}
.additional-barcodes-section {
  grid-column: 1 / -1;
  border-color: #e11919;
}
.stock-card-section .section-row {
  color: var(--green);
}
.barcode-grid {
  display: grid;
  grid-template-columns: 130px repeat(5, minmax(90px, 1fr));
  gap: 10px;
  margin: 0 18px 18px;
}
.barcode-grid .section-row {
  grid-column: auto;
  margin: 0;
  background: transparent;
  border: 0;
  padding: 0;
  color: var(--muted);
}
.additional-barcode-editor {
  display: grid;
  gap: 10px;
}
.additional-barcode-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.additional-barcode-table th:nth-child(1),
.additional-barcode-table td:nth-child(1) {
  width: 42%;
}
.additional-barcode-table th:nth-child(2),
.additional-barcode-table td:nth-child(2) {
  width: 14%;
}
.additional-barcode-table th:nth-child(3),
.additional-barcode-table td:nth-child(3) {
  width: 16%;
}
.additional-barcode-table th:nth-child(4),
.additional-barcode-table td:nth-child(4) {
  width: 22%;
}
.additional-barcode-table th,
.additional-barcode-table td {
  border: 1px solid var(--line);
  padding: 6px;
  text-align: left;
}
.additional-barcode-table th {
  background: #f7faf9;
  color: var(--ink);
  font-size: 12px;
  text-transform: lowercase;
}
.additional-barcode-table input {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 6px 8px;
}
.additional-barcode-table th:last-child,
.additional-barcode-table td:last-child {
  width: 42px;
  text-align: center;
}
.additional-barcode-table button {
  min-width: 30px;
  padding: 6px 8px;
}
.assembly-item-card {
  width: min(980px, 96vw);
}
.assembly-card-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(360px, 1.1fr);
  gap: 14px;
  padding: 18px;
}
.assembly-main-section,
.assembly-components-section {
  background: #fff;
  border: 4px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  align-content: start;
}
.assembly-main-section {
  border-color: #0966e8;
}
.assembly-components-section {
  border-color: #e11919;
}
.assembly-components-section > * {
  grid-column: 1 / -1;
}
.assembly-add-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto 90px auto;
  gap: 8px;
  align-items: center;
}
.assembly-add-row input {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
}
.assembly-component-table {
  margin-top: 10px;
}
.assembly-component-table th:nth-child(2),
.assembly-component-table td:nth-child(2) {
  width: 32%;
}
menu {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin: 0;
  padding: 0;
}

.thermal-receipt {
  width: 80mm;
  box-sizing: border-box;
  padding: 5mm 4mm;
  background: #fff;
  color: #050505;
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 11px;
  line-height: 1.25;
}
.thermal-header {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
}
.thermal-logo {
  width: 28mm;
  height: 28mm;
  border: 2px solid #050505;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 3px;
  overflow: hidden;
}
.thermal-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.thermal-logo strong {
  max-width: 22mm;
  font-size: 16px;
  line-height: 1.05;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.thermal-logo span {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1px;
}
.thermal-type {
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}
.thermal-divider {
  height: 0;
  border-top: 1px dashed #050505;
  margin: 10px 0;
}
.thermal-divider.solid {
  border-top-style: solid;
  border-top-width: 2px;
}
.thermal-meta,
.thermal-summary {
  display: grid;
  grid-template-columns: 31mm 4mm 1fr;
  align-items: baseline;
  gap: 2mm;
  margin: 6px 0;
  font-size: 12px;
}
.thermal-meta span,
.thermal-summary span {
  font-weight: 800;
  text-transform: uppercase;
}
.thermal-meta strong,
.thermal-summary strong {
  text-align: right;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.thermal-meta.referred-account {
  font-size: 13px;
}
.thermal-meta.referred-account strong {
  font-weight: 700;
}
.thermal-summary.strong {
  font-size: 15px;
}
.thermal-summary.strong strong,
.thermal-summary.strong span {
  font-weight: 900;
}
.thermal-lines {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.thermal-lines th {
  background: #050505;
  color: #fff;
  padding: 6px 4px;
  text-align: left;
  font-size: 12px;
  font-weight: 900;
}
.thermal-lines th:nth-child(1) { width: 33%; }
.thermal-lines th:nth-child(2) { width: 18%; text-align: center; }
.thermal-lines th:nth-child(3) { width: 24%; text-align: right; }
.thermal-lines th:nth-child(4) { width: 25%; text-align: right; }
.thermal-lines td {
  border-bottom: 1px dashed #555;
  padding: 8px 4px;
  vertical-align: middle;
  font-size: 12px;
}
.thermal-lines td:nth-child(2) {
  text-align: center;
}
.thermal-lines td:nth-child(3),
.thermal-lines td:nth-child(4) {
  text-align: right;
}
.thermal-item {
  font-weight: 700;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.thermal-note {
  margin: 8px 0;
  text-align: center;
  font-weight: 700;
}
.thermal-note-section {
  display: grid;
  gap: 4px;
  min-height: 14mm;
  margin: 9px 0;
  padding: 7px 8px;
  border-top: 1px dashed #050505;
  border-bottom: 1px dashed #050505;
  text-align: center;
}
.thermal-note-section strong {
  font-size: 12px;
  font-weight: 900;
}
.thermal-note-section span {
  min-height: 18px;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.thermal-thanks {
  display: grid;
  justify-items: center;
  gap: 3px;
  text-align: center;
  font-size: 12px;
}
.thermal-thanks strong {
  font-size: 12px;
}
.thermal-thanks b {
  font-size: 18px;
  line-height: 1;
}
.unpaid-invoice {
  position: relative;
  box-sizing: border-box;
  width: 190mm;
  min-height: 270mm;
  padding: 14mm 12mm;
  background: #fff;
  color: #050505;
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.3;
  overflow: hidden;
}
.unpaid-head {
  display: grid;
  grid-template-columns: 70mm 1fr;
  align-items: center;
  gap: 18mm;
}
.unpaid-logo {
  width: 40mm;
  height: 40mm;
  border: 3px solid #050505;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  justify-self: center;
  gap: 4px;
  overflow: hidden;
  text-align: center;
}
.unpaid-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.unpaid-logo strong {
  max-width: 30mm;
  font-size: 21px;
  line-height: 1.05;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.unpaid-logo span {
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 1px;
}
.unpaid-meta,
.unpaid-totals {
  display: grid;
  gap: 7px;
}
.unpaid-meta div,
.unpaid-totals div {
  display: grid;
  grid-template-columns: 42mm 5mm 1fr;
  align-items: baseline;
  gap: 6mm;
}
.unpaid-meta span,
.unpaid-totals span {
  font-weight: 900;
  text-transform: uppercase;
}
.unpaid-meta strong {
  min-height: 18px;
  border-bottom: 1px solid transparent;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.unpaid-meta div:nth-child(3) strong:empty {
  border-bottom-color: #050505;
}
.unpaid-rule {
  border-top: 2px solid #050505;
  margin: 10mm 0 8mm;
}
.unpaid-rule.light {
  border-top-width: 1px;
  margin: 6mm 0;
}
.unpaid-dash {
  border-top: 1px dashed #555;
  margin: 5mm 0;
}
.unpaid-lines {
  position: relative;
  z-index: 1;
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.unpaid-lines th {
  background: #050505;
  color: #fff;
  padding: 5mm 4mm;
  text-align: left;
  font-size: 16px;
  font-weight: 900;
}
.unpaid-lines th:nth-child(1) { width: 40%; }
.unpaid-lines th:nth-child(2) { width: 16%; text-align: center; }
.unpaid-lines th:nth-child(3) { width: 22%; text-align: right; }
.unpaid-lines th:nth-child(4) { width: 22%; text-align: right; }
.unpaid-lines td {
  border-bottom: 1px dashed #555;
  padding: 5mm 4mm;
  vertical-align: middle;
  font-size: 15px;
  text-transform: uppercase;
}
.unpaid-lines td:nth-child(2) {
  text-align: center;
}
.unpaid-lines td:nth-child(3),
.unpaid-lines td:nth-child(4) {
  text-align: right;
}
.unpaid-totals {
  width: 84mm;
  margin-left: 15mm;
}
.unpaid-totals div {
  grid-template-columns: 50mm 5mm 26mm;
}
.unpaid-totals strong {
  text-align: right;
  font-weight: 500;
}
.unpaid-totals .strong {
  font-size: 18px;
}
.unpaid-totals .strong span,
.unpaid-totals .strong strong {
  font-weight: 900;
}
.unpaid-totals.muted {
  font-size: 14px;
}
.unpaid-note-section,
.completed-note-section {
  display: grid;
  gap: 5px;
  min-height: 18mm;
  margin: 7mm 0;
  padding: 5mm;
  border: 1px solid #050505;
  border-radius: 4px;
}
.unpaid-note-section strong,
.completed-note-section strong {
  font-size: 15px;
  font-weight: 900;
}
.unpaid-note-section span,
.completed-note-section span {
  min-height: 20px;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.unpaid-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 15mm;
  margin-top: 10mm;
}
.unpaid-footer .unpaid-meta div {
  grid-template-columns: 28mm 5mm 1fr;
}
.unpaid-thanks {
  display: grid;
  justify-items: center;
  gap: 4px;
  text-align: center;
  font-size: 16px;
}
.unpaid-thanks strong {
  font-size: 16px;
  font-weight: 900;
}
.unpaid-thanks b {
  font-size: 22px;
  line-height: 1;
}
.unpaid-watermark {
  position: absolute;
  left: 28mm;
  top: 94mm;
  z-index: 0;
  display: grid;
  justify-items: center;
  transform: rotate(-28deg);
  color: rgba(198, 42, 24, 0.11);
  pointer-events: none;
  text-align: center;
  text-transform: uppercase;
}
.unpaid-watermark strong {
  font-size: 72px;
  line-height: 0.95;
  letter-spacing: 3px;
}
.unpaid-watermark span {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 2px;
}
.completed-invoice {
  box-sizing: border-box;
  width: 190mm;
  min-height: 270mm;
  padding: 14mm 12mm 8mm;
  background: #fff;
  color: #050505;
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.3;
}
.completed-head {
  display: grid;
  grid-template-columns: 62mm 1fr;
  align-items: center;
  gap: 16mm;
}
.completed-logo {
  width: 44mm;
  height: 44mm;
  border: 3px solid #050505;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  justify-self: center;
  gap: 4px;
  overflow: hidden;
  text-align: center;
}
.completed-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.completed-logo strong {
  max-width: 33mm;
  font-size: 22px;
  line-height: 1.05;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.completed-logo span {
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 1px;
}
.completed-meta {
  display: grid;
  gap: 8px;
  border-left: 2px solid #050505;
  padding-left: 10mm;
}
.completed-meta.small {
  border-left: 0;
  padding-left: 0;
}
.completed-meta div {
  display: grid;
  grid-template-columns: 8mm 44mm 5mm 1fr;
  align-items: center;
  gap: 4mm;
}
.completed-meta.small div {
  grid-template-columns: 8mm 30mm 5mm 1fr;
}
.completed-meta i {
  font-style: normal;
  font-size: 20px;
  text-align: center;
  line-height: 1;
}
.completed-meta span {
  font-weight: 900;
  text-transform: uppercase;
}
.completed-meta strong {
  min-height: 18px;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.completed-meta div:nth-child(3) strong:empty {
  border-bottom: 1px solid #050505;
}
.completed-rule {
  border-top: 2px solid #050505;
  margin: 10mm 0 8mm;
}
.completed-dash {
  border-top: 1px dashed #555;
  margin-top: 6mm;
}
.completed-lines {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}
.completed-lines th {
  background: #050505;
  color: #fff;
  padding: 5mm 4mm;
  text-align: left;
  font-size: 16px;
  font-weight: 900;
}
.completed-lines th:first-child {
  border-radius: 6px 0 0 6px;
}
.completed-lines th:last-child {
  border-radius: 0 6px 6px 0;
}
.completed-lines th:nth-child(1) { width: 40%; }
.completed-lines th:nth-child(2) { width: 16%; text-align: center; }
.completed-lines th:nth-child(3) { width: 22%; text-align: right; }
.completed-lines th:nth-child(4) { width: 22%; text-align: right; }
.completed-lines td {
  border-bottom: 1px dashed #555;
  padding: 5mm 4mm;
  vertical-align: middle;
  font-size: 15px;
  text-transform: uppercase;
}
.completed-lines td:nth-child(2) {
  text-align: center;
}
.completed-lines td:nth-child(3),
.completed-lines td:nth-child(4) {
  text-align: right;
}
.completed-total-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid #050505;
  border-radius: 6px;
  margin: 6mm 0 8mm;
}
.completed-total-card div {
  display: grid;
  grid-template-columns: 16mm 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 6mm;
  padding: 6mm 14mm;
}
.completed-total-card div + div {
  border-left: 1px solid #050505;
}
.completed-total-card b {
  grid-row: 1 / 3;
  width: 12mm;
  height: 12mm;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #050505;
  color: #fff;
  font-size: 13px;
}
.completed-total-card span {
  font-size: 15px;
  font-weight: 800;
}
.completed-total-card strong {
  font-size: 22px;
  font-weight: 900;
}
.completed-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 14mm;
  margin-top: 8mm;
}
.completed-footer .completed-thanks {
  border-left: 2px solid #050505;
}
.completed-thanks {
  display: grid;
  justify-items: center;
  gap: 4px;
  text-align: center;
  font-size: 16px;
}
.completed-thanks strong {
  font-size: 16px;
  font-weight: 900;
}
.completed-thanks b {
  font-size: 22px;
  line-height: 1;
}
.cash-voucher {
  box-sizing: border-box;
  width: 210mm;
  min-height: 0;
  padding: 7mm 9mm;
  border: 1px solid #141923;
  background: #fff;
  color: #101620;
  font-family: Arial, Helvetica, sans-serif;
  letter-spacing: 0;
  overflow: hidden;
  page-break-inside: avoid;
}
.cash-voucher-head {
  display: grid;
  justify-items: center;
  gap: 3.5mm;
  margin-bottom: 7mm;
}
.cash-voucher-head h1 {
  margin: 0;
  font-size: 8mm;
  font-weight: 900;
  letter-spacing: 0;
  text-align: center;
  text-transform: uppercase;
}
.cash-voucher-head::after {
  content: "";
  width: 136mm;
  height: 1px;
  background: #101620;
  box-shadow: 0 0 0 0 #101620;
}
.cash-voucher-title {
  margin-top: -1mm;
  padding: 2mm 6mm;
  border-radius: 2mm;
  background: transparent;
  color: #8d95a0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 4mm;
  font-weight: 900;
}
.cash-voucher-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12mm;
  margin-bottom: 8mm;
}
.cash-voucher-line,
.cash-voucher-wide-line,
.cash-voucher-note-line,
.cash-voucher-footer-line {
  display: grid;
  align-items: center;
  gap: 4mm;
  font-size: 3.4mm;
  font-weight: 800;
}
.cash-voucher-line {
  grid-template-columns: auto 1fr;
}
.cash-voucher-line span,
.cash-voucher-wide-line span,
.cash-voucher-note-line span,
.cash-voucher-footer-line span {
  min-height: 8mm;
  padding-top: 1mm;
  border-bottom: 1px solid #101620;
  font-weight: 500;
}
.cash-voucher-fields {
  display: grid;
  gap: 6mm;
  margin: 0 2mm 7mm;
}
.cash-voucher-wide-line {
  grid-template-columns: 24mm 4mm 1fr;
}
.cash-voucher-amount-row {
  display: grid;
  grid-template-columns: 1fr 36mm;
  gap: 7mm;
  align-items: center;
}
.cash-voucher-currency {
  display: grid;
  place-items: center;
  min-height: 13mm;
  border: 1px solid #101620;
  font-size: 3.2mm;
  font-weight: 800;
  text-transform: uppercase;
}
.cash-voucher-note-line {
  grid-template-columns: 24mm 4mm 1fr;
}
.cash-voucher-note-line span {
  min-height: 24mm;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent 7.8mm, #101620 8mm, #101620 8.25mm);
  border-bottom: 0;
  line-height: 8mm;
}
.cash-voucher-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 4mm;
  margin: 7mm 0 6mm;
}
.cash-voucher-divider::before,
.cash-voucher-divider::after {
  content: "";
  height: 1px;
  background: #101620;
}
.cash-voucher-divider span {
  width: 5mm;
  height: 5mm;
  border-radius: 50%;
  border: 2px solid #101620;
}
.cash-voucher-signatures {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12mm;
  min-height: 67mm;
  margin-bottom: 5mm;
}
.cash-voucher-signatures > div {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 5mm;
}
.cash-voucher-signatures > div + div {
  border-left: 1px solid #101620;
  padding-left: 12mm;
}
.cash-voucher-signatures h2 {
  margin: 0;
  font-size: 3.5mm;
  font-weight: 900;
}
.cash-voucher-stamp {
  width: 48mm;
  height: 28mm;
  border: 1px dashed #101620;
  border-radius: 5mm;
}
.cash-voucher-sign-space {
  height: 34mm;
}
.cash-voucher-sign-line {
  width: 60mm;
  border-bottom: 1px solid #101620;
}
.cash-voucher-signatures p {
  margin: -3mm 0 0;
  font-size: 3mm;
  font-weight: 500;
}
.cash-voucher-footer {
  display: grid;
  gap: 2.8mm;
  margin: 0 -9mm -7mm;
  padding: 7mm 12mm 6mm;
  border-top: 1px solid #101620;
}
.cash-voucher-footer-line {
  grid-template-columns: 38mm 1fr;
  font-size: 3.4mm;
}
.account-report {
  box-sizing: border-box;
  width: 190mm;
  min-height: 270mm;
  padding: 12mm;
  background: #fff;
  color: #050505;
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 12px;
  line-height: 1.25;
}
.account-report-head {
  display: grid;
  grid-template-columns: 34mm 1fr 34mm;
  gap: 8mm;
  align-items: center;
  padding-bottom: 8mm;
  border-bottom: 2px solid #050505;
}
.account-report-logo {
  width: 28mm;
  height: 28mm;
  border: 2px solid #050505;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  overflow: hidden;
  text-align: center;
}
.account-report-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.account-report-logo strong {
  max-width: 22mm;
  font-size: 15px;
  line-height: 1.05;
  overflow-wrap: anywhere;
  text-transform: uppercase;
}
.account-report-logo span {
  font-size: 7px;
  font-weight: 900;
}
.account-report-head h1 {
  margin: 0 0 3mm;
  font-size: 24px;
  text-transform: uppercase;
}
.account-report-head p {
  margin: 1mm 0;
  overflow-wrap: anywhere;
}
.account-report-head aside {
  display: grid;
  gap: 1mm;
  border-left: 1px solid #050505;
  padding-left: 5mm;
}
.account-report-head aside span {
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.account-report-summary {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2mm;
  margin: 7mm 0;
}
.account-report-summary.range-summary {
  grid-template-columns: repeat(3, 1fr);
}
.account-report-summary div {
  border: 1px solid #050505;
  padding: 3mm;
}
.account-report-summary span {
  display: block;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.account-report-summary strong {
  display: block;
  margin-top: 1mm;
  overflow-wrap: anywhere;
}
.account-report-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  margin-top: 7mm;
}
.account-report-table th {
  background: #050505;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  text-align: left;
  text-transform: uppercase;
}
.account-report-table th,
.account-report-table td {
  border: 1px solid #050505;
  padding: 2mm;
  vertical-align: top;
  overflow-wrap: anywhere;
}
.account-report-table.compact th:nth-child(1),
.account-report-table.compact td:nth-child(1) {
  width: 8mm;
  text-align: center;
}
.account-report-table.compact th:nth-child(2) { width: 22mm; }
.account-report-table.compact th:nth-child(4) { width: 18mm; }
.account-report-table.compact th:nth-child(7),
.account-report-table.compact td:nth-child(7) {
  width: 30mm;
  text-align: right;
}
.account-report-range-total {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2mm;
  margin-top: 6mm;
}
.account-report-range-total div {
  border: 1px solid #050505;
  padding: 3mm;
}
.account-report-range-total span {
  display: block;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.account-report-range-total strong {
  display: block;
  margin-top: 1mm;
  overflow-wrap: anywhere;
}
.item-statement-report {
  display: flex;
  flex-direction: column;
  gap: 7mm;
}
.item-statement-head {
  display: grid;
  grid-template-columns: 34mm 1fr 48mm;
  gap: 8mm;
  align-items: center;
  padding-bottom: 8mm;
  border-bottom: 2px solid #050505;
}
.item-statement-head h1 {
  margin: 0 0 3mm;
  font-size: 22px;
  text-align: center;
}
.item-statement-head p {
  margin: 0;
  text-align: center;
}
.item-statement-head aside {
  display: grid;
  grid-template-columns: 20mm 1fr;
  gap: 1mm 2mm;
  font-size: 10px;
}
.item-statement-head aside span {
  font-weight: 900;
}
.item-statement-old-balance,
.item-statement-current {
  text-align: center;
}
.item-statement-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.item-statement-table td {
  border: 1px solid #050505;
  padding: 1.2mm 1.8mm;
  vertical-align: middle;
  overflow-wrap: anywhere;
}
.item-statement-table td:nth-child(1) { width: 58%; }
.item-statement-table td:nth-child(2) { width: 16%; }
.item-statement-table td:nth-child(3) { width: 16%; }
.item-statement-table td:nth-child(4) { width: 18%; }
.item-statement-transaction-row td,
.item-statement-summary td {
  background: #e5e5e5;
  font-weight: 900;
}
.item-statement-transaction-row td:not(:first-child),
.item-statement-summary td:not(:first-child),
.item-statement-item-row td:not(:first-child) {
  text-align: center;
}
.item-statement-item-head td {
  font-weight: 900;
  text-align: center;
}
.item-statement-footer {
  display: flex;
  justify-content: space-between;
  gap: 12mm;
  margin-top: auto;
  padding: 0 16mm 8mm;
}

@media print {
  @page barcodeLabelPage {
    size: 72mm 26mm;
    margin: 0;
  }
  @page shelfLabelPage {
    size: 26mm 72mm;
    margin: 0;
  }
  @page thermalPage {
    size: 80mm auto;
    margin: 0;
  }
  @page invoicePage {
    size: A4 portrait;
    margin: 0;
  }
  @page journalLandscapePage {
    size: A4 landscape;
    margin: 8mm;
  }
  html,
  body {
    margin: 0;
    padding: 0;
  }
  body > :not(.printable) {
    display: none !important;
  }
  .printable, .printable * { visibility: visible; }
  .printable {
    box-sizing: border-box;
    display: block !important;
    position: static;
    margin: 0;
    padding: 0;
    width: auto;
    max-width: 100%;
    font-size: 11px;
    break-before: auto;
    break-after: auto;
    page-break-before: auto;
    page-break-after: auto;
  }
  .thermal-printable {
    page: thermalPage;
    width: 80mm;
  }
  .closing-printable {
    page: thermalPage;
    width: 80mm;
    max-width: 80mm;
    overflow: visible;
    color: #000;
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    line-height: 1.25;
  }
  .closing-printable .closing-sheet {
    box-sizing: border-box;
    width: 76mm;
    max-width: 76mm;
    gap: 2.2mm;
    padding: 3mm 2.5mm;
    border: 0;
    border-radius: 0;
    background: #fff;
  }
  .closing-printable .closing-heading {
    gap: 1mm;
    padding-bottom: 2mm;
    border-bottom: 0.35mm solid #000;
    color: #000;
  }
  .closing-printable .closing-heading strong,
  .closing-printable .closing-heading span {
    color: #000;
    font-size: 12px;
    font-weight: 900;
    line-height: 1.15;
    overflow-wrap: anywhere;
  }
  .closing-printable .closing-line,
  .closing-printable .closing-total {
    grid-template-columns: minmax(22mm, 0.75fr) minmax(0, 1.25fr);
    gap: 1.5mm;
    align-items: start;
    color: #000;
    min-width: 0;
  }
  .closing-printable .closing-line span,
  .closing-printable .closing-total span {
    color: #000;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.15;
  }
  .closing-printable .closing-line strong,
  .closing-printable .closing-total strong,
  .closing-printable .closing-lists p {
    color: #000;
    font-size: 13px;
    font-weight: 900;
    line-height: 1.18;
    text-align: right;
    overflow-wrap: anywhere;
    word-break: break-word;
    min-width: 0;
  }
  .closing-printable .closing-total {
    padding: 2.5mm 0;
    border-top: 0.6mm solid #000;
  }
  .closing-printable .closing-total strong {
    font-size: 15px;
  }
  .closing-printable .closing-total.difference {
    border-bottom: 0.6mm solid #000;
    gap: 2mm;
  }
  .closing-printable .closing-total.difference strong {
    font-size: 20px;
  }
  .closing-printable .closing-lists {
    box-sizing: border-box;
    width: 76mm;
    max-width: 76mm;
    gap: 1.5mm;
    padding: 0 2.5mm 3mm;
    color: #000;
  }
  .closing-printable .closing-lists h4 {
    margin: 3mm 0 0;
    border-top: 0.35mm solid #000;
    padding-top: 2mm;
    font-size: 14px;
    font-weight: 900;
  }
  .closing-printable .closing-lists p {
    margin: 0;
    text-align: left;
  }
  .invoice-printable {
    page: invoicePage;
    width: 210mm;
    max-width: 210mm;
  }
  .voucher-printable {
    page: invoicePage;
    width: 210mm;
    max-width: 210mm;
    min-height: 0;
    overflow: hidden;
  }
  .account-report-printable {
    page: invoicePage;
    width: 210mm;
    max-width: 210mm;
  }
  .simple-report-printable {
    page: invoicePage;
    width: 210mm;
    max-width: 210mm;
  }
  .journal-printable {
    page: journalLandscapePage;
    width: 281mm;
    font-family: Arial, Helvetica, sans-serif;
    color: #000;
  }
  .journal-printable table {
    width: 100%;
    border-collapse: collapse;
    font-size: 8px;
  }
  .journal-printable th,
  .journal-printable td {
    border: 1px solid #000;
    padding: 2mm 1.5mm;
    color: #000;
  }
  .journal-printable th {
    background: #e8e8e8;
  }
  .barcode-label-printable {
    page: barcodeLabelPage;
    width: 72mm;
    height: 26mm;
    overflow: hidden;
  }
  .barcode-label-sheet {
    width: 72mm;
    height: 26mm;
    box-sizing: border-box;
    padding: 0;
    display: block;
    break-after: auto;
    page-break-after: auto;
    overflow: hidden;
    background: #fff;
  }
  .barcode-label-sheet:not(:last-child) {
    break-after: page;
    page-break-after: always;
  }
  .barcode-label-sheet:last-child {
    break-after: auto;
    page-break-after: auto;
  }
  .barcode-label-page {
    width: 72mm;
    height: 26mm;
    overflow: hidden;
    background: #fff;
  }
  .barcode-label-page.empty {
    visibility: hidden;
  }
  .shelf-label-printable {
    page: shelfLabelPage;
    width: 26mm;
    overflow: visible;
    color: #000;
    background: #fff;
  }
  .shelf-label-sheet {
    width: 26mm;
    height: 72mm;
    box-sizing: border-box;
    padding: 0 0 0 1mm;
    display: grid;
    grid-template-rows: 40mm;
    align-content: start;
    justify-items: start;
    break-after: auto;
    page-break-after: auto;
    overflow: hidden;
    background: #fff;
  }
  .shelf-label-sheet:not(:last-child) {
    break-after: page;
    page-break-after: always;
  }
  .shelf-label-sheet:last-child {
    break-after: auto;
    page-break-after: auto;
  }
  .shelf-label-page {
    width: 23mm;
    height: 40mm;
    overflow: hidden;
    background: #fff;
  }
  .shelf-label-page.empty {
    visibility: hidden;
  }
  .printable > h2 { display: none; }
  .barcode-label {
    width: 72mm;
    height: 26mm;
    box-sizing: border-box;
    padding: 2mm;
    display: flex;
    flex-direction: column;
    gap: 0.6mm;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #000;
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
    text-align: center;
  }
  .barcode-label-code {
    display: block;
    width: 50mm;
    height: 12mm;
    fill: #000;
    shape-rendering: crispEdges;
  }
  .barcode-label-number,
  .barcode-label-name,
  .barcode-label-pack {
    max-width: 68mm;
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 700;
    line-height: 1;
  }
  .barcode-label-number {
    font-size: 9pt;
  }
  .barcode-label-name,
  .barcode-label-pack {
    font-size: 8pt;
  }
  .shelf-label {
    box-sizing: border-box;
    width: 23mm;
    height: 40mm;
    padding: 0.8mm 1.2mm;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto auto;
    align-items: center;
    justify-items: center;
    gap: 0.3mm;
    color: #000;
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
    text-align: center;
    overflow: hidden;
    transform: rotate(180deg);
    transform-origin: center;
  }
  .shelf-label-name,
  .shelf-label-pack,
  .shelf-label-price {
    max-width: 100%;
    line-height: 1;
    font-weight: 900;
    overflow-wrap: anywhere;
    word-break: break-word;
  }
  .shelf-label-name {
    font-size: var(--shelf-name-size, 4mm);
  }
  .shelf-label-pack {
    font-size: var(--shelf-pack-size, 2.6mm);
  }
  .shelf-label-price {
    font-size: var(--shelf-price-size, 3.2mm);
    white-space: nowrap;
  }
  .thermal-receipt {
    width: 80mm;
    min-height: 100%;
    box-shadow: none;
  }
  .unpaid-invoice {
    box-sizing: border-box;
    width: 210mm;
    min-height: 0;
  }
  .completed-invoice {
    box-sizing: border-box;
    width: 210mm;
    min-height: 0;
  }
  .cash-voucher {
    box-sizing: border-box;
    width: 210mm;
    min-height: 0;
  }
  .account-report {
    box-sizing: border-box;
    width: 210mm;
    min-height: 0;
  }
}

@media (max-width: 1050px) {
  .home-grid, .pos-layout, .pos-menu-panel, .pos-account-layout, .company-panel, .company-form, .referred-accounts-grid, .two-column, .report-grid, .store-grid, .invoice-sections, .settings-grid, .store-metrics, .store-chart-layout, .store-dashboard-charts {
    grid-template-columns: 1fr;
  }
  .store-dashboard-chart-row {
    grid-template-columns: 1fr;
  }
  .store-dashboard-chart-row b {
    text-align: left;
  }
  .store-dashboard-chart header,
  .store-dashboard-pie-wrap {
    grid-template-columns: 1fr;
  }
  .store-dashboard-chart header {
    display: grid;
  }
  .store-dashboard-chart-types {
    width: 100%;
  }
  .store-stock-list-toolbar,
  .store-orders-toolbar,
  .store-admin-item-editor,
  .store-admin-item-fields {
    grid-template-columns: 1fr;
  }
  .store-admin-item-preview {
    width: 120px;
    height: 120px;
  }
  .store-category-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .store-products-pager {
    align-items: flex-start;
    flex-direction: column;
  }
  .store-products-pager div {
    width: 100%;
    justify-content: space-between;
  }
  .storefront-toolbar {
    grid-template-columns: minmax(132px, auto) minmax(0, 1fr) auto;
  }
  .store-wallet-button {
    min-width: 76px;
    padding: 0 8px;
  }
  .store-wallet-button strong {
    max-width: 50px;
    font-size: 11px;
  }
  .store-title-wrap h3 {
    font-size: 20px;
  }
  .store-hero-slide {
    aspect-ratio: 16 / 5;
  }
  .store-cart-panel {
    left: 12px;
    right: 12px;
    width: auto;
  }
  .store-cart-line {
    grid-template-columns: 22px 48px minmax(0, 1fr) 64px 34px;
  }
  .store-cart-line .store-price,
  .store-cart-line > strong {
    grid-column: 3 / -1;
  }
  .store-customer-form,
  .store-customer-form.single,
  .store-order-history article {
    grid-template-columns: 1fr;
  }
  .store-customer-profile-card {
    grid-template-columns: 1fr;
  }
  .store-wallet-admin-add {
    grid-template-columns: 1fr;
  }
  .store-invoice-meta {
    grid-template-columns: 1fr;
  }
  .store-item-detail {
    grid-template-columns: 1fr;
  }
  .store-admin-shell {
    grid-template-columns: 1fr;
  }
  .store-admin-shell.menu-collapsed .store-admin-menu.open {
    display: grid;
  }
  .store-admin-menu {
    display: none;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .store-admin-menu.open {
    display: grid;
  }
  .account-card-grid, .stock-card-grid {
    grid-template-columns: 1fr;
  }
  .assembly-card-grid,
  .assembly-add-row {
    grid-template-columns: 1fr;
  }
  .barcode-grid {
    grid-template-columns: 1fr;
  }
  .module-tile { min-height: 220px; }
  .topbar, .screen-head { align-items: stretch; flex-direction: column; }
  .database-panel, .rate-panel, .pos-head-actions { justify-content: stretch; }
  .rate-panel { min-width: 0; width: 100%; }
}

@media (max-width: 720px) {
  .erp-invoice-dialog {
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
    border: 0;
    border-radius: 0;
    overflow: hidden;
  }
  .erp-invoice-card {
    min-height: 100dvh;
    max-height: 100dvh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-size: 13px;
  }
  .erp-invoice-card header {
    flex: 0 0 auto;
    padding: calc(10px + env(safe-area-inset-top, 0px)) 10px 10px;
  }
  .erp-invoice-card header strong {
    min-width: 0;
    font-size: 16px;
  }
  .erp-invoice-card header button {
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
  }
  .erp-invoice-head,
  .erp-line-entry {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 10px;
  }
  .erp-invoice-head {
    flex: 0 0 auto;
    max-height: 36dvh;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .erp-line-entry {
    flex: 0 0 auto;
    align-items: end;
  }
  .erp-invoice-head .wide-field,
  .erp-line-entry .amount-transaction-field,
  .erp-line-entry .erp-item-picker-field,
  .erp-line-entry #addErpInvoiceLine {
    grid-column: 1 / -1;
  }
  .erp-line-entry #addErpInvoiceLine {
    width: 100%;
    min-height: 40px;
  }
  .erp-invoice-card .field-row {
    gap: 4px;
  }
  .erp-invoice-card .field-row label {
    font-size: 10px;
    line-height: 1.2;
  }
  .erp-invoice-card .field-row input,
  .erp-invoice-card .field-row select,
  .erp-invoice-card .field-row textarea {
    width: 100%;
    min-width: 0;
    min-height: 36px;
    padding: 7px 8px;
    font-size: 13px;
  }
  .erp-invoice-table-wrap {
    flex: 1 1 auto;
    min-height: 150px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .erp-invoice-table {
    min-width: 760px;
  }
  .erp-invoice-table th,
  .erp-invoice-table td {
    padding: 6px;
    font-size: 12px;
  }
  .erp-line-input {
    width: 66px;
    min-height: 30px;
  }
  .erp-invoice-bottom {
    flex: 0 0 auto;
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 10px;
  }
  .erp-invoice-bottom label {
    grid-template-columns: 1fr;
    gap: 5px;
  }
  .erp-invoice-totals div {
    grid-template-columns: minmax(92px, 0.45fr) minmax(0, 1fr);
  }
  .erp-invoice-totals span,
  .erp-invoice-totals strong {
    padding: 7px 8px;
  }
  .erp-invoice-card footer {
    flex: 0 0 auto;
    display: grid;
    grid-template-columns: auto auto minmax(82px, 1fr) auto;
    gap: 8px;
    align-items: center;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px));
  }
  .erp-invoice-card footer #erpCloseOnSaveField,
  .erp-invoice-card footer #erpUtilitiesWrap,
  .erp-invoice-card footer #erpTransactionHint {
    display: none;
  }
  .erp-invoice-card footer button {
    min-width: 0;
    min-height: 40px;
    padding: 7px 9px;
    font-size: 12px;
    white-space: normal;
  }
  .erp-invoice-card footer #postErpTransaction {
    min-width: 82px;
    font-weight: 800;
  }
  .erp-invoice-card footer .print-dropdown {
    min-width: 0;
  }
  .erp-invoice-card footer #erpPrintMenuButton {
    width: 100%;
  }
  .erp-print-menu {
    right: 0;
    min-width: min(220px, calc(100vw - 20px));
  }
}
