/* AUTOERA MOBILE SEARCH EXISTING v3 REPAIR */
@media (max-width:768px){
  body.ae-search-v3r-page{
    overflow:hidden!important;
    background:#f7f8fa!important;
  }

  #ae-search-v3r{
    position:fixed;
    z-index:9000;
    top:108px;
    right:0;
    bottom:72px;
    left:0;
    overflow-y:auto;
    padding:54px 18px 24px;
    background:#f7f8fa;
    box-sizing:border-box;

    /* Белый слой закрывает desktop-фон, но не блокирует шапку и нижнее меню. */
    pointer-events:none;
  }

  #ae-search-v3r .ae-wrap{
    width:100%;
    max-width:560px;
    margin:0 auto;
    pointer-events:auto;
  }

  #ae-search-v3r .ae-box{
    position:relative;
    width:100%;
  }

  #ae-search-v3r input[type="search"]{
    width:100%;
    height:60px;
    padding:0 72px 0 18px;
    border:1px solid #d7dce3;
    border-radius:16px;
    background:#fff;
    color:#17191c;
    font-size:18px;
    outline:none;
    box-shadow:0 6px 20px rgba(0,0,0,.06);
    box-sizing:border-box;
  }

  #ae-search-v3r .ae-submit{
    position:absolute;
    top:6px;
    right:6px;
    width:48px;
    height:48px;
    border:0;
    border-radius:13px;
    background:#ed1c24;
    color:#fff;
    font-size:23px;
    font-weight:700;
    cursor:pointer;
  }

  #ae-search-v3r .ae-dropdown{
    display:none;
    width:100%;
    margin-top:8px;
    border:1px solid #dfe3e8;
    border-radius:14px;
    background:#fff;
    box-shadow:0 10px 28px rgba(0,0,0,.12);
    overflow:hidden;
    pointer-events:auto;
  }

  #ae-search-v3r .ae-dropdown.is-open{display:block}

  #ae-search-v3r .ae-item{
    display:grid;
    grid-template-columns:58px minmax(0,1fr) auto;
    gap:10px;
    align-items:center;
    min-height:72px;
    padding:10px 12px;
    border-bottom:1px solid #edf0f3;
    color:#172033;
    text-decoration:none;
    box-sizing:border-box;
  }

  #ae-search-v3r .ae-item:last-child{border-bottom:0}
  #ae-search-v3r .ae-item img{width:54px;height:54px;object-fit:contain}
  #ae-search-v3r .ae-name{color:#0b2d6b;font-size:14px;font-weight:800;line-height:1.25}
  #ae-search-v3r .ae-code{margin-top:4px;color:#6b7280;font-size:12px}
  #ae-search-v3r .ae-price{color:#ed1c24;font-size:15px;font-weight:900;white-space:nowrap}
  #ae-search-v3r .ae-loading,
  #ae-search-v3r .ae-empty{padding:16px;color:#6b7280;font-size:14px;text-align:center}

  #ae-search-v3r-lang{
    position:fixed;
    z-index:12000;
    top:92px;
    right:14px;
    display:none;
    width:174px;
    border:1px solid #dfe3e8;
    border-radius:14px;
    background:#fff;
    box-shadow:0 12px 30px rgba(0,0,0,.18);
    overflow:hidden;
    pointer-events:auto;
  }

  #ae-search-v3r-lang.is-open{display:block}

  #ae-search-v3r-lang a{
    display:flex;
    align-items:center;
    gap:10px;
    min-height:48px;
    padding:0 14px;
    border-bottom:1px solid #edf0f3;
    color:#172033;
    font-size:15px;
    font-weight:700;
    text-decoration:none;
  }

  #ae-search-v3r-lang a:last-child{border-bottom:0}
  #ae-search-v3r-lang a.is-active{background:#fff1f2;color:#d71920}

  /* Штатная шапка, hamburger и штатное нижнее меню всегда выше поиска. */
  body.ae-search-v3r-page header,
  body.ae-search-v3r-page .ae-mobile-header,
  body.ae-search-v3r-page #ae-mobile-header{
    position:relative;
    z-index:11000!important;
    pointer-events:auto!important;
  }

  body.ae-search-v3r-page .ae-mobile-bottom-nav,
  body.ae-search-v3r-page [class*="bottom-nav"],
  body.ae-search-v3r-page [class*="mobile-nav"]{
    position:fixed!important;
    z-index:11000!important;
    display:flex!important;
    visibility:visible!important;
    opacity:1!important;
    pointer-events:auto!important;
  }

  /* Любое штатное выезжающее меню должно быть выше поискового слоя. */
  body.ae-search-v3r-page [class*="drawer"],
  body.ae-search-v3r-page [class*="sidebar"],
  body.ae-search-v3r-page [class*="offcanvas"],
  body.ae-search-v3r-page [class*="mobile-menu"],
  body.ae-search-v3r-page nav[aria-hidden="false"]{
    z-index:13000!important;
    pointer-events:auto!important;
  }
}
