/* ── LA CARTE DE LA DEMANDE, PAGE PRO (16/10/2026, includes/carte-demande.php)
   La carte à gauche, la liste des dernières communes à droite ; l'une sous
   l'autre sur téléphone.

   LES POINTS SONT TRANSLUCIDES : là où la demande se resserre, ils se
   superposent et foncent. C'est la seule « densité » montrée, et elle ne se
   lit pas comme un nombre — voulu (api/lib-carte-demande.php).

   LES PLUS RÉCENTS sont en vert vif, celui du voyant de l'accueil, et
   envoient une onde. Toute animation vit sous `.carte-demande.cd-joue`,
   posée par assets/js/carte-demande.js : sans elle, tout est là, immobile.
   Les délais (`--d`, `--do`) sont écrits par le PHP, le même pour un point
   et pour son nom. */
.carte-demande { --vif: #1F9D6B;
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 24px 56px; align-items: center; }
@media (max-width: 900px) { .carte-demande { grid-template-columns: 1fr; } }

.carte-demande-svg { display: block; width: 100%; max-width: 560px; height: auto; overflow: hidden; }
.carte-demande-svg .cd-trace {
  fill: var(--voile, #E3EBE8); stroke: var(--trait, #DCE3E0);
  stroke-width: 1.5; stroke-linejoin: round; vector-effect: non-scaling-stroke;
}
.carte-demande-svg .cd-point { fill: var(--cadastre, #0E4F45); fill-opacity: .6; }
.carte-demande-svg .cd-recent .cd-point { fill: var(--vif); fill-opacity: 1; }
.carte-demande-svg .cd-onde { fill: none; stroke: var(--vif); stroke-width: 1.5; opacity: 0; }
.carte-demande-svg .cd-point,
.carte-demande-svg .cd-onde { transform-box: fill-box; transform-origin: center; }

/* « Les dernières estimations réalisées », avec son voyant qui respire. */
.cd-direct { display: flex; align-items: center; gap: 10px; margin: 0 0 18px;
  font-size: 15px; font-weight: 500; }
.cd-direct-voyant { position: relative; flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--vif); }
.cd-direct-voyant::after { content: ""; position: absolute; inset: -4px; border-radius: 50%;
  background: var(--vif); opacity: .25; animation: cd-voyant 2.4s ease-out infinite; }

/* La liste : un point vert, le nom, un filet entre deux. */
.cd-fil { list-style: none; margin: 0; padding: 0; }
.cd-fil li { display: flex; align-items: center; gap: 12px; padding: 10px 0;
  border-bottom: 1px solid var(--trait, #DCE3E0); font-size: 16px; color: var(--encre, #121F1C); }
.cd-fil li::before { content: ""; flex: none; width: 7px; height: 7px; border-radius: 50%;
  background: var(--cadastre, #0E4F45); opacity: .6; }
.cd-fil li:nth-child(-n+5)::before { background: var(--vif); opacity: 1; }

/* En attendant d'être à l'écran : ni points ni noms, pour que l'allumage se voie. */
.carte-demande.cd-attente .cd-points,
.carte-demande.cd-attente .cd-fil li { visibility: hidden; }

/* L'allumage : chaque point, puis son nom, au même instant. */
.carte-demande.cd-joue .cd-point { animation: cd-apparait .6s ease-out both; animation-delay: var(--d); }
.carte-demande.cd-joue .cd-fil li { animation: cd-entre .5s ease-out both; animation-delay: var(--d); }
.carte-demande.cd-joue .cd-onde { animation: cd-onde 2.4s ease-out infinite; animation-delay: var(--do); }

@keyframes cd-apparait {
  0%   { transform: scale(0);   opacity: 0; }
  60%  { transform: scale(1.8); opacity: 1; }
  100% { transform: scale(1);   opacity: 1; }
}
@keyframes cd-entre {
  0%   { transform: translateX(-12px); opacity: 0; }
  100% { transform: none;             opacity: 1; }
}
@keyframes cd-onde {
  0%   { transform: scale(1); opacity: .8; }
  100% { transform: scale(4.5); opacity: 0; }
}
@keyframes cd-voyant {
  0%   { transform: scale(.6); opacity: .45; }
  100% { transform: scale(1.4); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .cd-direct-voyant::after { animation: none; }
}
