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

:focus {
	outline: none;
}

::selection {
	background-color: color-mix(in srgb, var(--primary-color) 90%, white);
	color: var(--text-color);
}

:root {
	font-family: system-ui, Avenir, Helvetica, Arial, sans-serif;
	font-weight: 400;

	color-scheme: dark;

	font-synthesis: none;
	text-rendering: optimizeLegibility;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;

	--text-color: rgb(232, 235, 251);
	--background-color: rgb(15, 16, 23);
	--primary-color: rgb(255, 65, 106);
	--secondary-color: rgb(52, 198, 255);
	--error-color: rgb(255, 69, 91);
	--warning-color: rgb(255, 193, 7);
	--success-color: rgb(36, 255, 116);
	--text-muted-color: rgb(175, 184, 193);
	--border-color: rgb(70, 70, 70);
}

html {
	font-size: 62.5%;
}

body {
	background-color: var(--background-color);
	color: var(--text-color);
	font-size: 1.6rem;
	line-height: 1.4;
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

a {
	color: var(--primary-color);
	text-decoration: none;

	&:hover {
		color: color-mix(in srgb, var(--primary-color) 75%, white);
	}
}

button {
	font-family: inherit;
	font-size: 1.6rem;
	background: none;
	border: none;
	cursor: pointer;
}

input,
textarea {
	font-family: inherit;
	font-size: inherit;
	line-height: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
	font-weight: 600;
	line-height: 1.2;
}

h1 {
	font-size: 3.2rem;
}

h2 {
	font-size: 2.4rem;
}

h3 {
	font-size: 2rem;
}

h4 {
	font-size: 1.6rem;
}

h5 {
	font-size: 1.4rem;
}

h6 {
	font-size: 1.2rem;
}

ul,
ol {
	list-style: none;
}

img {
	max-width: 100%;
	height: auto;
	display: block;
}

.text-muted {
	color: var(--text-muted-color);
}

.text-primary {
	color: var(--primary-color);
}

.text-secondary {
	color: var(--secondary-color);
}

nav {
	background-color: color-mix(in srgb, var(--background-color) 95%, black);
	color: var(--text-muted-color);
	border-bottom: 1px solid var(--border-color);
	padding: 1.6rem 2rem;

	.nav-container {
		max-width: 120rem;
		margin: 0 auto;
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 0 2rem;

		h1 {
			font-size: 2.4rem;
			color: var(--text-color);
		}

		.nav-links {
			display: flex;
			gap: 2.4rem;

			@media screen and (max-width: 768px) {
				flex-direction: column;
				align-items: center;
			}

			.active a {
				color: var(--primary-color);
				font-weight: bold;
			}

			a {
				color: var(--text-muted-color);
				font-size: 1.6rem;
				font-weight: 500;
				transition: color 0.25s ease, transform 0.25s ease;

				&:hover {
					color: color-mix(in srgb, var(--primary-color) 80%, white);
					@media screen and (min-width: 769px) {
						transform: translateX(0.4rem);
					}
				}
			}
		}
	}
}

main {
	max-width: 120rem;
	margin: 0 auto;
	flex: 1;
	padding: 2.4rem 2rem;
	width: 100%;
}

footer {
	background-color: color-mix(in srgb, var(--background-color) 95%, black);
	color: var(--text-muted-color);
	border-top: 1px solid var(--border-color);
	margin-top: auto;

	.footer-content {
		max-width: 120rem;
		margin: 0 auto;
		padding: 3.2rem 2rem 2.4rem;
		display: grid;
		grid-template-columns: repeat(auto-fit, minmax(25rem, 1fr));
		gap: 2.4rem;

		@media screen and (max-width: 768px) {
			grid-template-columns: 1fr;
			gap: 2rem;
			text-align: center;
		}
	}

	.footer-section {
		h4 {
			color: var(--text-color);
			font-size: 1.6rem;
			font-weight: 600;
			margin-bottom: 1rem;
		}

		.version-info {
			display: flex;
			align-items: center;
			gap: 1rem;
			font-size: 1.4rem;
			color: var(--text-muted-color);

			@media screen and (max-width: 768px) {
				justify-content: center;
				flex-wrap: wrap;
			}

			.version-item {
				font-weight: 500;
			}

			.version-divider {
				font-weight: bold;
			}
		}

		.footer-links {
			display: flex;
			flex-direction: column;
			gap: 0.8rem;

			@media screen and (max-width: 768px) {
				align-items: center;
			}
		}

		.footer-link {
			color: var(--secondary-color);
			font-size: 1.4rem;
			font-weight: 500;
			transition: color 0.25s ease, transform 0.25s ease;
			width: fit-content;

			&:hover {
				color: color-mix(in srgb, var(--secondary-color) 80%, white);

				@media screen and (min-width: 769px) {
					transform: translateX(0.4rem);
				}
			}

			@media screen and (min-width: 769px) {
				&::before {
					content: "→ ";
					opacity: 0;
					transition: opacity 0.25s ease;
				}

				&:hover::before {
					opacity: 1;
				}
			}
		}

		.footer-description {
			font-size: 1.4rem;
			line-height: 1.5;
			color: var(--text-muted-color);
		}
	}

	.footer-bottom {
		border-top: 1px solid var(--border-color);
		padding: 1.6rem 2rem;
		text-align: center;

		p {
			font-size: 1.3rem;
			color: var(--text-muted-color);
		}
	}
}
