body {
	margin: 10px;
	padding: 0;
	text-align: center;
	background-color: #373349;
	font-family: Verdana, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

#logo {
	height: 75px;
	width: auto;
	margin: 1em auto;
}

img,
video {
	width: 100%;
	height: 500px;
	object-fit: cover;
	transform: scale(1);
	transition: all 0.3s ease-in-out;
}

details {
    margin: 0 auto 1.5em auto;
    border-radius: 10px;
    width: max-content;
    box-shadow: 0 0.5em 1em -0.1em rgba(0, 0, 0, 0.16), 0 0.5em 1em -0.1em rgba(0, 0, 0, 0.1);
    background: #585370;
    color: #FFFFFF;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    max-width: 90%;
}

details img {
	object-fit: contain;
}

summary {
    padding: 0.5em;
    cursor: pointer;
}

summary::marker {
    content: "";
}

div#info {
    padding: 0 1em 1em 1em;
    max-width: 1200px;
}

hr {
    width: 90%;
    border: 0;
    height: 1px;
    margin: 2em auto;
    display: block;
    clear: both;
    background-image: -webkit-linear-gradient(0deg, transparent, #7c7796, transparent);
}

hr:first-of-type {
    height: 2px;
    background-image: -webkit-linear-gradient(0deg, transparent, #e84e4e, transparent);
}

ul {
    width: max-content;
    max-width: 90%;
    text-align: left;
    margin: 1em auto;
    line-height: 1.5em;
}

li.spicy {
    margin: 0;
}

li.spicy .censored {
    background: black;
    display: flex;
    position: relative;
}

li.spicy .censored::before {
    content: "[Enable NSFW mode to view]";
    position: absolute;
    top: calc(50%);
    left: calc(50%);
    transform: translate(-50%, -50%);
    text-align: center;
}

li.spicy .censored ul {
    visibility: hidden;
}

li.spicy .uncensored ul {
	visibility: visible;
}

li.spicy ul {
    margin: 0;
    padding-inline-start: 0;
    list-style-type: "🌶️ ";
    max-width: 100%;
}

/*.spicy {
	display: none;
}

.spicy::marker {
	content: "🌶️ ";
}*/

#container {
	display: grid;
	grid-gap: 10px;
	grid-auto-flow: dense;
}

@media (max-width: 669px) {
	#container {
		grid-template-columns: repeat(4, 1fr);
		grid-auto-rows: calc(25vw - 10px);
	}
}

@media (min-width: 670px) {
	#container {
		grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
		grid-auto-rows: 100px;
	}
}

.entry.square {
	grid-row: span 2;
	grid-column: span 2;
}

.entry.wide {
	grid-row: span 2;
	grid-column: span 4;
}

.entry.tall {
	grid-row: span 4;
	grid-column: span 2;
}

.wrapper {
	width: 100%;
	height: 100%;
	overflow: hidden;
	border-radius: 6px;
	box-shadow:
		rgba(255, 255, 255, 0.2) 0px 0px 0px 1px inset,
		rgba(0, 0, 0, 0.9) 0px 0px 0px 1px;
}

.wrapper .image {
	width: 100%;
	height: 100%;
	overflow: hidden;
	display: block;
}

.wrapper .image img,
.wrapper .image video {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 50% 50%;
	cursor: pointer;
	transition: .5s ease-in-out;
}

.wrapper .text {
	z-index: 1;
	position: absolute;
	top: 0;
	left: 0;
	white-space: nowrap;
	display: none;
	padding: 1rem;
	background: #fff;
	font-weight: 400;
	margin-top: 1.25rem;
	margin-left: -2rem;
	text-align: left;
	border: 2px solid black;
}

.wrapper .text h2 {
	margin-top: 0;
	padding-top: 0;
}

.wrapper:hover .image img,
.wrapper:hover .image video {
	transform: scale(1.05);
}

.wrapper:hover .text {
	display: block;
}

.nsfw {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2em;
	color: white;
	background-color: black;
	user-select: none;
	cursor: pointer;
}

.nsfw_switch {
	margin: 0 auto 1.5em auto;
	padding: 0;
	position: relative;
	border: none;
	height: 1.5rem;
	width: 3rem;
	border-radius: 1.5rem;
	color: #6b7381;
	background-color: #74d881;
	transition: background-color 0.25s;
	display: block;
}

.nsfw_switch:before,
.nsfw_switch:after {
	line-height: 1.5rem;
	width: 4rem;
	text-align: center;
	font-weight: 600;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 2px;
	position: absolute;
	bottom: 0;
	transition: opacity 0.25s;
}

.nsfw_switch:before {
	content: "SFW";
	left: -4rem;
}

.nsfw_switch:after {
	content: "NSFW";
	right: -4rem;
	opacity: 0.5;
}

.nsfw_switch > .thingo {
	position: absolute;
	top: 0.1875rem;
	left: 0.1875rem;
	width: 1.125rem;
	height: 1.125rem;
	border-radius: 1.125rem;
	background: #fff;
	transition: left 0.25s;
}
.nsfw_switch.activated > .thingo {
	left: 1.6875rem;
	transition: left 0.25s;
}

.nsfw_switch.activated:before {
	opacity: 0.5;
}

.nsfw_switch.activated:after {
	opacity: 1;
}

.nsfw_switch:before {
	color: #74d881;
}

.nsfw_switch:after {
	color: #e84e4e;
}

.nsfw_switch.activated {
	background-color: #e84e4e;
}