.ats_mobile_menu_v1,
.ats-mobile-menu-v1 {
  display: none;
}

@media (max-width: 980px) {
  .ats_mobile_menu_v1,
  .ats-mobile-menu-v1 {
    display: block;
    position: relative;
    width: 100%;
  }

  .ats-mobile-menu-v1__toggle,
  .ats-mobile-menu-v1__group-toggle,

  .ats-mobile-menu-v1 a img.wpml-ls-flag,
  .ats-mobile-menu-v1 a img[class*="wpml-ls-flag"] {
    display: inline-block;
    width: auto;
    max-width: 30px;
    height: 16px;
    object-fit: contain;
    vertical-align: middle;
  }

  .ats-mobile-menu-v1__submenu-toggle {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--ats-mobile-menu-toggle-color, inherit);
    font: inherit;
    cursor: pointer;
  }

  .ats-mobile-menu-v1__toggle {
    display: inline-flex;
    align-items: center;
    gap: .65rem;
    min-height: 44px;
    padding: .65rem .8rem;
  }

  .ats-mobile-menu-v1__icon,
  .ats-mobile-menu-v1__icon::before,
  .ats-mobile-menu-v1__icon::after {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
    content: '';
    transition: transform .18s ease, opacity .18s ease;
  }

  .ats-mobile-menu-v1__icon { position: relative; }
  .ats-mobile-menu-v1__icon::before { position: absolute; top: -7px; left: 0; }
  .ats-mobile-menu-v1__icon::after { position: absolute; top: 7px; left: 0; }
  .ats-mobile-menu-v1.is-open .ats-mobile-menu-v1__icon { background: transparent; }
  .ats-mobile-menu-v1.is-open .ats-mobile-menu-v1__icon::before { top: 0; transform: rotate(45deg); }
  .ats-mobile-menu-v1.is-open .ats-mobile-menu-v1__icon::after { top: 0; transform: rotate(-45deg); }

  .ats-mobile-menu-v1__panel[hidden] { display: none !important; }
  .ats-mobile-menu-v1__panel {
    position: absolute;
    z-index: 99999;
    top: 100%;
    left: auto;
    right: 0;
    width: min(380px, calc(100vw - 24px));
    max-height: min(75vh, 720px);
    overflow: auto;
    background: var(--ats-mobile-menu-panel-bg, #fff);
    color: var(--ats-mobile-menu-panel-color, #111);
    border: 1px solid rgba(0,0,0,.12);
    box-shadow: 0 12px 36px rgba(0,0,0,.16);
    padding: .65rem;
  }

  .ats-mobile-menu-v1 ul {
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .ats-mobile-menu-v1__group + .ats-mobile-menu-v1__group { margin-top: .35rem; }
  .ats-mobile-menu-v1__group-toggle,
  .ats-mobile-menu-v1__submenu-toggle,
  .ats-mobile-menu-v1 a {
    min-height: 42px;
  }

  .ats-mobile-menu-v1__group-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .55rem .6rem;
    font-weight: 700;
    text-align: left;
  }

  .ats-mobile-menu-v1__item-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: stretch;
  }

  .ats-mobile-menu-v1 a {
    display: flex;
    align-items: center;
    padding: .55rem .6rem;
    color: inherit;
    text-decoration: none;
  }


  .ats-mobile-menu-v1 a img.wpml-ls-flag,
  .ats-mobile-menu-v1 a img[class*="wpml-ls-flag"] {
    display: inline-block;
    width: auto;
    max-width: 30px;
    height: 16px;
    object-fit: contain;
    vertical-align: middle;
  }

  .ats-mobile-menu-v1__submenu-toggle {
    min-width: 42px;
    padding: .4rem;
  }

  .ats-mobile-menu-v1__children {
    padding-left: .9rem !important;
  }

  .ats-mobile-menu-v1__children[hidden] { display: none !important; }
  .ats-mobile-menu-v1__item.is-current > .ats-mobile-menu-v1__item-row > a { font-weight: 700; }



  /* Alpha35: preserve source-menu boundaries without exposing internal menu names. */
  .ats-mobile-menu-v1__sections {
    display: block;
  }

  .ats-mobile-menu-v1__section + .ats-mobile-menu-v1__section {
    margin-top: .55rem;
    padding-top: .55rem;
    border-top: 1px solid rgba(127,127,127,.28);
  }

  /* WPML language switches form one responsive row. With two languages they
   * sit at the outer edges; additional languages distribute evenly between. */
  .ats-mobile-menu-v1__language-row {
    margin-top: .25rem;
    padding: .45rem .6rem .3rem;
    border-top: 1px solid rgba(127,127,127,.2);
  }

  .ats-mobile-menu-v1__language-list {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    gap: 1rem !important;
  }

  .ats-mobile-menu-v1__language-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 auto !important;
    min-height: 36px !important;
    padding: .25rem 0 !important;
  }

  /* Cleaner universal submenu disclosure: chevron instead of literal plus. */
  .ats-mobile-menu-v1__indicator {
    display: inline-block;
    box-sizing: border-box;
    width: 9px;
    height: 9px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transform-origin: 60% 60%;
    transition: transform .18s ease;
  }

  .ats-mobile-menu-v1__submenu-toggle[aria-expanded="true"] .ats-mobile-menu-v1__indicator,
  .ats-mobile-menu-v1__group-toggle[aria-expanded="true"] .ats-mobile-menu-v1__indicator {
    transform: rotate(225deg);
  }

  .ats-mobile-menu-v1-source-suppressed {
    display: none !important;
  }
}

.ats-mobile-menu-v1__diagnostic {
  display: none;
}
.et-fb .ats-mobile-menu-v1__diagnostic,
.et-fb-root-ancestor .ats-mobile-menu-v1__diagnostic {
  display: block;
}

/* Builder ergonomics: the module remains selectable/visible while editing even
 * when the builder viewport currently represents desktop. Frontend desktop
 * visibility remains off through the base rule above. */
.et-fb .ats_mobile_menu_v1,
.et-fb .ats-mobile-menu-v1,
.et-fb-root-ancestor .ats_mobile_menu_v1,
.et-fb-root-ancestor .ats-mobile-menu-v1 {
  display: block !important;
}

/* Alpha33: canonical mobile header controls + Panta topbar row contract. */
@media (max-width: 980px) {
  .ats-mobile-menu-v1__controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: .2rem;
    width: auto;
  }

  .ats-mobile-menu-v1__toggle {
    appearance: none;
    -webkit-appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    box-sizing: border-box;
    min-width: 44px;
    width: 44px;
    height: 44px;
    min-height: 44px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: var(--ats-mobile-menu-toggle-color, inherit);
    font: inherit;
    line-height: 1;
    cursor: pointer;
  }

  .ats-mobile-menu-v1--trigger-icon-text .ats-mobile-menu-v1__toggle {
    width: auto;
    padding: 0 .55rem;
  }

  .ats-mobile-menu-v1--trigger-icon .ats-mobile-menu-v1__label {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0,0,0,0) !important;
    white-space: nowrap !important;
    border: 0 !important;
  }

  .ats-mobile-menu-v1__controls .ats-mobile-menu-v1__control,
  .ats-mobile-menu-v1__controls .ats-header-wishlist-menu-item {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
    width: 44px !important;
    min-width: 44px !important;
    height: 44px !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .ats-mobile-menu-v1__controls .ats-header-control-link,
  .ats-mobile-menu-v1__controls .ats-lcn-cart-link,
  .ats-mobile-menu-v1__controls .ats-header-wishlist-menu-item > a {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    box-sizing: border-box !important;
    width: 44px !important;
    min-width: 44px !important;
    height: 44px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: var(--ats-mobile-menu-toggle-color, inherit) !important;
    text-decoration: none !important;
    line-height: 1 !important;
  }

  .ats-mobile-menu-v1__controls .ats-header-control-icon,
  .ats-mobile-menu-v1__controls .ats-header-wishlist-icon,
  .ats-mobile-menu-v1__controls .ats-lcn-cart-icon {
    display: block !important;
    width: 22px !important;
    height: 22px !important;
    flex: 0 0 22px !important;
    transform: none !important;
  }

  .ats-mobile-menu-v1__controls .ats-header-wishlist-icon-filled { display: none !important; }
  .ats-mobile-menu-v1__controls .ats-header-wishlist-menu-item.is-filled .ats-header-wishlist-icon-empty { display: none !important; }
  .ats-mobile-menu-v1__controls .ats-header-wishlist-menu-item.is-filled .ats-header-wishlist-icon-filled { display: block !important; }

  .ats-mobile-menu-v1__control--placeholder {
    color: var(--ats-mobile-menu-toggle-color, inherit);
    opacity: .72;
  }


}
