3D Social Media Button Using HTML and CSS | 3D Button Using HTML and CSS | SOcial Media Button Creating by HTML and CSS
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>compter soft skills</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css">
<style>
*
body {
background-repeat: no-repeat;
background-size: 100% 100%;
background-attachment: fixed;
background-image: url(bi.jpg)
}
{
font-family: "Roboto", sans-serif;
padding: 0;
margin: 0;
box-sizing: border-box;
}
ul {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
display: flex;
margin: 0;
padding: 0;
}
ul li {
list-style: none;
margin: 0 5px;
}
ul li a .fa-brands {
font-size: 40px;
color: black;
line-height: 80px;
transition: 0.5s;
padding-right: 14px;
}
ul li a span {
padding: 0;
margin: 0;
position: absolute;
top: 30px;
letter-spacing: 4px;
transition: 0.5s;
}
ul li a {
text-decoration: none;
display: absolute;
display: block;
width: 210px;
height: 80px;
background: white;
padding-left: 20px;
text-align: left;
transform: rotate(-30deg) skew(25deg) translate(0, 0);
transition: 0.5s;
box-shadow: -20px 20px 10px rgba(248, 8, 228, 0.5);
}
ul li a::before {
content: '';
position: absolute;
top: 10px;
left: -20px;
height: 100%;
width: 20px;
background-color: #ee0000d1;
transform: 0.5s;
transform: rotate(0deg) skewY(-45deg);
}
ul li a::after {
content: '';
position: absolute;
bottom: -20px;
left: -10px;
height: 20px;
width: 100%;
background: #ee0000d1;
transform: 0.5s;
transform: rotate(0deg) skewX(-45deg);
}
ul li a:hover {
transform: rotate(-30deg) skew(25deg) translate(20px, -15px);
box-shadow: -50px 50px 50px rgba(0, 0, 0, 0.5);
}
ul li:hover .fa-brands {
color: #fff;
}
ul li:hover span {
color: #fff;
}
ul li:hover:nth-child(1) a {
background: #3b5998;
}
ul li:hover:nth-child(1) a::before {
background: #0e4bc7;
}
ul li:hover:nth-child(1) a::after {
background: #0e4bc7;
}
ul li:hover:nth-child(2) a {
background: #00bbff;
}
ul li:hover:nth-child(2) a::before {
background: #00bbffb3;
}
ul li:hover:nth-child(2) a::after {
background: #0293c7b3;
}
ul li:hover:nth-child(3) a {
background: #ff1e00;
}
ul li:hover:nth-child(3) a::before {
background: #b33a2b;
}
ul li:hover:nth-child(3) a::after {
background: #e66a5a;
}
ul li:hover:nth-child(4) a {
background: #ff002f;
}
ul li:hover:nth-child(4) a::before {
background: #d81c3f;
}
ul li:hover:nth-child(4) a::after {
background: #e46880;
}
</style>
</head>
<body>
<ul>
<li>
<a href="#">
<i class="fa-brands fa-facebook-f" aria-hidden="true"></i>
<span>- Facebook</span>
</a>
</li>
<li>
<a href="#">
<i class="fa-brands fa-twitter" aria-hidden="true"></i>
<span>- Twitter</span>
</a>
</li>
<li>
<a href="#">
<i class="fa-brands fa-google-plus-g" aria-hidden="true"></i>
<span>- Google</span>
</a>
</li>
<li>
<a href="#">
<i class="fa-brands fa-instagram" aria-hidden="true"></i>
<span>- Instgram</span>
</a>
</li>
</ul>
</body>
</html>

0 Comments