:root {
  color-scheme: light;
  --auth-ink: #132033;
  --auth-muted: #667085;
  --auth-line: #dce3ed;
  --auth-accent: #3f58e8;
  --auth-accent-dark: #293db6;
  --auth-error: #b42318;
  --auth-surface: #ffffff;
  --auth-background: #f3f6fb;
}

* {
  box-sizing: border-box;
}

.auth-page {
  min-height: 100vh;
  margin: 0;
  background: var(--auth-background);
  color: var(--auth-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.auth-shell {
  width: min(100% - 2rem, 30rem);
  margin: 0 auto;
  padding: 8vh 0 3rem;
}

.auth-brand {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: var(--auth-ink);
  text-decoration: none;
}

.auth-brand svg {
  display: block;
  width: 12.2rem;
  max-width: 70%;
  height: auto;
}

.auth-card {
  padding: clamp(1.5rem, 5vw, 2.5rem);
  border: 1px solid var(--auth-line);
  border-radius: 0.5rem;
  background: var(--auth-surface);
  box-shadow: 0 1.5rem 4rem rgba(30, 42, 68, 0.1);
}

.auth-card h1 {
  margin: 0 0 0.5rem;
  font-size: 1.8rem;
}

.auth-intro {
  margin: 0 0 1.75rem;
  color: var(--auth-muted);
  line-height: 1.55;
}

.auth-field {
  display: grid;
  gap: 0.45rem;
  margin-top: 1rem;
  font-weight: 700;
}

.auth-field input {
  width: 100%;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--auth-line);
  border-radius: 0.4rem;
  color: var(--auth-ink);
  font: inherit;
}

.auth-field input:focus {
  border-color: var(--auth-accent);
  outline: 3px solid rgba(63, 88, 232, 0.15);
}

.auth-check {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.65rem;
  align-items: start;
  margin-top: 1.15rem;
  color: var(--auth-muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.auth-check input {
  width: 1rem;
  height: 1rem;
  margin-top: 0.1rem;
}

.auth-submit {
  width: 100%;
  margin-top: 1.5rem;
  padding: 0.85rem 1rem;
  border: 0;
  border-radius: 0.4rem;
  background: var(--auth-accent);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.auth-submit:hover {
  background: var(--auth-accent-dark);
}

.auth-error {
  margin: 1rem 0;
  padding: 0.75rem;
  border-radius: 0.4rem;
  background: #fef3f2;
  color: var(--auth-error);
}

.auth-qr {
  display: block;
  width: min(15rem, 100%);
  height: auto;
  margin: 1.25rem auto;
}

.auth-secret,
.auth-recovery-codes {
  padding: 1rem;
  border-radius: 0.4rem;
  background: var(--auth-background);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  overflow-wrap: anywhere;
}

.auth-recovery-codes {
  columns: 2;
  line-height: 2;
}

.auth-language {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.25rem;
}

.auth-language a {
  color: var(--auth-muted);
  font-size: 0.85rem;
  font-weight: 700;
}

.auth-secondary-link {
  display: block;
  margin-top: 1rem;
  color: var(--auth-accent-dark);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
}

.auth-notice {
  margin: 0 0 1rem;
  padding: 0.8rem;
  border: 1px solid #a9d7c0;
  border-radius: 0.4rem;
  background: #effaf4;
  color: #17633b;
  line-height: 1.5;
}
