/**
 * Meowtrick Custom — product options form (Acowebs WCPA) restyled to follow
 * WoodMart's own variation form and swatches (css/parts/woo-mod-variation-form,
 * woo-mod-swatches-*). Typography is inherited from the theme and every color,
 * border and radius comes from WoodMart's CSS variables, so changes made in
 * Theme Settings carry over to the form.
 */
.wcpa_form_outer {
	--mt-ink: var(--color-gray-900, #242424);
	--mt-line: var(--brdcolor-gray-300, rgba(0, 0, 0, 0.105));
	--mt-radius: var(--wd-form-brd-radius, 0px);
	margin: 0 0 20px;
	padding: 0;
	font: inherit;
	color: var(--wd-text-color);
}

.wcpa_form_outer .wcpa_wrap,
.wcpa_form_outer .wcpa_section,
.wcpa_form_outer .wcpa_row {
	margin: 0;
	padding: 0;
}

/* Field block + label (matches "table.variations label") ----------------- */
.wcpa_form_outer .wcpa_field_wrap {
	margin: 0 0 20px !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 0;
	min-width: 0;
}

.wcpa_form_outer .wcpa_field_wrap > .wcpa_field_label {
	display: block;
	width: 100%;
	margin: 0 0 10px !important;
	padding: 0 !important;
	font-family: inherit;
	font-size: inherit !important;
	font-style: inherit;
	font-weight: 600 !important;
	line-height: var(--wd-text-line-height, 1.6);
	text-transform: none;
	color: var(--wd-title-color, #242424) !important;
}

.wcpa_form_outer .wcpa_required_ast {
	display: none;
}

.wcpa_form_outer .wcpa_selected_items {
	display: inline !important;
	margin: 0;
	font-weight: var(--wd-text-font-weight, 400);
	color: var(--wd-text-color) !important;
}

.wcpa_form_outer .wcpa_selected_items::before {
	content: ": ";
	font-weight: 600;
	color: var(--wd-title-color, #242424);
}

.wcpa_form_outer .wcpa_selected_items span {
	color: inherit !important;
}

.wcpa_form_outer .wcpa_field_desc {
	margin: -4px 0 10px;
	font-size: 14px;
	line-height: var(--wd-text-line-height, 1.6);
	color: var(--wd-text-color);
}

.wcpa_form_outer .wcpa_field_error {
	font-size: 14px;
	color: #e01020;
}

/* Per-field price line ("$0.00" under each field): every surcharge is already
   printed on its option button and in the total, so this line is hidden. */
.wcpa_form_outer .wcpa_field_price {
	display: none !important;
}

/* Button options (matches WoodMart text swatches, filled when active) ------ */
.wcpa_form_outer .wcpa_type_radio-group .wcpa_fl_inline {
	display: grid !important;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	align-items: stretch !important;
	gap: 10px;
}

.wcpa_form_outer .wcpa_type_radio-group.mt-tee-type .wcpa_fl_inline {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.wcpa_form_outer .wcpa_type_radio-group.mt-size .wcpa_fl_inline {
	grid-template-columns: repeat(5, minmax(0, 1fr));
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio {
	display: flex;
	margin: 0 !important;
	padding: 0 !important;
	min-width: 0;
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label {
	display: flex !important;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 2px;
	flex: 1 1 auto;
	width: 100%;
	height: auto;
	min-height: var(--wd-form-height, 42px);
	margin: 0 !important;
	padding: 5px 8px !important;
	background: transparent !important;
	border: 1px solid var(--mt-line) !important;
	border-radius: var(--mt-radius) !important;
	box-shadow: none !important;
	outline: 0 !important;
	font-family: inherit;
	font-size: 14px !important;
	font-weight: 600 !important;
	line-height: 1.2;
	text-align: center;
	color: var(--mt-ink) !important;
	cursor: pointer;
	transition: all 0.25s ease;
}

@media (hover: hover) {
	.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label:hover {
		border-color: var(--mt-ink) !important;
	}
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio.wcpa_selected label,
.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label:has(input:checked) {
	background: var(--mt-ink) !important;
	border-color: var(--mt-ink) !important;
	color: var(--color-white, #fff) !important;
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label:has(input:focus-visible) {
	outline: 2px solid var(--mt-ink) !important;
	outline-offset: 2px;
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_check {
	display: none !important;
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label .wcpa_option_price {
	font-size: 12px;
	font-weight: var(--wd-text-font-weight, 400);
	line-height: 1.2;
	color: var(--color-gray-500, #767676);
	white-space: nowrap;
}

.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio.wcpa_selected label .wcpa_option_price,
.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label:has(input:checked) .wcpa_option_price {
	color: rgba(255, 255, 255, 0.8);
}

/* Color swatches (matches WoodMart round swatches, size M, style 2) -------- */
.wcpa_form_outer .wcpa_type_color-group .wcpa_group_field {
	display: flex !important;
	flex-wrap: wrap;
	gap: 10px !important;
}

.wcpa_form_outer .wcpa_color {
	position: relative;
	margin: 0 !important;
	padding: 0 !important;
}

.wcpa_form_outer .wcpa_color label {
	display: block;
	margin: 0 !important;
	padding: 0;
	cursor: pointer;
}

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

.wcpa_form_outer .wcpa_color_wrap {
	display: flex !important;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 35px !important;
	height: 35px !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 4px !important;
	border: 0 !important;
	border-radius: 50% !important;
	box-shadow: 0 0 0 1px var(--brdcolor-gray-200, rgba(0, 0, 0, 0.075)) inset !important;
	transition: all 0.25s ease;
}

.wcpa_form_outer .wcpa_color_bg {
	display: block !important;
	flex: 0 0 auto;
	box-sizing: border-box;
	width: 27px !important;
	height: 27px !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	font-size: 0;
	line-height: 0;
	border: 0 !important;
	border-radius: 50% !important;
	outline: 0 !important;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.08) inset !important;
}

.wcpa_form_outer .wcpa_color_bg::before,
.wcpa_form_outer .wcpa_color_bg::after {
	display: none !important;
}

@media (hover: hover) {
	.wcpa_form_outer .wcpa_color:hover .wcpa_color_wrap {
		box-shadow: 0 0 0 1px var(--mt-ink) inset !important;
	}
}

.wcpa_form_outer .wcpa_color.wcpa_selected .wcpa_color_wrap,
.wcpa_form_outer .wcpa_color:has(input:checked) .wcpa_color_wrap {
	box-shadow: 0 0 0 2px var(--mt-ink) inset !important;
}

.wcpa_form_outer .wcpa_color:has(input:focus-visible) .wcpa_color_wrap {
	outline: 2px solid var(--mt-ink);
	outline-offset: 2px;
}

/* Text input: hand it back to the theme's own input styling ---------------- */
.wcpa_form_outer .wcpa_type_text input.wcpa_field {
	width: 100%;
	max-width: 100%;
	height: var(--wd-form-height, 42px);
	margin: 0;
	padding: 0 15px;
	background-color: var(--wd-form-bg, transparent) !important;
	border: var(--wd-form-brd-width, 1px) solid var(--wd-form-brd-color, rgba(0, 0, 0, 0.1)) !important;
	border-radius: var(--mt-radius) !important;
	box-shadow: none !important;
	font: inherit;
	font-size: 14px;
	color: var(--wd-form-color, inherit);
	transition: border-color 0.5s ease;
}

.wcpa_form_outer .wcpa_type_text input.wcpa_field:focus {
	border-color: var(--wd-form-brd-color-focus, rgba(0, 0, 0, 0.15)) !important;
	outline: 0;
}

.wcpa_form_outer .wcpa_type_text input.wcpa_field::placeholder {
	color: var(--wd-form-placeholder-color, #767676);
	opacity: 1;
}

.wcpa_form_outer .mt-personalization > .wcpa_field_label::after {
	content: " (optional)";
	font-weight: var(--wd-text-font-weight, 400);
	color: var(--wd-text-color);
}

/* Price summary: only the total, styled like the theme's ".price" ---------- */
.wcpa_price_summary {
	margin: 0 0 20px !important;
	padding: 15px 0 0 !important;
	border-top: 1px solid var(--brdcolor-gray-300, rgba(0, 0, 0, 0.105)) !important;
	color: var(--wd-text-color);
}

.wcpa_price_summary .wcpa_options_total,
.wcpa_price_summary .wcpa_product_total {
	display: none !important;
}

.wcpa_price_summary .wcpa_total {
	display: flex !important;
	align-items: baseline;
	justify-content: space-between;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	font-size: inherit;
	font-weight: 600;
	line-height: var(--wd-text-line-height, 1.6);
	color: var(--wd-title-color, #242424);
}

.wcpa_price_summary .wcpa_total .wcpa_price_outer {
	font-size: 22px;
	font-weight: 600;
	color: var(--wd-primary-color, #242424);
}

.wcpa_price_summary .wcpa_total del {
	margin: 0 6px 0 0;
	font-size: 70%;
	font-weight: 400;
	color: var(--color-gray-300, #bbb);
	opacity: 1;
}

/* Mobile ------------------------------------------------------------------- */
@media (max-width: 480px) {
	.wcpa_form_outer .wcpa_type_radio-group .wcpa_fl_inline {
		gap: 8px;
	}

	.wcpa_form_outer .wcpa_type_radio-group.mt-size .wcpa_fl_inline {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}

	.wcpa_form_outer .wcpa_type_radio-group .wcpa_radio label {
		padding: 5px 4px !important;
	}
}
