/* ==========================================================================
   HTML5 Boilerplate styles - h5bp.com (generated via initializr.com)
   ========================================================================== */

html,
button,
input,
select,
textarea {
    color: #222;
}

body {
    font-size: 1em;
    line-height: 1.4;
}

::-moz-selection {
    background: #FFE889;
    text-shadow: none;
}

::selection {
    background: #FFE889;
    text-shadow: none;
}

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

img {
    vertical-align: middle;
}

fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

textarea {
    resize: vertical;
}

.chromeframe {
    margin: 0.2em 0;
    background: #ccc;
    color: #000;
    padding: 0.2em 0;
}

a, a:link, a:visited, a:hover, a:active {
	color: inherit;
}
a:hover {
	text-decoration: underline;
}


/* ===== Initializr Styles ==================================================
   Author: Jonathan Verrecchia - verekia.com/initializr/responsive-template
   ========================================================================== */

body {
    font: 16px/26px Helvetica, Helvetica Neue, Arial;
}

.wrapper {
    width: 90%;
    margin: 0 5%;
}

/* ===================
    ALL: Orange Theme
   =================== */

.header-container {
    border-bottom: 20px solid #e44d26;
}

.footer-container,
.main aside {
    border-top: 20px solid #e44d26;
}

.header-container,
.footer-container,
.main aside {
    background: #f16529;
}

.title {
    color: white;
}

/* ==============
    MOBILE: Menu
   ============== */

nav {
	margin-top: 1em;
	background-color: #333;
	color: #ddd;
}

nav ul {
    margin: 0;
    padding: 0;
}

nav ul li {
	display: inline-block;
}

nav a {
    display: block;
	padding: 0.5em 1em;

    text-align: center;
    text-decoration: none;
    font-weight: bold;

    color: white;
	
	background-color: #333;
	-webkit-transition: background 0.3s; 
	-moz-transition: background 0.3s; 
	-o-transition: background 0.3s; 
	transition: background 0.3s; 
}

nav a:hover,
nav a:visited {
    color: white;
}

nav a:hover {
    text-decoration: underline;
}

/* ==============
    MOBILE: Main
   ============== */

.main {
    padding: 30px 0;
}

.main article h1 {
    font-size: 2em;
}

.main aside {
    color: white;
    padding: 0px 5% 10px;
}

.footer-container footer {
    color: white;
    padding: 20px 0;
}

/* ===============
    ALL: IE Fixes
   =============== */

.ie7 .title {
    padding-top: 20px;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

h1, h2, h3, h4, h5, h6, p {
	margin: 0 0 .5em 0;
}

body {
	background-image: url(img/Texture0101.jpg);
}

body > header > div,
body > footer > div {
	margin: 0 auto;
	width: 60em;
	max-width: 95%;
	position: relative;
}

header, footer {
	background-image: url(img/Texture0101_dark.jpg);
}

header .logo {
	display: inline-block;
	padding: .6em 1.4em;
	margin: 0 .5em .5em .5em;
	background-color: #ffe062;
	background-image: -webkit-gradient(linear, left top, left bottom, from(#ffe062), to(#e0bd2f));
	background-image: -webkit-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -moz-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -o-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: linear-gradient(to bottom, #ffe062, #e0bd2f);
	box-shadow: 0 0 0 0.5em rgba(0,0,0,0.4);
	font-family: serif;
	font-weight: normal;
	font-size: 1em;
	line-height: 1;
	text-transform: uppercase;
	text-align: center;
}

header .logo:hover {
	text-decoration: inherit;
}

header .logo b {
	display: block;
	font-size: 2em;
}

header .search {
	text-align: right;
	margin: 0.3em 0;
}

.search input.g {
	background: #fff url(//www.google.com/cse/images/google_custom_search_smwide.gif) no-repeat 5px center;
	border: 1px inset #bbb;
	border-right: none;
	border-top-left-radius: 0.4em;
	border-bottom-left-radius: 0.4em;
	padding: 0.3em 0.4em;
}

.search input[type='submit'] {
	border: 1px outset #bbb;
	border-left: none;
	border-top-right-radius: 0.4em;
	border-bottom-right-radius: 0.4em;
	padding: 0.3em 0.4em;
	text-shadow: 0 .1em 0 #eee;
	background-color: #eeeeee;
	background-image: -webkit-gradient(linear, left top, left bottom, from(#eeeeee), to(#cccccc));
	background-image: -webkit-linear-gradient(top, #eeeeee, #cccccc);
	background-image:    -moz-linear-gradient(top, #eeeeee, #cccccc);
	background-image:      -o-linear-gradient(top, #eeeeee, #cccccc);
	background-image:         linear-gradient(to bottom, #eeeeee, #cccccc);

}

.search input.g:focus, .search input.clr {
	background-image: none;
	outline: none;
}

header nav ul li a:hover,
header nav ul li a:active,
header nav ul li.active a
 {
	background-color: #000;
	transition: background-color .2s;
}


/* Footer */

footer {
	border-top: 0.5em solid #999;
	margin-top: -0.5em;
	z-index: 1;
}

footer > div {
	background-color: #bbb;
	overflow: hidden;
	padding-bottom: 1em;
}

footer h4 {
	margin: 1em 0 0 0;
	border-bottom: .1em solid #999;
}

footer ul {
	margin: 0.6em 0 0 0;
	padding-left: 0;
	list-style-type: none;
	line-height: 1.3;
}

footer ul li {
	margin-bottom: .3em;
}

footer .s2of5 ul {
  -webkit-column-count: 2;  -webkit-column-gap: 1em;
     -moz-column-count: 2;     -moz-column-gap: 1em;
          column-count: 2;          column-gap: 1em;

}

footer a {
	transition: color .2s;
}

footer a:hover {
	color: #0032BA;
}



.main {
	margin: 0 auto;
	width: 60em;
	max-width: 95%;
	background-color: #fff;
	border-bottom: 0.5em solid #333;
	overflow: hidden;
	position: relative;
	z-index: 2;
}

.main a {
	color: #0032BA;
}
.main > div > div {
	box-shadow: .1em .1em .1em .1em #999;
	margin-bottom: 1em;
	border-radius: .3em;
}

footer > div > div {
	float: left;
}
footer .s1of5 {
	width: 10.8em;
	margin-left: 1em;
}
footer .s2of5 {
	width: 22.6em;
	margin-left: 1em;
}
footer .s3of5 {
	width: 34.4em;
	margin-left: 1em;
}
footer .s4of5 {
	width: 46.2em;
	margin-left: 1em;
}
footer .s5of5 {
	width: 58em;
	margin-left: 1em;
}


.main h2 {
	padding: .5em .66666666em;
}

.pagination a {
	display: inline-block;
	text-indent: 999em;
	width: 1em;
	height: 1em;
	border: .2em solid #eee;
	background-color: #444;
	margin-left: .2em;
	border-radius: 1em;
	font-size: 10px;
	transition: all .6s;
}

.pagination a:hover {
	background-color: #999;
	border-color: #fff;
}

/* News */
#s_news {
}
.sidebar > div > div {
	margin-top: -0.75em;
	border-bottom-right-radius: .3em;
	border-bottom-left-radius: .3em;
	overflow: hidden;
}

.slider {
	background-color: #555;
	color: #ddd;
}
.slider h3 {
	color: #aaa;
}
.slider > div {
	padding: 5%;
	width: 90%;
}

.cycle-pager { 
	z-index: 500;
	position: absolute;
	bottom: 0;
	right: 0;
	padding: 0 .2em;
	overflow: hidden;
	font-size: 3em;
}
.cycle-pager span { 
    font-family: arial;
	padding: 0 0.02em;
	display: inline-block;
	color: #aaa;
	cursor: pointer;
}
.cycle-pager span.cycle-pager-active { color: #ffe062;}
.cycle-pager > * { cursor: pointer;}


#s_browse > div {
	padding: .5em 1em;
}


#s_new {
	box-shadow: none;
}

#s_new > div {
	box-shadow: .1em .1em .1em .1em #999;
	border-radius: .3em;
	width: 12.75em;
	margin-left: 1em;
	float: left;
}
#s_new > div:first-child {
	margin-left: 0;
}
#s_new > div > div {
	padding: 0 .5em;
}
#s_new > div > div * {
	max-width: 100%;
	height: auto;
}
#s_new > div > div p {
	font-size: 0.9em;
	line-height: 1.3;
}
#s_new > div > div > img {
	margin-bottom: .5em;
}
#s_new h2 {
	background-color: #ffe062;
	background-image: -webkit-gradient(linear, left top, left bottom, from(#ffe062), to(#e0bd2f));
	background-image: -webkit-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -moz-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -o-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: linear-gradient(to bottom, #ffe062, #e0bd2f);
	border-top-left-radius: .3em;
	border-top-right-radius: .3em;
	padding: .3em .385em;
	font-size: 1.3em;
}

#s_new h3 a {text-decoration: none;}
#s_new h3 a:hover {text-decoration: underline;}

#s_news h2,
#s_browse h2,
#s_resources h2,
#s_vid h2,
.main-content > div > h2:first-child
{
	background-color: #ffe062;
	background-image: -webkit-gradient(linear, left top, left bottom, from(#ffe062), to(#e0bd2f));
	background-image: -webkit-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -moz-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: -o-linear-gradient(top, #ffe062, #e0bd2f);
	background-image: linear-gradient(to bottom, #ffe062, #e0bd2f);
	border-top-left-radius: .2em;
	border-top-right-radius: .2em;
	padding: 0.4em .33333333em 0.3em .33333333em;
	text-shadow: .05em .05em .05em #ffe062;
}

#s_vid > div {
	padding: .5em;
	overflow: hidden;
}

.video-wrapper {
	width: 26em;
	height: 16em;
	float: left;
	margin: 0 1.5em 1em 0;
	position: relative;
}
	.video-wrapper > .aspect4-3 { 
		margin-top: 63%;
	}
	.video-wrapper .stretch {
		position: absolute;
		top: 0;
		left: 0;
		right: 0;
		bottom: 0;
	}
	.video-wrapper iframe {
		width: 100%;
		height: 100%;
	}
.video-description {
	font-size: 0.9em;
	line-height: 1.3;
}






/* ==========================================================================
   Media Queries
   ========================================================================== */

@media only screen and (max-width: 480px) {
	
	header .logo {
		width: 90%;
		padding: 3%;
		margin: 0 2% 2% 2%;
	}
	
	.search input.g {
		display: block;
		border: 1px inset #bbb;
		border-radius: 0.3em;
		width: 97%;
		padding: 1%;
	}
	
	.search input[type='submit'] {
		border: 1px outset #bbb;
		border-radius: .2em;
		padding: 1% 5%;
	}
	
	footer .s2of5,
	footer .s1of5
	{
		margin: 0 3%;
		width: 94%;
	}
	
}
@media only screen and (max-width: 669px) {

/* ====================
    INTERMEDIATE size
   ==================== */
	
	body > header > div,
	body > footer > div,
	.main
	{
		max-width: 100%;
		max-width: 100%;
	}

	.sidebar {
		padding: 0 .5em;
	}
	.sidebar > div {
		margin-bottom: 1em;
	}
	
	.cycle-pager {
		left: 0; /* don't interfere with mobile scrolllbars */
		padding: .03em 5%;
		font-size: 4.5em;
		margin-left: -0.07em;
	}
	.cycle-pager span {
		padding: 0;
	}
	.slider > div {
		padding-bottom: 1.6em;
	}
	
	#s_new > div,
	#s_new > div:first-child,
	#s_vid
	{
		width: auto;
		margin: .5em;
	}
	
	/* 
		Height aspect ratio:
		http://stackoverflow.com/questions/5445491/height-equal-to-dynamic-width-css-fluid-layout
	*/
	.video-wrapper {
		float: none;
		display: block;
		width: auto;
		height: auto;
		overflow: hidden;
		margin: 0 0 0.5em 0;
	}
	.video-description {
		font-size: 0.9em;
		line-height: 1.3;
	}
	
	
}

@media only screen and (min-width: 670px) and (max-width: 1014px) {
	
	header .search {
		position: absolute;
		top: 0;
		right: 0;
	}
	
	.main > div {
		float: none;
		overflow: auto;
	}
	#s_new {
		margin: 0;
	}
	.main > div > div,
	#s_new > div,
	#s_new > div:first-child
	{
		margin-bottom: 1em;
		margin-left: 1%;
		width: 32%;
	}
	
	.main > .main-content > div {
		width: auto;
	}
	.main > .main-content > div > div {
		width: auto;
	}
	
	.sidebar > div {
		width: 12.75em;
		margin-left: 1em;
		float: left;
	}
	
	#s_vid > div {
		padding: 0;
	}
}

@media only screen and (min-width: 1015px) {
	
	header .search {
		position: absolute;
		top: 0;
		right: 0;
        width: 250px;
	}
	
	.main > div {
		float: left;
		overflow: visible;
	}
	
	.main > .sidebar {
		width: 13.75em;
		margin-left: 1em;
	}
	.main > .main-content {
		width: 40.25em;
		margin-left: 4em;
	}
	.sidebar > div {
		float: none;
		width: auto;
		margin-left: 0;
	}
}

/* ==========================================================================
   Helper classes
   ========================================================================== */

.ir {
    background-color: transparent;
    border: 0;
    overflow: hidden;
    *text-indent: -9999px;
}

.ir:before {
    content: "";
    display: block;
    width: 0;
    height: 150%;
}

.hidden {
    display: none !important;
    visibility: hidden;
}

.visuallyhidden {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
}

.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
    clip: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    width: auto;
}

.invisible {
    visibility: hidden;
}

.clearfix:before,
.clearfix:after {
    content: " ";
    display: table;
}

.clearfix:after {
    clear: both;
}

.clearfix {
    *zoom: 1;
}

/* ==========================================================================
   Print styles
   ========================================================================== */

@media print {
    * {
        background: transparent !important;
        color: #000 !important; /* Black prints faster: h5bp.com/s */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }

    abbr[title]:after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links for images, or javascript/internal links
     */

    .ir a:after,
    a[href^="javascript:"]:after,
    a[href^="#"]:after {
        content: "";
    }

    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    thead {
        display: table-header-group; /* h5bp.com/t */
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    img {
        max-width: 100% !important;
    }

    @page {
        margin: 0.5cm;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}
