Skip to content

Instantly share code, notes, and snippets.

@QETHAN
Created May 5, 2014 03:45
Show Gist options
  • Save QETHAN/11528415 to your computer and use it in GitHub Desktop.
Save QETHAN/11528415 to your computer and use it in GitHub Desktop.
A Pen by Craig England.
<section class="blue">
<button class="blue"><span>Browse Category</span><i class="entypo-right-open-big"></i></button>
</section>
<section class="green">
<button class="green"><span>Browse Category</span><i class="entypo-right-open-big"></i></button>
</section>
<section class="purple">
<button class="purple"><span>Browse Category</span><i class="entypo-right-open-big"></i></button>
</section>
<section class="pink">
<button class="pink"><span>Browse Category</span><i class="entypo-right-open-big"></i></button>
</section>
/*
Themes Kingdom
Inspired by www.themeskingdom.com
*/
@import "compass/css3";
@import url(http://fonts.googleapis.com/css?family=PT+Mono);
@import url(http://weloveiconfonts.com/api/?family=entypo);
/* Button Colors */
$blue: #86C7DB;
$green: #85AE52;
$purple: #675B99;
$pink: #FF7362;
$blue-hov: darken(#84C5D9, 5%);
$green-hov: darken(#85AE52, 5%);
$purple-hov: darken(#675B99, 5%);
$pink-hov: darken(#FF7362, 5%);
html, body {
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
-webkit-box-sizing: border-box;
}
i {
font-family: 'entypo', sans-serif;
content: "";
font-style: normal;
display: inline-block;
position: absolute;
left: 85%;
font-size: .7em;
top: 40%;
opacity: 0;
transition: all 0.2s;
}
button:hover i {
left: 88%;
opacity: 1;
transition: all 0.2s;
@media screen and (max-width: 340px) {
left: 92%;
}
}
section {
padding: 3em 0;
}
@mixin button {
margin: 2em auto;
position: relative;
display: block;
color: white;
border: 1px solid #fff;
padding: 1.4em 2.6em;
font-family: 'PT Mono', sans-serif;
transition: all 0.2s;
font-size: 1.4em;
@media screen and (max-width: 340px) {
padding: 0.8em 1.4em;
font-size: 1em;
}
span {
letter-spacing: 1px;
text-transform: uppercase;
position: relative;
left: 0;
transition: all 0.2s;
}
&:hover {
transition: all 0.2s;
cursor: pointer;
}
}
.blue {
background-color: $blue;
button {
@include button;
&:hover {
background-color: $blue-hov;
}
}
}
.green {
background-color: $green;
button {
@include button;
&:hover {
background-color: $green-hov;
}
}
}
.purple {
background-color: $purple;
button {
@include button;
&:hover {
background-color: $purple-hov;
}
}
}
.pink {
background-color: $pink;
button {
@include button;
&:hover {
background-color: $pink-hov;
}
}
}
button:hover span {
left: -15px;
transition: all 0.2s;
@media screen and (max-width: 340px) {
left: -5px;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment