/* Ledger direction: warm paper, navy ink, a serif heading. Keeps the AKCS logo as the only mark. */
:root {
  --paper: #f5f0e6;
  --sheet: #fffdf8;
  --rule: #d9cfbd;
  --ink: #1b2a41;
  --muted: #4d5a6b;
  --field: #8c9bb0;
  --focus: #2f6fa8;
  --error: #9b1c1c;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: "Avenir Next", "Gill Sans", "Segoe UI", sans-serif;
  display: grid;
  place-items: center;
  padding: 16px;
}

.sheet {
  width: 100%;
  max-width: 380px;
  background: var(--sheet);
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 36px 32px 32px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(27, 42, 65, 0.06);
}

.mark {
  display: block;
  margin: 0 auto 16px;
  border-radius: 8px;
}

h1 {
  font-family: "Newsreader", Georgia, serif;
  font-weight: 600;
  font-size: 1.75rem;
  line-height: 1.2;
  margin: 0 0 8px;
}

.lede {
  color: var(--muted);
  margin: 0 0 24px;
  font-size: 0.95rem;
}

button {
  font: inherit;
  font-weight: 600;
  width: 100%;
  min-height: 48px;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
}

button:disabled { opacity: 0.6; cursor: wait; }

button:focus-visible,
input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

button.primary {
  background: #1b2a41;
  color: #ffffff;
  margin-top: 8px;
}
button.primary:hover:not(:disabled) { background: #101b2d; }

button.google {
  background: #ffffff;
  color: var(--ink);
  border-color: var(--field);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
button.google:hover:not(:disabled) { background: #f3f6fa; }

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 18px;
  color: var(--muted);
  font-size: 0.85rem;
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--rule);
}

.stack { display: grid; gap: 14px; text-align: left; }

label { display: grid; gap: 6px; font-size: 0.9rem; color: var(--ink); font-weight: 600; }

input {
  font: inherit;
  font-weight: 400;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--field);
  border-radius: 6px;
  background: #ffffff;
  color: var(--ink);
  width: 100%;
}

.error {
  color: var(--error);
  font-size: 0.9rem;
  min-height: 1.2em;
  margin: 14px 0 0;
}

.loader {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 36px;
  height: 36px;
  margin: -18px 0 0 -18px;
  border: 4px solid var(--rule);
  border-top-color: var(--ink);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .loader { animation-duration: 2.4s; }
}

@media (max-width: 420px) {
  .sheet { padding: 28px 22px 24px; }
}
