body {
	/* Reserve the fixed navbar's landscape height. */
	padding-top: 5.4rem;
}

.siteHeader,
.siteHeader * {
	box-sizing: border-box;
}

.siteHeader {
	position: fixed;
	top: 0;
	right: 0;
	left: 0;
	z-index: 10;
	border-bottom: 1px solid var(--border);
	background: var(--header-bg);
	backdrop-filter: blur(14px);
	font-family: "Fredoka", system-ui, sans-serif;
}

.siteNav {
	display: grid;
	grid-template-columns: max-content minmax(0, 1fr) max-content;
	align-items: stretch;
	width: min(100%, 1440px);
	min-height: 5.25rem;
	margin: 0 auto;
	padding: 0 1.25rem;
}

.brand {
	display: flex;
	align-items: center;
	color: var(--text);
	text-decoration: none;
}

.brandLogo {
	width: 5.4rem;
	height: 5.4rem;
	object-fit: contain;
	filter: drop-shadow(0 0 0.45rem hsl(var(--theme-hue) var(--theme-saturation) var(--theme-foreground-lightness) / 0.2));
}

.navTabs {
	display: flex;
	justify-content: center;
	align-items: stretch;
	min-width: 0;
	margin: 0 0.5rem;
}

.navTab,
.accountNav {
	position: relative;
	color: var(--text);
	text-decoration: none;
}

.navTab {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 6.5rem;
	padding: 0 1.1rem;
	font-weight: 600;
}

.navTab::after,
.accountNav::after {
	position: absolute;
	right: 1rem;
	bottom: 0;
	left: 1rem;
	height: 0.2rem;
	background: var(--accent);
	content: "";
	opacity: 0;
	transform: scaleX(0.5);
	transition: opacity 160ms ease, transform 160ms ease;
}

.navTab.isActive::after,
.accountNav.isActive::after {
	opacity: 1;
	transform: scaleX(1);
}

.accountNav {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap: 0.15rem;
	min-width: 5.5rem;
	padding: 0.45rem 0.6rem;
}

.accountAvatar {
	width: auto;
	height: 100%;
	max-height: 4.25rem;
	object-fit: contain;
	filter: drop-shadow(0 0.18rem 0.4rem rgb(0 0 0 / 0.48));
}

.accountName {
	overflow: hidden;
	max-width: 7rem;
	color: var(--text);
	font-size: 0.72rem;
	font-weight: 600;
	text-overflow: ellipsis;
	white-space: nowrap;
}

@media (orientation: portrait) {
	body { padding-top: 4.4rem; }

	.siteNav {
		grid-template-columns: 3.25rem minmax(0, 1fr) 3.5rem;
		grid-template-areas: "brand tabs account";
		width: 100%;
		min-height: auto;
		padding: 0 0.25rem;
	}

	.brand { grid-area: brand; }
	.brandLogo { width: 3.25rem; height: 3.25rem; }

	.navTabs {
		grid-area: tabs;
		justify-content: flex-start;
		overflow-x: auto;
		max-width: 100%;
		padding: 0;
		scrollbar-width: none;
	}

	.navTabs::-webkit-scrollbar { display: none; }

	.navTab {
		flex: 1 1 0;
		min-width: 0;
		height: 4rem;
		padding: 0 0.12rem;
		font-size: 0.72rem;
	}

	.navTab::after,
	.accountNav::after { right: 0.35rem; left: 0.35rem; }

	.accountNav {
		grid-area: account;
		min-width: 3.5rem;
		padding: 0.3rem 0.1rem;
	}

	.accountAvatar { max-height: 3.35rem; }
	.accountName { max-width: 3.4rem; font-size: 0.66rem; }
}
