/* =========================================================================
   HFT — MINI-CART CONFIRMATION POPUP  (WS9)

   Compact "Added to cart" card, anchored under the header near the cart icon.
   Fires on WooCommerce's AJAX added_to_cart. Brand Kit V2.1 tokens only.

   !important is used on colour/typography while Elementor's kit CSS
   (.elementor-kit-38 a { sage tint }, Fraunces, etc.) is still enqueued.
   WS13 revisits this once Elementor is removed.
   ========================================================================= */

.hft-mc {
	position: fixed;
	top: 84px;
	right: 24px;
	z-index: 99990;
	width: 340px;
	max-width: calc(100vw - 32px);
	box-sizing: border-box;
	padding: 16px 16px 14px;
	background: #fff;
	border: 1px solid var(--hft-line, #E9E0D4);
	border-radius: var(--hft-r-md, 16px);
	box-shadow: 0 22px 48px -20px rgba(18, 48, 90, .45), 0 4px 12px -6px rgba(18, 48, 90, .18);
	font-family: var(--hft-font-body, "Nunito Sans", sans-serif) !important;
	color: var(--hft-ink, #231F20) !important;
	opacity: 0;
	transform: translateY(-10px);
	transition: opacity .22s ease, transform .22s ease;
	pointer-events: none;
}

.hft-mc.is-open {
	opacity: 1;
	transform: translateY(0);
	pointer-events: auto;
}

/* ---- Close ----
   Hardened against the site-wide rose <button> lock (Brand Kit still ships a
   global button fill while Elementor is installed). Two-class scope + !important
   so the × is a bare navy glyph, never a filled rose pill. */
.hft-mc .hft-mc-close {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 30px !important;
	height: 30px !important;
	min-width: 0 !important;
	max-width: 30px !important;
	padding: 0 !important;
	margin: 0 !important;
	display: flex !important;
	align-items: center;
	justify-content: center;
	border: 0 !important;
	background: transparent !important;
	background-color: transparent !important;
	border-radius: 999px !important;
	color: var(--hft-muted, #93A0AD) !important;
	-webkit-text-fill-color: currentColor !important;
	box-shadow: none !important;
	line-height: 1 !important;
	cursor: pointer;
	transition: background-color .15s ease, color .15s ease;
}
.hft-mc .hft-mc-close:hover,
.hft-mc .hft-mc-close:focus-visible {
	background: rgba(27, 67, 125, .10) !important;
	background-color: rgba(27, 67, 125, .10) !important;
	color: var(--hft-navy, #1B437D) !important;
	-webkit-text-fill-color: var(--hft-navy, #1B437D) !important;
	outline: none;
}
.hft-mc .hft-mc-close svg {
	width: 15px !important;
	height: 15px !important;
	display: block !important;
	color: inherit !important;
}
.hft-mc .hft-mc-close svg path { stroke: currentColor !important; }

/* ---- "Added to cart" line ---- */
.hft-mc-added {
	display: flex;
	align-items: center;
	gap: 9px;
	padding-right: 28px;
	font-family: var(--hft-font-display, "Fredoka", sans-serif) !important;
	font-weight: 600;
	font-size: 16px;
	color: var(--hft-navy, #1B437D) !important;
	line-height: 1.2;
}
.hft-mc-check {
	flex: 0 0 auto;
	width: 22px;
	height: 22px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--hft-cta, #D6337B);
	color: #fff !important;
	border-radius: 999px;
}
.hft-mc-check svg { width: 14px; height: 14px; }

/* "My Cart" heading uses a cart glyph in the same pink circle. */
.hft-mc-cart svg { width: 15px; height: 15px; }

/* Empty-cart line (header cart icon → "My Cart" with nothing in the basket). */
.hft-mc-empty {
	margin: 14px 0 2px;
	font-size: 14px;
	font-weight: 600;
	color: var(--hft-muted, #93A0AD) !important;
}

/* ---- Item just added ---- */
.hft-mc-item {
	display: flex;
	align-items: center;
	gap: 11px;
	margin-top: 12px;
}
.hft-mc .hft-mc-thumb,
.hft-mc-item img {
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
	object-fit: cover;
	border-radius: 10px;
	border: 1px solid var(--hft-line, #E9E0D4);
	background: var(--hft-cream, #FBF5EC);
}
.hft-mc-name {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	color: var(--hft-ink, #231F20) !important;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ---- Subtotal / count ---- */
.hft-mc-summary {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	margin-top: 12px;
	padding-top: 11px;
	border-top: 1px solid var(--hft-cream-200, #EEE6DA);
}
.hft-mc-count {
	font-size: 12.5px;
	font-weight: 700;
	letter-spacing: .01em;
	text-transform: uppercase;
	color: var(--hft-muted, #93A0AD) !important;
}
.hft-mc-sub {
	font-size: 17px;
	font-weight: 800;
	color: var(--hft-navy, #1B437D) !important;
}
.hft-mc-sub .woocommerce-Price-amount,
.hft-mc-sub bdi { color: var(--hft-navy, #1B437D) !important; }

/* ---- Actions ---- */
.hft-mc-actions {
	display: flex;
	gap: 10px;
	margin-top: 14px;
}
.hft-mc .hft-mc-btn {
	flex: 1 1 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 44px;
	padding: 0 14px;
	border-radius: var(--hft-r-pill, 999px);
	font-family: var(--hft-font-body, "Nunito Sans", sans-serif) !important;
	font-weight: 800 !important;
	font-size: 14px;
	line-height: 1;
	text-align: center;
	text-decoration: none !important;
	text-transform: none !important;
	box-sizing: border-box;
	cursor: pointer;
	transition: background .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.hft-mc .hft-mc-btn--ghost {
	background: #fff !important;
	color: var(--hft-navy, #1B437D) !important;
	-webkit-text-fill-color: var(--hft-navy, #1B437D) !important;
	border: 2px solid var(--hft-navy, #1B437D) !important;
}
/* Canonical HFT ghost hover: invert to a solid navy fill with white text —
   matches .hft-btn--ghost, the cart + thank-you ghost buttons. (Not cream.) */
.hft-mc .hft-mc-btn--ghost:hover,
.hft-mc .hft-mc-btn--ghost:focus-visible {
	background: var(--hft-navy, #1B437D) !important;
	border-color: var(--hft-navy, #1B437D) !important;
	color: #fff !important;
	-webkit-text-fill-color: #fff !important;
	outline: none;
}
.hft-mc .hft-mc-btn--cta {
	background: var(--hft-cta, #D6337B) !important;
	color: #fff !important;
	-webkit-text-fill-color: #fff !important;
	border: 2px solid var(--hft-cta, #D6337B) !important;
	box-shadow: var(--hft-sh-btn, 0 12px 26px -14px rgba(214, 51, 123, .75));
}
.hft-mc .hft-mc-btn--cta:hover,
.hft-mc .hft-mc-btn--cta:focus-visible {
	background: var(--hft-cta-hover, #B62A67) !important;
	border-color: var(--hft-cta-hover, #B62A67) !important;
	color: #fff !important;
	-webkit-text-fill-color: #fff !important;
	outline: none;
}

/* ---- Mobile: top sheet, full width ---- */
@media (max-width: 600px) {
	.hft-mc {
		top: 12px;
		right: 12px;
		left: 12px;
		width: auto;
		max-width: none;
	}
}

/* Respect reduced-motion. */
@media (prefers-reduced-motion: reduce) {
	.hft-mc { transition: opacity .01s linear; transform: none; }
	.hft-mc.is-open { transform: none; }
}

/* ---- Item H (SOW batch A–H): hide Woo's inline "View cart" link ----------
   wc-add-to-cart.js appends a.added_to_cart.wc-forward next to a card button
   after an AJAX add. The branded mini-cart popup already covers View cart /
   Checkout, so this inline confirmation is redundant. JS removes it; this is
   the belt-and-suspenders so it never flashes before the JS runs. */
a.added_to_cart.wc-forward,
a.added_to_cart { display: none !important; }
