/*! HTML5 Boilerplate v6.1.0 | MIT License | https://html5boilerplate.com/ */

/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* Edited by the high12noon blog */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
	/* Permalink - use to edit and share this gradient: http://colorzilla.com/gradient-editor/#5b95c1+0,fff8d1+23,f2db9d+77,eaa1a1+89,002400+100 */
	background: #5b95c1; /* Old browsers */
	background: -moz-linear-gradient(top, #5b95c1 0%, #fff8d1 23%, #f2db9d 77%, #eaa1a1 89%, #002400 100%); /* FF3.6-15 */
	background: -webkit-linear-gradient(top, #5b95c1 0%,#fff8d1 23%,#f2db9d 77%,#eaa1a1 89%,#002400 100%); /* Chrome10-25,Safari5.1-6 */
	background: linear-gradient(to bottom, #5b95c1 0%,#fff8d1 23%,#f2db9d 77%,#eaa1a1 89%,#002400 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
	filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#5b95c1', endColorstr='#002400',GradientType=0 ); /* IE6-9 */
	background-repeat: no-repeat;
	background-attachment: fixed;

	font-size: 1em;
	line-height: 1.4;

	font-family: serif;

	/* keep footer at bottom */
	height: 100%;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Vendor-prefixed and regular ::selection selectors cannot be combined:
 * https://stackoverflow.com/a/16982510/7133471
 *
 * Customize the background color to match your design.
 */

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

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

/*
 * A better looking default horizontal rule
 */

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

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
	vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

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

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
	resize: vertical;
}

/* ==========================================================================
   Browser Upgrade Prompt
   ========================================================================== */

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

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

body {
	/* keep footer at bottom */
	display: flex;
	flex-direction: column;

	padding: 0px;
	width: 100%;

	/* keep footer at bottom */
	height: 100%;
}


header {
	text-align: center;
}


footer {
	/* keep footer at bottom */
	flex-shrink: 0;

	text-align: center;

	background: #010203;
	color: #A39576;
}


/* Formatting of the <div id="content"> ... </div> element */
#content {
	/* keep footer at bottom */
	flex: 1 0 auto;

	background: #FAFCFB;
	border: 2px solid steelblue;

	margin: auto;
	margin-bottom: 10px;
	padding: 0px 10px 0px 10px;

	/* Subtract 24 = 2(10px) left and right padding + 2(2px) lext and right border*/
	width: calc(65em - 24px);
	max-width: calc(100% - 24px);
}


/* .resp-container, .resp-iframe: Make YouTube video fit within its parent.
   Source: https://blog.theodo.fr/2018/01/responsive-iframes-css-trick/
*/


.resp-container {
	position: relative;
	overflow: hidden;
	padding-top: 56.25%;
}


.resp-iframe {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border: 0;
}


/* Make SVG in <object> clickable by wrapping with <a href="">...</a>
   Source:   https://stackoverflow.com/questions/11374059/make-an-html-svg-object-also-a-clickable-link
   See also: https://teamtreehouse.com/community/how-do-you-make-a-svg-clickable
*/


a.svg {
	position: relative;
	display: inline-block;
}
a.svg:after {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left:0;
}


/* Add an icon after external links */
a[href*='//']::after {
	content: url("../img/extlink.png");
	margin-left: 5px
}


/* Table styling based on:
   https://dev.to/dcodeyt/creating-beautiful-html-tables-with-css-428l
*/


/* Use with:
   <table class="noon-table">...</table>
*/
.noon-table {
	border-collapse: collapse;
	margin: 25px 0;
	font-size: 0.9em;
	font-family: sans-serif;
	min-width: 400px;
	box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
}


/* Style the header
*/
.noon-table thead tr {
	background-color: ##3A668F;
	color: #ffffff;
	text-align: left;
}


/* Improve spacing between cells
*/
.noon-table th,
.noon-table td {
	padding: 12px 15px;
	text-align: left;
}


/* Horizontal rules between rows
*/
.noon-table tbody tr {
	border-bottom: thin solid #dddddd;
}


/* Different background every other row
*/
.noon-table tbody tr:nth-of-type(even) {
	background-color: #f3f3f3;
}


/* Horizontal rule at bottom of table to signify end
*/
.noon-table tbody tr:last-of-type {
	border-bottom: 2px solid ##3A668F;
}


/* Allow a row to be specified as "active" with:
   <tr class="active-row">...</tr>
*/
.noon-table tbody tr.active-row {
	font-weight: bold;
	color: ##3A668F;
}


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

/*
 * Hide visually and from screen readers
 */

.hidden {
	display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

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

/*
 * Extends the .visuallyhidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

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

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
	visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */

.clearfix:before,
.clearfix:after {
	content: " "; /* 1 */
	display: table; /* 2 */
}

.clearfix:after {
	clear: both;
}


/* ==========================================================================
   From https://stackoverflow.com/questions/8160514/is-there-css-for-typesetting-the-latex-logo-in-html
   Slightly modified
   ========================================================================== */
.tex sub, .latex sub, .latex sup {
  text-transform: uppercase;
}

.tex sub, .latex sub {
  vertical-align: -0.15ex;
  margin-left: -0.1667em;
  margin-right: -0.125em;
}

.tex, .latex, .tex sub, .latex sub {
  font-size: 1em;
}

.latex sup {
  font-size: 0.85em;
  vertical-align: 0.05em;
  margin-left: -0.36em;
  margin-right: -0.15em;
}


/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
	/* Style adjustments for viewports that meet the condition */
}

@media print,
	   (-webkit-min-device-pixel-ratio: 1.25),
	   (min-resolution: 1.25dppx),
	   (min-resolution: 120dpi) {
	/* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   https://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
	*,
	*:before,
	*:after {
		background: transparent !important;
		color: #000 !important; /* Black prints faster */
		-webkit-box-shadow: none !important;
		box-shadow: none !important;
		text-shadow: none !important;
	}

	/* Prevent printing an extra blank page */
	html, body {
		height: auto;
	}

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

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

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

	/*
	 * Don't show links that are fragment identifiers,
	 * or use the `javascript:` pseudo protocol
	 */

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

	pre {
		white-space: pre-wrap !important;
	}
	pre,
	blockquote {
		border: 1px solid #999;
		page-break-inside: avoid;
	}

	/*
	 * Printing Tables:
	 * http://css-discuss.incutio.com/wiki/Printing_Tables
	 */

	thead {
		display: table-header-group;
	}

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

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

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