/*
 * WCCM Video Testimonials, homepage social proof.
 * ─────────────────────────────────────────────────────────────────────────────
 */

.testimonials {
  background:
    radial-gradient(ellipse at 10% 0%, rgba(26, 122, 114, 0.06) 0%, transparent 50%),
    var(--color-gray-50);
}

.testimonials .section-heading__sub {
  margin-inline: auto;
}

/* ── Two-up video grid ───────────────────────────────────────────────────── */
.testi-video-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
  margin-top: var(--space-12);
}

/* ── Video card ──────────────────────────────────────────────────────────── */
.testi-video {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.testi-video__player {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--color-navy-dark);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(6, 21, 36, 0.08);
}

.testi-video__el {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--color-navy-dark);
}

/* Hide native controls until playing, custom play overlay first */
.testi-video__el:not(.is-playing) {
  /* Keep metadata frame visible under overlay */
}

.testi-video__player.is-active .testi-video__el {
  object-fit: contain;
  background: #000;
}

/* ── Custom play overlay ─────────────────────────────────────────────────── */
.testi-video__play {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  border: none;
  padding: 0;
  cursor: pointer;
  background:
    linear-gradient(160deg, rgba(6, 21, 36, 0.35) 0%, rgba(6, 21, 36, 0.55) 100%);
  color: var(--color-white);
  transition: background 0.25s ease, opacity 0.3s ease;
}

.testi-video__play:hover {
  background:
    linear-gradient(160deg, rgba(6, 21, 36, 0.25) 0%, rgba(6, 21, 36, 0.45) 100%);
}

.testi-video__play:focus-visible {
  outline: 3px solid var(--color-teal-light);
  outline-offset: -3px;
}

.testi-video__player.is-active .testi-video__play {
  opacity: 0;
  pointer-events: none;
}

.testi-video__play-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: var(--radius-full);
  background: var(--color-orange);
  color: var(--color-white);
  box-shadow: 0 8px 32px rgba(232, 98, 42, 0.45);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s ease;
}

.testi-video__play-icon svg {
  margin-left: 3px; /* optical center for play triangle */
}

.testi-video__play:hover .testi-video__play-icon {
  transform: scale(1.08);
  box-shadow: 0 12px 40px rgba(232, 98, 42, 0.55);
}

.testi-video__play-label {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
}

/* ── Meta ────────────────────────────────────────────────────────────────── */
.testi-video__meta {
  padding-inline: var(--space-1);
}

.testi-video__client {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  color: var(--color-navy);
  margin: 0 0 var(--space-1);
  letter-spacing: var(--tracking-tight);
}

.testi-video__role {
  font-size: var(--text-sm);
  color: var(--color-gray-500);
  margin: 0;
  letter-spacing: var(--tracking-wide);
}

.testi-pending {
  text-align: center;
  color: var(--color-gray-500);
  margin-top: var(--space-10);
  font-size: var(--text-base);
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 800px) {
  .testi-video-grid {
    grid-template-columns: 1fr;
    max-width: 640px;
    margin-inline: auto;
    gap: var(--space-10);
  }

  .testi-video__play-icon {
    width: 64px;
    height: 64px;
  }
}
