how to prevent hair thinning and loss