/* =========================================================
   Cat Corner — WooCommerce Cart custom styles.
   Loaded only on the cart page (see functions.php enqueue).
   Design System tokens:
     primary:               #00B4D8  (Electric Cyan)
     secondary-container:   #D6F2F8  (cyan-100 fill)
     cat-gold / CTA:        #FFC300  (Goldenrod — checkout button)
     surface-container-low: #F1F5F8
     outline-variant:       #E4E9EE
     on-surface-variant:    #2A2A2A
     error:                 #ba1a1a
   ========================================================= */

/* ---- Chewy display font utility (used by headings + totals) ---- */
.font-chewy {
	font-family: 'Chewy', cursive;
	font-weight: 400;
	letter-spacing: 0.01em;
}

/* ---- Quantity stepper wrapper ---- */
body.woocommerce-cart .cc-cart__qty-stepper {
	display: inline-flex;
	align-items: center;
	border: 1px solid #E4E9EE;
	border-radius: 8px;
	overflow: hidden;
	background: #ffffff;
}
body.woocommerce-cart .cc-cart__qty-stepper .cc-qty-minus,
body.woocommerce-cart .cc-cart__qty-stepper .cc-qty-plus {
	width: 36px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
	color: #2A2A2A;
	background: #F1F5F8;
	border: none;
	cursor: pointer;
	transition: background 150ms ease, color 150ms ease;
	box-shadow: none !important;
	padding: 0 !important;
}
body.woocommerce-cart .cc-cart__qty-stepper .cc-qty-minus:hover,
body.woocommerce-cart .cc-cart__qty-stepper .cc-qty-plus:hover {
	background: #00B4D8 !important;
	color: #ffffff !important;
}

/* ---- Quantity input (inside stepper) ---- */
body.woocommerce-cart .cc-cart__qty,
body.woocommerce-cart input.qty {
	width: 44px;
	height: 40px;
	padding: 6px 4px;
	text-align: center;
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	color: #000000;
	background: #ffffff;
	border: none;
	border-left: 1px solid #E4E9EE;
	border-right: 1px solid #E4E9EE;
	border-radius: 0;
	outline: none;
}
body.woocommerce-cart .cc-cart__qty:focus,
body.woocommerce-cart input.qty:focus {
	border-color: #E4E9EE;
	box-shadow: none;
}
/* Hide native spinner */
body.woocommerce-cart input.qty::-webkit-outer-spin-button,
body.woocommerce-cart input.qty::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}
body.woocommerce-cart input.qty[type='number'] {
	-moz-appearance: textfield;
	appearance: textfield;
}

/* ---- Hidden fallback "Update cart" button ----
   WC AJAX needs this in the DOM so quantity edits submit cleanly.
   We hide it visually but keep it focusable for keyboard users
   when the AJAX script is unavailable. */
body.woocommerce-cart .cc-cart__update-fallback {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* ---- AJAX loading overlay ----
   WC sets .blockUI.blockOverlay over the row being updated.
   Replace the default dark grey with a soft cream wash. */
body.woocommerce-cart .blockUI.blockOverlay {
	background: rgba(248, 250, 252, 0.65) !important; /* Oatmeal wash */
	opacity: 1 !important;
	cursor: wait;
	transition: opacity 150ms ease;
}
body.woocommerce-cart .blockUI.blockMsg {
	display: none !important;
}

/* ---- Cart item product name ----
   Force Plus Jakarta Sans on the link itself (Elementor or parent theme
   may apply a different family to <a> globally), and follow the
   .group-hover rule for color instead of Elementor's global a:hover. */
body.woocommerce-cart .cc-cart__product-name,
body.woocommerce-cart .cc-cart__product-name a {
	font-family: 'Plus Jakarta Sans', sans-serif !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	line-height: 1.4 !important;
	color: inherit !important;
	text-decoration: none !important;
}
@media (min-width: 768px) {
	body.woocommerce-cart .cc-cart__product-name,
	body.woocommerce-cart .cc-cart__product-name a {
		font-size: 14px !important;
	}
}
body.woocommerce-cart .woocommerce-cart-form__cart-item:hover .cc-cart__product-name,
body.woocommerce-cart .woocommerce-cart-form__cart-item:hover .cc-cart__product-name a {
	color: #00B4D8 !important;
}

/* ---- "Hapus Item" remove link ----
   The default WC class .remove ships with red × styling we don't want;
   our anchor uses .cc-cart__remove so no conflict, but reset .remove
   in case any plugin filter outputs the default markup. */
body.woocommerce-cart .cc-cart__remove {
	background: none !important;
	border: 0 !important;
	padding: 0 !important;
	box-shadow: none !important;
	text-decoration: none !important;
}
body.woocommerce-cart .cc-cart__remove:hover {
	color: #ba1a1a !important;
	opacity: 0.8;
}

/* ---- Coupon input + apply button polish ----
   Without an explicit text color, the typed value can inherit from a
   global rule (Elementor's typography sometimes sets input color to
   the surface color) and become illegible. Force on-surface ink. */
body.woocommerce-cart .cc-cart__coupon-input {
	color: #000000 !important;
	font-family: 'Plus Jakarta Sans', sans-serif;
	font-weight: 500;
}
body.woocommerce-cart .cc-cart__coupon-input::placeholder {
	color: #6B7280;
	opacity: 1;
}
/* Constrain icon width so the input's pl-14 (56px) reliably clears it. */
body.woocommerce-cart .cc-cart__coupon-icon {
	font-family: 'Material Symbols Outlined' !important;
	font-size: 22px;
	line-height: 1;
	width: 24px;
	height: 24px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* ---- Checkout CTA ----
     • Default = Goldenrod pill, Pitch Black text (DS: gold is CTA-only)
     • Hover   = gold-700 (#E0A500) pill, Pitch Black text
   Tailwind handles background via bg-cat-gold. These !important rules
   lock text color and strip Elementor's a:hover overrides. */
body.woocommerce-cart .cc-cart__checkout-btn,
body.woocommerce-cart .cc-cart__checkout-btn:visited {
	color: #000000 !important;          /* Pitch Black on Goldenrod */
	text-decoration: none !important;
}
body.woocommerce-cart .cc-cart__checkout-btn:hover,
body.woocommerce-cart .cc-cart__checkout-btn:focus {
	background-color: #E0A500 !important; /* gold-700 pressed */
	color: #000000 !important;
	text-decoration: none !important;
}
body.woocommerce-cart .cc-cart__checkout-btn .material-symbols-outlined {
	color: inherit !important;
}
body.woocommerce-cart .cc-cart__checkout-btn:focus-visible {
	outline: 3px solid rgba(255, 195, 0, 0.5); /* Goldenrod focus ring */
	outline-offset: 2px;
}

/* ---- "Kembali Belanja" back-to-shop link ----
   Electric Cyan — Elementor's global a:hover would otherwise override. */
body.woocommerce-cart .cc-cart__back,
body.woocommerce-cart .cc-cart__back:hover,
body.woocommerce-cart .cc-cart__back:focus,
body.woocommerce-cart .cc-cart__back span {
	color: #00B4D8 !important; /* Electric Cyan */
	text-decoration: none !important;
}

/* ---- Cart-level WooCommerce notices ----
   These appear after coupon apply / remove and on add-to-cart redirects.
   Style them so they fit the cream surface palette. */
body.woocommerce-cart .woocommerce-message,
body.woocommerce-cart .woocommerce-info,
body.woocommerce-cart .woocommerce-error {
	list-style: none;
	padding: 14px 18px;
	margin: 0 0 20px;
	border-radius: 12px;
	border: 1px solid #E4E9EE;
	background: #F1F5F8;
	font-size: 14px;
	font-weight: 500;
	color: #000000;
}
body.woocommerce-cart .woocommerce-message {
	border-color: rgba(0, 180, 216, 0.5); /* cyan success border */
	background: #D6F2F8;                   /* cyan-100 */
}
body.woocommerce-cart .woocommerce-error {
	border-color: rgba(186, 26, 26, 0.4);
	background: #ffdad6;
	color: #93000a;
}
body.woocommerce-cart .woocommerce-message .button,
body.woocommerce-cart .woocommerce-error .button,
body.woocommerce-cart .woocommerce-info .button {
	margin-left: 12px;
	font-size: 13px;
	font-weight: 600;
	color: #00B4D8; /* Electric Cyan */
	text-decoration: underline;
	background: none;
	border: 0;
}

/* ---- Applied-coupon remove link inside totals ---- */
body.woocommerce-cart .cc-cart__discount .woocommerce-remove-coupon {
	display: inline-block;
	margin-left: 8px;
	font-size: 11px;
	color: #ba1a1a;
	text-decoration: underline;
}

/* ---- Empty cart: decorative dot pattern background ---- */
.cc-cart-empty__dots {
	background-image: radial-gradient(#00B4D8 0.5px, transparent 0.5px); /* cyan dots */
	background-size: 24px 24px;
}

/* ---- Strip WooCommerce's default "Your cart is currently empty." copy
   that wc_empty_cart_message would otherwise inject above our CTA. ---- */
body.woocommerce-cart .cart-empty.woocommerce-info {
	display: none;
}

/* ---- Sticky sidebar safety: leave room for sticky header (h-20 = 80px) ---- */
@media (min-width: 1024px) {
	body.woocommerce-cart .cc-cart aside.lg\:sticky {
		top: 96px;
	}
}
