/**
 * Shop v2 flow refinements (product/cart/checkout).
 *
 * Scope firewall:
 * - Core product/cart selectors are locked to body.shop-v2.
 * - Checkout form fallbacks are limited to .woocommerce-checkout elements only.
 * - No global WooCommerce selector overrides.
 */

body.shop-v2 {
	--shop-v2-soft-edge-radius: 10px;
	--shop-v2-soft-edge-radius-sm: 8px;
	--shop-v2-soft-edge-border: 1px solid #d6dce4;
	--shop-v2-font-regular: "Montserrat-Regular", Helvetica, Arial, sans-serif;
	--shop-v2-font-medium: "Montserrat-Medium", Helvetica, Arial, sans-serif;
	--shop-v2-font-bold: "Montserrat-Bold", Helvetica, Arial, sans-serif;
}

body.shop-v2 #game-detail-shop,
body.shop-v2 .woocommerce-cart-form,
body.shop-v2 .cart_totals,
body.shop-v2 .woocommerce-checkout {
	font-family: var(--shop-v2-font-regular);
}

body.shop-v2 #game-detail-shop .orderbox {
	border-radius: var(--shop-v2-soft-edge-radius);
	overflow: hidden;
	border: var(--shop-v2-soft-edge-border);
}

body.shop-v2 #game-detail-shop .quantity-button .cart {
	border-radius: var(--shop-v2-soft-edge-radius-sm);
	overflow: hidden;
}

body.shop-v2 #game-detail-shop .quantity-button .quantity .qty {
	border-radius: var(--shop-v2-soft-edge-radius-sm) 0 0 var(--shop-v2-soft-edge-radius-sm);
	font-family: var(--shop-v2-font-medium);
	min-height: 3.5rem;
}

body.shop-v2 #game-detail-shop .quantity-button button.single_add_to_cart_button {
	border-radius: 0 var(--shop-v2-soft-edge-radius-sm) var(--shop-v2-soft-edge-radius-sm) 0;
	font-family: var(--shop-v2-font-bold);
}

body.shop-v2 .cart-collaterals .cross-sells .shoplisting-footer .add-to-cart-button.more-info-button {
	border-radius: var(--shop-v2-soft-edge-radius-sm) !important;
	font-family: var(--shop-v2-font-bold);
}

body.shop-v2 .cart-collaterals .cross-sells ul.products > li.shoplisting-product {
	border-radius: var(--shop-v2-soft-edge-radius) !important;
	overflow: hidden;
}

body.shop-v2 .woocommerce-cart-form .quantity .qty {
	border-radius: var(--shop-v2-soft-edge-radius-sm);
	border: var(--shop-v2-soft-edge-border);
	min-height: 2.75rem;
	font-family: var(--shop-v2-font-medium);
}

body.shop-v2 .woocommerce-notices-wrapper .woocommerce-message .button.wc-forward,
body.shop-v2 .woocommerce-notices-wrapper .woocommerce-message > .button.wc-forward,
body.shop-v2 .wc-proceed-to-checkout .checkout-button {
	border-radius: var(--shop-v2-soft-edge-radius-sm) !important;
	font-family: var(--shop-v2-font-bold);
}

/* Checkout v2 (css/checkout-v2.css) and Cart v2 (css/cart-v2.css) are the
   canonical owners of all checkout button, Stripe payment, and cart-button
   styling. The legacy soft-edge overrides for #place_order, the Stripe payment
   containers, and the Update Cart button were removed from here so they no
   longer conflict with the v2 design. */

body.shop-v2 .woocommerce-checkout form .form-row input.input-text,
body.shop-v2 .woocommerce-checkout form .form-row select,
body.shop-v2 .woocommerce-checkout form .form-row textarea,
body.shop-v2 .woocommerce-checkout .select2-container--default .select2-selection--single,
body.shop-v2 .woocommerce-checkout .select2-container--default .select2-selection--multiple,
form.checkout.woocommerce-checkout .form-row input.input-text,
form.checkout.woocommerce-checkout .form-row select,
form.checkout.woocommerce-checkout .form-row textarea,
form.checkout.woocommerce-checkout .select2-container--default .select2-selection--single,
form.checkout.woocommerce-checkout .select2-container--default .select2-selection--multiple {
	border-radius: var(--shop-v2-soft-edge-radius-sm, 8px) !important;
	border: var(--shop-v2-soft-edge-border, 1px solid #d6dce4);
	font-family: var(--shop-v2-font-medium, "Montserrat-Medium", Helvetica, Arial, sans-serif);
}

body.shop-v2 .woocommerce-checkout .select2-container--default .select2-selection--single,
form.checkout.woocommerce-checkout .select2-container--default .select2-selection--single {
	min-height: 2.85rem;
}

body.shop-v2 .woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__rendered,
form.checkout.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__rendered {
	line-height: 2.85rem;
}

body.shop-v2 .woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__arrow,
form.checkout.woocommerce-checkout .select2-container--default .select2-selection--single .select2-selection__arrow {
	height: 2.85rem;
}

body.shop-v2 #game-detail-shop .hero-image h2,
body.shop-v2 #game-detail-shop .game-info .instock,
body.shop-v2 #game-detail-shop .game-info .instock strong,
body.shop-v2 #game-detail-shop .orderbox .price,
body.shop-v2 #game-detail-shop h3,
body.shop-v2 #game-detail-shop .game-info .detail-points li,
body.shop-v2 #game-detail-shop .game-info .detail-points li .game-info-text,
body.shop-v2 #game-detail-shop .game-info .detail-points li .game-info-text-details,
body.shop-v2 #game-detail-shop .game-info .detail-points li .game-info-detail-line {
	font-family: var(--shop-v2-font-bold) !important;
}

@media (max-width: 1024px) {
	body.shop-v2 {
		--shop-v2-soft-edge-radius: 10px;
		--shop-v2-soft-edge-radius-sm: 8px;
	}
}

@media (max-width: 640px) {
	body.shop-v2 {
		--shop-v2-soft-edge-radius: 10px;
		--shop-v2-soft-edge-radius-sm: 8px;
	}

	/* Keep quantity and CTA control outlines uniform on product detail mobile layout. */
	body.shop-v2 #game-detail-shop .quantity-button .quantity .qty,
	body.shop-v2 #game-detail-shop .quantity-button button.single_add_to_cart_button {
		height: 3.2rem;
		min-height: 3.2rem;
	}
}
