improved element spacing in edge case scenario