/* CORE — HERO */
.hero {
  position:relative;
  width:100vw;
  max-width:100vw;
  margin-left:calc(50% - 50vw);
  margin-right:calc(50% - 50vw);
  margin-top:0;
  margin-bottom:0;
}
.hero-viewport {
  position:relative;
  border-radius:0;
  overflow:hidden;
  background:#000;
  outline:none;
}
.hero-viewport:focus-visible {
  box-shadow:0 0 0 3px rgba(var(--accent-rgb),.8);
}
.hero-track {
  position:relative;
  width:100%;
  aspect-ratio:2.2 / 1;
  min-height:560px;
  max-height:90vh;
}
.hero-slide {
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  overflow:hidden;
  color:var(--text);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transition:opacity .9s ease,visibility .9s ease;
}
.hero-slide.active {
  opacity:1;
  visibility:visible;
  pointer-events:auto;
  z-index:2;
}
.hero-bg {
  position:absolute;
  inset:0;
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center 20%;
}
.hero-scrim {
  position:absolute;
  inset:0;
  z-index:1;
  pointer-events:none;
  /* Cinejoy-style: side pool + bottom melt into site --bg */
  background:
    linear-gradient(
      to top,
      var(--bg, #1f1f1f) 0%,
      rgba(var(--bg-rgb, 31,31,31), 0.96) 10%,
      rgba(var(--bg-rgb, 31,31,31), 0.7) 28%,
      rgba(var(--bg-rgb, 31,31,31), 0.25) 48%,
      transparent 65%
    ),
    linear-gradient(
      90deg,
      rgba(0,0,0,.88) 0%,
      rgba(0,0,0,.5) 36%,
      rgba(0,0,0,.12) 62%,
      transparent 100%
    ),
    linear-gradient(
      0deg,
      transparent 40%,
      rgba(0,0,0,.25) 100%
    );
}
.hero-bg-link {
  position:absolute;
  inset:0;
  z-index:3;
  display:block;
}
.hero-bg-link:focus-visible {
  outline:3px solid var(--accent);
  outline-offset:-5px;
}
.hero-content {
  position:absolute;
  left:0;
  bottom:0;
  z-index:5;
  width:100%;
  max-width:560px;
  padding:clamp(28px,4.5vw,64px) clamp(28px,5vw,72px) clamp(56px,7vw,72px);
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:14px;
  box-sizing:border-box;
  pointer-events:none;
}
.hero-logo,.hero-title-text,.hero-genres,.hero-excerpt,.hero-cta {
  opacity:0;
  transform:translateY(22px);
}
.hero-slide.active .hero-logo {
  animation:heroFadeUp .7s ease .15s forwards;
}
.hero-slide.active .hero-title-text {
  animation:heroFadeUp .7s ease .15s forwards;
}
.hero-slide.active .hero-genres {
  animation:heroFadeUp .7s ease .28s forwards;
}
.hero-slide.active .hero-excerpt {
  animation:heroFadeUp .7s ease .38s forwards;
}
.hero-slide.active .hero-cta {
  animation:heroFadeUp .7s ease .48s forwards;
}
@keyframes heroFadeUp {
  from {
    opacity:0;
    transform:translateY(22px);
  }
  to {
    opacity:1;
    transform:translateY(0);
  }
}
.hero-logo {
  display:block;
  width:auto;
  height:auto;
  max-height:130px;
  max-width:380px;
  object-fit:contain;
  object-position:left center;
  filter:drop-shadow(0 8px 20px rgba(0,0,0,.55));
  position:relative;
  z-index:3;
  pointer-events:none;
}
.hero-title-text {
  margin:0;
  font-size:clamp(32px,4.8vw,52px);
  font-weight:700;
  line-height:1.06;
  letter-spacing:-.02em;
  color:#fff;
  text-shadow:0 5px 24px rgba(0,0,0,.55);
  position:relative;
  z-index:3;
  pointer-events:none;
}
.hero-genres {
  display:block;
  margin:0;
  font-size:13px;
  font-weight:700;
  letter-spacing:.04em;
  text-transform:uppercase;
  color:rgba(255,255,255,.78);
  text-shadow:0 2px 10px rgba(0,0,0,.45);
  position:relative;
  z-index:3;
  pointer-events:none;
}
.hero-excerpt {
  display:block;
  margin:0;
  max-width:480px;
  color:rgba(255,255,255,.86);
  font-size:15px;
  line-height:1.65;
  text-decoration:none;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  text-shadow:0 2px 12px rgba(0,0,0,.5);
  transition:color .2s;
  position:relative;
  z-index:3;
  pointer-events:auto;
}
.hero-excerpt:hover {
  color:#fff;
}
.hero-cta {
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:13px 28px;
  border-radius:25px;
  background:var(--accent);
  color:var(--accent-ink);
  font-size:14px;
  font-weight:700;
  text-decoration:none;
  letter-spacing:.03em;
  transition:.25s;
  position:relative;
  z-index:3;
  pointer-events:auto;
}
.hero-cta:hover {
  background:var(--accent-hi);
  transform:translateY(-2px);
  color:var(--accent-ink);
}
.hero-cta i {
  font-size:13px;
}
.hero-dots {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  position:absolute;
  left:0;
  right:0;
  bottom:14px;
  z-index:8;
  padding:0 12px;
}
.hero-dot {
  position:relative;
  width:24px;
  height:24px;
  padding:0;
  margin:0;
  border:none;
  background:transparent;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}
.hero-dot::before {
  content:"";
  width:7px;
  height:7px;
  border-radius:50%;
  background:rgba(255,255,255,.42);
  transition:background-color .25s ease,transform .25s ease;
  pointer-events:none;
}
.hero-dot span {
  display:none;
}
.hero-dot.active::before {
  transform:scale(1.15);
  background:#fff;
  box-shadow:0 0 0 2px rgba(255,255,255,.22);
}
.hero-dot:hover::before {
  background:rgba(255,255,255,.78);
}
.hero-dot:focus-visible {
  outline:2px solid #fff;
  outline-offset:2px;
  border-radius:50%;
}
@media (max-width:991px) {
  .hero-track {
    aspect-ratio:1.85 / 1;
    min-height:480px;
  }
  .hero-content {
    max-width:70%;
    padding:28px 28px 52px;
  }
  .hero-logo {
    max-height:100px;
    max-width:300px;
  }
}
@media (max-width:768px) {
  /* Full-bleed via negative margins (safe) — NOT calc(50%-50vw) which clips */
  .hero {
    width: auto !important;
    max-width: none !important;
    margin-left: -14px !important;
    margin-right: -14px !important;
    margin-bottom: 18px !important;
    padding-bottom: 0 !important;
    background: var(--bg, #1f1f1f) !important;
    overflow: visible !important;
  }
  .hero-viewport {
    border-radius: 0 !important;
    background: var(--bg, #1f1f1f) !important;
    overflow: hidden !important;
  }
  /*
   * Apple TV mobile hero:
   *  - backdrop sits in a TOP box (--tx-img-h-global tall)
   *  - track is a bit taller so logo/text can sit over the fade
   *  - never collapse (explicit min-height)
   */
  .hero-track {
    position: relative !important;
    width: 100% !important;
    aspect-ratio: auto !important;
    height: calc(var(--tx-img-h-global, clamp(380px, 120vw, 640px)) + 72px) !important;
    min-height: 460px !important;
    max-height: none !important;
    box-sizing: border-box !important;
  }
  .hero-slide {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
  }
  .hero-slide.active {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    z-index: 2 !important;
  }
  /* Backdrop only in the TOP band — shows more of the scene (less face-crop) */
  .hero-bg {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    width: 100% !important;
    height: var(--tx-img-h-global, clamp(380px, 120vw, 640px)) !important;
    display: block !important;
    object-fit: cover !important;
    object-position: center 15% !important;
  }
  .hero-scrim {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    height: var(--tx-img-h-global, clamp(380px, 120vw, 640px)) !important;
    background:
      linear-gradient(
        to top,
        var(--bg, #1f1f1f) 0%,
        rgba(var(--bg-rgb, 31, 31, 31), 0.96) 10%,
        rgba(var(--bg-rgb, 31, 31, 31), 0.75) 24%,
        rgba(var(--bg-rgb, 31, 31, 31), 0.35) 40%,
        transparent 58%
      ),
      linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, transparent 22%) !important;
  }
  .hero-content {
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    padding: 16px 20px 44px !important;
    gap: 8px !important;
    align-items: center !important;
    text-align: center !important;
  }
  .hero-slide.active .hero-logo,
  .hero-slide.active .hero-title-text,
  .hero-slide.active .hero-genres,
  .hero-slide.active .hero-excerpt,
  .hero-slide.active .hero-cta {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
  .hero-logo {
    max-height: 56px !important;
    max-width: 200px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    object-position: center center !important;
  }
  .hero-title-text {
    font-size: clamp(20px, 5.5vw, 26px) !important;
    text-align: center !important;
  }
  .hero-genres {
    font-size: 11px !important;
    text-align: center !important;
  }
  .hero-excerpt {
    font-size: 13px !important;
    line-height: 1.45 !important;
    -webkit-line-clamp: 2 !important;
    max-width: 92% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    text-align: center !important;
  }
  .hero-cta {
    display: none !important;
  }
  .hero-dots {
    gap: 0 !important;
    bottom: 6px !important;
    padding: 0 !important;
  }
  .hero-dot {
    width: 24px !important;
    height: 24px !important;
  }
  .hero-dot::before {
    width: 6px !important;
    height: 6px !important;
  }
  .hero-dot.active::before {
    transform: scale(1.25);
  }
}

@media (max-width:480px) {
  .hero {
    margin-left: -12px !important;
    margin-right: -12px !important;
  }
  .hero-track {
    height: calc(var(--tx-img-h-global, clamp(340px, 110vw, 520px)) + 64px) !important;
    min-height: 420px !important;
  }
  .hero-bg,
  .hero-scrim {
    height: var(--tx-img-h-global, clamp(340px, 110vw, 520px)) !important;
  }
}

@media (prefers-reduced-motion:reduce) {
  .hero-slide,.hero-dot span,.hero-arrow,.hero-logo,.hero-title-text,.hero-genres,.hero-excerpt,.hero-cta {
    transition:none !important;
    animation:none !important;
  }
  .hero-slide.active .hero-logo,.hero-slide.active .hero-title-text,.hero-slide.active .hero-genres,.hero-slide.active .hero-excerpt,.hero-slide.active .hero-cta {
    opacity:1 !important;
    transform:none !important;
  }
}

.hero-title-text {
  letter-spacing:-.015em;
}

/* Shared with single-post hero */
@media (max-width:960px) {
  :root {
    --tx-img-h-global: clamp(380px, 120vw, 640px);
  }
}
