/* Schnellsuche-Overlay — wird auf allen Seiten genutzt (Hauptseite + Katalog) */

/* Topbar-Wrapper für mehrere Buttons (Katalog-Seiten) */
.topbar-actions { display: inline-flex; align-items: center; gap: 8px; }

/* Lupen-Trigger in der Topbar */
.cta-search {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(112, 87, 66, 0.20);
  border-radius: 50%;
  background: rgba(252, 249, 244, 0.6);
  color: var(--brand-text, #2a2520);
  cursor: pointer;
  transition: background-color .2s ease, transform .2s ease, border-color .2s ease;
}
.cta-search:hover { background: #fff; transform: scale(1.05); border-color: rgba(112, 87, 66, 0.35); }
.cta-search svg { width: 18px; height: 18px; }
@media (min-width: 720px) {
  .cta-search { width: 42px; height: 42px; }
  .cta-search svg { width: 19px; height: 19px; }
}

/* Overlay */
.search-overlay {
  position: fixed; inset: 0; z-index: 200;
  display: none;
  opacity: 0;
  transition: opacity .2s ease;
}
.search-overlay.is-open { display: block; opacity: 1; }
.search-backdrop {
  position: absolute; inset: 0;
  background: rgba(28, 28, 25, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.search-sheet {
  position: absolute;
  top: 12vh;
  left: 50%;
  transform: translateX(-50%) translateY(-12px);
  width: min(620px, calc(100vw - 24px));
  max-height: 76vh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  transition: transform .25s ease;
}
.search-overlay.is-open .search-sheet { transform: translateX(-50%) translateY(0); }
@media (max-width: 600px) {
  .search-sheet { top: 8vh; width: calc(100vw - 16px); max-height: 84vh; border-radius: 14px; }
}

/* Eingabefeld */
.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(112, 87, 66, 0.12);
  padding: 4px 8px 4px 16px;
}
.search-input-wrap .search-icon {
  width: 18px; height: 18px;
  color: rgba(112, 87, 66, 0.7);
  flex: 0 0 auto;
  margin-right: 12px;
}
.search-sheet input[type="search"] {
  flex: 1;
  border: 0;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 17px;
  padding: 16px 0;
  color: var(--brand-text, #2a2520);
  -webkit-appearance: none;
}
.search-sheet input[type="search"]::placeholder { color: rgba(112, 87, 66, 0.55); }
.search-sheet input[type="search"]::-webkit-search-decoration,
.search-sheet input[type="search"]::-webkit-search-cancel-button { display: none; }
.search-close {
  flex: 0 0 auto;
  width: 32px; height: 32px;
  border: 0; border-radius: 50%;
  background: transparent;
  color: rgba(112, 87, 66, 0.7);
  font-size: 22px; line-height: 1;
  cursor: pointer;
  display: grid; place-items: center;
  transition: background-color .2s, color .2s;
}
.search-close:hover { background: rgba(112, 87, 66, 0.08); color: var(--brand-text, #2a2520); }

/* P3 Phase 2: Filter-Pills */
.search-filters {
  padding: 4px 16px 12px;
  border-bottom: 1px solid rgba(112, 87, 66, 0.08);
  display: flex; flex-direction: column; gap: 8px;
}
.search-filter-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
}
.search-filter-label {
  flex: 0 0 60px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(112, 87, 66, 0.7);
}
.search-pill {
  flex: 0 0 auto;
  padding: 5px 12px;
  border: 1px solid rgba(112, 87, 66, 0.18);
  border-radius: 999px;
  background: transparent;
  color: var(--brand-text, #2a2520);
  font-size: 12.5px; font-weight: 500;
  cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}
.search-pill:hover {
  background: rgba(112, 87, 66, 0.08);
  border-color: rgba(112, 87, 66, 0.4);
}
.search-pill.is-active {
  background: var(--brand-gold, #705742);
  border-color: var(--brand-gold, #705742);
  color: #fff;
}
@media (max-width: 600px) {
  .search-filter-label { flex: 0 0 100%; margin-bottom: -2px; }
  .search-pill { padding: 5px 10px; font-size: 12px; }
}

/* Ergebnisliste */
.search-results {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0 12px;
  -webkit-overflow-scrolling: touch;
}
.search-hint {
  margin: 0;
  padding: 24px 24px 28px;
  font-size: 14px;
  color: rgba(112, 87, 66, 0.7);
  text-align: center;
  line-height: 1.55;
}
.search-group {
  padding: 4px 0 8px;
}
.search-group h3 {
  margin: 0;
  padding: 12px 20px 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(112, 87, 66, 0.6);
}
.search-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 20px;
  text-decoration: none;
  color: var(--brand-text, #2a2520);
  font-size: 14.5px;
  border-left: 3px solid transparent;
  transition: background-color .15s, border-color .15s;
}
.search-item strong {
  font-weight: 500;
}
.search-item .search-meta {
  font-size: 12.5px;
  color: rgba(112, 87, 66, 0.65);
  flex: 0 0 auto;
}
.search-item:hover,
.search-item.is-active {
  background: rgba(252, 249, 244, 0.95);
  border-left-color: var(--brand-gold, #b08542);
}
