/* Sign up, log in, the email code, forgot password and the reset page in
   the homepage look (templates/register.html, login.html, verify_otp.html,
   forgot_password.html, reset_password.html): lavender with the faint QR
   pattern, Inter, navy headings, purple buttons, one clean white card.
   Loaded after each page's own styles and scoped to .auth-look, so only
   the look changes: every field, link, message and script is the same.
   Phones first: the card stays a card on a phone, every tap target is
   44px or taller. */
.auth-page.auth-look {
  --al-ink: #16133A; --al-muted: #4B4A63; --al-line: #E4E1F5; --al-purple: #4F46E5;
  --al-purple-dark: #4338CA; --al-soft: #EEF2FF; --al-bg: #F7F6FF;
  --al-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  position: relative; isolation: isolate; overflow: hidden;
  min-height: calc(100vh - 68px); display: flex; align-items: flex-start; justify-content: center;
  padding: 28px 16px 48px; background: var(--al-bg); font-family: var(--al-font); color: var(--al-ink);
}
/* The faint QR pattern, stronger at the edges, faded out behind the card. */
.auth-page.auth-look::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: url("../img/qr-pattern.svg") 0 0 / 320px 320px repeat; opacity: .05;
  -webkit-mask-image: linear-gradient(90deg, #000 0, transparent 22%, transparent 78%, #000 100%);
  mask-image: linear-gradient(90deg, #000 0, transparent 22%, transparent 78%, #000 100%);
}
.auth-look *, .auth-look *::before, .auth-look *::after { box-sizing: border-box; }
.auth-look .auth-card {
  width: 100%; max-width: 440px; background: #fff; border: 1px solid var(--al-line); border-radius: 20px;
  box-shadow: 0 1px 2px rgba(22,19,58,.04), 0 16px 40px rgba(22,19,58,.08); padding: 28px 20px 24px;
}
.auth-look .auth-title {
  font-family: var(--al-font); font-size: 26px; line-height: 1.2; font-weight: 900; letter-spacing: -.025em;
  color: var(--al-ink); text-align: center; margin: 0 0 8px; text-wrap: balance;
}
.auth-look .auth-sub {
  font-size: 16px; line-height: 1.5; font-weight: 500; color: var(--al-muted); text-align: center;
  margin: 0 auto 22px; max-width: 34ch; text-wrap: balance;
}
.auth-look .auth-intent-chip { font-family: var(--al-font); border-radius: 999px; }
/* Fields */
.auth-look .auth-field { margin-bottom: 16px; }
.auth-look .auth-field label {
  font-size: 15px; font-weight: 700; color: var(--al-ink); text-transform: none; letter-spacing: 0; margin-bottom: 6px;
}
.auth-look .auth-field label .optional { color: var(--al-muted); font-weight: 500; }
.auth-look .auth-field input {
  min-height: 48px; padding: 10px 14px; font-size: 16px; font-family: var(--al-font); color: var(--al-ink);
  border: 1.5px solid var(--al-line); border-radius: 12px; background: #fff;
}
.auth-look .pw-wrapper input { padding-right: 52px; }
.auth-look .auth-field input:focus { border-color: var(--al-purple); box-shadow: 0 0 0 3px rgba(79,70,229,.15); }
.auth-look .auth-hint, .auth-look .otp-hint { font-size: 14px; color: var(--al-muted); }
.auth-look .pw-toggle { color: var(--al-muted); }
/* Checkbox rows: the whole row is the tap target. */
.auth-look .remember-row { min-height: 44px; margin-bottom: 18px; }
.auth-look .remember-row input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--al-purple); }
.auth-look .remember-row label {
  display: inline-flex; align-items: center; min-height: 44px; font-size: 15px; color: var(--al-ink);
}
/* Buttons */
.auth-look .auth-submit {
  min-height: 52px; border-radius: 12px; background: var(--al-purple); color: #fff;
  font: 800 17px/1.2 var(--al-font); letter-spacing: -.01em; box-shadow: 0 6px 16px rgba(79,70,229,.25);
}
.auth-look .auth-submit:hover { background: var(--al-purple-dark); }
.auth-look .auth-submit:focus-visible, .auth-look .google-btn:focus-visible, .auth-look a:focus-visible {
  outline: 3px solid #A5B4FC; outline-offset: 2px;
}
.auth-look .google-btn {
  min-height: 52px; border: 1.5px solid var(--al-line); border-radius: 12px; font: 700 16px/1.2 var(--al-font); color: var(--al-ink);
}
.auth-look .google-btn:hover { border-color: #C7C2EE; background: var(--al-bg); color: var(--al-ink); }
.auth-look .or-divider { color: var(--al-muted); font-size: 13px; margin: 18px 0; }
.auth-look .or-divider::before, .auth-look .or-divider::after, .auth-look .auth-divider { border-color: var(--al-line); }
/* Links: 44px tall to tap. */
.auth-look .auth-forgot, .auth-look .auth-link, .auth-look .auth-back {
  display: flex; align-items: center; justify-content: center; min-height: 44px; margin: 4px 0 0;
  font-size: 15px; font-weight: 700; color: var(--al-purple); text-decoration: none;
}
.auth-look .auth-signup-line, .auth-look .auth-signin-line, .auth-look .auth-trust-line {
  font-size: 15px; color: var(--al-muted); text-align: center; text-wrap: balance;
}
.auth-look .auth-signup-line a, .auth-look .auth-signin-line a, .auth-look .auth-footer-links a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px;
  color: var(--al-purple); font-weight: 800; text-decoration: none;
}
.auth-look .auth-forgot:hover, .auth-look .auth-link:hover, .auth-look .auth-back:hover,
.auth-look .auth-signup-line a:hover, .auth-look .auth-signin-line a:hover, .auth-look .auth-footer-links a:hover { text-decoration: underline; }
.auth-look .auth-footer-links { font-size: 15px; }
.auth-look .success-icon { background: var(--al-soft); }
/* Errors and notices shown on these pages keep their words; only the shape follows the card. */
.auth-look .flash, .auth-look .alert { border-radius: 12px; }
@media (min-width: 600px) {
  .auth-page.auth-look { align-items: center; padding: 48px 24px 64px; }
  .auth-look .auth-card { padding: 36px 36px 28px; border-radius: 24px; }
  .auth-look .auth-title { font-size: 30px; }
}
/* The pages' own phone rules turned the card into a flat white page; the
   new look keeps the card (these win: two classes). */
@media (max-width: 480px) {
  .auth-page.auth-look { background: var(--al-bg); }
  .auth-look .auth-card { border: 1px solid var(--al-line); border-radius: 18px; box-shadow: 0 1px 2px rgba(22,19,58,.04), 0 12px 28px rgba(22,19,58,.07); padding: 24px 18px 20px; }
}

