/*
 * Windfall — page styles.
 *
 * Two owners, kept apart on purpose:
 *   - The website (hero, cards, FAQ, footer) consumes the Fall theme tokens from tokens.css.
 *     See GUI.md.
 *   - The live desktop inside the preview's Mac screen — menu bar, menus, Finder icons,
 *     Dock, the Windfall HUD — reproduces macOS Tahoe, by direction. Its literal values are
 *     macOS's, not the theme's, and live only in the "macOS" sections below.
 */

:root {
  --menubar: 24px; /* macOS menu bar height on a display without a notch */
  /* The macOS scene always uses the system font — SF Pro on Apple devices. */
  --macos-font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
  --page-max: 1180px;
}

/*
 * Söhne (Klim Type Foundry) is a licensed font and isn't bundled. The theme's font roles list
 * it first, then Graphik Web, so each renders where it's installed and SF Pro covers the
 * rest. To ship Söhne to every visitor, buy a Klim web licence, add its .woff2 files to
 * /assets/fonts/, and uncomment:
 *
 * @font-face { font-family: "Söhne"; src: url("/assets/fonts/soehne-leicht.woff2") format("woff2"); font-weight: 300; font-display: swap; }
 * @font-face { font-family: "Söhne"; src: url("/assets/fonts/soehne-buch.woff2") format("woff2"); font-weight: 400; font-display: swap; }
 * @font-face { font-family: "Söhne"; src: url("/assets/fonts/soehne-kraftig.woff2") format("woff2"); font-weight: 500; font-display: swap; }
 * @font-face { font-family: "Söhne"; src: url("/assets/fonts/soehne-fett.woff2") format("woff2"); font-weight: 700; font-display: swap; }
 */

* { box-sizing: border-box; }

html { background: var(--neutral-1); }
body {
  margin: 0;
  background: var(--neutral-1);
  font-family: var(--font-ui);
  font-weight: var(--weight-ui-regular);
  font-size: var(--size-m);
  line-height: var(--line-m);
  letter-spacing: var(--letter-spacing-m);
  color: var(--neutral-10);
  text-wrap: pretty;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

/* `color` inherits as a resolved value, so each mode scope re-resolves it. */
[data-mode] { color: var(--neutral-10); }

body.blowing, body.blowing * { cursor: none !important; }

/* Theme icons (assets/icons.svg) for the website's own controls. */
.icon {
  width: 16px;
  height: 16px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: var(--icon-stroke-width);
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Hero ───────────────────────────────────────────────────────────────── */

.hero {
  display: grid;
  justify-items: center;
  padding: clamp(64px, 11vh, 132px) var(--space-xl) 0;
  text-align: center;
}
.app-icon {
  width: 112px;
  height: 112px;
  margin-bottom: var(--space-xl);
  filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.5));
}
.headline {
  margin: 0;
  font-family: var(--font-brand);
  font-weight: var(--weight-brand-medium); /* Söhne Kräftig / Graphik Medium */
  font-size: var(--size-display);
  line-height: var(--line-display);
  letter-spacing: var(--letter-spacing-display);
  color: var(--neutral-10);
}
.headline span { display: block; }
.lede {
  margin: var(--space-l) 0 0;
  max-width: 30ch;
  font-size: var(--size-l);
  line-height: var(--line-l);
  letter-spacing: var(--letter-spacing-l);
  color: var(--neutral-7);
}
.hero-cta {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: var(--space-xxl);
}
/* A handwritten aside, as on a sketchbook page. */
/* The arrow's tip (12px down its 34px box) meets the button's right edge at its middle. */
.note {
  position: absolute;
  left: calc(100% + 6px);
  top: 50%;
  margin-top: -12px;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  font: 500 22px/1 "Caveat", "Bradley Hand", cursive;
  color: var(--neutral-7);
  white-space: nowrap;
  pointer-events: none;
}
.note svg { flex: none; }
.note span { transform: translateY(9px) rotate(-6deg); transform-origin: left center; }

/* Button — primary */
.button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-m);
  border: 0;
  border-radius: var(--radius-s);
  font-family: var(--font-ui);
  font-weight: var(--weight-ui-medium);
  font-size: var(--size-m);
  line-height: var(--line-m);
  letter-spacing: var(--letter-spacing-m);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: box-shadow var(--motion-duration) var(--motion-easing), transform var(--motion-duration) var(--motion-easing);
}
.button-primary {
  background: var(--color-5);
  color: var(--neutral-1);
  /* Rest elevation is the theme's shadow-none: just the edge. */
  box-shadow: inset 0 0 0 var(--border-s) var(--border-default-color);
}
.button-primary:hover { box-shadow: inset 0 0 0 var(--border-s) var(--border-default-color), var(--shadow-s); }
.button-primary:focus-visible { outline: var(--focus-ring-outline); outline-offset: var(--border-l); }
.button:active { transform: translateY(var(--motion-press-distance)); }

/* A larger primary action for the hero and closing. */
.button-lg {
  padding: var(--space-s) var(--space-l);
  border-radius: var(--radius-l);
}

/* Keycaps: composed from theme tokens (the theme has no keycap component). */
kbd {
  display: inline-grid;
  place-items: center;
  min-width: calc(var(--line-xs) + var(--space-xs));
  padding: 0 var(--space-xxs);
  border-radius: var(--radius-xs);
  background: var(--neutral-3);
  color: var(--neutral-10);
  box-shadow: inset 0 0 0 var(--border-s) var(--neutral-4);
  font-family: var(--font-ui);
  font-weight: var(--weight-ui-medium);
  font-size: var(--size-xs);
  line-height: var(--line-xs);
  letter-spacing: var(--letter-spacing-xs);
}

/* ── Preview: the live desktop on a Mac, over an autumn melt ─────────────── */

.preview {
  position: relative;
  margin: clamp(48px, 8vh, 88px) var(--space-s) 0;
  padding: clamp(28px, 6vw, 96px) clamp(16px, 6vw, 96px) clamp(64px, 8vw, 120px);
  border-radius: var(--radius-xl);
  overflow: hidden;
  isolation: isolate;
}
canvas.melt { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; display: block; }
canvas.melt.no-webgl { background: linear-gradient(135deg, #2b4433, #8a6a2c 50%, #8c3f1e); }
.mac {
  max-width: 1120px;
  margin: 0 auto;
  padding: 9px;
  border-radius: 22px;
  background: #0b0b0c;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09), 0 10px 30px rgba(0, 0, 0, 0.3), 0 40px 100px rgba(0, 0, 0, 0.45);
}
.screen-frame {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 13px;
  overflow: hidden;
  background: #8fa294;
}
/* A fixed 1280×800 display, scaled to the frame by main.js. */
.screen {
  position: absolute;
  top: 0; left: 0;
  width: 1280px;
  height: 800px;
  transform-origin: 0 0;
  overflow: hidden;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.preview-tab {
  position: absolute;
  left: 50%;
  bottom: 0;
  margin: 0;
  padding: var(--space-s) var(--space-l);
  transform: translateX(-50%);
  border-radius: var(--radius-l) var(--radius-l) 0 0;
  background: var(--neutral-1);
  color: var(--neutral-8);
  font-size: var(--size-s);
  line-height: var(--line-s);
  letter-spacing: var(--letter-spacing-s);
  white-space: nowrap;
}

/* Layers inside the screen. */
.screen .wallpaper, #leaves, #air, .screen .vignette { position: absolute; inset: 0; width: 100%; height: 100%; }
.screen .film { position: absolute; }
.screen .wallpaper { z-index: 0; }
#leaves { z-index: 1; }
.desk-icons { z-index: 2; }
.screen .film { z-index: 3; pointer-events: none; }
.dock { z-index: 4; }
.menubar { z-index: 5; }
.screen .vignette { z-index: 6; pointer-events: none; }
#air { z-index: 7; pointer-events: none; }
.toast { z-index: 8; }
.menu { z-index: 9; }

/* ── Wallpaper ──────────────────────────────────────────────────────────── */

/* The macOS Sierra wallpaper. */
.wallpaper {
  background:
    url("/assets/wallpaper.jpg") center / cover no-repeat,
    #6a5a7c;
}

/* Film grain over the whole scene — wallpaper, leaves and copy — beneath the macOS chrome. */
.film {
  inset: -60px;
  width: calc(100% + 120px);
  height: calc(100% + 120px);
  opacity: 0.06;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 0.9s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-18px, 12px); } 40% { transform: translate(14px, -20px); }
  60% { transform: translate(-10px, -8px); } 80% { transform: translate(20px, 16px); } 100% { transform: translate(0, 0); }
}

.vignette {
  opacity: 0;
  background: radial-gradient(ellipse at center, transparent 55%, color-mix(in srgb, var(--color-1) 22%, transparent) 100%);
}
.vignette.glow { animation: glow 1.8s var(--motion-large-easing); }
@keyframes glow { 0% { opacity: 0; } 18% { opacity: 1; } 45% { opacity: 1; } 100% { opacity: 0; } }

/* ── macOS: menu bar ────────────────────────────────────────────────────── */

/* Tahoe's menu bar is clear: no material, just type over the wallpaper — light over a dark one. */
.menubar {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: var(--menubar);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px 0 8px;
  background: linear-gradient(rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0));
  color: #fff;
  font: 400 13px/16px var(--macos-font);
  letter-spacing: -0.003em;
}
.menus, .status { display: flex; align-items: center; height: 100%; }
.mb-item {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 9px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: inherit;
  font: inherit;
  white-space: nowrap;
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
  cursor: default;
}
.mb-item .glyph, .mb-item .maple-glyph { filter: drop-shadow(0 0 1.5px rgba(0, 0, 0, 0.3)); }
.mb-item.apple { padding: 0 13px 0 10px; font-size: 16px; transform: translateY(-0.5px); }
.no-apple-glyph .mb-item.apple { display: none; }
.mb-item.app { font-weight: 700; }
.status .mb-item { padding: 0 8px; }
.mb-item .glyph, .mb-item .maple-glyph { display: block; flex: none; overflow: visible; }
.mb-trigger:hover, .mb-trigger.open { background: rgba(255, 255, 255, 0.18); }
.mb-trigger:focus-visible { outline: 2px solid rgba(255, 255, 255, 0.7); outline-offset: -2px; }
#sound-button .icon-off { display: none; }
#sound-button.muted .icon-on { display: none; }
#sound-button.muted .icon-off { display: block; }
.clock { padding: 0 8px 0 10px !important; font-variant-numeric: tabular-nums; }

/* ── macOS: menus (follow the system appearance, like real menus) ───────── */

.menu {
  position: absolute;
  top: calc(var(--menubar) + 3px);
  width: 240px;
  padding: 5px;
  border-radius: 12px;
  background: light-dark(rgba(246, 246, 246, 0.78), rgba(36, 36, 38, 0.66));
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  backdrop-filter: blur(40px) saturate(180%);
  box-shadow:
    inset 0 0 0 0.5px light-dark(rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.14)),
    0 0 0 0.5px light-dark(rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.6)),
    0 2px 6px rgba(0, 0, 0, 0.1),
    0 14px 40px rgba(0, 0, 0, 0.26);
  color: light-dark(rgba(0, 0, 0, 0.86), rgba(255, 255, 255, 0.9));
  font: 400 13px/16px var(--macos-font);
  letter-spacing: -0.003em;
  transform-origin: top left;
  animation: menu-in 0.12s ease-out;
}
.menu[hidden] { display: none; }
@keyframes menu-in { from { opacity: 0; } }
.menu-row {
  position: relative;
  display: flex;
  align-items: center;
  height: 22px;
  padding: 0 10px 0 22px;
  border-radius: 6px;
  cursor: default;
  outline: none;
}
.menu-row[role]:hover, .menu-row[role]:focus-visible {
  background: light-dark(#0a6cff, #0a84ff); /* the system accent colour */
  color: #fff;
}
.menu-label { color: light-dark(rgba(0, 0, 0, 0.36), rgba(255, 255, 255, 0.36)); }
.shortcut { margin-left: auto; color: light-dark(rgba(0, 0, 0, 0.42), rgba(255, 255, 255, 0.42)); letter-spacing: 0.08em; }
.menu-row[role]:hover .shortcut, .menu-row[role]:focus-visible .shortcut { color: rgba(255, 255, 255, 0.82); }
.menu-check {
  position: absolute;
  left: 7px;
  width: 11px;
  height: 11px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  visibility: hidden;
}
.menu-row[aria-checked='true'] .menu-check { visibility: visible; }
.menu-sep {
  height: 1px;
  margin: 5px 10px;
  border: 0;
  background: light-dark(rgba(0, 0, 0, 0.1), rgba(255, 255, 255, 0.1));
}

/* ── macOS: Finder desktop icons ────────────────────────────────────────── */

.desk-icons {
  position: absolute;
  top: calc(var(--menubar) + 10px);
  right: 10px;
  display: grid;
  gap: 4px;
  justify-items: center;
}
.desk-icon {
  width: 100px;
  height: 100px;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 2px;
  padding-top: 4px;
  color: #fff;
  font: 400 12px/15px var(--macos-font);
  text-align: center;
}
.desk-icon img { width: 64px; height: 64px; }
.desk-icon span { padding: 0 3px; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85), 0 0 2px rgba(0, 0, 0, 0.7), 0 0 6px rgba(0, 0, 0, 0.35); }

/* ── macOS: Dock (Tahoe Liquid Glass) ───────────────────────────────────── */

.dock {
  position: absolute;
  left: 50%;
  bottom: 5px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px 5px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.09));
  -webkit-backdrop-filter: blur(28px) saturate(185%);
  backdrop-filter: blur(28px) saturate(185%);
  box-shadow:
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.32),
    inset 0 1px 0.5px rgba(255, 255, 255, 0.38),
    inset 0 -1px 1px rgba(0, 0, 0, 0.06),
    0 0 0 0.5px rgba(0, 0, 0, 0.16),
    0 10px 30px rgba(0, 0, 0, 0.24);
}
.dock-item {
  all: unset;
  position: relative;
  width: 56px;
  height: 56px;
}
button.dock-item { cursor: default; }
button.dock-item:focus-visible { outline: 2px solid rgba(255, 255, 255, 0.7); outline-offset: 1px; border-radius: 14px; }
.dock-item .icon-tile { display: block; width: 100%; height: 100%; -webkit-user-drag: none; }
.dock-item:active .icon-tile { filter: brightness(0.7); }
/* Dock label: the dark rounded tag macOS shows above a hovered icon. */
.dock-item .label {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 14px);
  transform: translateX(-50%);
  padding: 3px 10px 4px;
  border-radius: 7px;
  background: rgba(30, 30, 32, 0.74);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.14), 0 0 0 0.5px rgba(0, 0, 0, 0.45), 0 4px 14px rgba(0, 0, 0, 0.28);
  color: rgba(255, 255, 255, 0.94);
  font: 400 13px/16px var(--macos-font);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease-out;
}
.dock-item:hover .label { opacity: 1; }
.running::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -3px;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.72);
  transform: translateX(-50%);
}
.divider { width: 1px; height: 44px; margin: 0 6px; background: rgba(255, 255, 255, 0.26); }
/* The launch bounce. */
.bounce .icon-tile { animation: bounce 0.95s cubic-bezier(0.3, 0, 0.3, 1); }
@keyframes bounce { 0%, 100% { transform: none; } 22% { transform: translateY(-24px); } 46% { transform: none; } 66% { transform: translateY(-10px); } 84% { transform: none; } }

/* ── macOS: Windfall's HUD (matches the app's vibrant-dark pill) ────────── */

.toast {
  position: absolute;
  left: 50%;
  bottom: 96px;
  padding: 8px 18px;
  border-radius: 999px;
  background: rgba(28, 28, 30, 0.62);
  -webkit-backdrop-filter: blur(30px) saturate(160%);
  backdrop-filter: blur(30px) saturate(160%);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.14), 0 12px 34px rgba(0, 0, 0, 0.35);
  color: rgba(255, 255, 255, 0.94);
  font: 500 13px/18px var(--macos-font);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition: opacity 0.22s ease-out, transform 0.3s ease-out;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ── Features ───────────────────────────────────────────────────────────── */

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-m);
  max-width: var(--page-max);
  margin: clamp(56px, 9vw, 112px) auto 0;
  padding: 0 var(--space-m);
}
.card {
  padding: var(--space-xl) var(--space-xl) var(--space-xxl);
  border-radius: var(--radius-xl);
  background: var(--neutral-2);
  text-align: center;
}
.card h2 {
  margin: 0 0 var(--space-xs);
  font-family: var(--font-brand);
  font-weight: var(--weight-brand-medium);
  font-size: var(--size-m);
  line-height: var(--line-m);
  letter-spacing: var(--letter-spacing-m);
}
.card p { margin: 0 auto; max-width: 32ch; color: var(--neutral-7); }
.visual { position: relative; height: 230px; margin-bottom: var(--space-l); overflow: hidden; }

/* All season long. */
.fx-fall { mask-image: linear-gradient(transparent, #000 18%, #000 78%, transparent); }
.fx-fall img {
  position: absolute;
  top: -70px;
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.35));
  animation: drift calc(6.5s + var(--i) * 0.55s) linear infinite;
  animation-delay: calc(var(--i) * -1.35s);
}
@keyframes drift {
  0% { transform: translate(0, 0) rotate(0deg); }
  25% { transform: translate(16px, 80px) rotate(80deg); }
  50% { transform: translate(-12px, 165px) rotate(175deg); }
  75% { transform: translate(14px, 250px) rotate(265deg); }
  100% { transform: translate(0, 340px) rotate(355deg); }
}

/* A blower in your menu bar: the app's own menu, as macOS draws it. */
.fx-menu { display: grid; place-items: center; }
.mini-menu {
  width: 230px;
  padding: 5px;
  border-radius: 12px;
  background: rgba(44, 44, 46, 0.9);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.14), 0 0 0 0.5px rgba(0, 0, 0, 0.6), 0 16px 40px rgba(0, 0, 0, 0.45);
  font: 400 13px/16px var(--macos-font);
  color: rgba(255, 255, 255, 0.9);
  text-align: left;
}
.mini-row { display: flex; justify-content: space-between; height: 22px; align-items: center; padding: 0 10px; border-radius: 6px; }
.mini-row.label { color: rgba(255, 255, 255, 0.36); }
.mini-row.on { background: #0a84ff; color: #fff; }
.mini-row span { color: rgba(255, 255, 255, 0.82); letter-spacing: 0.08em; }
.mini-sep { height: 1px; margin: 5px 10px; background: rgba(255, 255, 255, 0.1); }

/* Never in the way: the layers of a desktop, leaves between wallpaper and windows. */
.fx-layers { perspective: 900px; }
.plate {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 176px;
  height: 116px;
  margin: -58px 0 0 -88px;
  border-radius: 14px;
  transform: rotateX(58deg) rotateZ(-38deg) translateZ(var(--z));
}
.plate span {
  position: absolute;
  left: 10px;
  top: 8px;
  font-size: var(--size-xs);
  line-height: var(--line-xs);
  color: var(--neutral-10);
}
.plate.wall { --z: -60px; background: linear-gradient(160deg, #b7bb9c, #7d978a 60%, #34503e); }
.plate.leaves { --z: 0px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28); }
.plate.leaves img { position: absolute; transform: translate(-50%, -50%); filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.4)); }
.plate.windows {
  --z: 60px;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

/* ── FAQ ────────────────────────────────────────────────────────────────── */

.faq {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr);
  gap: var(--space-xxl);
  max-width: var(--page-max);
  margin: clamp(80px, 12vw, 160px) auto 0;
  padding: 0 var(--space-xl);
}
.faq h2, .closing h2 {
  margin: 0;
  font-family: var(--font-brand);
  font-weight: var(--weight-brand-medium);
  font-size: var(--size-xxl);
  line-height: var(--line-xxl);
  letter-spacing: var(--letter-spacing-xxl);
}
.faq details { box-shadow: inset 0 calc(var(--border-s) * -1) 0 var(--neutral-3); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-l);
  padding: var(--space-l) 0;
  list-style: none;
  cursor: pointer;
  color: var(--neutral-10);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '';
  flex: none;
  width: 7px;
  height: 7px;
  margin-right: 4px;
  border-right: 1.5px solid var(--neutral-7);
  border-bottom: 1.5px solid var(--neutral-7);
  transform: translateY(-2px) rotate(45deg);
  transition: transform var(--motion-duration) var(--motion-easing);
}
.faq details[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.faq summary:focus-visible { outline: var(--focus-ring-outline); outline-offset: var(--border-l); border-radius: var(--radius-s); }
.faq details p { margin: 0 0 var(--space-l); max-width: 60ch; color: var(--neutral-7); }

/* ── Closing ────────────────────────────────────────────────────────────── */

.closing {
  display: grid;
  justify-items: center;
  gap: var(--space-xl);
  padding: clamp(96px, 14vw, 180px) var(--space-xl) clamp(96px, 12vw, 160px);
  text-align: center;
}

/* ── Footer: leaves drift down from the closing into the wordmark ─────── */

/* Page copy stays above the drifting leaves. */
.faq, .closing { position: relative; z-index: 1; }
.footer {
  position: relative;
  isolation: isolate;
}
/* The drift starts well above the footer, behind the closing, so the two read as one scene. The
   leaves pass in front of the wordmark and fade out with it. */
.footer-leaves {
  position: absolute;
  z-index: 2;
  left: 0; right: 0;
  top: -80vh;
  bottom: 0;
  overflow: hidden;
  pointer-events: none;
  /* An eased ramp, so leaves materialise gradually instead of appearing along a line. */
  mask-image: linear-gradient(transparent, rgba(0, 0, 0, 0.06) 14%, rgba(0, 0, 0, 0.25) 26%, rgba(0, 0, 0, 0.6) 38%, #000 50%, #000 80%, transparent);
}
.footer-leaves img {
  position: absolute;
  top: -80px;
  filter: blur(var(--b)) drop-shadow(0 6px 8px rgba(0, 0, 0, 0.4));
  animation: sink var(--t) linear infinite;
  animation-delay: var(--d);
}
@keyframes sink {
  0% { transform: translate(0, 0) rotate(0deg); opacity: 0; }
  20% { opacity: var(--o); }
  25% { transform: translate(28px, 25vh) rotate(90deg); }
  50% { transform: translate(-18px, 50vh) rotate(185deg); }
  75% { transform: translate(24px, 75vh) rotate(270deg); }
  90% { opacity: var(--o); }
  100% { transform: translate(0, 102vh) rotate(360deg); opacity: 0; }
}
/* Black ground, white type, multiplied over the melt: the shader shows only through the letters.
   The page ends partway down the letters, and they fade out into the black as they go. */
.wordmark {
  position: relative;
  isolation: isolate;
  font-size: clamp(110px, 25vw, 400px);
  height: 0.74em;
  overflow: hidden;
  mask-image: linear-gradient(#000 45%, transparent 100%);
}
/* Start the shader just below the box's top edge, so no hairline of it shows above the letters. */
.wordmark .melt { z-index: 0; top: 0.1em; height: calc(100% - 0.1em); }
.wordmark-mask {
  position: relative;
  z-index: 1;
  background: #000;
  color: #fff;
  mix-blend-mode: multiply;
  font-family: var(--font-brand);
  font-weight: var(--weight-brand-medium);
  font-size: 1em;
  line-height: 0.8;
  letter-spacing: -0.05em;
  text-align: center;
  white-space: nowrap;
  /* Room for the ascenders, so every glyph sits over the shader; the mask overhangs the
     canvas slightly so no edge of it shows. */
  padding: 0.16em 0 0.06em;
  margin: -2px;
}

/* ── Intro: the page copy emerges while leaves storm onto the preview ────── */

.intro .hero > :not(.headline),
.intro .headline > span {
  opacity: 0;
  transform: translateY(16px);
  filter: blur(8px);
}
.revealed .hero > :not(.headline),
.revealed .headline > span {
  opacity: 1;
  transform: none;
  filter: blur(0);
  transition:
    opacity 0.9s var(--motion-large-easing),
    transform 1.2s var(--motion-large-easing),
    filter 0.9s var(--motion-large-easing);
  transition-delay: calc(var(--i, 0) * 110ms);
}

/* ── Smaller screens ────────────────────────────────────────────────────── */

@media (max-width: 900px) {
  .features { grid-template-columns: minmax(0, 1fr); }
  .faq { grid-template-columns: minmax(0, 1fr); gap: var(--space-xl); }
}
@media (max-width: 640px) {
  .note { display: none; }
  .preview { margin-left: 0; margin-right: 0; border-radius: 0; }
  .mac { padding: 5px; border-radius: 12px; }
  .screen-frame { border-radius: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .film { animation: none; }
  .fx-fall img { animation: none; }
  .footer-leaves { display: none; }
  .button, .toast, .dock-item .label { transition: none; }
  .menu { animation: none; }
}
