@font-face {
  font-family: 'Infrastructure Sans';
  src: url('./InfrastructureSans-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  font-family: 'Infrastructure Sans', "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-weight: 700;
  color: #111;
  background: #f5f4f0;
}

* { box-sizing: border-box; }

body { margin: 0; }

main { position: relative; }

/* Three screens of travel, plus room to linger at the invitation. */
.is-enhanced main { height: 340vh; height: 340svh; }

#galaxy {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.scene {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(32px, 8vh, 80px);
  padding: 48px 0;
}

.is-enhanced .scene {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  display: grid;
  place-items: center;
  justify-content: normal;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.identity, .invitation { text-align: center; }

.is-enhanced .identity, .is-enhanced .invitation { grid-area: 1 / 1; }

.identity {
  width: 100%;
  padding: 0 20px;
}

/* Script fades these every frame; own layers keep that off the paint path. */
.is-enhanced .identity, .is-enhanced .scroll-cue, .is-enhanced .invitation { will-change: opacity; }

h1 {
  margin: 0;
  font-size: clamp(15px, 3.65vw, 54px);
  line-height: 1.2;
}

.scroll-cue {
  position: absolute;
  bottom: max(36px, env(safe-area-inset-bottom));
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  color: inherit;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
}

.is-enhanced .scroll-cue { display: flex; }

.scroll-cue[hidden] { display: none; }

.scroll-cue { min-width: 44px; min-height: 44px; }
.scroll-cue:focus-visible { outline: 1px solid currentColor; outline-offset: 8px; }

.arrow { display: none; font-size: 24px; }

.is-enhanced .arrow { display: block; }

.invitation { padding: 24px; }

.is-enhanced .invitation {
  opacity: 0;
  visibility: hidden;
}

.is-enhanced .invitation.is-visible { visibility: visible; animation: float 3s ease-in-out infinite; }

h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 48px);
}

.is-enhanced #invitation-threshold { position: absolute; top: 200vh; top: 200svh; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

@media (prefers-reduced-motion: reduce) {
  .is-enhanced .invitation.is-visible { animation: none; }
}

a { color: inherit; }

a:focus-visible, button:focus-visible, [tabindex="-1"]:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 5px;
}

.site-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 13px 20px;
  border: 1px solid #111;
  border-radius: 2px;
  background: #111;
  color: #f5f4f0;
  font: inherit;
  font-size: 14px;
  line-height: 1.4;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.site-button:hover { background: #333; }
.site-button[hidden] { display: none; }
.site-button.is-disabled { cursor: help; background: #8d8b85; border-color: #8d8b85; opacity: 1; }

.invitation .arrow { margin-top: 24px; }

.contact-shell {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

.contact-options {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.contact-options[hidden] { display: none; }

.contact-tooltip {
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  width: min(320px, calc(100vw - 48px));
  margin: 0;
  padding: 12px 14px;
  transform: translateX(-50%);
  border: 1px solid #111;
  border-radius: 2px;
  background: #f5f4f0;
  font-size: 13px;
  line-height: 1.45;
  box-shadow: 0 8px 24px rgba(17, 17, 17, 0.12);
}

.contact-tooltip[hidden] { display: none; }

.copy-status {
  min-height: 1.5em;
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 5;
  padding: 14px 18px;
  background: #111;
  color: #f5f4f0;
  transform: translateY(-200%);
}

.skip-link:focus { transform: translateY(0); }

.document-page { min-height: 100vh; }

.document-header {
  width: min(100% - 48px, 900px);
  margin: 0 auto;
  padding: 32px 0 24px;
  border-bottom: 1px solid #cfcdc6;
}

.document-brand {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  max-width: 100%;
  font-size: clamp(14px, 3.5vw, 23px);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.document-nav { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 16px; font-size: 14px; }
.document-nav a { display: inline-flex; align-items: center; min-height: 44px; }
.document-nav [aria-current="page"] { text-decoration-thickness: 3px; text-underline-offset: 5px; }

.eyebrow {
  margin: 0 0 18px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.document-content {
  width: min(100% - 48px, 760px);
  margin: 0 auto;
  padding: 56px 0 72px;
}

.document-content p, .document-content li {
  font-size: 16px;
  line-height: 1.75;
}

.document-content a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-underline-offset: 4px;
}

.endpoint-url {
  overflow-wrap: anywhere;
  user-select: all;
  -webkit-user-select: all;
}

.prompt {
  margin: 20px 0;
  padding: 20px 24px;
  border-left: 3px solid #111;
  background: #eeede7;
  font-size: 16px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 0.9em; overflow-wrap: anywhere; }

.document-content h1 { margin-bottom: 24px; font-size: clamp(38px, 7vw, 64px); line-height: 1.1; }
.document-content h2 { margin: 42px 0 16px; font-size: clamp(23px, 4vw, 30px); line-height: 1.25; }
.document-content h3 { margin: 28px 0 12px; font-size: 20px; line-height: 1.35; }
.document-content ul, .document-content ol { padding-left: 24px; }
.document-content li { margin-bottom: 12px; }
.document-content .document-intro { font-size: 19px; }
.document-content .notice { padding: 20px 24px; background: #eeede7; border-left: 3px solid #111; }
.document-content pre { white-space: pre-wrap; overflow-wrap: anywhere; padding: 20px; background: #eeede7; line-height: 1.7; }

@media (max-width: 540px) {
  .contact-options { align-items: stretch; flex-direction: column; width: min(100%, 280px); }
  .document-header, .document-content { width: calc(100% - 40px); }
  .prompt { padding: 16px; }
}
