box-sizing layout

by danield770

HTML

<header>header</header>
 <div class="container">
     <div class="content">
     Some content
     </div>    
</div>
<footer>footer</footer>

CSS

*
{
    margin:0;padding:0;
}
html,body
{
    height: 100%;
}
header,footer,div
{
   width: 100%; 
}
.container
{
    height: 100%;
    background: pink;
    margin: -64px 0;
    padding: 64px 0;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}
.content {
    overflow:auto;
    height:100%;
}
header
{
    height: 64px;
    background: purple;
    position: relative;
    z-index:1;
}
footer
{
    height: 64px;
    background: gray;
    position: relative;
    z-index:1;
}