.testimonials-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 768px) {
    .testimonials-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .testimonials-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.testimonials-grid .testimonials-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    background: #fff;
}

.testimonials-grid .testimonials-card:nth-child(n) {
    background: #fff;
}

.testimonials-grid .testimonials-card:hover {
    z-index: 5;
    transform: none;
}

.testimonials-grid .testimonials-card > footer {
    margin-top: auto;
}

.testimonials-grid [data-testimonial-body] {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

.testimonials-grid [data-testimonial-quote] {
    flex: 1 1 auto;
    min-height: 7.5rem;
}

.testimonials-card__quote-mark {
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
    z-index: 3;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 3.25rem;
    line-height: 1;
    color: rgba(0, 168, 232, 0.16);
    pointer-events: none;
    user-select: none;
    transition: color 0.2s ease;
}

.testimonials-card:hover .testimonials-card__quote-mark {
    color: rgba(0, 168, 232, 0.24);
}

/* Read-more popup */
.testimonial-read-more-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.testimonial-read-more-modal.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.testimonial-read-more-modal__backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(15, 23, 42, 0.62);
    backdrop-filter: blur(4px);
    cursor: pointer;
}

.testimonial-read-more-modal__panel {
    position: relative;
    width: min(100%, 50rem);
    max-height: min(88vh, 44rem);
    overflow: auto;
    border-radius: 1.5rem;
    border: 1px solid rgba(226, 232, 240, 0.95);
    background: #fff;
    padding: 1.5rem;
    box-shadow: 0 24px 64px -24px rgba(15, 23, 42, 0.45);
}

@media (min-width: 640px) {
    .testimonial-read-more-modal__panel {
        padding: 2rem;
    }
}

.testimonial-read-more-modal__close {
    position: absolute;
    top: 0.875rem;
    right: 0.875rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border: 0;
    border-radius: 9999px;
    background: #f1f5f9;
    color: #475569;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.testimonial-read-more-modal__close:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.testimonial-read-more-modal__quote-mark {
    position: absolute;
    right: 1rem;
    top: 0.75rem;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 4rem;
    line-height: 1;
    color: rgba(0, 168, 232, 0.14);
    pointer-events: none;
    user-select: none;
}

.testimonial-read-more-modal__stars {
    display: flex;
    gap: 0.125rem;
    color: #fbbf24;
}

.testimonial-read-more-modal__title {
    margin-top: 1rem;
    font-size: 1.125rem;
    font-weight: 700;
    color: #0f172a;
}

.testimonial-read-more-modal__text {
    margin-top: 0.75rem;
    font-size: 1rem;
    line-height: 1.7;
    color: #334155;
}

.testimonial-read-more-modal__footer {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #f1f5f9;
}

.testimonial-read-more-modal__avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    flex-shrink: 0;
    border-radius: 9999px;
    background: linear-gradient(to bottom right, #f1f5f9, #e2e8f0);
    font-size: 0.875rem;
    font-weight: 700;
    color: #1e5aa8;
    box-shadow: 0 0 0 2px #fff;
}

.testimonial-read-more-modal__name {
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    font-style: normal;
    color: #0f172a;
}

.testimonial-read-more-modal__location {
    margin-top: 0.125rem;
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
}

body.testimonial-modal-open {
    overflow: hidden;
}
