:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e5e7eb;
  --orange: #f97316;
  --orange-soft: #fff5e8;
  --green: #16a34a;
  --green-strong: #099447;
  --green-soft: #eafbf0;
  --blue: #1577f2;
  --blue-strong: #0b63da;
  --blue-soft: #eaf4ff;
  --danger: #dc2626;
  --danger-soft: #fff1f2;
  --shadow: 0 4px 16px rgba(15, 23, 42, .06);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --bottom-nav: 74px;
}
* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { opacity: .46; cursor: not-allowed; }
.app-shell {
  width: min(100%, 880px);
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--bg);
  padding-bottom: calc(var(--bottom-nav) + env(safe-area-inset-bottom));
}
.topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: max(18px, env(safe-area-inset-top)) 18px 14px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.brand-mark {
  width: 46px;
  height: 46px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  font-size: 1.35rem;
  overflow: hidden;
}
.brand-mark img { width: 100%; height: 100%; object-fit: contain; }
.topbar h1 { margin: 0; font-size: clamp(1.45rem, 5vw, 2rem); letter-spacing: -.03em; }
.topbar p { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.connection { color: #22c55e; font-size: 1.2rem; padding: 8px; }
.connection.offline { color: #f59e0b; }
.main-content { padding: 0 14px 20px; }
.view { display: none; }
.view.active { display: block; }
.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; }

.sale-products-panel {
  background: linear-gradient(180deg, color-mix(in srgb, var(--orange-soft) 94%, var(--surface)), var(--orange-soft));
  border: 1px solid color-mix(in srgb, var(--orange) 24%, var(--line));
  border-radius: var(--radius-xl);
  padding: 14px;
  box-shadow: var(--shadow);
}
.panel-heading,
.section-title-row,
.page-heading,
.modal-head,
.change-row,
.pay-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.heading-group { display: flex; align-items: center; gap: 11px; min-width: 0; }
.panel-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--orange) 12%, var(--surface));
}
.panel-heading h2 { margin: 0; font-size: 1.05rem; }
.panel-heading p { margin: 3px 0 0; color: var(--muted); font-size: .78rem; }
.count-badge {
  display: inline-grid;
  place-items: center;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  margin-left: 4px;
  background: color-mix(in srgb, var(--orange) 13%, var(--surface));
  color: var(--orange);
  font-weight: 900;
}
.ghost-danger {
  border: 0;
  background: transparent;
  color: var(--orange);
  font-weight: 800;
  padding: 10px 4px;
}
.cart-scroller {
  margin-top: 12px;
  max-height: clamp(300px, 47dvh, 560px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  padding-right: 2px;
}
.cart-list { display: grid; gap: 10px; }
.cart-item {
  background: var(--surface);
  border: 1px solid color-mix(in srgb, var(--orange) 8%, var(--line));
  border-radius: 20px;
  padding: 13px;
}
.cart-line {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 10px;
  align-items: center;
}
.product-thumb {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--surface-soft);
  color: var(--muted);
  font-weight: 900;
  border: 1px solid var(--line);
}
.item-name { font-weight: 850; line-height: 1.25; }
.item-meta { color: var(--muted); font-size: .76rem; margin-top: 3px; }
.item-unit-price { color: var(--orange); font-weight: 900; margin-top: 4px; font-size: .9rem; }
.line-total { font-weight: 950; white-space: nowrap; font-size: 1rem; }
.cart-actions { margin-top: 10px; display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.qty-control {
  display: inline-grid;
  grid-template-columns: 42px 42px 42px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 13px;
  overflow: hidden;
  background: var(--surface-soft);
}
.qty-btn {
  height: 40px;
  border: 0;
  background: transparent;
  color: var(--text);
  font-size: 1.28rem;
  font-weight: 900;
}
.qty-btn:active { background: color-mix(in srgb, var(--blue) 9%, transparent); }
.qty-value { text-align: center; font-weight: 900; }
.remove-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--danger) 18%, var(--line));
  background: var(--danger-soft);
  color: var(--danger);
  font-weight: 900;
}
.empty-state { text-align: center; padding: 36px 12px; color: var(--muted); }
.empty-state strong { display: block; color: var(--text); margin-bottom: 5px; }
.empty-state p { margin: 0; }
.empty-icon { font-size: 2rem; opacity: .65; margin-bottom: 6px; }
.empty-state.compact { padding: 18px 8px; }

.payment-panel {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr minmax(140px, 44%);
  gap: 12px;
  align-items: stretch;
  background: linear-gradient(135deg, var(--green-soft), color-mix(in srgb, var(--green-soft) 65%, var(--surface)));
  border: 1px solid color-mix(in srgb, var(--green) 18%, var(--line));
  border-radius: var(--radius-lg);
  padding: 14px;
  box-shadow: var(--shadow);
}
.total-block { display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.total-block > span { font-weight: 850; color: color-mix(in srgb, var(--green) 74%, var(--text)); }
.total-block strong { display: block; margin-top: 2px; font-size: clamp(1.5rem, 6vw, 2.2rem); letter-spacing: -.04em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.total-block small { color: var(--muted); margin-top: 2px; }
.checkout-btn {
  border: 0;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--green), var(--green-strong));
  color: #fff;
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-shadow: 0 10px 24px rgba(22, 163, 74, .2);
}
.checkout-btn span { font-size: 1.35rem; }
.checkout-btn strong { font-size: 1.08rem; }

.scan-actions {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 10px;
  background: var(--blue-soft);
  border: 1px solid color-mix(in srgb, var(--blue) 16%, var(--line));
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.scan-action {
  border-radius: 18px;
  min-height: 84px;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px;
  text-align: left;
  font-weight: 850;
}
.scan-action.secondary { background: var(--surface); color: var(--blue); }
.scan-action.primary { background: linear-gradient(135deg, var(--blue), var(--blue-strong)); color: #fff; border-color: transparent; box-shadow: 0 10px 24px rgba(21,119,242,.22); }
.scan-icon { font-size: 1.45rem; }
.feedback { min-height: 22px; margin: 8px 4px 0; color: var(--green); font-size: .86rem; font-weight: 750; text-align: center; }

.bottom-nav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: min(100%, 880px);
  height: calc(var(--bottom-nav) + env(safe-area-inset-bottom));
  padding: 6px 6px env(safe-area-inset-bottom);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--surface) 95%, transparent);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
  z-index: 30;
}
.nav-btn {
  position: relative;
  border: 0;
  background: transparent;
  color: var(--muted);
  display: grid;
  place-items: center;
  align-content: center;
  gap: 3px;
  min-width: 0;
  border-radius: 14px;
}
.nav-btn span { font-size: 1.15rem; }
.nav-btn small { font-weight: 720; font-size: .66rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.nav-btn.active { color: var(--blue); }
.nav-btn.active::before { content: ""; position: absolute; top: 0; width: 38%; height: 3px; border-radius: 999px; background: var(--blue); }

.page-heading { align-items: flex-end; padding: 12px 3px 14px; }
.page-heading h2 { margin: 0; font-size: 1.5rem; letter-spacing: -.03em; }
.page-heading p:not(.eyebrow) { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }
.eyebrow { margin: 0 0 3px; color: var(--muted); font-size: .68rem; font-weight: 900; letter-spacing: .1em; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.solid-btn, .outline-btn {
  min-height: 44px;
  border-radius: 13px;
  padding: 10px 14px;
  font-weight: 850;
}
.solid-btn { border: 1px solid var(--blue); background: var(--blue); color: #fff; }
.outline-btn { border: 1px solid var(--line); background: var(--surface-soft); color: var(--text); }
.full { width: 100%; }
.file-button { display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }

.product-tools { padding: 14px; }
.search-field { display: block; font-size: .78rem; font-weight: 800; color: var(--muted); }
.search-field input { margin-top: 6px; }
.tool-actions { display: flex; gap: 8px; margin-top: 11px; flex-wrap: wrap; }
.helper { color: var(--muted); font-size: .76rem; margin: 10px 0 0; }
.product-list-card { margin-top: 12px; padding: 8px 14px; }
.product-item { padding: 13px 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; }
.product-item:first-child { border-top: 0; }
.product-actions { display: flex; align-items: center; gap: 6px; }
.mini-btn { border: 1px solid var(--line); background: var(--surface-soft); color: var(--text); border-radius: 10px; padding: 8px 9px; font-weight: 800; }
.mini-btn.danger { color: var(--danger); background: var(--danger-soft); }
.badge { display: inline-block; padding: 3px 7px; border-radius: 999px; font-size: .65rem; font-weight: 850; margin-left: 5px; background: var(--surface-soft); color: var(--muted); }
.badge.on { color: var(--green); background: var(--green-soft); }
.low-stock { color: #d97706; font-weight: 800; }

.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.metric-card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 15px; box-shadow: var(--shadow); }
.metric-card span { color: var(--muted); font-size: .78rem; font-weight: 750; }
.metric-card strong { display: block; margin-top: 4px; font-size: 1.35rem; }
.recent-sales-card { margin-top: 12px; padding: 14px; }
.section-title-row h3 { margin: 0; }
.sale-item { padding: 12px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 10px; }
.sale-item:first-child { border-top: 0; }
.sale-amount { font-weight: 900; white-space: nowrap; }

.info-stack { display: grid; gap: 12px; }
.info-card { padding: 16px; display: grid; grid-template-columns: 46px 1fr; gap: 12px; align-items: start; }
.info-card h3 { margin: 0 0 5px; }
.info-card p { margin: 0; color: var(--muted); line-height: 1.45; font-size: .9rem; }
.info-icon { width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; background: var(--surface-soft); border: 1px solid var(--line); }
.actions-card { grid-template-columns: 1fr; }
.backup-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.profile-card { padding: 16px; }
.logo-setting { display: grid; grid-template-columns: 82px 1fr; gap: 14px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.logo-preview { width: 82px; height: 82px; display: grid; place-items: center; overflow: hidden; border-radius: 20px; border: 1px solid var(--line); background: var(--surface-soft); font-size: 2rem; }
.logo-preview img { width: 100%; height: 100%; object-fit: contain; }
.logo-controls { min-width: 0; }
.logo-controls strong, .logo-controls small { display: block; }
.logo-controls small { margin-top: 4px; color: var(--muted); line-height: 1.35; }
.logo-actions { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 10px; }

input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface-soft);
  color: var(--text);
  padding: 11px 12px;
  outline: none;
}
input:focus { border-color: color-mix(in srgb, var(--blue) 58%, var(--line)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 13%, transparent); }
.profile-card label, .modal label { display: block; font-size: .82rem; font-weight: 800; margin: 12px 0; }
.profile-card label input, .modal label input { margin-top: 7px; }

.modal {
  width: min(calc(100% - 24px), 530px);
  max-height: calc(100dvh - 24px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 30px 90px rgba(0,0,0,.34);
}
.modal::backdrop { background: rgba(0,0,0,.6); backdrop-filter: blur(3px); }
.modal-head { margin-bottom: 14px; }
.modal-head h2 { margin: 0; }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface-soft); color: var(--text); font-size: 1.45rem; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.switch-row { display: flex !important; align-items: center; justify-content: space-between; gap: 14px; }
.switch-row span { flex: 1; }
.switch-row strong, .switch-row small { display: block; }
.switch-row small { color: var(--muted); font-weight: 500; margin-top: 3px; }
.switch-row input { width: 22px; height: 22px; min-height: 22px; margin: 0 !important; }
.form-error { min-height: 20px; color: var(--danger); font-size: .82rem; font-weight: 750; }
.scanner-box { min-height: 280px; overflow: hidden; background: #000; border-radius: 16px; }
.scanner-message { color: var(--muted); text-align: center; font-size: .88rem; }
.pay-total { background: var(--surface-soft); border: 1px solid var(--line); border-radius: 15px; padding: 14px; }
.pay-total span { color: var(--muted); }
.pay-total strong { font-size: 1.2rem; }
.pay-methods { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 12px 0; }
.pay-method { min-height: 50px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface-soft); color: var(--text); font-weight: 850; }
.pay-method.active { border-color: var(--green); background: var(--green); color: #fff; }
.change-row { padding: 12px; border: 1px solid var(--line); background: var(--surface-soft); border-radius: 13px; margin: 10px 0; }
.success-mark { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green); font-size: 2rem; font-weight: 950; }
.receipt-modal { text-align: center; }
.receipt-summary { text-align: left; background: var(--surface-soft); border: 1px solid var(--line); border-radius: 15px; padding: 14px; margin: 16px 0; }
.receipt-summary .row { display: flex; justify-content: space-between; gap: 10px; margin: 7px 0; }
.toast { position: fixed; left: 50%; top: max(16px, env(safe-area-inset-top)); transform: translate(-50%, -16px); opacity: 0; pointer-events: none; background: var(--text); color: var(--bg); padding: 10px 15px; border-radius: 999px; font-size: .85rem; font-weight: 850; z-index: 80; transition: .2s ease; box-shadow: var(--shadow); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.quick-products { margin-top: 12px; padding: 14px; }
.quick-products-head { display: grid; grid-template-columns: 1fr minmax(150px, 230px); gap: 12px; align-items: end; }
.quick-products h2 { margin: 0; font-size: 1rem; }
.quick-products p { margin: 4px 0 0; color: var(--muted); font-size: .8rem; }
.quick-search input { width: 100%; min-height: 42px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-soft); color: var(--text); padding: 9px 11px; outline: none; }
.quick-search input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(21, 119, 242, .1); }
.quick-product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 12px; }
.quick-product { min-height: 92px; display: flex; flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 5px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: #fff; color: var(--text); text-align: left; }
.quick-product span { font-weight: 800; }
.quick-product strong { color: var(--blue); }
.quick-product small { color: var(--muted); }
.quick-product:active { transform: scale(.985); }

@media (max-width: 390px) {
  .main-content { padding-inline: 10px; }
  .payment-panel { grid-template-columns: 1fr 42%; }
  .total-block strong { font-size: 1.35rem; }
  .scan-action { font-size: .82rem; padding: 9px; }
  .nav-btn small { font-size: .6rem; }
  .cart-line { grid-template-columns: 40px 1fr; }
  .line-total { grid-column: 2; justify-self: end; }
  .cart-actions { justify-content: space-between; }
  .logo-setting { grid-template-columns: 68px 1fr; }
  .logo-preview { width: 68px; height: 68px; }
  .quick-products-head, .quick-product-grid { grid-template-columns: 1fr; }
}
@media (min-width: 720px) {
  .main-content { padding-inline: 22px; }
  .cart-scroller { max-height: 52dvh; }
  .metric-grid { grid-template-columns: repeat(4, 1fr); }
}

/* Continuous barcode scanner feedback */
.scanner-status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
}
.scanner-status > div { min-width: 0; }
.scanner-status strong,
.scanner-status small { display: block; }
.scanner-status small {
  margin-top: 2px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.scanner-live-dot {
  width: 11px;
  height: 11px;
  flex: 0 0 11px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--blue) 13%, transparent);
}
.scanner-status.success {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  background: var(--green-soft);
}
.scanner-status.success .scanner-live-dot {
  background: var(--green);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--green) 13%, transparent);
}
.scanner-status.error {
  border-color: color-mix(in srgb, var(--danger) 35%, var(--line));
  background: var(--danger-soft);
}
.scanner-status.error .scanner-live-dot {
  background: var(--danger);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--danger) 13%, transparent);
}
.scanner-actions {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 8px;
  margin-top: 10px;
}
.scanner-actions > * { width: 100%; }

/* Search suggestions, catalog reports and period analytics */
.danger-btn { min-height: 44px; border: 1px solid var(--danger); border-radius: 13px; padding: 10px 14px; background: var(--danger); color: #fff; font-weight: 850; }
.quick-search { position: relative; }
.search-suggestions {
  position: absolute;
  z-index: 25;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: min(360px, 55dvh);
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 18px 48px rgba(15, 23, 42, .16);
  padding: 5px;
}
.suggestion-item { width: 100%; display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; border: 0; border-radius: 10px; padding: 10px; background: transparent; color: var(--text); text-align: left; }
.suggestion-item:hover, .suggestion-item.active { background: var(--blue-soft); }
.suggestion-item span, .suggestion-item small { display: block; }
.suggestion-item span { font-weight: 850; }
.suggestion-item small { margin-top: 2px; color: var(--muted); }
.suggestion-item strong { color: var(--blue); white-space: nowrap; }
.result-caption { min-height: 18px; margin: 10px 0 0 !important; color: var(--muted); font-size: .72rem !important; }
.import-report { display: grid; gap: 9px; margin: 2px 0 18px; }
.import-stat { display: flex; justify-content: space-between; gap: 14px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-soft); }
.import-stat strong { text-align: right; }
.import-warning { margin: 0; padding: 11px 12px; border-radius: 12px; background: var(--orange-soft); color: #9a3412; font-size: .82rem; line-height: 1.42; }
.period-switch { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin-bottom: 12px; padding: 5px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface-soft); }
.period-btn { min-height: 42px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-weight: 850; }
.period-btn.active { background: var(--surface); color: var(--blue); box-shadow: var(--shadow); }
.analytics-grid { display: grid; gap: 12px; margin-top: 12px; }
.chart-card { min-width: 0; padding: 14px; overflow: hidden; }
.chart-card h3 { margin: 0; font-size: 1rem; }
.bar-chart { display: flex; align-items: stretch; gap: 8px; min-height: 190px; margin-top: 14px; padding: 8px 2px 0; overflow-x: auto; overscroll-behavior-x: contain; }
.chart-column { min-width: 42px; flex: 1 0 42px; display: grid; grid-template-rows: 26px 1fr 22px; align-items: end; gap: 5px; text-align: center; }
.chart-value { color: var(--muted); font-size: .62rem; font-weight: 800; white-space: nowrap; }
.chart-track { height: 118px; display: flex; align-items: flex-end; justify-content: center; border-bottom: 1px solid var(--line); }
.chart-bar { width: min(28px, 72%); min-height: 3px; height: var(--bar-height); border-radius: 7px 7px 2px 2px; background: linear-gradient(180deg, var(--blue), var(--blue-strong)); }
.chart-label { color: var(--muted); font-size: .66rem; white-space: nowrap; }
.empty-chart { margin: auto; color: var(--muted); text-align: center; font-size: .86rem; }
.payment-chart { display: grid; gap: 12px; margin-top: 16px; }
.payment-row { display: grid; grid-template-columns: 70px 1fr auto; align-items: center; gap: 9px; font-size: .78rem; }
.payment-row span { font-weight: 800; }
.payment-track { height: 12px; overflow: hidden; border-radius: 999px; background: var(--surface-soft); }
.payment-fill { height: 100%; width: var(--fill-width); border-radius: inherit; background: var(--green); }
.payment-row.card-payment .payment-fill { background: var(--blue); }
.payment-row strong { white-space: nowrap; }
.top-products-list { margin-top: 8px; }
.top-product-row { display: grid; grid-template-columns: 26px 1fr auto; gap: 8px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.top-product-row:first-child { border-top: 0; }
.top-product-rank { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 9px; background: var(--blue-soft); color: var(--blue); font-size: .72rem; font-weight: 900; }
.top-product-row small { color: var(--muted); }
.top-product-row > strong { color: var(--blue); white-space: nowrap; }

@media (min-width: 720px) {
  .analytics-grid { grid-template-columns: 1.45fr 1fr; }
  .top-products-card { grid-column: 1 / -1; }
}
