/* 登录/注册/设置页 - 与主页风格统一 */
.auth-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.auth-body .sidebar { display: none; }

.auth-page {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  padding: 40px 24px;
  position: relative;
  width: 100%;
}

.auth-page::before {
  content: '';
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(ellipse 60% 40% at 80% 20%, rgba(14, 165, 233, 0.12), transparent),
    radial-gradient(ellipse 50% 30% at 20% 80%, rgba(99, 102, 241, 0.08), transparent);
  pointer-events: none;
}

.auth-split {
  display: flex;
  width: 100%;
  max-width: 960px;
  min-height: 600px;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 8px 40px rgba(0,0,0,.08), 0 0 0 1px rgba(0,0,0,.04);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.auth-brand {
  flex: 1;
  background: linear-gradient(160deg, #0ea5e9 0%, #6366f1 100%);
  padding: 48px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  margin-bottom: 40px;
  opacity: .95;
}
.auth-brand-logo-img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.auth-brand h2 {
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  margin-bottom: 12px;
}

.auth-brand p {
  font-size: 16px;
  color: rgba(255,255,255,.85);
  margin-bottom: 40px;
}

.auth-brand-features {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.auth-brand-features span {
  background: rgba(255,255,255,.2);
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 14px;
  color: #fff;
}

.auth-card-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.auth-card {
  width: 100%;
  max-width: 380px;
  background: transparent;
  border-radius: 24px;
  padding: 48px 40px;
  box-shadow: none;
  position: relative;
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo .icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, #0ea5e9 0%, #6366f1 100%);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.3);
}

.auth-logo h1 {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.auth-logo p {
  font-size: 14px;
  color: #64748b;
  margin-top: 6px;
}

.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
}

.auth-tab {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid #e2e8f0;
  background: #fff;
  border-radius: 12px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: #64748b;
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s, background 0.2s, box-shadow 0.2s;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.auth-tab:hover {
  background: #f8fafc;
  color: #334155;
  border-color: #cbd5e1;
}

.auth-tab.active {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(145deg, #22d3ee 0%, #0ea5e9 45%, #6366f1 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.22) inset,
    0 4px 14px rgba(14, 165, 233, 0.28);
}

.auth-form .form-group {
  margin-bottom: 22px;
}

.auth-form .form-group > label.auth-agree-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 400;
  font-size: 13px;
  line-height: 1.55;
  color: #475569;
  cursor: pointer;
  margin-bottom: 0;
}
.auth-agree-label input[type="checkbox"] {
  width: auto;
  margin-top: 0.2em;
  flex-shrink: 0;
  accent-color: #6366f1;
}
.auth-agree-label > span {
  flex: 1;
  min-width: 0;
}
.auth-agree-label a {
  color: #6366f1;
  font-weight: 600;
}

.auth-form .form-group > label:not(.auth-agree-label) {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #334155;
}

.auth-form input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  font-size: 15px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-form input:focus {
  outline: none;
  border-color: #0ea5e9;
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}

.auth-form input::placeholder {
  color: #94a3b8;
}

/* 验证码 */
.form-group-captcha .captcha-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.form-group-captcha .captcha-input {
  flex: 1;
  min-width: 0;
}
.form-group-captcha .captcha-img-wrap {
  flex-shrink: 0;
}
.captcha-img {
  display: block;
  height: 44px;
  width: 120px;
  border-radius: 8px;
  border: 2px solid #e2e8f0;
  cursor: pointer;
  background: #f8fafc;
}
.captcha-img:hover {
  border-color: #0ea5e9;
}
.captcha-refresh {
  display: inline-block;
  margin-top: 8px;
  font-size: 13px;
  color: #64748b;
  text-decoration: none;
}
.captcha-refresh:hover {
  color: #0ea5e9;
}

.auth-form button[type="submit"] {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-top: 8px;
  padding: 15px 20px;
  min-height: 52px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.2;
  color: #fff;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  background: linear-gradient(145deg, #22d3ee 0%, #0ea5e9 42%, #6366f1 100%);
  background-size: 100% 140%;
  background-position: 50% 0;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 4px 12px rgba(14, 165, 233, 0.28),
    0 12px 28px -8px rgba(99, 102, 241, 0.45);
  transition: transform 0.18s ease, box-shadow 0.2s ease, filter 0.2s ease, background-position 0.25s ease;
}

.auth-form button[type="submit"]::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 42%);
  pointer-events: none;
}

.auth-form button[type="submit"]:hover:not(:disabled) {
  transform: translateY(-2px);
  filter: brightness(1.03);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.32) inset,
    0 8px 20px rgba(14, 165, 233, 0.35),
    0 18px 36px -10px rgba(99, 102, 241, 0.5);
}

.auth-form button[type="submit"]:active:not(:disabled) {
  transform: translateY(0);
  filter: brightness(0.98);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.18) inset,
    0 2px 8px rgba(14, 165, 233, 0.25);
  transition-duration: 0.08s;
}

.auth-form button[type="submit"]:focus-visible {
  outline: none;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 4px 12px rgba(14, 165, 233, 0.28),
    0 12px 28px -8px rgba(99, 102, 241, 0.45),
    0 0 0 3px #fff,
    0 0 0 6px rgba(14, 165, 233, 0.45);
}

.auth-form button[type="submit"]:disabled {
  opacity: 0.58;
  cursor: not-allowed;
  transform: none;
  filter: grayscale(0.08) brightness(0.95);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset, 0 2px 8px rgba(15, 23, 42, 0.08);
}

.auth-footer {
  text-align: center;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid #f1f5f9;
  font-size: 14px;
  color: #64748b;
}

.auth-footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  column-gap: 10px;
  row-gap: 8px;
  max-width: 100%;
}

.auth-footer-dot {
  color: #cbd5e1;
  user-select: none;
  flex-shrink: 0;
}

.auth-footer-agree {
  white-space: nowrap;
}

.auth-footer-note {
  margin: 14px 0 0;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
  text-align: center;
  max-width: 100%;
}

.auth-footer a {
  color: #0ea5e9;
  text-decoration: none;
  font-weight: 500;
}

.auth-footer a:hover {
  text-decoration: underline;
}

.auth-error {
  background: #fef2f2;
  color: #dc2626;
  padding: 14px 16px;
  border-radius: 12px;
  font-size: 14px;
  margin-bottom: 20px;
  display: none;
  border: 1px solid #fecaca;
}

.auth-error.show {
  display: block;
}

/* 设置页等单卡布局（无 auth-split） */
.auth-page > .auth-card {
  max-width: 720px;
  padding: 48px 40px;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(0,0,0,.06), 0 0 0 1px rgba(0,0,0,.04);
}

@media (max-width: 768px) {
  .auth-brand { display: none; }
  .auth-split { min-height: auto; }
  .auth-card-wrap { padding: 32px 24px; }
  .auth-card { padding: 0; }
  .membership-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
