/* ============================================================
   VIAJAR — Risultati ricerca
   ============================================================ */

.risultati-hero {
  background: var(--teal);
  padding-block: var(--sp-12);
}

.risultati-hero .search-box {
  opacity: 1;
  animation: none;
  margin-top: var(--sp-6);
}

/* ── Active filters row ── */
.active-filters {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
  padding-block: var(--sp-4);
  min-height: 52px;
}

.active-filters__label {
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-right: var(--sp-1);
}

.active-filters__clear {
  font-size: var(--fs-xs);
  color: var(--gold);
  margin-left: auto;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-weight: 600;
  transition: color var(--transition-fast);
}

.active-filters__clear:hover { color: #b8862f; }

/* ── Results header ── */
.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-6);
  flex-wrap: wrap;
}

.results-count {
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

.results-count strong {
  color: var(--black);
  font-weight: 700;
}

.sort-select {
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-size: var(--fs-sm);
  background: var(--white);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  cursor: pointer;
  outline: none;
  font-family: var(--font-body);
  transition: border-color var(--transition-fast);
}

.sort-select:focus { border-color: var(--gold); }

/* ── Sidebar filters ── */
.filters-sidebar {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--sp-6);
  position: sticky;
  top: calc(var(--navbar-height) + var(--sp-4));
}

.filters-title {
  font-size: var(--fs-base);
  font-weight: 700;
  margin-bottom: var(--sp-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.filters-reset {
  font-size: var(--fs-xs);
  color: var(--gold);
  font-weight: 600;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font-body);
}

.filter-group {
  padding-bottom: var(--sp-5);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--sp-5);
}

.filter-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.filter-group__title {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: var(--sp-4);
}

/* Checkbox filters */
.filter-check {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-2) 0;
  cursor: pointer;
  font-size: var(--fs-sm);
  color: var(--black);
}

.filter-check input[type="checkbox"] {
  width: 16px;
  height: 16px;
  border: 1.5px solid var(--border);
  border-radius: 3px;
  accent-color: var(--teal);
  cursor: pointer;
  flex-shrink: 0;
}

.filter-check:hover { color: var(--teal); }

/* noUiSlider custom style */
.price-range-wrap {
  padding: var(--sp-3) var(--sp-2);
}

.price-range-values {
  display: flex;
  justify-content: space-between;
  font-size: var(--fs-xs);
  color: var(--text-muted);
  margin-top: var(--sp-3);
}

.noUi-target {
  background: var(--border);
  border-radius: 4px;
  border: none;
  box-shadow: none;
  height: 4px;
}

.noUi-connects {
  border-radius: 4px;
}

.noUi-connect {
  background: var(--teal);
}

.noUi-handle {
  background: var(--white);
  border: 2px solid var(--teal);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
  width: 18px !important;
  height: 18px !important;
  top: -7px !important;
  right: -9px !important;
  cursor: grab;
}

.noUi-handle::before,
.noUi-handle::after {
  display: none;
}

/* ── Mobile filter toggle ── */
.filter-toggle-btn {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.6rem 1.25rem;
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-size: var(--fs-sm);
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font-body);
  transition: border-color var(--transition-fast), color var(--transition-fast);
}

.filter-toggle-btn:hover {
  border-color: var(--teal);
  color: var(--teal);
}

@media (min-width: 1024px) {
  .filter-toggle-btn { display: none; }
  .filters-sidebar { display: block !important; }
  .bottom-sheet .filters-sidebar {
    border: none;
    padding: 0;
    position: static;
  }
}

@media (max-width: 1023px) {
  .filters-sidebar { display: none; }
}

/* ── Bottom-sheet drawer (filtri mobile) ── */
.bottom-sheet__overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .5);
  z-index: 9998;
}
.bottom-sheet__overlay.is-open { display: block; }

.bottom-sheet {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: 85vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--white);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  box-shadow: 0 -8px 30px rgba(0, 0, 0, .25);
  z-index: 9999;
}
.bottom-sheet.is-open { display: block; }

.bottom-sheet__handle {
  width: 44px;
  height: 4px;
  border-radius: 4px;
  background: var(--border);
  margin: var(--sp-3) auto var(--sp-2);
}

.bottom-sheet__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 var(--sp-6) var(--sp-3);
  position: sticky;
  top: 0;
  background: var(--white);
  z-index: 1;
}

.bottom-sheet__title {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  margin: 0;
}

.bottom-sheet__close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cream);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}
.bottom-sheet__close:hover { background: var(--border); }

.bottom-sheet__filters {
  padding: 0 var(--sp-6);
}

.bottom-sheet__host {
  padding-bottom: var(--sp-4);
}

.bottom-sheet__apply {
  margin: var(--sp-4) var(--sp-6) var(--sp-6);
  width: calc(100% - var(--sp-6) * 2);
}

@media (min-width: 1024px) {
  .bottom-sheet,
  .bottom-sheet__overlay { display: none !important; }
}

/* ── Result card ── */
.card-result {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: border-color var(--transition-base), box-shadow var(--transition-base);
}

.card-result:hover {
  border-color: var(--teal-muted);
  box-shadow: var(--shadow-md);
}

@media (min-width: 640px) {
  .card-result--list {
    flex-direction: row;
  }

  .card-result--list .card-result__img-wrap {
    width: 220px;
    flex-shrink: 0;
    aspect-ratio: auto;
  }
}

.card-result__img-wrap {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
}

.card-result__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card-result:hover .card-result__img { transform: scale(1.04); }

.card-result__badge {
  position: absolute;
  top: var(--sp-3);
  left: var(--sp-3);
}

.card-result__body {
  padding: var(--sp-5);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-result__name {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 600;
  margin-bottom: var(--sp-1);
}

.card-result__meta {
  font-size: var(--fs-xs);
  color: var(--text-muted);
  margin-bottom: var(--sp-3);
}

.card-result__features {
  display: flex;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin-bottom: var(--sp-4);
}

.card-result__feature {
  font-size: var(--fs-xs);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-result__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: var(--sp-4);
  border-top: 1px solid var(--border);
  gap: var(--sp-4);
}

.card-result__price-from {
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.card-result__price-value {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  font-weight: 700;
  color: var(--teal);
  line-height: 1;
}
