/* ============================================================
   hero.css — Full-screen hero section
   Depends on: variables.css, layout.css, components/button.css, components/badge.css
   ============================================================ */

/* ── Section ────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;               /* use svh so mobile address bar doesn't cut off */
  min-height: 100vh;                /* fallback */
  display: flex;
  align-items: center;
  background-color: var(--color-primary);
  overflow: hidden;
  padding: calc(var(--nav-height) + var(--space-8)) 0 var(--space-16);
}

@media (max-width: 479px) {
  .hero {
    min-height: 100svh;  /* тянем hero во весь экран, чтобы жёлтая stats-bar не просвечивала */
    min-height: 100vh;   /* fallback */
    padding: calc(var(--nav-height) + var(--space-3)) 0 var(--space-8);
  }
}

/* На мобиле фото компактное — оставляем место для заголовка и CTA в первом экране */
@media (max-width: 1023px) {
  .hero__title {
    font-size: 22px;
    line-height: 1.18;
  }
  .hero__subtitle {
    font-size: var(--text-body-m);
  }
  .hero__photo::before,
  .hero__photo::after {
    display: none;
  }
}

@media (max-width: 479px) {
  .hero__title {
    font-size: 20px;
  }
  .hero__actions .btn--lg {
    padding: 12px 18px;
    font-size: 15px;
  }
}

@media (min-width: 1024px) {
  .hero {
    padding: calc(var(--nav-height) + var(--space-12)) 0 var(--space-24);
  }
}

/* ── Background photo overlay ───────────────────────────── */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(15, 31, 61, 0.72) 0%,
    rgba(30, 97, 192, 0.65) 60%,
    rgba(30, 97, 192, 0.45) 100%
  );
}

/* ── Inner layout ───────────────────────────────────────── */
.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  align-items: center;
}

@media (min-width: 640px) {
  .hero__inner {
    gap: var(--space-6);
  }
}

@media (min-width: 1024px) {
  .hero__inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-16);
  }
}

/* ── Content (left column) ──────────────────────────────── */
.hero__content {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  order: 2;
}

@media (min-width: 1024px) {
  .hero__content {
    order: 1;
    gap: var(--space-6);
  }
}

.hero__eyebrow {
  display: inline-flex;
  align-self: flex-end;
}

.hero__title {
  font-size: 26px;
  font-weight: var(--font-weight-extrabold);
  color: var(--color-text-on-dark);
  line-height: 1.15;
  letter-spacing: var(--ls-heading);
  text-wrap: balance;
}

@media (min-width: 640px) {
  .hero__title {
    font-size: 30px;
  }
}

@media (min-width: 1024px) {
  .hero__title {
    font-size: 36px;
  }
}

@media (min-width: 1280px) {
  .hero__title {
    font-size: 40px;
  }
}

.hero__subtitle {
  font-size: var(--text-body-l);
  color: rgba(255, 255, 255, 0.92);  /* WCAG AA на gradient overlay */
  line-height: var(--lh-body);
  max-width: 52ch;
}

/* Определение клуба — акцентный жёлтый для brand-якоря */
.hero__subtitle strong {
  color: var(--color-accent);
  font-weight: var(--font-weight-extrabold);
}

/* ── CTA buttons row ────────────────────────────────────── */
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  padding-top: var(--space-2);
}

/* ── Trust row (mini stats below buttons) ───────────────── */
.hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4) var(--space-6);
  padding-top: var(--space-2);
}

.hero__trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-caption);
  color: rgba(255, 255, 255, 0.75);
  font-weight: var(--font-weight-semibold);
}

.hero__trust-item svg {
  width: 16px;
  height: 16px;
  color: var(--color-accent);
  flex-shrink: 0;
}

/* ── Photo (right column) ───────────────────────────────── */
.hero__photo {
  order: 1;
  position: relative;
  display: flex;
  justify-content: center;
}

@media (min-width: 1024px) {
  .hero__photo {
    order: 2;
    justify-content: flex-end;
  }
}

.hero__photo-wrap {
  position: relative;
  width: 100%;
  max-width: 220px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(15, 31, 61, 0.45);
}

@media (min-width: 640px) {
  .hero__photo-wrap {
    max-width: 280px;
  }
}

@media (min-width: 1024px) {
  .hero__photo-wrap {
    max-width: 520px;
  }
}

.hero__photo-wrap img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center top;
}

/* When the wrap holds a carousel — remove overflow clip so badge is visible */
.hero__photo-wrap--carousel {
  overflow: visible;
  background: transparent;
  box-shadow: none;
}

/* ── Hero carousel ──────────────────────────────────────── */
.hero-carousel {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(15, 31, 61, 0.45);
  aspect-ratio: 3 / 4;
  background-color: rgba(255,255,255,0.07);
}

.hero-carousel__track {
  display: flex;
  height: 100%;
  transition: transform 0.5s ease;
  will-change: transform;
}

.hero-carousel__slide {
  flex: 0 0 100%;
  height: 100%;
}

.hero-carousel__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Prev / Next */
.hero-carousel__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.82);
  color: var(--color-text-primary);
  border: none;
  cursor: pointer;
  transition: var(--transition-fast);
  z-index: 2;
}

.hero-carousel__btn:hover { background: white; }
.hero-carousel__btn--prev { left: var(--space-3); }
.hero-carousel__btn--next { right: var(--space-3); }

/* Dots */
.hero-carousel__dots {
  position: absolute;
  bottom: var(--space-3);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--space-2);
  z-index: 2;
}

.hero-carousel__dot {
  width: 7px;
  height: 7px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.45);
  border: none;
  cursor: default;
  pointer-events: none;
  padding: 0;
  transition: var(--transition-fast);
}

.hero-carousel__dot.is-active {
  background: white;
  width: 22px;
}

/* Decorative accent dots */
.hero__photo::before {
  content: '';
  position: absolute;
  top: -20px;
  right: -20px;
  width: 120px;
  height: 120px;
  background-image: radial-gradient(
    circle, rgba(255, 217, 19, 0.55) 2px, transparent 2px
  );
  background-size: 16px 16px;
  z-index: -1;
}

.hero__photo::after {
  content: '';
  position: absolute;
  bottom: -16px;
  left: -16px;
  width: 80px;
  height: 80px;
  background-image: radial-gradient(
    circle, rgba(255, 255, 255, 0.25) 2px, transparent 2px
  );
  background-size: 14px 14px;
  z-index: -1;
}

/* ── Floating badge on photo ────────────────────────────── */
.hero__photo-badge {
  position: absolute;
  bottom: var(--space-4);
  left: 0;
  transform: translateX(-8px);
  background-color: var(--color-bg);
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-4);
  box-shadow: 0 8px 24px rgba(15, 31, 61, 0.2);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 180px;
}

@media (min-width: 1024px) {
  .hero__photo-badge {
    transform: translateX(-40px);
  }
}

.hero__photo-badge-icon {
  font-size: 28px;
  line-height: 1;
}

.hero__photo-badge-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hero__photo-badge-label {
  font-size: var(--text-caption);
  color: var(--color-text-muted);
  font-weight: var(--font-weight-semibold);
}

.hero__photo-badge-value {
  font-size: var(--text-body-m);
  font-weight: var(--font-weight-extrabold);
  color: var(--color-text-primary);
}

/* ── Scroll-down hint ───────────────────────────────────── */
.hero__scroll-hint {
  position: absolute;
  bottom: var(--space-8);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  color: rgba(255, 255, 255, 0.5);
  font-size: var(--text-caption);
  text-decoration: none;
  transition: color 0.2s ease;
  z-index: 1;
}

.hero__scroll-hint:hover {
  color: rgba(255, 255, 255, 0.8);
}

.hero__scroll-hint svg {
  width: 20px;
  height: 20px;
  animation: scroll-bounce 1.8s ease-in-out infinite;
}

@keyframes scroll-bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(6px); }
}

@media (max-width: 767px) {
  .hero__scroll-hint {
    display: none;
  }
}

