/**
 * Client reviews carousel — used by template-parts/global/reviews.php on every
 * surface, so this file must not depend on front-page-only styles.
 * Behaviour lives in assets/js/carousel.js.
 */
.dl-reviews {
  padding: 3rem 0;
  background: var(--cloud);
  color: var(--charcoal);
}
.dl-reviews__head {
  max-width: 36rem;
  margin: 0 auto 1.75rem;
  text-align: center;
}
.dl-reviews__eyebrow {
  margin: 0 0 0.5rem;
  color: #007da9;
  font: 700 0.72rem/1.5 var(--font-display);
  letter-spacing: 0.1em;
}
.dl-reviews__head h2 {
  margin: 0 0 0.5rem;
  color: var(--navy);
  font-size: clamp(1.5rem, 6vw, 2.2rem);
  line-height: 1.18;
}
.dl-reviews__head p {
  margin: 0;
  color: #59707f;
  font-size: 0.95rem;
}

.carousel-shell { position: relative; }
.carousel-nav { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 20px; }
.carousel-nav > button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid #c3ced8;
  border-radius: 50%;
  background: #fff;
  color: var(--navy);
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  transition: background .2s, color .2s, border-color .2s;
}
.carousel-nav > button:hover,
.carousel-nav > button:focus-visible { border-color: transparent; background: var(--cyan); color: #fff; }
.carousel-dots { display: flex; gap: 10px; }
.carousel-dots button { position: relative; width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: #a8b5c3; cursor: pointer; transition: width .2s, background .2s; }
/* Invisible 44px hit area so a 10px dot is still thumb-friendly. */
.carousel-dots button::after { content: ""; position: absolute; inset: -17px -7px; }
.carousel-dots button:hover { background: #7c8b9c; }
.carousel-dots button.is-active { width: 30px; border-radius: 5px; background: var(--cyan); }
.reviews-carousel {
  margin-top: 4px;
}
.reviews-track {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-inline: contain;
  direction: ltr;
  padding: 4px 0 8px;
}
.reviews-track::-webkit-scrollbar {
  display: none;
}
.reviews-page {
  flex: 0 0 100%;
  width: 100%;
  max-width: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: grid;
  gap: 14px;
  direction: rtl;
  min-width: 0;
  box-sizing: border-box;
}
.reviews-track .review-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 22px 20px 20px;
  border: 0;
  border-radius: 16px;
  background: #fff;
  color: var(--charcoal);
  box-shadow: 0 14px 36px -26px rgba(11, 31, 58, 0.55);
  text-align: right;
}
.reviews-track .review-card:not(.is-featured) {
  border-inline-start: 3px solid var(--cyan);
}
.reviews-track .review-card.is-featured {
  min-height: 280px;
  padding: 26px 24px 22px;
  background:
    radial-gradient(circle at 12% 88%, transparent 0 18%, rgba(0, 167, 225, 0.08) 19% 20%, transparent 21% 34%, rgba(0, 167, 225, 0.07) 35% 36%, transparent 37%),
    linear-gradient(155deg, #0a2744 0%, var(--navy) 55%, #07182c 100%);
  color: var(--cloud);
  box-shadow: 0 22px 48px -28px rgba(7, 24, 44, 0.75);
}
.reviews-track .review-card.is-featured::after {
  content: "";
  position: absolute;
  left: -40px;
  right: auto;
  bottom: -50px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 1px solid rgba(0, 167, 225, 0.22);
  box-shadow: 0 0 0 18px rgba(0, 167, 225, 0.08), 0 0 0 36px rgba(0, 167, 225, 0.05);
  pointer-events: none;
}
.quote-mark {
  display: block;
  height: 28px;
  margin-bottom: 4px;
  color: var(--cyan);
  font: 700 2.6rem/0.85 var(--font-display);
  opacity: 0.95;
}
.reviews-track .review-card.is-featured .quote-mark {
  font-size: 3.1rem;
  height: 34px;
}
.reviews-track .review-card p {
  margin: 6px 0 18px;
  font-size: 0.95rem;
  line-height: 1.7;
  flex: 1 1 auto;
}
.reviews-track .review-card.is-featured p {
  font-size: 1.05rem;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.94);
}
.reviews-track .review-card footer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
}
.reviews-track .review-card:not(.is-featured) footer {
  flex-direction: row-reverse;
  justify-content: flex-end;
}
.review-avatar {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--review-accent, var(--cyan)) 18%, #fff);
  color: var(--review-accent, var(--cyan));
  font: 700 0.85rem var(--font-display);
  letter-spacing: 0;
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--review-accent, var(--cyan)) 35%, transparent);
}
.reviews-track .review-card.is-featured .review-avatar {
  background: rgba(0, 167, 225, 0.16);
  color: #9edfff;
  box-shadow: inset 0 0 0 2px rgba(0, 167, 225, 0.35);
}
.review-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.review-meta strong {
  font-size: 0.95rem;
  line-height: 1.25;
}
.review-meta span {
  color: #68788a;
  font-size: 0.78rem;
  line-height: 1.35;
}
.reviews-track .review-card.is-featured .review-meta span {
  color: rgba(215, 225, 236, 0.78);
}
.reviews-source {
  margin: 16px 0 0;
  text-align: center;
}
.reviews-source a {
  color: #007da9;
  font-weight: 700;
  text-decoration: none;
}
.reviews-source a:hover {
  text-decoration: underline;
}
@media (min-width: 900px) {
  .reviews-page {
    direction: ltr;
    grid-template-columns: 1.2fr 0.9fr;
    grid-template-rows: 1fr 1fr;
    gap: 16px;
    min-height: 400px;
  }
  .reviews-page .review-card {
    direction: rtl;
  }
  .reviews-page .review-card.is-featured {
    grid-column: 1;
    grid-row: 1 / -1;
    min-height: 0;
    padding: 32px 28px 26px;
  }
  .reviews-page .review-card:not(.is-featured) {
    grid-column: 2;
    min-height: 0;
  }
  .reviews-page .review-card.is-featured p {
    font-size: 1.12rem;
  }
  /* Desktop has no swipe, so the arrows carry the navigation. */
  .reviews-carousel .carousel-nav {
    gap: 18px;
    margin-top: 24px;
  }
  .reviews-carousel .carousel-nav > button {
    width: 48px;
    height: 48px;
    font-size: 1.25rem;
    box-shadow: 0 10px 24px -18px rgba(11, 31, 58, 0.6);
  }
}

@media (min-width: 760px) {
  .dl-reviews { padding: 4.5rem 0; }
}
