@alexbuzzbee I'm very much working one #1, but I'm interested to see what you come up with!
Also I'm basically treating HTML like XML, only my user agent stylesheet cares about the different elements so far. And that (mostly) extends to the HTML parser I'm using.