/* Dedicated search page — extends categories page design language. */
.search-page .category-browse { margin-top: 8px; }
.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.9fr) auto;
  gap: 10px;
  margin-bottom: 18px;
}
.search-panel-go {
  min-height: 54px;
  padding: 0 22px;
  border-radius: 12px;
  background: #003b37;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}
.search-panel-go:hover { background: #01554e; }

.search-filters {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr)) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 16px;
}
.search-filter {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.search-filter span {
  font-size: 11px;
  font-weight: 700;
  color: #5f766d;
}
.search-filter select,
.search-filter input {
  width: 100%;
  min-height: 46px;
  padding: 0 12px;
  border: 1px solid #dce5df;
  border-radius: 12px;
  background: #fff;
  font-size: 13px;
}
.search-filter select:focus,
.search-filter input:focus {
  outline: none;
  border-color: #218a70;
  box-shadow: 0 0 0 3px #218a7018;
}
.search-reset {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid #dce5df;
  border-radius: 12px;
  background: #fff;
  font-size: 12px;
  font-weight: 700;
  color: #3f5f55;
  white-space: nowrap;
}
.search-reset:hover { background: #eaf2ec; }

.search-page #search-groups { margin-top: 4px; margin-bottom: 4px; }

.search-page .search-ad-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.search-page .ad-card {
  background: #fff;
  border: 1px solid #e0e7e1;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.search-page .ad-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px #193e3010;
  border-color: #aac8b5;
}
.search-page .ad-photo {
  aspect-ratio: 1;
  background: #e8f1eb;
  display: grid;
  place-items: center;
  font-size: 42px;
  font-weight: 800;
  color: #7a9588;
  overflow: hidden;
}
.search-page .ad-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.search-page .ad-copy { padding: 12px 12px 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.search-page .ad-copy h3 {
  margin: 0;
  font-size: 14px;
  line-height: 1.3;
  letter-spacing: -.02em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.search-page .price { margin: 0; font-size: 15px; font-weight: 800; color: #003b37; }
.search-page .meta {
  margin: 0;
  font-size: 12px;
  color: #6a8176;
  display: flex;
  align-items: center;
  gap: 4px;
}
.search-page .meta .ui-icon { width: 14px; height: 14px; flex-shrink: 0; }
.search-page .ad-card-bottom {
  display: flex;
  align-items: center;
  gap: 6px;
  border-top: 1px solid #edf0eb;
  margin-top: 6px;
  padding-top: 8px;
}
.search-page .ad-updated { font-size: 10px; color: #758980; flex: 1; min-width: 0; }
.search-page .ad-fav {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #f3f7f3;
  color: #557c68;
  display: grid;
  place-items: center;
  margin-left: auto;
}
.search-page .ad-fav .ui-icon { width: 16px; height: 16px; }
.search-page .ad-fav.is-on { color: #007c61; background: #def0e3; }

@media (max-width: 1000px) {
  .search-filters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .search-page .search-ad-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .search-panel { grid-template-columns: 1fr; }
  .search-panel-go { width: 100%; }
  .search-filters { grid-template-columns: 1fr 1fr; }
  .search-reset { grid-column: 1 / -1; }
  .search-page .search-ad-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .search-page .ad-card { transition: none; }
  .search-page .ad-card:hover { transform: none; }
}

/* Unified search: marketplace filters only on the Marketplace tab. */
.search-page[data-type="all"] .search-market-filters { display: none !important; }
