:root {
  font-family:
    -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei",
    sans-serif;
  color: #24323c;
  background: #f6f7f9;
  font-synthesis: none;
  --accent: #176c67;
  --muted: #71808c;
  --border: #e2e7ec;
  --danger: #ad3d3d;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  border: 1px solid var(--border);
  background: white;
  color: inherit;
  border-radius: 6px;
  padding: 8px 14px;
  font-weight: 500;
}
button:hover {
  background: #f1f6f5;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}
button.danger {
  color: var(--danger);
}
a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 24px;
  line-height: 1.4;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}
h2 {
  font-size: 18px;
}
h3 {
  font-size: 15px;
}
.muted,
.help {
  color: var(--muted);
}
.help {
  font-size: 12px;
  margin-top: 6px;
}
.row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.between {
  justify-content: space-between;
}
.stack {
  display: grid;
  gap: 18px;
}
.panel {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
}
.toolbar {
  margin-bottom: 22px;
}
.empty {
  text-align: center;
  padding: 56px 24px;
  color: var(--muted);
}
.empty h2 {
  color: #3b4c57;
  margin-bottom: 8px;
}
.notice {
  border-left: 3px solid #b9c9c6;
  background: #f0f5f4;
  padding: 12px 16px;
  color: #47635f;
  margin-bottom: 20px;
}
.error {
  color: var(--danger);
  background: #fff1f0;
  padding: 10px 14px;
  border-radius: 6px;
  white-space: pre-wrap;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 16px;
}
.field > span {
  font-weight: 500;
}
.field input,
.field select,
.field textarea {
  border: 1px solid #ced7de;
  border-radius: 5px;
  background: #fff;
  color: #24323c;
  padding: 10px 12px;
  min-width: 0;
  width: 100%;
  outline: none;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px #176c6717;
}
.field textarea {
  min-height: 80px;
  resize: vertical;
}
.field.check {
  flex-direction: row;
  align-items: center;
}
.field.check input {
  width: 18px;
  height: 18px;
}
.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 18px;
}
.actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
}
.badge {
  display: inline-flex;
  padding: 2px 8px;
  background: #eef2f4;
  color: #566875;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
}
.badge.good {
  background: #e7f3ef;
  color: #176c51;
}
.badge.warn {
  background: #fff3de;
  color: #8b641c;
}
.table-wrap {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-variant-numeric: tabular-nums;
}
th {
  font-weight: 500;
  color: #778793;
  background: #f8fafb;
  font-size: 12px;
}
td,
th {
  padding: 14px 12px;
  border-bottom: 1px solid #eaf0f2;
  vertical-align: middle;
}
td small {
  display: block;
  color: var(--muted);
}
tr:last-child td {
  border-bottom: 0;
}
.amount {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.small-btn {
  padding: 4px 9px;
  font-size: 12px;
}
.toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  background: #263d39;
  color: #fff;
  padding: 11px 22px;
  border-radius: 6px;
  z-index: 100;
  max-width: 90vw;
}
.login {
  max-width: 400px;
  margin: 12vh auto;
  background: white;
  border: 1px solid var(--border);
  padding: 36px;
  border-radius: 8px;
}
.brand {
  display: flex;
  align-items: center;
  min-width: 0;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: normal;
  overflow-wrap: anywhere;
}
.environment-label {
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
  white-space: nowrap;
}
.divider {
  height: 1px;
  background: var(--border);
  margin: 22px 0;
}
dialog {
  border: 1px solid var(--border);
  border-radius: 10px;
  max-width: 640px;
  width: calc(100% - 32px);
  padding: 28px;
  max-height: 90dvh;
  overflow: auto;
  color: inherit;
}
dialog::backdrop {
  background: #17273166;
}
dialog h2 {
  margin-bottom: 22px;
}
.code {
  font-family: ui-monospace, SFMono-Regular, monospace;
  background: #f6f8f9;
  border: 1px solid var(--border);
  padding: 10px 12px;
  border-radius: 5px;
  overflow-wrap: anywhere;
  font-size: 12px;
  white-space: pre-wrap;
}
.preview {
  max-width: 180px;
  max-height: 180px;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: 6px;
  margin: 10px 0;
}
.hidden {
  display: none !important;
}
.auth-note {
  max-width: 680px;
}
.steps {
  display: flex;
  gap: 18px;
  margin: 26px 0;
  color: #63776f;
}
.steps span {
  background: #e8f1ee;
  padding: 5px 12px;
  border-radius: 4px;
  font-size: 12px;
}
.mono {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 12px;
  overflow-wrap: anywhere;
}
.field legend {
  font-size: 14px;
}
fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
