/* MAVEN GLOBAL — премиум-полировка: появления, glow, акценты, моушн */

/* ====== Утилитарные акценты ====== */
.text-gradient {
  background: linear-gradient(120deg, var(--color-accent-blue) 0%, var(--color-accent-blue-bright, #3d8cff) 55%, var(--color-accent-green-alt, #22b86a) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline;
}

.text-underline-glow {
  position: relative;
  white-space: nowrap;
}

.text-underline-glow::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -0.18em;
  height: 0.42em;
  background: linear-gradient(90deg, rgba(11, 108, 255, 0.55), rgba(34, 184, 106, 0.55));
  filter: blur(10px);
  opacity: 0.55;
  z-index: -1;
  pointer-events: none;
}

/* ====== Scroll-reveal ====== */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.8s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1)),
    transform 0.8s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1));
  will-change: opacity, transform;
}

[data-reveal="fade"] {
  transform: none;
}

[data-reveal="left"] {
  transform: translateX(-32px);
}

[data-reveal="right"] {
  transform: translateX(32px);
}

[data-reveal="zoom"] {
  transform: scale(0.96);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* Каскадная задержка для дочерних элементов */
[data-reveal-stagger] > * {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.7s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1)),
    transform 0.7s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1));
}

[data-reveal-stagger].is-visible > * {
  opacity: 1;
  transform: none;
}

[data-reveal-stagger].is-visible > *:nth-child(1) { transition-delay: 0.05s; }
[data-reveal-stagger].is-visible > *:nth-child(2) { transition-delay: 0.12s; }
[data-reveal-stagger].is-visible > *:nth-child(3) { transition-delay: 0.19s; }
[data-reveal-stagger].is-visible > *:nth-child(4) { transition-delay: 0.26s; }
[data-reveal-stagger].is-visible > *:nth-child(5) { transition-delay: 0.33s; }
[data-reveal-stagger].is-visible > *:nth-child(6) { transition-delay: 0.40s; }

@media (prefers-reduced-motion: reduce) {
  [data-reveal],
  [data-reveal-stagger] > * {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ====== Скрытое подключение hero-анимации (как было) ====== */
@media (prefers-reduced-motion: no-preference) {
  .hero__copy {
    animation: mg-fade-up 0.85s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1)) both;
  }

  .hero__eyebrow {
    animation: mg-fade-up 0.7s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1)) 0.05s both;
  }
}

@keyframes mg-fade-up {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ====== Sticky-header: компактный режим при скролле ====== */
.site-header {
  transition:
    background-color 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.site-header.is-scrolled {
  background: rgba(7, 15, 28, 0.94);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.32);
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.site-header.is-scrolled .site-header__inner {
  padding-top: 0.7rem;
  padding-bottom: 0.7rem;
}

.site-header.is-scrolled .site-header__logo {
  height: 38px;
}

/* ====== Бургер-меню ====== */
.site-header__toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  margin: 0;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  color: var(--color-text-on-dark);
  cursor: pointer;
}

.site-header__toggle:focus-visible {
  outline: 2px solid var(--color-text-on-dark);
  outline-offset: 3px;
}

.site-header__toggle-bar,
.site-header__toggle-bar::before,
.site-header__toggle-bar::after {
  content: "";
  display: block;
  width: 18px;
  height: 2px;
  background-color: currentColor;
  border-radius: 2px;
  transition: transform 0.25s ease, top 0.25s ease, opacity 0.2s ease;
}

.site-header__toggle-bar {
  position: relative;
}

.site-header__toggle-bar::before {
  position: absolute;
  top: -6px;
  left: 0;
}

.site-header__toggle-bar::after {
  position: absolute;
  top: 6px;
  left: 0;
}

.site-header__toggle[aria-expanded="true"] .site-header__toggle-bar {
  background-color: transparent;
}

.site-header__toggle[aria-expanded="true"] .site-header__toggle-bar::before {
  top: 0;
  transform: rotate(45deg);
}

.site-header__toggle[aria-expanded="true"] .site-header__toggle-bar::after {
  top: 0;
  transform: rotate(-45deg);
}

@media (max-width: 960px) {
  /* Одна строка: лого · языки · бургер (без переноса бургера вниз) */
  .site-header__inner {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    align-content: center;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
    column-gap: 0.35rem;
    row-gap: 0.65rem;
  }

  .site-header__inner:has(#site-nav.is-open) {
    flex-wrap: wrap;
  }

  .site-header__brand {
    flex: 1 1 auto;
    min-width: 0;
    justify-content: flex-start;
  }

  .site-header__title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .site-header__toggle {
    display: inline-flex;
    flex: 0 0 auto;
    align-self: center;
    margin-left: 0;
  }

  .site-header__right {
    display: none;
    flex-basis: 100%;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
    margin-top: 0;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .site-header__right.is-open {
    display: flex;
  }

  .site-header__nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
  }

  .site-header__nav a {
    display: block;
    padding: 0.65rem 0.85rem;
    border-radius: 10px;
  }

  .site-header__cta {
    width: 100%;
    text-align: center;
  }

  /* Компактный переключатель — одна линия с логотипом и бургером */
  .lang-switcher--header {
    flex: 0 0 auto;
    align-self: center;
    height: 40px;
    padding: 0 0.12rem;
    gap: 0.06rem;
    box-sizing: border-box;
  }

  .lang-switcher--header .lang-switcher__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.65rem;
    height: 30px;
    min-height: 30px;
    padding: 0 0.3rem;
    line-height: 1;
    font-size: 0.68rem;
  }
}

/* ====== Glow на карточках при наведении (--mx, --my задаются JS) ====== */
.problems__card {
  position: relative;
  overflow: hidden;
}

.problems__card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    220px circle at var(--mx, 50%) var(--my, 0%),
    rgba(11, 108, 255, 0.18),
    transparent 60%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
  z-index: 0;
}

.problems__card:hover::after {
  opacity: 1;
}

.problems__card > * {
  position: relative;
  z-index: 1;
}


/* ====== Кнопка "Наверх" ====== */
.back-to-top {
  position: fixed;
  right: clamp(1rem, 2.5vw, 1.75rem);
  bottom: clamp(1rem, 2.5vw, 1.75rem);
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: linear-gradient(135deg, var(--color-accent-blue) 0%, var(--color-accent-blue-alt) 100%);
  color: var(--color-text-on-dark);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 16px 40px rgba(11, 108, 255, 0.42);
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px) scale(0.85);
  pointer-events: none;
  transition:
    opacity 0.3s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1)),
    transform 0.3s var(--ease-out, cubic-bezier(0.22, 1, 0.36, 1));
  z-index: 90;
}

.back-to-top.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.back-to-top:hover {
  background: linear-gradient(135deg, var(--color-accent-blue-bright, #3d8cff) 0%, var(--color-accent-blue) 100%);
  box-shadow: 0 20px 50px rgba(11, 108, 255, 0.55);
}

.back-to-top:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 3px;
}

.back-to-top svg {
  width: 22px;
  height: 22px;
}

/* ====== Trust strip ====== */
.trust-strip {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-bottom: 1px solid rgba(6, 16, 40, 0.06);
  padding: 1.75rem 0;
}

.trust-strip__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem 2rem;
  align-items: center;
}

.trust-strip__item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  position: relative;
  padding-left: 1rem;
}

.trust-strip__item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.4rem;
  bottom: 0.4rem;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--color-accent-blue), var(--color-accent-green));
}

.trust-strip__value {
  font-family: var(--font-heading);
  font-weight: var(--font-weight-heading);
  font-size: clamp(1.25rem, 1.8vw, 1.5rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--color-text-heading);
}

.trust-strip__label {
  font-size: 0.8125rem;
  font-weight: var(--font-weight-body-medium);
  color: var(--color-text-body);
  letter-spacing: 0.02em;
}

@media (max-width: 760px) {
  .trust-strip {
    padding: 1.5rem 0;
  }

  .trust-strip__inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 1rem;
    padding: 0 1rem;
  }

  .trust-strip__value {
    font-size: 1.1rem;
  }

  .trust-strip__label {
    font-size: 0.78rem;
  }
}

@media (max-width: 420px) {
  .trust-strip__inner {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }
}

/* ====== Hero floating stat ====== */
.hero {
  position: relative;
}

.hero__floating {
  position: absolute;
  right: clamp(1.25rem, 4vw, 3rem);
  bottom: clamp(1.5rem, 5vw, 3rem);
  z-index: 3;
  max-width: 17rem;
  padding: 1rem 1.15rem;
  background: rgba(15, 31, 56, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: var(--color-text-on-dark);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.hero__floating-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.hero__floating-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(11, 108, 255, 0.3) 0%, rgba(34, 184, 106, 0.3) 100%);
  color: #fff;
}

.hero__floating-value {
  display: block;
  font-family: var(--font-heading);
  font-weight: var(--font-weight-heading);
  font-size: 1.05rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.hero__floating-label {
  display: block;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.02em;
}

.hero__floating-text {
  margin: 0.65rem 0 0;
  font-size: 0.82rem;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.78);
}

@media (max-width: 900px) {
  .hero__floating {
    position: static;
    display: block;
    width: auto;
    max-width: none;
    margin: 1.5rem 1rem 0;
    padding: 0.95rem 1.1rem;
  }
}

@media (max-width: 480px) {
  .hero__floating {
    display: none;
  }
}

/* ====== Featured offer: бейдж и чуть больше воздуха ====== */
.offer-card--featured {
  position: relative;
}

.offer-card__badge {
  position: absolute;
  top: -12px;
  right: 16px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: var(--font-weight-heading);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffffff;
  background: linear-gradient(135deg, #fbbf24 0%, #f97316 100%);
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(249, 115, 22, 0.4);
  z-index: 2;
}

.offer-card__badge svg {
  width: 12px;
  height: 12px;
  stroke-width: 2.5;
}

/* Process — соединения теперь полностью описаны в process.css */

/* ====== Section divider ====== */
.section-divider {
  position: relative;
  height: 64px;
  margin: -1px 0;
  pointer-events: none;
  overflow: hidden;
}

.section-divider svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* ====== Sticky-header reduced motion ====== */
@media (prefers-reduced-motion: reduce) {
  .hero__copy,
  .hero__eyebrow,
  .back-to-top {
    animation: none !important;
  }
}
