/**
 * 全模板通用 - 选择应用下方应用简介（标题与内容同一行）
 */
.qy-app-intro-box {
	margin-top: 10px;
	padding: 12px 16px;
	border-radius: 10px;
	background: #eff6ff;
	border: 1px solid #bfdbfe;
	color: #1e40af;
	font-size: 13px;
	line-height: 1.6;
	text-align: left;
	word-break: break-word;
}

.qy-app-intro-box.is-hidden {
	display: none;
}

.qy-app-intro-box .qy-app-intro-title {
	display: inline;
	font-size: 13px;
	font-weight: 600;
	color: #1d4ed8;
	margin: 0;
	white-space: nowrap;
}

.qy-app-intro-box .qy-app-intro-body {
	display: inline;
	color: #1e3a8a;
}

.card-body .qy-app-intro-box,
.layui-input-block .qy-app-intro-box,
.layui-form-item .layui-input-block .qy-app-intro-box,
.form-group .qy-app-intro-box,
.mg-field .qy-app-intro-box {
	margin-top: 10px;
	margin-bottom: 4px;
	width: 100%;
	box-sizing: border-box;
}

.qy-app-intro-panel .qy-app-intro-body p {
	display: inline;
	margin: 0;
}

/* 添加授权 - 应用权限彩色徽章 */
.qy-app-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	padding: 2px 10px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 600;
	line-height: 1.5;
	letter-spacing: 0.02em;
}

.qy-app-badge--agent {
	color: #1d4ed8;
	background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
	border: 1px solid #93c5fd;
	box-shadow: 0 1px 2px rgba(29, 78, 216, 0.08);
}

.qy-app-badge--partner {
	color: #047857;
	background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
	border: 1px solid #6ee7b7;
	box-shadow: 0 1px 2px rgba(4, 120, 87, 0.08);
}

/* 添加授权 - 自定义应用下拉（内联权限徽章） */
.qy-app-select-wrap--perm {
	position: relative;
	width: 100%;
}

.qy-app-select-native {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

.qy-app-select-custom {
	position: relative;
	width: 100%;
}

.qy-app-select-trigger {
	display: flex;
	align-items: center;
	flex-wrap: nowrap;
	gap: 0;
	width: 100%;
	text-align: left;
	cursor: pointer;
	background: #fff;
	appearance: none;
	-webkit-appearance: none;
}

.qy-app-select-trigger-label {
	flex: 1 1 auto;
	min-width: 0;
	display: inline-flex;
	align-items: center;
	flex-wrap: nowrap;
	gap: 0;
	overflow: hidden;
}

.qy-app-select-trigger.layui-input,
.qy-app-select-trigger.form-control {
	display: flex !important;
	align-items: center;
	height: auto;
	min-height: 38px;
	line-height: 1.5;
}

.qy-app-select-trigger:focus {
	outline: none;
	box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6);
}

.qy-app-select-trigger-name {
	flex: 0 1 auto;
	min-width: 0;
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.qy-app-select-trigger-badges,
.qy-app-select-item-badges {
	display: inline-flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: 4px;
	flex-shrink: 0;
	margin: 0 0 0 1em;
	padding: 0;
}

.qy-app-select-trigger-badges:empty,
.qy-app-select-item-badges:empty {
	display: none;
	margin-left: 0;
}

.qy-app-select-trigger-badges .qy-app-badge,
.qy-app-select-item-badges .qy-app-badge {
	min-width: 0;
	padding: 1px 6px;
}

.qy-app-select-arrow {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	margin-left: auto;
	padding-left: 8px;
}

.qy-app-select-arrow::after {
	content: '';
	display: block;
	width: 0;
	height: 0;
	border: 5px solid transparent;
	border-top-color: #888;
	margin-top: 5px;
}

.qy-app-select-menu {
	display: none;
	position: absolute;
	top: calc(100% + 2px);
	left: 0;
	right: 0;
	z-index: 1050;
	max-height: 280px;
	overflow-y: auto;
	margin: 0;
	padding: 4px 0;
	list-style: none;
	background: #fff;
	border: 1px solid #d2d6de;
	border-radius: 4px;
	box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
}

.qy-app-select-wrap--perm.is-open .qy-app-select-menu {
	display: block;
}

.qy-app-select-item {
	display: block;
	padding: 8px 12px;
	cursor: pointer;
	font-size: 14px;
	line-height: 1.5;
}

.qy-app-select-item:hover,
.qy-app-select-item.is-selected {
	background: #f0f7ff;
}

.qy-app-select-item-name {
	display: inline;
	line-height: 1.5;
	vertical-align: baseline;
}

.input-group > .qy-app-select-wrap--perm {
	position: relative;
	z-index: 2;
	float: left;
	width: 100%;
	margin-bottom: 0;
	display: block;
	min-width: 0;
}

.input-group > .qy-app-select-wrap--perm .qy-app-select-custom,
.input-group > .qy-app-select-wrap--perm .qy-app-select-trigger {
	width: 100%;
}

.layui-input-block > .qy-app-select-wrap--perm {
	width: 100%;
}

.col-sm-8 > .qy-app-select-wrap--perm {
	width: 100%;
}

/* 添加授权 / 卡密授权 - 表单页通用布局（moyu、appui、qingyuan 等） */
.card-body.qy-form-page .form-group {
	margin-bottom: 18px;
}

.card-body.qy-form-page .form-group > label {
	display: block;
	margin-bottom: 8px;
	font-size: 14px;
	font-weight: 600;
	color: #334155;
}

.card-body.qy-form-page .help-block {
	margin: 8px 0 0;
	font-size: 13px;
	color: #64748b;
	line-height: 1.6;
}

.card-body.qy-form-page .help-block code {
	color: #dc2626;
	background: #fef2f2;
	padding: 1px 6px;
	border-radius: 4px;
}
