/* ==========================================================================
   页面级样式：登录页 / 门户首页 / 后台管理
   ========================================================================== */

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

.auth-body { min-height: 100vh; overflow-x: hidden; }

.auth-shell {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  min-height: 100vh;
}

.auth-brand {
  position: relative;
  overflow: hidden;
  background: linear-gradient(150deg, #312e81 0%, #4f46e5 46%, #7c3aed 100%);
  color: #fff;
  display: flex;
  align-items: center;
  padding: 56px 60px;
}

.auth-brand-inner { position: relative; z-index: 2; max-width: 460px; }
.auth-brand .brand { color: #fff; }
.auth-brand .brand-mark { background: rgba(255, 255, 255, .18); box-shadow: none; backdrop-filter: blur(6px); }

.auth-headline {
  font-size: 40px;
  line-height: 1.16;
  margin: 40px 0 18px;
  font-weight: 720;
  letter-spacing: -.03em;
}

.auth-sub { font-size: 16px; line-height: 1.7; color: rgba(255, 255, 255, .82); margin: 0 0 38px; max-width: 400px; }

.auth-points { list-style: none; padding: 0; margin: 0 0 44px; display: grid; gap: 18px; }
.auth-points li { display: flex; gap: 14px; align-items: flex-start; font-size: 14.5px; line-height: 1.5; }
.auth-points .pt-ico {
  width: 36px; height: 36px; flex: none;
  display: grid; place-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, .14);
  font-size: 17px;
  backdrop-filter: blur(6px);
}
.auth-points .muted { color: rgba(255, 255, 255, .62); }
.auth-foot { color: rgba(255, 255, 255, .55) !important; }

.auth-glow {
  position: absolute;
  width: 620px; height: 620px;
  right: -230px; bottom: -260px;
  background: radial-gradient(circle, rgba(255, 255, 255, .26), transparent 66%);
  border-radius: 50%;
  pointer-events: none;
}

.auth-form-side { display: flex; align-items: center; justify-content: center; padding: 40px 28px; }

.auth-card { width: 100%; max-width: 396px; }

.auth-mobile-brand { display: none; align-items: center; gap: 10px; margin-bottom: 30px; }

.auth-title { font-size: 27px; margin-bottom: 7px; letter-spacing: -.025em; }
.auth-desc { margin: 0 0 30px; font-size: 14.5px; }
.auth-note { margin: 22px 0 0; line-height: 1.65; }

.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 46px; }
.pw-toggle {
  position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
  border: 0; background: none; cursor: pointer;
  font-size: 15px; padding: 7px 9px; border-radius: 7px; color: var(--muted); line-height: 1;
}
.pw-toggle:hover { background: var(--surface-2); color: var(--text); }

@media (max-width: 900px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-mobile-brand { display: flex; }
  .auth-form-side { min-height: 100vh; }
}

/* ------------------------------ 门户首页 ------------------------------ */

.page { padding: 34px 0 72px; }

.hero { margin-bottom: 26px; }
.hero h1 { font-size: 27px; letter-spacing: -.025em; margin-bottom: 6px; }
.hero p { margin: 0; color: var(--muted); font-size: 14.5px; }

.stat-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }

.stat-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: 13.5px;
  box-shadow: var(--shadow-sm);
}
.stat-chip b { font-weight: 680; }
.stat-chip .muted { font-size: 12.5px; }

.toolbar {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  margin: 26px 0 20px;
}

.search-wrap { position: relative; flex: 1; min-width: 220px; max-width: 420px; }
.search-wrap .input { padding-left: 38px; }
.search-ico {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 14px; pointer-events: none;
}

.chips { display: flex; gap: 7px; flex-wrap: wrap; }

.chip {
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 550;
  color: var(--text-2);
  cursor: pointer;
  transition: all .14s;
}
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-color: transparent; color: #fff;
  box-shadow: 0 2px 8px color-mix(in srgb, var(--accent) 30%, transparent);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(272px, 1fr));
  gap: 16px;
}

.pcard {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: transform .16s cubic-bezier(.2,.8,.3,1), box-shadow .16s, border-color .16s;
  position: relative;
  overflow: hidden;
  min-height: 158px;
}
.pcard::after {
  content: '';
  position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  opacity: 0;
  transition: opacity .16s;
}
.pcard:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in srgb, var(--accent) 32%, var(--border));
  text-decoration: none;
}
.pcard:hover::after { opacity: 1; }
.pcard.is-down { opacity: .62; }

.pcard-top { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 11px; }

.pcard-ico {
  width: 42px; height: 42px; flex: none;
  border-radius: 11px;
  display: grid; place-items: center;
  font-size: 21px;
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 16%, transparent);
}

.pcard-name { font-weight: 640; font-size: 15.5px; letter-spacing: -.012em; margin-bottom: 3px; }
.pcard-cat { font-size: 11.5px; color: var(--muted); font-weight: 550; letter-spacing: .02em; }

.pcard-desc {
  font-size: 13.5px; color: var(--text-2); line-height: 1.55;
  margin: 0 0 14px;
  flex: 1;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.pcard-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding-top: 12px; border-top: 1px solid var(--border);
  font-size: 12px; color: var(--muted);
}
.pcard-addr { font-family: var(--mono); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard-status { display: inline-flex; align-items: center; gap: 6px; font-weight: 560; white-space: nowrap; }

/* ------------------------------ 后台管理 ------------------------------ */

.admin-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.admin-head h1 { font-size: 25px; letter-spacing: -.025em; }

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(158px, 1fr));
  gap: 13px;
  margin-bottom: 28px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 17px 18px;
  box-shadow: var(--shadow-sm);
}
.stat-card .k { font-size: 12.5px; color: var(--muted); font-weight: 550; margin-bottom: 7px; }
.stat-card .v { font-size: 25px; font-weight: 700; letter-spacing: -.03em; line-height: 1.1; }
.stat-card .s { font-size: 12px; color: var(--muted); margin-top: 5px; }

.section-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; margin-bottom: 14px; flex-wrap: wrap;
}
.section-head h2 { font-size: 17.5px; }

.audit-line { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; align-items: baseline; }
.audit-line:last-child { border-bottom: 0; }
.audit-line .t { color: var(--muted); font-size: 12px; white-space: nowrap; font-family: var(--mono); }
.audit-line .a { font-weight: 600; }
.audit-line .d { color: var(--muted); font-size: 12.5px; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 860px) { .two-col { grid-template-columns: 1fr; } }

/* 打印 */
@media print {
  .topbar, .toolbar, .btn { display: none !important; }
}
