/* Shared premium testimonial-card effects for the home and testimonials pages. */

.home-page .tesimoinial-style-four-area .testimonial-style-four,
.testimonials-page .reviews-grid .testimonial-style-four {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    border: 1px solid transparent;
    background:
        linear-gradient(#ffffff, #ffffff) padding-box,
        linear-gradient(135deg, rgba(37, 99, 235, 0.28), rgba(103, 68, 255, 0.12), rgba(34, 197, 94, 0.25)) border-box;
    box-shadow:
        0 16px 38px rgba(21, 48, 89, 0.09),
        0 0 0 rgba(37, 99, 235, 0);
    transition:
        transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1),
        box-shadow 0.35s ease,
        border-color 0.35s ease;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four::before,
.testimonials-page .reviews-grid .testimonial-style-four::before {
    position: absolute;
    top: 0;
    left: 10%;
    z-index: 2;
    width: 80%;
    height: 4px;
    content: "";
    border-radius: 0 0 10px 10px;
    background: linear-gradient(90deg, #2563eb, #713bff, #21c77a);
    box-shadow: 0 3px 18px rgba(74, 91, 255, 0.45);
    transform: scaleX(0.35);
    opacity: 0.55;
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four::after,
.testimonials-page .reviews-grid .testimonial-style-four::after {
    position: absolute;
    top: -90px;
    right: -80px;
    z-index: -1;
    width: 230px;
    height: 230px;
    content: "";
    border-radius: 50%;
    background: radial-gradient(circle, rgba(90, 72, 255, 0.15), rgba(37, 99, 235, 0.04) 48%, transparent 70%);
    transform: scale(0.85);
    opacity: 0.65;
    transition: transform 0.45s ease, opacity 0.45s ease;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four:hover,
.testimonials-page .reviews-grid .testimonial-style-four:hover {
    transform: translateY(-9px) scale(1.01);
    box-shadow:
        0 28px 60px rgba(21, 48, 89, 0.16),
        0 0 34px rgba(53, 104, 255, 0.18),
        0 0 48px rgba(113, 59, 255, 0.08);
}

.home-page .tesimoinial-style-four-area .testimonial-style-four:hover::before,
.testimonials-page .reviews-grid .testimonial-style-four:hover::before {
    transform: scaleX(1);
    opacity: 1;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four:hover::after,
.testimonials-page .reviews-grid .testimonial-style-four:hover::after {
    transform: scale(1.2);
    opacity: 1;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four .provider,
.testimonials-page .reviews-grid .testimonial-style-four .provider,
.home-page .tesimoinial-style-four-area .testimonial-style-four p,
.testimonials-page .reviews-grid .testimonial-style-four p {
    position: relative;
    z-index: 1;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four .provider,
.testimonials-page .reviews-grid .testimonial-style-four .provider {
    transition: transform 0.35s ease;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four:hover .provider,
.testimonials-page .reviews-grid .testimonial-style-four:hover .provider {
    transform: translateX(5px);
}

.home-page .tesimoinial-style-four-area .testimonial-style-four .quote,
.testimonials-page .reviews-grid .testimonial-style-four .quote {
    z-index: 1;
    filter: drop-shadow(0 7px 10px rgba(76, 65, 255, 0.2));
    transition: transform 0.35s ease, filter 0.35s ease;
}

.home-page .tesimoinial-style-four-area .testimonial-style-four:hover .quote,
.testimonials-page .reviews-grid .testimonial-style-four:hover .quote {
    filter: drop-shadow(0 10px 15px rgba(76, 65, 255, 0.38));
    transform: translateY(-3px) scale(1.12);
}

/* Give carousel cards room for their elevated shadow. */
.home-page .testimonial-style-four-carousel {
    margin: -18px;
    padding: 18px 18px 38px;
}

@media (max-width: 767px) {
    .home-page .testimonial-style-four-carousel {
        margin: -10px;
        padding: 10px 10px 28px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-page .tesimoinial-style-four-area .testimonial-style-four,
    .testimonials-page .reviews-grid .testimonial-style-four,
    .home-page .tesimoinial-style-four-area .testimonial-style-four::before,
    .testimonials-page .reviews-grid .testimonial-style-four::before,
    .home-page .tesimoinial-style-four-area .testimonial-style-four::after,
    .testimonials-page .reviews-grid .testimonial-style-four::after,
    .home-page .tesimoinial-style-four-area .testimonial-style-four .provider,
    .testimonials-page .reviews-grid .testimonial-style-four .provider,
    .home-page .tesimoinial-style-four-area .testimonial-style-four .quote,
    .testimonials-page .reviews-grid .testimonial-style-four .quote {
        transition: none;
    }
}
