Clean up HTML, add stats