:root {
	--primary-color: #006400;
	--second-color: #00ff00;
	--second-alpha: #00ff0080;
	--third-color: #cccccc;
	
	--text-color: #323232;
	--border-color: #808080;

	--background-color: rgba(255, 255, 255, 0.9);
	--background-noa-color: #ffffff;
}

@media (prefers-color-scheme: dark) {
	:root {
		--text-color: #cacaca;
		--border-color: #323232;

		--background-color: rgba(0, 0, 0, 0.9);
		--background-noa-color: #000000;
	}
}

@keyframes logo {
	from {
		transform: rotate(0);
	}

	to {
		transform: rotate(360deg);
	}
}

* {
	font-size: 14pt;
	box-sizing: border-box;
	margin: 0;
	padding: 0;
	color: var(--text-color);
}

a, b, u, s, i, span, small, strong, em {
	font-size: inherit;
	color: inherit;
}

p {
	margin: 0.5rem 0.25rem;
}

.flex {
	display: flex;
	justify-content: space-around;
}

.flex.left {
	justify-content: left;
}

.flex > div, .flex > section {
	width: 100%;
	margin: 0.5rem;
}

.flex[class*="wrap"] {
	flex-wrap: wrap;
}

.flex.wrap2 > div, .flex.wrap2 > section {
	flex-basis: calc(50% - 1rem);
}

.flex.wrap3 > div, .flex.wrap3 > section {
	flex-basis: calc(33.3% - 1rem);
}

.box {
	border: 1px solid var(--border-color);
	border-radius: 0.5rem;
	box-shadow: 0 0.1rem rgba(0, 0, 0, 0.5);
	background-color: var(--background-color);
}



.box > img:first-child {
	border-radius: 0.5rem 0.5rem 0 0;
}

[onclick] {
	cursor: pointer;
}

[onclick]:hover {
	text-decoration: underline;
}

.thumb {
	width: 100%;
	height: 30vh;
	background-size: cover;
	background-repeat: no-repeat;
	background-position: top center;
	position: relative;
	transition: all 0.5s;
}

.thumb:hover {
	background-position: bottom center;
}

.thumb:active {
	background-size: contain;
}

.thumb::after {
	position: absolute;
	top: 0;
	left: 0;
	content: "";
	width: 100%;
	height: 30vh;
	display: block;
	background-image: linear-gradient(180deg, transparent 80%, var(--background-noa-color));
}

.mobile {
	display: none;
}

html {
	width: 100vw;
	height: 100vh;
	background-size: 5vh 5vh;
}

body {
	width: 99vw;
	height: 99vh;
	border: 2px solid var(--border-color);
	box-shadow: 0px 0.4vh rgba(0, 0, 0, 0.75);
	margin: 0.5vh auto;
	border-radius: 1rem;
	overflow-x: hidden;
	background-color: var(--background-color);
	position: relative;
}

img {
	width: 100%;
	height: auto;
	margin: auto;
	display: block;
}

strong {
	font-size: 1.5rem;
	font-weight: bold;
}

button {
	padding: 0 0.5rem;
	margin: 0 0.5rem;
}

select {
	margin: 0 0.5rem;
}

h2 {
	font-size: 1.8rem;
	font-weight: bold;
	text-align: center;
	position: relative;
	margin: 0.5rem 0;
}

h2::after {
	content: "";
	display: block;
	width: 100%;
	height: 5px;
	background-image: linear-gradient(90deg, transparent, var(--second-color) 10%, var(--second-color) 90%, transparent 100%);
}

h3 {
	font-size: 1.5rem;
	border: 2px solid var(--text-color);
	border-left: 0.5rem solid var(--primary-color);
	margin: 0.25rem;
	padding: 0 0.5rem;
	border-radius: 0.25rem;
	background-color: var(--background-color);
}


section h2 {
	font-size: 1.5rem;
}

section h3 {
	font-size: 1.2rem;
}

#content {
	position: absolute;
	width: 100%;
	height: calc(100% - 10vh - 2rem);
	top: 10vh;
	left: 0;
	overflow-x: hidden;
	overflow-y: scroll;
}

@media screen and (max-width: 640px) {
	.flex:not(.force) {
		display: block;
	}

	.flex > div, .flex > section {
		width: calc(100% - 1rem) !important;
	}

	#content {
		height: calc(100% - 10vh - 3.6rem);
	}

	.box.closable {
		max-height: 4.5rem;
		overflow: hidden;
		transition: all 0.2s;
	}

	.box.closable h3::before {
		content: "▽　";
	}

	.box.closable.open h3::before {
		content: "△　";
	}

	.box.closable h3 {
		text-overflow: ellipsis;
		white-space: nowrap;
		overflow: hidden;
	}

	.box.closable.open {
		max-height: 120vh;
	}

	.mobile {
		display: block;
	}
}