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

:root {
	--color-light: hsl(220, 80%, 90%);
	--color-dark: hsl(220, 80%, 10%);
	--color-primary: hsl(220, 80%, 50%);
	--color-secondary: hsl(220, 80%, 30%);
	--color-tertiary: hsl(220, 80%, 70%);
	--color-background: hsl(220, 30%, 10%);
	--color-header: hsl(220, 50%, 30%);
	--color-header-hover: hsl(220, 50%, 20%);
	--color-error: hsl(0, 80%, 70%);

	scroll-behavior: smooth;
}

html,
body {
	height: 100%;
	margin: 0;
	font-family: "Lato", sans-serif;
	color: var(--color-light);
	background-color: var(--color-background);
	display: flex;
	flex-direction: column;
}

header {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: center;
	background-color: var(--color-header);
}

header .logo {
	height: 100%;
	width: 100%;
}

.pages {
	height: 3rem;
}

.pages ul {
	display: flex;
	flex-wrap: nowrap;
	list-style: none;
	padding: 0;
	margin: 0;
	height: 100%;
}

.pages .icon {
	display: flex;
	gap: 1ch;
}

.pages a {
	display: flex;
	align-items: center;
	text-align: center;
	text-decoration: none;
	color: var(--color-light);
	transition: 250ms ease-in-out;
	height: 100%;
	padding-inline: 1rem;
}

.pages a:hover,
.pages a:focus {
	background-color: var(--color-header-hover);
}

.pages:first-child li:first-child a {
	padding-left: 0;
}

.pages [data-page="profile"] {
	display: none;
}

.pages [data-page="profile"] img {
	object-fit: cover;
	height: 100%;
	padding-block: 0.5ch;
	vertical-align: middle;
	border-radius: 50%;
}

main {
	padding: 1ch 1rem;
	max-width: 50rem;
	margin: 0 auto;
}

a {
	color: var(--color-tertiary);
}

footer {
	padding: 1ch;
	font-size: 0.8em;
	padding: 1rem;
	background: var(--color-dark);
	color: var(--color-light);
	text-align: center;
	margin-top: auto;
}

footer p {
	margin: 0;
}

footer a {
	color: inherit;
}

@media screen and (max-width: 455px) {
	header {
		justify-content: center;
	}
}

@media screen and (max-width: 780px) {
	main {
		position: static;
		border-top: 1px solid var(--color-light);
	}
}
