.pagination {
    display: flex;
    align-items: center;
    height: 56px;
    flex-wrap: wrap;
    flex: 1 1 100%;
    margin: 56px auto 0;
}

.pagination a > img.grey {
    display: none;
}

.pagination a[disabled] > img.grey {
    display: block;
}

.pagination a[disabled] > img.black {
    display: none;
}

.pagination .prev {
    text-align: end;
}
.pagination .next {
    text-align: start;
}
.pagination .prev, .pagination .next {
    color: #000000;
    flex: 0 1 180px;
    padding: 0;
    gap: 8px;
}

.pagination .prev[disabled], .pagination .next[disabled] {
    color: #808080;
}

.pagination a {
    font-size: 18px;
    line-height: 24px;
    font-weight: 400;
    box-sizing: border-box;
    color: #595959;
    padding: 14px 22px;
    border: 2px solid transparent;
    text-decoration: none;
    width: auto;

    display: flex;
    align-items: center;
}

.pagination a:first-child {
    margin-right: 40px;
}

.pagination a:last-child {
    margin-left: 40px;
}

.pagination a[disabled]:not(.prev, .next) {
    color: #000000;
    border-radius: 50px;
    border-color: #000000;
}

.pagination .ellipsis {
    cursor: pointer;
    color: #000000;
    margin: 0 5px;
}
.pagination .ellipsis:hover {
    text-decoration: underline;
}

@media (max-width: 900px) {
    .pagination .prev img,
    .pagination .next img {
        width: 40px;
        height: 40px;
    }

    .pagination .prev,
    .pagination .next {
        border: none;
        flex-basis: 0;
        font-size: 0;
        gap: 0;
        margin: 0 !important;
    }
    .pagination a {
        font-size: 15px;
        line-height: 20px;
        font-weight: 400;
        padding: 0 !important;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}