/*
 * Geolist Core — geolist.css
 *
 * CSS custom properties consumed here (defined globally by the Orthopus theme):
 *   --col_1  couleur claire  (fond card + texte bouton au hover)
 *   --col_2  bleu nuit  #212233  (fond carte, bordures cards, texte bouton)
 *   --col_3  violet  #B399FF  (pays distributeur, focus ring)
 *   --col_5  vert d'eau pâle  #E1FFF9  (pays neutre)
 */

/* ── Map container ── */
.geolist-map {
  background: var(--col_2, #212233);
  border-radius: 40px;
  overflow: hidden;
  width: 100%;
  display: block;
}

.geolist-map svg {
  width: 100%;
  height: auto;
  display: block;
}

/* ── Country paths ── */
.geolist-map .land {
  fill: var(--col_5, #e1fff9);
  transition: fill 200ms ease;
}

.geolist-map .land.has-distributor {
  fill: var(--col_3, #b399ff);
  cursor: pointer;
}

.geolist-map .land.has-distributor:hover,
.geolist-map .land.is-highlighted {
  fill: color-mix(in srgb, var(--col_3, #b399ff) 80%, black);
}

.geolist-map .land.has-distributor:focus-visible {
  outline: 3px solid var(--col_3, #b399ff);
  outline-offset: 1px;
}

/* ── Attribution ── */
.geolist-attribution {
  font-size: 0.75rem;
  opacity: 0.6;
  text-align: right;
  margin-top: 0.5rem;
}

.geolist-attribution a {
  color: inherit;
  text-underline-offset: 2px;
}

/* ── Cards grid — 5 columns ≥ 1280px ── */
.geolist-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.5rem;
}

.geolist-cards > li {
  display: contents;
}

/* ── Single card ── */
.geolist-card {
  border: 2px solid var(--col_2, #212233);
  border-radius: 40px;
  padding: 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  background: var(--col_1, #fff);
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.geolist-card.is-highlighted,
.geolist-card.is-active {
  transform: translateY(-4px);
  box-shadow: 8px 8px 0 var(--col_3);
}

/* ── Card elements ── */
.geolist-card__logo img {
  max-width: 160px;
  height: auto;
}

.geolist-card__country {
  font-weight: 700;
  margin: 0;
}

.geolist-card__url {
  color: var(--col_2, #212233);
  text-decoration: underline;
  text-underline-offset: 3px;
  word-break: break-all;
}

.geolist-card__activity {
  margin: 0;
}

.geolist-card__noscript {
  font-size: 0.875rem;
  opacity: 0.8;
  margin: 0;
}

.geolist-empty {
  text-align: center;
  color: #999;
  padding: 2rem 0;
}

/* ── Contact button (pill) ── */
.geolist-card__btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  border-radius: 3em;
  border: 2px solid var(--col_2, #212233);
  background: var(--col_1, #fff);
  color: var(--col_2, #212233);
  font-weight: 700;
  cursor: pointer;
  transition: background 200ms ease, color 200ms ease;
  font-family: inherit;
  font-size: inherit;
  margin-top: auto;
}

.geolist-card__btn:hover,
.geolist-card__btn:focus-visible {
  background: var(--col_2, #212233);
  color: var(--col_1, #fff);
}

.geolist-card__btn:focus-visible {
  outline: 3px solid var(--col_3, #b399ff);
  outline-offset: 2px;
}

/* ── Link focus ── */
.geolist-card a:focus-visible {
  outline: 3px solid var(--col_3, #b399ff);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Responsive: 4 columns 1024–1279px ── */
@media (max-width: 1279px) {
  .geolist-cards {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ── Responsive: 3 columns 768–1023px ── */
@media (max-width: 1023px) {
  .geolist-cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ── Responsive: 2 columns 480–767px ── */
@media (max-width: 767px) {
  .geolist-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ── Responsive: 1 column < 480px ── */
@media (max-width: 479px) {
  .geolist-cards {
    grid-template-columns: 1fr;
  }
}

/* ── Accessibility: reduce motion ── */
@media (prefers-reduced-motion: reduce) {
  .geolist-map .land,
  .geolist-card,
  .geolist-card__btn {
    transition: none;
  }
}
