HeHe… @harr , It’s not recognised by Obsidian as a header to be included in the headings metadataCache. It’s seems to be formatted kind of correct, but you’re in a grey zone as you start introducing block elements within inline elements (aka an <h2> within a <li> element) which is strictly speaking not following the HTML standards.
In short, I don’t recommend doing it, but I do see people wanting that visual effect. But Obsidian doesn’t recognise it as a header, as shown at the top in the thread below.