
/* =========================================================
   HOUSERENOFIX — POST FORMAT
   ========================================================= */

body.single-post{
    overflow-x:hidden !important;
}

/* Keep the post content inside its column */
body.single-post article,
body.single-post .entry-content,
body.single-post .post-content,
body.single-post .article-content,
body.single-post .single-content,
body.single-post main{
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
}

body.single-post .entry-content > *,
body.single-post .post-content > *,
body.single-post .article-content > *{
    max-width:100% !important;
    box-sizing:border-box !important;
    overflow-wrap:anywhere !important;
}

/* Main / featured / content images */
body.single-post .post-thumbnail,
body.single-post .featured-image,
body.single-post .wp-block-image{
    width:100% !important;
    max-width:100% !important;
    margin-left:auto !important;
    margin-right:auto !important;
    box-sizing:border-box !important;
}

body.single-post .wp-post-image,
body.single-post .post-thumbnail img,
body.single-post .featured-image img,
body.single-post .entry-content figure.wp-block-image img,
body.single-post .entry-content img,
body.single-post .post-content img,
body.single-post .article-content img{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    height:auto !important;
    box-sizing:border-box !important;
    border:2px solid #d8d2c5 !important;
    border-radius:10px !important;
    box-shadow:
        0 15px 34px rgba(37,31,24,.14),
        0 3px 8px rgba(37,31,24,.07) !important;
    background:#fff !important;
}

body.single-post .wp-post-image,
body.single-post .post-thumbnail img,
body.single-post .featured-image img{
    margin-bottom:28px !important;
}

body.single-post .entry-content img{
    margin-top:18px !important;
    margin-bottom:26px !important;
}

/* Prevent theme/inline width from shrinking images */
body.single-post .entry-content figure[style],
body.single-post .entry-content img[style],
body.single-post .entry-content .wp-block-image[style]{
    max-width:100% !important;
}

/* Related guides thumbnails equal size */
body.single-post [class*="related"] img{
    display:block !important;
    width:100% !important;
    height:220px !important;
    min-height:220px !important;
    max-height:220px !important;
    object-fit:cover !important;
    border:2px solid #d7d0c2 !important;
    border-radius:8px !important;
    box-shadow:0 10px 22px rgba(37,31,24,.11) !important;
}

/* =========================================================
   CONTEXTUAL RELATED LINKS
   ========================================================= */

.hrf-context-link{
    width:100% !important;
    max-width:100% !important;
    margin:28px 0 30px !important;
    padding:14px 16px !important;
    box-sizing:border-box !important;
    background:#fbf7ef !important;
    border:1px solid #ded5c6 !important;
    border-left:5px solid #b58a36 !important;
    border-radius:7px !important;
    box-shadow:0 7px 18px rgba(64,50,31,.055) !important;
}

.hrf-context-label{
    display:block !important;
    margin:0 0 7px !important;
    color:#9b742b !important;
    font-size:9px !important;
    line-height:1 !important;
    font-weight:900 !important;
    letter-spacing:.14em !important;
    text-transform:uppercase !important;
}

.hrf-context-link a{
    display:flex !important;
    align-items:center !important;
    justify-content:space-between !important;
    gap:14px !important;
    color:#25394d !important;
    text-decoration:none !important;
    font-weight:800 !important;
    line-height:1.42 !important;
}

.hrf-context-link a:hover{
    color:#a06e1b !important;
}

.hrf-context-link a span{
    min-width:0 !important;
    overflow-wrap:anywhere !important;
}

.hrf-context-link b{
    flex:0 0 auto !important;
    color:#b58a36 !important;
    font-size:18px !important;
}

/* =========================================================
   EXTERNAL / INTERNAL LINK COLOR DIFFERENCE
   ========================================================= */

body.single-post .entry-content a.hrf-external-link,
body.single-post .post-content a.hrf-external-link,
body.single-post .article-content a.hrf-external-link{
    color:#1d72b8 !important;
    text-decoration:underline !important;
    text-underline-offset:3px !important;
    font-weight:700 !important;
}

body.single-post .entry-content a.hrf-internal-link,
body.single-post .post-content a.hrf-internal-link,
body.single-post .article-content a.hrf-internal-link{
    color:#9c6d22 !important;
    text-decoration:underline !important;
    text-underline-offset:3px !important;
}

/* =========================================================
   FOOTER OVERLAP FIX
   ========================================================= */

/* Make sure related section finishes before footer starts */
body.single-post main,
body.single-post .site-main,
body.single-post .content-area,
body.single-post .site-content{
    position:relative !important;
    z-index:1 !important;
    overflow:visible !important;
}

body.single-post footer,
body.single-post .site-footer,
body.single-post #colophon{
    position:relative !important;
    z-index:2 !important;
    clear:both !important;
    float:none !important;
    width:100% !important;
    margin-top:40px !important;
    transform:none !important;
}

/* Neutralize negative bottom margins that can pull content into footer */
body.single-post article,
body.single-post .entry-content,
body.single-post .post-content,
body.single-post .article-content,
body.single-post [class*="related"]{
    margin-bottom:0 !important;
}

body.single-post [class*="related"]{
    padding-bottom:24px !important;
}

/* Tables / embeds / long links */
body.single-post .entry-content a{
    overflow-wrap:anywhere !important;
    word-break:break-word !important;
}

body.single-post .entry-content table{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    overflow-x:auto !important;
}

body.single-post .entry-content iframe,
body.single-post .entry-content video,
body.single-post .entry-content embed,
body.single-post .entry-content object{
    max-width:100% !important;
}

@media(max-width:700px){
    .hrf-context-link{
        margin:22px 0 24px !important;
        padding:12px 13px !important;
    }

    body.single-post [class*="related"] img{
        height:190px !important;
        min-height:190px !important;
        max-height:190px !important;
    }

    body.single-post footer,
    body.single-post .site-footer,
    body.single-post #colophon{
        margin-top:28px !important;
    }
}
