/* ===== PROPERTIES PAGE - MATCH EVENTS LIST CONTAINER ===== */

/* Container card (matches .events-list-container) */
.properties-list-container {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: clamp(20px, 4vw, 32px);
  box-shadow: 0 4px 24px rgba(0,0,0,0.2);
  max-width: min(1000px, 95%);
  margin: 15px auto 0;
  width: 100%;
  box-sizing: border-box;
}

/* Header */
.section-title {
  margin: 0 0 clamp(16px, 3vw, 24px);
  font-size: clamp(1.2rem, 3vw, 1.4rem);
  color: #fff;
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: clamp(12px, 2.5vw, 16px);
}

/* Grid: 3 columns when space allows (same feel as events list) */
.properties-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
  gap: clamp(16px, 3vw, 20px);
  width: 100%;
}

/* Property tile card */
.property-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 0;
  transition: border-color 0.2s, transform 0.2s;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  width: 100%;
  box-sizing: border-box;
  text-decoration: none;
  color: inherit;
}

.property-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 6px 20px rgba(79,159,248,0.2);
}

/* Image area on tiles (top) */
.property-image {
  width: 100%;
  height: clamp(150px, 28vw, 180px);
  overflow: hidden;
  background: rgba(0,0,0,0.25);
}

.property-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* ---- Property image carousel (no stretching) ---- */
.property-image.carousel {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;               /* consistent tile height, no distortion */
  height: auto;                       /* replaces fixed pixel height */
  overflow: hidden;
  background: rgba(0,0,0,0.25);
}

.carousel-track {
  position: relative;
  width: 100%;
  height: 100%;
}

.carousel-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;                  /* fill without stretching (crops) */
  object-position: center;
  opacity: 0;
  transition: opacity .35s ease;
}

.carousel-slide.active { opacity: 1; }

/* Optional: show entire image with letterboxing (no crop) */
.property-image.carousel.fit-contain .carousel-slide {
  object-fit: contain;                /* fully visible, may letterbox */
  background: #0b1220;
}

/* Tweak ratio on smaller screens if desired */
@media (max-width: 768px) {
  .property-image.carousel { aspect-ratio: 4 / 3; }
}

/* Controls */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: clamp(30px, 6vw, 36px);
  height: clamp(30px, 6vw, 36px);
  border-radius: 50%;
  border: 1px solid var(--glass-border);
  background: rgba(11,18,32,0.8);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 2;
  transition: background .2s ease, border-color .2s ease, transform .15s ease;
}

.carousel-btn:hover {
  background: rgba(26,35,50,0.9);
  border-color: var(--accent);
  transform: translateY(-50%) scale(1.03);
}

.carousel-btn.prev { left: 10px; }
.carousel-btn.next { right: 10px; }

/* Dots */
.carousel-dots {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}

.carousel-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.5);
  transition: width .2s ease, background .2s ease;
}

.carousel-dots .dot.active {
  width: 18px;
  background: #fff;
  box-shadow: 0 0 8px rgba(255,255,255,0.5);
}

/* Content */
.property-content {
  padding: clamp(14px, 3vw, 20px);
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 2vw, 12px);
  width: 100%;
  box-sizing: border-box;
}

.property-title {
  font-size: clamp(1.1rem, 2.5vw, 1.2rem);
  color: #fff;
  margin: 0;
  font-weight: 600;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.property-address {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: clamp(0.85rem, 2vw, 0.9rem);
  flex-wrap: wrap;
}

.property-features {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  color: var(--text);
  font-size: clamp(0.85rem, 2vw, 0.95rem);
}

.property-feature {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Empty/State */
.properties-empty-note,
.properties-state {
  text-align: center;
  padding: clamp(30px, 5vw, 40px);
  color: var(--muted);
  font-size: clamp(0.9rem, 2vw, 1rem);
}

.properties-state.error { color: #ff7e7e; }

/* Pagination (match events) */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(6px, 2vw, 10px);
  margin-top: clamp(24px, 4vw, 32px);
  padding-top: clamp(16px, 3vw, 24px);
  border-top: 1px solid var(--glass-border);
  flex-wrap: wrap;
}

.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: clamp(34px, 7vw, 38px);
  min-width: clamp(38px, 8vw, 42px);
  padding: 0 clamp(12px, 2.5vw, 14px);
  background: rgba(79,159,248,0.12);
  border: 1px solid rgba(79,159,248,0.35);
  color: #fff;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  font-size: clamp(0.85rem, 2vw, 1rem);
}

.page-btn:hover:not(:disabled) {
  background: var(--accent);
  color: #062037;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(79,159,248,0.4);
}

.page-btn.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #062037;
  font-weight: 800;
  border-color: var(--accent-2);
  box-shadow: 0 4px 12px rgba(79,159,248,0.35);
}

.page-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.page-dots { color: var(--muted); padding: 0 clamp(6px, 1.5vw, 8px); font-weight: 700; }

/* Responsive */
@media (max-width: 768px) {
  .properties-list { grid-template-columns: 1fr; }
}