/**
 * Teco Taxonomy Filter — 基础布局（具体颜色/间距可在 Elementor「样式」里覆盖；无变量时接近侧栏筛选样式）。
 */

.elementor-widget-teco-taxonomy-filter.teco-tax-filter--vis-hidden {
	display: none !important;
}

.elementor-widget-teco-taxonomy-filter .teco-taxonomy-filter-widget.teco-tax-filter--layout {
	box-sizing: border-box;
	width: 100%;
	border: none;
}

.elementor-widget-teco-taxonomy-filter .teco-tax-filter__heading {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0.65rem 1rem;
	overflow: hidden;
	text-align: center;
	font-weight: 700;
	font-size: 24px;
	line-height: 1.3;
	letter-spacing: 0.02em;
	color: #f3f3f3;
	background: linear-gradient(180deg, #82c9f1 0%, #1d507a 100%);
}

.elementor-widget-teco-taxonomy-filter .teco-tax-filter__heading-text {
	display: block;
	min-width: 0;
	flex: 1 1 auto;
	overflow-wrap: break-word;
	word-break: break-word;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-heading--ellipsis .teco-tax-filter__heading-text {
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	word-break: normal;
	overflow-wrap: normal;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 0;
	list-style: none;
	margin: 0;
	padding: 11px;
	max-width: 100%;
	box-sizing: border-box;
	flex-direction: column;
	/* 无 style 控件默认时的兜底背景 */
	background-color: #f1f5f9;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button {
	display: block;
	width: 100%;
	min-width: 0;
	margin: 0;
	box-sizing: border-box;
	cursor: pointer;
	font: inherit;
	text-align: left;
	line-height: 1.4;
	color: var(--e-filter-normal-text-color, #1e293b);
	background-color: transparent;
	border: none;
	border-radius: 0;
	padding: 0.6rem 0.35rem;
	box-shadow: none;
	appearance: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button:hover {
	color: var(--e-filter-hover-text-color, #0f172a);
	background-color: rgba(226, 232, 240, 0.65);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button:focus {
	outline: 2px solid #2563eb;
	outline-offset: 1px;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button:focus:not(:focus-visible) {
	outline: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button[aria-pressed="true"] {
	color: var(--e-filter-active-text-color, #F0A500);
	background-color: transparent;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter > .teco-e-filter__item--button:not(:last-child),
.elementor-widget-teco-taxonomy-filter .teco-e-filter > .teco-e-filter__branch:not(:last-child) {
	border-bottom: 1px solid #e2e8f0;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__drawer > .teco-e-filter__item--button:not(:last-child),
.elementor-widget-teco-taxonomy-filter .teco-e-filter__drawer > .teco-e-filter__branch:not(:last-child) {
	border-bottom: 1px solid #e2e8f0;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch {
	width: 100%;
	min-width: 0;
	box-sizing: border-box;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row {
	display: flex;
	flex-direction: row;
	align-items: stretch;
	width: 100%;
	min-width: 0;
	box-sizing: border-box;
	gap: 0.15rem;
	margin: 0;
	padding: 0;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row .teco-e-filter__item--button.teco-e-filter__item--branch-main {
	flex: 1 1 0%;
	min-width: 0;
	width: auto;
	border-bottom: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row .teco-e-filter__row--branch-head {
	flex: 1 1 0%;
	min-width: 0;
	margin: 0;
	border-bottom: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row:not(:last-child) {
	border-bottom: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	min-height: 2.25rem;
	margin: 0;
	padding: 0;
	border: none;
	border-radius: 0;
	background: transparent;
	color: var(--e-filter-normal-text-color, #64748b);
	cursor: pointer;
	box-sizing: border-box;
	transition: color 0.15s ease, background-color 0.15s ease;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle:hover {
	color: var(--e-filter-hover-text-color, #0f172a);
	background-color: rgba(226, 232, 240, 0.45);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle:focus {
	outline: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle:focus-visible {
	outline: 2px solid #2563eb;
	outline-offset: 1px;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle-icon {
	display: block;
	width: 0;
	height: 0;
	border-style: solid;
	border-width: 0.28rem 0 0.28rem 0.42rem;
	border-color: transparent transparent transparent currentColor;
	transform-origin: 30% 50%;
	transition: transform 0.2s ease;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__toggle[aria-expanded='true'] .teco-e-filter__toggle-icon {
	transform: rotate(90deg);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__drawer {
	box-sizing: border-box;
	width: 100%;
	padding: 0 0 0 0.65rem;
	margin: 0;
	border: none;
	background: rgba(241, 245, 249, 0.85);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__drawer[hidden] {
	display: none !important;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__row {
	display: flex;
	align-items: center;
	gap: 0.55rem;
	margin: 0;
	padding: 0.45rem 0.35rem;
	cursor: pointer;
	width: 100%;
	min-width: 0;
	box-sizing: border-box;
	transition: background-color 0.15s ease;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__row:not(:last-child) {
	border-bottom: 1px solid #e2e8f0;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__row:hover {
	background-color: rgba(226, 232, 240, 0.5);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__input {
	margin: 0;
	flex-shrink: 0;
	box-sizing: border-box;
	width: 1.0625rem;
	height: 1.0625rem;
	min-width: 1.0625rem;
	min-height: 1.0625rem;
	appearance: none;
	-webkit-appearance: none;
	border-style: solid;
	border-width: 1px;
	border-color: #64748b;
	border-radius: 2px;
	background-color: #fff;
	cursor: pointer;
	vertical-align: middle;
	position: relative;
	align-self: center;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__input:checked {
	background-color: #3b89b6;
	border-color: #3b89b6;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__input:checked::after {
	content: '';
	position: absolute;
	box-sizing: border-box;
	left: 18%;
	top: 6%;
	width: 38%;
	height: 62%;
	border: solid var(--teco-cb-check, #fff);
	border-width: 0 2.5px 2.5px 0;
	transform: rotate(45deg) scale(var(--teco-cb-check-scale, 1.3));
	transform-origin: 50% 75%;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__input:focus {
	outline: none;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__input:focus-visible {
	outline: 2px solid #2563eb;
	outline-offset: 2px;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__check-label {
	/* flex-basis: 0 + grow：整行里除勾选框外宽度都给文字，减少「看起来够宽却提前断行」 */
	flex: 1 1 0%;
	min-width: 0;
	text-align: left;
	overflow-wrap: normal;
	word-break: normal;
	hyphens: none;
	color: var(--e-filter-normal-text-color, #1e293b);
}

/* 统一继承 Elementor「文字排版」控制，避免 checkbox/span/button 被主题样式覆盖。 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter__row,
.elementor-widget-teco-taxonomy-filter .teco-e-filter__check-label,
.elementor-widget-teco-taxonomy-filter .teco-e-filter__item--button,
.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row .teco-e-filter__item--branch-main {
	font-family: inherit;
	font-size: inherit;
	font-style: inherit;
	font-weight: inherit;
	line-height: inherit;
	letter-spacing: inherit;
	text-transform: inherit;
	text-decoration: inherit;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-selected-bold-yes .teco-e-filter__item--button[aria-pressed='true'],
.elementor-widget-teco-taxonomy-filter.teco-tax-filter-selected-bold-yes .teco-e-filter__row.is-active .teco-e-filter__check-label,
.elementor-widget-teco-taxonomy-filter.teco-tax-filter-selected-bold-yes .teco-e-filter__branch-row.is-active .teco-e-filter__item--button,
.elementor-widget-teco-taxonomy-filter.teco-tax-filter-selected-bold-yes .teco-e-filter__branch-row.is-active .teco-e-filter__check-label {
	font-weight: 700;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-center .teco-e-filter__item--button {
	text-align: center;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-right .teco-e-filter__item--button {
	text-align: right;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-center .teco-e-filter__row {
	justify-content: center;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-center .teco-e-filter__check-label {
	flex: 0 1 auto;
	min-width: 0;
	text-align: center;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-right .teco-e-filter__row {
	justify-content: flex-end;
}

.elementor-widget-teco-taxonomy-filter.teco-tax-filter-item-halign-right .teco-e-filter__check-label {
	flex: 0 1 auto;
	min-width: 0;
	text-align: right;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__row.is-active .teco-e-filter__check-label,
.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row.is-active .teco-e-filter__check-label {
	color: var(--e-filter-active-text-color, #F0A500);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter__branch-row.is-active .teco-e-filter__item--button[aria-pressed='true'] {
	color: var(--e-filter-active-text-color, #F0A500);
}

/* 横向排列（项间距与纵向共用 .teco-e-filter 的 gap，样式面板可覆盖） */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal {
	flex-direction: row;
	flex-wrap: nowrap;
	padding: 11px;
	align-items: flex-start;
	justify-content: flex-start;
	overflow-x: hidden;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal > .teco-e-filter__item--button {
	width: auto;
	flex: 0 1 auto;
	min-width: 0;
	white-space: nowrap;
	overflow: visible;
	text-overflow: clip;
	font-size: var(--teco-horizontal-main-font-size, 14px);
	padding-left: 0.25rem;
	padding-right: 0.25rem;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__item--button {
	width: auto;
	flex: 1 1 auto;
	min-width: 0;
	border-bottom: none;
	padding-top: 0.5rem;
	padding-bottom: 0.5rem;
	/* 左右由内联/「项左右内边距」控件覆盖，避免简写盖住缩进 */
	padding-left: 0.5rem;
	padding-right: 0.5rem;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__row {
	width: auto;
	flex: 1 1 auto;
	border-bottom: none;
}

/* ─── 横向手风琴：子级内嵌下拉列 ──────────────────────────────────────── */
/*
 * 抽屉保持正常流（不用 position:absolute），避免被 Elementor
 * 容器的 overflow:hidden 裁剪。展开时在顶级按钮正下方以列式展示子分类。
 */

/* branch 在横向中是纵向的 flex 列，收缩到内容宽 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal > .teco-e-filter__branch {
	width: auto;
	flex: 0 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	align-items: stretch;
}

/* branch-row：与 branch 等宽 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal > .teco-e-filter__branch > .teco-e-filter__branch-row {
	width: 100%;
	min-width: 0;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal > .teco-e-filter__branch > .teco-e-filter__branch-row .teco-e-filter__item--branch-main,
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal > .teco-e-filter__branch > .teco-e-filter__branch-row .teco-e-filter__row--branch-head {
	font-size: var(--teco-horizontal-main-font-size, 14px);
	white-space: nowrap;
	overflow: visible;
	text-overflow: clip;
	padding-left: 0.25rem;
	padding-right: 0.25rem;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__toggle {
	width: 1.6rem;
	min-height: 2rem;
}

/* 横向箭头：收起朝上，展开朝下 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__toggle-icon {
	transform: rotate(-90deg);
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__toggle[aria-expanded='true'] .teco-e-filter__toggle-icon {
	transform: rotate(90deg);
}

/* 横向抽屉：内嵌显示（展开时允许该项自动增高） */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__drawer {
	position: static;
	width: 100%;
	min-width: 0;
	padding: 4px 0;
	border-top: 1px solid #e2e8f0;
	background: rgba(241, 245, 249, 0.97);
	box-shadow: 0 4px 8px -2px rgba(0, 0, 0, 0.12);
	max-height: none;
	overflow: visible;
}

/* 打开时以列式展示子项 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__drawer:not([hidden]) {
	display: flex;
	flex-direction: column;
}

/* 抽屉子项：宽度充满 branch，竖向排列 */
.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__drawer .teco-e-filter__item--button {
	width: 100%;
	flex: 0 0 auto;
	text-align: left;
	border-bottom: 1px solid rgba(226, 232, 240, 0.7);
	padding: 0.4rem 0.75rem;
}

.elementor-widget-teco-taxonomy-filter .teco-e-filter--horizontal .teco-e-filter__drawer .teco-e-filter__item--button:last-child {
	border-bottom: none;
}
