/* Homepage Reviews Section - mockup-aligned redesign */
/* Break out of Bootstrap .row / #post negative margins on homepage */
.hp-reviews-section {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
    background: linear-gradient(180deg, #f6f9fc 0%, #ffffff 100%);
    padding: 88px 0 96px;
    position: relative;
    overflow-x: hidden;
    overflow-y: visible;
    box-sizing: border-box;
    -webkit-text-size-adjust: 100%;
}
.hp-reviews-section::before,
.hp-reviews-section::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}
.hp-reviews-section::before {
    top: -180px;
    right: -120px;
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, rgba(44, 145, 206, 0.10) 0%, rgba(44, 145, 206, 0) 70%);
}
.hp-reviews-section::after {
    bottom: -160px;
    left: -140px;
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(249, 179, 59, 0.10) 0%, rgba(249, 179, 59, 0) 70%);
}

.hp-reviews-container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 40px;
    position: relative;
    z-index: 1;
    box-sizing: border-box;
    overflow: visible;
}

/* Header */
.hp-reviews-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 44px;
}
.hp-reviews-header-text {
    flex: 1 1 280px;
    min-width: 0;
    max-width: 100%;
}
.hp-reviews-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 16px;
    border-radius: 999px;
    background: rgba(32, 119, 186, 0.08);
    color: #2077ba;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 20px;
    max-width: 100%;
    flex-wrap: wrap;
}
.hp-reviews-badge span {
    line-height: 1.35;
}
.hp-reviews-badge i {
    font-size: 0.68rem;
    flex-shrink: 0;
}
/* Override global homepage-headings.css inside this section */
.hp-reviews-section .home-section-title,
.hp-reviews-header .home-section-title {
    margin: 0 0 14px !important;
    text-align: left !important;
    text-transform: none !important;
    font-family: 'Cormorant Garamond', Georgia, serif !important;
    font-weight: 600 !important;
    font-size: clamp(2rem, 6.5vw, 3.75rem) !important;
    line-height: 1.08 !important;
    color: #0f2438 !important;
    letter-spacing: -0.02em !important;
}
.hp-reviews-section .home-section-subtitle,
.hp-reviews-subtitle {
    margin: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    text-align: left !important;
    font-size: clamp(0.95rem, 2.8vw, 1.05rem) !important;
    line-height: 1.65 !important;
    color: #5b7186 !important;
    font-weight: 400 !important;
    letter-spacing: normal !important;
}
.hp-reviews-section .home-section-subtitle::after,
.hp-reviews-subtitle::after {
    display: none !important;
    content: none !important;
}
.hp-reviews-accent {
    display: block;
    width: 52px;
    height: 3px;
    margin-top: 22px;
    border-radius: 999px;
    background: linear-gradient(90deg, #2077ba 0%, #2c91ce 100%);
}

/* Summary card */
.hp-reviews-summary {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 26px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 18px 44px rgba(15, 42, 68, 0.10);
    border: 1px solid rgba(44, 145, 206, 0.10);
    flex-shrink: 0;
    max-width: 100%;
    box-sizing: border-box;
}
.hp-reviews-summary-main {
    text-align: center;
    min-width: 88px;
}
.hp-reviews-summary-score {
    font-size: 2.6rem;
    font-weight: 800;
    color: #0f2438;
    line-height: 1;
}
.hp-reviews-summary-stars {
    display: flex;
    gap: 2px;
    justify-content: center;
    color: #f9b33b;
    font-size: 0.92rem;
    margin: 8px 0 6px;
}
.hp-reviews-summary-count {
    font-size: 0.78rem;
    color: #7a8da0;
    font-weight: 600;
}
.hp-reviews-summary-divider {
    width: 1px;
    height: 64px;
    background: linear-gradient(180deg, transparent, rgba(15, 42, 68, 0.12), transparent);
    flex-shrink: 0;
}
.hp-reviews-summary-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: rgba(32, 119, 186, 0.08);
    color: #2077ba;
    font-size: 1.3rem;
    flex-shrink: 0;
}

/* Carousel */
.hp-reviews-carousel-wrap {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: 100%;
    min-width: 0;
}
.hp-reviews-nav {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(44, 145, 206, 0.12);
    border-radius: 50%;
    background: #fff;
    color: #2077ba;
    box-shadow: 0 8px 22px rgba(32, 119, 186, 0.12);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
    z-index: 2;
}
.hp-reviews-nav:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(32, 119, 186, 0.22);
}
.hp-reviews-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.hp-reviews-track {
    display: flex;
    gap: 22px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
    scrollbar-width: none;
    padding: 10px 6px 18px;
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    max-width: 100%;
    scroll-padding-inline: 6px;
}
.hp-reviews-track::-webkit-scrollbar {
    display: none;
}

/* Card */
.hp-review-card {
    flex: 0 0 calc((100% - 44px) / 3);
    min-width: 0;
    max-width: 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    position: relative;
    background: #fff;
    border-radius: 22px;
    padding: 28px 28px 26px;
    box-shadow: 0 14px 40px rgba(15, 42, 68, 0.07);
    border: 1px solid #eef3f8;
    display: flex;
    flex-direction: column;
    min-height: 286px;
    box-sizing: border-box;
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}
.hp-review-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 54px rgba(32, 119, 186, 0.14);
}
.hp-review-quote {
    position: absolute;
    top: 24px;
    right: 26px;
    font-size: 2.4rem;
    color: #2077ba;
    opacity: 0.10;
    line-height: 1;
}
.hp-review-card[data-channel="trustpilot"] .hp-review-quote {
    color: #00b67a;
}
.hp-review-card[data-channel="facebook"] .hp-review-quote {
    color: #1877f2;
}

.hp-review-card-top {
    margin-bottom: 12px;
}
.hp-review-author {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.hp-review-avatar-wrap {
    position: relative;
    flex-shrink: 0;
}
.hp-review-avatar {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 1.25rem;
    box-shadow: 0 6px 16px rgba(15, 42, 68, 0.12);
}
.hp-review-channel-badge {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
    font-size: 0.68rem;
}
.hp-review-channel-badge--google {
    color: #2077ba;
}
.hp-review-channel-badge--trustpilot {
    color: #00b67a;
}
.hp-review-channel-badge--facebook {
    color: #1877f2;
}

.hp-review-author-meta {
    min-width: 0;
    flex: 1;
    padding-right: 28px;
}
.hp-review-name {
    margin: 0 0 5px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f2438;
    line-height: 1.2;
    overflow-wrap: anywhere;
    word-break: break-word;
}
.hp-review-meta-line {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0.8rem;
    color: #94a3b8;
}
.hp-review-channel {
    padding: 0;
    background: none !important;
    font-weight: 600;
    font-size: 0.8rem;
}
.hp-review-channel--google {
    color: #2077ba;
}
.hp-review-channel--trustpilot {
    color: #00b67a;
}
.hp-review-channel--facebook {
    color: #1877f2;
}
.hp-review-meta-sep {
    color: #cbd5e1;
    font-weight: 700;
    line-height: 1;
}
.hp-review-date {
    font-size: 0.8rem;
    color: #94a3b8;
}

.hp-review-stars {
    display: flex;
    gap: 3px;
    color: #f9b33b;
    font-size: 0.92rem;
    margin-bottom: 16px;
}
.hp-review-stars .hp-star-empty {
    color: #e2e8f0;
}

.hp-review-text {
    margin: 0;
    flex: 1;
    padding-left: 16px;
    border-left: 3px solid #2077ba;
}
.hp-review-card[data-channel="trustpilot"] .hp-review-text {
    border-left-color: #00b67a;
}
.hp-review-card[data-channel="facebook"] .hp-review-text {
    border-left-color: #1877f2;
}
.hp-review-text p {
    margin: 0;
    color: #46586b;
    font-size: 0.98rem;
    line-height: 1.68;
    overflow-wrap: anywhere;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 6;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hp-reviews-swipe-hint {
    display: none;
    margin: 4px 0 0;
    text-align: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: #94a3b8;
    letter-spacing: 0.02em;
}

/* Footer links */
.hp-reviews-links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
    margin-top: 40px;
}
.hp-reviews-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 14px 24px;
    min-height: 48px;
    border-radius: 999px;
    font-size: 0.92rem;
    font-weight: 700;
    text-decoration: none;
    border: 1.5px solid transparent;
    box-sizing: border-box;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.hp-reviews-link:hover {
    text-decoration: none;
    transform: translateY(-2px);
}
.hp-reviews-link--google {
    background: linear-gradient(135deg, #2077ba 0%, #2c91ce 100%);
    color: #fff;
    box-shadow: 0 10px 26px rgba(32, 119, 186, 0.28);
}
.hp-reviews-link--google:hover {
    color: #fff;
    box-shadow: 0 14px 32px rgba(32, 119, 186, 0.38);
}
.hp-reviews-link--write {
    background: #fff;
    color: #2077ba;
    border-color: rgba(32, 119, 186, 0.25);
    box-shadow: none;
}
.hp-reviews-link--write:hover {
    color: #2077ba;
    border-color: #2077ba;
}
.hp-reviews-link--trustpilot {
    background: #fff;
    color: #00b67a;
    border-color: rgba(0, 182, 122, 0.4);
}
.hp-reviews-link--trustpilot:hover {
    background: #00b67a;
    color: #fff;
}
.hp-reviews-link--facebook {
    background: #fff;
    color: #1877f2;
    border-color: rgba(24, 119, 242, 0.4);
}
.hp-reviews-link--facebook:hover {
    background: #1877f2;
    color: #fff;
}

/* Responsive */
@media (max-width: 1100px) {
    .hp-review-card {
        flex: 0 0 calc((100% - 22px) / 2);
    }
}

@media (max-width: 992px) {
    .hp-reviews-container {
        padding: 0 24px;
    }
    .hp-reviews-section {
        padding: 64px 0 72px;
    }
}

@media (max-width: 768px) {
    .hp-reviews-section {
        padding: 48px 0 56px;
    }

    .hp-reviews-section::before,
    .hp-reviews-section::after {
        display: none;
    }

    .hp-reviews-container {
        padding: 0 16px;
        max-width: 100%;
    }

    .hp-reviews-header {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
        margin-bottom: 28px;
    }

    .hp-reviews-header-text {
        flex: 1 1 auto;
        width: 100%;
    }

    .hp-reviews-badge {
        font-size: 0.66rem;
        padding: 6px 12px;
        letter-spacing: 0.06em;
    }

    .hp-reviews-accent {
        margin-top: 16px;
    }

    .hp-reviews-summary {
        width: 100%;
        justify-content: center;
        padding: 16px 18px;
        gap: 14px;
        flex-wrap: wrap;
    }

    .hp-reviews-summary-score {
        font-size: 2rem;
    }

    .hp-reviews-summary-divider {
        height: 52px;
    }

    .hp-reviews-carousel-wrap {
        margin: 0;
        width: 100%;
        gap: 0;
        overflow: hidden;
    }

    .hp-reviews-nav {
        display: none;
    }

    .hp-reviews-track {
        gap: 12px;
        padding: 8px 0 20px;
        scroll-padding-inline: 0;
        scroll-snap-type: x mandatory;
    }

    .hp-review-card {
        flex: 0 0 100%;
        min-width: 0;
        max-width: 100%;
        width: 100%;
        padding: 20px 18px 18px;
        min-height: auto;
        border-radius: 18px;
        scroll-snap-align: center;
    }

    .hp-review-quote {
        top: 16px;
        right: 16px;
        font-size: 1.8rem;
    }

    .hp-review-avatar {
        width: 46px;
        height: 46px;
        font-size: 1.05rem;
    }

    .hp-review-channel-badge {
        width: 20px;
        height: 20px;
        font-size: 0.62rem;
    }

    .hp-review-author-meta {
        padding-right: 20px;
    }

    .hp-review-name {
        font-size: 0.98rem;
    }

    .hp-review-stars {
        font-size: 0.85rem;
        margin-bottom: 12px;
    }

    .hp-review-text {
        padding-left: 12px;
        border-left-width: 2px;
    }

    .hp-review-text p {
        font-size: 0.9rem;
        line-height: 1.62;
        -webkit-line-clamp: 8;
    }

    .hp-reviews-swipe-hint {
        display: block;
    }

    .hp-reviews-links {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        margin-top: 28px;
        padding: 0 2px;
    }

    .hp-reviews-link {
        width: 100%;
        font-size: 0.88rem;
        padding: 14px 18px;
    }
}

@media (max-width: 480px) {
    .hp-reviews-section {
        padding: 40px 0 48px;
    }

    .hp-reviews-container {
        padding: 0 12px;
    }

    .hp-reviews-track {
        gap: 10px;
        padding-bottom: 18px;
    }

    .hp-review-card {
        flex: 0 0 100%;
        width: 100%;
        padding: 18px 16px 16px;
    }

    .hp-review-text p {
        font-size: 0.88rem;
        -webkit-line-clamp: 7;
    }

    .hp-reviews-summary {
        padding: 14px 16px;
    }

    .hp-reviews-summary-icon {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
}

@media (max-width: 360px) {
    .hp-reviews-section .home-section-title,
    .hp-reviews-header .home-section-title {
        font-size: 1.85rem !important;
    }

    .hp-reviews-badge {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .hp-review-card {
        flex: 0 0 100%;
        width: 100%;
    }
}

@media (hover: none) and (pointer: coarse) {
    .hp-review-card:hover {
        transform: none;
        box-shadow: 0 14px 40px rgba(15, 42, 68, 0.07);
    }

    .hp-reviews-link:hover {
        transform: none;
    }
}
