/* Ermax global search (1.8.43): desktop dropdown, mobile full-screen overlay, compact product card. */
.ermax-header__search { position: relative; }
.ermax-header { --ermax-search-gutter: 32px; }
.ermax-header__mobile-search { display: none; color: var(--ermax-header-text, #fff); font-size: 21px; align-items: center; justify-content: center; }
.ermax-header__mobile-search svg { width: 1em; height: 1em; fill: currentColor; }

.ermax-search-panel[hidden] { display: none !important; }

.ermax-search__section + .ermax-search__section { margin-top: 16px; }
.ermax-search__label {
  margin: 0 2px 8px;
  color: #65635F;
  font-size: 11px;
  font-weight: 700;
  line-height: 16px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.ermax-search__chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.ermax-search a.ermax-search__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 6px 12px;
  color: #0C0C0C;
  background: #FFFFFF;
  border: 1px solid #DDDAD4;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 650;
  line-height: 18px;
  text-decoration: none;
  transition: border-color .18s ease, color .18s ease;
}
.ermax-search a.ermax-search__chip span { color: #65635F; font-weight: 500; }
.ermax-search a.ermax-search__chip:hover,
.ermax-search a.ermax-search__chip.is-active { color: #23845B; border-color: #3FAF7A; }

.ermax-search__products { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.ermax-search a.ermax-search-card {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 8px 12px 8px 8px;
  color: #0C0C0C;
  background: #FFFFFF;
  border: 1px solid #DDDAD4;
  border-radius: 10px;
  text-decoration: none;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.ermax-search a.ermax-search-card:hover,
.ermax-search a.ermax-search-card.is-active { border-color: #3FAF7A; box-shadow: 0 8px 22px rgba(12, 12, 12, .07); }
.ermax-search-card__img { width: 56px; height: 56px; object-fit: cover; background: #ECEAE6; border-radius: 6px; display: block; }
.ermax-search-card__body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ermax-search-card__name {
  display: -webkit-box;
  overflow: hidden;
  font-size: 14px;
  font-weight: 750;
  line-height: 18px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.ermax-search-card__meta { overflow: hidden; color: #65635F; font-size: 12px; line-height: 16px; white-space: nowrap; text-overflow: ellipsis; }
.ermax-search-card__price { color: #23845B; font-size: 13px; font-weight: 750; line-height: 18px; }
.ermax-search-card__price del { color: #65635F; font-weight: 500; margin-right: 4px; }
.ermax-search-card__price ins { text-decoration: none; }
.ermax-search-card__price .screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); }

.ermax-search__all {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 44px;
  margin-top: 16px;
  color: #07100C !important;
  background: #3FAF7A;
  border: 1px solid #3FAF7A;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color .18s ease, background-color .18s ease;
}
.ermax-search__all:hover, .ermax-search__all.is-active { color: #0C0C0C !important; background: transparent; }
.ermax-search__status { margin: 4px 2px; color: #65635F; font-size: 13px; line-height: 20px; }
.ermax-search :focus-visible { outline: 3px solid #3FAF7A; outline-offset: 2px; }

/* Mobile overlay */
.ermax-search-overlay {
  position: fixed;
  inset: 0;
  z-index: 100001;
  display: flex;
  flex-direction: column;
  background: #F7F7F7;
  font-family: Inter, sans-serif;
}
.ermax-search-overlay[hidden] { display: none !important; }
.ermax-search-overlay__head {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 0 12px 0 16px;
  background: #0C0C0C;
  border-bottom: 3px solid #3FAF7A;
}
.ermax-search-overlay__form { display: flex; flex: 1 1 auto; align-items: center; min-width: 0; height: 42px; border-bottom: 1px solid rgba(255, 255, 255, .22); }
.ermax-search-overlay__form:focus-within { border-color: #3FAF7A; }
.ermax-search-overlay__form input[type="search"] {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0 8px 0 0;
  color: #FFFFFF;
  background: transparent;
  border: 0;
  outline: 0;
  font-family: Inter, sans-serif;
  font-size: 16px;
  line-height: 22px;
}
.ermax-search-overlay__form input::placeholder { color: #BFC5C1; }
.ermax-search-overlay__close {
  display: flex !important;
  flex: 0 0 40px;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  color: #07100C;
  background: #3FAF7A !important;
  border: 1px solid #3FAF7A !important;
  border-radius: 4px;
  font-size: 20px;
  cursor: pointer;
}
.ermax-search-overlay__close svg { width: 1em; height: 1em; fill: currentColor; }
.ermax-search-overlay__body { flex: 1 1 auto; overflow: auto; padding: 16px; -webkit-overflow-scrolling: touch; }
body.ermax-search-open { overflow: hidden; }

@media (max-width: 1024px) {
  .ermax-header .ermax-header__main-inner { grid-template-columns: 40px 40px 1fr 40px 40px 40px; }
  .ermax-header__mobile-search { display: flex; width: 40px; height: 40px; grid-row: 1; grid-column: 4; }
  .ermax-header .ermax-header__account { grid-column: 5; }
  .ermax-header .ermax-header__cart { grid-column: 6; }
  .ermax-search-panel { display: none !important; }
}

/* Cart cards (drawer + cart page): moto and reference lines. */
.ermax-header__cart-panel-body .elementor-menu-cart__product-name dl.variation {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0 6px;
  margin: 4px 0 0;
  color: #65635F;
  font-size: 12px;
  line-height: 16px;
}
.ermax-header__cart-panel-body .elementor-menu-cart__product-name dl.variation dt { margin: 0; font-weight: 600; }
.ermax-header__cart-panel-body .elementor-menu-cart__product-name dl.variation dd { margin: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ermax-header__cart-panel-body .elementor-menu-cart__product-name dl.variation dd p { margin: 0; display: inline; }


/* Desktop panel, Dafy-style: full header width, side column + products on 2 columns. */
.ermax-search-panel {
  position: absolute;
  top: 100%;
  left: 50%;
  z-index: 10001;
  width: min(1360px, calc(100% - (2 * var(--ermax-search-gutter))));
  max-height: calc(100vh - 160px);
  overflow: auto;
  padding: 20px 32px 28px;
  color: #0C0C0C;
  background: #F7F7F7;
  border-top: 3px solid #3FAF7A;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .34);
  transform: translateX(-50%);
  font-family: Inter, sans-serif;
  text-align: left;
}
.ermax-search-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.ermax-search-panel__title { margin: 0; font-size: 18px; font-weight: 750; line-height: 24px; }
.ermax-search-panel__close {
  display: flex !important;
  flex: 0 0 36px;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  color: #0C0C0C !important;
  background: transparent !important;
  border: 1px solid #DDDAD4 !important;
  border-radius: 4px;
  font-size: 18px;
  cursor: pointer;
  transition: border-color .18s ease, color .18s ease;
}
.ermax-search-panel__close:hover { color: #23845B !important; border-color: #3FAF7A !important; }
.ermax-search-panel__close svg { width: 1em; height: 1em; fill: currentColor; }
.ermax-search-panel .ermax-search__status { margin: 0 0 4px; }

.ermax-search-panel .ermax-search__layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; align-items: start; }
.ermax-search-panel .ermax-search__layout--no-side,
.ermax-search-panel .ermax-search__layout--no-main { grid-template-columns: minmax(0, 1fr); }
.ermax-search-panel .ermax-search__side { padding-right: 24px; border-right: 1px solid #DDDAD4; }
.ermax-search-panel .ermax-search__side .ermax-search__section + .ermax-search__section { margin-top: 20px; padding-top: 20px; border-top: 1px solid #DDDAD4; }
.ermax-search-panel .ermax-search__label { margin-left: 0; color: #0C0C0C; font-size: 13px; letter-spacing: .06em; }
.ermax-search-panel .ermax-search__chips { display: flex; flex-direction: column; flex-wrap: nowrap; gap: 2px; }
.ermax-search-panel .ermax-search a.ermax-search__chip,
.ermax-search-panel a.ermax-search__chip {
  display: block;
  min-height: 0;
  padding: 5px 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
}
.ermax-search-panel a.ermax-search__chip:hover,
.ermax-search-panel a.ermax-search__chip.is-active { color: #23845B; text-decoration: underline; text-underline-offset: 3px; }

.ermax-search-panel .ermax-search__main .ermax-search__label { display: none; }
.ermax-search-panel .ermax-search__products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.ermax-search-panel .ermax-search a.ermax-search-card,
.ermax-search-panel a.ermax-search-card { grid-template-columns: 88px minmax(0, 1fr); gap: 16px; min-height: 104px; padding: 8px 16px 8px 8px; }
.ermax-search-panel .ermax-search-card__img { width: 88px; height: 88px; }
.ermax-search-panel .ermax-search-card__body { align-self: stretch; justify-content: flex-start; }
.ermax-search-panel .ermax-search-card__price { margin-top: auto; text-align: right; font-size: 14px; }

.ermax-search-panel a.ermax-search__all {
  display: flex !important;
  width: auto;
  min-height: 0;
  justify-content: flex-end;
  margin: 16px 0 0;
  padding: 4px 0;
  color: #0C0C0C !important;
  background: transparent;
  border: 0;
  font-size: 14px;
  letter-spacing: 0;
  text-transform: none;
}
.ermax-search-panel a.ermax-search__all::after { content: "→"; margin-left: 8px; color: #3FAF7A; font-size: 16px; }
.ermax-search-panel a.ermax-search__all:hover,
.ermax-search-panel a.ermax-search__all.is-active { color: #23845B !important; background: transparent; text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1240px) {
  .ermax-search-panel .ermax-search__layout { grid-template-columns: 200px minmax(0, 1fr); gap: 24px; }
  .ermax-search-panel .ermax-search__side { padding-right: 16px; }
}

/* Mobile overlay: sticky button. */
.ermax-search-overlay .ermax-search__all { position: sticky; bottom: 0; box-shadow: 0 -16px 0 #F7F7F7; }
.ermax-search-overlay .ermax-search__side + .ermax-search__main { margin-top: 16px; }
.ermax-search-overlay .ermax-search-card__meta { display: -webkit-box; white-space: normal; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.ermax-search-overlay__close svg, .ermax-search-panel__close svg { display: block; width: 18px; height: 18px; fill: currentColor; }
.ermax-search-overlay .ermax-search-overlay__close { width: 40px !important; min-width: 40px; height: 40px !important; padding: 0 !important; color: #07100C !important; }
.ermax-search-overlay__close svg, .ermax-search-panel__close svg { flex: 0 0 18px; min-width: 18px; }
