The HTML created by the stylesheet is no longer valid XHTML. The problem seems to be in the TOC patch of quite some time ago. Matteo, could try to fix it?