window.addEvent('domready', function(){	
	$$('input.cat').addEvent('click',function(e){
		var check = this.checked;
		$$('input.'+this.id+',input.vis-'+this.id).each(function(el,index){
			el.checked = check;
		});
	});
	$$('input[id^=book-]').addEvent('click',function(e){
		var vis = (this.id).replace('book','vis');
		$(vis).checked = $(this.id).checked;
	})	
});