.afce-google-reviews,
.afce-google-reviews * {
    box-sizing: border-box;
}

.afce-google-reviews {
    --afce-google-reviews-per-view: 3;
    --afce-google-reviews-gap: 20px;
    --afce-google-reviews-navy: #102544;
    --afce-google-reviews-teal: #00a99d;
    --afce-google-reviews-yellow: #fbbc04;
    --afce-google-reviews-muted: rgba(16, 37, 68, 0.62);
    --afce-google-reviews-card-bg: #f4f4f5;
    position: relative;
    width: 100%;
    color: var(--afce-google-reviews-navy);
}

.afce-google-reviews:focus-visible {
    outline: 2px solid var(--afce-google-reviews-teal);
    outline-offset: 6px;
}

.afce-google-reviews__summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 22px;
    text-align: left;
}

.afce-google-reviews__summary-score {
    font-size: clamp(34px, 4vw, 52px);
    font-weight: 800;
    line-height: 1;
    color: var(--afce-google-reviews-navy);
}

.afce-google-reviews__summary-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.afce-google-reviews__summary-stars,
.afce-google-reviews__stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    color: var(--afce-google-reviews-yellow);
    line-height: 1;
    letter-spacing: 1px;
}

.afce-google-reviews__summary-stars {
    font-size: 21px;
}

.afce-google-reviews__stars {
    font-size: 22px;
}

.afce-google-reviews__stars .is-empty,
.afce-google-reviews__summary-stars .is-empty {
    opacity: 0.24;
}

.afce-google-reviews__summary-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    font-size: 14px;
    color: var(--afce-google-reviews-muted);
}

.afce-google-reviews__summary-meta a,
.afce-google-reviews__summary-meta a:visited {
    color: var(--afce-google-reviews-teal);
    font-weight: 700;
    text-decoration: none !important;
}

.afce-google-reviews__summary-meta a:hover,
.afce-google-reviews__summary-meta a:focus-visible {
    color: var(--afce-google-reviews-navy);
}

.afce-google-reviews__viewport {
    overflow: hidden;
    width: 100%;
}

.afce-google-reviews__track {
    display: flex;
    gap: var(--afce-google-reviews-gap);
    width: 100%;
    transition: transform 420ms ease;
    will-change: transform;
}

.afce-google-reviews.is-dragging .afce-google-reviews__track {
    transition: none;
}

.afce-google-reviews__card {
    flex: 0 0 calc((100% - (var(--afce-google-reviews-gap) * (var(--afce-google-reviews-per-view) - 1))) / var(--afce-google-reviews-per-view));
    min-width: 0;
    min-height: 280px;
    padding: 24px;
    border-radius: 4px;
    background: var(--afce-google-reviews-card-bg);
    color: var(--afce-google-reviews-navy);
}

.afce-google-reviews__card-header {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.afce-google-reviews__avatar {
    width: 48px;
    height: 48px;
    border-radius: 999px;
    object-fit: cover;
    display: block;
    background: #fff;
}

.afce-google-reviews__avatar--fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    color: var(--afce-google-reviews-navy);
    border: 1px solid rgba(16, 37, 68, 0.08);
}

.afce-google-reviews__author-wrap {
    min-width: 0;
}

.afce-google-reviews__author,
.afce-google-reviews__author:visited {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--afce-google-reviews-navy);
    font-size: 16px;
    font-style: italic;
    font-weight: 800;
    line-height: 1.2;
    text-decoration: none !important;
}

.afce-google-reviews__author:hover,
.afce-google-reviews__author:focus-visible {
    color: var(--afce-google-reviews-teal);
}

.afce-google-reviews__date {
    display: block;
    margin-top: 3px;
    color: var(--afce-google-reviews-muted);
    font-size: 13px;
    font-style: italic;
    line-height: 1.2;
}

.afce-google-reviews__source,
.afce-google-reviews__source:visited {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    color: #4285f4;
    background: #fff;
    font-family: Arial, sans-serif;
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none !important;
}

.afce-google-reviews__rating-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}

.afce-google-reviews__verified {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: #4285f4;
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
}

.afce-google-reviews__text {
    color: #111827;
    font-size: clamp(17px, 1.2vw, 20px);
    font-weight: 500;
    line-height: 1.33;
}

.afce-google-reviews__text p {
    margin: 0;
}

.afce-google-reviews__text.has-more p {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.afce-google-reviews__card.is-expanded .afce-google-reviews__text.has-more p {
    display: block;
    overflow: visible;
}

.afce-google-reviews__read-more {
    margin-top: 12px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #8a8f98;
    cursor: pointer;
    font-size: 16px;
    font-style: italic;
    font-weight: 600;
    line-height: 1.2;
}

.afce-google-reviews__read-more:hover,
.afce-google-reviews__read-more:focus-visible {
    color: var(--afce-google-reviews-teal);
}

.afce-google-reviews__controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 20px;
}

.afce-google-reviews__arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #fff;
    color: rgba(16, 37, 68, 0.35);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
    transition: transform 180ms ease, color 180ms ease, opacity 180ms ease;
}

.afce-google-reviews__arrow:hover,
.afce-google-reviews__arrow:focus-visible {
    color: var(--afce-google-reviews-teal);
    transform: translateY(-1px);
}

.afce-google-reviews__arrow:disabled {
    opacity: 0.25;
    cursor: not-allowed;
    transform: none;
}

.afce-google-reviews__dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
}

.afce-google-reviews__dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(16, 37, 68, 0.24);
    cursor: pointer;
}

.afce-google-reviews__dot.is-active {
    background: var(--afce-google-reviews-teal);
}

.afce-google-reviews__admin-note,
.afce-google-reviews-empty {
    margin-top: 12px;
    padding: 12px 14px;
    border-left: 4px solid #d63638;
    background: #fff8f8;
    color: #1d2327;
    font-size: 14px;
}

@media (prefers-reduced-motion: reduce) {
    .afce-google-reviews__track,
    .afce-google-reviews__arrow {
        transition: none;
    }
}

@media (max-width: 1023px) {
    .afce-google-reviews {
        --afce-google-reviews-gap: 16px;
    }

    .afce-google-reviews__card {
        padding: 22px;
    }
}

@media (max-width: 767px) {
    .afce-google-reviews__summary {
        justify-content: flex-start;
        margin-bottom: 18px;
    }

    .afce-google-reviews__card {
        min-height: 250px;
        padding: 20px;
    }

    .afce-google-reviews__card-header {
        grid-template-columns: 44px minmax(0, 1fr) auto;
        gap: 10px;
    }

    .afce-google-reviews__avatar {
        width: 44px;
        height: 44px;
    }

    .afce-google-reviews__controls {
        margin-top: 14px;
    }

    .afce-google-reviews__arrow {
        width: auto;
        height: auto;
        min-width: 30px;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        font-size: 32px;
    }
}
