<!DOCTYPE html>
<html>
<head>
<title>Fade In and Out Animation Demo</title>
<style>
/* Custom CSS for the animation */
.container {
text-align: center;
padding: 50px;
}
.fade-in-out {
animation: fadeInOut 4s;
opacity: 0;
}
@keyframes fadeInOut {
0% {
opacity: 0;
}
25% {
opacity: 1;
}
75% {
opacity: 1;
}
100% {
opacity: 0;
}
}
</style>
</head>
<body>
<div class="container">
<h1>Fade In and Out Animation Demo</h1>
<p>Animate an element with a fading in and out effect:</p>
<!-- Element with Fading In and Out Animation -->
<div class="fade-in-out">
<p>This element fades in and out.</p>
</div>
</div>
</body>
</html>