/*--Name: Amy Blain
Current Date: 12APR2018
Class.Section: CGS1821.054
Assignment: Module 10 Townhall
Language: CSS3
Purpose: Using grid layout to format webpages */

/* the styles for the elements */
* {
	margin: 0;
	padding: 0;
}
html {
	background-color: white;
}
body {
	font-family: Arial, Helvetica, sans-serif;
    font-size: 100%;
    width: 98%;                     /* changed from 800 pixels */
    max-width: 960px;
    margin: 0 auto;
    border: 3px solid #931420;
    background-color: #fffded;
    display: grid;
    grid-template: repeat(4, auto) / auto 1fr;
    grid-template-areas: 
        "head head"
        "navi navi"
        "main main"
        "foot foot";
}
a:focus, a:hover {
	font-style: italic;
}
/* the styles for the header */
header {
	padding: 1em 0 .5em 0;
	border-bottom: 3px solid #931420;
		background-image: -moz-linear-gradient(
	    30deg, #f6bb73 0%, #f6bb73 30%, white 50%, #f6bb73 80%, #f6bb73 100%);
	background-image: -webkit-linear-gradient(
	    30deg, #f6bb73 0%, #f6bb73 30%, white 50%, #f6bb73 80%, #f6bb73 100%);
	background-image: -o-linear-gradient(
	    30deg, #f6bb73 0%, #f6bb73 30%, white 50%, #f6bb73 80%, #f6bb73 100%);
	background-image: linear-gradient(
	    30deg, #f6bb73 0%, #f6bb73 30%, white 50%, #f6bb73 80%, #f6bb73 100%);
    grid-area: head;
}
header h2 {
	font-size: 175%;
	color: #800000;
}
header h3 {
	font-size: 130%;
	font-style: italic;
}
header img {
	float: left;
	padding: 0 3.75%;
}
.shadow {
	text-shadow: 2px 2px 2px #800000;
}
/* the styles for the navigation menu */
#nav_menu {
        grid-area: navi;
}
#nav_menu ul {
	list-style-type: none;
	margin: 0;
	padding: 0;
    display: grid;
    grid-template: auto / repeat(5, 1fr);
    align-content: center;
}
#nav_menu ul li a {
    display: block;
    text-align: center;
    padding: 1em 0;
    text-decoration: none;
    background-color: #800000;
    color: white;
    font-weight: bold;
}
#nav_menu a.current {
	color: yellow;
}
/* the styles for the main */
main {
    grid-area: main;
    display: grid;
    grid-template: auto / 30% 1fr;
    grid-column-gap: 2.5%;
    grid-template-areas: 
        "arti side";
}

/* the styles for the section */
section {
    grid-area: sect;
    grid-row: 1 / 2;
    grid-column:  2 / 3;
    padding: 0 3.7% 20px 0;
}
section h1 {
	font-size: 150%;
	padding: .5em 0 .25em 0;
	margin: 0;
}
section h2 {
	color: #800000;
	font-size: 130%;
	padding: .5em 0 .25em 0;
}
section p {
	padding-bottom: .5em;
}
section blockquote {
	padding: 0 2em;
	font-style: italic;
}
section ul {
	padding: 0 0 .25em 1.25em;
	list-style-type: circle;
}
section li {
	padding-bottom: .35em;
}

/* the styles for the article */
article {
	padding: .5em 0;
	border-top: 2px solid #800000;
	border-bottom: 2px solid #800000;
    grid-area: arti;
}
article h2 {
	padding-top: 0;
}
article h3 {
	font-size: 105%;
	padding-bottom: .25em;
}
article img {
	float: right;
	max-width: 40%;
	min-width: 150px;
	margin: .5em 0 1em 1em;
	border: 1px solid black;
}

/* the styles for the aside */
aside {
    grid-area: side;
    grid-row: 1 / 2;
    grid-column: 1 / 2;
    padding: 0 0 20px 8.3%;
}
aside h2 {
	color: #800000;
	font-size: 130%;
	padding: .5em 0 .25em 0;
}

aside h3 {
	font-size: 105%;
	padding-bottom: .25em;
}
aside img {
	padding-bottom: 1em;
}

/* the styles for the footer */
footer {
	background-color: #931420;
    grid-area: foot;
}
footer p {
	text-align: center;
	color: white;
	padding: 1em 0;
}
#mobile_menu {
	display: none;
}

/* tablet portrait to standard 960 */
@media only screen and (max-width: 959px) {
	section h1 { font-size: 135%; }
	section h2, aside h2 { font-size: 120%; }
}

/* mobile landscape to tablet portrait */
@media only screen and (max-width: 767px) {
	header img { 
        float: none; 
    }
	header {
        text-align: center;
        grid-template: repeat(3,auto) / auto;
        grid-gap: .5em;
        padding: 1.5em 0 1.5em 0;
        text-align: center;
    }
    body {
        grid-template: repeat(4,auto) / auto;
        grid-template-areas: 
        "head"
        "navi"
        "main"
        "foot";
    }
    main {
        grid-template: repeat(2,auto) / 1fr;
        grid-area: main;
    }
    aside {
    grid-area: side;
    grid-row: 2 / 3;
    grid-column: 1 / 2;
    padding-right: 2.5%;
    padding-left: 2.5%;

}
	article img { 
        max-width: 30%; 
    }
	#speakers {
		column-count: 2;
	}
	#nav_menu {
		display: none;
	}
	#mobile_menu {
		display: block;
        grid-area: navi;
	}
	.slicknav_menu {
		background-color: #800000 !important;
	}
    section {
    grid-area: sect;
    grid-row: 1 / 2;
    grid-column:  1 / 2;
    padding-right: 0;
    margin: 0 2.5%;
}

    footer {
        grid-area: foot;
    }
}

/* mobile portrait to mobile landscape */
@media only screen and (max-width: 479px) {
	body { font-size: 90%; }
}
