About
Explore
Events & Classes
Support Us
Join
Sign In
Ashley Piper
View Project Page
Run
Fullscreen
Bouncing Balls | Coding with Rumaysa Tutorial
HTML
CSS
JS
<!-- Created by Ashley Piper, subject to copyright. Coding with Rumaysa tutorial. --> <!DOCTYPE HTML> <html> <head> <title>Page Title</title> <meta charset="utf-8"> <meta name="author" content="Ashley Piper"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> </head> <body> <div class="ball"></div> <div class="ball"></div> <div class="ball"></div> </body> </html>
.ball { background: linear-gradient(to bottom, orange, red, pink, gold); border-radius: 50%; display: inline-block; width: 100px; height: 100px; margin-right: 135px; animation: bounce 1s infinite; } .ball:nth-of-type(1) { margin-left: 10px; } @keyframes bounce { from { margin-top: 0; } to { margin-top: 600px; } }