layout optimizations for safari