WEBLEB
Início
Editor
Entrar
Pro
Português
English
Français
Español
Português
Deutsch
Italiano
हिंदी
Codificando a realidade
60
ByBy.inc
Abrir no Editor
Publique Seu Código
Recomendado
16 November 2024
Barra lateral
19 October 2024
Código da barra de navegação HTML CSS
7 November 2024
Animação CSS
HTML
Copy
CSS
Copy
.container { width: 100%; height: 100vh; overflow: hidden; background: linear-gradient(to bottom, #ff9999, #ffcc99); /* Background gradient */ } .world { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 200px; height: 200px; border-radius: 50%; background: #fff; animation: spin 3s linear infinite; } @keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } } .planet { position: absolute; width: 50px; height: 50px; background: #ccc; border-radius: 50%; animation: orbit 5s ease-in-out infinite; } .planet:nth-child(1) { animation-delay: 0s; top: 20px; left: 50%; transform: translateX(-50%); } .planet:nth-child(2) { top: 70px; left: 20px; } .planet:nth-child(3) { top: 20px; left: 80px; } @keyframes orbit { 0% { transform: translate(0, 0); } 100% { transform: translate(50px, 0);} }
JS
Copy
/* Replace with your JS Code (Leave empty if not needed) */