:root {
  --bg-0: #050606;
  --bg-1: #0c0f0c;
  --bg-2: #131a14;
  --ink: #e4e8e1;
  --muted: #94a19a;
  --glow: #88f3c0;
  --ember: #f6b46c;
  --shadow: rgba(5, 7, 6, 0.9);
  --path: rgba(122, 92, 58, 0.38);
  --path-edge: rgba(190, 150, 100, 0.45);
  --font-display: "Cinzel Decorative", serif;
  --font-mono: "IBM Plex Mono", monospace;
  --mx: 0.5;
  --my: 0.5;
}

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

body {
  min-height: 100vh;
  font-family: var(--font-mono);
  color: var(--ink);
  background: var(--bg-0);
}

.stage {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  padding: 48px clamp(24px, 6vw, 96px) 64px;
  background:
    radial-gradient(circle at 20% 10%, rgba(140, 255, 210, 0.08), transparent 40%),
    radial-gradient(circle at 80% 20%, rgba(140, 255, 210, 0.06), transparent 45%),
    linear-gradient(180deg, var(--bg-1), var(--bg-2) 45%, #070807 100%);
}

.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 7, 6, 0.12) 0%, rgba(5, 7, 6, 0.68) 78%),
    url("assets/Forestscene.png") center 70% / 120% auto no-repeat;
  transform: translateY(0) scale(1.05);
  filter: drop-shadow(0 0 28px rgba(0, 0, 0, 0.6)) contrast(1.05) brightness(0.85);
  z-index: 1;
}

.stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 78%, var(--path), transparent 62%),
    radial-gradient(ellipse at 50% 90%, var(--path-edge), transparent 60%),
    linear-gradient(180deg, transparent 60%, rgba(40, 28, 18, 0.35) 100%);
  clip-path: polygon(47% 16%, 53% 16%, 78% 100%, 22% 100%);
  mix-blend-mode: soft-light;
  opacity: 0.78;
  z-index: 2;
}

.grain {
  position: absolute;
  inset: -100%;
  background-image: url("data:image/svg+xml,%3Csvg width='220' height='220' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23n)' opacity='0.2'/%3E%3C/svg%3E");
  opacity: 0.2;
  mix-blend-mode: soft-light;
  z-index: 3;
  animation: drift 22s linear infinite;
}

.mist {
  position: absolute;
  inset: -40% -10% 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(110, 160, 150, 0.2), transparent 40%),
    radial-gradient(circle at 70% 20%, rgba(160, 220, 200, 0.2), transparent 45%),
    radial-gradient(circle at 50% 60%, rgba(90, 120, 120, 0.25), transparent 55%);
  filter: blur(16px);
  opacity: 0.6;
  z-index: 4;
}

.mist-one {
  animation: float 26s ease-in-out infinite;
}

.mist-two {
  animation: float 32s ease-in-out infinite reverse;
  opacity: 0.45;
}

.starfield {
  position: absolute;
  top: -4vh;
  height: 50vh;
  left: 35%;
  width: 32.5%;
  z-index: 5;
  pointer-events: none;
  overflow: hidden;
  mix-blend-mode: normal;
  opacity: 1;
  filter: drop-shadow(0 0 24px rgba(235, 245, 255, 0.85));
  will-change: opacity, filter;
  contain: layout paint;
  -webkit-mask-image:
    linear-gradient(180deg, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 55%, rgba(0, 0, 0, 0) 100%),
    linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.9) 25%, rgba(0, 0, 0, 0.9) 75%, rgba(0, 0, 0, 0) 100%);
  mask-image:
    linear-gradient(180deg, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 55%, rgba(0, 0, 0, 0) 100%),
    linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.9) 25%, rgba(0, 0, 0, 0.9) 75%, rgba(0, 0, 0, 0) 100%);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
}

.firefly {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 7;
  mix-blend-mode: screen;
  will-change: transform;
}

.firefly-light {
  position: absolute;
  top: 0;
  left: 0;
  width: 200px;
  height: 200px;
  z-index: 4;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.4;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(255, 214, 120, 0.22) 0%,
    rgba(255, 214, 120, 0.12) 35%,
    rgba(255, 214, 120, 0.05) 55%,
    rgba(255, 214, 120, 0) 75%
  );
  will-change: transform, opacity;
}

.firefly-core {
  position: absolute;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 252, 214, 1) 0%, rgba(255, 228, 145, 0.85) 55%, rgba(255, 214, 120, 0) 100%);
  box-shadow: 0 0 18px rgba(255, 228, 145, 0.95), 0 0 42px rgba(255, 214, 120, 0.6);
  transform: translate(-50%, -50%);
  animation: firefly-pulse 2.8s ease-in-out infinite;
  will-change: opacity, transform;
}

.firefly-core::after {
  content: "";
  position: absolute;
  inset: -2px;
  background: radial-gradient(circle, rgba(255, 228, 145, 0.32) 0%, rgba(255, 214, 120, 0.16) 36%, rgba(255, 214, 120, 0.05) 50%, rgba(255, 214, 120, 0) 62%);
  opacity: 0.45;
  filter: blur(3px);
}

.starfield .star {
  position: absolute;
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.85) 40%, rgba(255, 255, 255, 0) 72%);
  opacity: 0.08;
  box-shadow: 0 0 var(--glow) rgba(230, 245, 255, 0.45);
  animation: twinkle-random var(--twinkle-duration) linear infinite;
  animation-delay: var(--twinkle-delay);
  transform: translateZ(0);
}

.starfield .star::after {
  content: "";
  position: absolute;
  inset: -140%;
  background: radial-gradient(circle, rgba(230, 245, 255, 0.65) 0%, rgba(230, 245, 255, 0.25) 38%, rgba(230, 245, 255, 0) 72%);
  opacity: 0.04;
  filter: blur(8px);
  animation: twinkle-glow var(--twinkle-duration) linear infinite;
  animation-delay: var(--twinkle-delay);
}

.nav {
  position: relative;
  z-index: 6;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.68rem;
  color: var(--muted);
}

.brand {
  font-weight: 500;
}

.sigil {
  border: 1px solid rgba(148, 161, 154, 0.4);
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.7rem;
}

.hero {
  position: relative;
  z-index: 6;
  max-width: 560px;
  margin-top: clamp(72px, 16vh, 160px);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.4em;
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 18px;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5.6rem);
  line-height: 1.02;
  text-shadow:
    0 12px 40px rgba(0, 0, 0, 0.5),
    0 0 18px rgba(130, 220, 180, 0.18);
  margin-bottom: 24px;
}

.lead {
  font-size: 1rem;
  line-height: 1.7;
  color: #c6d0c8;
  max-width: 440px;
  margin-bottom: 32px;
}

.cta-row {
  display: flex;
  align-items: center;
  gap: 18px;
}

.cta {
  background: linear-gradient(120deg, rgba(9, 18, 14, 0.9), rgba(25, 50, 40, 0.9));
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 14px 26px;
  border: 1px solid rgba(136, 243, 192, 0.5);
  border-radius: 999px;
  position: relative;
  cursor: default;
}

.hint {
  font-size: 0.8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.3em;
}

.runes {
  position: absolute;
  right: clamp(18px, 6vw, 80px);
  top: 36%;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.75rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(140, 200, 180, 0.6);
  z-index: 6;
}

.campfire {
  position: absolute;
  left: 50%;
  bottom: clamp(-96px, -6vh, -20px);
  transform: translateX(-50%);
  z-index: 6;
  width: clamp(180px, 26vw, 320px);
  pointer-events: none;
}

.campfire img {
  width: 100%;
  height: auto;
  display: block;
  -webkit-mask-image: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0) 12%,
    rgba(0, 0, 0, 0.2) 30%,
    rgba(0, 0, 0, 0.6) 50%,
    rgba(0, 0, 0, 1) 82%,
    rgba(0, 0, 0, 0.55) 94%,
    rgba(0, 0, 0, 0) 100%
  );
  mask-image: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0) 12%,
    rgba(0, 0, 0, 0.2) 30%,
    rgba(0, 0, 0, 0.6) 50%,
    rgba(0, 0, 0, 1) 82%,
    rgba(0, 0, 0, 0.55) 94%,
    rgba(0, 0, 0, 0) 100%
  );
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
}

.campfire-glow {
  position: absolute;
  left: 50%;
  bottom: clamp(-190px, -15vh, -70px);
  width: clamp(420px, 70vw, 900px);
  height: clamp(220px, 38vw, 520px);
  transform: translateX(-50%);
  z-index: 5;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at 50% 80%,
      rgba(255, 198, 128, 0.65) 0%,
      rgba(255, 186, 110, 0.38) 28%,
      rgba(255, 168, 94, 0.2) 48%,
      rgba(255, 150, 80, 0.08) 62%,
      rgba(0, 0, 0, 0) 80%
    ),
    radial-gradient(
      ellipse at 50% 88%,
      rgba(255, 168, 94, 0.24) 0%,
      rgba(255, 150, 80, 0.12) 35%,
      rgba(0, 0, 0, 0) 70%
    ),
    radial-gradient(
      ellipse at 50% 95%,
      rgba(255, 140, 70, 0.16) 0%,
      rgba(0, 0, 0, 0) 60%
    );
  filter: blur(42px);
  mix-blend-mode: screen;
  opacity: 0.85;
}

.light-falloff {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at 50% 84%,
      rgba(5, 7, 6, 0) 0%,
      rgba(5, 7, 6, 0.18) 32%,
      rgba(5, 7, 6, 0.42) 58%,
      rgba(5, 7, 6, 0.7) 85%,
      rgba(5, 7, 6, 0.82) 100%
    ),
    radial-gradient(
      ellipse at 50% 92%,
      rgba(5, 7, 6, 0) 0%,
      rgba(5, 7, 6, 0.25) 40%,
      rgba(5, 7, 6, 0.6) 78%,
      rgba(5, 7, 6, 0.8) 100%
    );
  mix-blend-mode: multiply;
}

.constellation {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}

.constellation span {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(136, 243, 192, 0.9), transparent 70%);
  box-shadow: 0 0 18px rgba(136, 243, 192, 0.6);
  opacity: 0.7;
}

.constellation span:nth-child(1) { top: 18%; left: 68%; }
.constellation span:nth-child(2) { top: 32%; left: 78%; }
.constellation span:nth-child(3) { top: 20%; left: 84%; }
.constellation span:nth-child(4) { top: 26%; left: 72%; }
.constellation span:nth-child(5) { top: 14%; left: 76%; }

.footer {
  position: relative;
  z-index: 6;
  margin-top: clamp(120px, 20vh, 220px);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(148, 161, 154, 0.75);
}

@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-4%, -6%, 0); }
}

@keyframes drift {
  0% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(2%, 2%, 0); }
  100% { transform: translate3d(0, 0, 0); }
}

@keyframes twinkle {
  0%, 100% {
    opacity: 0.18;
    filter: brightness(1) drop-shadow(0 0 18px rgba(220, 235, 255, 0.85));
  }
  50% {
    opacity: 1;
    filter: brightness(1.55) drop-shadow(0 0 46px rgba(230, 245, 255, 1));
  }
}

@keyframes twinkle-slow {
  0%, 100% {
    opacity: 0.25;
    filter: brightness(1) drop-shadow(0 0 16px rgba(220, 235, 255, 0.8));
  }
  50% {
    opacity: 0.9;
    filter: brightness(1.5) drop-shadow(0 0 42px rgba(230, 245, 255, 1));
  }
}

@keyframes twinkle-random {
  0%, 92%, 100% {
    opacity: 0.08;
    transform: scale(0.95);
  }
  4% {
    opacity: var(--twinkle-max);
    transform: scale(1.08);
  }
  8% {
    opacity: 0.12;
    transform: scale(0.98);
  }
}

@keyframes twinkle-glow {
  0%, 92%, 100% {
    opacity: 0.03;
    transform: scale(0.95);
  }
  4% {
    opacity: 0.7;
    transform: scale(1.2);
  }
  8% {
    opacity: 0.08;
    transform: scale(1.02);
  }
}

@keyframes firefly-pulse {
  0%, 100% {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(0.85);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@media (max-width: 860px) {
  .runes {
    display: none;
  }

  .footer {
    flex-direction: column;
    align-items: flex-start;
    letter-spacing: 0.12em;
  }
}

@media (max-width: 600px) {
  .cta-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .campfire {
    width: clamp(160px, 45vw, 240px);
  }

  .hint {
    letter-spacing: 0.18em;
  }

  .hero {
    margin-top: 96px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mist,
  .grain {
    animation: none;
  }

  .cta {
    transition: none;
  }

  .starfield .star,
  .starfield .star::after,
  .firefly {
    animation: none;
  }

  .firefly-light {
    display: none;
  }
}
