【CSS3】Transitions & Transfoms アニメーション
@keyframesなど
by KURO KUMO
HTML
<link rel="stylesheet" href="http://yui.yahooapis.com/3.10.3/build/cssreset/cssreset-min.css">
<div class="footer">
<small>coptyright © 2013 うにゃうにゃうにゃCo.,LTD.</small>
</div>
CSS
@keyframes bgcolor
{
0% {background: #fff}
25% {background: #fff5a5}
50% {background: #ffd4da}
75% {background: #99d2e4}
100% {background: #d8cab4}
}
@-webkit-keyframes bgcolor
{
0% {background: #fff}
25% {background: #fff5a5}
50% {background: #ffd4da}
75% {background: #99d2e4}
100% {background: #d8cab4}
}
@-moz-keyframes bgcolor
{
0% {background: #fff}
25% {background: #fff5a5}
50% {background: #ffd4da}
75% {background: #99d2e4}
100% {background: #d8cab4}
}
html,body {
background-color: #ccc;
}
.footer {
background: #fff;
padding: 20px;
animation: bgcolor 5s infinite alternate;
-webkit-animation: bgcolor 5s infinite alternate;
-moz-animation: bgcolor 5s infinite alternate;
}
.footer small {
font-weight: bold;
font-size: 110%;
}