.trendy_moving_gallery {
    --gallerygap: 20px;
    --fadecolor: rgba(0, 0, 0, 0);
    --fadesize: 200px;
    height: 400px;
}

.trendy_moving_gallery>div {
    height: 100%;
}

.trendy_moving_gallery .moving-gallery-container {
    display: grid;
    grid-template-columns: 1fr;
    overflow: hidden;
    gap: var(--gallerygap);
    height: 100%;
    width: 100%;
    position: relative;
}

.trendy_moving_gallery .moving-gallery-container::before,
.trendy_moving_gallery .moving-gallery-container::after {
    content: '';
    display: block;
    height: var(--fadesize);
    width: 100%;
    position: absolute;
    left: 0;
    top: 0;
    bottom: auto;
    background: linear-gradient(to bottom, var(--fadecolor), rgba(0, 0, 0, 0.0));
    z-index: 10;
    pointer-events: none;
}

.trendy_moving_gallery .moving-gallery-container::after {
    top: auto;
    bottom: 0;
    background: linear-gradient(to top, var(--fadecolor), rgba(0, 0, 0, 0.0));
}

.trendy_moving_gallery .moving-gallery-container[data-trendycols="2"] {
    grid-template-columns: 1fr 1fr;
}

.trendy_moving_gallery .moving-gallery-container[data-trendycols="3"] {
    grid-template-columns: 1fr 1fr 1fr;
}

.trendy_moving_gallery .moving-gallery-col {
    height: 100%;
    overflow: hidden;
}

.trendy_moving_gallery .moving-gallery-imgs {
    display: flex;
    flex-direction: column;
    gap: var(--gallerygap);
    justify-content: space-around;
    min-height: 100%;
    flex-shrink: 0;
    padding-bottom: var(--gallerygap);
    animation: trendy_moving_gallery 10s linear infinite;
}

.moving-gallery-col-2 .moving-gallery-imgs {
    animation-direction: reverse;
}

.trendy_moving_gallery .moving-gallery-imgs img {
    width: 100%;
    line-height: 0;
}

@keyframes trendy_moving_gallery {
    from {
        transform: translateY(-100%);
    }

    to {
        transform: translateY(0);
    }
}
