HTML
<div class="container">
<div class="anio"></div>
<div class="sombra"></div>
</div>CSS
body{
background:#fef9e7;
margin:0;
padding:0;
}
.container{
width:100%;
height:100vh;
display:flex;
justify-content:center;
align-items:center;
flex-direction:column;
}
.anio{
width:500px;
height:300px;
background-image:url("2021.png");
background-size:cover;
animation:animar 1s infinite alternate;
}
.sombra{
width:300px;
height:100px;
background:rgba(0,0,0,0.3);
border-radius:50%;
transform:rotateX(-70deg);
animation:sombra 1s infinite alternate;
}
@keyframes animar{
to{
transform:translateY(-50px);
}
}
@keyframes sombra{
to{
transform:scale(0.6) rotateX(-70deg);
opacity:0.1;
}
}
Deja tu comentario