/*
 * JBA v16.20.179 — desktop-only compact marketplace-style mega-menu columns.
 * The mobile/tablet navigation below 992px is intentionally untouched.
 */
@media (min-width:992px){
  /* Keep the whole desktop panel clean and prevent the internal scrollbar. */
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-mega-shell{
    height:min(620px,calc(100vh - var(--jba-v1620175-top,142px) - 12px))!important;
    min-height:500px!important;
    max-height:620px!important;
    overflow:hidden!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-content{
    overflow:hidden!important;
    overscroll-behavior:none!important;
    scrollbar-width:none!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-content::-webkit-scrollbar{
    display:none!important;
    width:0!important;
    height:0!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel{
    box-sizing:border-box!important;
    height:100%!important;
    min-height:0!important;
    max-height:100%!important;
    padding:17px 24px 18px!important;
    overflow:hidden!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel-head{
    align-items:center!important;
    min-height:58px!important;
    margin:0 0 14px!important;
    padding:0 0 10px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel-head h2{
    font-size:19px!important;
    line-height:1.4!important;
  }

  /*
   * Marketplace-style flow: each column is filled from top to bottom and then
   * continues in the next column from right to left. Groups remain intact, so
   * headings never become detached from their own links.
   */
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-groups{
    display:block!important;
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    max-height:calc(100% - 72px)!important;
    margin:0!important;
    padding:0!important;
    columns:5!important;
    column-gap:28px!important;
    column-fill:balance!important;
    direction:rtl!important;
    overflow:visible!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-group{
    display:inline-block!important;
    box-sizing:border-box!important;
    width:100%!important;
    min-width:0!important;
    margin:0 0 12px!important;
    padding:0!important;
    vertical-align:top!important;
    break-inside:avoid-column!important;
    page-break-inside:avoid!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-group h3{
    margin:0 0 7px!important;
    padding-right:10px!important;
    font-size:15px!important;
    line-height:1.55!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-group h3::before{
    top:4px!important;
    height:15px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-links{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:0!important;
    columns:auto!important;
    margin:0!important;
    padding:0!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-links a{
    min-height:0!important;
    margin:0!important;
    padding:3px 9px 3px 4px!important;
    border-radius:6px!important;
    font-size:14px!important;
    font-weight:650!important;
    line-height:1.45!important;
    white-space:normal!important;
    overflow-wrap:normal!important;
    word-break:normal!important;
  }

  /* The single agate landing link should behave like every other clean group. */
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620178-agate-summary{
    display:inline-block!important;
    grid-row:auto!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620178-agate-summary .jba-v1620175-links{
    display:flex!important;
    columns:auto!important;
  }

  /* Future/legacy links are kept, but their block may continue naturally. */
  html body > .jba-v1620175-mega.jba-v1620177-complete [data-jba-v1620177-auto-group="1"]{
    break-inside:auto!important;
  }
}

@media (min-width:992px) and (max-width:1279px){
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-groups{
    columns:4!important;
    column-gap:22px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel{
    padding-right:20px!important;
    padding-left:20px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-links a{
    font-size:13.5px!important;
    padding-top:2px!important;
    padding-bottom:2px!important;
  }
}

@media (min-width:1440px){
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-groups{
    columns:6!important;
    column-gap:30px!important;
  }
}

/* Compact fallback for short desktop viewports, still without an internal scroll. */
@media (min-width:992px) and (max-height:760px){
  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-mega-shell{
    min-height:430px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel{
    padding-top:12px!important;
    padding-bottom:12px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-panel-head{
    min-height:50px!important;
    margin-bottom:9px!important;
    padding-bottom:7px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-group{
    margin-bottom:8px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-group h3{
    margin-bottom:4px!important;
    font-size:14px!important;
  }

  html body > .jba-v1620175-mega.jba-v1620177-complete .jba-v1620175-links a{
    padding-top:1px!important;
    padding-bottom:1px!important;
    font-size:13px!important;
    line-height:1.4!important;
  }
}
