@font-face {
  font-family: "Berkeley Mono";
  src: url(/static/fonts/BerkeleyMonoVariable.woff2) format("woff2");
  font-weight: 400 700;
  font-display: block;
}

:root {
  --bg: #000000;
  --ink: #F2EFE6;
  --text2: #B5B1A6;
  --dim: #8C887C;
  --xw1: #FFD20A;
  --xw2: #FF3B2E;
  --xw3: #2EDCFF;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 18px/1.4 "Berkeley Mono", monospace;
}

.header {
  height: 72px;
  padding: 0 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

h1 {
  margin: 0;
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .16em;
}

.header time {
  color: var(--text2);
  font-size: 16px;
  letter-spacing: .06em;
}

.map {
  display: block;
  box-sizing: border-box;
  width: 100%;
  height: auto;
  padding-inline: 48px;
}

@media (min-width: 961px) {
  body:has(.map) {
    height: 100vh;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
  }

  body:has(.map) main {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    min-height: 0;
  }

  .map {
    height: 100%;
  }
}

.map text {
  paint-order: stroke;
  stroke: #000;
  stroke-width: 4px;
  stroke-linejoin: round;
}

.map-labels {
  fill: var(--dim);
  font-size: 14px;
}

.patchy { --program: var(--xw1); }
.swarm { --program: var(--xw2); }
.hivemind { --program: var(--xw3); }

.track {
  fill: none;
  stroke: var(--program);
  stroke-width: 2px;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
  transition: opacity 120ms;
}

.track.development {
  stroke-width: 1.5px;
  stroke-dasharray: 6 6;
}

.station rect {
  fill: var(--bg);
  stroke: var(--ink);
  stroke-width: 1.5px;
}

.leader {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1px;
  vector-effect: non-scaling-stroke;
}

.station text {
  fill: var(--ink);
  font-size: 14px;
  text-transform: uppercase;
}

.station .label {
  fill: var(--program);
  font-size: 14px;
  font-weight: 700;
}

.frame {
  fill: none;
  stroke: #2A2924;
  stroke-width: 1px;
  vector-effect: non-scaling-stroke;
}

.programs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: 24px 48px 32px;
}

.program {
  border-top: 2px solid var(--program);
  padding-top: 12px;
}

.program.development {
  border-top-style: dashed;
}

.meta {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  line-height: 16px;
  letter-spacing: .08em;
}

.meta strong {
  color: var(--program);
  font-weight: 700;
}

.development-status {
  color: var(--dim);
}

h2 {
  margin: 12px 0 8px;
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .06em;
  text-transform: uppercase;
}

p {
  margin: 0;
  color: var(--text2);
  font-size: 17px;
  line-height: 1.45;
}

.downloads {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.button {
  display: inline-block;
  padding: 9px 12px;
  border: 1px solid var(--program);
  background: var(--bg);
  color: var(--program);
  font: 700 15px/16px "Berkeley Mono", monospace;
  letter-spacing: .06em;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 120ms, color 120ms;
}

.button span {
  color: var(--text2);
  font-weight: 400;
  transition: color 120ms;
}

.button:hover {
  background: var(--program);
  color: var(--bg);
}

.button:hover span {
  color: var(--bg);
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

input:focus-visible {
  outline-offset: -1px;
}

body:has(.program:hover) .track {
  opacity: .25;
}

body:has(.program.patchy:hover) .track.patchy,
body:has(.program.swarm:hover) .track.swarm,
body:has(.program.hivemind:hover) .track.hivemind {
  opacity: 1;
}

.readout {
  fill: var(--ink);
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 120ms;
}

.celestial:hover .readout {
  opacity: 1;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1;
}

.backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.72);
  animation: backdrop-in 150ms ease-out;
}

.access-panel {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  box-sizing: border-box;
  width: 440px;
  max-width: calc(100% - 48px);
  padding: 28px;
  border: 1px solid var(--program);
  background: var(--bg);
  animation: panel-in 150ms ease-out;
}

.access-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.access-heading strong {
  color: var(--program);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
}

.access-heading a {
  color: var(--dim);
  font-size: 13px;
  letter-spacing: .08em;
  text-decoration: none;
  transition: color 120ms;
}

.access-heading a:hover {
  color: var(--ink);
}

.access-file {
  margin-top: 16px;
}

.access-panel form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  margin-top: 24px;
}

.access-panel label {
  grid-column: 1 / -1;
  color: var(--dim);
  font-size: 13px;
  letter-spacing: .08em;
}

.access-panel input[type="password"] {
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--bg);
  color: var(--ink);
  font: inherit;
}

.access-panel .button {
  --program: var(--ink);
}

.denied {
  margin-top: 16px;
  color: var(--xw2);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .08em;
}

@keyframes backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes panel-in {
  from { opacity: 0; transform: translate(-50%, calc(-50% + 6px)); }
  to { opacity: 1; transform: translate(-50%, -50%); }
}

.not-found {
  --program: var(--ink);
  margin: 48px;
}

.not-found h2 {
  margin: 0;
  font-size: 96px;
  letter-spacing: 0;
}

.not-found p {
  color: var(--dim);
  font-size: 14px;
  letter-spacing: .16em;
}

.not-found .button {
  margin-top: 24px;
}

@media (max-width: 960px) {
  .header,
  .map,
  .programs {
    padding-inline: 24px;
  }

  .not-found {
    margin-inline: 24px;
  }

  .map text,
  .leader {
    display: none;
  }

  h1 {
    font-size: 28px;
  }

  .header time {
    font-size: 13px;
  }

  .programs {
    grid-template-columns: 1fr;
    gap: 32px;
    padding-bottom: 32px;
  }
}
