@import url('https://fonts.googleapis.com/css?family=PT+Serif');
@import url('https://fonts.googleapis.com/css?family=Open+Sans');

:root {
	--title-color: #247b99;
}

* {
	vertical-align: top;
	box-sizing: border-box;
}

body {
	margin: 0;
	font-family: "Open Sans", Helvetica, sans-serif;
	background-color: white;
	color: black;
	text-align: justify;
}

header {
	font-size: 0;
	height: 300px;
	margin-bottom: 60px;
}
header > div {
	width:100%;
}
main, div.content {
	display: flex;
	flex-direction: row-reverse;
}
section {
	flex-basis: 75%;
	padding: 0 2% 0 4%;
}
aside {
	min-width: 400px;
	flex-basis: 25%;
	padding: 0 1%;
}

.droite {
	position: absolute;
	top:0;
	right:0;
	text-align: right;
}
.gauche {
	position: absolute;
	top:0;
	right:0;
	text-align: left;
}


.square-line > div {
	display:inline-block;
	background-color: var(--title-color);
}
.fill1 {
	width: 100px;
	height: 100px;
	margin: 0;
	opacity: 0.75;
}
.fill2 {
	width: 66px;
	height: 66px;
	margin: 16.5px;
	opacity: 0.6;
}
.fill3 {
	width: 40px;
	height: 40px;
	margin: 30px;
	opacity: 0.4;
}
.fill4 {
	width: 20px;
	height: 20px;
	margin: 40px;
	opacity: 0.2;
}

h1 {
	position: relative;
	z-index: 1;
	padding: 110px 0 0 0;
	font-size: 4rem;
	text-align: center;
	color: var(--title-color);
	font-family: 'PT Serif', serif;
	width: 50%;
	line-height: 100%;
	margin: 0 auto;
	font-weight: bold;
	transform: scale(1, 1.15);
}
h2 {
	font-size: 2rem;
	color: var(--title-color);
	font-family: 'PT Serif', serif;
	letter-spacing: 1px;
	margin: 60px 20px 20px 0;
	padding: 30px 0 0;
	border-top: 1px solid #ccc;
	position: relative;
}
h2:before {
	content: "";
	width: 40px;
	height: 40px;
	display: inline-block;
	background-color: var(--title-color);
	opacity: 0.4;
	position: absolute;
	top: 12px;
	left: -27px;
}
h2:after {
	content: "";
	width: 25px;
	height: 25px;
	display: inline-block;
	background-color: var(--title-color);
	opacity: 0.2;
	position: relative;
	top: 13px;
	left: -7px;
}
h2:first-of-type {
	border-top: none;
	padding: 0;
	margin-top: 0;
}
h2:first-of-type:before {
	top: -18px;
}
h3 {
	font-size: 1.5rem;
	color: #555;
	font-family: 'PT Serif', serif;
	letter-spacing: 1px;
	margin: 40px 0 20px 0;
}
p {
	line-height: 2;
	margin: 0 0 1em;
}

img {
	max-width: 100%;
}

.icons {
	margin: 1.5em 0 0;
}
.icons a {
	display: inline-block;
	text-decoration: none;
	margin: 0 2em;
}
.icons a:hover {
	text-decoration: none;
}
.icons a svg {
	display: inline-block;
	height: 3em;
	fill: var(--title-color);
	transition: fill 0.3s;
}
.icons a svg:hover {
	fill: #ccc;
}
body.dark .icons svg {
	fill: white;
}
body.dark .icons svg:hover {
	fill: var(--title-color);
}

ul.list-images {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-around;
	margin: 40px 0 -20px;
	padding: 0 40px;
}
ul.list-images li {
	width: 30%;
	overflow: hidden;
	background-color: rgba(225, 225, 225);
	list-style: none;
	border: solid 1px #ccc;
	margin-bottom: 40px;
}
ul.list-images li.nomargin {
	margin-bottom: 0;
}
ul.list-images a {
	opacity: 0.85;
	transition: all .5s;
}
ul.list-images a img {
	opacity: 0.75;
	transition: all .5s;
}
ul.list-images a:hover img {
	transform: scale(1.05);
	opacity: 0.7;
}
ul.list-images figure {
	margin: 0;
	padding: 0;
	cursor: pointer;
	position: relative;
}
ul.list-images figure img {
	opacity: 0.85;
	transition: all .5s;
}
ul.list-images figure figcaption {
	text-align: center;
	background-color: rgba(255, 255, 255, 0.75);
	transition: all .5s;
	position: absolute;
	bottom: 0;
	width: 100%;
	height: 42px;
}
ul.list-images figure:hover img {
	transform: scale(1.05);
	opacity: 0.7;
}

/* Default display for screens between 1450 & 1700 px width */
ul.list-images figure figcaption h4 {
	font-size: 1.1em;
	font-family: 'PT Serif', serif;
	color: #333;
	margin: 5px 0;
	line-height: 1.5;
}
ul.list-images figure figcaption p {
	line-height: 1.75;
	margin: 0 3%;
	font-size: 0.8em;
}
ul.list-images figure.selected figcaption {
	height: 100%;
	background-color: rgba(255, 255, 255, 0.9);
}

a, a:hover, a:focus {
	text-decoration: underline;
	text-decoration-style: dashed;
	color : #555;
}
a:hover, a:focus {
	color : #888;
}

ul {
	margin-bottom: 20px;
}
li {
	line-height: 2;
}
ol li {
	list-style: none;
}

nav {
	width: 100%;
}
nav a:hover, nav a:focus {
	color: inherit;
	text-decoration: none;
}
nav ol {
	border-top: 1px solid #ccc;
	border-left: 1px solid #ccc;
	border-radius: 4px;
	padding: 0;
	margin: 0 0 0 10px;
	background-color: rgba(81, 143, 171, 0.07);
}
nav ol li {
	border: 1px solid #ccc;
	border-top: none;
	border-left: none;
	cursor:pointer;
}
nav ol li:last-child {
	border-radius: 0 0 4px 4px; 
}
nav ol li.col {
	display: inline-block;
	width: 50%;
	border-left: none;
}
nav ol li.active {
	background-color: rgba(36, 123, 153, 0.2);
}
nav ol li:hover {
	background-color: #ccc;
}
nav ol li a {
	padding: 14px;
	display: inline-block;
	color: #333;
	text-decoration: none;
	width: 100%;
	height: 100%;
}
nav.sticky {
	position: fixed;
	min-width: calc(400px - 2%);
	width: 23%;
	top: 60px;
	right: 1%;
}

footer {
	background-color: #ccc;
	color: #333;
	margin-top: 60px;
	padding: 30px 4%;
	font-size: 0.85rem;
}
footer > *:last-child {
	margin-bottom: 0;
}

#dark-toggle {
	position: fixed;
	bottom: 4%;
	right: 2%;
}
#dark-toggle input[type=checkbox]{
	height: 0;
	width: 0;
	visibility: hidden;
}
#dark-toggle label {
	cursor: pointer;
	text-indent: -9999px;
	width: 64px;
	height: 32px;
	background: var(--title-color);
	display: inline-block;
	border-radius: 32px;
	position: relative;
}
#dark-toggle label:after {
	content: '';
	position: absolute;
	top: 4px;
	left: 4px;
	width: 24px;
	height: 24px;
	background: #fff;
	border-radius: 24px;
	transition: 0.3s;
}
#dark-toggle input:checked + label:after {
	background: #aaa;
}
#dark-toggle input:checked + label {
	background: white;
}
#dark-toggle input:checked + label:after {
	left: calc(100% - 5px);
	transform: translateX(-100%);
}
#dark-toggle svg {
	display: inline-block;
	width: 32px;
	margin-left: 10px;
	fill: var(--title-color);
}
body.dark #dark-toggle svg {
	fill: white;
}

/* NIGHT MODE */
body.dark {
	background-color: black;
	color:white;
}
body.dark h3 {
	color:#aaa;
}
body.dark a {
	color: #aaa;
}
body.dark a:hover {
	color: #ccc;
}
body.dark nav ol li a {
	color: #ccc;
}
body.dark nav ol li:hover {
	background-color: #333;
}
body.dark footer {
	color: #ccc;
	background-color: #333;
}
body.dark ul.list-images li {
	border-color: #333;
}
body.dark ul.list-images figure figcaption {
	background-color: rgba(0, 0, 0, 0.75);
}
body.dark ul.list-images figure figcaption h4 {
	color: #ccc;
}
body.dark ul.list-images figure.selected figcaption {
	height: 100%;
	background-color: rgba(0, 0, 0, 0.9);
}

/* RESPONSIVE */
@media screen and (min-width: 1700px) {
	ul.list-images figure figcaption h4 {
		font-size: 1.2em;
	}
	ul.list-images figure figcaption p {
		font-size: 1em;
	}
}

@media screen and (max-width: 1700px) {
	ul.list-images li {
		width:45%;
	}
	ul.list-images figure figcaption h4 {
		font-size: 1.2em;
	}
	ul.list-images figure figcaption p {
		font-size: 1em;
	}
}

@media screen and (max-width: 1200px) {
	aside {
		min-width: 280px;
		padding: 0 1%;
	}
	nav.sticky {
		min-width: calc(280px - 2%);
	}

	header {
		height: 18vw;
	}
	h1 {
		padding: 4.5vw 0 0 0;
		width: 80%;
	}
	
	.fill1 {
		width: 6vw;
		height: 6vw;
	}
	.fill2 {
		width: 4vw;
		height: 4vw;
		margin: 1vw;
	}
	.fill3 {
		width: 2.4vw;
		height: 2.4vw;
		margin: 1.8vw;
	}
	.fill4 {
		width: 1.2vw;
		height: 1.2vw;
		margin: 2.4vw;
	}

	ul.list-images {
		display: block;
	}
	ul.list-images li {
		display: block;
		width: 100%;
		max-width: 600px;
		margin-bottom: 30px;
	}

	#dark-toggle {
		bottom: 2%;
	}
	/* #dark-toggle label {
		width: 96px;
		height: 48px;
		border-radius: 48px;
	}
	#dark-toggle label:after {
		top: 6px;
		left: 6px;
		width: 36px;
		height: 36px;
		border-radius: 48px;
	}
	#dark-toggle svg {
		width: 48px;
	} */
}

@media screen and (max-width: 800px) {
	h1 {
		font-size: 2.4rem;
	}
	aside {
		display: none;
	}
	section {
		flex-basis: 100%;
		padding-right: 4%;
	}
}