/* =========================================================
   آریون — مریخ از نزدیک
   نسخه استاتیک HTML/CSS/JS (بدون Node.js) — معادل کامل نسخه Next.js
   ========================================================= */

:root {
  --background: #06080d;
  --background-elevated: #0d1117;
  --foreground: #f5f3ee;
  --foreground-muted: #9a9ea8;
  --accent: #e8c77e;
  --line: #4c6ef5;
  --border: rgba(245, 243, 238, 0.1);

  --font-display: 'Lalezar', system-ui, sans-serif;
  --font-body: 'IBM Plex Sans Arabic', system-ui, sans-serif;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-body);
  font-weight: 500;
  line-height: 1.8;
  overflow-x: hidden;
  max-width: 100vw;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.4; margin: 0; }
p { margin: 0; }
ul, ol, dl { margin: 0; padding: 0; list-style: none; }
dd { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }

::selection { background: var(--accent); color: var(--background); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.text-balance { text-wrap: balance; }
.text-end { text-align: end; }

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

.container {
  max-width: 72rem; /* 6xl */
  margin-inline: auto;
  padding-inline: 1.5rem;
}
@media (min-width: 640px) { .container { padding-inline: 2.5rem; } }
@media (min-width: 1024px) { .container { padding-inline: 5rem; } }

.font-mono { font-family: var(--font-body); font-weight: 600; letter-spacing: 0.05em; }
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  color: var(--accent);
}
.eyebrow-muted { color: var(--foreground-muted); }

.heading-lg {
  margin-top: 1rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.875rem;
  color: var(--foreground);
}
@media (min-width: 640px) { .heading-lg { font-size: 2.25rem; } }

.lead {
  margin-top: 1.25rem;
  max-width: 28rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--foreground-muted);
}

.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  border-radius: 999px;
  background: var(--foreground);
  color: var(--background);
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.875rem 1.75rem;
  transition: transform 0.3s ease;
}
.btn-pill:hover { transform: scale(1.05); }

/* =========================================================
   Background decor
   ========================================================= */
.bg-decor {
  position: fixed;
  inset: 0;
  z-index: -10;
  overflow: hidden;
  background: var(--background);
  pointer-events: none;
}
.bg-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(160px);
}
.bg-blob-a {
  left: 50%;
  top: -10%;
  width: 560px;
  height: 560px;
  transform: translateX(-50%);
  background: rgba(232, 199, 126, 0.14);
}
.bg-blob-b {
  bottom: -15%;
  right: 5%;
  width: 520px;
  height: 520px;
  background: rgba(76, 110, 245, 0.16);
  filter: blur(170px);
}
.bg-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 45%, rgba(6, 8, 13, 0.85) 100%);
}
.bg-grain {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.035;
  mix-blend-mode: overlay;
}

/* =========================================================
   Navbar
   ========================================================= */
.navbar {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 1rem 0;
}
@media (min-width: 640px) { .navbar { padding: 1.25rem 1.5rem 0; } }

.navbar-inner {
  display: flex;
  width: 100%;
  max-width: 72rem;
  align-items: center;
  justify-content: space-between;
  border-radius: 999px;
  border: 1px solid var(--border);
  padding: 0.75rem 1.25rem;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: rgba(6, 8, 13, 0.3);
  transition: background-color 0.5s ease;
}
.navbar-inner.is-scrolled { background: rgba(6, 8, 13, 0.7); }
@media (min-width: 640px) { .navbar-inner { padding: 0.75rem 1.75rem; } }

.brand {
  font-family: var(--font-display);
  font-size: 1.125rem;
  letter-spacing: -0.01em;
  color: var(--foreground);
}
.brand-sub {
  margin-inline-start: 0.5rem;
  display: none;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  color: var(--foreground-muted);
}
@media (min-width: 640px) { .brand-sub { display: inline; } }

.nav-links { display: none; align-items: center; gap: 2.25rem; }
@media (min-width: 768px) { .nav-links { display: flex; } }
.nav-links a {
  position: relative;
  font-size: 0.875rem;
  color: var(--foreground-muted);
  transition: color 0.3s ease;
}
.nav-links a:hover { color: var(--foreground); }
.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  inset-inline-start: 0;
  height: 1px;
  width: 0;
  background: var(--accent);
  transition: width 0.3s ease;
}
.nav-links a:hover::after { width: 100%; }

.navbar-actions { display: flex; align-items: center; gap: 0.75rem; }
.nav-cta { display: none; padding: 0.5rem 1.25rem; }
@media (min-width: 640px) { .nav-cta { display: inline-flex; } }

.menu-btn {
  display: flex;
  height: 2.25rem;
  width: 2.25rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--foreground);
}
@media (min-width: 768px) { .menu-btn { display: none; } }
.menu-icon { position: relative; display: block; height: 0.75rem; width: 1rem; }
.menu-bar {
  position: absolute;
  inset-inline: 0;
  height: 1px;
  background: currentColor;
  transition: transform 0.3s ease;
}
.menu-bar-top { top: 0; }
.menu-bar-bottom { bottom: 0; }
.menu-btn.is-open .menu-bar-top { transform: translateY(6px) rotate(45deg); }
.menu-btn.is-open .menu-bar-bottom { transform: translateY(-6px) rotate(-45deg); }

.mobile-nav {
  position: absolute;
  left: 1rem;
  right: 1rem;
  top: calc(100% + 0.5rem);
  border-radius: 1.5rem;
  border: 1px solid var(--border);
  background: rgba(6, 8, 13, 0.95);
  padding: 1.5rem;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
@media (min-width: 768px) { .mobile-nav { display: none !important; } }
.mobile-nav-links { display: flex; flex-direction: column; gap: 1.25rem; }
.mobile-nav-links a {
  font-size: 1rem;
  color: var(--foreground-muted);
  transition: color 0.3s ease;
}
.mobile-nav-links a:hover { color: var(--foreground); }
.mobile-cta { margin-top: 0.5rem; justify-content: center; padding: 0.625rem 1.25rem; }

/* =========================================================
   Canvas scene (pinned scroll sequence)
   ========================================================= */
.scene {
  position: relative;
  height: 100dvh;
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--background);
}
.loader-content { display: flex; flex-direction: column; align-items: center; gap: 1.5rem; padding-inline: 1.5rem; }
.loader-brand { font-family: var(--font-body); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.3em; color: var(--foreground-muted); }
.loader-track { position: relative; height: 1px; width: 14rem; overflow: hidden; background: var(--border); }
@media (min-width: 640px) { .loader-track { width: 18rem; } }
.loader-fill {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  width: 0%;
  background: var(--accent);
  transition: width 0.15s ease-out;
}
.loader-pct { font-family: var(--font-body); font-weight: 600; font-size: 0.875rem; font-variant-numeric: tabular-nums; color: var(--foreground-muted); }

.scene-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  height: 100%;
  width: 100%;
}

.scene-scrim {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
  background: linear-gradient(to top, rgba(6,8,13,0.9), rgba(6,8,13,0.1) 60%, transparent);
}

.scene-text-wrap {
  position: fixed;
  inset-inline: 1rem;
  bottom: 6rem;
  z-index: 20;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
@media (min-width: 640px) {
  .scene-text-wrap { inset-inline: auto; inset-inline-end: 1.5rem; bottom: 2.5rem; justify-content: flex-end; }
}
@media (min-width: 768px) { .scene-text-wrap { inset-inline-end: 2.5rem; bottom: 3.5rem; } }
@media (min-width: 1024px) { .scene-text-wrap { inset-inline-end: 4rem; bottom: 4rem; } }

.scene-text-card {
  width: 100%;
  max-width: 24rem;
  border-radius: 1.75rem;
  border: 1px solid var(--border);
  background: rgba(13, 17, 23, 0.5);
  padding: 1.25rem;
  text-align: center;
  box-shadow: 0 25px 70px -20px rgba(0,0,0,0.7);
  backdrop-filter: blur(40px);
  -webkit-backdrop-filter: blur(40px);
}
@media (min-width: 640px) { .scene-text-card { max-width: 28rem; padding: 1.75rem; text-align: end; } }
@media (min-width: 768px) { .scene-text-card { max-width: 32rem; padding: 2rem; } }
@media (min-width: 1024px) { .scene-text-card { max-width: 36rem; } }

.scene-aperture { font-family: var(--font-body); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.3em; color: var(--accent); }
.scene-title {
  margin-top: 0.75rem;
  white-space: pre-line;
  font-family: var(--font-display);
  font-size: 1.875rem;
  line-height: 1.3;
  color: var(--foreground);
}
@media (min-width: 640px) { .scene-title { margin-top: 1rem; font-size: 2.25rem; } }
@media (min-width: 1024px) { .scene-title { font-size: 3rem; } }
.scene-subtitle {
  margin-top: 1rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--foreground-muted);
}
@media (min-width: 640px) { .scene-subtitle { margin-top: 1.25rem; font-size: 1rem; } }
@media (min-width: 1024px) { .scene-subtitle { font-size: 1.125rem; } }

.progress-rail {
  position: fixed;
  inset-block: 0;
  inset-inline-end: 1.25rem;
  z-index: 30;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  pointer-events: none;
}
@media (min-width: 640px) { .progress-rail { display: flex; inset-inline-end: 2rem; } }
.rail-line { position: relative; height: 16rem; width: 1px; background: var(--border); }
.rail-dot {
  position: absolute;
  left: 50%;
  top: 0%;
  height: 0.75rem;
  width: 0.75rem;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px 2px rgba(232,199,126,0.55);
}
.rail-tick {
  position: absolute;
  left: 50%;
  height: 1px;
  width: 0.625rem;
  transform: translateX(-50%);
  background: rgba(154, 158, 168, 0.6);
}

.scroll-cue {
  position: fixed;
  inset-inline: 0;
  top: calc(100dvh - 4.5rem);
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--foreground-muted);
  pointer-events: none;
  transition: opacity 0.5s ease;
}
.scroll-cue-label { font-family: var(--font-body); font-weight: 600; font-size: 0.65rem; letter-spacing: 0.3em; }
.scroll-cue-line {
  height: 2rem;
  width: 1px;
  background: rgba(154,158,168,0.6);
  animation: cue-pulse 2s ease-in-out infinite;
}
@keyframes cue-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* =========================================================
   Generic sections
   ========================================================= */
.section { position: relative; padding: 7rem 0; }
.section-border { border-top: 1px solid var(--border); }
@media (min-width: 640px) { .section { padding-block: 7rem; } }

.section-intro { max-width: 36rem; }

/* card grids */
.grid-cards {
  margin-top: 4rem;
  display: grid;
  gap: 1px;
  overflow: hidden;
  border-radius: 1.5rem;
  border: 1px solid var(--border);
  background: var(--border);
}
@media (min-width: 640px) { .grid-cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-cards { grid-template-columns: repeat(4, 1fr); } }

.card {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  background: var(--background-elevated);
  padding: 1.75rem;
}
.card-featured { box-shadow: inset 0 0 0 1px rgba(232,199,126,0.4); }
.card-top { display: flex; align-items: center; justify-content: space-between; }
.card-order { font-family: var(--font-body); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.2em; color: var(--foreground-muted); }
.card-badge { font-family: var(--font-body); font-weight: 600; font-size: 0.6rem; letter-spacing: 0.2em; color: var(--accent); }
.planet-dot {
  height: 3.5rem;
  width: 3.5rem;
  border-radius: 50%;
  box-shadow: inset -6px -6px 14px rgba(0,0,0,0.45);
}
.card-title { font-family: var(--font-display); font-size: 1.25rem; color: var(--foreground); }
.spec-list { margin-top: 0.25rem; display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.75rem; color: var(--foreground-muted); }
.spec-list > div { display: flex; justify-content: space-between; gap: 0.75rem; }
.spec-list dd { font-family: var(--font-body); font-weight: 600; color: var(--foreground); }

/* fast facts */
.facts-grid .fact-card { background: var(--background-elevated); padding: 1.75rem; display: flex; flex-direction: column; gap: 1rem; }
.fact-label { font-family: var(--font-body); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.2em; color: var(--foreground-muted); }
.fact-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.fact-tag { display: block; font-size: 0.65rem; letter-spacing: 0.15em; color: var(--foreground-muted); }
.fact-tag-accent { color: var(--accent); }
.fact-value { display: block; font-family: var(--font-display); font-size: 1.125rem; color: var(--foreground); }

/* mission reel */
.reel-frame {
  position: relative;
  margin-top: 3rem;
  height: 80vh;
  overflow: hidden;
  border-radius: 1.5rem;
  border: 1px solid var(--border);
}
.reel-video { position: absolute; inset: 0; height: 100%; width: 100%; object-fit: cover; }
.reel-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.35); }
.reel-caption-wrap { position: relative; z-index: 10; display: flex; height: 100%; align-items: flex-end; padding: 1rem; }
@media (min-width: 640px) { .reel-caption-wrap { padding: 2rem; } }
@media (min-width: 1024px) { .reel-caption-wrap { padding: 2.5rem; } }
.reel-caption {
  max-width: 36rem;
  border-radius: 1.75rem;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(13,17,23,0.5);
  padding: 1.25rem;
  box-shadow: 0 25px 70px -20px rgba(0,0,0,0.7);
  backdrop-filter: blur(40px);
  -webkit-backdrop-filter: blur(40px);
}
@media (min-width: 640px) { .reel-caption { padding: 1.75rem; } }
@media (min-width: 1024px) { .reel-caption { padding: 2rem; } }
.reel-caption-title { margin-top: 0.75rem; font-family: var(--font-display); font-size: 1.5rem; color: #fff; }
@media (min-width: 640px) { .reel-caption-title { margin-top: 1rem; font-size: 1.875rem; } }
@media (min-width: 1024px) { .reel-caption-title { font-size: 2.25rem; } }
.reel-caption-body { margin-top: 0.75rem; font-family: var(--font-body); font-weight: 600; font-size: 0.875rem; color: rgba(255,255,255,0.8); }
@media (min-width: 640px) { .reel-caption-body { margin-top: 1rem; } }
.reel-footnote {
  margin: 1.25rem auto 0;
  max-width: 42rem;
  text-align: center;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--foreground-muted);
}

/* details */
.details-grid { display: grid; gap: 4rem; }
@media (min-width: 1024px) { .details-grid { grid-template-columns: 1.3fr 1fr; gap: 6rem; } }

.process-list { margin-top: 3.5rem; display: flex; flex-direction: column; gap: 2.5rem; }
.process-item { display: flex; gap: 1.5rem; }
.process-index { font-family: var(--font-display); font-size: 1.5rem; color: rgba(232,199,126,0.8); }
.process-title { font-family: var(--font-display); font-size: 1.125rem; color: var(--foreground); }
.process-body { margin-top: 0.5rem; max-width: 28rem; font-size: 0.875rem; line-height: 1.7; color: var(--foreground-muted); }

.specs-card {
  height: fit-content;
  border-radius: 1.5rem;
  border: 1px solid var(--border);
  background: var(--background-elevated);
  padding: 2rem;
}
.specs-dl { margin-top: 1.5rem; }
.specs-dl > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1rem;
  border-bottom: 1px solid var(--border);
}
.specs-dl > div:last-child { border-bottom: none; }
.specs-dl dt { font-size: 0.875rem; color: var(--foreground-muted); }
.specs-dl dd { font-family: var(--font-body); font-weight: 600; font-size: 0.875rem; color: var(--foreground); text-align: end; }

/* CTA */
.cta-container {
  display: flex;
  max-width: 56rem;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  border-radius: 2.5rem;
  border: 1px solid var(--border);
  background: var(--background-elevated);
  padding: 4rem 2rem;
  text-align: center;
}
@media (min-width: 640px) { .cta-container { padding-inline: 4rem; } }
.cta-heading { font-family: var(--font-display); font-size: 1.875rem; line-height: 1.3; color: var(--foreground); }
@media (min-width: 640px) { .cta-heading { font-size: 3rem; } }
.cta-sub { max-width: 28rem; font-family: var(--font-body); font-weight: 600; font-size: 1rem; color: var(--foreground-muted); }
@media (min-width: 640px) { .cta-sub { font-size: 1.125rem; } }
.cta-btn { padding: 0.875rem 1.75rem; }
.cta-arrow { transition: transform 0.3s ease; }
.cta-btn:hover .cta-arrow { transform: translateX(-4px); }

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 2.5rem 0; }
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
@media (min-width: 640px) { .footer-inner { flex-direction: row; } }
.footer-brand { font-family: var(--font-display); font-size: 0.875rem; color: var(--foreground-muted); }
.footer-nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.5rem; }
.footer-nav a { font-size: 0.75rem; color: var(--foreground-muted); transition: color 0.3s ease; }
.footer-nav a:hover { color: var(--foreground); }
.footer-note { font-family: var(--font-body); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.05em; color: var(--foreground-muted); }

/* Reveal-on-scroll: initial hidden state is applied by JS (GSAP) itself,
   exactly like the original React version — so if JS fails to load for
   any reason, this content simply displays normally instead of staying
   invisible. */
