@font-face {
	font-family: 'icomoon';
	src: url('../fonts/icomoon.eot');
	src: url('../fonts/icomoon.eot?#iefix') format('embedded-opentype'),
		url('../fonts/icomoon.woff') format('woff'),
		url('../fonts/icomoon.ttf') format('truetype'),
		url('../fonts/icomoon.svg#icomoon') format('svg');
	font-weight: normal;
	font-style: normal;
}

/* Windows Chrome ugly fix http://stackoverflow.com/questions/13674808/chrome-svg-font-rendering-breaks-layout/14345363#14345363 */
@media screen and (-webkit-min-device-pixel-ratio:0) {
	@font-face {
		font-family: 'icomoon';
		src: url('../fonts/icomoon.svg#icomoon') format('svg');
	};
}

a, li {
	-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

/* Global CSS that are applied for all screen sizes */

.nav ul {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	width: 74em;
	margin: 0 auto;
	margin-bottom: 1em;
	padding: 0;
	list-style: none;
	gap: 0.12em;
}


.nav li {
	height: 4vw;
	font-size: 0.75vw;
	border-radius: 0.8em;
	border: solid 0.27em #F1C9F3;
}

.nav a {
	display: block;
	height: 100%;
	text-align: center;
	padding-top: 1.7em;
	text-decoration: none;
	color: rgba(249, 249, 249, .9);
}



/* Hover effect for the whole navigation to make the hovered item stand out */

.no-touch .nav ul:hover a {
	color: rgba(249, 249, 249, .5);
}

.no-touch .nav ul:hover a:hover {
	color: rgba(255,255,255,0.99);
}

/* Adding some background color to the different menu items */

.nav li:nth-child(6n+1) {
	background: #6862F0;
}

.nav li:nth-child(6n+2) {
	background: #111CE0;
}

.nav li:nth-child(6n+3) {
	background:#4F0ED4;
}

.nav li:nth-child(6n+4) {
	background: #6862F0 ;
}

.nav li:nth-child(6n+5) {
	background: #111CE0;
}

.nav li:nth-child(6n+6) {
	background: #4F0ED4;
}


@media (max-width: 810px) {

	/* Size and font adjustments to make it fit into the screen*/
	.nav ul {
		width: 100%;
		font-size: 2.3vw;
	}
	.nav li {
		height: 6em;
	}
	.nav a {
		padding-top: 1em;
	}
	}

/* For screen bigger than 810px */

@media (min-width: 811px) and (max-width:1350px){

	/* Transforms the list into a horizontal navigation */
	
	.nav ul {
		width: 100%;
	}
	.nav li {
		height: 5.1em;
		text-align:center;
		font-size: 1vw;
	}

	.nav a {
		display: block;
		width: 100%;
	}

	/* hover, focused and active effects that add a little colored border to the different items */
	.no-touch .nav li:nth-child(6n+1) a:hover,
	.no-touch .nav li:nth-child(6n+1) a:active,
	.no-touch .nav li:nth-child(6n+1) a:focus {
		border-bottom: 0.1em solid rgba(182, 199, 9,1.00);
	}

	.no-touch .nav li:nth-child(6n+2) a:hover,
	.no-touch .nav li:nth-child(6n+2) a:active,
	.no-touch .nav li:nth-child(6n+2) a:focus {
		border-bottom: 0.1em solid rgba(182,199,9,1.00);
	}

	.no-touch .nav li:nth-child(6n+3) a:hover,
	.no-touch .nav li:nth-child(6n+3) a:active,
	.no-touch .nav li:nth-child(6n+3) a:focus {
		border-bottom: 0.1em solid rgba(182,199,9,1.00);
	}

	.no-touch .nav li:nth-child(6n+4) a:hover,
	.no-touch .nav li:nth-child(6n+4) a:active,
	.no-touch .nav li:nth-child(6n+4) a:focus {
		border-bottom: 0.1em solid rgba(182,199,9,1.00);
	}

	.no-touch .nav li:nth-child(6n+5) a:hover,
	.no-touch .nav li:nth-child(6n+5) a:active,
	.no-touch .nav li:nth-child(6n+5) a:focus {
		border-bottom: 0.1em solid rgba(182,199,9,1.00);
	}

	.no-touch .nav li:nth-child(6n+6) a:hover,
	.no-touch .nav li:nth-child(6n+6) a:active,
	.no-touch .nav li:nth-child(6n+6) a:focus {
		border-bottom: 0.1em solid rgba(182,199,9,1.00);
	}


	/* Animating the height of the element*/
	.nav a {
		height: 6em;
	}

	.no-touch .nav a:hover ,
	.nav a:active ,
	.nav a:focus {
		height: 6em;
	}	
}



/* The "tablet" and "mobile" version */

@media (max-width: 810px) {		
	
	/* Instead of adding a border, we transition the background color */
	.no-touch .nav ul li:nth-child(6n+1) a:hover,
	.no-touch .nav ul li:nth-child(6n+1) a:active,
	.no-touch .nav ul li:nth-child(6n+1) a:focus {
		background: rgb(227, 119, 20);
	}

	.no-touch .nav li:nth-child(6n+2) a:hover,
	.no-touch .nav li:nth-child(6n+2) a:active,
	.no-touch .nav li:nth-child(6n+2) a:focus {
		background: rgb(245, 160, 41);
	}

	.no-touch .nav li:nth-child(6n+3) a:hover,
	.no-touch .nav li:nth-child(6n+3) a:active,
	.no-touch .nav li:nth-child(6n+3) a:focus {
		background: rgb(44, 168, 219);
	}

	.no-touch .nav li:nth-child(6n+4) a:hover,
	.no-touch .nav li:nth-child(6n+4) a:active,
	.no-touch .nav li:nth-child(6n+4) a:focus {
		background: rgb(31, 120, 176);
	}

	.no-touch .nav li:nth-child(6n+5) a:hover,
	.no-touch .nav li:nth-child(6n+5) a:active,
	.no-touch .nav li:nth-child(6n+5) a:focus {
		background: rgba(138,162,23,1.00);
	}

	.no-touch .nav li:nth-child(6n+6) a:hover,
	.no-touch .nav li:nth-child(6n+6) a:active,
	.no-touch .nav li:nth-child(6n+6) a:focus {
		background: rgba(24,134,23,1.00);
	}	

}

/* CSS specific to the 2x3 columns version */

@media (min-width:20px) and (max-width: 810px) {
	
	/* Creating the 2 column layout using floating elements once again */
	.nav li {
		display: block;
		float: left;
		width: 100%;
	}
	
	/* Adding some padding to make the elements look nicer*/
	.nav a {	
		text-align: center;
	}

	/* Displaying the icons on the left, and the text on the right side using inlin-block*/
	 
	.nav li {
		display: inline-block;
		width: 100%;
	}

	.nav li {
		padding-top: 1em;
		font-size: 0.62em;
	}
	
}
