\chapter{Animals}
instead of
== Animals
or should that be:
=== Animals
I think an xml or html like approach is better:
<chapter>Animals</chapter>
One of the big issue is modal states for structure or styling.
I've often found trouble in latex because you are in some state that you didn't expect and somehow have to get out of.
Nested XML would hopefully be more obvious about what your state is.
Docbook probably got this right, but it was too verbose for most.
But then surely the h1 document title should be above that, which would be "=" (1), so a chapter is below at "==" (2)?
\part apparently is -1 in latex, which would be seem to be odd.
But document title isn't part of the latex sectioning hierarchy...
Given that there is a document title, part and chapter, chapter could maybe "===" (3) or maybe "==" (2) if we're not using parts or we don't consider the document title.
I think anyway?
It's unfortunate that the creators of latex did not follow the HTML heading rules better. (despite latex pre-dating html of course)
:-)