body {
	font-family: sans-serif;
	margin: 1.5em 0em;
}

#gallery {
	height: 100%;
	position: fixed;
	text-align: center;
	top: 0em;
}

#gallery,
span.project-label {
	display: none;
}

#gallery-nav,
#gallery-close,
#gallery-counter,
span.project-details {
	display: inline-block;
}

#gallery,
#gallery div.navbar,
#gallery-content {
	width: 100%;
}

span.project-label.release-date {
	background-color: #000;
}

span.project-label.c-language {
	background-color: #a00;
}

span.project-label.extension {
	background-color: #0aa;
}

span.project-label.game-maker {
	background-color: #0a0;
}

span.project-label.javascript {
	background-color: #a0a;
}

span.project-label.sdl {
	background-color: #00a;
}

span.project-label.bricklink-studio {
	background-color: #aa0;
}

span.project-label.android {
	background-color: #066;
}

span.project-label,
span.project-label > a {
	color: #eee;
}

#gallery .navbar {
	box-sizing: border-box;
	height: 3em;
}

div.author-element,
div.project-text-line {
	padding: 0.1em 0em;
}

#gallery-nav, #gallery-close {
	padding: 0.375em;
}

#gallery-close button {
	padding-top: 0.1em;
}

#gallery-nav button {
	padding-bottom: 0.1em;
}

div.author,
div.project-text,
div.project-images {
	padding-left: 2em;
}

#gallery-nav {
	position: relative;
}

#gallery-close,
#gallery-title,
#gallery-content,
#gallery img {
	position: absolute;
}

#gallery-close {
	right: 1em;
}

#gallery-title,
#gallery-counter,
#gallery button,
div.author-left {
	font-weight: bold;
}

#gallery-title {
	left: 1.5em;
	top: 0.9em;
	white-space: nowrap;
}

#gallery-counter,
#gallery button,
div.project-images img,
div.project-text-line:first-child > * {
	vertical-align: middle;
}

#gallery-counter {
	margin: 0em 1em;
}

h1 {
	margin: 1.5rem 1rem;
}

div.project-images img {
	margin: 0.5em 0.5em 0em 0em;
}

#gallery-content {
	bottom: 0em;
	top: 3em;
}

#gallery img {
	bottom: 0;
	left: 0;
	right: 0;
	top: 0;
	margin: auto;
	max-height: 100%;
	max-width: 100%;
}

#gallery button,
span.project-label {
	border-radius: 0.5em;
}

#gallery button,
div.project-images img {
	cursor: pointer;
}

h1,
#gallery button {
	font-size: 1.5em;
}

#gallery button {
	background-color: transparent;
	border: none;
	height: 1.5em;
	width: 1.5em;
	margin: 0em;
}

a:link,
a:visited {
	text-decoration: none;
}

a:hover,
a:active {
	text-decoration: underline;
}

div.author,
div.project-text {
	border-style: solid;
	border-width: 0.1em 0em;
	padding-top: 0.25em;
	padding-bottom: 0.25em;
}

div.author-left {
	float: left;
	margin-right: 1.5em;
}

div.project-text-line:first-child {
	font-size: 1.2em;
	margin-bottom: 0.25em;
}

div.project-text {
	margin-top: 1.5em;
	padding-right: 0.5em;
}

span.project-details,
span.project-label {
	font-style: italic;
}

span.project-label {
	font-size: 0.8em;
	margin: 0.125em 0.25em;
	padding: 0.25em 0.5em;
}

@media (prefers-color-scheme: light) {

	body {
		background-color: #eee;
		color: #444;
	}

	#gallery {
		background-color: rgba(0, 0, 0, 0.5);
	}

	#gallery button:hover {
		background-color: #444;
	}

	#gallery div.navbar,
	#gallery-nav,
	#gallery-close,
	div.author,
	div.project-text {
		background-color: #ddd;
	}

	#gallery button:hover {
		color: #bbb;
	}

	#gallery button {
		color: #444;
	}

	a:link,
	a:hover,
	a:active {
		color: #00c;
	}

	a:visited {
		color: #339;
	}

	span.project-details {
		color: #666;
	}

	div.author,
	div.project-text {
		border-color: #666;
	}
}

@media (prefers-color-scheme: dark) {

	body {
		background-color: #111;
		color: #bbb;
	}

	#gallery {
		background-color: rgba(0, 0, 0, 0.75);
	}

	#gallery button:hover {
		background-color: #bbb;
	}

	#gallery div.navbar,
	#gallery-nav,
	#gallery-close,
	div.author,
	div.project-text {
		background-color: #222;
	}

	#gallery button:hover {
		color: #444;
	}

	#gallery button {
		color: #bbb;
	}

	a:link,
	a:hover,
	a:active {
		color: #77f;
	}

	a:visited {
		color: #99d;
	}

	span.project-details {
		color: #999;
	}

	div.author,
	div.project-text {
		border-color: #999;
	}
}
