/* Shared Inner Weather animation contract.
   The same primitives power the public interactive and app micro-animations. */
.weather-svg {
  display: block;
  inline-size: var(--iw-size, 100%);
  max-inline-size: 100%;
  block-size: auto;
  aspect-ratio: 1;
  overflow: visible;
  isolation: isolate;
}
.weather-svg .weather-core {
  transform-box: fill-box;
  transform-origin: center;
  opacity: var(--iw-core-opacity, .84);
  filter: blur(var(--iw-blur, .6px));
}
.weather-svg .ring,
.weather-svg .wave,
.weather-svg .thread,
.weather-svg .orbit,
.weather-svg .ray,
.weather-svg .veil,
.weather-svg .vector {
  transform-box: fill-box;
  transform-origin: center;
}
.weather-svg .spin-slow { animation: iw-spin var(--iw-duration-spin, 18s) linear infinite; }
.weather-svg .spin-reverse { animation: iw-spin var(--iw-duration-spin-fast, 14s) linear infinite reverse; }
.weather-svg .pulse { animation: iw-pulse var(--iw-duration-pulse, 3.4s) ease-in-out infinite; }
.weather-svg .breathe { animation: iw-breathe var(--iw-duration-breathe, 6s) ease-in-out infinite; }
.weather-svg .drift { animation: iw-drift var(--iw-duration-drift, 7s) ease-in-out infinite alternate; }
.weather-svg .fall { animation: iw-fall var(--iw-duration-fall, 4.6s) ease-in-out infinite; }
.weather-svg .flicker { animation: iw-flicker var(--iw-duration-pulse, 3s) ease-in-out infinite alternate; }
.weather-svg .draw {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: iw-line-draw var(--iw-duration-draw, 3.9s) ease-in-out infinite alternate;
}
.weather-svg .witness-ring {
  opacity: var(--iw-witness, 0) !important;
  transition: opacity .7s ease;
}
.weather-svg .form-path {
  opacity: var(--iw-path, 0) !important;
  stroke-dasharray: 1;
  stroke-dashoffset: calc(1 - var(--iw-path, 0));
  transition: opacity .7s ease, stroke-dashoffset .9s ease;
}
.weather-svg[data-state="present"] .weather-core {
  transform: scale(var(--iw-core-present-scale, 1));
}
.weather-svg[data-state="held"] .weather-core {
  transform: scale(var(--iw-core-held-scale, .84));
}
.weather-svg[data-state="held"] .witness-ring {
  opacity: max(.72, var(--iw-witness, 0)) !important;
}
.weather-svg[data-state="formed"] .weather-core {
  transform: scale(var(--iw-core-formed-scale, .74));
}
.weather-svg[data-state="formed"] .form-path {
  opacity: max(.76, var(--iw-path, 0)) !important;
  stroke-dashoffset: 0;
}
.weather-svg[data-mode="micro"] {
  filter: none;
}
.weather-svg[data-mode="micro"] .weather-core {
  filter: none;
}
.weather-svg[data-mode="micro"] .flicker:nth-of-type(n+12),
.weather-svg[data-mode="micro"] .ring:nth-of-type(n+6),
.weather-svg[data-mode="micro"] .ray:nth-of-type(n+15) {
  display: none;
}
.weather-svg[data-distress-safe="true"] *,
.weather-svg[data-reduced-motion="true"] * {
  animation-play-state: paused !important;
}
.weather-svg[data-distress-safe="true"] .weather-core {
  filter: none;
  opacity: .88;
}
.weather-svg[data-distress-safe="true"] .witness-ring {
  opacity: .8 !important;
}

@keyframes iw-spin { to { transform: rotate(360deg); } }
@keyframes iw-pulse {
  0%,100% { opacity:.45; transform:scale(.94); }
  50% { opacity:1; transform:scale(1.035); }
}
@keyframes iw-breathe {
  0%,100% { transform:scale(.97); opacity:.72; }
  50% { transform:scale(1.025); opacity:1; }
}
@keyframes iw-drift { from { transform:translate(-3px, 1px); } to { transform:translate(4px, -2px); } }
@keyframes iw-fall { 0% { transform:translateY(-4px); opacity:0; } 25% { opacity:1; } 100% { transform:translateY(34px); opacity:0; } }
@keyframes iw-flicker { from { opacity:.35; } to { opacity:1; } }
@keyframes iw-line-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

@media (prefers-reduced-motion: reduce) {
  .weather-svg * {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .weather-svg .form-path { stroke-dashoffset: 0; }
}

