:root {
	color-scheme: light dark;
}

* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

body {
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #0a0f14;
	color: #e8eeed;
	font-family:
		system-ui,
		-apple-system,
		BlinkMacSystemFont,
		'Segoe UI',
		sans-serif;
	padding: 2rem;
	text-align: center;
}

.container {
	max-width: 540px;
	width: 100%;
}

.brand {
	display: inline-block;
	margin-bottom: 2.5rem;
	color: #2dd4bf;
	font-size: 0.875rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-decoration: none;
	text-transform: uppercase;
}

.error-code {
	margin-bottom: 1rem;
	color: #2dd4bf;
	font-size: 7rem;
	font-weight: 700;
	letter-spacing: -0.04em;
	line-height: 1;
	opacity: 0.2;
}

h1 {
	margin-bottom: 0.75rem;
	color: #e8eeed;
	font-size: 1.75rem;
}

.message {
	margin-bottom: 2.5rem;
	color: #aebbba;
	line-height: 1.6;
}

.nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	justify-content: center;
}

.nav-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.625rem 1.25rem;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.05);
	color: #e8eeed;
	font-size: 0.875rem;
	font-weight: 500;
	text-decoration: none;
}

@media (prefers-reduced-motion: no-preference) {
	.nav-link {
		transition:
			background 0.2s ease,
			border-color 0.2s ease,
			transform 0.2s ease;
	}

	.nav-link:hover {
		transform: translateY(-1px);
	}
}

button.nav-link {
	font: inherit;
	cursor: pointer;
}

.nav-link:focus-visible,
.brand:focus-visible {
	outline: 2px solid #2dd4bf;
	outline-offset: 2px;
}

.nav-link:hover {
	border-color: rgba(45, 212, 191, 0.3);
	background: rgba(255, 255, 255, 0.1);
}

.primary-link {
	border-color: rgba(45, 212, 191, 0.2);
	background: rgba(45, 212, 191, 0.1);
	color: #2dd4bf;
}

.primary-link:hover {
	border-color: rgba(45, 212, 191, 0.4);
	background: rgba(45, 212, 191, 0.2);
}

@media (max-width: 480px) {
	.error-code {
		font-size: 5rem;
	}

	h1 {
		font-size: 1.375rem;
	}

	.nav-links {
		flex-direction: column;
	}
}

@media (prefers-color-scheme: light) {
	body {
		background: #f6f9f8;
		color: #0a0f14;
	}

	h1 {
		color: #0a0f14;
	}

	.brand,
	.error-code {
		color: #0f766e;
	}

	.message {
		color: #3f4f4e;
	}

	.nav-link {
		border-color: rgba(15, 86, 98, 0.12);
		background: rgba(15, 86, 98, 0.04);
		color: #0a0f14;
	}

	.nav-link:hover {
		border-color: rgba(15, 118, 110, 0.35);
		background: rgba(15, 86, 98, 0.08);
	}

	.nav-link:focus-visible,
	.brand:focus-visible {
		outline-color: #0f766e;
	}

	.primary-link {
		border-color: rgba(15, 118, 110, 0.25);
		background: rgba(15, 118, 110, 0.1);
		color: #0f766e;
	}

	.primary-link:hover {
		border-color: rgba(15, 118, 110, 0.45);
		background: rgba(15, 118, 110, 0.18);
	}
}
