/* ----------------------------------------------------------------------------
 * AniVoyage Verify Site - styles
 * Vanilla CSS / no build / mobile-first / dark mode via prefers-color-scheme
 * --------------------------------------------------------------------------*/

:root {
  --bg: #f5f7fb;
  --card-bg: #ffffff;
  --card-border: #e5e8ef;
  --fg: #1a1f2e;
  --fg-muted: #5a6378;
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --primary-fg: #ffffff;
  --success: #10b981;
  --error: #ef4444;
  --muted: #94a3b8;
  --shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  --radius: 16px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1320;
    --card-bg: #181d2c;
    --card-border: #262c3d;
    --fg: #f1f3f8;
    --fg-muted: #9aa3b8;
    --primary: #60a5fa;
    --primary-hover: #93c5fd;
    --primary-fg: #0f1320;
    --success: #34d399;
    --error: #f87171;
    --muted: #64748b;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--fg);
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    "Hiragino Sans",
    "Noto Sans JP",
    "Noto Sans CJK KR",
    "Noto Sans CJK SC",
    "Noto Sans CJK TC",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;
  font-size: 16px;
  line-height: 1.6;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px 24px 28px;
  text-align: center;
}

.brand {
  margin: 0 0 24px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--fg);
}

/* --- state sections ------------------------------------------------------ */

.state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.state[hidden] {
  display: none;
}

.state-title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--fg);
}

.state-desc {
  margin: 0;
  color: var(--fg-muted);
  font-size: 14.5px;
}

/* --- icons --------------------------------------------------------------- */

.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  margin-bottom: 4px;
}

.icon-success {
  background: color-mix(in srgb, var(--success) 14%, transparent);
  color: var(--success);
}

.icon-error {
  background: color-mix(in srgb, var(--error) 14%, transparent);
  color: var(--error);
}

.icon-muted {
  background: color-mix(in srgb, var(--muted) 18%, transparent);
  color: var(--muted);
}

/* --- spinner ------------------------------------------------------------- */

.spinner {
  width: 44px;
  height: 44px;
  border: 3px solid var(--card-border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
  margin: 4px 0 8px;
}

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

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

/* --- buttons ------------------------------------------------------------- */

.primary-button {
  display: inline-block;
  margin-top: 12px;
  padding: 12px 28px;
  min-width: 200px;
  background: var(--primary);
  color: var(--primary-fg);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  border-radius: 10px;
  transition: background-color 0.15s ease;
}

.primary-button:hover,
.primary-button:focus-visible {
  background: var(--primary-hover);
  outline: none;
}

/* --- store section ------------------------------------------------------- */

.store-section {
  margin: 18px 0 0;
  font-size: 13px;
  color: var(--fg-muted);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.store-label {
  display: block;
}

.store-links {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.store-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.store-link:hover,
.store-link:focus-visible {
  text-decoration: underline;
  outline: none;
}

.store-sep {
  color: var(--muted);
}

/* --- footer -------------------------------------------------------------- */

.footer {
  margin-top: 28px;
  color: var(--muted);
  font-size: 12px;
}

/* --- responsive ---------------------------------------------------------- */

@media (max-width: 380px) {
  .card {
    padding: 24px 18px 22px;
  }
  .state-title {
    font-size: 18px;
  }
  .primary-button {
    min-width: 0;
    width: 100%;
  }
}
