/**
 * 歌单头部：标题、分类标签栏、歌单搜索
 * 加载顺序：layout → player-bar → library-header → song-panel → playlist → overrides（见 index.html），顺序不可调换。
 */

/* ================ 头部导航栏样式优化 ================ */
.list_header {
	position: relative;
	width: 100%;
	height: 82px;
	background: var(--surface-muted);
	border-radius: 16px;
	border: 1px solid var(--border-subtle);
	padding: 0 14px 0 18px;
	display: flex;
	align-items: center;
	overflow: hidden;
	flex-shrink: 0;
	gap: 18px;
}

.library-summary {
	width: 112px;
	flex: 0 0 112px;
}

.library-summary h1 {
	font-size: 21px;
	line-height: 1.2;
	font-weight: 700;
	color: var(--text-primary);
}

.library-count {
	display: block;
	margin-top: 5px;
	font-size: 12px;
	line-height: 1.2;
	color: var(--text-tertiary);
}

/* 标签栏容器样式 */
.list_header .list-tab {
	display: flex;
	align-items: center;
	gap: 8px;
	height: 100%;
	min-width: 0;
	flex: 1;
	overflow-x: auto;
	scrollbar-width: none;
	/* Firefox */
	-ms-overflow-style: none;
	/* IE and Edge */
}

/* 隐藏滚动条 */
.list_header .list-tab::-webkit-scrollbar {
	display: none;
}

/* 标签按钮样式 */
.list_header .list-tab>button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 15px;
	letter-spacing: 0;
	padding: 8px 16px;
	min-width: 82px;
	height: 36px;
	border-radius: 999px;
	color: var(--text-secondary);
	transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
	cursor: pointer;
	white-space: nowrap;
	border: 1px solid transparent;
}

/* 标签悬停效果 */
.list_header .list-tab>button:hover {
	background: var(--surface-hover);
	color: var(--white-color);
}

/* 激活状态标签样式 */
.list-tab>button.active {
	color: var(--theme-color);
	background: var(--surface-active);
	font-weight: 600;
	border-color: var(--border-strong);
}

/* ================ 歌单搜索 ================ */
.list-search {
	position: relative;
	display: flex;
	align-items: center;
	flex-shrink: 0;
	height: 42px;
	margin-bottom: 12px;
	border-radius: 999px;
	border: 1px solid var(--border-subtle);
	background: var(--surface-muted);
	transition: border-color 0.16s ease, background 0.16s ease;
}

.list-search:focus-within {
	border-color: var(--border-strong);
	background: var(--surface-active);
	/* 焦点环画在胶囊外框上（随圆角），代替输入框自身的方形 outline */
	outline: 2px solid var(--focus-ring, #fff);
	outline-offset: 2px;
}

.list-search .list-search-input:focus-visible {
	outline: none;
}

.list-search-icon {
	position: absolute;
	left: 15px;
	width: 17px;
	height: 17px;
	color: var(--text-tertiary);
	pointer-events: none;
}

.list-search-input {
	width: 100%;
	height: 100%;
	padding: 0 42px 0 42px;
	border: 0;
	outline: none;
	background: transparent;
	color: var(--text-primary);
	font: inherit;
	font-size: 14px;
	/* 输入框需要允许选中文本（body 全局禁用了文本选择） */
	user-select: text;
	-webkit-user-select: text;
	-webkit-appearance: none;
	appearance: none;
}

.list-search-input::placeholder {
	color: var(--text-tertiary);
}

/* 隐藏浏览器自带的清除按钮，统一使用自定义按钮 */
.list-search-input::-webkit-search-cancel-button,
.list-search-input::-webkit-search-decoration {
	-webkit-appearance: none;
	appearance: none;
}

.list-search-clear {
	position: absolute;
	right: 6px;
	width: 30px;
	height: 30px;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	color: var(--text-secondary);
	cursor: pointer;
}

.list-search-clear[hidden] {
	display: none;
}

.list-search-clear:hover {
	background: var(--surface-hover);
	color: var(--white-color);
}

.list-search-clear .icon {
	width: 15px;
	height: 15px;
}

/* 搜索命中的文字 */
.wrapper-contentList mark {
	background: transparent;
	/* 与进度条填充同色系的暖色，在各主题的冷色底上都足够醒目 */
	color: rgb(255, 193, 120);
	font-weight: 600;
}

/* 搜索无结果 / 空分类提示 */
.wrapper-contentList .contentList-empty {
	padding: 48px 16px;
	text-align: center;
	font-size: 14px;
	line-height: 1.6;
	color: var(--text-tertiary);
}

/* 平板适配 */
@media (max-width: 1200px) and (min-width: 769px) {
	.app_layout {
		grid-template-columns: minmax(0, 1.4fr) minmax(320px, 1fr);
		gap: 18px;
	}
}

/* 手机端响应式适配 - 详细规则在 response.css 中 */
@media (max-width: 768px) {
	/* 基础样式保留,详细适配在 response.css */
}
