/* ══════════════════════════════════════════════════════════════
   LISTING ENGINE — shared browse grid + detail/booking components
   Used by short-term.html today; long-term.html can adopt the same
   engine once real bookable property data exists.
   ══════════════════════════════════════════════════════════════ */

/* ─── Browsable grid ─────────────────────────────────────────── */
.le-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.le-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
  font-size: 15px;
}
.le-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-alt, #f5f5f7);
  border: 1px solid var(--border, rgba(0,0,0,0.08));
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  transition: transform .35s cubic-bezier(.16,1,.3,1), box-shadow .35s, border-color .35s;
}
.le-card:hover {
  transform: translateY(-6px);
  border-color: rgba(53,90,50,.35);
  box-shadow: 0 26px 60px rgba(0,0,0,.14);
}
.le-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0b1020;
}
.le-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.le-card-badge {
  position: absolute; top: 14px; left: 14px;
  background: rgba(11,16,32,.78);
  color: #fff; backdrop-filter: blur(6px);
  font-size: 11.5px; font-weight: 600;
  padding: 5px 12px; border-radius: 100px;
  border: 1px solid rgba(255,255,255,.14);
}
.le-card-body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 8px; }
.le-card-title { font-family: var(--font-display); font-size: 18px; font-weight: 700; letter-spacing: -.01em; color: var(--text); margin: 0; }
.le-card-sub { font-size: 13px; color: var(--text-muted); margin: 0; }
.le-card-price { margin-top: 6px; font-size: 15px; font-weight: 700; color: var(--accent); }
.le-card-price span { font-size: 12px; font-weight: 500; color: var(--text-muted); }

/* ─── Detail / booking view ──────────────────────────────────── */
.le-detail { }
.le-back {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: none; cursor: pointer;
  font-size: 13.5px; font-weight: 600; color: var(--text-muted);
  margin-bottom: 24px; padding: 0;
}
.le-back:hover { color: var(--accent); }

/* Specs row (populated dynamically per listing) */
.specs-grid-mini {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}
.spec-item-mini {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  padding: 12px;
  text-align: center;
}
.spec-item-mini strong { display: block; font-size: 16px; color: var(--text); font-family: var(--font-display); }
.spec-item-mini span { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }

/* Carousel */
.carousel-container {
  position: relative; width: 100%; aspect-ratio: 16/10;
  border-radius: 20px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #0d0d11; margin-bottom: 24px;
}
.carousel-track { display: flex; width: 100%; height: 100%; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.carousel-slide { min-width: 100%; height: 100%; position: relative; }
.carousel-slide img { width: 100%; height: 100%; object-fit: cover; }
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(13, 13, 17, 0.6); border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff; font-size: 18px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s; z-index: 5; backdrop-filter: blur(8px);
}
.carousel-btn:hover { background: rgba(255, 255, 255, 0.15); border-color: rgba(255, 255, 255, 0.4); }
.carousel-btn.prev { left: 16px; }
.carousel-btn.next { right: 16px; }
.carousel-dots { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; z-index: 5; }
.carousel-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, 0.4); cursor: pointer; transition: all 0.25s; }
.carousel-dot.active { background: #fff; transform: scale(1.4); }

/* Calendar widget */
.calendar-widget {
  background: rgba(13, 13, 17, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px; padding: 24px;
  backdrop-filter: blur(20px); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}
.calendar-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.calendar-title { font-size: 18px; font-weight: 600; color: var(--text); font-family: var(--font-display); }
.calendar-nav-btn {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text-muted); transition: all 0.2s;
}
.calendar-nav-btn:hover { background: rgba(255, 255, 255, 0.05); color: var(--text); border-color: rgba(255, 255, 255, 0.3); }
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.weekday-lbl { font-size: 11px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; padding-bottom: 12px; }
.calendar-day {
  aspect-ratio: 1; display: flex; align-items: center; justify-content: center;
  font-size: 13.5px; font-weight: 500; border-radius: 50%; cursor: pointer;
  position: relative; transition: all 0.2s; color: var(--text); user-select: none;
}
.calendar-day.empty { cursor: default; }
.calendar-day.past { color: rgba(255, 255, 255, 0.15); cursor: not-allowed; text-decoration: line-through; }
.calendar-day.blocked { color: rgba(255, 255, 255, 0.2); cursor: not-allowed; position: relative; }
.calendar-day.blocked::after {
  content: ''; position: absolute; width: 60%; height: 1px;
  background: rgba(204, 0, 0, 0.5); transform: rotate(-45deg);
}
.calendar-day:not(.empty):not(.past):not(.blocked):hover { background: rgba(255, 255, 255, 0.1); }
.calendar-day.selected { background: var(--text) !important; color: #000 !important; font-weight: 700; box-shadow: 0 0 14px rgba(255, 255, 255, 0.4); }
.calendar-day.in-range { background: rgba(255, 255, 255, 0.08); border-radius: 0; }
.calendar-day.in-range:hover { background: rgba(255, 255, 255, 0.12); }
.calendar-day.range-start { border-top-left-radius: 50%; border-bottom-left-radius: 50%; background: #fff !important; color: #000 !important; }
.calendar-day.range-end { border-top-right-radius: 50%; border-bottom-right-radius: 50%; background: #fff !important; color: #000 !important; }

/* Cost breakdown */
.quote-box { margin-top: 24px; padding: 20px; background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 16px; }
.quote-row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 13.5px; color: var(--text-muted); }
.quote-row.total { font-size: 18px; font-weight: 600; color: var(--text); border-top: 1px solid rgba(255, 255, 255, 0.1); padding-top: 12px; margin-top: 8px; margin-bottom: 0; }

/* Member verify box */
.verify-box { background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 16px; padding: 16px; margin-top: 20px; }
.verify-row { display: flex; gap: 8px; margin-top: 8px; }

/* Success overlay */
.success-overlay {
  position: fixed; inset: 0; z-index: 10000;
  background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(20px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.4s ease;
}
.success-overlay.active { opacity: 1; pointer-events: auto; }
.success-card {
  max-width: 500px; width: min(100% - 32px, 500px);
  background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px; padding: 40px; text-align: center;
  box-shadow: 0 30px 80px rgba(0,0,0,0.6);
  transform: translateY(20px); transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.success-overlay.active .success-card { transform: translateY(0); }
.success-icon { font-size: 48px; margin-bottom: 24px; display: inline-block; animation: leGlow 2s infinite; }
@keyframes leGlow {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 5px rgba(255,215,0,0.4)); }
  50% { transform: scale(1.1); filter: drop-shadow(0 0 15px rgba(255,215,0,0.8)); }
}

/* Compliance / included-terms table */
.compliance-matrix { width: 100%; border-collapse: collapse; font-size: 13.5px; margin-top: 12px; }
.compliance-matrix td { padding: 10px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.06); color: var(--text-muted); }
.compliance-matrix td strong { color: var(--text); margin-right: 12px; font-family: var(--font-display); }

/* ─── Host / member trust card ───────────────────────────────── */
.le-host-card {
  display: flex; gap: 16px; align-items: flex-start;
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px; padding: 18px 20px; margin-top: 4px;
}
.le-host-avatar {
  width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  border: 2px solid rgba(184,137,63,.5);
}
.le-host-name { font-family: var(--font-display); font-size: 15.5px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.le-host-badge {
  font-size: 10.5px; font-weight: 700; letter-spacing: .03em;
  color: #14110a; background: var(--gold-grad, var(--gold));
  padding: 3px 9px; border-radius: 999px;
}
.le-host-role { font-size: 12.5px; color: var(--text-muted); margin-top: 2px; line-height: 1.5; }
.le-host-stats { display: flex; gap: 18px; margin-top: 10px; }
.le-host-stats div { text-align: left; }
.le-host-stats strong { display: block; font-size: 14px; color: var(--text); font-family: var(--font-display); }
.le-host-stats span { font-size: 10.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.le-host-quote {
  margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,0.08);
  font-size: 12.5px; line-height: 1.6; color: var(--text-muted); font-style: italic;
}
.le-host-quote strong { font-style: normal; color: var(--text); }

@media (max-width: 640px) {
  .le-host-card { flex-direction: column; align-items: flex-start; }
  .le-host-stats { gap: 14px; }
}
