:root {
  --auth-orange: #ff6500;
  --auth-orange-hover: #eb5d00;
  --auth-ink: #171717;
  --auth-muted: #777;
  --auth-line: #dedede;
  --auth-soft: #f7f7f7;
}

.login-view {
  min-height: 100vh !important;
  padding: 42px 24px !important;
  background: #fff !important;
  overflow-y: auto;
  overflow-x: hidden;
}

.auth-pending .mobile-nav-trigger,
.auth-pending .mobile-nav-scrim,
.auth-pending .mobile-nav-drawer {
  display: none !important;
}

.auth-shell {
  width: min(590px, 100%);
  margin: auto;
}

.auth-brand {
  position: static !important;
  z-index: auto !important;
  inset: auto !important;
  width: auto !important;
  height: auto !important;
  display: grid;
  justify-items: center;
  gap: 6px;
  margin: 0 0 42px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

.auth-brand .brand-logo-login {
  width: 230px !important;
  margin: 0 !important;
}

.auth-brand p {
  margin: 0;
  color: var(--auth-muted);
  font-size: 16px;
  letter-spacing: .08em;
}

.login-card.auth-panel {
  width: 100% !important;
  display: grid;
  gap: 24px !important;
}

.login-card.auth-panel[hidden] {
  display: none !important;
}

.auth-heading {
  text-align: center;
}

.login-card .auth-heading h1 {
  display: block !important;
  margin: 4px 0 8px;
  color: var(--auth-ink);
  font-size: 28px;
  line-height: 1.3;
}

.login-card .auth-heading > p:not(.eyebrow) {
  display: block !important;
  margin: 0;
  color: var(--auth-muted);
  font-size: 14px;
}

.auth-heading .eyebrow {
  color: var(--auth-orange);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .18em;
}

.login-form {
  display: grid;
  gap: 18px !important;
}

.login-form label {
  display: grid;
  color: #666 !important;
  font-size: 14px !important;
  line-height: 1.4;
}

.login-form input {
  width: 100%;
  min-height: 56px !important;
  margin-top: 7px;
  padding: 0 16px !important;
  border: 1px solid var(--auth-line) !important;
  border-radius: 7px !important;
  background: #fff;
  color: var(--auth-ink);
  font-size: 16px !important;
}

.login-form input:focus {
  border-color: var(--auth-orange) !important;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(255, 101, 0, .1) !important;
}

.auth-primary {
  min-height: 56px !important;
  margin-top: 4px;
  border-color: var(--auth-orange) !important;
  background: var(--auth-orange) !important;
  color: #fff !important;
  font-size: 17px !important;
}

.auth-primary:hover {
  border-color: var(--auth-orange-hover) !important;
  background: var(--auth-orange-hover) !important;
}

.auth-switch,
.auth-footer {
  text-align: center;
  color: var(--auth-muted);
  font-size: 14px;
}

.auth-switch a,
.auth-footer a,
.privacy-consent a {
  color: var(--auth-orange);
  text-decoration: none;
}

.auth-footer {
  display: flex;
  justify-content: center;
  gap: 12px;
  font-size: 12px;
}

.register-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--auth-line);
}

.register-method {
  padding: 13px 8px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: #fff;
  color: #888;
  font: inherit;
  font-size: 17px;
  cursor: pointer;
}

.register-method.active {
  border-bottom-color: var(--auth-orange);
  color: var(--auth-ink);
}

.register-method small,
.wechat-register small {
  display: inline-flex;
  margin-left: 5px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #f1f1f1;
  color: #777;
  font-size: 10px;
}

.register-method small.available,
.wechat-register small.available {
  background: #eaf8ef;
  color: #178348;
}

.code-row {
  display: grid;
  grid-template-columns: 1fr 126px;
  gap: 10px;
}

.code-row input {
  margin-top: 0 !important;
}

.code-row .btn {
  min-height: 56px;
  padding: 0 12px;
  border: 1px solid var(--auth-line) !important;
  border-radius: 7px !important;
  background: #fff !important;
  color: var(--auth-ink) !important;
}

.phone-row {
  display: grid;
  grid-template-columns: 66px 1fr;
  margin-top: 7px;
  border: 1px solid var(--auth-line);
  border-radius: 7px;
  overflow: hidden;
}

.phone-row span {
  display: grid;
  place-items: center;
  border-right: 1px solid var(--auth-line);
  background: var(--auth-soft);
  color: #555;
}

.phone-row input {
  margin: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
}

.phone-row:focus-within {
  border-color: var(--auth-orange);
  box-shadow: 0 0 0 3px rgba(255, 101, 0, .1);
}

.privacy-consent {
  display: flex !important;
  grid-template-columns: none !important;
  align-items: flex-start;
  gap: 9px;
  color: #777 !important;
  font-size: 13px !important;
}

.privacy-consent input {
  width: 16px !important;
  min-height: 16px !important;
  margin: 1px 0 0 !important;
  accent-color: var(--auth-orange);
}

.third-party-register {
  display: grid;
  gap: 12px;
}

.third-party-register > span {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #999;
  font-size: 12px;
}

.third-party-register > span::before,
.third-party-register > span::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--auth-line);
}

.wechat-register {
  min-height: 58px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border: 1px solid var(--auth-line);
  border-radius: 7px;
  background: #fff;
  color: var(--auth-ink);
  text-align: left;
  cursor: pointer;
}

.wechat-register:disabled,
.register-method:disabled {
  cursor: not-allowed;
  opacity: .65;
}

.sync-error:empty {
  display: none;
}

.sync-error:not(:empty) {
  padding: 10px 12px;
  border-left: 3px solid #d92d20;
  background: #fff4f2;
  color: #b42318;
  font-size: 13px;
}

@media (max-width: 640px) {
  .login-view { padding: 28px 18px !important; }
  .auth-shell { max-width: 100%; }
  .auth-brand { margin-bottom: 28px; }
  .auth-brand .brand-logo-login { width: 190px !important; }
  .auth-brand p { font-size: 14px; }
  .login-card.auth-panel { gap: 20px !important; }
  .code-row { grid-template-columns: 1fr 112px; }
}

.legal-page {
  min-height: 100vh;
  padding: 48px 24px 80px;
  background: #fff;
  color: var(--auth-ink);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
}

.legal-document {
  width: min(820px, 100%);
  margin: 0 auto;
}

.legal-document > a {
  color: var(--auth-orange);
  text-decoration: none;
}

.legal-document h1 {
  margin: 36px 0 8px;
  font-size: 34px;
}

.legal-document h2 {
  margin: 30px 0 10px;
  font-size: 20px;
}

.legal-document p,
.legal-document li {
  color: #555;
  font-size: 15px;
  line-height: 1.85;
}

.legal-document .legal-meta,
.legal-document .legal-notice {
  padding: 14px 16px;
  border-left: 3px solid var(--auth-orange);
  background: var(--auth-soft);
}
