/*
 * Freedom UTM — публичный лендинг (СПЕК A). Направление 2 «Горизонт операций».
 * Single-theme drenched-тёмный. Никакого glassmorphism/backdrop-filter,
 * никакого gradient-текста, никаких eyebrow/нумерации секций.
 */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--canvas);
  scroll-behavior: auto; /* скролл не управляет камерой/анимациями — без smooth-scroll трюков */
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  margin: 0;
  color: var(--text);
}

p {
  margin: 0;
}

a {
  color: inherit;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -48px;
  left: 1rem;
  background: var(--surface);
  color: var(--text);
  padding: 0.75rem 1rem;
  border: 1px solid var(--hairline);
  z-index: 100;
  transition: top 150ms ease;
}

.skip-link:focus {
  top: 1rem;
}

:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}

/* ---------------------------------------------------------------------- */
/* Кнопки — solid amber (primary) / outline на --muted (secondary)        */
/* ---------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.85rem 1.5rem;
  border-radius: 4px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
  white-space: nowrap;
}

.btn--primary {
  background: var(--amber);
  color: var(--canvas);
}

.btn--primary:hover {
  background: var(--amber-hover);
}

.btn--outline {
  background: transparent;
  border-color: var(--muted);
  color: var(--text);
}

.btn--outline:hover {
  border-color: var(--amber);
  color: var(--amber);
}

.btn--small {
  padding: 0.55rem 1.1rem;
  font-size: 0.85rem;
}

.btn--large {
  padding: 1.05rem 2rem;
  font-size: 1.05rem;
}

/* ---------------------------------------------------------------------- */
/* Шапка — fixed, --surface solid, hairline снизу, БЕЗ blur               */
/* ---------------------------------------------------------------------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--hairline);
}

.site-header__inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  color: var(--text);
}

/* ---------------------------------------------------------------------- */
/* Hero — текст на сплошной верхней части канвы, сцена в нижней трети     */
/* ---------------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding-top: 5.5rem;
  overflow: hidden;
}

.hero__content {
  position: relative;
  z-index: 2;
  max-width: var(--container-max);
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 3rem;
  flex: 1 0 66%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero__title {
  font-weight: 750;
  letter-spacing: 0.005em;
  font-size: clamp(2.5rem, 5.4vw, 4.3rem);
  line-height: 1.08;
  text-wrap: balance;
  max-width: 20ch;
}

.hero__line {
  display: block;
  opacity: 0;
  transform: translateY(0.4em);
  animation: line-in 640ms var(--ease-descent) forwards;
  animation-delay: calc(var(--line-index, 0) * 60ms + 120ms);
}

@keyframes line-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__subtitle {
  margin-top: 1.5rem;
  max-width: var(--measure);
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.6;
}

.hero__actions {
  margin-top: 2.25rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.status-line {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--muted);
  font-family: var(--font-body);
  font-variant-numeric: tabular-nums;
  font-size: 0.9rem;
}

.status-line__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber);
  flex: none;
  animation: status-pulse 2.6s ease-in-out infinite;
}

@keyframes status-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.45;
  }
}

.hero__scene {
  position: relative;
  flex: 0 0 34vh;
  min-height: 220px;
  width: 100%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to top, black 78%, transparent 100%);
  mask-image: linear-gradient(to top, black 78%, transparent 100%);
}

/*
 * Горизонт — пре-рендеренная SVG-иллюстрация, не живой Cesium (см. landing.js
 * верхний комментарий: убрано после найденного вживую бага рендер-таймингов).
 * Псевдо fly-in - чистый CSS-transform (не requestAnimationFrame-цикл, не
 * WebGL) - сцена "спускается" из увеличенного/смещённого состояния в
 * состояние покоя тем же кастомным easing (--ease-descent), что и раньше
 * камера. Reduced-motion: класс .is-settled не добавляется вовсе -
 * .hero__horizon по умолчанию уже в конечном (не увеличенном) состоянии,
 * контент виден сразу.
 */
.hero__horizon {
  display: block;
  width: 100%;
  height: 100%;
  transform: scale(1.12) translateY(3%);
  transition: transform 2.4s var(--ease-descent);
  will-change: transform;
}

.hero__scene.is-settled .hero__horizon {
  transform: scale(1) translateY(0);
}

.hero__horizon-label {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  fill: oklch(0.68 0.01 250);
}

@media (prefers-reduced-motion: reduce) {
  .hero__horizon {
    transition: none;
    transform: none;
  }
}

/* ---------------------------------------------------------------------- */
/* Разделитель секций — тонкая линия с координатными тиками               */
/* ---------------------------------------------------------------------- */

.section-divider {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section-divider svg {
  width: 100%;
  height: 24px;
  display: block;
}

.section-divider__rule {
  stroke: var(--hairline);
  stroke-width: 1;
}

.section-divider__ticks line {
  stroke: var(--line);
  stroke-width: 1;
}

/* ---------------------------------------------------------------------- */
/* Секции копирайта (Проблема / Решение / Доверие)                        */
/* ---------------------------------------------------------------------- */

.copy-section {
  padding: 4.5rem 1.5rem;
}

.copy-section--surface {
  background: var(--surface);
}

.copy-section__inner {
  max-width: var(--container-max);
  margin: 0 auto;
}

.copy-section__title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 650;
  max-width: 18ch;
}

.copy-section__text {
  margin-top: 1.25rem;
  max-width: var(--measure);
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.copy-section--with-diagram {
  max-width: var(--container-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.copy-section--with-diagram .copy-section__inner {
  max-width: none;
  margin: 0;
}

.airspace-diagram {
  margin: 0;
}

.airspace-diagram svg {
  width: 100%;
  height: auto;
}

.airspace-diagram__band rect {
  fill: transparent;
  stroke: var(--line);
  stroke-width: 1;
}

.airspace-diagram__band--drone rect {
  fill: color-mix(in oklch, var(--amber) 14%, transparent);
  stroke: var(--amber);
}

.airspace-diagram__axis {
  stroke: var(--line);
  stroke-width: 1;
}

.airspace-diagram__ticks line {
  stroke: var(--line);
  stroke-width: 1;
}

.airspace-diagram__label {
  fill: var(--muted);
  font-family: var(--font-body);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.airspace-diagram__caption {
  fill: var(--muted);
  font-family: var(--font-body);
  font-size: 11px;
}

.airspace-diagram__caption--accent {
  fill: var(--amber);
}

.standards-list {
  margin-top: 1.75rem;
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.standards-list li {
  border: 1px solid var(--hairline);
  padding: 0.4rem 0.9rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--muted);
  border-radius: 3px;
}

/* ---------------------------------------------------------------------- */
/* Возможности — строки-досье, КАЖДАЯ своей внутренней раскладки          */
/* ---------------------------------------------------------------------- */

.dossier {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 4.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

.dossier__row {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

.dossier__row--diagram {
  grid-template-columns: 1.3fr 1fr;
}

.dossier__row--status {
  grid-template-columns: 2fr 1fr;
}

.dossier__row--map {
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.dossier__title {
  font-size: 1.4rem;
  font-weight: 650;
}

.dossier__desc {
  margin-top: 0.85rem;
  max-width: 48ch;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

.dossier__visual svg {
  width: 100%;
  height: auto;
}

.dossier__route {
  fill: none;
  stroke: var(--line);
  stroke-width: 2;
}

.dossier__conflict {
  fill: var(--sig-conflict);
}

.dossier__conflict-label {
  fill: var(--sig-conflict);
  font-family: var(--font-body);
  font-size: 10px;
}

.dossier__states {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  align-items: flex-start;
}

.dossier__state {
  font-family: var(--font-body);
  font-size: 0.85rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--hairline);
  border-radius: 3px;
  color: var(--muted);
}

.dossier__state::before {
  content: "\2014\0020"; /* — как текстовый префикс, не только цвет */
}

.dossier__state--ok {
  color: var(--sig-ok);
  border-color: var(--sig-ok);
}

.dossier__state--conflict {
  color: var(--sig-conflict);
  border-color: var(--sig-conflict);
}

.dossier__legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.dossier__legend li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--muted);
}

.dossier__legend-swatch {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex: none;
}

.dossier__legend-swatch--zone {
  background: var(--sig-conflict);
}

.dossier__legend-swatch--weather {
  background: var(--line);
}

.dossier__legend-swatch--traffic {
  background: var(--text);
}

.dossier__legend-swatch--density {
  background: var(--amber);
}

/* ---------------------------------------------------------------------- */
/* Финальный призыв                                                       */
/* ---------------------------------------------------------------------- */

.final-cta {
  padding: 6rem 1.5rem 7rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.75rem;
}

.final-cta__text {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
}

/* ---------------------------------------------------------------------- */
/* D1e (BUGS_release2.2.md) — версия продукта, ненавязчиво                */
/* ---------------------------------------------------------------------- */

.app-footer {
  padding: 1.25rem 1.5rem;
  text-align: center;
  border-top: 1px solid var(--hairline);
}

.app-footer__version {
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* ---------------------------------------------------------------------- */
/* Раскладка для узких экранов                                            */
/* ---------------------------------------------------------------------- */

@media (max-width: 760px) {
  .copy-section--with-diagram {
    grid-template-columns: 1fr;
  }

  .dossier__row--diagram,
  .dossier__row--status {
    grid-template-columns: 1fr;
  }
}

/* ---------------------------------------------------------------------- */
/* prefers-reduced-motion — мгновенный финальный кадр, без исключений     */
/* ---------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .hero__line {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .status-line__dot {
    animation: none !important;
    opacity: 1 !important;
  }

  * {
    transition-duration: 0.001ms !important;
  }
}
