/* BM3 no longer places messages below .bp-messages-wrap. Scope directly to
 * BM3 message classes so the rule works in App, Safari and the full page. */
@media (max-width: 768px) {
	body .bm-msg-stack {
		--bm-bubble-max-width: 100% !important;
		--bm-msg-actions-space: 40px !important;
	}

	body.tc-bm-longpress-ready .bm-msg-stack {
		--bm-msg-actions-space: 0px !important;
	}

	body .bm-msg-stack__bubbles,
	body .bm-msg-body,
	body .bm-msg-main,
	body .bm-msg-bubble {
		box-sizing: border-box !important;
		min-width: 0 !important;
		max-width: 100% !important;
	}

	/* Match the pre-BM3 custom CSS: short text stays compact; only long text,
	 * video and cards grow to the shared maximum available beside the avatar. */
	body .bm-msg-body,
	body .bm-msg-main,
	body .bm-msg-bubble {
		flex: 0 1 auto !important;
		width: auto !important;
	}
}
