/**
 * ClicksMoney Child Theme — Custom Styles
 *
 * Comprehensive custom styles for WooCommerce overrides, My Account,
 * Downloads, Marketing pages, and all custom components.
 *
 * @package ClicksMoney_Child
 * @since 1.0.0
 */

/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   ========================================================================== */

:root {
	--cm-navy: #1e293b;
	--cm-navy-dark: #0f172a;
	--cm-navy-light: #334155;
	--cm-orange: #f97316;
	--cm-orange-hover: #ea580c;
	--cm-orange-light: #fff7ed;
	--cm-orange-shadow: rgba(249, 115, 22, 0.25);
	--cm-white: #ffffff;
	--cm-gray-50: #f8fafc;
	--cm-gray-100: #f1f5f9;
	--cm-gray-200: #e2e8f0;
	--cm-gray-300: #cbd5e1;
	--cm-gray-500: #64748b;
	--cm-gray-700: #334155;
	--cm-gray-900: #0f172a;
	--cm-green: #22c55e;
	--cm-green-light: #dcfce7;
	--cm-blue: #3b82f6;
	--cm-blue-light: #dbeafe;
	--cm-red: #ef4444;
	--cm-radius-sm: 0.375rem;
	--cm-radius-md: 0.5rem;
	--cm-radius-lg: 0.75rem;
	--cm-radius-xl: 1rem;
	--cm-radius-2xl: 1.5rem;
	--cm-radius-full: 9999px;
	--cm-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
	--cm-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
	--cm-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
	--cm-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
	--cm-transition: all 0.2s ease-in-out;
}

/* ==========================================================================
   WooCommerce Button Overrides
   ========================================================================== */

/* Primary buttons — Add to Cart, Buy Now, Submit */
.woocommerce .button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.woocommerce .single_add_to_cart_button,
.woocommerce .checkout-button,
#place_order {
	background-color: var(--cm-orange) !important;
	color: var(--cm-white) !important;
	border: none !important;
	border-radius: var(--cm-radius-lg) !important;
	padding: 0.875rem 2rem !important;
	font-size: 1rem !important;
	font-weight: 700 !important;
	line-height: 1.5 !important;
	text-transform: none !important;
	letter-spacing: 0 !important;
	box-shadow: 0 4px 14px 0 var(--cm-orange-shadow) !important;
	transition: var(--cm-transition) !important;
	cursor: pointer !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	text-decoration: none !important;
}

.woocommerce .button:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover,
.woocommerce .single_add_to_cart_button:hover,
.woocommerce .checkout-button:hover,
#place_order:hover {
	background-color: var(--cm-orange-hover) !important;
	transform: translateY(-1px) !important;
	box-shadow: 0 6px 20px 0 var(--cm-orange-shadow) !important;
}

.woocommerce .button:active,
.woocommerce a.button:active,
.woocommerce button.button:active {
	transform: translateY(0) !important;
}

/* Single product Add to Cart — extra large */
.woocommerce .single_add_to_cart_button {
	padding: 1.125rem 2.5rem !important;
	font-size: 1.125rem !important;
	border-radius: var(--cm-radius-xl) !important;
	width: 100% !important;
	max-width: 400px !important;
}

/* Disabled button state */
.woocommerce .button:disabled,
.woocommerce .button.disabled,
.woocommerce .button[disabled] {
	opacity: 0.5 !important;
	cursor: not-allowed !important;
	transform: none !important;
}

/* Secondary / outline buttons */
.woocommerce .button.wc-forward,
.woocommerce a.button.wc-backward {
	background-color: var(--cm-white) !important;
	color: var(--cm-gray-700) !important;
	border: 2px solid var(--cm-gray-200) !important;
	box-shadow: var(--cm-shadow-sm) !important;
}

.woocommerce .button.wc-forward:hover,
.woocommerce a.button.wc-backward:hover {
	border-color: var(--cm-gray-300) !important;
	background-color: var(--cm-gray-50) !important;
	transform: none !important;
}

/* ==========================================================================
   My Account — Horizontal Tab Navigation
   ========================================================================== */

.cm-my-account-wrapper {
	max-width: 1100px;
	margin: 0 auto;
}

.cm-account-nav ul {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	gap: 0.5rem;
	flex-wrap: nowrap;
}

.cm-account-nav li {
	list-style: none;
	margin: 0;
	padding: 0;
}

.cm-account-nav a {
	text-decoration: none;
	transition: var(--cm-transition);
}

.cm-account-nav a:focus-visible {
	outline: 2px solid var(--cm-orange);
	outline-offset: 2px;
	border-radius: var(--cm-radius-full);
}

/* Active tab pill */
.cm-account-nav a[aria-current="page"] {
	background-color: var(--cm-orange) !important;
	color: var(--cm-white) !important;
	box-shadow: 0 4px 14px 0 var(--cm-orange-shadow);
}

/* Remove default WC My Account navigation sidebar */
.woocommerce-MyAccount-navigation {
	display: none !important;
}

.woocommerce-MyAccount-content {
	width: 100% !important;
	float: none !important;
}

/* ==========================================================================
   Download Cards
   ========================================================================== */

.cm-download-card {
	transition: var(--cm-transition);
}

.cm-download-card:hover {
	transform: translateY(-2px);
	box-shadow: var(--cm-shadow-lg);
	border-color: var(--cm-orange) !important;
}

.cm-download-btn {
	position: relative;
	overflow: hidden;
}

.cm-download-btn::after {
	content: '';
	position: absolute;
	top: 0;
	left: -100%;
	width: 100%;
	height: 100%;
	background: linear-gradient(
		90deg,
		transparent,
		rgba(255, 255, 255, 0.2),
		transparent
	);
	transition: left 0.5s ease;
}

.cm-download-btn:hover::after {
	left: 100%;
}

/* ==========================================================================
   Marketing Page Section Styles
   ========================================================================== */

.cm-marketing-page section {
	position: relative;
}

.cm-marketing-hero {
	position: relative;
	overflow: hidden;
}

.cm-marketing-hero::before {
	content: '';
	position: absolute;
	top: -50%;
	right: -20%;
	width: 600px;
	height: 600px;
	background: radial-gradient(circle, rgba(249, 115, 22, 0.08) 0%, transparent 70%);
	border-radius: 50%;
	pointer-events: none;
}

.cm-marketing-hero::after {
	content: '';
	position: absolute;
	bottom: -30%;
	left: -10%;
	width: 400px;
	height: 400px;
	background: radial-gradient(circle, rgba(249, 115, 22, 0.05) 0%, transparent 70%);
	border-radius: 50%;
	pointer-events: none;
}

/* Video wrapper responsive */
.cm-video-wrapper {
	position: relative;
	padding-bottom: 56.25%; /* 16:9 */
	height: 0;
	overflow: hidden;
}

.cm-video-wrapper iframe,
.cm-video-wrapper > div {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

/* ==========================================================================
   Product Page Hero Section
   ========================================================================== */

.cm-hero {
	position: relative;
	overflow: hidden;
}

.cm-hero::before {
	content: '';
	position: absolute;
	top: 0;
	right: 0;
	width: 50%;
	height: 100%;
	background: radial-gradient(ellipse at top right, rgba(249, 115, 22, 0.1) 0%, transparent 60%);
	pointer-events: none;
}

/* ==========================================================================
   Thank You Page — Celebration Styles
   ========================================================================== */

.cm-thankyou-page {
	max-width: 700px;
	margin: 0 auto;
	padding: 2rem 0;
}

/* Bounce animation for success checkmark */
@keyframes bounceOnce {
	0% {
		transform: scale(0.5);
		opacity: 0;
	}
	60% {
		transform: scale(1.1);
		opacity: 1;
	}
	80% {
		transform: scale(0.95);
	}
	100% {
		transform: scale(1);
	}
}

.animate-bounce-once {
	animation: bounceOnce 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

/* Confetti-like subtle background on thank you */
.cm-thankyou-page::before {
	content: '';
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background:
		radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.03) 0%, transparent 50%),
		radial-gradient(circle at 80% 80%, rgba(34, 197, 94, 0.03) 0%, transparent 50%);
	pointer-events: none;
	z-index: -1;
}

/* Hide default WC order details on thank you (we show our own summary) */
.cm-thankyou-page .woocommerce-order-details,
.cm-thankyou-page .woocommerce-customer-details {
	display: none;
}

/* ==========================================================================
   Trust Badges Row
   ========================================================================== */

.cm-trust-badges {
	position: relative;
}

.cm-trust-badges .grid > div {
	transition: var(--cm-transition);
}

.cm-trust-badges .grid > div:hover {
	transform: translateY(-2px);
}

/* ==========================================================================
   FAQ Accordion Styles (details/summary)
   ========================================================================== */

.cm-faq-item {
	transition: var(--cm-transition);
}

.cm-faq-item:hover {
	border-color: var(--cm-orange) !important;
}

.cm-faq-item[open] {
	border-color: var(--cm-orange) !important;
	box-shadow: 0 0 0 1px var(--cm-orange);
}

/* Remove default marker */
.cm-faq-item summary {
	list-style: none;
}

.cm-faq-item summary::-webkit-details-marker {
	display: none;
}

.cm-faq-item summary::marker {
	display: none;
	content: '';
}

/* Smooth open/close (limited without JS, but improves UX) */
.cm-faq-item summary ~ div {
	animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(-8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ==========================================================================
   Price Badge Styles
   ========================================================================== */

.cm-price-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.cm-price-badge::before {
	content: '';
	position: absolute;
	inset: -2px;
	background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), transparent);
	border-radius: inherit;
	pointer-events: none;
}

/* Price in WC context */
.cm-price-badge .woocommerce-Price-amount {
	font-size: inherit;
	font-weight: inherit;
	color: inherit;
}

.cm-price-badge del {
	opacity: 0.6;
	font-size: 0.7em;
	margin-right: 0.5rem;
}

.cm-price-badge ins {
	text-decoration: none;
}

/* ==========================================================================
   Mobile-Responsive Overrides
   ========================================================================== */

@media (max-width: 768px) {
	/* Account nav scrolls horizontally on mobile */
	.cm-account-nav {
		margin-left: -1rem;
		margin-right: -1rem;
		padding-left: 1rem;
		padding-right: 1rem;
		-webkit-overflow-scrolling: touch;
	}

	.cm-account-nav ul {
		padding-bottom: 0.5rem;
	}

	/* Stack download cards */
	.cm-downloads-page .grid {
		grid-template-columns: 1fr;
	}

	/* Full-width buttons on mobile */
	.cm-buy-now-btn {
		width: 100%;
		max-width: 100%;
	}

	/* Reduce section padding on mobile */
	.cm-hero,
	.cm-marketing-hero {
		padding-top: 3rem !important;
		padding-bottom: 3rem !important;
	}

	/* Pricing card full width */
	.cm-marketing-pricing .max-w-lg {
		max-width: 100%;
	}

	/* Smaller headings on mobile */
	.cm-hero h1,
	.cm-marketing-hero h1 {
		font-size: 2rem !important;
		line-height: 1.2 !important;
	}

	/* Quick cards stack */
	.cm-quick-card {
		padding: 1rem !important;
	}

	/* Thank you page */
	.cm-thankyou-page {
		padding: 1rem 0;
	}
}

@media (max-width: 480px) {
	/* Even smaller headings */
	.cm-hero h1,
	.cm-marketing-hero h1 {
		font-size: 1.75rem !important;
	}

	.cm-price-badge {
		font-size: 1.5rem !important;
		padding: 0.5rem 1.25rem !important;
	}

	/* Account nav items smaller */
	.cm-account-nav a {
		padding: 0.5rem 1rem !important;
		font-size: 0.8rem !important;
	}
}

/* ==========================================================================
   WooCommerce Form Styling
   ========================================================================== */

/* Cleaner inputs */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce-page form .form-row input.input-text,
.woocommerce-page form .form-row textarea,
.woocommerce-page form .form-row select {
	border: 2px solid var(--cm-gray-200) !important;
	border-radius: var(--cm-radius-lg) !important;
	padding: 0.75rem 1rem !important;
	font-size: 1rem !important;
	line-height: 1.5 !important;
	transition: var(--cm-transition) !important;
	background-color: var(--cm-white) !important;
	color: var(--cm-gray-900) !important;
	width: 100% !important;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus,
.woocommerce-page form .form-row input.input-text:focus,
.woocommerce-page form .form-row textarea:focus,
.woocommerce-page form .form-row select:focus {
	border-color: var(--cm-orange) !important;
	outline: none !important;
	box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1) !important;
}

/* Form row spacing */
.woocommerce form .form-row {
	margin-bottom: 1.25rem !important;
	padding: 0 !important;
}

/* Labels */
.woocommerce form .form-row label {
	font-size: 0.875rem !important;
	font-weight: 600 !important;
	color: var(--cm-gray-700) !important;
	margin-bottom: 0.375rem !important;
	display: block !important;
}

/* Required asterisk */
.woocommerce form .form-row .required {
	color: var(--cm-red) !important;
}

/* Validation states */
.woocommerce form .form-row.woocommerce-validated input.input-text {
	border-color: var(--cm-green) !important;
}

.woocommerce form .form-row.woocommerce-invalid input.input-text {
	border-color: var(--cm-red) !important;
}

/* ==========================================================================
   Checkout Page Streamlined Styles
   ========================================================================== */

/* Clean checkout layout */
.woocommerce-checkout {
	max-width: 700px;
	margin: 0 auto;
}

/* Checkout sections */
.woocommerce-checkout .col2-set {
	width: 100%;
	float: none;
}

.woocommerce-checkout .col2-set .col-1,
.woocommerce-checkout .col2-set .col-2 {
	float: none;
	width: 100%;
}

/* Order review box */
.woocommerce-checkout #order_review_heading {
	font-size: 1.25rem;
	font-weight: 700;
	color: var(--cm-gray-900);
	margin-top: 2rem;
	margin-bottom: 1rem;
	padding-bottom: 0.75rem;
	border-bottom: 2px solid var(--cm-gray-100);
}

.woocommerce-checkout #order_review {
	background: var(--cm-gray-50);
	border-radius: var(--cm-radius-xl);
	padding: 1.5rem;
	border: 1px solid var(--cm-gray-200);
}

/* Checkout table */
.woocommerce-checkout .shop_table {
	border: none !important;
	border-radius: var(--cm-radius-lg) !important;
	overflow: hidden;
}

.woocommerce-checkout .shop_table th,
.woocommerce-checkout .shop_table td {
	border: none !important;
	padding: 0.75rem 0 !important;
	border-bottom: 1px solid var(--cm-gray-100) !important;
}

.woocommerce-checkout .shop_table tfoot tr:last-child th,
.woocommerce-checkout .shop_table tfoot tr:last-child td {
	border-bottom: none !important;
	font-size: 1.125rem;
	font-weight: 700;
	padding-top: 1rem !important;
	border-top: 2px solid var(--cm-gray-200) !important;
}

/* Payment methods */
.woocommerce-checkout #payment {
	background: transparent !important;
	border-radius: var(--cm-radius-xl) !important;
}

.woocommerce-checkout #payment ul.payment_methods {
	border: none !important;
	padding: 0 !important;
}

.woocommerce-checkout #payment ul.payment_methods li {
	background: var(--cm-white);
	border: 2px solid var(--cm-gray-200);
	border-radius: var(--cm-radius-lg);
	margin-bottom: 0.75rem;
	padding: 1rem 1.25rem;
	transition: var(--cm-transition);
}

.woocommerce-checkout #payment ul.payment_methods li:hover {
	border-color: var(--cm-orange);
}

.woocommerce-checkout #payment .place-order {
	padding: 1.5rem 0 0 !important;
}

/* Place order button — extra prominent */
.woocommerce-checkout #place_order {
	width: 100% !important;
	padding: 1.125rem 2rem !important;
	font-size: 1.125rem !important;
	border-radius: var(--cm-radius-xl) !important;
}

/* Coupon field */
.woocommerce-checkout .woocommerce-form-coupon-toggle {
	margin-bottom: 1.5rem;
}

.woocommerce-checkout .checkout_coupon {
	border: 2px solid var(--cm-gray-200) !important;
	border-radius: var(--cm-radius-xl) !important;
	padding: 1.25rem !important;
}

/* ==========================================================================
   WooCommerce Notices
   ========================================================================== */

.woocommerce-message,
.woocommerce-info {
	border-top-color: var(--cm-orange) !important;
	background: var(--cm-orange-light) !important;
	border-radius: var(--cm-radius-lg) !important;
	padding: 1rem 1.5rem !important;
	border: 1px solid rgba(249, 115, 22, 0.2) !important;
	border-top: 3px solid var(--cm-orange) !important;
}

.woocommerce-message::before,
.woocommerce-info::before {
	color: var(--cm-orange) !important;
}

.woocommerce-error {
	border-top-color: var(--cm-red) !important;
	background: #fef2f2 !important;
	border-radius: var(--cm-radius-lg) !important;
	padding: 1rem 1.5rem !important;
	border: 1px solid rgba(239, 68, 68, 0.2) !important;
	border-top: 3px solid var(--cm-red) !important;
}

/* ==========================================================================
   Quick Access Cards (My Account Dashboard)
   ========================================================================== */

.cm-quick-card {
	text-decoration: none !important;
	transition: var(--cm-transition);
}

.cm-quick-card:hover {
	transform: translateY(-2px);
}

.cm-quick-card:focus-visible {
	outline: 2px solid var(--cm-orange);
	outline-offset: 2px;
}

/* ==========================================================================
   Product Description Prose Styles
   ========================================================================== */

.cm-product-description h2,
.cm-product-description h3,
.cm-product-description h4 {
	color: var(--cm-navy);
	font-weight: 700;
	margin-top: 2rem;
	margin-bottom: 0.75rem;
}

.cm-product-description h2 {
	font-size: 1.5rem;
}

.cm-product-description h3 {
	font-size: 1.25rem;
}

.cm-product-description p {
	margin-bottom: 1.25rem;
	line-height: 1.75;
	color: var(--cm-gray-700);
}

.cm-product-description ul,
.cm-product-description ol {
	margin-bottom: 1.25rem;
	padding-left: 1.5rem;
}

.cm-product-description li {
	margin-bottom: 0.5rem;
	line-height: 1.75;
	color: var(--cm-gray-700);
}

.cm-product-description ul li::marker {
	color: var(--cm-orange);
}

.cm-product-description a {
	color: var(--cm-orange);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.cm-product-description a:hover {
	color: var(--cm-orange-hover);
}

.cm-product-description blockquote {
	border-left: 4px solid var(--cm-orange);
	padding-left: 1.5rem;
	margin: 1.5rem 0;
	font-style: italic;
	color: var(--cm-gray-500);
}

.cm-product-description img {
	border-radius: var(--cm-radius-lg);
	margin: 1.5rem 0;
}

/* ==========================================================================
   WooCommerce Table Overrides (Orders, etc.)
   ========================================================================== */

.woocommerce table.shop_table {
	border: 1px solid var(--cm-gray-200) !important;
	border-radius: var(--cm-radius-xl) !important;
	overflow: hidden;
	border-collapse: separate !important;
	border-spacing: 0 !important;
}

.woocommerce table.shop_table thead {
	background: var(--cm-gray-50) !important;
}

.woocommerce table.shop_table thead th {
	font-size: 0.75rem !important;
	font-weight: 600 !important;
	text-transform: uppercase !important;
	letter-spacing: 0.05em !important;
	color: var(--cm-gray-500) !important;
	padding: 1rem 1.25rem !important;
	border-bottom: 1px solid var(--cm-gray-200) !important;
}

.woocommerce table.shop_table td {
	padding: 1rem 1.25rem !important;
	border-bottom: 1px solid var(--cm-gray-100) !important;
	color: var(--cm-gray-700) !important;
	vertical-align: middle !important;
}

.woocommerce table.shop_table tr:last-child td {
	border-bottom: none !important;
}

/* Order status badges */
.woocommerce table.shop_table .woocommerce-orders-table__cell-order-status {
	font-weight: 600;
}

/* ==========================================================================
   WooCommerce Pagination
   ========================================================================== */

.woocommerce nav.woocommerce-pagination ul {
	border: none !important;
	display: flex;
	gap: 0.5rem;
	justify-content: center;
}

.woocommerce nav.woocommerce-pagination ul li {
	border: none !important;
	overflow: visible !important;
}

.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
	border: 2px solid var(--cm-gray-200) !important;
	border-radius: var(--cm-radius-md) !important;
	padding: 0.5rem 1rem !important;
	font-weight: 600 !important;
	transition: var(--cm-transition) !important;
	color: var(--cm-gray-700) !important;
	background: var(--cm-white) !important;
}

.woocommerce nav.woocommerce-pagination ul li a:hover {
	border-color: var(--cm-orange) !important;
	color: var(--cm-orange) !important;
}

.woocommerce nav.woocommerce-pagination ul li span.current {
	background: var(--cm-orange) !important;
	border-color: var(--cm-orange) !important;
	color: var(--cm-white) !important;
}

/* ==========================================================================
   Misc Utility Overrides
   ========================================================================== */

/* Remove WC default breadcrumbs styling */
.woocommerce .woocommerce-breadcrumb {
	font-size: 0.875rem;
	color: var(--cm-gray-500);
	margin-bottom: 1.5rem;
	padding: 0;
}

.woocommerce .woocommerce-breadcrumb a {
	color: var(--cm-orange);
	text-decoration: none;
}

.woocommerce .woocommerce-breadcrumb a:hover {
	text-decoration: underline;
}

/* Sale badge */
.woocommerce span.onsale {
	background-color: var(--cm-orange) !important;
	border-radius: var(--cm-radius-full) !important;
	font-weight: 700 !important;
	padding: 0.5rem 1rem !important;
	min-height: auto !important;
	line-height: 1.5 !important;
}

/* Star rating */
.woocommerce .star-rating span::before {
	color: #fbbf24 !important;
}

/* Quantity input */
.woocommerce .quantity .qty {
	border: 2px solid var(--cm-gray-200) !important;
	border-radius: var(--cm-radius-md) !important;
	padding: 0.5rem 0.75rem !important;
	width: 4rem !important;
	text-align: center !important;
}

.woocommerce .quantity .qty:focus {
	border-color: var(--cm-orange) !important;
	outline: none !important;
	box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1) !important;
}

/* Loading spinner/overlay */
.woocommerce .blockUI.blockOverlay {
	background-color: rgba(255, 255, 255, 0.7) !important;
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
	.cm-account-nav,
	.cm-quick-card,
	.cm-buy-now-btn,
	.cm-trust-badges {
		display: none !important;
	}

	.cm-thankyou-page,
	.cm-downloads-page {
		max-width: 100%;
	}

	body {
		color: #000 !important;
		background: #fff !important;
	}
}

/* ==========================================================================
   Accessibility Enhancements
   ========================================================================== */

/* Focus-visible for keyboard users */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
	outline: 2px solid var(--cm-orange);
	outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}

	.cm-download-btn::after {
		display: none;
	}

	.cm-buy-now-btn:hover,
	.cm-download-card:hover,
	.cm-quick-card:hover {
		transform: none !important;
	}
}

/* High contrast mode support */
@media (forced-colors: active) {
	.cm-buy-now-btn,
	.cm-download-btn,
	.woocommerce .button {
		border: 2px solid ButtonText !important;
	}

	.cm-account-nav a[aria-current="page"] {
		border: 2px solid Highlight !important;
	}
}

/* ==========================================================================
   Dark mode support (if parent theme enables it)
   ========================================================================== */

@media (prefers-color-scheme: dark) {
	.cm-my-account-wrapper .cm-account-content,
	.cm-download-card,
	.cm-quick-card {
		/* Only apply if a .dark class is present on body (theme-controlled) */
	}
}

/* Dark mode via class (if parent theme uses .dark toggle) */
body.dark-mode .cm-account-content {
	background: var(--cm-navy-dark);
	border-color: var(--cm-navy-light);
	color: var(--cm-gray-200);
}

body.dark-mode .cm-download-card {
	background: var(--cm-navy);
	border-color: var(--cm-navy-light);
}

body.dark-mode .cm-quick-card {
	background: var(--cm-navy);
	border-color: var(--cm-navy-light);
}
