@font-face {
	font-family: "Computer Modern Sans";
	src: url("fonts/cmunss.woff2") format("woff2");
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Computer Modern Sans";
	src: url("fonts/cmunsx.woff2") format("woff2");
	font-weight: bold;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Computer Modern Sans";
	src: url("fonts/cmunsi.woff2") format("woff2");
	font-weight: normal;
	font-style: italic;
	font-display: swap;
}

@font-face {
	font-family: "Computer Modern Sans";
	src: url("fonts/cmunso.woff2") format("woff2");
	font-weight: bold;
	font-style: italic;
	font-display: swap;
}

@font-face {
	font-family: "MonaspiceKr NF";
	src: url("fonts/MonaspiceKrNerdFont-Regular.woff2") format("woff2");
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

:root {
	--foreground-color: black;
	--background-color: hsl(60, 75%, 75%);
	--middle-color: color-mix(
		in srgb,
		var(--foreground-color) 30%,
		var(--background-color) 70%
	);
	--link-color: hsl(240, 75%, 35%);
	--visited-link-color: hsl(300, 75%, 35%);

	font-family: "Computer Modern Sans", sans-serif;
	font-size: 18px;
	background-color: var(--background-color);
	color: var(--foreground-color);
}

body {
	margin: 0 auto;
	padding: 1.5rem;
	height: 100vh;
	box-sizing: border-box;
	width: min(100%, 80ch);

	display: flex;
	justify-content: space-between;
	flex-direction: column;
}

header {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 1rem;
	b {
		font-size: 200%;
	}
}

code {
	font-family: "MonaspiceKR NFM", monospace;
}

pre {
	padding: 1em;
}

p > code {
	background-color: var(--code);
	border-radius: 0.1em;
	box-shadow: 0 0 0 0.2em var(--code);
}

img {
	max-width: 100%;
}

a {
	color: var(--link-color);

	&:active {
		transform: scale(0.9);
	}

	&[target="_blank"]::after {
		background: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxNiAxNiIgd2lkdGg9IjE2IiBoZWlnaHQ9IjE2Ij48cGF0aCBkPSJNOSAyTDkgMyAxMi4zIDMgNiA5LjMgNi43IDEwIDEzIDMuNyAxMyA3IDE0IDcgMTQgMlpNNCA0QzIuOSA0IDIgNC45IDIgNkwyIDEyQzIgMTMuMSAyLjkgMTQgNCAxNEwxMCAxNEMxMS4xIDE0IDEyIDEzLjEgMTIgMTJMMTIgNyAxMSA4IDExIDEyQzExIDEyLjYgMTAuNiAxMyAxMCAxM0w0IDEzQzMuNCAxMyAzIDEyLjYgMyAxMkwzIDZDMyA1LjQgMy40IDUgNCA1TDggNSA5IDRaIi8+PC9zdmc+)
			no-repeat;
		background-size: contain;
		margin-left: 0.1em;
		content: "";
		width: 1em;
		height: 1em;
		display: inline-block;
		vertical-align: middle;
	}
}

footer {
	margin-top: auto;
	border-top: 1px solid var(--middle-color);
	font-size: small;
	padding-top: 0.5rem;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 1ch;
	a {
		display: contents;
	}
}
