/* WooCommerce notices: preserve native icons, roles, links and dismissal. */
body .wc-block-components-notice-banner {
	border-radius: 0;
	font-family: var(--wp--preset--font-family--body);
	font-size: calc(var(--wp--preset--font-size--body) * 0.9375);
	line-height: 1.65;
	color: var(--wp--preset--color--ink);
	gap: 14px;
	align-items: center;
}

body .wc-block-components-notice-banner.is-success {
	background: color-mix(in srgb, var(--wp--preset--color--ivory) 75%, var(--wp--preset--color--citron));
	border-color: color-mix(in srgb, var(--wp--preset--color--citron) 80%, var(--wp--preset--color--ink));
}

body .wc-block-components-notice-banner.is-info {
	background: var(--wp--preset--color--ivory);
	border-color: var(--wp--preset--color--divider);
}

body .wc-block-components-notice-banner.is-error {
	background: var(--wp--preset--color--blush);
	border-color: var(--wp--preset--color--burgundy);
}

body .wc-block-components-notice-banner.is-warning {
	background: #f4eddc;
	border-color: #a58d59;
}

body .wc-block-components-notice-banner[class] > svg {
	background: var(--wp--preset--color--burgundy);
	fill: var(--wp--preset--color--ivory);
	margin: 0;
	width: 24px;
	height: 24px;
	box-sizing: border-box;
}

body .wc-block-components-notice-banner .wc-block-components-notice-banner__content a,
body .wc-block-components-notice-banner .wc-block-components-notice-banner__content a.wc-forward {
	color: var(--wp--preset--color--burgundy) !important;
	opacity: 1;
	font-weight: 600;
	text-underline-offset: 4px;
}

/* Legacy shortcodes retain their own semantic notice markup. */
body .woocommerce-message,
body .woocommerce-info,
body .woocommerce-error {
	border-radius: 0;
	font-family: var(--wp--preset--font-family--body);
	font-size: calc(var(--wp--preset--font-size--body) * 0.9375);
	line-height: 1.65;
	color: var(--wp--preset--color--ink);
}

body .woocommerce-message {
	background: color-mix(in srgb, var(--wp--preset--color--ivory) 75%, var(--wp--preset--color--citron));
	border-top-color: color-mix(in srgb, var(--wp--preset--color--citron) 80%, var(--wp--preset--color--ink));
}

body .woocommerce-info {
	background: var(--wp--preset--color--ivory);
	border-top-color: var(--wp--preset--color--divider);
}

body .woocommerce-error {
	background: var(--wp--preset--color--blush);
	border-top-color: var(--wp--preset--color--burgundy);
}

body :is(.woocommerce-message, .woocommerce-info, .woocommerce-error)::before {
	color: var(--wp--preset--color--burgundy);
}

body .wc-block-components-notice-banner .wc-block-components-notice-banner__content {
	overflow-wrap: anywhere;
}

@media (max-width: 600px) {
	body .wc-block-components-notice-banner .wc-block-components-notice-banner__content .wc-forward {
		float: none;
		display: block;
		width: fit-content;
		margin: 0 0 8px;
	}
}

/* Match the action line box to the message rather than theme button sizing. */
body .wc-block-components-notice-banner .wc-block-components-notice-banner__content .wc-forward {
	min-height: 0;
	height: auto;
	line-height: inherit;
	font-size: inherit;
	vertical-align: middle;
}

body .wc-block-components-notice-banner > .wc-block-components-button {
	align-self: center;
	margin-block: 0 !important;
}
