/* Morphwheel site: one static page, no scripts. Dark by default, light follows the OS.
   The demo is one 10 s CSS timeline; every animated part uses the same percentages.
   The rest of the motion is CSS too (the CSP allows no script): smooth anchor scrolling, the
   hero's entrance, sections that rise in as they scroll into view, and the FAQ's opening and
   closing. All of it is off under prefers-reduced-motion, and every part degrades to a static
   page where a browser lacks the feature (scroll-driven animations, interpolate-size). */

:root {
  --bg: #0c0c0d;
  --text: #ededed;
  --muted: #8f8f94;
  --line: #222225;
  --accent: #0078d4;
  --accent-text: #fff;
  --accent-soft: #4cc2ff; /* icons on the dark background */
  --header-h: 64px;
  --ease-out: cubic-bezier(0.2, 0.7, 0.2, 1);
  --font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --display: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "Cascadia Mono", "Cascadia Code", Consolas, ui-monospace, monospace;

  /* the demo's desktop and File Explorer (Windows 11 dark) */
  --desk: #17181b;
  --win: #1c1c1c;
  --win-bar: #202020;
  --win-line: #2e2e2e;
  --win-field: #2b2b2b;
  --win-text: #e8e8e8;
  --win-muted: #9a9a9a;
  --select: rgb(76 194 255 / 0.16);
  --select-line: rgb(76 194 255 / 0.5);
  --key: #26272b;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #fbfbfa;
    --text: #18181a;
    --muted: #6b6b70;
    --line: #e6e6e3;
    --accent: #0067c0;
    --accent-soft: #0067c0;

    --desk: #e9ecef;
    --win: #f9f9f9;
    --win-bar: #f3f3f3;
    --win-line: #e2e2e2;
    --win-field: #fff;
    --win-text: #1a1a1a;
    --win-muted: #616161;
    --select: rgb(0 103 192 / 0.1);
    --select-line: rgb(0 103 192 / 0.45);
    --key: #fff;
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 0.5rem); /* anchors land below the sticky header */
  interpolate-size: allow-keywords; /* lets the FAQ animate to its content's height */
}

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

::selection {
  background: color-mix(in srgb, var(--accent) 40%, transparent);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

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

h1,
h2 {
  font-family: var(--display);
  margin: 0;
}

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

h1,
h2,
h3,
.lede {
  text-wrap: balance;
}

code {
  font: 0.9em var(--mono);
}

.wrap {
  width: min(1080px, 100% - 3rem);
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: absolute;
  z-index: 20; /* above the sticky header */
  inset-inline-start: 1rem;
  top: -3rem;
  padding: 0.5rem 1rem;
  background: var(--accent);
  color: var(--accent-text);
  border-radius: 6px;
}

.skip:focus {
  top: 1rem;
}

/* ------------------------------------------------------------------ header */

.top {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}

/* Where scroll-driven animations exist, the header's line appears only once the page scrolls. */
@supports (animation-timeline: scroll()) {
  .top {
    animation: header-line linear both;
    animation-timeline: scroll();
    animation-range: 0 64px;
  }

  @keyframes header-line {
    from { border-bottom-color: transparent; }
    to { border-bottom-color: var(--line); }
  }
}

.top-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 600;
  text-decoration: none;
}

.top nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.94rem;
}

.top nav a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s;
}

.top nav a:hover {
  color: var(--text);
}

.top nav .pill {
  color: var(--text);
  padding: 0.35rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: color 0.15s, border-color 0.15s, background-color 0.15s;
}

.top nav .pill:hover {
  border-color: var(--muted);
  background: color-mix(in srgb, var(--text) 6%, transparent);
}

/* ------------------------------------------------------------------ hero */

.hero {
  padding: clamp(4rem, 10vw, 7.5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
  text-align: center;
}

h1 {
  font-size: clamp(3rem, 9vw, 6.2rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.045em;
}

.lede {
  max-width: 34rem;
  margin: 1.6rem auto 0;
  font-size: clamp(1.05rem, 2vw, 1.22rem);
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.4rem;
  margin-top: 2.2rem;
}

.button {
  display: inline-block;
  padding: 0.75rem 1.4rem;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-text);
  font-weight: 600;
  text-decoration: none;
  transition: filter 0.15s, transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
}

.button:hover {
  filter: brightness(1.12);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px -8px color-mix(in srgb, var(--accent) 75%, transparent);
}

.button:active {
  filter: brightness(0.96);
  transform: translateY(0) scale(0.98);
  box-shadow: none;
}

.link {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s;
}

.link:hover {
  color: var(--text);
}

.meta {
  margin-top: 1.3rem;
  font-size: 0.88rem;
  color: var(--muted);
}

/* ------------------------------------------------------------------ the demo
   A 1000 by 600 design-pixel stage; 1 design px = var(--u), so it scales as one picture. */

.demo-wrap {
  position: relative;
  padding-bottom: clamp(4rem, 9vw, 7rem);
}

.pause-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pause {
  position: absolute;
  z-index: 1;
  top: 0.75rem;
  right: 0.75rem;
  padding: 0.2rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  color: var(--muted);
  font-size: 0.8rem;
  cursor: pointer;
  transition: color 0.15s;
}

.pause:hover {
  color: var(--text);
}

.pause-input:focus-visible + .pause {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.when-paused,
.pause-input:checked + .pause .when-playing {
  display: none;
}

.pause-input:checked + .pause .when-paused {
  display: inline;
}

.pause-input:checked ~ .demo .stage *,
.pause-input:checked ~ .captions li {
  animation-play-state: paused;
}

.demo {
  container-type: inline-size;
}

.stage {
  --u: calc(100cqw / 1000);
  position: relative;
  aspect-ratio: 1000 / 600;
  overflow: hidden;
  border-radius: calc(var(--u) * 16);
  background: var(--desk);
  border: 1px solid var(--line);
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: calc(var(--u) * 12);
  color: var(--win-text);
  user-select: none;
}

.stage *,
.captions li {
  animation-duration: 10s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
}

.stage svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* File Explorer: x 120 to 760, y 50 to 380 */
.explorer {
  position: absolute;
  left: calc(var(--u) * 120);
  top: calc(var(--u) * 50);
  width: calc(var(--u) * 640);
  height: calc(var(--u) * 330);
  display: flex;
  flex-direction: column;
  background: var(--win);
  border: 1px solid var(--win-line);
  border-radius: calc(var(--u) * 8);
  box-shadow: 0 calc(var(--u) * 18) calc(var(--u) * 50) rgb(0 0 0 / 0.35);
  overflow: hidden;
}

.ex-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: calc(var(--u) * 40);
  padding-inline-start: calc(var(--u) * 10);
  background: var(--win-bar);
}

.ex-tab {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--u) * 8);
  height: calc(var(--u) * 32);
  margin-top: calc(var(--u) * 8);
  padding: 0 calc(var(--u) * 14);
  background: var(--win);
  border-radius: calc(var(--u) * 7) calc(var(--u) * 7) 0 0;
}

.stage .ex-tab svg {
  width: calc(var(--u) * 16);
  height: calc(var(--u) * 16);
  fill: #f0c342;
  stroke: none;
}

.ex-controls {
  display: flex;
  height: 100%;
}

.stage .ex-controls svg {
  width: calc(var(--u) * 46);
  height: 100%;
  padding: 0 calc(var(--u) * 18);
  stroke: var(--win-muted);
}

.ex-bar {
  display: flex;
  align-items: center;
  gap: calc(var(--u) * 12);
  height: calc(var(--u) * 48);
  padding: 0 calc(var(--u) * 14);
  border-bottom: 1px solid var(--win-line);
  color: var(--win-muted);
}

.ex-bar > svg {
  width: calc(var(--u) * 16);
  height: calc(var(--u) * 16);
}

.ex-address,
.ex-search {
  height: calc(var(--u) * 30);
  display: flex;
  align-items: center;
  padding: 0 calc(var(--u) * 12);
  background: var(--win-field);
  border: 1px solid var(--win-line);
  border-radius: calc(var(--u) * 5);
}

.ex-address {
  flex: 1;
  color: var(--win-text);
}

.ex-address i {
  font-style: normal;
  margin: 0 calc(var(--u) * 6);
  color: var(--win-muted);
}

.ex-search {
  width: calc(var(--u) * 170);
}

.ex-files {
  display: flex;
  flex: 1;
  align-items: flex-start;
  padding: calc(var(--u) * 16) calc(var(--u) * 20);
}

.tile {
  flex: none;
  width: calc(var(--u) * 112);
  margin: 0;
  padding: calc(var(--u) * 8) 0 calc(var(--u) * 6);
  text-align: center;
  border: 1px solid transparent;
  border-radius: calc(var(--u) * 5);
  overflow: hidden;
  white-space: nowrap;
}

.tile img {
  display: block;
  width: calc(var(--u) * 96);
  height: calc(var(--u) * 72);
  margin: calc(var(--u) * 12) auto;
  border-radius: calc(var(--u) * 2);
}

.ex-status {
  position: relative;
  height: calc(var(--u) * 28);
  padding: 0 calc(var(--u) * 14);
  display: flex;
  align-items: center;
  color: var(--win-muted);
}

.ex-status span {
  position: absolute;
}

/* The wheel: 380 design px (its window at size M), centered at (540, 300) */
.wheel {
  position: absolute;
  left: calc(var(--u) * 350);
  top: calc(var(--u) * 110);
  width: calc(var(--u) * 380);
  height: calc(var(--u) * 380);
}

.wheel picture,
.wheel img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* The toast: 360 by 91, bottom right */
.toast {
  position: absolute;
  right: calc(var(--u) * 24);
  bottom: calc(var(--u) * 24);
  width: calc(var(--u) * 360);
  filter: drop-shadow(0 calc(var(--u) * 8) calc(var(--u) * 18) rgb(0 0 0 / 0.3));
}

.toast img {
  display: block;
  width: 100%;
  height: auto;
}

.key {
  position: absolute;
  left: calc(var(--u) * 24);
  bottom: calc(var(--u) * 24);
  padding: calc(var(--u) * 8) calc(var(--u) * 16);
  font: 600 calc(var(--u) * 15) / 1 "Segoe UI", system-ui, sans-serif;
  color: var(--win-text);
  background: var(--key);
  border: 1px solid var(--win-line);
  border-bottom-width: calc(var(--u) * 3);
  border-radius: calc(var(--u) * 7);
}

/* The pointer; its hot spot is the element's origin */
.cursor {
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
}

.stage .arrow {
  position: absolute;
  width: calc(var(--u) * 20);
  height: calc(var(--u) * 30);
  fill: #fff;
  stroke: #000;
  stroke-width: 1.4;
  filter: drop-shadow(0 1px 2px rgb(0 0 0 / 0.4));
}

.ghost {
  position: absolute;
  left: calc(var(--u) * 14);
  top: calc(var(--u) * 20);
  width: calc(var(--u) * 52);
  height: calc(var(--u) * 39);
  border-radius: calc(var(--u) * 3);
}

/* ---- the timeline: drag (4-24 %), Shift (27-38 %), aim (40-47 %), drop (52 %), result */

.cursor {
  translate: calc(var(--u) * 850) calc(var(--u) * 420);
  animation-name: pointer;
}

@keyframes pointer {
  0%, 4% { translate: calc(var(--u) * 850) calc(var(--u) * 420); }
  14%, 16% { translate: calc(var(--u) * 420) calc(var(--u) * 200); }
  24%, 40% { translate: calc(var(--u) * 540) calc(var(--u) * 300); }
  47%, 54% { translate: calc(var(--u) * 512) calc(var(--u) * 212); }
  64%, 100% { translate: calc(var(--u) * 850) calc(var(--u) * 420); }
}

.ghost {
  opacity: 0;
  animation-name: ghost;
}

@keyframes ghost {
  0%, 17% { opacity: 0; }
  19%, 52% { opacity: 0.55; }
  53%, 100% { opacity: 0; }
}

.tile-source {
  animation-name: selected;
}

@keyframes selected {
  0%, 15% { background: transparent; border-color: transparent; }
  16%, 92% { background: var(--select); border-color: var(--select-line); }
  95%, 100% { background: transparent; border-color: transparent; }
}

.key {
  opacity: 0;
  animation-name: key;
}

@keyframes key {
  0%, 26% { opacity: 0; transform: translateY(calc(var(--u) * 6)); }
  27.5%, 37% { opacity: 1; transform: translateY(0); }
  39%, 100% { opacity: 0; transform: translateY(0); }
}

.wheel {
  opacity: 0;
  animation-name: wheel;
}

@keyframes wheel {
  0%, 28.5% { opacity: 0; transform: scale(0.94); }
  30.5%, 52.5% { opacity: 1; transform: scale(1); }
  54.5%, 100% { opacity: 0; transform: scale(0.96); }
}

.wheel-hover {
  opacity: 0;
  animation-name: hover;
}

@keyframes hover {
  0%, 44.5% { opacity: 0; }
  45.5%, 99% { opacity: 1; }
  100% { opacity: 0; }
}

.tile-new {
  width: 0;
  opacity: 0;
  border: 0;
  animation-name: new-file;
}

@keyframes new-file {
  0%, 55% { width: 0; opacity: 0; }
  58%, 92% { width: calc(var(--u) * 112); opacity: 1; }
  96%, 100% { width: 0; opacity: 0; }
}

.n5 {
  opacity: 0;
  animation-name: show-mid;
}

.n4 {
  animation-name: hide-mid;
}

@keyframes show-mid {
  0%, 56% { opacity: 0; }
  57%, 93% { opacity: 1; }
  94%, 100% { opacity: 0; }
}

@keyframes hide-mid {
  0%, 56% { opacity: 1; }
  57%, 93% { opacity: 0; }
  94%, 100% { opacity: 1; }
}

.toast {
  opacity: 0;
  animation-name: toast;
}

@keyframes toast {
  0%, 57% { opacity: 0; transform: translateY(calc(var(--u) * 14)); }
  60%, 89% { opacity: 1; transform: translateY(0); }
  92%, 100% { opacity: 0; transform: translateY(0); }
}

/* ---- the captions under the stage, on the same clock */

.captions {
  position: relative;
  height: 1.6em;
  margin: 1.2rem 0 0;
  padding: 0;
  list-style: none;
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
}

.captions li {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.captions .c1 { animation-name: cap1; }
.captions .c2 { animation-name: cap2; }
.captions .c3 { animation-name: cap3; }
.captions .c4 { animation-name: cap4; }

@keyframes cap1 {
  0%, 23% { opacity: 1; }
  25%, 94% { opacity: 0; }
  96%, 100% { opacity: 1; }
}

@keyframes cap2 {
  0%, 25% { opacity: 0; }
  27%, 39% { opacity: 1; }
  41%, 100% { opacity: 0; }
}

@keyframes cap3 {
  0%, 41% { opacity: 0; }
  43%, 54% { opacity: 1; }
  56%, 100% { opacity: 0; }
}

@keyframes cap4 {
  0%, 56% { opacity: 0; }
  58%, 92% { opacity: 1; }
  94%, 100% { opacity: 0; }
}

/* ------------------------------------------------------------------ facts */

.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.8rem 3rem;
  padding: clamp(3rem, 7vw, 5rem) 0;
  border-top: 1px solid var(--line);
}

.facts .icon {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
  margin-bottom: 0.85rem;
  fill: none;
  stroke: var(--accent-soft);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.facts .icon .solid {
  fill: var(--accent-soft);
  stroke: none;
}

.facts h3 {
  margin-top: 0;
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.45rem;
  letter-spacing: -0.01em;
}

.facts p {
  color: var(--muted);
  font-size: 0.96rem;
}

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

.formats {
  padding: 2rem 0;
  border-top: 1px solid var(--line);
  font: 0.9rem/1.9 var(--mono);
  color: var(--text);
}

.formats p {
  display: grid;
  grid-template-columns: 6.5rem 1fr;
}

.formats span {
  color: var(--muted);
}

.formats small {
  color: var(--muted);
  font-size: 1em;
}

/* ------------------------------------------------------------------ install */

.install {
  padding: clamp(3rem, 7vw, 5rem) 0;
  border-top: 1px solid var(--line);
}

.install h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.install-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.6rem;
  margin-top: 1.6rem;
}

.install-row code {
  padding: 0.7rem 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.install-row .meta {
  margin: 0;
}

.install .note {
  max-width: 40rem;
}

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

.faq {
  padding: clamp(3rem, 7vw, 5rem) 0;
  border-top: 1px solid var(--line);
}

.faq h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 1.4rem;
}

.faq details {
  max-width: 46rem;
  border-bottom: 1px solid var(--line);
}

.faq summary {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.faq summary:hover::after {
  color: var(--text);
}

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

.faq summary::after {
  content: "+";
  flex: none;
  color: var(--muted);
  font-size: 1.25em;
  font-weight: 300;
  line-height: 1.2;
  transition: rotate 0.3s var(--ease-out), color 0.15s;
}

.faq details[open] summary::after {
  rotate: 45deg;
}

.faq summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.faq details p {
  padding-bottom: 1.1rem;
  color: var(--muted);
}

.faq a {
  color: var(--text);
}

/* Opening and closing slide: the answer's box animates between 0 and its own height (Chromium;
   elsewhere it opens at once). */
@supports (interpolate-size: allow-keywords) {
  .faq details::details-content {
    block-size: 0;
    opacity: 0;
    overflow-y: clip;
    transition:
      block-size 0.35s var(--ease-out),
      opacity 0.3s ease,
      content-visibility 0.35s allow-discrete;
  }

  .faq details[open]::details-content {
    block-size: auto;
    opacity: 1;
  }
}

/* ------------------------------------------------------------------ footer */

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--line);
  font-size: 0.88rem;
  color: var(--muted);
}

.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.3rem;
}

.foot a {
  text-decoration: none;
}

.foot a:hover {
  color: var(--text);
}

.credit {
  display: grid;
  gap: 0.35rem;
}

.credit p {
  margin: 0;
}

.maker {
  font-size: 1rem;
  color: var(--text);
}

.maker a {
  font-weight: 600;
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--muted);
  text-underline-offset: 0.2em;
}

.maker a:hover {
  text-decoration-color: currentColor;
}

.maker-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.3rem;
}

/* ------------------------------------------------------------------ 404 */

.not-found {
  padding: 8rem 0;
  text-align: center;
}

.not-found .lede {
  margin-bottom: 2rem;
}

/* ------------------------------------------------------------------ narrow screens */

@media (max-width: 820px) {
  .facts {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .top nav {
    gap: 1rem;
  }

  .wide-only {
    display: none; /* GitHub: also "View source" in the hero and the footer */
  }

  .facts {
    grid-template-columns: 1fr;
  }

  .demo-wrap {
    width: calc(100% - 1rem);
  }

  .captions {
    height: 3.2em;
  }

  .formats p {
    grid-template-columns: 1fr;
    margin-bottom: 0.6rem;
  }
}

/* Bigger targets for fingers: the small text links get vertical padding. */
@media (pointer: coarse) {
  .top nav a:not(.pill),
  .foot a,
  .link {
    padding-block: 0.6rem;
  }
}

/* ------------------------------------------------------------------ motion
   The hero rises in on load; the sections below rise in as they scroll into view. */

@media (prefers-reduced-motion: no-preference) {
  .hero > *,
  .demo-wrap {
    animation: rise 0.8s var(--ease-out) both;
  }

  .hero > :nth-child(2) { animation-delay: 0.08s; }
  .hero > :nth-child(3) { animation-delay: 0.16s; }
  .hero > :nth-child(4) { animation-delay: 0.22s; }
  .demo-wrap { animation-delay: 0.3s; }

  @supports (animation-timeline: view()) {
    .facts > div,
    .formats p,
    .install > *,
    .faq h2,
    .faq details,
    .foot > * {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 5% entry 50%;
    }

    .facts > div:nth-child(3n + 2) { animation-range: entry 10% entry 55%; }
    .facts > div:nth-child(3n) { animation-range: entry 15% entry 60%; }
  }
}

@keyframes rise {
  from {
    opacity: 0;
    translate: 0 1.5rem;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}

/* ------------------------------------------------------------------ reduced motion
   No timeline: the stage holds the moment just before the drop. */

@media (prefers-reduced-motion: reduce) {
  .stage *,
  .captions li {
    animation: none !important;
  }

  .cursor {
    translate: calc(var(--u) * 512) calc(var(--u) * 212);
  }

  .ghost {
    opacity: 0.55;
  }

  .tile-source {
    background: var(--select);
    border-color: var(--select-line);
  }

  .wheel,
  .wheel-hover {
    opacity: 1;
  }

  .captions .c3 {
    opacity: 1;
  }

  .pause {
    display: none;
  }

  .faq summary::after {
    transition: none;
  }

  .faq details::details-content {
    transition: none;
  }

  .button,
  .link,
  .top nav a {
    transition: none;
  }

  .button:hover,
  .button:active {
    transform: none;
  }
}

/* ------------------------------------------------------------------ print
   No scrolling and no clock: every element at rest, fully visible. */

@media print {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .top {
    position: static;
  }
}
