/* Water plants on the footer wave (every page), placed as in Figma "Footer ·
   Animation Wasserpflanzen" (1440 wide): feet on the wave line, which the
   wave, drawn after them, covers. Heights in parts of the wave height. */
.ef-footer__plant {
  /* Feet a little below the wave line, so every plant touches the ground. */
  --ef-plant-sink: 0.75rem;
  position: absolute;
  bottom: calc(100% + var(--ef-wave-h) * 0.45 - var(--ef-plant-sink));
  height: auto;
  max-width: none;
  /* Swaying leaves reach past the drawing's box. */
  overflow: visible;
  pointer-events: none;
}

.ef-footer__plant--left { left: 0.5rem; width: 5.5rem; }
.ef-footer__plant--left-small { display: none; }
.ef-footer__plant--right { right: 4.5rem; width: 3rem; }
.ef-footer__plant--right-far { right: 0.5rem; width: 4rem; }

/* Each leaf sways around its foot like in a light current (Figma "Footer ·
   Animation Wasserpflanzen", Nina): 6 s loop, 2.2° for big leaves, 3° middle,
   4° small, phases staggered from left to right. Still with reduced motion. */
.ef-footer__plant [id^="blatt-"] {
  transform-box: fill-box;
  transform-origin: 50% 100%;
  animation: 6s ease-in-out infinite;
}

@keyframes ef-leaf-2-2 { 0%, 100% { transform: rotate(2.2deg); } 50% { transform: rotate(-2.2deg); } }
@keyframes ef-leaf-3 { 0%, 100% { transform: rotate(3deg); } 50% { transform: rotate(-3deg); } }
@keyframes ef-leaf-4 { 0%, 100% { transform: rotate(4deg); } 50% { transform: rotate(-4deg); } }

#blatt-01 { animation-name: ef-leaf-3; animation-delay: -2.221s; }
#blatt-02 { animation-name: ef-leaf-2-2; animation-delay: -2.135s; }
#blatt-03 { animation-name: ef-leaf-2-2; animation-delay: -2.369s; }
#blatt-04 { animation-name: ef-leaf-2-2; animation-delay: -2.228s; }
#blatt-05 { animation-name: ef-leaf-3; animation-delay: -2.071s; }
#blatt-06 { animation-name: ef-leaf-4; animation-delay: -1.875s; }
#blatt-07 { animation-name: ef-leaf-4; animation-delay: -2.17s; }
#blatt-08 { animation-name: ef-leaf-4; animation-delay: -1.561s; }
#blatt-09 { animation-name: ef-leaf-4; animation-delay: -1.751s; }
#blatt-10 { animation-name: ef-leaf-4; animation-delay: -1.874s; }
#blatt-11 { animation-name: ef-leaf-4; animation-delay: -0.86s; }
#blatt-12 { animation-name: ef-leaf-3; animation-delay: -0.576s; }
#blatt-13 { animation-name: ef-leaf-4; animation-delay: -0.308s; }
#blatt-14 { animation-name: ef-leaf-4; animation-delay: -0.602s; }
#blatt-15 { animation-name: ef-leaf-3; animation-delay: -0.368s; }

@media (prefers-reduced-motion: reduce) {
  .ef-footer__plant [id^="blatt-"] { animation: none; }
}

@media (width >= 64rem) {
  .ef-footer__plant--left { left: 1.8%; bottom: calc(100% + var(--ef-wave-h) * 0.75 - var(--ef-plant-sink)); width: 14.7rem; }
  .ef-footer__plant--left-small { display: block; left: 18.2%; bottom: calc(100% + var(--ef-wave-h) * 0.855 - var(--ef-plant-sink)); width: 5.55rem; }
  .ef-footer__plant--right { left: 70.6%; right: auto; bottom: calc(100% + var(--ef-wave-h) * 0.367 - var(--ef-plant-sink)); width: 5.8rem; }
  .ef-footer__plant--right-far { left: 87.6%; right: auto; bottom: calc(100% + var(--ef-wave-h) * 0.467 - var(--ef-plant-sink)); width: 8.55rem; }
}
