/**
 * 移动端导航 - 现代化全屏侧边菜单
 * 设计理念：类似小程序的抽屉式导航，更适合移动端操作习惯
 */

/* ==================== 移动端菜单遮罩 ==================== */
.mobile-menu-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,0.5);
	z-index: 1040;
	opacity: 0;
	visibility: hidden;
	transition: all 0.3s ease;
}

.mobile-menu-overlay.active {
	opacity: 1;
	visibility: visible;
}

/* ==================== 移动端菜单面板 ==================== */
.mobile-menu {
	position: fixed;
	top: 0;
	right: 0;
	width: 85%;
	max-width: 320px;
	height: 100vh;
	background: #fff;
	z-index: 1050;
	transform: translateX(100%);
	transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	box-shadow: -5px 0 30px rgba(0,0,0,0.15);
}

.mobile-menu.active {
	transform: translateX(0);
}

/* ==================== 菜单头部 ==================== */
.mobile-menu-header {
	padding: 20px;
	background: linear-gradient(135deg, #0a1628 0%, #1b263b 100%);
	color: #fff;
	position: relative;
}

.mobile-menu-close {
	position: absolute;
	top: 20px;
	right: 20px;
	width: 36px;
	height: 36px;
	background: rgba(255,255,255,0.1);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	font-size: 16px;
	cursor: pointer;
	transition: all 0.3s;
}

.mobile-menu-close:hover {
	background: rgba(255,255,255,0.2);
}

.mobile-menu-brand {
	display: flex;
	align-items: center;
	gap: 12px;
}

.mobile-menu-brand img {
	height: 40px;
	width: auto;
}

.mobile-menu-brand-text {
	font-size: 16px;
	font-weight: 600;
}

/* ==================== 菜单内容 ==================== */
.mobile-menu-body {
	height: calc(100vh - 80px);
	overflow-y: auto;
	padding: 20px 0;
}

/* 主导航项 */
.mobile-nav-item {
	position: relative;
}

.mobile-nav-link {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	color: #1f2937;
	text-decoration: none;
	font-size: 16px;
	font-weight: 500;
	transition: all 0.2s;
	border-left: 3px solid transparent;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
	background: #f8fafc;
	color: #0066cc;
	border-left-color: #0066cc;
}

.mobile-nav-link i:first-child {
	width: 24px;
	margin-right: 12px;
	color: #6b7280;
	font-size: 18px;
}

.mobile-nav-link:hover i:first-child,
.mobile-nav-link.active i:first-child {
	color: #0066cc;
}

/* 展开箭头 */
.mobile-nav-arrow {
	width: 24px;
	height: 24px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #9ca3af;
	transition: transform 0.3s;
}

.mobile-nav-item.expanded .mobile-nav-arrow {
	transform: rotate(180deg);
}

/* 子菜单 */
.mobile-submenu {
	background: #f9fafb;
	overflow: hidden;
	max-height: 0;
	transition: max-height 0.3s ease;
}

.mobile-nav-item.expanded .mobile-submenu {
	max-height: 500px;
}

.mobile-submenu-item {
	display: block;
	padding: 14px 20px 14px 59px;
	color: #4b5563;
	text-decoration: none;
	font-size: 14px;
	transition: all 0.2s;
	position: relative;
}

.mobile-submenu-item::before {
	content: '';
	position: absolute;
	left: 47px;
	top: 50%;
	transform: translateY(-50%);
	width: 4px;
	height: 4px;
	background: #9ca3af;
	border-radius: 50%;
}

.mobile-submenu-item:hover,
.mobile-submenu-item.active {
	color: #0066cc;
	background: #f3f4f6;
}

.mobile-submenu-item:hover::before,
.mobile-submenu-item.active::before {
	background: #0066cc;
}

/* ==================== 快速操作区 ==================== */
.mobile-menu-actions {
	padding: 20px;
	border-top: 1px solid #e5e7eb;
	margin-top: 20px;
}

.mobile-menu-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	padding: 14px 20px;
	background: linear-gradient(135deg, #0066cc 0%, #0088ff 100%);
	color: #fff;
	border-radius: 8px;
	text-decoration: none;
	font-weight: 600;
	font-size: 15px;
	transition: all 0.3s;
}

.mobile-menu-btn:hover {
	background: linear-gradient(135deg, #0052a3 0%, #0066cc 100%);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0,102,204,0.3);
}

/* ==================== 菜单按钮（汉堡按钮） ==================== */
.mobile-menu-toggle {
	display: none;
	width: 44px;
	height: 44px;
	align-items: center;
	justify-content: center;
	background: transparent;
	border: none;
	cursor: pointer;
	padding: 10px;
	margin-right: 15px;
	margin-right: 15px;
}

.mobile-menu-toggle span {
	display: block;
	width: 24px;
	height: 2px;
	background: #1a1a2e;
	position: relative;
	transition: all 0.3s;
}

.mobile-menu-toggle span::before,
.mobile-menu-toggle span::after {
	content: '';
	position: absolute;
	width: 24px;
	height: 2px;
	background: #1a1a2e;
	transition: all 0.3s;
}

.mobile-menu-toggle span::before {
	top: -7px;
}

.mobile-menu-toggle span::after {
	top: 7px;
}

/* 菜单打开时的动画 */
.mobile-menu-toggle.active span {
	background: transparent;
}

.mobile-menu-toggle.active span::before {
	transform: rotate(45deg);
	top: 0;
}

.mobile-menu-toggle.active span::after {
	transform: rotate(-45deg);
	top: 0;
}

/* ==================== 桌面端隐藏移动端菜单 ==================== */
@media (min-width: 992px) {
	.mobile-menu,
	.mobile-menu-overlay,
	.mobile-menu-toggle {
		display: none !important;
	}
}

/* ==================== 移动端显示菜单按钮 ==================== */
@media (max-width: 991px) {
	.mobile-menu-toggle {
		display: flex;
	}
	
	/* 隐藏Bootstrap默认的折叠菜单 */
	.navbar-collapse {
		display: none !important;
	}
	
	.navbar-tech .container {
		position: relative;
	}
}

/* ==================== 底部固定导航栏（可选） ==================== */
.mobile-bottom-nav {
	display: none;
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	background: #fff;
	box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
	z-index: 1030;
	padding-bottom: env(safe-area-inset-bottom);
}

.mobile-bottom-nav-list {
	display: flex;
	justify-content: space-around;
	padding: 8px 0;
}

.mobile-bottom-nav-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	padding: 4px 16px;
	color: #6b7280;
	text-decoration: none;
	font-size: 11px;
	transition: all 0.2s;
}

.mobile-bottom-nav-item i {
	font-size: 20px;
}

.mobile-bottom-nav-item:hover,
.mobile-bottom-nav-item.active {
	color: #0066cc;
}

@media (max-width: 991px) {
	.mobile-bottom-nav {
		display: block;
	}
	
	/* 为底部导航留出空间 */
	body {
		padding-bottom: 70px;
	}
}
