:root {
    --next-block-width: 100%;
    --next-block-max-height: 600px;

    --next-block-background: inherit;
    --next-block-gradient: none;
}

.next-block {
    width: var(--next-block-width);
    display: flex;
    flex-direction: column;
}

.next-block__container {
    position: relative;
    flex: 1;
    max-height: var(--next-block-max-height);
    overflow: hidden;
    transition: max-height 1600ms ease-in-out;
}

.next-block__container::after {
    content: '';
    display: block;
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 40px;
    /* mask-image: linear-gradient(180deg, #000 0%, #000 65%, transparent 92%, transparent 100%);
    mask-repeat: no-repeat; */

    /* background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, var(--bg_page) 80%); */


    /* Для плавного исчезновения текста */
    -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-size: 100% 100%;

    /* Для Firefox */
    mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    mask-repeat: no-repeat;
    mask-size: 100% 100%;
}

.next-block__footer {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}