/*
 * MADANET - animation de l'illustration principale
 * A charger APRES style.css ; aucun JavaScript ni bibliotheque necessaire.
 * Les elements decoratifs sont aria-hidden et ne bloquent pas les clics.
 */
.hero-art--motion {
  position: relative;
  isolation: isolate;
}

.hero-art--motion .hero-server-animated {
  position: relative;
  z-index: 2;
  display: block;
  max-width: 100%;
  height: auto;
  transform-origin: 50% 53%;
  animation: mh-floating 5.8s ease-in-out infinite;
  will-change: transform;
}

/* Un halo doux sous l'illustration apporte du relief. */
.hero-art--motion .mh-halo {
  position: absolute;
  z-index: 0;
  inset: 17% 12% 19%;
  border-radius: 50%;
  background: radial-gradient(ellipse at center,
    rgba(30, 144, 255, .22),
    rgba(0, 186, 255, .09) 40%,
    transparent 70%);
  filter: blur(21px);
  animation: mh-breathe 7s ease-in-out infinite;
  pointer-events: none;
}

/* Anneaux technologiques translucides en mouvement lent. */
.hero-art--motion .mh-orbit {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 47%;
  width: 76%;
  aspect-ratio: 1;
  border: 1px solid rgba(32, 153, 239, .21);
  border-radius: 50%;
  transform: translate(-50%, -50%) rotate(0deg);
  pointer-events: none;
  animation: mh-rotate 19s linear infinite;
}
.hero-art--motion .mh-orbit::after {
  content: '';
  position: absolute;
  top: 13%;
  left: 13%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #17baf5;
  box-shadow: 0 0 0 5px rgba(23, 186, 245, .1), 0 0 16px rgba(23, 186, 245, .75);
}
.hero-art--motion .mh-orbit--two {
  width: 91%;
  border-color: rgba(29, 171, 201, .15);
  animation-duration: 28s;
  animation-direction: reverse;
}
.hero-art--motion .mh-orbit--two::after {
  top: 83%;
  left: 14%;
  width: 5px;
  height: 5px;
  background: #24d2ae;
  box-shadow: 0 0 14px rgba(36, 210, 174, .65);
}

/* Points lumineux representant l'activite du reseau. */
.hero-art--motion .mh-beacon {
  position: absolute;
  z-index: 4;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #26dcb4;
  box-shadow: 0 0 12px rgba(38, 220, 180, .8);
  pointer-events: none;
  animation: mh-led 2.5s ease-in-out infinite;
}
.hero-art--motion .mh-beacon::after {
  content: '';
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(38, 220, 180, .6);
  border-radius: 50%;
  animation: mh-ripple 2.5s ease-out infinite;
}
.hero-art--motion .mh-beacon--one { top: 37%; left: 30%; }
.hero-art--motion .mh-beacon--two { top: 58%; right: 24%; animation-delay: 1.2s; }
.hero-art--motion .mh-beacon--two::after { animation-delay: 1.2s; }

/* Particules : trois petits flux diagonaux, sans canvas ni JS. */
.hero-art--motion .mh-packet {
  position: absolute;
  z-index: 4;
  top: 64%;
  left: 13%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #22b8ff;
  box-shadow: 0 0 8px 3px rgba(34, 184, 255, .25);
  opacity: 0;
  pointer-events: none;
  animation: mh-traffic 5.7s linear infinite;
}
.hero-art--motion .mh-packet--two {
  top: 72%; left: 25%;
  animation-delay: 1.8s;
  background: #3cdbb7;
}
.hero-art--motion .mh-packet--three {
  top: 56%; left: 11%;
  animation-delay: 3.7s;
}

/* Petites cartes en verre depoli, volontairement non interactives. */
.hero-art--motion .mh-status {
  position: absolute;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(91, 163, 213, .27);
  border-radius: 999px;
  padding: 9px 13px;
  background: rgba(255, 255, 255, .91);
  box-shadow: 0 8px 26px rgba(12, 49, 92, .10);
  color: #16365e;
  font: 700 12px/1.2 'DM Sans', Arial, sans-serif;
  white-space: nowrap;
  pointer-events: none;
  animation: mh-chip-floating 6.5s ease-in-out infinite;
}
@supports (backdrop-filter: blur(8px)) {
  .hero-art--motion .mh-status {
    background: rgba(255, 255, 255, .84);
    backdrop-filter: blur(8px);
  }
}
.hero-art--motion .mh-status--cloud { top: 16%; right: 1%; }
.hero-art--motion .mh-status--security {
  bottom: 21%; left: 1%;
  animation-delay: -3s;
}
.hero-art--motion .mh-status__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #12bd99;
  box-shadow: 0 0 0 4px rgba(18, 189, 153, .12);
}
.hero-art--motion .mh-status__shield {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: #e4f8f2;
  color: #0d997f;
  font-weight: 800;
}
.hero-art--motion .art-caption {
  position: relative;
  z-index: 6;
}

@keyframes mh-floating {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(0, -13px, 0); }
}
@keyframes mh-breathe {
  0%, 100% { opacity: .54; transform: scale(.95); }
  50% { opacity: 1; transform: scale(1.06); }
}
@keyframes mh-rotate {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to { transform: translate(-50%, -50%) rotate(360deg); }
}
@keyframes mh-led {
  0%, 100% { opacity: .45; }
  50% { opacity: 1; }
}
@keyframes mh-ripple {
  0% { opacity: .7; transform: scale(.55); }
  80%, 100% { opacity: 0; transform: scale(1.9); }
}
@keyframes mh-traffic {
  0% { opacity: 0; transform: translate3d(0, 0, 0) scale(.6); }
  12% { opacity: .9; }
  78% { opacity: .9; }
  100% { opacity: 0; transform: translate3d(170px, -112px, 0) scale(1.3); }
}
@keyframes mh-chip-floating {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* Sur smartphone, on reduit les effets pour ne pas masquer l'illustration. */
@media (max-width: 640px) {
  .hero-art--motion .mh-status { display: none; }
  .hero-art--motion .mh-orbit--two { display: none; }
  .hero-art--motion .mh-beacon--one { left: 23%; }
  .hero-art--motion .mh-packet { animation-name: mh-traffic-mobile; }
  .hero-art--motion .hero-server-animated { animation-duration: 7s; }
}
@keyframes mh-traffic-mobile {
  0% { opacity: 0; transform: translate3d(0,0,0); }
  15%, 75% { opacity: .85; }
  100% { opacity: 0; transform: translate3d(80px,-53px,0); }
}

/* Respect des preferences systeme : pas de mouvement impose. */
@media (prefers-reduced-motion: reduce) {
  .hero-art--motion .hero-server-animated,
  .hero-art--motion .mh-halo,
  .hero-art--motion .mh-orbit,
  .hero-art--motion .mh-beacon,
  .hero-art--motion .mh-beacon::after,
  .hero-art--motion .mh-packet,
  .hero-art--motion .mh-status {
    animation: none !important;
    will-change: auto;
  }
  .hero-art--motion .mh-packet { display: none; }
}
