@font-face {
  font-family: "Space Grotesk";
  src: url("space-grotesk-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --ink: #090a0d;
  --canvas: #0e1014;
  --panel: #14161c;
  --text: #f5f6f8;
  --muted: #a3a8b6;
  --line: #ffffff28;
  --cue: #fb6e90;
  --display: "Space Grotesk", "Segoe UI", sans-serif;
  --page-edge: clamp(20px, 4.5vw, 88px);
  --header-height: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-height); }
body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 1rem/1.6 var(--display);
}

h1, h2, h3, p, figure, ol, dl, dd { margin: 0; }
h1, h2, h3, .brand { font-family: var(--display); }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
button { color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--text); outline-offset: 4px; }

.wrap {
  width: min(100%, 1680px);
  margin-inline: auto;
  padding-inline: var(--page-edge);
}

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

.skip-link {
  position: fixed;
  z-index: 4;
  margin: 10px;
  padding: 9px 16px;
  background: var(--text);
  color: var(--ink);
  transform: translateY(-160%);
}

.skip-link:focus { transform: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 3;
  background: #090a0dfa;
  border-bottom: 1px solid var(--line);
}

.header-inner, .footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.header-inner { min-height: var(--header-height); }
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: -.035em;
  text-decoration: none;
}

.brand img { flex: none; }
.main-nav, .footer-inner nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: clamp(16px, 3vw, 44px);
}

.main-nav a, footer a:not(.brand) {
  color: var(--muted);
  text-decoration: none;
  font-size: .875rem;
}

.main-nav a:hover, footer a:not(.brand):hover { color: var(--text); }
.header-download {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  font-size: .875rem;
  text-decoration: none;
  white-space: nowrap;
}

.header-download:hover { border-color: var(--text); }
.header-controls { display: flex; align-items: center; gap: 8px; }

.stage-world {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

main, footer { position: relative; z-index: 1; }

.hero {
  position: relative;
  display: grid;
  min-height: max(660px, calc(100svh - var(--header-height)));
  isolation: isolate;
  overflow: clip;
  background: #090a0d;
}

.hero-art {
  position: absolute;
  z-index: -1;
  inset: 0;
  overflow: hidden;
  background:
    linear-gradient(0deg, #090a0d 0%, transparent 27%),
    radial-gradient(ellipse at 74% 41%, #412b25 0%, #222026 25%, #0f1016 56%, #090a0d 82%);
}

.hero-art::after {
  position: absolute;
  inset: 0;
  background: url("stage-grain.svg");
  opacity: .23;
  mix-blend-mode: soft-light;
  content: "";
}

.record {
  position: absolute;
  top: 50%;
  right: max(-4%, calc((100vw - 1540px) / 2));
  width: min(62vw, 920px);
  transform: translateY(-52%);
  opacity: .95;
}

.record img {
  width: 100%;
  animation: spin 26s linear infinite paused;
}

.hero[data-playing] .record img { animation-play-state: running; }
@keyframes spin { to { transform: rotate(1turn); } }

@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .hero { view-timeline-name: --stage; }
    .record {
      animation: drift-out linear both;
      animation-timeline: --stage;
      animation-range: exit 0% exit 100%;
    }
    .hero[data-scene-paused] .record { animation: none; }
  }
}

@keyframes drift-out { to { transform: translateY(-34%); } }

.hero-layout {
  position: relative;
  display: grid;
  grid-template-columns: 1fr minmax(250px, .65fr);
  grid-template-rows: 1fr auto auto;
  align-items: end;
  column-gap: clamp(20px, 5vw, 96px);
  min-width: 0;
  padding-top: clamp(52px, 8vh, 108px);
}

.hero-intro { align-self: start; max-width: 38rem; }
.hero-intro > p:not(.release-label) {
  margin-top: 22px;
  max-width: 24rem;
  color: #d1d3da;
  font-size: clamp(1rem, 1.6vw, 1.2rem);
}

.release-label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: #d1d3da;
  font-size: .875rem;
}

.release-label span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--cue);
}

h1 {
  font-size: clamp(4rem, 7.6vw, 8.25rem);
  font-weight: 500;
  line-height: .86;
  letter-spacing: -.083em;
}

.hero-actions, .install-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px 24px;
}

.hero-actions { margin-top: 27px; }
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  min-height: 45px;
  padding: 9px 15px;
  color: var(--ink);
  background: var(--text);
  border: 1px solid transparent;
  font-size: .875rem;
  font-weight: 700;
  text-decoration: none;
}

.button:hover { background: #dbdde3; }
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  text-decoration-color: #ffffff6b;
  text-underline-offset: .28em;
  font-size: .875rem;
}

.text-link:hover { text-decoration-color: currentColor; }

.preview {
  justify-self: end;
  width: min(100%, 356px);
  margin-bottom: 4px;
  padding: 15px 18px 13px;
  border: 1px solid #ffffff36;
  background: #101116ed;
}

.preview-head, .transport {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.preview-head strong { display: block; font-family: var(--display); font-weight: 600; }
.preview-head span, .time { color: var(--muted); font-size: .75rem; }
.scene-toggle {
  display: grid;
  place-items: center;
  flex: none;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.scene-toggle:hover { color: var(--text); border-color: currentColor; }
.scene-toggle svg { width: 18px; height: 18px; fill: currentColor; }
.scene-play, .scene-toggle[data-paused] .scene-pause { display: none; }
.scene-toggle[data-paused] .scene-play { display: block; }
.time { white-space: nowrap; }
.time { font-variant-numeric: tabular-nums; }
.lyric {
  display: flex;
  flex-wrap: wrap;
  align-content: center;
  column-gap: .26em;
  min-height: 3.4em;
  padding-block: 8px;
  font: 500 clamp(1.15rem, 2vw, 1.5rem)/1.15 var(--display);
  color: #cccdd6;
  letter-spacing: -.025em;
}

/* Words are spaced by flex once the timed line is active. */
.lyric:not([data-timed]) { display: block; }
.lyric .is-active { color: var(--cue); }
.transport { border-top: 1px solid var(--line); padding-top: 8px; }
.transport button {
  display: grid;
  flex: none;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
}

.transport button:hover { background: #ffffff14; }
.transport svg { width: 20px; height: 20px; fill: currentColor; }
.pause-icon, .hero[data-playing] .play-icon { display: none; }
.hero[data-playing] .pause-icon { display: block; }
.transport input {
  width: 100%;
  min-width: 30px;
  height: 32px;
  margin: 0;
  accent-color: var(--cue);
  cursor: pointer;
}

.hero-wordmark {
  grid-column: 1 / -1;
  position: relative;
  margin-top: clamp(28px, 4vh, 52px);
  padding-bottom: .06em;
  font: 700 min(17.4vw, 290px)/.78 var(--display);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: -.072em;
  user-select: none;
}

.chapters {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  margin-top: clamp(16px, 2.6vh, 32px);
}

.chapters a {
  display: grid;
  grid-template-columns: auto 1fr;
  align-content: start;
  column-gap: 12px;
  padding: 16px 12px 20px;
  text-decoration: none;
}

.chapters a + a { border-left: 1px solid var(--line); }
.chapters a:hover { background: #ffffff0c; }
.chapters a > span, .chapter-label span {
  font-family: var(--display);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.chapters strong { font-size: .875rem; font-weight: 600; }
.chapters small { grid-column: 2; color: var(--muted); font-size: .75rem; }

.chapter {
  padding-block: clamp(72px, 11vw, 156px);
  border-top: 1px solid var(--line);
}

#showcase, .install, .releases { background: var(--canvas); }
.stage-live .hero, .stage-live .hero-art { background: transparent; }
.stage-live .record { visibility: hidden; }
.stage-live #showcase, .stage-live #sync, .stage-live .install, .stage-live .releases {
  background: linear-gradient(90deg, #090a0df5, #090a0dc7 50%, #090a0d90);
}

.stage-live footer { background: #090a0df2; }
.stage-live .gallery-screen img { box-shadow: 0 28px 55px #0009; }
.stage-live .style-list { background: #0e1014d9; }

@media (prefers-reduced-motion: no-preference) {
  .stage-enter .hero-intro { animation: stage-intro .9s both; }
  .stage-enter .preview { animation: stage-intro .85s .18s both; }
  .stage-enter .hero-wordmark { animation: stage-letters 1.1s .12s both; }
}

@keyframes stage-intro {
  from { transform: translateY(12px); }
  to { transform: translateY(0); }
}

@keyframes stage-letters {
  from { clip-path: inset(0 0 78%); transform: translateY(20px); }
  to { clip-path: inset(0); transform: translateY(0); }
}
.chapter-label {
  display: flex;
  gap: 14px;
  margin-bottom: 22px;
  font-size: .875rem;
  font-weight: 600;
}

.section-intro {
  display: grid;
  grid-template-columns: 1.4fr .6fr;
  align-items: end;
  gap: 24px 40px;
  margin-bottom: clamp(32px, 5vw, 70px);
}

h2 {
  font-size: clamp(2.85rem, 6.9vw, 7rem);
  font-weight: 500;
  line-height: .94;
  letter-spacing: -.073em;
}

.section-intro p { max-width: 36ch; color: var(--muted); }
.section-intro > div > p { margin-top: 18px; }
.gallery {
  display: grid;
  grid-template-columns: minmax(0, 2.45fr) minmax(230px, 1fr);
  gap: clamp(16px, 3vw, 44px);
  align-items: start;
}

.gallery-screen { min-width: 0; }
.gallery-screen img {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  background: var(--panel);
}

.gallery-screen figcaption {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 14px;
  padding-top: 12px;
  color: var(--muted);
  font-size: .875rem;
}

.gallery-screen figcaption strong { color: var(--text); }
.style-list { border-top: 1px solid var(--line); }
.style-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
  gap: 8px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  font: 500 .95rem/1.3 var(--display);
}

.style-list a:hover { background: #ffffff0b; }
.style-list a[aria-current] { box-shadow: inset 2px 0 currentColor; background: #ffffff10; }
.style-list a small { color: var(--muted); font-size: .75rem; }

.signal-path {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 0;
  list-style: none;
  border-block: 1px solid var(--line);
}

.signal-path li { padding: 20px clamp(10px, 2vw, 28px) 24px; }
.signal-path li + li { border-left: 1px solid var(--line); }
.signal-path li > span, .app-shot figcaption { color: var(--muted); font-size: .875rem; }
.signal-path h3, .install h3 { font-size: 1.25rem; font-weight: 600; }
.signal-path h3 { margin-block: 8px; }
.signal-path p, .install-grid p { color: var(--muted); }

.app-shot { margin-top: clamp(36px, 6vw, 72px); }
.app-shot img { width: 100%; max-width: 1150px; margin-inline: auto; }
.app-shot figcaption { margin-top: 12px; text-align: center; }
.install-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px 60px;
}

.install-grid h3 { margin-bottom: 6px; }
.install-grid pre {
  overflow: auto;
  max-width: 100%;
  margin: 16px 0 0;
  padding: 14px;
  background: var(--ink);
  border: 1px solid var(--line);
  font-size: .8125rem;
}

.help { border-top: 1px solid var(--line); }
.help details { border-bottom: 1px solid var(--line); }
.help summary { padding-block: 12px; cursor: pointer; font-weight: 600; }
.help details p, .shortcuts { margin-bottom: 16px; }
.shortcuts > div { display: flex; justify-content: space-between; gap: 10px; padding-block: 3px; }
.shortcuts kbd { padding: 1px 4px; border: 1px solid var(--line); }

.release-list {
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.release-list > li {
  display: grid;
  grid-template-columns: minmax(190px, .7fr) minmax(0, 2.3fr);
  gap: 10px 48px;
  padding-block: 26px 30px;
  border-bottom: 1px solid var(--line);
}

.release-head h3 { font-size: 1.5rem; font-weight: 600; letter-spacing: -.025em; }
.release-head time { display: block; margin-top: 8px; color: var(--muted); font-size: .875rem; }
.release-tag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: .6875rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  vertical-align: middle;
}

.release-notes { display: grid; gap: 7px; margin: 0; padding-left: 1.1em; color: var(--muted); }
.release-notes code { font-size: .9em; }
.release-links {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 4px;
  font: 500 .875rem var(--display);
}

.release-links a { text-decoration: none; border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.release-links a:hover { border-color: currentColor; }

footer { border-top: 1px solid var(--line); }
.footer-inner { min-height: 92px; padding-block: 20px; flex-wrap: wrap; }

@media (min-width: 900px) {
  .hero-intro { padding-bottom: 16px; }
  .preview { margin-bottom: 26px; }
}

@media (min-width: 761px) and (max-height: 790px) {
  .hero { min-height: max(560px, calc(100svh - var(--header-height))); }
  .hero-layout { padding-top: clamp(36px, 7vh, 55px); }
  .hero-intro > p:not(.release-label) { margin-top: 16px; }
  .hero-actions { margin-top: 18px; }
  .hero-wordmark { margin-top: 22px; }
  .chapters { margin-top: 17px; }
  .chapters a { padding-block: 10px 14px; }
}

@media (max-width: 760px) {
  :root { --header-height: 60px; }
  .header-inner { gap: 12px; }
  .main-nav { display: none; }
  .hero-layout { grid-template-columns: minmax(0, 1fr); padding-top: 48px; }
  .hero-intro { grid-row: 1; }
  .hero-wordmark { grid-row: 2; margin-top: 32px; }
  .preview { grid-row: 3; justify-self: start; margin: 24px 0 0; }
  .chapters { grid-row: 4; grid-template-columns: repeat(2, 1fr); }
  .chapters a { padding: 11px 8px; }
  .chapters a:nth-child(3) { border-left: 0; }
  .chapters a:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .record { top: 34%; right: -31%; width: 113vw; opacity: .64; }
  .hero-art { background: radial-gradient(ellipse at 85% 38%, #412b25, #171820 42%, #090a0d 75%); }
  .stage-live .hero { background: linear-gradient(90deg, #090a0d93, #090a0d24); }
  .stage-live #showcase, .stage-live #sync, .stage-live .install, .stage-live .releases { background: #090a0dba; }
  .section-intro, .install-grid { grid-template-columns: minmax(0, 1fr); }
  .release-list > li { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .release-links { grid-column: 1; }
  .gallery { grid-template-columns: minmax(0, 1fr); }
  .style-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .style-list a:nth-child(even) { border-left: 1px solid var(--line); }
}

@media (max-width: 430px) {
  .hero-layout { padding-top: 38px; }
  h1 { font-size: clamp(3rem, 14vw, 4rem); }
  .hero-actions { gap: 6px 14px; }
  .gallery { gap: 16px; }
  .style-list a { padding-inline: 7px; }
  .style-list a small { display: none; }
  .signal-path { grid-template-columns: 1fr; }
  .signal-path li { padding-inline: 0; }
  .signal-path li + li { border-left: 0; border-top: 1px solid var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero[data-playing] .record img { animation: none; }
}
