Reduce width % by X px using calc

http://stackoverflow.com/questions/2434602/css-setting-width-height-as-percentage-minus-pixels

by Jayna

HTML

<div class="box"></div>
<div class="box2"></div>

CSS

.box {
    width: 100%;
    height: 200px;
    /* Firefox */
    width: -moz-calc(100% - 100px);
    /* WebKit */
    width: -webkit-calc(100% - 100px);
    /* Opera */
    width: -o-calc(100% - 100px);
    /* Standard */
    width: calc(100% - 100px);
    background-color: red;
    margin-bottom: 20px;
}

.box2 {
    width: 100%;
    height: 200px;
    background-color: red;
}