* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #1f2328;
  background: #f6f7f9;
}
a { color: #2563eb; }
button {
  cursor: pointer;
  border: 1px solid #d0d7de;
  background: #fff;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 13px;
}
button.primary { background: #2563eb; color: #fff; border-color: #2563eb; }
button.danger { color: #b91c1c; border-color: #f0b4b4; }
button:disabled { opacity: 0.5; cursor: not-allowed; }
input, textarea, select {
  border: 1px solid #d0d7de;
  border-radius: 6px;
  padding: 7px 9px;
  font-size: 13px;
  font-family: inherit;
  width: 100%;
}
textarea { min-height: 90px; resize: vertical; }
label { display: block; font-size: 12px; color: #57606a; margin: 8px 0 3px; }

header.top {
  display: flex; align-items: center; gap: 18px;
  background: #fff; border-bottom: 1px solid #e5e7eb;
  padding: 0 20px; height: 52px;
}
header.top .brand { font-weight: 700; }
header.top nav { display: flex; gap: 4px; flex: 1; }
header.top nav a {
  padding: 8px 12px; border-radius: 6px; text-decoration: none; color: #57606a; font-size: 14px;
}
header.top nav a.active { background: #eef2ff; color: #2563eb; font-weight: 600; }

main { max-width: 1080px; margin: 20px auto; padding: 0 20px; }
.card { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 16px; margin-bottom: 16px; }
.card h3 { margin: 0 0 12px; font-size: 15px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.row > div { flex: 1; min-width: 160px; }
.muted { color: #8b949e; font-size: 12px; }
.right { text-align: right; }

table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 7px 8px; border-bottom: 1px solid #eef0f2; vertical-align: top; }
th { color: #57606a; font-weight: 600; font-size: 12px; }
.tag { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 11px; background: #eef2ff; color: #3730a3; }
.tag.ok { background: #dcfce7; color: #166534; }
.tag.warn { background: #fef9c3; color: #854d0e; }
.tag.err { background: #fee2e2; color: #991b1b; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.stats { display: flex; flex-wrap: wrap; gap: 14px; }
.stats div { background: #f6f8fa; border-radius: 8px; padding: 8px 14px; min-width: 90px; }
.stats b { display: block; font-size: 20px; }

.login-box { max-width: 340px; margin: 14vh auto; }
.toast { position: fixed; bottom: 20px; right: 20px; background: #1f2328; color: #fff; padding: 10px 16px; border-radius: 8px; font-size: 13px; opacity: 0; transition: opacity .2s; z-index: 9; }
.toast.show { opacity: 1; }
.checkbox-list { max-height: 180px; overflow: auto; border: 1px solid #eef0f2; border-radius: 6px; padding: 6px; }
.checkbox-list label { display: flex; gap: 8px; align-items: center; margin: 2px 0; font-size: 13px; color: #1f2328; }
.checkbox-list input { width: auto; }
