:root {
  --bg: #0d0d10;
  --bg-elevated: #18181c;
  --bg-card: #1a1a1f;
  --text: #ffffff;
  --text-muted: #9ca3af;
  --text-faint: #6b7280;
  --accent: #7e6bff;
  --accent-hover: #6c5cf5;
  --accent-glow: rgba(126, 107, 255, 0.35);
  --border: #27272a;
  --border-hover: #3f3f46;
  --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  background:
    radial-gradient(1200px 600px at 50% -200px, rgba(126, 107, 255, 0.15), transparent 60%),
    radial-gradient(800px 400px at 80% 80%, rgba(126, 107, 255, 0.06), transparent 50%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  padding: 80px 24px 40px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.page {
  max-width: 1100px;
  margin: 0 auto;
}

/* ---- Hero ---- */
.hero {
  text-align: center;
  margin-bottom: 36px;
}

.logo {
  margin-bottom: 24px;
  border-radius: 22px;
  box-shadow: 0 8px 30px -8px var(--accent-glow);
}

.title {
  font-size: 56px;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #d4d4d8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.tagline {
  font-size: 19px;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 580px;
  margin: 0 auto;
}

/* ---- Release badge ---- */
.release {
  text-align: center;
  margin-bottom: 48px;
}

.release__badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 18px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 14px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.release__badge.is-loaded {
  background: var(--bg-elevated);
  border-color: var(--accent);
  color: var(--text);
}

.release__spinner {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}

.is-loaded .release__spinner { display: none; }

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

.release__date {
  color: var(--text-faint);
  margin-left: 4px;
}

/* ---- Download cards ---- */
.downloads {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 48px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 32px 26px;
  text-align: left;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.card.is-recommended {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 10px 30px -10px var(--accent-glow);
}

.card.is-recommended::before {
  content: "Recommended for you";
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 10px;
  background: var(--accent);
  color: white;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  background: var(--bg-elevated);
  border-radius: 14px;
  color: var(--accent);
}

.card__title {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 4px;
  text-align: center;
}

.card__hint {
  font-size: 13px;
  color: var(--text-faint);
  margin-bottom: 22px;
  text-align: center;
}

.card__downloads {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ---- Download button ---- */
.download {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.download:hover {
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.download:active { transform: translateY(0); }

.download__col {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.download__name {
  font-size: 15px;
  font-weight: 500;
}

.download__hint {
  font-size: 12px;
  color: var(--text-faint);
}

.download:hover .download__hint { color: rgba(255, 255, 255, 0.85); }

.download__size {
  font-size: 13px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.download:hover .download__size { color: rgba(255, 255, 255, 0.9); }

/* ---- Empty state ---- */
.empty {
  text-align: center;
  padding: 40px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-bottom: 48px;
  color: var(--text-muted);
  line-height: 1.6;
}

.empty p + p { margin-top: 8px; }

.inline-link {
  color: var(--accent);
  text-decoration: none;
}

.inline-link:hover { text-decoration: underline; }

code {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  background: var(--bg-elevated);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
}

/* ---- Footer ---- */
.footer {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  font-size: 14px;
}

.footer__link {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer__link:hover { color: var(--text); }

.footer__sep {
  color: var(--text-faint);
  user-select: none;
}

/* ---- Responsive ---- */
@media (max-width: 880px) {
  body { padding: 60px 20px 30px; }
  .downloads { grid-template-columns: 1fr; gap: 16px; }
  .title { font-size: 42px; }
  .tagline { font-size: 17px; }
  .card { padding: 26px 22px; }
}

@media (max-width: 480px) {
  body { padding: 40px 16px 24px; }
  .title { font-size: 36px; }
  .tagline { font-size: 16px; }
  .hero { margin-bottom: 28px; }
  .release { margin-bottom: 32px; }
  .downloads { margin-bottom: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .release__spinner { animation: none; }
  .card, .download { transition: none; }
}