/* Cohort — auth pages: "the cover sheet".
   Admin login uses the centred .auth-shell; the trainee login + sign-up use
   the two-panel .auth-layout — an ink brand statement on the left (flat ink,
   top spotlight, faint engineering grid: the marketing ink-section signature)
   and a calm paper document panel carrying one white record-card.
   Foundation layer (styles.css, body:not(.mk)) supplies type roles, fields,
   buttons and focus rings; this sheet adds the auth-specific surfaces only. */

/* ─── Centred shell (admin login) ─────────────────────────────── */
.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem 1.5rem;
  background: var(--app-ground);
}

/* ─── Two-panel layout (trainee login + sign-up) ──────────────── */
.auth-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
}
.auth-main {
  display: grid;
  place-items: center;
  padding: 2.5rem 1.5rem;
  background: var(--app-ground);
}

/* ─── Brand panel: flat ink + spotlight + engineering grid ────── */
.auth-brand {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(2.5rem, 4vw, 4rem);
  background: var(--clr-ink);
  color: var(--clr-white);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.auth-brand > * { position: relative; z-index: 1; }
.auth-brand::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(110% 45% at 50% -8%, rgba(0, 106, 175, 0.22), transparent 62%);
}
.auth-brand::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask: radial-gradient(120% 90% at 30% 8%, #000 25%, transparent 78%);
          mask: radial-gradient(120% 90% at 30% 8%, #000 25%, transparent 78%);
}

.auth-brand .logo__brand { color: var(--clr-white); }
.auth-brand .logo__sub { font-size: 0.68rem; color: var(--app-st-blue); }
body:not(.mk) .auth-brand :focus-visible { outline-color: #8FD0FF; } /* legible on ink */

/* Mono eyebrow above the statement (the .mk-eyebrow signature) */
.auth-brand__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--ff-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--app-st-blue);
  margin: 0 0 1.1rem;
}
.auth-brand__eyebrow::before {
  content: "";
  width: 1.6rem;
  height: 1px;
  background: currentColor;
  opacity: 0.55;
  flex-shrink: 0;
}

.auth-brand__headline {
  color: var(--clr-white);
  font-family: var(--ff-display);
  font-weight: 800;
  font-size: clamp(2rem, 3.2vw, 2.9rem);
  line-height: 1.06;
  letter-spacing: -0.025em;
  max-width: 15ch;
  margin: 0 0 1.1rem;
}
/* Lit status accent — solid, no gradient text */
.auth-brand__accent { color: var(--app-st-blue); }

.auth-brand__lede {
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.02rem;
  line-height: 1.6;
  max-width: 42ch;
  margin: 0 0 2rem;
}

/* Record-facts (the .mk-hero__facts pattern): mono, square green dots */
.auth-brand__points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
  font-family: var(--ff-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.66);
}
.auth-brand__points li {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}
.auth-brand__points li::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 1.5px;
  background: var(--app-st-green);
  flex-shrink: 0;
}

/* Panel footer: hairline-topped mono record line */
.auth-brand__foot {
  margin: 0;
  padding-top: 1.1rem;
  border-top: 1px solid var(--app-chrome-line);
  font-family: var(--ff-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

@media (max-width: 860px) {
  .auth-layout { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
}

/* ─── The record-card ─────────────────────────────────────────── */
.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--app-card);
  border: 1px solid var(--app-hair);
  border-radius: var(--app-r-card);
  box-shadow: var(--app-shadow-1);
  padding: 2.5rem 2.25rem 2rem;
}

.auth-card .logo { margin-bottom: 1.75rem; }
.auth-card .logo__mark { width: 2.4rem; height: 2.4rem; }
/* The brand panel already carries the wordmark on wide screens —
   the card reads as a clean document; the logo returns on mobile. */
@media (min-width: 861px) {
  .auth-layout .auth-card > .logo { display: none; }
}

/* Own line even after the inline-flex logo (beats the foundation's
   body:not(.mk) .app-eyebrow inline-flex on specificity). */
body:not(.mk) .auth-card .app-eyebrow {
  display: flex;
  margin-bottom: 0.85rem;
}
.auth-card h1 {
  font-size: 1.6rem;
  line-height: 1.15;
  margin-bottom: 0.5rem;
  color: var(--clr-dark-blue-text);
}
.auth-card .lede {
  color: var(--app-text-dim);
  font-size: 0.95rem;
  line-height: 1.55;
  margin: 0 0 1.6rem;
}

/* Two-field row (e.g. first name / last name) — stacks on narrow screens. */
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
}
@media (max-width: 460px) { .field-row { grid-template-columns: 1fr; gap: 0; } }

.field { margin-bottom: 1.1rem; }
.field label { margin-bottom: 0.4rem; }
.field-hint {
  display: block;
  font-size: 0.8rem;
  font-weight: var(--fw-regular);
  color: rgba(0, 39, 64, 0.55);
  margin-top: 0.3rem;
}
.field input, .field select, .field textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  padding: 0.7rem 0.9rem;
  color: var(--clr-dark-blue-text);
  transition: border-color var(--app-dur-fast) var(--app-ease-out),
              box-shadow var(--app-dur-fast) var(--app-ease-out);
}

.btn--block { width: 100%; }

/* ─── Alerts: quiet record notes, semantic rail ───────────────── */
.alert {
  padding: 0.7rem 0.9rem;
  font-size: 0.93rem;
  margin-bottom: 1rem;
  border: 1px solid;
}
.alert--error {
  background: rgba(212, 43, 42, 0.06);
  border-color: rgba(212, 43, 42, 0.3);
  color: var(--clr-red);
}
.alert--info {
  background: var(--clr-bg-light-blue);
  border-color: rgba(0, 106, 175, 0.25);
  color: var(--clr-dark-blue);
}
.alert--success {
  background: var(--clr-green-soft);
  border-color: rgba(10, 122, 63, 0.35);
  color: var(--clr-green);
}

.auth-foot {
  margin-top: 1.25rem;
  font-size: 0.88rem;
  color: rgba(0, 39, 64, 0.6);
  text-align: center;
}
.auth-foot a { font-weight: var(--fw-semi-bold); }

/* Card footer: hairline-topped mono session stamp */
.auth-card__stamp {
  margin: 1.75rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid var(--app-hair);
  font-family: var(--ff-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  color: rgba(0, 39, 64, 0.55);
}
