:root {
  /* === Цвета темы === */
  --bg: #000000;
  --surface: rgba(10, 15, 28, 0.72);
  --surface-strong: rgba(12, 19, 36, 0.86);
  --border: rgba(148, 163, 184, 0.16);
  --border-accent: rgba(56, 189, 248, 0.35);
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #38bdf8;
  --accent-strong: #0284c7;
  --burner: #f97316;
  --p: 0;
  --mig-p: 0;
  --earth-p: 0;

  /* === Ручки настройки Луны, МиГ-25 и Земли === */
  --sky-height: 108vh;
  --bg-blur: 3px;
  --bg-opacity: 0.84;
  --mig-start-y: 66vh;
  --mig-end-y: -6vh;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background-color: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Inter, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

/* === Космический фон: Луна сверху, МиГ-25 по центру, Земля во всю ширину в самом низу === */
.sky-stage {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(1px 1px at 14% 18%, rgba(255, 255, 255, 0.55), transparent),
    radial-gradient(1.5px 1.5px at 32% 42%, rgba(186, 230, 253, 0.4), transparent),
    radial-gradient(1px 1px at 22% 76%, rgba(255, 255, 255, 0.45), transparent),
    radial-gradient(1.5px 1.5px at 48% 15%, rgba(255, 255, 255, 0.35), transparent),
    radial-gradient(1px 1px at 78% 62%, rgba(186, 230, 253, 0.35), transparent),
    radial-gradient(1.5px 1.5px at 88% 28%, rgba(255, 255, 255, 0.3), transparent),
    #000000;
}

/* Полноширинный горизонт Земли в конце страницы */
.sky-stage::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -36vh;
  width: max(160vw, 1500px);
  height: 58vh;
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  background:
    radial-gradient(ellipse 32% 42% at 24% 26%, rgba(255, 255, 255, 0.46) 0%, transparent 70%),
    radial-gradient(ellipse 38% 36% at 64% 22%, rgba(255, 255, 255, 0.36) 0%, transparent 66%),
    radial-gradient(ellipse 26% 34% at 38% 40%, rgba(217, 154, 78, 0.42) 0%, transparent 68%),
    radial-gradient(ellipse 22% 28% at 75% 38%, rgba(202, 138, 64, 0.32) 0%, transparent 64%),
    radial-gradient(ellipse 100% 95% at 50% 100%, #071936 0%, #0c3b6e 48%, #38bdf8 82%, #bae6fd 94%, #f0f9ff 100%);
  box-shadow:
    0 -10px 55px rgba(56, 189, 248, 0.45),
    0 -3px 20px rgba(186, 230, 253, 0.65),
    inset 0 12px 30px rgba(224, 242, 254, 0.55);
  filter: blur(var(--bg-blur));
  transform: translate3d(-50%, calc((1 - var(--earth-p)) * 34vh), 0);
  opacity: calc(var(--earth-p) * var(--bg-opacity));
  will-change: transform, opacity;
}

.sky-track {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  height: var(--sky-height);
  min-height: 540px;
  max-height: 1400px;
  mix-blend-mode: lighten;
}

.art-img {
  display: block;
  height: 100%;
  width: auto;
  max-width: none;
  filter: blur(var(--bg-blur));
  user-select: none;
  will-change: transform, opacity;
}

/* Луна остаётся вверху */
.moon-layer {
  clip-path: polygon(0% 0%, 100% 0%, 100% 20.5%, 88% 20.5%, 84% 24.5%, 0% 24.5%);
  transform: translate3d(0, calc(30px - var(--p) * 3vh), 0);
  opacity: var(--bg-opacity);
}

/* МиГ-25: отрезаем узкую Землю снизу мягкой маской, чтобы не висела в середине экрана */
.mig-layer {
  clip-path: polygon(0% 24.5%, 84% 24.5%, 88% 20.5%, 100% 20.5%, 100% 100%, 0% 100%);
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 82%, transparent 89.5%);
  mask-image: linear-gradient(to bottom, #000 0%, #000 82%, transparent 89.5%);
  transform: translate3d(
    0,
    calc(var(--mig-start-y) + (var(--mig-end-y) - var(--mig-start-y)) * var(--mig-p)),
    0
  );
  opacity: min(var(--bg-opacity), calc(var(--mig-p) * 3.5));
}

.sky-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 45%, rgba(0, 0, 0, 0.24) 0%, rgba(0, 0, 0, 0.58) 100%);
}

/* === Контент поверх фона === */
.page {
  position: relative;
  z-index: 1;
}

.wrap {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(0, 0, 0, 0.65);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.brand-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav a:hover {
  color: var(--text);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px;
  background: rgba(15, 23, 42, 0.6);
  font-size: 12px;
  font-weight: 600;
}

.lang-switch a,
.lang-switch span {
  padding: 4px 10px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--muted);
}

.lang-switch .active {
  background: rgba(56, 189, 248, 0.18);
  color: var(--accent);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(90deg, #0284c7 0%, #0ea5e9 100%);
  color: #ffffff;
  box-shadow: 0 6px 24px rgba(14, 165, 233, 0.28);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(14, 165, 233, 0.42);
}

.btn-ghost {
  background: rgba(15, 23, 42, 0.65);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  border-color: var(--border-accent);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.hero {
  min-height: calc(92vh - 68px);
  display: flex;
  align-items: center;
  padding: 64px 0 84px;
}

.hero-content {
  max-width: 610px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(14, 165, 233, 0.12);
  color: #7dd3fc;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 22px;
}

h1 {
  margin: 0 0 18px;
  font-size: clamp(34px, 5.2vw, 56px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  font-weight: 800;
}

.hero-lead {
  margin: 0 0 32px;
  font-size: 17px;
  color: var(--muted);
  max-width: 540px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 40px;
}

.hero-specs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.spec-val {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
}

.spec-label {
  font-size: 13px;
  color: var(--muted);
}

section {
  padding: 80px 0;
}

.section-head {
  max-width: 600px;
  margin-bottom: 36px;
}

.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.eyebrow-burner {
  color: var(--burner);
}

h2 {
  margin: 0 0 12px;
  font-size: clamp(26px, 3.6vw, 36px);
  line-height: 1.18;
  letter-spacing: -0.015em;
}

.section-desc {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.card {
  background: var(--surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
}

.card-gaming {
  border-color: rgba(249, 115, 22, 0.35);
  background: linear-gradient(160deg, rgba(249, 115, 22, 0.08) 0%, rgba(10, 15, 28, 0.8) 55%);
}

.card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  color: var(--text);
}

.card p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

.nodes-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  max-width: 720px;
}

.node-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--surface-strong);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
}

.node-name {
  font-weight: 600;
  font-size: 15px;
}

.node-sub {
  font-size: 12px;
  color: var(--muted);
}

.pill {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #7dd3fc;
  background: rgba(14, 165, 233, 0.12);
}

.pill-game {
  border-color: rgba(249, 115, 22, 0.45);
  color: #fdba74;
  background: rgba(249, 115, 22, 0.14);
}

.cta-box {
  max-width: 720px;
  background: var(--surface-strong);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-accent);
  border-radius: 20px;
  padding: 36px 32px;
}

.cta-box p {
  margin: 0 0 24px;
  color: var(--muted);
}

footer {
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.64);
  backdrop-filter: blur(10px);
  padding: 32px 0 42px;
  margin-top: 40px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  font-size: 13px;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--accent);
}

@media (max-width: 860px) {
  :root {
    --sky-height: 96vh;
    --bg-blur: 2.5px;
    --bg-opacity: 0.72;
    --mig-start-y: 64vh;
    --mig-end-y: -2vh;
  }
  .sky-stage::before {
    bottom: -30vh;
    height: 46vh;
    width: max(200vw, 1000px);
  }
  .nav {
    display: none;
  }
  .grid-3,
  .grid-2,
  .nodes-grid {
    grid-template-columns: 1fr;
  }
  .hero-specs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }
  .cta-box {
    padding: 26px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .moon-layer {
    transform: none;
  }
  .mig-layer {
    transform: translate3d(0, 0, 0);
    opacity: 0.7;
  }
  .sky-stage::before {
    transform: translate3d(-50%, 0, 0);
    opacity: 0.7;
  }
}
