/* Section carte de l'annuaire, chargee apres annuaire.css. */
.an-tnmap-wrap {
  background: var(--an-surface);
  border: 1px solid var(--an-border);
  border-radius: var(--an-radius-lg);
  box-shadow: var(--an-shadow);
  padding: 1rem;
  overflow: hidden;
}
/* La colonne carte s'étire à la hauteur de la grille voisine (hybride C1). */
.an-tnmap-wrap { display: flex; flex-direction: column; }
#an-tnmap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  flex: 1 1 auto;
}
.an-tnmap-svg {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 640px;
}
.an-tnmap-caption {
  min-height: 1.5rem;
  margin-block-start: .65rem;
  text-align: center;
  color: var(--an-navy);
  font-weight: 700;
}

/* Regions du gouvernorat dans le SVG injecte — contrastes affirmes (la carte doit se LIRE). */
.an-region {
  fill: var(--an-map-region);
  stroke: #fff;
  stroke-width: .8;
  transition: fill .15s ease;
  cursor: pointer;
}
.an-region.has { fill: var(--an-map-region-has); }
/* Survol/focus = bleu : la carte désigne un LIEU, pas une action. */
.an-region:hover,
.an-region.hover {
  fill: var(--an-blue);
}
.an-region:focus {
  outline: none;
  fill: var(--an-blue);
  stroke: var(--an-navy);
  stroke-width: 1.6;
}

/* Liste des 24 gouvernorats, visible sans defilement interne. */
.an-govlist {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .5rem;
}
.an-govlist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  padding-block: .6rem;
  padding-inline: .8rem;
  min-height: 44px;
  background: var(--an-surface);
  border: 1px solid var(--an-border);
  border-radius: var(--an-radius);
  color: var(--an-ink);
  text-decoration: none;
  transition: border-color .15s ease, background .15s ease;
}
.an-govlist-item:hover,
.an-govlist-item:focus {
  background: var(--an-blue-tint);
  border-color: var(--an-blue);
  color: var(--an-ink);
  text-decoration: none;
}
.an-govlist-item .name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 575.98px) {
  .an-govlist { grid-template-columns: 1fr; }
}
/* Respect du mouvement reduit. */
@media (prefers-reduced-motion: reduce) {
  .an-region,
  .an-govlist-item {
    transition: none;
  }
}
