/* The sign-in page (`templates/login.html`). Standalone: loaded after
   `datum.css` with no `shell.css` in front of it, so nothing here may assume
   a shell primitive exists.

   ONE CARD ON THE CANVAS, Datum pattern 9, geometry from mockups v3/v5:
   a 380px card, a wordmark head, a padded body, a banded footer line.
   The code entry is Datum pattern 15 as vendored (`.dt-code-entry`,
   `.dt-code-box`); this file adds nothing to it.

   COLOUR IS ROLES ONLY (KICKOFF C3): every value below is a `var(--dt-*)`
   or a `color-mix` of two of them, so `[data-theme="dark"]` in datum.css
   carries the whole page with no rule of its own here. */

.login-body {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  background: var(--dt-canvas);
}

.login-wrap {
  width: 100%;
  max-width: 380px;
}

.login-card {
  width: 100%;
}

.login-head {
  padding: 18px 22px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* The wordmark, as the shell header sets it. */
.login-wordmark {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--dt-ink-strong);
  white-space: nowrap;
}

.login-head .brand-mark {
  height: 14px;
  width: auto;
  display: block;
  flex: none;
  color: var(--dt-ink-strong);
}

.login-step {
  padding: 10px 22px 20px;
}

.login-step h1 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 6px 0 2px;
  color: var(--dt-ink-strong);
}

/* Full-width controls inside the card, as the mockup draws them. The code
   boxes are excluded: pattern 15 sizes them itself and they must shrink,
   not stretch. */
.login-step .dt-input:not(.dt-code-box) {
  width: 100%;
  height: 36px;
}
.login-full {
  width: 100%;
  height: 36px;
  justify-content: center;
}
.login-full.dt-btn--lg {
  height: 40px;
}
.login-send {
  margin-top: 10px;
}
.login-icon {
  width: 14px;
  height: 14px;
  flex: none;
}
.login-error {
  margin: 6px 0 0;
}

/* "or use a one-time code": a label between two hairlines. */
.login-or {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 12px;
  font-size: 12px;
  color: var(--dt-ink-muted);
}
.login-or::before,
.login-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--dt-divider);
}

/* Back on the left, the resend timer on the right. */
.login-code-acts {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.login-hint {
  margin: 12px 0 0;
}

/* The quiet state while the silent refresh is in flight. Reserves roughly
   the height of the sign-in step so the card does not jump when the form
   replaces it. */
.login-checking {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 180px;
  font-size: 13px;
  color: var(--dt-ink-muted);
}

.login-foot {
  padding: 12px 22px;
  border-top: 1px solid var(--dt-divider);
  font-size: 12px;
  line-height: 1.45;
  color: var(--dt-ink-muted);
  background: color-mix(in srgb, var(--dt-canvas) 55%, var(--dt-surface));
}
