:root {
  --ink: #e8e4dc;
  --muted: rgba(232, 228, 220, 0.62);
  --void: #07080c;
  --hue: 46;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  background: var(--void);
  color: var(--ink);
  font-family: "Outfit", system-ui, sans-serif;
  overflow: hidden;
}

body {
  min-height: 100dvh;
}

#field {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

main {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6vh 6vw 7vh;
  text-align: center;
  pointer-events: none;
}

.mark {
  letter-spacing: 0.62em;
  font-weight: 300;
  font-size: 0.78rem;
  text-indent: 0.62em;
  color: var(--muted);
  margin-bottom: 1.6rem;
}

.scene {
  position: relative;
  width: min(78vw, 560px);
  height: min(62vw, 440px);
  margin-bottom: 2.2rem;
  --hue: 46;
}

.orb {
  position: absolute;
  left: 50%;
  top: 46%;
  width: min(28vw, 196px);
  height: min(28vw, 196px);
  transform: translate(-50%, -50%);
  animation: drift 18s ease-in-out infinite;
}

.sphere {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, hsl(52, 100%, 78%) 0%, transparent 22%),
    radial-gradient(circle at 70% 76%, hsl(28, 85%, 22%) 0%, transparent 48%),
    radial-gradient(circle at 42% 40%,
      hsl(50, 100%, 62%) 0%,
      hsl(42, 92%, 46%) 40%,
      hsl(32, 78%, 26%) 100%);
  box-shadow:
    inset -18px -22px 40px hsla(var(--hue), 80%, 8%, 0.55),
    inset 10px 12px 24px hsla(var(--hue), 100%, 82%, 0.35),
    0 0 80px hsla(var(--hue), 100%, 52%, 0.38);
  animation: breathe 7.4s ease-in-out infinite;
}

.sphere::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 30%, rgba(255, 255, 255, 0.42), transparent 26%);
  mix-blend-mode: screen;
}

.halo {
  position: absolute;
  inset: -18%;
  border-radius: 50%;
  background: radial-gradient(circle, hsla(var(--hue), 100%, 55%, 0.3), transparent 68%);
  filter: blur(10px);
  animation: breathe 7.4s ease-in-out infinite reverse;
}

.ring {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  border: 1px solid rgba(232, 228, 220, 0.18);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.r1 {
  width: 138%;
  height: 138%;
  animation: spin 48s linear infinite;
  border-color: hsla(var(--hue), 100%, 64%, 0.34);
}

.r2 {
  width: 176%;
  height: 48%;
  border-color: hsla(var(--hue), 100%, 64%, 0.4);
  animation: spin 36s linear infinite reverse;
}

.r3 {
  width: 48%;
  height: 186%;
  border-color: hsla(var(--hue), 100%, 64%, 0.28);
  animation: spin 52s linear infinite;
}

.creatures {
  list-style: none;
  position: absolute;
  inset: 0;
}

.creature {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 92px;
  height: 104px;
  margin-left: -46px;
  margin-top: -42px;
  transform: rotate(var(--a)) translateY(-176px) rotate(calc(var(--a) * -1));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.creature svg {
  width: 76px;
  height: 76px;
  overflow: visible;
}

.creature path,
.creature .form {
  fill: rgba(232, 228, 220, 0.86);
  stroke: none;
}

.creature .eye {
  fill: #12140f;
  stroke: none;
}

.creature .halo-set {
  transform-box: fill-box;
  transform-origin: center;
  animation: halo 6.9s ease-in-out infinite;
  animation-delay: var(--d);
}

.creature .halo-deep,
.creature .halo-mid,
.creature .halo-rim {
  fill: none;
  stroke-linecap: round;
}

.creature .halo-deep {
  fill: hsla(34, 85%, 36%, 0);
  stroke: hsla(32, 78%, 34%, 0);
  stroke-width: 5;
}

.creature .halo-mid {
  stroke: hsl(44, 96%, 58%);
  stroke-width: 2.4;
}

.creature .halo-rim {
  stroke: hsl(52, 100%, 76%);
  stroke-width: 1.15;
}

.creature .name {
  order: 2;
  font-size: 0.62rem;
  letter-spacing: 0.28em;
  text-indent: 0.28em;
  text-transform: lowercase;
  color: rgba(232, 228, 220, 0.42);
  font-weight: 300;
}

.line {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 400;
  font-size: clamp(1.28rem, 2.4vw, 1.92rem);
  line-height: 1.45;
  max-width: 42rem;
  letter-spacing: 0.01em;
}

.line a,
.domain a {
  pointer-events: auto;
  color: #fff;
  text-decoration: none;
}

.line a:hover,
.line a:focus-visible,
.domain a:hover,
.domain a:focus-visible {
  color: hsl(var(--hue), 80%, 72%);
}

.domain {
  margin-top: 1.8rem;
  font-size: 0.78rem;
  letter-spacing: 0.38em;
  text-indent: 0.38em;
  color: var(--muted);
  font-weight: 300;
}

@keyframes breathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.035); }
}

@keyframes drift {
  0%, 100% { transform: translate(-50%, -50%); }
  50% { transform: translate(-50%, calc(-50% - 8px)); }
}

@keyframes spin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes halo {
  0%, 18%, 100% {
    opacity: 0;
    transform: scale(0.78);
    filter: none;
  }
  7% {
    opacity: 1;
    transform: scale(1);
    filter: drop-shadow(0 0 5px hsla(42, 100%, 58%, 0.85)) drop-shadow(0 0 14px hsla(32, 90%, 40%, 0.7));
  }
  11% {
    opacity: 0.72;
    transform: scale(1.14);
    filter: drop-shadow(0 0 8px hsla(48, 100%, 64%, 0.55));
  }
}

.creature .halo-set .halo-deep {
  animation: halo-deep 6.9s ease-in-out infinite;
  animation-delay: var(--d);
  transform-box: fill-box;
  transform-origin: center;
}

@keyframes halo-deep {
  0%, 18%, 100% { fill: hsla(30, 80%, 32%, 0); stroke: hsla(28, 70%, 28%, 0); }
  7% { fill: hsla(36, 88%, 42%, 0.42); stroke: hsla(30, 85%, 36%, 0.9); }
  11% { fill: hsla(42, 90%, 50%, 0.16); stroke: hsla(38, 80%, 40%, 0.45); }
}

@media (max-width: 720px) {
  .scene {
    width: min(92vw, 420px);
    height: 340px;
    margin-bottom: 1.6rem;
  }
  .orb {
    width: 148px;
    height: 148px;
  }
  .creature {
    width: 74px;
    transform: rotate(var(--a)) translateY(-132px) rotate(calc(var(--a) * -1));
  }
  .creature svg {
    width: 52px;
    height: 52px;
  }
  .line {
    font-size: 1.22rem;
  }
}

@media (max-height: 700px) {
  .scene {
    height: 300px;
    margin-bottom: 1rem;
  }
  .creature {
    transform: rotate(var(--a)) translateY(-124px) rotate(calc(var(--a) * -1));
  }
  .mark {
    margin-bottom: 0.8rem;
  }
}
