/* Trust blocks shared by /wynajem/, /kurier/ and /serwis/ (Targetorium CRO pass, 17.10.2026):
   verbatim Google reviews, assurances under the pricing button and the mobile
   sticky request button. Loaded deferred: everything here sits below the hero. */

/* --- Google reviews: «Opinie klientów», variant C «grey panel» (Figma 3894:17816 and
   3894:17948, Danil 25.10.2026). Centred header like the pricing one; one #f4f6f2 panel
   like «Jak wynająć» and FAQ. The live rating column is the only link to Google; the three
   quotes are plain text. From 1100 px: rating column and three quote columns split by thin
   lines. 900–1099: the rating in one row above the columns. Below 900 everything stacks,
   no carousel. --- */
.reviews-section {
  padding: 72px 0;
  background: #ffffff;
  color: var(--ink);
  scroll-margin-top: var(--anchor-offset, 96px);
}

.reviews-inner {
  display: grid;
  gap: 28px;
  width: var(--page-width, min(calc(100vw - 48px), 1214px));
  margin-inline: auto;
}

/* Same header as the pricing section (.pricing-heading). */
.reviews-header {
  display: grid;
  gap: 8px;
  text-align: center;
}

.reviews-title {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--page-heading-size, 48px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.reviews-subtitle {
  margin: 0;
  color: var(--text-secondary);
  font-size: clamp(18px, 2.2vw, 30px);
  font-weight: 400;
  line-height: 1.3;
  text-wrap: balance;
}

/* Screen-reader words around the rating numbers («Ocena … otwiera się w nowej karcie»). */
.reviews-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.reviews-panel {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 32px;
  padding: 32px 8px 32px 32px;
  border-radius: var(--radius-lg);
  background: #f4f6f2;
}

/* Lime tiles with Iconsax like-1 and quote-up, as in «Dlaczego to wygodne?». */
.reviews-tile {
  display: grid;
  width: 40px;
  height: 40px;
  flex: none;
  place-items: center;
  border-radius: 8px;
  background: var(--icon-tile-bg);
}

.reviews-tile img {
  display: block;
  width: 28px;
  height: 28px;
}

/* Five stars from one file: `space` spreads them with the gap of the design. */
.reviews-stars {
  --star: 16px;
  --star-gap: 2px;
  display: block;
  flex: none;
  width: calc(var(--star) * 5 + var(--star-gap) * 4);
  height: var(--star);
  background: url("/assets/reviews/star.svg") left center / var(--star) var(--star) space no-repeat;
}

.reviews-google {
  display: block;
  flex: none;
}

/* Rating column: the whole column opens the Google profile. */
.reviews-summary {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  align-self: start;
  padding-bottom: 28px;
  border-radius: var(--radius-md);
  color: var(--ink);
  text-decoration: none;
}

.reviews-summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.reviews-summary-score {
  margin-top: 16px;
  font-size: 72px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.04em;
}

.reviews-summary-meta {
  display: grid;
  gap: 12px;
  margin-top: 10px;
}

.reviews-stars--summary {
  --star: 24px;
  --star-gap: 3px;
}

.reviews-summary-count {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 18px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
}

.reviews-summary-count .reviews-google {
  width: 18px;
  height: 18px;
}

/* Quote columns of one height; «Opinia Google» sits at the bottom of each. */
.reviews-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.review-item {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  padding-left: 32px;
  border-left: 1px solid #dde1dd;
}

.review-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}

.review-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.review-name {
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  overflow-wrap: anywhere;
}

.review-quote { margin: 0; }

.review-quote p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--text-secondary);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.45;
  text-wrap: pretty;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--quote-lines, 8);
  line-clamp: var(--quote-lines, 8);
}

.review-source {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: auto 0 0;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
}

.review-source .reviews-google {
  width: 14px;
  height: 14px;
}

/* Hover only for a mouse. */
@media (hover: hover) and (pointer: fine) {
  .reviews-summary:hover .reviews-summary-count > span { text-decoration: underline; }
}

/* 900–1099 px: the rating in one row on top, three quote columns under a thin line. */
@media (max-width: 1099px) {
  .reviews-header { margin-bottom: 8px; }
  .reviews-subtitle { max-width: 42ch; margin-inline: auto; }

  .reviews-panel {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
    padding: 32px;
  }

  .reviews-summary {
    flex-direction: row;
    align-items: center;
    gap: 16px;
    padding-bottom: 0;
  }

  .reviews-summary-score {
    margin-top: 0;
    font-size: 56px;
  }

  .reviews-summary-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 0;
  }

  .reviews-list {
    padding-top: 28px;
    border-top: 1px solid #dde1dd;
  }

  .review-item:first-child {
    padding-left: 0;
    border-left: 0;
  }

  .review-quote p { --quote-lines: 9; }
}

/* Below 900 px: the rating row, then the quotes one under another. */
@media (max-width: 899px) {
  .reviews-panel {
    gap: 20px;
    padding: 20px;
  }

  .reviews-summary { gap: 14px; }

  .reviews-tile {
    width: 36px;
    height: 36px;
    border-radius: 7px;
  }

  .reviews-tile img {
    width: 25px;
    height: 25px;
  }

  .reviews-summary-score { font-size: 44px; }

  /* Longer counts («47 reviews on Google») wrap instead of widening the page at 320 px. */
  .reviews-summary-meta {
    display: grid;
    gap: 6px;
    min-width: 0;
  }

  .reviews-stars--summary {
    --star: 16px;
    --star-gap: 2px;
  }

  .reviews-summary-count {
    gap: 6px;
    font-size: 15px;
    line-height: 1.2;
    white-space: normal;
  }

  .reviews-summary-count .reviews-google {
    width: 15px;
    height: 15px;
  }

  .reviews-list {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
    padding-top: 0;
    border-top: 0;
  }

  .review-item,
  .review-item:first-child {
    flex-direction: row;
    gap: 14px;
    padding: 20px 0 0;
    border-top: 1px solid #dde1dd;
    border-left: 0;
  }

  .review-name { font-size: 17px; }

  .review-stars { --star: 14px; }

  .review-quote p {
    --quote-lines: 5;
    font-size: 15px;
  }
}

@media (max-width: 599px) {
  .reviews-section { padding: 40px 0; }

  .reviews-inner { gap: 20px; }

  .reviews-header {
    gap: 6px;
    margin-bottom: 0;
  }

  .reviews-subtitle {
    font-size: 17px;
    line-height: 1.45;
  }
}

/* One-time entrance like the neighbouring cards (nav.js adds .is-visible; reveal.js arms
   only sections that start below the fold, so without JavaScript everything is visible). */
.reviews-section.reveal-ready .reviews-panel {
  transition: opacity 420ms var(--ease-out), transform 420ms var(--ease-out);
}

.reviews-section.reveal-ready:not(.is-visible) .reviews-panel {
  opacity: 0;
  transform: translateY(12px);
}

@media (prefers-reduced-motion: reduce) {
  .reviews-section.reveal-ready:not(.is-visible) .reviews-panel { transform: none; }
  .reviews-section.reveal-ready .reviews-panel { transition: opacity 200ms linear; }
}

/* --- Assurances under the pricing button --- */
.pricing-assurances {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pricing-assurances li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: #3c4247;
  font-size: 16px;
  font-weight: 500;
  line-height: 22px;
}

.pricing-assurances svg {
  flex: 0 0 20px;
  margin-top: 1px;
  color: var(--lime-text);
}

/* --- Mobile sticky request button --- */
.mobile-cta {
  display: none;
}

@media (max-width: 767px) {
  .mobile-cta:not([hidden]) {
    position: fixed;
    inset-inline: 0;
    bottom: 0;
    z-index: 40;
    display: block;
    padding: 10px 16px max(10px, env(safe-area-inset-bottom));
    border-top: 1px solid #e6e8e3;
    background: rgb(255 255 255 / .94);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    animation: mobile-cta-in 200ms var(--ease-out, ease-out);
  }

  /* While the bar is shown, scrolling to a focused element or an anchor stops above it. */
  html:has(.mobile-cta:not([hidden])) { scroll-padding-bottom: calc(80px + env(safe-area-inset-bottom)); }

  /* Never cover the cookie banner, an open request dialog or the mobile menu. */
  html:has([data-cookie-consent].is-visible) .mobile-cta,
  html:has(dialog[open]) .mobile-cta,
  html:has([data-mobile-menu-trigger][aria-expanded="true"]) .mobile-cta {
    display: none;
  }
}

.mobile-cta-button {
  display: flex;
  width: 100%;
  min-height: 52px;
  align-items: center;
  gap: 10px;
  padding: 6px 6px 6px 20px;
  border: 0;
  border-radius: 999px;
  background: var(--lime);
  color: var(--ink);
  font-family: inherit;
  font-size: 17px;
  font-weight: 700;
  line-height: 22px;
  cursor: pointer;
}

.mobile-cta-button > span:first-child {
  flex: 1;
  text-align: center;
}

.mobile-cta-arrow {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  background: var(--ink);
}

.mobile-cta-button:active { transform: scale(.98); }

.mobile-cta-button:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

@keyframes mobile-cta-in {
  from { transform: translateY(100%); }
  to { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-cta:not([hidden]) { animation: none; }
  .mobile-cta-button:active { transform: none; }
}
