/* Some variables */
:root {
	--folder-width: 6em;
	--folder-height: calc(0.8 * var(--folder-width));
	--folder-deco-width: calc(var(--folder-width) / 3.5);
	--folder-cover-height: calc(0.7 * var(--folder-width));
	--folder-slip-height: calc(var(--folder-height) - var(--folder-cover-height));
	--folder-border-radius: calc(var(--folder-width) / 10);
	--folder-title-size: calc(0.16 * var(--folder-width));
	--thumb-width: calc(0.6 * var(--folder-width));
	--grid-item-padding: 3em;
}

*,
*::after,
*::before {
	-webkit-box-sizing: border-box;
	box-sizing: border-box;
}

body {
	font-family: 'Nunito Sans', sans-serif;
	color: #c8c8d0;
	background: #323437;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	counter-reset: folderstyle; 

}

a {
	text-decoration: none;
	color: #d15066;
	outline: none;
	transition: color 0.2s;
}

a:hover,
a:focus {
	color: #fff;
}

.hidden {
	position: absolute;
	overflow: hidden;
	width: 0;
	height: 0;
	pointer-events: none;
}

/* Icons */
.icon {
	display: block;
	width: 1.5em;
	height: 1.5em;
	margin: 0 auto;
	fill: currentColor;
}

.message-mobile {
	display: none;
	width: 100%;
	padding: 0.5em;
	text-align: center;
	background: #f6506c;
	color: #fff;
}

/* Header */
.codrops-header {
	display: flex;
	flex-direction: column;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	width: 100%;
	height: 100vh;
	min-height: 500px;
	padding: 1.5em 1.5em 4em;
	text-align: center;
	background: url(../img/confetti.svg) repeat center center;
}

.codrops-header__title {
	font-size: 3em;
	font-weight: 200;
	margin: 0.25em 0 0.15em;
	padding: 0 0.5em;
}

.codrops-header__tagline {
	width: 100%;
	margin: 0 0 1em;
	color: #595c62;
	font-weight: normal;
	font-size: 1.15em;
	max-width: 300px;
}

.github {
	font-weight: bold;
}

/* Top Navigation Style */
.codrops-links {
	position: relative;
	display: flex;
	justify-content: center;
	text-align: center;
	white-space: nowrap;
}

.codrops-icon {
	display: inline-block;
	margin: 0.25em 0 0.25em 0.25em;
	padding: 0.35em 0 0.35em 0.35em;
}

.codrops-icon:first-child {
	margin: 0.25em 0.25em 0.25em 0;
	padding: 0.35em 0.35em 0.35em 0;
}

/* Content */
.content {
	position: relative;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	padding: 0 0 1em;
	height: 100vh;
	min-height: 400px;
	overflow: hidden;
}

.content--info {
	position: absolute;
	top: 3em;
	left: 2.2em;
	color: #b1b1c1;
	font-size: 0.85em;
}

.content--info a:hover,
.content--info a:focus {
	color: #333;
}

.grid {
	flex: none;
	display: flex;
	flex-wrap: wrap;
	align-content: center;
	justify-content: center;
	width: calc(5 * (2 * var(--grid-item-padding) + var(--folder-width)));
}

.content::after {
	position: absolute;
	top: 0;
	left: 0;
	margin: 2em;
	counter-increment: folderstyle;
	font-weight: bold;
	content: "folder style \203A  00" counter(folderstyle);
	letter-spacing: 1px;
	font-size: 0.95em;
	color: #323437;
}

.grid__item {
	padding: var(--grid-item-padding);
}

.content__title {
	font-size: 0.85em;
	position: absolute;
	top: 18%;
	left: 2em;
	width: 5em;
	margin: 0.75em 0;
	color: #b0adad;
}

/* Folder */
.folder {
	position: relative;
	z-index: 100;
	width: var(--folder-width);
}

.folder__feedback {
	position: absolute;
	width: var(--thumb-width);
	height: var(--thumb-width);
	border-radius: 50%;
	background: #181a1c;
	top: 50%;
	left: 50%;
	margin: calc(var(--thumb-width) / -2 + var(--folder-slip-height) / 2) 0 0 calc(var(--thumb-width) / -2);
	pointer-events: none;
	opacity: 0;
}

.folder__icon {
	position: relative;
	width: 100%;
	height: var(--folder-height);
	cursor: pointer;
}

.folder__icon--perspective {
	perspective: 800px;
}

.folder__icon-img {
	backface-visibility: hidden;
	transform-origin: 50% 100%;
}

.folder__icon-img,
.folder__icon-svg {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.folder__icon--perspective .folder__icon-img,
.folder__icon--perspective .folder__icon-svg {
	transform-style: preserve-3d;
}

.folder__icon-svg {
	fill: currentColor;
}

.folder__icon-svg--deco {
	color: #76767f;
	width: var(--folder-deco-width);
	height: var(--folder-deco-width);
	top: 50%;
	left: 50%;
	margin: calc( (var(--folder-deco-width) / -2) + var(--folder-slip-height) / 2 ) 0 0 calc(var(--folder-deco-width) / -2);
}

/* Inner paper sheets */
.folder__icon-deco {
	position: absolute;
	bottom: 2px;
	left: 2px;
	width: calc(var(--folder-width) - 4px);
	height: calc(var(--folder-cover-height) - 4px);
	border-radius: var(--folder-border-radius);
	background-color: #fff;
}

.folder__preview {
	pointer-events: none;
	position: absolute;
}

.folder__preview--thumbs {
	width: var(--thumb-width);
	height: var(--thumb-width);
	top: calc((var(--folder-height) + var(--folder-slip-height)) / 2 - var(--thumb-width) / 2);
	left: calc(var(--folder-width) / 2 - var(--thumb-width) / 2);
}

.folder__preview--text {
	position: absolute;
	left: 100%;
	top: var(--folder-slip-height);
	padding: 0 2em;
	opacity: 0;
}

.folder__preview--magnifier {
	top: 50%;
	text-align: center;
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: center;
	align-content: space-between;
	left: 50%;
	background: #fff;
	width: calc(var(--thumb-width) * 5);
	height: calc(var(--thumb-width) * 5);
	margin: calc(var(--thumb-width) * 5 / -2) 0 0 calc(var(--thumb-width) * 5 / -2);
	padding: 3.5em;
	border-radius: 50%;
	opacity: 0;
}

.folder__preview--bar {
	position: fixed;
	bottom: 0;
	left: 0;
	width: 100%;
}

.folder__thumb {
	max-width: 100%;
	display: block;
	position: absolute;
	opacity: 0;
}

.folder__detail {
	margin: 0;
}

.folder__detail-svg {
	width: 2em;
	height: 2em;
	position: relative;
	fill: #ddd;
}

.folder__detail-svg--gif {
	fill: #5cc7be;
}

.folder__detail-svg--txt {
	fill: #b8d8fb;
}

.folder__detail-svg--mp3 {
	fill: #fbcf7b;
}

.folder__detail-text {
	display: block;
	font-size: 68.5%;
}

.folder__caption {
	position: relative;
	display: inline-block;
	line-height: 1.15;
	margin: 0.75em 0 0;
	font-size: var(--folder-title-size); /* dynamic font sizing depending on the folder dimension */
}

/* Dummy */
.dummy {
	position: relative;
	flex: none;
	pointer-events: none;
}

.dummy::after {
	content: '';
	position: relative;
	display: block;
	margin: 0 0.35em;
	width: calc(var(--folder-width) * 0.6);
	height: var(--folder-title-size);
	background: currentColor;
	opacity: 0.5;
}

.dummy svg {
	fill: currentColor;
	opacity: 0.3;
	display: block;
	width: var(--folder-width);
	height: var(--folder-height);
	margin-bottom: 0.75em; 
}

/* Individual styles and colors */
/* devi */

.content--devi {
	color: #c6c6d3;
	background: #f2f2f9;
}

.folder--devi .folder__icon-img--back {
	color: #8c8c99;
}

.folder--devi .folder__icon-img--cover {
	color: #adadba;
}

.folder--devi .folder__icon-img--cover,
.folder--devi .folder__icon-img--back {
	transition: color 0.15s ease;
}

.content--devi .folder__icon:hover .folder__icon-img--cover {
	color: #636372;
}

.content--devi .folder__icon:hover .folder__icon-img--back {
	color: #333;
}

.folder--devi .folder__icon-svg--deco {
	-webkit-filter: brightness(1.3);
	filter: brightness(1.3);
}

.folder--devi .folder__caption {
	color: #323437;
}

/* rudras */
.content--rudras {
	background-color: #c7ceda;
	color: #9fa7b5;
}

.content--rudras::after {
	color: #2c67cd;
}

.folder--rudras .folder__icon-img--back {
	color: #353637;
}

.folder--rudras .folder__icon-img--cover {
	color: #505153;
}

.folder--rudras .folder__icon-svg--deco {
	color: #c7ceda;
}

.folder--rudras .folder__caption {
	color: #2c67cd;
}

/* ardra */
.content--ardra {
	background-color: #2b2d31;
	color: #4c4e52;
}

.content--ardra::after {
	color: #396fc5;
}

.folder--ardra .folder__icon-img--back {
	color: #234e91;
}

.folder--ardra .folder__icon-img--cover {
	color: #396fc5;
}

.folder--ardra .folder__icon-svg--deco {
	color: #234e91;
}

.folder--ardra .folder__caption {
	color: #396fc5;
}

/* shakti */
.content--shakti {
	background-color: #396fc5;
	color: #4f8dee;
}

.content--shakti::after {
	color: #a8e485;
}

.folder--shakti .folder__icon-img--back {
	color: #091aad;
}

.folder--shakti .folder__icon-img--cover {
	color: #061bce;
}

.folder--shakti .folder__icon-svg--deco {
	color: #091aad;
}

.folder--shakti .folder__caption {
	color: #a8e485;
}

.folder--shakti .folder__thumb {
	transform-origin: -600% 50%;
}

/* kubera */
.content--kubera {
	background-color: #41f0b0;
	color: #4ccf9f;
}

.content--kubera::after {
	color: #2d2f2f;
}

.folder--kubera .folder__icon-img--back {
	color: #121313;
}

.folder--kubera .folder__icon-img--cover {
	color: #2d2f2f;
}

.folder--kubera .folder__icon-svg--deco {
	color: #5a6f67;
}

.folder--kubera .folder__caption {
	color: #2d2f2f;	
}

/* hari */
.content--hari {
	background-color: #1198e8;
	color: #0b66d9;
}

.content--hari::after {
	color: #f9dd48;
}

.folder--hari .folder__icon-img--back {
	color: #0c1dc0;
}

.folder--hari .folder__icon-img--cover {
	color: #1025ee;
}

.folder--hari .folder__icon-svg--deco {
	color: #0e1da7;
}

.folder--hari .folder__caption {
	color: #f9dd48;	
	transition: opacity 0.2s;
}

.folder--hari .folder__icon {
	transform-origin: 50% 100%;
}

.folder--hari .folder__icon:hover + .folder__caption {
	opacity: 0;
	transition-delay: 0.3s;
}

.folder--hari .folder__feedback {
	background-color: #1198e8;	
}

/* ravi */
.content--ravi {
	background-color: #e6e6e4;
	color: #c3c3b6;
}

.content--ravi::after {
	color: #202023;
}

.folder--ravi .folder__icon-img--back {
	color: #202023;
}

.folder--ravi .folder__icon-img--cover {
	color: #3f3f45;
}

.folder--ravi .folder__icon-svg--deco {
	color: #000;
}

.folder--ravi .folder__caption {
	color: #202023;	
}

.folder--ravi .folder__feedback {
	background-color: #fff;	
}

.folder--ravi .folder__preview--thumbs {
	width: 75px;
	height: 65px;
	top: calc((var(--folder-height) + var(--folder-slip-height)) / 2 - 65px / 2);
	left: calc(var(--folder-width) / 2 - 75px / 2);
}

/* durga */
.content--durga {
	background-color: #202225;
	color: #000;
}

.content--durga::after {
	color: #75dd96;
}

.folder--durga .folder__icon-img--back {
	color: #56ac72;
}

.folder--durga .folder__icon-img--cover {
	color: #75dd96;
}

.folder--durga .folder__icon-svg--deco {
	color: #56ac72;
}

.folder--durga .folder__caption {
	color: #75dd96;
	font-family: monospace;
}

.folder--durga .folder__detail	{
	color: #f1f1f1;
	font-size: 1.15em;
	margin: 0.25em 0;
	font-family: monospace;
}

/* nandi */
.content--nandi {
	background-color: #e3f6e5;
	color: #cbd9cc;
}

.content--nandi::after {
	color: #292d28;
}

.folder--nandi .folder__icon-img--back {
	color: #caa968;
}

.folder--nandi .folder__icon-img--cover {
	color: #ddba75;
}

.folder--nandi .folder__icon-svg--deco {
	color: #caa968;
}

.folder--nandi .folder__caption {
	color: #292d28;
}

.folder--nandi .folder__detail {
	width: 33%;
}

/* Related demos */
.content--related {
	font-weight: bold;
	justify-content: center;
	min-height: 0;
	padding-bottom: 10em;
	text-align: center;
}

.content--related p:first-child {
	padding: 6em 0 2em;
}

.content--related p {
	width: 100%;
}

.media-item {
	display: inline-block;
	padding: 1em 2vw;
	vertical-align: top;
	transition: color 0.3s;
}

.media-item__img {
	max-width: 100%;
	opacity: 0.6;
	transition: opacity 0.3s;
}

.media-item:hover .media-item__img,
.media-item:focus .media-item__img {
	opacity: 1;
}

.media-item__title {
	font-size: 1em;
	margin: 0;
	padding: 0.5em;
}

@media screen and (max-width: 42em) {
	.dummy {
		opacity: 0;
	}
	.codrops-header {
		height: auto;
		min-height: 0;
		padding: 12.5vh 0.5em;
	}
	.codrops-header__title {
		font-size: 1.5em;
	}
	.message-mobile {
		display: block;
	}
}
