/**
 * @file
 * Positioning for a fixed-width, desktop-centric layout.
 *
 * Define CSS classes to create a table-free, 3-column, 2-column, or single
 * column layout depending on whether blocks are enabled in the left or right
 * columns.
 *
 * This layout uses the Zen Grids plugin for Compass: http://zengrids.com
 */


/*
 * Center the page.
 */

#page,
.region-bottom {
  /* If you want to make the page a fixed width and centered in the viewport,
   * this is the standards-compliant way to do that. */
  margin-left: auto;
  margin-right: auto;
  width: 960px;
}

/*
 * Apply the shared properties of grid items in a single, efficient ruleset.
 */
/* This design comes from a hacked grid, so setting my own gutters, allowing borders on header element, etc.. */
#header,
#content,
#navigation,
.region-sidebar-first,
.region-sidebar-second,
#footer {
/*  padding-left: 10px;
  padding-right: 10px;*/
  word-wrap: break-word;
  _display: inline;
  _overflow: hidden;
  _overflow-y: visible;
}

#content,
#navigation,
.region-sidebar-first,
.region-sidebar-second,
#footer {
  border: 0 !important;
}

#content,
.region-sidebar-first,
.region-sidebar-second {
  padding-left: 10px;
  padding-right: 10px;
}

.node-type-landing-page #content {
  padding: 0;
}


/*
 * Containers for grid items and flow items.
 */

#header,
#main,
#footer {
  *position: relative;
  *zoom: 1;
}
#header:before, #header:after,
#main:before, #main:after,
#footer:before, #footer:after {
  content: "";
  display: table;
}
#header:after,
#main:after,
#footer:after {
  clear: both;
}

/*
 * Navigation bar
 */

#main {
  /*padding-top: 3em;  Move all the children of #main down to make room. This space for the navbarneeds to be moved to the bottom of #top-banner */
  position: relative;
}

#navigation {
  position: absolute;
  top: 138px; /* Move the navbar up inside #main's padding. */
  height: 3em;
  width: 960px;
}
#top-banner {
  padding-bottom: 3em;
}
/*
 * The layout when there is only one sidebar, the left one.
 */

.sidebar-first #content {
  float: left;
  width: 700px;
  margin-left: 240px; /* 2 x 10px padding gutters */
  margin-right: -960px;
}

.sidebar-first .region-sidebar-first {
  float: left;
  width: 220px; /* 240px minus 20px (2 x 10px gutters) */
  margin-left: 0px;
  margin-right: -240px;
}

/*
 * The layout when there is only one sidebar, the right one.
 */

.sidebar-second #content {
  float: left;
  width: 780px; /* 906 - 200px, which is 180px sidebar plus 10px gutters */
  margin-left: 0px;
  margin-right: -760px; /* This is 960 - 200 */
}

.sidebar-second .region-sidebar-second {
  float: left;
  width: 180px; 
  margin-left: 760px;
  margin-right: -960px;
}

/*
 * The layout when there are two sidebars.
 */

.two-sidebars #content {
  float: left;
  width: 500px;
  margin-left: 240px;
  margin-right: -920px;
}

.two-sidebars .region-sidebar-first {
  float: left;
  width: 220px;
  margin-left: 0px;
  margin-right: -220px;
}

.two-sidebars .region-sidebar-second {
  float: left;
  width: 180px;
  margin-left: 740px;
  margin-right: -960px;
}
