/**
 * Chesterfield PDP chips — single outer border only.
 * Beats WVS + site-wide rs-pdp-conversion.css (which borders the INNER span).
 */

body.rs-chesterfield-pdp,
body.rs-chesterfield-pdp.woo-variation-swatches {
	--wvs-single-product-item-width: auto !important;
	--wvs-single-product-item-height: auto !important;
	--wvs-single-product-item-font-size: 15px !important;
	--wvs-item-box-shadow: none !important;
	--wvs-hover-item-box-shadow: none !important;
	--wvs-selected-item-box-shadow: none !important;
	--wvs-selected-item-background-color: #ffffff !important;
	--wvs-selected-item-text-color: #243447 !important;
	--wvs-selected-item-border-color: #243447 !important;
}

/* Hide WoodMart selected-value echo (": Deep (39 inches)") — mobile always injects it */
body.rs-chesterfield-pdp .wd-attr-selected,
body.rs-chesterfield-pdp form.variations_form .wd-attr-selected,
body.rs-chesterfield-pdp form.variations_form table.variations .wd-attr-selected,
body.rs-chesterfield-pdp form.variations_form table.variations th .wd-attr-selected,
body.rs-chesterfield-pdp form.variations_form table.variations .label .wd-attr-selected {
	display: none !important;
	visibility: hidden !important;
	width: 0 !important;
	height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	overflow: hidden !important;
	font-size: 0 !important;
	line-height: 0 !important;
	opacity: 0 !important;
	pointer-events: none !important;
}

/* Labels — title only, no colon */
body.rs-chesterfield-pdp form.variations_form table.variations {
	width: 100% !important;
	margin: 0 0 1rem !important;
	border: 0 !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .cell {
	display: block !important;
	width: 100% !important;
	padding: 0 !important;
	border: 0 !important;
	text-align: left !important;
	vertical-align: top !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations tr {
	display: block !important;
	margin: 0 0 1.15rem !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .label {
	display: block !important;
	margin: 0 0 0.5rem !important;
	padding: 0 !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .label label,
body.rs-chesterfield-pdp form.variations_form table.variations .label > * {
	display: inline !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .label label {
	margin: 0 !important;
	padding: 0 !important;
	font-size: 1.05rem !important;
	font-weight: 700 !important;
	line-height: 1.3 !important;
	letter-spacing: -0.01em !important;
	text-transform: none !important;
	white-space: normal !important;
	color: #243447 !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .label label::after,
body.rs-chesterfield-pdp form.variations_form table.variations label::after {
	content: none !important;
	display: none !important;
	margin: 0 !important;
}

body.rs-chesterfield-pdp form.variations_form table.variations .value {
	display: block !important;
	width: 100% !important;
}

/* Chip row */
body.rs-chesterfield-pdp ul.variable-items-wrapper,
body.rs-chesterfield-pdp .variable-items-wrapper,
body.rs-chesterfield-pdp .variable-items-wrapper.button-variable-items-wrapper,
body.rs-chesterfield-pdp .variable-items-wrapper.wvs-style-squared,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper {
	display: flex !important;
	flex-direction: row !important;
	flex-wrap: wrap !important;
	align-items: stretch !important;
	gap: 0.5rem !important;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
}

/* Outer chip — ONE border only */
body.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item:not(.radio-variable-item),
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.button-variable-item,
body.rs-chesterfield-pdp .wvs-style-squared.variable-items-wrapper .variable-item:not(.radio-variable-item).button-variable-item,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item {
	float: none !important;
	box-sizing: border-box !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: auto !important;
	min-width: 0 !important;
	max-width: none !important;
	height: auto !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border-radius: 6px !important;
	border: 1.5px solid #7fd4d1 !important;
	outline: none !important;
	background: #ffffff !important;
	-webkit-box-shadow: none !important;
	box-shadow: none !important;
	overflow: visible !important;
	cursor: pointer !important;
	transform: none !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item::before,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item::after,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-contents::before,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-contents::after {
	display: none !important;
	content: none !important;
	background: none !important;
	box-shadow: none !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-contents {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: auto !important;
	height: auto !important;
	min-height: 2.45rem !important;
	padding: 0.45rem 0.95rem !important;
	margin: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	-webkit-box-shadow: none !important;
	box-shadow: none !important;
}

/*
 * CRITICAL: rs-pdp-conversion.css borders the INNER .variable-item-span.
 * That is the second/oval border — strip it completely on Chesterfield.
 */
body.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item .variable-item-span,
body.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item > span,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-span,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-span-button,
body.rs-chesterfield-pdp .wvs-style-squared.variable-items-wrapper .variable-item:not(.radio-variable-item).button-variable-item .variable-item-span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item .variable-item-span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item > span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item:not(.radio-variable-item):hover .variable-item-span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item:not(.radio-variable-item):hover > span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item.selected .variable-item-span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item.selected > span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item:not(.radio-variable-item).selected .variable-item-span {
	display: block !important;
	padding: 0 !important;
	margin: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	outline: none !important;
	background: transparent !important;
	-webkit-box-shadow: none !important;
	box-shadow: none !important;
	font-size: 0.95rem !important;
	font-weight: 500 !important;
	line-height: 1.25 !important;
	color: #243447 !important;
	white-space: nowrap !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item:hover,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item:hover {
	border-color: #0abab5 !important;
	background: #ffffff !important;
	-webkit-box-shadow: none !important;
	box-shadow: none !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.selected,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.selected:not(.no-stock),
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item[aria-checked="true"],
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.button-variable-item.selected:not(.no-stock),
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item.selected {
	border: 2px solid #243447 !important;
	background: #ffffff !important;
	-webkit-box-shadow: none !important;
	box-shadow: none !important;
	color: #243447 !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.selected .variable-item-span,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item[aria-checked="true"] .variable-item-span,
body.single-product.rs-chesterfield-pdp ul.variable-items-wrapper .variable-item.button-variable-item.selected .variable-item-span {
	color: #243447 !important;
	font-weight: 600 !important;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}

body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.disabled,
body.rs-chesterfield-pdp .variable-items-wrapper .variable-item.disabled:hover {
	opacity: 0.38 !important;
}

body.rs-chesterfield-pdp form.variations_form .wd-reset-var {
	margin-top: 0.4rem !important;
}

@media (max-width: 520px) {
	body.rs-chesterfield-pdp .variable-items-wrapper .variable-item .variable-item-span {
		white-space: normal !important;
		text-align: center !important;
	}
}
