/**
 * MLabs Product Manager Frontend Styles
 * Compatible with Flatsome Theme & CURCY Multi Currency
 */

/* 1. Hide Native Selects without breaking accessibility or form submission */
.mlabs-native-select-wrap {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
	opacity: 0 !important;
	pointer-events: none !important;
}

/* 2. Swatches Container */
.mlabs-swatches-container {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 10px 0 18px 0;
}

/* 3. Swatch Button Base */
.mlabs-swatch-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: #ffffff;
	color: #334155;
	border: 1.5px solid #cbd5e1;
	font-family: inherit;
	font-size: 14px;
	line-height: 1.3;
	font-weight: 500;
	cursor: pointer;
	text-decoration: none;
	transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
	user-select: none;
	outline: none;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.mlabs-swatch-btn:hover {
	border-color: #70a8dc;
	background-color: #f8fafc;
	color: #0f172a;
	transform: translateY(-1px);
}

.mlabs-swatch-btn:active {
	transform: translateY(0);
}

/* Pill Style */
.mlabs-swatches-pill .mlabs-swatch-btn {
	border-radius: 30px;
	padding: 8px 18px;
}

/* Card Style */
.mlabs-swatches-card .mlabs-swatch-btn {
	border-radius: 8px;
	padding: 10px 20px;
}

/* Active / Selected State */
.mlabs-swatch-btn.mlabs-swatch-active {
	background: #70a8dc !important;
	border-color: #5892c9 !important;
	color: #ffffff !important;
	font-weight: 600;
	box-shadow: 0 3px 8px rgba(112, 168, 220, 0.35);
}

/* Disabled / Out of Stock State */
.mlabs-swatch-btn.mlabs-swatch-disabled {
	opacity: 0.45;
	background: #f1f5f9 !important;
	border-color: #e2e8f0 !important;
	color: #94a3b8 !important;
	text-decoration: line-through;
	cursor: not-allowed !important;
	pointer-events: none;
	transform: none !important;
	box-shadow: none !important;
}

/* 4. Single Price Optimization & Duplicate Suppression */
.woocommerce-variation-price {
	display: none !important;
}

.mlabs-single-price {
	display: inline-block;
}

.mlabs-price-from {
	font-size: 0.85em;
	font-weight: 400;
	opacity: 0.85;
	margin-right: 4px;
}

/* 5. Minimal Checkout Polish */
.woocommerce-checkout .woocommerce-billing-fields__field-wrapper {
	margin-bottom: 15px;
}

.woocommerce-checkout #billing_email_field input {
	border-radius: 8px;
	padding: 12px 14px;
	font-size: 15px;
	border: 1.5px solid #cbd5e1;
	transition: border-color 0.2s ease;
}

.woocommerce-checkout #billing_email_field input:focus {
	border-color: #70a8dc;
	box-shadow: 0 0 0 2px rgba(112, 168, 220, 0.2);
	outline: none;
}

/* Responsive adjustments */
@media (max-width: 549px) {
	.mlabs-swatches-container {
		gap: 8px;
	}
	.mlabs-swatches-pill .mlabs-swatch-btn {
		padding: 7px 14px;
		font-size: 13px;
	}
}
