/**
 * blocks/hero/hero.css
 * Desktop/tablet (≥768px): the hero image is a real <img> at 100% width /
 * auto height so it is always shown whole, never cropped, full page width
 * (with the top 18% cropped off via translateY, per an earlier request).
 * The text block overlays the image, horizontally centered, near the top.
 *
 * Mobile (<768px): the banner image is instead treated as pure decorative
 * background — it fills a fixed-height box completely (object-fit:cover)
 * regardless of what's depicted, so the section's height doesn't depend on
 * the image at all. This mobile-only override is intentional: on small
 * screens the "show the whole image" approach left too little/uneven room
 * for the overlay text, so the fill approach reads better there. Desktop
 * keeps the original "whole image, uncropped" treatment.
 */
.hero {
  position: relative;
  color: var(--color-white);
  background: var(--color-bg-dark);
  /* The overlay text panel needs real vertical room to sit near the top of
     the image without spilling into the next section. On wide viewports the
     image itself (1920:820, full width, uncropped) is already far taller
     than this floor, so the clamp becomes a no-op there; on narrow mobile
     viewports the image alone would be too short (~166px at 390px wide), so
     this reserves enough height in the section for the overlay to render
     fully above whatever the image doesn't cover. */
  min-height: 545px;
}
.hero__media {
  position: relative;
  width: 100%;
  line-height: 0;
  overflow: hidden;
  /* Crop the top 18% off the banner: reserve only the bottom 82% of the
     image's natural height as visible area (source images are 1895x830). */
  aspect-ratio: 1895 / 680.6;
}
.hero__image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: auto;
  display: block;
  /* Shift the full (uncropped) image up by 18% of its own height so only
     the top 18% is cut off; the bottom edge stays flush with the visible
     (shorter) container — nothing is cropped from the bottom or sides. */
  transform: translateY(-18%);
}
.hero__scrim {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 55%;
  background: linear-gradient(180deg, rgba(15, 22, 23, 0.75) 0%, rgba(15, 22, 23, 0) 100%);
  pointer-events: none;
}
.hero__inner {
  position: absolute;
  left: 50%;
  top: clamp(48px, 14%, 140px);
  transform: translateX(-50%);
  width: min(92%, 760px);
  max-width: 760px;
  margin-inline: 0;
  padding: 16px 20px 20px;
  display: grid;
  gap: 10px;
  background: rgba(15, 22, 23, 0.6);
  clip-path: var(--clip-card);
  z-index: 2;
}
/* .hero__inner is itself a grid; its direct children default to
   min-width:auto, which (independent of overflow-wrap) can still let a long
   heading push the item wider than the box — same blowout class as
   .content-section > .container, fixed the same way. Kept for all
   viewports: this is a layout bug fix, not part of the banner-image
   treatment the mobile/desktop split above is about. */
.hero__inner > * {
  min-width: 0;
}
.hero__breadcrumb { margin-bottom: 4px; }
.hero__rating {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-heading-accent);
  font-weight: var(--fw-btn);
  font-size: var(--fs-small);
  margin: 0;
}
.hero__rating-stars { letter-spacing: 2px; }
.hero__title {
  margin: 0;
}
.hero__subtitle {
  margin: 0;
  color: var(--color-text-body);
  max-width: 60ch;
}
.hero__cta { margin-top: 8px; width: fit-content; }

@media (min-width: 480px) {
  .hero { min-height: 460px; }
}
@media (min-width: 640px) {
  .hero { min-height: 380px; }
}
@media (min-width: 900px) {
  .hero { min-height: 0; }
}

@media (min-width: 768px) {
  .hero__inner { padding: 24px 32px 28px; gap: 14px; top: clamp(56px, 12%, 160px); }
}

/* ---------- Mobile-only: banner as pure background (see file header) ---------- */
@media (max-width: 767px) {
  .hero {
    min-height: 0;
  }
  .hero__media {
    overflow: hidden;
    aspect-ratio: auto;
    height: clamp(420px, 46vw, 620px);
  }
  .hero__image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
    transform: none;
  }
  .hero__scrim {
    top: 0;
    height: auto;
    background: linear-gradient(180deg, rgba(15, 22, 23, 0.8) 0%, rgba(15, 22, 23, 0.35) 45%, rgba(15, 22, 23, 0.55) 100%);
  }
}
