/* SiteHQ Google Reviews — front-end styles.
   Brand: purple #5c068c (theme $primary), body grey #6d6e71, star gold #fbbc05 (Google). */

:root {
  --shq-gr-purple: #5c068c;
  --shq-gr-text: #333333;
  --shq-gr-muted: #6d6e71;
  --shq-gr-star: #fbbc05;
  --shq-gr-star-empty: #d9d9d9;
  --shq-gr-card-bg: #ffffff;
  --shq-gr-card-border: #e6e6e6;
}

/* ---------- stars ---------- */
.shq-gr-stars {
  position: relative;
  display: inline-flex;
  line-height: 0;
  vertical-align: middle;
  white-space: nowrap;
}
.shq-gr-stars__base,
.shq-gr-stars__fill {
  display: inline-flex;
  gap: 1px;
}
.shq-gr-stars__fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  overflow: hidden;
}
.shq-gr-stars svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  fill: var(--shq-gr-star-empty);
}
.shq-gr-stars__fill svg {
  fill: var(--shq-gr-star);
}
.shq-gr-stars--sm svg {
  width: 15px;
  height: 15px;
}
.shq-gr-stars--lg svg {
  width: 24px;
  height: 24px;
}

/* ---------- Google mark ---------- */
.shq-gr-gmark {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
}

/* ---------- rating badge ---------- */
.shq-gr-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--shq-gr-text);
  text-decoration: none !important;
  font-family: inherit;
  line-height: 1.2;
  max-width: 100%;
}
a.shq-gr-badge:hover,
a.shq-gr-badge:focus {
  color: var(--shq-gr-text);
  text-decoration: none;
}
a.shq-gr-badge:hover .shq-gr-badge__count,
a.shq-gr-badge:focus .shq-gr-badge__count {
  text-decoration: underline;
}

.shq-gr-badge__score {
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}
.shq-gr-badge__count {
  color: var(--shq-gr-muted);
  font-weight: 700;
}

/* badge (card) */
.shq-gr-badge--badge {
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--shq-gr-card-border);
  border-radius: 8px;
  background: var(--shq-gr-card-bg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
a.shq-gr-badge--badge:hover,
a.shq-gr-badge--badge:focus {
  box-shadow: 0 4px 14px rgba(92, 6, 140, 0.18);
  transform: translateY(-1px);
}
.shq-gr-badge--badge .shq-gr-gmark {
  width: 32px;
  height: 32px;
}
.shq-gr-badge__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.shq-gr-badge__label {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--shq-gr-purple);
}
.shq-gr-badge__row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.shq-gr-badge--badge .shq-gr-badge__score {
  font-size: 22px;
  line-height: 1;
}
.shq-gr-badge--badge .shq-gr-badge__count {
  font-size: 12px;
  font-weight: 700;
}

/* inline */
.shq-gr-badge--inline {
  gap: 6px;
  font-size: 15px;
}
.shq-gr-badge--inline .shq-gr-badge__score {
  font-size: 16px;
}
.shq-gr-badge--inline .shq-gr-badge__count {
  font-size: 13px;
}

/* compact */
.shq-gr-badge--compact {
  gap: 6px;
  font-size: 14px;
}
.shq-gr-badge--compact .shq-gr-gmark {
  width: 18px;
  height: 18px;
}

/* dark theme (purple footer bar etc.) */
.shq-gr-badge--dark,
a.shq-gr-badge--dark:hover,
a.shq-gr-badge--dark:focus {
  color: #ffffff;
}
.shq-gr-badge--dark .shq-gr-badge__label,
.shq-gr-badge--dark .shq-gr-badge__count {
  color: rgba(255, 255, 255, 0.85);
}
.shq-gr-badge--dark .shq-gr-stars svg {
  fill: rgba(255, 255, 255, 0.3);
}
.shq-gr-badge--dark .shq-gr-stars__fill svg {
  fill: var(--shq-gr-star);
}
.shq-gr-badge--dark.shq-gr-badge--badge {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: none;
}
.shq-gr-badge--dark.shq-gr-badge--badge .shq-gr-gmark {
  background: #fff;
  border-radius: 50%;
  padding: 4px;
}

/* ---------- reviews list ---------- */
.shq-gr-reviews {
  box-sizing: border-box;
  max-width: var(--wp--style--global--wide-size, 1200px);
  margin: 0 auto;
  padding: 0 16px;
}
.shq-gr-reviews * {
  box-sizing: border-box;
}
.shq-gr-reviews__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  margin-bottom: 24px;
}
.shq-gr-reviews__heading {
  margin: 0;
  color: var(--shq-gr-purple);
  font-weight: 900;
  text-transform: uppercase;
}
.shq-gr-reviews__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 768px) {
  .shq-gr-reviews--cols-2 .shq-gr-reviews__grid,
  .shq-gr-reviews--cols-3 .shq-gr-reviews__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 992px) {
  .shq-gr-reviews--cols-3 .shq-gr-reviews__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.shq-gr-review {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 20px;
  background: var(--shq-gr-card-bg);
  border: 1px solid var(--shq-gr-card-border);
  border-top: 4px solid var(--shq-gr-purple);
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  color: var(--shq-gr-text);
}
.shq-gr-review__head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.shq-gr-review__avatar {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: #f1f1f1;
}
.shq-gr-review__avatar--initial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--shq-gr-purple);
  color: #fff;
  font-weight: 900;
  font-size: 16px;
}
.shq-gr-review__meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1 1 auto;
}
.shq-gr-review__author {
  font-weight: 900;
  font-size: 15px;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.shq-gr-review__time {
  font-size: 12px;
  color: var(--shq-gr-muted);
}
.shq-gr-review__head .shq-gr-gmark {
  width: 20px;
  height: 20px;
  margin-left: auto;
}
.shq-gr-review__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--shq-gr-text);
}
.shq-gr-review--clamped .shq-gr-review__text {
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.shq-gr-review--clamped.is-open .shq-gr-review__text {
  display: block;
  -webkit-line-clamp: unset;
  overflow: visible;
}
.shq-gr-review__more {
  align-self: flex-start;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--shq-gr-purple);
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  cursor: pointer;
}
.shq-gr-review__more:hover,
.shq-gr-review__more:focus {
  text-decoration: underline;
}

/* ---------- block toolbar: star filter + sort ---------- */
.shq-gr-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  margin-bottom: 20px;
}
.shq-gr-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.shq-gr-filter__btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border: 2px solid var(--shq-gr-card-border);
  border-radius: 999px;
  background: #fff;
  color: var(--shq-gr-text);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.shq-gr-filter__btn svg {
  width: 14px;
  height: 14px;
  fill: var(--shq-gr-star);
}
.shq-gr-filter__count {
  color: var(--shq-gr-muted);
  font-weight: 400;
  font-size: 12px;
}
.shq-gr-filter__btn:hover,
.shq-gr-filter__btn:focus-visible {
  border-color: var(--shq-gr-purple);
}
.shq-gr-filter__btn.is-active {
  border-color: var(--shq-gr-purple);
  background: var(--shq-gr-purple);
  color: #fff;
}
.shq-gr-filter__btn.is-active .shq-gr-filter__count {
  color: rgba(255, 255, 255, 0.8);
}
.shq-gr-sort {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--shq-gr-muted);
}
.shq-gr-sort__select {
  padding: 6px 32px 6px 10px;
  border: 2px solid var(--shq-gr-card-border);
  border-radius: 6px;
  background: #fff;
  color: var(--shq-gr-text);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}
.shq-gr-empty {
  margin: 12px 0;
  text-align: center;
  color: var(--shq-gr-muted);
}

/* ---------- block pager ---------- */
.shq-gr-pager {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-top: 24px;
}
.shq-gr-pager__btn {
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border: 2px solid var(--shq-gr-card-border);
  border-radius: 6px;
  background: #fff;
  color: var(--shq-gr-purple);
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.shq-gr-pager__btn:hover:not(:disabled),
.shq-gr-pager__btn:focus-visible:not(:disabled) {
  border-color: var(--shq-gr-purple);
}
.shq-gr-pager__btn.is-active {
  background: var(--shq-gr-purple);
  border-color: var(--shq-gr-purple);
  color: #fff;
  cursor: default;
}
.shq-gr-pager__btn:disabled:not(.is-active) {
  opacity: 0.4;
  cursor: default;
}
.shq-gr-pager__gap {
  padding: 0 4px;
  color: var(--shq-gr-muted);
}
.shq-gr-review[hidden] {
  display: none;
}

/* ---------- editor preview ---------- */
.shq-gr-block-editor__note {
  margin: 0 0 12px;
}
.shq-gr-block-editor__empty {
  padding: 24px;
  border: 1px dashed #c3c4c7;
  text-align: center;
  color: #50575e;
}

.shq-gr-reviews__cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}
.shq-gr-btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 4px;
  font-weight: 900;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none !important;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.shq-gr-btn--solid {
  background: var(--shq-gr-purple);
  color: #fff !important;
  border: 2px solid var(--shq-gr-purple);
}
.shq-gr-btn--solid:hover,
.shq-gr-btn--solid:focus {
  background: #46066b;
  border-color: #46066b;
}
.shq-gr-btn--outline {
  background: transparent;
  color: var(--shq-gr-purple) !important;
  border: 2px solid var(--shq-gr-purple);
}
.shq-gr-btn--outline:hover,
.shq-gr-btn--outline:focus {
  background: var(--shq-gr-purple);
  color: #fff !important;
}
