Coding task · HTML and CSS course · Module 6: CSS Animations
Rotating an Element in CSS
transform: rotate() rotates an element by a given angle (360deg = full rotation). A continuous rotation animation uses 0% { rotate(0deg) } to 100% { rotate(360deg) }. The 'linear' value gives constant speed without easing.
Task
Create @keyframes spin: from rotate(0deg) to rotate(360deg). Apply to .hieroglyph: animation: spin 3s linear infinite. The hieroglyph will spin smoothly like a waterwheel on the Nile!