/*
=================================================================
  Page: Single Blog Post
=================================================================
*/

/* --- Header Layout --- */
.post-header > .wp-block-group.is-layout-flex,
.post-category-recipes .wp-block-post-content .wp-block-group:first-child .is-layout-flex {
    flex-direction: column;
}

.post-category-recipes .wp-block-post-content .wp-block-post-featured-image,
.post-header .wp-block-post-featured-image {
    aspect-ratio: 1.4;
    width: 100% !important;
}

.post-category-recipes .wp-block-post-featured-image img,
.post-header .wp-block-post-featured-image img {
    height: 100%;
    width: 100%;
    object-fit: cover;
}

/* --- Entry Content Spacing --- */
.single-post .entry-content {
    padding-block: 2rem;
    padding-inline: var(--wp--preset--spacing--50);
}

.single-post .wp-block-image {
    margin-bottom: 3rem;
}

.wp-block-post-content .wp-block-media-text__media {
    border-radius: 2.5rem;
    overflow: hidden;
}

/* --- Footer Spacing on Single Posts --- */
body:not(.home) .wp-block-post-content:has(+ footer.wp-block-template-part):not(:has(.slider--blog-latest)) {
    padding-bottom: 5rem;
}

.entry-content:has(.slider--blog-latest) + footer {
    margin-top: -2.6rem !important;
}

/* --- Desktop Adjustments --- */
@media screen and (min-width: 781px) {
    .post-header > .wp-block-group.is-layout-flex,
    .post-category-recipes .wp-block-post-content .wp-block-group:first-child .is-layout-flex {
        flex-direction: row !important;
    }

    .post-header .wp-block-post-featured-image,
    .post-category-recipes .wp-block-post-featured-image {
        aspect-ratio: 1;
        max-width: 25em;
        max-height: 25em;
    }

    .single-post .entry-content {
        padding-block: 6rem 3rem;
    }
}