Friday, 27 September 2019

Rain Effect in CSS


Rain Effect in CSS

Take a look at how to make a raindrops on Background, using HTML and CSS.


 
Rain effect
Source Code:

<!Doctype html>
<html>
<head>
<title> Rain Effect</title>
<style>
*{
margin:0px;
padding:0px;
}
.maindiv{
width:100%;
height:100vh;
background-image:url("bg.jpg");
background-repeat:no-repeat;
background-size:100% 100%;
}
.main{
height:100vh;
background-image:url("rain.png");
animation:main .4s linear infinite;

@keyframes main{
from{
background-position:0% 0%;
}
to{
background-position: 40% 100%;
}
</style>
</head>
<body>
<div class="maindiv">
<div class="main">
</div> 
</div>

</body>

No comments:

Post a Comment

SEO introduction

What is SEO? SEO(Search Engine Optimization ) is a technique that helps to bring the Website on top. Seo depends on the Keyword . Ke...