/* Site-wide content rail: match Home, including editorial and system routes.
 * theme.json owns the 1280px shell; theme.css owns responsive gutters.
 * Keep reading copy and components inside columns independent of this rail.
 */
.wp-site-blocks .wp-block-group.ad-shell,
.wp-site-blocks .ad-article-opening > .ad-prose,
.wp-site-blocks .ad-system > .ad-prose,
.ad-role-policy .wp-site-blocks main .ad-prose {
    width: calc(100% - 2 * var(--wp--custom--gutter));
    max-width: var(--wp--custom--rail--shell);
    margin-inline: auto !important;
}

/* Full-section compositions must not introduce a second, narrower container.
 * Direct children only: retain the proportions of split layouts and cards.
 */
.wp-site-blocks .ad-shell > :is(
    .am-inner-intro,
    .am-r5-intro,
    .amp-centered-intro,
    .am-case-intro,
    .am-case-presentation,
    .am-product-opening-image,
    .am-r5-software-frame,
    .am-product-browser,
    .am-product-detail-browser,
    .am-resource-reading
) {
    width: 100%;
    max-width: 100% !important;
    margin-inline: 0 !important;
}

.search .ad-shell .ad-article-grid {
    max-width: none;
}

/* Grid children may shrink to the rail even with long accordion questions. */
.wp-site-blocks .ad-shell > * {
    min-width: 0;
}

/* Long-form copy stays readable within the same outer page rail. */
.ad-role-policy main .ad-prose > :not(h1) {
    max-width: var(--wp--custom--rail--prose);
}
