adc

clicks

how to create social media buttons hover effect html and css

 

 HTML 

Before we start writing code first, we need to create a primary structure of the HTML document, so that the browser can understand and start working. The basic HTML structure looks like the following.

After writing the primary structure of the HTML document, you will also write the tags and content you need. After that, you can see the output in your browser. We know that HTML Sudu Mae is used for exposing content in a basic format. To complete our content we need to use CSS, which is an HTML insert and it creates an engaging user interface.


<!DOCTYPE html>

<html>

<head>

               <title>Social Media Buttons</title>

               <link rel="stylesheet" type="text/css" href="style.css">

               <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">

</head>

<body>

               <div class="icon">

                              <a href="#"><i class="fa fa-facebook-f"></i></a>

                              <a href="#"><i class="fa fa-instagram"></i></a>

                              <a href="#"><i class="fa fa-twitter"></i></a>

                              <a href="#"><i class="fa fa-youtube"></i></a>

               </div>

</body>

</html>

 CSS 

Now, we have time to improve the HTML content, for that, we need to add CSS to the HTML file. CSS can be added to HTML documents in a total of three ways, here we are using outside CSS design using CSS will arrive here after typing and see the output in your browser. 


*{
               margin: 0;
               padding: 0;
}
body{
               background-image: url(bg.jpg);
               background-size: cover;
               background-repeat: no-repeat;
}
.icon{
               position: absolute;
               top: 40%;
               left: 30%
}
a{
               display: inline-block;
               width: 90px;
               height: 90px;
               background-color: #eee;
               border-radius: 25px;
               margin: 20px;
               box-shadow: 3px 3px 10px #aeaeae,
                                                            -4px -4px 10px white;
               text-align: center;
               line-height: 90px;
               font-size: 50px;
               border:3px solid #eee;
               color: #333;
               transition: 0.3s;
}
a:hover{
               animation: animed .6s alternate infinite linear;
               background-color: #333;
               color: #eee;
 
}
@keyframes animed{
               0%{
                              border: 3px solid lightgreen;
               }
               50%{
                              border: 3px solid salmon;
               }
               100%{
                              border: 3px solid skyblue;
               }
}

 

 





how to create social media buttons hover effect html and css how to create social media buttons  hover effect  html and css Reviewed by easycoding on August 28, 2020 Rating: 5

No comments:

Powered by Blogger.