/* ----------------------------- PLAGUES, Ge Ricci 2015 ---------------------------- */


/* ----------------------------- RESET'N DEFALUTS ------------------------------ */
* {
	padding: 0;
	margin: 0;
}

@font-face {
	font-family: 'open_sanslight';
	src: url('opensans-light-webfont.eot');
	src: url('opensans-light-webfont.eot?#iefix') format('embedded-opentype'),
	url('opensans-light-webfont.woff2') format('woff2'),
	url('opensans-light-webfont.woff') format('woff'),
	url('opensans-light-webfont.ttf') format('truetype'),
	url('opensans-light-webfont.svg#open_sanslight') format('svg');
	font-weight: normal;
	font-style: normal;
}

@font-face {
	font-family: 'open_sansbold';
	src: url('opensans-bold-webfont.eot');
	src: url('opensans-bold-webfont.eot?#iefix') format('embedded-opentype'),
	url('opensans-bold-webfont.woff2') format('woff2'),
	url('opensans-bold-webfont.woff') format('woff'),
	url('opensans-bold-webfont.ttf') format('truetype'),
	url('opensans-bold-webfont.svg#open_sansbold') format('svg');
	font-weight: normal;
	font-style: normal;
}

@font-face {
	font-family: 'open_sansregular';
	src: url('opensans-regular-webfont.eot');
	src: url('opensans-regular-webfont.eot?#iefix') format('embedded-opentype'),
	url('opensans-regular-webfont.woff2') format('woff2'),
	url('opensans-regular-webfont.woff') format('woff'),
	url('opensans-regular-webfont.ttf') format('truetype'),
	url('opensans-regular-webfont.svg#open_sansregular') format('svg');
	font-weight: normal;
	font-style: normal;
}


body {
	font: 100%/1 open_sanslight, "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}

h1 {
	font: 3em/1 open_sansbold, "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
	text-transform: uppercase;
	color: #333;
	background: #FFF;
	margin-top: 4rem;
}

img {max-width: 100%; border: none;}

/* ---------------------------------- STRUCTURAL BLOCKS ------------------------------------- */

#container {max-width: 1430px; margin: 5vw 5% 2vw;}

div.the-canvas {}

header {
	position: relative;
	overflow: hidden;
	margin-bottom: 2rem;
}

#mySVG {border: 1px solid #CCC;}

footer {
	text-align: center;
	padding: 0 5% 1rem;
}
p.copyright {
	font-size: 0.7em;
	line-height: 1.4;
	margin-top: 1rem;
}

	footer li {
		display: inline-block;
		position: relative;
		list-style-type: none;
		font-size: 0.8em;
	}

		footer li + li::before {
			content: "";
			display: inline-block;
			width: 0.5em;
			height: 0.5em;
			background-color: #000;
			margin: 0 0.7em 0 0.5em;
		}

/* ---------------------------------- KEYFRAMES ------------------------------------- */

/* RELOAD */

@keyframes emerge {
	0% {bottom: -5em;}
	100% {bottom: 0;}
}
@-webkit-keyframes emerge {
	0% {bottom: -5em;}
	100% {bottom: 0;}
}

@keyframes to-rotate {
	0% {transform-origin:center; transform: rotate(0deg);}
	100% {transform-origin:center; transform: rotate(360deg);}
}
@-webkit-keyframes to-rotate {
	0% {-webkit-transform: rotate(0deg);}
	100% {-webkit-transform: rotate(360deg);}
}

/*  GREED */
@keyframes appearing {
	0% {fill-opacity: 0.3; fill: #333;}
	50% {fill-opacity: 1; fill: #333;}
	100% {fill: #C00;}
}
@-webkit-keyframes appearing {
	from {fill-opacity: 0.3; fill: #333;}
	to {fill-opacity: 1; fill: #C00;}
}

@keyframes fading {
	from {fill-opacity: 1;}
	to {fill-opacity: 0.2;}
}
@-webkit-keyframes fading {
	from {fill-opacity: 1;}
	to {fill-opacity: 0.2;}
}

/* FEAR */
@keyframes growingF {
	from {opacity: 0;}
	to {transform: scale(6) translate(85px, 30px) rotate(25deg); opacity: 1;}
}

@-webkit-keyframes growingF {
	from {opacity: 0;}
	to {transform: scale(6) translate(85px, 30px) rotate(25deg); opacity: 1;}
}

@keyframes pulse {
  0%, 50%, 100% {
    opacity: 1;
	stroke-width: 10px;
  }

  25%, 75% {
    opacity: 0;
	stroke-width: 0;
  }
  100% {stroke: #b4cee1; fill: #b4cee1;}
}
@-webkit-keyframes pulse {
  0%, 50%, 100% {
    opacity: 1;
	stroke-width: 10px;
  }

  25%, 75% {
    opacity: 0;
	stroke-width: 0;
  }
  100% {stroke: #b4cee1; fill: #b4cee1;}
}

@keyframes interference {
	0%, 50%, 100% {transform: scaleX(5) translateX(53px);}
	25%, 75% {transform: translateX(0);}
	100% {transform: scaleX(0.5) skewX(2deg);}
}
@keyframes interference2 {
	0%, 50%, 100% {transform: translateX(5px);}
	25%, 75% {transform: translateX(0);}
	100% {transform: skewX(-1deg);}
}
@keyframes interference3 {
	0%, 50%, 100% {transform: translateX(15px);}
	25%, 75% {transform: translateX(0);}
	100% {transform: skewX(0.5deg);}
}

@-webkit-keyframes interference {
	0%, 50%, 100% {-webkit-transform: translateX(53px);}
	25%, 75% {-webkit-transform: translateX(0);}
	100% {-webkit-transform: skewX(2deg);}
}
@-webkit-keyframes interference2 {
	0%, 50%, 100% {-webkit-transform: translateX(5px);}
	25%, 75% {-webkit-transform: translateX(0);}
	100% {-webkit-transform: skewX(-1deg);}
}
@-webkit-keyframes interference3 {
	0%, 50%, 100% {-webkit-transform: translateX(15px);}
	25%, 75% {-webkit-transform: translateX(0);}
	100% {-webkit-transform: skewX(0.5deg);}
}


/* ---------------------------------- GENERAL ELEMENTS ------------------------------------- */

/* Page data */
dl {
	word-spacing: .125em;
	color: #888;
	background: #FFF;
}

dt {font-size: 0.7em; text-transform: uppercase;}
dd {
	font: 0.8em/1.5 open_sansregular, "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
	text-transform: uppercase;
	color: #444;
}


/* Reload Button */

ul.control {
	position: absolute;
	display: flex;
	width: auto;
	right: 0;
	bottom: -15rem;
	list-style-type: none;
	font-size: 0.8em;
	animation: 2s ease;
	animation-delay: 6s;
	animation-fill-mode: forwards;
	animation-name: emerge;
}

	ul.control li {text-align: center; margin-left: 1rem;}

	ul.control a, ul.control a:visited {
		overflow: hidden;
		display: inline-block;
		width: 32px;
		height: 32px;
		text-indent: -50em;
	}
	ul.control li.previous a {
		background: url(../imgs/previous.svg) 0 0 no-repeat;
		margin: 0 10% 0.5em 0;
	}
	ul.control li.next a {
		background: url(../imgs/next.svg) 0 0 no-repeat;
		margin: 0 0 0.5em 0;
	}

#to-restart {
	overflow: hidden;
	display: block;
	width: 32px;
	height: 32px;
	text-indent: -10em;
	background: transparent url(../imgs/reload.svg) no-repeat;
	margin-bottom: 0.5rem;
	border: none;
	cursor: pointer;
	opacity: .5;
	-webkit-animation: 3s ease;
	-moz-animation: 3s ease;
	-ms-animation: 3s ease;
	-o-animation: 3s ease;
	animation: 3s ease;
	-webkit-animation-delay: 6s;
	-ms-animation-delay: 6s;
	-moz-animation-delay: 6s;
	-o-animation-delay: 6s;
	animation-delay: 6s;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: to-rotate;
	-moz-animation-name: to-rotate;
	-ms-animation-name: to-rotate;
	-o-animation-name: to-rotate;
	animation-name: to-rotate;
}

#num2 ul.control {
	-webkit-animation-delay: 5s;
	-ms-animation-delay: 5s;
	-moz-animation-delay: 5s;
	-o-animation-delay: 5s;
	animation-delay: 5s;
}

#num2 #to-restart {
	-webkit-animation-delay: 6s;
	-ms-animation-delay: 6s;
	-moz-animation-delay: 6s;
	-o-animation-delay: 6s;
	animation-delay: 6s;
}

#num3 ul.control {
	-webkit-animation-delay: 2s;
	-ms-animation-delay: 2s;
	-moz-animation-delay: 2s;
	-o-animation-delay: 2s;
	animation-delay: 2s;
}
#num3 #to-restart {
	-webkit-animation-delay: 3s;
	-ms-animation-delay: 3s;
	-moz-animation-delay: 3s;
	-o-animation-delay: 3s;
	animation-delay: 3s;
}


/* ---------------------------------- P1: GREED ------------------------------------- */

#theone {
	-webkit-animation: 10s ease;
	-moz-animation: 10s ease;
	-ms-animation: 10s ease;
	-o-animation: 10s ease;
	animation: 10s ease;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: appearing;
	-moz-animation-name: appearing;
	-ms-animation-name: appearing;
	-o-animation-name: appearing;
	animation-name: appearing;
}

.animated {
	-webkit-animation: .1s ease;
	-moz-animation: .1s ease;
	-ms-animation: .1s ease;
	-o-animation: .1s ease;
	animation: .1s ease;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: fading;
	-moz-animation-name: fading;
	-ms-animation-name: fading;
	-o-animation-name: fading;
	animation-name: fading;
}


/* ---------------------------------- P2: FEAR ------------------------------------- */

#fear {
	-webkit-animation: 5s ease;
	-moz-animation: 5s ease;
	-ms-animation: 5s ease;
	-o-animation: 5s ease;
	animation: 5s ease;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: growingF;
	-moz-animation-name: growingF;
	-ms-animation-name: growingF;
	-o-animation-name: growingF;
	animation-name: growingF;
}
#afraid {
	stroke-width: 10px;
	stroke: #F90;
	-webkit-animation: 2s ease;
	-moz-animation: 2s ease;
	-ms-animation: 2s ease;
	-o-animation: 2s ease;
	animation: 2s ease;
	-webkit-animation-delay: 1s;
	-ms-animation-delay: 1s;
	-moz-animation-delay: 1s;
	-o-animation-delay: 1s;
	animation-delay: 1s;
	-webkit-animation-iteration-count: 2;
	-moz-animation-iteration-count: 2;
	-ms-animation-iteration-count: 2;
	-o-animation-iteration-count: 2;
	animation-iteration-count: 2;
	-webkit-animation-fill-mode: both;
	-moz-animation-fill-mode: both;
	-o-animation-fill-mode: both;
	-ms-animation-fill-mode: both;
	animation-fill-mode: both;
	-webkit-animation-name: pulse;
	-moz-animation-name: pulse;
	-ms-animation-name: pulse;
	-o-animation-name: pulse;
	animation-name: pulse;
}


/* ---------------------------------- P3: IGNORANCE ------------------------------------- */

#myrect-8 {
	-webkit-animation: .5s ease;
	-moz-animation: .5s ease;
	-ms-animation: .5s ease;
	-o-animation: .5s ease;
	animation: .5s ease;
	-webkit-animation-delay: 1s;
	-ms-animation-delay: 1s;
	-moz-animation-delay: 1s;
	-o-animation-delay: 1s;
	animation-delay: 1s;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: interference;
	-moz-animation-name: interference;
	-ms-animation-name: interference;
	-o-animation-name: interference;
	animation-name: interference;
}
#myrect-2 {
	-webkit-animation: .2s ease;
	-moz-animation: .2s ease;
	-ms-animation: .2s ease;
	-o-animation: .2s ease;
	animation: .2s ease;
	-webkit-animation-delay: 3s;
	-ms-animation-delay: 3s;
	-moz-animation-delay: 3s;
	-o-animation-delay: 3s;
	animation-delay: 3s;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: interference2;
	-moz-animation-name: interference2;
	-ms-animation-name: interference2;
	-o-animation-name: interference2;
	animation-name: interference2;
}
#myrect-6 {
	-webkit-animation: .2s ease;
	-moz-animation: .2s ease;
	-ms-animation: .2s ease;
	-o-animation: .2s ease;
	animation: .2s ease;
	-webkit-animation-delay: 3.5s;
	-ms-animation-delay: 3.5s;
	-moz-animation-delay: 3.5s;
	-o-animation-delay: 3.5s;
	animation-delay: 3.5s;
	-webkit-animation-fill-mode: forwards;
	-moz-animation-fill-mode: forwards;
	-o-animation-fill-mode: forwards;
	-ms-animation-fill-mode: forwards;
	animation-fill-mode: forwards;
	-webkit-animation-name: interference3;
	-moz-animation-name: interference3;
	-ms-animation-name: interference3;
	-o-animation-name: interference3;
	animation-name: interference3;
}

#num3 h1 {
	position: relative;
	top: -0.4em;
	font-size: 1.8em;
}

/* ---------------------------------- MEDIA QUERIES ------------------------------------- */

@media screen and (min-width: 920px) {

	@keyframes emerge {
		0% {bottom: -5em;}
		100% {bottom: 1rem;}
	}

	@-webkit-keyframes emerge {
		0% {bottom: -5em;}
		100% {bottom: 1rem;}
	}


	#container {display: flex; display: -webkit-flex;}

	footer {text-align: left;}

	div.the-canvas {
		flex: 2 1 80%;
		order: 1;
		-webkit-flex: 2 1 80%;
		-webkit-order: 1;
	}
	header {
		flex: 0 0 20%;
		order: 2;
		-webkit-flex: 0 0 20%;
		-webkit-order: 2;
		margin: 0 0 0 22px;
	}

	h1 {font-size: 4vmax;}
	#num3 h1 {font-size: 2.5vw;}

	ul.control {
		width: 100%;
		text-align: left;
		bottom: -5rem;
	}
}
