@font-face {
  font-family: "Space Grotesk";
  src: url("space-grotesk-400.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Space Grotesk";
  src: url("space-grotesk-500.ttf") format("truetype");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

:root {
  --background: #02040a;
  --text: #efeee9;
  --muted: #999ca4;
  --accent: #f29a60;
  --line: #24262b;
  color-scheme: dark;
  font-family: "Space Grotesk", sans-serif;
  font-synthesis: none;
  color: var(--text);
  background: var(--background);
}

* { box-sizing: border-box; }
body { margin: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
button[hidden] { display: none; }
::selection { background: var(--accent); color: var(--background); }
a:focus-visible, button:focus-visible, canvas:focus-visible { outline: 2px solid var(--accent); outline-offset: 7px; border-radius: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

.page {
  width: 100%;
  height: 100svh;
  min-height: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: clip;
}
.signal-art { position: relative; flex: 1; min-height: 0; }
.page:has(.signal-art.is-ready) { min-height: 0; }
.signal-art canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.signal-art.is-ready canvas { cursor: grab; }
.signal-art.is-ready canvas.is-dragging { cursor: grabbing; }
.signal-art canvas:focus-visible { outline: none; }
.page:has(canvas:focus-visible) .scene-hint { color: var(--text); outline: 1px solid var(--accent); outline-offset: 6px; border-radius: 2px; }
.signal-art:not(.is-ready) canvas { opacity: 0; pointer-events: none; }
.signal-art.is-ready .scene-copy { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.signal-art.is-ready .signal-fallback { display: none; }
.scene-controls { padding: 14px 24px 24px; display: flex; align-items: center; justify-content: space-between; gap: 20px; width: min(100%, 1440px); margin-inline: auto; color: var(--muted); }
.scene-controls[hidden] { display: none; }
.scene-hint { margin: 0; font-size: 11px; letter-spacing: .02em; white-space: nowrap; }
.touch-hint { display: none; }
.scene-actions { display: flex; align-items: center; gap: 7px; }
.scene-button { color: var(--muted); background: transparent; border: 1px solid #353038; border-radius: 50%; height: 36px; cursor: pointer; transition: color .2s, border-color .2s; }
.scene-button:hover { color: var(--text); border-color: #a97755; }
.scene-button:disabled { opacity: .35; cursor: default; }
.zoom-button { width: 36px; font-size: 18px; line-height: 1; }
.reset-view { border-radius: 20px; padding: 0 14px; font-size: 11px; white-space: nowrap; }
.motion-toggle { color: var(--muted); background: none; border: 0; display: flex; justify-content: center; align-items: center; gap: 8px; margin-left: 12px; padding: 12px 4px; cursor: pointer; font-size: 11px; white-space: nowrap; transition: color .2s; }
.motion-toggle:hover { color: var(--text); }
.play-icon { display: none; }
.motion-toggle[aria-pressed="true"] .pause-icon { display: none; }
.motion-toggle[aria-pressed="true"] .play-icon { display: block; }

/* Accessible HTML also supplies a complete layout while WebGL is unavailable. */
.scene-copy { position: absolute; inset: 0; padding: 48px 6vw 24px; display: flex; flex-direction: column; }
.fallback-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.wordmark { color: var(--text); font-size: 24px; font-weight: 500; letter-spacing: -1.1px; }
.wordmark span, .fallback-header p { color: var(--muted); }
.fallback-header p { font-size: 12px; }
.fallback-hero { margin-block: auto; }
.launch-label { color: var(--accent); font-size: 14px; margin: 0 0 30px; }
h1 { font-size: clamp(54px, 6.45vw, 108px); font-weight: 500; line-height: 1.035; letter-spacing: -.065em; margin: 0; }
.description { color: var(--muted); font-size: 16px; line-height: 1.8; margin: 30px 0 0; }
.fallback-footer { display: flex; justify-content: space-between; color: var(--muted); gap: 20px; font-size: 11px; }
.signal-fallback { position: absolute; width: 24vw; height: 24vw; max-width: 350px; max-height: 350px; right: 13%; top: 50%; transform: translateY(-50%); border: 1px solid #f29a6014; border-radius: 50%; box-shadow: 0 0 80px #f29a6008, inset 0 0 50px #f29a6005; }
.signal-fallback::before { content: ""; position: absolute; inset: -25%; border: 1px solid #f29a6040; border-radius: 50%; transform: rotate(-24deg) scaleY(.3); }
@media (pointer: coarse) { .pointer-hint { display: none; } .touch-hint { display: inline; } .scene-button { min-width: 44px; height: 44px; } }
@media (max-width: 700px) {
  .page { min-height: 740px; }
  .scene-controls { flex-direction: column; gap: 14px; padding: 14px 20px 22px; }
  .scene-hint { font-size: 10px; }
  .scene-copy { padding: 30px 26px; }
  .fallback-header { align-items: flex-start; flex-direction: column; gap: 8px; }
  .fallback-header p { margin: 0; font-size: 10px; }
  .fallback-hero { margin-top: 70px; margin-bottom: auto; }
  .fallback-footer { flex-direction: column; gap: 14px; font-size: 10px; }
  .signal-fallback { width: 180px; height: 180px; top: 75%; right: calc(50% - 90px); }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
