/* ============================================================================
   testimonials.css — Home "Google-style" client review widget
   Scope: .tm-*  (theme ke .testimonial-* classes se koi collision nahi)
   Reference: Screenshot 2026-11-06 153513.png
   ============================================================================= */

.tm-section {
    position: relative;
    padding: 70px 0 64px;
    overflow: hidden;
}

.tm-container {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ─── Summary header ─── */
.tm-summary {
    text-align: center;
    margin-bottom: 46px;
}

.tm-heading {
    margin: 0 0 10px;
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.4px;
    color: #1a2a6c;
}

.tm-summary__score {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.tm-summary__value {
    font-size: 32px;
    font-weight: 600;
    line-height: 1;
    color: #d99a00;
}

.tm-summary__source {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: #8a8f9c;
    padding: 5px 10px;
    border: 1px solid #dfe2e8;
    border-radius: 999px;
}

.tm-summary__count {
    margin: 12px 0 0;
    font-size: 17px;
    color: #6b7280;
}

.tm-summary__count strong {
    color: #4b5563;
    font-weight: 600;
}

.tm-empty {
    text-align: center;
    color: #6b7280;
    font-size: 16px;
    margin: 0;
    padding-bottom: 20px;
}

/* ─── Stars ─── */
.tm-stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.tm-stars li {
    font-size: 17px;
    line-height: 1;
}

.tm-stars--lg li {
    font-size: 25px;
}

.tm-stars li.is-filled { color: #f5a623; }
.tm-stars li.is-empty { color: #d7dae1; }

/* ─── Carousel shell ─── */
.tm-carousel-wrap {
    position: relative;
    display: flex;
    align-items: stretch;
    gap: 6px;
}

.tm-carousel {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
}

.tm-carousel .swiper-wrapper {
    align-items: stretch;
}

.tm-nav {
    flex: 0 0 34px;
    width: 34px;
    border: 0;
    background: transparent;
    color: #9aa0ad;
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s ease;
    padding: 0;
}

.tm-nav:hover,
.tm-nav:focus-visible { color: #1a2a6c; }

.tm-nav:disabled,
.tm-nav.swiper-button-disabled {
    opacity: 0.35;
    cursor: default;
}

.tm-nav:focus-visible {
    outline: 2px solid #1a2a6c;
    outline-offset: 2px;
    border-radius: 6px;
}

/* ─── Review card (flat, screenshot jaisa) ─── */
.tm-card {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 250px;
    padding: 6px 22px 10px;
    background: transparent;
    border-right: 1px solid #e7e9ee;
    box-sizing: border-box;
}

.tm-carousel .swiper-slide:last-child .tm-card { border-right: 0; }

.tm-card__head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.tm-avatar {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    background: #e8ebfb;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tm-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tm-avatar--initials {
    color: #2b3aa0;
    font-size: 15px;
    font-weight: 700;
}

.tm-card__identity {
    min-width: 0;
}

.tm-card__identity h3 {
    margin: 0 0 2px;
    font-size: 15px;
    font-weight: 700;
    color: #1a3a8f;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.tm-card__identity h3 a {
    color: inherit;
    text-decoration: none;
}

.tm-card__identity h3 a:hover,
.tm-card__identity h3 a:focus-visible { text-decoration: underline; }

.tm-card__identity time {
    font-size: 12.5px;
    color: #8a8f9c;
}

.tm-card .tm-stars { margin-bottom: 14px; }

.tm-card__review {
    margin: 0 0 16px;
    font-size: 15.5px;
    line-height: 1.55;
    color: #33383f;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
}

.tm-card__response {
    margin-top: auto;
    padding: 2px 0 2px 12px;
    border-left: 2px solid #c8ccd6;
    font-size: 13.5px;
    line-height: 1.45;
    color: #5f6570;
}

.tm-card__response-label {
    font-weight: 600;
    color: #3f444d;
}

.tm-card__response-text {
    display: block;
    overflow-wrap: anywhere;
}

/* ─── Pagination dots ─── */
.tm-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 34px;
}

.tm-pagination .tm-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #d0d3dc;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.tm-pagination .tm-dot.is-active {
    background: #2f4bd8;
    transform: scale(1.05);
}

.tm-pagination .tm-dot:focus-visible {
    outline: 2px solid #1a2a6c;
    outline-offset: 3px;
}

/* ─── Responsive ─── */
@media (max-width: 991.98px) {
    .tm-section { padding: 54px 0 50px; }
    .tm-container { padding: 0 16px; }
    .tm-card { padding: 6px 16px 10px; min-height: 0; }
}

@media (max-width: 575.98px) {
    .tm-heading { font-size: 25px; }
    .tm-summary { margin-bottom: 30px; }
    .tm-summary__value { font-size: 27px; }
    .tm-stars--lg li { font-size: 21px; }
    .tm-summary__source { display: none; }
    .tm-nav { flex-basis: 24px; width: 24px; font-size: 26px; }
    .tm-card { padding: 4px 8px 8px; }
    .tm-carousel-wrap { gap: 2px; }
}

@media (prefers-reduced-motion: reduce) {
    .tm-nav, .tm-pagination .tm-dot { transition: none; }
}
