/* === Auth Page === */

.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 4vw, 2rem);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.24), transparent 24rem),
    radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.14), transparent 22rem),
    linear-gradient(135deg, var(--swish-green), var(--swish-green-dark));
}

.auth-card {
  width: 100%;
  max-width: 460px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, #ffffff, #fbfefb);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius-xl);
  padding: clamp(1.5rem, 4vw, 2.1rem);
  box-shadow: var(--shadow-strong);
}

.auth-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 5px;
  background: linear-gradient(90deg, var(--swish-green), #28c76f, var(--swish-green-dark));
}

.auth-card .brand {
  margin-bottom: 2rem;
}

.brand h1 {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--swish-green);
  line-height: 1.18;
  letter-spacing: -0.045em;
}

.brand p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* === Tabs === */

.tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.45rem;
  margin-bottom: 1.5rem;
  padding: 0.35rem;
  background: var(--swish-green-soft-2);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
}

.tab {
  min-height: 42px;
  border: none;
  background: transparent;
  color: #334033;
  padding: 0.72rem 0.7rem;
  border-radius: 11px;
  font-weight: 900;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.12s ease;
}

.tab:hover {
  color: var(--swish-green);
  background: #ffffff;
}

.tab.active {
  background: var(--swish-green);
  color: #ffffff;
  box-shadow: 0 10px 22px rgba(1, 162, 0, 0.18);
}

/* === Auth Forms === */

.form {
  display: none;
}

.form.active {
  display: block;
}

.form h2 {
  font-size: 1.38rem;
  color: var(--text-strong);
  margin-bottom: 1rem;
  letter-spacing: -0.035em;
  line-height: 1.25;
}

.form label:first-of-type {
  margin-top: 0;
}

.form-helper,
.password-helper {
  margin: -0.35rem 0 1rem;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.password-helper {
  margin: 0.5rem 0 0.7rem;
}

.password-rules {
  display: grid;
  gap: 0.42rem;
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
}

.password-rules li {
  position: relative;
  padding-left: 1.45rem;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.4;
}

.password-rules li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.4rem;
  width: 0.58rem;
  height: 0.58rem;
  border-radius: 999px;
  background: #d7ded7;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.password-rules li.valid {
  color: var(--swish-green-dark);
  font-weight: 750;
}

.password-rules li.valid::before {
  background: var(--swish-green);
}

.password-rules li.invalid {
  color: #9f1d1d;
}

.password-rules li.invalid::before {
  background: #e05252;
}

.auth-card .message {
  text-align: center;
}

/* === Auth Links === */

.auth-card a,
.reset-footer a {
  color: var(--swish-green);
  font-weight: 850;
  text-decoration: none;
}

.auth-card a:hover,
.reset-footer a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* === Responsive === */

@media (max-width: 700px) {
  .auth-page {
    padding: 1rem;
  }

  .auth-card {
    border-radius: var(--radius-lg);
  }

  .tabs {
    gap: 0.3rem;
  }

  .tab {
    padding-inline: 0.45rem;
    font-size: 0.9rem;
  }
}