/* H4H Step 4I.7 Fix 1 — featured cover height 20% lower. All portrait rules retained. */

/* The feature cover owns its dimensions. An absolutely positioned image cannot
   enlarge the 5:4 frame through its intrinsic portrait height or min-content size. */
body.h4h-public-home .h4h-feature-cards .h4h-card-image {
    display: block !important;
    position: relative !important;
    box-sizing: border-box !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    padding: 0 !important;
    aspect-ratio: 5 / 4 !important;
    flex: 0 0 auto !important;
    overflow: hidden !important;
}

body.h4h-public-home .h4h-feature-cards .h4h-card-image > img {
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    max-height: 100% !important;
    aspect-ratio: auto !important;
    object-fit: cover !important;
    object-position: center !important;
}

/* Keep both quotes in one overlapping grid cell. A longer quote can size the
   card instead of shrinking the portrait or colliding with the existing dots.
   Existing opacity/visibility classes and the slider JavaScript are unchanged. */
body.h4h-public-home [data-h4h-testimonials] .h4h-testimonial-card {
    display: grid;
}

body.h4h-public-home [data-h4h-testimonials] [data-h4h-testimonial] {
    position: relative;
    inset: auto;
    grid-area: 1 / 1;
    min-width: 0;
}

/* Slight increase from 88 to 104 CSS px. Reduce the bottom margin by 16px
   to retain the normal portrait-plus-gap footprint where no shrink occurred. */
body.h4h-public-home [data-h4h-testimonials] [data-h4h-testimonial] > img {
    box-sizing: border-box;
    width: 104px;
    height: 104px;
    flex: 0 0 104px;
    max-width: 104px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 22px;
}

/* Match the existing site's small-screen breakpoint. Previous size: 76px. */
@media (max-width: 560px) {
    body.h4h-public-home [data-h4h-testimonials] [data-h4h-testimonial] > img {
        width: 88px;
        height: 88px;
        flex-basis: 88px;
        max-width: 88px;
        margin-bottom: 16px;
    }
}
