/* =====================================================
   Google Reviews Section  —  The RP Law Firm
   Left: Google rating badge   |   Right: scrolling reviews
   ===================================================== */

.google-review-section {
    position: relative;
    padding: 90px 0;
    background-image: url(../images/bg/testimonial-bg.webp);
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    overflow: hidden;
}

.google-review-section:before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 45, 88, .95) 0%, rgba(2, 45, 88, .88) 45%, rgba(2, 45, 88, .80) 100%);
}

.google-review-section>.container {
    position: relative;
    z-index: 2;
}

/* ---------- Left column ---------- */
.grw-left .pbmit-heading-subheading-style-1 {
    margin-bottom: 28px;
}

.grw-badge {
    position: relative;
    overflow: hidden;
    background: var(--pbmit-white-color, #fff);
    border-radius: 16px;
    padding: 36px 28px 30px;
    text-align: center;
    box-shadow: 0 18px 45px rgba(0, 0, 0, .22);
}

/* Google four-colour keyline */
.grw-badge:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4285F4 0 25%, #EA4335 25% 50%, #FBBC05 50% 75%, #34A853 75% 100%);
}

.grw-badge-logo {
    display: block;
    width: 190px;
    max-width: 75%;
    height: auto;
    margin: 0 auto 20px;
}

.grw-score-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 6px;
}

.grw-score {
    font-size: 46px;
    line-height: 1;
    font-weight: 700;
    color: var(--pbmit-blackish-color, #022d58);
    font-family: var(--pbmit-heading-typography-font-family);
}

.grw-badge-stars {
    display: flex;
    gap: 3px;
    color: #fbbc04;
    font-size: 20px;
    line-height: 1;
}

.grw-count {
    font-size: 15px;
    color: #5f6368;
    margin: 0 0 22px;
}

.grw-count strong {
    color: #022d58;
}

.grw-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background-color: #022d58;
    color: #fff;
    padding: 13px 28px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    transition: all .35s ease;
}

.grw-btn:hover,
.grw-btn:focus {
    background-color: #e0bf8c;
    color: #022d58;
}

.grw-btn svg {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
}

.grw-verified {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin: 20px 0 0;
    font-size: 13px;
    color: #5f6368;
}

.grw-verified i {
    color: #34a853;
    font-size: 14px;
}

/* ---------- Arrows ---------- */
.grw-arrows {
    position: relative;
    width: 104px;
    height: 46px;
    margin-top: 28px;
}

.grw-arrows .swiper-buttons {
    display: none;
}

/* Swiper appends "next" before "prev", so pin each one explicitly */
.grw-arrows .swiper-button-next,
.grw-arrows .swiper-button-prev {
    position: absolute;
    top: 0;
    bottom: auto;
    right: auto;
    margin: 0;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .45);
    background-color: transparent;
    transform: none;
    transition: all .35s ease;
}

.grw-arrows .swiper-button-prev {
    left: 0;
}

.grw-arrows .swiper-button-next {
    left: 58px;
}

/* base.css swaps these two glyphs — point each arrow the right way */
.grw-arrows .swiper-button-prev:after {
    content: '\e834';
}

.grw-arrows .swiper-button-next:after {
    content: '\e826';
}

.grw-arrows .swiper-button-next:hover,
.grw-arrows .swiper-button-prev:hover {
    background-color: #e0bf8c;
    border-color: #e0bf8c;
}

.grw-arrows .swiper-button-next:hover:after,
.grw-arrows .swiper-button-prev:hover:after {
    color: #022d58 !important;
}

.grw-arrows .swiper-button-next:after,
.grw-arrows .swiper-button-prev:after {
    font-size: 18px;
}

/* ---------- Right column / slider ---------- */
.grw-swiper {
    padding: 14px 0 20px;
}

.grw-swiper .swiper-slide {
    height: auto;
    display: flex;
}

.grw-card {
    position: relative;
    overflow: hidden;
    width: 100%;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 14px;
    padding: 28px 26px 24px;
    box-shadow: 0 14px 34px rgba(0, 0, 0, .16);
    transition: transform .35s ease, box-shadow .35s ease;
}

/* Google four-colour keyline, revealed on hover */
.grw-card:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #4285F4 0 25%, #EA4335 25% 50%, #FBBC05 50% 75%, #34A853 75% 100%);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform .45s ease;
}

.grw-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 22px 46px rgba(0, 0, 0, .24);
}

.grw-card:hover:before {
    transform: scaleX(1);
}

.grw-card-top {
    display: flex;
    align-items: center;
    gap: 13px;
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid #eceff2;
}

.grw-avatar {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    font-weight: 600;
    line-height: 1;
    text-transform: uppercase;
}

.grw-c1 { background-color: #1a73e8 }
.grw-c2 { background-color: #ea4335 }
.grw-c3 { background-color: #0b8043 }
.grw-c4 { background-color: #9334e6 }
.grw-c5 { background-color: #f4511e }
.grw-c6 { background-color: #00897b }

.grw-card-meta {
    min-width: 0;
}

.grw-name {
    font-size: 17px;
    line-height: 1.25;
    margin: 0 0 2px;
    color: #022d58;
    font-weight: 600;
}

.grw-date {
    display: block;
    font-size: 13px;
    line-height: 1;
    color: #5f6368;
}

.grw-gicon {
    margin-left: auto;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
}

.grw-stars {
    display: flex;
    gap: 3px;
    color: #fbbc04;
    font-size: 15px;
    line-height: 1;
    margin-bottom: 13px;
}

.grw-text-wrap {
    position: relative;
    height: 150px;
    overflow: hidden;
}

.grw-text-wrap:after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 48px;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #fff 90%);
    transition: opacity .3s ease;
}

.grw-card.is-open .grw-text-wrap {
    overflow-y: auto;
}

.grw-card.is-open .grw-text-wrap:after {
    opacity: 0;
}

.grw-text-wrap::-webkit-scrollbar {
    width: 4px;
}

.grw-text-wrap::-webkit-scrollbar-thumb {
    background: #d5d8dc;
    border-radius: 4px;
}

.grw-text {
    margin: 0;
    font-size: 15px;
    line-height: 25px;
    color: #4a4f54;
    text-align: left;
}

.grw-more {
    align-self: flex-start;
    margin-top: 14px;
    padding: 0;
    border: 0;
    background: none;
    color: #1a73e8;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.grw-more:hover {
    text-decoration: underline;
}

.grw-card.grw-no-toggle .grw-more {
    display: none;
}

.grw-card.grw-no-toggle .grw-text-wrap:after {
    opacity: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 1199px) {
    .grw-badge {
        padding: 28px 22px 26px;
    }

    .grw-score {
        font-size: 40px;
    }
}

@media (max-width: 991px) {
    .google-review-section {
        padding: 60px 0;
    }

    .google-review-section:before {
        background: rgba(2, 45, 88, .92);
    }

    .grw-left {
        margin-bottom: 35px;
    }

    .grw-arrows {
        margin: 24px auto 0;
    }
}

@media (max-width: 767px) {
    .google-review-section {
        padding: 50px 0;
    }

    .grw-card {
        padding: 24px 20px 20px;
    }

    .grw-text-wrap {
        height: 140px;
    }
}

@media (max-width: 575px) {
    .grw-badge-logo {
        width: 160px;
    }

    .grw-score {
        font-size: 36px;
    }
}
