/* ==========================================================================
   PRÉSENCE INTERNATIONALE — carte D3 SVG (intégrée page métier)
   Variables locales préfixées (--pi-*) pour éviter tout conflit avec style.css
   ========================================================================== */

.presence-section {
  --pi-blue: #06507f;
  --pi-red: #ed1d3a;
  --pi-bg: #f3eee5;
  --pi-text-primary: #1a2332;
  --pi-text-secondary: #5a6478;
  --pi-land: #ffffff;
  --pi-land-stroke: #d8d2c4;
  --pi-stroke: #c8c2b6;
  --pi-font-title: 'Cocon', 'Quicksand', system-ui, sans-serif;
  --pi-font-body: 'Avenir Next', 'Inter', system-ui, sans-serif;

  max-width: 1500px;
  margin: 0 auto;
  padding: 60px 40px;
  background: var(--pi-bg);
  color: var(--pi-text-primary);
  font-family: var(--pi-font-body);
}

.presence-section .section-header {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 60px;
  margin-bottom: 50px;
}

.presence-section .label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--pi-text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}
.presence-section .label::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--pi-red);
}

.presence-section .intro-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--pi-text-secondary);
  max-width: 360px;
}

.presence-section .headline {
  font-family: var(--pi-font-title);
  font-size: clamp(40px, 5vw, 72px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--pi-text-primary);
}

.presence-section .stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 760px;
}

.presence-section .map-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.presence-section .country {
  fill: var(--pi-land);
  stroke: var(--pi-land-stroke);
  stroke-width: 0.5;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.04));
}

.presence-section .continent-label {
  font-family: var(--pi-font-title);
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  fill: var(--pi-text-primary);
  text-anchor: middle;
  opacity: 0.5;
}

.presence-section .port-logistics { fill: var(--pi-red); }
.presence-section .port-dest      { fill: var(--pi-blue); }

.presence-section .port-pulse {
  transform-origin: center;
  transform-box: fill-box;
  animation: presence-pulse 2.5s ease-out infinite;
  opacity: 0;
  fill: var(--pi-red);
}
@keyframes presence-pulse {
  0%   { transform: scale(1); opacity: 0.4; }
  100% { transform: scale(4); opacity: 0;   }
}

.presence-section .wap-hq-core   { fill: var(--pi-red); }
.presence-section .wap-hq-ring {
  fill: none;
  stroke: var(--pi-red);
  stroke-width: 2;
  transform-origin: center;
  transform-box: fill-box;
  animation: wap-presence-pulse 2.6s ease-out infinite;
  opacity: 0;
}
.presence-section .wap-hq-ring-2 {
  fill: none;
  stroke: var(--pi-red);
  stroke-width: 1.2;
  transform-origin: center;
  transform-box: fill-box;
  animation: wap-presence-pulse 2.6s ease-out infinite;
  animation-delay: 1.3s;
  opacity: 0;
}
.presence-section .wap-hq-label {
  font-family: var(--pi-font-title);
  font-size: 16px;
  font-weight: 600;
  fill: var(--pi-red);
  text-anchor: start;
}
@keyframes wap-presence-pulse {
  0%   { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(6); opacity: 0;   }
}

.presence-section .route {
  fill: none;
  stroke: var(--pi-stroke);
  opacity: 0.3;
  stroke-linecap: round;
}
.presence-section .route-sea  { stroke-width: 0.7; }
.presence-section .route-rail { stroke-width: 1;   stroke-dasharray: 5 2 1 2; opacity: 0.5;  stroke: var(--pi-blue); }
.presence-section .route-road { stroke-width: 0.8; stroke-dasharray: 2 3;     opacity: 0.45; stroke: var(--pi-blue); }
.presence-section .route-air  { stroke-width: 0.7; stroke-dasharray: 2 5;     opacity: 0.25; }

.presence-section .legend {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 30px;
  padding-top: 22px;
  border-top: 1px solid var(--pi-stroke);
}
.presence-section .legend-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--pi-text-primary);
}
.presence-section .legend-marker {
  width: 12px; height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}
.presence-section .legend-marker.logistics { background: var(--pi-red); }
.presence-section .legend-marker.dest      { background: var(--pi-blue); }
.presence-section .legend-marker.wap {
  background: var(--pi-red);
  width: 18px; height: 18px;
  box-shadow: 0 0 0 6px rgba(237, 29, 58, 0.18);
}

.presence-section .kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid var(--pi-stroke);
}
.presence-section .kpi {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.presence-section .kpi-value {
  font-family: var(--pi-font-title);
  font-size: clamp(26px, 3.2vw, 44px);
  font-weight: 500;
  line-height: 1;
  color: var(--pi-blue);
  letter-spacing: -0.02em;
}
.presence-section .kpi-value .unit {
  font-size: clamp(12px, 1.4vw, 20px);
  color: var(--pi-text-secondary);
  margin-left: 4px;
}
.presence-section .kpi-label {
  font-size: clamp(9px, 0.85vw, 11px);
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--pi-text-secondary);
}

@media (max-width: 768px) {
  .presence-section { padding: 30px 20px; }
  .presence-section .section-header { grid-template-columns: 1fr; gap: 20px; }
  .presence-section .kpis   { gap: 14px; }
  .presence-section .legend { gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .presence-section .port-pulse,
  .presence-section .wap-hq-ring,
  .presence-section .wap-hq-ring-2 { animation: none; opacity: 0.4; }
}
