/* ==========================================================================
   Sign-in and registration.
   Loaded on top of app.css, which already provides the input and button
   primitives; only the page shell and the few auth-only pieces live here.
   ========================================================================== */

.auth-body {
  min-height: 100vh;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: linear-gradient(180deg, #f6f8fc 0%, #eef2f9 100%);
}

.auth-wrap {
  width: 100%;
  max-width: 424px;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: center;
  margin-block-end: 20px;
  font-size: 17px;
  font-weight: 700;
  color: var(--txt);
  text-decoration: none;
  letter-spacing: -.01em;
}

.auth-mark {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  box-shadow: 0 2px 6px rgba(37, 99, 235, .35);
}

.auth-card {
  padding: 30px 28px 26px;
  background: #fff;
  border: 1px solid #e3e9f2;
  border-radius: 16px;
  box-shadow: 0 12px 34px rgba(20, 34, 60, .09);
}

.auth-title {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--txt);
}

.auth-sub {
  margin: 0 0 20px;
  font-size: 14px;
  color: var(--txt-3);
}

.auth-form {
  display: grid;
  gap: 14px;
}

.fld { display: block; }

.fld-label {
  display: block;
  margin-block-end: 6px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--txt-2);
}

.chk {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--txt-2);
  cursor: pointer;
}
.chk input { width: 16px; height: 16px; accent-color: var(--brand); }

/* Google's button is deliberately not styled like ours: recognisability is the
   whole point of a third-party sign-in affordance. */
.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  padding: 11px 16px;
  font-size: 14.5px;
  font-weight: 600;
  color: #1f2328;
  text-decoration: none;
  background: #fff;
  border: 1px solid #cfd6e0;
  border-radius: 9px;
  transition: background-color .12s, border-color .12s, box-shadow .12s;
}
.btn-google:hover { background: #f7f9fc; border-color: #b9c3d1; }
.btn-google:focus-visible {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .15);
}
.g-mark { flex: 0 0 auto; }

.auth-or {
  position: relative;
  margin: 18px 0;
  text-align: center;
}
.auth-or::before {
  content: '';
  position: absolute;
  inset-block-start: 50%;
  inset-inline: 0;
  height: 1px;
  background: #e3e9f2;
}
.auth-or span {
  position: relative;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--txt-3);
  background: #fff;
}

.alert {
  margin-block-end: 16px;
  padding: 11px 13px;
  font-size: 13.5px;
  border-radius: 9px;
  border: 1px solid transparent;
}
.alert ul { margin: 0; padding-inline-start: 18px; }
.alert.is-bad  { color: #8a1c1c; background: #fdf1f1; border-color: #f5cfcf; }
.alert.is-good { color: #14532d; background: #f0fdf4; border-color: #bbf7d0; }

.auth-terms {
  margin: 2px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--txt-3);
}

.auth-benefits {
  margin: 22px 0 0;
  padding: 16px 0 0;
  list-style: none;
  border-top: 1px solid #eef1f6;
  display: grid;
  gap: 9px;
}
.auth-benefits li {
  position: relative;
  padding-inline-start: 24px;
  font-size: 13.5px;
  color: var(--txt-2);
}
/* Checkmark drawn with borders so there is no icon font and no extra request. */
.auth-benefits li::before {
  content: '';
  position: absolute;
  inset-inline-start: 3px;
  inset-block-start: 4px;
  width: 5px;
  height: 9px;
  border-right: 2px solid #16a34a;
  border-bottom: 2px solid #16a34a;
  transform: rotate(45deg);
}
[dir="rtl"] .auth-benefits li::before { transform: rotate(45deg) scaleX(-1); }

.auth-alt {
  margin: 18px 0 0;
  text-align: center;
  font-size: 13.5px;
  color: var(--txt-3);
}
.auth-alt a { color: var(--brand); font-weight: 600; text-decoration: none; }
.auth-alt a:hover { text-decoration: underline; }

.auth-foot {
  margin: 18px 0 0;
  text-align: center;
  font-size: 13px;
}
.auth-foot a { color: var(--txt-3); text-decoration: none; }
.auth-foot a:hover { color: var(--brand); text-decoration: underline; }

@media (max-width: 480px) {
  .auth-card { padding: 24px 18px 22px; border-radius: 14px; }
  .auth-title { font-size: 20px; }
}
