:root {
  --bg-deep: #05060f;
  --bg-mid: #0b1026;
  --bg-glow: #14204a;
  --text: #eef1ff;
  --text-dim: #9aa3c7;
  --accent: #8fb8ff;
  --moon-light: #f6f2e8;
  --moon-dark: #cfc6b4;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem 0;
  overflow: hidden;
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(120% 90% at 78% 12%, var(--bg-glow) 0%, transparent 55%),
    radial-gradient(100% 80% at 12% 95%, #1a1240 0%, transparent 60%),
    linear-gradient(170deg, var(--bg-mid) 0%, var(--bg-deep) 70%);
}

#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ---------- Moon ---------- */
.moon {
  position: fixed;
  top: clamp(-4rem, -2vw, 2rem);
  right: clamp(-5rem, 2vw, 5rem);
  width: clamp(190px, 30vw, 380px);
  aspect-ratio: 1;
  z-index: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, var(--moon-light) 0%, #e7e0d1 45%, var(--moon-dark) 78%, #a79c88 100%);
  box-shadow:
    0 0 60px 12px rgba(200, 214, 255, 0.18),
    0 0 160px 50px rgba(120, 150, 255, 0.12),
    inset -22px -18px 50px rgba(20, 22, 45, 0.55);
  animation: drift 26s ease-in-out infinite alternate;
}

.crater {
  position: absolute;
  border-radius: 50%;
  background: rgba(150, 141, 122, 0.55);
  box-shadow: inset 2px 3px 6px rgba(75, 70, 60, 0.5);
}
.crater--1 { width: 19%; height: 19%; top: 24%; left: 22%; }
.crater--2 { width: 12%; height: 12%; top: 54%; left: 44%; }
.crater--3 { width: 26%; height: 26%; top: 60%; left: 14%; opacity: .7; }
.crater--4 { width: 9%;  height: 9%;  top: 34%; left: 61%; opacity: .75; }

/* ---------- Orbit ---------- */
.orbit {
  position: fixed;
  top: 50%;
  left: 50%;
  width: min(120vmin, 900px);
  aspect-ratio: 1;
  translate: -50% -50%;
  z-index: 1;
  border: 1px solid rgba(143, 184, 255, 0.12);
  border-radius: 50%;
  animation: spin 40s linear infinite;
}

.orbit__dot {
  position: absolute;
  top: -4px;
  left: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px 3px rgba(143, 184, 255, 0.7);
}

/* ---------- Content ---------- */
.stage {
  position: relative;
  z-index: 2;
  max-width: 44rem;
  margin: auto;
  text-align: center;
}

.eyebrow {
  margin: 0 0 1.4rem;
  font-size: clamp(.7rem, 1.6vw, .82rem);
  font-weight: 600;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--accent);
}

.title {
  margin: 0;
  font-size: clamp(2.1rem, 7vw, 4.1rem);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.015em;
  /* keeps the headline legible if it crosses the moon on mid-size screens */
  text-shadow: 0 2px 24px rgba(5, 6, 15, 0.75);
}

.title__line { display: block; }

.title__line--accent {
  font-weight: 600;
  background: linear-gradient(100deg, #ffffff 10%, var(--accent) 55%, #c4a8ff 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  margin: 1.6rem auto 0;
  max-width: 33rem;
  font-size: clamp(.98rem, 2.1vw, 1.12rem);
  line-height: 1.7;
  color: var(--text-dim);
}

.status {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  margin: 2.2rem 0 0;
  padding: .5rem 1.1rem;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-dim);
  background: rgba(143, 184, 255, 0.06);
  border: 1px solid rgba(143, 184, 255, 0.18);
  border-radius: 999px;
}

.status__pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6ee7a8;
  box-shadow: 0 0 10px 2px rgba(110, 231, 168, .6);
  animation: pulse 2.4s ease-in-out infinite;
}

.backlink {
  display: inline-block;
  margin-top: 2rem;
  font-size: .95rem;
  letter-spacing: .04em;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid rgba(238, 241, 255, 0.28);
  padding-bottom: 2px;
  transition: color .25s ease, border-color .25s ease;
}

.backlink:hover,
.backlink:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
}

.footer {
  position: relative;
  z-index: 2;
  padding: 2rem 0 1.6rem;
  font-size: .78rem;
  color: rgba(154, 163, 199, 0.65);
  text-align: center;
}

.footer p { margin: 0; }

/* ---------- Animations ---------- */
@keyframes drift {
  from { transform: translateY(0) rotate(0deg); }
  to   { transform: translateY(18px) rotate(4deg); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: .45; transform: scale(.8); }
}

@media (prefers-reduced-motion: reduce) {
  .moon, .orbit, .status__pulse { animation: none; }
}
