html * {box-sizing: border-box;}

:root {
	--headerbg: #aaa;
	--dark: #233d4d;
	--bg1: #fe7f2d;
	--bg2: #fcca46;
	--bg3: #a1c181;
	--bg4: #619b8a;
}

body {
	font-family: "Avenir Next", system-ui, sans-serif;
	font-size: 100%;
	line-height: 1.4rem;
	margin: 0;
	color: var(--dark);
}

body>* {padding: 0 1em;}

header {
	min-height: 50vh;
	background-color: var(--headerbg);
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}
.home header {
	background-color: var(--bg1);
}
.next header {
	background-color: var(--bg2);
}
.gallery header {
	background-color: var(--bg3);
}
.about header {
	background-color: var(--bg4);
}


h1 {
	font-size: 1.5rem;
	margin: 0;
}
h2 {
	font-size: 8vw;
	line-height: 1.1em;
}

nav {
	padding-bottom: 1em;
}

ul.toplinks {
	list-style: none;
	padding: 0;
	display: flex;
	flex-direction: column; 
	justify-content: center;
	gap: .5em;
}

.toplinks a.cr {
	pointer-events: none;
	text-decoration: none;
}

main {
	display: flex;
	flex-direction: column;
	gap: 1em;
}

.gallery section.primary {
	display: flex;
	flex-direction: row;
	justify-content: space-evenly;
	flex-wrap: wrap;
	gap: 1em;
	padding-top: 1em;
}

.gallery figure {
	background-color: var(--dark);
	height: 10em;
	width:20vw;
	margin: 0;
	color: var(--bg3);
	margin: .2em;
}


@media (min-width: 600px) { 

  main {
	flex-direction: row;
	gap: 1em;
  }
  .about main {
	flex-direction: column;
	padding: 0 20vw;
  }
  
  section.primary {flex:89;}
  section.secondary {flex:55;}
  
  ul.toplinks {
	flex-direction: row;  
    gap: 2em;
  }

}

@media (min-width: 900px) {
	body {
		display: flex;
		flex-direction: row;
		align-items: stretch;		
	}
	header {
        align-self: stretch;
	}
    
	main {
		flex-direction: column;
		overflow: auto;
	}
	footer {
		position: absolute;
		bottom: 1em;
	}
}