JSFiddle - React, Tailwind, and code Playground
HTML
<style>
<div> {
width: 100%;
height: 400px;
background-color: orange;
margin: 0 auto 40px auto;
border: 4px solid green;
/*border-radius: 8px; */
box-shadow: 3px 3px 2px gray;
box-sizing: border-box;
padding-top: 20px;
animation-delay: 2s;
}
h1 {
border: 2 px solid green;
border-radius: 6px;
box-shadow: 4px 4px 3px gray;
font-size: 2.5em;
text-align: center;
color: blue;
background: lightblue;
}
.d1, .d2,.d3 {
border-radius: 8px;
animation-name: couleur;
animation-duration: 6s;
animation-iteration-count: infinite;
font-family: serif;
font-size: 5em;
text-align: center;
color: orange;
margin-bottom: 6px;
}
@keyframes couleur {
from{background-color: orange;}
50% {background-color: green;}
to {background-color: orange;}
}
footer {
font-size: 1.5em;
color: blue;
}
</style>
<h1>Animation couleur HTML et CSS</h1>
<div class="d1">WAAOOUUH !</div>
<div class="d2">THE FRENCH RAFALE</div>
<div class="d3">IS FANTASTIC PLANE !!</div>
<footer>Harmo</footer>