/* possearchproducts — TrustWear search modal */
#_desktop_search_category {
  position: relative;
  padding: 0;
}
#_mobile_search_category {
  display: none;
}

/* Form inside search modal */
.tw-search-modal #pos_search_top {
  padding: 0;
}
.tw-search-modal #pos_search_top .form_search {
  position: relative;
  display: flex;
  align-items: stretch;
  width: 100%;
  height: 46px;
  margin: 0;
  padding: 0;
  float: none;
  border: 1px solid var(--gray, #E8E7E3);
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
}
.tw-search-modal #pos_search_top .form_search label {
  display: none;
}
.tw-search-modal #pos_search_top .form_search .form-group {
  position: relative;
  left: auto;
  top: auto;
  display: flex;
  align-items: center;
  width: auto;
  min-width: 170px;
  margin: 0;
  background: var(--off, #F5F4F1);
  border-right: 1px solid var(--gray, #E8E7E3);
  flex-shrink: 0;
}
.tw-search-modal #pos_search_top .form_search .form-group .bootstrap-select {
  width: 100%;
  min-width: 150px;
  height: 44px;
  line-height: 44px;
  margin: 0;
  border: 0;
  padding: 0 32px 0 16px;
  color: var(--text, #1A1A1A);
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  background: transparent url(../../img/option_search.png) no-repeat calc(100% - 12px) center;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  cursor: pointer;
}
.tw-search-modal #pos_search_top .form_search .form-control {
  flex: 1;
  width: auto;
  height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 0;
  font-size: 15px;
  font-family: 'DM Sans', sans-serif;
  color: var(--text, #1A1A1A);
  background: #fff;
  box-shadow: none;
}
.tw-search-modal #pos_search_top .form_search.show-categories .form-control {
  padding-left: 16px;
}
.tw-search-modal #pos_search_top .form_search .form-control::placeholder {
  color: var(--muted, #6B6B6B);
}
.tw-search-modal #pos_search_top .form_search .form-control:focus {
  outline: none;
  box-shadow: none;
}
.tw-search-modal #pos_search_top .form_search .search_submit {
  position: relative;
  top: auto;
  right: auto;
  flex-shrink: 0;
  width: 52px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: var(--blue, #203F7B);
  color: #fff;
  transition: background .2s;
}
.tw-search-modal #pos_search_top .form_search .search_submit:hover {
  background: var(--orange, #EC801C);
  opacity: 1;
}
.tw-search-modal #pos_search_top .form_search .search_submit svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.tw-search-modal #pos_search_top .form_search .search_submit i {
  font-size: 20px;
  line-height: 1;
}

/* Autocomplete results */
.ui-autocomplete.ui-widget-content {
  max-height: 380px;
  overflow: auto;
  border: 1px solid var(--gray, #E8E7E3);
  border-radius: 8px;
  padding: 1rem;
  font-family: 'DM Sans', sans-serif;
  box-shadow: 0 12px 40px rgba(32, 63, 123, .12);
  z-index: 10070 !important;
}
.ui-autocomplete.ui-widget-content li {
  margin-bottom: 12px;
}
.ui-autocomplete.ui-widget-content li:last-child {
  margin-bottom: 0;
}
.ui-autocomplete.ui-widget-content img {
  float: left;
  width: 60px;
  border-radius: 4px;
}
.ui-autocomplete.ui-widget-content .product {
  display: block;
  overflow: hidden;
  padding: 12px 16px;
  max-width: 320px;
  color: var(--text, #1A1A1A);
  font-size: 14px;
}
.ui-autocomplete.ui-widget-content a:hover .product {
  color: var(--blue, #203F7B);
}

@media (max-width: 767px) {
  body.trustwear-theme .tw-search-modal-bar {
    padding: 12px 16px;
    min-height: 60px;
    gap: 10px;
  }
  .tw-search-modal #pos_search_top .form_search {
    height: 42px;
  }
  .tw-search-modal #pos_search_top .form_search .form-group {
    min-width: 110px;
  }
  .tw-search-modal #pos_search_top .form_search .form-group .bootstrap-select {
    min-width: 100px;
    font-size: 11px;
    padding: 0 24px 0 10px;
    height: 40px;
    line-height: 40px;
  }
  .tw-search-modal #pos_search_top .form_search .form-control {
    height: 40px;
    font-size: 14px;
    padding: 0 10px;
  }
  .tw-search-modal #pos_search_top .form_search .search_submit {
    width: 44px;
    height: 40px;
  }
}
