A small refactor to improve HTMLFormat, to help to prevent low-level mistakes. And fix #33141, fix #33139
Remove unmaintainable sanitizer rules. No need to add special "class" regexp rules anymore, use RenderInternal.SafeAttr instead, more details (and examples) are in the tests