Write a two-keyframe transform animation with chosen duration, timing curve, and repetition value.
The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.
Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.
The @keyframes block supplies from and to transform declarations, and an animation shorthand applies its name, seconds, easing, and iterations to .animated. Browsers interpolate compatible transform values between those endpoints.
Name: float From transform: translateY(0) To transform: translateY(-12px) Duration seconds: 1.5 Easing: ease-in-out Iterations: infinite
@keyframes float {
from { transform: translateY(0); }
to { transform: translateY(-12px); }
}
.animated {
animation: float 1.5s ease-in-out infinite;
}
Loading marks loop transforms, decorative elements float between translations, and prototypes compare easing curves over equal durations.