.testimonials-section {
  background: var(--cream);
  border-block: 1px solid var(--line);
}

.testimonials-intro h2 {
  text-wrap: balance;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.testimonial-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 154px;
  gap: 24px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--paper);
  box-shadow: 0 8px 26px #273e3505;
}

.testimonial-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.testimonial-tag {
  padding: 6px 11px;
  border-radius: 30px;
  background: #e5ede1;
  color: var(--deep);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .05em;
  line-height: 1.45;
  text-transform: uppercase;
}

.testimonial-card--warm .testimonial-tag {
  background: #f9e8be;
  color: #70531e;
}

.testimonial-quote {
  margin: 24px 0 28px;
}

.testimonial-quote > p {
  font-size: clamp(1.35rem, 2.1vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.26;
  overflow-wrap: anywhere;
}

.testimonial-quote .testimonial-followup {
  margin-top: 18px;
  color: var(--muted);
  font-size: .94rem;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.6;
}

.testimonial-attribution {
  margin-top: auto;
  padding-left: 13px;
  border-left: 3px solid var(--yellow);
}

.testimonial-attribution > p {
  font-size: .86rem;
  font-weight: 700;
  line-height: 1.5;
}

.testimonial-attribution > span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.5;
}

.testimonial-evidence {
  min-width: 0;
}

.testimonial-image-link {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid #d5dcd1;
  border-radius: 11px;
  background: white;
  cursor: zoom-in;
}

.testimonial-image-link > img {
  width: 100%;
  height: auto;
}

.testimonial-zoom {
  position: absolute;
  right: 8px;
  bottom: 8px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid #ffffff70;
  border-radius: 50%;
  background: var(--deep);
  color: white;
  box-shadow: 0 2px 8px #273e3520;
}

.testimonial-zoom svg,
.testimonial-viewer-close svg {
  width: 18px;
  height: 18px;
}

.testimonial-evidence figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.5;
}

.testimonial-evidence figcaption span {
  display: block;
  margin-top: 2px;
  color: var(--ink);
  font-weight: 700;
}

.testimonials-source-note {
  margin-top: 22px;
  color: var(--muted);
  font-size: .83rem;
}

.testimonial-viewer {
  width: min(820px, calc(100% - 32px));
  height: min(92dvh, 1000px);
  max-width: none;
  max-height: none;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 18px 80px #17291d40;
}

.testimonial-viewer[open] {
  display: flex;
  flex-direction: column;
}

.testimonial-viewer::backdrop {
  background: #152d24bf;
  backdrop-filter: blur(4px);
}

html:has(.testimonial-viewer[open]) {
  overflow: hidden;
}

.testimonial-viewer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 20px 24px;
}

.testimonial-viewer-header .eyebrow {
  margin-bottom: 5px;
  font-size: .7rem;
}

.testimonial-viewer-header h2 {
  font-size: 1.3rem;
  line-height: 1.3;
}

.testimonial-viewer-close {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--pale);
  color: var(--ink);
}

.testimonial-viewer-content {
  flex: 1;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 20px;
  background: var(--pale);
}

.testimonial-viewer-content img {
  width: min(100%, 650px);
  height: auto;
  margin-inline: auto;
  border-radius: 6px;
}

.testimonial-viewer-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 15px 24px;
  color: var(--muted);
  font-size: .8rem;
  line-height: 1.5;
}

.testimonial-viewer-footer a {
  flex-shrink: 0;
  padding-block: 5px;
  color: var(--ink);
  font-weight: 700;
}

@media (max-width: 1100px) {
  .testimonials-grid {
    grid-template-columns: 1fr;
  }

  .testimonial-card {
    grid-template-columns: minmax(0, 1fr) 170px;
    gap: 32px;
  }

  .testimonial-quote > p {
    max-width: 500px;
    font-size: 1.8rem;
  }
}

@media (max-width: 520px) {
  .testimonial-card {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 23px;
    border-radius: 20px;
  }

  .testimonial-quote > p {
    font-size: 1.65rem;
  }

  .testimonial-quote .testimonial-followup {
    font-size: .94rem;
  }

  .testimonial-evidence {
    width: min(100%, 235px);
    margin-inline: auto;
  }

  .testimonial-evidence figcaption {
    text-align: center;
  }

  .testimonial-viewer-header {
    gap: 12px;
    padding: 16px;
  }

  .testimonial-viewer-header h2 {
    font-size: 1.08rem;
  }

  .testimonial-viewer-content {
    padding: 12px;
  }

  .testimonial-viewer-footer {
    flex-wrap: wrap;
    gap: 6px;
    padding: 12px 16px;
  }
}
