/*
 * Ripristino della navigazione tra articoli del vecchio Savoy su Astra Child.
 * Limitato al markup .nm-post-pagination già presente in single.php.
 */

body.single-post .nm-post-pagination {
    box-sizing: border-box;
    width: 100vw;
    max-width: none;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    border-top: 1px solid #6b6b6b;
    margin-top: 45px;
    padding: 58px 0 56px;
    background: #fff;
}

body.single-post .nm-post-pagination .nm-row {
    box-sizing: border-box;
    width: calc(100% - 90px);
    max-width: 1900px;
    margin: 0 auto;
    padding: 0;
}

body.single-post .nm-post-pagination .col-xs-12 {
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    float: none;
    padding: 0;
    margin: 0;
}

body.single-post .nm-post-pagination-inner {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    min-height: 70px;
}

body.single-post .nm-post-pagination .nm-post-prev,
body.single-post .nm-post-pagination .nm-post-next {
    box-sizing: border-box;
    display: flex;
    flex: 1 1 50%;
    min-width: 0;
    margin: 0;
    padding: 0;
}

body.single-post .nm-post-pagination .nm-post-next {
    justify-content: flex-end;
    text-align: right;
}

body.single-post .nm-post-pagination .nm-post-prev a,
body.single-post .nm-post-pagination .nm-post-next a {
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    position: relative;
    max-width: 100%;
    min-height: 52px;
    color: #303030;
    text-decoration: none;
    font-size: 21px;
    font-weight: 400;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

body.single-post .nm-post-pagination .nm-post-prev a {
    padding-left: 58px;
    text-align: left;
}

body.single-post .nm-post-pagination .nm-post-next a {
    align-items: flex-end;
    padding-right: 58px;
    text-align: right;
}

body.single-post .nm-post-pagination .short-title {
    display: block;
    margin-bottom: 5px;
    color: #aaa;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.25;
    text-transform: none;
}

body.single-post .nm-post-pagination .long-title {
    display: block;
    color: #303030;
    font-size: 17px;
    font-weight: 400;
    line-height: 1.25;
    text-transform: uppercase;
}

/* Frecce sottili come nella navigazione di Savoy. */
body.single-post .nm-post-pagination .nm-post-prev a::before,
body.single-post .nm-post-pagination .nm-post-next a::after {
    content: "";
    display: block;
    position: absolute;
    top: 50%;
    width: 24px;
    height: 24px;
    border-color: #c3c3c3;
    border-style: solid;
    border-width: 0;
}

body.single-post .nm-post-pagination .nm-post-prev a::before {
    left: 5px;
    border-left-width: 2px;
    border-bottom-width: 2px;
    transform: translateY(-50%) rotate(45deg);
}

body.single-post .nm-post-pagination .nm-post-next a::after {
    right: 5px;
    border-right-width: 2px;
    border-top-width: 2px;
    transform: translateY(-50%) rotate(45deg);
}

body.single-post .nm-post-pagination a:hover .long-title,
body.single-post .nm-post-pagination a:focus .long-title {
    color: #111;
}

@media (max-width: 767px) {
    body.single-post .nm-post-pagination {
        margin-top: 30px;
        padding: 35px 0;
    }

    body.single-post .nm-post-pagination .nm-row {
        width: calc(100% - 30px);
    }

    body.single-post .nm-post-pagination-inner {
        gap: 20px;
    }

    body.single-post .nm-post-pagination .nm-post-prev a,
    body.single-post .nm-post-pagination .nm-post-next a {
        font-size: 14px;
        min-height: 50px;
    }

    body.single-post .nm-post-pagination .long-title {
        font-size: 13px;
    }

    body.single-post .nm-post-pagination .short-title {
        font-size: 12px;
    }

    body.single-post .nm-post-pagination .nm-post-prev a {
        padding-left: 25px;
    }

    body.single-post .nm-post-pagination .nm-post-next a {
        padding-right: 25px;
    }

    body.single-post .nm-post-pagination .nm-post-prev a::before,
    body.single-post .nm-post-pagination .nm-post-next a::after {
        width: 12px;
        height: 12px;
    }

    body.single-post .nm-post-pagination .nm-post-prev a::before {
        left: 2px;
    }

    body.single-post .nm-post-pagination .nm-post-next a::after {
        right: 2px;
    }
}
