/* Keep the magnifier on the left of the expanding field, as in the RTL header. */
#pb-site .pb-header-search {
  --pb-search-size: 48px;
  --pb-search-border: 3px;
  --pb-search-width: 288px;
  position: relative;
  z-index: 4;
  direction: ltr;
  flex: 0 1 auto;
  min-width: var(--pb-search-size);
  width: var(--pb-search-size);
  transition: width 240ms ease;
}
#pb-site .pb-header-search.is-open { width: var(--pb-search-width); }
#pb-site .pb-header-search [hidden] { display: none !important; }
#pb-site .pb-header-search .pb-search-line {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  width: 100%;
  height: var(--pb-search-size);
  border: var(--pb-search-border) solid var(--line, #e7e8ee);
  border-radius: 999px;
  background: white;
}
#pb-site .pb-header-search:not(.is-open):hover .pb-search-line { border-color: var(--accent, #ee1c24); }
#pb-site .pb-search-line button {
  display: grid;
  place-items: center;
  flex: none;
  height: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent, #ee1c24);
  cursor: pointer;
}
#pb-site .pb-search-line button:focus-visible { outline: 2px solid var(--navy, #1b1464); outline-offset: -3px; border-radius: 999px; }
#pb-site .pb-search-trigger { width: calc(var(--pb-search-size) - var(--pb-search-border) - var(--pb-search-border)); }
#pb-site .pb-search-trigger .icon { width: 23px; height: 23px; }
#pb-site .pb-search-surface { display: contents; }
#pb-site .pb-search-line .pb-search-mobile-submit { display: none; }
#pb-site .pb-search-field {
  overflow: hidden;
  border-radius: 0 999px 999px 0;
  display: flex;
  flex: 1;
  align-items: center;
  min-width: 0;
  height: 100%;
}
#pb-site .pb-search-field::before { content: ""; height: 15px; border-left: 1px solid var(--line, #e7e8ee); }
#pb-site .pb-search-field input {
  flex: 1;
  min-width: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0 5px;
  border: 0;
  background: transparent;
  color: #191637;
  font: inherit;
  font-size: 14px;
  text-align: right;
  outline: 0;
  box-shadow: none;
}
#pb-site .pb-search-line:focus-within { border-color: #bcb9cd; }
#pb-site .pb-search-field input::-webkit-search-cancel-button { -webkit-appearance: none; }
#pb-site .pb-search-field button { width: 34px; color: #686479; }
#pb-site .pb-search-field .icon { width: 15px; height: 15px; }
#pb-site .pb-search-panel {
  position: absolute;
  top: calc(100% + 7px);
  left: 0;
  box-sizing: border-box;
  width: 100%;
  padding: 8px;
  border: 1px solid #dedee6;
  border-radius: 12px;
  background: white;
  box-shadow: 0 12px 36px #14104222;
  color: #181544;
  text-align: right;
}
#pb-site .pb-search-status { margin: 4px; font-size: 13px; color: #514d65; }
#pb-site .pb-search-status:empty { display: none; }
#pb-site .pb-search-results { list-style: none; margin: 0; padding: 0; max-height: min(45vh, 340px); overflow: auto; overscroll-behavior: contain; }
#pb-site .pb-search-results li + li { border-top: 1px solid #ededf2; }
#pb-site .pb-search-results a { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 5px 4px; text-align: right; color: #201b4c; text-decoration: none; }
#pb-site .pb-search-results a:hover, #pb-site .pb-search-results a:focus-visible { background: #f5f5f9; }
#pb-site .pb-search-results img { display: block; flex: none; width: 36px; height: 36px; object-fit: contain; }
#pb-site .pb-search-all { display: block; margin-top: 8px; padding: 6px; color: #1b1464; text-align: center; font-weight: 600; }

@media (max-width: 991px) {
  #pb-site .site-header .header-main { position: relative; }
  #pb-site .pb-header-search {
    --pb-search-size: 36px;
    --pb-search-border: 1px;
    --pb-search-width: var(--pb-search-size);
    position: static;
    flex: none;
    margin-left: 6px;
    transition: none;
  }
  #pb-site .pb-search-trigger .icon { width: 19px; height: 19px; }
  #pb-site .pb-search-surface {
    position: absolute;
    z-index: 5;
    inset-inline: 8px;
    top: calc(100% + 4px);
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    padding: 8px;
    max-height: calc(100vh - 88px);
    max-height: min(460px, max(64px, var(--pb-search-room, calc(100dvh - 88px))));
    overflow: auto;
    overscroll-behavior: contain;
    border: 1px solid #dedee6;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 8px 26px #14104224;
  }
  #pb-site .pb-search-field {
    flex: none;
    height: 44px;
    box-sizing: border-box;
    border: 1px solid #c5c3d2;
    border-radius: 9px;
  }
  #pb-site .pb-search-field:focus-within { border-color: var(--navy, #1b1464); }
  #pb-site .pb-search-field::before { content: none; }
  #pb-site .pb-search-field input { font-size: 16px; }
  #pb-site .pb-search-field button { width: 44px; }
  #pb-site .pb-search-field .pb-search-mobile-submit { display: grid; color: var(--accent, #ee1c24); }
  #pb-site .pb-search-mobile-submit .icon { width: 19px; height: 19px; }
  #pb-site .pb-search-panel {
    position: static;
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 6px 0 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
  #pb-site .pb-search-results { min-height: 0; max-height: 340px; }
  #pb-site .pb-search-all { flex: none; }
}
@media (max-width: 600px) {
  /* Match the resting header, with the menu in its own grid track. */
  #pb-site .site-header .header-main { grid-template-columns: 44px minmax(0, 1fr); }
  #pb-site .site-header .header-main > .brand { grid-column: 2; }
  #pb-site .site-header .header-main > .header-tools { grid-column: 2; justify-self: stretch; pointer-events: none; }
  #pb-site .site-header .header-main > .header-tools > * { pointer-events: auto; }
}
@media (max-width: 440px) {
  #pb-site .header-main .pb-header-contact .phone-text { max-width: 140px; overflow: hidden; white-space: nowrap; }
}
@media (max-width: 359px) {
  #pb-site .site-header .header-main > .brand { width: max(0px, min(109px, calc(100% - 165px))); }
}
@media (max-width: 991px) and (prefers-reduced-motion: no-preference) {
  #pb-site .pb-header-search.is-open .pb-search-surface { animation: pb-mobile-search-open 150ms ease-out; }
}
@keyframes pb-mobile-search-open {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  #pb-site .pb-header-search { transition: none; }
}

/* FaraShop search renders the same native cards directly in its own list. */
#pb-site #farashop__search-result .js__product-list.product-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  gap: 28px;
  margin: 0;
  padding: 26px 29px 0;
  background: transparent;
}
#pb-site #farashop__search-result .js__product-list.product-list::before,
#pb-site #farashop__search-result .js__product-list.product-list::after { display: none; content: none; }
#pb-site #farashop__search-result .js__product-list.product-list > .pb-product-card {
  display: flex;
  float: none;
  width: 100%;
  max-width: none;
  min-width: 0;
  padding: 0;
  margin: 0;
}
@media (max-width: 991px) {
  #pb-site #farashop__search-result .js__product-list.product-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; padding-inline: 0; }
}
@media (max-width: 600px) {
  #pb-site #farashop__search-result .js__product-list.product-list { grid-template-columns: minmax(0, 1fr); gap: 25px; max-width: 390px; margin-inline: auto; }
}
