/*
 * HoverIntent
 * 
 */

(function(a){a.fn.hoverIntent=function(b,c){var d={sensitivity:7,interval:100,timeout:0};d=a.extend(d,c?{over:b,out:c}:b);var e,f,g,h;var i=function(a){e=a.pageX;f=a.pageY};var j=function(b,c){c.hoverIntent_t=clearTimeout(c.hoverIntent_t);if(Math.abs(g-e)+Math.abs(h-f)<d.sensitivity){a(c).unbind("mousemove",i);c.hoverIntent_s=1;return d.over.apply(c,[b])}else{g=e;h=f;c.hoverIntent_t=setTimeout(function(){j(b,c)},d.interval)}};var k=function(a,b){b.hoverIntent_t=clearTimeout(b.hoverIntent_t);b.hoverIntent_s=0;return d.out.apply(b,[a])};var l=function(b){var c=(b.type=="mouseover"?b.fromElement:b.toElement)||b.relatedTarget;while(c&&c!=this){try{c=c.parentNode}catch(b){c=this}}if(c==this){return false}var e=jQuery.extend({},b);var f=this;if(f.hoverIntent_t){f.hoverIntent_t=clearTimeout(f.hoverIntent_t)}if(b.type=="mouseover"){g=e.pageX;h=e.pageY;a(f).bind("mousemove",i);if(f.hoverIntent_s!=1){f.hoverIntent_t=setTimeout(function(){j(e,f)},d.interval)}}else{a(f).unbind("mousemove",i);if(f.hoverIntent_s==1){f.hoverIntent_t=setTimeout(function(){k(e,f)},d.timeout)}}};return this.mouseover(l).mouseout(l)}})(jQuery);





/* Copyright (c) 2006 Brandon Aaron (http://brandonaaron.net)
 * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 
 * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
 *
 * $LastChangedDate: 2007-06-19 20:25:28 -0500 (Tue, 19 Jun 2007) $
 * $Rev: 2111 $
 *
 * Version 2.1
 */
(function($){$.fn.bgIframe=$.fn.bgiframe=function(s){if($.browser.msie&&parseInt($.browser.version)<=6){s=$.extend({top:'auto',left:'auto',width:'auto',height:'auto',opacity:true,src:'javascript:false;'},s||{});var prop=function(n){return n&&n.constructor==Number?n+'px':n;},html='<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+s.src+'"'+'style="display:block;position:absolute;z-index:-1;'+(s.opacity!==false?'filter:Alpha(Opacity=\'0\');':'')+'top:'+(s.top=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+\'px\')':prop(s.top))+';'+'left:'+(s.left=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+\'px\')':prop(s.left))+';'+'width:'+(s.width=='auto'?'expression(this.parentNode.offsetWidth+\'px\')':prop(s.width))+';'+'height:'+(s.height=='auto'?'expression(this.parentNode.offsetHeight+\'px\')':prop(s.height))+';'+'"/>';return this.each(function(){if($('> iframe.bgiframe',this).length==0)this.insertBefore(document.createElement(html),this.firstChild);});}return this;};if(!$.browser.version)$.browser.version=navigator.userAgent.toLowerCase().match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)[1];})(jQuery);

/*
 * Superfish v1.4.8 - jQuery menu widget
 * Copyright (c) 2008 Joel Birch
 *
 * Dual licensed under the MIT and GPL licenses:
 * 	http://www.opensource.org/licenses/mit-license.php
 * 	http://www.gnu.org/licenses/gpl.html
 *
 * CHANGELOG: http://users.tpg.com.au/j_birch/plugins/superfish/changelog.txt
 */

(function(a){a.fn.superfish=function(b){var c=a.fn.superfish,d=c.c,e=a(['<span class="',d.arrowClass,'"> &#187;</span>'].join("")),f=function(){var b=a(this),c=h(b);clearTimeout(c.sfTimer);b.showSuperfishUl().siblings().hideSuperfishUl()},g=function(){var b=a(this),d=h(b),e=c.op;clearTimeout(d.sfTimer);d.sfTimer=setTimeout(function(){e.retainPath=a.inArray(b[0],e.$path)>-1;b.hideSuperfishUl();if(e.$path.length&&b.parents(["li.",e.hoverClass].join("")).length<1){f.call(e.$path)}},e.delay)},h=function(a){var b=a.parents(["ul.",d.menuClass,":first"].join(""))[0];c.op=c.o[b.serial];return b},i=function(a){a.addClass(d.anchorClass).append(e.clone())};return this.each(function(){var e=this.serial=c.o.length;var h=a.extend({},c.defaults,b);h.$path=a("li."+h.pathClass,this).slice(0,h.pathLevels).each(function(){a(this).addClass([h.hoverClass,d.bcClass].join(" ")).filter("li:has(ul)").removeClass(h.pathClass)});c.o[e]=c.op=h;a("li:has(ul)",this)[a.fn.hoverIntent&&!h.disableHI?"hoverIntent":"hover"](f,g).each(function(){if(h.autoArrows)i(a(">a:first-child",this))}).not("."+d.bcClass).hideSuperfishUl();var j=a("a",this);j.each(function(a){var b=j.eq(a).parents("li");j.eq(a).focus(function(){f.call(b)}).blur(function(){g.call(b)})});h.onInit.call(this)}).each(function(){var b=[d.menuClass];if(c.op.dropShadows&&!(a.browser.msie&&a.browser.version<7))b.push(d.shadowClass);a(this).addClass(b.join(" "))})};var b=a.fn.superfish;b.o=[];b.op={};b.IE7fix=function(){var c=b.op;if(a.browser.msie&&a.browser.version>6&&c.dropShadows&&c.animation.opacity!=undefined)this.toggleClass(b.c.shadowClass+"-off")};b.c={bcClass:"sf-breadcrumb",menuClass:"sf-js-enabled",anchorClass:"sf-with-ul",arrowClass:"sf-sub-indicator",shadowClass:"sf-shadow"};b.defaults={hoverClass:"sfHover",pathClass:"overideThisToUse",pathLevels:1,delay:800,animation:{opacity:"show"},speed:"normal",autoArrows:true,dropShadows:true,disableHI:false,onInit:function(){},onBeforeShow:function(){},onShow:function(){},onHide:function(){}};a.fn.extend({hideSuperfishUl:function(){var c=b.op,d=c.retainPath===true?c.$path:"";c.retainPath=false;var e=a(["li.",c.hoverClass].join(""),this).add(this).not(d).removeClass(c.hoverClass).find(">ul").hide().css("visibility","hidden");c.onHide.call(e);return this},showSuperfishUl:function(){var a=b.op,c=b.c.shadowClass+"-off",d=this.addClass(a.hoverClass).find(">ul:hidden").css("visibility","visible");b.IE7fix.call(d);a.onBeforeShow.call(d);d.animate(a.animation,a.speed,function(){b.IE7fix.call(d);a.onShow.call(d)});return this}})})(jQuery);


/*
 * jQuery hashchange event - v1.3 - 7/21/2010
 * http://benalman.com/projects/jquery-hashchange-plugin/
 * 
 * Copyright (c) 2010 "Cowboy" Ben Alman
 * Dual licensed under the MIT and GPL licenses.
 * http://benalman.com/about/license/
 */
(function($,e,b){var c="hashchange",h=document,f,g=$.event.special,i=h.documentMode,d="on"+c in e&&(i===b||i>7);function a(j){j=j||location.href;return"#"+j.replace(/^[^#]*#?(.*)$/,"$1")}$.fn[c]=function(j){return j?this.bind(c,j):this.trigger(c)};$.fn[c].delay=50;g[c]=$.extend(g[c],{setup:function(){if(d){return false}$(f.start)},teardown:function(){if(d){return false}$(f.stop)}});f=(function(){var j={},p,m=a(),k=function(q){return q},l=k,o=k;j.start=function(){p||n()};j.stop=function(){p&&clearTimeout(p);p=b};function n(){var r=a(),q=o(m);if(r!==m){l(m=r,q);$(e).trigger(c)}else{if(q!==m){location.href=location.href.replace(/#.*/,"")+q}}p=setTimeout(n,$.fn[c].delay)}$.browser.msie&&!d&&(function(){var q,r;j.start=function(){if(!q){r=$.fn[c].src;r=r&&r+a();q=$('<iframe tabindex="-1" title="empty"/>').hide().one("load",function(){r||l(a());n()}).attr("src",r||"javascript:0").insertAfter("body")[0].contentWindow;h.onpropertychange=function(){try{if(event.propertyName==="title"){q.document.title=h.title}}catch(s){}}}};j.stop=k;o=function(){return a(q.location.href)};l=function(v,s){var u=q.document,t=$.fn[c].domain;if(v!==s){u.title=h.title;u.open();t&&u.write('<script>document.domain="'+t+'"<\/script>');u.close();q.location.hash=v}}})();return j})()})(jQuery,this);



/*
 * Sudo Slider
 */

(function(i){i.fn.sudoSlider=function(X){var d=!1,e=!d,f=this,X=i.extend({controlsShow:e,controlsFadeSpeed:400,controlsFade:e,insertAfter:e,firstShow:d,lastShow:d,vertical:d,speed:800,ease:"swing",auto:d,pause:2E3,continuous:d,prevNext:e,numeric:d,numericAttr:'class="controls"',numericText:[],clickableAni:d,history:d,speedhistory:400,autoheight:e,customLink:d,fade:d,crossFade:e,fadespeed:1E3,updateBefore:d,ajax:d,preloadAjax:100,startSlide:d,ajaxLoadFunction:d,beforeAniFunc:d,afterAniFunc:d,uncurrentFunc:d,
currentFunc:d,prevHtml:'<a href="#" class="prevBtn"> previous </a>',nextHtml:'<a href="#" class="nextBtn"> next </a>',loadingText:"Loading Content...",firstHtml:'<a href="#" class="firstBtn"> first </a>',controlsAttr:'id="controls"',lastHtml:'<a href="#" class="lastBtn"> last </a>',autowidth:e,slideCount:1,resumePause:d,moveCount:1},X);return this.each(function(){function ea(c,p){l=0;for(b in I)a[l]=I[b],l++;x=d;D=e;o=c.children("ul");k=o.children("li");j=k.length;if(a[25]&&(o.length==0&&c.append(o=
i("<ul></ul>")),a[25].length>j)){for(b=1;b<=a[25].length-j;b++)o.append("<li><p>"+a[35]+"</p></li>");k=o.children("li");j=k.length}y=g=0;s=j-1;q=e;J=r=Y=d;Q=[];x=d;c.css("position")=="static"&&c.css("position","relative");k.css({"float":"left",display:"block"});a[40]=n(a[40]);a[42]--;v=a[40];a[21]||(a[40]+=a[42]);a[40]>j&&(a[40]=j);a[27]=n(a[27])||1;E=a[11]&&(!a[21]||a[40]>1);for(b=0;b<j;b++)a[15][b]=a[15][b]||b+1,a[25][b]=a[25][b]||d;if(E){for(h=a[40];h>=1;h--)o.prepend(k.eq(-a[40]+h-1).clone()).append(k.eq(a[40]-
h).clone());m=o.children("li");if(a[25])for(b=j-a[40];b<j;b++)a[25][b]&&b!=a[27]-1&&z(b,d,0,d)}a[2]=a[2]&&!a[11];o[a[6]?"height":"width"](1E7);m=o.children("li");A=d;if(a[0]){A=i("<span "+a[37]+"></span>");i(c)[a[3]?"after":"before"](A);if(a[13]){fa=A.prepend("<ol "+a[14]+"></ol>").children();l=a[13]=="pages"?v:1;for(b=0;b<j-(a[11]||a[13]=="pages"?1:v)+1;b+=l)Q[b]=i("<li rel='"+(b+1)+"'><a href='#'><span>"+a[15][b]+"</span></a></li>").appendTo(fa).click(function(){F(i(this).attr("rel")-1,e);return d})}a[4]&&
(ga=R(a[36],"first"));a[5]&&(ha=R(a[38],"last"));a[12]&&(ia=R(a[34],"next"),ja=R(a[33],"prev"))}if(a[26]===e)for(h=0;h<=s;h++)a[25][h]&&a[27]-1!=h&&z(h,d,0,d);l=[1,7,10,18,23];for(b in l)a[n(l[b])]=sa(a[n(l[b])]);a[20]&&i(a[20]).live("click",function(){if(b=i(this).attr("rel"))b=="stop"?(a[9]=d,clearTimeout(t),K=d):b=="start"?(t=L(a[10]),a[9]=e):b=="block"?q=d:b=="unblock"?q=e:q&&F(b==n(b)?b-1:b,e);return d});Z(m.slice(0,a[40]),e,function(){a[9]&&(t=L(a[10]));p?B(p,d,d,d):a[17]?(i.hashchange?i(window).hashchange(S):
i.address?i.address.change(function(){S()}):i(window).bind("hashchange",S),S()):B(a[27]-1,d,d,d)})}function S(){a:{var c=location.hash.substr(1);for(h in a[15])if(a[15][h]==c)break a;h=c?g:0}D?B(h,d,d,d):h!=g&&F(h,d)}function ka(){if(a[25]&&n(a[26]))for(b in a[25])if(a[25][b]){clearTimeout(T);T=setTimeout(function(){z(b,d,0,d)},n(a[26]));break}}function L(a){K=e;return setTimeout(function(){F("next",d)},a)}function sa(a){return n(a)||a==0?n(a):a=="fast"?200:a=="normal"||a=="medium"?400:a=="slow"?
600:400}function R(a,b){return i(a).prependTo(A).click(function(){F(b,e);return d})}function F(c,p){M=d;if(!x){if(a[9]){var w=a[7];r&&a[22]?w=n(w*0.6):r&&(w=0);p?(clearTimeout(t),K=d,a[41]&&(t=L(w+a[41]))):t=L(a[10]+w)}a[21]?la(c,p):(a[11]?(c=b=N(c),w=Math.abs(g-b),b<a[40]-v+1&&Math.abs(g-(b+j))<w&&(c=b+j,w=Math.abs(g-b-j)),b>s-a[40]&&Math.abs(g-b+j)<w&&(c=b-j)):c=N(c),B(c,p,e,d))}}function ma(c,d,b){if(b)var b=ia,e=ha,g="next",f="last",j=a[5];else b=ja,e=ga,g="prev",f="first",j=a[4];if(a[0]){if(a[12])b[c?
"fadeIn":"fadeOut"](d);if(j)e[c?"fadeIn":"fadeOut"](d)}if(a[20])i(a[20]).filter(function(){return i(this).attr("rel")==g||i(this).attr("rel")==f})[c?"fadeIn":"fadeOut"](d)}function na(a,b){ma(a,b,d);ma(a<j-v,b,e)}function $(c){c=u(c)+1;if(a[13])for(b in Q)oa(Q[b],c);a[20]&&oa(i(a[20]),c)}function oa(c,p){c.filter&&(c.filter(".current").removeClass("current").each(function(){i.isFunction(a[31])&&a[31].call(this,i(this).attr("rel"))}),c.filter(function(){l=i(this).attr("rel");if(a[13]=="pages")for(b=
0;b<v;b++){if(l==p-b)return e}else return l==p;return d}).addClass("current").each(function(){i.isFunction(a[32])&&a[32].call(this,p)}))}function Z(a,b,d){var a=a.add(a.find("img")).filter("img"),e=a.length;e||d();a.load(function(){this.naturalHeight&&!this.clientHeight&&i(this).height(this.naturalHeight).width(this.naturalWidth);b?(e--,e==0&&d()):d()}).each(function(){if((this.complete||this.complete===void 0)&&b){var a=this.src;this.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==";
this.src=a}})}function V(c,b){a[19]&&pa(c,b,e);a[39]&&pa(c,b,d)}function pa(a,b,e){O.ready(function(){qa(a,b,e);Z(k.eq(a),d,function(){qa(a,b,e)})})}function qa(c,b,e){c=u(c);l=k.eq(c)[e?"height":"width"]();O.animate(e?{height:l}:{width:l},{queue:d,duration:b,easing:a[8]})}function aa(){o.css(a[6]?"margin-top":"margin-left",ba(g))}function ba(c){c=m.eq(c+(E?a[40]:0));return c.length?-c.position()[a[6]?"top":"left"]:0}function ta(){g=u(g);a[24]||$(g);aa();q=e;if(a[17]&&Y)window.location.hash=a[15][g];
!r&&M&&C(g,e)}function C(c,b){(b?ca:da)(k.eq(c),u(c)+1);if(E&&(c<a[40]&&(b?ca:da)(m.eq(c<0?c+a[40]:c-a[40]),c+1),c>s-a[40]||c==-a[40]))(b?ca:da)(m.eq(c==-a[40]?-1:a[40]+c-s-1),c+1)}function ca(c,b){i.isFunction(a[30])&&a[30].call(c,b)}function da(c,b){i.isFunction(a[29])&&a[29].call(c,b)}function N(c){return c=="next"?u(g+1+a[42]):c=="prev"?u(g-1-a[42]):c=="first"?0:c=="last"?s:n(c)}function z(c,b,g,f){T&&clearTimeout(T);var U=a[25][c],j=k.eq(c),l=g===e,g=g===e?0:g;r&&!a[22]&&n(a[23]*0.4);var h=d;
i.ajax({url:U,success:function(a,i,U){U.getResponseHeader("Content-Type").substr(0,5)!="image"&&(h=e,j.html(a),ra(c,g,f,b,l,d))},complete:function(){if(!h)image=new Image,j.html("").append(image),image.src=U,ra(c,g,f,b,l,e)}});a[25][c]=d;I.ajax[c]=d}function ra(c,b,g,f,j,l){var h=k.eq(c);E&&(c<a[40]&&m.eq(c<0?c+a[40]:c-a[40]).replaceWith(i(h).clone()),c>s-a[40]&&m.eq(a[40]+c-s-1).replaceWith(i(h).clone()),m=o.children("li"),j===e&&aa());f&&V(c,b);Z(h,e,function(){j===e&&aa();i.isFunction(g)&&g();
ka()});i.isFunction(a[28])&&a[28].call(h,n(c)+1,l);g==2&&(C(c,d),M||(C(c,e),M=e))}function la(c,p,f){if(N(c)!=g&&!x&&q){J=d;a[24]&&$(N(c));var j=!p&&!a[9]&&a[17]?a[23]*(a[18]/a[7]):a[23],h=N(c);a[2]&&na(h,a[1]);if(f)j=W,G&&G--;else if(a[25]){G=0;W=j;for(b=h;b<h+v;b++)a[25][b]&&(z(u(b),d,j,function(){la(c,p,e)}),G++)}else G=d;if(!G)if(q=!p,V(h,a[23]),C(h,d),a[22]){var l=e,f=0;for(b=h;b<h+v;b++)k.eq(u(b)).clone().prependTo(O).css({"z-index":"100000",position:"absolute","list-style":"none",top:a[6]?
f:0,left:a[6]?0:f}).hide().fadeIn(a[23],function(){screen.fontSmoothingEnabled&&this.style.removeAttribute("filter");r=q=e;if(l){B(h,d,d,d);if(a[17]&&p)window.location.hash=a[15][g];C(h,e);l=d}i(this).remove();r=d}),f+=k.eq(b)[a[6]?"outerHeight":"outerWidth"](e)}else{var o=n(j*0.6);k.stop().fadeTo(j-o,0.001,function(){r=q=e;B(h,d,d,d);q=!p;k.fadeTo(o,1,function(){screen.fontSmoothingEnabled&&this.style.removeAttribute("filter");if(a[17]&&p)window.location.hash=a[15][g];q=e;r=d;C(h,e)})})}}}function B(c,
f,h,i){if(q&&!x&&(c!=g||D)&&j>u(c)||i){i||(J=d);q=!f&&!a[9]?e:a[16];Y=f;y=g;g=c;a[24]&&$(g);var k=Math.sqrt(Math.abs(y-g)),m=!h?0:!f&&!a[9]?n(k*a[18]):n(k*a[7]),k=u(g);if(i)m=W,P&&P--;else if(a[25]){a[25][k]&&(z(k,e,D||m,2),J=e);if(!r){var i=y>g?g:y,t=y>g?y:g;P=0;W=m;for(b=i;b<=t;b++)b<=s&&b>=0&&a[25][b]&&(z(b,d,m,function(){B(c,f,h,e)}),P++)}for(b=k+1;b<=k+v;b++)a[25][b]&&z(b,d,0,d)}P||(!r&&!J&&(C(k,d),M=e),r||V(g,m),l=ba(g),o.animate(a[6]?{marginTop:l}:{marginLeft:l},{queue:d,duration:m,easing:a[8],
complete:ta}),a[2]&&(m=a[1],!f&&!a[9]&&(m=a[18]/a[7]*a[1]),h||(m=0),r&&(m=n(a[23]*0.6)),na(g,m)),D&&(a[25][k]||ka()),D=d)}}function u(a){return n(a<0?a+j:a>s?a-j:a)}function n(a){return parseInt(a,10)}var D,o,k,m,j,g,y,s,q,Y,r,J,Q,fa,x,A,ga,ha,ia,ja,t,H,W,P,G,K,b,l,h,E,v,M=d,T,O=i(this),I=X,a=[];ea(O,d);f.getOption=function(a){return I[a]};f.setOption=function(a,b){b&&(f.destroy(),I[a]=b,f.init());return f};f.insertSlide=function(c,b,d){if(c){f.destroy();b>j&&(b=j);c="<li>"+c+"</li>";!b||b==0?o.prepend(c):
k.eq(b-1).after(c);(b<=H||!b||b==0)&&H++;if(a[15].length<b)a[15].length=b;a[15].splice(b,0,d||n(b)+1);f.init()}return f};f.removeSlide=function(b){b--;f.destroy();k.eq(b).remove();a[15].splice(b,1);b<H&&H--;f.init();return f};f.goToSlide=function(a){F(a==n(a)?a-1:a,e);return f};f.block=function(){q=d;return f};f.unblock=function(){q=e;return f};f.startAuto=function(){a[9]=e;t=L(a[10]);return f};f.stopAuto=function(){a[9]=d;clearTimeout(t);K=d;return f};f.destroy=function(){H=g;A&&A.remove();x=e;i(a[20]).die("click");
if(E)for(b=1;b<=a[40];b++)m.eq(b-1).add(m.eq(-b)).remove();o.css(a[6]?"margin-top":"margin-left",ba(g));return f};f.init=function(){x&&ea(O,H);return f};f.adjust=function(a){a||(a=0);V(h,a);return f};f.getValue=function(a){return a=="currentSlide"?g+1:a=="totalSlides"?j:a=="clickable"?q:a=="destroyed"?x:a=="autoAnimation"?K:void 0}})}})(jQuery);

