/**
 * Tour price filter widget (shortcode UI).
 * Hook a range slider library to [data-tour-price-slider] when logic is added.
 */

.tour-price-filter {
	--tour-pf-accent: #2271b1;
	--tour-pf-accent-hover: #135e96;
	--tour-pf-surface: #f6f7f7;
	--tour-pf-border: #dcdcde;
	--tour-pf-muted: #646970;
	--tour-pf-text: #1d2327;
	box-sizing: border-box;
	max-width: 100%;
	padding: 16px 18px !important;
	background: var(--tour-pf-surface);
	border-radius: 12px;
	border: 1px solid var(--tour-pf-border);
	font-family: inherit;
	font-size: 14px;
	line-height: 1.45;
	color: var(--tour-pf-text);
}

.tour-price-filter *,
.tour-price-filter *::before,
.tour-price-filter *::after {
	box-sizing: border-box;
}

.tour-price-filter__summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	cursor: pointer;
	list-style: none;
	font-weight: 600;
	font-size: 15px;
	color: var(--tour-pf-text);
	padding: 0 !important;
	margin: 0 0 16px;
}

.tour-price-filter__summary::-webkit-details-marker {
	display: none;
}

.tour-price-filter__chevron {
	flex-shrink: 0;
	width: 10px;
	height: 10px;
	border-right: 2px solid var(--tour-pf-muted);
	border-bottom: 2px solid var(--tour-pf-muted);
	transform: rotate(45deg);
	margin-top: -4px;
	transition: transform 0.2s ease;
}

.tour-price-filter details[open] .tour-price-filter__chevron {
	transform: rotate(225deg);
	margin-top: 2px;
}

.tour-price-filter__body {
	padding-top: 0 !important;
}

/* Slider shell — target this root for noUiSlider or similar */
.tour-price-filter__slider {
	position: relative;
	height: 32px;
	margin: 4px 10px 20px;
	touch-action: none;
	cursor: pointer;
}

.tour-price-filter__slider-track {
	position: absolute;
	left: 0;
	right: 0;
	top: 50%;
	height: 6px;
	margin-top: -3px;
	background: #c3c4c7;
	border-radius: 999px;
}

.tour-price-filter__slider-range {
	position: absolute;
	left: 0;
	top: 50%;
	height: 6px;
	margin-top: -3px;
	width: 100%;
	max-width: 100%;
	background: var(--e-color-primary, #1e4d40);
	border-radius: 999px;
	pointer-events: none;
}

.tour-price-filter__handle {
	position: absolute;
	top: 50%;
	width: 20px;
	height: 20px;
	margin-top: -10px;
	margin-left: -10px;
	background: #fff;
	border: 2px solid var(--e-color-primary, #1e4d40);
	border-radius: 50%;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
	z-index: 2;
	pointer-events: auto;
	cursor: grab;
	touch-action: none;
}

.tour-price-filter__handle:active {
	cursor: grabbing;
}

.tour-price-filter__handle--min {
	left: 0;
}

.tour-price-filter__handle--max {
	left: 100%;
}

.tour-price-filter__inputs {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 16px;
}

.tour-price-filter__field {
	flex: 1;
	min-width: 0;
	padding: 10px 12px !important;
	background: #fff;
	border: 1px solid var(--tour-pf-border);
	border-radius: 10px;
}

.tour-price-filter__field-label {
	display: block;
	font-size: 12px;
	color: var(--tour-pf-muted);
	margin-bottom: 4px;
}

.tour-price-filter__value {
	display: block;
	width: 100%;
	margin: 0;
	padding: 0 !important;
	font: inherit;
	font-weight: 700;
	font-size: 15px;
	color: var(--tour-pf-text);
	line-height: 1.25;
}

.tour-price-filter__inputs-sep {
	flex: 0 0 auto;
	color: var(--tour-pf-muted);
	font-weight: 500;
	line-height: 1;
}

.tour-price-filter__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding-top: 16px !important;
	border-top: 1px solid var(--tour-pf-border);
}

.tour-price-filter__clear {
	display: inline-block;
	margin: 0;
	padding: 0 !important;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	font: inherit;
	font-size: 14px;
	font-weight: 400;
	line-height: inherit;
	color: var(--e-color-primary, #1e4d40);
	text-decoration: underline !important;
	text-decoration-line: underline;
	text-underline-offset: 3px;
	text-decoration-thickness: 1px;
	cursor: pointer;
	align-self: center;
	user-select: none;
}

.tour-price-filter__clear:hover,
.tour-price-filter__clear:focus-visible {
	color: #163d33;
	color: color-mix(in srgb, var(--e-color-primary, #1e4d40) 78%, #000);
	text-decoration: underline !important;
	text-decoration-line: underline;
}

.tour-price-filter__clear:focus-visible {
	outline: 2px solid var(--e-color-primary, #1e4d40);
	outline-offset: 2px;
}

.tour-price-filter__apply {
	margin: 0 !important;
	padding: 8px 22px !important;
	border: 0;
	border-radius: 999px;
	background: var(--tour-pf-accent);
	color: #fff;
	font: inherit;
	font-size: 12px;
	font-weight: 600;
	line-height: 1.3;
	cursor: pointer;
	transition: background 0.15s ease;
}

.tour-price-filter__apply:hover,
.tour-price-filter__apply:focus-visible {
	background: var(--tour-pf-accent-hover);
}
