/* Mobile nav – cały serwis (≤900px), zamiast scrollującej belki #top_nav */

@media (min-width: 901px) {
	#sys-dash-mobile-nav {
		display: none !important;
	}
}

@media (max-width: 900px) {
	#sys-dash-mobile-nav {
		display: block;
	}
	#dashboard_nav_desktop_wrap {
		display: none !important;
	}
	body {
		min-width: 0 !important;
		width: 100%;
		max-width: 100%;
		overflow-x: hidden;
	}
	#main_cointainer {
		width: 100% !important;
		max-width: 100% !important;
		overflow-x: hidden;
	}
	#content {
		width: 100% !important;
		max-width: 100% !important;
		padding-bottom: 4px;
		box-sizing: border-box;
	}
	#px1200 {
		width: 100% !important;
		max-width: 100% !important;
	}
	/* Dashboard: nie tnij overflow — widżety muszą się przewijać ze stroną */
	html:has(#system_dashboard) body {
		overflow-x: auto !important;
		overflow-y: auto !important;
		height: auto !important;
	}
	html:has(#system_dashboard) #main_cointainer {
		overflow-x: visible !important;
		overflow-y: visible !important;
	}
	/* Stopka: mniej pustki nad nią, więcej oddechu tekstu od dolnej krawędzi */
	#main_cointainer {
		margin-bottom: 0 !important;
	}
	.push {
		height: 0 !important;
		min-height: 0 !important;
	}
	.footer {
		height: auto !important;
		min-height: 0;
	}
	.footer_dahsboard {
		height: auto !important;
		min-height: 0;
		padding: 8px 12px calc(12px + env(safe-area-inset-bottom, 0px));
		box-sizing: border-box;
	}
	.footer_dahsboard img {
		height: 22px;
		margin-top: 2px;
	}
	.footer_dahsboard p {
		line-height: 1.35;
		padding-bottom: 2px;
	}
}

.sys-dash-mobile-nav {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 10000;
	background: #333;
	border-bottom: 1px solid #111;
}

.sys-dash-mobile-nav-bar {
	position: relative;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 40px;
	padding: 0 8px 0 10px;
	box-sizing: border-box;
}

.sys-dash-mobile-nav-logo {
	display: flex;
	align-items: center;
	flex: 1;
	min-width: 0;
	padding: 4px 8px 4px 0;
}

.sys-dash-mobile-nav-logo img {
	height: 26px;
	width: auto;
	max-width: 100%;
	display: block;
}

.sys-dash-mobile-nav-toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 32px;
	margin: 0;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, 0.25);
	border-radius: 4px;
	background: #1a1a1a;
	color: #fff;
	cursor: pointer;
	flex-shrink: 0;
}

.sys-dash-mobile-nav-toggle-bars {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 4px;
	width: 18px;
}

.sys-dash-mobile-nav-toggle-bars span {
	display: block;
	height: 2px;
	background: #fff;
	border-radius: 1px;
}

.sys-dash-mobile-nav.is-open .sys-dash-mobile-nav-toggle {
	background: #006CFF;
	border-color: #0052cc;
}

.sys-dash-mobile-nav-panel[hidden],
.sys-dash-mobile-nav-backdrop[hidden] {
	display: none !important;
}

.sys-dash-mobile-nav-panel {
	position: fixed;
	top: 40px;
	left: 0;
	right: 0;
	bottom: 0;
	height: calc(100dvh - 40px);
	height: calc(100vh - 40px);
	max-height: calc(100dvh - 40px);
	max-height: calc(100vh - 40px);
	flex-direction: column;
	overflow: hidden;
	z-index: 2;
	background: #2a2a2a;
	border-bottom: 1px solid #111;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.sys-dash-mobile-nav-panel:not([hidden]) {
	display: flex;
}

.sys-dash-mobile-nav-panel-inner {
	flex: 1 1 auto;
	min-height: 0;
	padding: 0;
	overflow-x: hidden;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior: contain;
	touch-action: pan-y;
}

.sys-dash-mobile-nav-user {
	margin: 0;
	padding: 12px 14px;
	font-size: 14px;
	color: #fff;
	border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.sys-dash-mobile-nav-user-op {
	color: rgba(255, 255, 255, 0.65);
	font-size: 11px;
}

.sys-dash-mobile-nav-section {
	padding: 0;
	border-bottom: none;
}

.sys-dash-mobile-nav-section-title {
	margin: 10px 0 0;
	padding: 10px 14px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #fff;
	background: #006CFF;
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	border-bottom: 1px solid #0052cc;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.sys-dash-mobile-nav-section:first-of-type .sys-dash-mobile-nav-section-title {
	margin-top: 0;
}

.sys-dash-mobile-nav-list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.sys-dash-mobile-nav-list li {
	margin: 0;
	padding: 0;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sys-dash-mobile-nav-list li:last-child {
	border-bottom: none;
}

.sys-dash-mobile-nav-list a {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 14px;
	font-size: 14px;
	line-height: 1.35;
	color: #fff;
	text-decoration: none;
}

.sys-dash-mobile-nav-list a:hover,
.sys-dash-mobile-nav-list a:active,
.sys-dash-mobile-nav-list a:focus {
	background: rgba(255, 255, 255, 0.08);
	color: #fff;
}

.sys-dash-mobile-nav-list a [class*="fonticon-"] {
	color: #fff;
}

.sys-dash-mobile-nav-list img {
	width: 24px;
	height: 24px;
	flex-shrink: 0;
}

.sys-dash-mobile-nav-legend {
	padding: 12px 14px 6px;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.55);
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sys-dash-mobile-nav-more {
	font-weight: 600;
	color: #fff !important;
}

.sys-dash-mobile-nav-footer {
	flex: 0 0 auto;
	position: relative;
	z-index: 3;
	margin-top: 0;
	padding: 12px 14px calc(12px + env(safe-area-inset-bottom, 0px));
	border-top: 1px solid rgba(255, 255, 255, 0.14);
	background: #242424;
	box-shadow: 0 -6px 14px rgba(0, 0, 0, 0.22);
}

.sys-dash-mobile-nav-logout-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	box-sizing: border-box;
	padding: 13px 14px;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	color: #fff;
	text-decoration: none;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	background: #8f2a2a;
	border: 1px solid rgba(255, 255, 255, 0.18);
	border-radius: 6px;
}

.sys-dash-mobile-nav-logout-btn:hover,
.sys-dash-mobile-nav-logout-btn:active,
.sys-dash-mobile-nav-logout-btn:focus {
	background: #a83232;
	color: #fff;
}

.sys-dash-mobile-nav-logout-btn .fonticon-logout {
	color: #fff;
}

.sys-dash-mobile-nav-backdrop {
	position: fixed;
	inset: 0;
	top: 40px;
	z-index: 1;
	background: rgba(0, 0, 0, 0.45);
	pointer-events: auto;
}

html.sys-dash-mobile-nav-open,
body.sys-dash-mobile-nav-open {
	overflow: hidden;
	height: 100%;
}
