Skip to content

Instantly share code, notes, and snippets.

@jethrolarson
Created September 22, 2011 04:14
Show Gist options
  • Select an option

  • Save jethrolarson/1234017 to your computer and use it in GitHub Desktop.

Select an option

Save jethrolarson/1234017 to your computer and use it in GitHub Desktop.
Super simple compass grid system for modern browsers (IE8+)
.container{overflow:hidden;zoom:1;margin:0;padding:0}
.container > *{float:left;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;-ms-box-sizing:border-box;box-sizing:border-box;padding-left:10px}
.container > .alpha,.container > :first-child{padding-left:0!important}
.container > .grid_12{padding:0}
.grid_1{width:8.333%}
.grid_2{width:16.667%}
.grid_3{width:25%}
.grid_4{width:33.333%}
.grid_5{width:41.667%}
.grid_6{width:50%}
.grid_7{width:58.333%}
.grid_8{width:66.667%}
.grid_9{width:75%}
.grid_10{width:83.333%}
.grid_11{width:91.667%}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment