Fix z-index of legend and layers