/**
 * Member Discount for WooCommerce — front-end styles.
 *
 * Scoped to `.woocommerce` so nothing bleeds into the surrounding theme.
 * The member discount renders as a WooCommerce coupon discount row
 * (`tr.cart-discount.coupon-member_discount`); we tint it green and prepend a
 * small "MEMBER" pill to make it clearly distinguishable from regular totals
 * and from the customer's own coupons. Works with Storefront, Astra,
 * GeneratePress and block-based themes because it only touches WooCommerce's
 * own markup.
 */

/* Cart totals + checkout review coupon row colouring. */
.woocommerce .cart_totals .cart-discount.coupon-member_discount th,
.woocommerce .cart_totals .cart-discount.coupon-member_discount td,
.woocommerce-cart .cart_totals .cart-discount.coupon-member_discount th,
.woocommerce-cart .cart_totals .cart-discount.coupon-member_discount td,
.woocommerce-checkout .woocommerce-checkout-review-order-table .cart-discount.coupon-member_discount th,
.woocommerce-checkout .woocommerce-checkout-review-order-table .cart-discount.coupon-member_discount td {
	color: #2e7d32;
}

.woocommerce .cart_totals .cart-discount.coupon-member_discount td .amount,
.woocommerce-cart .cart_totals .cart-discount.coupon-member_discount td .amount,
.woocommerce-checkout .woocommerce-checkout-review-order-table .cart-discount.coupon-member_discount td .amount {
	color: #2e7d32;
	font-weight: 600;
}

/* Small "MEMBER" pill prepended to the coupon label cell. */
.woocommerce .cart_totals .cart-discount.coupon-member_discount th::before,
.woocommerce-cart .cart_totals .cart-discount.coupon-member_discount th::before,
.woocommerce-checkout .woocommerce-checkout-review-order-table .cart-discount.coupon-member_discount th::before {
	content: "MEMBER";
	display: inline-block;
	margin-right: 0.5em;
	padding: 0.1em 0.5em;
	border-radius: 999px;
	background-color: #2e7d32;
	color: #ffffff;
	font-size: 0.7em;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: 0.03em;
	vertical-align: middle;
	text-transform: uppercase;
}

/* Block-based Cart & Checkout blocks (WooCommerce Blocks) discount row. */
.woocommerce .wc-block-components-totals-discount .wc-block-components-totals-item__value,
.wc-block-components-totals-discount .wc-block-components-totals-item__value {
	color: #2e7d32;
	font-weight: 600;
}
