:root {
  --bg: #ffffff;
  --text: #1d1d22;
  --muted: #5c5c66;
  --rule: #e6e2df;
  --surface: #f6f3f1;
  --accent: #c0392b;
  --accent-text: #a32d22;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131316;
    --text: #e8e6e3;
    --muted: #a3a09c;
    --rule: #2c2a2a;
    --surface: #1c1b1d;
    --accent: #e0553f;
    --accent-text: #f08a72;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent-text);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  text-decoration-thickness: 2px;
}

/* Header: a Hyperion model of a turbulent dusty cloud lit by a few stars,
   seen in scattered light (red, green and blue are 0.8, 0.55 and 0.45
   microns), with the name and links written over it. A light gradient keeps
   the text readable over the brighter parts of the image. */

.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: min(37.5vw, 560px);
  padding: 40px 16px 44px;
  background:
    linear-gradient(rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.45)),
    #05070b url(images/banner.jpg) center / cover no-repeat;
  color: #f2eee9;
  text-align: center;
}

/* On phones the header is roughly square, so only about a third of the
   image's width shows: use a brighter stretch of the same image, anchored
   on the nebulosity at the left rather than the dark middle, with a
   lighter overlay. Only one of the two images is downloaded. */
@media (max-width: 700px) {
  .hero {
    background:
      linear-gradient(rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.3)),
      #05070b url(images/banner-mobile.jpg) 15% center / cover no-repeat;
  }
}

.name {
  margin: 0;
  font-family: Georgia, "Times New Roman", Times, serif;
  font-weight: 400;
  font-size: clamp(3.5rem, 10vw, 7rem);
  line-height: 1;
  letter-spacing: 0.01em;
  color: #fff;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.6);
}

.tagline {
  max-width: 34em;
  margin: 14px auto 8px;
  font-size: 1.2rem;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.7);
  line-height: 1.45;
  color: #e9dfda;
}

.version {
  display: inline-block;
  align-self: center;
  margin: 8px 0 28px;
  padding: 2px 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.25);
  font-size: 0.85rem;
  color: #d8cbc5;
}

.buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.button {
  display: inline-block;
  padding: 10px 22px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.button:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.7);
}

.button.primary {
  background: #c0392b;
  border-color: #c0392b;
}

.button.primary:hover {
  background: #d4473a;
  border-color: #d4473a;
}

/* Content */

main {
  max-width: 760px;
  margin: 0 auto;
  padding: 24px 16px 16px;
}

section {
  padding: 28px 0;
  border-bottom: 1px solid var(--rule);
}

section:last-child {
  border-bottom: none;
}

section[id] {
  scroll-margin-top: 16px;
}

h2 {
  margin: 0 0 12px;
  font-size: 1.45rem;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 12px;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 8px 28px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.features li {
  position: relative;
  padding-left: 20px;
}

.features li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.62em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

pre {
  margin: 0 0 14px;
  padding: 14px 18px;
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 8px;
}

code {
  font: 0.92em/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.citation {
  margin: 0;
  padding: 16px 20px;
  background: var(--surface);
  border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0;
}

.citation .links {
  display: flex;
  gap: 16px;
  margin-top: 8px;
  font-size: 0.92rem;
  font-weight: 600;
}

footer {
  padding: 24px 16px 40px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--muted);
}

footer p {
  margin: 0;
}
