/* ==========================================================
   07 · Testimonials: one featured story (tall, cobalt wash)
   + four quote cards. Phones: swipeable snap carousel.
   ========================================================== */
.testimonials { padding: 120px 0 40px; }
.tm-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 48px; }
.tm-head > div { display: grid; gap: 20px; justify-items: start; }

.tm-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr;
  grid-auto-rows: auto;
  gap: 20px;
}
.tm-feature { grid-row: span 2; }

.tm-card {
  position: relative;
  margin: 0;
  display: flex; flex-direction: column; gap: 18px;
  padding: 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-2xl);
  box-shadow: var(--shadow-sm);
  transition: box-shadow .3s ease, transform .3s ease;
}
.tm-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

/* large decorative quote mark, tinted by the ribbon colours */
.tm-card::before {
  content: "“";
  position: absolute; right: 22px; top: 6px;
  font-family: Georgia, serif; font-size: 88px; line-height: 1;
  color: var(--cobalt-100);
  pointer-events: none;
}

.tm-tag {
  align-self: flex-start;
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 10px;
  border-radius: var(--r-pill);
  background: var(--teal-50);
  font-size: 12.5px; font-weight: 500; color: #08715F;
}
.tm-tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--teal-500); }

.tm-card blockquote {
  margin: 0; flex: 1;
  font-size: 17px; line-height: 1.55; letter-spacing: -0.005em;
  color: var(--ink-900);
  text-wrap: pretty;
}
.tm-card figcaption { display: flex; align-items: center; gap: 11px; padding-top: 16px; border-top: 1px solid var(--ink-100); }
.tm-card figcaption .av { --s: 38px; font-size: 13px; box-shadow: none; }
.tm-who { flex: 1; display: grid; }
.tm-who b { font-weight: 600; font-size: 15px; color: var(--ink-950); }
.tm-who small { font-size: 13.5px; color: var(--ink-500); }
.tm-card figcaption .lg { width: 30px; height: 30px; font-size: 13px; border-radius: 8px; }

/* ---------- Featured story ---------- */
.tm-feature {
  overflow: hidden;
  background:
    var(--wash-cobalt);
  border-color: var(--cobalt-100);
  padding: 30px;
  gap: 24px;
}
.tm-feature::before { font-size: 140px; top: 4px; color: var(--cobalt-200); }
.tf-brand { display: grid; grid-template-columns: auto 1fr; column-gap: 12px; align-items: center; }
.tf-brand .lg { grid-row: span 2; width: 44px; height: 44px; font-size: 19px; border-radius: 12px; box-shadow: inset 0 1px 0 rgba(255,255,255,.25), 0 8px 18px -6px rgba(31,86,230,.55); }
.tf-brand b { font-family: var(--font-display); font-size: 17px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink-950); }
.tf-brand small { font-size: 13.5px; color: var(--ink-500); }
.tm-feature blockquote {
  font-family: var(--font-display);
  font-size: 26px; line-height: 1.3; letter-spacing: -0.02em; font-weight: 500;
  color: var(--ink-950);
}
.tf-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0; }
.tf-stats > div { display: flex; flex-direction: column-reverse; gap: 2px; padding: 14px 16px; border-radius: 14px; background: rgba(255,255,255,.7); border: 1px solid rgba(255,255,255,.9); box-shadow: var(--shadow-xs); }
.tf-stats dd { margin: 0; font-family: var(--font-display); font-size: 30px; font-weight: 600; letter-spacing: -0.03em; color: var(--cobalt-600); font-variant-numeric: tabular-nums; }
.tf-stats dt { font-size: 13.5px; color: var(--ink-600); }
.tm-feature figcaption { border-top-color: rgba(47,107,255,.14); }

/* ---------- Responsive ---------- */
@media (max-width: 1023px) {
  .tm-grid { grid-template-columns: 1fr 1fr; }
  .tm-feature { grid-row: auto; grid-column: span 2; }
}
@media (max-width: 767px) {
  .testimonials { padding: 72px 0 24px; }
  .tm-head { flex-direction: column; align-items: flex-start; margin-bottom: 28px; }
  /* swipeable row that bleeds to the screen edge, with a peek of the next card */
  .tm-grid {
    display: flex; gap: 12px;
    margin-inline: calc(var(--gutter) * -1);
    padding: 4px var(--gutter) 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }
  .tm-grid::-webkit-scrollbar { display: none; }
  .tm-card { flex: 0 0 86%; scroll-snap-align: start; padding: 22px; border-radius: var(--r-xl); }
  .tm-card:hover { transform: none; }
  .tm-feature { padding: 22px; }
  .tm-feature::before { display: none; }
  .tm-feature blockquote { font-size: 21px; }
  .tm-card blockquote { font-size: 16px; }
  .tf-stats dd { font-size: 26px; }
}
