/* Shared admin shell for regular and full-height workspaces. */

.app.app-content-full-height {
	height: 100dvh;
	overflow: hidden;
}

.app-content-full-height .app-content {
	display: flex;
	min-width: 0;
	min-height: 0;
	overflow: hidden;
}

#sidebar-secondary {
	width: 20rem;
	min-width: 20rem;
	display: flex;
	flex-direction: column;
	border-right: 1px solid var(--bs-border-color);
	background: var(--bs-body-bg);
}

#sidebar-secondary > [data-scrollbar] {
	flex: 1;
	min-height: 0;
	overflow-y: auto;
}

.sidebar-header,
.content-header {
	min-height: 3.5rem;
	padding: 0.75rem 1rem;
	border-bottom: 1px solid var(--bs-border-color);
}

.content-inner {
	display: flex;
	flex: 1;
	min-width: 0;
	min-height: 0;
	flex-direction: column;
}

.content-body {
	flex: 1;
	min-height: 0;
	overflow: auto;
	padding: 1rem;
}

.sidebar-close {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	z-index: 2;
}

.secondary-sidebar-backdrop {
	display: none;
}

@media (max-width: 1199.98px) {
	#sidebar-secondary {
		position: fixed;
		z-index: 1050;
		inset: var(--app-header-height, 3.5rem) auto 0 0;
		max-width: min(90vw, 22rem);
		transform: translateX(-100%);
		transition: transform 0.2s ease;
		box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.18);
	}

	body.secondary-sidebar-open #sidebar-secondary {
		transform: translateX(0);
	}

	.secondary-sidebar-backdrop {
		position: fixed;
		z-index: 1040;
		inset: var(--app-header-height, 3.5rem) 0 0;
		border: 0;
		background: rgba(0, 0, 0, 0.35);
	}

	body.secondary-sidebar-open .secondary-sidebar-backdrop {
		display: block;
	}
}

@media (prefers-reduced-motion: reduce) {
	#sidebar-secondary {
		transition: none;
	}
}
