/* ============================================================
   HSL Filter UI
   Intentionally minimal — inherits Squarespace font/color
   ============================================================ */

#hsl-filter-ui {
  padding: 20px 0 28px;
  margin-bottom: 8px;
}

.hsl-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
}

.hsl-filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 140px;
}

.hsl-filter-group label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.6;
}

.hsl-filter-group select {
  appearance: none;
  -webkit-appearance: none;
  background-color: transparent;
  border: 1px solid currentColor;
  border-radius: 2px;
  padding: 8px 28px 8px 10px;
  font-size: 13px;
  font-family: inherit;
  color: inherit;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23666'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  min-width: 140px;
}

.hsl-filter-group select:focus {
  outline: 1px solid currentColor;
  outline-offset: 1px;
}

/* Toggle (boudoir friendly) */
.hsl-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
}

.hsl-toggle-wrap input[type="checkbox"] {
  width: 16px;
  height: 16px;
  cursor: pointer;
  accent-color: currentColor;
}

.hsl-toggle-wrap label {
  font-size: 13px;
  font-weight: normal;
  letter-spacing: normal;
  text-transform: none;
  opacity: 1;
  cursor: pointer;
}

/* Footer row */
.hsl-filter-footer {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 16px;
}

.hsl-filter-count {
  font-size: 12px;
  opacity: 0.55;
}

.hsl-filter-clear {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  font-family: inherit;
  color: inherit;
  opacity: 0.55;
  cursor: pointer;
  text-decoration: underline;
}

.hsl-filter-clear:hover {
  opacity: 1;
}

/* Mirror Squarespace's BlogList grid layout on our container */
.hsl-BlogList {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px 24px;
}

@media (max-width: 800px) {
  .hsl-BlogList { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 500px) {
  .hsl-BlogList { grid-template-columns: 1fr; }
}

/* Image placeholder for listings without a photo */
#hsl-card-grid .BlogList-item-image:not(:has(img)) {
  background-color: #f0ede8;
  aspect-ratio: 4 / 5;
  display: block;
}

/* Ensure images fill their container consistently */
#hsl-card-grid .BlogList-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Pagination */
#hsl-pagination {
  margin-top: 40px;
  margin-bottom: 20px;
}

.hsl-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  justify-content: center;
}

.hsl-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  background: none;
  border: 1px solid currentColor;
  border-radius: 2px;
  font-size: 13px;
  font-family: inherit;
  color: inherit;
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 0.15s;
}

.hsl-page-btn:hover {
  opacity: 1;
}

.hsl-page-active {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  background-color: currentColor;
  border: 1px solid currentColor;
  border-radius: 2px;
  font-size: 13px;
  opacity: 1;
}

.hsl-page-active > span {
  color: #fff;
}

.hsl-page-ellipsis {
  font-size: 12px;
  opacity: 0.35;
  padding: 0 4px;
  user-select: none;
}

/* Mobile */
@media (max-width: 640px) {
  .hsl-filters {
    flex-direction: column;
    gap: 10px;
  }

  .hsl-filter-group {
    width: 100%;
  }

  .hsl-filter-group select {
    width: 100%;
  }
}
