/* Pearl variation UI - image cards */
.pearl-variations-form .pearl-attribute-row {
	margin-bottom: 1.5em;
}
.pearl-attribute-label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.5em;
}
.pearl-option-cards {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5em;
}
.pearl-option-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 0.5em;
	border: 2px solid #ddd;
	background: #fff;
	cursor: pointer;
	min-width: 110px;
	transition: border-color 0.2s, box-shadow 0.2s;
}
.pearl-option-card:hover {
	border-color: #999;
}
.pearl-option-card[aria-pressed="true"],
.pearl-option-card.selected {
	border-color: #22c55e;
	box-shadow: 0 0 0 2px rgba(34,197,94,0.3);
}
.pearl-option-card .pearl-option-img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	max-width: 120px;
	max-height: 120px;
}
.pearl-option-card .pearl-option-placeholder {
	width: 100px;
	height: 100px;
	background: #f0f0f0;
	border-radius: 4px;
}
.pearl-option-card .pearl-option-text {
	font-size: 0.85em;
	margin-top: 0.25em;
	text-align: center;
}
.pearl-letter-charm-row { margin-top: 1.5em; margin-bottom: 1em; }
.pearl-charm-hint { font-size: 0.9em; color: #666; margin-bottom: 0.5em; }
.pearl-letter-input-wrap {
	display: flex;
	align-items: center;
	gap: 0.5em;
	margin-bottom: 0.75em;
}
.pearl-letter-input {
	min-width: 280px;
	width: 100%;
	max-width: 320px;
	padding: 0.5em 0.75em;
	border: 1px solid #ddd;
	font-size: 0.8em;
	text-transform: uppercase;
	box-sizing: border-box;
}
.pearl-letter-price-hint {
	font-size: 0.9em;
	color: #666;
}
.pearl-letter-price-hint.has-letters { font-weight: 600; color: #22c55e; }
.pearl-letter-backspace {
	width: 44px;
	height: 44px;
	padding: 0;
	border: 2px solid #ddd;
	background: #fff;
	cursor: pointer;
	font-size: 1em;
}
.pearl-letter-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35em;
	margin-bottom: 0.5em;
}
.pearl-letter-btn {
	width: 44px;
	height: 44px;
	padding: 0;
	border: 2px solid #ddd;
	background: #fff;
	cursor: pointer;
	font-size: 1em;
	transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.pearl-letter-btn:hover { background: #f5f5f5; border-color: #999; }
.pearl-letter-backspace:hover {
	background: #f5f5f5;
	border-color: #999;
}
.pearl-letter-clear {
	width: auto;
	min-width: 44px;
	height: 44px;
	padding: 0 0.5em;
	font-size: 0.9em;
	cursor: pointer;
	background: #fff;
	border: 2px solid #ddd;
	color: #666;
	transition: border-color 0.2s, color 0.2s;
}
.pearl-letter-clear:hover {
	border-color: #999;
	color: #333;
}
.pearl-subtotal-row {
	margin: 1em 0;
	padding: 0.75em 0;
	border-top: 1px solid #eee;
}
.pearl-subtotal-label { margin-right: 0.5em; }

/* Price + Add to cart: single row, one actual price */
.pearl-price-add-to-cart-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 48px;
	margin-top: 48px;
}
.pearl-price-add-to-cart-row .pearl-subtotal-row {
	margin: 0;
	padding: 0;
	border: none;
	flex: 1;
	min-width: 0;
}
.pearl-price-add-to-cart-row .pearl-subtotal-value {
	font-size: 1.25em;
	font-weight: 600;
}
.pearl-price-add-to-cart-row .single_variation_wrap,
.pearl-price-add-to-cart-row .pearl-simple-add-to-cart-wrap {
	margin-bottom: 0;
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 0.5em;
}
/* Hide WC variation price - we show our calculated price only */
.pearl-variations-form .woocommerce-variation-price {
	display: none !important;
}

/* Hide quantity selector on Pearl product page */
.pearl-variations-form .single_variation_wrap .quantity,
.pearl-variations-form .variations_button .quantity,
.pearl-simple-add-to-cart-wrap .quantity {
	display: none !important;
}

/* Add to cart: button styling (layout handled by pearl-price-add-to-cart-row) */
.pearl-variations-form .woocommerce-variation-add-to-cart.variations_button {
	display: flex;
	justify-content: flex-end;
}
.pearl-variations-form .single_add_to_cart_button,
.pearl-simple-add-to-cart-wrap .single_add_to_cart_button {
	margin-left: auto;
}

/* Add to cart button: TPS style (black bg, white text, match variable product) */
.pearl-price-add-to-cart-row .single_add_to_cart_button {
	-webkit-appearance: none;
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0 32px;
	height: 50px;
	min-width: 200px;
	background: #000;
	color: #fff;
	border: none;
	border-radius: 0;
	font-size: 15px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	cursor: pointer;
	transition: box-shadow 0.2s;
}
.pearl-price-add-to-cart-row .single_add_to_cart_button:hover {
	background: #1a1a1a;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
}

/* Mobile: dropdown/collapsed option style */
@media (max-width: 991px) {
	.pearl-mobile-option-box {
		display: flex !important;
		align-items: center;
	}
	.tps_productDetailOptionType_optionsContainer .tps_productDetailOptionType_titleDesktop,
	.tps_productDetailOptionType_optionsContainer .tps_productDetailOptionType_selectedName,
	.tps_productDetailOptionType_optionsContainer .tps_productDetailOptionType_arrow {
		display: none !important;
	}
	.tps_productDetailOptionType_optionsContainer .tps_productDetailOptionType_boxMobile {
		display: block !important;
	}
	.pearl-mobile-option-box .tps_productDetailOptionType_mobileBox {
		display: flex;
		align-items: center;
		justify-content: space-between;
		width: 100%;
		padding: 12px 16px;
		border: 1px solid #ddd;
		background: #fff;
		cursor: pointer;
		margin-bottom: 12px;
	}
	.pearl-mobile-option-box .tps_productDetailOptionType_mobileHeader {
		display: flex;
		align-items: center;
		justify-content: space-between;
		flex: 1;
	}
	.pearl-mobile-option-box .tps_productDetailOptionType_mobileTitle {
		font-weight: 500;
	}
	.pearl-mobile-option-box .tps_productDetailOptionType_mobilePrice {
		margin: 0 12px;
		color: #666;
	}
	.pearl-mobile-chevron {
		display: inline-flex;
		opacity: 0.6;
	}
	.tps_productDetailOptionType_boxDesktop {
		display: none !important;
	}
	.tps_productDetailOptionType_boxDesktop.tps_productDetailOptionType_boxDesktopShowed {
		display: block !important;
	}
}
@media (min-width: 992px) {
	.pearl-mobile-option-box {
		display: none !important;
	}
}
