/* ============================================================
   ABF Auth Pages — Shared Styles
   Used by: login.html, signup.html, reset-password.html,
            update-password.html
   ============================================================ */

* { -webkit-tap-highlight-color: transparent; }

body {
  background: var(--warm-cream);
  min-height: 100vh;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.auth-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 20px;
  background:
    radial-gradient(circle at 80% 20%, rgba(164,34,23,0.06), transparent 50%),
    radial-gradient(circle at 10% 80%, rgba(140,139,131,0.08), transparent 50%);
}
.auth-card {
  background: white;
  border-radius: 12px;
  box-shadow: var(--premium-shadow);
  padding: 44px 26px;
  max-width: 460px;
  width: 100%;
}
@media (min-width: 480px) {
  .auth-card { padding: 52px 44px; }
}

.auth-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 30px;
}
.auth-logo a { display: inline-flex; line-height: 0; }
.auth-logo img { height: 80px; width: auto; display: block; }
@media (min-width: 480px) {
  .auth-logo img { height: 96px; }
}

.auth-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brand-red);
  margin-bottom: 14px;
}
.auth-eyebrow::before,
.auth-eyebrow::after {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--brand-red);
}
.auth-card h1 {
  font-family: 'Fraunces', Georgia, serif;
  font-size: clamp(1.7rem, 5.5vw, 2.1rem);
  font-weight: 600;
  text-align: center;
  margin: 0 0 12px;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.auth-sub {
  color: #6A6A66;
  text-align: center;
  margin: 0 0 28px;
  font-size: 0.96rem;
  line-height: 1.6;
}
.auth-sub strong { color: var(--ink); }

/* Field */
.auth-field { margin-bottom: 16px; }
.auth-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 8px;
}
.auth-field label {
  display: block;
  font-weight: 600;
  font-size: 0.84rem;
  color: var(--ink);
  margin-bottom: 8px;
  letter-spacing: 0.01em;
}
.auth-label-row label { margin-bottom: 0; }

.auth-field input {
  width: 100%;
  padding: 15px 16px;
  border: 1.5px solid rgba(27,27,26,0.12);
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
  background: var(--warm-cream);
  color: var(--ink);
  transition: all 0.2s;
  -webkit-appearance: none;
  appearance: none;
}
.auth-field input:focus {
  outline: none;
  border-color: var(--brand-red);
  background: white;
  box-shadow: 0 0 0 3px rgba(164,34,23,0.08);
}

/* Password input + show/hide */
.auth-pw-wrap { position: relative; }
.auth-pw-wrap input { padding-right: 50px; }
.auth-pw-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  cursor: pointer;
  color: #8A8A86;
  padding: 8px;
  border-radius: 6px;
  display: flex;
  align-items: center;
}
.auth-pw-toggle:hover { color: var(--brand-red); }

.auth-link-sm {
  color: var(--brand-red);
  font-weight: 600;
  font-size: 0.82rem;
  text-decoration: none;
}
.auth-link-sm:hover { text-decoration: underline; }

/* Two-column grid for first/last name */
.auth-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Primary button */
.auth-btn {
  width: 100%;
  padding: 17px;
  background: var(--ink);
  color: white;
  border: none;
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.98rem;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  font-family: inherit;
  margin-top: 10px;
  min-height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.auth-btn:hover:not(:disabled) {
  background: var(--brand-red);
  transform: translateY(-2px);
  box-shadow: 0 16px 40px -10px rgba(164,34,23,0.4);
}
.auth-btn:active { transform: translateY(0); }
.auth-btn:disabled {
  background: rgba(27,27,26,0.18);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.auth-btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.auth-btn-ghost {
  background: transparent;
  color: var(--brand-red);
  border: 1.5px solid var(--brand-red);
}
.auth-btn-ghost:hover:not(:disabled) {
  background: var(--brand-red);
  color: white;
}

/* Google OAuth button */
.auth-btn-google {
  width: 100%;
  padding: 14px 18px;
  background: white;
  color: var(--ink);
  border: 1.5px solid rgba(27,27,26,0.18);
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.96rem;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.auth-btn-google:hover:not(:disabled) {
  border-color: rgba(27,27,26,0.4);
  background: var(--warm-cream);
  transform: translateY(-1px);
}
.auth-btn-google:disabled { opacity: 0.5; cursor: not-allowed; }

/* "or sign in with email" divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 24px 0 22px;
  color: #8A8A86;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(27,27,26,0.1);
}

/* Footer link */
.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 0.92rem;
  color: #6A6A66;
}
.auth-footer a {
  color: var(--brand-red);
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.auth-footer a svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Back to home */
.auth-back {
  text-align: center;
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid rgba(27,27,26,0.06);
}
.auth-back a {
  color: #8A8A86;
  font-size: 0.86rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}
.auth-back a:hover { color: var(--brand-red); }
.auth-back a svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Success/Error states */
.auth-success {
  background: var(--warm-sand);
  border-left: 4px solid var(--brand-red);
  padding: 18px 22px;
  border-radius: 8px;
  margin-bottom: 22px;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.55;
  display: none;
}
.auth-success.visible { display: flex; gap: 14px; align-items: flex-start; }
.auth-success svg {
  width: 22px;
  height: 22px;
  stroke: var(--brand-red);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  margin-top: 1px;
}
.auth-success strong {
  display: block;
  margin-bottom: 4px;
  font-family: 'Fraunces', serif;
  font-size: 1rem;
  color: var(--brand-red);
  font-weight: 600;
}

.auth-error {
  background: #FEF2F2;
  border-left: 4px solid #DC2626;
  padding: 16px 20px;
  border-radius: 8px;
  margin-bottom: 22px;
  color: #991B1B;
  font-size: 0.9rem;
  line-height: 1.55;
  display: none;
}
.auth-error.visible { display: block; }
.auth-error strong { display: block; margin-bottom: 4px; font-family: 'Fraunces', serif; }
.auth-error a {
  color: var(--brand-red);
  font-weight: 700;
}

/* Password strength bar */
.auth-strength {
  height: 4px;
  border-radius: 2px;
  background: rgba(27,27,26,0.08);
  margin-top: 8px;
  overflow: hidden;
  position: relative;
}
.auth-strength-bar {
  height: 100%;
  width: 0%;
  transition: all 0.25s;
  background: #DC2626;
  border-radius: 2px;
}
.auth-strength-bar[data-strength="1"] { width: 25%; background: #DC2626; }
.auth-strength-bar[data-strength="2"] { width: 50%; background: #F59E0B; }
.auth-strength-bar[data-strength="3"] { width: 75%; background: #84CC16; }
.auth-strength-bar[data-strength="4"] { width: 100%; background: #16A34A; }
.auth-strength-label {
  font-size: 0.74rem;
  color: #6A6A66;
  margin-top: 6px;
  display: block;
}

.auth-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 8px 0 20px;
  font-size: 0.86rem;
  color: #6A6A66;
  line-height: 1.5;
}
.auth-checkbox-row input[type="checkbox"] {
  margin-top: 3px;
  accent-color: var(--brand-red);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.auth-checkbox-row a {
  color: var(--brand-red);
  font-weight: 600;
  text-decoration: none;
}

.auth-hidden { display: none !important; }
