:root {
  --pink: #f8c8d4;
  --pink-deep: #e891a8;
  --bg: #fff5f8;
  --card: #ffffff;
  --text: #5c3a45;
  --muted: #9a7a84;
  --line: #f3d6de;
  --ok: #7bcf9c;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
}
a { color: var(--pink-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

.topbar {
  background: linear-gradient(90deg, #ffe6ee, #fff);
  border-bottom: 1px solid var(--line);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { font-weight: 700; font-size: 1.15rem; }
.brand span { color: var(--pink-deep); }

.layout { display: flex; min-height: calc(100vh - 54px); }
.sidebar {
  width: 200px;
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 16px 12px;
}
.sidebar a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--text);
  margin-bottom: 6px;
}
.sidebar a:hover, .sidebar a.active {
  background: #ffe9f0;
  text-decoration: none;
}

.content { flex: 1; padding: 20px; }
.card {
  background: var(--card);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: 0 8px 24px rgba(232, 145, 168, 0.12);
  margin-bottom: 16px;
}
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
}
.stat .n { font-size: 1.6rem; font-weight: 700; color: var(--pink-deep); }
.stat .l { color: var(--muted); font-size: 0.9rem; }

table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; font-size: 0.95rem; }
th { color: var(--muted); font-weight: 600; }

.btn {
  display: inline-block;
  background: var(--pink-deep);
  color: #fff !important;
  border: none;
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  text-decoration: none !important;
}
.btn.secondary { background: #fff; color: var(--pink-deep) !important; border: 1px solid var(--pink-deep); }
.btn:hover { opacity: 0.92; }

input, select, textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin: 6px 0 12px;
  font: inherit;
}
input[type="checkbox"],
input[type="radio"] {
  width: auto;
  min-width: 1.1rem;
  height: 1.1rem;
  margin: 0 10px 0 0;
  padding: 0;
  border-radius: 4px;
  vertical-align: middle;
  flex-shrink: 0;
  accent-color: #e891a8;
}
label { font-size: 0.9rem; color: var(--muted); }
label.check-row {
  display: flex;
  align-items: center;
  gap: 0;
  color: var(--text);
  font-size: 0.95rem;
  margin: 0;
  padding: 8px 6px;
  border-radius: 10px;
  cursor: pointer;
}
label.check-row:hover { background: #fff5f8; }
.check-list {
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px 8px;
  margin-bottom: 12px;
  background: #fff;
}

.flash {
  padding: 10px 14px;
  border-radius: 12px;
  margin-bottom: 12px;
}
.flash.ok { background: #e8f8ef; }
.flash.err { background: #ffe8ee; }

.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #fff0f5, #ffe6ee 40%, #fff);
}
.login-card {
  width: 360px;
  background: #fff;
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 12px 40px rgba(232, 145, 168, 0.2);
}
.muted { color: var(--muted); font-size: 0.9rem; }
.tag {
  display: inline-block;
  background: #ffe9f0;
  color: var(--pink-deep);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.8rem;
}
