/* Google Reviews Carousel - Frontend Styles */

.grc-wrapper {
    --grc-card-bg: #ffffff;
    --grc-text-color: #3c4043;
    --grc-star-color: #fbbc04;
    --grc-font-size: 14px;
    --grc-dot-color: #dadce0;
    --grc-dot-active-color: #1a73e8;
    --grc-dot-size: 10px;
    position: relative;
    padding: 10px 0;
    max-width: 100%;
    font-family: 'Google Sans', 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

.grc-title {
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    color: var(--grc-text-color);
    margin-bottom: 24px;
}

/* Swiper overrides */
.grc-swiper {
    padding-bottom: 50px !important;
    overflow: hidden;
}

.grc-swiper .swiper-slide {
    height: auto;
    display: flex;
    align-items: stretch;
}

/* Card */
.grc-card {
    background: var(--grc-card-bg);
    color: var(--grc-text-color);
    font-size: var(--grc-font-size);
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    width: 100%;
    box-sizing: border-box;
    position: relative;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.grc-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12), 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

/* Google badge */
.grc-google-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.grc-google-g {
    width: 20px;
    height: 20px;
}

.grc-google-text {
    font-size: 13px;
    font-weight: 500;
    color: #5f6368;
    letter-spacing: -0.2px;
}

/* Header */
.grc-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.grc-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.grc-avatar-fallback {
    background: #1a73e8;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 600;
}

.grc-card-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.grc-reviewer-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--grc-text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.grc-review-date {
    font-size: 12px;
    color: #70757a;
}

/* Stars */
.grc-stars {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 10px;
}

.grc-star {
    width: 18px;
    height: 18px;
}

.grc-star-filled {
    fill: var(--grc-star-color);
}

.grc-star-empty {
    fill: #dadce0;
}

/* Review text */
.grc-review-text {
    font-size: var(--grc-font-size);
    line-height: 1.6;
    color: var(--grc-text-color);
    margin-bottom: 14px;
    flex-grow: 1;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 6;
    -webkit-box-orient: vertical;
}

/* Read on Google link */
.grc-read-link {
    font-size: 13px;
    color: #1a73e8;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: auto;
    transition: color 0.2s ease;
}

.grc-read-link:hover {
    color: #174ea6;
    text-decoration: underline;
}

/* Navigation arrows: placed in side gutters outside the cards */
.grc-carousel {
    position: relative;
}

.grc-carousel.grc-has-arrows {
    padding: 0 56px;
}

.grc-carousel .swiper-button-prev,
.grc-carousel .swiper-button-next {
    position: absolute;
    top: calc(50% - 25px); /* centred on the cards, ignoring the space reserved for dots */
    margin-top: -20px;
    color: #3c4043;
    background: rgba(255, 255, 255, 0.9);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

.grc-carousel .swiper-button-prev {
    left: 0;
    right: auto;
}

.grc-carousel .swiper-button-next {
    right: 0;
    left: auto;
}

.grc-carousel .swiper-button-prev:hover,
.grc-carousel .swiper-button-next:hover {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.grc-carousel .swiper-button-prev::after,
.grc-carousel .swiper-button-next::after {
    font-size: 16px;
    font-weight: 700;
}

/* Pagination dots */
.grc-pagination.swiper-pagination {
    position: relative;
    bottom: 0;
    margin-top: 16px;
}

.grc-pagination .swiper-pagination-bullet {
    background: var(--grc-dot-color);
    opacity: 1;
    width: var(--grc-dot-size);
    height: var(--grc-dot-size);
    transition: background 0.2s ease;
}

.grc-pagination .swiper-pagination-bullet-active {
    background: var(--grc-dot-active-color);
}

/* Responsive */
@media (max-width: 767px) {
    .grc-card {
        padding: 18px;
    }

    .grc-carousel .swiper-button-prev,
    .grc-carousel .swiper-button-next {
        display: none;
    }

    .grc-carousel.grc-has-arrows {
        padding: 0;
    }

    .grc-title {
        font-size: 20px;
    }
}
