/* WP_LEGACY_CONTENT_V1 (Julien 2026-10-19): presentation of posts imported verbatim from WordPress.
   Loaded only on a post whose content still carries WordPress markup (includes/wp-legacy-content.php).
   Core block classes take the article's own rhythm and tokens; no new visual component. */

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(figure.wp-block-image, div.wp-block-image) {
    margin: 1.75rem 0;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image, .wp-block-gallery) img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: var(--radius, 8px);
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image.aligncenter, .wp-block-image .aligncenter) {
    margin-inline: auto;
    text-align: center;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image.aligncenter, .wp-block-image .aligncenter) img {
    margin-inline: auto;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image, .wp-block-gallery, .wp-block-table) figcaption {
    margin-top: 0.5rem;
    color: var(--color-text-muted);
    font-size: 0.875rem;
    line-height: 1.45;
    text-align: center;
}

@media (min-width: 720px) {
    :is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image.alignleft, .wp-block-image .alignleft) {
        float: left;
        max-width: 50%;
        margin: 0.35rem 1.5rem 1rem 0;
    }

    :is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(.wp-block-image.alignright, .wp-block-image .alignright) {
        float: right;
        max-width: 50%;
        margin: 0.35rem 0 1rem 1.5rem;
    }

    :is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(h2, h3) {
        clear: both;
    }
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) .wp-block-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.75rem;
    margin: 1.75rem 0;
    padding: 0;
    list-style: none;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) .wp-block-gallery > :is(figure, li) {
    margin: 0;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) .wp-block-gallery img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) .has-text-align-center {
    text-align: center;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) .has-text-align-right {
    text-align: right;
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) hr.wp-block-separator {
    margin: 2rem 0;
    border: 0;
    border-top: 1px solid var(--color-border);
}

/* Question / answer summaries saved as HTML blocks (bloc_resume_post, Rank Math FAQ): read as the article's text. */
:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(aside.bloc_resume_post, .wp-block-rank-math-faq-block) {
    margin: 2rem 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
}

:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(aside.bloc_resume_post h4, .rank-math-question) {
    margin: 1.25rem 0 0.4rem;
    font-size: 1.05rem;
}

/* Social embeds keep the provider's card width. */
:is(.cms-pc-std__content, .cms-pc-sb__content, .article-content, .post-content) :is(blockquote.instagram-media, blockquote.twitter-tweet) {
    max-width: 540px;
    margin: 1.75rem auto;
}
