/* Sticky left banners (#java_links) - loaded only when stickySidebar = True (inc/tools.asp).
   Scoped to .mm-main-row / .mm-left-col and desktop widths, so other templates are not affected.
   The column is taller than the screen: js/sticky-sidebar.js makes it stick by its bottom edge
   while scrolling down and by its top edge while scrolling up. */
@media (min-width: 1200px) {
  /* flex lets the left column stretch to the content height (the room #java_links travels in);
     the other columns keep their natural height like the original float layout */
  .mm-main-row { display: flex; align-items: flex-start; }
  .mm-main-row:before, .mm-main-row:after { display: none; }
  .mm-left-col { align-self: stretch; display: flex; flex-direction: column; align-items: flex-end; }
  /* spacer that anchors #java_links where it currently is (set from JS). It has to sit outside
     #java_links: a margin on #java_links itself would stop sticky from moving it back up */
  .mm-left-col:before { content: ''; display: block; flex: none; height: var(--mm-offset, 0px); }
  .mm-left-col #java_links {
    position: -webkit-sticky;
    position: sticky;
    top: 20px;
  }
}
