toc: fix lines before horizontal lines being matched as headers