:root {
	color-scheme: light dark;
	--orange: 244, 99, 31;
	--sea-green: 11, 175, 168;
	--olive: 51,75,73;
	--cool: 149,177,174;
	--background-image-light: linear-gradient(320deg, rgba(var(--olive),1) 0%, rgba(var(--cool),1) 20%, rgba(255,255,255,1) 100%);
	--background-image-dark: linear-gradient(320deg, rgba(var(--cool),1) 0%, rgba(var(--olive),5) 20% );
	--background-gradient-orange: linear-gradient(150deg, rgba(244,99,31,0.5) -20%, rgba(0,0,0,.21) 23%, rgba(0,0,0,.21) 77%, rgba(244,99,31,0.5) 120%);
}

* {
	font: inherit;
	box-sizing: border-box;
}

body {
	position: relative;
	z-index: 1;
    width: 100dvw;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    color: light-dark(
    	color-mix(in lab, rgb(var(--cool)) 20%, white), 
    	black
    );
    background-color: light-dark(
    	rgba(var(--olive), .5), 
    	rgba(var(--olive), 1)
    );
    font-family: system-ui;
    font-size: 18px;
    line-height: 22px;
    font-weight: 400;
}

main {
	z-index: 1;
	flex-grow: 1;
	width: 100%;
    margin-inline: auto;
    display: flex;
    max-width: 95%;
    box-shadow: 0 0 5px 0px rgb(var(--cool));
}

.text-wrapper {
    margin-block: auto;
}

main {
	z-index: 1;
	flex-grow: 1;
	width: 100%;
	margin-block: 2rem;
}
header, 
footer {
	display: flex;
	justify-content: center;
	align-items: center;
	padding-block: 1rem .5rem;
	background-color: light-dark(
	    rgba(var(--olive), .5), 
	    rgba(var(--cool), .5)
	);
	color: light-dark(
		color-mix(in lab, rgb(var(--cool)) 20%, white), 
		color-mix(in lab, rgb(var(--orange)) 30%, white)
	);
	backdrop-filter: blur(5px);
}
header {
	box-shadow: 0 2px 5px 0px rgb(var(--cool));
}
footer {
	box-shadow: 0 -2px 5px 0px rgb(var(--cool));
}
h1 {
	color: white;
	--mix-ratio: 55%;
	--mix-color: var(--olive);
	line-height: 2.5rem;
	font-size: 2rem;
	font-weight: 700;
	text-align: center;
	text-transform: uppercase;
	text-shadow: 
		-5px 0 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
		5px 0 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
		0px -5px 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
		0px 5px 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent);
}
h2 {
	text-align: center;
	line-height: 1.6rem;
	font-size: 1.2rem;
	font-weight: 500;
}
h3 {
	line-height: 1.1rem;
	font-size: .9rem;
	font-weight: 400;
	text-transform: none;
}
p {
	font-size: 1rem;
	line-height: 1.5rem;
	margin-block-end: 1.5rem;
	margin-inline: auto;
}
a, a:visited {
	color: inherit;
}
code {
    display: block;
    margin-block: 1.5rem;
    margin-inline: auto;
    padding-block: .6rem;
    padding-inline: 2rem;
    opacity: .75;
    background-color: light-dark(white, black);
    color: light-dark(black, white);
    border-radius: .35rem;
    font-family: monospace;
    font-weight: 300;
    text-align: center;
}

.text-wrapper {
    max-width: 80ch;
    margin-inline: auto;
    padding-block: 1rem;
    padding-inline: 2rem;
    border-radius: .25rem;
    overflow: hidden;
    box-shadow: 0 0 5px 0px rgb(var(--cool));
    backdrop-filter: blur(5px);
    background-color: light-dark(
       rgba(var(--olive), .65), 
       rgba(var(--cool), .65)
  	);
}

@media screen and (min-width: 1080px) {
	.bg-layer {
		--x-offset: -.2;
		--y-offset: -1;
		position: absolute;
		top: 0;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 2;
		background-position-y: calc((100% / 500px) * var(--y-offset));
		background-position-x: calc((100% / 500px) * var(--y-offset));
		animation-name: rain;
		animation-timing-function: linear;
		animation-iteration-count: infinite;
		background-repeat: no-repeat;
	}
	main {
		max-width: 100%;
		width: 100%;
		margin-block: 2rem;
	}
	.text-wrapper {
		margin-block: unset;
	}
	.layer {
		--image-width: 500;
		--image-height: 500;
		--step-duration: 22;
		position:absolute;
		top: 0;
		right:0;
		bottom:0;
		left:0;
		background-repeat: no-repeat;
		background-position: 
			calc(var(--image-width) * -1px),
			calc(var(--image-height) * -1px);
	}

	.layer:nth-child(1) {
		background-image: url(/images/computer-tile-1-500.png);
		--step-size: 1.9;
	}
	.layer:nth-child(2) {
		background-image: url(/images/computer-tile-2-500.png);
		--step-size: 2.3;
	}
	.layer:nth-child(3) {
		background-image: url(/images/computer-tile-3-500.png);
		--step-size: 2.7;
	}
	.layer:nth-child(4) {
		background-image: url(/images/computer-tile-4-500.png);
		--step-size: 3.3;
	}
	.layer:nth-child(5) {
		background-image: url(/images/computer-tile-5-500.png);
		--step-size: 3.8;
	}
	.layer:nth-child(6) {
		background-image: url(/images/computer-tile-6-500.png);
		--step-size: 4.2;
	}
	.layer:nth-child(7) {
		background-image: url(/images/computer-tile-7-500.png);
		--step-size: 4.5;
	}
}
@media (prefers-color-scheme: dark) {
	.text-wrapper {
		box-shadow: 0 0 5px 0px rgb(var(--olive));
	}
	header {
		box-shadow: 0 2px 5px 0px rgb(var(--olive));
	}
	footer {
		box-shadow: 0 -2px 5px 0px rgb(var(--olive));
	}
	h1 {
		--mix-ratio: 25%;
		--mix-color: var(--orange);
		text-shadow: 
			-5px 0 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
			5px 0 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
			0px -5px 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent),
			0px 5px 4px color-mix(in lab, rgb(var(--mix-color)) var(--mix-ratio), transparent);
	}
}