:root {
  color-scheme: light;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #f3f5f3;
  color: #142b28;
  --ink: #142b28;
  --muted: #526861;
  --line: #dce5df;
  --panel: #fff;
  --brand: #087b68;
  --brand-dark: #076052;
  --forest: #143c34;
  --pale: #e8f4ee;
  --radius: 12px;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 300px; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
button:disabled { cursor: default; opacity: .52; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, main:focus-visible {
  outline: 2px solid #30a794;
  outline-offset: 3px;
}
h1, h2, p { margin: 0; }
h1, h2 { letter-spacing: -.035em; }
[hidden] { display: none !important; }
.skip-link {
  position: fixed;
  z-index: 20;
  left: 12px;
  top: 12px;
  padding: 9px 12px;
  border-radius: 7px;
  background: #fff;
  transform: translateY(-200%);
}
.skip-link:focus { transform: translateY(0); }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.loading-view { min-height: 100vh; display: grid; place-items: center; color: var(--muted); }
.brand { display: flex; align-items: center; gap: 10px; width: max-content; }
.brand-mark {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  background: #0c806b;
  border-radius: 10px;
}
.brand-mark::before, .brand-mark::after {
  content: "";
  position: absolute;
  left: 9px;
  top: 9px;
  width: 7px;
  height: 18px;
  transform: skewY(-20deg);
  border-radius: 2px;
  background: #f2f8f5;
}
.brand-mark::after { left: 19px; top: 11px; height: 14px; background: #92d3c2; }
.brand-name { display: block; font-size: 19px; font-weight: 780; letter-spacing: -.04em; }
.brand-detail { display: block; color: #c4dfd1; font-size: 11px; margin-top: 2px; }
.operator-shell { display: grid; grid-template-columns: 223px minmax(0, 1fr); min-height: 100vh; }
.side {
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100vh;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 34px;
  padding: 25px 14px 14px;
  color: #f2faf6;
  background: var(--forest);
}
.side .brand { margin-inline: 7px; }
.side-nav { display: grid; gap: 6px; }
.side-nav a {
  display: flex;
  align-items: center;
  min-height: 41px;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 7px;
  color: #ecf5ef;
  font-size: 13px;
}
.side-nav a:hover, .side-nav a[aria-current="location"] { background: #ffffff1d; }
.nav-mark { width: 16px; height: 16px; display: grid; place-items: center; flex: none; color: #a8d8cf; }
.operator-account {
  margin-top: auto;
  padding: 13px 6px 0;
  min-width: 0;
  border-top: 1px solid #ffffff26;
}
.operator-account strong { display: block; font-size: 12px; }
.operator-account p { margin: 5px 0 10px; font-size: 11px; color: #c4dfd1; overflow: hidden; text-overflow: ellipsis; }
.btn {
  min-width: 0;
  min-height: 37px;
  padding: 7px 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  white-space: nowrap;
  font-size: 13px;
  font-weight: 680;
}
.btn:hover:enabled { background: #f5f9f6; border-color: #a7cbbd; }
.btn.primary { background: var(--brand); color: #fff; border-color: var(--brand); }
.btn.primary:hover:enabled { background: var(--brand-dark); border-color: var(--brand-dark); }
.btn.ghost { background: transparent; color: #f9fffc; border-color: #ffffff38; }
.btn.ghost:hover:enabled { background: #ffffff17; border-color: #ffffff83; }
.operator-main { min-width: 0; }
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  gap: 12px;
  padding-inline: var(--gutter, 26px);
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.path { color: var(--muted); font-size: 12px; }
.path strong { margin-left: 7px; color: var(--ink); }
.top-actions { display: flex; align-items: center; gap: 8px; }
.account-mobile { display: none; }
.content { --gutter: clamp(16px, 3vw, 42px); max-width: 1500px; padding: 25px var(--gutter) 45px; margin: 0 auto; }
.page-heading { margin-bottom: 18px; display: flex; align-items: end; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.page-heading h1 { font-size: clamp(25px, 3vw, 36px); font-weight: 775; }
.page-heading p { margin-top: 6px; color: var(--muted); font-size: 13px; }
.last-update { color: var(--muted); font-size: 11px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.panel + .panel { margin-top: 14px; }
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
}
.panel-heading h2 { font-size: 15px; font-weight: 740; }
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
}
.stat { min-width: 0; padding: 17px 16px 15px; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-name { display: block; color: var(--muted); font-size: 12px; font-weight: 640; }
.stat-count {
  display: block;
  color: var(--ink);
  margin-top: 5px;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.1;
  font-weight: 760;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.payment-status { scroll-margin-top: 12px; }
.payment-details { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.payment-details div { padding: 13px 16px; min-width: 0; }
.payment-details div + div { border-left: 1px solid var(--line); }
.payment-details dt { font-size: 12px; color: var(--muted); }
.payment-details dd { margin: 5px 0 0; font-variant-numeric: tabular-nums; font-size: 13px; font-weight: 680; color: var(--ink); }
.stores-panel { scroll-margin-top: 12px; }
.store-filters { display: flex; align-items: center; gap: 7px; min-width: 0; }
.store-filters input, .store-filters select {
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 7px;
  min-height: 35px;
  padding: 6px 9px;
  font-size: 12px;
}
.store-filters input { min-width: 80px; width: min(20vw, 230px); }
.store-filters select { min-width: 0; max-width: 118px; }
.table-wrap { overflow-x: auto; }
.stores { border-collapse: collapse; width: 100%; white-space: nowrap; text-align: left; }
.stores th { height: 38px; background: #f7f9f6; color: var(--muted); font-size: 12px; font-weight: 650; }
.stores td { height: 53px; border-bottom: 1px solid #e7ede8; font-size: 13px; }
.stores :is(td, th) { padding: 7px 11px; }
.stores :is(td, th):first-child { padding-left: 16px; }
.stores :is(td, th):last-child { padding-right: 16px; }
.stores tr:last-child td { border-bottom: 0; }
.stores tbody tr:hover { background: #fafcf9; }
.stores .number { text-align: right; font-variant-numeric: tabular-nums; }
.store-cell { display: flex; align-items: center; gap: 10px; }
.favicon {
  width: 30px;
  height: 30px;
  flex: none;
  display: grid;
  place-items: center;
  color: var(--brand-dark);
  background: #e9f3ec;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 760;
}
.store-name { font-weight: 690; }
.store-sub { display: block; margin-top: 4px; font-size: 11px; color: var(--muted); }
.store-name, .store-sub { max-width: clamp(115px, 24vw, 250px); overflow: hidden; text-overflow: ellipsis; }
.badge {
  width: max-content;
  max-width: 100%;
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 7px;
  border-radius: 5px;
  color: #52645e;
  background: #ebf0ec;
  font-size: 11px;
  font-weight: 660;
  white-space: nowrap;
}
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; flex: none; }
.badge.ok { background: #e5f4eb; color: #19684f; }
.badge.wait { color: #805215; background: #fbf0d9; }
.summary-footer {
  min-height: 48px;
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 8px 16px;
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.page-controls { display: flex; gap: 6px; align-items: center; }
.page-controls .btn { min-height: 30px; width: 32px; padding: 4px; }
.empty { padding: 36px 16px; color: var(--muted); text-align: center; font-size: 13px; line-height: 1.6; }
.empty strong { display: block; color: var(--ink); font-size: 14px; margin-bottom: 4px; }
.empty .btn { margin-top: 10px; }
.alert {
  margin: 0 0 12px;
  padding: 12px 14px;
  color: #963537;
  background: #fff2f2;
  border: 1px solid #f2d8d7;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.6;
}
.alert:empty { display: none; }
.identity {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(300px, 1.08fr);
  background: #fff;
}
.identity-side {
  display: flex;
  flex-direction: column;
  padding: clamp(23px, 5vw, 74px);
  justify-content: space-between;
  gap: 60px;
  color: #f2faf6;
  min-height: 100vh;
  background: radial-gradient(ellipse at 50% 75%, #1b5a4b, transparent 60%), var(--forest);
}
.identity-side h1 { font-size: clamp(28px, 4.4vw, 51px); line-height: 1.16; }
.identity-side p { margin-top: 12px; color: #d1e6db; font-size: 14px; line-height: 1.6; }
.identity-main { display: grid; place-items: center; padding: 22px 30px; }
.identity-card { max-width: 371px; width: 100%; }
.identity-card h2 { font-size: 26px; line-height: 1.2; }
.identity-card > p { margin: 8px 0 17px; color: var(--muted); line-height: 1.6; font-size: 13px; }
.identity-form { display: grid; gap: 13px; }
.identity-form label { display: grid; gap: 6px; color: var(--ink); font-size: 13px; font-weight: 680; }
.identity-form input { min-height: 43px; border: 1px solid var(--line); border-radius: 7px; padding: 8px 10px; }
.identity-form .btn { min-height: 43px; }
@media (max-width: 1000px) {
  .operator-shell { grid-template-columns: 184px minmax(0, 1fr); }
  .stores .secondary { display: none; }
}
@media (max-width: 760px) {
  .operator-shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; height: auto; min-height: 0; flex-flow: row wrap; justify-content: space-between; align-items: center; gap: 11px; padding: 11px 14px; }
  .side .brand { margin-inline: 0; }
  .side-nav { display: flex; flex-wrap: wrap; gap: 4px; }
  .side-nav a { min-height: 38px; padding-inline: 6px; gap: 4px; }
  .operator-account { display: none; }
  .account-mobile { display: inline-flex; }
  .topbar { min-height: 51px; padding-inline: 12px; }
  .content { padding-top: 16px; --gutter: 12px; }
  .stores .optional { display: none; }
}
@media (max-width: 540px) {
  .stat-grid, .payment-details { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-grid .stat:nth-child(3) { border-left: 0; }
  .stat-grid .stat:nth-child(n+3), .payment-details div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .payment-details div:nth-child(3) { border-left: 0; }
  .stat, .payment-details div { padding: 12px 10px; }
  .panel-heading { padding-inline: 10px; }
  .top-actions { gap: 5px; }
  .top-actions .btn { min-height: 40px; padding-inline: 7px; font-size: 12px; }
  .topbar .path { font-size: 11px; }
  .path strong, .topbar .badge, .stores .mobile-hide { display: none; }
  .stores .store-cell { gap: 5px; }
  .stores .favicon { display: none; }
  .stores :is(td, th) { padding: 6px; font-size: 12px; }
  .stores :is(td, th):first-child { padding-left: 10px; }
  .stores :is(td, th):last-child { padding-right: 10px; }
  .store-filters input { min-width: 0; width: min(29vw, 140px); }
  .store-filters select { width: min(24vw, 95px); }
  .identity { grid-template-columns: 1fr; }
  .identity-side { min-height: 0; padding: 16px; gap: 18px; }
  .identity-side .brand-detail { display: none; }
  .identity-side p { margin-top: 6px; }
  .identity-main { padding: 24px 17px; }
}
