.auth-page {
  min-height: 100vh;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto 1fr auto;
}
.auth-shell {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
  padding: 72px 0;
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 70px;
  align-items: center;
}
.auth-brand h1 {
  font-size: clamp(42px, 5vw, 64px);
  line-height: 1.05;
  margin-bottom: 18px;
  background: linear-gradient(135deg, #fff 25%, var(--mf-accent-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 26px rgba(255, 43, 91, 0.22));
}
.auth-brand p { color: var(--mf-text-muted); line-height: 1.7; max-width: 520px; }
.auth-kicker { color: var(--mf-accent); font-weight: 800; font-size: 12px; letter-spacing: 1.6px; text-transform: uppercase; margin-bottom: 14px; }
.auth-card {
  background: rgba(18, 11, 15, 0.88);
  border: 1px solid rgba(255, 43, 91, 0.28);
  border-radius: 22px;
  padding: 32px;
  box-shadow: 0 24px 70px rgba(0,0,0,.55), 0 0 44px rgba(255,43,91,.13);
  backdrop-filter: blur(22px);
}
.auth-card h2 { font-size: 25px; margin-bottom: 7px; }
.auth-card-subtitle { color: #858599; font-size: 13.5px; margin-bottom: 26px; }
.auth-field { margin-bottom: 17px; }
.auth-field label { display: block; font-size: 12.5px; color: #aaaabc; margin-bottom: 8px; font-weight: 600; }
.auth-input {
  width: 100%;
  padding: 13px 14px;
  border-radius: 11px;
  border: 1px solid rgba(255,43,91,.18);
  background: rgba(255,255,255,.035);
  color: #fff;
  outline: none;
  font-size: 14px;
  transition: .25s ease;
  user-select: text;
}
.auth-input:focus { border-color: var(--mf-accent); box-shadow: 0 0 0 3px rgba(255,43,91,.08), 0 0 18px rgba(255,43,91,.13); }
.auth-submit { width: 100%; justify-content: center; margin-top: 8px; }
.auth-submit:disabled { opacity: .55; cursor: wait; transform: none; }
.auth-switch { text-align: center; color: #77778b; font-size: 13px; margin-top: 20px; }
.auth-switch a { color: var(--mf-accent-light); text-decoration: none; font-weight: 700; }
.auth-message { display: none; padding: 11px 13px; border-radius: 10px; font-size: 12.5px; line-height: 1.45; margin-bottom: 16px; }
.auth-message.show { display: block; }
.auth-message.error { background: rgba(255,52,80,.08); border: 1px solid rgba(255,52,80,.3); color: #ff8296; }
.auth-message.success { background: rgba(0,255,136,.07); border: 1px solid rgba(0,255,136,.25); color: #71ffc0; }
.auth-message.info { background: rgba(255,43,91,.06); border: 1px solid rgba(255,43,91,.2); color: #ffc0ce; }
.auth-back { color: #8e8e9f; text-decoration: none; font-size: 13px; display: inline-flex; gap: 8px; align-items: center; margin-top: 24px; }
.auth-back:hover { color: #fff; }
.password-hint { font-size: 11px; color: #68687a; margin-top: 7px; }
@media (max-width: 850px) {
  .auth-shell { grid-template-columns: 1fr; gap: 34px; padding: 45px 0; }
  .auth-brand { text-align: center; }
  .auth-brand p { margin: 0 auto; }
  .auth-card { max-width: 520px; width: 100%; margin: 0 auto; }
}


/* Password visibility + recovery controls */
.auth-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 8px;
}
.auth-label-row label {
  margin-bottom: 0;
}
.auth-link-button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--mf-accent-light);
  font: inherit;
  font-size: 11.5px;
  font-weight: 700;
  padding: 0;
  cursor: pointer;
  transition: color .2s ease, opacity .2s ease;
}
.auth-link-button:hover { color: #fff; }
.auth-link-button:disabled { opacity: .55; cursor: wait; }

.password-input-wrap {
  position: relative;
}
.password-input-wrap .auth-input {
  padding-right: 48px;
}
.password-toggle {
  position: absolute;
  top: 50%;
  right: 9px;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #737386;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: color .2s ease, background .2s ease, box-shadow .2s ease;
}
.password-toggle:hover {
  color: #fff;
  background: rgba(255, 43, 91, .08);
}
.password-toggle.is-visible {
  color: var(--mf-accent-light);
  background: rgba(255, 43, 91, .08);
  box-shadow: 0 0 16px rgba(255, 43, 91, .10);
}
.password-eye {
  font-size: 16px;
  line-height: 1;
}

/* Enhanced reset password experience */
.auth-brand-reset {
  position: relative;
}

.reset-feature-list {
  margin-top: 28px;
  display: grid;
  gap: 14px;
  max-width: 520px;
}

.reset-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 43, 91, 0.14);
  background: rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.02);
}

.reset-feature-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--mf-accent), var(--mf-accent-light));
  box-shadow: 0 0 16px rgba(255, 43, 91, 0.5);
  margin-top: 7px;
  flex: 0 0 auto;
}

.reset-feature-item strong {
  display: block;
  margin-bottom: 4px;
  color: #ffffff;
  font-size: 14px;
}

.reset-feature-item p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #8f90a3;
}

.auth-card-reset {
  position: relative;
  overflow: hidden;
}

.auth-card-reset::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(255,43,91,0), rgba(255,43,91,0.65), rgba(255,43,91,0));
  opacity: 0.9;
}

.reset-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.reset-card-logo-wrap {
  position: relative;
  width: 62px;
  height: 62px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,0.035);
  border: 1px solid rgba(255, 43, 91, 0.22);
  overflow: hidden;
}

.reset-card-logo-glow {
  position: absolute;
  inset: 8px;
  border-radius: 14px;
  background: radial-gradient(circle, rgba(255,43,91,0.24) 0%, rgba(255,43,91,0.04) 58%, transparent 100%);
  filter: blur(4px);
}

.reset-card-logo {
  position: relative;
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.reset-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 43, 91, 0.08);
  border: 1px solid rgba(255, 43, 91, 0.22);
  color: #ffd2dd;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.password-checklist {
  margin-top: 10px;
  margin-bottom: 10px;
  display: grid;
  gap: 10px;
}

.password-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: #7f8093;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,0.025);
  border: 1px solid rgba(255,255,255,0.05);
  transition: .2s ease;
}

.password-check-item.is-valid {
  color: #96ffd0;
  border-color: rgba(0,255,136,.24);
  background: rgba(0,255,136,.06);
}

.password-check-icon {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: rgba(255,255,255,0.08);
  color: currentColor;
  font-weight: 700;
  line-height: 1;
}

.password-check-item.is-valid .password-check-icon {
  background: rgba(0,255,136,.12);
}

@media (max-width: 850px) {
  .reset-feature-list {
    max-width: 100%;
  }

  .reset-card-top {
    align-items: flex-start;
  }
}

/* Animated password reset email success state */
.is-hidden-for-reset {
  display: none !important;
}

.reset-success-state {
  display: none;
  text-align: center;
  padding: 6px 0 2px;
}

.reset-success-state.show {
  display: block;
  animation: resetSuccessIn .48s cubic-bezier(.2,.8,.2,1) both;
}

.reset-success-icon-wrap {
  width: 88px;
  height: 88px;
  margin: 4px auto 20px;
  position: relative;
  display: grid;
  place-items: center;
}

.reset-success-ring {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 1px solid rgba(255, 43, 91, .42);
  background: radial-gradient(circle, rgba(255,43,91,.14) 0%, rgba(255,43,91,.04) 58%, transparent 72%);
  box-shadow: 0 0 34px rgba(255,43,91,.18);
  animation: resetRingPulse 2.2s ease-in-out infinite;
}

.reset-success-check {
  width: 52px;
  height: 52px;
  position: relative;
  overflow: visible;
}

.reset-success-check path {
  fill: none;
  stroke: #ff4d78;
  stroke-width: 4.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 44;
  stroke-dashoffset: 44;
  filter: drop-shadow(0 0 7px rgba(255,43,91,.5));
  animation: resetCheckDraw .55s .18s cubic-bezier(.2,.8,.2,1) forwards;
}

.reset-success-kicker {
  color: var(--mf-accent-light);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  margin-bottom: 9px;
}

.reset-success-state h3 {
  margin: 0 0 10px;
  font-size: 26px;
  color: #fff;
}

.reset-success-state > p {
  margin: 0 auto;
  max-width: 360px;
  color: #8f90a3;
  font-size: 13.5px;
  line-height: 1.65;
}

.reset-success-email {
  display: inline-flex;
  max-width: 100%;
  margin: 15px auto 13px;
  padding: 9px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255,43,91,.18);
  background: rgba(255,43,91,.055);
  color: #ffc6d4;
  font-size: 12px;
  font-weight: 700;
  word-break: break-all;
}

.reset-success-state .reset-success-note {
  color: #6f7082;
  font-size: 11.5px;
  line-height: 1.55;
}

.reset-success-actions {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.reset-success-primary {
  width: 100%;
  justify-content: center;
}

.reset-resend-button {
  width: 100%;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.025);
  color: #aaaabc;
  border-radius: 11px;
  padding: 12px 14px;
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: .2s ease;
}

.reset-resend-button:hover:not(:disabled) {
  color: #fff;
  border-color: rgba(255,43,91,.22);
  background: rgba(255,43,91,.06);
}

.reset-resend-button:disabled {
  opacity: .48;
  cursor: wait;
}

@keyframes resetSuccessIn {
  from { opacity: 0; transform: translateY(12px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes resetCheckDraw {
  to { stroke-dashoffset: 0; }
}

@keyframes resetRingPulse {
  0%,100% { transform: scale(1); opacity: .92; }
  50% { transform: scale(1.06); opacity: .68; }
}

@media (prefers-reduced-motion: reduce) {
  .reset-success-state.show,
  .reset-success-ring,
  .reset-success-check path {
    animation: none !important;
  }
  .reset-success-check path { stroke-dashoffset: 0; }
}
