@media (min-width: 992px) {
  header .search_header_desktop {
    height: 100%;
    position: relative;
  }
}

body #mi_modal {
  position: absolute;
  top: 50%;
  right: 0;
  left: auto;
  transform: translateY(-50%);
  width: 0;
  height: 40px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #ffffff;
  border-radius: 20px;
  overflow: visible;
  z-index: 99999;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  flex-direction: row;
}

body #mi_modal.in {
  width: 720px;
  max-width: 60vw;
  opacity: 1;
  visibility: visible;
  border: 1px solid #e5e5ea;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

@media (max-width: 1400px) {
  body #mi_modal.in {
    width: 620px;
    max-width: 50vw;
  }
}

@media (max-width: 1200px) {
  body #mi_modal.in {
    width: 500px;
    max-width: 45vw;
  }
}

body #mi_modal .input-group {
  display: flex;
  align-items: center;
  width: 100%;
  height: 100%;
  position: relative;
  padding: 0;
  background: transparent;
  border: none;
}

body #mi_modal .input-group::before,
body #mi_modal .input-group::after {
  display: none;
  content: none;
}

body #mi_modal .search_modal {
  flex: 1;
  display: block;
  float: none;
  border: none;
  box-shadow: none;
  background: transparent;
  height: 100%;
  padding: 0 15px;
  margin: 0;
  font-family: 'Barlow', sans-serif;
  font-size: 15px;
  color: #1c1c1e;
  line-height: normal;
  box-sizing: border-box;
  border-radius: 20px 0 0 20px;
}

body #mi_modal .search_modal::placeholder {
  font-family: 'Barlow', sans-serif;
  color: #999999;
  opacity: 1;
}

body #mi_modal .cerrar_modal_search {
  flex: 0 0 auto;
  height: 100%;
  margin: 0;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #8e8e93;
  opacity: 0.8;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 0 24px 24px 0;
  float: none;
  line-height: 1;
  align-self: center;
}

body #mi_modal .cerrar_modal_search span {
  display: inline-block;
  line-height: 1;
  margin-top: -2px;
}

.boton_ejecutar_buscar,
.cerrar_modal_search {
  cursor: pointer;
  color: #8e8e93;
  padding: 0 12px;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  margin: 0;
  flex: 0 0 auto;
  background: transparent;
  border: none;
  box-shadow: none;
  transition: color 0.2s ease;
}

.boton_ejecutar_buscar:hover,
.cerrar_modal_search:hover {
  color: #111111;
}

.boton_ejecutar_buscar svg,
.cerrar_modal_search svg {
  display: block;
  width: 16px;
  height: 16px;
  stroke-width: 2;
}

body .search-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.4);
  z-index: 99998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

body .search-backdrop.active {
  opacity: 1;
  visibility: visible;
}

body #mi_modal .modal-body,
.modal_body_search {
  margin: 0;
  padding: 0;
  height: 100%;
  flex: 1;
  width: auto;
}

.imagen_lupa_search {
  cursor: pointer;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

body #mi_modal1 {
  background-color: rgba(0, 0, 0, 0.69);
}

body #mi_modal div.winter-search {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 100%;
  z-index: 100001;
  background: #ffffff;
  border: 1px solid #e5e5ea;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  padding: 0;
  display: none;
  overflow: hidden;
  pointer-events: auto;
}

body #mi_modal div.winter-search.active {
  display: block;
}

body #mi_modal div.winter-search > * {
  pointer-events: auto;
}

body #mi_modal .winter-search-result,
body #mi_modal2 .winter-search-result {
  font-family: 'Barlow', sans-serif;
}

body #mi_modal .winter-search-result *,
body #mi_modal2 .winter-search-result * {
  font-family: 'Barlow', sans-serif;
}

body #mi_modal .winter-search-result p,
body #mi_modal2 .winter-search-result p {
  font-family: 'Barlow', sans-serif;
  font-size: 14px;
  color: #8e8e93;
  margin: 0;
  padding: 20px;
  width: 100%;
  text-align: center;
}

body #mi_modal .winter-search-result {
  position: relative;
  top: auto;
  left: auto;
  right: auto;
  display: flex;
  flex-wrap: wrap;
  background: transparent;
  border: none;
  box-shadow: none;
  border-radius: 0;
  max-height: 50vh;
  overflow-y: auto;
  padding: 15px;
  margin: 0;
}

body #mi_modal .winter-search-result:empty {
  display: none;
}

body #mi_modal .winter-search-loader {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 20px;
  display: none;
  min-height: 80px;
  text-align: center;
}

body #mi_modal .search-footer-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  background: #ffffff;
  border-top: 1px solid #f2f2f7;
  cursor: pointer;
  height: 52px;
  box-sizing: border-box;
  width: 100%;
}

body #mi_modal .search-footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

body #mi_modal .search-footer-text {
  font-family: 'Barlow', sans-serif;
  font-size: 14px;
  color: #1c1c1e;
}

body #mi_modal .search-footer-text strong {
  color: #1c1c1e;
  font-weight: 600;
}

body #mi_modal .search-footer-right {
  display: flex;
  align-items: center;
}

body #mi_modal .search-loader-img,
body #mi_modal2 .search-loader-img {
  display: block;
  margin: 0 auto;
  width: 40px;
  height: 40px;
  object-fit: contain;
}

body #mi_modal input::-webkit-search-cancel-button,
body #mi_modal input::-webkit-search-decoration,
body #mi_modal2 input::-webkit-search-cancel-button,
body #mi_modal2 input::-webkit-search-decoration,
body #mi_modal input::-webkit-clear-button,
body #mi_modal2 input::-webkit-clear-button {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

body #mi_modal2.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  z-index: 99999999;
  overflow: hidden;
}

body #mi_modal2 .modal-dialog {
  width: 100%;
  height: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  position: relative;
}

body #mi_modal2 .modal-content {
  height: 100%;
  border: none;
  border-radius: 0;
  box-shadow: none;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body #mi_modal2 .modal-body {
  padding: 0;
  margin: 0;
  height: 100%;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  background: #ffffff;
}

body #mi_modal2 .search-header-area {
  width: 100%;
  background: #ffffff;
  padding: 16px 16px 20px 16px;
  box-sizing: border-box;
  border-bottom: 1px solid #f2f2f7;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  z-index: 10;
}

body #mi_modal2 .search-top-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  height: 24px;
  margin-bottom: 16px;
  width: 100%;
}

body #mi_modal2 .cerrar_modal_search {
  position: static;
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0;
  height: 24px;
  width: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  opacity: 0.8;
  transition: opacity 0.2s ease;
  box-shadow: none;
  text-shadow: none;
}

body #mi_modal2 .cerrar_modal_search:hover {
  opacity: 1;
  background: transparent;
}

body #mi_modal2 .search-controls {
  display: flex;
  flex-direction: row;
  align-items: center;
  width: 100%;
}

body #mi_modal2 .search-input-wrapper {
  flex: 1 1 auto;
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  background: #ffffff;
  border: 1px solid #c7c7cc;
  border-radius: 24px;
  height: 48px;
  padding: 0 16px;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
}

body #mi_modal2 .search-input-wrapper:focus-within {
  border-color: var(--verde);
}

body #mi_modal2 .search-icon-left {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 10px;
  flex: 0 0 auto;
}

body #mi_modal2 .search-clear-right {
  display: none;
  align-items: center;
  justify-content: center;
  margin-left: 10px;
  cursor: pointer;
  padding: 4px;
  flex: 0 0 auto;
}

body #mi_modal2 .search-clear-right.active {
  display: flex;
}

body #mi_modal2 .search-input-wrapper input#search2 {
  flex: 1 1 auto;
  width: 50px;
  height: 100%;
  border: none;
  background: transparent;
  background-color: transparent;
  background-image: none;
  padding: 0;
  margin: 0;
  font-size: 16px;
  color: #1c1c1e;
  box-shadow: none;
  outline: none;
  -webkit-appearance: none;
}

body #mi_modal2 .search-input-wrapper input#search2:focus,
body #mi_modal2 .search-input-wrapper input#search2:active {
  border: none;
  box-shadow: none;
  outline: none;
}

body #mi_modal2 div.winter-search {
  flex: 1 1 auto;
  position: relative;
  width: 100%;
  height: 100%;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body #mi_modal2 .winter-search-result {
  position: static;
  width: 100%;
  height: 100%;
  background: #ffffff;
  border-top: none;
  overflow-y: auto;
  padding: 15px;
  display: none;
  flex-wrap: wrap;
  z-index: 5;
  box-sizing: border-box;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

body #mi_modal2 .winter-search-result.active {
  display: flex;
}

body #mi_modal2 .winter-search-result:empty {
  display: none;
}

body #mi_modal2 .search-footer-area {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  background: #ffffff;
  border-top: 1px solid #f2f2f7;
  cursor: pointer;
  flex: 0 0 auto;
  height: 68px;
  box-sizing: border-box;
}

body #mi_modal2 .search-footer-area.active {
  display: flex;
}

body #mi_modal2 .search-footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

body #mi_modal2 .search-footer-text {
  font-family: 'Barlow', sans-serif;
  font-size: 14px;
  color: #1c1c1e;
}

body #mi_modal2 .search-footer-text strong {
  color: #1c1c1e;
  font-weight: 600;
}

body #mi_modal2 .search-footer-arrow {
  display: flex;
  align-items: center;
}

body.search2-open .modal-backdrop {
  z-index: 99999990;
}

body #mi_modal2 .winter-search-result .winter-cat {
  padding: 0;
  margin: 0;
  width: 100%;
  float: none;
  box-sizing: border-box;
}

body #mi_modal2 .winter-search-result .searchbr {
  background: transparent;
  border: none;
  border-bottom: 1px solid #f2f2f7;
  border-radius: 0;
  box-shadow: none;
  padding: 12px 0;
  margin: 0;
  float: none;
  width: 100%;
  display: flex;
  align-items: center;
  box-sizing: border-box;
  aspect-ratio: auto;
}

body #mi_modal2 .winter-search-result .searchbr:last-child {
  border-bottom: none;
}

body #mi_modal2 .winter-search-result .searchbr .product-info {
  flex: 0 0 60px;
  width: 60px;
  height: 75px;
  padding: 0;
  margin-right: 15px;
  float: none;
  overflow: hidden;
  border-radius: 4px;
  background: #f5f5f7;
  display: flex;
  align-items: center;
  justify-content: center;
}

body #mi_modal2 .winter-search-result .searchbr .product-info img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body #mi_modal2 .winter-search-result .searchbr .winter-dis {
  flex: 1;
  padding: 0;
  float: none;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

body #mi_modal2 .winter-search-result .nombre_search {
  font-family: 'Barlow', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: #2c2c2e;
  margin: 0 0 4px 0;
  line-height: 1.3;
}

body #mi_modal2 .winter-search-result .nombre_search a {
  color: #2c2c2e;
  text-decoration: none;
}

body #mi_modal2 .winter-search-result .price {
  font-family: 'Barlow', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #1c1c1e;
  margin: 0;
}

body #mi_modal2 .winter-search-result .price-new {
  color: #ff3b30;
  margin-right: 5px;
}

body #mi_modal2 .winter-search-result .price-old {
  color: #8e8e93;
  text-decoration: line-through;
  font-size: 11px;
  font-weight: 400;
}

body #mi_modal2 .input-group::before,
body #mi_modal2 .input-group::after {
  display: none;
  content: none;
}

body #mi_modal2 .search_modal {
  flex: 1;
  display: block;
  float: none;
  border: none;
  box-shadow: none;
  background: transparent;
  height: 100%;
  padding: 0 15px;
  margin: 0;
  font-family: 'Barlow', sans-serif;
  font-size: 15px;
  color: #333333;
  line-height: normal;
  box-sizing: border-box;
}

body #mi_modal2 .search_modal::placeholder {
  font-family: 'Barlow', sans-serif;
  color: #999999;
  opacity: 1;
}

body #mi_modal2 .boton_ejecutar_buscar {
  padding-left: 0;
}

body #mi_modal2 .cerrar_modal_search {
  padding-right: 0;
}

body #mi_modal2 .winter-search-loader {
  position: relative;
  width: 100%;
  height: 50vh;
  min-height: 300px;
  background: #ffffff;
  border-top: none;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

body #mi_modal2 .winter-search-loader[style*="display: block"] {
  display: flex;
}

body #mi_modal2 .search-loader-img {
  width: 60px;
  height: 60px;
}


body #mi_modal,
body #mi_modal2 {
  z-index: 99999;
}

body.search-open .header_desktop,
body.search-open .header_desktop_product,
body.search-open .fixed,
body.search-open .derecha_header_fixed {
  z-index: 99999999;
}

@media (min-width: 992px) {
  body .fixed,
  body .derecha_header_fixed {
    height: 52px;
  }
}
