Keyframe animations for cards, icons, loaders and headings - drop a class on an element and it comes alive.
1Floating Animation
Lets any card, icon or image drift gently up and down as if it were weightless. Class: fx-floating-animation
Modern equipment
Hover to pause
<div class="d-flex flex-wrap align-items-center justify-content-center gap-3 p-3 h-100" style="min-height:200px">
<div class="card border-0 shadow text-center fx-floating-animation" style="width:12rem">
<div class="card-body">
<div class="fs-1 text-primary mb-2">
<i class="bi bi-rocket-takeoff" aria-hidden="true"></i>
</div>
<h3 class="h6 mb-1">Modern equipment</h3>
<p class="small text-body-secondary mb-0">Hover to pause</p>
</div>
</div>
</div>
/* CSS (already in assets/css/effects.css) */
.fx-floating-animation { animation: fx-floating-animation-float 3.6s ease-in-out infinite; will-change: transform; }
.fx-floating-animation:hover { animation-play-state: paused; }
@keyframes fx-floating-animation-float {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-12px); }
}
@media (prefers-reduced-motion: reduce) {
.fx-floating-animation, .fx-floating-animation::before, .fx-floating-animation::after, .fx-floating-animation *, .fx-floating-animation *::before, .fx-floating-animation *::after { animation: none !important; transition: none !important; }
}2Orbital Motion
Two small planets circle around an avatar, logo or icon on separate orbits. Class: fx-orbital-motion
<div class="d-flex flex-wrap align-items-center justify-content-center gap-3 p-3 h-100" style="min-height:200px">
<div class="fx-orbital-motion">
<img src="../assets/img/avatar-5.svg" alt="Team member avatar" class="rounded-circle shadow" style="width:4.5rem;height:4.5rem">
</div>
</div>
/* CSS (already in assets/css/effects.css) */
.fx-orbital-motion {
position: relative; display: inline-grid; place-items: center; width: 9rem; height: 9rem;
border-radius: 50%; border: 1px dashed rgba(var(--wt-primary-rgb), .45);
}
.fx-orbital-motion::before, .fx-orbital-motion::after {
content: ""; position: absolute; top: 50%; left: 50%; border-radius: 50%; pointer-events: none;
}
.fx-orbital-motion::before {
width: 14px; height: 14px; margin: -7px; background: var(--wt-primary);
box-shadow: 0 0 10px rgba(var(--wt-primary-rgb), .7);
animation: fx-orbital-motion-outer 5s linear infinite;
}
.fx-orbital-motion::after {
width: 10px; height: 10px; margin: -5px; background: var(--wt-accent);
animation: fx-orbital-motion-inner 3.2s linear infinite reverse;
}
@keyframes fx-orbital-motion-outer { from { transform: rotate(0deg) translateX(4.5rem) rotate(0deg); } to { transform: rotate(360deg) translateX(4.5rem) rotate(-360deg); } }
@keyframes fx-orbital-motion-inner { from { transform: rotate(0deg) translateX(3.1rem); } to { transform: rotate(360deg) translateX(3.1rem); } }
@media (prefers-reduced-motion: reduce) {
.fx-orbital-motion, .fx-orbital-motion::before, .fx-orbital-motion::after, .fx-orbital-motion *, .fx-orbital-motion *::before, .fx-orbital-motion *::after { animation: none !important; transition: none !important; }
}