Cool Social Sharing Button using CSS3
Cool social sharing buttons using css3
HTML
HTML
<div class="sharing-wrap"> <h2>Social Sharing</h2> <div class="form"> <a href="Javascript:void(0)" class="icon-button linkedin"><i class="icon-linkedin"></i><span></span></a> <a href="Javascript:void(0)" class="icon-button pinterest"><i class="icon-pinterest"></i><span></span></a> <a href="Javascript:void(0)" class="icon-button twitter"><i class="icon-twitter"></i><span></span></a> <a href="Javascript:void(0)" class="icon-button facebook"><i class="icon-facebook"></i><span></span></a> <a href="Javascript:void(0)" class="icon-button google-plus"><i class="icon-google-plus"></i><span></span></a> </div> </div>CSS
* { box-sizing: border-box; margin: 0; padding: 0; } body { margin-top:20px; } html { background: #95a5a6; background-image: url(http://subtlepatterns.com/patterns/tweed.png); font-family:'Helvetica Neue', Arial, Sans-Serif; } html .sharing-wrap { position: relative; margin: 0 auto; background: #ecf0f1; width: 390px; border-radius: 5px; box-shadow: 3px 3px 10px #333; padding: 15px; } html .sharing-wrap h2 { text-align: center; font-weight: 200; font-size: 2em; margin-top: 10px; color: #34495e; } html .sharing-wrap .form { padding-top: 20px; } html .sharing-wrap .form a { text-align: center; font-size: 20px; color: #3498db; } html .sharing-wrap:after { content:''; position: absolute; top: 0; left: 0; right: 0; background: -webkit-linear-gradient(left, #27ae60 0%, #27ae60 20%, #8e44ad 20%, #8e44ad 40%, #3498db 40%, #3498db 60%, #e74c3c 60%, #e74c3c 80%, #f1c40f 80%, #f1c40f 100%); background: -moz-linear-gradient(left, #27ae60 0%, #27ae60 20%, #8e44ad 20%, #8e44ad 40%, #3498db 40%, #3498db 60%, #e74c3c 60%, #e74c3c 80%, #f1c40f 80%, #f1c40f 100%); height: 5px; border-radius: 5px 5px 0 0; } /* Wrapper */ .icon-button { background-color: white; border-radius: 3.6rem; cursor: pointer; display: inline-block; font-size: 2.0rem; height: 3.6rem; line-height: 3.6rem; margin: 0 5px; position: relative; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; width: 3.6rem; } /* Circle */ .icon-button span { border-radius: 0; display: block; height: 0; left: 50%; margin: 0; position: absolute; top: 50%; -webkit-transition: all 0.3s; -moz-transition: all 0.3s; -o-transition: all 0.3s; transition: all 0.3s; width: 0; } .icon-button:hover span { width: 3.6rem; height: 3.6rem; border-radius: 3.6rem; margin: -1.8rem; } .linkedin span { background-color: #4393BB; } .pinterest span { background-color: #C92228; } .twitter span { background-color: #4099ff; } .facebook span { background-color: #3B5998; } .google-plus span { background-color: #db5a3c; } /* Icons */ .icon-button i { background: none; color: white; height: 3.6rem; left: 0; line-height: 3.6rem; position: absolute; top: 0; -webkit-transition: all 0.3s; -moz-transition: all 0.3s; -o-transition: all 0.3s; transition: all 0.3s; width: 3.6rem; z-index: 10; } .icon-button .icon-linkedin { color: #4393BB; } .icon-button .icon-pinterest { color: #C92228; } .icon-button .icon-twitter { color: #4099ff; } .icon-button .icon-facebook { color: #3B5998; } .icon-button .icon-google-plus { color: #db5a3c; } .icon-button:hover .icon-linkedin, .icon-button:hover .icon-pinterest, .icon-button:hover .icon-twitter, .icon-button:hover .icon-facebook, .icon-button:hover .icon-google-plus { color: white; }
Cool Social Sharing Button using CSS3
Reviewed by Bhaumik Patel
on
9:03 PM
Rating: