Using kramdown to put a box around a paragraph with display math

Hi! I’m completely new to Jekyll and kramdown, so apologies in advance if I’m missing something obvious.

I’m trying to use the TeXt theme (random decision, it was mainly for the header image support?). I want to box some text and I saw the “additional styles” page here:
https://kitian616.github.io/jekyll-TeXt-theme/docs/en/additional-styles

The simple case works fine:

{:.info}

This is text.
Lots of it.

…but I have a paragraph that contains display math, which needs newlines:


{:.info}

This is text.

$$
x^2 + y^2 = z^2
$$

More text.

Now kramdown seems to treat these as separate paragraphs, so only the first sentence is boxed. Is there an easy way around this?

You can use a div and tell kramdown that you still want Markdown to be interpreted within that div, something like

<div markdown="1">
This is text.

$$
x^2 + y^2 = z^2
$$

More text.
</div>
{: .info}

See the docs at Syntax | kramdown

Renders for me on a MathJax-enabled Jekyll website with a similar utility class like this: