/**
 * MLabs Paddle Gateway - Frontend Checkout & Paddle Buy Now Styling
 *
 * Provides non-intrusive styling for Paddle.js checkout and the optional "Paddle Buy Now" button.
 * Preserves standard WooCommerce "Add to Cart" and theme buttons without interference.
 *
 * @package MLabs_Paddle_Gateway
 * @version 1.4.0
 */

/* 1. Paddle Buy Now Button Wrapper (Single Product Pages) */
form.cart > .mlabs-paddle-buy-now-wrapper,
.woocommerce-variation-add-to-cart > .mlabs-paddle-buy-now-wrapper,
form.cart .mlabs-paddle-buy-now-wrapper,
.mlabs-paddle-buy-now-wrapper {
	display: inline-flex !important;
	flex-direction: column !important;
	align-items: stretch !important;
	vertical-align: middle !important;
	box-sizing: border-box !important;
	max-width: 100%;
}

form.cart > .mlabs-paddle-buy-now-wrapper,
.woocommerce-variation-add-to-cart > .mlabs-paddle-buy-now-wrapper {
	margin: 0 !important;
}

/* Width Mode: Fit to Content (Default - Keeps button aligned inline with Quantity Selector) */
form.cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content,
.woocommerce-variation-add-to-cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content,
form.cart .mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content,
.mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content {
	flex: 0 0 auto !important;
	flex-grow: 0 !important;
	flex-shrink: 0 !important;
	flex-basis: auto !important;
	align-self: flex-start !important;
	display: inline-flex !important;
	width: auto !important;
	width: fit-content !important;
	width: -moz-fit-content !important;
	max-width: 100% !important;
	min-width: 0 !important;
	margin: 0 !important;
}

.mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content .mlabs-paddle-buy-now-btn {
	width: 100% !important;
	min-width: max-content !important;
	min-width: -moz-max-content !important;
	max-width: 100% !important;
	padding: 0 20px !important;
	box-sizing: border-box !important;
}

.mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content .mlabs-buy-now-subtitle {
	width: 100% !important;
	white-space: nowrap !important;
	text-align: center !important;
}

/* Width Mode: Full Width (100%) */
form.cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-full_width,
.woocommerce-variation-add-to-cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-full_width,
form.cart .mlabs-paddle-buy-now-wrapper.mlabs-width-full_width,
.mlabs-paddle-buy-now-wrapper.mlabs-width-full_width {
	display: flex !important;
	flex: 1 1 100% !important;
	flex-grow: 1 !important;
	flex-shrink: 1 !important;
	flex-basis: 100% !important;
	width: 100% !important;
	max-width: 100% !important;
	margin: 8px 0 !important;
}

.mlabs-paddle-buy-now-wrapper.mlabs-width-full_width .mlabs-paddle-buy-now-btn {
	width: 100% !important;
	min-width: 100% !important;
}

/* Width Mode: Custom Width */
form.cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-custom,
.woocommerce-variation-add-to-cart > .mlabs-paddle-buy-now-wrapper.mlabs-width-custom,
form.cart .mlabs-paddle-buy-now-wrapper.mlabs-width-custom,
.mlabs-paddle-buy-now-wrapper.mlabs-width-custom {
	display: inline-flex !important;
	flex: 0 0 auto !important;
	flex-grow: 0 !important;
	flex-shrink: 0 !important;
	flex-basis: auto !important;
	align-self: flex-start !important;
	width: auto !important;
	min-width: var(--mlabs-pdl-btn-min-width, 200px) !important;
	max-width: 100% !important;
	margin: 0 !important;
}

.mlabs-paddle-buy-now-wrapper.mlabs-width-custom .mlabs-paddle-buy-now-btn {
	width: 100% !important;
	min-width: var(--mlabs-pdl-btn-min-width, 200px) !important;
}

/* 2. Paddle Buy Now Button */
.mlabs-paddle-buy-now-btn {
	width: 100% !important;
	height: var(--mlabs-pdl-btn-height, 40px) !important;
	min-height: var(--mlabs-pdl-btn-height, 40px) !important;
	padding: 0 20px !important;
	font-size: var(--mlabs-pdl-btn-font-size, 14px) !important;
	font-weight: var(--mlabs-pdl-btn-font-weight, 700) !important;
	text-transform: uppercase !important;
	letter-spacing: 0.5px;
	border-radius: var(--mlabs-pdl-btn-radius, 8px) !important;
	box-sizing: border-box !important;
	text-align: center;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	cursor: pointer !important;
	line-height: 1 !important;
	transition: all 0.2s ease-in-out;
	border: none !important;
	text-decoration: none !important;
	white-space: nowrap !important;
	background-color: var(--mlabs-pdl-btn-bg, #efa63d) !important;
	color: var(--mlabs-pdl-btn-color, #ffffff) !important;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mlabs-paddle-buy-now-btn:hover {
	background-color: var(--mlabs-pdl-btn-bg-hover, #d9922b) !important;
	color: var(--mlabs-pdl-btn-color-hover, #ffffff) !important;
}

/* Ensure text color applies to all inner spans/elements, preventing theme overrides */
.mlabs-paddle-buy-now-btn,
.mlabs-paddle-buy-now-btn *,
.mlabs-paddle-buy-now-btn .mlabs-btn-text,
.mlabs-paddle-buy-now-btn span {
	color: var(--mlabs-pdl-btn-color, #ffffff) !important;
}

.mlabs-paddle-buy-now-btn:hover,
.mlabs-paddle-buy-now-btn:hover *,
.mlabs-paddle-buy-now-btn:hover .mlabs-btn-text,
.mlabs-paddle-buy-now-btn:hover span {
	color: var(--mlabs-pdl-btn-color-hover, #ffffff) !important;
}

/* Visual cue when option is not selected or price ID is missing (Clickable!) */
.mlabs-paddle-buy-now-btn.mlabs-need-selection,
.mlabs-paddle-buy-now-btn.mlabs-missing-price {
	opacity: 0.85 !important;
	cursor: pointer !important;
}

/* 3. Subtitle beneath button */
.mlabs-buy-now-subtitle {
	display: block !important;
	font-size: var(--mlabs-pdl-sub-font-size, 11.5px) !important;
	font-weight: var(--mlabs-pdl-sub-font-weight, 400) !important;
	color: var(--mlabs-pdl-sub-color, #64748b) !important;
	margin-top: var(--mlabs-pdl-sub-margin-top, 6px) !important;
	line-height: 1.35 !important;
	text-align: var(--mlabs-pdl-sub-align, center) !important;
	letter-spacing: normal;
	width: 100% !important;
	max-width: 100% !important;
	word-wrap: break-word;
}

/* 3.1. Admin-only Sandbox Indicator Badge beneath Buy Now */
.mlabs-sandbox-admin-badge {
	display: inline-block;
	margin-top: 6px;
	padding: 2px 8px;
	font-size: 11px;
	font-weight: 600;
	line-height: 1.4;
	color: #92400e;
	background: #fef3c7;
	border: 1px solid #fcd34d;
	border-radius: 4px;
	text-align: center;
}

/* 4. Inline Notice Box */
.mlabs-buy-now-notice {
	margin-top: 8px;
	padding: 8px 12px;
	border-radius: 4px;
	font-size: 12.5px;
	line-height: 1.4;
	text-align: center;
	font-weight: 500;
	box-sizing: border-box;
}

.mlabs-buy-now-notice.notice-error {
	background: #fef2f2;
	color: #b91c1c;
	border: 1px solid #fecaca;
}

.mlabs-buy-now-notice.notice-warning {
	background: #fffbeb;
	color: #b45309;
	border: 1px solid #fde68a;
}

.mlabs-buy-now-notice.notice-info {
	background: #f0f9ff;
	color: #0369a1;
	border: 1px solid #bae6fd;
}

/* 5. Gentle Pulse Highlight for Variation Selector */
.mlabs-highlight-pulse {
	outline: 2px solid #0078d4 !important;
	outline-offset: 4px;
	border-radius: 4px;
	transition: outline 0.3s ease;
	animation: mlabs-pulse 1.2s infinite alternate;
}

@keyframes mlabs-pulse {
	0% {
		outline-color: #0078d4;
	}
	100% {
		outline-color: #93c5fd;
	}
}

/* 6. Button Spinner */
.mlabs-btn-spinner {
	display: inline-block;
	animation: mlabs-btn-pulse 0.9s infinite alternate;
}

@keyframes mlabs-btn-pulse {
	0% {
		opacity: 0.2;
	}
	100% {
		opacity: 1;
	}
}

/* 7. Shortcode Wrapper */
.mlabs-paddle-buy-now-wrapper.mlabs-shortcode {
	margin: 8px 0;
}

/* 8. Processing Overlay */
#mlabs-paddle-processing-overlay {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(255, 255, 255, 0.92);
	backdrop-filter: blur(4px);
	z-index: 999999;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.mlabs-paddle-spinner {
	width: 44px;
	height: 44px;
	border: 4px solid #e2e8f0;
	border-top-color: #0078d4;
	border-radius: 50%;
	animation: mlabs-overlay-spin 0.9s infinite linear;
}

@keyframes mlabs-overlay-spin {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(360deg);
	}
}

/* 9. Mobile Responsive Layout */
@media (max-width: 575px) {
	.mlabs-paddle-buy-now-wrapper.mlabs-width-full_width {
		display: flex !important;
		width: 100% !important;
		margin: 8px 0 0 0 !important;
	}

	.mlabs-paddle-buy-now-wrapper.mlabs-width-full_width .mlabs-paddle-buy-now-btn {
		width: 100% !important;
		max-width: 100% !important;
	}

	.mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content {
		display: inline-flex !important;
		width: auto !important;
		width: fit-content !important;
		max-width: 100% !important;
		margin: 6px 0 !important;
	}

	.mlabs-paddle-buy-now-wrapper.mlabs-width-fit_content .mlabs-paddle-buy-now-btn {
		width: 100% !important;
		min-width: 0 !important;
		max-width: 100% !important;
	}
}

/* 10. Dedicated Soft-Light License Card Component & Realtime Poller */
#mlabs-paddle-license-card {
	background: #ffffff;
	border: 1px solid #dce1e7;
	border-radius: 8px;
	padding: 22px 24px;
	margin: 25px 0;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
	box-sizing: border-box;
	clear: both;
}

#mlabs-paddle-license-card.is-waiting {
	border-color: #cbd5e1;
	background: #f8fafc;
}

.mlabs-license-card-header {
	display: flex;
	align-items: center;
	gap: 14px;
	margin-bottom: 18px;
	padding-bottom: 14px;
	border-bottom: 1px solid #e2e8f0;
}

.mlabs-license-header-icon {
	flex: 0 0 40px;
	width: 40px;
	height: 40px;
	border-radius: 8px;
	background: #eff6ff;
	border: 1px solid #bfdbfe;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mlabs-license-header-text {
	flex: 1 1 auto;
}

.mlabs-license-title {
	margin: 0 !important;
	font-size: 17px !important;
	font-weight: 600 !important;
	color: #1e293b !important;
	line-height: 1.3 !important;
}

.mlabs-license-subtitle {
	margin: 3px 0 0 0 !important;
	font-size: 13.5px !important;
	color: #64748b !important;
	line-height: 1.4 !important;
}

/* Waiting / Poller State */
.mlabs-license-waiting-box {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 16px 18px;
	background: #ffffff;
	border: 1px solid #e2e8f0;
	border-radius: 6px;
}

.mlabs-license-spinner-wrap {
	flex: 0 0 34px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.mlabs-license-spinner {
	width: 28px;
	height: 28px;
	border: 3px solid #e2e8f0;
	border-top-color: #0078d4;
	border-radius: 50%;
	animation: mlabs-overlay-spin 0.9s infinite linear;
}

.mlabs-license-waiting-text {
	flex: 1 1 auto;
}

.mlabs-license-waiting-heading {
	font-size: 15px;
	font-weight: 600;
	color: #1e293b;
	line-height: 1.3;
}

.mlabs-license-waiting-sub {
	margin-top: 4px;
	font-size: 13px;
	color: #64748b;
	line-height: 1.4;
}

/* License Items List */
.mlabs-license-items-list {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.mlabs-license-item-row {
	background: #f8fafc;
	border: 1px solid #e2e8f0;
	border-radius: 6px;
	padding: 16px 18px;
	box-sizing: border-box;
}

.mlabs-license-item-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 10px;
	flex-wrap: wrap;
	gap: 8px;
}

.mlabs-license-product-name {
	font-size: 15px;
	font-weight: 600;
	color: #1e293b;
}

.mlabs-license-badge-active {
	display: inline-flex;
	align-items: center;
	padding: 3px 9px;
	font-size: 11.5px;
	font-weight: 600;
	color: #166534;
	background: #dcfce7;
	border: 1px solid #bbf7d0;
	border-radius: 12px;
	text-transform: uppercase;
	letter-spacing: 0.3px;
}

/* License Key Action Bar */
.mlabs-license-key-action-bar {
	display: flex;
	align-items: stretch;
	gap: 10px;
	margin-bottom: 10px;
}

.mlabs-license-key-code {
	flex: 1 1 auto;
	background: #ffffff;
	border: 1px dashed #cbd5e1;
	border-radius: 6px;
	padding: 10px 14px;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	overflow-x: auto;
	cursor: text;
}

.mlabs-license-key-code code {
	font-family: Consolas, Monaco, "Courier New", monospace !important;
	font-size: 14.5px !important;
	font-weight: 600 !important;
	color: #0369a1 !important;
	background: transparent !important;
	border: none !important;
	padding: 0 !important;
	white-space: nowrap;
	letter-spacing: 0.5px;
	user-select: all;
	-webkit-user-select: all;
}

/* 1-Click Copy Button */
.mlabs-license-copy-btn {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	background: #0078d4;
	color: #ffffff !important;
	border: 1px solid #0078d4;
	border-radius: 6px;
	padding: 0 18px;
	font-size: 13.5px;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
	white-space: nowrap;
	line-height: normal;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mlabs-license-copy-btn:hover {
	background: #0284c7;
	border-color: #0284c7;
	color: #ffffff !important;
}

.mlabs-license-copy-btn:active {
	background: #0369a1;
	border-color: #0369a1;
	transform: scale(0.98);
}

.mlabs-license-copy-btn.is-copied {
	background: #16a34a !important;
	border-color: #16a34a !important;
}

.mlabs-copy-icon-svg,
.mlabs-check-icon-svg {
	vertical-align: middle;
	flex-shrink: 0;
}

/* Meta Details underneath */
.mlabs-license-meta-details {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12.5px;
	color: #64748b;
	flex-wrap: wrap;
}

.mlabs-license-meta-item strong {
	color: #475569;
	font-weight: 600;
}

.mlabs-license-meta-sep {
	color: #cbd5e1;
}

/* Responsive adjustment for Mobile */
@media (max-width: 575px) {
	#mlabs-paddle-license-card {
		padding: 16px;
	}

	.mlabs-license-key-action-bar {
		flex-direction: column;
	}

	.mlabs-license-copy-btn {
		width: 100%;
		padding: 11px 16px;
	}
}

/* 11. Paddle-Only Variation Enforcement & Subscription UI */
form.cart .mlabs-buy-now-wrapper.mlabs-hidden-by-paddle-only,
.woocommerce-variation-add-to-cart .mlabs-buy-now-wrapper.mlabs-hidden-by-paddle-only,
form.cart .single_add_to_cart_button.mlabs-hidden-by-paddle-only,
.mlabs-hidden-by-paddle-only {
	display: none !important;
	visibility: hidden !important;
}

.mlabs-sub-period {
	font-size: 0.72em;
	font-weight: 500;
	color: #64748b;
	white-space: nowrap;
}

.mlabs-license-badge-disabled {
	display: inline-flex;
	align-items: center;
	padding: 3px 9px;
	font-size: 11.5px;
	font-weight: 600;
	color: #991b1b;
	background: #fee2e2;
	border: 1px solid #fecaca;
	border-radius: 12px;
	text-transform: uppercase;
	letter-spacing: 0.3px;
}

.mlabs-paddle-sub-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 14px;
	margin-bottom: 14px;
	font-size: 13px;
	color: #475569;
}

.mlabs-paddle-sub-pill {
	display: inline-flex;
	align-items: center;
	padding: 3px 10px;
	border-radius: 9999px;
	font-size: 11.5px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.3px;
}

.mlabs-paddle-sub-pill.is-active {
	background: #dcfce7;
	color: #166534;
	border: 1px solid #bbf7d0;
}

.mlabs-paddle-sub-pill.is-past_due {
	background: #fef3c7;
	color: #92400e;
	border: 1px solid #fde68a;
}

.mlabs-paddle-sub-pill.is-paused,
.mlabs-paddle-sub-pill.is-canceled {
	background: #fee2e2;
	color: #991b1b;
	border: 1px solid #fecaca;
}

/* ==========================================================================
   12. WooCommerce Checkout - Unified Paddle Payment Card, CTA Button & Trust Note
   ========================================================================== */

/* Section Heading (Hidden for streamlined Checkout UI) */
.mlabs-payment-method-heading {
	display: none !important;
}

/* Clean container reset for #payment when Paddle is rendered */
#payment.woocommerce-checkout-payment {
	background: transparent !important;
	border-radius: 0 !important;
	padding: 0 !important;
	margin-top: 0 !important;
}

#payment ul.wc_payment_methods {
	margin: 0 0 18px 0 !important;
	padding: 0 !important;
	border: none !important;
	list-style: none !important;
	background: transparent !important;
}

#payment ul.wc_payment_methods:has(> li.wc_payment_method.payment_method_mlabs_paddle:only-child) {
	margin: 0 !important;
}

#payment ul.wc_payment_methods li.wc_payment_method.payment_method_mlabs_paddle {
	margin: 0 !important;
	padding: 0 !important;
	border: none !important;
	list-style: none !important;
	background: transparent !important;
}

/* When Paddle is the ONLY payment gateway, seamlessly hide redundant radio + label */
#payment ul.wc_payment_methods li.wc_payment_method.payment_method_mlabs_paddle:only-child > input.input-radio,
#payment ul.wc_payment_methods li.wc_payment_method.payment_method_mlabs_paddle:only-child > label {
	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;
}

/* Strip WooCommerce default gray box & triangle arrow on Paddle payment_box */
#payment div.payment_box.payment_method_mlabs_paddle {
	position: relative !important;
	background: transparent !important;
	padding: 0 !important;
	margin: 0 !important;
	border: none !important;
	box-shadow: none !important;
	color: inherit !important;
}

#payment div.payment_box.payment_method_mlabs_paddle:empty {
	display: none !important;
}

#payment div.payment_box.payment_method_mlabs_paddle::before,
#payment div.payment_box.payment_method_mlabs_paddle::after {
	display: none !important;
	content: none !important;
}

/* Unified Payment Card */
.mlabs-paddle-checkout-card {
	background: #fafbfc;
	border: 1px solid #e2e8f0;
	border-radius: 12px;
	padding: 20px 22px;
	box-sizing: border-box;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
	text-align: left;
}

.mlabs-paddle-card-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px 16px;
	flex-wrap: wrap;
}

/* Dark Slate Verified Paddle Pill Badge */
.mlabs-paddle-brand-pill {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	height: 36px;
	padding: 0 12px 0 13px;
	border-radius: 7px;
	background: linear-gradient(135deg, #475569 0%, #334155 100%);
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.14);
	box-sizing: border-box;
	user-select: none;
}

.mlabs-paddle-p-mark {
	display: block;
	flex-shrink: 0;
}

.mlabs-paddle-brand-name {
	color: #ffffff !important;
	font-size: 16px;
	font-weight: 600;
	line-height: 1;
	letter-spacing: -0.015em;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.mlabs-paddle-verified-check {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-left: 2px;
	flex-shrink: 0;
}

/* Accepted Payment Brand Mini-Cards */
.mlabs-paddle-method-icons {
	display: inline-flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 6px;
}

.mlabs-method-pill {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 30px;
	min-width: 44px;
	padding: 0 8px;
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 6px;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
	box-sizing: border-box;
}

.mlabs-method-pill svg {
	display: block;
	max-width: 100%;
	height: auto;
}

/* Card Description Text */
.mlabs-paddle-card-desc {
	margin-top: 14px;
	color: #374151;
	font-size: 14.5px;
	line-height: 1.55;
	font-weight: 400;
}

.mlabs-paddle-card-desc p {
	margin: 0 !important;
	padding: 0 !important;
	color: #374151 !important;
	font-size: 14.5px !important;
	line-height: 1.55 !important;
}

.mlabs-paddle-card-desc p + p {
	margin-top: 4px !important;
}

/* Place Order Wrapper Reset */
#payment .form-row.place-order {
	padding: 0 !important;
	margin: 20px 0 0 0 !important;
	border: none !important;
	background: transparent !important;
}

/* Primary Orange Gradient CTA Button ("PAY & GET LICENSE KEY ->") */
#payment #place_order.mlabs-paddle-place-order-btn,
button#place_order.mlabs-paddle-place-order-btn,
.woocommerce-checkout button#place_order.mlabs-paddle-place-order-btn {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 9px !important;
	width: 100% !important;
	min-height: 54px !important;
	height: auto !important;
	padding: 14px 24px !important;
	margin: 0 !important;
	border: none !important;
	border-radius: 10px !important;
	background: linear-gradient(135deg, #f39526 0%, #e56c09 55%, #d55402 100%) !important;
	background-color: #e56c09 !important;
	color: #ffffff !important;
	font-size: 16px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
	letter-spacing: 0.45px !important;
	text-transform: uppercase !important;
	text-decoration: none !important;
	cursor: pointer !important;
	box-shadow: 0 4px 14px rgba(213, 84, 2, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
	transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease !important;
	box-sizing: border-box !important;
}

#payment #place_order.mlabs-paddle-place-order-btn:hover,
button#place_order.mlabs-paddle-place-order-btn:hover {
	filter: brightness(1.04) !important;
	transform: translateY(-1px) !important;
	box-shadow: 0 6px 18px rgba(213, 84, 2, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.22) !important;
	color: #ffffff !important;
}

#payment #place_order.mlabs-paddle-place-order-btn:active,
button#place_order.mlabs-paddle-place-order-btn:active {
	transform: translateY(0) !important;
	filter: brightness(0.97) !important;
}

#payment #place_order.mlabs-paddle-place-order-btn:disabled,
button#place_order.mlabs-paddle-place-order-btn.disabled {
	opacity: 0.7 !important;
	cursor: not-allowed !important;
	transform: none !important;
}

.mlabs-paddle-place-order-btn .mlabs-place-order-label,
.mlabs-paddle-place-order-btn .mlabs-place-order-arrow {
	color: #ffffff !important;
	flex-shrink: 0;
}

.mlabs-paddle-place-order-btn .mlabs-place-order-arrow {
	transition: transform 0.15s ease;
}

.mlabs-paddle-place-order-btn:hover .mlabs-place-order-arrow {
	transform: translateX(3px);
}

/* Instant License Delivery Trust Note beneath CTA Button */
.mlabs-checkout-security-note {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-top: 12px;
	padding: 0 4px;
	color: #6b7280;
	font-size: 13px;
	line-height: 1.45;
	font-weight: 400;
	text-align: center;
}

.mlabs-security-lock-icon {
	color: #6b7280;
	flex-shrink: 0;
	margin-top: -1px;
}

/* Responsive adjustments for smaller checkout columns & mobile */
@media (max-width: 575px) {
	.mlabs-paddle-checkout-card {
		padding: 16px;
	}

	.mlabs-paddle-card-top {
		gap: 10px;
	}

	.mlabs-method-pill {
		height: 28px;
		min-width: 40px;
		padding: 0 6px;
	}

	#payment #place_order.mlabs-paddle-place-order-btn,
	button#place_order.mlabs-paddle-place-order-btn {
		font-size: 14.5px !important;
		min-height: 50px !important;
		padding: 12px 18px !important;
	}

	.mlabs-checkout-security-note {
		font-size: 12px;
	}
}

/* ==========================================================================
   13. Paddle Direct & Localized Price Display (Storefront)
   ========================================================================== */
.mlabs-paddle-price {
	display: inline;
	transition: opacity 0.2s ease;
}

.mlabs-paddle-price--fade.is-loading {
	opacity: 0.55;
}

.mlabs-paddle-price--skeleton.is-loading {
	display: inline-block;
	min-width: 64px;
	border-radius: 4px;
	background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
	background-size: 200% 100%;
	animation: mlabs-price-shimmer 1.2s infinite ease-in-out;
	color: transparent !important;
}

.mlabs-paddle-price--skeleton.is-loading * {
	visibility: hidden;
}

@keyframes mlabs-price-shimmer {
	0% {
		background-position: 200% 0;
	}
	100% {
		background-position: -200% 0;
	}
}

.mlabs-paddle-approx-local {
	display: block;
	margin-top: 6px;
	font-size: 17px !important;
	font-weight: 600 !important;
	color: #475569 !important;
	line-height: 1.4 !important;
	letter-spacing: normal !important;
}

.related.products .mlabs-paddle-approx-local,
.upsells .mlabs-paddle-approx-local,
.cross-sells .mlabs-paddle-approx-local,
.product-small .mlabs-paddle-approx-local {
	display: none !important;
}
