/*! HTML5 Boilerplate v8.0.0 | MIT License | https://html5boilerplate.com/ */

/* main.css 2.1.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * 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.
 */

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

html {
	color: #222;
	font-size: 16px;
	line-height: 1.4;
}

/*
 * 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;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */
/*-------- General Styles for all pages --------*/
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	font-size: 16px;
}

body {
	font-family: "Montserrat", sans-serif;
	font-size: 1em;
	display: grid;
}

ul,
ol {
	list-style: none;
	text-transform: uppercase;
	font-weight: 400;
	font-size: 1rem;
	letter-spacing: 0.1rem;
}

a {
	color: #5f5f5f;
	text-decoration: none;
}

a:hover {
	cursor: pointer;
}

h1 {
	font-family: "DM Serif Display", serif;
	font-size: 2.5em;
	font-weight: 500;
	margin: 0 0 0.75em 0;
}

h2 {
	font-family: "DM Serif Display", serif;
	font-size: 2em;
	font-weight: 500;
	margin: 0 0 0.75em 0;
}

h3,
h4 {
	font-family: "DM Serif Display", serif;
	font-size: 1.5em;
	font-weight: 500;
}

p {
	font-size: 1rem;
	line-height: 1.8em;
	color: #5f5f5f;
}

figure {
	margin: 0;
}

address {
	font-style: normal;
}

/* button hover effect */
button {
	cursor: pointer;
	border: none;
	background-color: #c68d3b;
	color: #fff;
	clear: both;
	display: block;
	font-weight: 700;
	font-size: 1rem;
	letter-spacing: 0.1em;
	margin: 0 auto;
	margin-top: 5em;
	padding: 15px 30px;
	text-transform: uppercase;
	text-decoration: none;
	text-align: center;
	width: 20em;
	transition: all 0.5s;
	position: relative;
}

button span {
	transition: all 0.5s;
}
button::before {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
	opacity: 0;
	transition: all 0.3s;
	transform: scale(0.1, 1);
}
button:hover span {
	letter-spacing: 0.15em;
}
button:hover::before {
	opacity: 1;
	transform: scale(1, 1);
}
button::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
	transition: all 0.3s;
	background-color: rgba(255, 255, 255, 0.1);
}
button:hover::after {
	opacity: 0;
	transform: scale(0.1, 1);
}

/*-------- Header tyles --------*/

header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-flow: row wrap;
	background-color: #fff;
}

/* Nav Bar */
nav ul {
	display: flex;
	justify-content: space-around;
	padding: 0;
}

nav ul li {
	padding: 0 20px;
	color: black;
	display: inline-block;
}

/* nav hover effect */
nav ul li a {
	padding: 0.75em;
}

nav ul li a,
nav ul li a:after,
nav ul li a:before {
	transition: all 0.5s;
}

nav ul li a:hover {
	color: #555;
}

nav.nav-items ul li a {
	position: relative;
}

nav.nav-items ul li a:after {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	margin: auto;
	width: 0%;
	content: ".";
	color: transparent;
	background: #c68d3b;
	height: 2px;
}

nav.nav-items ul li a:hover:after {
	width: 100%;
}

.hero-heading {
	padding: 0 1em;
}

/* -------- footer section -------- */
#section-footer {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	grid-template-rows: minmax(600px, min-content);
}

.footer-img {
	background-image: url("../img/intro.jpeg");
	background-size: cover;
	background-position: center;
	max-width: 100%;
	max-height: 100%;
}

.footer-contact {
	display: flex;
	flex-direction: column;
	padding: 6em 4em 5em 4em;
	background-color: #faf5ed;
}

.footer-contact p {
	padding-bottom: 2em;
}

.contact-form {
	display: flex;
	flex-direction: column;
}

form {
	display: flex;
	flex-direction: column;
}

input {
	margin-bottom: 1em;
}

input,
textarea {
	padding: 1em;
}

.logo img {
	width: 50%;
	margin-left: 2em;
	padding: 1em 0 1em 0;
}

.social-icons {
	display: flex;
	justify-content: space-evenly;
	align-items: flex-end;
	padding-top: 5em;
}

.social-icons a i {
	font-family: "Font Awesome 5 Brands";
	font-style: normal;
	color: #c68d3b;
	font-size: 2.5em;
}

.social-icons p {
	display: flex;
	justify-self: center;
	align-items: center;
	padding-bottom: 0;
}

.copyright {
	padding: 1.5em 0;
	text-align: center;
}

/* ==========================================================================
    Mobile Styles - X page
   ========================================================================== */
/* -------- header / nav area -------- */
.nav-items ul {
	flex-direction: column;
}

/* -------- main area -------- */
/* -------- hero section -------- */
#section-hero {
	min-height: 600px;
	background-image: url("../img/hero.jpeg");
	background-size: cover;
	background-position: center;
	position: relative;
}

#section-hero .overlay {
	background: rgba(0, 0, 0, 0.7);
	position: absolute;
	height: 100%;
	width: 100%;
	top: 0;
	left: 0;
	color: white;
	letter-spacing: 0.08em;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
}

.overlay img {
	display: grid;
	grid-template-columns: 1fr;
	padding: 3em 0;
	width: 20%;
	opacity: 0.7;
}

.hero-heading img {
	padding: 5em 0;
}

/* -------- intro section -------- */
#section-intro {
	display: grid;
	grid-template-columns: 1fr;
	grid-template-rows: min-content;
}

.item-1 {
	background-image: url("../img/intro.jpeg");
	background-size: cover;
	background-position: center;
	max-width: 100%;
	max-height: 100%;
}

/* -------- services section -------- */
#section-services {
	display: grid;
	grid-template-columns: 1fr;
	grid-template-rows: min-content;
}

.item-2 {
	display: grid;
	align-content: center;
	background-color: #faf5ed;
	padding: 6em 4em 6em 4em;
}

.item-3 {
	display: grid;
	align-content: center;
	background-color: #faf5ed;
	padding: 6em 4em 6em 4em;
}

.item-4 {
	display: flex;
	justify-content: center;
	flex-flow: row wrap;
	padding: 4em 1em;
}

.service-icons {
	display: flex;
	justify-content: center;
	flex-flow: row wrap;
}

.icon {
	display: flex;
	flex-basis: 50%;
	flex-direction: column;
	text-align: center;
	margin: 2em 0;
	text-transform: uppercase;
}

.icon img {
	width: 50%;
	text-align: center;
	align-self: center;
	padding-bottom: 3em;
}

.service-description {
	font-weight: 700;
	letter-spacing: 0.09em;
}

/* -------- stats insert -------- */
.stats {
	height: min-content;
	padding: 7em 3em;
	background-color: #f0e2d6;
	text-align: center;
}

.stats h2 {
	margin-bottom: 0;
}

.stats small {
	display: inline-block;
	padding-bottom: 3em;
}

/* -------- portfolio section -------- */
#section-portfolio {
	display: grid;
	grid-template-columns: 1fr;
	padding: 8em 2em;
}

.portfolio-header {
	display: grid;
	padding-left: 5em;
	align-items: center;
}

.project-example {
	display: grid;
	align-items: center;
	justify-items: center;
	padding: 3em 0 0.5em 0;
}

.project-example a {
	display: grid;
	align-items: center;
	justify-items: center;
}

.project-example a img {
	width: 90%;
	padding-bottom: 1em;
}

/* portfolio image overlay */

/* -------- contact section -------- */
#section-footer {
	display: grid;
	grid-template-columns: repeat(1, 1fr);
	grid-template-rows: minmax(600px, min-content);
}

/* ==========================================================================
    Tablet Styles - X page
   ========================================================================== */
/*-------- Tablet Styles X Section --------*/
@media only screen and (min-width: 768px) {
	.nav-items ul {
		flex-direction: row;
	}

	h1 {
		font-size: 3em;
	}

	h2 {
		font-size: 2.5em;
	}

	h3,
	h4 {
		font-size: 1.8em;
	}

	#section-intro {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		grid-template-rows: min-content;
	}

	.overlay img {
		padding: 3em 0;
		width: 15%;
		opacity: 0.7;
	}

	#section-services {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		grid-template-rows: min-content;
	}

	.icon {
		display: flex;
		flex-basis: 50%;
		justify-content: start;
	}

	.icon img {
		width: 40%;
	}

	#section-portfolio {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
	}

	.project-example img {
		width: 80%;
		padding-bottom: 1em;
	}

	#section-footer {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		grid-template-rows: minmax(600px, min-content);
	}
}

/* ==========================================================================
    Desktop Styles - X page
   ========================================================================== */
/*-------- Desktop Styles X Section --------*/
@media only screen and (min-width: 1200px) {
	#section-services {
		display: grid;
		grid-template-columns: repeat(2, 1fr);
		grid-template-rows: min-content;
	}

	.overlay img {
		width: 10%;
	}

	.service-icons {
		display: flex;
		justify-content: center;
		flex-flow: row wrap;
	}

	.icon {
		display: flex;
		flex-basis: 30%;
		justify-content: start;
	}

	.icon img {
		width: 50%;
	}

	#section-portfolio {
		display: grid;
		grid-template-columns: repeat(3, 1fr);
	}
}

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

/*
 * Hide visually and from screen readers
 */

.hidden,
[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
 */

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

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

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

/*
 * 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: " ";
	display: table;
}

.clearfix::after {
	clear: both;
}

/* ==========================================================================
   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: #fff !important;
		color: #000 !important;
		/* Black prints faster */
		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 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:
   * https://web.archive.org/web/20180815150934/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;
	}
}
