/* ============================================================
 * 前台多语言纯下拉（lg-dd）
 * 用法：并入站点 skin/css/style.css，或单独 <link> 引入本文件
 * 依赖：apps/home/controller/ExtLabelController.php 的 {pboot:areas}
 * ============================================================ */

/* 桌面端：纯下拉 */
.lg-switch.lg-dd{
	position: relative;
	float: right;
	height: 40px;
	z-index: 96;
}
.lg-dd-btn{
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 32px;
	margin-top: 4px;
	padding: 0 12px 0 8px;
	border: 1px solid rgba(255,255,255,.42);
	border-radius: 4px;
	background: rgba(255,255,255,.08);
	color: #fff;
	font-size: 13px;
	line-height: 1;
	cursor: pointer;
	outline: none;
	box-sizing: border-box;
	transition: background .2s ease, border-color .2s ease;
}
.lg-dd-btn:hover,
.lg-dd.open .lg-dd-btn{
	background: rgba(255,255,255,.16);
	border-color: rgba(255,255,255,.75);
}
.lg-dd-btn .lg-code{
	display: inline-block;
	min-width: 26px;
	height: 20px;
	padding: 0 4px;
	line-height: 20px;
	text-align: center;
	border-radius: 3px;
	background: rgba(255,255,255,.2);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .04em;
}
.lg-dd-btn .lg-name{
	white-space: nowrap;
	max-width: 8em;
	overflow: hidden;
	text-overflow: ellipsis;
}
.lg-dd-caret{
	width: 0;
	height: 0;
	margin-left: 2px;
	border-left: 4px solid transparent;
	border-right: 4px solid transparent;
	border-top: 5px solid currentColor;
	opacity: .85;
	transition: transform .2s ease;
}
.lg-dd.open .lg-dd-caret{
	transform: rotate(180deg);
}
.lg-dd-menu{
	display: none;
	position: absolute;
	right: 0;
	top: 100%;
	min-width: 148px;
	margin-top: 4px;
	padding: 6px 0;
	border: 1px solid rgba(0,0,0,.08);
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 10px 28px rgba(0,0,0,.14);
	box-sizing: border-box;
}
.lg-dd.open .lg-dd-menu{
	display: block;
}
.lg-dd-menu .lg-a{
	display: flex !important;
	align-items: center;
	gap: 8px;
	height: auto !important;
	margin: 0 !important;
	padding: 9px 14px !important;
	line-height: 1.3 !important;
	color: #333 !important;
	font-size: 13px !important;
	text-decoration: none;
	background: transparent !important;
	border: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
}
.lg-dd-menu .lg-a:hover{
	background: #f3f6f3 !important;
}
.lg-dd-menu .lg-a.on{
	background: #eef3ee !important;
	color: #2f3a2f !important;
	font-weight: 600;
}
.lg-dd-menu .lg-code{
	display: inline-block;
	min-width: 28px;
	height: 20px;
	padding: 0 4px;
	line-height: 20px;
	text-align: center;
	border-radius: 3px;
	background: #e8ece8;
	color: #445044;
	font-size: 11px;
	font-weight: 700;
}
.lg-dd-menu .lg-a.on .lg-code{
	background: #adbfaa;
	color: #fff;
}
.lg-dd-menu .lg-name{
	white-space: nowrap;
}

/* 吸顶/深色头时按钮配色（按站点 header.cli / header.on 自行调整） */
header.cli .lg-dd-btn,
header.on .lg-dd-btn{
	color: #333;
	border-color: rgba(0,0,0,.16);
	background: rgba(0,0,0,.03);
}
header.cli .lg-dd-btn:hover,
header.on .lg-dd-btn:hover,
header.cli .lg-dd.open .lg-dd-btn,
header.on .lg-dd.open .lg-dd-btn{
	background: rgba(173,191,170,.16);
	border-color: #adbfaa;
}
header.cli .lg-dd-btn .lg-code,
header.on .lg-dd-btn .lg-code{
	background: rgba(0,0,0,.08);
	color: #333;
}

/* 手机侧栏：竖排列表 */
.lg-switch--panel{
	float: none;
	display: flex;
	flex-direction: column;
	align-items: stretch;
	justify-content: flex-start;
	height: auto;
	gap: 10px;
	width: 100%;
}
.lg-switch--panel .lg-a{
	display: flex;
	align-items: center;
	gap: 10px;
	height: 46px;
	margin: 0 !important;
	padding: 0 14px !important;
	justify-content: flex-start;
	border-radius: 10px;
	border: none;
	background: #fff !important;
	color: #333 !important;
	font-size: 14px !important;
	text-decoration: none;
	box-shadow: 0 6px 18px rgba(0,0,0,.08);
}
.lg-switch--panel .lg-name{
	white-space: nowrap;
}
.lg-switch--panel .lg-code{
	display: inline-block;
	min-width: 28px;
	height: 22px;
	line-height: 22px;
	text-align: center;
	border-radius: 4px;
	background: #eef2ee;
	color: #333;
	font-size: 11px;
	font-weight: 700;
}
.lg-switch--panel .lg-a.on{
	background: #adbfaa !important;
	color: #fff !important;
	box-shadow: 0 8px 20px rgba(173,191,170,.4);
}
.lg-switch--panel .lg-a.on .lg-code{
	background: rgba(255,255,255,.28);
	color: #fff;
}
