/* ==========================================================================
   Hero Block — Full viewport photo with overlay content
   ========================================================================== */

/* Трапециевидная форма — параметры задаются через CSS-переменные в design-system.css:
   --zg3-hero-taper  (сужение с каждой стороны, напр. 0.03 = 3%)
   --zg3-hero-br     (закругление нижних углов, напр. 0.07 = 7%)
   SVG clipPath обновляется скриптом в hero.php при загрузке страницы. */
.zg3-hero {
  position: relative;
  width: 100%;
  height: 649px;
  min-height: 649px;
  overflow: hidden;
  margin: 0;
  clip-path: url(#zg3-hero-clip);
}

/* Background slider */
.zg3-hero__slider {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
}
.zg3-hero__slider .swiper-wrapper { height: 100%; }
.zg3-hero__slider .swiper-slide { height: 100%; overflow: hidden; }
.zg3-hero__slide-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  will-change: transform;
  transform: scale(1.08);
  transition: transform 8s ease-out;
}
.swiper-slide-active .zg3-hero__slide-img { transform: scale(1); }

/* Overlay gradient */
.zg3-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    180deg,
    rgba(0,0,0,0.3) 0%,
    rgba(0,0,0,0.05) 40%,
    rgba(0,0,0,0.55) 100%
  );
}

/* Content layer */
.zg3-hero__content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: var(--zg3-sp-32) var(--zg3-sp-40);
  color: var(--zg3-white);
}

/* Top bar: logo left, stats right */
.zg3-hero__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.zg3-hero__logo {
  display: flex;
  align-items: center;
  gap: var(--zg3-sp-12);
}
.zg3-hero__logo img { border-radius: var(--zg3-r-md); }
.zg3-hero__logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.zg3-hero__logo-text strong {
  font-size: 18px;
  font-weight: var(--zg3-fw-bold);
}

/* Stats (top-right on desktop) */
.zg3-hero__stats {
  display: flex;
  align-items: center;
  gap: var(--zg3-sp-20);
}
.zg3-hero__stat {
  display: flex;
  align-items: center;
  gap: var(--zg3-sp-8);
}
.zg3-hero__stat-num {
  font-size: clamp(28px, 3vw, 44px);
  font-weight: var(--zg3-fw-bold);
  letter-spacing: -0.04em;
  line-height: 1;
}
.zg3-hero__stat-label {
  font-size: 12px;
  color: #fff;
  line-height: 1.3;
}
.zg3-hero__stat-divider {
  width: 1px;
  height: 40px;
  background: rgba(255,255,255,0.2);
}

/* Right-side vertical nav */
.zg3-hero__nav {
  position: absolute;
  right: 28px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.zg3-hero__nav-link {
  font-size: var(--zg3-fs-micro);
  font-weight: var(--zg3-fw-medium);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  padding: var(--zg3-sp-8) var(--zg3-sp-16);
  border-radius: var(--zg3-r-full);
  transition: color var(--zg3-dur-fast), background var(--zg3-dur-fast);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  transition: all 0.2s ease;
}
.zg3-hero__nav-link:hover {
  color: var(--zg3-white);
  background: rgba(0, 0, 0, 0.3);
  margin-right: 12px;
  backdrop-filter: blur(12px);
}
.zg3-hero__nav-arrow { margin-left: 4px;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.2s, transform 0.2s;
}
.zg3-hero__nav-link:hover .zg3-hero__nav-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* Bottom area */
.zg3-hero__bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--zg3-sp-32);
}

.zg3-hero__text {
  max-width: 720px;
}

.zg3-hero__subtitle {
  font-size: clamp(18px, 2.2vw, 28px);
  font-weight: var(--zg3-fw-medium);
  line-height: 1.15;
  margin-bottom: 0;
  letter-spacing: -0.03em;
  margin-left: 48px;
}
.zg3-hero__hl {
  color: #ff5f42;
}

.zg3-hero__buttons {
  display: flex;
  flex-wrap: wrap;
  gap: var(--zg3-sp-12);
  align-items: center;
  flex-shrink: 0;
  margin-right: 28px;
}

/* Outline white button variant */
.zg3-btn--outline-white {
  background: transparent;
  color: var(--zg3-white);
  box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.5);
}
.zg3-btn--outline-white:hover {
  background: rgba(255,255,255,0.1);
  box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.8);
}

/* ===== Mobile ===== */
@media (max-width: 767px) {
  .zg3-hero {
    width: 100%;
    height: calc(100dvh - 60px);
    min-height: calc(100dvh - 60px);
    margin: 0;
    clip-path: none;
    overflow: hidden;
  }
  /* Mobile stats: column layout in top-right */
  .zg3-hero__stats {
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
  }
  .zg3-hero__stat { flex-direction: column; align-items: flex-end; gap: 2px; }
  .zg3-hero__stat-num { font-size: 20px; }
  .zg3-hero__stat-label { font-size: 10px; text-align: right; }
  .zg3-hero__stat-divider { display: none; }
  /* Mobile buttons: inline row, 12px font */
  .zg3-hero__buttons {
    flex-direction: row !important;
    gap: var(--zg3-sp-8);
  }
  .zg3-hero__buttons .zg3-btn {
    font-size: 12px !important;
    padding: 10px 14px !important;
    width: auto !important;
  }
  .zg3-hero__content {
    padding: var(--zg3-sp-20) var(--zg3-sp-20);
    padding-bottom: 52px;
  }
  .zg3-hero__overlay {
    background: linear-gradient(
      180deg,
      rgba(0,0,0,0.45) 0%,
      rgba(0,0,0,0.05) 35%,
      rgba(0,0,0,0.5) 70%,
      rgba(0,0,0,0.8) 100%
    );
  }
  .zg3-hero__subtitle {
    font-size: 16px;
    margin-left: 0;
  }
  .zg3-hero__buttons {
    flex-direction: column;
    gap: var(--zg3-sp-8);
  }
  .zg3-hero__buttons .zg3-btn {
    width: 100%;
    justify-content: center;
    font-size: var(--zg3-fs-small);
    padding: 14px var(--zg3-sp-20);
  }
  .zg3-hero__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--zg3-sp-24);
  }
  .zg3-hero__stat-num {
    font-size: clamp(20px, 6vw, 32px);
  }
}
