/* CommunityHub v0.4.487.2 — frozen geometry and height-aware page-scroll sticky rails.
 * One reserved grid owns the left rail, center surface and right rail. This file
 * intentionally loads after historical theme.css so legacy route-specific width
 * experiments cannot move a rail after paint. Mobile/tablet rail behavior is not
 * changed here.
 */
@media (min-width:1180px){
  body.ch-theme .ch-theme-container--community{
    --ch-social-stack-width:820px;
    --ch-social-widget-width:340px;
    --ch-social-widget-gap:8px;
    width:min(calc(100% - 20px),1516px)!important;
    max-width:1516px!important;
    margin-inline:auto!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar{
    display:grid!important;
    align-items:start!important;
    justify-content:center!important;
    gap:var(--ch-social-widget-gap)!important;
    min-width:0!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-both{
    grid-template-columns:minmax(220px,var(--ch-social-widget-width)) minmax(620px,var(--ch-social-stack-width)) minmax(220px,var(--ch-social-widget-width))!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-left{
    grid-template-columns:minmax(220px,var(--ch-social-widget-width)) minmax(620px,var(--ch-social-stack-width))!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-right{
    grid-template-columns:minmax(620px,var(--ch-social-stack-width)) minmax(220px,var(--ch-social-widget-width))!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-both>.ch-theme-sidebar--left,
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-left>.ch-theme-sidebar--left{
    grid-column:1!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-both>.ch-theme-community-content-wrap{
    grid-column:2!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-both>.ch-theme-sidebar--right{
    grid-column:3!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-left>.ch-theme-community-content-wrap{
    grid-column:2!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-right>.ch-theme-community-content-wrap{
    grid-column:1!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar-right>.ch-theme-sidebar--right{
    grid-column:2!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar>.ch-theme-community-content-wrap{
    width:100%!important;
    max-width:var(--ch-social-stack-width)!important;
    min-width:0!important;
    margin:0!important;
    justify-self:stretch!important;
  }
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar>.ch-theme-community-sidebar{
    width:100%!important;
    max-width:var(--ch-social-widget-width)!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    justify-self:stretch!important;
    align-self:start!important;
    /* Until height is measured, natural page scrolling is the safe fallback. */
    position:static!important;
    top:auto!important;
    max-height:none!important;
    height:auto!important;
    overflow:visible!important;
    transform:none!important;
  }
  /* A short rail pins below the header. A tall rail moves with the page until
   * its BOTTOM enters the viewport, then follows that bottom position. Never
   * snap it to the top or create an independent overflow scroller. */
  body.ch-theme .ch-theme-community-shell.ch-theme-layout--sidebar>.ch-theme-community-sidebar[data-ch-rail-follow-ready="1"]{
    position:sticky!important;
    top:var(--ch-rail-follow-top,88px)!important;
  }
}
