You can do it with jquery, when something happens, do:
$('yourdiv1').css({"color": "black"})
$('yourdiv2').css({"background-color": "white"})
To set it to default just:
$('yourdiv1').css({"color": ""})
$('yourdiv2').css({"background-color": ""})
Also add transitions to make it look really nice.