<p class="block block-1"><code>animation-iteration-count: 2;</code></p>
<p class="block block-2"><code>animation-iteration-count: 15;</code></p>
body {
line-height: 1.45;
font-family: Ubuntu, sans-serif;
font-size: 17px;
color: #252525;
}
.block {
padding: 16px;
animation-name: jump;
animation-duration: 1.75s;
animation-timing-function: linear;
animation-delay: 2.5s;
animation-direction: alternate;
animation-fill-mode: both;
}
.block..block-1 {
animation-iteration-count: 2;
}
.block.block-2 {
animation-iteration-count: 15;
}
@keyframes jump {
from {
margin-top: 0;
background-color: #666;
color: #f1f1f1;
}
to {
margin-top: 15%;
background-color: #808080;
color: #252525;
}
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.