/* The static pages (about, y-generator): a sheet of prose on the same paper the
   app is drawn on. Deliberately separate from style.css — these pages have no
   canvas, no chrome and no app shell, so they load tokens.css and this, and
   nothing else. Notes live in DESIGN.md. */

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }

.page { max-width: 720px; margin: 0 auto; padding: 34px clamp(18px, 5vw, 32px) 72px; }

:where(a, button, input, summary):focus-visible { outline: 2.5px solid var(--brand); outline-offset: 2px; }

/* ---------- masthead ---------- */

.masthead { display: flex; align-items: center; gap: 14px; margin-bottom: 46px; }
.mast-brand {
  display: inline-flex; align-items: center; gap: 9px;
  font: 600 17px var(--sans); color: var(--ink); text-decoration: none;
}
.mast-brand svg { width: 24px; height: 24px; color: var(--faint); }
.mast-brand .cube { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.mast-nav { margin-left: auto; display: flex; align-items: center; gap: 16px; font-size: 14px; }
.mast-nav a { color: var(--muted); text-decoration: none; }
.mast-nav a:hover { color: var(--ink); }

/* ---------- prose ---------- */

h1 {
  margin: 0 0 14px; font-size: 32px; font-weight: 600; line-height: 1.2;
  letter-spacing: -0.025em; text-wrap: balance;
}
h2 {
  margin: 46px 0 12px; font-size: 19px; font-weight: 600;
  letter-spacing: -0.015em; text-wrap: balance;
}
h3 { margin: 26px 0 6px; font-size: 15px; font-weight: 600; }
p { margin: 0 0 15px; max-width: 68ch; text-wrap: pretty; }
.lede { font-size: 18px; color: var(--muted); margin-bottom: 30px; }
a { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--brand); }
ul { margin: 0 0 15px; padding-left: 20px; max-width: 68ch; }
li { margin-bottom: 7px; }
li::marker { color: var(--faint); }
b, strong { font-weight: 600; }
hr { border: 0; border-top: 1px solid var(--line); margin: 46px 0; }

/* ---------- the one call to action ---------- */

.cta {
  display: inline-flex; align-items: center; gap: 9px;
  font: 600 15px var(--sans); text-decoration: none;
  background: var(--brand); color: var(--surface);
  border-radius: 999px; padding: 12px 22px; box-shadow: var(--press);
  transition: background .15s ease, transform .12s var(--ease);
}
.cta:hover { background: color-mix(in srgb, var(--brand) 82%, var(--muted)); color: var(--surface); }
.cta:active { transform: translateY(1px); }
.cta svg { width: 16px; height: 16px; }

.ghost {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 14px var(--sans); text-decoration: none;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 999px; padding: 11px 19px;
  transition: background .15s ease, border-color .15s ease, transform .12s var(--ease);
}
.ghost:hover { background: color-mix(in srgb, var(--brand) 8%, var(--surface)); border-color: color-mix(in srgb, var(--brand) 28%, var(--line)); color: var(--ink); }
.ghost:active { transform: translateY(1px); }
.ghost svg { width: 15px; height: 15px; }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 26px 0 10px; }

/* ---------- FAQ ---------- */

.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 15px 26px 15px 0; position: relative;
  font-weight: 600; font-size: 15.5px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; position: absolute; right: 4px; top: 22px;
  width: 8px; height: 8px; border-right: 2px solid var(--faint); border-bottom: 2px solid var(--faint);
  transform: rotate(45deg); transform-origin: 70% 70%; transition: transform .15s var(--ease);
}
.faq details[open] summary::after { transform: rotate(-135deg); }
.faq details p { margin: 0 0 15px; color: var(--muted); }

/* ---------- the Y generator's board ---------- */

.ypad {
  position: relative; background: var(--board); border: 1px solid var(--line);
  border-radius: var(--r3); overflow: hidden;
  background-image: radial-gradient(var(--grid) 1.2px, transparent 1.2px);
  background-size: 24px 24px;
  aspect-ratio: 4 / 3;
}
.ypad canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.seedline { font-size: 13px; color: var(--faint); }

/* ---------- foot ---------- */

.page-foot {
  margin-top: 56px; padding-top: 20px; border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  font-size: 13px; color: var(--faint);
}
.page-foot a { color: var(--muted); text-decoration: none; }
.page-foot a:hover { color: var(--ink); text-decoration: underline; }

@media (max-width: 560px) {
  h1 { font-size: 27px; }
  .lede { font-size: 16.5px; }
  .mast-nav { gap: 13px; font-size: 13.5px; }
}
