Button with Hover Effect
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="container"> | |
<div class="title"> | |
<a href="http://codepen.io/sashatran/" target="_blank">Subscribe Now</a> | |
</div> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".title").hover(function(){ | |
$(this).toggleClass("is-active"); | |
}) | |
//Without JS by Ana Tudor | |
// https://codepen.io/anon/pen/egGKwv | |
// by Scott | |
//Button to zoom in instead of moving down | |
// http://codepen.io/scottjenson/pen/mRBGbP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import url('https://fonts.googleapis.com/css?family=Roboto'); | |
* { | |
padding: 0; | |
margin: 0; | |
} | |
.container { | |
height: 100vh; | |
display: flex; | |
justify-content: center; | |
align-items: center; | |
background: linear-gradient(50deg, #B388EB, #8093F1); | |
opacity: 0.8; | |
filter: saturate(1.6); | |
} | |
.title { | |
width: 200px; | |
height: 20px; | |
font-size: 16px; | |
font-family: 'Roboto', sans-serif; | |
color: #FFF; | |
text-transform: uppercase; | |
text-align: center; | |
letter-spacing: 4px; | |
background: rgba(#000000, 0.2); | |
padding: 15px 20px; | |
transition: all .5s ease; | |
border-radius: 3px; | |
cursor: pointer; | |
a { | |
text-decoration: none; | |
color: #FFF; | |
} | |
} | |
.is-active { | |
box-shadow: 0 20px 5px -10px rgba(#000, 0.4); | |
transform: translateY(10px); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment