Beautiful memorable footer is one of the most important parts of any website. Often it supplements the basic navigation on the website. Today we are going to show you how to the create responsive stylish footer which consists of two section, the first section will consist of three columns with the headings and some text, the second section will contain a menu with links and social icons.
Before we start, have a look at the result (in the beginning of our tutorial) which we are going to achieve:

HTML markyp
Below you can see the general html markup of the page:
04 | <meta charset="utf-8" /> |
05 | <meta name="author" content="Script Tutorials" /> |
06 | <title>Stylish responsive footer | Script Tutorials</title> |
07 | <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> |
09 | <link href="css/styles.css" rel="stylesheet"> |
14 | <div class="splitter"></div> |
19 | <div class="bar-wrap"> |
21 | <li><a href="#">Home</a></li> |
22 | <li><a href="#">License</a></li> |
23 | <li><a href="#">Contact Us</a></li> |
24 | <li><a href="#">Advertise</a></li> |
25 | <li><a href="#">About</a></li> |
30 | <div class="clear"></div> |
31 | <div class="copyright">© 2014 All Rights Reserved</div> |
As you can see, the main page content (of your project) should be placed before the footer element. The first child element in the footer is .splitter – it is narrow striped green line that visually separates our footer. Below are the three-column structure:
03 | <div class="icon" data-icon="E"></div> |
06 | <div>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin tristique justo eu sollicitudin pretium. Nam scelerisque arcu at dui porttitor, non viverra sapien pretium. Nunc nec dignissim nunc. Sed eget est purus. Sed convallis, metus in dictum feugiat, odio orci rhoncus metus. <a href="#">Read more</a></div> |
10 | <div class="icon" data-icon="a"></div> |
13 | <div>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin tristique justo eu sollicitudin pretium. Nam scelerisque arcu at dui porttitor, non viverra sapien pretium. Nunc nec dignissim nunc. Sed eget est purus. Sed convallis, metus in dictum feugiat, odio orci rhoncus metus. <a href="#">Read more</a></div> |
17 | <div class="icon" data-icon="s"></div> |
20 | <div>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin tristique justo eu sollicitudin pretium. Nam scelerisque arcu at dui porttitor, non viverra sapien pretium. Nunc nec dignissim nunc. Sed eget est purus. Sed convallis, metus in dictum feugiat, odio orci rhoncus metus. <a href="#">Read more</a></div> |
Basically, this is the basic unordered list that holds three columns. Every column consists of an icon, title and text. The ‘data-icon’ attribute is used to define an icon to display on the left of column. We use the special font to display the icons – zocial (by Sam Collins). Below these three columns we have another section:
02 | <div class="bar-wrap"> |
04 | <li><a href="#">Home</a></li> |
05 | <li><a href="#">License</a></li> |
06 | <li><a href="#">Contact Us</a></li> |
07 | <li><a href="#">Advertise</a></li> |
08 | <li><a href="#">About</a></li> |
11 | <a href="#" class="fb"> |
12 | <span data-icon="f" class="icon"></span> |
14 | <span class="follow">Become a fan Facebook</span> |
15 | <span class="num">9,999</span> |
18 | <a href="#" class="tw"> |
19 | <span data-icon="T" class="icon"></span> |
21 | <span class="follow">Follow us Twitter</span> |
22 | <span class="num">9,999</span> |
25 | <a href="#" class="rss"> |
26 | <span data-icon="R" class="icon"></span> |
28 | <span class="follow">Subscribe RSS</span> |
29 | <span class="num">9,999</span> |
33 | <div class="clear"></div> |
34 | <div class="copyright">© 2014 All Rights Reserved</div> |
It consists of three elements: another unordered list for the menu, three social icons and the copyright text. Now we can start adding styles for all generated html elements.
CSS
As usual, first of all we provide the most general styles:
css/styles.css
07 | font-family: 'zocial', sans-serif; |
10 | font-family: 'zocial'; |
11 | content: attr(data-icon); |
12 | -webkit-font-smoothing: antialiased; |
15 | font-family: 'Verdana', sans-serif; |
18 | text-decoration: none; |
19 | -webkit-transition: all .2s linear; |
20 | -moz-transition: all .2s linear; |
21 | -ms-transition: all .2s linear; |
22 | -o-transition: all .2s linear; |
23 | transition: all .2s linear; |
First line imports the ‘Zocial’ font, that applies for all elements with the attribute ‘data-icon’. In order to specify a particular icon of the font, we may use the ‘attr’ function of CSS to get the ‘data-icon’ attribute value. For the rest text we use the ‘Verdana’ font. For all <a> elements we removed it’s underline (text-decoration) and added the transition for all it’s styles. The main footer element has the gray background color:
2 | background-color: #2E3639; |
The stripped splitter line has the following styles:
02 | background-color: #ac0; |
03 | background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(.25, rgba(255, 255, 255, .2)), color-stop(.25, transparent), |
04 | color-stop(.5, transparent), color-stop(.5, rgba(255, 255, 255, .2)), |
05 | color-stop(.75, rgba(255, 255, 255, .2)), color-stop(.75, transparent), |
07 | background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, |
08 | transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, |
09 | transparent 75%, transparent); |
10 | background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, |
11 | transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, |
12 | transparent 75%, transparent); |
13 | background-image: -ms-linear-gradient(45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, |
14 | transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, |
15 | transparent 75%, transparent); |
16 | background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, |
17 | transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, |
18 | transparent 75%, transparent); |
19 | background-image: linear-gradient(45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, |
20 | transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, |
21 | transparent 75%, transparent); |
22 | -webkit-background-size: 50px 50px; |
23 | -moz-background-size: 50px 50px; |
24 | background-size: 50px 50px; |
25 | -moz-box-shadow: 1px 1px 8px gray; |
26 | -webkit-box-shadow: 1px 1px 8px gray; |
27 | box-shadow: 1px 1px 8px gray; |
As you can see – it’s just tilted at a 45-degree gradient.
Next are three columns:
02 | list-style: none outside none; |
14 | box-sizing:border-box; |
15 | -webkit-box-sizing:border-box; |
16 | -moz-box-sizing:border-box; |
18 | footer > ul li:first-child { |
21 | footer > ul li:nth-child(3) { |
24 | footer > ul li .icon { |
30 | footer > ul li .text { |
45 | border-bottom: 1px dotted transparent; |
50 | border-color: #FFDD00; |
All three columns are floated from left to right. We use the increased font size for icons of this section (font-size: 80px). The header color is white, the color of ‘read more’ links is yellow (#FFDD00). The next ‘bar’ section has the short menu:
02 | background-color: #1E2629; |
14 | list-style: none outside none; |
All the menu elements are floated from left to right. The right of the menu, we have social icons and slightly below is the copyright text:
14 | display: inline-block; |
17 | vertical-align: middle; |
18 | -webkit-transition: -webkit-transform .3s linear; |
19 | -moz-transition: -moz-transform .3s linear; |
20 | -ms-transition: -ms-transform .3s linear; |
21 | -o-transition: -o-transform .3s linear; |
22 | transition: transform .3s linear; |
24 | .social a:hover .icon { |
25 | -webkit-transform: rotate(360deg); |
26 | -moz-transform: rotate(360deg); |
27 | -ms-transform: rotate(360deg); |
28 | -o-transform: rotate(360deg); |
29 | transform: rotate(360deg); |
32 | display: inline-block; |
33 | vertical-align: middle; |
35 | .social .info .follow { |
If you hover the mouse on the social links – their icon rotates on 360 degrees.
Finally, and most importantly – responsive styles, they serve to our footer displayed well on any (mobile) screens:
01 | @media screen and (max-width: 1000px){ |
02 | .links, .social, .copyright{ |
21 | @media screen and (max-width: 835px) { |
27 | @media screen and (max-width: 768px) { |
[sociallocker]
[/sociallocker]
Conclusion
All ingenious – is simple, at least it should be so. That’s it for today, thanks for your attention. If you like what we have done today – share it with your friends in your social networks using the form below.