text selection spills over to following HTML element