/* Buddy's Auto Google Reviews — styled to match the Service Portals design language. */
.home-reviews-section,
.home-reviews-section * {
    box-sizing: border-box;
}

.home-reviews-section {
    --reviews-brand: #05dda6;
    --reviews-brand-dark: #008e69;
    --reviews-text: #1d1f21;
    --reviews-muted: #6f767d;
    --reviews-line: #e3e6e8;
    --reviews-card-line: #dde1e3;
    --reviews-star: #f4b400;
    background: #ffffff;
    border-top: 1px solid var(--reviews-line);
    color: var(--reviews-text);
    font-family: 'Open Sans', Arial, sans-serif;
}

.home-reviews-shell {
    width: 90%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 54px 0 42px;
}

.google-reviews {
    width: 100%;
}

.google-reviews-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 34px;
    padding-bottom: 22px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--reviews-line);
}

.google-reviews-heading h2 {
    margin: 0 0 7px;
    color: var(--reviews-text);
    font-size: clamp(28px, 3vw, 40px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -1px;
}

.google-reviews-heading p {
    margin: 0;
    color: var(--reviews-muted);
    font-size: 15px;
    line-height: 1.55;
}

.google-reviews-overview {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 24px;
}

.google-reviews-summary {
    min-height: 44px;
    display: grid;
    grid-template-columns: auto auto;
    grid-template-areas:
        "rating stars"
        "rating count";
    align-items: center;
    column-gap: 11px;
    row-gap: 1px;
    white-space: nowrap;
}

.google-rating-number {
    grid-area: rating;
    color: var(--reviews-text);
    font-size: 34px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -1px;
}

.google-summary-stars {
    grid-area: stars;
    color: var(--reviews-star);
    font-size: 16px;
    line-height: 1;
    letter-spacing: 1.5px;
}

.google-review-count {
    grid-area: count;
    color: var(--reviews-muted);
    font-size: 12px;
    line-height: 1.2;
}

.google-maps-label {
    display: none;
}

.google-reviews-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 9px;
}

.google-review-link {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d7dbde;
    border-radius: 5px;
    padding: 9px 14px;
    color: #242729;
    background: #ffffff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}

.google-review-link:hover {
    transform: translateY(-1px);
}

.google-review-link-secondary:hover {
    border-color: #bcc3c7;
    background: #f7f8f8;
    color: #161819;
}

.google-review-link-primary {
    border-color: var(--reviews-brand);
    background: var(--reviews-brand);
    color: #07372b;
}

.google-review-link-primary:hover {
    border-color: #00c996;
    background: #00c996;
    color: #07372b;
}

.google-review-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.google-review-card {
    position: relative;
    min-width: 0;
    min-height: 248px;
    display: flex;
    flex-direction: column;
    padding: 20px;
    background: #ffffff;
    border: 1px solid var(--reviews-card-line);
    border-radius: 5px;
    text-align: left;
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.google-review-card:hover {
    transform: translateY(-2px);
    border-color: #bcc3c7;
    box-shadow: 0 7px 20px rgba(20, 28, 33, .07);
}

.google-review-author-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.google-review-author {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 11px;
}

.google-review-avatar-link,
.google-review-avatar-fallback {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    overflow: hidden;
}

.google-review-avatar-link {
    display: block;
}

.google-review-avatar {
    width: 42px;
    height: 42px;
    display: block;
    object-fit: cover;
}

.google-review-avatar-fallback {
    display: grid;
    place-items: center;
    background: #e9fbf6;
    color: #007e5d;
    border: 1px solid #c8f3e7;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
}

.google-review-author-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.google-review-author-name {
    max-width: 100%;
    overflow: hidden;
    color: #242729;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.google-review-author-name:hover {
    color: var(--reviews-brand-dark);
}

.google-review-time {
    margin-top: 3px;
    color: #7b8287;
    font-size: 11px;
    line-height: 1.2;
}

.google-review-platform {
    flex: 0 0 auto;
    color: #8a9095;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .1px;
}

.google-review-stars {
    margin: 17px 0 11px;
    color: var(--reviews-star);
    font-size: 16px;
    line-height: 1;
    letter-spacing: 1.6px;
}

.google-review-text {
    display: -webkit-box;
    overflow: hidden;
    margin: 0 0 20px;
    color: #34383b;
    font-size: 14px;
    line-height: 1.65;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 6;
}

.google-review-card-footer {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid #eef0f1;
}

.google-review-source {
    color: var(--reviews-brand-dark);
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
}

.google-review-source::after {
    content: '  →';
}

.google-review-source:hover {
    text-decoration: underline;
}

.google-reviews-footnote {
    margin-top: 17px;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    color: #858b90;
    font-size: 11px;
    line-height: 1.45;
}

.google-reviews-status,
.google-reviews-message {
    color: var(--reviews-muted);
    font-family: 'Open Sans', Arial, sans-serif;
    font-size: 12px;
    line-height: 1.5;
}

.google-reviews-message {
    margin: 18px 0 0;
    padding: 14px 16px;
    border: 1px solid var(--reviews-line);
    border-radius: 5px;
    background: #f7f8f8;
}

@media (max-width: 1120px) {
    .google-reviews-header {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 18px;
    }

    .google-reviews-overview {
        width: 100%;
        justify-content: space-between;
    }

    .google-review-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .home-reviews-shell {
        width: 90%;
        padding: 40px 0 32px;
    }

    .google-reviews-header {
        padding-bottom: 18px;
        margin-bottom: 16px;
    }

    .google-reviews-overview {
        align-items: flex-start;
        flex-direction: column;
        gap: 15px;
    }

    .google-reviews-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .google-review-link {
        flex: 1 1 0;
    }

    .google-review-cards {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .google-review-card {
        min-height: 0;
        padding: 18px;
    }

    .google-reviews-footnote {
        flex-direction: column;
        gap: 4px;
    }
}

@media (max-width: 430px) {
    .google-reviews-heading h2 {
        font-size: 28px;
    }

    .google-rating-number {
        font-size: 31px;
    }

    .google-reviews-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .google-review-link {
        width: 100%;
    }
}
