/* Legacy Website V2 theme/Kadence compatibility.
 * Preserved unchanged from v1.0.62 except for this classification header.
 * Migrate selectors by page type; do not extend this file with new dependencies.
 */
/* Website V2 large-desktop outer-shell authority for v1.0.58. */
@media (min-width:1360px){
  :root{
    --opse-reading-narrow:842px;
  }

  /* Every major public shell uses the same wide desktop measure. */
  .site-main-header-wrap .site-container,
  .site-footer-row-layout-standard .site-container,
  .entry-hero-layout-contained,
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container,
  .opse-results-shell__inner,
  .home #primary>.content-container.site-container,
  .home .kb-row-layout-id46_66c6d6-5a,
  .home .opse-home-listings,
  .home .opm-panel__wrap,
  body.home .opse-insights-home,
  .opse-detail-wrap,
  .opse-insights-home,
  .opse-insights-archive,
  .opse-insight-single,
  .opse-worth,
  .opse-worth__admin-warning{
    box-sizing:border-box;
    width:min(92vw,1800px)!important;
    max-width:none!important;
    margin-inline:auto!important;
  }

  /* Homepage: keep the visual hero canvas wide, but constrain functional content. */
  .home .kb-row-layout-id46_66c6d6-5a>.kt-row-column-wrap,
  .home .opse-search--home{
    box-sizing:border-box;
    width:min(1360px,100%)!important;
    max-width:1360px!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }

  /* Align header and footer content to the shell edge rather than an inner fixed grid. */
  .site-main-header-wrap .site-container,
  .site-footer-row-layout-standard .site-container{
    padding-left:0!important;
    padding-right:0!important;
  }

  /* Kadence page shells and the homepage must not add a second outer gutter. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container,
  .home #primary>.content-container.site-container,
  .home #primary .entry-content-wrap,
  .home .kb-row-layout-id46_66c6d6-5a>.kt-row-column-wrap,
  .opse-insights-home,
  .opse-insights-archive,
  .opse-insight-single{
    padding-left:0!important;
    padding-right:0!important;
  }

  /* Business Platform and future major Kadence rows use the same viewport-centred shell. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content>.wp-block-kadence-rowlayout{
    position:relative!important;
    left:50%!important;
    box-sizing:border-box;
    width:min(92vw,1800px)!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    transform:translateX(-50%)!important;
  }

  /* Property Worth is rendered inside Kadence content and must share the viewport-centred shell. */
  body:not(.home) #primary>.content-container.site-container .opse-worth,
  body:not(.home) #primary>.content-container.site-container .opse-worth__admin-warning{
    position:relative!important;
    left:50%!important;
    margin-left:0!important;
    margin-right:0!important;
    transform:translateX(-50%)!important;
  }

  /* Keep narrow page copy readable inside the wide visible page shell. */
  body.content-width-narrow:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content-wrap{
    box-sizing:border-box;
    width:100%;
    max-width:var(--opse-reading-narrow)!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }

  /* Ordinary nested alignwide content cannot escape the shared shell. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content .alignwide{
    width:auto!important;
    max-width:100%!important;
    margin-left:0!important;
    margin-right:0!important;
  }

  /* A direct major alignwide section may use the full shared shell; alignfull remains untouched. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content>.alignwide{
    position:relative!important;
    left:50%!important;
    box-sizing:border-box;
    width:min(92vw,1800px)!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    transform:translateX(-50%)!important;
  }
}

/* v1.0.60 targeted desktop visual corrections. */
@media (min-width:1360px){
  /* Homepage: true full-bleed hero visual, while the existing 1360px inner
     content/search constraints above remain in force. */
  .home .kb-row-layout-id46_66c6d6-5a{
    position:relative!important;
    left:50%!important;
    width:100vw!important;
    max-width:none!important;
    margin-left:-50vw!important;
    margin-right:-50vw!important;
    transform:none!important;
  }

  /* Major top-level Kadence marketing rows: let the row and its generated
     inner grid use the shared wide shell rather than retaining a hidden
     page-specific max-width. This does not alter nested reading columns. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content>.wp-block-kadence-rowlayout>.kt-row-column-wrap{
    box-sizing:border-box!important;
    width:100%!important;
    max-width:none!important;
  }

  /* Property Insights archive/listing: keep the page aligned to the site,
     but pull the visible archive/cards back from the 92vw functional shell. */
  .opse-insights-archive{
    width:min(1450px,calc(100% - 48px))!important;
    max-width:1450px!important;
    margin-inline:auto!important;
  }
}

/* v1.0.61 desktop consistency correction.
   Preserve the laptop desktop layout; only expand the homepage inner hero
   measure on genuinely large desktop screens so it keeps the same visual
   relationship to the viewport instead of collapsing into a narrow 1360px island. */
@media (min-width:1600px){
  .home .kb-row-layout-id46_66c6d6-5a>.kt-row-column-wrap,
  .home .opse-search--home{
    width:min(92vw,1800px)!important;
    max-width:1800px!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }
}

@media (min-width:1360px){
  /* Homepage Insights is a content section, not a functional full-width tool. */
  body.home .opse-insights-home{
    width:min(1400px,calc(100% - 48px))!important;
    max-width:1400px!important;
    margin-inline:auto!important;
  }

  /* Archive/listing uses the same controlled editorial measure. */
  .opse-insights-archive{
    width:min(1400px,calc(100% - 48px))!important;
    max-width:1400px!important;
    margin-inline:auto!important;
  }

  /* Kadence can emit an extra inner wrapper depending on the Row Layout.
     Cover both structures so the already-wide top-level marketing row is not
     visually trapped by Kadence's theme content max-width. */
  body:not(.home):not(.opse-results-page) #primary>.content-container.site-container .entry-content>.wp-block-kadence-rowlayout>.kt-row-layout-inner>.kt-row-column-wrap{
    box-sizing:border-box!important;
    width:100%!important;
    max-width:none!important;
  }
}
