
@font-face {
	font-family: "Minecraft";
	src: url("fonts/Minecraft.woff2") format("woff2"), 
		url("fonts/Minecraft.woff") format("woff"),
		url("fonts/Minecraft.ttf") format("truetype");
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

body {
	font-family: "Minecraft", Helvetica, sans-serif;
	font-size: 1.2rem;
	text-wrap: balance;
	color: #d0c5e6;
	background-image: url("backgrounds/moondust.png");
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
	background-attachment: fixed;
	scrollbar-color: #9D72ED #27104E;
	margin: 0;
	padding: 0;
	overflow: hidden;
}

/* global */
* {
	padding:0;
	box-sizing: border-box;
}

img { /* No img drag & No highlight */
	user-select: none;
	-ms-user-select:none;
	-moz-user-select: none;
	-webkit-user-drag: none;
	-webkit-user-select: none;
}

a {
	color: lightblue;
}
a:hover {
	color: white;
}

.title { margin-top: 0.1em; }

.dust { position: fixed; }

.dust * {
	top: 0;
	left: 0;
	position: absolute;
	display: none;
}

@keyframes dust {
	from {
		top: 0vh;
		opacity: var(--opacity-start);
		transform: rotate(var(--rotation-start));
		scale: var(--scale-start);
		left: var(--position-start)
	}
	to {
		top: 100vh;
		opacity: var(--opacity-end);
		transform: rotate(var(--rotation-end));
		scale: var(--scale-end);
		left: var(--position-end);
	}
}

/* layout */
.topbar {
	color: #d0c5e6;
	background-color: #27104E;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: left;
	overflow: hidden;
}

.sidebar-toggle {
	color: #9D72ED;
	background-color: transparent;
	height: 90%;
	aspect-ratio: 1;
	border: none;
	cursor: pointer;
}

.moondust-logo {
	height: 90%;
	width: auto;
}
.moondust-logo:hover { animation: tada 0.5s;}

.moondust-title { padding-left: 0.4em; }

.sidebar {
	font-size: calc(var(--sidebar-size) / 10);
	position: fixed;
	display: flex;
	flex-direction: column;
	background-color: #27104e;
	gap: clamp(0.3em, 2.7vh, 0.9em);
	padding-top: 0.5em;
	padding-bottom: 0.3em;
	padding-left: 1.2em;
	opacity: 0.8;
	overflow-y: auto;
}

.sidebar a {
	text-decoration: none;
	color: #d0c5e6;
	transition: color 0.3s;
}
.sidebar a:hover {
	color: #7c5ca1;
}

.bottombar {
	font-size: 0.75em;
	text-align: center;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color:#27104E;
}

.bottombar p { margin: 0;}

.content {
	scrollbar-gutter: stable both-edges;
	padding: 0.8em;
	overflow: auto;
}

/* home */
.discord {
	position: absolute;
	right: 0;
	bottom: 0;
}

.content:has(.home) {
	display:flex;
	justify-content: center;
	align-items: center;
}

.home {
	position: relative;
	background-color: rgb(46, 46, 46, .5);
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap:  0.3em;
	border: 0.3em solid #27104e;
	width: 50%;
	height: 12em;
	margin-bottom: 3.4em;
}

.home h3 {
	font-size: 2em;
	color: #9D72ED;
	text-shadow: 5px 5px black;
	margin: 0;
}

.home p {
	font-size: 1.2em;
	color: white;
	text-shadow: 5px 5px black;
	margin: 0;
}

.ip {
	text-align: center;
	margin: 0;
	user-select: none;
	cursor: pointer;
}

.link-box {
	display: flex;
	flex-direction: row;
	justify-content: center;
	align-items: center;
	gap: 0.2em;
	width: 100%;
}

.link-box a:hover {
	animation: tada 0.5s;
}

/* staff */
body:has(.staff-page) .background {
	position: fixed;
	background-image: url(backgrounds/staff.png);
	background-size: cover;
	background-position: top center;
	background-repeat: no-repeat;
	top: var(--topbar-size);
	bottom: var(--bottombar-size);
	left: 0;
	right: 0;
}

.content:has(.staff-page) { background-color: rgba(0, 0, 0, 0.2); }

.staff-page {
	text-align: center;
	word-wrap: normal; /* For older browsers */
	overflow-wrap: normal; /* For newer browsers */
	text-shadow:
		-1px -1px 0 #27104E,
		 1px -1px 0 #27104E,
		-1px  1px 0 #27104E,
		 1px  1px 0 #27104E;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(22em, 100%), 1fr));
	gap: 2em;
	padding-top: 0.3em;
}

.staff-member h1, .staff-member h2 { margin: 0; }

.staff-member h3 {
	text-wrap: balance;
	hyphens: auto;
}

.staff-member img {
	height: 2em;
	display: block;
	margin: 0 auto;
}

/* maps */
.map {
	text-align: center;
	color: #8e69b9;
	background-color: #27104E;
	background-size:cover;
	background-repeat: no-repeat;
	background-position: center;
	border: 0.2em #27104e solid;
	padding: 4.5em 0.5em;
	margin: 1em 0;
	text-shadow:
		-1px -1px 0 #3b1b72,
		 1px -1px 0 #3b1b72,
		-1px  1px 0 #3b1b72,
		 1px  1px 0 #3b1b72,
		 2px  2px 0 transparent;
	transition: color 0.3s, text-shadow 0.3s;
}
.map:hover {
	color: #9d76ca;
	text-shadow:
		-1px -1px 0 #27104E,
		 1px -1px 0 #27104E,
		-1px  1px 0 #27104E,
		 1px  1px 0 #27104E,
		 2px  2px 0 rgba(0, 0, 0, 0.3);
}

.map#survival {
	background-image:url(backgrounds/survival.png);
	margin-top: 0;
}

.map#skyblock {
	background-image:url(backgrounds/skyblock.png);
}

.map#creative {
	background-image:url(backgrounds/creative.png);
}

.map#tiny {
	background-image:url(backgrounds/tiny.png);
	margin-bottom: 0;
}

/* newsletters and other button lists */
.list-box {
	display: flex;
	flex-direction: column;
	gap: 0.17em;
	width: auto;
	padding: 0;
	margin: 0;
 }

 .list-button {
	color: #d0c5e6;
	text-decoration: none;
	text-align: center;
	background-color: #27104E;
	display: block;
	border: 0.3em solid #180a30;
	border-radius: 0.25em;
	width: 13.7em;
	padding: 0.3%;
	margin: 0;
	transition: color 0.5s;
}
.list-button:hover { color: #7c5ca1; }

/* newsletter */
.newsletter {
	font-size: 1rem;
	border: none;
	width: 100%;
}

.content:has(.newsletter) {
	display: flex;
	top: calc(var(--topbar-size) - 42px) !important;
	padding: 0;
}

/* events */
.image-box {
	display: grid;
	grid-template-columns: repeat(auto-fit, min(22em, 100%));
	gap: 0.7em;
}

.image-box img {
	background-color: black;
	border: 0.2em double #3b1b72;
	border-radius: 0.15em;
	width: 100%;
}

/* misc */
.application {
	border: none;
	width: 60%;
	height: 100%;
}

body:has(.about) { background-image: url(backgrounds/about.png); }
.content.about { background-color: rgba(0, 0, 0, 0.4); }

@keyframes tada {
	from {
		transform: scale3d(1, 1, 1);
	}

	10%, 20% {
		transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
	}

	30%, 50%, 70%, 90% {
		transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
	}

	40%, 60%, 80% {
		transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
	}

	to {
		transform: scale3d(1, 1, 1);
	}
}

@media (max-width: 900px) { /* tablet */
	.application { width: 100%; }
	.home { width: 65%; }
}

@media (max-width: 600px) { /* phone */
	.home { width: 90%; }
}

@media (max-height: 40rem) {
	.sidebar { justify-content: center; }
}