/* ═══ Premium Search & Filter Drawer ═══ */

.search-page__header {
  margin-bottom: var(--space-4);
}

.search-page__title {
  font-size: 1.25rem;
  font-weight: var(--weight-bold);
  letter-spacing: -0.03em;
}

.search-page__count {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.search-type-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  margin-bottom: var(--space-3);
  padding-bottom: 4px;
}
.search-type-tabs__tab {
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--text-muted);
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
}
.search-type-tabs__tab.is-active {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}
.search-results-section { margin-bottom: var(--space-4); }
.search-results-section__title {
  font-size: 0.9375rem;
  font-weight: 700;
  margin: 0 0 var(--space-3);
  display: flex;
  align-items: center;
  gap: 8px;
}
.search-results-section__title span {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-secondary);
  padding: 2px 8px;
  border-radius: 99px;
}

.search-bar-premium {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.5rem 0.5rem 0.5rem 0.875rem;
  background: var(--bg-glass-strong);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-card);
  margin-bottom: var(--space-3);
}

.search-bar-premium:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-muted);
}

.search-bar-premium svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-bar-premium input {
  flex: 1;
  min-width: 0;
  font-size: var(--text-sm);
  background: transparent;
}

.search-toolbar {
  display: flex;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  flex-wrap: wrap;
}

.filter-open-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  font-weight: var(--weight-semibold);
  color: var(--accent);
  background: var(--accent-muted);
  border: 1px solid rgba(236, 72, 153, 0.2);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.25s ease;
}

.filter-open-btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.filter-open-btn svg { width: 16px; height: 16px; }

.filter-active-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: var(--space-3);
}

.filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.25rem 0.625rem;
  font-size: 0.625rem;
  font-weight: var(--weight-semibold);
  color: var(--accent-purple);
  background: rgba(168, 85, 247, 0.08);
  border-radius: var(--radius-full);
}

/* Filter Drawer */
.filter-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  backdrop-filter: blur(4px);
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.filter-drawer-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.filter-drawer {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: var(--app-max-width);
  max-height: 88vh;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(24px) saturate(1.3);
  border-radius: var(--radius-modal) var(--radius-modal) 0 0;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 -12px 40px rgba(15, 23, 42, 0.12);
  z-index: 201;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.filter-drawer.is-open {
  transform: translateX(-50%) translateY(0);
}

.filter-drawer__handle {
  width: 36px;
  height: 4px;
  background: var(--border-default);
  border-radius: var(--radius-full);
  margin: var(--space-3) auto var(--space-2);
}

.filter-drawer__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-4) var(--space-3);
  border-bottom: 1px solid var(--border-subtle);
}

.filter-drawer__title {
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
}

.filter-drawer__close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: none;
  cursor: pointer;
  font-size: 1.125rem;
  color: var(--text-muted);
}

.filter-drawer__body {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-4);
  -webkit-overflow-scrolling: touch;
}

.filter-group {
  margin-bottom: var(--space-5);
}

.filter-group__label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.6875rem;
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: var(--space-2);
}

.filter-group__label svg {
  width: 14px;
  height: 14px;
  color: var(--accent);
}

.filter-toggles {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-toggle {
  padding: 0.4rem 0.75rem;
  font-size: 0.6875rem;
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-toggle:hover {
  border-color: rgba(236, 72, 153, 0.25);
}

.filter-toggle.is-active {
  background: var(--accent-muted);
  color: var(--accent);
  border-color: rgba(236, 72, 153, 0.35);
  box-shadow: 0 2px 8px var(--accent-glow);
}

.filter-range {
  padding: var(--space-2) 0;
}

.filter-range__values {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: var(--weight-semibold);
  color: var(--accent);
  margin-bottom: var(--space-2);
}

.filter-range input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
  height: 4px;
}

.filter-drawer__footer {
  display: flex;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4) calc(var(--space-4) + var(--safe-bottom));
  border-top: 1px solid var(--border-subtle);
  background: rgba(255,255,255,0.9);
}

.filter-drawer__footer .btn { flex: 1; }

