/*
 * jQuery history plugin
 * Copyright (c) 2006-2009 Taku Sano (Mikage Sawatari)
 * Copyright (c) 2010 Takayuki Miwa
 */
(function($){var locationWrapper={put:function(hash,win){(win||window).location.hash=this.encoder(hash);},get:function(win){var hash=((win||window).location.hash).replace(/^#/,'');try{return $.browser.mozilla?hash:decodeURIComponent(hash);}catch(error){return hash;}},encoder:encodeURIComponent};var iframeWrapper={id:"__jQuery_history",init:function(){var html='<iframe id="'+this.id+'" style="display:none" src="javascript:false;" />';$("body").prepend(html);return this;},_document:function(){return $("#"+this.id)[0].contentWindow.document;},put:function(hash){var doc=this._document();doc.open();doc.close();locationWrapper.put(hash,doc);},get:function(){return locationWrapper.get(this._document());}};function initObjects(options){options=$.extend({unescape:false},options||{});locationWrapper.encoder=encoder(options.unescape);function encoder(unescape_){if(unescape_===true){return function(hash){return hash;};}if(typeof unescape_=="string"&&(unescape_=partialDecoder(unescape_.split("")))||typeof unescape_=="function"){return function(hash){return unescape_(encodeURIComponent(hash));};}return encodeURIComponent;}function partialDecoder(chars){var re=new RegExp($.map(chars,encodeURIComponent).join("|"),"ig");return function(enc){return enc.replace(re,decodeURIComponent);};}}var implementations={};implementations.base={callback:undefined,type:undefined,check:function(){},load:function(hash){},init:function(callback,options){initObjects(options);self.callback=callback;self._options=options;self._init();},_init:function(){},_options:{}};implementations.timer={_appState:undefined,_init:function(){var current_hash=locationWrapper.get();self._appState=current_hash;self.callback(current_hash);setInterval(self.check,100);},check:function(){var current_hash=locationWrapper.get();if(current_hash!=self._appState){self._appState=current_hash;self.callback(current_hash);}},load:function(hash){if(hash!=self._appState){locationWrapper.put(hash);self._appState=hash;self.callback(hash);}}};implementations.iframeTimer={_appState:undefined,_init:function(){var current_hash=locationWrapper.get();self._appState=current_hash;iframeWrapper.init().put(current_hash);self.callback(current_hash);setInterval(self.check,100);},check:function(){var iframe_hash=iframeWrapper.get(),location_hash=locationWrapper.get();if(location_hash!=iframe_hash){if(location_hash==self._appState){self._appState=iframe_hash;locationWrapper.put(iframe_hash);self.callback(iframe_hash);}else{self._appState=location_hash;iframeWrapper.put(location_hash);self.callback(location_hash);}}},load:function(hash){if(hash!=self._appState){locationWrapper.put(hash);iframeWrapper.put(hash);self._appState=hash;self.callback(hash);}}};implementations.hashchangeEvent={_init:function(){self.callback(locationWrapper.get());$(window).bind('hashchange',self.check);},check:function(){self.callback(locationWrapper.get());},load:function(hash){locationWrapper.put(hash);}};var self=$.extend({},implementations.base);if($.browser.msie&&($.browser.version<8||document.documentMode<8)){self.type='iframeTimer';}else if("onhashchange"in window){self.type='hashchangeEvent';}else{self.type='timer';}
$.extend(self,implementations[self.type]);$.history=self;})(jQuery);
// ColorBox v1.3.16 - a full featured, light-weight, customizable lightbox based on jQuery 1.3+
// Copyright (c) 2011 Jack Moore - jack@colorpowered.com
// Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php
(function(a,b,c){function ba(b){if(!T){O=b;Z(a.extend(J,a.data(O,e)));x=a(O);P=0;if(J.rel!=="nofollow"){x=a("."+V).filter(function(){var b=a.data(this,e).rel||this.rel;return b===J.rel});P=x.index(O);if(P===-1){x=x.add(O);P=x.length-1}}if(!R){R=S=true;q.show();if(J.returnFocus){try{O.blur();a(O).one(k,function(){try{this.focus()}catch(a){}})}catch(c){}}p.css({opacity:+J.opacity,cursor:J.overlayClose?"pointer":"auto"}).show();J.w=X(J.initialWidth,"x");J.h=X(J.initialHeight,"y");U.position(0);if(n){y.bind("resize."+o+" scroll."+o,function(){p.css({width:y.width(),height:y.height(),top:y.scrollTop(),left:y.scrollLeft()})}).trigger("resize."+o)}$(g,J.onOpen);I.add(C).hide();H.html(J.close).show()}U.load(true)}}function _(){var a,b=f+"Slideshow_",c="click."+f,d,e,g;if(J.slideshow&&x[1]){d=function(){E.text(J.slideshowStop).unbind(c).bind(i,function(){if(P<x.length-1||J.loop){a=setTimeout(U.next,J.slideshowSpeed)}}).bind(h,function(){clearTimeout(a)}).one(c+" "+j,e);q.removeClass(b+"off").addClass(b+"on");a=setTimeout(U.next,J.slideshowSpeed)};e=function(){clearTimeout(a);E.text(J.slideshowStart).unbind([i,h,j,c].join(" ")).one(c,d);q.removeClass(b+"on").addClass(b+"off")};if(J.slideshowAuto){d()}else{e()}}}function $(b,c){if(c){c.call(O)}a.event.trigger(b)}function Z(b){for(var c in b){if(a.isFunction(b[c])&&c.substring(0,2)!=="on"){b[c]=b[c].call(O)}}b.rel=b.rel||O.rel||"nofollow";b.href=a.trim(b.href||a(O).attr("href"));b.title=b.title||O.title}function Y(a){return J.photo||/\.(gif|png|jpg|jpeg|bmp)(?:\?([^#]*))?(?:#(\.*))?$/i.test(a)}function X(a,b){b=b==="x"?y.width():y.height();return typeof a==="string"?Math.round(/%/.test(a)?b/100*parseInt(a,10):parseInt(a,10)):a}function W(c,d){var e=b.createElement("div");if(c){e.id=f+c}e.style.cssText=d||false;return a(e)}var d={transition:"elastic",speed:300,width:false,initialWidth:"600",innerWidth:false,maxWidth:false,height:false,initialHeight:"450",innerHeight:false,maxHeight:false,scalePhotos:true,scrolling:true,inline:false,html:false,iframe:false,fastIframe:true,photo:false,href:false,title:false,rel:false,opacity:.9,preloading:true,current:"image {current} of {total}",previous:"previous",next:"next",close:"close",open:false,returnFocus:true,loop:true,slideshow:false,slideshowAuto:true,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",onOpen:false,onLoad:false,onComplete:false,onCleanup:false,onClosed:false,overlayClose:true,escKey:true,arrowKey:true},e="colorbox",f="cbox",g=f+"_open",h=f+"_load",i=f+"_complete",j=f+"_cleanup",k=f+"_closed",l=f+"_purge",m=a.browser.msie&&!a.support.opacity,n=m&&a.browser.version<7,o=f+"_IE6",p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J={},K,L,M,N,O,P,Q,R,S,T=false,U,V=f+"Element";U=a.fn[e]=a[e]=function(b,c){var f=this,g;if(!f[0]&&f.selector){return f}b=b||{};if(c){b.onComplete=c}if(!f[0]||f.selector===undefined){f=a("<a/>");b.open=true}f.each(function(){a.data(this,e,a.extend({},a.data(this,e)||d,b));a(this).addClass(V)});g=b.open;if(a.isFunction(g)){g=g.call(f)}if(g){ba(f[0])}return f};U.init=function(){y=a(c);q=W().attr({id:e,"class":m?f+(n?"IE6":"IE"):""});p=W("Overlay",n?"position:absolute":"").hide();r=W("Wrapper");s=W("Content").append(z=W("LoadedContent","width:0; height:0; overflow:hidden"),B=W("LoadingOverlay").add(W("LoadingGraphic")),C=W("Title"),D=W("Current"),F=W("Next"),G=W("Previous"),E=W("Slideshow").bind(g,_),H=W("Close"));r.append(W().append(W("TopLeft"),t=W("TopCenter"),W("TopRight")),W(false,"clear:left").append(u=W("MiddleLeft"),s,v=W("MiddleRight")),W(false,"clear:left").append(W("BottomLeft"),w=W("BottomCenter"),W("BottomRight"))).children().children().css({"float":"left"});A=W(false,"position:absolute; width:9999px; visibility:hidden; display:none");a("body").prepend(p,q.append(r,A));s.children().hover(function(){a(this).addClass("hover")},function(){a(this).removeClass("hover")}).addClass("hover");K=t.height()+w.height()+s.outerHeight(true)-s.height();L=u.width()+v.width()+s.outerWidth(true)-s.width();M=z.outerHeight(true);N=z.outerWidth(true);q.css({"padding-bottom":K,"padding-right":L}).hide();F.click(function(){U.next()});G.click(function(){U.prev()});H.click(function(){U.close()});I=F.add(G).add(D).add(E);s.children().removeClass("hover");a("."+V).live("click",function(a){if(!(a.button!==0&&typeof a.button!=="undefined"||a.ctrlKey||a.shiftKey||a.altKey)){a.preventDefault();ba(this)}});p.click(function(){if(J.overlayClose){U.close()}});a(b).bind("keydown."+f,function(a){var b=a.keyCode;if(R&&J.escKey&&b===27){a.preventDefault();U.close()}if(R&&J.arrowKey&&x[1]){if(b===37){a.preventDefault();G.click()}else if(b===39){a.preventDefault();F.click()}}})};U.remove=function(){q.add(p).remove();a("."+V).die("click").removeData(e).removeClass(V)};U.position=function(a,c){function g(a){t[0].style.width=w[0].style.width=s[0].style.width=a.style.width;B[0].style.height=B[1].style.height=s[0].style.height=u[0].style.height=v[0].style.height=a.style.height}var d,e=Math.max(b.documentElement.clientHeight-J.h-M-K,0)/2+y.scrollTop(),f=Math.max(y.width()-J.w-N-L,0)/2+y.scrollLeft();d=q.width()===J.w+N&&q.height()===J.h+M?0:a;r[0].style.width=r[0].style.height="9999px";q.dequeue().animate({width:J.w+N,height:J.h+M,top:e,left:f},{duration:d,complete:function(){g(this);S=false;r[0].style.width=J.w+N+L+"px";r[0].style.height=J.h+M+K+"px";if(c){c()}},step:function(){g(this)}})};U.resize=function(a){if(R){a=a||{};if(a.width){J.w=X(a.width,"x")-N-L}if(a.innerWidth){J.w=X(a.innerWidth,"x")}z.css({width:J.w});if(a.height){J.h=X(a.height,"y")-M-K}if(a.innerHeight){J.h=X(a.innerHeight,"y")}if(!a.innerHeight&&!a.height){var b=z.wrapInner("<div style='overflow:auto'></div>").children();J.h=b.height();b.replaceWith(b.children())}z.css({height:J.h});U.position(J.transition==="none"?0:J.speed)}};U.prep=function(b){function h(b){U.position(b,function(){var b,d,g,h,j=x.length,k,n;if(!R){return}n=function(){B.hide();$(i,J.onComplete)};if(m){if(Q){z.fadeIn(100)}}C.html(J.title).add(z).show();if(j>1){if(typeof J.current==="string"){D.html(J.current.replace(/\{current\}/,P+1).replace(/\{total\}/,j)).show()}F[J.loop||P<j-1?"show":"hide"]().html(J.next);G[J.loop||P?"show":"hide"]().html(J.previous);b=P?x[P-1]:x[j-1];g=P<j-1?x[P+1]:x[0];if(J.slideshow){E.show()}if(J.preloading){h=a.data(g,e).href||g.href;d=a.data(b,e).href||b.href;h=a.isFunction(h)?h.call(g):h;d=a.isFunction(d)?d.call(b):d;if(Y(h)){a("<img/>")[0].src=h}if(Y(d)){a("<img/>")[0].src=d}}}else{I.hide()}if(J.iframe){k=a("<iframe/>").addClass(f+"Iframe")[0];if(J.fastIframe){n()}else{a(k).load(n)}k.name=f+ +(new Date);k.src=J.href;if(!J.scrolling){k.scrolling="no"}if(m){k.frameBorder=0;k.allowTransparency="true"}a(k).appendTo(z).one(l,function(){k.src="//about:blank"})}else{n()}if(J.transition==="fade"){q.fadeTo(c,1,function(){q[0].style.filter=""})}else{q[0].style.filter=""}y.bind("resize."+f,function(){U.position(0)})})}function g(){J.h=J.h||z.height();J.h=J.mh&&J.mh<J.h?J.mh:J.h;return J.h}function d(){J.w=J.w||z.width();J.w=J.mw&&J.mw<J.w?J.mw:J.w;return J.w}if(!R){return}var c=J.transition==="none"?0:J.speed;y.unbind("resize."+f);z.remove();z=W("LoadedContent").html(b);z.hide().appendTo(A.show()).css({width:d(),overflow:J.scrolling?"auto":"hidden"}).css({height:g()}).prependTo(s);A.hide();a(Q).css({"float":"none"});if(n){a("select").not(q.find("select")).filter(function(){return this.style.visibility!=="hidden"}).css({visibility:"hidden"}).one(j,function(){this.style.visibility="inherit"})}if(J.transition==="fade"){q.fadeTo(c,0,function(){h(0)})}else{h(c)}};U.load=function(b){var c,d,g=U.prep;S=true;Q=false;O=x[P];if(!b){Z(a.extend(J,a.data(O,e)))}$(l);$(h,J.onLoad);J.h=J.height?X(J.height,"y")-M-K:J.innerHeight&&X(J.innerHeight,"y");J.w=J.width?X(J.width,"x")-N-L:J.innerWidth&&X(J.innerWidth,"x");J.mw=J.w;J.mh=J.h;if(J.maxWidth){J.mw=X(J.maxWidth,"x")-N-L;J.mw=J.w&&J.w<J.mw?J.w:J.mw}if(J.maxHeight){J.mh=X(J.maxHeight,"y")-M-K;J.mh=J.h&&J.h<J.mh?J.h:J.mh}c=J.href;B.show();if(J.inline){W().hide().insertBefore(a(c)[0]).one(l,function(){a(this).replaceWith(z.children())});g(a(c))}else if(J.iframe){g(" ")}else if(J.html){g(J.html)}else if(Y(c)){a(Q=new Image).addClass(f+"Photo").error(function(){J.title=false;g(W("Error").text("This image could not be loaded"))}).load(function(){var a;Q.onload=null;if(J.scalePhotos){d=function(){Q.height-=Q.height*a;Q.width-=Q.width*a};if(J.mw&&Q.width>J.mw){a=(Q.width-J.mw)/Q.width;d()}if(J.mh&&Q.height>J.mh){a=(Q.height-J.mh)/Q.height;d()}}if(J.h){Q.style.marginTop=Math.max(J.h-Q.height,0)/2+"px"}if(x[1]&&(P<x.length-1||J.loop)){Q.style.cursor="pointer";Q.onclick=function(){U.next()}}if(m){Q.style.msInterpolationMode="bicubic"}setTimeout(function(){g(Q)},1)});setTimeout(function(){Q.src=c},1)}else if(c){A.load(c,function(b,c,d){g(c==="error"?W("Error").text("Request unsuccessful: "+d.statusText):a(this).contents())})}};U.next=function(){if(!S&&x[1]&&(P<x.length-1||J.loop)){P=P<x.length-1?P+1:0;U.load()}};U.prev=function(){if(!S&&x[1]&&(P||J.loop)){P=P?P-1:x.length-1;U.load()}};U.close=function(){if(R&&!T){T=true;R=false;$(j,J.onCleanup);y.unbind("."+f+" ."+o);p.fadeTo(200,0);q.stop().fadeTo(300,0,function(){q.add(p).css({opacity:1,cursor:"auto"}).hide();$(l);z.remove();setTimeout(function(){T=false;$(k,J.onClosed)},1)})}};U.element=function(){return a(O)};U.settings=d;a(U.init)})(jQuery,document,this)
//Written by Nathan Faubion: http://n-son.com
//Use this or edit how you want, just give me
//some credit!
function jsScroller(o,w,h){var self=this;var list=o.getElementsByTagName("div");for(var i=0;i<list.length;i++){if(list[i].className.indexOf("Scroller-Container")>-1){o=list[i];}}
this._setPos=function(x,y){if(x<this.viewableWidth-this.totalWidth)
x=this.viewableWidth-this.totalWidth;if(x>0)x=0;if(y<this.viewableHeight-this.totalHeight)
y=this.viewableHeight-this.totalHeight;if(y>0)y=0;this._x=x;this._y=y;with(o.style){left=this._x+"px";top=this._y+"px";}};this.reset=function(){this.content=o;this.totalHeight=o.offsetHeight;this.totalWidth=o.offsetWidth;this._x=0;this._y=0;with(o.style){left="0px";top="0px";}};this.scrollBy=function(x,y){this._setPos(this._x+x,this._y+y);};this.scrollTo=function(x,y){this._setPos(-x,-y);};this.stopScroll=function(){if(this.scrollTimer)window.clearInterval(this.scrollTimer);};this.startScroll=function(x,y){this.stopScroll();this.scrollTimer=window.setInterval(function(){self.scrollBy(x,y);},40);};this.swapContent=function(c,w,h){o=c;var list=o.getElementsByTagName("div");for(var i=0;i<list.length;i++){if(list[i].className.indexOf("Scroller-Container")>-1){o=list[i];}}
if(w)this.viewableWidth=w;if(h)this.viewableHeight=h;this.reset();};this.content=o;this.viewableWidth=w;this.viewableHeight=h;this.totalWidth=o.offsetWidth;this.totalHeight=o.offsetHeight;this.scrollTimer=null;this.reset();};
//Written by Nathan Faubion: http://n-son.com
//Use this or edit how you want, just give me
//some credit!
function jsScrollbar(o,s,a,ev){var self=this;this.reset=function(){this._parent=o;this._src=s;this.auto=a?a:false;this.eventHandler=ev?ev:function(){};this._up=this._findComponent("Scrollbar-Up",this._parent);this._down=this._findComponent("Scrollbar-Down",this._parent);this._yTrack=this._findComponent("Scrollbar-Track",this._parent);this._yHandle=this._findComponent("Scrollbar-Handle",this._yTrack);this._trackTop=findOffsetTop(this._yTrack);this._trackHeight=this._yTrack.offsetHeight;this._handleHeight=this._yHandle.offsetHeight;this._x=0;this._y=0;this._scrollDist=5;this._scrollTimer=null;this._selectFunc=null;this._grabPoint=null;this._tempTarget=null;this._tempDistX=0;this._tempDistY=0;this._disabled=false;this._ratio=(this._src.totalHeight-this._src.viewableHeight)/(this._trackHeight-this._handleHeight);this._yHandle.ondragstart=function(){return false;};this._yHandle.onmousedown=function(){return false;};this._addEvent(this._src.content,"mousewheel",this._scrollbarWheel);this._removeEvent(this._parent,"mousedown",this._scrollbarClick);this._addEvent(this._parent,"mousedown",this._scrollbarClick);this._src.reset();with(this._yHandle.style){top="0px";left="0px";}
this._moveContent();if(this._src.totalHeight<this._src.viewableHeight){this._disabled=true;this._yHandle.style.visibility="hidden";if(this.auto)this._parent.style.visibility="hidden";}else{this._disabled=false;this._yHandle.style.visibility="visible";this._parent.style.visibility="visible";}};this._addEvent=function(o,t,f){if(o.addEventListener)o.addEventListener(t,f,false);else if(o.attachEvent)o.attachEvent('on'+t,f);else o['on'+t]=f;};this._removeEvent=function(o,t,f){if(o.removeEventListener)o.removeEventListener(t,f,false);else if(o.detachEvent)o.detachEvent('on'+t,f);else o['on'+t]=null;};this._findComponent=function(c,o){var kids=o.childNodes;for(var i=0;i<kids.length;i++){if(kids[i].className&&kids[i].className==c){return kids[i];}}};function findOffsetTop(o){var t=0;if(o.offsetParent){while(o.offsetParent){t+=o.offsetTop;o=o.offsetParent;}}
return t;};this._scrollbarClick=function(e){if(self._disabled)return false;e=e?e:event;if(!e.target)e.target=e.srcElement;if(e.target.className.indexOf("Scrollbar-Up")>-1)self._scrollUp(e);else if(e.target.className.indexOf("Scrollbar-Down")>-1)self._scrollDown(e);else if(e.target.className.indexOf("Scrollbar-Track")>-1)self._scrollTrack(e);else if(e.target.className.indexOf("Scrollbar-Handle")>-1)self._scrollHandle(e);self._tempTarget=e.target;self._selectFunc=document.onselectstart;document.onselectstart=function(){return false;};self.eventHandler(e.target,"mousedown");self._addEvent(document,"mouseup",self._stopScroll,false);return false;};this._scrollbarDrag=function(e){e=e?e:event;var t=parseInt(self._yHandle.style.top);var v=e.clientY+document.body.scrollTop-self._trackTop;with(self._yHandle.style){if(v>=self._trackHeight-self._handleHeight+self._grabPoint)
top=self._trackHeight-self._handleHeight+"px";else if(v<=self._grabPoint)top="0px";else top=v-self._grabPoint+"px";self._y=parseInt(top);}
self._moveContent();};this._scrollbarWheel=function(e){e=e?e:event;var dir=0;if(e.wheelDelta>=120)dir=-1;if(e.wheelDelta<=-120)dir=1;self.scrollBy(0,dir*20);e.returnValue=false;};this._startScroll=function(x,y){this._tempDistX=x;this._tempDistY=y;this._scrollTimer=window.setInterval(function(){self.scrollBy(self._tempDistX,self._tempDistY);},40);};this._stopScroll=function(){self._removeEvent(document,"mousemove",self._scrollbarDrag,false);self._removeEvent(document,"mouseup",self._stopScroll,false);if(self._selectFunc)document.onselectstart=self._selectFunc;else document.onselectstart=function(){return true;};if(self._scrollTimer)window.clearInterval(self._scrollTimer);self.eventHandler(self._tempTarget,"mouseup");};this._scrollUp=function(e){this._startScroll(0,-this._scrollDist);};this._scrollDown=function(e){this._startScroll(0,this._scrollDist);};this._scrollTrack=function(e){var curY=e.clientY+document.body.scrollTop;this._scroll(0,curY-this._trackTop-this._handleHeight/2);};this._scrollHandle=function(e){var curY=e.clientY+document.body.scrollTop;this._grabPoint=curY-findOffsetTop(this._yHandle);this._addEvent(document,"mousemove",this._scrollbarDrag,false);};this._scroll=function(x,y){if(y>this._trackHeight-this._handleHeight)
y=this._trackHeight-this._handleHeight;if(y<0)y=0;this._yHandle.style.top=y+"px";this._y=y;this._moveContent();};this._moveContent=function(){this._src.scrollTo(0,Math.round(this._y*this._ratio));};this.scrollBy=function(x,y){this._scroll(0,(-this._src._y+y)/this._ratio);};this.scrollTo=function(x,y){this._scroll(0,y/this._ratio);};this.swapContent=function(o,w,h){this._removeEvent(this._src.content,"mousewheel",this._scrollbarWheel,false);this._src.swapContent(o,w,h);this.reset();};this.reset();};
/**
 * jQuery-Plugin "preloadCssImages"
 * by Scott Jehl, scott@filamentgroup.com
 * http://www.filamentgroup.com
 * reference article: http://www.filamentgroup.com/lab/update_automatically_preload_images_from_css_with_jquery/
 * demo page: http://www.filamentgroup.com/examples/preloadImages/index_v2.php
 * Copyright (c) 2008 Filament Group, Inc
 * Dual licensed under the MIT (filamentgroup.com/examples/mit-license.txt) and GPL (filamentgroup.com/examples/gpl-license.txt) licenses.
 *
 * Version: 5.0, 10.31.2008
 */
jQuery.preloadCssImages=function(a){function i(b,c){var f=false,g=[],j=[],k;var l=b.length;while(l--){var m="";if(c&&c[l]){k=c[l]}else{var n=b[l].href?b[l].href:"window.location.href";var o=n.split("/");o.pop();k=o.join("/");if(k){k+="/"}}if(b[l].cssRules||b[l].rules){e=b[l].cssRules?b[l].cssRules:b[l].rules;var p=e.length;while(p--){if(e[p].style&&e[p].style.cssText){var q=e[p].style.cssText;if(q.toLowerCase().indexOf("url")!=-1){m+=q}}else if(e[p].styleSheet){g.push(e[p].styleSheet);f=true}}}var r=m.match(/[^\("]+\.(gif|jpg|jpeg|png)/g);if(r){var s=r.length;while(s--){var t=r[s].charAt(0)=="/"||r[s].match("://")?r[s]:k+r[s];if(jQuery.inArray(t,d)==-1){d.push(t)}}}if(!f&&b[l].imports&&b[l].imports.length){for(var u=0,v=b[l].imports.length;u<v;u++){var w=b[l].imports[u].href;w=w.split("/");w.pop();w=w.join("/");if(w){w+="/"}var x=w.charAt(0)=="/"||w.match("://")?w:k+w;j.push(x);g.push(b[l].imports[u])}}}if(g.length){i(g,j);return false}var y=a.simultaneousCacheLoading;while(y--){setTimeout(h,y)}}function h(){if(d&&d.length&&d[c]){var b=new Image;b.src=d[c];if(!b.complete){jQuery(b).bind("error load onreadystatechange",g)}else{g()}f=setTimeout(g,a.errorDelay)}}function g(){clearTimeout(f);if(d&&d.length&&d[c]){c++;if(a.statusTextEl){var b=d[c]?"Now Loading: <span>"+d[c].split("/")[d[c].split("/").length-1]:"Loading complete";jQuery(a.statusTextEl).html("numLoaded "+c+" of numTotal "+d.length+" | Percent Loaded "+(c/d.length*100).toFixed(0)+"% | Current Image: "+b)}if(a.statusBarEl){var e=jQuery(a.statusBarEl).width();jQuery(a.statusBarEl).css("background-position",-(e-(e*c/d.length).toFixed(0))+"px 50%")}h()}}a=jQuery.extend({statusTextEl:null,statusBarEl:null,errorDelay:999,simultaneousCacheLoading:2},a);var b=[],c=0,d=[],e,f;i(document.styleSheets);return d}
/*
the distillery
*/
function initScrollBar(){scroller=new jsScroller(document.getElementById("Scroller"),380,320);scrollbar=new jsScrollbar(document.getElementById("Scrollbar-Container"),scroller,true,scrollbarEvent)}function scrollbarEvent(a,b){if(b=="mousedown"){if(a.className=="Scrollbar-Track"){a.style.backgroundImage="url(images/common/bg-scrollbar.png)"}else{a.style.backgroundImage="url(images/common/bg-opacity88-3.png)"}}else{if(a.className=="Scrollbar-Track"){a.style.backgroundImage="url(images/common/bg-scrollbar.png)"}else{a.style.backgroundImage="url(images/common/bg-opacity64-3.png)"}}}var scroller=null;var scrollbar=null;var scrollcontent=".Scroller-Container";$(document).ready(function(){function g(a,d,e,f){$.ajax({url:a,cache:false,success:function(a){b.addClass("active").not(d).removeClass("active").removeAttr("class");c.empty().append($(innerShiv(a,false))).hide()},complete:function(){c.fadeTo("slow",1)}})}function f(b){var d="#mainnav a[href=#"+b+"]";var f="pages/"+b+".php";if(b!=""){if(a==""){a=c.html()}g(f,d,b);if(".bg-"+b==e){}if("."+b!=e){$(e).fadeTo("slow",0);$(".bg-"+b).fadeTo("slow",1);e=".bg-"+b}}else if(a!=""){var h="pages/"+a+".php";var i="#mainnav a[href=#"+a+"]";$(".bg-"+a).fadeTo("slow",1);g(h,i,"")}}var a="building";var b=$("#mainnav a");var c=$("#ajax_content");var d=$(".bg-building, .bg-history, .bg-area, .bg-standard-signature, .bg-amenities, .bg-suites-courtyard,.bg-suites-tower,.bg-suites-penthouse,.bg-suites-clear-spirit, .bg-team, .bg-contact, .bg-features-flooring, .bg-features-green, .bg-team-cityscape, .bg-team-dundee-realty, .bg-team-architects-alliance, .bg-team-chase-aja, .bg-news, .bg-penthouses, .bg-team-insite");d.hide();var e=".bg-building";b.click(function(){var a=$(this).parent().hasClass("register");var b=$(this).parent().hasClass("webcam");if(!a&&!b){var c=$(this).attr("href");c=c.replace(/^.*#/,"");$.history.load(c);return false}});$.history.init(f);$.preloadCssImages()})
	

	
	

 


		
		

