/**
 * sideNav.css - the side navigation styling.
 *
 */

:root {
	--side-nav-width: 210px;
	--side-nav-gutter: calc(var(--side-nav-width) + 8px);
}

body:not(.sideNavHidden) {
	padding-left: var(--side-nav-gutter);
}

@media screen and (min-width: 801px) {
	body:not(.sideNavHidden) {
		margin-left: 0;
	}

	/* Center threads: centre the 1200px column on the viewport, never under the nav. */
	body.centerthreads:not(.sideNavHidden) {
		max-width: none;
		padding-left: max(var(--side-nav-gutter), calc((100% - 1200px) / 2));
		padding-right: max(8px, calc((100% - 1200px) / 2));
	}
}

.sideNavHidden .sideNav {
	display: none;
}

.sideNav {
	position: fixed;
	top: 0;
	left: 0;
	width: var(--side-nav-width);
	height: 100vh;
	/* Above the pinned nav (3), the pager (1) and neomenu (100); below previews and windows. */
	z-index: 101;
}

.sideNavPanel {
	height: 100%;
	overflow-y: auto;
	box-sizing: border-box;
	padding: 0;
	background-color: var(--color-bg-main);
	border-right: 1px solid var(--color-lo-contrast-border);
	text-align: left;
	font-size: 10pt;
}

.sideNavGroup {
	margin-top: 0.5em;
}

.sideNavGroupTitle {
	font-weight: bold;
	cursor: pointer;
	list-style: none;
}

.sideNavGroupTitle::-webkit-details-marker {
	display: none;
}

.sideNavList {
	margin: 0;
	padding: 0 0 0 0.2em;
	list-style: none;
}

.sideNavStyle label {
	display: flex;
	align-items: center;
	gap: 0.3em;
	white-space: nowrap;
}

.sideNavStyle select {
	flex: 1;
	min-width: 0;
}

.sideNavItem a {
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	outline: none;
	text-decoration: none;
	color: var(--color-fg-side-nav-link, #550);
}

.sideNavBoardDir {
	display: none;
}

.sideNavShowDirs .sideNavBoardDir {
	display: inline;
}

@media screen and (max-width: 800px) {
	body:not(.sideNavHidden) {
		padding-left: 0;
	}

	.sideNav {
		display: none;
	}
}
