.success-stories-hero {
    background: linear-gradient(180deg, #fff7f9 0%, #ffffff 100%);
}

.success-stories-script {
    font-family: 'Brush Script MT', 'Segoe Script', cursive;
    font-size: 2rem;
    line-height: 1.2;
    color: var(--brand-color, #ed3e6a);
}

.success-stories-stats {
    border-radius: 12px;
}

.success-stories-stat-value {
    font-size: 1.75rem;
    line-height: 1.1;
}

.success-stories-stat-label {
    font-size: 0.75rem;
    letter-spacing: 0.06em;
}

.success-story-card {
    border-radius: 12px;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.success-story-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.1) !important;
}

.success-story-image {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 50%;
}

.success-story-author {
    width: 125px;
    text-align: center;
}

.success-story-author-name {
    font-size: 0.9rem;
    overflow-wrap: break-word;
    margin: 0.5rem 0 0.25rem;
}

/* Below lg the stats are a 2x2 grid, so the desktop border-left on the 3rd cell lands on the
   card's left edge instead of between two columns; drop it on the left column of each row. */
@media (max-width: 991.98px) {
    .success-stories-stats .row > [class*="col-"]:nth-child(odd) {
        border-left: 0 !important;
    }
}

/* Compact card on phones: everything stacks left-aligned with a smaller avatar, so two narrow
   masonry columns fit side by side without names or markers breaking apart. */
@media (max-width: 767.98px) {
    .success-story-card {
        flex-direction: column;
    }

    /* Avatar sits beside a name/marker column, so the single marker lines up under the
       username instead of dropping to its own full-width line. */
    .success-story-author {
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        width: auto;
        margin-right: 0;
        margin-bottom: 0.5rem;
        text-align: left;
    }

    .success-story-author-details {
        flex: 1;
        min-width: 0;
        margin-left: 0.5rem;
    }

    .success-story-author-name {
        margin: 0 0 0.125rem;
        font-size: 0.8rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* The narrow two-column cards leave the name very little room next to the avatar, so the
       decorative heart gives way to the name itself. */
    .success-story-author-name .fa-heart {
        display: none;
    }

    .success-story-marker {
        margin-top: 0;
        justify-content: flex-start;
    }

    .success-story-image {
        width: 36px;
        height: 36px;
    }

    .success-story-quote-icon {
        display: none;
    }

    .success-story-quote {
        font-size: 0.95rem;
    }

    .success-stories-masonry-item {
        margin-bottom: 1rem;
    }

    /* Match the card's py-2 with equal horizontal padding so the centred grid isn't tight to the
       edges. */
    .success-stories-stats {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    .success-stories-stat-value {
        font-size: 1.5rem;
        white-space: nowrap;
    }

    /* Reserve two lines so labels that wrap (e.g. "Paid to sellers") keep the same block height
       as single-line labels, so all four cells in the 2x2 grid stay aligned. */
    .success-stories-stat-label {
        font-size: 0.6rem;
        min-height: 1.8rem;
    }

    .success-stories-script {
        font-size: 1.5rem;
    }
}

/* CSS-columns masonry: cards keep their natural height and pack vertically, so a short quote
   never leaves an aligned-grid gap under its row neighbours. */
.success-stories-masonry {
    column-count: 1;
    column-gap: 1rem;
}

.success-stories-masonry-item {
    break-inside: avoid;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .success-stories-masonry {
        column-count: 1;
    }
}

@media (min-width: 992px) {
    .success-stories-masonry {
        column-count: 3;
    }
}

/* Flex children default to min-width:auto, so the no-wrap meta row would stretch the whole
   column past the card edge instead of wrapping. */
.success-story-body {
    min-width: 0;
}

.success-story-quote-icon {
    font-size: 1.5rem;
    line-height: 1;
}

.success-story-quote {
    font-size: 1.05rem;
    line-height: 1.4;
}

.success-story-marker {
    font-size: 0.75rem;
    gap: 0.125rem 0.75rem;
}

/* Centre the marker under the centred avatar/name column on desktop; scoped to the masonry
   card so the left-aligned storyMeta marker (tall cards) is unaffected, and to a min-width
   query so it doesn't override the mobile left-alignment via its higher specificity. */
@media (min-width: 768px) {
    .success-story-author .success-story-marker {
        justify-content: center;
    }
}

.success-stories-filters .btn {
    border-radius: 50rem;
}

/* Horizontal carousel: scroll-snap gives native touch swiping on mobile, while the arrow
   buttons scroll it by one card width on desktop where there is no swipe gesture. */
.success-stories-carousel {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    padding-bottom: 0.5rem;
}

.success-stories-carousel::-webkit-scrollbar {
    display: none;
}

.success-stories-carousel > * {
    flex: 0 0 85%;
    scroll-snap-align: start;
}

.success-stories-carousel-arrow {
    width: 40px;
    height: 40px;
    padding: 0;
    line-height: 1;
    border-radius: 50%;
    z-index: 2;
}

.success-story-card-tall {
    overflow: hidden;
}

.success-story-image-wide {
    width: 100%;
    height: 170px;
    object-fit: cover;
}

.success-story-read {
    font-size: 0.75rem;
}

.success-stories-more {
    border-radius: 12px;
    overflow: hidden;
}

/* Sits over the right edge of the track; must stay fully inside the block because the
   surrounding .success-stories-more clips overflow for its rounded corners. */
.success-stories-carousel-arrow-floating {
    position: absolute;
    top: 50%;
    right: 0.75rem;
    transform: translateY(-50%);
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.2);
}

.success-stories-carousel-arrow-floating-left {
    right: auto;
    left: 0.75rem;
}

.success-stories-dot {
    width: 8px;
    height: 8px;
    padding: 0;
    margin: 0 4px;
    border: 0;
    border-radius: 50%;
    background-color: #d5d5d5;
}

.success-stories-dot.active {
    background-color: var(--brand-color, #ed3e6a);
}

.success-stories-cta {
    background-color: #16151a;
    border-radius: 12px;
}

@media (min-width: 768px) {
    .success-stories-carousel > * {
        flex-basis: 45%;
    }
}

@media (min-width: 992px) {
    .success-stories-script {
        font-size: 2.5rem;
    }

    .success-stories-carousel > * {
        flex-basis: 31%;
    }
}
