/*
 * V3 section package: hero
 *
 * CSS isolation: every selector rooted under
 *   .pd-section--hero[data-pd-module]
 *
 * Class/attribute selectors only - no element selectors.
 *
 * Canonical tokens used:
 *   --pd-color-text, --pd-color-muted, --pd-color-surface,
 *   --pd-color-surface-alt, --pd-color-primary, --pd-color-secondary,
 *   --pd-color-accent
 *   --pd-font-heading, --pd-font-body
 *   --pd-radius-sm, --pd-radius-md, --pd-radius-lg
 *   --pd-space-2, --pd-space-3, --pd-space-4, --pd-space-5,
 *   --pd-space-6, --pd-space-8
 *
 * Variants:
 *   stacked-centered  single column, centered text, no media column
 *   split-media       text column next to media column on wide screens
 *   banner-wide       full-bleed background media with overlaid text
 */

.pd-section--hero[data-pd-module] {
  display: block;
  position: relative;
  width: 100%;
  background: var(--pd-color-surface);
  color: var(--pd-color-text);
  font-family: var(--pd-font-body);
  box-sizing: border-box;
  --pd-hero-height: clamp(20rem, 40vw, 36rem);
  --pd-hero-overlay-opacity: 0.45;
  --pd-hero-font-heading: var(--pd-font-heading);
}

.pd-section--hero[data-pd-module] .pd-hero__inner {
  display: grid;
  gap: var(--pd-space-6);
}

.pd-section--hero[data-pd-module] .pd-hero__text {
  display: flex;
  flex-direction: column;
  gap: var(--pd-space-4);
}

.pd-section--hero[data-pd-module] .pd-hero__eyebrow {
  margin: 0;
  font-family: var(--pd-font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pd-color-accent);
}

.pd-section--hero[data-pd-module] .pd-hero__headline {
  margin: 0;
  font-family: var(--pd-hero-font-heading);
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  line-height: 1.1;
  font-weight: 700;
  color: var(--pd-color-text);
}

.pd-section--hero[data-pd-module] .pd-hero__headline--placeholder {
  color: var(--pd-color-muted);
  font-style: italic;
  opacity: 0.7;
}

.pd-section--hero[data-pd-module] .pd-hero__subheadline {
  margin: 0;
  font-size: 1.125rem;
  line-height: 1.5;
  color: var(--pd-color-muted);
  max-width: 42rem;
}

.pd-section--hero[data-pd-module] .pd-hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--pd-space-3);
  margin-top: var(--pd-space-2);
}

/* PASS 4BN: hero CTAs now compose .pd-button + .pd-button--primary /
 * .pd-button--ghost. The button visual styling (padding, radius,
 * background, color, hover, focus, transition) lives in
 * components.css. The section-level classes survive purely as
 * layout / placement hooks and have no visual declarations. */

.pd-section--hero[data-pd-module] .pd-hero__cta-label {
  display: inline-block;
}

.pd-section--hero[data-pd-module] .pd-hero__media {
  border-radius: var(--pd-radius-lg);
  overflow: hidden;
  background: var(--pd-color-surface-alt);
  aspect-ratio: 4 / 3;
}

.pd-section--hero[data-pd-module] .pd-hero__media-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Variant: stacked-centered */
.pd-section--hero[data-pd-module][data-pd-variant="stacked-centered"] .pd-hero__inner {
  grid-template-columns: 1fr;
  text-align: center;
  justify-items: center;
}

.pd-section--hero[data-pd-module][data-pd-variant="stacked-centered"] .pd-hero__subheadline {
  margin-inline: auto;
}

.pd-section--hero[data-pd-module][data-pd-variant="stacked-centered"] .pd-hero__ctas {
  justify-content: center;
}

/* Variant: split-media */
.pd-section--hero[data-pd-module][data-pd-variant="split-media"] .pd-hero__inner {
  grid-template-columns: 1fr;
  align-items: center;
}

.pd-section--hero[data-pd-module][data-pd-variant="split-media"][data-has-media="false"] .pd-hero__inner {
  grid-template-columns: 1fr;
}

@media (min-width: 60rem) {
  .pd-section--hero[data-pd-module][data-pd-variant="split-media"][data-has-media="true"] .pd-hero__inner {
    grid-template-columns: 1fr 1fr;
  }
}

/* Variant: banner-wide */
.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] {
  min-height: var(--pd-hero-height);
  display: flex;
  align-items: center;
  padding-block: var(--pd-space-8);
  color: #ffffff;
  background-color: var(--pd-color-surface-alt);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  overflow: hidden;
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, var(--pd-hero-overlay-opacity));
  pointer-events: none;
}

.pd-section--hero[data-pd-module][data-pd-variant="split-media"] {
  min-height: var(--pd-hero-height);
}

.pd-section--hero[data-pd-module][data-headline-animation="fade-up"] .pd-hero__headline {
  animation: pd-hero-headline-fade-up 480ms ease-out both;
}

.pd-section--hero[data-pd-module][data-headline-animation="drop-in"] .pd-hero__headline {
  animation: pd-hero-headline-drop-in 420ms ease-out both;
}

.pd-section--hero[data-pd-module][data-headline-animation="zoom-in"] .pd-hero__headline {
  animation: pd-hero-headline-zoom-in 420ms ease-out both;
}

@keyframes pd-hero-headline-fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pd-hero-headline-drop-in {
  from { opacity: 0; transform: translateY(-12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pd-hero-headline-zoom-in {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__inner {
  position: relative;
  z-index: 1;
  text-align: center;
  grid-template-columns: 1fr;
  justify-items: center;
  max-width: 56rem;
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__headline {
  color: #ffffff;
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__headline--placeholder {
  color: rgba(255, 255, 255, 0.75);
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__subheadline {
  color: rgba(255, 255, 255, 0.88);
  max-width: 42rem;
  margin-inline: auto;
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__eyebrow {
  color: #ffffff;
  opacity: 0.85;
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__ctas {
  justify-content: center;
}

/* PASS 4BN allowlist: banner-wide hero renders CTAs over a dark
 * background-image scrim, NOT a [data-background-tone="primary"]
 * surface. Shared tone-aware contrast rules in components.css don't
 * trip here, so banner-wide keeps its own contrast adjustments for
 * the secondary CTA's white border + transparent fill. The primary
 * CTA inherits the standard surface-on-primary inversion via
 * .pd-button--primary. */
.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__cta--secondary {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.7);
}

.pd-section--hero[data-pd-module][data-pd-variant="banner-wide"] .pd-hero__cta--secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Respect reduced-motion preference. Hero headline animation is
 * package-specific; CTA transition/hover-transform now come from
 * .pd-button so the reduced-motion override for those lives in
 * components.css. */
@media (prefers-reduced-motion: reduce) {
  .pd-section--hero[data-pd-module] .pd-hero__headline {
    animation: none !important;
  }
}
