/* Styli mobile search overlay */

.zs-search {
  display: none;
}

@media (max-width: 1023px) {
  body.zs-search-on {
    overflow: hidden;
  }

  body.zs-search-on header.sticky,
  body.zs-search-on .zs-bn,
  body.zs-search-on .zs-cats,
  body.zs-search-on .zs-mweb-tabs,
  body.zs-search-on .zs-plp-filters {
    display: none !important;
  }

  .zs-search {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    z-index: 90;
    background: #fff;
    font-family: "Noto Sans", Inter, sans-serif;
  }

  .zs-search-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 15px;
    background: #fff;
    flex-shrink: 0;
  }

  .zs-search-ico {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    color: #2d2d2d;
    background: #fff;
    flex-shrink: 0;
    text-decoration: none;
    padding: 0;
    cursor: pointer;
  }

  .zs-search-ico svg {
    display: block;
  }

  html[dir="rtl"] .zs-search-ico[data-back] svg {
    transform: scaleX(-1);
  }

  .zs-search-field {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    height: 30px;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 0 4px 0 0;
    background: #fff;
  }

  .zs-search-field svg {
    flex-shrink: 0;
    margin: 0 10px;
  }

  .zs-search-field input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: none;
    font-size: 12px;
    padding: 0;
    height: 28px;
    background: transparent;
    color: #2d2d2d;
    font-family: inherit;
  }

  .zs-search-body {
    flex: 1;
    overflow-y: auto;
    border-top: 1px solid #ececec;
    padding: 15px 15px 24px;
    -webkit-overflow-scrolling: touch;
  }

  .zs-search-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
  }

  .zs-search-title {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #000;
    display: flex;
    align-items: center;
    gap: 4px;
  }

  .zs-search-clear {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: #000;
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
    padding: 0;
  }

  .zs-search-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
  }

  .zs-search-chip {
    border: 0;
    cursor: pointer;
    color: #424242;
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.04em;
    padding: 5px 10px;
    border-radius: 5px;
    background: #f0eee8;
    font-family: inherit;
  }

  .zs-search-chip.trend {
    font-size: 12px;
    padding: 8px 12px;
    background: linear-gradient(180deg, #f4f4f4 0%, #e8e8e8 100%);
  }

  .zs-search-banner {
    display: block;
    margin: 16px 0 0;
  }

  .zs-search-banner img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 4px;
  }

  .zs-search-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 20px -6px 0;
  }

  .zs-search-card {
    flex: 0 0 33.333%;
    max-width: 33.333%;
    box-sizing: border-box;
    padding: 0 6px 16px;
    text-decoration: none;
    color: inherit;
  }

  .zs-search-card figure {
    margin: 0;
    position: relative;
    background: #f4f4f4;
    border-radius: 10px;
    overflow: hidden;
  }

  .zs-search-card img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: contain;
  }

  .zs-search-bag {
    position: absolute;
    right: 8px;
    bottom: 10px;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .zs-search-price {
    margin-top: 6px;
    font-size: 13px;
    font-weight: 700;
    color: #2d2d2d;
    letter-spacing: 0.04em;
  }

  .zs-search-price del {
    margin-left: 5px;
    font-size: 10px;
    font-weight: 400;
    color: #9a9a9a;
  }

  .zs-search-off {
    display: inline-block;
    margin-top: 2px;
    font-size: 10px;
    font-weight: 700;
    color: #d64045;
    background: rgba(214, 64, 69, 0.1);
    padding: 1px 4px;
    text-transform: uppercase;
  }

  .zs-search-more {
    display: block;
    width: 100%;
    margin: 8px auto 20px;
    background: none;
    border: 0;
    font-size: 10px;
    font-weight: 500;
    color: #000;
    cursor: pointer;
    text-align: center;
    font-family: inherit;
  }

  /* Search results header + filter pills */
  body.zs-plp-on header.sticky > div[class*="max-w"] {
    display: grid !important;
    grid-template-columns: 32px 32px minmax(0, 1fr) 32px 32px !important;
    grid-template-areas: "back menu search wish bag" !important;
    align-items: center;
    column-gap: 8px !important;
    row-gap: 0 !important;
    padding: 15px !important;
    border-bottom: 1px solid #ececec;
  }

  body.zs-plp-on .zs-mweb-tabs,
  body.zs-plp-on .zs-mh-logo,
  body.zs-plp-on header a[href="/"] img[alt="Zosouq"] {
    display: none !important;
  }

  body.zs-plp-on .zs-plp-back {
    grid-area: back;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    background: #fff;
    padding: 0;
    cursor: pointer;
    color: #2d2d2d;
  }

  html[dir="rtl"] body.zs-plp-on .zs-plp-back svg {
    transform: scaleX(-1);
  }

  body.zs-plp-on header .zs-mh-search form > div.relative,
  body.zs-plp-on header div[class*="sm:hidden"] form > div.relative {
    height: 32px !important;
    border-radius: 8px !important;
    background: #f3f1ec !important;
    border: 1px solid #e4dfd4 !important;
    padding: 0 12px 0 10px !important;
  }

  body.zs-plp-on header div[class*="sm:hidden"] input[type="text"] {
    height: 32px !important;
    font-size: 14px !important;
  }

  body.zs-plp-on header .justify-end > a[href="/cart"],
  body.zs-plp-on header a[href="/cart"] {
    grid-area: bag;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 32px !important;
    height: 32px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 1px solid #e8e8e8 !important;
    border-radius: 8px !important;
    background: #fff !important;
    color: #2d2d2d !important;
    position: relative !important;
    justify-self: end;
  }

  body.zs-plp-on header a[href="/cart"] svg {
    width: 18px !important;
    height: 18px !important;
  }

  body.zs-plp-on header a[href="/cart"] span {
    position: absolute !important;
    top: -4px;
    right: -4px;
    min-width: 15px;
    height: 15px;
    padding: 0 3px;
    border-radius: 50%;
    background: #e85d4c !important;
    color: #fff !important;
    font-size: 10px !important;
    font-weight: 500;
    line-height: 15px;
    text-align: center;
  }

  .zs-plp-filters {
    position: sticky;
    top: 62px;
    z-index: 25;
    background: #fff;
    padding: 10px 0;
    font-family: "Noto Sans", Inter, sans-serif;
  }
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0 12px 6px;
    gap: 0;
  }

  .zs-plp-pills::-webkit-scrollbar {
    display: none;
  }

  .zs-plp-pill {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    height: 22px;
    margin: 0 4px;
    padding: 0 8px;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    background: #fff;
    color: #000;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.04em;
    line-height: 16px;
    white-space: nowrap;
    cursor: pointer;
    font-family: inherit;
  }

  .zs-plp-pill.is-on {
    border-color: #2d2d2d;
    font-weight: 600;
  }

  .zs-plp-pill svg {
    margin-left: 8px;
    margin-bottom: 1px;
  }

  html[dir="rtl"] .zs-plp-pill svg {
    margin-left: 0;
    margin-right: 8px;
  }

  .zs-plp-drop {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: #fff;
    border-top: 1px solid #ececec;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
    max-height: 50vh;
    overflow-y: auto;
    padding: 8px 0;
    z-index: 26;
  }

  .zs-plp-filters.is-open .zs-plp-drop {
    display: block;
  }

  .zs-plp-opt {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: 0;
    padding: 12px 16px;
    font-size: 13px;
    color: #2d2d2d;
    cursor: pointer;
    font-family: inherit;
  }

  .zs-plp-opt.is-on {
    font-weight: 600;
    background: #f7f7f7;
  }

  body.zs-plp-on .max-w-7xl.mx-auto {
    padding-top: 8px !important;
    padding-bottom: 88px !important;
  }

  body.zs-plp-on .max-w-7xl.mx-auto > .mb-8 {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  .zs-search {
    display: none !important;
  }
}
