:root {
  --ink: #14201c;
  --moss: #163528;
  --sand: #f2e6d0;
  --splash-green: #2bb34a;
  --splash-yellow: #ffe14a;
  --splash-pink: #ff2f9f;
  --mist: rgba(20, 32, 28, 0.55);
  --glow: rgba(255, 225, 74, 0.35);
  --font-ui: "Segoe UI", "Avenir Next", "Century Gothic", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  background: var(--moss);
  font-family: var(--font-ui);
  color: var(--sand);
}

#map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.leaflet-container {
  width: 100%;
  height: 100%;
  background: #163528;
  font: inherit;
}

.leaflet-control-attribution {
  background: rgba(20, 32, 28, 0.55) !important;
  color: rgba(242, 230, 208, 0.75) !important;
  font-size: 10px;
  max-width: 55vw;
}

.leaflet-control-attribution a {
  color: rgba(242, 230, 208, 0.9) !important;
}

.leaflet-control-zoom a {
  background: rgba(26, 47, 40, 0.9) !important;
  color: var(--sand) !important;
  border-color: rgba(242, 230, 208, 0.25) !important;
}

.zuzlik-divicon {
  background: transparent !important;
  border: 0 !important;
}

.zuzlik-marker {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 3px solid var(--sand);
  box-shadow:
    0 8px 22px rgba(0, 0, 0, 0.35),
    0 0 0 6px var(--glow);
  background: center / cover no-repeat #2c4a40;
  /* jen opacity — CSS transform by kolidoval s Leaflet translate3d a posouval body */
  animation: pop-in 0.45s ease both;
}

.zuzlik-marker.has-photo {
  border-color: var(--splash-pink);
}

@keyframes pop-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.leaflet-popup-content-wrapper {
  background: rgba(20, 32, 28, 0.92);
  color: var(--sand);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  padding: 0;
  overflow: hidden;
}

.leaflet-popup-content {
  margin: 0;
  min-width: 180px;
}

.leaflet-popup-tip {
  background: rgba(20, 32, 28, 0.92);
}

.place-card {
  display: grid;
  gap: 0;
}

.place-card img {
  display: block;
  width: 220px;
  max-width: 70vw;
  height: 160px;
  object-fit: cover;
  cursor: pointer;
  transition: transform 0.35s ease;
}

.place-card img:hover {
  transform: scale(1.03);
}

.place-card .thumbs {
  display: flex;
  gap: 4px;
  padding: 6px;
  overflow-x: auto;
}

.place-card .thumbs img {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  flex: 0 0 auto;
}

.place-card .empty {
  width: 180px;
  height: 120px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 30% 30%, rgba(242, 230, 208, 0.18), transparent 55%),
    #243830;
}

.place-card .empty::after {
  content: "";
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: url("/assets/zuzlik.svg") center / cover no-repeat;
  opacity: 0.85;
  animation: floaty 2.8s ease-in-out infinite;
}

@keyframes floaty {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  /* bez backdrop-filter — na některých telefonech kazí systémový screenshot */
  background: rgba(20, 32, 28, 0.88);
  display: grid;
  place-items: center;
  animation: fade-in 0.25s ease both;
}

.lightbox[hidden] {
  display: none;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.lightbox img {
  max-width: min(92vw, 1100px);
  max-height: 88vh;
  border-radius: 12px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  object-fit: contain;
  background: #0d1512;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  border: 0;
  background: rgba(20, 32, 28, 0.75);
  color: var(--sand);
  font-size: 2rem;
  line-height: 1;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
}

.lightbox-close {
  top: 16px;
  right: 16px;
}

.lightbox-nav.prev {
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-nav.next {
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 640px) {
  .lightbox-nav {
    display: none;
  }
}
