/* Served outside the SPA bundle, so it cannot import tokens.css. Colours mirror --hatch-bg,
   --hatch-text-strong, --hatch-muted and --hatch-accent there; spacing stays on its 4px scale.
   theme-boot.js sets data-theme before this stylesheet paints. */
:root {
  color-scheme: dark;
  --login-bg: #181818;
  --login-heading: #ffffff;
  --login-muted: #909090;
  --login-action-bg: #ffffff;
  --login-action-hover: #e6e6e6;
  --login-action-text: #181818;
  --login-focus: #339cff;
}

:root[data-theme="light"] {
  color-scheme: light;
  --login-bg: #ffffff;
  --login-heading: #000000;
  --login-muted: #5c5c5c;
  --login-action-bg: #1f1f1f;
  --login-action-hover: #303030;
  --login-action-text: #ffffff;
  --login-focus: #0860c9;
}

* { box-sizing: border-box; }

html, body { height: 100%; margin: 0; }

body {
  display: grid;
  place-items: center;
  padding: 24px;
  background: var(--login-bg);
  color: var(--login-muted);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.5;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.login {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 400px;
  /* Optical centring: the mark's whitespace makes a true centre read low. */
  margin-bottom: 8vh;
  text-align: center;
}

.login-mark {
  width: 56px;
  height: 64px;
  margin-bottom: 24px;
  color: var(--login-heading);
}

.login h1 {
  margin: 0 0 8px;
  color: var(--login-heading);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -.01em;
  line-height: 1.25;
}

.login p {
  margin: 0;
  font-size: 16px;
  text-wrap: balance;
}

.login-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 280px;
  height: 44px;
  margin-top: 32px;
  padding: 0 24px;
  border-radius: 22px;
  background: var(--login-action-bg);
  color: var(--login-action-text);
  font-size: 14px;
  font-weight: 550;
  text-decoration: none;
  transition: background-color .15s;
}

.login-action:hover { background: var(--login-action-hover); }

.login-action:focus-visible {
  outline: 2px solid var(--login-focus);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .login-action { transition: none; }
}
