:root {
  --blue: oklch(51% 0.23 260);
  --teal: oklch(51% 0.095 191);
  --ink: oklch(24% 0.038 260);
  --muted: oklch(48% 0.029 260);
  --line: oklch(92% 0.015 255);
  --bg: oklch(98.5% 0.006 255);
  --surface: #fff;
  --soft: oklch(96% 0.025 250);
  --green: #087f5b;
  --orange: #955a06;
  --red: #b0273c;
  --sidebar: 224px;
  --z-nav: 20;
  --z-toast: 60;
}
.map-settings-panel { margin-bottom:20px; }
.map-settings-panel form { align-items:flex-end; }
.map-settings-panel form.wrap { flex-wrap:wrap; }
.map-settings-panel input,.map-settings-panel select { width:100%; }
.map-settings-panel hr { border:0;border-top:1px solid var(--line);width:100%; }
.columns.geo-layout { grid-template-columns:minmax(0,1fr) 320px; align-items:start; }
.geography { min-width:0; overflow:hidden; }
.geo-toolbar { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:16px 20px; border-bottom:1px solid var(--line); flex-wrap:wrap; }
.geo-tabs { display:flex; gap:4px; flex-wrap:wrap; }
.geo-tab { border:0; background:transparent; color:var(--muted); padding:10px 12px; border-radius:6px; }
.geo-tab[aria-selected="true"] { color:var(--blue); background:var(--soft); font-weight:650; }
.geo-tab:hover { background:var(--soft); }
.geo-body { height:480px; position:relative; background:var(--bg); }
.geo-canvas { position:absolute; inset:0; }
.geo-message { position:absolute; top:24px; left:24px; right:24px; max-width:430px; margin:auto; padding:24px; background:var(--surface); border:1px solid var(--line); border-radius:10px; }
.geo-message[hidden],.geo-message a[hidden],tr[hidden] { display:none; }
.geo-message h3 { font-size:18px; margin:12px 0 8px; }
.geo-message p { margin-bottom:14px; }
.geo-symbol { color:var(--blue); }
.geo-symbol svg { width:28px; height:28px; }
.geo-legend { display:flex; gap:8px; align-items:center; flex-wrap:wrap; padding:14px 20px 6px; font-size:12px; }
.geo-legend small { flex-basis:100%; color:var(--muted); }
.heat-scale { width:84px; height:8px; border-radius:3px; background:linear-gradient(90deg,#d9efff,#66b4ff,#0057d9); }
.point-key { width:9px; height:9px; border-radius:50%; background:#007e82; }
.point-key.empty-stock { background:#a55c00; }
.point-key.inactive { background:#748096; }
.geo-caption { padding:6px 20px 16px; font-size:12px; }
.geo-detail-list { display:grid; grid-template-columns:1fr auto; gap:14px 12px; margin:8px 0; }
.geo-detail-list dt { color:var(--muted); }
.geo-detail-list dd { margin:0; text-align:right; }
.geo-selected { background:var(--soft); }
.geo-filters { flex-wrap:wrap; }
.geo-filters label { min-width:140px; }
.geo-filters input,.geo-filters select { width:100%; }
.geo-filter-count { margin-top:8px; font-size:12px; }
.map-settings-panel textarea { width:100%; min-height:110px; }
@media (max-width:1180px) { .columns.geo-layout { grid-template-columns:minmax(0,1fr); } }
@media (max-width:760px) {
  .geo-body { height:360px; }
  .geo-toolbar { padding:12px; }
  .geo-tab { padding:10px 8px; }
  .geo-message { top:16px; left:12px; right:12px; padding:20px; }
  .geo-filters label { flex:1; min-width:130px; }
  .geo-legend,.geo-caption { padding-left:14px; padding-right:14px; }
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    14px/1.55 -apple-system,
    BlinkMacSystemFont,
    "PingFang SC",
    "Microsoft YaHei",
    system-ui,
    sans-serif;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  outline-offset: 3px;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #80bbff;
}
button,
a {
  touch-action: manipulation;
}
a {
  color: var(--blue);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.025em;
  text-wrap: balance;
}
h2 {
  font-size: 16px;
  font-weight: 650;
}
h3 {
  font-size: 14px;
}
p {
  color: var(--muted);
}
small {
  font-size: 12px;
  color: var(--muted);
}
svg.lucide {
  width: 19px;
  height: 19px;
  stroke-width: 1.7;
  flex-shrink: 0;
}
input,
select,
textarea {
  color: var(--ink);
  background: #fff;
  border: 1px solid #c9d5e4;
  border-radius: 6px;
  padding: 9px 11px;
  min-height: 40px;
  max-width: 100%;
}
input::placeholder,
textarea::placeholder {
  color: var(--muted);
}
textarea {
  min-height: 88px;
  resize: vertical;
}
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid #82b8ff;
  border-color: var(--blue);
}
label {
  display: grid;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 14px;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font-weight: 550;
  white-space: nowrap;
  transition: background 150ms;
}
.btn:hover {
  background: var(--soft);
  text-decoration: none;
}
.btn.primary {
  background: var(--blue);
  border-color: var(--blue);
  color: white;
}
.btn.primary:hover {
  background: #064ec2;
}
.btn.teal {
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
}
.btn.danger {
  color: var(--red);
}
.btn.small {
  min-height: 30px;
  padding: 5px 9px;
  font-size: 12px;
}
.link-btn {
  border: 0;
  background: none;
  color: var(--blue);
  padding: 5px;
  cursor: pointer;
}
.row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.spread {
  justify-content: space-between;
}
.stack {
  display: grid;
  gap: 18px;
}
.muted {
  color: var(--muted);
}
.mono {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  overflow-wrap: anywhere;
}
.boot {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 20px;
}
.boot img {
  width: 220px;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  border-right: 1px solid var(--line);
  background: #fff;
  z-index: var(--z-nav);
  display: flex;
  flex-direction: column;
  padding: 26px 12px 20px;
}
.brand {
  padding: 0 12px 30px;
}
.brand img {
  width: 176px;
  height: 58px;
  object-fit: contain;
}
.brand small {
  display: block;
  margin-left: 8px;
  font-size: 10px;
  letter-spacing: 1px;
}
.brand .brand-title {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  margin: 6px 0 0;
}
.workspace-brand-name {
  display: none;
}
.sidebar nav {
  display: grid;
  gap: 4px;
}
.nav-link {
  display: flex;
  gap: 14px;
  align-items: center;
  min-height: 46px;
  padding: 11px 13px;
  color: #516078;
  border-radius: 6px;
  font-size: 13px;
  transition: background 150ms;
}
.nav-link:hover {
  text-decoration: none;
  background: var(--soft);
}
.nav-link.active {
  background: #eaf5f7;
  color: var(--teal);
  font-weight: 650;
}
.nav-sep {
  height: 1px;
  background: var(--line);
  margin: 12px;
}
.sidebar-foot {
  margin-top: auto;
  padding: 24px 10px 0;
  font-size: 12px;
  color: var(--muted);
}
.status-dot {
  display: inline-block;
  background: #0e9c72;
  border-radius: 50%;
  width: 7px;
  height: 7px;
  margin-right: 6px;
}
.workspace {
  margin-left: var(--sidebar);
  padding: 28px 28px 40px;
  min-width: 0;
}
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 22px;
}
.subtitle {
  margin-top: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
}
.top-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 13px;
}
.filters {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.filters select {
  font-size: 12px;
  min-height: 35px;
  padding: 6px 9px;
}
.user-menu {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  border-radius: 4px;
  background: #edf4ff;
  color: #1556ad;
  padding: 3px 7px;
  font-size: 11px;
  font-weight: 550;
}
.badge.green {
  color: #067b60;
  background: #eaf7f2;
}
.badge.orange {
  color: #985807;
  background: #fff5e6;
}
.badge.red {
  color: #ad2843;
  background: #fff0f2;
}
.badge.gray {
  color: #556078;
  background: #f0f2f5;
}
.notice {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border: 1px solid #eedbc0;
  background: #fffaf0;
  color: #845210;
  padding: 11px 15px;
  border-radius: 6px;
  font-size: 12px;
  margin-bottom: 18px;
}
.notice.info {
  background: #f1f7ff;
  border-color: #cdddf3;
  color: #295078;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  margin-bottom: 20px;
}
.stat {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 20px;
  min-width: 0;
}
.stat + .stat {
  border-left: 1px solid var(--line);
}
.stat-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 49px;
  height: 49px;
  border-radius: 50%;
  background: #eaf2ff;
  color: var(--blue);
  flex-shrink: 0;
}
.stat-icon svg {
  width: 25px;
  height: 25px;
}
.stat:nth-child(even) .stat-icon {
  color: var(--teal);
  background: #e9f7f7;
}
.stat label {
  font-size: 12px;
  margin-bottom: 6px;
}
.stat strong {
  font-size: 28px;
  line-height: 1;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.025em;
}
.stat em {
  font-style: normal;
  font-size: 12px;
  margin-left: 6px;
}
.columns {
  display: grid;
  grid-template-columns: minmax(0, 2.15fr) minmax(280px, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}
.columns.equal {
  grid-template-columns: 1fr 1fr;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-width: 0;
  overflow: clip;
}
.panel-head {
  padding: 18px 20px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.panel-body {
  padding: 18px 20px;
}
.chart {
  width: 100%;
  height: 300px;
}
.flow {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  padding: 30px 20px;
}
.flow-step {
  text-align: center;
  position: relative;
}
.flow-step:not(:last-child):after {
  content: "›";
  position: absolute;
  right: -12px;
  top: 14px;
  color: #9ec6f7;
  font-size: 30px;
}
.flow-icon {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 1px solid #c8dcff;
  border-radius: 50%;
  color: var(--blue);
  margin: 0 auto 13px;
}
.flow-icon svg {
  width: 25px;
  height: 25px;
}
.flow-step p {
  color: var(--ink);
  font-size: 12px;
}
.flow-step strong {
  display: block;
  font-size: 23px;
  margin-top: 8px;
  font-weight: 600;
}
.flow-step small {
  font-size: 10px;
}
.panel-footer {
  border-top: 1px solid var(--line);
  margin: 0 20px;
  padding: 15px 0;
  color: var(--muted);
  font-size: 12px;
}
.alert-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  gap: 10px;
}
.alert-item strong {
  display: block;
  font-size: 24px;
}
.alert-item p {
  font-size: 12px;
}
.alert-item .stat-icon {
  background: #fff4e5;
  color: #b66a05;
}
.table-wrap {
  overflow: auto;
  max-width: 100%;
}
table {
  width: 100%;
  border-collapse: collapse;
  white-space: nowrap;
  text-align: left;
  font-size: 12px;
}
th {
  font-weight: 500;
  color: var(--muted);
  background: #f7f9fc;
  padding: 11px 15px;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 13px 15px;
  border-bottom: 1px solid #f0f3f7;
}
tr:last-child td {
  border-bottom: 0;
}
tbody tr:hover {
  background: #f9fbff;
}
.table-wrap.long {
  max-height: 540px;
}
.pagination {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  align-items: center;
  padding: 14px 16px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}
.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 14px;
  min-height: 210px;
  padding: 28px;
  text-align: center;
}
.empty svg {
  width: 32px;
  height: 32px;
  color: #98abc5;
}
.empty p {
  max-width: 48ch;
}
.empty h3 {
  font-size: 15px;
}
.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin: 0 0 18px;
  flex-wrap: wrap;
}
.toolbar input {
  width: 260px;
}
.tabs {
  display: flex;
  gap: 6px;
  padding: 3px;
  background: #f2f5f9;
  border-radius: 6px;
}
.tabs button {
  padding: 8px 16px;
  border: 0;
  border-radius: 4px;
  background: none;
  color: var(--muted);
}
.tabs button.active {
  background: #fff;
  color: var(--blue);
  box-shadow: 0 1px 3px #00132c14;
}
.definition {
  font-size: 11px;
  margin-top: 10px;
  color: var(--muted);
}
.detail-list {
  display: grid;
  gap: 20px;
}
.detail-list > div {
  display: flex;
  gap: 15px;
  justify-content: space-between;
  font-size: 13px;
}
.detail-list dt {
  color: var(--muted);
}
.detail-list dd {
  margin: 0;
  text-align: right;
}
.progress {
  height: 5px;
  background: #e8eef6;
  border-radius: 3px;
  overflow: hidden;
}
.progress span {
  display: block;
  height: 100%;
  background: var(--blue);
}
.region-row {
  display: grid;
  grid-template-columns: 85px minmax(50px, 1fr) 60px;
  align-items: center;
  gap: 16px;
  margin: 24px 0;
}
.region-row strong {
  text-align: right;
}
.region-row .progress {
  height: 12px;
}
.summary-note {
  padding: 18px;
  background: var(--soft);
  border-radius: 6px;
  font-size: 12px;
}
.forms {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.forms .full {
  grid-column: 1/-1;
}
.error {
  color: var(--red);
  font-size: 13px;
  white-space: pre-wrap;
}
.error:empty {
  display: none;
}
.success {
  color: var(--green);
}
.page-foot {
  text-align: center;
  margin-top: 26px;
  font-size: 11px;
  color: var(--muted);
}
.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
}
.login-art {
  background: #edf5ff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12%;
  position: relative;
  overflow: hidden;
}
.login-art img {
  width: 200px;
  mix-blend-mode: multiply;
  margin-bottom: 40px;
}
.login-art h1 {
  font-size: 40px;
  line-height: 1.4;
  max-width: 10em;
}
.login-art p {
  margin-top: 22px;
  font-size: 16px;
  max-width: 25em;
}
.login-lines {
  display: flex;
  gap: 12px;
  margin-top: 48px;
  color: #35748b;
  flex-wrap: wrap;
}
.login-lines span {
  padding: 10px 0;
  border-top: 1px solid #b5d3ed;
  font-size: 12px;
}
.login-form {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px;
}
.login-form form {
  width: 360px;
  display: grid;
  gap: 22px;
}
.login-form h2 {
  font-size: 24px;
  margin-bottom: 8px;
}
.login-form label {
  font-size: 13px;
}
.login-form input {
  min-height: 46px;
}
.login-form small {
  font-size: 11px;
}
.mobile-menu {
  display: none;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0;
  width: min(640px, calc(100vw - 32px));
  max-height: 90vh;
  color: var(--ink);
}
dialog::backdrop {
  background: #10254166;
}
dialog header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}
dialog form,
dialog .dialog-body {
  padding: 22px;
}
dialog footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
}
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-toast);
  background: #132641;
  color: #fff;
  border-radius: 7px;
  padding: 12px 20px;
  max-width: 90vw;
  display: none;
}
#toast.show {
  display: block;
}
.qr-preview {
  width: 210px;
  height: 210px;
  display: block;
  margin: 18px auto;
  background: white;
}
.qr-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
}
.qr-label {
  border: 1px solid var(--line);
  padding: 12px;
  text-align: center;
  font-size: 10px;
}
.qr-label img {
  width: 140px;
  max-width: 100%;
  display: block;
  margin: auto;
}
.scan-layout {
  display: grid;
  grid-template-columns: minmax(280px, 400px) minmax(0, 1fr);
  gap: 22px;
}
.camera {
  aspect-ratio: 4/3;
  background: #15243a;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  display: grid;
  place-items: center;
}
.camera video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.camera-hint {
  position: absolute;
  color: white;
  text-align: center;
  padding: 20px;
  pointer-events: none;
}
.camera video:not([src]) {
  min-height: 240px;
}
.scan-status {
  padding: 15px;
  border: 1px solid #c7ded7;
  background: #effbf6;
  border-radius: 6px;
  font-size: 13px;
  color: #126d53;
}
.scan-status.bad {
  background: #fff2f2;
  border-color: #efc6c6;
  color: var(--red);
}
.counter {
  display: flex;
  justify-content: space-around;
  text-align: center;
  padding: 18px 0;
}
.counter strong {
  display: block;
  font-size: 28px;
}
.counter small {
  font-size: 11px;
}
.session-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}
.trace-page {
  max-width: 500px;
  min-height: 100vh;
  margin: 0 auto;
  background: #f7fbff;
  padding: 20px 16px calc(106px + env(safe-area-inset-bottom));
}
.trace-bottom-nav {
  position: fixed;
  z-index: 20;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 500px);
  display: flex;
  background: #fff;
  border-top: 1px solid var(--line);
  padding: 9px 8px calc(9px + env(safe-area-inset-bottom));
}
.trace-bottom-nav a {
  flex: 1;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: #52647c;
  text-decoration: none;
}
.trace-bottom-nav a[aria-current="page"] { color: var(--blue); font-weight: 650; }
.trace-bottom-nav a:focus-visible { outline: 3px solid #80b9ff; outline-offset: -3px; }
.trace-bottom-nav svg { width: 22px; height: 22px; }
.trace-brand img {
  width: 182px;
  height: 60px;
  object-fit: contain;
}
.trace-hero {
  padding: 27px 4px 25px;
  display: flex;
  align-items: center;
  gap: 15px;
}
.trace-hero h1 {
  font-size: 20px;
  color: var(--green);
}
.trace-hero > div:last-child { min-width: 0; }
.trace-page-title { font-size: 20px; margin-top: 16px; }
.trace-hero p {
  font-size: 13px;
  margin-top: 8px;
}
.trace-hero .seal {
  background: #e3f5eb;
  color: var(--green);
  border-radius: 50%;
  width: 65px;
  height: 65px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.seal svg {
  width: 39px;
  height: 39px;
}
.product-panel {
  background: white;
  border: 1px solid #d9e5f3;
  border-radius: 10px;
  padding: 18px;
  margin-bottom: 16px;
}
.product-identity {
  display: flex;
  align-items: center;
  gap: 17px;
  min-height: 200px;
}
.bottle {
  width: 108px;
  object-fit: contain;
  mix-blend-mode: multiply;
}
.product-identity h2 {
  font-size: 22px;
  line-height: 1.5;
}
.volume {
  display: inline-flex;
  padding: 4px 12px;
  color: white;
  background: var(--blue);
  border-radius: 20px;
  font-size: 23px;
  font-weight: 650;
  margin: 12px 6px 12px 0;
}
.trace-fields {
  margin-top: 15px;
}
.trace-field {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}
.trace-field > span {
  color: var(--muted);
  white-space: nowrap;
}
.trace-field strong {
  font-weight: 500;
  text-align: right;
  overflow-wrap: anywhere;
  max-width: 65%;
}
.trace-timeline {
  display: flex;
  justify-content: space-between;
  margin: 24px 0 6px;
  gap: 6px;
}
.trace-stage {
  flex: 1;
  text-align: center;
  font-size: 12px;
}
.trace-stage .flow-icon {
  background: #f3f6fa;
  color: #8e9cb1;
  border-color: #e5eaf0;
}
.trace-stage.done .flow-icon {
  background: #edf6ff;
  color: var(--blue);
  border-color: #c6ddff;
}
.trace-stage small {
  font-size: 10px;
  display: block;
  margin-top: 7px;
}
.trace-actions {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}
.trace-actions .btn {
  min-height: 53px;
  font-size: 17px;
  justify-content: space-between;
  padding: 12px 18px;
}
.trace-page .notice {
  font-size: 12px;
}
.trace-footer {
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  margin-top: 18px;
}
.activity-disabled {
  padding: 18px;
  background: #fafbfe;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}
.skeleton {
  height: 180px;
  background: linear-gradient(100deg, #f0f4f9 20%, #f8faff 40%, #f0f4f9 60%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
  border-radius: 8px;
  margin: 20px 0;
}
@keyframes loading {
  to {
    background-position: -200% 0;
  }
}
@media (min-width: 1600px) {
  .workspace {
    max-width: 1770px;
    margin-right: auto;
  }
  .chart {
    height: 340px;
  }
  .stat {
    padding: 26px;
  }
}
@media (max-width: 1180px) {
  :root {
    --sidebar: 190px;
  }
  .workspace {
    padding: 22px 18px;
  }
  .brand img {
    width: 150px;
  }
  .topbar {
    flex-direction: column;
  }
  .top-controls {
    align-items: flex-start;
    width: 100%;
  }
  .stat {
    padding: 17px 13px;
    gap: 10px;
  }
  .stat strong {
    font-size: 24px;
  }
  .stat-icon {
    width: 40px;
    height: 40px;
  }
  .columns {
    grid-template-columns: 1fr;
  }
  .scan-layout {
    grid-template-columns: 340px 1fr;
  }
}
@media (max-width: 760px) {
  :root {
    --sidebar: 0px;
  }
  .sidebar {
    width: 230px;
    transform: translateX(-100%);
    transition: transform 180ms;
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 2px 0 8px #12243a33;
  }
  .workspace {
    margin: 0;
    padding: 18px 14px 30px;
  }
  .mobile-menu {
    display: inline-flex;
  }
  .topbar h1 {
    font-size: 23px;
  }
  .workspace-brand-name {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 8px;
  }
  .topbar {
    gap: 16px;
  }
  .subtitle {
    font-size: 12px;
  }
  .filters {
    width: 100%;
  }
  .filters select {
    flex: 1;
    min-width: 0;
  }
  .user-menu {
    font-size: 11px;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
  }
  .stat {
    padding: 18px 12px;
  }
  .stat:nth-child(3) {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .stat:nth-child(4) {
    border-top: 1px solid var(--line);
  }
  .stat strong {
    font-size: 25px;
  }
  .stat label {
    font-size: 11px;
  }
  .columns.equal,
  .scan-layout {
    grid-template-columns: 1fr;
  }
  .panel-head {
    padding: 16px 15px 0;
  }
  .panel-body {
    padding: 16px 15px;
  }
  .flow {
    padding: 23px 12px;
    gap: 8px;
  }
  .flow-icon {
    width: 40px;
    height: 40px;
  }
  .flow-step p {
    font-size: 10px;
  }
  .flow-step strong {
    font-size: 20px;
  }
  .flow-step small {
    font-size: 9px;
  }
  .flow-step:not(:last-child):after {
    right: -9px;
    top: 9px;
    font-size: 23px;
  }
  .chart {
    height: 260px;
  }
  .forms {
    grid-template-columns: 1fr;
  }
  .login {
    grid-template-columns: 1fr;
  }
  .login-art {
    padding: 30px 25px;
  }
  .login-art img {
    margin-bottom: 18px;
    width: 150px;
  }
  .login-art h1 {
    font-size: 28px;
    max-width: 100%;
  }
  .login-art p {
    font-size: 13px;
    margin-top: 10px;
  }
  .login-lines {
    display: none;
  }
  .login-form {
    padding: 32px 25px;
  }
  .login-form form {
    width: 100%;
    max-width: 400px;
  }
  .toolbar input {
    width: 100%;
  }
  .toolbar {
    align-items: stretch;
  }
  .toolbar > .row {
    width: 100%;
  }
  .toolbar .btn {
    flex: 1;
  }
  .qr-list {
    grid-template-columns: 1fr 1fr;
  }
  .camera {
    max-height: 340px;
  }
  .trace-field strong {
    font-size: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
@media print {
  body {
    background: white;
  }
  .sidebar,
  .topbar,
  .page-foot,
  .toolbar,
  .notice,
  #toast {
    display: none !important;
  }
  .workspace {
    margin: 0;
    padding: 0;
  }
  .qr-list {
    grid-template-columns: repeat(3, 1fr);
  }
  .qr-label {
    break-inside: avoid;
  }
  .no-print {
    display: none !important;
  }
}
