/* 登录、注册、找回密码共享认证外壳。 */
.auth-main {
  max-width: 1120px;
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(300px, .92fr) minmax(390px, 1.08fr);
  gap: 22px;
  align-items: stretch;
}

.auth-brand,
.auth-form-pane {
  min-width: 0;
}

.auth-brand {
  position: relative;
  overflow: hidden;
  min-height: 520px;
  padding: 32px;
  border: 1px solid var(--site-border);
  border-radius: 22px;
  background:
    radial-gradient(circle at 82% 12%, var(--site-primary-soft), transparent 17rem),
    linear-gradient(150deg, color-mix(in srgb, var(--site-card) 96%, transparent), color-mix(in srgb, var(--site-bg-elevated) 90%, transparent));
  box-shadow: var(--site-shadow-soft);
}

.auth-brand::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -80px;
  width: 240px;
  height: 240px;
  border: 1px solid var(--site-border);
  border-radius: 50%;
  box-shadow: 0 0 0 32px color-mix(in srgb, var(--site-primary) 5%, transparent), 0 0 0 64px color-mix(in srgb, var(--site-warm) 4%, transparent);
}

.auth-brand-mark {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--site-text);
  font-size: 16px;
  font-weight: 800;
}

.auth-brand-mark img {
  width: 42px;
  height: 42px;
  border: 1px solid var(--site-border);
  border-radius: 13px;
  background: var(--site-warm-soft);
}

.auth-brand h1 {
  max-width: 360px;
  margin: 62px 0 14px;
  color: var(--site-text);
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.12;
  letter-spacing: -1px;
}

.auth-brand > p {
  max-width: 390px;
  color: var(--site-text-dim);
  font-size: 14px;
  line-height: 1.8;
}

.auth-feature-list {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  margin-top: 34px;
}

.auth-feature {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 11px 12px;
  border: 1px solid var(--site-border-soft);
  border-radius: 13px;
  background: color-mix(in srgb, var(--site-bg-elevated) 64%, transparent);
  color: var(--site-text-dim);
  font-size: 12.5px;
  line-height: 1.55;
}

.auth-feature strong {
  display: block;
  color: var(--site-text);
  font-size: 13px;
}

.auth-feature-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--site-green);
  box-shadow: 0 0 0 5px var(--site-primary-soft);
}

.auth-form-pane {
  display: flex;
  align-items: center;
}

.auth-form-pane .form-card {
  width: 100%;
  margin: 0;
}

.auth-form-pane .form-card,
.auth-form-pane .notice {
  box-shadow: var(--site-shadow-soft);
}

.auth-form-pane .form-title {
  font-size: 27px;
  letter-spacing: -.5px;
}

.auth-form-pane .form-sub {
  margin-bottom: 22px;
}

.password-field {
  position: relative;
}

.password-input-wrap {
  position: relative;
  width: 100%;
}

.password-input-wrap .input {
  width: 100%;
}

.password-field .input {
  padding-right: 80px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  min-width: 58px;
  height: 30px;
  padding: 0 9px;
  border: 1px solid var(--site-border);
  border-radius: 9px;
  background: var(--site-bg-elevated);
  color: var(--site-text-dim);
  cursor: pointer;
  font: inherit;
  font-size: 11px;
  transform: translateY(-50%);
}

.password-toggle:hover {
  color: var(--site-text);
  border-color: var(--site-border-hi);
}

.auth-form-pane .form-msg.ok {
  animation: auth-success .36s ease both;
}

@keyframes auth-success {
  from { opacity: .25; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 900px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-brand {
    min-height: auto;
    padding: 24px;
  }

  .auth-brand h1 {
    margin-top: 34px;
  }
}

@media (max-width: 480px) {
  .auth-main {
    padding-top: 22px;
  }

  .auth-brand {
    padding: 18px;
  }

  .auth-brand h1 {
    font-size: 29px;
  }

  .auth-form-pane .form-card {
    padding: 20px 16px;
  }

  .auth-shell,
  .auth-brand,
  .auth-form-pane,
  .auth-form-pane .form-card {
    min-width: 0;
    max-width: 100%;
  }

  .auth-form-pane .form-foot {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-form-pane .form-msg.ok {
    animation: none;
  }
}
