/* Sign-in page for the Academy. Same brand as academy.css (Bone ground, Paper card, Ink outline, one blue),
   kept in its own file because this is the only stylesheet served before sign-in. */
:root {
  --bone: #F5F3EF;
  --paper: #FDFDFC;
  --fog: #E9E7E2;
  --stone: #C9C6BF;
  --ink: #141416;
  --muted: #6B6963;
  --blue: #007AFF;
  --err: #B3261E;
  --grid: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32'%3E%3Cpath d='M31.5 0V32M0 31.5H32' stroke='%23E9E7E2' stroke-width='1' fill='none'/%3E%3C/svg%3E");
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  display: grid; place-items: center; padding: 24px 16px;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px; line-height: 1.5; color: var(--ink);
  background: var(--bone) var(--grid);
}
h1, p { margin: 0; }

.gate { width: 100%; max-width: 420px; }
.card {
  background: var(--paper); border: 2px solid var(--ink); border-radius: 16px;
  box-shadow: 8px 8px 0 var(--ink); padding: 32px 28px 28px;
}
.mark { display: block; width: 44px; height: 44px; margin-bottom: 18px; }
h1 {
  font-weight: 900; text-transform: uppercase; letter-spacing: -0.04em; line-height: 0.95;
  font-size: clamp(34px, 9vw, 44px); margin-bottom: 26px;
}
.hl { color: var(--blue); }

label { display: block; font-size: 14px; font-weight: 700; margin: 0 0 6px; }
input {
  display: block; width: 100%; margin: 0 0 18px; padding: 13px 14px;
  font: inherit; font-size: 16px; /* 16px stops iOS zooming on focus */ color: var(--ink);
  background: var(--paper); border: 2px solid var(--ink); border-radius: 12px;
}
input:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
input[aria-invalid="true"] { border-color: var(--err); }

.err { font-size: 14px; font-weight: 600; color: var(--err); margin: -4px 0 16px; }

.btn {
  display: flex; align-items: center; justify-content: center; width: 100%; text-decoration: none;
  font: inherit; font-weight: 800; font-size: 17px; letter-spacing: -0.01em; line-height: 1.25;
  color: #fff; background: var(--blue);
  border: 2px solid var(--ink); border-radius: 999px; padding: 14px 26px;
  box-shadow: 4px 4px 0 var(--ink); cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
.btn.alt { color: var(--ink); background: var(--paper); }
.or {
  display: flex; align-items: center; gap: 12px; margin: 22px 0 20px;
  font-size: 13px; font-weight: 600; color: var(--muted);
}
.or::before, .or::after { content: ""; flex: 1; height: 2px; background: var(--fog); }
.btn.alt:disabled, .btn:disabled { background: var(--fog); color: var(--muted); border-color: var(--stone); box-shadow: none; cursor: progress; transform: none; }

@media (max-width: 420px) {
  .card { padding: 26px 20px 22px; box-shadow: 5px 5px 0 var(--ink); }
}
@media (prefers-reduced-motion: reduce) {
  .btn { transition: none; }
}
