﻿:root {
  --canvas: #0e1013;
  --surface: #16191d;
  --border: #24282e;
  --ink: #f4f4f5;
  --ink-muted: #9ca3af;
  /* One accent for every button. Per-platform colours made the three compete for
   attention instead of reading as one page. Pandawan green matches the launcher. */
  --accent: #22c55e;
  --accent-ink: #0e1013;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--canvas);
  color: var(--ink);
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
  display: grid;
  place-items: center;
}

main {
  width: 100%;
  max-width: 60rem;
  padding: 4rem 1.5rem;
}

/* Hero ---------------------------------------------------------------- */

/* Generous air below the version badge so the download choices read as their own
   group instead of trailing the heading. */
.hero {
  text-align: center;
  margin-bottom: 6.5rem;
}

.logo {
  width: 88px;
  height: 88px;
  object-fit: contain;
  margin-bottom: 0.75rem;
}

h1 {
  font-size: clamp(2.25rem, 8vw, 3.5rem);
  letter-spacing: -0.03em;
  margin: 0;
}

.lede {
  color: var(--ink-muted);
  margin: 0.5rem 0 0;
  font-size: 1.05rem;
}

.version {
  display: inline-block;
  margin: 1.4rem 0 0;
  padding: 0.3rem 0.9rem;
  border: 1px solid var(--accent);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
}

/* Cards --------------------------------------------------------------- */

.platforms {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
}

/* No card surface: the buttons carry the visual weight, so the columns can sit
   directly on the background. */
.card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
  padding: 0.5rem 0.25rem;
}

.card-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.os-icon {
  width: 44px;
  height: 44px;
  /* object-fit keeps the Tux bitmap from distorting in the shared square box;
     the two brand glyphs are 1:1 so they are unaffected. */
  object-fit: contain;
}

.os-name {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0;
}

.card-empty {
  color: var(--ink-muted);
  font-size: 0.9rem;
  margin: 0;
}

/* Download button ------------------------------------------------------ */

.btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  width: 100%;
  padding: 0.7rem 1.25rem;
  border-radius: 10px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition:
    filter 0.15s ease,
    transform 0.1s ease;
}

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

.btn:active {
  transform: translateY(1px);
}

/* Arrow and label share one centred row. */
.btn-main {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.dl {
  width: 18px;
  height: 18px;
}

/* Sits below the whole button content, parenthesised and dimmed so it reads as
   reference detail rather than part of the action. */
.btn-ext {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--accent-ink);
  opacity: 0.6;
}

/* Alternative formats -------------------------------------------------- */

.alt {
  width: 100%;
}

.alt-select {
  width: 100%;
  padding: 0.45rem 0.7rem;
  background: transparent;
  color: var(--ink-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.8rem;
  cursor: pointer;
  /* Without this the native popup renders with the OS light palette: white
     background under our light grey text, which is unreadable when opened. */
  color-scheme: dark;
}

.alt-select:hover {
  border-color: var(--ink-muted);
  color: var(--ink);
}

.alt-select option {
  background: var(--surface);
  color: var(--ink);
}

.status {
  grid-column: 1 / -1;
  color: var(--ink-muted);
  text-align: center;
}
