/* http://meyerweb.com/eric/tools/css/reset/ 
   v2.0 | 20110126
   License: none (public domain)
*/

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
	margin: 0;
	padding: 0;
	border: 0;
	font-size: 100%;
	font: inherit;
	vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
	display: block;
}
body {
	line-height: 1;
}
ol, ul {
	list-style: none;
}
blockquote, q {
	quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
	content: '';
	content: none;
}
table {
	border-collapse: collapse;
	border-spacing: 0;
}

strong {
	font-family: univers-bold;
}

em {
	font-family: univers-italic;
}

/* variables*/

:root {
--line-weight: 2px;

--spacing-xs: 8px;
--spacing-sm: 16px;
--spacing-md: 32px;
--spacing-lg: 64px;
--spacing-xl: 128px;
--spacing-xxl: 256px;

--spacing-case-line: var(--spacing-lg);

/* colors */
--accent: #670BDD;
--primary: #252521;
--background: #EDECEF;
--background-2: #FAFAFA;
}

/* add fonts */

@font-face{
	font-family: "univers";
	src: url("../fonts/univers.woff2") format("woff2"),url("../fonts/univers.woff") format("woff");
}

@font-face{
	font-family: "univers-bold";
	src: url("../fonts/univers-bold.woff2") format("woff2"),url("../fonts/univers-bold.woff") format("woff");
}

@font-face{
	font-family: "univers-italic";
	src: url("../fonts/univers-italic.woff2") format("woff2"),url("../fonts/univers-italic.woff") format("woff");
}

@font-face{
	font-family: "univers-light";
	src: url("../fonts/univers-light.woff2") format("woff2"),url("../fonts/univers-light.woff") format("woff");
}


/* basic atoms */

html, body {
	overflow-x: hidden;
	position: relative;
}

body {
	background-color: var(--background);
	font-family: univers;
	color: var(--primary);
	letter-spacing: 1px;
	font-size: 16px;
}

h1 {
	font-size: 40px;
	font-family: univers-bold;
}

h2 {
	font-size: 20px;
	text-transform: uppercase;
	color: var(--accent);
}

h3 {
	font-size: 20px;
	text-transform: uppercase;
	margin-bottom: 10px;
}

h4, label, input.button, button {
	font-size: 14px;
	text-transform: uppercase;
}

p, input, textarea {
	max-width: 60ch;
	line-height: 150%;
	margin-bottom: var(--spacing-md);
}

input, textarea {
	-webkit-appearance: none;
	-webkit-border-radius: 0;
	border-radius: 0;
}

li {
	max-width: 60ch;
	line-height: 150%;
}

a {
	text-decoration: none;
	color: var(--primary);
	cursor: pointer;
}

a:hover, p > a {
	color: var(--accent);
}

.arrow {
	font-size: 23px;
	position: relative;
	top: 3px;
}

svg {
	width: auto;
}

/* grid */
body {
	display: grid;
	grid-template-columns: 1fr 2fr;
	column-gap: var(--spacing-xl);
}

/* nav */

#title, #nav-block {
	margin-top: var(--spacing-md);
}

#title {
	text-align: right;
	grid-column: 1;
	grid-row: 1;
}

#nav-block {
	grid-column: 2;
	grid-row: 1;
}

#nav-block > li {
	display: inline-block;
	list-style-type: none;
	margin-right: var(--spacing-lg);
	margin-bottom: calc(var(--spacing-lg) + var(--spacing-md));
	margin-top: 0px;
	line-height: 1;
}

#active::after {
	content: "";
	display: block;
	margin-right: -8px;
	margin-left: -8px;
	padding-bottom: 10px;
	border-bottom: var(--line-weight) var(--accent) solid;
}

/* about layout*/
#about-diagram {
	text-anchor: end;
	position: relative;
	top: -50px;
	right: calc(-1 * var(--spacing-xl) + -10px); /* (was +5 at full 374px size) */
	justify-self: right;
	width: 330px !important;
}

#about-text {
	padding-left: var(--spacing-xl);
	padding-top: var(--spacing-md);
	max-width: 40ch;
}

.fade {
	opacity: 0;
	transition: opacity 3s ease;
}

/* process layout */
#process-diagram {
	position: absolute;
	top: 0px;
	left: -249px;
	/*grid-column: 1/3;
	grid-row: 3;
	margin-left: calc(33% + 2*var(--spacing-xl)/3 - 245px);*/
}

#small-process-diagram {
	display: none;
}

#process-container {
	grid-column: 2;
	grid-row: 3;
	position: relative;
	height: 200px;
}

#process-content {
	grid-column: 2;
	grid-row: 2;
	margin-bottom: var(--spacing-md);
}

text {
	fill: var(--primary);
}

.titles {
	font-size: 20px;
}




/* contact */

form {
	grid-column: 2;
}

label {
	display: block;
}

input, textarea {
	width: 400px;
	background-color: var(--background);
	margin-top: var(--spacing-xs);
	border: none;
	border-bottom: 2px solid var(--primary);
	height: calc(var(--spacing-sm) + 2px);
	padding: var(--spacing-xs);
	transition: background-color .5s ease;
	max-height: 50vh;
}

input {
	margin-bottom: var(--spacing-lg);
}

textarea {
	margin-bottom: var(--spacing-md);
}


/* alt text area styles
textarea {
	border: 2px solid var(--primary);
	border-radius: 3px;
}

*/

input:focus, textarea:focus {
	outline: none;
	border-color: var(--accent);
	background-color: var(--background-2);
	transition: background-color .5s ease;
}

input.button, button {
	background-color: var(--accent);
	border: none;
	border-radius: 3px;
	color: var(--background-2);
	padding: var(--spacing-xs) calc(var(--spacing-sm) - 2px) var(--spacing-xs) var(--spacing-sm);
	width: auto;
	height: auto;
	letter-spacing: 2px;

}

input.button:hover, button {
	background-color: var(--primary);
	cursor: pointer;
}

#contacted, #error {
	grid-column: 2;
}

#contacted > h2, #error > h2 {
	margin-bottom: var(--spacing-sm);
}

/* portfolio index layout */

.portfolio-list-category {
	text-align: right;
}

.portfolio-item {
	display: block;
	margin-bottom: 10px;
}

.portfolio-section {
	margin-bottom: 30px;
}




/* responsive */

@media (max-width: 1050px) {
	body {
		column-gap: var(--spacing-lg);
		max-width: none;
		grid-template-columns: minmax(190px,auto) 590px;
	}
}


@media (max-width: 900px) {
	#about-diagram {
		width: 300px !important;
	}

	#process-container {
		grid-column: 1/3;
		position: relative;
	}

	#process-diagram {
		width: 740px;
		margin-left: 50%;
		transform: translate(-50%, 0);
		position: static;
	}



}

/* @ 900px, adjust the svgs. 
	- process becomes vertical (next to text?)
	- about gets smaller? (or goes above text?)
*/

@media (max-width: 850px) {
	body {
		display: block;
		max-width: 100%;
	}

	#title {
		display: none;
	}

	#nav-block {
		text-align: center;
	}

	#nav-block > li:last-child {
		margin-right: 0px;
	}

	
	#about-diagram {
		margin-left: 50%;
		transform: translate(-50%, 0);
		position: static;
	}

	#about-text {
		padding-left: 0px;
		margin: auto;
	}

	#nav-block > li.short-nav {
		margin-bottom: var(--spacing-md);
	}

	#nav-block > li {
		margin-bottom: var(--spacing-lg);
	}

	#process-content > p, #about-text > p {
		margin-left: auto;
		margin-right: auto;
	}

	#process-container {
		width: 100%;
		padding-left: var(--spacing-md);
		padding-right: var(--spacing-md);
		box-sizing: border-box;
		overflow-x: hidden;
	}

	#process-diagram {
		max-width: 100%;
	}

	.portfolio-list-category {
		text-align: left;
		margin: auto;
		width: 522px;
		margin-bottom: var(--spacing-md);
	}

	.portfolio-section {
		margin: auto;
		width: 522px;
		margin-bottom: calc(var(--spacing-lg) + var(--spacing-md));
	}

	form {
		margin: auto;
		width: fit-content;
	}

}



@media (max-width: 580px) {
	#nav-block > li {
    	margin-right: 32px;
	}

	.portfolio-list-category, .portfolio-section {
		max-width: 100%;
		padding-left: var(--spacing-md);
		padding-right: var(--spacing-md);
		box-sizing: border-box;
	}

	#process-content {
		width: 100%;
		overflow-x: hidden;
		padding-left: var(--spacing-md);
		padding-right: var(--spacing-md);
		box-sizing: border-box;
	}

	#process-content > p, #about-text > p {
		width: 100%;
	}

	#process-container {
		display: none;
	}

	#small-process-diagram {
		display: block;
		margin: auto;
	}

	#small-process-diagram + .process {
		margin-top: var(--spacing-lg);
	}
}


@media (max-width: 490px) {
	.portfolio-list-category, .portfolio-section {
		padding-left: var(--spacing-sm);
		padding-right: var(--spacing-sm);
	}
}

@media (max-width: 480px) {
	form {
		width: 100%;
		box-sizing: border-box;
		padding: 0 var(--spacing-md);
		overflow-x: hidden;
	}

	.contact {
		width: 100%;
		overflow-x: hidden;
	}

	input, textarea {
		width: 100%;
	}



}

@media (max-width: 450px) {
	#nav-block > li {
		margin-right: 16px;
	}

	#active::after {
		margin-right: 2px;
		margin-left: 2px;
	}

	h4 {
		font-size: 12px;
	}

		#process-content {
		padding-left: var(--spacing-sm);
		padding-right: var(--spacing-sm);
	}

}

@media (max-width: 350px) {
	#nav-block > li {
		margin-right: 8px;
	}
}


/*mobile should always be 1 column*/
