/* Shared video + text testimonial cards (1-row slider) */
html body #testimonials.testimonials-section .testi-card {
  width: 550px !important;
  min-height: 310px !important;
  border: none !important;
  align-items: stretch;
}

html body.page-logo-design-v2 #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-mobile-application-v2 #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-social-media #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-apparel #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-ebook #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-product-packaging #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-guest-posting #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-link-building #testimonials.testimonials-section .testi-card > .testi-video,
html body.page-ppc-ads #testimonials.testimonials-section .testi-card > .testi-video,
html body #testimonials.testimonials-section .testi-card > .testi-video {
  display: block !important;
  position: relative !important;
  width: 180px !important;
  min-width: 180px !important;
  flex: 0 0 180px !important;
  align-self: stretch !important;
  min-height: 310px !important;
  padding: 0 !important;
  margin: 0 !important;
  background: transparent !important;
  overflow: hidden !important;
  text-decoration: none !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

html body #testimonials.testimonials-section .testi-video img {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center top !important;
  display: block !important;
  border: none !important;
  outline: none !important;
  opacity: 1 !important;
  transform: none !important;
}

/* Review thumbs are 9:16 portrait frames with name/title overlays baked in, so
   they must never be cropped or zoomed. */
html body #testimonials.testimonials-section .testi-card .testi-video img:not(.testi-video__logo),
html body #testimonials.testimonials-section .testi-card:hover .testi-video img:not(.testi-video__logo) {
  object-fit: contain !important;
  object-position: center center !important;
  transform: none !important;
}

html body #testimonials.testimonials-section .testi-video .testi-video-play {
  inset: auto !important;
  top: auto !important;
  left: auto !important;
  right: 10px !important;
  bottom: 10px !important;
  width: 34px !important;
  height: 34px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.95) !important;
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.18),
    0 8px 24px rgba(0, 0, 0, 0.35) !important;
}

html body #testimonials.testimonials-section .testi-video .testi-video-play::before {
  display: none !important;
}

html body #testimonials.testimonials-section .testi-video .testi-video-play::after {
  content: "" !important;
  position: static !important;
  width: 0 !important;
  height: 0 !important;
  border-top: 6px solid transparent !important;
  border-bottom: 6px solid transparent !important;
  border-left: 10px solid #454da1 !important;
  background: none !important;
  box-shadow: none !important;
  margin: 0 0 0 2px !important;
}

html body #testimonials.testimonials-section .testi-content {
  width: 100%;
  justify-content: flex-start;
  padding: 22px 24px 20px;
}

html body #testimonials.testimonials-section .testi-quote {
  font-size: 18px;
  line-height: 1.65;
  -webkit-line-clamp: 4;
  line-clamp: 4;
}

html body #testimonials.testimonials-section .testi-author {
  margin-top: auto;
  padding-top: 14px;
}

html body #testimonials.testimonials-section .testi-video-duration {
  display: none !important;
}

.pf-lightbox.pf-lightbox--shorts .pf-lightbox__youtube {
  width: min(90vw, 480px);
  height: min(88vh, 854px);
  height: min(88dvh, 854px);
  aspect-ratio: 9 / 16;
  max-height: 88vh;
  max-height: 88dvh;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
  background: #000;
}

.pf-lightbox.pf-lightbox--shorts .pf-lightbox__youtube iframe,
.pf-lightbox.pf-lightbox--shorts .pf-lightbox__youtube video {
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: contain;
  background: #000;
}

/* Custom local video player (portfolio popup) */
.pf-lightbox.pf-lightbox--shorts .pf-lightbox__youtube--player {
  position: relative;
}

.sa-vplayer {
  position: relative;
  width: 100%;
  height: 100%;
  background: #000;
  user-select: none;
}

.sa-vplayer__video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: #000;
  cursor: pointer;
}

.sa-vplayer__bigplay {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 64px;
  height: 64px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #454da1 0%, #21bfcf 100%);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(33, 191, 207, 0.35);
  opacity: 1;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 2;
}

.sa-vplayer.is-playing .sa-vplayer__bigplay {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.9);
}

.sa-vplayer__bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 28px 12px 12px;
  background: linear-gradient(180deg, transparent 0%, rgba(10, 12, 28, 0.88) 55%);
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.sa-vplayer.is-playing .sa-vplayer__bar {
  opacity: 1;
}

.sa-vplayer__btn {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.2s ease;
}

.sa-vplayer__btn:hover {
  background: rgba(33, 191, 207, 0.35);
}

.sa-vplayer__play .sa-vplayer__ico-pause,
.sa-vplayer.is-playing .sa-vplayer__play .sa-vplayer__ico-play {
  display: none;
}

.sa-vplayer.is-playing .sa-vplayer__play .sa-vplayer__ico-pause {
  display: block;
}

.sa-vplayer__mute .sa-vplayer__ico-mute,
.sa-vplayer.is-muted .sa-vplayer__mute .sa-vplayer__ico-vol {
  display: none;
}

.sa-vplayer.is-muted .sa-vplayer__mute .sa-vplayer__ico-mute {
  display: block;
}

.sa-vplayer__time {
  flex: 0 0 auto;
  min-width: 78px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.88);
  font-variant-numeric: tabular-nums;
}

.sa-vplayer__seek {
  --sa-seek: 0%;
  flex: 1 1 auto;
  min-width: 0;
  height: 4px;
  appearance: none;
  -webkit-appearance: none;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    #21bfcf 0%,
    #21bfcf var(--sa-seek),
    rgba(255, 255, 255, 0.22) var(--sa-seek),
    rgba(255, 255, 255, 0.22) 100%
  );
  outline: none;
  cursor: pointer;
}

.sa-vplayer__seek::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(33, 191, 207, 0.35);
  cursor: pointer;
}

.sa-vplayer__seek::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(33, 191, 207, 0.35);
  cursor: pointer;
}

.sa-vplayer__seek::-moz-range-track {
  background: transparent;
}

/* Landscape videos (not Shorts) */
.pf-lightbox.pf-lightbox--shorts.pf-lightbox--wide .pf-lightbox__youtube {
  width: min(92vw, 960px);
  height: auto;
  aspect-ratio: 16 / 9;
  max-height: 84vh;
}

@media (max-width: 640px) {
  html body #testimonials.testimonials-section .testi-card {
    width: 88vw !important;
  }
}
