<!-- Style 1: square icon tiles --> <div class="social-row"> <a href="#" class="social-1 fb" aria-label="Facebook"><i class="fab fa-facebook-f" aria-hidden="true"></i></a> <a href="#" class="social-1 x" aria-label="X (Twitter)"><i class="fab fa-x-twitter" aria-hidden="true"></i></a> <a href="#" class="social-1 in" aria-label="LinkedIn"><i class="fab fa-linkedin-in" aria-hidden="true"></i></a> <a href="#" class="social-1 pi" aria-label="Pinterest"><i class="fab fa-pinterest-p" aria-hidden="true"></i></a> <a href="#" class="social-1 rd" aria-label="Reddit"><i class="fab fa-reddit-alien" aria-hidden="true"></i></a> <a href="#" class="social-1 wa" aria-label="WhatsApp"><i class="fab fa-whatsapp" aria-hidden="true"></i></a> </div> <!-- Style 2: icon block with a label --> <div class="social-row"> <a href="#" class="social-2 fb"><i class="fab fa-facebook-f" aria-hidden="true"></i><span>Facebook</span></a> <a href="#" class="social-2 x"><i class="fab fa-x-twitter" aria-hidden="true"></i><span>X (Twitter)</span></a> <a href="#" class="social-2 in"><i class="fab fa-linkedin-in" aria-hidden="true"></i><span>LinkedIn</span></a> <a href="#" class="social-2 pi"><i class="fab fa-pinterest-p" aria-hidden="true"></i><span>Pinterest</span></a> <a href="#" class="social-2 rd"><i class="fab fa-reddit-alien" aria-hidden="true"></i><span>Reddit</span></a> <a href="#" class="social-2 wa"><i class="fab fa-whatsapp" aria-hidden="true"></i><span>WhatsApp</span></a> </div> <!-- Style 3: raised buttons --> <div class="social-row"> <a href="#" class="social-3 fb"><i class="fab fa-facebook-f" aria-hidden="true"></i>Facebook</a> <a href="#" class="social-3 x"><i class="fab fa-x-twitter" aria-hidden="true"></i>X (Twitter)</a> <a href="#" class="social-3 in"><i class="fab fa-linkedin-in" aria-hidden="true"></i>LinkedIn</a> <a href="#" class="social-3 pi"><i class="fab fa-pinterest-p" aria-hidden="true"></i>Pinterest</a> <a href="#" class="social-3 rd"><i class="fab fa-reddit-alien" aria-hidden="true"></i>Reddit</a> <a href="#" class="social-3 wa"><i class="fab fa-whatsapp" aria-hidden="true"></i>WhatsApp</a> </div> <!-- Style 4: pill buttons --> <div class="social-row"> <a href="#" class="social-4 fb"><i class="fab fa-facebook-f" aria-hidden="true"></i><span>Facebook</span></a> <a href="#" class="social-4 x"><i class="fab fa-x-twitter" aria-hidden="true"></i><span>X (Twitter)</span></a> <a href="#" class="social-4 in"><i class="fab fa-linkedin-in" aria-hidden="true"></i><span>LinkedIn</span></a> <a href="#" class="social-4 pi"><i class="fab fa-pinterest-p" aria-hidden="true"></i><span>Pinterest</span></a> <a href="#" class="social-4 rd"><i class="fab fa-reddit-alien" aria-hidden="true"></i><span>Reddit</span></a> <a href="#" class="social-4 wa"><i class="fab fa-whatsapp" aria-hidden="true"></i><span>WhatsApp</span></a> </div>
@import "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css";
html, body {
padding: 20px;
margin: 0;
background: #f2f4f6;
font-family: Verdana, Geneva, sans-serif;
}
.social-row {
padding-bottom: 30px;
}
.social-row a {
box-sizing: border-box;
margin-bottom: 10px;
margin-right: 5px;
color: #ffffff;
text-decoration: none;
}
.social-row a:focus-visible {
outline: 3px solid #1f2937;
outline-offset: 2px;
}
/* one background color per network */
.fb { background-color: #0866FF; }
.x { background-color: #000000; }
.in { background-color: #0A66C2; }
.pi { background-color: #E60023; }
.rd { background-color: #D93A00; }
.wa { background-color: #0F7A6E; }
/* style 1 */
.social-1 {
display: inline-block;
width: 60px;
height: 60px;
overflow: hidden;
}
.social-1 i {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
transition: transform 0.2s, background-color 0.2s;
}
.social-1:hover i {
background-color: rgba(0,0,0,0.1);
transform: scale(1.2);
}
/* style 2 */
.social-2 {
display: inline-flex;
height: 50px;
overflow: hidden;
}
.social-2 i {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
width: 50px;
background-color: rgba(0,0,0,0.1);
transition: background-color 0.2s;
}
.social-2 span {
display: flex;
align-items: center;
justify-content: center;
padding: 0 30px;
font-weight: bold;
font-size: 14px;
transition: background-color 0.2s;
}
.social-2:hover i {
background-color: rgba(0,0,0,0.2);
}
.social-2:hover span {
background-color: rgba(0,0,0,0.1);
}
/* style 3 */
.social-3 {
display: inline-flex;
height: 40px;
overflow: hidden;
align-items: center;
justify-content: center;
padding: 0 15px 4px 15px;
font-weight: bold;
font-size: 14px;
border-radius: 4px;
box-shadow: inset 0 -4px 0 0 rgba(0,0,0,0.2);
}
.social-3 i {
padding-right: 10px;
}
.social-3:hover {
background-image: linear-gradient(rgba(0,0,0,0.1), rgba(0,0,0,0.1));
}
/* style 4 */
.social-4 {
display: inline-flex;
height: 40px;
overflow: hidden;
border-radius: 20px;
}
.social-4 i {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
width: 40px;
background-color: rgba(0,0,0,0.1);
border-top-right-radius: 20px;
border-bottom-right-radius: 20px;
transition: background-color 0.2s;
}
.social-4 span {
display: flex;
align-items: center;
justify-content: center;
padding: 0 15px;
font-weight: bold;
font-size: 14px;
transition: background-color 0.2s;
}
.social-4:hover i {
background-color: rgba(0,0,0,0.2);
}
.social-4:hover span {
background-color: rgba(0,0,0,0.1);
}Click any element to find its code Esc
Check this code before you run it
It came from a shared link. It runs with fewer permissions, so it cannot open pop-ups, submit forms or start downloads.
element.animate() call shows up here as it plays.