:root {
  --gutter: clamp(24px, 4vw, 64px);
  font-family: "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  font-synthesis: none;
  color: #e9e3d9;
  color-scheme: dark;
  background: #000;
}
* {
  box-sizing: border-box;
}
html,
body {
  min-width: 280px;
  min-height: 100%;
  margin: 0;
}
body {
  overflow: hidden;
}
main {
  position: relative;
  width: 100%;
  height: 100svh;
  min-height: 320px;
  overflow: clip;
  isolation: isolate;
}
#hole {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.rendered #hole {
  opacity: 1;
}
#observer {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: none;
  width: 100%;
  height: 100%;
  padding: 0;
  touch-action: none;
  cursor: grab;
  background: none;
  border: 0;
}
.rendered #observer {
  display: block;
}
#observer[data-dragging] {
  cursor: grabbing;
}
#observer:focus {
  outline: none;
}
#observer:focus-visible:not([data-pointer-focused]) {
  outline: 1px solid #ab947566;
  outline-offset: -8px;
}
.masthead {
  position: absolute;
  inset: 0 0 auto;
  z-index: 2;
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  padding: max(24px, env(safe-area-inset-top)) var(--gutter) 64px;
  pointer-events: none;
  background: linear-gradient(#0009, transparent);
  transform: translateZ(0);
}
h1 {
  margin: 0;
  font-size: 22px;
  font-weight: 450;
  line-height: 1;
  letter-spacing: -0.025em;
}
h1 span {
  color: #ba9670;
}
.contacts {
  display: flex;
  gap: clamp(24px, 3vw, 42px);
}
.contacts a {
  display: inline-flex;
  gap: 9px;
  align-items: center;
  min-height: 44px;
  padding: 8px 0;
  font-size: 14px;
  font-weight: 400;
  color: #c9c5bd;
  text-decoration: none;
  pointer-events: auto;
  transition: color 0.2s;
}
.contacts a span {
  color: #8f877d;
  transition:
    color 0.2s,
    transform 0.2s;
}
.contacts a:hover {
  color: #fff8ee;
}
.contacts a:hover span {
  color: #e1bc8e;
  transform: translate(2px, -2px);
}
.contacts a:focus-visible {
  outline: 1px solid #d6b68b;
  outline-offset: 7px;
  border-radius: 2px;
}
.flight-info {
  position: absolute;
  inset: auto 0 0;
  z-index: 2;
  display: grid;
  visibility: hidden;
  grid-template-columns: 1fr auto;
  gap: 12px 20px;
  padding: 56px var(--gutter) max(30px, env(safe-area-inset-bottom));
  font-size: 12px;
  line-height: 1.6;
  color: #b0a89c;
  pointer-events: none;
  background: linear-gradient(transparent, #0009 48%, #000c);
  opacity: 0;
  transform: translateZ(0);
  transition: opacity 1.2s ease;
}
.rendered .flight-info {
  visibility: visible;
  opacity: 1;
}
#hint {
  display: flex;
  grid-row: 2;
  grid-column: 1 / -1;
  gap: 14px;
  align-items: center;
  margin: 0;
  font-size: 11px;
  color: #858179;
}
#hint.dismissed {
  display: none;
}
.hint-divider {
  margin: 0 14px;
  color: #665e53;
}
.hint-touch {
  display: none;
}
.scroll-mark {
  position: relative;
  flex: 0 0 13px;
  height: 20px;
  border: 1px solid #7d7468;
  border-radius: 8px;
}
.scroll-mark::after {
  position: absolute;
  top: 4px;
  left: 5px;
  width: 1px;
  height: 5px;
  content: "";
  background: #c0b5a5;
}
.flight-state {
  grid-row: 1;
  grid-column: 1;
  max-width: 540px;
}
.flight-heading {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 13px;
  color: #e3d6c4;
  letter-spacing: 0.025em;
}
.stage-mark {
  width: 4px;
  height: 4px;
  background: #c3a582;
  border-radius: 50%;
  box-shadow: 0 0 8px #bb987d44;
}
#flight-status:empty {
  display: none;
}
#flight-note {
  margin: 5px 0 0 14px;
  font-size: 11px;
  line-height: 1.65;
  color: #a19b90;
}
#flight-note:empty {
  display: none;
}
.flight-toolbar {
  display: flex;
  grid-row: 3;
  grid-column: 1 / -1;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
}
.travel-control,
.scene-control {
  display: inline-flex;
  gap: 9px;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin: 0;
  font: inherit;
  font-size: 11px;
  color: #b9b0a4;
  pointer-events: auto;
  cursor: pointer;
  background: #0006;
  border: 1px solid #b8a08830;
  border-radius: 4px;
  transition:
    color 0.2s,
    border-color 0.2s,
    background 0.2s;
}
.travel-control {
  min-width: 160px;
  padding: 9px 17px;
  color: #e0d0bb;
  border-color: #b8a08855;
}
.travel-control:hover,
.scene-control:hover {
  color: #fff0dc;
  background: #b8a08812;
  border-color: #b8a08880;
}
.travel-control:focus-visible,
.scene-control:focus-visible {
  outline: 1px solid #d6b68b;
  outline-offset: 4px;
}
.travel-control:disabled,
.scene-control:disabled {
  cursor: default;
  opacity: 0.45;
}
.scene-controls {
  display: flex;
  gap: 6px;
  align-items: center;
  min-width: 0;
  padding: 0;
  margin: 0;
  border: 0;
}
.scene-control {
  padding: 9px 11px;
  background: transparent;
  border-color: transparent;
}
.scene-control[aria-pressed="true"],
.scene-control[aria-expanded="true"] {
  color: #d6b68b;
}
.scene-control[hidden] {
  display: none;
}
.scene-control svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.15;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.travel-icon {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.pause-shape,
.travel-control[data-playing] .play-shape,
.sound-waves,
.scene-control[aria-pressed="true"] .sound-off {
  display: none;
}
.travel-control[data-playing] .pause-shape,
.scene-control[aria-pressed="true"] .sound-waves {
  display: block;
}
.journey-position {
  display: flex;
  flex-direction: column;
  grid-row: 1;
  grid-column: 2;
  gap: 6px;
  align-items: flex-end;
  padding-top: 1px;
  font-family: ui-monospace, "Cascadia Code", monospace;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: #8d857c;
}
.radius-unit {
  margin-left: 6px;
  font-family: Georgia, serif;
  font-size: 14px;
  font-style: italic;
  color: #71685f;
}
.journey-signal {
  font-size: 9px;
  color: #9daebd;
}
.journey-track {
  position: absolute;
  inset: auto var(--gutter) max(14px, env(safe-area-inset-bottom));
  height: 1px;
  background: #a78e7129;
}
#journey-progress {
  position: absolute;
  inset: 0;
  background: #b99870a6;
  transform: scaleX(0);
  transform-origin: left;
}
.horizon-tick {
  position: absolute;
  top: -2px;
  left: 39.23%;
  width: 1px;
  height: 5px;
  background: #b9987055;
}
.fallback {
  position: absolute;
  top: 49%;
  left: 50%;
  width: min(85vw, 1050px);
  height: min(42vw, 410px);
  background: radial-gradient(
    ellipse,
    #000 28%,
    #d9ad6d 30%,
    #8d532a4d 35%,
    transparent 58%
  );
  border-radius: 50%;
  filter: blur(2px);
  transform: translate(-50%, -50%);
}
.rendered .fallback {
  display: none;
}
.physics-panel {
  position: absolute;
  top: 96px;
  right: var(--gutter);
  bottom: 185px;
  z-index: 4;
  width: min(400px, calc(100vw - var(--gutter) * 2));
  padding: 23px;
  overflow-y: auto;
  overscroll-behavior: contain;
  font-size: 12px;
  line-height: 1.65;
  color: #bcbab7;
  pointer-events: auto;
  scrollbar-color: #6b6254 transparent;
  scrollbar-width: thin;
  background: #07090df0;
  border: 1px solid #b8a08830;
  border-radius: 8px;
  box-shadow: 0 12px 60px #0009;
  backdrop-filter: blur(16px);
}
.physics-panel [hidden],
.physics-panel[hidden] {
  display: none;
}
.physics-heading {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  justify-content: space-between;
}
.physics-eyebrow {
  margin: 0 0 7px;
  font-size: 10px;
  color: #a38b6d;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.physics-panel h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.4;
  color: #e8dfd2;
}
.physics-close {
  flex: 0 0 30px;
  min-height: 36px;
  padding: 0;
  font: inherit;
  font-size: 24px;
  color: #aca49b;
  cursor: pointer;
  background: transparent;
  border: 0;
}
.physics-intro {
  margin: 18px 0 22px;
}
.physics-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 13px;
  margin: 0;
}
.physics-metrics dt,
.sky-shifts dt {
  font-size: 10px;
  color: #929399;
}
.physics-metrics dd {
  margin: 4px 0 0;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  color: #dedbd4;
}
.physics-fine {
  margin: 12px 0 0;
  font-size: 11px;
  line-height: 1.6;
  color: #929399;
}
.physics-spectrum {
  padding: 16px 0;
  margin-top: 22px;
  border-top: 1px solid #b8a08825;
  border-bottom: 1px solid #b8a08825;
}
.spectral-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 36px;
  padding: 0;
  font: inherit;
  color: #e0d7c7;
  cursor: pointer;
  background: transparent;
  border: 0;
}
.switch-track {
  position: relative;
  width: 30px;
  height: 16px;
  background: #343332;
  border-radius: 12px;
}
.switch-track::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 10px;
  height: 10px;
  content: "";
  background: #a49c91;
  border-radius: 50%;
  transition: transform 0.2s;
}
.spectral-switch[aria-pressed="true"] .switch-track {
  background: #466267;
}
.spectral-switch[aria-pressed="true"] .switch-track::after {
  background: #b4e0df;
  transform: translateX(14px);
}
.spectrum-legend {
  display: flex;
  justify-content: space-between;
  padding-top: 9px;
  margin-top: 15px;
  font-size: 10px;
  color: #c2c2c2;
  background:
    linear-gradient(
      90deg,
      #ad4132,
      #df9456 25%,
      #aaaaa2 50%,
      #65b6c9 75%,
      #6984d4
    )
    top / 100% 3px no-repeat;
}
.physics-sky {
  margin: 20px 0;
}
.physics-panel h3 {
  margin: 0;
  font-size: 12px;
  font-weight: 400;
  color: #ddd5c8;
}
.sky-shifts {
  margin: 16px 0 0;
}
.sky-shifts div {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 5px 0;
}
.sky-shifts dd {
  margin: 0;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: #d0d3d7;
}
.light-clocks {
  padding: 16px 0 0;
  margin-top: 18px;
  border-top: 1px solid #b8a08825;
}
.clock-heading {
  margin: 0 0 13px;
  font-size: 11px;
  color: #d2c6b4;
}
.light-clock {
  --signal-colour: #cabca6;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px 12px;
  margin: 13px 0;
  font-size: 10px;
  color: #929399;
}
.light-clock output {
  font-variant-numeric: tabular-nums;
  color: var(--signal-colour);
}
.clock-path {
  position: relative;
  grid-column: 1 / -1;
  height: 10px;
  overflow: hidden;
  opacity: 0.9;
}
.clock-path::before {
  position: absolute;
  top: 5px;
  width: 100%;
  height: 1px;
  content: "";
  background: #c6c0b91c;
}
.clock-path i,
.clock-path b {
  position: absolute;
  top: 3px;
  left: calc(var(--signal-phase, 0) * (100% - 6px));
  width: 5px;
  height: 5px;
  background: var(--signal-colour);
  border-radius: 50%;
}
.clock-path b {
  left: calc(var(--signal-second, 0.5) * (100% - 6px));
  opacity: 0.35;
}
.light-clock[data-empty="true"] .clock-path {
  opacity: 0.12;
}
.light-clock[data-empty="true"] .clock-path i,
.light-clock[data-empty="true"] .clock-path b {
  display: none;
}
.physics-explanation details {
  padding: 14px 0;
  border-top: 1px solid #b8a08825;
}
.physics-explanation summary {
  color: #d4c9b8;
  cursor: pointer;
}
.physics-explanation p {
  margin: 12px 0 0;
  font-size: 11px;
  color: #a3a3a5;
}
.physics-sources {
  margin: 16px 0 0;
  font-size: 10px;
  color: #868489;
}
.physics-sources a {
  color: #b5aa9a;
}
@media (max-width: 600px) {
  .physics-panel {
    top: 75px;
    bottom: 210px;
    padding: 18px;
  }
  .masthead {
    gap: 20px;
    padding-top: max(20px, env(safe-area-inset-top));
  }
  h1 {
    font-size: 21px;
  }
  .contacts {
    gap: 22px;
  }
  .contacts a {
    gap: 5px;
    font-size: 12px;
  }
  .flight-info {
    padding-top: 36px;
    padding-bottom: max(26px, env(safe-area-inset-bottom));
    font-size: 12px;
  }
  .hint-divider {
    margin: 0 8px;
  }
  #hint {
    gap: 10px;
  }
  .flight-heading {
    font-size: 12px;
  }
  .scene-control span {
    display: none;
  }
  .scene-control {
    width: 34px;
    padding: 8px;
  }
  .scene-controls {
    gap: 1px;
  }
  .travel-control {
    min-width: 0;
    padding-inline: 12px;
  }
  .flight-toolbar {
    gap: 8px;
  }
  .journey-position {
    font-size: 10px;
  }
}
@media (max-width: 350px) {
  :root {
    --gutter: 16px;
  }
  .scene-control {
    width: 34px;
  }
  .flight-toolbar {
    flex-wrap: wrap;
  }
  .scene-controls {
    margin-left: auto;
  }
}
@media (max-height: 600px) {
  .physics-panel {
    top: 75px;
    bottom: 140px;
  }
}
@media (pointer: coarse) {
  .hint-desktop,
  .scroll-mark {
    display: none;
  }
  .hint-touch {
    display: inline;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
