/* =====================================================================
   LAIKA — Soviet constructivist poster, set in deep space (1957)
   Palette: deep cosmos · aged cream · constructivist red · gold · navy
   Type: Oswald (condensed poster headings) + Spectral (serif body)
   ===================================================================== */
:root {
  --bg: #070a14;
  --bg-2: #0d1424;
  --panel: rgba(18, 26, 45, 0.55);
  --panel-solid: #0f1830;
  --cream: #ece0c6;
  --cream-dim: #c7bda6;
  --muted: #93a0bf;
  --red: #d63b2e;
  --red-deep: #a52519;
  --gold: #e0b153;
  --navy: #21406e;
  --line: rgba(236, 224, 198, 0.16);
  --glow-red: rgba(214, 59, 46, 0.5);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(ellipse at 75% 12%, rgba(63, 42, 92, 0.5), transparent 55%),
    radial-gradient(ellipse at 15% 60%, rgba(24, 52, 92, 0.45), transparent 55%),
    radial-gradient(ellipse at 50% 120%, rgba(139, 34, 30, 0.28), transparent 55%),
    linear-gradient(var(--bg), #05070f);
  background-attachment: fixed;
  color: var(--cream);
  font-family: "Spectral", Georgia, serif;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* starfield canvas + nebula haze */
#stars { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.nebula {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 80% 15%, rgba(120, 80, 170, 0.16), transparent 40%),
    radial-gradient(circle at 12% 70%, rgba(40, 90, 160, 0.14), transparent 42%);
  mix-blend-mode: screen;
}

/* rotating Earth peeking from the bottom of the viewport */
.planet {
  position: fixed;
  left: 50%;
  bottom: -150vmin;
  width: 168vmin;
  height: 168vmin;
  transform: translateX(-50%);
  border-radius: 50%;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background: radial-gradient(circle at 40% 32%, #3f78ad 0%, #1f4d80 42%, #0c2647 78%, #071a33 100%);
  box-shadow:
    0 0 90px 14px rgba(70, 140, 210, 0.35),   /* atmosphere halo */
    inset -40px -30px 120px rgba(0, 0, 0, 0.65); /* terminator shadow */
}
/* rotating land masses (repeats seamlessly every 300px) */
.planet::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='300'%3E%3Cg fill='%233f7d4e'%3E%3Cellipse cx='120' cy='120' rx='72' ry='46'/%3E%3Cellipse cx='195' cy='175' rx='40' ry='30'/%3E%3Cellipse cx='300' cy='215' rx='58' ry='30'/%3E%3Cellipse cx='420' cy='95' rx='62' ry='40'/%3E%3Cellipse cx='475' cy='160' rx='34' ry='46'/%3E%3Cellipse cx='250' cy='90' rx='38' ry='26'/%3E%3C/g%3E%3Cg fill='%235a9a63'%3E%3Cellipse cx='130' cy='110' rx='40' ry='24'/%3E%3Cellipse cx='425' cy='90' rx='34' ry='22'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-size: 300px 300px;
  opacity: 0.5;
  filter: blur(0.4px);
  animation: spin-globe 80s linear infinite;
}
@keyframes spin-globe { to { background-position-x: -300px; } }
/* specular highlight + rim light */
.planet-shade {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 24%, rgba(190, 225, 255, 0.35), transparent 40%),
    radial-gradient(circle at 50% 50%, transparent 60%, rgba(120, 190, 255, 0.18) 78%, transparent 82%);
}

/* cinematic vignette + film grain overlays */
.vignette {
  position: fixed;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 42%, transparent 48%, rgba(0, 0, 0, 0.42) 100%),
    linear-gradient(transparent 70%, rgba(0, 0, 0, 0.35));
}
.filmgrain {
  position: fixed;
  inset: -50%;
  width: 200%;
  height: 200%;
  z-index: 6;
  pointer-events: none;
  opacity: 0.07;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 0.5s steps(3) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  33% { transform: translate(-3%, 2%); }
  66% { transform: translate(2%, -2%); }
  100% { transform: translate(0, 0); }
}

main, .nav, footer { position: relative; z-index: 1; }

h1, h2, h3, .brand, .badge, .year, .num, .label, .nav nav a, .cta, .panel-no {
  font-family: "Oswald", "Arial Narrow", sans-serif;
}

/* ---------- NAV ---------- */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem clamp(1rem, 5vw, 3.5rem);
  background: rgba(7, 10, 20, 0.72);
  backdrop-filter: blur(10px);
  color: var(--cream);
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 2px solid var(--red);
}
.brand {
  color: var(--cream);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.brand .star { color: var(--red); text-shadow: 0 0 10px var(--glow-red); }
.brand .cyr { color: var(--gold); }
.nav nav { display: flex; gap: clamp(0.9rem, 2.5vw, 2.2rem); flex-wrap: wrap; }
.nav nav a {
  color: var(--cream);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.82rem;
  opacity: 0.78;
  transition: color 0.2s, opacity 0.2s;
}
.nav nav a:hover { color: var(--gold); opacity: 1; }
.nav nav a.nav-token {
  color: var(--gold);
  opacity: 1;
  border: 1px solid var(--gold);
  padding: 0.22em 0.6em;
  font-weight: 600;
}
.nav nav a.nav-token:hover { background: var(--gold); color: var(--bg); }

/* ---------- TOKEN ---------- */
.token { text-align: center; }
.token-intro {
  color: var(--cream-dim);
  font-style: italic;
  font-size: clamp(1.05rem, 2.4vw, 1.3rem);
  max-width: 44ch;
  margin: -1rem auto 2.4rem;
}
.ca-box {
  max-width: 720px;
  margin: 0 auto 2rem;
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(6px);
  padding: 1.2rem 1.4rem;
}
.ca-label {
  display: block;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  color: var(--gold);
  margin-bottom: 0.7rem;
}
.ca-row {
  display: flex;
  align-items: stretch;
  gap: 0.7rem;
  flex-wrap: wrap;
}
.ca-value {
  flex: 1;
  min-width: 0;
  font-family: "Consolas", "SFMono-Regular", "Menlo", monospace;
  font-size: clamp(0.72rem, 2.1vw, 0.95rem);
  color: var(--cream);
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--line);
  padding: 0.7rem 0.9rem;
  text-align: left;
  word-break: break-all;
  line-height: 1.5;
}
.copy-btn {
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--bg);
  background: var(--gold);
  border: none;
  padding: 0 1.3rem;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}
.copy-btn:hover { background: var(--cream); }
.copy-btn:active { transform: scale(0.97); }
.copy-btn.copied { background: #4caf6a; color: #fff; }

.token-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}
.tk-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--cream);
  text-decoration: none;
  padding: 0.85rem 1.7rem;
  border: 2px solid var(--red);
  transition: all 0.2s;
}
.tk-btn:hover { background: var(--red); box-shadow: 0 0 28px var(--glow-red); }
.tk-btn.dex { border-color: var(--gold); }
.tk-btn.dex:hover { background: var(--gold); color: var(--bg); box-shadow: 0 0 28px rgba(224, 177, 83, 0.4); }
.tk-ico { font-size: 1.1em; line-height: 1; }

/* ---------- HERO ---------- */
.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: clamp(1.5rem, 5vw, 4rem);
  max-width: 1160px;
  margin: 0 auto;
  padding: clamp(2.5rem, 7vw, 6rem) clamp(1.2rem, 6vw, 4rem);
}
.kicker {
  display: inline-block;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--cream-dim);
  margin-bottom: 0.8rem;
}
.kicker .star { color: var(--red); text-shadow: 0 0 10px var(--glow-red); margin-right: 0.3em; }
.hero h1 {
  font-weight: 700;
  line-height: 0.82;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  font-size: clamp(4.5rem, 16vw, 10rem);
  color: var(--red);
  text-shadow: 0 4px 40px var(--glow-red);
  margin-bottom: 0.4rem;
}
.sub {
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 400;
  font-size: clamp(1rem, 2.6vw, 1.5rem);
  color: var(--cream);
  margin-bottom: 1.6rem;
}
.mission {
  border-left: 3px solid var(--red);
  padding-left: 1rem;
  margin-bottom: 1.8rem;
}
.mission .mdate {
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  color: var(--red);
  margin-bottom: 0.3rem;
}
.mission .mblurb {
  color: var(--cream-dim);
  max-width: 34ch;
  font-size: 1.02rem;
}
.signature {
  font-family: "Dancing Script", cursive;
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--cream);
  margin-top: 1.6rem;
  position: relative;
  display: block;
  width: fit-content;
  line-height: 1;
}
.signature::after {
  content: "";
  position: absolute;
  left: 6%;
  right: -4%;
  bottom: -0.22em;
  height: 3px;
  border-radius: 3px;
  background: var(--red);
  transform: rotate(-1.5deg);
  box-shadow: 0 0 12px var(--glow-red);
}
.cta {
  display: inline-block;
  background: transparent;
  color: var(--cream);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
  padding: 0.85rem 1.8rem;
  text-decoration: none;
  border: 2px solid var(--red);
  transition: all 0.2s;
}
.cta:hover { background: var(--red); color: var(--cream); box-shadow: 0 0 28px var(--glow-red); }

/* poster SVG */
.hero-art { position: relative; display: flex; justify-content: center; overflow: visible; }
.poster-svg {
  width: 100%;
  max-width: 420px;
  height: auto;
  filter: drop-shadow(0 0 30px rgba(33, 64, 110, 0.6));
}

/* CCCP rubber stamp */
.cccp-stamp {
  position: absolute;
  top: -22px;
  right: -6px;
  width: clamp(96px, 22%, 140px);
  height: auto;
  color: var(--cream);
  opacity: 0.42;
  transform: rotate(-14deg);
  mix-blend-mode: screen;
  pointer-events: none;
}
.cccp-stamp .arc {
  font-family: "Oswald", sans-serif;
  font-size: 10px;
  letter-spacing: 1.5px;
  fill: currentColor;
  text-transform: uppercase;
}
.cccp-stamp .mid {
  font-family: "Oswald", sans-serif;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 2px;
  fill: currentColor;
}

/* Postage stamp */
.postage {
  position: absolute;
  bottom: -24px;
  right: -10px;
  width: clamp(110px, 30%, 158px);
  height: auto;
  transform: rotate(6deg);
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.55));
  pointer-events: none;
}
.postage .p-val {
  font-family: "Oswald", sans-serif;
  font-weight: 700;
  font-size: 18px;
  fill: #e7dbbf;
  paint-order: stroke;
  stroke: #1c2331;
  stroke-width: 0.6px;
}
.postage .p-cap {
  font-family: "Oswald", sans-serif;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 1px;
  fill: #1c2331;
}
.postage .p-cap.sm { font-size: 8.5px; font-weight: 500; letter-spacing: 0.5px; }
.fill-navy { fill: #12203c; }
.fill-red { fill: var(--red); }
.fill-cream { fill: var(--cream); }
.fill-gold { fill: var(--gold); }
.stroke-red { stroke: var(--red); }
.stroke-cream { stroke: var(--cream); }
.ring { fill: none; stroke: var(--cream); stroke-width: 1.5; stroke-dasharray: 3 6; opacity: 0.5; }
.frame-ring { fill: none; stroke: var(--gold); stroke-width: 3; opacity: 0.85; }
.frame-ring.thin { stroke: var(--cream); stroke-width: 1; opacity: 0.35; }
.poster-svg .orbit-anim {
  transform-box: view-box;
  transform-origin: 200px 210px;
  animation: orbit 18s linear infinite;
}
@keyframes orbit { to { transform: rotate(360deg); } }
.poster-svg .big-rocket {
  transform-box: view-box;
  transform-origin: 200px 210px;
  animation: bob 4.5s ease-in-out infinite;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.35));
}
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

/* ---------- decorative rule ---------- */
.rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 clamp(1.2rem, 6vw, 4rem);
  color: var(--red);
}
.rule::before, .rule::after { content: ""; height: 1px; flex: 1; background: var(--line); }
.rule span { letter-spacing: 0.4em; font-size: 0.8rem; text-shadow: 0 0 12px var(--glow-red); }

/* ---------- section shared ---------- */
section { max-width: 1160px; margin: 0 auto; padding: clamp(3rem, 7vw, 5rem) clamp(1.2rem, 6vw, 4rem); }
.section-title {
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  font-size: clamp(1.8rem, 5vw, 3rem);
  margin-bottom: 2.5rem;
  display: flex;
  align-items: baseline;
  gap: 1rem;
  color: var(--cream);
}
.section-title span {
  color: var(--red);
  font-size: 0.5em;
  border: 2px solid var(--red);
  padding: 0.1em 0.4em;
}

/* ---------- STORY PANELS ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; }
.panel {
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(6px);
  padding: 1.8rem 1.6rem;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.panel:hover {
  transform: translateY(-5px);
  border-color: var(--red);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4), 0 0 24px rgba(214, 59, 46, 0.25);
}
.panel-no {
  display: block;
  color: var(--red);
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  margin-bottom: 0.6rem;
  text-shadow: 0 0 16px var(--glow-red);
}
.panel h3 {
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-weight: 600;
  font-size: 1.35rem;
  margin-bottom: 0.7rem;
  line-height: 1.1;
  color: var(--cream);
}
.panel p { font-size: 1rem; color: var(--cream-dim); }

/* ---------- TIMELINE ---------- */
.timeline { list-style: none; max-width: 760px; }
.timeline li {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 1.5rem;
  padding: 1.4rem 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
}
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.year {
  color: var(--gold);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: 0.02em;
  text-align: right;
  text-shadow: 0 0 18px rgba(224, 177, 83, 0.35);
}
.t-body h3 {
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-weight: 500;
  font-size: 1.25rem;
  margin-bottom: 0.3rem;
  color: var(--cream);
}
.t-body p { color: var(--muted); }

/* ---------- FACTS ---------- */
.facts {
  background: rgba(10, 15, 30, 0.5);
  border-block: 1px solid var(--line);
  max-width: none;
  margin: 0;
  padding-left: max(clamp(1.2rem, 6vw, 4rem), calc((100vw - 1160px) / 2));
  padding-right: max(clamp(1.2rem, 6vw, 4rem), calc((100vw - 1160px) / 2));
}
.section-title.light { color: var(--cream); }
.section-title.light span { color: var(--gold); border-color: var(--gold); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1px; background: var(--line); }
.stat { background: var(--bg-2); padding: 2rem 1.2rem; text-align: center; }
.num {
  display: block;
  color: var(--gold);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  line-height: 1;
  margin-bottom: 0.6rem;
  text-shadow: 0 0 26px rgba(224, 177, 83, 0.4);
}
.stat .label {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.78rem;
  font-weight: 300;
  color: var(--cream-dim);
}

/* ---------- TRIBUTE ---------- */
.tribute { text-align: center; }
.tribute blockquote {
  max-width: 760px;
  margin: 0 auto 1.8rem;
  font-size: clamp(1.3rem, 3.4vw, 2rem);
  font-style: italic;
  line-height: 1.4;
  color: var(--cream);
}
.tribute .mark {
  display: block;
  font-family: "Oswald", sans-serif;
  color: var(--red);
  font-size: 3rem;
  line-height: 0.5;
  margin-bottom: 0.4rem;
  text-shadow: 0 0 20px var(--glow-red);
}
.tribute cite {
  display: block;
  font-style: normal;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
  color: var(--gold);
  margin-top: 1.4rem;
}
.tribute-text { max-width: 52ch; margin: 0 auto; color: var(--muted); font-size: 1.1rem; }
.tribute-star { color: var(--red); font-size: 1.6rem; margin-top: 2rem; letter-spacing: 0.3em; text-shadow: 0 0 20px var(--glow-red); }

/* ---------- FOOTER ---------- */
footer {
  background: rgba(5, 7, 15, 0.85);
  color: var(--cream);
  text-align: center;
  padding: 2.2rem 1rem;
  border-top: 2px solid var(--red);
}
footer .star { color: var(--red); display: block; margin-bottom: 0.8rem; text-shadow: 0 0 14px var(--glow-red); }
.footer-links {
  display: flex;
  gap: 0.7rem;
  justify-content: center;
  align-items: center;
  margin-bottom: 0.9rem;
}
.footer-links a {
  color: var(--gold);
  text-decoration: none;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.82rem;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--cream); }
.footer-links .dot { color: var(--cream); opacity: 0.5; }
footer p {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-family: "Oswald", sans-serif;
  font-size: 0.8rem;
  font-weight: 300;
  opacity: 0.8;
}

/* ---------- reveal + motion ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: none; }

@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero .badge, .lead { margin-inline: auto; }
  .hero-art { order: -1; max-width: 320px; margin: 0 auto; }
  .timeline li { grid-template-columns: 90px 1fr; gap: 1rem; }
  .year { font-size: 1.2rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { transition: none; opacity: 1; transform: none; }
  .poster-svg .orbit-anim,
  .poster-svg .big-rocket { animation: none; }
  .planet::before { animation: none; }
  .filmgrain { animation: none; }
}
