function trim(n){return n.replace(/^\s+|\s+$/g,"")}function ltrim(n){return n.replace(/^\s+/,"")}function rtrim(n){return n.replace(/\s+$/,"")}var USOC,getCookie,setCookie;try{c=console.log}catch(e){}jQuery.expr[":"].regex=function(n,t,i){var r=i[3].split(","),u=/^(data|css):/,f={method:r[0].match(u)?r[0].split(":")[0]:"attr",property:r.shift().replace(u,"")},e=new RegExp(r.join("").replace(/^\s+|\s+$/g,""),"ig");return e.test(jQuery(n)[f.method](f.property))};USOC={SPEED:{fast:200,normal:500,slow:1e3},TRANSPARENCY:.7,PAGESCROLL:{top:750,middle:1875,bottom:2625},CURRENT_PAGE:jQuery("body").attr("class"),IE:jQuery.browser.msie?parseInt(jQuery.browser.version):!1};jQuery.noConflict(),function(n){n(document).ready(function(){USOC.IE&&USOC.IE<=7&&n(".sponsors .logo").append(n('<span style="display: inline-block;" />'));switch(USOC.IE){case 9:n("html").addClass("ie9");break;case 8:n("html").addClass("ie8");break;case 7:n("html").addClass("ie7")}navigator.userAgent.toLowerCase().match(/(iphone|ipod|ipad|android|webos)/)&&n("body").addClass("mobile");n(".module").css("opacity",0);n(".module").each(function(){n(this).delay(Math.ceil(Math.random()*1500)).animate({opacity:1},USOC.SPEED.normal,function(){n(this).has(".blind")&&n(this).find(".blind").blinds({})})});n(".main-nav > li.sports").bind("mouseenter",function(){n(this).find(".sub-nav.level-1 li.summer").addClass("selected")});n(".main-nav > li.sports > .sub-nav.level-1 > li").bind("mouseenter",function(){n(this).addClass("selected")});n(".main-nav > li.sports > .sub-nav.level-1 > li").bind("mouseleave",function(t){n(t.relatedTarget).hasClass("sub-nav")||n(this).removeClass("selected")});n(".sign-up, .search-input-wrapper, .search-box, .video-search").fieldReset({"class":"gray"});n("select.replace").replaceSelect();n(".carousel").carousel();n(".datepicker-from, .datepicker-to").datepicker({dateFormat:"mm/dd/y",dayNamesMin:["S","M","T","W","T","F","S"],showOtherMonths:!0,selectOtherMonths:!0});n("a.image-gallery").each(function(){var t=n(this);t.lox({speed:500,onLoad:function(){},onShow:function(){t.find(".play").show();t.find(".loading").hide()},onHide:function(){},type:"ajax",url:"/gallery/slideshow?sid="+t.attr("sid")})})}),function(n){n.fn.accordion=function(t){var t=n.extend({},t);return this.each(function(){$triggers=n(".accordion li span.accordion-trigger");$content=n(".accordion li span.accordion-trigger + .accordion-content");n('<div class="blocker" />').appendTo($triggers.parent());$triggers.each(function(){n(this).click(function(t){if($content.filter(":animated").length>0)return!1;$content.filter(":visible").length==0?(n(this).next(".accordion-content").slideDown(USOC.SPEED.normal),n(this).parent().addClass("selected"),$triggers.not(n(this)).parent().find(".blocker").show().animate({opacity:.6},USOC.SPEED.normal)):($content.filter(":visible:not(:animated)").slideUp(USOC.SPEED.normal),n(this).parent().removeClass("selected"),$triggers.not(n(this)).parent().find(".blocker").animate({opacity:0},USOC.SPEED.normal,function(){n(this).hide()}));t.preventDefault()})})})}}(jQuery),function(n){n.fn.pageScrollBar=function(t){var i={top:USOC.PAGESCROLL.top,middle:USOC.PAGESCROLL.middle,bottom:USOC.PAGESCROLL.bottom,content:n("#content-wrapper"),"reveal-bar":n(this)},t=n.extend(i,t);t.content.height(t.top);n(t["reveal-bar"]).bind("click",function(){if(n(t.content).filter(":animated").length>0)return!1;switch(t.content.height()){case t.top:n(t.content).animate({height:t.middle},USOC.SPEED.normal);break;case t.middle:n(t.content).animate({height:t.bottom},USOC.SPEED.normal,function(){n(t["reveal-bar"]).find("a").attr("class","return-to-top")});break;default:n("html,body").animate({scrollTop:0},1e3)}})}}(jQuery),function(n){n.fn.fieldReset=function(t){var t=n.extend({"class":!1},t);return this.each(function(){var i=n(this),r=i.find("input[type=text]");r.each(function(){n(this).data({"default":n(this).val()});n(this).focus(function(){n(this).val()==n(this).data("default")&&(n(this).val(""),t["class"]&&n(this).removeClass(t["class"]))});n(this).blur(function(){n(this).val()==""&&(n(this).val(n(this).data("default")),t["class"]&&n(this).addClass(t["class"]))})})})}}(jQuery),function(n){n.fn.blinds=function(t){var i={hasTitle:!1,animationDuration:USOC.SPEED.fast,special:{}},t=n.extend(i,t);return this.each(function(i,r){var u=n(r),f=u.parent(),e=f.find(".rollover-overlay"),o=0,s=u.find(".title"),h=u.find(".detail"),l=u.outerHeight(),a=f.outerHeight(),v=s.outerHeight(),y=h.outerHeight(),c;t.special=t.special||!1;USOC.IE&&USOC.IE<9&&(c=n('<div class="blind-gradient"><\/div>').prependTo(n(r)));e.find("> *").each(function(){o+=n(this).outerHeight(!0)});e.css({paddingTop:(f.outerHeight()-o)/2});u.animate({bottom:0},USOC.SPEED.normal);f.hover(function(){e.stop(!1,!1).animate({opacity:USOC.IE&&USOC.IE<9?.8:1},USOC.SPEED.normal);u.stop(!1,!1).animate({opacity:0},USOC.SPEED.normal);return},function(){e.stop(!1,!1).animate({opacity:0},USOC.SPEED.normal);u.stop(!1,!1).animate({opacity:1},USOC.SPEED.normal);return})})}}(jQuery),function(n){n.fn.carousel=function(t){var i={animationDuration:USOC.SPEED.normal,orientation:"h",pagination:!1,visibleNodes:!1,autoscroll:!1,autoscrollTimeout:USOC.SPEED.normal*5,onNavigate:null},t=n.extend(i,t);return this.each(function(i,r){var nt=n(r),rt=t,o=nt,s,tt,ut,ft,et,l,f=o.find("ul:eq(0)")||{},p=o.find(".next")||{},w=o.find(".prev")||{},a=o.find(".status")||{},b=o.find(".captions li"),ct=f.width(),lt=f.height(),v=t.animationDuration,k=t.pagination,at=t.visibleNodes,st=t.autoscroll,ht=t.autoscrollTimeout,y=[],u=0,it=0,h=!1,e=[],d=0,c=0,ot=0,g;for(this.left=0,this.top=0,n.fn.carousel.goto=function(n){n<0||n>e.length-1||isNaN(n)||s({direction:"jump",duration:0,jumpTo:n})},n.fn.carousel.getPosition=function(){return u},tt=function(){nt.left=f.position().left;nt.top=f.position().top;h=u+1>it?"next":u-1<0?"prev":!1;h=="next"?p.addClass("inactive"):p.removeClass("inactive");h=="prev"?w.addClass("inactive"):w.removeClass("inactive")},ut=function(){a!={}&&a.find(".current").text(parseInt(u)+1)},ft=function(){n(".placeholder").fadeOut(t.animationDuration/2,function(){var i=n(this).prev(".captions").find("li:eq("+u+") span.photo-credit"),t=n(this).prev(".captions").find("li:eq("+u+") a.high-res");n(this).find("span.photo-credit").text(i.text());n(this).find("a.high-res").text(t.text()).attr("href",t.attr("href"))});b.filter(":visible").fadeOut(t.animationDuration/2,function(){n(this).addClass("hidden");b.eq(u).removeClass("hidden").fadeIn(t.animationDuration/2);n(".placeholder").fadeIn(t.animationDuration/2);n.fn.lox.resize()})},l=function(n){if(!k)return!1;n=="add"?y[u].obj.addClass("selected"):y[u].obj.removeClass("selected")},et=function(n){n=ht;window.setInterval(function(){u+1>it?s({direction:"jump",duration:v,jumpTo:0}):s({direction:"next",duration:v})},n)},s=function(n){var c=n.direction,o=n.duration,i=n.jumpTo,t=0,p=this,s,a,v,r;if(offset={},offset.top="0",offset.left="0",dimension="width",f.filter(":animated").length>0)return!1;s=e[u].obj.find("iframe");s.length>0&&s.remove();switch(c){case"next":if(t=h=="next"?30:e[u][dimension],offset.left="-="+t,h=="next")return f.animate(offset,USOC.SPEED.fast),offset.left=offset.left.replace("-","+"),offset.top=offset.top.replace("-","+"),f.animate(offset,USOC.SPEED.fast),!1;l("remove");f.animate(offset,o,function(){});u++;l("add");break;case"prev":if(t=h=="prev"?30:e[u-1][dimension],offset.left="+="+t,h=="prev")return f.animate(offset,USOC.SPEED.fast),offset.left=offset.left.replace("+","-"),offset.top=offset.top.replace("+","-"),f.animate(offset,USOC.SPEED.fast),!1;l("remove");u--;f.animate(offset,o,function(){});l("add");break;case"jump":if(i==u)return!1;for(k&&y[u].obj.removeClass("selected"),a=i>u?u:i,v=i>u?i:u,r=a;r<v;r++)t+=e[r].width;i<u&&(t="-"+t);f.animate({left:"-="+t},o,function(){});u=i;k&&y[u].obj.addClass("selected")}if(ut(),ft(),tt(),typeof rt.onNavigate=="function")rt.onNavigate(u,c)},k&&o.find(".pagination a").each(function(t){y.push({obj:n(this),index:t});n(this).click(function(n){s({direction:"jump",duration:v,jumpTo:t});n.preventDefault()})}),f.find("> li").each(function(t){e.push({obj:n(this),index:t,width:n(this).outerWidth(),height:n(this).outerHeight()})}),g=0;g<e.length;g++)ot+=e[g].width;f.width(ot);c=e[0].width;o.width(c);c=c!=0?c+="px":"auto";d=d!=0?d+="px":"auto";it=e.length-1;f.wrap('<div style="width: '+c+"; height: "+d+';  overflow: hidden; position: relative;" />');w.appendTo(f.parent());p.appendTo(f.parent());b.each(function(){n(this).addClass("hidden")});b.eq(0).removeClass("hidden");a!={}&&(a.find(".current").text(u+1),a.find(".total").text(e.length));st&&et();tt();p.click(function(n){s({direction:"next",duration:v});n.preventDefault()});w.click(function(n){s({direction:"prev",duration:v});n.preventDefault()})})}}(jQuery),function(n){n.fn.replaceSelect=function(t){var i=!1,t=n.extend({},t);return this.each(function(r,u){var f=n(u),h=f.outerWidth(),o=n('<div class="select-replace" id="'+f.attr("id")+'-replaced" rel="'+f.attr("id")+'" />'),c="",l=n('<a href="javascript:void(0)">'+f.find("option:selected").text()+"<\/a>").appendTo(o),e=n("<ul />").appendTo(o),s,a;f.after(o);o.css("width",h);e.css("width",h);f.find("option").each(function(){c+='<li><a href="javascript:void(0)" rel="'+n(this).val()+'">'+n(this).text()+"<\/a><\/li>"});f.hide();e.append(c);o.find("> a").click(function(n){if(e.filter(":animated").length>0)return!1;i?(i=!1,s()):(i=!0,a());n.preventDefault();n.stopPropagation()});e.find("a").click(function(t){t.preventDefault();o.find("> a").text(n(this).text());f.val(n(this).attr("rel"));s();f.trigger("change")});a=function(){var t=0;f.attr("data-dropdown-height")!=undefined?t=f.attr("data-dropdown-height"):e.find("li").each(function(){t+=n(this).outerHeight(!0)});f.attr("data-dropdown-scroll")!=undefined&&new Boolean(f.attr("data-dropdown-scroll")).valueOf()==!0&&e.css("overflow-y","scroll");e.animate({height:t,opacity:1},USOC.SPEED.fast);l.addClass("selected")};s=function(){e.animate({height:0,opacity:0},USOC.SPEED.fast);l.removeClass("selected")};n("body").click(function(){e.height()!=0&&s()});t.debug==!0&&(f.show(),f.css({position:"absolute",right:0,top:-40}),f.change(function(){alert("changed value")}))})}}(jQuery),function(n){n.fn.lox=function(t){var t=n.extend({selector:null,speed:500,type:"inline"},t),o=n(this),c=t.selector==null?n(o.attr("href")):n(t.selector),v=!1,s=!1,u=n("#lox").length>0?n("#lox"):n('<div id="lox" class="off-screen" />').appendTo("body"),f,y,i,l,e,p,a,r,h,w;return w=function(){e={w:c.outerWidth(),h:c.outerHeight()}},p=function(){n("#lox>.lox-content").length===0?(f=n('<div class="lox-overlay" />').appendTo(u),y=n('<div class="lox-content-wrapper" />').appendTo(u),i=n('<div class="lox-content" />').appendTo(u),l=n('<a href="#" class="lox-close" />').appendTo(i)):(f=n("#lox>.lox-overlay"),y=n("#lox>.lox-content-wrapper"),i=n("#lox>.lox-content"),l=n("#lox>.lox-content>.lox-close"));t.type=="ajax"?o.unbind("click").bind("click",function(u){o.find(".play").hide();o.find(".loading").show();n.ajax({url:t.url,success:function(u){i.empty();l=n('<a href="#" class="lox-close" />').appendTo(i);c=n(u).appendTo(i);t.onLoad&&t.onLoad();h();i.css("visibility","visible");n(window).unbind("resize").bind("resize",function(){if(!s&&v)return!1;h()});f.unbind("click").bind("click",function(){r()});l.unbind("click").bind("click",function(n){r();n.preventDefault()});n(document).unbind("keydown").bind("keydown",function(n){s&&v&&n.which==27&&r()});a()},complete:function(){},error:function(n,t,i){alert("Gallery could not be loaded: "+i+". Please try again later.")}});u.preventDefault()}):o.unbind("click").bind("click",function(u){c.appendTo(i);t.onLoad&&t.onLoad();h();i.css("visibility","visible");c.removeClass("off-screen");n(window).unbind("resize").bind("resize",function(){if(!s&&v)return!1;h()});f.unbind("click").bind("click",function(){r()});l.unbind("click").bind("click",function(n){r();n.preventDefault()});o.unbind("click").bind("click",function(n){a();n.preventDefault()});n(document).unbind("keydown").bind("keydown",function(n){s&&v&&n.which==27&&r()});a();u.preventDefault()})},r=function(){var n=i.find("iframe");n.length>0&&n.remove();f.animate({opacity:0},t.speed);i.animate({opacity:0},t.speed,function(){u.addClass("off-screen");t.onHide&&t.onHide()});s=!1},a=function(){u.removeClass("off-screen");f.css({width:n("body").hasClass("mobile")?n("body").width():n(window).outerWidth(),height:n("body").hasClass("mobile")?n("body").height():n(document).outerHeight()}).animate({opacity:USOC.TRANSPARENCY},t.speed);i.animate({opacity:1},t.speed,function(){t.onShow&&t.onShow()});s=!0},h=function(){w();f.css({width:n("body").hasClass("mobile")?n("body").width():n(window).outerWidth(),height:n("body").hasClass("mobile")?n("body").height():n(document).outerHeight()});n(window).height()<e.h?u.css("position","absolute"):u.css("position","fixed");i.animate({width:e.w,height:e.h,left:((n("body").hasClass("mobile")?n("body").width():n(window).width())-e.w)/2,top:n(window).height()>e.h?(n(window).height()-e.h)/2:n(document).scrollTop()})},n.fn.lox.show=function(){a()},n.fn.lox.hide=function(){r()},n.fn.lox.resize=function(){h()},p(),this}}(jQuery),function(n){n.fn.validator=function(){var t=n.extend({},t);return this.each(function(){var t=n(this),f,i={text:t.find("input[type=text].required, input[type=password].required, textarea.required"),select:t.find("select.required"),checkbox:t.find("input[type=checkbox].required"),radio:t.find("input[type=radio].required")},e,r,u;for(name in i)i[name].each(function(){name=="radio"||name=="checkbox"?t.find(".label[group="+n(this).attr("name")+"] .required-mark").length==0&&t.find(".label[group="+n(this).attr("name")+"]").prepend(n('<span class="required-mark">*<\/span>')):(n(this).parent().prepend(n('<span class="required-mark">*<\/span>')),n(this).attr("original",n(this).val()))});t.find("input[type=image]").bind("click",function(){return e()});r=function(i,r){var u;switch(r){case"text":i.addClass("error");break;case"select":u=i.attr("err")==undefined?"Please select one":i.attr("err");i.next("span.error").length==0&&n('<span class="error">'+u+"<\/span>").insertAfter(i).fadeIn(300);break;case"checkbox":u=i.attr("err")==undefined?"Please check off at least one box":i.attr("err");t.find(".label[group="+i.attr("name")+"]").siblings("span.error").length==0&&n('<span class="error">'+u+"<\/span>").insertAfter(t.find(".label[group="+i.attr("name")+"]")).fadeIn(300);break;case"radio":u=i.attr("err")==undefined?"Please select one":i.attr("err");t.find(".label[group="+i.attr("name")+"]").siblings("span.error").length==0&&n('<span class="error">'+u+"<\/span>").insertAfter(t.find(".label[group="+i.attr("name")+"]")).fadeIn(300)}};u=function(i,r){switch(r){case"text":case"select":i.removeClass("error");break;case"checkbox":case"radio":t.find(".label[group="+i.attr("name")+"]").siblings("span.error").fadeOut(300,function(){n(this).remove()})}};e=function(){return f=0,i.text.each(function(){var t=n(this);t.val()==t.attr("original")||t.hasClass("email")&&!/.+@.+\..+/.test(t.val())||t.hasClass("confirm")&&t.val()!=i.text.filter(t.attr("with")).val()?(f++,r(t,"text")):u(t,"text")}),i.select.each(function(){var t=n(this);n(this).val()==""?(f++,r(t,"select")):u(t,"select")}),i.checkbox.each(function(){var t=n(this);name=t.attr("name");filter=i.checkbox.filter("[name="+name+"]:checked");filter.length==0?r(t,"checkbox"):u(t,"checkbox")}),i.radio.each(function(){var t=n(this);name=t.attr("name");filter=i.radio.filter("[name="+name+"]:checked");filter.length==0?r(t,"radio"):u(t,"radio")}),f==0}})}}(jQuery)}(jQuery);getCookie=function(n){var t;return(t=new RegExp("(?:^|; )"+encodeURIComponent(n)+"=([^;]*)").exec(document.cookie))?t[1]:null};setCookie=function(n,t,i){var r=new Date,u;r.setDate(r.getDate()+i);u=escape(t)+(i==null?"":"; expires="+r.toUTCString());document.cookie=[n,"=",u].join("")}