/* Custom styles par-dessus Tailwind */

/* Marker de carte personnalisé */
.city-marker {
  background: transparent !important;
  border: none !important;
}
.marker-pin {
  width: 32px;
  height: 32px;
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 14px;
  border: 3px solid white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  transition: transform 0.15s ease;
}
.marker-pin > * {
  transform: rotate(45deg);
}
.marker-pin:hover {
  transform: rotate(-45deg) scale(1.12);
}

/* Leaflet popup — léger override */
.leaflet-popup-content-wrapper {
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}
.leaflet-popup-content {
  margin: 12px 14px;
  font-family: 'Inter', system-ui, sans-serif;
}

/* Mode sombre sur la carte — tile moins agressif */
.dark .leaflet-tile {
  filter: brightness(0.7) invert(1) contrast(1) hue-rotate(200deg) saturate(0.5);
}
.dark .leaflet-popup-content-wrapper,
.dark .leaflet-popup-tip {
  background: #1e293b;
  color: #e2e8f0;
}

/* Line-clamp utility (au cas où Tailwind JIT ne sort pas) */
.line-clamp-1 {
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

/* Smooth scroll global */
html {
  scroll-behavior: smooth;
}

/* Scrollbar discrète */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
.dark ::-webkit-scrollbar-thumb { background: #334155; }

/* Print : version papier de secours */
@media print {
  header, nav, footer, #map, #darkToggle, #checklistReset { display: none !important; }
  main { max-width: 100% !important; padding: 0 !important; }
  body { background: white !important; color: black !important; }
  .shadow-lg, .shadow-xl, .shadow-sm { box-shadow: none !important; }
  section { page-break-inside: avoid; margin-bottom: 1rem !important; }
  .grid { display: block !important; }
  .grid > * { margin-bottom: 0.5rem; }
}

/* Focus visible améliorations accessibilité */
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 2px solid #6366f1;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Animation d'apparition subtile */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
#timelineGrid > *, #checklistGroups > * {
  animation: fadeInUp 0.4s ease-out backwards;
}
#timelineGrid > *:nth-child(1) { animation-delay: 0.00s; }
#timelineGrid > *:nth-child(2) { animation-delay: 0.03s; }
#timelineGrid > *:nth-child(3) { animation-delay: 0.06s; }
#timelineGrid > *:nth-child(4) { animation-delay: 0.09s; }
#timelineGrid > *:nth-child(5) { animation-delay: 0.12s; }
#timelineGrid > *:nth-child(6) { animation-delay: 0.15s; }
#timelineGrid > *:nth-child(7) { animation-delay: 0.18s; }
#timelineGrid > *:nth-child(8) { animation-delay: 0.21s; }
#timelineGrid > *:nth-child(n+9) { animation-delay: 0.24s; }
