/* ═══════════════════════════════════════════════════════════════════════
   SANLILAS — BÚSQUEDA (Luxury Search Experience)
   Liquid Glass · Glassmorphism · Smart Filters · Instant Results
   ═══════════════════════════════════════════════════════════════════════ */

.page-buscar {
  background: linear-gradient(180deg, #F8F5F1 0%, #F4EEE7 100%);
  color: #4A2E2B;
  min-height: 100vh;
}

/* ═══ SCROLL PROGRESS ═══ */
.scroll-progress {
  position: fixed; top: 0; left: 0; z-index: 9998;
  height: 3px; width: 0%;
  background: linear-gradient(90deg, #D8C4A3, #C8A46A, #C86D51);
  transition: width 0.1s linear;
  will-change: width;
  border-radius: 0 2px 2px 0;
}

/* ═══ HERO SEARCH BAR ═══ */
.srch {
  padding-top: clamp(140px, 18vh, 200px);
}

.srch-hero {
  text-align: center;
  padding: 0 1.5rem 3rem;
}

.srch-hero__title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  font-size: clamp(2.4rem, 5vw, 4rem);
  color: #4A2E2B;
  margin-bottom: 2rem;
  line-height: 1.1;
}

.srch-hero__title em {
  font-style: italic;
  color: #C8A46A;
}

.srch-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 700px;
  margin: 0 auto;
  height: 70px;
  padding: 0 28px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 20px 60px rgba(74, 46, 43, 0.1), inset 0 1px 1px rgba(255, 255, 255, 0.9);
  transition: box-shadow 0.4s, border-color 0.4s, transform 0.4s var(--ease-out-expo);
}

.srch-bar:focus-within {
  border-color: rgba(200, 164, 106, 0.6);
  box-shadow: 0 28px 80px rgba(200, 164, 106, 0.2), inset 0 1px 1px rgba(255, 255, 255, 0.9);
  transform: translateY(-2px);
}

.srch-bar svg {
  flex-shrink: 0;
  color: #C8A46A;
}

.srch-bar input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem;
  font-weight: 300;
  letter-spacing: 0.03em;
  color: #4A2E2B;
}

.srch-bar input::placeholder {
  color: rgba(74, 46, 43, 0.4);
}

/* ═══ POPULAR SEARCH TERMS ═══ */
.srch-popular {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 1.6rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: rgba(74, 46, 43, 0.5);
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.srch-pill {
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid rgba(74, 46, 43, 0.12);
  background: rgba(255, 255, 255, 0.5);
  color: rgba(74, 46, 43, 0.7);
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  cursor: pointer;
  transition: transform 0.3s var(--ease-out-expo), background 0.3s, border-color 0.3s, color 0.3s;
}

.srch-pill:hover {
  transform: translateY(-2px);
  background: rgba(200, 164, 106, 0.2);
  border-color: rgba(200, 164, 106, 0.5);
  color: #4A2E2B;
}

/* ═══ LAYOUT: FILTERS + RESULTS ═══ */
.srch-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  max-width: 1500px;
  margin: 0 auto;
  padding: 2rem clamp(1rem, 3vw, 3rem) 4rem;
  align-items: start;
}

/* ═══ FILTERS SIDEBAR ═══ */
.srch-filters {
  position: sticky;
  top: 140px;
  padding: 24px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(22px) saturate(180%);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 20px 60px rgba(74, 46, 43, 0.08), inset 0 1px 1px rgba(255, 255, 255, 0.85);
}

.srch-filters h3 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
  font-size: 1.4rem;
  color: #4A2E2B;
  margin-bottom: 1.4rem;
}

.srch-filter-group {
  margin-bottom: 1.6rem;
}

.srch-filter-group h4 {
  font-family: 'Inter', sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: rgba(74, 46, 43, 0.5);
  margin-bottom: 0.8rem;
}

.srch-filter-opts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.srch-check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  color: rgba(74, 46, 43, 0.75);
  cursor: pointer;
}

.srch-check input {
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  border: 1px solid rgba(74, 46, 43, 0.25);
  background: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.3s;
}

.srch-check input:checked {
  background: linear-gradient(135deg, #C8A46A, #D8C4A3);
  border-color: #C8A46A;
}

/* ═══ COLOR SWATCHES ═══ */
.srch-filter-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.srch-swatch {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease-elastic), border-color 0.3s, box-shadow 0.3s;
}

.srch-swatch:hover {
  transform: scale(1.2);
}

.srch-swatch.is-active {
  border-color: #C8A46A;
  box-shadow: 0 0 0 3px rgba(200, 164, 106, 0.3);
  transform: scale(1.15);
}

/* ═══ SIZE PILLS ═══ */
.srch-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.srch-size-pill {
  min-width: 40px;
  height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid rgba(74, 46, 43, 0.15);
  background: rgba(255, 255, 255, 0.5);
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  color: rgba(74, 46, 43, 0.7);
  cursor: pointer;
  transition: all 0.3s;
}

.srch-size-pill:hover {
  transform: translateY(-2px);
  border-color: rgba(200, 164, 106, 0.5);
}

.srch-size-pill.is-active {
  background: linear-gradient(135deg, #C8A46A, #D8C4A3);
  border-color: #C8A46A;
  color: #F8F5F2;
}

/* ═══ PRICE INPUTS ═══ */
.srch-price-inputs {
  display: flex;
  align-items: center;
  gap: 8px;
}

.srch-price-inputs input {
  flex: 1;
  height: 42px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(74, 46, 43, 0.15);
  background: rgba(255, 255, 255, 0.6);
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: #4A2E2B;
  outline: none;
  width: 80px;
}

.srch-price-inputs input:focus {
  border-color: #C8A46A;
}

.srch-price-inputs span {
  color: rgba(74, 46, 43, 0.3);
}

.srch-clear-filters {
  width: 100%;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(200, 164, 106, 0.4);
  background: rgba(255, 255, 255, 0.4);
  color: #C8A46A;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 0.5rem;
}

.srch-clear-filters:hover {
  background: rgba(200, 164, 106, 0.15);
  border-color: #C8A46A;
}

/* ═══ ACTIVE FILTER CHIPS ═══ */
.srch-active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 1.2rem;
  min-height: 0;
}

.srch-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(200, 164, 106, 0.15);
  border: 1px solid rgba(200, 164, 106, 0.4);
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  color: #4A2E2B;
}

.srch-chip button {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: none;
  background: rgba(200, 164, 106, 0.3);
  color: #4A2E2B;
  font-size: 0.7rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ═══ GRID ═══ */
.srch-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(16px, 1.8vw, 24px);
}

/* ═══ PRODUCT CARD ═══ */
.srch-card {
  position: relative;
  border-radius: 32px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.52);
  backdrop-filter: blur(24px) saturate(170%);
  -webkit-backdrop-filter: blur(24px) saturate(170%);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 22px 60px rgba(74, 46, 43, 0.1), inset 0 1px 1px rgba(255, 255, 255, 0.85);
  transition: transform 0.5s var(--ease-out-expo), box-shadow 0.5s, border-color 0.5s;
  will-change: transform;
  animation: srch-card-in 0.6s var(--ease-out-expo) both;
}

@keyframes srch-card-in {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.srch-card:hover {
  transform: translateY(-8px);
  border-color: rgba(200, 164, 106, 0.7);
  box-shadow: 0 36px 80px rgba(74, 46, 43, 0.16), 0 0 30px rgba(200, 164, 106, 0.12);
}

.srch-card::before {
  content: '';
  position: absolute;
  top: 0; left: -140%;
  width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-18deg);
  transition: left 1s cubic-bezier(0.2, 0.6, 0.2, 1);
  z-index: 5;
  pointer-events: none;
}

.srch-card:hover::before { left: 150%; }

.srch-card__media {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}

.srch-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease-out-expo);
}

.srch-card:hover .srch-card__media img { transform: scale(1.06); }

.srch-card__badge {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 3;
  padding: 6px 12px;
  border-radius: 999px;
  font-family: 'Inter', sans-serif;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  color: #F8F5F2;
  background: linear-gradient(135deg, rgba(200, 164, 106, 0.9), rgba(216, 196, 163, 0.7));
  border: 1px solid rgba(248, 245, 242, 0.5);
  box-shadow: 0 8px 22px rgba(200, 164, 106, 0.4);
}

.srch-card__fav {
  position: absolute;
  top: 10px; right: 10px;
  z-index: 3;
  width: 38px; height: 38px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center; justify-content: center;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  color: #4A2E2B;
  cursor: pointer;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.4s, transform 0.4s;
}

.srch-card:hover .srch-card__fav { opacity: 1; transform: translateY(0); }

.srch-card__fav.is-fav { color: #C8A46A; opacity: 1; transform: translateY(0); }
.srch-card__fav.is-fav svg { fill: currentColor; }

.srch-card__body {
  padding: 1.1rem 1.1rem 1.3rem;
}

.srch-card__name {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  font-size: 1.25rem;
  color: #4A2E2B;
  line-height: 1.1;
}

.srch-card__type {
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  font-size: 0.75rem;
  color: rgba(74, 46, 43, 0.5);
  margin-top: 2px;
}

.srch-card__price {
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  font-weight: 500;
  color: #C8A46A;
  margin-top: 8px;
}

.srch-card__colors {
  display: flex;
  gap: 7px;
  margin-top: 8px;
}

.srch-card__swatch {
  width: 16px; height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 6px rgba(74, 46, 43, 0.15);
}

/* ═══ META ═══ */
.srch-meta {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: rgba(74, 46, 43, 0.5);
  margin-bottom: 1rem;
}

/* ═══ EMPTY STATE ═══ */
.srch-empty {
  text-align: center;
  padding: 4rem 1.5rem;
}

.srch-empty__orb {
  display: block;
  width: 64px; height: 64px;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.95), rgba(216, 196, 163, 0.3) 72%);
  box-shadow: 0 16px 44px rgba(200, 164, 106, 0.25);
}

.srch-empty h3 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: 1.6rem;
  color: #4A2E2B;
}

.srch-empty p {
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  color: rgba(74, 46, 43, 0.5);
  margin: 0.8rem 0 1.6rem;
}

.srch-empty__btn {
  height: 48px;
  padding: 0 2rem;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #C8A46A, #D8C4A3);
  color: #F8F5F2;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(200, 164, 106, 0.35);
  transition: transform 0.4s, box-shadow 0.4s;
}

.srch-empty__btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 20px 44px rgba(200, 164, 106, 0.45);
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 1200px) {
  .srch-layout { grid-template-columns: 240px 1fr; }
  .srch-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .srch-layout { grid-template-columns: 1fr; }
  .srch-filters { position: static; display: none; }
  .srch-filters.is-open { display: block; }
  .srch-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .srch-hero__title { font-size: 1.8rem; }
  .srch-bar { height: 58px; padding: 0 18px; }
  .srch-bar input { font-size: 0.95rem; }
  .srch-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .srch-card { border-radius: 24px; }
  .srch-card__body { padding: 0.8rem; }
  .srch-card__name { font-size: 1rem; }
}
