:root {
  color-scheme: light dark;
  --fg: #1d1d1f;
  --muted: #6e6e73;
  --bg: #fbfbfd;
  --card: #ffffff;
  --line: #e5e5ea;
  --accent: #0a66d6;
  --accent-fg: #ffffff;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 12px 32px rgb(0 0 0 / 0.08);
}
@media (prefers-color-scheme: dark) {
  :root {
    --fg: #f5f5f7;
    --muted: #a1a1a6;
    --bg: #000000;
    --card: #161617;
    --line: #2c2c2e;
    --accent: #4aa3ff;
    --accent-fg: #00142b;
    --shadow: 0 0 0 1px #2c2c2e;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "Helvetica Neue", sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.top {
  max-width: 1120px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 15px;
}
.top .brand { display: flex; align-items: center; gap: 10px; color: var(--fg); font-weight: 600; margin-right: auto; }
.top .brand img { width: 28px; height: 28px; border-radius: 7px; }
.top a:not(.brand) { color: var(--muted); }
.top a.star { color: var(--fg); font-weight: 600; padding: 6px 12px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); white-space: nowrap; }
.top a.star:hover { text-decoration: none; opacity: 0.8; }
/* The star count, filled in at build time; hidden when it could not be read. */
.count { margin-left: 8px; padding-left: 8px; border-left: 1px solid currentColor; font-variant-numeric: tabular-nums; opacity: 0.85; }
.count:empty { display: none; }
.open-source { text-align: center; }
section.block.open-source > p.lead { margin: 0 auto; }
/* Narrow screens keep the language switch and Star; the section links go. */
@media (max-width: 560px) {
  .top { gap: 14px; }
  .top a[href^="#"] { display: none; }
}

.hero { text-align: center; padding: 56px 24px 32px; }
.hero img.icon { width: 96px; height: 96px; border-radius: 22px; box-shadow: var(--shadow); }
.hero h1 { font-size: clamp(36px, 6vw, 60px); line-height: 1.08; letter-spacing: -0.02em; margin: 24px auto 16px; max-width: 820px; }
.hero p { font-size: clamp(18px, 2.2vw, 21px); color: var(--muted); max-width: 680px; margin: 0 auto; }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 32px; }
.button {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 16px;
  background: var(--accent);
  color: var(--accent-fg);
}
.button.secondary { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.button:hover { text-decoration: none; opacity: 0.88; }
.note { font-size: 14px; color: var(--muted); margin-top: 14px; }

.shots {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(200px, 1fr);
  gap: 16px;
  overflow-x: auto;
  max-width: 1120px;
  margin: 40px auto 0;
  padding: 8px 24px 24px;
  scroll-snap-type: x mandatory;
}
.shots.mac { grid-auto-columns: minmax(300px, 1fr); }
.shots figure { margin: 0; scroll-snap-align: start; }
.shots img { width: 100%; height: auto; display: block; border-radius: 18px; box-shadow: var(--shadow); background: var(--card); }
.shots.mac img { border-radius: 10px; aspect-ratio: 16 / 11; object-fit: cover; object-position: top; }
.shots figcaption { font-size: 14px; color: var(--muted); margin-top: 10px; line-height: 1.45; }
.shots figcaption b { color: var(--fg); }

section.block { max-width: 1120px; margin: 0 auto; padding: 64px 24px 0; }
section.block > h2 { font-size: clamp(28px, 4vw, 40px); letter-spacing: -0.015em; line-height: 1.15; margin: 0 0 8px; }
section.block > p.lead { color: var(--muted); font-size: 19px; margin: 0 0 28px; max-width: 720px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.card { background: var(--card); border-radius: 18px; padding: 24px; box-shadow: var(--shadow); min-width: 0; }
.card h3 { font-size: 19px; margin: 0 0 8px; }
.card p { margin: 0; color: var(--muted); font-size: 16px; }
/* Checksums are one long word; let them wrap inside the card. */
.card .note { margin-top: 12px; }
.card code { display: block; margin-top: 2px; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; word-break: break-all; }

footer {
  max-width: 1120px;
  margin: 80px auto 0;
  padding: 24px 24px 48px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 14px;
  color: var(--muted);
}
footer span { margin-right: auto; }
footer a { color: var(--muted); }

main.doc { max-width: 720px; margin: 0 auto; padding: 32px 24px 0; }
main.doc h1 { font-size: 34px; line-height: 1.2; margin: 16px 0 8px; }
main.doc h2 { font-size: 21px; margin: 36px 0 8px; }
main.doc .muted { color: var(--muted); font-size: 15px; }
main.doc hr { border: 0; border-top: 1px solid var(--line); margin: 56px 0; }
