Styling updates and defensive code around event handler attachment for links.