/* Shared render treatment for the homepage and purchase page. */
.product-media-page .product-render {
  min-width: 0;
  margin: 0;
}

.product-media-page .product-render img {
  display: block;
  width: 100%;
  height: auto;
}

.product-media-page .product-render figcaption {
  margin-top: 12px;
  color: #9cabbf;
  font-size: 12px;
  line-height: 1.5;
}

.product-media-page .product-render--hero img {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent), linear-gradient(180deg, transparent, #000 10%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent), linear-gradient(180deg, transparent, #000 10%, #000 88%, transparent);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}

.product-media-page .product-render--hero figcaption {
  margin-top: 0;
  text-align: center;
}

/* More specific than the existing hero rules, including the critical CSS. */
.sales-home.product-media-page .home-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  min-height: min(820px, 100svh);
  padding: calc(var(--home-header-height) + 48px) clamp(20px, 5vw, 72px) 54px;
}

.sales-home.product-media-page .home-hero::before {
  content: none;
}

.sales-home.product-media-page .home-hero-copy {
  width: 100%;
  padding-top: 0;
}

.sales-home.product-media-page .home-hero-brand {
  max-width: 7ch;
  font-size: clamp(3.5rem, 6.3vw, 6.5rem);
  line-height: 0.98;
}

.sales-home.product-media-page .home-hero-product {
  display: block;
  position: relative;
  z-index: 0;
  inset: auto;
  width: 100%;
  min-width: 0;
  opacity: 1;
  filter: none;
  mix-blend-mode: normal;
  -webkit-mask-image: none;
  mask-image: none;
}

.product-media-page .home-trackside {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: #04060a;
}

.product-media-page .home-trackside .product-render {
  position: relative;
}

.product-media-page .home-trackside img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center 60%;
}

.product-media-page .home-trackside .product-render::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(4, 6, 10, 0.7), transparent 45%, rgba(4, 6, 10, 0.25));
  pointer-events: none;
}

.product-media-page .home-trackside figcaption {
  position: absolute;
  right: clamp(20px, 5vw, 72px);
  bottom: 20px;
  z-index: 1;
  margin: 0;
  color: #d5deec;
  text-shadow: 0 1px 4px #000;
}

.product-media-page .home-trackside-copy {
  position: absolute;
  top: clamp(32px, 6vw, 88px);
  left: clamp(20px, 5vw, 72px);
  z-index: 1;
  max-width: 12ch;
  margin: 0;
  color: #fff;
  font-size: clamp(2rem, 4.8vw, 5rem);
  font-weight: 800;
  line-height: 1.05;
}

/* Override the shared interior-hero !important rules only on this page. */
body.purchase-page.product-media-page main {
  padding-top: 0 !important;
}

body.purchase-page.product-media-page .purchase-hero {
  min-height: min(820px, 100svh) !important;
  padding: 124px var(--interior-pad-x) 54px !important;
  background: #04060a !important;
}

body.purchase-page.product-media-page .purchase-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  align-items: center;
  gap: clamp(20px, 3vw, 48px);
  width: min(1320px, 100%) !important;
}

.product-media-page .purchase-hero-copy {
  min-width: 0;
  gap: 18px;
}

body.purchase-page.product-media-page .purchase-hero h1 {
  max-width: 12ch !important;
  font-size: clamp(2.6rem, 4.8vw, 4.8rem) !important;
  line-height: 1.02 !important;
  text-shadow: none !important;
}

body.purchase-page.product-media-page .purchase-hero p {
  margin-top: 0 !important;
  font-size: 17px !important;
  line-height: 1.5 !important;
}

body.purchase-page.product-media-page .purchase-hero .fine-print {
  font-size: 12px !important;
  font-weight: 400;
  color: #9cabbf !important;
}

.product-media-page .purchase-hero .purchase-actions {
  gap: 10px;
}

.product-media-page .product-detail-grid,
.product-media-page .product-installation-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.product-media-page .product-detail-grid .purchase-heading,
.product-media-page .product-installation-grid .purchase-heading {
  margin-bottom: 0;
}

.product-media-page .product-installation-grid {
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  margin-bottom: 40px;
}

@media (max-width: 900px) {
  .product-media-page .product-detail-grid,
  .product-media-page .product-installation-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .product-media-page .product-detail-grid .purchase-heading {
    grid-row: 1;
  }
}

@media (max-width: 720px) {
  .sales-home.product-media-page .home-hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    gap: 24px;
    padding: 108px 20px 32px;
  }

  .sales-home.product-media-page .home-hero-brand {
    max-width: none;
    margin-top: 0;
    font-size: clamp(2.5rem, 11.5vw, 4rem);
  }

  .sales-home.product-media-page .home-hero-product {
    max-width: 600px;
    justify-self: center;
  }

  body.purchase-page.product-media-page .purchase-hero {
    min-height: 0 !important;
    padding: 108px 20px 32px !important;
  }

  body.purchase-page.product-media-page .purchase-hero-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  body.purchase-page.product-media-page .purchase-hero h1 {
    max-width: 16ch !important;
    font-size: clamp(2rem, 8.5vw, 3.25rem) !important;
  }

  .product-media-page .home-trackside img {
    aspect-ratio: 4 / 5;
    object-position: right center;
  }

  .product-media-page .home-trackside-copy {
    max-width: 11ch;
  }
}
