chameleons don't only change color to hide but also to show mood, dark coloration, like yours was exhibiting, is an indication that the chameleon was uncomfortable, this could have been caused by several factors: ie. there might have been something environmentally wrong