:root {
  --bg: #070a10;
  --panel: #0d121b;
  --panel-2: #101724;
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(111, 155, 255, .30);
  --text: #e8edf7;
  --muted: #8590a3;
  --dim: #5d6779;
  --accent: #6f9bff;
  --accent-2: #a78bfa;
  --ok: #4fd1a5;
  --warn: #f2b45c;
  --bad: #ff6b81;
  --radius: 14px;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.6 "Segoe UI", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(900px 480px at 18% -8%, rgba(111, 155, 255, .16), transparent 60%),
    radial-gradient(800px 460px at 88% 4%, rgba(167, 139, 250, .10), transparent 55%),
    radial-gradient(700px 520px at 50% 112%, rgba(79, 209, 165, .06), transparent 60%);
}

.bg-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .38;
  background-image:
    linear-gradient(rgba(255, 255, 255, .028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .028) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 28%, transparent 78%);
  mask-image: radial-gradient(ellipse at 50% 0%, #000 28%, transparent 78%);
}

a { color: inherit; }

/* ---------------- 顶栏 ---------------- */

.topbar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 34px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 10, 16, .55);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.brand { display: flex; align-items: center; gap: 12px; }

.mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: #cfe0ff;
  background: linear-gradient(160deg, rgba(111, 155, 255, .22), rgba(167, 139, 250, .12));
  border: 1px solid rgba(111, 155, 255, .30);
  box-shadow: 0 8px 24px rgba(20, 40, 90, .35), inset 0 1px 0 rgba(255, 255, 255, .08);
}

.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 12.5px; letter-spacing: .24em; font-weight: 600; }
.brand-text small { color: var(--muted); font-size: 11.5px; letter-spacing: .10em; margin-top: 3px; }

.top-right { display: flex; align-items: center; gap: 12px; }

.chip {
  font-size: 10.5px;
  letter-spacing: .12em;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid rgba(111, 155, 255, .25);
  color: #a9c2ff;
  background: rgba(111, 155, 255, .08);
}

.who { color: var(--muted); font-size: 12.5px; }

.ghost {
  font: inherit;
  font-size: 12.5px;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 12px;
  cursor: pointer;
  transition: .15s;
}
.ghost:hover { color: var(--text); border-color: rgba(255, 255, 255, .18); }

.logout-form { margin: 0; }

/* ---------------- 主区 ---------------- */

.wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 46px 34px 30px;
  flex: 1;
}

.intro { margin-bottom: 28px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--dim);
  margin-bottom: 12px;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.intro h1 {
  margin: 0 0 8px;
  font-size: 27px;
  font-weight: 600;
  letter-spacing: .01em;
}

.intro p { margin: 0; color: var(--muted); font-size: 13.5px; }
.intro p b { color: var(--text); font-weight: 600; }

/* ---------------- 站点卡片 ---------------- */

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 26px;
}

.card {
  position: relative;
  padding: 20px 20px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .010));
  overflow: hidden;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(420px 130px at 82% -30%, rgba(111, 155, 255, .16), transparent 70%);
  opacity: 0;
  transition: opacity .25s ease;
  pointer-events: none;
}

.card:hover {
  transform: translateY(-2px);
  border-color: var(--line-2);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .38);
}
.card:hover::after { opacity: 1; }

.card.off { opacity: .62; }
.card.off:hover { transform: none; border-color: var(--line); box-shadow: none; }

.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 10.5px;
  letter-spacing: .12em;
  color: var(--dim);
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dim);
}
.dot.on {
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(79, 209, 165, .10), 0 0 12px rgba(79, 209, 165, .55);
}

.tag {
  font-size: 11px;
  color: var(--dim);
  letter-spacing: .04em;
  font-variant-numeric: tabular-nums;
}

.card h2 {
  margin: 0 0 4px;
  font-size: 17.5px;
  font-weight: 600;
  letter-spacing: .01em;
}

.card .meta {
  margin: 0 0 20px;
  color: var(--dim);
  font-size: 11.5px;
  letter-spacing: .04em;
}

.card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.enter {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: #cfe0ff;
  text-decoration: none;
  letter-spacing: .04em;
}
.enter span { transition: transform .15s ease; }
.enter:hover span { transform: translateX(3px); }
.enter:hover { color: #fff; }

.pending { font-size: 11.5px; color: var(--dim); letter-spacing: .08em; }

/* ---------------- 面板 / 表格 ---------------- */

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .018);
  overflow: hidden;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 20px;
  border-bottom: 1px solid var(--line);
}

.panel-head h3 {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .16em;
  color: var(--muted);
  text-transform: uppercase;
}

.panel-head .hint { font-size: 11px; color: var(--dim); }

table.log { width: 100%; border-collapse: collapse; }

table.log th {
  text-align: left;
  font-size: 10.5px;
  letter-spacing: .14em;
  color: var(--dim);
  font-weight: 500;
  padding: 10px 20px;
  background: rgba(255, 255, 255, .012);
}

table.log td {
  padding: 11px 20px;
  font-size: 12.5px;
  border-top: 1px solid rgba(255, 255, 255, .045);
  color: var(--muted);
}

table.log td.t { color: var(--dim); font-variant-numeric: tabular-nums; white-space: nowrap; }
table.log td.a { color: var(--text); }
table.log td.s { color: #a9c2ff; }

.empty { padding: 26px 20px; color: var(--dim); font-size: 12.5px; text-align: center; }

.banner {
  position: relative;
  z-index: 2;
  max-width: 1120px;
  margin: 18px auto -18px;
  padding: 11px 16px;
  border-radius: 10px;
  font-size: 12.5px;
  display: flex;
  gap: 12px;
  align-items: center;
}
.banner.warn {
  border: 1px solid rgba(242, 180, 92, .28);
  background: rgba(242, 180, 92, .07);
  color: #f3d3a3;
}
.banner strong { letter-spacing: .06em; }

.note {
  margin-top: 18px;
  font-size: 11.5px;
  color: var(--dim);
  line-height: 1.8;
}

/* ---------------- 登录页 ---------------- */

.login-wrap {
  position: relative;
  z-index: 2;
  flex: 1;
  display: grid;
  place-items: center;
  padding: 40px 20px;
}

.login-card {
  width: 384px;
  max-width: 100%;
  padding: 30px 30px 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012));
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .06);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 26px;
}

.login-card h1 {
  margin: 0 0 6px;
  font-size: 21px;
  font-weight: 600;
}

.login-card .sub {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 12.5px;
  letter-spacing: .03em;
}

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 13px; }
.field span { font-size: 11.5px; color: var(--muted); letter-spacing: .04em; }

input[type="text"],
input[type="password"] {
  width: 100%;
  background: #090e16;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 11px 12px;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}

input[type="text"]:focus,
input[type="password"]:focus {
  border-color: rgba(111, 155, 255, .55);
  box-shadow: 0 0 0 3px rgba(111, 155, 255, .12);
}

button.primary {
  width: 100%;
  margin-top: 8px;
  padding: 11px 14px;
  border: 1px solid rgba(111, 155, 255, .40);
  border-radius: 9px;
  background: linear-gradient(180deg, rgba(111, 155, 255, .26), rgba(111, 155, 255, .14));
  color: #eaf1ff;
  font: inherit;
  font-size: 13.5px;
  letter-spacing: .06em;
  cursor: pointer;
  transition: .18s;
}
button.primary:hover {
  background: linear-gradient(180deg, rgba(111, 155, 255, .34), rgba(111, 155, 255, .18));
  border-color: rgba(111, 155, 255, .60);
  box-shadow: 0 10px 28px rgba(50, 90, 190, .28);
}

.alert {
  margin: 0 0 16px;
  padding: 10px 12px;
  border-radius: 9px;
  border: 1px solid rgba(255, 107, 129, .26);
  background: rgba(255, 107, 129, .07);
  color: #ffb9c3;
  font-size: 12.5px;
}

.hintline {
  margin: 16px 0 0;
  color: var(--dim);
  font-size: 11.5px;
  line-height: 1.7;
}

.fromline {
  margin: -10px 0 16px;
  color: var(--dim);
  font-size: 11.5px;
}

/* ---------------- 页脚 ---------------- */

.foot {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px 34px 30px;
  color: var(--dim);
  font-size: 11px;
  letter-spacing: .06em;
}

.dot-sep { width: 3px; height: 3px; border-radius: 50%; background: var(--dim); opacity: .7; }

@media (max-width: 760px) {
  .topbar { padding: 13px 18px; }
  .brand-text small { display: none; }
  .wrap { padding: 28px 18px 20px; }
  .grid { grid-template-columns: 1fr; }
  .intro h1 { font-size: 22px; }
  table.log th, table.log td { padding-left: 14px; padding-right: 14px; }
  .banner { margin: 14px 18px -10px; }
}
