Fix some layout issues for window resizing and in chrome