@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/plus-jakarta-sans-400.woff2") format("woff2");
}
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/plus-jakarta-sans-500.woff2") format("woff2");
}
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/static/fonts/plus-jakarta-sans-600.woff2") format("woff2");
}
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/static/fonts/plus-jakarta-sans-700.woff2") format("woff2");
}

:root {
  --ink: #12241C;
  --ink-soft: #3d5348;
  --paper: #e7e2d4;
  --surface: #F3F0E4;
  --surface-2: #e7e2d4;
  --accent: #E3B12A;
  --accent-50: #e7efe9;
  --line: #d4ccb8;
  --action: #154B39;
  --action-ink: #ffffff;
  --money: #154B39;
  --warn: #6d4a08;
  --danger: #8e2f2f;
  --slate: #3d5348;
  --sidebar: #154B39;
  --shadow: 0 12px 40px rgba(18, 36, 28, 0.16);
  --sans: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  --r-field: 6px;
  --r-sheet: 10px;
  --space: 16px;
}

* { box-sizing: border-box; }
html { margin: 0; background: var(--paper); overscroll-behavior-y: none; }
[hidden] { display: none !important; }
body {
  margin: 0; padding: 0; max-width: 100%;
  min-height: 100%; height: auto; overflow: visible;
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 400;
  color: var(--ink);
  background: var(--paper);
  word-spacing: normal;
}
img, svg, video { max-width: 100%; height: auto; }
p, li, .lede, .hint, small {
  overflow-wrap: break-word;
  word-spacing: normal;
}
.nowrap, .data td.num { white-space: nowrap; }
a { color: var(--action); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { font-weight: 600; letter-spacing: normal; margin: 0; }
h1 { font-size: 1.5rem; line-height: 1.2; }
h2 { font-size: 1.05rem; }
p { line-height: 1.45; margin: 0 0 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
input:focus-visible, select:focus-visible, textarea:focus-visible, .chip:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--accent);
}
.skip {
  position: fixed; left: 8px; top: -40px; background: var(--surface); padding: 8px 12px; z-index: 50;
}
.skip:focus { top: 8px; }

.nav-toggle, .more-toggle {
  position: fixed; left: 0; top: 0; width: 1px; height: 1px; min-height: 0; margin: 0; padding: 0;
  opacity: 0; pointer-events: none; border: 0; overflow: hidden;
}
.layout { display: block; min-height: 100%; background: var(--paper); }
.topbar {
  display: flex; align-items: center; flex-wrap: nowrap; gap: 8px;
  position: sticky; top: 0; z-index: 40;
  background: var(--sidebar); color: #f3f5f7;
  height: 56px; min-height: 56px; max-height: 56px; padding: 0 10px;
  overflow: visible;
}
.hamburger { width: 44px; height: 44px; display: grid; place-content: center; gap: 5px; cursor: pointer; }
.hamburger span { display: block; width: 18px; height: 2px; background: #f3f5f7; }
.brand { display: flex; gap: 10px; align-items: center; color: inherit; text-decoration: none; }
.brand img.brand-icon { width: 32px; height: 32px; flex: 0 0 32px; }
.brand strong { font-weight: 700; letter-spacing: normal; }
.mark {
  width: 32px; height: 32px; display: grid; place-items: center;
  background: var(--action); color: white; font-weight: 700; border-radius: 6px;
}
.brand small { display: block; color: #b7c3ce; font-size: 0.75rem; font-weight: 450; }
.scrim { display: none; }
.side {
  position: fixed; inset: 0 auto 0 0; width: min(280px, 86vw); z-index: 30;
  background: var(--sidebar); color: #f3f5f7;
  transform: translateX(-105%);
  display: flex; flex-direction: column; padding: 16px 12px 24px; gap: 8px;
}
.nav-toggle:checked ~ .layout .side { transform: none; }
.nav-toggle:checked ~ .layout .scrim { display: block; position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 25; }
.side nav { display: flex; flex-direction: column; gap: 2px; margin-top: 12px; }
.side nav a, .tabbar a, .tabbar label {
  color: inherit; text-decoration: none; min-height: 44px;
  display: flex; align-items: center; padding: 0 12px; border-radius: 6px;
}
.side nav a.on { background: rgba(255, 255, 255, 0.08); }
.shop-switch, .logout { margin-top: auto; }
.shop-switch label, .shop-fixed { color: #b7c3ce; font-size: 0.8rem; }
.shop-fixed { padding: 8px 12px; }
.side select, .side button { color: #f3f5f7; border-color: #314556; }
.side button { background: #12352a; }
.side select {
  background-color: #12352a;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23F3F0E4' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  padding-right: 36px;
}
main {
  display: block; height: auto; min-height: 0; overflow: visible;
  background: var(--paper);
  padding: 16px 16px calc(56px + env(safe-area-inset-bottom, 0px) + 24px);
}
.example-banner {
  margin: 0 0 12px; padding: 8px 10px; background: #fff8e8; color: var(--warn);
  border: 1px solid #ead7a4; border-radius: 6px; font-size: 0.8rem;
}
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; background: var(--surface); border-top: 1px solid var(--line);
  min-height: 56px; padding-bottom: env(safe-area-inset-bottom, 0px);
}
.tabbar a, .tabbar label { flex: 1; justify-content: center; font-size: 0.8rem; color: var(--ink-soft); cursor: pointer; }
.tabbar a.on { color: var(--action); font-weight: 650; }

.page-head { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.page-head .lede, .hint { color: var(--ink-soft); font-size: 0.9rem; }
#order-box { overflow-wrap: normal; word-break: normal; white-space: normal; }
.head-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.search-row, .chip-row { display: flex; gap: 8px; align-items: center; min-width: 0; }
.search-row { flex: 1 1 240px; }
.chip-row { flex: 1 1 auto; flex-wrap: wrap; overflow: visible; }
.search { flex: 1 1 auto; min-width: 0; }
.search input { width: 100%; }
.sort { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: var(--ink-soft); min-width: 140px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 10px;
  background: #e7eef5; color: var(--ink); text-decoration: none; border-radius: 99px; font-size: 0.85rem;
  border: 0; box-shadow: inset 0 0 0 1px transparent;
}
.chip.on { color: var(--action); background: var(--accent-50); box-shadow: inset 0 0 0 2px var(--action); }
.badge {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--action); color: white; border-radius: 99px; font-size: 0.75rem; font-weight: 650;
}

.btn, button, .ghost, .primary, .danger {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 44px; padding: 8px 14px; border-radius: var(--r-field);
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  text-decoration: none; cursor: pointer; font-weight: 600;
}
.primary, button.primary { background: var(--action); color: var(--action-ink); border-color: var(--action); }
.danger, button.danger { background: var(--surface); color: var(--danger); border-color: #e2c2c2; }
.ghost { background: transparent; }
button[aria-busy="true"] { opacity: 0.7; }
button:disabled { opacity: 0.4; }
.fab {
  position: fixed; right: 16px; bottom: 76px; z-index: 18;
  width: 56px; height: 56px; border-radius: 28px;
  display: grid; place-items: center;
  background: var(--action); color: white; text-decoration: none; font-size: 1.6rem; font-weight: 500;
  box-shadow: var(--shadow);
}

input, select, textarea {
  width: 100%; min-height: 44px; padding: 10px 12px;
  border-radius: var(--r-field); border: 1px solid var(--line); background: var(--surface); font-size: 16px;
}
select {
  -webkit-appearance: none; appearance: none;
  padding-right: 36px;
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2312241C' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px 16px;
}
textarea { min-height: 96px; resize: vertical; }
input[aria-invalid="true"], textarea[aria-invalid="true"], select[aria-invalid="true"] { border-color: var(--danger); }
input[type="checkbox"], input[type="radio"] { width: 22px; min-width: 22px; min-height: 22px; padding: 0; accent-color: var(--action); }
label { display: grid; gap: 6px; font-size: 0.95rem; }
label.check { display: flex; align-items: center; gap: 10px; min-height: 44px; }
.field-error { color: var(--danger); font-size: 0.85rem; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sheet); padding: 12px; margin-bottom: 12px; }
.grid-form, .inline-form { display: grid; gap: 12px; grid-template-columns: 1fr; }
.grid-form .wide, .grid-form button, .grid-form .check { grid-column: 1 / -1; }
.actions { display: flex; flex-direction: column; gap: 8px; }
.actions form, .actions .ghost, .actions button { width: 100%; }

.toast {
  position: fixed; left: 16px; right: 16px; bottom: 76px; z-index: 35;
  margin: 0; padding: 12px 14px; border-radius: var(--r-sheet);
  background: var(--ink); color: white; box-shadow: var(--shadow);
}
.toast.ok { background: #143526; }
.toast.error { background: #4a1c1c; }
.toast.out { opacity: 0; }

.empty { color: var(--ink-soft); padding: 24px 8px; text-align: center; }
.empty strong { display: block; color: var(--ink); margin-bottom: 4px; }

.table-wrap { display: none; }
.card-list, .stack-list { display: flex; flex-direction: column; gap: 8px; }
.data { width: 100%; border-collapse: collapse; background: var(--surface); }
.data th, .data td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; font-size: 0.9rem; }
.data th { position: sticky; top: 0; background: #eef2f6; font-weight: 650; font-size: 0.8rem; color: var(--ink-soft); }
.data tbody:nth-child(even) .summary td { background: #f8fafc; }
.data .num, .num { text-align: right; font-variant-numeric: tabular-nums; font-weight: 650; }
.data .acc-detail { display: none; }
.data tbody:has(.acc-toggle:checked) .acc-detail { display: table-row; }
.data tbody:has(.acc-toggle:checked) .acc-detail .acc-body { display: block; }
.acc-toggle { position: absolute; width: 1px; height: 1px; opacity: 0; }
.acc { border: 1px solid var(--line); border-radius: var(--r-sheet); background: var(--surface); overflow: hidden; }
.acc-summary {
  display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center;
  min-height: 56px; padding: 10px 12px; cursor: pointer;
}
.acc-body { display: none; padding: 0 12px 12px; border-top: 1px solid var(--line); }
.acc-toggle:checked + .acc-summary + .acc-body,
.acc-toggle:checked + .acc-summary + form.acc-body { display: block; }
.thumb { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; background: var(--paper); }
.gallery { display: flex; gap: 8px; overflow-x: auto; margin: 8px 0; }
.gallery img, .previews img { width: 120px; height: 90px; object-fit: cover; border-radius: 6px; }
.muted { opacity: 0.55; }

.pill {
  display: inline-flex; align-items: center; min-height: 24px; padding: 2px 10px;
  border-radius: 99px; font-size: 0.75rem; font-weight: 600; background: #e7edf2; color: var(--slate);
  white-space: nowrap; max-width: 11rem; overflow: hidden; text-overflow: ellipsis; line-height: 1.2;
}
.status-paid, .status-delivered { background: #e5f3ea; color: var(--money); }
.status-awaiting_payment, .status-quoted, .status-awaiting_customer { background: #f8f0dc; color: var(--warn); }
.pill.web { background: #e5eef6; color: var(--action); }
.status-dispatched { background: #e5eef6; color: var(--action); }
.status-cancelled { background: #f8e8e8; color: var(--danger); }
.status-new { background: #e7edf2; color: var(--slate); }

.pager { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 12px 0; }
.pager a, .pager span {
  min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 6px; background: var(--surface); text-decoration: none; color: var(--ink); padding: 0 8px;
}
.pager a.on { background: var(--ink); color: white; border-color: var(--ink); }
.pager small { color: var(--ink-soft); }

.drawer-toggle { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drawer {
  display: none; position: fixed; z-index: 40; left: 0; right: 0; bottom: 0;
  max-height: 88vh; overflow: auto; background: var(--surface);
  border-radius: 16px 16px 0 0; box-shadow: var(--shadow); padding: 8px 16px 24px;
}
.drawer-scrim { display: none; position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 39; }
button.drawer-scrim, button.catalog-scrim { border: 0; padding: 0; min-height: 0; width: auto; background: rgba(20, 32, 43, 0.45); }
.drawer-scrim.is-open, .catalog-scrim.is-open { display: block; z-index: 47; }
.drawer.is-open { display: flex; flex-direction: column; overflow: hidden; max-height: none; }
.drawer form { display: flex; flex-direction: column; min-height: 0; flex: 1 1 auto; overflow: hidden; }
.drawer .fields { overflow-y: auto; flex: 1 1 auto; min-height: 0; }
.drawer-bar {
  flex: 0 0 auto; display: flex; gap: 8px; background: var(--surface);
  border-top: 1px solid var(--line); padding-top: 8px;
}
.drawer header { display: flex; justify-content: space-between; align-items: center; min-height: 48px; }
.drawer .fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.drawer .fields label.full, .drawer .fields h3 { grid-column: 1 / -1; margin: 8px 0 0; }
.drawer .fields input, .drawer .fields select { min-width: 0; }
.drawer h3 { margin: 12px 0 4px; font-size: 0.8rem; color: var(--ink-soft); font-weight: 650; }

.sheet-scrim { position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 40; }
.sheet {
  position: fixed; z-index: 41; inset: 0; background: var(--surface);
  display: flex; flex-direction: column; overflow: hidden;
}
.sheet-form { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.sheet-head, .sheet-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 16px; background: var(--surface); border-bottom: 1px solid var(--line); flex: 0 0 auto;
}
.sheet-foot { border-bottom: 0; border-top: 1px solid var(--line); }
.sheet-foot .btn, .sheet-foot button { flex: 1; }
.sheet-body { padding: 16px; display: grid; gap: 12px; overflow: auto; flex: 1; }
.sheet-body h3 { font-size: 0.8rem; color: var(--ink-soft); font-weight: 650; }
.drop {
  border: 1px dashed var(--line); border-radius: var(--r-sheet); padding: 16px; background: var(--paper); text-align: center;
}
.drop.over { border-color: var(--action); background: #e7eef5; }
.previews { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.import-toggle { position: absolute; width: 1px; height: 1px; opacity: 0; }
.import-pop { display: none; margin-bottom: 12px; }
.import-toggle:checked ~ .import-pop { display: grid; }

.kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 16px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sheet); padding: 12px; }
.kpi span, .kpi small { color: var(--ink-soft); font-size: 0.8rem; }
.kpi strong { display: block; font-size: 1.35rem; font-variant-numeric: tabular-nums; margin: 4px 0; }
.kpi-lead { grid-column: 1 / -1; }
.kpi-lead strong { font-size: 1.8rem; }
.kpi-sub { display: flex; flex-wrap: nowrap; gap: 6px; white-space: nowrap; }
.kpi-sub span { white-space: nowrap; }
.kpi-sub span + span::before { content: "· "; }
.bars { display: flex; align-items: end; gap: 8px; height: 120px; }
.bar { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: end; height: 100%; gap: 4px; }
.bar span { display: block; width: 100%; background: var(--action); border-radius: 3px 3px 0 0; min-height: 4px; }
.bar small, .bar b { font-size: 0.72rem; color: var(--ink-soft); font-weight: 500; }
.split { display: grid; gap: 12px; }
.stack { display: grid; gap: 12px; }
.totals { display: grid; gap: 6px; margin-top: 12px; }
.totals div { display: flex; justify-content: space-between; gap: 12px; }
.totals .grand { font-weight: 700; font-size: 1.1rem; border-top: 1px solid var(--line); padding-top: 8px; }
.proof, .qr-preview {
  width: 160px; height: 160px; max-width: 160px; object-fit: contain; display: block;
  border-radius: 6px; border: 1px solid var(--line); background: white;
}
.mini-log { list-style: none; padding: 0; margin: 0; }
.mini-log li, .log-msg { padding: 8px 0; border-bottom: 1px solid var(--line); white-space: pre-line; }
.thumb-dock { display: flex; flex-direction: column; gap: 8px; }
table.cards { width: 100%; border-collapse: collapse; }
table.cards thead { display: none; }
table.cards tr { display: block; border-bottom: 1px solid var(--line); padding: 8px 0; }
table.cards td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border: 0; }
table.cards td::before { content: attr(data-label); color: var(--ink-soft); flex: 0 0 40%; }

.public { display: grid; place-items: center; background: var(--paper); min-height: 100vh; min-height: 100dvh; }
.login-wrap { width: min(440px, calc(100% - 32px)); padding: 32px 0; }
.login-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sheet); padding: 24px; }
.login-brand { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; }
.login-brand img { width: 40px; height: 40px; }
.login-brand strong { font-size: 1.35rem; color: var(--action); }
.login-card .hint { margin-top: 12px; }
.login-card form { display: grid; gap: 12px; }
.login-card button { width: 100%; }
@media (max-width: 420px) {
  .public { place-items: stretch; }
  .login-wrap { width: 100%; padding: 0; }
  .login-card { min-height: 100dvh; border: 0; border-radius: 0; }
}
.hint code { background: var(--paper); padding: 1px 6px; border-radius: 4px; }

.thread-list { list-style: none; padding: 0; margin: 0; }
.thread-list a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: inherit; }
.thread-log { display: flex; flex-direction: column; gap: 10px; max-height: 520px; overflow: auto; }
.log-line { padding: 10px 12px; border-radius: 8px; background: var(--paper); }
.log-line.in { background: #e5f3ea; }
.log-line header { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--ink-soft); }
.reply-box textarea { margin: 8px 0; }

html:has(.sim-shell), body:has(.sim-shell) {
  height: 100svh; height: 100dvh; overflow: hidden;
}
.layout:has(.sim-shell) {
  height: 100svh; height: 100dvh; overflow: hidden;
  display: flex; flex-direction: column;
  padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px));
}
main:has(.sim-shell) {
  display: flex; flex-direction: column; overflow: hidden;
  overscroll-behavior: contain; padding: 0; flex: 1 1 auto; min-height: 0; height: auto;
}
main:has(.sim-shell) .page-head,
main:has(.sim-shell) .example-banner { display: none; }
.sim-shell { display: grid; gap: 12px; flex: 1 1 auto; min-height: calc(100dvh - 132px); height: 100%; overflow: hidden; }
.phone {
  position: relative; background: #efeae2; border: 1px solid var(--line); border-radius: var(--r-sheet);
  display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; height: 100%; overflow: hidden;
}
.phone > header {
  position: relative; z-index: 6;
  flex: 0 0 auto; display: flex; justify-content: space-between; align-items: center;
  background: var(--action); color: var(--surface); padding: 10px 12px; min-height: 56px;
  box-shadow: 0 18px 0 var(--action);
}
.phone header small { display: block; color: #d5dde5; font-size: 0.75rem; }
.phone .thread, #composer { background: transparent; }
.thread {
  position: relative; z-index: 1; contain: paint;
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: auto;
  padding: 12px; display: flex; flex-direction: column; gap: 8px;
}
.bubble { max-width: 82%; padding: 6px 8px 4px; border-radius: 8px; background: #fff; box-shadow: 0 1px 0 rgba(20, 32, 43, 0.06); }
.bubble.in { align-self: flex-start; border-top-left-radius: 2px; }
.bubble.out { align-self: flex-end; background: #d9fdd3; border-top-right-radius: 2px; }
.bubble.owner { background: #fff4d6; }
.bubble p { margin: 0; white-space: pre-wrap; line-height: 1.35; overflow-wrap: break-word; word-break: normal; }
.bubble p.link-line { display: block; }
.bubble p.gap { height: 8px; }
.bubble strong { font-weight: 700; }
.bubble img { display: block; width: 100%; max-height: 160px; object-fit: cover; border-radius: 6px; margin: 4px 0; }
.bubble time { display: block; text-align: right; font-size: 0.68rem; color: #667781; }
.choices { display: flex; flex-flow: row wrap; gap: 6px; margin-top: 8px; }
.choices button { text-align: center; background: #fff; color: #1f4e79; border: 1px solid #d5dde5; border-radius: 99px; font-weight: 650; width: auto; min-height: 36px; padding: 6px 12px; }
.thread-empty { margin: auto; text-align: center; color: #3d5348; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.thread-empty strong { font-size: 1rem; }
.wa-card { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; padding: 10px 12px; background: #fff; color: #1f4e79; border: 1px solid #d5dde5; border-radius: 12px; text-decoration: none; }
.wa-card b { font-size: 0.95rem; }
.wa-card small { color: #3d5348; font-weight: 450; word-break: break-all; }
a.wa-cta { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; padding: 8px 10px; text-align: center; background: #fff; color: #1f4e79; border: 1px solid #d5dde5; border-radius: 8px; font-weight: 650; text-decoration: none; }
a.token-link { display: block; margin-top: 6px; color: #1f4e79; font-size: 0.78rem; word-break: break-all; }
a.wa-cta svg { flex: 0 0 auto; }
.choices.wa-rows { flex-direction: column; }
.choices.wa-rows button { align-items: flex-start; text-align: left; flex-direction: column; gap: 2px; width: 100%; border-radius: 10px; }
.choices.wa-rows small { font-weight: 450; color: var(--ink-soft); font-size: 0.78rem; }
.choices button:disabled { color: #8aa0b3; background: #f3f5f7; }
.wa-list {
  position: absolute; left: 0; right: 0; bottom: 58px; z-index: 4; max-height: 70%;
  overflow: auto; background: #fff; border-radius: 12px 12px 0 0; box-shadow: var(--shadow);
}
.wa-list header { display: flex; justify-content: space-between; align-items: center; padding: 12px; border-bottom: 1px solid var(--line); background: #fff; color: var(--ink); }
.wa-list header button { background: transparent; color: var(--action); border: 0; }
#option-body { display: flex; flex-direction: column; }
#option-body button { display: grid; text-align: left; background: #fff; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; padding: 12px 16px; }
#option-body small { color: var(--ink-soft); }
#composer { flex: 0 0 auto; display: flex; gap: 8px; padding: 8px; background: #f3f5f7; border-top: 1px solid var(--line); }
#composer input { border-radius: 99px; background: #fff; }
.sim-tools, .sim-close, .sim-scrim { display: none; }
.sim-scrim { position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 28; }
.sim-close { margin-bottom: 8px; background: transparent; color: var(--action); border: 0; min-height: 44px; font-weight: 650; }
@media (max-width: 899px) {
  .sim-shell { display: flex; flex-direction: column; height: calc(100dvh - 112px); min-height: calc(100dvh - 112px); overflow: hidden; }
  .phone { flex: 1 1 auto; height: auto; min-height: 0; overflow: hidden; }
  .sim-tools {
    display: inline-flex; align-items: center; min-height: 32px; padding: 0 10px;
    border: 1px solid rgba(255, 255, 255, 0.45); border-radius: 99px;
    background: transparent; color: #f3f5f7; font-size: 0.8rem;
  }
  .sim-scrim:not([hidden]) { display: block; }
  .sim-side { display: none; }
  .sim-side.open .sim-close { display: inline-flex; }
  .sim-side.open {
    display: block; position: fixed; z-index: 30; left: 8px; right: 8px;
    bottom: calc(56px + 8px); max-height: min(70dvh, 520px); overflow: auto;
    background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
    padding: 12px; box-shadow: var(--shadow);
  }
}
.help-card { border: 1px solid var(--line); border-radius: 10px; background: var(--surface); margin-top: 10px; }
.help-card summary { min-height: 40px; display: flex; align-items: center; padding: 0 12px; cursor: pointer; font-weight: 650; }
.help-card summary::-webkit-details-marker { display: none; }
.sim-actions { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 12px 12px; }
.sim-actions button { min-height: 32px; padding: 0 10px; font-size: 0.82rem; width: auto; }
.help-steps { margin: 0; padding: 0 12px 12px 32px; color: var(--ink-soft); display: grid; gap: 6px; }
.help-steps li { overflow-wrap: anywhere; }
.order-detail, .order-detail p, .order-detail a, .order-detail dd { overflow-wrap: anywhere; min-width: 0; max-width: 100%; }
.split { min-width: 0; }
.place-map {
  position: relative; z-index: 0; isolation: isolate; contain: paint;
  display: block; clear: both; overflow: hidden;
  height: 220px; width: 100%; max-width: 100%; margin-top: 12px;
  border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2);
}
.leaflet-container { position: relative; z-index: 0; width: 100%; max-width: 100%; }
.leaflet-container img, .leaflet-container svg { max-width: none !important; max-height: none !important; }
.shop-pin { background: none; border: 0; }
.shop-pin span { display: block; width: 28px; height: 34px; line-height: 0; filter: drop-shadow(0 2px 3px rgba(18, 36, 28, 0.45)); }
.shop-pin svg { display: block; width: 28px; height: 34px; }
@media (min-width: 900px) { .place-map { height: 300px; } }
#confirm { border: 0; border-radius: var(--r-sheet); padding: 16px; max-width: 360px; box-shadow: var(--shadow); }
#confirm::backdrop { background: rgba(20, 32, 43, 0.45); }
#confirm menu { display: flex; gap: 8px; justify-content: flex-end; padding: 0; margin: 12px 0 0; }

@media (min-width: 900px) {
  .topbar, .tabbar, .hamburger, .scrim, .fab { display: none; }
  .layout { display: grid; grid-template-columns: 248px minmax(0, 1fr); align-items: start; }
  .side select { font-size: 14px; }
  .side {
    position: sticky; top: 0; transform: none; width: auto;
    height: 100vh; height: 100dvh; min-height: 0;
    overflow-y: auto; overscroll-behavior: contain;
  }
  main { height: auto; overflow: visible; padding: 28px 32px 48px; }
  .page-head { flex-direction: row; align-items: flex-end; justify-content: space-between; }
  .kpis { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
  .kpi-lead { grid-column: auto; }
  .grid-form { grid-template-columns: repeat(3, 1fr); }
  .split { grid-template-columns: 1.3fr 0.9fr; align-items: start; }
  .actions { flex-direction: row; flex-wrap: wrap; }
  .actions form, .actions .ghost, .actions button { width: auto; }
  .table-wrap { display: block; }
  .card-list { display: none; }
  .panel .card-list { display: flex; flex-direction: column; gap: 8px; }
  .stack-list { display: flex; }
  .head-actions { flex-wrap: nowrap; justify-content: flex-end; }
  table.cards { border-collapse: collapse; }
  table.cards thead { display: table-header-group; }
  table.cards tr { display: table-row; border: 0; padding: 0; }
  table.cards td { display: table-cell; border-bottom: 1px solid var(--line); padding: 8px; }
  table.cards td::before { content: none; }
  .sheet { inset: 0 0 0 auto; width: min(440px, 100%); box-shadow: var(--shadow); }
  .drawer {
    left: auto; top: 0; bottom: 0; width: min(400px, 100%); max-height: none;
    border-radius: 0; padding: 16px 20px 32px;
  }
  html:has(.sim-shell), body:has(.sim-shell) { height: 100dvh; overflow: hidden; }
  .layout:has(.sim-shell) { height: 100dvh; display: grid; align-items: stretch; padding-bottom: 0; overflow: hidden; }
  main:has(.sim-shell) { height: 100%; min-height: 0; max-height: none; padding: 16px 24px; overflow: hidden; }
  main:has(.sim-shell) .app-body { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
  .sim-shell { grid-template-columns: minmax(420px, 1fr) 300px; align-items: stretch; min-height: 0; }
  .thumb-dock { position: static; }
}

.more-toggle { position: fixed; width: 1px; height: 1px; min-height: 0; opacity: 0; }
.more-toggle:checked ~ .more-scrim { display: block; }
.more-toggle:checked ~ .more-sheet { display: flex; flex-direction: column; }
.tabbar svg { width: 22px; height: 22px; fill: currentColor; }
.tabbar a, .tabbar label { flex-direction: column; gap: 2px; justify-content: center; font-size: 0.68rem; line-height: 1.1; text-align: center; }
.tabbar { min-height: 56px; height: auto; padding-bottom: env(safe-area-inset-bottom); }
.more-links { display: flex; flex-direction: column; }
.more-links a { min-height: 44px; display: flex; align-items: center; color: inherit; text-decoration: none; border-bottom: 1px solid var(--line); }
.demo-pill { display: none; position: relative; flex: 0 0 auto; align-self: center; }
.top-shop, .shop-chip { margin-left: auto; min-width: 0; flex: 1 1 72px; max-width: 46%; }
.shop-chip {
  height: 32px; min-height: 32px; margin-bottom: 0; padding: 0 10px;
  display: flex; align-items: center;
  background: #12352a; color: #F3F0E4; border: 1px solid rgba(243, 240, 228, 0.35); border-radius: 8px;
  font-size: 0.8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.readonly-badge {
  flex: 0 0 auto; align-self: center; height: 22px; min-height: 22px; padding: 0 8px;
  font-size: 0.68rem; line-height: 22px; background: #F3F0E4; color: #12241C;
}
.top-shop select {
  width: 100%; min-width: 0; min-height: 32px; height: 32px; padding: 0 28px 0 10px;
  background-color: #12352a; color: #F3F0E4; color-scheme: dark;
  border: 1px solid rgba(243, 240, 228, 0.35);
  font-size: 0.8rem;
  text-overflow: ellipsis;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23F3F0E4' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 14px 14px;
}
.demo-pill summary { list-style: none; height: 22px; min-height: 22px; display: inline-flex; align-items: center; padding: 0 8px; border-radius: 99px; background: #fff8e8; color: var(--warn); cursor: pointer; font-size: 0.68rem; }
.demo-pill summary::-webkit-details-marker { display: none; }
.demo-pill p { position: absolute; right: 0; top: 48px; width: min(260px, calc(100vw - 32px)); background: var(--surface); color: var(--ink); border: 1px solid var(--line); padding: 10px; border-radius: 8px; z-index: 30; }
.quick { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.quick .chip { min-height: 44px; }
.order-card {
  display: flex; flex-direction: column; gap: 4px; align-items: stretch;
  width: 100%; min-width: 0; padding: 12px; margin: 0;
  border: 1px solid var(--line); border-radius: 14px; background: var(--surface);
  color: inherit; text-decoration: none; text-align: left;
}
.oc-top, .oc-mid { display: flex; align-items: center; gap: 8px; min-width: 0; }
.oc-top .row-title { flex: 1 1 auto; min-width: 0; white-space: normal; overflow: visible; text-overflow: clip; }
.oc-mid .row-meta, .oc-mid .pill { flex: 0 0 auto; white-space: nowrap; }
.oc-phone { color: var(--ink-soft); font-size: 0.85rem; white-space: nowrap; }
.pair-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 8px;
  row-gap: 2px;
  align-items: center;
  min-width: 0;
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  text-align: left;
}
.row-title, .row-meta { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-title { font-weight: 700; }
.row-meta { color: var(--ink-soft); font-size: 0.82rem; }
.row-amount, .row-pill { white-space: nowrap; justify-self: end; }
.row-amount { font-variant-numeric: tabular-nums; font-weight: 700; }
.row-pill .pill { display: inline-block; vertical-align: bottom; max-width: 11rem; }
.card-list .line-name { font-size: 1rem; }
.kv { display: flex; justify-content: space-between; gap: 12px; min-width: 0; padding: 8px 0; border-bottom: 1px solid var(--line); }
.kv span:first-child { color: var(--ink-soft); flex: 0 0 auto; }
.kv span:last-child { min-width: 0; text-align: right; overflow-wrap: anywhere; }
.mini-lines { display: grid; gap: 6px; margin: 12px 0; }
.mini-lines > div, .mini-total { display: flex; justify-content: space-between; gap: 12px; min-width: 0; }
.mini-lines span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-lines span:last-child, .mini-total span:last-child { font-variant-numeric: tabular-nums; white-space: nowrap; }
.mini-total { font-weight: 700; border-top: 1px solid var(--line); padding-top: 8px; }
.sheet-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; }
.sheet-actions {
  display: flex; gap: 8px; margin-top: auto; position: sticky; bottom: 0; z-index: 2;
  background: var(--surface); padding: 12px 0 0; border-top: 1px solid var(--line);
}
.sheet-actions > *, .sheet-actions form { flex: 1 1 0; min-width: 0; }
.sheet-actions .btn, .sheet-actions button, .sheet-actions a {
  width: 100%; min-height: 44px; justify-content: center; white-space: nowrap; padding-left: 10px; padding-right: 10px;
}
.sheet-secondary .btn, .sheet-secondary a, .sheet-secondary button {
  width: auto; min-height: 40px; justify-content: center; white-space: nowrap; padding-left: 14px; padding-right: 14px;
}
.sheet-secondary { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 4px; justify-content: flex-start; }
.sheet-secondary > * { flex: 0 1 auto; width: auto; min-width: 8.5rem; text-decoration: none; }
.add-btn { font-size: 1.4rem; font-weight: 700; line-height: 1; padding: 0; }
.sheet-title { flex: 1 1 auto; min-width: 0; margin: 0; font-size: 1.05rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sheet-handle { display: block; width: 36px; height: 4px; border-radius: 99px; background: var(--line); margin: 8px auto 0; }
#new-msgs {
  position: absolute; left: 50%; bottom: 64px; transform: translateX(-50%); z-index: 5;
  min-height: 32px; padding: 0 12px; border-radius: 99px; background: var(--action); color: #F3F0E4; border: 0;
}
.card-list .line-key { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.radio-cards { display: grid; gap: 8px; }
.radio-card { display: flex; gap: 10px; align-items: flex-start; min-height: 44px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.radio-card input { margin-top: 4px; }
.radio-card small { display: block; color: var(--ink-soft); font-weight: 450; }
.radio-card:has(input:checked) { border-color: var(--action); background: #e7eef5; }
form.envio .only-yango, form.envio .only-peya { display: none; }
form.envio:has(input[value="yango"]:checked) .only-yango,
form.envio:has(input[value="pedidosya"]:checked) .only-peya { display: grid; gap: 12px; margin-top: 12px; }
.status-card header { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.copy-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.copy-row code, .tech code { overflow-wrap: anywhere; word-break: break-all; }
.tech { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.tech summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; font-weight: 650; }
.guide { padding-left: 1.2rem; display: grid; gap: 8px; }
.fab { width: auto; height: 36px; padding: 0 14px; border-radius: 18px; font-size: 0.9rem; bottom: calc(56px + env(safe-area-inset-bottom, 0px) + 12px); z-index: 26; }
main:has(.fab) { padding-bottom: calc(56px + 88px + env(safe-area-inset-bottom, 0px)); }
main:has(.pager-compact) { padding-bottom: calc(56px + 72px + env(safe-area-inset-bottom, 0px)); }
main:has(.fab):has(.pager-compact) { padding-bottom: calc(56px + 140px + env(safe-area-inset-bottom, 0px)); }
main:has(.pager-compact) .fab { bottom: calc(56px + 64px + env(safe-area-inset-bottom, 0px)); }
.icon-btn { position: relative; width: 44px; height: 44px; min-height: 44px; padding: 0; flex: 0 0 44px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.icon-btn svg { width: 22px; height: 22px; fill: currentColor; }
.icon-btn .badge { position: absolute; top: -4px; right: -4px; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pair-actions { display: flex; gap: 8px; margin-top: 12px; }
.pair-actions button { flex: 1; }
.drawer-form { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.drawer-bar { display: flex; gap: 8px; padding-top: 12px; background: var(--surface); border-top: 1px solid var(--line); }
.drawer-bar .btn, .drawer-bar button { flex: 1; }
.pop { display: block; }
.tech summary::-webkit-details-marker { display: none; }
.tech summary::before { content: ""; width: 8px; height: 8px; margin-right: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); }
.tech[open] summary::before { transform: rotate(45deg); margin-top: -4px; }
.read-detail .thumb { width: 72px; height: 72px; }
.thumb-slot { width: 40px; height: 40px; display: inline-grid; place-items: center; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-soft); overflow: hidden; flex: 0 0 40px; }
.thumb-slot img { width: 100%; height: 100%; object-fit: cover; }
.thumb-slot svg { width: 22px; height: 22px; }
.detail-photo { width: 100%; max-height: 220px; aspect-ratio: 4 / 3; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: grid; place-items: center; color: var(--ink-soft); margin-bottom: 12px; }
.detail-photo img { width: 100%; height: 100%; max-height: 220px; object-fit: cover; }
.detail-photo svg { width: 48px; height: 48px; }
.card-list .acc-summary { display: flex; flex-direction: column; align-items: stretch; gap: 2px; }
.card-list .acc-summary:has(.thumb-slot) { display: grid; grid-template-columns: 44px 1fr; align-items: center; gap: 4px; }
.card-list .acc-summary:has(.thumb-slot) .thumb-slot { grid-row: 1 / span 2; }
.card-list .acc-summary:has(.thumb-slot) .line-name,
.card-list .acc-summary:has(.thumb-slot) .line-key { grid-column: 2; }
.line-meta { color: var(--ink-soft); font-size: 0.8rem; }
.product-hit, .customer-hit, .order-row, .order-hit { cursor: pointer; }
button.linkish { background: none; border: 0; padding: 0; color: var(--action); font: inherit; font-weight: 650; cursor: pointer; text-align: left; }
.card-list article.order-row {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 12px; border: 1px solid var(--line); border-radius: 14px; margin-bottom: 8px; background: var(--surface);
}
.card-list article.pair-card,
.sheet-scroll button.pair-card,
button.pair-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  width: 100%;
}
.data tbody tr.order-row.is-selected td { background: var(--accent-50); box-shadow: none; }
.data tbody tr.order-row.is-selected td:first-child { box-shadow: inset 3px 0 0 var(--action); }
#order-panel .panel-detail { overflow: auto; flex: 1; min-height: 0; }
#ord-sheet .panel-head, #cust-sheet .panel-head { justify-content: space-between; }
.demo-wrap { max-width: 1100px; margin: 0 auto; padding: 20px 16px 48px; }
.demo-split { display: grid; gap: 16px; }
.demo-split .phone { height: 640px; max-height: 72dvh; }
.demo-orders { display: grid; gap: 8px; }
.demo-order { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: var(--surface); display: grid; gap: 6px; }
.demo-order header { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
@media (min-width: 900px) {
  .demo-split { grid-template-columns: minmax(300px, 380px) 1fr; align-items: start; }
}
.who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.who b, .who small, .who h2, .who p { display: block; margin: 0; }
.who small, .who p { color: var(--ink-soft); font-size: 0.78rem; font-weight: 500; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center; background: var(--accent-50); color: var(--action);
  font-weight: 700; font-size: 0.8rem;
}
.data tbody tr.customer-hit.is-selected td { background: var(--accent-50); box-shadow: none; }
.data tbody tr.customer-hit.is-selected td:first-child { box-shadow: inset 3px 0 0 var(--action); }
.card-list article.customer-hit {
  display: flex; flex-wrap: nowrap; justify-content: space-between; gap: 8px; align-items: center;
  padding: 12px; border: 1px solid var(--line); border-radius: 14px; margin-bottom: 8px; background: var(--surface);
}
.card-list article.customer-hit .who { flex: 1 1 auto; min-width: 0; }
.card-list article.pair-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  justify-content: stretch;
}
.card-list article.customer-hit .line-key,
.card-list article.order-row .line-key {
  margin-left: auto; display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  justify-content: flex-end; white-space: nowrap; flex: 0 0 auto;
}
.avatar svg { width: 18px; height: 18px; }
button.pair-card.order-hit {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 8px;
  row-gap: 2px;
  align-items: center;
  width: 100%;
  margin: 0 0 8px;
  text-align: left;
}
#cust-body h2, #cust-sheet-body h2 { margin: 0 0 4px; font-size: 1.15rem; }
#cust-body h3, #cust-sheet-body h3 { margin: 16px 0 6px; font-size: 0.8rem; color: var(--ink-soft); }
#customer-panel .panel-detail { overflow: auto; flex: 1; min-height: 0; }
#cust-sheet .panel-head { justify-content: space-between; }
.data tbody tr.product-hit.is-selected td { background: var(--accent-50); box-shadow: none; }
.data tbody tr.product-hit.is-selected td:first-child { box-shadow: inset 3px 0 0 var(--action); }
@media (min-width: 900px) {
  .catalog-page .sort.desk-only { font-size: 0.85rem; gap: 8px; min-width: 0; }
  .catalog-page .sort.desk-only select { max-width: 11rem; font-size: 0.9rem; }
}
.pager-inline { margin: 0; }
.pager-inline a, .pager-inline span { min-width: 0; min-height: 40px; padding: 0 8px; }
.dual-read { margin: 0 0 6px; font-variant-numeric: tabular-nums; font-weight: 650; }
.dual-sliders { position: relative; height: 28px; margin: 4px 0 14px; }
.dual-sliders::before { content: ""; position: absolute; left: 8px; right: 8px; top: 12px; height: 4px; background: var(--line); border-radius: 99px; }
.dual-fill { position: absolute; top: 12px; height: 4px; background: var(--action); border-radius: 99px; }
.dual-sliders input[type="range"] { position: absolute; left: 0; width: 100%; height: 28px; min-height: 0; padding: 0; margin: 0; background: transparent; pointer-events: none; -webkit-appearance: none; appearance: none; }
.dual-sliders input[type="range"]::-webkit-slider-runnable-track { height: 4px; background: transparent; }
.dual-sliders input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; pointer-events: auto; width: 18px; height: 18px; margin-top: -7px; border-radius: 50%; background: var(--action); border: 2px solid #fff; box-shadow: 0 1px 3px rgba(20, 32, 43, 0.28); }
.dual-sliders input[type="range"]::-moz-range-track { height: 4px; background: transparent; }
.dual-sliders input[type="range"]::-moz-range-thumb { pointer-events: auto; width: 18px; height: 18px; border-radius: 50%; background: var(--action); border: 2px solid #fff; box-shadow: 0 1px 3px rgba(20, 32, 43, 0.28); }
.choice-row { display: flex; flex-wrap: wrap; gap: 6px; }
.choice { position: relative; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); cursor: pointer; }
.choice input { position: absolute; width: 1px; height: 1px; min-width: 0; min-height: 0; opacity: 0; }
.choice .tick { display: none; width: 14px; height: 14px; }
.choice:has(input:checked) { background: var(--accent-50); border-color: var(--action); color: var(--action); }
.choice:has(input:checked) .tick { display: block; }
.flag-row { display: grid; gap: 0; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.switch input[type="checkbox"] { appearance: none; width: 44px; min-width: 44px; height: 26px; min-height: 26px; padding: 0; border: 0; border-radius: 99px; background: var(--line); position: relative; }
.switch input[type="checkbox"]::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(20, 32, 43, 0.25); }
.switch input[type="checkbox"]:checked { background: var(--action); }
.switch input[type="checkbox"]:checked::after { transform: translateX(18px); }
.pager-seg { display: inline-flex; height: 40px; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--surface); }
.pager-seg a, .pager-seg span { min-width: 36px; min-height: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; padding: 0 10px; border: 0; border-radius: 0; border-right: 1px solid var(--line); background: transparent; text-decoration: none; color: var(--ink); }
.pager-seg a:last-child { border-right: 0; }
.back-link { align-self: flex-start; border: 0; background: transparent; color: var(--action); min-height: 36px; padding: 0; font-weight: 650; cursor: pointer; text-decoration: none; }
.back-link::before { content: "‹ "; }
.page-head.detail-head { display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 4px; padding: 0 0 8px; }
.title-row { display: flex; align-items: center; justify-content: flex-start; gap: 10px; flex-wrap: wrap; width: 100%; }
.title-row h1 { margin: 0; }
.title-row .actions { margin-left: auto; flex-direction: row; width: auto; }
.title-row .actions a, .title-row .actions .btn { width: auto; }
.icon-x { width: 44px; height: 44px; border: 0; background: transparent; font-size: 1.4rem; cursor: pointer; }
.spec { display: grid; gap: 8px; margin: 0 0 12px; }
.spec div { display: flex; justify-content: space-between; gap: 12px; }
.spec dt { color: var(--ink-soft); }
.spec dd { margin: 0; text-align: right; }
.mobile-scrim { display: none; position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 45; }
.mobile-scrim.open { display: block; }
.mobile-detail { display: none; position: fixed; z-index: 46; left: 0; right: 0; bottom: 0; max-height: 85vh; overflow: hidden; background: var(--surface); border-radius: 16px 16px 0 0; box-shadow: var(--shadow); padding: 0 16px 16px; }
.mobile-detail.open { display: flex; flex-direction: column; }
#mobile-detail .panel-head { justify-content: flex-end; }
.catalog-panel .fields { display: grid; gap: 4px; }
.catalog-panel .fields h3 { margin: 10px 0 4px; font-size: 0.8rem; color: var(--ink-soft); }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 44px; background: var(--surface); position: sticky; top: 0; z-index: 1; }
.panel-detail[hidden], .panel-filters[hidden] { display: none; }

@media (max-width: 899px) {
  .hamburger, .side, .scrim { display: none !important; }
  .drawer-toggle:checked ~ .drawer {
    bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    max-height: min(100dvh - 68px, 88dvh);
  }
  .example-banner { display: none; }
  .demo-pill { display: flex; align-items: center; }
  .fab { display: none !important; }
  .search-row { align-items: center; }
  .search input, .fields input, .fields select, .drawer-form input, .drawer-form select {
    height: 44px; min-height: 44px;
  }
  .sort-chip { flex: 0 0 auto; height: 44px; min-height: 44px; padding: 0 12px; background: var(--surface); border: 1px solid var(--line); }
  .icon-btn { width: 44px; height: 44px; }
  .pager-compact {
    position: sticky; bottom: calc(56px + env(safe-area-inset-bottom, 0px)); z-index: 25;
    margin: 8px -16px 0; height: 52px; padding: 0 16px;
    display: flex; align-items: center; justify-content: center; gap: 0;
    background: var(--paper);
  }
  main:has(.fab) .card-list,
  main:has(.fab) .table-wrap { margin-bottom: calc(132px + env(safe-area-inset-bottom, 0px)); }
.mobile-detail {
    bottom: calc(64px + env(safe-area-inset-bottom, 0px));
    max-height: min(85vh, calc(100dvh - 76px - env(safe-area-inset-bottom, 0px)));
  }
  .card-list .acc-summary:has(.thumb-slot) { grid-template-columns: 44px 1fr; }
  .card-list .line-key { justify-content: flex-start; }
  .card-list .thumb-slot { width: 44px; height: 44px; flex-basis: 44px; }
  .desk-only { display: none !important; }
  .pager-full { display: none; }
  .pager-compact a, .pager-compact span {
    min-width: 72px; min-height: 36px; height: 36px; padding: 0 14px; margin: 0;
    border: 1px solid var(--line); border-radius: 0; background: var(--surface); color: var(--ink);
  }
  .pager-compact > :first-child { border-radius: 6px 0 0 6px; }
  .pager-compact > :not(:first-child) { margin-left: -1px; }
  .pager-compact > :last-child { border-radius: 0 6px 6px 0; }
  .chip-row { overflow: visible; flex-wrap: wrap; gap: 6px; }
  .chip-row .chip { flex: 0 1 auto; min-height: 36px; padding: 0 8px; font-size: 0.78rem; }
  .kpi-lead { grid-column: 1 / -1; }
  .kpi-lead strong { font-size: 1.2rem; }
}
@media (max-width: 480px) {
  .topbar .brand strong { display: none; }
}
@media (max-width: 899px) {
  main { padding-left: 16px; padding-right: 16px; }
  .page-head {
    position: static; background: transparent;
    flex-direction: row; align-items: center; justify-content: space-between;
    margin: 0 0 8px; padding: 0;
  }
  .page-head:not(.detail-head) .lede, .head-extra { display: none; }
  .page-head h1 { font-size: 1.15rem; white-space: nowrap; }
  .page-head.detail-head {
    flex-direction: column; align-items: stretch; justify-content: flex-start;
    width: 100%; max-width: 100%; margin: 0 0 8px; padding: 4px 0 8px;
  }
  .page-head.detail-head h1 { white-space: normal; overflow-wrap: anywhere; }
  .page-head.detail-head .title-row { min-width: 0; max-width: 100%; }
  .page-head.detail-head .title-row h1 { flex: 1 1 auto; min-width: 0; }
  .page-head > .pill { flex: 0 0 auto; white-space: nowrap; }
  .toolbar { flex-direction: column; align-items: stretch; gap: 8px; margin-bottom: 8px; }
  .search-row, .chip-row { width: 100%; }
  .search-row { flex: 0 0 auto; }
}
@media (max-width: 899px) {
  .drawer.is-open {
    position: fixed; z-index: 40; left: 0; right: 0; top: 0;
    bottom: calc(64px + env(safe-area-inset-bottom, 0px));
    border-radius: 0; background: var(--surface); padding: 8px 16px 12px;
  }
  .catalog-panel { display: none; }
  .catalog-panel.is-open {
    display: flex; flex-direction: column; position: fixed; z-index: 48;
    left: 0; right: 0; top: 48px; bottom: calc(64px + env(safe-area-inset-bottom, 0px));
    max-height: none; overflow: hidden;
    background: var(--surface); border-radius: 0; box-shadow: none;
    padding: 8px 16px 12px;
  }
  .catalog-panel.is-open > .panel-filters,
  .drawer.is-open {
    display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; overflow: hidden;
  }
  .catalog-panel form, .drawer.is-open form { display: flex; flex-direction: column; min-height: 0; flex: 1 1 auto; overflow: hidden; }
  .catalog-panel .fields { overflow-y: auto; flex: 1 1 auto; min-height: 0; }
  .catalog-panel .drawer-bar { flex: 0 0 auto; position: sticky; bottom: 0; background: var(--surface); padding-top: 8px; border-top: 1px solid var(--line); }
}
@media (min-width: 900px) {
  .more-sheet, .more-scrim, .more-toggle, .phone-only { display: none !important; }
  .pager-compact { display: none; }
  .catalog-page { margin-right: 0; }
  .catalog-panel { display: none; }
  .catalog-scrim.is-open, .drawer-scrim.is-open { display: block; z-index: 60; }
  .catalog-panel.is-open, .drawer.is-open {
    display: flex; flex-direction: column; position: fixed; z-index: 70;
    top: 0; right: 0; bottom: 0; left: auto; width: min(400px, 100%);
    max-height: none; overflow: hidden; background: var(--surface);
    border-left: 1px solid var(--line); box-shadow: var(--shadow); padding: 16px;
  }
  .catalog-panel.is-open > .panel-filters, .drawer.is-open { min-height: 0; }
  .catalog-panel form, .drawer.is-open form { display: flex; flex-direction: column; min-height: 0; flex: 1; overflow: hidden; }
  .catalog-panel .fields, .drawer.is-open .fields { overflow: auto; flex: 1 1 auto; min-height: 0; }
  .toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; }
  .search-row { flex: 1 1 100%; min-width: 0; display: flex; align-items: center; gap: 8px; }
  .search { flex: 1 1 auto; min-width: 0; }
  .search input { width: 100%; }
  .chip-row { flex: 1 1 100%; flex-wrap: wrap; }
  .btn, .chip, .pill, button { white-space: nowrap; }
  .data { width: 100%; }
  .data td:first-child, .data th:first-child { white-space: nowrap; }
  .data .acc-detail { display: none !important; }
  .catalog-page .toolbar { flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; }
  .catalog-page .search-row { flex: 1 1 100%; height: auto; }
  .catalog-page .search input,
  .catalog-page .toolbar .btn,
  .catalog-page .sort select,
  .catalog-page .chip-row .chip { height: 40px; min-height: 40px; }
  .catalog-page .sort { flex-direction: row; align-items: center; min-width: 0; }
}

html:has(.mobile-detail.open),
html:has(.sim-side.open),
html:has(.sheet) { overflow: hidden; }

.file-pick { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.file-native {
  position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; margin: 0;
  opacity: 0; overflow: hidden; border: 0;
}
.file-pick > span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: var(--r-field); background: var(--surface);
  font-weight: 650; cursor: pointer;
}
.file-pick em { color: var(--ink-soft); font-style: normal; font-size: 0.85rem; }
.drop .file-native { position: absolute; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

.store-page { max-width: 1240px; margin: 0 auto; padding: 16px 16px 108px; }
.store-page main { padding: 0; background: transparent; }
.store-head { display: grid; gap: 8px; margin-bottom: 16px; }
.store-head .lede { color: var(--ink-soft); margin: 0; }
.store-credit {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin: 28px 0 72px; color: var(--ink-soft); font-size: 0.85rem;
}
.store-credit img { width: 20px; height: 20px; }
.share-url { overflow-wrap: break-word; word-break: normal; }
#ord-body .drawer-links, #ord-sheet-body .drawer-links,
#cust-body .drawer-links, #cust-sheet-body .drawer-links {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px;
}
.drawer-links a, .drawer-links .btn {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--surface); text-decoration: none;
}
.store-chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.store-chips button { flex: 0 0 auto; border-radius: 99px; min-height: 40px; background: var(--surface); }
.store-chips button.on { background: var(--action); color: white; border-color: var(--action); }
.product-grid { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
.product {
  display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: start;
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px;
}
.product img, .product .ph {
  width: 72px; height: 72px; object-fit: cover; border-radius: 8px; background: var(--surface-2);
}
.product .ph { display: grid; place-items: center; }
.product .ph svg { width: 62%; height: 62%; max-width: 84px; max-height: 84px; }
.tone-cable { background: #e7eef5; color: #1f4e79; }
.tone-power { background: #f8f0dc; color: #8a5a12; }
.tone-audio { background: #e5f3ea; color: #1b6b3a; }
.tone-light { background: #fff4d6; color: #9a6b00; }
.tone-tool { background: #f8e8e8; color: #8d3b32; }
.tone-misc { background: #eef2f6; color: #3e5163; }
.product h2 { font-size: 1rem; line-height: 1.25; text-wrap: balance; }
.product .desc {
  color: var(--ink-soft); font-size: 0.88rem; margin: 4px 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.product .desc.open { display: block; -webkit-line-clamp: unset; }
.product .more { background: transparent; border: 0; color: var(--action); min-height: 32px; padding: 0; font-weight: 650; }
.product .price, .cart-body .price { color: var(--money); font-weight: 700; margin: 0 0 8px; }
.stepper { display: flex; align-items: center; gap: 8px; }
.stepper button { width: 44px; min-width: 44px; padding: 0; }
.stepper b { min-width: 1.6rem; text-align: center; }
.cart-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: var(--surface); border-top: 1px solid var(--line);
  box-shadow: 0 -8px 18px rgba(20, 32, 43, 0.08);
}
.cart-bar strong { color: var(--money); font-size: 1.05rem; }
.cart-scrim { position: fixed; inset: 0; background: rgba(20, 32, 43, 0.45); z-index: 28; }
.cart-scrim[hidden] { display: none; }
.cart-dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: none; flex-direction: column; overflow: hidden;
  max-height: min(92dvh, 760px);
  background: var(--surface); border-radius: 16px 16px 0 0;
  box-shadow: 0 -8px 28px rgba(20, 32, 43, 0.18);
}
.cart-dock.open { display: flex; }
.cart-dock header, .dock-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
}
.cart-body { overflow: auto; flex: 1 1 auto; min-height: 0; padding: 12px 16px 16px; }
.dock-foot {
  flex: 0 0 auto; display: grid; gap: 8px;
  padding: 8px 16px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line); background: var(--surface);
}
.dock-foot:empty { display: none; }
.dock-foot .primary, .dock-foot .ghost, #geo-btn { width: 100%; }
.cart-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.cart-line p { margin: 0; }
.segment { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 4px 0 8px; }
.segment label {
  position: relative; display: grid; place-items: center; min-height: 44px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--surface);
}
.segment input { position: absolute; width: 1px; min-width: 1px; height: 1px; min-height: 1px; opacity: 0; }
.segment label:has(input:checked) { background: var(--accent-50); box-shadow: inset 0 0 0 2px var(--action); color: var(--action); }
.addr-box { background: var(--accent-50); border-radius: 10px; padding: 12px; margin: 8px 0 12px; }
.addr-box strong { display: block; font-size: 1.05rem; line-height: 1.35; }
.addr-box a { display: inline-block; margin-top: 6px; }
.pin-coords { display: block; white-space: nowrap; font-weight: 650; }
.dock-foot a.primary { text-decoration: none; }
.checkout { display: grid; gap: 12px; }
.checkout textarea { min-height: 72px; }
.checkout .primary, .summary-actions .primary, .summary-actions .ghost { width: 100%; }
.summary-actions { display: grid; gap: 8px; }
.catalog-share { display: grid; gap: 8px; }
.catalog-share .primary { width: 100%; }
html:has(body.cart-open) { overflow: hidden; }
body.cart-open .cart-bar { display: none; }
@media (max-width: 959px) {
  .cart-dock.open { height: min(92dvh, 760px); }
  .cart-body {
    flex: 1 1 0;
    padding-bottom: calc(var(--dock-foot, 128px) + 12px + env(safe-area-inset-bottom));
  }
}
@media (min-width: 960px) {
  .store-page { padding: 24px 24px 40px; }
  .store-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 20px; align-items: start; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .product { grid-template-columns: 1fr; gap: 8px; }
  .product img, .product .ph { width: 100%; height: 120px; }
  .product .ph svg { width: 58%; height: 58%; max-width: 88px; max-height: 88px; }
  .cart-bar, .cart-scrim, #dock-close { display: none !important; }
  .cart-dock {
    position: sticky; top: 16px; display: flex; max-height: calc(100vh - 48px);
    border: 1px solid var(--line); border-radius: 12px; box-shadow: none;
  }
  .catalog-share .primary { width: auto; justify-self: start; }
  html:has(body.cart-open) { overflow: visible; }
}

body.landing {
  margin: 0; background: var(--paper); color: var(--ink);
  min-height: 100dvh;
}
.land-bar, .land-foot {
  display: flex; align-items: center; gap: 12px;
  padding: 0 16px; height: 56px;
}
.land-bar {
  position: sticky; top: 0; z-index: 5;
  background: var(--action); color: #F3F0E4;
}
.land-bar .brand { color: inherit; }
.land-bar .btn { margin-left: auto; min-height: 36px; height: 36px; padding: 0 14px; background: #F3F0E4; color: var(--ink); }
.land-bar .btn.primary, .hero-actions .btn.primary, .final .btn.primary {
  background: var(--accent); color: var(--ink); border-color: var(--accent);
}
.landing main { max-width: 1120px; margin: 0 auto; padding: 28px 16px 48px; }
.hero h1 { font-size: clamp(1.8rem, 5vw, 3.2rem); line-height: 1.12; margin: 8px 0 12px; max-width: 16ch; }
.hero .lede { max-width: 42rem; font-size: 1.05rem; }
.hero-actions, .final { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.hero-actions .btn, .final .btn { min-height: 48px; padding: 0 18px; }
.landing .steps, .benefits, .final { margin-top: 48px; }
.landing .steps h2, .benefits h2, .final h2 { font-size: 1.5rem; margin: 0 0 16px; }
.landing .steps ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 20px; }
.landing .steps li {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
}
.landing .steps img { display: block; width: 100%; height: auto; background: #efeae2; }
.landing .steps li div { padding: 16px; }
.landing .steps li span {
  display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 99px;
  background: var(--action); color: #F3F0E4; font-weight: 700; font-size: 0.85rem;
}
.landing .steps h3, .benefits h3 { margin: 8px 0 4px; }
.benefits ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.benefits li { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.benefits p, .steps p, .final p { color: var(--ink-soft); margin: 0; }
.final {
  background: var(--action); color: #F3F0E4; border-radius: 16px; padding: 24px 16px;
}
.final h2, .final p { color: inherit; }
.final p { margin: 8px 0 0; }
.land-foot {
  height: auto; min-height: 56px; padding: 16px; flex-wrap: wrap;
  border-top: 1px solid var(--line); color: var(--ink-soft);
}
.land-foot p { margin: 0; flex: 1 1 180px; }
.land-foot a { color: var(--action); font-weight: 650; }
@media (min-width: 800px) {
  .landing .steps ol, .benefits ul { grid-template-columns: 1fr 1fr; }
  .landing main { padding: 56px 32px 72px; }
}
@media (min-width: 1200px) {
  .hero { display: grid; gap: 8px; max-width: 860px; }
}

@media (min-width: 900px) {
  html:has(.layout),
  body:has(.layout) {
    height: auto;
    max-height: none;
    overflow: auto;
  }
  .layout {
    height: auto;
    max-height: none;
    min-height: 100dvh;
    overflow: visible;
    align-items: stretch;
  }
  .side { height: 100%; max-height: none; position: sticky; top: 0; }
  main {
    display: block;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
    padding: 12px 24px 32px;
  }
  .example-banner, main > .toast { flex: 0 0 auto; }
  .app-body {
    min-height: 0;
    overflow: visible;
    display: block;
  }
  .catalog-page, .list-page {
    min-height: 0;
    display: block;
    overflow: visible;
    height: auto;
  }
  .app-body > .sim-shell {
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
    display: grid;
    overflow: hidden;
  }
  .page-head, .filter-root { flex: 0 0 auto; }
  .list-page > .panel { max-height: none; overflow: visible; }
  .list-scroll {
    min-height: 0;
    overflow: visible;
    display: block;
  }
  .list-scroll .pager { margin-top: auto; flex: 0 0 auto; }
  .catalog-panel .panel-filters:not([hidden]) {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .catalog-panel:has(.panel-detail:not([hidden]))::before {
    content: "";
    position: fixed;
    inset: 0;
    background: rgba(18, 36, 28, 0.45);
    z-index: 69;
  }
  .catalog-panel .panel-detail:not([hidden]) {
    position: fixed;
    z-index: 70;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(520px, calc(100vw - 48px));
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 8px 16px 16px;
  }
  html:has(.sim-shell), body:has(.sim-shell) { height: 100dvh; max-height: 100dvh; overflow: hidden; }
  main:has(.sim-shell) { display: flex; flex-direction: column; height: 100dvh; overflow: hidden; }
}
@media (max-width: 899px) {
  html:has(.layout),
  body:has(.layout) { height: auto; max-height: none; overflow: auto; }
  .list-page, .catalog-page { display: block; height: auto; overflow: visible; }
}
