/* [agm_reviews] rotating review card.
 *
 * The slides are all stacked into a single grid cell, so the card is as tall as its
 * tallest slide from first paint. Rotation only swaps which slide is visible, so the
 * height never changes and there is no layout shift — with or without JavaScript.
 */

.agm-reviews {
  position: relative;
  font-family: Georgia, serif;
  text-align: center;
  padding: 30px 26px 22px;
}

.agm-reviews--navy {
  background: #1b4e82;
  color: #fff;
}

.agm-reviews--light {
  background: #f5f8fa;
  color: #1c1c1c;
  border: 1px solid #dfe5ec;
}

/* Every slide occupies the same cell, so the container is as tall as the tallest slide.
 * align-items: center leaves the shorter slides floating in the middle of that space
 * rather than pinned to the top with a gap underneath — centred slack reads as padding,
 * bottom-anchored slack reads as a bug. Row height still comes from the tallest item,
 * so this does not reintroduce any layout shift. */
.agm-reviews-stage {
  display: grid;
  align-items: center;
}

.agm-review {
  grid-area: 1 / 1;
  margin: 0;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .35s ease;
}

.agm-review.is-active {
  opacity: 1;
  visibility: visible;
}

@media (prefers-reduced-motion: reduce) {
  .agm-review { transition: none; }
}

.agm-review-stars {
  font-size: 13px;
  letter-spacing: 2px;
  line-height: 1;
  margin: 0 0 14px;
}

.agm-reviews--navy .agm-review-stars { color: rgba(255, 255, 255, .6); }
.agm-reviews--light .agm-review-stars { color: #1b4e82; }

.agm-reviews .agm-review-quote {
  margin: 0 0 18px;
  padding: 0;
  border: 0;
  font-size: 20px;
  line-height: 1.5;
  font-style: normal;
  color: inherit;
  quotes: none;
}

.agm-review-by {
  font-weight: 700;
  font-size: 15px;
  margin: 0;
  color: inherit;
}

.agm-review-src {
  display: inline-block;
  font-weight: 400;
  font-size: 13px;
  text-decoration: none;
}

.agm-reviews--navy .agm-review-src { color: #dbeafe; }
.agm-reviews--light .agm-review-src { color: #4a6b8a; }
.agm-review-src:hover { text-decoration: underline; }

/* ---- controls: hidden until the script marks the card ready ---- */

.agm-reviews-nav {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
}

.agm-reviews.is-ready .agm-reviews-nav { display: flex; }

.agm-reviews-arrow {
  appearance: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  font-family: Georgia, serif;
  font-size: 26px;
  line-height: 1;
  padding: 0 6px;
  min-width: 30px;
  min-height: 30px;
  opacity: .65;
  transition: opacity .2s;
}

.agm-reviews--navy .agm-reviews-arrow { color: #fff; }
.agm-reviews--light .agm-reviews-arrow { color: #1b4e82; }
.agm-reviews-arrow:hover,
.agm-reviews-arrow:focus-visible { opacity: 1; }

.agm-reviews-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.agm-reviews-dot {
  appearance: none;
  border: 0;
  padding: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  cursor: pointer;
  background: currentColor;
  opacity: .35;
  transition: opacity .2s;
}

.agm-reviews--navy .agm-reviews-dot { color: #fff; }
.agm-reviews--light .agm-reviews-dot { color: #1b4e82; }
.agm-reviews-dot.is-active { opacity: 1; }
.agm-reviews-dot:hover { opacity: .7; }

.agm-reviews-arrow:focus-visible,
.agm-reviews-dot:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

@media (max-width: 600px) {
  .agm-reviews { padding: 24px 18px 18px; }
  .agm-reviews .agm-review-quote { font-size: 18px; }
}
