Fixing dropdown menu snapping