:root {
  --bg-0: #02060d;
  --bg-1: #07111f;
  --bg-2: #0f2139;
  --text: #f2f7fc;
  --muted: rgba(242, 247, 252, 0.66);
  --line: rgba(117, 196, 244, 0.14);
  --accent: rgba(220, 200, 151, 0.74);
  --border: rgba(117, 196, 244, 0.16);
  --panel: rgba(5, 12, 21, 0.56);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow: hidden;
  color: var(--text);
  font-family: "Space Grotesk", sans-serif;
  background:
    radial-gradient(circle at 18% 18%, rgba(117, 196, 244, 0.14), transparent 24%),
    radial-gradient(circle at 84% 18%, rgba(220, 200, 151, 0.1), transparent 22%),
    radial-gradient(circle at 50% 48%, rgba(24, 54, 92, 0.42), transparent 36%),
    linear-gradient(135deg, var(--bg-0) 0%, #050b13 42%, var(--bg-1) 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: -18%;
  background:
    conic-gradient(
      from 180deg at 50% 50%,
      rgba(117, 196, 244, 0.06),
      rgba(2, 6, 13, 0),
      rgba(220, 200, 151, 0.05),
      rgba(2, 6, 13, 0),
      rgba(117, 196, 244, 0.06)
    );
  filter: blur(90px);
  opacity: 0.55;
  animation: spin 24s linear infinite;
  pointer-events: none;
}

.page-shell {
  position: relative;
  min-height: 100vh;
  isolation: isolate;
}

.field-canvas,
.grid-overlay,
.vignette,
.formula-layer {
  position: absolute;
  inset: 0;
}

.field-canvas {
  width: 100%;
  height: 100%;
}

.grid-overlay {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(117, 196, 244, 0.03) 1px, transparent 1px);
  background-size: clamp(34px, 4vw, 56px) clamp(34px, 4vw, 56px);
  opacity: 0.12;
  mix-blend-mode: screen;
  -webkit-mask-image: radial-gradient(circle at center, black 34%, transparent 94%);
  mask-image: radial-gradient(circle at center, black 34%, transparent 94%);
  pointer-events: none;
}

.vignette {
  background:
    radial-gradient(circle at center, transparent 32%, rgba(0, 0, 0, 0.18) 66%, rgba(0, 0, 0, 0.74) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.3), transparent 35%, transparent 68%, rgba(0, 0, 0, 0.42));
  pointer-events: none;
}

.formula-layer {
  overflow: hidden;
  font-family: "IBM Plex Mono", monospace;
  font-size: clamp(0.68rem, 0.75vw, 0.84rem);
  letter-spacing: 0.08em;
  color: rgba(194, 223, 245, 0.26);
  text-transform: uppercase;
}

.formula-layer span {
  position: absolute;
  left: var(--x);
  top: var(--y);
  transform: translate(-50%, -50%);
  white-space: nowrap;
  animation: drift var(--duration) ease-in-out infinite alternate;
  animation-delay: var(--delay);
}

.hero {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.hero-halo {
  position: absolute;
  width: min(78vw, 680px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(
      circle,
      rgba(117, 196, 244, 0.24) 0%,
      rgba(117, 196, 244, 0.12) 24%,
      rgba(220, 200, 151, 0.08) 38%,
      rgba(2, 6, 13, 0) 72%
    );
  filter: blur(18px);
  opacity: 0.9;
  animation: pulse 7s ease-in-out infinite;
  pointer-events: none;
}

.hero-panel {
  position: relative;
  z-index: 1;
  width: min(100%, 34rem);
  padding: clamp(2rem, 4vw, 3rem);
  border-radius: 2rem;
  text-align: center;
  background: linear-gradient(180deg, rgba(10, 20, 35, 0.52), rgba(5, 10, 18, 0.7));
  border: 1px solid var(--border);
  box-shadow:
    0 24px 80px rgba(0, 0, 0, 0.44),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(16px);
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.04);
  pointer-events: none;
}

.logo-wrap {
  position: relative;
  width: clamp(118px, 18vw, 152px);
  margin: 0 auto 1.5rem;
}

.logo-wrap::after {
  content: "";
  position: absolute;
  inset: -16%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(117, 196, 244, 0.18), transparent 68%);
  filter: blur(14px);
  z-index: -1;
}

.logo-wrap svg {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 20px rgba(117, 196, 244, 0.26));
}

.eyebrow {
  margin: 0 0 0.65rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.34em;
  color: var(--accent);
}

h1 {
  margin: 0;
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 0.94;
  letter-spacing: -0.04em;
  font-weight: 700;
}

.tagline {
  max-width: 21rem;
  margin: 0.95rem auto 0;
  font-size: clamp(0.95rem, 1.25vw, 1.08rem);
  color: var(--muted);
}

@media (max-width: 640px) {
  body::before {
    opacity: 0.38;
  }

  .formula-layer {
    font-size: 0.64rem;
  }

  .formula-layer span:nth-child(n + 7) {
    display: none;
  }

  .hero-panel {
    padding: 1.5rem;
    border-radius: 1.6rem;
  }

  .eyebrow {
    letter-spacing: 0.26em;
  }
}

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

@keyframes drift {
  from {
    transform: translate(-50%, -50%) translate3d(-12px, -8px, 0);
    opacity: 0.2;
  }

  to {
    transform: translate(-50%, -50%) translate3d(14px, 10px, 0);
    opacity: 0.42;
  }
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(0.94);
    opacity: 0.72;
  }

  50% {
    transform: scale(1.05);
    opacity: 1;
  }
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}
