@keyframes background-scroll {
	0% {
	background-position: 640px 480px;
	}

	100% {
		background-position: 0px 0px;
	}
}

@keyframes prophecy {
	0% {
		margin-top: 0.02em;
	}

	50% {
		margin-top: -0.02em;
	}

	100% {
		margin-top: 0.02em;
	}
}

@keyframes prophecy-color {
	0% {
		filter: hue-rotate(7deg) brightness(1.6);
		
	}

	50% {
		filter: hue-rotate(10deg) brightness(1.6);
	}

	100% {
		filter: hue-rotate(7deg) brightness(1.6);
	}
}

@keyframes prophecy-shadows {
	0% {
		left: 0.05em;
		top: 0.05em;
	}

	50% {
		left: -0.15em;
		top: -0.05em;
	}

	100% {
		left: 0.05em;
		top: 0.05em;
	}
}

html {
	overflow: hidden;
}

body {
	background: #270010;
	text-align: center;
	font-size: 24px;
	position: absolute;
	inset: 0;
	margin: 0;
	display: flex;
	justify-content: center;
	align-items: center;
	height: 100vh;
	flex-direction: column;
	overflow: hidden;
	max-width: none;
}

bg-layer {
	position: absolute;
	height: 100vh;
	width: 100vw;

	&.root {
		background: url(/assets/img/prophecy.png);
		animation: background-scroll 20s linear 0s infinite;
		filter: contrast(0.5) brightness(0.3) saturate(3);
		z-index: -4;
	}

	&.vignette {
		height: 40vh;
		width: 200vw;
		background: transparent;
		outline: 1000px solid black;
		filter: blur(100px);
		z-index: -3;
	}
}


article.error {
	text-align: center;
	height: 8em;
	cursor: default;
	user-select: none;

	&>h1 {
		font-size: 8em;
		display: inline-block;
		color: transparent;
		position: relative;
		margin: auto;
		letter-spacing: -10px;
		animation: prophecy 3s ease-in-out 0s infinite;
		font-variant-numeric: tabular-nums;

		&::before {
			content: "404";
			margin: auto;
			background: url(/assets/img/prophecy.png);
			background-clip: text;
			color: #0000;
			animation: 
				background-scroll 10s linear 0s infinite, 
				prophecy-color 3s ease-in-out 0s infinite;
			position: absolute;
		}
		&::after {
			content: "404";
			position: absolute;
			inset: -10px;
			
			z-index: -2;
			background: url(/assets/img/prophecy.png);
			background-clip: text;
			animation: 
				prophecy-shadows 3s ease-in-out 0s infinite,
				background-scroll 10s linear 0s infinite;
			filter: brightness(1) opacity(0.5);
		}
	}

	& > span {
		margin: -6.75em 0 6.5em;
		font-size: 1.6em;
		text-transform: lowercase;
		display: block;
		font-family: "Atkinson Hyperlegible Mono", monospace;
		animation: background-scroll 10s linear 0s infinite;
		background: url(/assets/img/prophecy.png);
		filter: brightness(2);
		background-clip: text;
		color: transparent;
		width: 20em;
	}
}	

@media (max-width: 600px) {
	body {
		font-size: 16px;
	}
}
