:root {
  color-scheme: dark;
  --background: #070a0d;
  --text: #ded2bc;
  --accent: #e5bf62;
  --red: #bd3a32;
  --gold: #d9a94f;
  --matrix: #69d7a0;
  --matrix-dim: rgba(105, 215, 160, 0.34);
}

.russo-one-regular {
  font-family: "Russo One", sans-serif;
  font-weight: 400;
  font-style: normal;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100%;
}

body {
  display: grid;
  min-height: 100vh;
  margin: 0;
  overflow: hidden;
  color: var(--text);
  background: var(--background);
}

.background,
.background > * {
  position: fixed;
  pointer-events: none;
}

.background {
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 42%, rgba(153, 105, 41, 0.16), transparent 38%),
    radial-gradient(ellipse at 7% 18%, rgba(189, 58, 50, 0.16), transparent 27%),
    radial-gradient(ellipse at 20% 100%, rgba(117, 38, 32, 0.12), transparent 42%),
    var(--background);
}

.background::before {
  content: '';
  position: absolute;
  inset: -30%;
  opacity: 0.35;
  background: linear-gradient(132deg, transparent 0 42%, rgba(189, 58, 50, 0.18) 42% 43%, transparent 43% 47%, rgba(189, 58, 50, 0.09) 47% 48%, transparent 48%);
  transform: rotate(-7deg);
}

.background-stars {
  inset: 0;
  opacity: 0.45;
  background-image:
    radial-gradient(circle at 12% 24%, rgba(229, 191, 98, 0.7) 0 1px, transparent 1.5px),
    radial-gradient(circle at 76% 18%, rgba(229, 191, 98, 0.45) 0 1px, transparent 1.5px),
    radial-gradient(circle at 34% 68%, rgba(229, 191, 98, 0.35) 0 1px, transparent 1.5px),
    radial-gradient(circle at 88% 74%, rgba(229, 191, 98, 0.55) 0 1px, transparent 1.5px);
  background-size: 260px 230px, 330px 290px, 410px 370px, 520px 430px;
}

.background-matrix,
.background-grid {
  inset: 0;
  opacity: 0.5;
  mask-image: radial-gradient(ellipse 76% 78% at center, transparent 8%, rgba(0, 0, 0, 0.48) 66%, #000 100%);
}

.background-matrix {
  width: 100%;
  height: 100%;
}

.background-grid {
  opacity: 0.2;
  background-image:
    linear-gradient(rgba(105, 215, 160, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(105, 215, 160, 0.12) 1px, transparent 1px);
  background-size: 72px 72px;
}

.background-constellation {
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0.72;
}

.background-constellation svg {
  display: block;
  width: min(88vw, 78vh, 900px);
  height: auto;
  overflow: visible;
}

.constellation-base,
.constellation-halo,
.constellation-lines,
.auto-reveal-lines {
  fill: none;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.constellation-auto-reveal {
  opacity: 0;
  transition: opacity 260ms ease;
}

#constellation.is-auto-revealing .constellation-auto-reveal {
  opacity: 0.76;
}

.auto-reveal-glow,
.auto-reveal-lines {
  stroke: url(#auto-star-gradient);
}

.auto-reveal-glow {
  stroke-width: 9;
  opacity: 0.42;
  filter: blur(2px);
}

.auto-reveal-lines {
  stroke-width: 2.5;
}

.constellation-base {
  stroke: var(--gold);
  stroke-width: 1.25;
  opacity: 0.18;
}

.constellation-halo {
  stroke: var(--red);
  stroke-width: 5;
  opacity: 0;
  transition: opacity 180ms ease;
}

.constellation-lines {
  stroke: var(--gold);
  stroke-width: 1.25;
  opacity: 0;
  transition: opacity 180ms ease;
}

#constellation.is-hovering .constellation-halo {
  opacity: 0.4;
}

#constellation.is-hovering .constellation-lines {
  opacity: 0.7;
}

.constellation-node {
  filter: drop-shadow(0 0 7px rgba(229, 191, 98, 0.75));
}

.node-halo {
  fill: rgba(217, 169, 79, 0.14);
  stroke: var(--gold);
  stroke-width: 1;
}

.node-core {
  fill: #f4d27c;
}

.landing {
  position: relative;
  z-index: 1;
  display: grid;
  place-content: center;
  justify-items: center;
  width: min(100% - 40px, 760px);
  min-height: 190px;
  margin: auto;
  text-align: center;
}

h1 {
  margin: 0 0 26px;
  color: var(--accent);
  font-family: 'Russo One', sans-serif;
  font-size: clamp(3rem, 10vw, 7.5rem);
  font-weight: 500;
  letter-spacing: 0.035em;
  line-height: 0.95;
  text-shadow: 0 0 30px rgba(229, 191, 98, 0.25), 0 0 1px rgba(105, 215, 160, 0.3);
}

.message {
  max-width: 620px;
  margin: 0;
  color: rgba(222, 210, 188, 0.82);
  font-family: 'Courier New', monospace;
  font-size: clamp(1rem, 2vw, 1rem);
  letter-spacing: 0.1em;
  line-height: 1;
  transition: opacity 240ms ease, filter 240ms ease;
}

.message.is-changing {
  opacity: 0;
  filter: blur(3px);
}

@media (max-width: 540px) {
  .background-constellation svg {
    width: min(96vw, 72vh, 900px);
  }
  .landing {
    width: min(100% - 32px, 760px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

