$(document).ready(function(){var a="offer-choice",b="offer-button";$(".accordion .toggle").click(function(){if($(this).next(".accordionContent").is(":hidden")){$(this).addClass("expanded");$(this).parent().addClass("acc-expanded");$(this).next(".accordionContent").slideDown("fast")}else{$(this).removeClass("expanded");$(this).next(".accordionContent").slideUp("fast",function(){$(this).parent().removeClass("acc-expanded")})}return false});$(".accordion .toggle a").click(function(){if($(this).parent().parent().next().next().is(":hidden")){$(".accordion .toggle a").removeClass("expanded");$(".accordion .toggle a").html("View Programs");$(this).html("Hide Programs");$(this).addClass("expanded");$(".accordion .accordionContent").slideUp("fast");$(this).parents(".toggle").nextAll(".accordionContent").slideDown("fast")}else{$(this).removeClass("expanded");$(this).html("View Programs");$(this).parents(".toggle").nextAll(".accordionContent").slideUp("fast")}return false});$(".accordion .toggle a").each(function(){var c=false;$(this).parents(".accordion").find(".accordionContent").filter(".collapsed").each(function(){c=true});if(c){$(this).click()}});$(":radio[name^='"+a+"']").click(function(){var e=this.name.substring(a.length),d=/(.+)-\d+/,c=d.exec(e);if(c){e=c[1]}$("."+$(this).attr("class")).attr("checked",this.checked);$("a."+b+e).attr("href",this.value)});$("a.popup").first().each(function(){$.getScript("/cms/global/static/js/jquery.popupWindow.min.t8589170058924488439.js",function(){$("a.popup").popupWindow({centerScreen:1,windowName:"popup"})})})});function writeVideo(j,n){var c=$(j).attr("video"),h=$(j).attr("image"),l=$(j).attr("target_id"),k=jwplayer(l),g="autostart",a="backcolor",m="frontcolor",b="width",i="height",f,d;if(arguments[1]==undefined){n={}}n[g]=(n[g]==undefined?true:n[g]);n[a]=(n[a]==undefined?"000000":n[a]);n[m]=(n[m]==undefined?"ffffff":n[m]);n[b]=(n[b]==undefined?245:n[b]);n[i]=(n[i]==undefined?137:n[i]);if(k){if(k.getState()){f=k.getPlaylistItem();if(f){d=f.file}}if(d!=c){k.setup({autostart:n[g],backcolor:n[a],flashplayer:"http://aws-cdn.hottopicmedia.com/global/static/media/jwplayer-5.8.swf",file:c,frontcolor:n[m],height:n[i],image:h,width:n[b]})}else{k.play(true)}}return false};
