/* ===========================================================
   DXB PRO — sign in / create account
   =========================================================== */

.auth {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 40px 20px;
}

.stack { width: 100%; max-width: 400px; }

/* The wordmark is white — it sits on the navy page, above the card */
.mark {
  display: flex;
  justify-content: center;
  margin-bottom: 18px;
}

.mark img {
  display: block;
  width: 148px;
  height: auto;
}

.auth__intro { margin: 0 auto 22px; text-align: center; }
.auth__intro h1 { margin: 0; font-size: 22px; font-weight: 600; letter-spacing: -.025em; }
.auth__intro p { margin: 5px 0 0; font-size: 13.5px; color: var(--text-soft); }

.text-button { padding: 0; font: inherit; background: none; border: 0; cursor: pointer; }

.card {
  padding: 30px 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
}

/* ── Segmented switch ──────────────────────────────────── */

.switch {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 4px;
  margin-bottom: 26px;
  background: rgba(255,255,255,.05);
  border-radius: 999px;
}

.switch__pill {
  position: absolute;
  top: 4px;
  left: 4px;
  width: calc(50% - 4px);
  height: calc(100% - 8px);
  background: var(--nav-800);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  transition: transform .28s var(--ease);
}

.switch.is-signup .switch__pill { transform: translateX(100%); }

.switch__btn {
  position: relative;
  z-index: 1;
  border: 0;
  background: none;
  padding: 9px 0;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-mute);
  cursor: pointer;
  transition: color .2s var(--ease);
}

.switch__btn.is-active { color: var(--text); }

/* ── Forms ─────────────────────────────────────────────── */

.form { display: none; }
.form.is-active { display: block; }

.reveal {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 0;
  background: none;
  border-radius: 8px;
  color: var(--text-mute);
  cursor: pointer;
  transition: color .18s var(--ease), background .18s var(--ease);
}

.reveal:hover { color: var(--text); background: rgba(255,255,255,.07); }
.reveal.is-on  { color: var(--gold-500); }

/* ── Strength meter ────────────────────────────────────── */

.meter {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  margin-top: 9px;
}

.meter i {
  height: 3px;
  border-radius: 2px;
  background: rgba(255,255,255,.12);
  transition: background .25s var(--ease);
}

.meter i.on-1 { background: var(--danger); }
.meter i.on-2 { background: var(--warning); }
.meter i.on-3 { background: var(--gold-500); }
.meter i.on-4 { background: var(--success); }

.meter__label {
  margin: 7px 0 0;
  font-size: 12.5px;
  color: var(--text-mute);
}

/* ── Checkbox ──────────────────────────────────────────── */

.check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 4px 0 20px;
  font-size: 13.5px;
  color: var(--text-soft);
  cursor: pointer;
  user-select: none;
}

.check input { position: absolute; opacity: 0; width: 0; height: 0; }

.check__box {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: rgba(255,255,255,.05);
  transition: .18s var(--ease);
}

.check input:checked + .check__box {
  background: var(--gold-500);
  border-color: var(--gold-500);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2310192A' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 8.5l3 3 6-6'/%3E%3C/svg%3E");
  background-size: 14px;
  background-position: center;
  background-repeat: no-repeat;
}

.check input:focus-visible + .check__box {
  box-shadow: 0 0 0 3px rgba(238,186,43,.28);
}

/* ── Divider + fine print ──────────────────────────────── */

.btn--spaced { margin-top: 6px; }

.divider {
  position: relative;
  margin: 20px 0;
  text-align: center;
}

.divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line);
}

.divider span {
  position: relative;
  padding: 0 12px;
  background: var(--surface);
  font-size: 12.5px;
  color: var(--text-mute);
}

.fine {
  margin: 12px 0 0;
  text-align: center;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text-mute);
}

.foot {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 22px;
  font-size: 12.5px;
  color: var(--text-mute);
}

.foot a { text-decoration: none; }
.foot a:hover { color: var(--text); }

@media (max-width: 480px) {
  .auth { padding: 28px 16px; }
  .card { padding: 22px 18px; }
}

.form__err {
  margin: 0 0 14px;
  padding: 10px 13px;
  font-size: 13px;
  color: var(--danger);
  background: rgba(242,107,107,.1);
  border: 1px solid rgba(242,107,107,.3);
  border-radius: var(--radius);
}

.form__err[hidden] { display: none; }
