/*************************
****** Grid System *******
**** Version: 0.0.2 ******
*************************/
// Utility function — you should never need to modify this
@function gridsystem-width($columns:$columns) {
  @return ($column-width * $columns) + ($gutter-width * $columns);
}

//////////
// GRID //
//////////

@mixin row($columns:$columns) {
  display: block;
  width: $total-width*(($gutter-width + gridsystem-width($columns))/gridsystem-width($columns));
  margin: 0 $total-width*((($gutter-width*.5)/gridsystem-width($columns))*-1);
  // *width: $total-width*(($gutter-width + gridsystem-width($columns))/gridsystem-width($columns))-$correction;
  // *margin: 0 $total-width*((($gutter-width*.5)/gridsystem-width($columns))*-1)-$correction;
  @include clearfix();
}

@mixin column($x, $columns:$columns) {
  display: inline;
  float: left;
  width: $total-width*(((($gutter-width+$column-width)*$x)-$gutter-width) / gridsystem-width($columns));
  margin: 0 $total-width*(($gutter-width*.5)/gridsystem-width($columns));
  // *width: $total-width*(((($gutter-width+$column-width)*$x)-$gutter-width) / gridsystem-width($columns))-$correction;
  // *margin: 0 $total-width*(($gutter-width*.5)/gridsystem-width($columns))-$correction;
}

@mixin push($offset:1) {
  margin-left: $total-width*((($gutter-width+$column-width)*$offset) / gridsystem-width($columns)) + $total-width*(($gutter-width*.5)/gridsystem-width($columns));
}

@mixin pull($offset:1) {
  margin-right: $total-width*((($gutter-width+$column-width)*$offset) / gridsystem-width($columns)) + $total-width*(($gutter-width*.5)/gridsystem-width($columns));
}