/* Live-view narration captions + tap-to-hear. Presentation only. */
.hvl-narration-layer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  pointer-events: none;
}
.player.has-sponsor-slate .hvl-narration-layer,
.player.has-sponsor-slate .hvl-narration-below {
  display: none !important;
}
.hvl-narration-captions {
  position: relative;
  max-width: 80%;
  padding: 7px 28px 7px 12px;
  border-radius: 10px;
  background: rgba(8, 10, 16, 0.72);
  color: #fff;
  font-size: 15px;
  font-weight: 650;
  line-height: 1.35;
  text-align: center;
  text-wrap: balance;
  pointer-events: auto;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}
.hvl-caption-text { display: block; }
.hvl-caption-close {
  position: absolute;
  top: 2px;
  right: 2px;
  appearance: none;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  pointer-events: auto;
}
.hvl-caption-close:hover { background: rgba(255, 255, 255, 0.18); }
.hvl-narration-captions[hidden],
.hvl-narration-layer[hidden],
.hvl-narration-below[hidden],
.hvl-narration-tap[hidden] {
  display: none !important;
}
.hvl-narration-below {
  margin: 10px auto 0;
  max-width: min(80%, 720px);
}
.hvl-narration-below .hvl-narration-captions {
  max-width: 100%;
}
.hvl-narration-tap {
  pointer-events: auto;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(8, 10, 16, 0.78);
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}
.hvl-narration-tap:hover { background: rgba(8, 10, 16, 0.9); }

.hvl-player-btn.hvl-narration-intro {
  min-width: auto;
  padding: 0 10px;
  gap: 6px;
  letter-spacing: 0.01em;
}
.hvl-narration-intro-label-full { display: inline; }
.hvl-narration-intro-label-short { display: none; }

@media (max-width: 640px) {
  .hvl-narration-captions {
    max-width: min(80%, 420px);
    font-size: 13px;
    line-height: 1.3;
    padding: 6px 32px 6px 10px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .hvl-caption-text {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .hvl-caption-close {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    top: 0;
    right: 0;
  }
  .hvl-narration-layer {
    bottom: max(8px, env(safe-area-inset-bottom, 0px));
    padding-left: max(10px, env(safe-area-inset-left, 0px));
    padding-right: max(10px, env(safe-area-inset-right, 0px));
  }
  .hvl-narration-intro-label-full { display: none; }
  .hvl-narration-intro-label-short { display: inline; }
}

.player.has-player-controls .hvl-narration-layer {
  bottom: 10px;
}
.player.is-fullscreen.is-controls-visible.has-player-controls .hvl-narration-layer,
.player-shell:fullscreen .player.is-controls-visible.has-player-controls .hvl-narration-layer,
html.hvltv-ios-fullview .player.is-controls-visible.has-player-controls .hvl-narration-layer,
html.hvl-full-view .player.is-controls-visible.has-player-controls .hvl-narration-layer {
  bottom: 56px;
}
.player.is-fullscreen.is-controls-visible.has-player-controls.has-dvr .hvl-narration-layer,
.player-shell:fullscreen .player.is-controls-visible.has-player-controls.has-dvr .hvl-narration-layer,
html.hvltv-ios-fullview .player.is-controls-visible.has-player-controls.has-dvr .hvl-narration-layer,
html.hvl-full-view .player.is-controls-visible.has-player-controls.has-dvr .hvl-narration-layer {
  bottom: 100px;
}

.hvl-narration-player {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 10px 0 0;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(8, 10, 16, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  min-width: 0;
}
.hvl-narration-player[hidden] { display: none !important; }
.hvl-narration-player-toggle,
.hvl-narration-player-close {
  appearance: none;
  flex: 0 0 auto;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.hvl-narration-player-toggle:hover,
.hvl-narration-player-close:hover {
  background: rgba(255, 255, 255, 0.16);
}
.hvl-narration-player-main {
  flex: 1 1 auto;
  min-width: 0;
}
.hvl-narration-player-status {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}
.hvl-narration-player.is-error .hvl-narration-player-status {
  color: #ffb4b4;
}
.hvl-narration-player-progress {
  width: 100%;
  height: 6px;
  margin: 6px 0 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.16);
  overflow: hidden;
}
.hvl-narration-player-bar {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: #4cc9ff;
}
.hvl-narration-player-time {
  font-size: 11px;
  font-weight: 650;
  color: rgba(255, 255, 255, 0.72);
}
@media (max-width: 640px) {
  html:not(.hvltv-ios-fullview):not(.hvltv-ios-pip) .player-shell {
    display: flex;
    flex-direction: column;
    background: #000;
  }
  html:not(.hvltv-ios-fullview):not(.hvltv-ios-pip) .hvl-narration-player {
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 0;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: #000;
    padding: 8px;
    padding-left: max(8px, env(safe-area-inset-left, 0px));
    padding-right: max(8px, env(safe-area-inset-right, 0px));
  }
  .hvl-narration-player-toggle,
  .hvl-narration-player-close {
    min-width: 44px;
    min-height: 44px;
  }
}

.hvl-narration-player {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 10px 0 0;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(8, 10, 16, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
  min-width: 0;
}
.hvl-narration-player[hidden] { display: none !important; }
.hvl-narration-player-toggle,
.hvl-narration-player-close {
  appearance: none;
  flex: 0 0 auto;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.hvl-narration-player-toggle:hover,
.hvl-narration-player-close:hover {
  background: rgba(255, 255, 255, 0.16);
}
.hvl-narration-player-main {
  flex: 1 1 auto;
  min-width: 0;
}
.hvl-narration-player-status {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}
.hvl-narration-player.is-error .hvl-narration-player-status {
  color: #ffb4b4;
}
.hvl-narration-player-progress {
  width: 100%;
  height: 6px;
  margin: 6px 0 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.16);
  overflow: hidden;
}
.hvl-narration-player-bar {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: #4cc9ff;
}
.hvl-narration-player-time {
  font-size: 11px;
  font-weight: 650;
  color: rgba(255, 255, 255, 0.72);
}
@media (max-width: 640px) {
  html:not(.hvltv-ios-fullview):not(.hvltv-ios-pip) .player-shell {
    display: flex;
    flex-direction: column;
    background: #000;
  }
  html:not(.hvltv-ios-fullview):not(.hvltv-ios-pip) .hvl-narration-player {
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 0;
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: #000;
    padding: 8px;
    padding-left: max(8px, env(safe-area-inset-left, 0px));
    padding-right: max(8px, env(safe-area-inset-right, 0px));
  }
  .hvl-narration-player-toggle,
  .hvl-narration-player-close {
    min-width: 44px;
    min-height: 44px;
  }
}
