/* ============================================
   Header-Suche: Live-Autocomplete (bh-live-search.js)
   Nur .search-modal / .bh-ls — keine globalen Selektoren.
   ============================================ */

.search-modal {
  max-height: 100vh;
  max-height: 100dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.search-modal-inner {
  max-width: 880px;
}

.search-modal-form {
  max-width: 640px;
  margin: 0 auto;
}

.bh-ls {
  text-align: left;
  transition: opacity 0.15s;
}

.bh-ls.is-filled {
  margin-top: 2rem;
}

.bh-ls.is-loading {
  opacity: 0.55;
}

.bh-ls-section + .bh-ls-section {
  margin-top: 1.75rem;
}

.bh-ls-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.bh-ls-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #E6503E;
}

.bh-ls-clear {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  color: #6b7280;
  text-decoration: underline;
  cursor: pointer;
}

.bh-ls-clear:hover {
  color: #000;
}

/* Pills */
.bh-ls-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.bh-ls-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.9rem;
  border: 1px solid #e5e5e5;
  border-radius: 31px;
  background: #fff;
  color: #000;
  font-size: 13px;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}

.bh-ls-pill:hover,
.bh-ls-pill:focus-visible {
  border-color: #E6503E;
  color: #E6503E;
  outline: none;
}

.bh-ls-pill--history {
  font-weight: 700;
}

.bh-ls-pill--need {
  background: #F8F8F8;
  border-color: #F8F8F8;
}

/* Produkt-Treffer */
.bh-ls-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.bh-ls-product {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 0.6rem;
  border-radius: 6px;
  color: #000;
  text-decoration: none;
  transition: background-color 0.15s;
}

.bh-ls-product:hover,
.bh-ls-product:focus-visible {
  background: #F8F8F8;
  outline: none;
}

.bh-ls-thumb {
  flex: 0 0 72px;
  width: 72px;
  height: 72px;
  background: #F8F8F8;
  border-radius: 4px;
  overflow: hidden;
}

.bh-ls-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.bh-ls-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.bh-ls-stufe {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b7280;
}

.bh-ls-name {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.bh-ls-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.bh-ls-chip {
  padding: 0.1rem 0.5rem;
  border-radius: 31px;
  background: #F8F8F8;
  font-size: 11px;
  color: #374151;
}

.bh-ls-price {
  font-size: 14px;
  color: #000;
}

.bh-ls-price del {
  color: #9ca3af;
  margin-right: 0.25rem;
}

.bh-ls-price ins {
  text-decoration: none;
  color: #E6503E;
}

.bh-ls-oos {
  font-size: 11px;
  color: #6b7280;
}

/* Zuletzt angesehen (horizontal) */
.bh-ls-recent {
  display: flex;
  gap: 0.75rem;
  margin: 0;
  padding: 0 0 0.5rem;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.bh-ls-recent > li {
  flex: 0 0 132px;
  scroll-snap-align: start;
}

.bh-ls-recent-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: #000;
  text-decoration: none;
}

.bh-ls-recent-card .bh-ls-thumb {
  flex: none;
  width: 132px;
  height: 132px;
}

.bh-ls-recent-card .bh-ls-name {
  font-size: 13px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.bh-ls-recent-card:hover .bh-ls-name,
.bh-ls-recent-card:focus-visible .bh-ls-name {
  color: #E6503E;
}

/* Magazin & Service */
.bh-ls-content {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bh-ls-content a {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.5rem 0.6rem;
  border-radius: 6px;
  color: #000;
  font-size: 14px;
  text-decoration: none;
}

.bh-ls-content a:hover,
.bh-ls-content a:focus-visible {
  background: #F8F8F8;
  outline: none;
}

.bh-ls-type {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b7280;
}

/* CTA / leer */
.bh-ls-all {
  margin-top: 1.5rem;
  text-align: center;
}

.bh-ls-all-btn {
  display: inline-block;
  padding: 0.5rem 1.15rem;
  border: 1px solid #000;
  border-radius: 31px;
  color: #000;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}

.bh-ls-all-btn:hover,
.bh-ls-all-btn:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
}

.bh-ls-empty {
  text-align: center;
}

.bh-ls-empty p {
  margin: 0 0 1rem;
  color: #374151;
}

.bh-ls-empty .bh-ls-pills {
  justify-content: center;
  margin-bottom: 1.25rem;
}

@media (max-width: 640px) {
  .bh-ls.is-filled {
    margin-top: 1.5rem;
  }
  .bh-ls-products {
    grid-template-columns: 1fr;
  }
  .bh-ls-thumb {
    flex-basis: 60px;
    width: 60px;
    height: 60px;
  }
  .bh-ls-recent > li {
    flex-basis: 112px;
  }
  .bh-ls-recent-card .bh-ls-thumb {
    width: 112px;
    height: 112px;
  }
}
