css hover link style : demo 231

HTML

1
2
3
4
5
<div class="demo">
    <a href="#" class="link" data-hover="Hover Me">
        <span>Hover me</span>
    </a>
</div>

CSS

(Fonts required: Kalam.)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
.link{
    color: #777;
    font-family: 'Kalam', cursive;
    font-size: 24px;
    font-weight: 500;
    line-height: 24px;
    text-transform: capitalize;
    text-shadow: 3px 3px #ddd;
    display: inline-block;
    position: relative;
    z-index: 1;
    transition: all 0.5s ease 0s;
}
.link:focus,
.link:hover{
    color: #fff;
    text-shadow: none;
}
.link:before{
    content: attr(data-hover);
    color: #f9412b;
    width: 100%;
    height: 0;
    overflow: hidden;
    position: absolute;
    top: 0;
    left: 0;
    transition: all 0.5s ease 0s;
}
.link:hover:before{ height: 100%; }
@media only screen and (max-width: 767px){
    .link{ margin-bottom: 30px; }
}
License Terms