/* Шапка, первый экран, подвал. */

.header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(11, 11, 15, 0.72);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.header__inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 76px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 19px;
  color: var(--ink-strong);
  letter-spacing: -0.03em;
}

.logo:hover {
  text-decoration: none;
}

.logo img {
  width: 34px;
  height: 34px;
}

.nav {
  display: flex;
  gap: 30px;
  margin-left: auto;
}

/* Пара действий в шапке. Свой отступ, меньше общего: иначе кнопки разъезжаются
   на 28px и читаются как два разных блока, а не как соседние действия. */
.header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Высота задаётся явно: у стеклянной кнопки есть рамка в 1px, у градиентной
   нет, и рядом они разъезжались на 2px. Добирать рамкой нельзя — прозрачная
   рамка поверх градиента даёт светящуюся кромку по краю. */
.header__actions .btn {
  min-height: 48px;
}

.header__app img {
  /* Белый знак рядом с текстом кнопки — приглушаем, как в подвале. */
  opacity: 0.85;
}

/* На десктопе то же самое уже есть кнопкой справа. */
.nav__app {
  display: none;
}

.nav a {
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 500;
  transition: color 0.15s ease;
}

.nav a:hover {
  color: var(--ink-strong);
  text-decoration: none;
}

.burger {
  display: none;
  margin-left: auto;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--glass);
  color: var(--ink-strong);
  font-size: 19px;
  cursor: pointer;
}

/* Первый экран.
   Свечение под контентом — общий приём обоих образцов: на почти чёрном холсте
   оно даёт глубину там, где на светлом фоне работала бы тень. */
.hero {
  position: relative;
  padding: 96px 0 88px;
  overflow: hidden;
  background: var(--bg);
}

.hero::before {
  content: "";
  position: absolute;
  top: -280px;
  left: 50%;
  width: 1100px;
  height: 760px;
  transform: translateX(-50%);
  background: radial-gradient(
    ellipse at center,
    rgba(107, 43, 255, 0.4) 0%,
    rgba(58, 137, 251, 0.16) 42%,
    transparent 70%
  );
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--line-strong) 30%,
    var(--line-strong) 70%,
    transparent
  );
}

.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 44px;
  align-items: center;
}

.hero h1 {
  margin-bottom: 22px;
}

.hero__lead {
  font-size: 20px;
  color: var(--ink-soft);
  max-width: 560px;
  margin-bottom: 34px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

/* «Заказать своего бота» стоит под кнопками мессенджеров. Своей ширины по
   тексту она была шире их, и второстепенное действие выглядело главным —
   держим её в той же ширине, что и остальные кнопки выбора. */
.hero__actions .btn--ghost {
  min-width: var(--btn-choice-width);
  min-height: var(--btn-choice-height);
}

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

.hero__art {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero__art img {
  width: min(430px, 100%);
  filter: drop-shadow(0 30px 60px rgba(107, 43, 255, 0.4));
  animation: mascot-float 5.5s ease-in-out infinite;
}

/* Маскот покачивается вверх-вниз. Тень при этом усиливается на подъёме —
   без этого он выглядит не парящим, а просто съезжающим по вертикали. */
@keyframes mascot-float {
  0%,
  100% {
    transform: translateY(0);
    filter: drop-shadow(0 30px 60px rgba(107, 43, 255, 0.4));
  }
  50% {
    transform: translateY(-18px);
    filter: drop-shadow(0 44px 72px rgba(107, 43, 255, 0.52));
  }
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  padding: 32px 0 0;
  margin-top: 38px;
  border-top: 1px solid var(--line);
}

.facts__value {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.05;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.facts__label {
  font-size: 14px;
  color: var(--ink-muted);
}

/* Подвал */
.footer {
  background: #07070a;
  color: var(--ink-soft);
  padding: 64px 0 36px;
  font-size: 15px;
  border-top: 1px solid var(--line);
}

.footer a {
  color: var(--ink-soft);
}

.footer a:hover {
  color: var(--ink-strong);
}

.footer__top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 19px;
  color: var(--ink-strong);
  margin-bottom: 12px;
  letter-spacing: -0.03em;
}

.footer__brand img {
  width: 32px;
  height: 32px;
}

.footer h4 {
  margin: 0 0 12px;
  color: var(--ink-strong);
  font-size: 15px;
}

.footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 9px;
}

.footer__bottom {
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  color: var(--ink-muted);
  font-size: 13px;
}

@media (max-width: 940px) {
  .hero__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero__lead {
    margin-left: auto;
    margin-right: auto;
  }

  .hero__actions,
  .facts {
    justify-content: center;
  }

  .hero__art {
    order: -1;
  }

  .hero__art img {
    width: min(280px, 68%);
  }

  .footer__top {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .hero {
    padding: 40px 0 56px;
  }

  /* На узком экране картинка стоит первой и вместе со свечением съедала весь
     первый экран — заголовок уходил за сгиб. Уменьшаем оба. */
  .hero__art img {
    width: min(180px, 48%);
  }

  .hero::before {
    top: -170px;
    width: 560px;
    height: 460px;
  }

  .nav {
    display: none;
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(11, 11, 15, 0.97);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line);
    padding: 8px 0;
  }

  .nav.is-open {
    display: flex;
  }

  .nav a {
    padding: 14px var(--gutter);
  }

  .header__inner .btn {
    display: none;
  }

  /* Кнопки спрятались — пункт меню занимает их место. */
  .nav__app {
    display: block;
  }

  .burger {
    display: block;
  }

  .facts {
    gap: 24px;
  }

  .facts > div {
    flex: 1 1 40%;
  }

  .facts__value {
    font-size: 30px;
  }

  .footer__top {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  /* Кнопки мессенджеров на этой ширине растягиваются на всю строку
     (components.css). «Заказать своего бота» должна тянуться вместе с ними,
     иначе в столбце окажется одна кнопка короче остальных. */
  .hero__actions .btn--ghost {
    width: 100%;
  }
}
