* { box-sizing: border-box; }

:root {
  --bg: #071012;
  --panel: #0d181b;
  --panel-soft: #142327;
  --line: rgba(152, 190, 180, 0.18);
  --text: #e8f1ef;
  --muted: #8fa5a1;
  --teal: #59ddc8;
  --red: #ff7b6b;
  --amber: #f5c45b;
}

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, sans-serif;
}

body.center {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.card {
  width: 100%;
  max-width: 380px;
  padding: 34px 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #0f1d20, #0b1518);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.card.wide { max-width: 900px; }

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
}

.brand .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 12px var(--teal);
}

h1 { margin: 0 0 6px; font-size: 19px; font-weight: 600; }
h2 { margin: 0 0 18px; font-size: 15px; font-weight: 500; color: var(--muted); }

label {
  display: block;
  margin: 14px 0 6px;
  font-size: 12px;
  color: var(--muted);
}

input, select {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #0a1416;
  color: var(--text);
  font-size: 14px;
  outline: none;
}

input:focus, select:focus { border-color: var(--teal); }

button {
  height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 6px;
  background: var(--teal);
  color: #04201c;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

button:hover { filter: brightness(1.08); }
button:disabled { opacity: .55; cursor: not-allowed; }

button.ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 500;
}

button.danger {
  background: transparent;
  border: 1px solid rgba(255, 123, 107, 0.5);
  color: var(--red);
  font-weight: 500;
}

button.small { height: 30px; padding: 0 10px; font-size: 12px; }

.actions { display: flex; gap: 10px; margin-top: 22px; }
.actions button { flex: 1; }

.msg {
  min-height: 18px;
  margin-top: 14px;
  font-size: 12px;
  color: var(--red);
}

.msg.ok { color: var(--teal); }

.foot {
  margin-top: 20px;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}

.foot a { color: var(--teal); text-decoration: none; }

table {
  width: 100%;
  margin-top: 18px;
  border-collapse: collapse;
  font-size: 13px;
}

th, td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th { color: var(--muted); font-weight: 500; font-size: 12px; }

.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  border: 1px solid var(--line);
}

.tag.admin { color: var(--amber); border-color: rgba(245, 196, 91, .45); }
.tag.active { color: var(--teal); border-color: rgba(89, 221, 200, .45); }
.tag.pending { color: var(--amber); border-color: rgba(245, 196, 91, .45); }
.tag.disabled { color: var(--muted); }

.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }

.head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.inline-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 8px;
  align-items: end;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.inline-form label { margin-top: 0; }

@media (max-width: 720px) {
  .inline-form { grid-template-columns: 1fr 1fr; }
  .inline-form button { grid-column: 1 / -1; }
  table { font-size: 12px; }
  th:nth-child(4), td:nth-child(4) { display: none; }
}
