/*
 * Styles for homepage (index.html)
 */

#home-banner {
	height: 90vh;
	min-height: 30rem;
	background-image: url("../images/backgrounds/homepage-landing.jpg");
}

#landing-article h2 {
	font-size: 1.8rem;
	font-weight: normal;
	margin: 0;
}

#landing-article p {
	margin: 1rem 0;
	line-height: 1.6rem;
}

#landing-article a {
	display: inline-block;
	margin-top: 0.5rem;
	box-shadow: 0 0 50px #222222;
}


#intro {
	background-color: var(--theme-white);
}

#intro-container {
	/* row flexbox, becomes column for screens < 600px wide */
	display: flex;
	align-items: center;
	justify-content: space-between;
}

#intro-graphic {
	display: grid;
	justify-items: center;
	align-items: center;
	grid-row-gap: 1.5rem;
}

/* The "360" in the logo */
#intro-graphic h3 {
	/* Same grid cell as the img so they overlap */
	grid-area: 1 / 1 / 2 / 2;
	margin: 0;
	color: var(--theme-blue);
	font-size: 2.5vw;
	font-weight: normal;
}

/* The text below the logo */
#intro-graphic h2 {
	grid-area: 2 / 1 / 3 / 2;
	margin: 0;
	font-family: var(--secondary-font-family);
	font-weight: 400;
	letter-spacing: 0.15rem;
	font-size: 1.5vw;
	text-transform: uppercase;
	text-align: center;
}

#intro img {
	/* Same grid cell as the h3 so they overlap */
	grid-area: 1 / 1 / 2 / 2;
	width: 10vw;
	animation-name: rotate;
	animation-duration: 40s;
	animation-direction: reverse;
	animation-iteration-count: infinite;
	animation-timing-function: linear;
}

#intro-text {
	text-align: center;
	/* 12.5% of 80% = 10% of screen, same as side margins of container */
	margin-left: 12.5%;
}

#intro p {
	text-align: left;
	line-height: 1.6rem;
	margin: 0;
}

#intro a {
	display: inline-block;
	margin: 1rem 0;
	box-shadow: 7px 7px 10px #bbbbbb;
}


#services {
	background-image: url("../images/backgrounds/homepage-services.jpg");
	background-size: cover;
	background-position: 60% 50%;
}

#services > .container {
	padding: 4rem 0;
}

#services h2 {
	margin: 0 0 4rem 0;
	font-weight: normal;
}

#services-grid {
	display: inline-grid;
	grid-template-columns: 1fr 1fr;
	justify-content: center;
	grid-gap: 1rem;
}

/* The grid cells */
#services a {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: space-between;
	padding: 2rem 0 0.5rem 0;
	height: 9rem;
	max-width: 9rem;
	text-decoration: none;
	background-color: var(--theme-white);
	border-radius: 0.4rem;
	box-shadow: 0 0 15px #d2d2d2;
	transition: padding var(--default-transition-duration);
}

#services a:hover {
	/* (top rem, bottom rem) Padding changes from (2, 0.5) to (1.5, 1.5) */
	padding: 1.5rem 0;
}

.services-icon {
	max-width: 2rem;
}

#services h3 {
	margin: 0;
	font-size: 0.8rem;
	color: black;
	font-weight: 400;
	text-transform: uppercase;
	text-align: center;
	letter-spacing: 0.07rem;
}

a .services-arrow {
	width: 0.6rem;
	visibility: hidden;
}

a:hover .services-arrow {
	visibility: visible;
}


#contact {
	background-color: var(--theme-white);
}

#contact > .container {
	padding: 3rem 0;
}

#contact-content {
	display: grid;
	grid-template-columns: 1fr;
	align-items: center;
	grid-row-gap: 1rem;
}

#contact h2 {
	font-weight: normal;
	margin: 0 0 1rem 0;
}

#contact-modes {
	margin: 1rem 0;
}

#contact-modes a, #contact-modes > div {
	/* center-aligned inline-flex to center icon and arrow with text */
	display: inline-flex;
	align-items: center;
	text-decoration: none;
	margin: 1rem 0;
}

.contact-icon {
	background-color: var(--theme-blue);
	border-radius: 100rem;
	min-width: 2.25rem;
	min-height: 2.25rem;
	display: flex; align-items: center; justify-content: center;
	box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
}

.contact-icon img {
	height: 1rem;
}

#contact-modes address {
	font-size: 0.9rem;
	font-style: normal;
	margin: 0 1.25rem;
	transition: opacity var(--default-transition-duration);
}

#contact-modes a address {
	color: var(--theme-light-blue);
}

#contact-modes a:hover address {
	opacity: 0.55;
}

#contact-modes a .contact-icon {
	transition: background-color var(--default-transition-duration);
}

#contact-modes a:hover .contact-icon {
	background-color: var(--theme-light-blue);
}

.contact-arrow {
	height: 0.6rem;
}

#contact-map iframe {
	border: none;
	width: 100%;
	height: 100%;
	min-height: 40vw;
}


@media(min-width: 900px) {

	/* Services - 4 column grid */
	#services-grid {
		grid-template-columns: 1fr 1fr 1fr 1fr;
		grid-gap: 2vw;
	}


	/* Contact - right column with map, responsive map height */
	#contact-content {
		grid-template-columns: 1fr 1fr;
	}

	#contact-map iframe {
		min-height: 25vw;
	}
}

@media(max-width: 480px) {

	/* Landing article - h2 smaller, p line-height smaller */
	#landing-article h2 {
		font-size: 1.5rem;
	}

	#landing-article p {
		line-height: 1.5rem;
	}


	/* Services - h2 and grid centered on page*/
	#services > .container {
		text-align: center;
	}


	/* Contact - h2 centered on page */
	#contact h2 {
		text-align: center;
	}
}

@media(max-width: 600px) {

	/* Intro - vertically stacked, graphic size fixed */
	#intro-container {
		flex-direction: column;
	}

	#intro-graphic {
		margin-bottom: 2rem;
	}

	#intro-text {
		margin-left: 0;
	}

	#intro-graphic h3 {
		font-size: 1rem;
	}

	#intro-graphic h2 {
		font-size: 0.6rem;
	}

	#intro img {
		width: 4rem;
	}
}
