@font-face {
  font-family: "Instrument Serif";
  src: url("assets/fonts/instrument-serif.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("assets/fonts/instrument-serif-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Space Grotesk";
  src: url("assets/fonts/space-grotesk.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: "Space Mono";
  src: url("assets/fonts/space-mono.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0b0f17;
  --slate: #131b29;
  --cyan: #38bdf8;
  --teal: #2dd4bf;
  --text: #f8fafc;
  --muted: #94a3b8;
  --line: rgba(148, 163, 184, .22);
  --display: "Space Grotesk", system-ui, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --mono: "Space Mono", monospace;
  --header-h: 72px;
  --view: 100vh;
}

@supports (height: 100svh) {
  :root { --view: 100svh; }
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: var(--display);
  font-size: 1rem;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, figure { margin: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
a { color: inherit; }
img { display: block; max-width: 100%; }
::selection { color: var(--bg); background: var(--cyan); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 5px; }
[id] { scroll-margin-top: var(--header-h); }
#home { scroll-margin-top: 0; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link {
  position: fixed;
  z-index: 50;
  top: 12px;
  left: 12px;
  padding: .65rem 1rem;
  border: 1px solid var(--cyan);
  background: var(--bg);
  color: var(--text);
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

.journey {
  position: relative;
  isolation: isolate;
  background: #05070d;
}
.js-ready .journey {
  --flight-travel: clamp(57rem, calc(var(--view) * 1.14), 65rem);
  height: calc(var(--view) + var(--flight-travel));
}
@media (hover: none) and (pointer: coarse) {
  .js-ready .journey {
    --flight-travel: clamp(110rem, calc(var(--view) * 2.48), 140rem);
  }
}
.journey-stage {
  position: sticky;
  top: 0;
  display: grid;
  place-items: center;
  height: var(--view);
  overflow: hidden;
  background: #03060c;
}
#cosmos,
.journey-vignette {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
#cosmos { display: block; }
.journey-vignette {
  pointer-events: none;
  opacity: var(--welcome-veil, .55);
  background:
    radial-gradient(ellipse at 50% 48%, #02040b49 0%, transparent 52%),
    linear-gradient(180deg, #03060f44 0%, transparent 20%, transparent 77%, #03050bc2 100%);
}
.journey-caption-veil {
  position: absolute;
  inset: 0;
  opacity: var(--caption-veil, 0);
  pointer-events: none;
  background:
    radial-gradient(ellipse at 10% 65%, #02040cdc, #02040c41 51%, transparent 74%),
    linear-gradient(90deg, #02040c5e, transparent 66%);
}
.welcome-panel,
.journey-caption {
  position: absolute;
  inset-inline: 4%;
  top: 50%;
  transform: translateY(calc(-50% + var(--caption-drift, 0px)));
  text-align: center;
  pointer-events: none;
  text-shadow: 0 2px 26px #000, 0 1px 66px #000a;
}
.welcome-panel { top: 48%; }
.welcome-panel h1 {
  font-family: var(--serif);
  font-size: clamp(5rem, 13.5vw, 13rem);
  font-weight: 400;
  line-height: .84;
  letter-spacing: -.042em;
  min-height: .86em;
}
.welcome-title { color: #f6f7fc; }
.welcome-prompt {
  min-height: 1.8rem;
  margin-top: clamp(1.35rem, 4vh, 2.75rem);
  color: #d3dde8;
  font: 400 clamp(.73rem, 1.1vw, .9rem)/1.5 var(--mono);
  letter-spacing: .23em;
  text-transform: uppercase;
}
.type-caret {
  display: inline-block;
  width: 1px;
  height: 1em;
  margin-left: .38em;
  background: var(--cyan);
  box-shadow: 0 0 12px #38bdf8aa;
  vertical-align: -.14em;
  animation: blink 1.25s step-end 4;
}
@keyframes blink { 50% { opacity: 0; } }
.journey-caption {
  --caption-gutter: clamp(1.4rem, 8vw, 10rem);
  inset: auto auto auto var(--caption-gutter);
  top: 64%;
  width: min(62vw, 51rem);
  visibility: hidden;
  opacity: 0;
  transform: translate(var(--caption-drift, 0px), -50%);
  text-align: left;
}
.journey-caption::before {
  content: "";
  display: block;
  width: clamp(1.1rem, 3.1vw, 2.6rem);
  height: 1px;
  margin-bottom: clamp(.8rem, 2.3vw, 1.7rem);
  background: #71d8fd;
  box-shadow: 0 0 12px #38bdf888;
}
.journey-caption p:first-child {
  color: #f8fafc;
  font: 400 clamp(2.8rem, 6.05vw, 6.75rem)/.95 var(--serif);
  letter-spacing: -.031em;
}
.journey-caption em {
  font-weight: 400;
  color: #d5eef4;
}
.journey-caption .journey-caption-note {
  max-width: 32ch;
  margin: 1.25rem 0 0;
  color: #e5edf5;
  font: 400 clamp(.95rem, 1.35vw, 1.09rem)/1.55 var(--display);
}
.journey-progress {
  position: absolute;
  bottom: max(1.55rem, env(safe-area-inset-bottom));
  left: 50%;
  width: min(22vw, 110px);
  height: 2px;
  transform: translateX(-50%);
  background: #d3e8fb38;
  opacity: var(--progress-opacity, 0);
}
.journey-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: #c1edff;
  transform: scaleX(var(--progress, 0));
  transform-origin: left center;
  box-shadow: 0 0 10px #38bdf8ad;
}

.playback-toggle {
  position: absolute;
  right: max(clamp(.9rem, 4vw, 4.25rem), env(safe-area-inset-right));
  bottom: max(clamp(.9rem, 3vh, 2rem), env(safe-area-inset-bottom));
  padding: .6rem .45rem;
  min-height: 44px;
  border: 0;
  border-radius: .25rem;
  background: none;
  color: #bad0e4;
  font: .78rem/1.35 var(--mono);
  text-shadow: 0 1px 8px #020610;
  text-underline-offset: .24em;
  cursor: pointer;
}
.playback-toggle[hidden] { display: none; }
.playback-toggle:hover, .playback-toggle:focus-visible {
  color: #e1f4ff;
  text-decoration: underline;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  right: 0;
  left: 0;
  min-height: var(--header-h);
  opacity: 0;
  pointer-events: none;
  background: #0b0f17e8;
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: opacity .27s ease;
}
.site-header.is-visible { opacity: 1; pointer-events: auto; }
.site-nav {
  width: min(1380px, 100% - clamp(2rem, 8vw, 8rem));
  min-height: var(--header-h);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr minmax(48px, auto) 1fr;
  align-items: center;
}
.nav-group { display: flex; align-items: center; gap: clamp(1.1rem, 2.5vw, 3rem); }
.nav-group-right { justify-content: end; }
.nav-group a,
.menu-toggle,
.mobile-menu a {
  color: #c0cad8;
  padding-block: .35em;
  font-size: .88rem;
  font-weight: 500;
  white-space: nowrap;
  text-decoration: none;
  transition: color .2s ease;
}
.nav-group a:hover,
.nav-group a[aria-current],
.mobile-menu a:hover,
.mobile-menu a[aria-current] { color: var(--cyan); }
.site-logo {
  width: 48px;
  height: 52px;
  display: grid;
  place-items: center;
  grid-column: 2;
  grid-row: 1;
  border-radius: 8px;
}
.site-logo img { width: auto; height: 38px; transition: filter .2s ease; }
.site-logo:hover img { filter: drop-shadow(0 0 10px #38bdf897); }
.menu-toggle,
.mobile-menu { display: none; }
.site-credits {
  max-width: 1440px;
  margin: auto;
  padding: .75rem clamp(1.25rem, 6vw, 6rem) 1.5rem;
  color: var(--muted);
  font: .76rem/1.7 var(--display);
}
.site-credits summary { cursor: pointer; width: fit-content; }
.site-credits p { max-width: 65ch; padding-block: .5rem .25rem; }
.site-credits a { text-underline-offset: .2em; }

@media (max-width: 760px) {
  :root { --header-h: 64px; }
  .welcome-panel { top: 46%; }
  .journey-caption {
    --caption-gutter: clamp(1.35rem, 7vw, 3rem);
    width: calc(100% - var(--caption-gutter) * 2);
    top: 72%;
  }
  .journey-caption-veil {
    background: radial-gradient(ellipse at 16% 72%, #02040cec, #02040c6e 47%, transparent 75%);
  }
  .journey-caption p:first-child { font-size: clamp(2.55rem, 8.9vw, 4.2rem); }
  .journey-caption .journey-caption-note { margin-top: .82rem; }
  .nav-group { display: none; }
  .menu-toggle {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    display: flex;
    align-items: center;
    gap: .55rem;
    min-height: 44px;
    border: 0;
    background: none;
    cursor: pointer;
  }
  .menu-mark { width: 13px; border-block: 1px solid currentColor; height: 6px; }
  .mobile-menu:not([hidden]) {
    grid-column: 1 / -1;
    display: grid;
    gap: .15rem;
    padding: .6rem 0 1.1rem;
  }
  .mobile-menu a { padding: .55rem 0; }
  .site-logo img { height: 34px; }
}

@media (max-width: 370px) {
  .welcome-panel h1 { font-size: clamp(4rem, 22vw, 5rem); }
  .journey-caption p:first-child { font-size: clamp(2.35rem, 12vw, 3rem); }
}

@media (max-height: 400px) and (orientation: landscape) {
  .welcome-panel h1 { font-size: clamp(4rem, 18vh, 6rem); }
  .journey-caption { top: 62%; }
  .journey-caption p:first-child { font-size: clamp(2.25rem, 12vh, 4.1rem); }
  .welcome-prompt { margin-top: .65rem; min-height: 1rem; }
  .mobile-menu:not([hidden]) { max-height: calc(100dvh - var(--header-h)); overflow: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .js-ready .journey { --flight-travel: clamp(17rem, calc(var(--view) * .38), 22rem); }
  .site-header, .site-logo img, .nav-group a, .mobile-menu a { transition: none; }
  .type-caret { animation: none; }
}
