/* Canonical grid shared by FSC and LGB. Components consume these tokens, never invent widths. */
:root,.editor-styles-wrapper{--fs-layout-max:1360px;--fs-layout-gutter:clamp(20px,4vw,72px);--fs-layout-gap:40px;--fs-layout-thirds:repeat(3,minmax(0,1fr));--fs-layout-frame:min(calc(100% - var(--fs-layout-gutter)*2),var(--fs-layout-max));--fsc-width:var(--fs-layout-max);--fsc-gutter:var(--fs-layout-gutter);}
.is-style-fs-content-frame{width:var(--fs-layout-frame);max-width:var(--fs-layout-max);margin-inline:auto;padding-inline:0;box-sizing:border-box;}
.wp-block-group.is-style-fs-content-frame>.wp-block-group__inner-container{padding-inline:0;max-width:none;}
/* Native three-column blocks always have equal tracks; a four-column catalog is explicit. */
:is(body.fs-type-system,.editor-styles-wrapper) .wp-block-columns:has(>.wp-block-column:nth-child(3):last-child){display:grid;grid-template-columns:var(--fs-layout-thirds);gap:var(--fs-layout-gap);}
:is(body.fs-type-system,.editor-styles-wrapper) .wp-block-columns:has(>.wp-block-column:nth-child(3):last-child)>.wp-block-column{width:auto;min-width:0;margin:0;}
body.gm-site :is(.gm-footer__top,.gm-memberships__grid,.gm-blog-grid){grid-template-columns:var(--fs-layout-thirds);gap:var(--fs-layout-gap);}
/* LGB's legacy GP containers are adapted at their outside edge, not inset a second time. */
body.fs-type-system:not(.gm-site) :is(.inside-header,.is-style-lgb-content-inset,.lgb-enrollment-content,.inside-site-info){width:var(--fs-layout-frame);max-width:var(--fs-layout-max);margin-inline:auto;padding-inline:0;box-sizing:border-box;}
body.fs-type-system:not(.gm-site) .is-style-lgb-enrollment-section{padding-inline:0;}
body.fs-type-system:not(.gm-site) .footer-widgets-container.grid-container{width:100%;max-width:none;padding-inline:0;}
body.fs-type-system:not(.gm-site) .footer-widgets .inside-footer-widgets{display:grid;grid-template-columns:var(--fs-layout-thirds);gap:var(--fs-layout-gap);width:var(--fs-layout-frame);max-width:var(--fs-layout-max);margin-inline:auto;}
body.fs-type-system:not(.gm-site) .inside-footer-widgets>[class*="footer-widget-"]{width:auto;padding-inline:0;min-width:0;}
body.fs-type-system:not(.gm-site) .inside-site-info .footer-bar{width:100%;}
body.fs-type-system:not(.gm-site) .footer-bar .is-style-lgb-affiliations{gap:var(--fs-layout-gap);}
/* A hero frame already sits inside Cover padding, so only its maximum is constrained. */
.is-style-lgb-hero-frame{max-width:var(--fs-layout-max);}
.fs-client-section{width:var(--fs-layout-frame);max-width:var(--fs-layout-max);padding-inline:0;}
@media(max-width:767px){
 :is(body.fs-type-system,.editor-styles-wrapper) .wp-block-columns:has(>.wp-block-column:nth-child(3):last-child){grid-template-columns:1fr;gap:30px;}
 body.gm-site :is(.gm-blog-grid,.gm-footer__top){grid-template-columns:1fr;gap:30px;}
 body.gm-site .gm-memberships__grid{grid-template-columns:var(--fs-layout-thirds);gap:12px;max-width:var(--fs-layout-max);}
 body.fs-type-system:not(.gm-site) .footer-widgets .inside-footer-widgets{grid-template-columns:1fr;gap:30px;}
 body.fs-type-system:not(.gm-site) .footer-bar .is-style-lgb-affiliations{grid-template-columns:var(--fs-layout-thirds);gap:12px;}
}
/* Enrollment is one column of photography plus a two-column span of plans: true thirds. */
body.fs-type-system .is-style-lgb-enrollment-layout{grid-template-columns:var(--fs-layout-thirds);gap:var(--fs-layout-gap);}
body.fs-type-system .lgb-enrollment-options{grid-column:span 2;}
body.fs-type-system .is-style-lgb-enrollment-plans{gap:var(--fs-layout-gap);}
@media(max-width:900px){body.fs-type-system .is-style-lgb-enrollment-layout{grid-template-columns:1fr;}body.fs-type-system .lgb-enrollment-options{grid-column:auto;}}

/* GP legacy widget padding must not add a second gutter inside shared tracks. */
body.fs-type-system .inside-footer-widgets .widget.inner-padding{padding-inline:0;}

/* Explicit media feature: one shared track of imagery, two tracks of editorial content. */
:is(body.fs-type-system,.editor-styles-wrapper) .wp-block-columns.is-style-fs-media-feature{display:grid;grid-template-columns:var(--fs-layout-thirds);gap:var(--fs-layout-gap);align-items:center;margin-block:40px;}
:is(body.fs-type-system,.editor-styles-wrapper) .is-style-fs-media-feature>.wp-block-column{min-width:0;width:auto;margin:0;}
:is(body.fs-type-system,.editor-styles-wrapper) .is-style-fs-media-feature>.wp-block-column:last-child{grid-column:span 2;align-self:center;}
.is-style-fs-media-feature figure{margin:0;}
.is-style-fs-media-feature img{display:block;width:100%;aspect-ratio:4/3;object-fit:cover;}
.is-style-fs-media-feature h3{margin-top:0;}
@media(max-width:767px){:is(body.fs-type-system,.editor-styles-wrapper) .wp-block-columns.is-style-fs-media-feature{grid-template-columns:1fr;gap:24px;}:is(body.fs-type-system,.editor-styles-wrapper) .is-style-fs-media-feature>.wp-block-column:last-child{grid-column:auto;}.is-style-fs-media-feature img{aspect-ratio:4/3;}}

/* Optional portrait treatment for photography-led service introductions. */
.is-style-fs-media-feature .is-style-fs-portrait-photo img{aspect-ratio:3/4;object-position:50% 65%;}
@media(max-width:767px){.is-style-fs-media-feature .is-style-fs-portrait-photo img{aspect-ratio:4/3;object-position:50% 70%;}}

/* Preserve a photograph’s full composition on every viewport when selected in the editor. */
.wp-block-image.is-style-fs-natural-photo img{width:100%;height:auto;aspect-ratio:auto;object-fit:contain;}
