/*
 * Alf Theme — Shared Hero Banner
 * Figma node: 625:3284 baseline
 *
 * Generic full-viewport hero — reused across pages via hero-banner.php with
 * a page-specific meta_key. Header floats over this section — body
 * padding-top is removed here.
 *
 * Desktop structure:
 *   section.hero-banner            full-viewport, bg-image + double overlay
 *   └── .alf-container
 *       └── .hero-banner__wrap     flex-col gap-80  pt-144 pb-80
 *           ├── .hero-banner__content    flex-col gap-32  (badge → H1 → sub → CTA)
 *           └── .hero-banner__stats      flex-row gap-32  (dynamic stat count)
 */

/* ── Remove body top-offset — header overlays this section ────────── */
body {
  padding-top: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   SECTION CONTAINER
   ═══════════════════════════════════════════════════════════════════ */
.hero-banner {
  position: relative;
  padding: 144px 0 80px;
  min-height: 100svh;
  overflow: hidden;
}

/* ── Image Layer ─────────────────────────────────────────────────── */
.hero-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--hero-bg);
  background-position: 50%;
  background-size: cover;
  background-repeat: no-repeat;
  filter: grayscale(100%);
  z-index: 1;
}

/* ── Figma Gradient Overlay ─────────────────────────────────────── */
.hero-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--color-black) 0%, rgba(12, 12, 12, 0.00) 19.23%), linear-gradient(0deg, rgba(12, 12, 12, 0.30) 0%, rgba(12, 12, 12, 0.30) 100%), linear-gradient(90deg, rgba(37, 37, 37, 0.95) 0%, rgba(37, 37, 37, 0.80) 50%, rgba(0, 0, 0, 0.00) 100%);
  pointer-events: none;
  z-index: 2;
}

/* ── Inner wrap ───────────────────────────────────────────────────── */
.hero-banner__wrap {
  display: flex;
  flex-direction: column;
  gap: 80px;
  align-items: flex-start;
  position: relative;
  z-index: 3;
}

/* ═══════════════════════════════════════════════════════════════════
   UPPER CONTENT BLOCK  (gap-32: badge → H1 → sub → CTA)
   ═══════════════════════════════════════════════════════════════════ */
.hero-banner__content {
  display: flex;
  flex-direction: column;
  gap: 32px;
  align-items: flex-start;
}

/* ── Badge pill ───────────────────────────────────────────────────── */
.hero-banner__badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  font-size: 16px;
  font-weight: 400;
  line-height: normal;
  color: var(--color-bg);
  background-color: rgba(205, 38, 29, 0.2);
  border: 1px solid rgba(205, 38, 29, 0.3);
  border-radius: 1000px;
  margin: 0;
  white-space: nowrap;
}

/* ── Headline ─────────────────────────────────────────────────────── */
.hero-banner__heading {
  font-size: 72px;
  font-weight: 400;
  line-height: normal;
  color: var(--color-bg);
  margin: 0;
}

.hero-banner__heading-accent {
  color: var(--color-primary);
}

/* ── Sub-heading ──────────────────────────────────────────────────── */
.hero-banner__sub {
  font-size: 16px;
  font-weight: 400;
  line-height: normal;
  color: var(--color-bg);
  margin: 0;
}

/* ── CTA button ──────────────────────────────────────────────────── */
.hero-banner__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  width: fit-content;
  gap: 10px;
  max-width: 100%;
  padding: 14px 16px;
  font-size: 16px;
  font-weight: 400;
  line-height: normal;
  text-decoration: none;
  color: var(--color-dark);
  background-color: var(--color-bg);
  border-radius: 8px;
  transition: background-color 0.2s ease, transform 0.15s ease;
}

.hero-banner__cta:hover,
.hero-banner__cta:focus-visible {
  background-color: #e5e8d4;
  transform: translateY(-1px);
}

.hero-banner__cta:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

.hero-banner__cta img {
  flex-shrink: 0;
  filter: brightness(0);
}

/* ═══════════════════════════════════════════════════════════════════
   STATS BAR  (flex-row, gap-32, dynamic stat count)
   ═══════════════════════════════════════════════════════════════════ */
.hero-banner__stats {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 32px;
  margin: 0;
  padding: 0;
}

/* ── Individual stat block ────────────────────────────────────────── */
.hero-banner__stat {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
  max-width: 200px;
}

.hero-banner__stat-value {
  font-size: 24px;
  font-weight: 700;
  line-height: normal;
  color: var(--color-primary);
  margin: 0;
}

.hero-banner__stat-label {
  font-size: 16px;
  font-weight: 300;
  line-height: normal;
  color: var(--color-bg);
  margin: 0;
  max-width: 200px;
}

/* ── Vertical divider ─────────────────────────────────────────────── */
.hero-banner__stat-divider {
  width: 1px;
  height: 79px;
  background-color: rgba(248, 250, 240, 0.3);
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE ADJUSTMENTS
   ═══════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  .hero-banner {
    padding: 112px 0 120px;
    min-height: auto;
  }

  /* Mobile: H1 drops to 48px, font-weight 300 / Light */
  .hero-banner__heading {
    font-size: 48px;
    font-weight: 300;
  }

  .hero-banner__content {
    max-width: 100%;
  }

  /* Stats: clean 2-col grid, any stat count (Figma 1354:1738) — divider
     elements are hidden and replaced by a border on each row's left-hand
     stat, since a fixed nth-child hide can't handle a variable number of
     admin-entered stats correctly (it only worked for exactly 3). */
  .hero-banner__stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 8px;
    row-gap: 64px;
    max-width: 100%;
  }

  .hero-banner__stat {
    align-items: center;
    text-align: center;
    gap: 21px;
  }

  .hero-banner__stat-label {
    max-width: 100%;
  }

  .hero-banner__stat-divider {
    display: none;
  }

  /* Left-hand stat of each row gets the divider as a border instead —
     stat items sit at nth-child 1, 5, 9… because a divider element is
     interspersed between every pair. */
  .hero-banner__stat:nth-child(4n+1):not(:last-child) {
    border-right: 1px solid rgba(248, 250, 240, 0.3);
  }
}

@media (max-width: 480px) {
  .hero-banner {
    padding: 100px 0 80px;
  }

  .hero-banner__badge {
    font-size: 14px;
    padding: 6px 12px;
  }
}
