/* EnFavori Home: mobile latest-list card standard height V7.
   Only the homepage's "Yeni eklenen listeler" carousel is affected.
   Desktop grids, content-type carousels and articles remain unchanged. */
@media (max-width:760px) {
    .ef4 .ef4-home-lists .ef4-home-list-grid > * {
        box-sizing:border-box !important;
        display:flex !important;
        flex-direction:column !important;
        width:100% !important;
        min-width:0 !important;
        height:510px !important;
        min-height:510px !important;
        max-height:510px !important;
        overflow:hidden !important;
    }

    /* Keep the image and body in their existing positions.
       Body takes the remaining space; footer stays at the bottom. */
    .ef4 .ef4-home-lists .ef4-home-list-grid > * :is(
        .card__body,
        .lab-directory-card__body,
        .lab-list-card__body,
        .list-card__body,
        .ef4-list-card__body,
        [class*="__body"]
    ) {
        display:flex;
        flex-direction:column;
        flex:1 1 auto;
        min-height:0;
        min-width:0;
    }
    .ef4 .ef4-home-lists .ef4-home-list-grid > * :is(
        .card__title,
        .lab-directory-card__title,
        .lab-list-card__title,
        .list-card__title,
        [class*="__title"],
        h2,
        h3
    ) {
        display:-webkit-box !important;
        -webkit-box-orient:vertical;
        -webkit-line-clamp:2;
        line-clamp:2;
        overflow:hidden !important;
        text-overflow:ellipsis;
        min-height:2.7em;
        max-height:2.7em !important;
        flex:0 0 auto;
        overflow-wrap:anywhere;
    }
    .ef4 .ef4-home-lists .ef4-home-list-grid > * :is(
        [class*="__description"],
        [class*="__excerpt"],
        [class*="__summary"],
        .card__desc,
        .lab-directory-card__desc
    ) {
        display:-webkit-box !important;
        -webkit-box-orient:vertical;
        -webkit-line-clamp:3;
        line-clamp:3;
        overflow:hidden !important;
        max-height:4.8em !important;
        min-height:0;
        overflow-wrap:anywhere;
    }
    .ef4 .ef4-home-lists .ef4-home-list-grid > * :is(
        [class*="__footer"],
        [class*="__foot"],
        .card__actions
    ) {
        margin-top:auto !important;
        flex-shrink:0;
    }

    /* V5 tracks keep the current card in document flow.
       Fixed card dimensions also fix the track height after swiping. */
    .ef4 .ef4-home-lists.ef4-stack--ready .ef4-stack__track > .ef4-stack__active {
        height:510px !important;
        min-height:510px !important;
        max-height:510px !important;
    }
}
