:root {
  color-scheme: light;
  --ink: #19332e;
  --muted: #63736d;
  --line: #dce5de;
  --base: #f3f6f2;
  --deep: #173833;
  --green: #11745a;
  --mint: #deeee3;
  --amber: #8d5c21;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--base);
  font:
    14px/1.55 'Segoe UI',
    'Microsoft YaHei',
    system-ui,
    sans-serif;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
select {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.48;
  cursor: default;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #58aa8b;
  outline-offset: 2px;
}
a {
  color: var(--green);
}
button {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 8px 13px;
  background: #fff;
  color: var(--ink);
  font-weight: 550;
}
button:hover {
  background: #f0f6f1;
}
.primary,
.primary:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}
.quiet {
  border: 0;
  background: transparent;
  color: var(--green);
  padding: 5px 7px;
}
.warn {
  color: #a14631;
}
.layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 218px minmax(0, 1fr);
}
aside {
  background: var(--deep);
  color: white;
  display: flex;
  flex-direction: column;
  padding: 27px 14px;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.04em;
}
.brand small {
  display: block;
  font-size: 10px;
  color: #abc6b8;
  font-weight: 500;
  letter-spacing: 0.12em;
}
.brandmark {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  background: #c1e9be;
  color: var(--deep);
  border-radius: 12px;
  font: bold 24px/1 system-ui;
}
.sidehead {
  padding: 2px 10px 27px;
}
nav {
  display: grid;
  gap: 5px;
}
.navbtn {
  display: flex;
  align-items: center;
  gap: 13px;
  border: 0;
  background: transparent;
  color: #bfcec7;
  text-align: left;
  padding: 12px 14px;
  font-weight: 500;
}
.navbtn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}
.navbtn:hover {
  background: #24483e;
  color: white;
}
.navbtn.active {
  background: #d8ebd7;
  color: #153e30;
  font-weight: 650;
}
.sidefoot {
  margin-top: auto;
  border-top: 1px solid #36534a;
  padding: 16px 8px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.sidefoot .quiet {
  color: #cce0d0;
}
.user {
  max-width: 110px;
  overflow-wrap: anywhere;
}
.main {
  min-width: 0;
  padding: 24px clamp(16px, 3vw, 52px) 50px;
}
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  align-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.topbar strong {
  font-weight: 600;
  color: var(--ink);
}
.pagehead,
.panelhead,
.bar,
.actions,
.inline {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.pagehead,
.panelhead,
.bar {
  justify-content: space-between;
}
.pagehead {
  margin: 28px 0 20px;
}
.pagehead h1 {
  font-size: clamp(25px, 3vw, 35px);
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.04em;
}
.pagehead p {
  margin: 7px 0 0;
  color: var(--muted);
}
h2 {
  font-size: 18px;
  margin: 0;
}
h3 {
  font-size: 15px;
}
.grid4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.metric,
.panel,
.groupcard {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.metric {
  padding: 19px;
}
.metric:first-child {
  background: var(--deep);
  border-color: var(--deep);
  color: white;
}
.metric span {
  color: var(--muted);
  font-size: 13px;
}
.metric:first-child span {
  color: #c3d8c9;
}
.metric b {
  display: block;
  font:
    600 clamp(27px, 3vw, 39px)/1.4 'Segoe UI',
    sans-serif;
  font-variant-numeric: tabular-nums;
  margin-top: 7px;
}
.panel {
  padding: 20px;
  margin-top: 16px;
  min-width: 0;
}
.panelhead {
  margin-bottom: 15px;
}
.duo {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(240px, 1fr);
  gap: 16px;
}
.chart {
  height: 166px;
  display: flex;
  align-items: end;
  gap: 6px;
  margin-top: 17px;
  border-bottom: 1px solid var(--line);
}
.barcol {
  flex: 1;
  background: #6baf86;
  min-height: 2px;
  border-radius: 3px 3px 0 0;
}
.axis {
  display: flex;
  justify-content: space-between;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
}
.chart svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}
.kv {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.kv:last-child {
  border: 0;
}
.gridcards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
}
.groupcard {
  padding: 16px;
  text-align: left;
}
.groupcard strong {
  display: block;
  font-size: 17px;
}
.groupcard span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
}
.pill {
  display: inline-flex;
  padding: 3px 9px;
  border-radius: 20px;
  background: #edf1ed;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}
.pill.ok {
  background: var(--mint);
  color: #1d694d;
}
.pill.bad {
  background: #f6e6dc;
  color: #89442a;
}
.empty {
  text-align: center;
  padding: 28px 14px;
  color: var(--muted);
  background: #f8faf7;
  border-radius: 7px;
}
.muted,
small {
  color: var(--muted);
}
.tablewrap {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 13px;
}
th,
td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  background: #f8faf7;
}
td {
  overflow-wrap: anywhere;
}
td .actions {
  gap: 4px;
}
.mono,
code {
  font-family: Consolas, monospace;
  overflow-wrap: anywhere;
}
.filter {
  display: flex;
  gap: 10px;
  align-items: end;
  flex-wrap: wrap;
}
.filter label {
  min-width: 90px;
}
.field,
label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 13px;
}
input:not([type='checkbox']),
select,
textarea {
  display: block;
  width: 100%;
  padding: 9px 11px;
  border: 1px solid #cdd9d0;
  border-radius: 7px;
  background: white;
  color: var(--ink);
}
input[type='checkbox'] {
  accent-color: var(--green);
}
textarea {
  min-height: 84px;
  resize: vertical;
}
.check {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
}
.fixedbtn {
  white-space: nowrap;
}
.pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 12px;
}
.login {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 16px;
  background: linear-gradient(125deg, #dfebe0, #f4f7f3 61%, #eaf1e8);
}
.loginbox {
  width: min(400px, 100%);
  padding: 34px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 15px;
  box-shadow: 0 16px 70px #243c2910;
}
.loginbox .brand {
  margin-bottom: 30px;
}
.loginbox h1 {
  font-size: 26px;
}
.stack {
  display: grid;
  gap: 15px;
}
.error {
  color: #ab3d31;
  white-space: pre-wrap;
}
.notice {
  background: #f2f6ef;
  color: #4e6557;
  padding: 10px 13px;
  border-radius: 7px;
}
.checks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  max-height: 160px;
  overflow: auto;
  gap: 5px;
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 7px;
}
.checks label[hidden] {
  display: none;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  color: var(--ink);
  width: min(560px, 94vw);
  max-height: 90dvh;
  box-shadow: 0 16px 80px #12322535;
}
dialog::backdrop {
  background: #14292168;
}
dialog .panelhead {
  position: sticky;
  top: -22px;
  background: #fff;
  padding: 5px 0;
  z-index: 1;
}
.loginbox .primary {
  padding: 11px;
}
.note {
  font-size: 12px;
  margin-top: 12px;
  color: var(--muted);
}
#toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #1b3c32;
  color: white;
  padding: 10px 16px;
  border-radius: 8px;
  display: none;
  z-index: 5;
}
#toast.show {
  display: block;
}
.mobilemenu {
  display: none;
}
.buttonlink {
  display: inline-block;
  padding: 7px 10px;
}
.scrolltext {
  max-height: 160px;
  overflow: auto;
  white-space: pre-line;
}
.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.tabs .active {
  background: var(--deep);
  color: white;
}
@media (max-width: 920px) {
  .layout {
    grid-template-columns: 175px minmax(0, 1fr);
  }
  aside {
    padding: 20px 9px;
  }
  .grid4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .duo {
    grid-template-columns: 1fr;
  }
  .duo .panel + .panel {
    margin-top: 0;
  }
}
@media (max-width: 650px) {
  .layout {
    display: block;
  }
  aside {
    position: static;
    height: auto;
    padding: 12px 14px;
  }
  .sidehead {
    padding: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .brandmark {
    width: 30px;
    height: 30px;
    font-size: 19px;
  }
  .brand {
    font-size: 17px;
  }
  .mobilemenu {
    display: block;
    background: transparent;
    color: white;
    border-color: #587068;
  }
  aside nav,
  aside .sidefoot {
    display: none;
  }
  aside.open nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 10px;
  }
  aside.open .sidefoot {
    display: flex;
    margin-top: 10px;
  }
  .main {
    padding: 15px 12px 36px;
  }
  .topbar {
    padding-bottom: 10px;
  }
  .pagehead {
    margin: 19px 0 14px;
  }
  .panel {
    padding: 13px;
  }
  .metric {
    padding: 13px;
  }
  .grid4 {
    gap: 8px;
  }
  .tablewrap {
    max-width: 100%;
  }
  .actions button {
    padding: 7px 9px;
  }
}

@media (max-width: 650px) {
  .tablewrap:has(th:nth-child(4)) table {
    min-width: 510px;
  }
  .tablewrap .actions {
    min-width: 110px;
  }
  .actions button {
    white-space: nowrap;
  }
}
