/* ── Carte ── */
#map {
  flex: 1;
  z-index: 1;
}

/* ── Popup Leaflet ── */
.leaflet-popup-content-wrapper {
  background: #1e2233;
  border: 1px solid #2a2f3e;
  border-radius: 10px;
  color: #e8e6e0;
  box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}
.leaflet-popup-tip { background: #1e2233; }
.popup-nom { font-size: 15px; font-weight: 700; margin-bottom: 8px; color: #fff; }
.popup-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  margin: 2px 2px 6px 0;
}
.popup-desc {
  font-size: 12px;
  color: #9ca3af;
  margin-top: 6px;
  line-height: 1.5;
}

/* Le conteneur qui contient le texte déplié */
.desc-full {
  max-height: 180px;
  overflow-y: auto;
  overflow-x: hidden;
  margin-top: 4px;
  padding-right: 6px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}
.desc-full::-webkit-scrollbar {
  width: 10px;
}
.desc-full::-webkit-scrollbar-track {
  background: #171b26;
  border-radius: 10px;
}
.desc-full::-webkit-scrollbar-thumb {
  background: #4fc3a1;
  border-radius: 10px;
}

.desc-toggle {
  background: none;
  border: none;
  color: #4fc3a1;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
}
.desc-toggle:hover { text-decoration: underline; }

/* ── Message vide ── */
#empty-msg {
  display: none;
  position: absolute;
  top: 50%;
  left: calc(var(--icon-rail-width) + 270px + 50%);
  transform: translate(-50%, -50%);
  z-index: 500;
  text-align: center;
  color: #6b7280;
  pointer-events: none;
}
#empty-msg svg { margin-bottom: 8px; opacity: 0.4; }
#empty-msg p { font-size: 14px; }

/* ── Loading ── */
#loading {
  position: absolute;
  inset: 0;
  background: #0f1117;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  flex-direction: column;
  gap: 12px;
}
.spinner {
  width: 36px; height: 36px;
  border: 3px solid #2a2f3e;
  border-top-color: #4fc3a1;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }
#loading p { font-size: 13px; color: #6b7280; }