:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --text: #1d2330;
  --muted: #5b6475;
  --accent: #1f4e8c;
  --accent-text: #ffffff;
  --ok: #1b7a3d;
  --error: #b42318;
  --border: #dfe3ea;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12151b;
    --card: #1b2029;
    --text: #e8ebf1;
    --muted: #a3acbd;
    --accent: #6ea3e8;
    --accent-text: #0d1117;
    --ok: #5fcf86;
    --error: #ff8a80;
    --border: #2c3341;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

main {
  width: 100%;
  max-width: 440px;
  padding: 32px 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-align: center;
}

.brand { margin: 0 0 24px; font-size: 1.5rem; font-weight: 700; letter-spacing: 0.02em; }
h1 { margin: 0 0 8px; font-size: 1.25rem; }
p { margin: 0 0 16px; color: var(--muted); }
.status-ok h1 { color: var(--ok); }
.status-error h1 { color: var(--error); }

.button {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-text);
  font-weight: 600;
  text-decoration: none;
}

.button[hidden] { display: none; }

.spinner {
  width: 28px;
  height: 28px;
  margin: 0 auto 16px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

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

@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
