/* Product page hero and video. Loaded only on pages that use [prance_product_video]. */
:root {
  --pv-overlap: clamp(84px, 15vw, 230px);
  --pv-ground: #190A2E;
  --pv-ink: #1A0F26;
  --pv-muted: #635670;
  --pv-line: #E9E2ED;
  --pv-accent: #972371;
}

/* Hero: one headline, one sentence, one button. */
/* !important on the padding: the theme sets padding on full-width groups with a later rule. */
.pv-hero.alignfull {
  margin: 0;
  max-width: none;
  background: var(--pv-ground);
  color: #fff;
  padding: clamp(44px, 6vw, 88px) clamp(16px, 5vw, 72px) calc(var(--pv-overlap) + clamp(36px, 5vw, 64px)) !important;
}
.pv-hero__inner {
  max-width: 1120px;
  margin: 0 auto;
}
.pv-hero .pv-hero__heading {
  margin: 0;
  color: #fff;
  font-size: clamp(31px, 4.8vw, 64px);
  font-weight: 700;
  line-height: 1.24;
  letter-spacing: -0.015em;
}
.pv-hero__row.wp-block-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px 48px;
  margin-top: clamp(20px, 3vw, 36px);
}
.pv-hero .pv-hero__description {
  flex: 1 1 420px;
  max-width: 720px;
  margin: 0;
  color: #CFC6D8;
  font-size: clamp(15px, 1.3vw, 18px);
  line-height: 1.85;
}
.pv-hero .wp-block-buttons {
  margin: 0;
}
.pv-hero .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 34px;
  border-radius: 999px;
  background: #fff !important;
  background-image: none !important;
  color: var(--pv-ground) !important;
  font-size: 16px;
  font-weight: 700;
  box-shadow: none;
}
.pv-hero .wp-block-button__link:hover {
  background: #F3ECF6 !important;
}

/* Video: sits over the edge of the hero. */
.pv {
  position: relative;
  z-index: 1;
  max-width: 1120px;
  margin: calc(var(--pv-overlap) * -1) auto clamp(56px, 8vw, 104px);
  padding: 0 clamp(16px, 4vw, 40px);
  box-sizing: content-box;
  color: var(--pv-ink);
}
.pv [hidden] {
  display: none !important;
}
.pv__slot {
  aspect-ratio: 16 / 9;
  border-radius: clamp(10px, 1.4vw, 16px);
  background: #0b1121;
}
.pv__stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: inherit;
  background: #0b1121;
  box-shadow: 0 30px 80px rgba(25, 10, 46, 0.28);
}
.pv__video {
  display: block;
  width: 100%;
  height: 100%;
  /* contain, not cover: in fullscreen on a phone, cover cuts off the sides of the screen recording. */
  object-fit: contain;
  background: #0b1121;
}

/* The whole picture is the button. The visible part is a small glass pill, kept below the avatar's face. */
.pv__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100%;
  border: 0;
  padding: 0 0 clamp(14px, 11%, 76px);
  background: transparent;
  color: #fff;
  font: inherit;
  cursor: pointer;
}
.pv__play-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: clamp(40px, 4.6vw, 54px);
  padding: 0 clamp(16px, 1.8vw, 24px) 0 clamp(13px, 1.5vw, 19px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(16, 18, 30, 0.58);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  transition: background 0.2s ease, border-color 0.2s ease;
}
.pv__play-text {
  font-size: clamp(14px, 1.2vw, 16px);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}
.pv__play:hover .pv__play-pill {
  background: rgba(16, 18, 30, 0.78);
  border-color: rgba(255, 255, 255, 0.48);
}

/* When the video ends: one next step. */
.pv__end {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2vw, 24px);
  padding: 16px;
  background: rgba(25, 10, 46, 0.92);
  color: #fff;
  text-align: center;
}
.pv__end-text {
  margin: 0;
  font-size: clamp(18px, 2.4vw, 32px);
  font-weight: 700;
  line-height: 1.4;
}
.pv__end-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 12px;
}
.pv__end-cta,
.pv__replay {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 24px;
  border-radius: 999px;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.pv__end-cta,
.pv__end-cta:hover {
  background: #fff;
  color: var(--pv-ground);
}
.pv__replay {
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: transparent;
  color: #fff;
}

/* Scene buttons. */
.pv__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0 24px;
  margin-top: 12px;
  border-bottom: 1px solid var(--pv-line);
}
.pv__chapters {
  flex: 1 1 560px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  min-width: 0;
}
.pv__chapter {
  appearance: none;
  min-height: 44px;
  margin-bottom: -1px;
  padding: 16px 8px 18px 2px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.pv__chapter:hover .pv__chapter-label {
  color: var(--pv-accent);
}
.pv__chapter[aria-pressed="true"] {
  border-bottom-color: var(--pv-accent);
}
.pv__chapter-time {
  display: block;
  color: var(--pv-muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.pv__chapter-label {
  display: block;
  margin-top: 2px;
  font-size: clamp(14px, 1.2vw, 16px);
  font-weight: 700;
  line-height: 1.5;
}
.pv__pip {
  appearance: none;
  display: inline-flex;
  align-self: center;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: var(--pv-muted);
  font: inherit;
  font-size: 14px;
  white-space: nowrap;
  cursor: pointer;
}
.pv__pip:hover {
  color: var(--pv-accent);
}
.pv button:focus-visible,
.pv a:focus-visible {
  outline: 3px solid #F0A062;
  outline-offset: 2px;
}

/* Keeps playing in the corner after the visitor scrolls past it. */
.pv__stage.is-floating {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;
  width: min(380px, calc(100vw - 32px));
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  box-shadow: 0 16px 48px rgba(25, 10, 46, 0.42);
  animation: pv-float-in 0.22s ease-out;
}
@keyframes pv-float-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
.pv__close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: rgba(11, 17, 33, 0.72);
  color: #fff;
  cursor: pointer;
}

@media (max-width: 719px) {
  .pv__chapters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    flex-basis: 100%;
  }
  .pv__chapter {
    padding: 12px 8px 14px 2px;
  }
  .pv__stage.is-floating {
    right: 12px;
    bottom: 12px;
    width: min(62vw, 300px);
  }
  .pv-hero .wp-block-buttons,
  .pv-hero .wp-block-button,
  .pv-hero .wp-block-button__link {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pv__stage.is-floating { animation: none; }
  .pv__play-pill { transition: none; }
}
