.media-widget {
    width: 100%;
    max-width: 1290px;

    margin: 0 auto;
    padding: 40px 0 80px;

    box-sizing: border-box;
}

.media-widget *,
.media-widget *::before,
.media-widget *::after {
    box-sizing: border-box;
}

.media-widget__grid {
    display: grid;

    grid-template-columns:
        repeat(3, 394px);

    justify-content: center;

    column-gap: 54px;
    row-gap: 44px;
}

.media-widget__card {
    display: flex;
    flex-direction: column;

    width: 394px;
    height: 376px;

    background: linear-gradient(
        105deg,
        #256f9d 0%,
        #1d5f89 45%,
        #174568 100%
    );

    overflow: hidden;
}

.media-widget__image-wrapper {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 394px;
    height: 263px;

    flex: 0 0 263px;

    background: #e9eef2;

    overflow: hidden;
}

.media-widget__image {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center;
}

.media-widget__image-placeholder {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;

    padding: 24px;

    color: #173f5c;

    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;

    text-align: center;

    background: #eef3f6;
}

.media-widget__content {
    display: flex;
    flex-direction: column;

    flex: 1;

    min-height: 113px;

    padding: 22px 20px 16px;

    background: linear-gradient(
        105deg,
        #256f9d 0%,
        #1d5f89 45%,
        #174568 100%
    );
}

.media-widget__title {
    display: -webkit-box;

    width: 100%;

    overflow: hidden;

    color: #fff;

    font-size: 20px;
    font-weight: 400;
    line-height: 1.35;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.media-widget__meta {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    width: 100%;

    margin-top: auto;
}

.media-widget__type {
    display: inline-flex;
    align-items: center;

    gap: 8px;

    color: rgba(255, 255, 255, 0.9);
}

.media-widget__type-icon {
    display: block;

    width: 21px;
    height: 21px;

    flex: 0 0 21px;
}

.media-widget__count {
    font-size: 16px;
    font-weight: 400;
    line-height: 1;
}

@media (max-width: 1360px) {

    .media-widget {
        padding-left: 24px;
        padding-right: 24px;
    }

    .media-widget__grid {
        grid-template-columns:
            repeat(3, minmax(0, 394px));

        column-gap: 32px;
    }

    .media-widget__card {
        width: 100%;
    }

    .media-widget__image-wrapper {
        width: 100%;
    }

}

@media (max-width: 1000px) {

    .media-widget__grid {
        grid-template-columns:
            repeat(2, minmax(0, 394px));
    }

}

@media (max-width: 650px) {

    .media-widget {
        padding:
            30px 16px
            60px;
    }

    .media-widget__grid {
        grid-template-columns:
            minmax(0, 394px);

        row-gap: 24px;
    }

}

@media (max-width: 430px) {

    .media-widget__card {
        width: 100%;
        height: auto;
        min-height: 0;
    }

    .media-widget__image-wrapper {
        width: 100%;
        height: auto;

        aspect-ratio: 394 / 263;

        flex-basis: auto;
    }

    .media-widget__content {
        min-height: 113px;

        padding: 20px 18px 16px;
    }

}