A collection of my #ButtonChallenge can be found here > http://codepen.io/collection/riHLy/
Created
February 28, 2016 23:25
-
-
Save ntwcklng/0b8fa7dc6a37c267dc3f to your computer and use it in GitHub Desktop.
#ButtonChallenge6
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
<a class="btn-edge" href="#">Hover Me</a> |
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(http://fonts.googleapis.com/css?family=Titillium+Web:700); | |
*, *:before, *:after { | |
margin:0; | |
padding:0; | |
box-sizing:border-box; | |
} | |
body { | |
padding-top:10%; | |
text-align:center; | |
overflow-x:hidden; | |
} | |
.btn-edge { | |
position:relative; | |
display:inline-block; | |
padding:1rem 2rem; | |
font-family:'Titillium Web', sans-serif; | |
font-weight:700; | |
text-decoration:none; | |
font-size:3rem; | |
color:#333; | |
background-image: | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333), | |
linear-gradient(#333,#333); | |
background-repeat:no-repeat; | |
background-size: | |
2rem 5px, | |
2rem 5px, | |
2rem 5px, | |
2rem 5px, | |
5px 2rem, | |
5px 2rem, | |
5px 2rem, | |
5px 2rem; | |
background-position: | |
0 0, | |
100% 0, | |
0 100%, | |
100% 100%; | |
box-shadow:inset 0 0 0 5px rgba(tomato, 0); | |
transition: | |
background-size 1s .4s, | |
box-shadow .4s, | |
color .4s; | |
transform:translateZ(0); | |
&:hover { | |
color:tomato; | |
background-size: | |
52% 5px, | |
52% 5px, | |
52% 5px, | |
52% 5px, | |
5px 52%, | |
5px 52%, | |
5px 52%, | |
5px 52%; | |
box-shadow:inset 0 0 0 5px rgba(tomato, 1); | |
transition: | |
background-size 1s, | |
box-shadow .4s .6s, | |
color .4s .6s; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment