/* Momento website. Light only. Tokens follow the desktop app (paper white, graphite, one restrained
   blue). Surfaces are tinted with a continuous outline — never an accent strip along one edge. */

:root {
  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-2: #f2f4f7;
  --surface-3: #e8ecf2;
  --border: rgba(35, 49, 69, 0.08);
  --border-strong: rgba(35, 49, 69, 0.16);
  --text-1: #1d1d1f;
  --text-2: #4f5661;
  --text-3: #6e7682;
  --accent: #087af5;
  --accent-ink: #005cc8;
  --accent-fill: #0868d9;
  --accent-fill-hover: #005bc4;
  --accent-tint: rgba(8, 122, 245, 0.08);
  --shadow-1: 0 1px 2px rgba(23, 37, 57, 0.05);
  --shadow-2: 0 2px 6px rgba(23, 37, 57, 0.04), 0 18px 40px -12px rgba(23, 37, 57, 0.14);
  --shadow-frame: 0 2px 8px rgba(23, 37, 57, 0.06), 0 40px 90px -30px rgba(23, 37, 57, 0.35);
  --radius-tile: 28px;
  --radius-card: 18px;
  --radius-control: 12px;
  --wrap: 1200px;
  --font:
    -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei',
    'Noto Sans SC', system-ui, sans-serif;
  --font-display:
    -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', 'Noto Sans SC', system-ui, sans-serif;
  --font-mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --tracking-display: -0.032em;
  --tracking-title: -0.02em;
  color-scheme: light;
}

/* Chinese is set without the negative tracking Latin display type needs, and with more leading. */
:root:lang(zh-CN) {
  --tracking-display: 0;
  --tracking-title: 0;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 88px;
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-1);
  font: 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

:lang(zh-CN) body {
  line-height: 1.75;
  line-break: strict;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: var(--tracking-title);
  text-wrap: balance;
}

:lang(zh-CN) :is(h1, h2, h3, h4) {
  line-height: 1.3;
  font-weight: 650;
}

p {
  margin: 0;
  text-wrap: pretty;
}

a {
  color: var(--accent-ink);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

code,
kbd {
  font-family: var(--font-mono);
  font-size: 0.88em;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 8px;
}

.wrap {
  width: min(var(--wrap), 100% - 40px);
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-control);
}

.skip:focus {
  top: 12px;
}

.icon {
  flex: none;
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 50px;
  padding: 0 26px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 600 16px/1 var(--font);
  cursor: pointer;
  text-decoration: none;
  transition:
    background-color 0.2s ease,
    transform 0.2s var(--ease),
    box-shadow 0.2s ease;
}

.button:hover {
  text-decoration: none;
}

.button:active {
  transform: scale(0.98);
}

.button-primary {
  background: var(--accent-fill);
  color: #fff;
  box-shadow:
    0 1px 2px rgba(0, 72, 160, 0.2),
    0 8px 20px -8px rgba(8, 104, 217, 0.55);
}

.button-primary:hover {
  background: var(--accent-fill-hover);
}

.button-secondary {
  background: var(--surface);
  color: var(--text-1);
  border-color: var(--border-strong);
}

.button-secondary:hover {
  background: var(--surface-2);
}

.button-small {
  min-height: 36px;
  padding: 0 16px;
  font-size: 14px;
}

.button[aria-disabled='true'] {
  opacity: 0.5;
  pointer-events: none;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}

.link-arrow .icon {
  transition: transform 0.2s var(--ease);
}

.link-arrow:hover {
  text-decoration: none;
}

.link-arrow:hover .icon {
  transform: translateX(3px);
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
}

.icon-button:hover {
  background: var(--surface-3);
  color: var(--text-1);
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 248, 250, 0.78);
  backdrop-filter: saturate(1.8) blur(20px);
  -webkit-backdrop-filter: saturate(1.8) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease;
}

.site-header.scrolled {
  border-bottom-color: var(--border);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-1);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
}

.brand:hover {
  text-decoration: none;
}

.brand .logo-mark {
  color: var(--accent-fill);
}

.site-nav {
  display: flex;
  gap: 2px;
  flex: 1;
}

.site-nav a {
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--text-2);
  font-size: 15px;
}

.site-nav a:hover {
  color: var(--text-1);
  text-decoration: none;
}

.site-nav a[aria-current='page'] {
  color: var(--text-1);
  font-weight: 600;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--text-2);
  font-size: 14px;
}

.lang-switch:hover {
  background: var(--surface-3);
  color: var(--text-1);
  text-decoration: none;
}

.menu-toggle {
  display: none;
}

/* ---------- Type scale ---------- */

.display {
  font-size: clamp(44px, 7.2vw, 96px);
  letter-spacing: var(--tracking-display);
  line-height: 1.02;
}

:lang(zh-CN) .display {
  font-size: clamp(40px, 6.4vw, 84px);
  line-height: 1.18;
}

.title-xl {
  font-size: clamp(34px, 5vw, 64px);
  letter-spacing: var(--tracking-display);
}

.title-l {
  font-size: clamp(28px, 3.4vw, 44px);
}

.title-m {
  font-size: clamp(22px, 2.2vw, 28px);
}

.lede {
  color: var(--text-2);
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.5;
}

:lang(zh-CN) .lede {
  line-height: 1.7;
}

.eyebrow {
  color: var(--accent-ink);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-2);
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow-1);
}

.badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.muted {
  color: var(--text-3);
}

/* ---------- Sections ---------- */

.section {
  padding: clamp(80px, 11vw, 160px) 0;
}

.section-tight {
  padding: clamp(56px, 7vw, 96px) 0;
}

.section-white {
  background: var(--surface);
}

.section-head {
  max-width: 800px;
  margin: 0 auto clamp(48px, 6vw, 80px);
  text-align: center;
  display: grid;
  gap: 18px;
  justify-items: center;
}

.section-title {
  max-width: 900px;
  margin: 0 auto clamp(48px, 6vw, 80px);
  text-align: center;
}

.statements {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
  font-family: var(--font-display);
  font-size: clamp(20px, 2vw, 26px);
  font-weight: 600;
  letter-spacing: var(--tracking-title);
  color: var(--text-2);
}

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

.hero {
  position: relative;
  padding: clamp(64px, 9vw, 120px) 0 0;
  text-align: center;
  isolation: isolate;
}

.hero::before {
  content: '';
  position: absolute;
  inset: -64px 0 auto;
  height: 900px;
  z-index: -1;
  background:
    radial-gradient(60% 50% at 50% 30%, rgba(8, 122, 245, 0.1), transparent 70%),
    radial-gradient(40% 40% at 80% 10%, rgba(120, 170, 255, 0.12), transparent 70%);
  pointer-events: none;
}

.hero .wrap {
  display: grid;
  justify-items: center;
  gap: 26px;
}

.hero .lede {
  max-width: 680px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 14px 32px;
  margin-top: 6px;
}

.hero-note {
  color: var(--text-3);
  font-size: 14px;
}

.hero-stage {
  margin-top: clamp(48px, 7vw, 88px);
  perspective: 1800px;
}

.hero-stage .frame {
  width: min(1180px, 100% - 40px);
  margin-inline: auto;
  transform-origin: 50% 0;
  will-change: transform;
}

/* ---------- Screenshot frames and crops ---------- */

.frame {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: var(--surface);
  box-shadow:
    0 0 0 1px rgba(35, 49, 69, 0.1),
    var(--shadow-frame);
}

.frame img {
  width: 100%;
}

/* A region of a 1440×900 screenshot, scaled to fill its box: --x/--y/--w/--h in screenshot pixels. */
.crop {
  position: relative;
  overflow: hidden;
  aspect-ratio: var(--w) / var(--h);
  border-radius: 14px;
  background: var(--surface);
  box-shadow:
    0 0 0 1px rgba(35, 49, 69, 0.1),
    var(--shadow-2);
}

.crop img {
  position: absolute;
  max-width: none;
  width: calc(1440 / var(--w) * 100%);
  left: calc(var(--x) / var(--w) * -100%);
  top: calc(var(--y) / var(--h) * -100%);
}

.art {
  width: 100%;
  height: auto;
}

/* ---------- Bento ---------- */

.bento {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 20px;
}

.tile {
  position: relative;
  grid-column: span 4;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 420px;
  padding: 36px 36px 0;
  border-radius: var(--radius-tile);
  background: var(--surface);
  box-shadow:
    0 0 0 1px var(--border),
    var(--shadow-1);
  overflow: hidden;
}

.section-white .tile {
  background: var(--surface-2);
  box-shadow: none;
}

.tile.span-5 {
  grid-column: span 5;
}

.tile.span-6 {
  grid-column: span 6;
}

.tile.span-7 {
  grid-column: span 7;
}

.tile.span-8 {
  grid-column: span 8;
}

.tile h3 {
  font-size: clamp(22px, 2vw, 28px);
}

.tile p {
  color: var(--text-2);
  font-size: 16px;
  max-width: 460px;
}

.tile-visual {
  margin-top: auto;
  padding-top: 28px;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.tile-visual .crop {
  width: 100%;
  border-radius: 14px 14px 0 0;
  box-shadow: 0 0 0 1px rgba(35, 49, 69, 0.1);
}

.tile-visual .art {
  width: min(100%, 460px);
  margin-bottom: 12px;
}

/* A typeset GB/T 7714 sample, shown as real text. */
.specimen {
  width: 100%;
  margin: 0 0 32px;
  padding: 22px 24px;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--border);
  font-family: 'Songti SC', 'STSong', 'SimSun', serif;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-1);
}

.section-white .specimen {
  background: var(--surface);
}

.specimen-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
  font-family: var(--font);
}

.specimen-tabs span {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 600;
}

.specimen-tabs span:first-child {
  background: var(--accent-tint);
  color: var(--accent-ink);
}

.specimen p + p {
  margin-top: 6px;
}

/* ---------- Scroll-driven showcase ---------- */

.showcase {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}

.showcase-steps {
  display: grid;
}

.showcase-step {
  min-height: 70vh;
  display: grid;
  align-content: center;
  gap: 16px;
  opacity: 0.3;
  transition: opacity 0.5s var(--ease);
}

.showcase-step.active {
  opacity: 1;
}

.showcase-step .num {
  color: var(--accent-ink);
  font-weight: 700;
  font-size: 15px;
}

.showcase-step p {
  color: var(--text-2);
  font-size: 18px;
}

.showcase-stage {
  position: sticky;
  top: 18vh;
}

.showcase-frames {
  position: relative;
  aspect-ratio: 1440 / 900;
}

.showcase-frames .frame {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(0.97) translateY(14px);
  transition:
    opacity 0.6s var(--ease),
    transform 0.8s var(--ease);
}

.showcase-frames .frame.active {
  opacity: 1;
  transform: none;
}

.showcase-mobile-shot {
  display: none;
}

/* ---------- Chapters (features) ---------- */

.chapter {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}

.chapter.flip .chapter-text {
  order: 2;
}

.chapter-text {
  display: grid;
  gap: 18px;
}

.chapter + .chapter {
  margin-top: clamp(96px, 12vw, 160px);
}

.feature-list {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: grid;
  gap: 20px;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 17px;
  color: var(--text-1);
}

.feature-list .icon {
  color: var(--accent);
}

.chapter-visual .art {
  width: min(100%, 520px);
  margin-inline: auto;
}

/* ---------- Plain cards (compare, download) ---------- */

.grid {
  display: grid;
  gap: 20px;
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card {
  background: var(--surface);
  border-radius: var(--radius-card);
  box-shadow:
    0 0 0 1px var(--border),
    var(--shadow-1);
  padding: 28px;
  display: grid;
  gap: 12px;
  align-content: start;
}

.section-white .card {
  background: var(--surface-2);
  box-shadow: none;
}

.card h3 {
  font-size: 20px;
}

.card p {
  color: var(--text-2);
  font-size: 15.5px;
}

.checks {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.checks li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 15.5px;
  color: var(--text-1);
}

.checks .icon {
  color: var(--accent);
  margin-top: 3px;
}

/* ---------- Privacy band ---------- */

.band {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
}

.band-facts {
  display: grid;
  gap: 22px;
  margin-top: 8px;
}

.band-facts div {
  display: grid;
  gap: 4px;
}

.band-facts strong {
  font-size: 17px;
}

.band-facts span {
  color: var(--text-2);
  font-size: 16px;
}

/* ---------- Tables ---------- */

.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow:
    0 0 0 1px var(--border),
    var(--shadow-1);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

th,
td {
  padding: 16px 20px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border);
}

tr:last-child td,
tr:last-child th {
  border-bottom: 0;
}

thead th {
  color: var(--text-3);
  font-weight: 600;
  font-size: 13.5px;
  white-space: nowrap;
}

thead th:nth-child(2),
td:nth-child(2) {
  background: var(--accent-tint);
}

th[scope='row'] {
  font-weight: 600;
  color: var(--text-1);
  min-width: 150px;
}

td {
  color: var(--text-2);
  min-width: 120px;
}

.yes {
  color: var(--accent-ink);
  font-weight: 600;
}

.table-note {
  margin-top: 14px;
  color: var(--text-3);
  font-size: 13.5px;
}

/* ---------- Docs layout (help, legal, changelog) ---------- */

.page-head {
  padding: clamp(64px, 8vw, 112px) 0 clamp(40px, 5vw, 64px);
}

.page-head .wrap {
  display: grid;
  gap: 18px;
  justify-items: center;
  text-align: center;
}

.page-head .lede {
  max-width: 680px;
}

.docs {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: start;
  padding-bottom: clamp(80px, 10vw, 140px);
}

.toc {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 2px;
  font-size: 14.5px;
}

.toc-title {
  color: var(--text-3);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  padding-left: 12px;
}

.toc a {
  padding: 7px 12px;
  border-radius: 10px;
  color: var(--text-2);
}

.toc a:hover {
  color: var(--text-1);
  background: var(--surface-3);
  text-decoration: none;
}

.toc a.active {
  color: var(--accent-ink);
  background: var(--accent-tint);
  font-weight: 600;
}

.prose {
  max-width: 740px;
  font-size: 17px;
}

.prose h2 {
  font-size: 28px;
  margin: 64px 0 16px;
  scroll-margin-top: 96px;
}

.prose section:first-child h2 {
  margin-top: 0;
}

.prose h3 {
  font-size: 19px;
  margin: 28px 0 10px;
}

.prose p,
.prose ul,
.prose ol {
  margin: 0 0 16px;
  color: var(--text-2);
}

.prose li {
  margin-bottom: 8px;
}

.prose strong {
  color: var(--text-1);
}

.updated {
  color: var(--text-3);
  font-size: 14px;
}

/* Changelog */

.release {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 32px;
  padding: 40px 0;
  border-top: 1px solid var(--border);
}

.release:first-child {
  border-top: 0;
  padding-top: 0;
}

.release-meta {
  display: grid;
  gap: 4px;
  align-content: start;
}

.release-meta strong {
  font-size: 24px;
  font-family: var(--font-display);
}

.release-meta span {
  color: var(--text-3);
  font-size: 14px;
}

.release ul {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 12px;
  color: var(--text-2);
}

/* Help */

.search {
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(600px, 100%);
  padding: 0 20px;
  height: 56px;
  border-radius: 999px;
  background: var(--surface);
  box-shadow:
    0 0 0 1px var(--border-strong),
    var(--shadow-2);
  color: var(--text-3);
}

.search input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text-1);
  font: 17px var(--font);
}

.search:focus-within {
  box-shadow:
    0 0 0 2px var(--accent),
    var(--shadow-2);
}

.faq-group + .faq-group {
  margin-top: 56px;
}

.faq-group h2 {
  font-size: 24px;
  margin-bottom: 8px;
  scroll-margin-top: 96px;
}

details.faq {
  border-bottom: 1px solid var(--border);
}

details.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-weight: 600;
  font-size: 17px;
}

details.faq summary::-webkit-details-marker {
  display: none;
}

details.faq summary .icon {
  color: var(--text-3);
  transition: transform 0.3s var(--ease);
}

details.faq[open] summary .icon {
  transform: rotate(180deg);
}

details.faq .answer {
  padding-bottom: 20px;
  color: var(--text-2);
}

details.faq .answer p + p {
  margin-top: 10px;
}

.contact-card {
  margin-top: 64px;
  padding: 36px;
  border-radius: var(--radius-tile);
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--border);
  display: grid;
  gap: 14px;
  justify-items: start;
  scroll-margin-top: 96px;
}

[hidden] {
  display: none !important;
}

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

.download-hero {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 22px;
}

.app-icon {
  width: 128px;
  height: 128px;
  filter: drop-shadow(0 18px 30px rgba(23, 37, 57, 0.22));
}

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

.codeblock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 12px 12px 18px;
  border-radius: var(--radius-control);
  background: #1d2129;
  color: #e6ebf2;
  font-family: var(--font-mono);
  font-size: 13.5px;
  overflow-x: auto;
}

.codeblock .icon-button {
  color: #aeb7c4;
}

.codeblock .icon-button:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.verify-item {
  display: grid;
  gap: 8px;
}

.verify-item + .verify-item {
  margin-top: 20px;
}

/* ---------- CTA ---------- */

.cta {
  text-align: center;
}

.cta .wrap {
  display: grid;
  justify-items: center;
  gap: 22px;
}

.cta .art {
  width: min(340px, 80%);
}

.cta .lede {
  max-width: 620px;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 56px 0 36px;
  color: var(--text-2);
  font-size: 14px;
  background: var(--bg);
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-brand {
  display: grid;
  gap: 10px;
  max-width: 380px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  align-content: start;
}

.footer-links a {
  color: var(--text-2);
}

.footer-legal {
  margin-top: 36px;
  color: var(--text-3);
  font-size: 13px;
}

/* ---------- Motion ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.9s var(--ease),
    transform 0.9s var(--ease);
  transition-delay: calc(var(--i, 0) * 80ms);
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hero-stage .frame {
    transform: none !important;
  }
  .showcase-frames .frame {
    transition: none;
  }
}

/* ---------- Narrow windows ---------- */

@media (max-width: 1080px) {
  .tile,
  .tile.span-5,
  .tile.span-7 {
    grid-column: span 6;
  }
  .tile.span-8 {
    grid-column: span 12;
  }
  .tile {
    min-height: 380px;
  }
}

@media (max-width: 900px) {
  .showcase {
    grid-template-columns: 1fr;
  }
  .showcase-stage {
    display: none;
  }
  .showcase-step {
    min-height: 0;
    opacity: 1;
    padding: 24px 0 48px;
  }
  .showcase-mobile-shot {
    display: block;
    margin-top: 12px;
  }
  .chapter,
  .band {
    grid-template-columns: 1fr;
  }
  .chapter.flip .chapter-text {
    order: 0;
  }
  .docs {
    grid-template-columns: 1fr;
  }
  .toc {
    display: none;
  }
  .release {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .grid-3 {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  body {
    font-size: 16px;
  }
  .menu-toggle {
    display: inline-grid;
  }
  .header-actions .button-small {
    display: none;
  }
  .site-nav {
    display: none;
    position: absolute;
    inset: 64px 0 auto;
    flex-direction: column;
    padding: 8px 16px 20px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
  }
  .site-nav.open {
    display: flex;
  }
  .site-nav a {
    padding: 14px 12px;
    font-size: 17px;
  }
  .header-row {
    gap: 12px;
    justify-content: space-between;
  }
  .tile,
  .tile.span-5,
  .tile.span-6,
  .tile.span-7,
  .tile.span-8 {
    grid-column: span 12;
    min-height: 0;
    padding: 28px 24px 0;
  }
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
  .hero-stage .frame {
    width: calc(100% - 24px);
    border-radius: 10px;
  }
}
