:root {
	--iconheight: 2.2em;
}

.Sidebar {
	min-width: 15em;
	max-width: 40em;
	background: #f4f5f7;
	border-right: 0.1em solid #ccc;
	position: sticky;
	top: 0;
	align-self: flex-start;
	height: calc(100vh);
	flex: 0 0 auto;
	overflow-y: auto;
}

.SBFunctions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
}

.SBOpenAdmin {
	all: unset;
	display: flex;
	align-items: center;
	margin-left: 1em;
	margin-right: auto;
	cursor: pointer;
}

.SBOpenAdmin > img  {
	padding: 0;
	margin: 0.5em;
	height: var(--iconheight);
	cursor: pointer;
}

.ToggleSBEditMode {
	all: unset;
	display: flex;
	align-items: center;
	margin-left: auto;
	margin-right: 1em;
	cursor: pointer;
}

.CancelSBEditMode {
	all: unset;
	display: none;
	align-items: center;
	margin-left: 0.5em;
	margin-right: 1em;
	cursor: pointer;
}

.CancelSBEditMode > img  {
	padding: 0;
	margin: 0.5em;
	height: var(--iconheight);
	cursor: pointer;
}

#EMIconEdit {
	padding: 0;
	margin: 0.5em;
	height: var(--iconheight);
	cursor: pointer;
}

@keyframes EMSavePulse {
	0%   { transform: scale(1); }
	50%  { transform: scale(1.35); }
	100% { transform: scale(1); }
}

#EMIconSave {
	padding: 0;
	animation: EMSavePulse 1.2s infinite;
	margin: 0.5em;
	height: var(--iconheight);
	cursor: pointer;
}

.Sidebar.SBEditMode .SBItemActions,
.Sidebar.SBEditMode .SBDragKnob,
.Sidebar.SBEditMode .CancelSBEditMode {
	display: flex !important;
}

.Sidebar.SBEditMode .SBCatTitleAddButton {
    display: none;
}

.SBItemActions,
.SBDragKnob {
	display: none;
}

.SBItemActions {
	margin-right: 1em;
}

.SBItemActions > button {
	all: unset;
	font-size: 1.5em;
	cursor: pointer;
}

.SBItemActions > button > img {
	margin-right: 0;
	cursor: pointer;
	font-size: 80%;
}

.SBDragKnob {
    cursor: grab;
	touch-action: none;
    user-select: none;
	margin-right: 0.3em;
}

.SBDragging {
    opacity: 0.5;
}

.SBDragPlaceholder {
    height: 0.5em;
    border: 0.1em dashed #aaa;
    margin: 0.2em 0;
}

.SBRenameInput {
	width: 15em;
}

.SBResizeHandle {
	position: absolute;
	top: 0;
	right: 0;
	width: 0.5em;
	height: 100%;
	cursor: ew-resize;
	background: transparent;
}

.SBToggle {
	position: fixed;
	top: 50%;
	transform: translateY(-50%);
	width: 1.5em;
	height: 5em;
	background: #ddd;
	border-radius: 0 0.5em 0.5em 0;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	user-select: none;
	font-size: 1.5em;
	z-index: 10;
}

.SBCatTitle {
    display: flex;
    align-items: center;
    border-top: 0.05em solid #ddd;
	height: 3em;
	padding-left: 1em;
}

.SBCatTitleText {
    flex: 1 0 auto;
    text-align: left;
    align-items: center;
    justify-content: flex-start;
    cursor: pointer;
    font-weight: bold;
    padding: 0.5em;
    transition: background-color 0.2s ease;
}

.SBCatTitleText:hover {
    background-color: #eee;
}

.SBCatTitleAddButton {
	all: unset;
	flex-shrink: 0;
}

.SBCatTitleAddButton > img {
	width: var(--iconheight);
	height: var(--iconheight);
	cursor: pointer;
	margin-right: 0.5em;
}

.SBCatTitleAddButton:hover {
	
}

.SBCatContent {
    padding-left: 2em;
    margin-bottom: 0.5em;
}

.SBCatContentLine {
    padding: 0.3em 0;
	text-align: left;
    align-items: center;
	justify-content: space-between;
	display: flex;
}

.SBCatContentLine > a {
	flex: 1;
}