/* ==========================================================================
   1. DESKTOP & BASE STYLES (Native Nesting)
   ========================================================================== */
@media(min-width: 769px){
    .fixit-latest-post.desktop-hidden{
        display: none;
    }

    .fixit-latest-posts-carousel{
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 26px;
    }
}


@media (min-width: 769px) and (max-width: 944px) {
    .fixit-latest-posts-carousel{
        grid-template-columns: 1fr 1fr;
    }
}



.fixit-latest-post {
    a {
        display: flex;
        flex-direction: column;
        height: 100%;
        border-radius: 37px;
        overflow: hidden;
        box-shadow: 0px 3px 6px #00000029;
    }

    .fixit-latest-post-thumb {
        img {
            aspect-ratio: 520 / 237;
            width: 100%;
            height: auto;
            object-fit: cover;
            object-position: center;
        }
    }

    .fixit-latest-post-body {
        padding: 23px 23px 55px 23px;
    }

    .fixit-latest-post-title {
        font-size: 21px;
        line-height: 29px;
        font-family: var(--font-display);
        font-weight: 700;
        text-align: left;
        color: black;
        margin-bottom: 14px;
    }

    .fixit-latest-post-excerpt {
        font-size: 16px;
        line-height: 25px;
        font-family: var(--font-display);
        font-weight: 400;
        text-align: left;
        color: black;

        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .fixit-latest-post-footer {
        padding: 0px 23px 33px 23px;
        display: flex;
        justify-content: flex-end;
        align-items: center;
        gap: 9px;
        margin-top: auto;

        span {
            color: black;

            &:nth-child(1) {
                font-size: 14px;
                line-height: 23px;
                font-family: var(--font-display);
                font-weight: 400;
            }

            &:nth-child(2) {
                svg {
                    width: 20px;
                    height: 10px;
                }
            }
        }
    }


}


/* ==========================================================================
   2. MOBILE STYLES (Max-width: 768px)
   ========================================================================== */

@media (max-width: 768px) {

    .fixit-latest-post {
        a {
            margin-bottom: 20px;
            margin-inline: 3px;
            border-radius: 24px;
        }

        .fixit-latest-post-thumb {
            img {
                aspect-ratio: 346 / 160;
            }
        }

        .fixit-latest-post-body {
            padding: 12px 15px 10px 15px;
        }

        .fixit-latest-post-title {
            font-size: 16px;
            line-height: 22px;
            margin-bottom: 15px;
        }

        .fixit-latest-post-excerpt {
            font-size: 14px;
            line-height: 19px;
        }

        .fixit-latest-post-footer {
            padding: 0px 30px 15px 15px;

            span {
                &:nth-child(1) {
                    display: none;
                }

                &:nth-child(2) {
                    svg {
                        width: 27px;
                        height: 16px;
                    }
                }
            }
        }
    }

    /* Carousel / Slick Slider Mobile Overrides */
    .fixit-latest-posts-carousel {
        .slick-dots {
            display: flex;
            gap: 0px;
            justify-content: center;
            bottom: -24px;

            li{
                margin-inline: 0;
            }

            button {
                &:before {
                    font-size: 10px;
                    opacity: 0.3;
                }

                &:hover:before {
                    opacity: 0.3;
                }
            }

            .slick-active button:before {
                font-size: 14px;
                opacity: 0.6;
            }
        }
    }
}

