:root {
  color-scheme: light dark;
  --bg: #0b0d12;
  --card-bg: #12151c;
  --border: #22262f;
  --text: #eef0f3;
  --text-dim: #8b93a1;
  --accent: #4f8cff;
  --accent-dim: #2a3a5c;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f5f7;
    --card-bg: #ffffff;
    --border: #e3e5ea;
    --text: #12151c;
    --text-dim: #6b7280;
    --accent: #2f6fed;
    --accent-dim: #dce6ff;
  }
}

* { box-sizing: border-box; }

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

.card {
  width: 100%;
  max-width: 380px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  text-align: center;
  box-shadow: 0 20px 60px -25px rgba(0, 0, 0, 0.35);
}

.logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  margin: 0 auto 1.25rem;
  display: block;
}

.brand {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0;
}

.site-name {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin: 0.2rem 0 1.75rem;
}

.loader {
  width: 40px;
  height: 40px;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  border: 3px solid var(--accent-dim);
  border-top-color: var(--accent);
  animation: spin 0.9s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

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

.status {
  font-size: 0.9rem;
  color: var(--text-dim);
  margin: 0;
  min-height: 1.3em;
}

.dots::after {
  content: "";
  animation: dots 1.4s steps(4, end) infinite;
}

@keyframes dots {
  0% { content: ""; }
  25% { content: "."; }
  50% { content: ".."; }
  75%, 100% { content: "..."; }
}

.actions {
  display: none;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.actions.visible { display: flex; }

.btn {
  display: block;
  padding: 0.7rem 1rem;
  border-radius: 10px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid var(--border);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover { filter: brightness(1.08); }

.btn-secondary {
  color: var(--text);
  background: transparent;
}

.btn-secondary:hover { border-color: var(--accent); }

.hint {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 1rem;
}

.hint-link {
  color: inherit;
}
