/* Reality — katalog, mapa, detail modal */

#props-map {
  height: 560px;
  width: 100%;
  background: #141219;
}

html.light #props-map { background: #e9e2d3; }

/* Přepínací pilulky Katalog/Mapa (stejný vzor jako filter-btn v adminu) */
.filter-pill {
  color: rgba(244, 239, 230, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.filter-pill.active {
  color: #d4b684;
  border-color: rgba(212, 182, 132, 0.4);
  background: rgba(212, 182, 132, 0.08);
}

html.light .filter-pill { color: rgba(22, 20, 27, 0.5); border-color: rgba(22, 20, 27, 0.15); }
html.light .filter-pill.active {
  color: #7a6142;
  border-color: rgba(122, 97, 66, 0.45);
  background: rgba(212, 182, 132, 0.14);
}

/* Karta nemovitosti */
.prop-card {
  cursor: pointer;
}

.prop-card .prop-img {
  aspect-ratio: 4 / 3;
  width: 100%;
  object-fit: cover;
  background: linear-gradient(135deg, #141219, #0c0a10);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

html.light .prop-card .prop-img { background: linear-gradient(135deg, #e9e2d3, #f1ece1); }

.prop-card:hover .prop-img { transform: scale(1.04); }

.prop-badge {
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  backdrop-filter: blur(8px);
}

.prop-badge-prodej { background: rgba(212, 182, 132, 0.9); color: #08070a; }
.prop-badge-pronajem { background: rgba(12, 10, 16, 0.75); color: #e8cfa6; border: 1px solid rgba(212, 182, 132, 0.4); }

/* Stav nabídky — funguje na tmavém i světlém motivu (plné barvy, bílý text/černý text) */
.prop-badge-reserved { background: rgba(245, 158, 11, 0.95); color: #1c1917; }
.prop-badge-sold { background: rgba(220, 38, 38, 0.95); color: #ffffff; }

/* Detail modal */
.prop-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 7, 10, 0.82);
  backdrop-filter: blur(8px);
}

html.light .prop-modal-backdrop { background: rgba(246, 242, 234, 0.85); }

.prop-modal-card {
  position: relative;
  max-width: 56rem;
  margin: 4rem auto;
  background: #0c0a10;
  border: 1px solid rgba(212, 182, 132, 0.25);
  border-radius: 1.5rem;
  overflow: hidden;
}

html.light .prop-modal-card { background: #ffffff; border-color: rgba(122, 97, 66, 0.3); }

.prop-gallery-main {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #141219;
}

html.light .prop-gallery-main { background: #e9e2d3; }

.prop-thumb {
  width: 5.5rem;
  height: 4rem;
  object-fit: cover;
  border-radius: 0.5rem;
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 0.2s, outline 0.2s;
  outline: 2px solid transparent;
  flex: none;
}

.prop-thumb.active,
.prop-thumb:hover { opacity: 1; outline-color: #d4b684; }

/* Leaflet — sladění s tématem */
.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: #0c0a10;
  color: #f4efe6;
  border: 1px solid rgba(212, 182, 132, 0.3);
}

html.light .leaflet-popup-content-wrapper,
html.light .leaflet-popup-tip {
  background: #ffffff;
  color: #16141b;
  border-color: rgba(122, 97, 66, 0.3);
}

.leaflet-popup-content { margin: 10px 14px; font-family: 'Geist', system-ui, sans-serif; }
.leaflet-popup-content a { color: #d4b684; text-decoration: underline; cursor: pointer; }
html.light .leaflet-popup-content a { color: #7a6142; }

@media (max-width: 640px) {
  #props-map { height: 420px; }
  .prop-modal-card { margin: 1rem auto; }
}
