how do the nervous and endocrine systems respond to an increase in environmental temperature to achive homeostasis