window.log=function(){log.history=log.history||[];log.history.push(arguments);if(this.console){arguments.callee=arguments.callee.caller;var a=[].slice.call(arguments);(typeof console.log==="object"?log.apply.call(console.log,console,a):console.log.apply(console,a))}};
(function(b){function c(){}for(var d="assert,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,timeStamp,profile,profileEnd,time,timeEnd,trace,warn".split(","),a;a=d.pop();){b[a]=b[a]||c}})((function(){try
{console.log();return window.console;}catch(err){return window.console={};}})());

var wrapAroundSpeedSetting = 0;
// Slideshow scripts
//if ($('.royalSlider').length>0){
//    jQuery.easing.jswing=jQuery.easing.swing;
//    jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(e,a,c,b,d){return jQuery.easing[jQuery.easing.def](e,a,c,b,d)},easeInQuad:function(e,a,c,b,d){return b*(a/=d)*a+c},easeOutQuad:function(e,a,c,b,d){return-b*(a/=d)*(a-2)+c},easeInOutQuad:function(e,a,c,b,d){if((a/=d/2)<1)return b/2*a*a+c;return-b/2*(--a*(a-2)-1)+c},easeInCubic:function(e,a,c,b,d){return b*(a/=d)*a*a+c},easeOutCubic:function(e,a,c,b,d){return b*((a=a/d-1)*a*a+1)+c},easeInOutCubic:function(e,a,c,b,d){if((a/=d/2)<1)return b/
//    2*a*a*a+c;return b/2*((a-=2)*a*a+2)+c},easeInQuart:function(e,a,c,b,d){return b*(a/=d)*a*a*a+c},easeOutQuart:function(e,a,c,b,d){return-b*((a=a/d-1)*a*a*a-1)+c},easeInOutQuart:function(e,a,c,b,d){if((a/=d/2)<1)return b/2*a*a*a*a+c;return-b/2*((a-=2)*a*a*a-2)+c},easeInQuint:function(e,a,c,b,d){return b*(a/=d)*a*a*a*a+c},easeOutQuint:function(e,a,c,b,d){return b*((a=a/d-1)*a*a*a*a+1)+c},easeInOutQuint:function(e,a,c,b,d){if((a/=d/2)<1)return b/2*a*a*a*a*a+c;return b/2*((a-=2)*a*a*a*a+2)+c},easeInSine:function(e,
//    a,c,b,d){return-b*Math.cos(a/d*(Math.PI/2))+b+c},easeOutSine:function(e,a,c,b,d){return b*Math.sin(a/d*(Math.PI/2))+c},easeInOutSine:function(e,a,c,b,d){return-b/2*(Math.cos(Math.PI*a/d)-1)+c},easeInExpo:function(e,a,c,b,d){return a==0?c:b*Math.pow(2,10*(a/d-1))+c},easeOutExpo:function(e,a,c,b,d){return a==d?c+b:b*(-Math.pow(2,-10*a/d)+1)+c},easeInOutExpo:function(e,a,c,b,d){if(a==0)return c;if(a==d)return c+b;if((a/=d/2)<1)return b/2*Math.pow(2,10*(a-1))+c;return b/2*(-Math.pow(2,-10*--a)+2)+c},
//    easeInCirc:function(e,a,c,b,d){return-b*(Math.sqrt(1-(a/=d)*a)-1)+c},easeOutCirc:function(e,a,c,b,d){return b*Math.sqrt(1-(a=a/d-1)*a)+c},easeInOutCirc:function(e,a,c,b,d){if((a/=d/2)<1)return-b/2*(Math.sqrt(1-a*a)-1)+c;return b/2*(Math.sqrt(1-(a-=2)*a)+1)+c},easeInElastic:function(e,a,c,b,d){e=1.70158;var f=0,g=b;if(a==0)return c;if((a/=d)==1)return c+b;f||(f=d*0.3);if(g<Math.abs(b)){g=b;e=f/4}else e=f/(2*Math.PI)*Math.asin(b/g);return-(g*Math.pow(2,10*(a-=1))*Math.sin((a*d-e)*2*Math.PI/f))+c},easeOutElastic:function(e,
//    a,c,b,d){e=1.70158;var f=0,g=b;if(a==0)return c;if((a/=d)==1)return c+b;f||(f=d*0.3);if(g<Math.abs(b)){g=b;e=f/4}else e=f/(2*Math.PI)*Math.asin(b/g);return g*Math.pow(2,-10*a)*Math.sin((a*d-e)*2*Math.PI/f)+b+c},easeInOutElastic:function(e,a,c,b,d){e=1.70158;var f=0,g=b;if(a==0)return c;if((a/=d/2)==2)return c+b;f||(f=d*0.3*1.5);if(g<Math.abs(b)){g=b;e=f/4}else e=f/(2*Math.PI)*Math.asin(b/g);if(a<1)return-0.5*g*Math.pow(2,10*(a-=1))*Math.sin((a*d-e)*2*Math.PI/f)+c;return g*Math.pow(2,-10*(a-=1))*Math.sin((a*
//    d-e)*2*Math.PI/f)*0.5+b+c},easeInBack:function(e,a,c,b,d,f){if(f==undefined)f=1.70158;return b*(a/=d)*a*((f+1)*a-f)+c},easeOutBack:function(e,a,c,b,d,f){if(f==undefined)f=1.70158;return b*((a=a/d-1)*a*((f+1)*a+f)+1)+c},easeInOutBack:function(e,a,c,b,d,f){if(f==undefined)f=1.70158;if((a/=d/2)<1)return b/2*a*a*(((f*=1.525)+1)*a-f)+c;return b/2*((a-=2)*a*(((f*=1.525)+1)*a+f)+2)+c},easeInBounce:function(e,a,c,b,d){return b-jQuery.easing.easeOutBounce(e,d-a,0,b,d)+c},easeOutBounce:function(e,a,c,b,d){return(a/=
//    d)<1/2.75?b*7.5625*a*a+c:a<2/2.75?b*(7.5625*(a-=1.5/2.75)*a+0.75)+c:a<2.5/2.75?b*(7.5625*(a-=2.25/2.75)*a+0.9375)+c:b*(7.5625*(a-=2.625/2.75)*a+0.984375)+c},easeInOutBounce:function(e,a,c,b,d){if(a<d/2)return jQuery.easing.easeInBounce(e,a*2,0,b,d)*0.5+c;return jQuery.easing.easeOutBounce(e,a*2-d,0,b,d)*0.5+b*0.5+c}});
//    function RoyalSlider(a,b){if("ontouchstart"in window){this.hasTouch=true}else{this.hasTouch=false}this.slider=$(a);var c=this;this.defaults={directionNavEnabled:true,directionNavAutoHide:false,slideTransitionSpeed:400,slideTransitionEasing:"easeInOutSine",captionAnimationEnabled:true,captionShowEffects:["fade","moveleft"],captionMoveOffset:20,captionShowSpeed:400,captionShowEasing:"easeOutCubic",captionShowDelay:200,controlNavEnabled:true,controlNavThumbs:false,slideshowEnabled:false,slideshowDelay:5000,slideshowPauseOnHover:true,slideshowAutoStart:true,welcomeScreenEnabled:true,welcomeScreenShowSpeed:500,minSlideOffset:20,hideArrowOnLastSlide:false,beforeSlideChange:function(){},afterSlideChange:function(){},loadingComplete:function(){}};this.settings=$.extend({},this.defaults,b);if(this.hasTouch){this.settings.directionNavAutoHide=false;this.settings.hideArrowOnLastSlide=true}this.isSlideshowRunning=false;this._az=false;this._by=this.slider.find(".royalSlidesContainer");this._cx=this._by.wrap('<div class="royalWrapper"/>').parent();this.slides=this._by.find(".royalSlide");this.slider.css("overflow","visible");this.sliderWidth=0;this.sliderHeight=0;this.slideshowTimer='';this.numSlides=this.slides.length;this.currentSlideId=0;this.lastSlideId=-1;this.isAnimating=true;this._dw=0;this._ev=0;this._fu=[];this._gt=[];this._hs=0;this._ir=0;this._jq=0;this._kp=0;this._lo=false;this.wasSlideshowPlaying=false;this._az1=false;if(this.settings.slideshowEnabled){if(this.settings.slideshowDelay>0){if(this.settings.slideshowPauseOnHover){this.slider.hover(function(){c._az1=true;c.stopSlideshow(true)},function(){c._az1=false;c.resumeSlideshow(true)})}}}var d="";if($.browser.msie){if(parseInt($.browser.version)==7){this.isIE7=true;this._by.css("cursor","move")}else{this.isIE7=false}}if($.browser.opera){_by1="move";_cx1="move"}else{if($.browser.mozilla){_by1="-moz-grab";_cx1="-moz-grabbing"}else{_by1="url(img/cursors/grab.cur), move";_cx1="url(img/cursors/grabbing.cur), move"}_by1=$.browser.mozilla?"-moz-grab":"url(img/cursors/grab.cur), move";_cx1=$.browser.mozilla?"-moz-grabbing":"url(img/cursors/grabbing.cur), move"}this._dw1();if(this.settings.controlNavEnabled){if(!c.settings.controlNavThumbs){var e=$('<div class="royalControlNavOverflow"><div class="royalControlNavContainer"><div class="royalControlNavCenterer"></div></div></div>')}else{var e=$('<div class="royalControlNavOverflow royalThumbs"><div class="royalControlNavContainer"><div class="royalControlNavCenterer"></div></div></div>')}var f=e.find('.royalControlNavCenterer');var g=0;this.slides.each(function(){if(c.settings.controlNavThumbs){f.append("<a href='#' class='royalThumb' style='background-image:url("+$(this).attr("data-thumb")+");'/>")}else{f.append('<a href="#"/>')}g++});this.navItems=f.children();this.navItems.eq(0).addClass("current");this.navItems.eq(this.navItems.length-1).addClass("last");this._cx.after(e)}if(this.settings.captionAnimationEnabled){this._cx.find(".royalCaption").css("display","none")}if(this.settings.directionNavEnabled){this._cx.after("<a href='#' class='arrow left'/>");this._cx.after("<a href='#' class='arrow right'/>");this.arrowLeft=this.slider.find("a.arrow.left");this.arrowRight=this.slider.find("a.arrow.right");if(this.arrowLeft.length<1||this.arrowRight.length<1){this.settings.directionNavEnabled=false}else if(this.settings.directionNavAutoHide){this.arrowLeft.hide();this.arrowRight.hide();this.slider.bind("mousemove.arrowshover",function(){c.arrowLeft.fadeIn("fast");c.arrowRight.fadeIn("fast");c.slider.unbind("mousemove.arrowshover")});this.slider.hover(function(){c.arrowLeft.fadeIn("fast");c.arrowRight.fadeIn("fast")},function(){c.arrowLeft.fadeOut("fast");c.arrowRight.fadeOut("fast")})}if(this.settings.hideArrowOnLastSlide){this.arrowLeft.css("visibility","hidden")}}this.resizeTimer=null;$(window).bind('resize',function(){if(this.resizeTimer)clearTimeout(resizeTimer);this.resizeTimer=setTimeout(function(){c._gt1()},100)});this._gt1();if(this.settings.welcomeScreenEnabled){var h=this.slides.eq(0).css("background-image");if(h!=""&&h!="none"){var i=new Image();$(i).load(function(){c.settings.loadingComplete.call(c);c.slider.find(".royalLoadingScreen").fadeOut(c.settings.welcomeScreenShowSpeed,function(){$(this).remove()});setTimeout(function(){c._hs1()},c.settings.welcomeScreenShowSpeed+100)});h=h.substring(4,h.length-1);if(h.charAt(0)=='"'||h.charAt(0)=="'"){h=h.substring(1,h.length-1)}i.src=h}else{var j=this.slider.find(".royalLoadingScreen");if(j){c.settings.loadingComplete.call(c);j.fadeOut(c.settings.welcomeScreenShowSpeed,function(){$(this).remove()});setTimeout(function(){c._hs1()},c.settings.welcomeScreenShowSpeed+100)}else{setTimeout(function(){c._hs1();c.slider.find(".royalLoadingScreen").remove();c.settings.loadingComplete.call(c)},100)}}}else{setTimeout(function(){c._hs1();c.slider.find(".royalLoadingScreen").remove();c.settings.loadingComplete.call(c)},100)}}RoyalSlider.prototype={goTo:function(a){if(!this.isAnimating){this.isAnimating=true;var b=this;this._by.unbind("mousedown").unbind("touchstart").unbind("MozTouchDown");if(this.settings.controlNavEnabled){this.navItems.unbind("click");this.navItems.eq(this.currentSlideId).removeClass('current');this.navItems.eq(a).addClass("current")}this.lastSlideId=this.currentSlideId;this.currentSlideId=a;if(this.settings.directionNavEnabled){if(this.settings.hideArrowOnLastSlide){if(this.lastSlideId==0){this.arrowLeft.css("visibility","visible")}else if(this.lastSlideId==this.numSlides-1){this.arrowRight.css("visibility","visible")}if(this.currentSlideId==0){this.arrowLeft.css("visibility","hidden")}else if(this.currentSlideId==this.numSlides-1){this.arrowRight.css("visibility","hidden")}this.arrowRight.unbind("click");this.arrowLeft.unbind("click")}}this.settings.beforeSlideChange.call(this);this.stopSlideshow();this._by.animate({left:-this.currentSlideId*this.sliderWidth},this.settings.slideTransitionSpeed,this.settings.slideTransitionEasing,function(){b._ir1()})}},prev:function(){if(this.currentSlideId<=0){this.goTo(this.numSlides-1)}else{this._jq1()}},next:function(){if(this.currentSlideId>=this.numSlides-1){this.goTo(0)}else{this._kp1()}},resumeSlideshow:function(a){if(this.settings.slideshowEnabled){if(this.slideshowTimer==''){if(a){if(!this._az){return}}var b=this;this.slideshowTimer=setInterval(function(){b.next()},this.settings.slideshowDelay);this.isSlideshowRunning=true}}},stopSlideshow:function(a){if(this.settings.slideshowEnabled){if(a){this._az=this.isSlideshowRunning}else{this._az=false;this.isSlideshowRunning=false}clearInterval(this.slideshowTimer);this.slideshowTimer=''}},_hs1:function(){this._ir1();if(this.settings.slideshowEnabled&&!this.settings.slideshowAutoStart){this.stopSlideshow()}},_dw1:function(){if(!this.isIE7){this._by.css("cursor",_by1)}},_lo1:function(){if(!this.isIE7){this._by.css("cursor",_cx1)}},_kp1:function(){if(this.currentSlideId<this.numSlides-1){this.goTo(this.currentSlideId+1)}else{this.goTo(this.currentSlideId)}},_jq1:function(){if(this.currentSlideId>0){this.goTo(this.currentSlideId-1)}else{this.goTo(this.currentSlideId)}},_gt1:function(){var a=parseInt(this._cx.width());var b=parseInt(this._cx.height());if(a!=this.sliderWidth||b!=this.sliderHeight){this.sliderWidth=a;this.slides.each(function(){$(this).css({height:b+"px",width:a+"px"})});this._by.css({"left":-this.currentSlideId*this.sliderWidth,width:this.sliderWidth*this.numSlides})}},mn1:function(e){this.goTo($(e.currentTarget).index())},_az2:function(e){if(!this._lo){var a;if(this.hasTouch){var b=e.originalEvent.touches;if(b&&b.length>0){a=b[0]}else{return false}}else{a=e;e.preventDefault()}if(this.slideshowTimer!=''){this.wasSlideshowPlaying=true;this.stopSlideshow()}else{this.wasSlideshowPlaying=false}this._lo1();this._lo=true;var c=this;$(document).bind("mousemove touchmove MozTouchMove",function(e){c._by2(e)});$(document).bind("mouseup touchend MozTouchRelease",function(e){c._cx2(e)});this._hs=parseInt(this._by.css("left"));this._ir=a.clientX;this._jq=a.clientY;this._kp=parseInt(this._by.css("left"))}return false},_by2:function(e){var a;if(this.hasTouch){var b=e.originalEvent.touches;if(b.length>1){return false}a=b[0];if(Math.abs(a.clientY-this._jq)+10>Math.abs(a.clientX-this._ir)){return false}e.preventDefault()}else{a=e;e.preventDefault()}this._ev=this._dw;var c=a.clientX-this._ir;if(this._ev!=c){this._dw=c}if(c!=0){if(this.currentSlideId==0){if(c>0){c=Math.sqrt(c)*5}}else if(this.currentSlideId==(this.numSlides-1)){if(c<0){c=-Math.sqrt(-c)*5}}this._by.css("left",this._hs+c)}return false},_cx2:function(e){if(this.wasSlideshowPlaying){this.resumeSlideshow()}if(this._lo){this._lo=false;this._dw1();this.endPos=parseInt(this._by.css("left"));this.isdrag=false;$(document).unbind("mousemove").unbind("touchmove").unbind("MozTouchMove").unbind("mouseup").unbind("touchend").unbind("MozTouchRelease");if(this.endPos==this._kp){return}if(this._kp-this.settings.minSlideOffset>this.endPos){if(this._ev<this._dw){this.goTo(this.currentSlideId);return false}this._kp1()}else if(this._kp+this.settings.minSlideOffset<this.endPos){if(this._ev>this._dw){this.goTo(this.currentSlideId);return false}this._jq1()}else{this.goTo(this.currentSlideId)}}return false},_ir1:function(){var a=this;this.resumeSlideshow();if(this.settings.controlNavEnabled){this.navItems.bind("click",function(e){e.preventDefault();a.mn1(e)})}this._by.bind("mousedown touchstart MozTouchDown",function(e){a._az2(e)});if(this.settings.directionNavEnabled){this.arrowRight.bind('click',function(e){e.preventDefault();a.next()});this.arrowLeft.bind('click',function(e){e.preventDefault();a.prev()})}if(this.settings.captionAnimationEnabled&&this.lastSlideId!=this.currentSlideId){if(this.lastSlideId!=-1){this.slides.eq(this.lastSlideId).find(".royalCaption").css("display","none")}setTimeout(function(){a._dw2(this.currentSlideId)},10)}this.isAnimating=false;this.settings.afterSlideChange.call(this)},_dw2:function(f){var g=this.slides.eq(this.currentSlideId).find(".royalCaption");if(g.length){g.css("display","block");var h=this;var j;var l=g.children();var m;var n;var o;var p;var r;var s;var t;var u;var v;var w;var x;var y;if(this._fu.length>0){for(var a=this._fu.length-1;a>-1;a--){clearTimeout(this._fu.splice(a,1))}}if(this._gt.length>0){var z;for(var k=this._gt.length-1;k>-1;k--){z=this._gt[k];if(z!=undefined){z.captionItem.css(z.css)}this._gt.splice(k,1)}}for(var i=0;i<l.length;i++){j=$(l[i]);p={};m=false;n=false;r="";if(j.attr("data-show-effect")==undefined){s=this.settings.captionShowEffects}else{s=j.attr("data-show-effect").split(" ")}for(var q=0;q<s.length;q++){if(m&&n){break}o=s[q].toLowerCase();if(!m&&o=="fade"){m=true;p['opacity']=1}else if(n){break}else if(o=="movetop"){r="margin-top"}else if(o=="moveleft"){r="margin-left"}else if(o=="movebottom"){r="margin-bottom"}else if(o=="moveright"){r="margin-right"}if(r!=""){p['moveProp']=r;p['moveStartPos']=parseInt(j.css(r));n=true}}u=parseInt(j.attr("data-move-offset"));if(isNaN(u)){u=this.settings.captionMoveOffset}v=parseInt(j.attr("data-delay"));if(isNaN(v)){v=h.settings.captionShowDelay*i+10}w=parseInt(j.attr("data-speed"));if(isNaN(w)){w=h.settings.captionShowSpeed}x=j.attr("data-easing");if(x==undefined){x=h.settings.captionShowEasing}t={};if(n){y=p.moveProp;if(y=="margin-right"){y="margin-left";t[y]=p.moveStartPos+u+"px"}else if(y=="margin-bottom"){y="margin-top";t[y]=p.moveStartPos+u+"px"}else{t[y]=p.moveStartPos-u+"px"}}if(m){t.opacity=0}j.hide().css(t);if(n){t[y]=p.moveStartPos+"px"}if(m){t.opacity=1}this._gt.push({captionItem:j,css:t});this._fu.push(setTimeout((function(a,b,c,d,e){return function(){delete h._gt[e];a.show().animate(b,c,d)}})(j,t,w,x,i),v))}}}};
//}
try {
    var index = window.location.pathname.lastIndexOf("/");
    var filename = window.location.pathname.substr(index+1);
    if (filename != "blog.aspx") {
        if ($('.royalSlider').length) { jQuery.easing.jswing = jQuery.easing.swing; jQuery.extend(jQuery.easing, { def: "easeOutQuad", swing: function (e, a, c, b, d) { return jQuery.easing[jQuery.easing.def](e, a, c, b, d) }, easeInQuad: function (e, a, c, b, d) { return b * (a /= d) * a + c }, easeOutQuad: function (e, a, c, b, d) { return -b * (a /= d) * (a - 2) + c }, easeInOutQuad: function (e, a, c, b, d) { if ((a /= d / 2) < 1) return b / 2 * a * a + c; return -b / 2 * (--a * (a - 2) - 1) + c }, easeInCubic: function (e, a, c, b, d) { return b * (a /= d) * a * a + c }, easeOutCubic: function (e, a, c, b, d) { return b * ((a = a / d - 1) * a * a + 1) + c }, easeInOutCubic: function (e, a, c, b, d) { if ((a /= d / 2) < 1) return b / 2 * a * a * a + c; return b / 2 * ((a -= 2) * a * a + 2) + c }, easeInQuart: function (e, a, c, b, d) { return b * (a /= d) * a * a * a + c }, easeOutQuart: function (e, a, c, b, d) { return -b * ((a = a / d - 1) * a * a * a - 1) + c }, easeInOutQuart: function (e, a, c, b, d) { if ((a /= d / 2) < 1) return b / 2 * a * a * a * a + c; return -b / 2 * ((a -= 2) * a * a * a - 2) + c }, easeInQuint: function (e, a, c, b, d) { return b * (a /= d) * a * a * a * a + c }, easeOutQuint: function (e, a, c, b, d) { return b * ((a = a / d - 1) * a * a * a * a + 1) + c }, easeInOutQuint: function (e, a, c, b, d) { if ((a /= d / 2) < 1) return b / 2 * a * a * a * a * a + c; return b / 2 * ((a -= 2) * a * a * a * a + 2) + c }, easeInSine: function (e, a, c, b, d) { return -b * Math.cos(a / d * (Math.PI / 2)) + b + c }, easeOutSine: function (e, a, c, b, d) { return b * Math.sin(a / d * (Math.PI / 2)) + c }, easeInOutSine: function (e, a, c, b, d) { return -b / 2 * (Math.cos(Math.PI * a / d) - 1) + c }, easeInExpo: function (e, a, c, b, d) { return a == 0 ? c : b * Math.pow(2, 10 * (a / d - 1)) + c }, easeOutExpo: function (e, a, c, b, d) { return a == d ? c + b : b * (-Math.pow(2, -10 * a / d) + 1) + c }, easeInOutExpo: function (e, a, c, b, d) { if (a == 0) return c; if (a == d) return c + b; if ((a /= d / 2) < 1) return b / 2 * Math.pow(2, 10 * (a - 1)) + c; return b / 2 * (-Math.pow(2, -10 * --a) + 2) + c }, easeInCirc: function (e, a, c, b, d) { return -b * (Math.sqrt(1 - (a /= d) * a) - 1) + c }, easeOutCirc: function (e, a, c, b, d) { return b * Math.sqrt(1 - (a = a / d - 1) * a) + c }, easeInOutCirc: function (e, a, c, b, d) { if ((a /= d / 2) < 1) return -b / 2 * (Math.sqrt(1 - a * a) - 1) + c; return b / 2 * (Math.sqrt(1 - (a -= 2) * a) + 1) + c }, easeInElastic: function (e, a, c, b, d) { e = 1.70158; var f = 0, g = b; if (a == 0) return c; if ((a /= d) == 1) return c + b; f || (f = d * 0.3); if (g < Math.abs(b)) { g = b; e = f / 4 } else e = f / (2 * Math.PI) * Math.asin(b / g); return -(g * Math.pow(2, 10 * (a -= 1)) * Math.sin((a * d - e) * 2 * Math.PI / f)) + c }, easeOutElastic: function (e, a, c, b, d) { e = 1.70158; var f = 0, g = b; if (a == 0) return c; if ((a /= d) == 1) return c + b; f || (f = d * 0.3); if (g < Math.abs(b)) { g = b; e = f / 4 } else e = f / (2 * Math.PI) * Math.asin(b / g); return g * Math.pow(2, -10 * a) * Math.sin((a * d - e) * 2 * Math.PI / f) + b + c }, easeInOutElastic: function (e, a, c, b, d) { e = 1.70158; var f = 0, g = b; if (a == 0) return c; if ((a /= d / 2) == 2) return c + b; f || (f = d * 0.3 * 1.5); if (g < Math.abs(b)) { g = b; e = f / 4 } else e = f / (2 * Math.PI) * Math.asin(b / g); if (a < 1) return -0.5 * g * Math.pow(2, 10 * (a -= 1)) * Math.sin((a * d - e) * 2 * Math.PI / f) + c; return g * Math.pow(2, -10 * (a -= 1)) * Math.sin((a * d - e) * 2 * Math.PI / f) * 0.5 + b + c }, easeInBack: function (e, a, c, b, d, f) { if (f == undefined) f = 1.70158; return b * (a /= d) * a * ((f + 1) * a - f) + c }, easeOutBack: function (e, a, c, b, d, f) { if (f == undefined) f = 1.70158; return b * ((a = a / d - 1) * a * ((f + 1) * a + f) + 1) + c }, easeInOutBack: function (e, a, c, b, d, f) { if (f == undefined) f = 1.70158; if ((a /= d / 2) < 1) return b / 2 * a * a * (((f *= 1.525) + 1) * a - f) + c; return b / 2 * ((a -= 2) * a * (((f *= 1.525) + 1) * a + f) + 2) + c }, easeInBounce: function (e, a, c, b, d) { return b - jQuery.easing.easeOutBounce(e, d - a, 0, b, d) + c }, easeOutBounce: function (e, a, c, b, d) { return (a /= d) < 1 / 2.75 ? b * 7.5625 * a * a + c : a < 2 / 2.75 ? b * (7.5625 * (a -= 1.5 / 2.75) * a + 0.75) + c : a < 2.5 / 2.75 ? b * (7.5625 * (a -= 2.25 / 2.75) * a + 0.9375) + c : b * (7.5625 * (a -= 2.625 / 2.75) * a + 0.984375) + c }, easeInOutBounce: function (e, a, c, b, d) { if (a < d / 2) return jQuery.easing.easeInBounce(e, a * 2, 0, b, d) * 0.5 + c; return jQuery.easing.easeOutBounce(e, a * 2 - d, 0, b, d) * 0.5 + b * 0.5 + c } }); function RoyalSlider(a, b) { if ("ontouchstart" in window) { this.hasTouch = true } else { this.hasTouch = false } this.slider = $(a); var c = this; this.defaults = { directionNavEnabled: true, directionNavAutoHide: false, slideTransitionSpeed: 400, slideTransitionEasing: "easeInOutSine", captionAnimationEnabled: true, captionShowEffects: ["fade", "moveleft"], captionMoveOffset: 20, captionShowSpeed: 400, captionShowEasing: "easeOutCubic", captionShowDelay: 200, controlNavEnabled: true, controlNavThumbs: false, slideshowEnabled: false, slideshowDelay: 5000, slideshowPauseOnHover: true, slideshowAutoStart: true, welcomeScreenEnabled: true, welcomeScreenShowSpeed: 500, minSlideOffset: 20, hideArrowOnLastSlide: false, beforeSlideChange: function () { }, afterSlideChange: function () { }, loadingComplete: function () { } }; this.settings = $.extend({}, this.defaults, b); if (this.hasTouch) { this.settings.directionNavAutoHide = false; this.settings.hideArrowOnLastSlide = true } this.isSlideshowRunning = false; this._az = false; this._by = this.slider.find(".royalSlidesContainer"); this._cx = this._by.wrap('<div class="royalWrapper"/>').parent(); this.slides = this._by.find(".royalSlide"); this.slider.css("overflow", "visible"); this.sliderWidth = 0; this.sliderHeight = 0; this.slideshowTimer = ''; this.numSlides = this.slides.length; this.currentSlideId = 0; this.lastSlideId = -1; this.isAnimating = true; this._dw = 0; this._ev = 0; this._fu = []; this._gt = []; this._hs = 0; this._ir = 0; this._jq = 0; this._kp = 0; this._lo = false; this.wasSlideshowPlaying = false; this._az1 = false; if (this.settings.slideshowEnabled) { if (this.settings.slideshowDelay > 0) { if (this.settings.slideshowPauseOnHover) { this.slider.hover(function () { c._az1 = true; c.stopSlideshow(true) }, function () { c._az1 = false; c.resumeSlideshow(true) }) } } } var d = ""; if ($.browser.msie) { if (parseInt($.browser.version) == 7) { this.isIE7 = true; this._by.css("cursor", "move") } else { this.isIE7 = false } } if ($.browser.opera) { _by1 = "move"; _cx1 = "move" } else { if ($.browser.mozilla) { _by1 = "-moz-grab"; _cx1 = "-moz-grabbing" } else { _by1 = "url(img/cursors/grab.cur), move"; _cx1 = "url(img/cursors/grabbing.cur), move" } _by1 = $.browser.mozilla ? "-moz-grab" : "url(img/cursors/grab.cur), move"; _cx1 = $.browser.mozilla ? "-moz-grabbing" : "url(img/cursors/grabbing.cur), move" } this._dw1(); if (this.settings.controlNavEnabled) { if (!c.settings.controlNavThumbs) { var e = $('<div class="royalControlNavOverflow"><div class="royalControlNavContainer"><div class="royalControlNavCenterer"></div></div></div>') } else { var e = $('<div class="royalControlNavOverflow royalThumbs"><div class="royalControlNavContainer"><div class="royalControlNavCenterer"></div></div></div>') } var f = e.find('.royalControlNavCenterer'); var g = 0; this.slides.each(function () { if (c.settings.controlNavThumbs) { f.append("<a href='#' class='royalThumb' style='background-image:url(" + $(this).attr("data-thumb") + ");'/>") } else { f.append('<a href="#"/>') } g++ }); this.navItems = f.children(); this.navItems.eq(0).addClass("current"); this.navItems.eq(this.navItems.length - 1).addClass("last"); this._cx.after(e) } if (this.settings.captionAnimationEnabled) { this._cx.find(".royalCaption").css("display", "none") } if (this.settings.directionNavEnabled) { this._cx.after("<a href='#' class='arrow left'/>"); this._cx.after("<a href='#' class='arrow right'/>"); this.arrowLeft = this.slider.find("a.arrow.left"); this.arrowRight = this.slider.find("a.arrow.right"); if (this.arrowLeft.length < 1 || this.arrowRight.length < 1) { this.settings.directionNavEnabled = false } else if (this.settings.directionNavAutoHide) { this.arrowLeft.hide(); this.arrowRight.hide(); this.slider.bind("mousemove.arrowshover", function () { c.arrowLeft.fadeIn("fast"); c.arrowRight.fadeIn("fast"); c.slider.unbind("mousemove.arrowshover") }); this.slider.hover(function () { c.arrowLeft.fadeIn("fast"); c.arrowRight.fadeIn("fast") }, function () { c.arrowLeft.fadeOut("fast"); c.arrowRight.fadeOut("fast") }) } if (this.settings.hideArrowOnLastSlide) { this.arrowLeft.css("visibility", "hidden") } } this.resizeTimer = null; $(window).bind('resize', function () { if (this.resizeTimer) clearTimeout(resizeTimer); this.resizeTimer = setTimeout(function () { c._gt1() }, 100) }); this._gt1(); if (this.settings.welcomeScreenEnabled) { var h = this.slides.eq(0).css("background-image"); if (h != "" && h != "none") { var i = new Image(); $(i).load(function () { c.settings.loadingComplete.call(c); c.slider.find(".royalLoadingScreen").fadeOut(c.settings.welcomeScreenShowSpeed, function () { $(this).remove() }); setTimeout(function () { c._hs1() }, c.settings.welcomeScreenShowSpeed + 100) }); h = h.substring(4, h.length - 1); if (h.charAt(0) == '"' || h.charAt(0) == "'") { h = h.substring(1, h.length - 1) } i.src = h } else { var j = this.slider.find(".royalLoadingScreen"); if (j) { c.settings.loadingComplete.call(c); j.fadeOut(c.settings.welcomeScreenShowSpeed, function () { $(this).remove() }); setTimeout(function () { c._hs1() }, c.settings.welcomeScreenShowSpeed + 100) } else { setTimeout(function () { c._hs1(); c.slider.find(".royalLoadingScreen").remove(); c.settings.loadingComplete.call(c) }, 100) } } } else { setTimeout(function () { c._hs1(); c.slider.find(".royalLoadingScreen").remove(); c.settings.loadingComplete.call(c) }, 100) } } RoyalSlider.prototype = { goTo: function (a) { if (!this.isAnimating) { this.isAnimating = true; var b = this; this._by.unbind("mousedown").unbind("touchstart").unbind("MozTouchDown"); if (this.settings.controlNavEnabled) { this.navItems.unbind("click"); this.navItems.eq(this.currentSlideId).removeClass('current'); this.navItems.eq(a).addClass("current") } this.lastSlideId = this.currentSlideId; this.currentSlideId = a; if (this.settings.directionNavEnabled) { if (this.settings.hideArrowOnLastSlide) { if (this.lastSlideId == 0) { this.arrowLeft.css("visibility", "visible") } else if (this.lastSlideId == this.numSlides - 1) { this.arrowRight.css("visibility", "visible") } if (this.currentSlideId == 0) { this.arrowLeft.css("visibility", "hidden") } else if (this.currentSlideId == this.numSlides - 1) { this.arrowRight.css("visibility", "hidden") } this.arrowRight.unbind("click"); this.arrowLeft.unbind("click") } } this.settings.beforeSlideChange.call(this); this.stopSlideshow(); this._by.animate({ left: -this.currentSlideId * this.sliderWidth }, this.settings.slideTransitionSpeed, this.settings.slideTransitionEasing, function () { b._ir1() }) } }, prev: function () { if (this.currentSlideId <= 0) { this.goTo(this.numSlides - 1) } else { this._jq1() } }, next: function () { if (this.currentSlideId >= this.numSlides - 1) { var savedslideTransitionSpeed = this.settings.slideTransitionSpeed; this.settings.slideTransitionSpeed = this.numSlides * wrapAroundSpeedSetting; this.goTo(0); this.settings.slideTransitionSpeed = savedslideTransitionSpeed } else { this._kp1() } }, resumeSlideshow: function (a) { if (this.settings.slideshowEnabled) { if (this.slideshowTimer == '') { if (a) { if (!this._az) { return } } var b = this; this.slideshowTimer = setInterval(function () { b.next() }, this.settings.slideshowDelay); this.isSlideshowRunning = true } } }, stopSlideshow: function (a) { if (this.settings.slideshowEnabled) { if (a) { this._az = this.isSlideshowRunning } else { this._az = false; this.isSlideshowRunning = false } clearInterval(this.slideshowTimer); this.slideshowTimer = '' } }, _hs1: function () { this._ir1(); if (this.settings.slideshowEnabled && !this.settings.slideshowAutoStart) { this.stopSlideshow() } }, _dw1: function () { if (!this.isIE7) { this._by.css("cursor", _by1) } }, _lo1: function () { if (!this.isIE7) { this._by.css("cursor", _cx1) } }, _kp1: function () { if (this.currentSlideId < this.numSlides - 1) { this.goTo(this.currentSlideId + 1) } else { this.goTo(this.currentSlideId) } }, _jq1: function () { if (this.currentSlideId > 0) { this.goTo(this.currentSlideId - 1) } else { this.goTo(this.currentSlideId) } }, _gt1: function () { var a = parseInt(this._cx.width()); var b = parseInt(this._cx.height()); if (a != this.sliderWidth || b != this.sliderHeight) { this.sliderWidth = a; this.slides.each(function () { $(this).css({ height: b + "px", width: a + "px" }) }); this._by.css({ "left": -this.currentSlideId * this.sliderWidth, width: this.sliderWidth * this.numSlides }) } }, mn1: function (e) { this.goTo($(e.currentTarget).index()) }, _az2: function (e) { if (!this._lo) { var a; if (this.hasTouch) { var b = e.originalEvent.touches; if (b && b.length > 0) { a = b[0] } else { return false } } else { a = e; e.preventDefault() } if (this.slideshowTimer != '') { this.wasSlideshowPlaying = true; this.stopSlideshow() } else { this.wasSlideshowPlaying = false } this._lo1(); this._lo = true; var c = this; $(document).bind("mousemove touchmove MozTouchMove", function (e) { c._by2(e) }); $(document).bind("mouseup touchend MozTouchRelease", function (e) { c._cx2(e) }); this._hs = parseInt(this._by.css("left")); this._ir = a.clientX; this._jq = a.clientY; this._kp = parseInt(this._by.css("left")) } return false }, _by2: function (e) { var a; if (this.hasTouch) { var b = e.originalEvent.touches; if (b.length > 1) { return false } a = b[0]; if (Math.abs(a.clientY - this._jq) + 10 > Math.abs(a.clientX - this._ir)) { return false } e.preventDefault() } else { a = e; e.preventDefault() } this._ev = this._dw; var c = a.clientX - this._ir; if (this._ev != c) { this._dw = c } if (c != 0) { if (this.currentSlideId == 0) { if (c > 0) { c = Math.sqrt(c) * 5 } } else if (this.currentSlideId == (this.numSlides - 1)) { if (c < 0) { c = -Math.sqrt(-c) * 5 } } this._by.css("left", this._hs + c) } return false }, _cx2: function (e) { if (this.wasSlideshowPlaying) { this.resumeSlideshow() } if (this._lo) { this._lo = false; this._dw1(); this.endPos = parseInt(this._by.css("left")); this.isdrag = false; $(document).unbind("mousemove").unbind("touchmove").unbind("MozTouchMove").unbind("mouseup").unbind("touchend").unbind("MozTouchRelease"); if (this.endPos == this._kp) { return } if (this._kp - this.settings.minSlideOffset > this.endPos) { if (this._ev < this._dw) { this.goTo(this.currentSlideId); return false } this._kp1() } else if (this._kp + this.settings.minSlideOffset < this.endPos) { if (this._ev > this._dw) { this.goTo(this.currentSlideId); return false } this._jq1() } else { this.goTo(this.currentSlideId) } } return false }, _ir1: function () { var a = this; this.resumeSlideshow(); if (this.settings.controlNavEnabled) { this.navItems.bind("click", function (e) { e.preventDefault(); a.mn1(e) }) } this._by.bind("mousedown touchstart MozTouchDown", function (e) { a._az2(e) }); if (this.settings.directionNavEnabled) { this.arrowRight.bind('click', function (e) { e.preventDefault(); a.next() }); this.arrowLeft.bind('click', function (e) { e.preventDefault(); a.prev() }) } if (this.settings.captionAnimationEnabled && this.lastSlideId != this.currentSlideId) { if (this.lastSlideId != -1) { this.slides.eq(this.lastSlideId).find(".royalCaption").css("display", "none") } setTimeout(function () { a._dw2(this.currentSlideId) }, 10) } this.isAnimating = false; this.settings.afterSlideChange.call(this) }, _dw2: function (f) { var g = this.slides.eq(this.currentSlideId).find(".royalCaption"); if (g.length) { g.css("display", "block"); var h = this; var j; var l = g.children(); var m; var n; var o; var p; var r; var s; var t; var u; var v; var w; var x; var y; if (this._fu.length > 0) { for (var a = this._fu.length - 1; a > -1; a--) { clearTimeout(this._fu.splice(a, 1)) } } if (this._gt.length > 0) { var z; for (var k = this._gt.length - 1; k > -1; k--) { z = this._gt[k]; if (z != undefined) { z.captionItem.css(z.css) } this._gt.splice(k, 1) } } for (var i = 0; i < l.length; i++) { j = $(l[i]); p = {}; m = false; n = false; r = ""; if (j.attr("data-show-effect") == undefined) { s = this.settings.captionShowEffects } else { s = j.attr("data-show-effect").split(" ") } for (var q = 0; q < s.length; q++) { if (m && n) { break } o = s[q].toLowerCase(); if (!m && o == "fade") { m = true; p['opacity'] = 1 } else if (n) { break } else if (o == "movetop") { r = "margin-top" } else if (o == "moveleft") { r = "margin-left" } else if (o == "movebottom") { r = "margin-bottom" } else if (o == "moveright") { r = "margin-right" } if (r != "") { p['moveProp'] = r; p['moveStartPos'] = parseInt(j.css(r)); n = true } } u = parseInt(j.attr("data-move-offset")); if (isNaN(u)) { u = this.settings.captionMoveOffset } v = parseInt(j.attr("data-delay")); if (isNaN(v)) { v = h.settings.captionShowDelay * i + 10 } w = parseInt(j.attr("data-speed")); if (isNaN(w)) { w = h.settings.captionShowSpeed } x = j.attr("data-easing"); if (x == undefined) { x = h.settings.captionShowEasing } t = {}; if (n) { y = p.moveProp; if (y == "margin-right") { y = "margin-left"; t[y] = p.moveStartPos + u + "px" } else if (y == "margin-bottom") { y = "margin-top"; t[y] = p.moveStartPos + u + "px" } else { t[y] = p.moveStartPos - u + "px" } } if (m) { t.opacity = 0 } j.hide().css(t); if (n) { t[y] = p.moveStartPos + "px" } if (m) { t.opacity = 1 } this._gt.push({ captionItem: j, css: t }); this._fu.push(setTimeout((function (a, b, c, d, e) { return function () { delete h._gt[e]; a.show().animate(b, c, d) } })(j, t, w, x, i), v)) } } } } }
    }
}
catch (err) {
    //Handle errors here
}


//CrossBrowser (IE) media queries
//if (typeof Object.create !== "function") { Object.create = function (a) { function b() { } b.prototype = a; return new b } } var ua = { toString: function () { return navigator.userAgent }, test: function (a) { return this.toString().toLowerCase().indexOf(a.toLowerCase()) > -1 } }; ua.version = (ua.toString().toLowerCase().match(/[\s\S]+(?:rv|it|ra|ie)[\/: ]([\d.]+)/) || [])[1]; ua.webkit = ua.test("webkit"); ua.gecko = ua.test("gecko") && !ua.webkit; ua.opera = ua.test("opera"); ua.ie = ua.test("msie") && !ua.opera; ua.ie6 = ua.ie && document.compatMode && typeof document.documentElement.style.maxHeight === "undefined"; ua.ie7 = ua.ie && document.documentElement && typeof document.documentElement.style.maxHeight !== "undefined" && typeof XDomainRequest === "undefined"; ua.ie8 = ua.ie && typeof XDomainRequest !== "undefined"; var domReady = function () { var a = []; var b = function () { if (!arguments.callee.done) { arguments.callee.done = true; for (var b = 0; b < a.length; b++) { a[b]() } } }; if (document.addEventListener) { document.addEventListener("DOMContentLoaded", b, false) } if (ua.ie) { (function () { try { document.documentElement.doScroll("left") } catch (a) { setTimeout(arguments.callee, 50); return } b() })(); document.onreadystatechange = function () { if (document.readyState === "complete") { document.onreadystatechange = null; b() } } } if (ua.webkit && document.readyState) { (function () { if (document.readyState !== "loading") { b() } else { setTimeout(arguments.callee, 10) } })() } window.onload = b; return function (b) { if (typeof b === "function") { a[a.length] = b } return b } } (); var cssHelper = function () { var a = { BLOCKS: /[^\s{][^{]*\{(?:[^{}]*\{[^{}]*\}[^{}]*|[^{}]*)*\}/g, BLOCKS_INSIDE: /[^\s{][^{]*\{[^{}]*\}/g, DECLARATIONS: /[a-zA-Z\-]+[^;]*:[^;]+;/g, RELATIVE_URLS: /url\(['"]?([^\/\)'"][^:\)'"]+)['"]?\)/g, REDUNDANT_COMPONENTS: /(?:\/\*([^*\\\\]|\*(?!\/))+\*\/|@import[^;]+;)/g, REDUNDANT_WHITESPACE: /\s*(,|:|;|\{|\})\s*/g, MORE_WHITESPACE: /\s{2,}/g, FINAL_SEMICOLONS: /;\}/g, NOT_WHITESPACE: /\S+/g }; var b, c = false; var d = []; var e = function (a) { if (typeof a === "function") { d[d.length] = a } }; var f = function () { for (var a = 0; a < d.length; a++) { d[a](b) } }; var g = {}; var h = function (a, b) { if (g[a]) { var c = g[a].listeners; if (c) { for (var d = 0; d < c.length; d++) { c[d](b) } } } }; var i = function (a, b, c) { if (ua.ie && !window.XMLHttpRequest) { window.XMLHttpRequest = function () { return new ActiveXObject("Microsoft.XMLHTTP") } } if (!XMLHttpRequest) { return "" } var d = new XMLHttpRequest; try { d.open("get", a, true); d.setRequestHeader("X_REQUESTED_WITH", "XMLHttpRequest") } catch (e) { c(); return } var f = false; setTimeout(function () { f = true }, 5e3); document.documentElement.style.cursor = "progress"; d.onreadystatechange = function () { if (d.readyState === 4 && !f) { if (!d.status && location.protocol === "file:" || d.status >= 200 && d.status < 300 || d.status === 304 || navigator.userAgent.indexOf("Safari") > -1 && typeof d.status === "undefined") { b(d.responseText) } else { c() } document.documentElement.style.cursor = ""; d = null } }; d.send("") }; var j = function (b) { b = b.replace(a.REDUNDANT_COMPONENTS, ""); b = b.replace(a.REDUNDANT_WHITESPACE, "$1"); b = b.replace(a.MORE_WHITESPACE, " "); b = b.replace(a.FINAL_SEMICOLONS, "}"); return b }; var k = { mediaQueryList: function (b) { var c = {}; var d = b.indexOf("{"); var e = b.substring(0, d); b = b.substring(d + 1, b.length - 1); var f = [], g = []; var h = e.toLowerCase().substring(7).split(","); for (var i = 0; i < h.length; i++) { f[f.length] = k.mediaQuery(h[i], c) } var j = b.match(a.BLOCKS_INSIDE); if (j !== null) { for (i = 0; i < j.length; i++) { g[g.length] = k.rule(j[i], c) } } c.getMediaQueries = function () { return f }; c.getRules = function () { return g }; c.getListText = function () { return e }; c.getCssText = function () { return b }; return c }, mediaQuery: function (b, c) { b = b || ""; var d = false, e; var f = []; var g = true; var h = b.match(a.NOT_WHITESPACE); for (var i = 0; i < h.length; i++) { var j = h[i]; if (!e && (j === "not" || j === "only")) { if (j === "not") { d = true } } else { if (!e) { e = j } else { if (j.charAt(0) === "(") { var k = j.substring(1, j.length - 1).split(":"); f[f.length] = { mediaFeature: k[0], value: k[1] || null} } } } } return { getList: function () { return c || null }, getValid: function () { return g }, getNot: function () { return d }, getMediaType: function () { return e }, getExpressions: function () { return f } } }, rule: function (a, b) { var c = {}; var d = a.indexOf("{"); var e = a.substring(0, d); var f = e.split(","); var g = []; var h = a.substring(d + 1, a.length - 1).split(";"); for (var i = 0; i < h.length; i++) { g[g.length] = k.declaration(h[i], c) } c.getMediaQueryList = function () { return b || null }; c.getSelectors = function () { return f }; c.getSelectorText = function () { return e }; c.getDeclarations = function () { return g }; c.getPropertyValue = function (a) { for (var b = 0; b < g.length; b++) { if (g[b].getProperty() === a) { return g[b].getValue() } } return null }; return c }, declaration: function (a, b) { var c = a.indexOf(":"); var d = a.substring(0, c); var e = a.substring(c + 1); return { getRule: function () { return b || null }, getProperty: function () { return d }, getValue: function () { return e } } } }; var l = function (c) { if (typeof c.cssHelperText !== "string") { return } var d = { mediaQueryLists: [], rules: [], selectors: {}, declarations: [], properties: {} }; var e = d.mediaQueryLists; var f = d.rules; var g = c.cssHelperText.match(a.BLOCKS); if (g !== null) { for (var h = 0; h < g.length; h++) { if (g[h].substring(0, 7) === "@media ") { e[e.length] = k.mediaQueryList(g[h]); f = d.rules = f.concat(e[e.length - 1].getRules()) } else { f[f.length] = k.rule(g[h]) } } } var i = d.selectors; var j = function (a) { var b = a.getSelectors(); for (var c = 0; c < b.length; c++) { var d = b[c]; if (!i[d]) { i[d] = [] } i[d][i[d].length] = a } }; for (h = 0; h < f.length; h++) { j(f[h]) } var l = d.declarations; for (h = 0; h < f.length; h++) { l = d.declarations = l.concat(f[h].getDeclarations()) } var m = d.properties; for (h = 0; h < l.length; h++) { var n = l[h].getProperty(); if (!m[n]) { m[n] = [] } m[n][m[n].length] = l[h] } c.cssHelperParsed = d; b[b.length] = c; return d }; var m = function (a, b) { a.cssHelperText = j(b || a.innerHTML); return l(a) }; var n = function () { c = true; b = []; var d = []; var e = function () { for (var a = 0; a < d.length; a++) { l(d[a]) } var b = document.getElementsByTagName("style"); for (a = 0; a < b.length; a++) { m(b[a]) } c = false; f() }; var g = document.getElementsByTagName("link"); for (var h = 0; h < g.length; h++) { var k = g[h]; if (k.getAttribute("rel").indexOf("style") > -1 && k.href && k.href.length !== 0 && !k.disabled) { d[d.length] = k } } if (d.length > 0) { var n = 0; var o = function () { n++; if (n === d.length) { e() } }; var p = function (b) { var c = b.href; i(c, function (d) { d = j(d).replace(a.RELATIVE_URLS, "url(" + c.substring(0, c.lastIndexOf("/")) + "/$1)"); b.cssHelperText = d; o() }, o) }; for (h = 0; h < d.length; h++) { p(d[h]) } } else { e() } }; var o = { mediaQueryLists: "array", rules: "array", selectors: "object", declarations: "array", properties: "object" }; var p = { mediaQueryLists: null, rules: null, selectors: null, declarations: null, properties: null }; var q = function (a, b) { if (p[a] !== null) { if (o[a] === "array") { return p[a] = p[a].concat(b) } else { var c = p[a]; for (var d in b) { if (b.hasOwnProperty(d)) { if (!c[d]) { c[d] = b[d] } else { c[d] = c[d].concat(b[d]) } } } return c } } }; var r = function (a) { p[a] = o[a] === "array" ? [] : {}; for (var c = 0; c < b.length; c++) { q(a, b[c].cssHelperParsed[a]) } return p[a] }; domReady(function () { var a = document.body.getElementsByTagName("*"); for (var b = 0; b < a.length; b++) { a[b].checkedByCssHelper = true } if (document.implementation.hasFeature("MutationEvents", "2.0") || window.MutationEvent) { document.body.addEventListener("DOMNodeInserted", function (a) { var b = a.target; if (b.nodeType === 1) { h("DOMElementInserted", b); b.checkedByCssHelper = true } }, false) } else { setInterval(function () { var a = document.body.getElementsByTagName("*"); for (var b = 0; b < a.length; b++) { if (!a[b].checkedByCssHelper) { h("DOMElementInserted", a[b]); a[b].checkedByCssHelper = true } } }, 1e3) } }); var s = function (a) { if (typeof window.innerWidth != "undefined") { return window["inner" + a] } else { if (typeof document.documentElement != "undefined" && typeof document.documentElement.clientWidth != "undefined" && document.documentElement.clientWidth != 0) { return document.documentElement["client" + a] } } }; return { addStyle: function (a, b) { var c = document.createElement("style"); c.setAttribute("type", "text/css"); document.getElementsByTagName("head")[0].appendChild(c); if (c.styleSheet) { c.styleSheet.cssText = a } else { c.appendChild(document.createTextNode(a)) } c.addedWithCssHelper = true; if (typeof b === "undefined" || b === true) { cssHelper.parsed(function (b) { var d = m(c, a); for (var e in d) { if (d.hasOwnProperty(e)) { q(e, d[e]) } } h("newStyleParsed", c) }) } else { c.parsingDisallowed = true } return c }, removeStyle: function (a) { return a.parentNode.removeChild(a) }, parsed: function (a) { if (c) { e(a) } else { if (typeof b !== "undefined") { if (typeof a === "function") { a(b) } } else { e(a); n() } } }, mediaQueryLists: function (a) { cssHelper.parsed(function (b) { a(p.mediaQueryLists || r("mediaQueryLists")) }) }, rules: function (a) { cssHelper.parsed(function (b) { a(p.rules || r("rules")) }) }, selectors: function (a) { cssHelper.parsed(function (b) { a(p.selectors || r("selectors")) }) }, declarations: function (a) { cssHelper.parsed(function (b) { a(p.declarations || r("declarations")) }) }, properties: function (a) { cssHelper.parsed(function (b) { a(p.properties || r("properties")) }) }, broadcast: h, addListener: function (a, b) { if (typeof b === "function") { if (!g[a]) { g[a] = { listeners: []} } g[a].listeners[g[a].listeners.length] = b } }, removeListener: function (a, b) { if (typeof b === "function" && g[a]) { var c = g[a].listeners; for (var d = 0; d < c.length; d++) { if (c[d] === b) { c.splice(d, 1); d -= 1 } } } }, getViewportWidth: function () { return s("Width") }, getViewportHeight: function () { return s("Height") } } } (); domReady(function a() { var a; var b = { LENGTH_UNIT: /[0-9]+(em|ex|px|in|cm|mm|pt|pc)$/, RESOLUTION_UNIT: /[0-9]+(dpi|dpcm)$/, ASPECT_RATIO: /^[0-9]+\/[0-9]+$/, ABSOLUTE_VALUE: /^[0-9]*(\.[0-9]+)*$/ }; var c = []; var d = function () { var a = "css3-mediaqueries-test"; var b = document.createElement("div"); b.id = a; var c = cssHelper.addStyle("@media all and (width) { #" + a + " { width: 1px !important; } }", false); document.body.appendChild(b); var e = b.offsetWidth === 1; c.parentNode.removeChild(c); b.parentNode.removeChild(b); d = function () { return e }; return e }; var e = function () { a = document.createElement("div"); a.style.cssText = "position:absolute;top:-9999em;left:-9999em;" + "margin:0;border:none;padding:0;width:1em;font-size:1em;"; document.body.appendChild(a); if (a.offsetWidth !== 16) { a.style.fontSize = 16 / a.offsetWidth + "em" } a.style.width = "" }; var f = function (b) { a.style.width = b; var c = a.offsetWidth; a.style.width = ""; return c }; var g = function (a, c) { var d = a.length; var e = a.substring(0, 4) === "min-"; var g = !e && a.substring(0, 4) === "max-"; if (c !== null) { var h; var i; if (b.LENGTH_UNIT.exec(c)) { h = "length"; i = f(c) } else { if (b.RESOLUTION_UNIT.exec(c)) { h = "resolution"; i = parseInt(c, 10); var j = c.substring((i + "").length) } else { if (b.ASPECT_RATIO.exec(c)) { h = "aspect-ratio"; i = c.split("/") } else { if (b.ABSOLUTE_VALUE) { h = "absolute"; i = c } else { h = "unknown" } } } } } var k, l; if ("device-width" === a.substring(d - 12, d)) { k = screen.width; if (c !== null) { if (h === "length") { return e && k >= i || g && k < i || !e && !g && k === i } else { return false } } else { return k > 0 } } else { if ("device-height" === a.substring(d - 13, d)) { l = screen.height; if (c !== null) { if (h === "length") { return e && l >= i || g && l < i || !e && !g && l === i } else { return false } } else { return l > 0 } } else { if ("width" === a.substring(d - 5, d)) { k = document.documentElement.clientWidth || document.body.clientWidth; if (c !== null) { if (h === "length") { return e && k >= i || g && k < i || !e && !g && k === i } else { return false } } else { return k > 0 } } else { if ("height" === a.substring(d - 6, d)) { l = document.documentElement.clientHeight || document.body.clientHeight; if (c !== null) { if (h === "length") { return e && l >= i || g && l < i || !e && !g && l === i } else { return false } } else { return l > 0 } } else { if ("device-aspect-ratio" === a.substring(d - 19, d)) { return h === "aspect-ratio" && screen.width * i[1] === screen.height * i[0] } else { if ("color-index" === a.substring(d - 11, d)) { var m = Math.pow(2, screen.colorDepth); if (c !== null) { if (h === "absolute") { return e && m >= i || g && m < i || !e && !g && m === i } else { return false } } else { return m > 0 } } else { if ("color" === a.substring(d - 5, d)) { var n = screen.colorDepth; if (c !== null) { if (h === "absolute") { return e && n >= i || g && n < i || !e && !g && n === i } else { return false } } else { return n > 0 } } else { if ("resolution" === a.substring(d - 10, d)) { var o; if (j === "dpcm") { o = f("1cm") } else { o = f("1in") } if (c !== null) { if (h === "resolution") { return e && o >= i || g && o < i || !e && !g && o === i } else { return false } } else { return o > 0 } } else { return false } } } } } } } } }; var h = function (a) { var b = a.getValid(); var c = a.getExpressions(); var d = c.length; if (d > 0) { for (var e = 0; e < d && b; e++) { b = g(c[e].mediaFeature, c[e].value) } var f = a.getNot(); return b && !f || f && !b } }; var i = function (a) { var b = a.getMediaQueries(); var d = {}; for (var e = 0; e < b.length; e++) { if (h(b[e])) { d[b[e].getMediaType()] = true } } var f = [], g = 0; for (var i in d) { if (d.hasOwnProperty(i)) { if (g > 0) { f[g++] = "," } f[g++] = i } } if (f.length > 0) { c[c.length] = cssHelper.addStyle("@media " + f.join("") + "{" + a.getCssText() + "}", false) } }; var j = function (a) { for (var b = 0; b < a.length; b++) { i(a[b]) } if (ua.ie) { document.documentElement.style.display = "block"; setTimeout(function () { document.documentElement.style.display = "" }, 0); setTimeout(function () { cssHelper.broadcast("cssMediaQueriesTested") }, 100) } else { cssHelper.broadcast("cssMediaQueriesTested") } }; var k = function () { for (var a = 0; a < c.length; a++) { cssHelper.removeStyle(c[a]) } c = []; cssHelper.mediaQueryLists(j) }; var l = 0; var m = function () { var a = cssHelper.getViewportWidth(); var b = cssHelper.getViewportHeight(); if (ua.ie) { var c = document.createElement("div"); c.style.position = "absolute"; c.style.top = "-9999em"; c.style.overflow = "scroll"; document.body.appendChild(c); l = c.offsetWidth - c.clientWidth; document.body.removeChild(c) } var e; var f = function () { var c = cssHelper.getViewportWidth(); var f = cssHelper.getViewportHeight(); if (Math.abs(c - a) > l || Math.abs(f - b) > l) { a = c; b = f; clearTimeout(e); e = setTimeout(function () { if (!d()) { k() } else { cssHelper.broadcast("cssMediaQueriesTested") } }, 500) } }; window.onresize = function () { var a = window.onresize || function () { }; return function () { a(); f() } } () }; var n = document.documentElement; n.style.marginLeft = "-32767px"; setTimeout(function () { n.style.marginTop = "" }, 2e4); return function () { if (!d()) { cssHelper.addListener("newStyleParsed", function (a) { j(a.cssHelperParsed.mediaQueryLists) }); cssHelper.addListener("cssMediaQueriesTested", function () { if (ua.ie) { n.style.width = "1px" } setTimeout(function () { n.style.width = ""; n.style.marginLeft = "" }, 0); cssHelper.removeListener("cssMediaQueriesTested", arguments.callee) }); e(); k() } else { n.style.marginLeft = "" } m() } } ()); try { document.execCommand("BackgroundImageCache", false, true) } catch (e) { }

/*! Respond.js v1.0.1pre: min/max-width media query polyfill. (c) Scott Jehl. MIT/GPLv2 Lic. j.mp/respondjs  */
(function (e, h) { e.respond = {}; respond.update = function () { }; respond.mediaQueriesSupported = h; if (h) { return } var u = e.document, r = u.documentElement, i = [], k = [], p = [], o = {}, g = 30, f = u.getElementsByTagName("head")[0] || r, b = f.getElementsByTagName("link"), d = [], a = function () { var B = b, w = B.length, z = 0, y, x, A, v; for (; z < w; z++) { y = B[z], x = y.href, A = y.media, v = y.rel && y.rel.toLowerCase() === "stylesheet"; if (!!x && v && !o[x]) { if (y.styleSheet && y.styleSheet.rawCssText) { m(y.styleSheet.rawCssText, x, A); o[x] = true } else { if (!/^([a-zA-Z]+?:(\/\/)?)/.test(x) || x.replace(RegExp.$1, "").split("/")[0] === e.location.host) { d.push({ href: x, media: A }) } } } } t() }, t = function () { if (d.length) { var v = d.shift(); n(v.href, function (w) { m(w, v.href, v.media); o[v.href] = true; t() }) } }, m = function (G, v, x) { var E = G.match(/@media[^\{]+\{([^\{\}]+\{[^\}\{]+\})+/gi), H = E && E.length || 0, v = v.substring(0, v.lastIndexOf("/")), w = function (I) { return I.replace(/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g, "$1" + v + "$2$3") }, y = !H && x, B = 0, A, C, D, z, F; if (v.length) { v += "/" } if (y) { H = 1 } for (; B < H; B++) { A = 0; if (y) { C = x; k.push(w(G)) } else { C = E[B].match(/@media ([^\{]+)\{([\S\s]+?)$/) && RegExp.$1; k.push(RegExp.$2 && w(RegExp.$2)) } z = C.split(","); F = z.length; for (; A < F; A++) { D = z[A]; i.push({ media: D.match(/(only\s+)?([a-zA-Z]+)(\sand)?/) && RegExp.$2, rules: k.length - 1, minw: D.match(/\(min\-width:[\s]*([\s]*[0-9]+)px[\s]*\)/) && parseFloat(RegExp.$1), maxw: D.match(/\(max\-width:[\s]*([\s]*[0-9]+)px[\s]*\)/) && parseFloat(RegExp.$1) }) } } j() }, l, q, j = function (E) { var v = "clientWidth", x = r[v], D = u.compatMode === "CSS1Compat" && x || u.body[v] || x, z = {}, C = u.createDocumentFragment(), B = b[b.length - 1], w = (new Date()).getTime(); if (E && l && w - l < g) { clearTimeout(q); q = setTimeout(j, g); return } else { l = w } for (var y in i) { var F = i[y]; if (!F.minw && !F.maxw || (!F.minw || F.minw && D >= F.minw) && (!F.maxw || F.maxw && D <= F.maxw)) { if (!z[F.media]) { z[F.media] = [] } z[F.media].push(k[F.rules]) } } for (var y in p) { if (p[y] && p[y].parentNode === f) { f.removeChild(p[y]) } } for (var y in z) { var G = u.createElement("style"), A = z[y].join("\n"); G.type = "text/css"; G.media = y; if (G.styleSheet) { G.styleSheet.cssText = A } else { G.appendChild(u.createTextNode(A)) } C.appendChild(G); p.push(G) } f.insertBefore(C, B.nextSibling) }, n = function (v, x) { var w = c(); if (!w) { return } w.open("GET", v, true); w.onreadystatechange = function () { if (w.readyState != 4 || w.status != 200 && w.status != 304) { return } x(w.responseText) }; if (w.readyState == 4) { return } w.send(null) }, c = (function () { var v = false; try { v = new XMLHttpRequest() } catch (w) { v = new ActiveXObject("Microsoft.XMLHTTP") } return function () { return v } })(); a(); respond.update = a; function s() { j(true) } if (e.addEventListener) { e.addEventListener("resize", s, false) } else { if (e.attachEvent) { e.attachEvent("onresize", s) } } })(this, (function (f) { if (f.matchMedia) { return true } var e, i = document, c = i.documentElement, g = c.firstElementChild || c.firstChild, h = !i.body, d = i.body || i.createElement("body"), b = i.createElement("div"), a = "only all"; b.id = "mq-test-1"; b.style.cssText = "position:absolute;top:-99em"; d.appendChild(b); b.innerHTML = '_<style media="' + a + '"> #mq-test-1 { width: 9px; }</style>'; if (h) { c.insertBefore(d, g) } b.removeChild(b.firstChild); e = b.offsetWidth == 9; if (h) { c.removeChild(d) } else { d.removeChild(b) } return e })(this));


//Temporary Code:


