/* ────────────────────────────────────────────────────────────────────────
   Pre-authentication pages (sign in, sign up, password reset, email
   verification) — collection/templates/allauth/layouts/entrance.html.

   Reuses collection/landing.css's design tokens and .lp-nav/.lp-btn
   components so these pages read as a continuation of the public landing
   page, not a separate, older surface. collection/style.css stays loaded
   underneath for Bootstrap-adjacent base resets and untouched MFA/
   passkey/social-login markup (SOCIALACCOUNT_PROVIDERS is empty today,
   but the templates that would render if it weren't are left alone).
   ──────────────────────────────────────────────────────────────────── */

.auth-page {
  min-height: 100vh;
  background: var(--ivory);
  display: block;
}

.auth-shell {
  display: flex;
  width: 100%;
  min-height: calc(100vh - 76px);
}

/* Left panel — brand storytelling, dark/navy to match the landing hero */
.auth-hero {
  flex: 0 0 44%;
  background: linear-gradient(155deg, var(--navy-2) 0%, var(--navy) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 4.5rem;
  position: relative;
  overflow: hidden;
}
.auth-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 20% 20%, rgba(182, 146, 92, 0.14), transparent 60%);
}
.auth-hero-content { position: relative; z-index: 1; max-width: 30rem; }

.auth-hero-headline {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 2.1rem;
  line-height: 1.28;
  letter-spacing: -0.008em;
  color: var(--cream);
  margin: 0 0 1.1rem;
}

.auth-hero-text {
  font-size: 0.98rem;
  line-height: 1.65;
  color: var(--cream-muted);
  margin-bottom: 2.5rem;
  max-width: 26rem;
}

.auth-features { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.auth-features li {
  position: relative;
  padding-left: 20px;
  color: var(--cream-muted);
  font-size: 0.92rem;
  line-height: 1.4;
}
.auth-features li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 6px;
  height: 6px;
  background: var(--gold);
}

/* Right panel — the form itself */
.auth-form-side {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2.5rem;
  background: var(--ivory);
}
.auth-form-wrap { width: 100%; max-width: 380px; }

.auth-h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.65rem;
  line-height: 1.3;
  color: var(--ink);
  text-align: left;
  margin: 0 0 0.5rem;
}

.auth-p {
  font-size: 0.92rem;
  color: var(--ink-muted);
  text-align: left;
  line-height: 1.55;
}

.auth-form-wrap a {
  color: var(--gold-dark);
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 3px;
  transition: text-decoration-color 0.15s ease;
}
.auth-form-wrap a:hover { text-decoration-color: currentColor; }
.auth-form-wrap a:focus-visible {
  outline: 2px solid var(--gold-dark);
  outline-offset: 2px;
  border-radius: 2px;
}

.auth-form-wrap label:not(.visually-hidden) {
  font-size: 0.84rem;
  color: var(--ink-muted);
  font-weight: 500;
}

.auth-form-wrap .form-control,
.auth-form-wrap .form-select {
  padding: 0.65rem 0.85rem;
  border-radius: 3px;
  border-color: var(--rule-light);
  background: #fff;
  color: var(--ink);
}
.auth-form-wrap .form-control:focus,
.auth-form-wrap .form-select:focus {
  /* collection/style.css's old brass-theme focus ring uses !important,
     so this needs it too to win — plain specificity isn't enough
     against an !important declaration. */
  border-color: var(--gold-dark) !important;
  box-shadow: 0 0 0 0.2rem rgba(125, 95, 51, 0.15) !important;
}

.auth-form-wrap .alert {
  border-radius: 3px;
  font-size: 0.875rem;
  border: 1px solid transparent;
}

/* Bootstrap's stock alert palette (bright mint/red/blue) reads as a
   different, more generic product than the rest of this page — restyled
   to the same muted, restrained family as everything else here. Kept as
   distinct hues (not just gold) since these are semantic states, not
   brand accents. */
.auth-form-wrap .alert-danger,
.auth-form-wrap .invalid-feedback {
  color: #9c3b2e;
}
.auth-form-wrap .alert-danger {
  background: #f5e3df;
  border-color: #e3c4bc;
}
.auth-form-wrap .alert-success {
  color: #3f6b4c;
  background: #e3ecdf;
  border-color: #cddbc6;
}
.auth-form-wrap .alert-warning {
  color: #8a5a2b;
  background: #f1e4cf;
  border-color: #e2cfa8;
}
.auth-form-wrap .alert-info {
  color: #3d5568;
  background: #e2e9ee;
  border-color: #c7d3dc;
}
.auth-form-wrap .alert .btn-close {
  opacity: 0.5;
  transition: opacity 0.15s ease;
}
.auth-form-wrap .alert .btn-close:hover { opacity: 0.85; }
.auth-form-wrap .alert .btn-close:focus-visible {
  outline: 2px solid var(--gold-dark);
  outline-offset: 2px;
  opacity: 0.85;
  box-shadow: none;
}

.auth-form-wrap .form-control.is-invalid,
.auth-form-wrap .form-select.is-invalid {
  border-color: #c2685a;
}
.auth-form-wrap .form-control.is-invalid:focus,
.auth-form-wrap .form-select.is-invalid:focus {
  border-color: #9c3b2e !important;
  box-shadow: 0 0 0 0.2rem rgba(156, 59, 46, 0.15) !important;
}

/* Disabled inputs/buttons — still legible, clearly non-interactive */
.auth-form-wrap .form-control:disabled,
.auth-form-wrap .form-select:disabled {
  background: var(--ivory-2);
  color: var(--ink-muted);
  opacity: 1;
}
.auth-form-wrap .lp-btn:disabled,
.auth-form-wrap .lp-btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* Browser autofill (Chrome/Edge/Safari) forces its own yellow/blue
   background + black text via an internal UA style that normal
   `background`/`color` rules can't override — the only reliable fix is
   an absurdly long transition delay on an internal box-shadow, which
   paints over the autofill background without touching layout. Also
   forces the ink color so text stays readable against it. */
.auth-form-wrap .form-control:-webkit-autofill,
.auth-form-wrap .form-control:-webkit-autofill:hover,
.auth-form-wrap .form-control:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--ink);
  caret-color: var(--ink);
  box-shadow: 0 0 0 1000px #fff inset;
  transition: background-color 600000s 0s, color 600000s 0s;
}

@media (max-width: 900px) {
  .auth-hero { display: none; }
  .auth-shell { min-height: calc(100vh - 64px); }
  .auth-form-side { padding: 3rem 1.5rem; align-items: flex-start; }
}
