Fixed window resize layout bug