:root {
  color-scheme: dark;
  --bg: #070b20;
  --ink: #f4f6ff;
  --muted: #8993b1;
  --cobalt: #5b78ff;
  --cyan: #74dad3;
  --coral: #ff7869;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  background: var(--bg);
}

body {
  min-height: 100svh;
  color: var(--ink);
  font-family: "Manrope", sans-serif;
  overflow: hidden;
}

.scene {
  position: relative;
  min-height: 100svh;
  padding: clamp(22px, 4vw, 52px);
  isolation: isolate;
  overflow: hidden;
}

#field,
.grid {
  position: absolute;
  z-index: -1;
  inset: 0;
  width: 100%;
  height: 100%;
}

.grid {
  opacity: 0.11;
  background-image:
    linear-gradient(rgba(231, 236, 255, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(231, 236, 255, 0.12) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: linear-gradient(90deg, transparent, black 45%, black);
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  font-size: clamp(18px, 2vw, 28px);
  font-weight: 700;
  letter-spacing: -0.06em;
}

.mono {
  font-family: "IBM Plex Mono", monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
}

header .mono {
  color: var(--muted);
}

.copy {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: clamp(22px, 5vw, 72px);
  max-width: min(560px, 70vw);
  transform: translateY(-50%);
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--cyan);
}

h1 {
  margin: 0 0 24px;
  font-size: clamp(46px, 8vw, 104px);
  line-height: 0.88;
  letter-spacing: -0.075em;
}

.copy > p:last-child {
  max-width: 450px;
  margin: 0;
  color: rgba(244, 246, 255, 0.58);
  font-size: clamp(13px, 1.5vw, 18px);
  line-height: 1.55;
}

.legend {
  position: absolute;
  top: 50%;
  right: clamp(20px, 4vw, 58px);
  display: grid;
  gap: 12px;
  color: var(--muted);
  transform: translateY(-50%);
}

.legend span {
  display: flex;
  align-items: center;
}

.dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 10px;
  border-radius: 50%;
  box-shadow: 0 0 12px currentColor;
}

.cobalt { color: var(--cobalt); background: var(--cobalt); }
.cyan { color: var(--cyan); background: var(--cyan); }
.coral { color: var(--coral); background: var(--coral); }

.coordinate,
.status {
  position: absolute;
  bottom: clamp(20px, 4vw, 48px);
  color: var(--muted);
}

.coordinate {
  left: clamp(22px, 4vw, 52px);
}

.status {
  right: clamp(22px, 4vw, 52px);
}

.status i {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-right: 9px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
}

@media (max-width: 620px) {
  header .mono,
  .legend,
  .coordinate {
    display: none;
  }

  .copy {
    max-width: calc(100vw - 44px);
  }

  h1 {
    font-size: clamp(50px, 16vw, 76px);
  }
}

@media (prefers-reduced-motion: reduce) {
  #field { opacity: 0.75; }
}
