function printEmail(a,b,c,d){var e="@",f=".";document.write("<a href='mailto:"+a+e+b+f+c+"' title='Send us an e-mail'>"),d===undefined?document.write(a+e+b+f+c):document.write(d),document.write("</a>")}$(document).ready(function(){$("#latest-tweets div").tweet({count:3,username:["avisi_it","avisi_atlassian"],loading_text:"Loading tweets...",template:"<a class='author' href='{user_url}' target='_blank'>{screen_name}:</a>{text}"})}),function(a){a.flexslider=function(b,c){var d=b;d.init=function(){d.vars=a.extend({},a.flexslider.defaults,c),d.data("flexslider",!0),d.container=a(".slides",d),d.slides=a(".slides > li",d),d.count=d.slides.length,d.animating=!1,d.currentSlide=d.vars.slideToStart,d.animatingTo=d.currentSlide,d.atEnd=d.currentSlide==0?!0:!1,d.eventType="ontouchstart"in document.documentElement?"touchstart":"click",d.cloneCount=0,d.cloneOffset=0,d.vars.controlsContainer!=""&&(d.controlsContainer=a(d.vars.controlsContainer).eq(a(".slides").index(d.container)),d.containerExists=d.controlsContainer.length>0),d.vars.manualControls!=""&&(d.manualControls=a(d.vars.manualControls,d.containerExists?d.controlsContainer:d),d.manualExists=d.manualControls.length>0),d.vars.randomize&&(d.slides.sort(function(){return Math.round(Math.random())-.5}),d.container.empty().append(d.slides)),d.vars.animation.toLowerCase()=="slide"?(d.css({overflow:"hidden"}),d.vars.animationLoop&&(d.cloneCount=2,d.cloneOffset=1,d.container.append(d.slides.filter(":first").clone().addClass("clone")).prepend(d.slides.filter(":last").clone().addClass("clone"))),d.container.width((d.count+d.cloneCount)*d.width()+2e3),d.newSlides=a(".slides > li",d),setTimeout(function(){d.newSlides.width(d.width()).css({"float":"left"}).show()},100),d.container.css({marginLeft:-1*(d.currentSlide+d.cloneOffset)*d.width()+"px"})):d.slides.css({width:"100%","float":"left",marginRight:"-100%"}).eq(d.currentSlide).fadeIn(400);if(d.vars.controlNav){if(d.manualExists)d.controlNav=d.manualControls;else{var b=a('<ol class="flex-control-nav"></ol>'),e=1;for(var f=0;f<d.count;f++)b.append("<li><a>"+e+"</a></li>"),e++;d.containerExists?(a(d.controlsContainer).append(b),d.controlNav=a(".flex-control-nav li a",d.controlsContainer)):(d.append(b),d.controlNav=a(".flex-control-nav li a",d))}d.controlNav.eq(d.currentSlide).addClass("active"),d.controlNav.bind(d.eventType,function(b){b.preventDefault(),a(this).hasClass("active")||d.flexAnimate(d.controlNav.index(a(this)),d.vars.pauseOnAction)})}if(d.vars.directionNav){var g=a('<ul class="flex-direction-nav"><li><a class="prev" href="#">'+d.vars.prevText+'</a></li><li><a class="next" href="#">'+d.vars.nextText+"</a></li></ul>");d.containerExists?(a(d.controlsContainer).append(g),d.directionNav=a(".flex-direction-nav li a",d.controlsContainer)):(d.append(g),d.directionNav=a(".flex-direction-nav li a",d)),d.vars.animationLoop||(d.currentSlide==0?d.directionNav.filter(".prev").addClass("disabled"):d.currentSlide==d.count-1&&d.directionNav.filter(".next").addClass("disabled")),d.directionNav.bind(d.eventType,function(b){b.preventDefault();var c=a(this).hasClass("next")?d.getTarget("next"):d.getTarget("prev");d.canAdvance(c)&&d.flexAnimate(c,d.vars.pauseOnAction)})}d.vars.keyboardNav&&a("ul.slides").length==1&&a(document).keyup(function(a){if(d.animating)return;if(a.keyCode!=39&&a.keyCode!=37)return;if(a.keyCode==39)var b=d.getTarget("next");else if(a.keyCode==37)var b=d.getTarget("prev");d.canAdvance(b)&&d.flexAnimate(b,d.vars.pauseOnAction)}),d.vars.slideshow&&(d.vars.pauseOnHover&&d.vars.slideshow&&d.hover(function(){d.pause()},function(){d.resume()}),d.animatedSlides=setInterval(d.animateSlides,d.vars.slideshowSpeed));if(d.vars.pausePlay){var h=a('<div class="flex-pauseplay"><span></span></div>');d.containerExists?(d.controlsContainer.append(h),d.pausePlay=a(".flex-pauseplay span",d.controlsContainer)):(d.append(h),d.pausePlay=a(".flex-pauseplay span",d));var i=d.vars.slideshow?"pause":"play";d.pausePlay.addClass(i).text(i=="pause"?d.vars.pauseText:d.vars.playText),d.pausePlay.click(function(b){b.preventDefault(),a(this).hasClass("pause")?d.pause():d.resume()})}d.vars.touchSwipe&&"ontouchstart"in document.documentElement&&d.each(function(){function c(){this.removeEventListener("touchmove",e),a=null,isMoving=!1}function e(e){if(isMoving){var f=e.touches[0].pageX,g=a-f;if(Math.abs(g)>=b){c();var h=g>0?d.getTarget("next"):d.getTarget("prev");d.canAdvance(h)&&d.flexAnimate(h,d.vars.pauseOnAction)}}}function f(b){b.touches.length==1&&(a=b.touches[0].pageX,isMoving=!0,this.addEventListener("touchmove",e,!1))}var a,b=20;isMoving=!1,"ontouchstart"in document.documentElement&&this.addEventListener("touchstart",f,!1)}),d.vars.animation.toLowerCase()=="slide"&&(d.sliderTimer,a(window).resize(function(){d.newSlides.width(d.width()),d.container.width((d.count+d.cloneCount)*d.width()+2e3),clearTimeout(d.sliderTimer),d.sliderTimer=setTimeout(function(){d.flexAnimate(d.currentSlide)},300)})),d.vars.start(d)},d.flexAnimate=function(a,b){d.animating||(d.animating=!0,d.animatingTo=a,d.vars.before(d),b&&d.pause(),d.vars.controlNav&&d.controlNav.removeClass("active").eq(a).addClass("active"),d.atEnd=a==0||a==d.count-1?!0:!1,!d.vars.animationLoop&&d.vars.directionNav&&(a==0?d.directionNav.removeClass("disabled").filter(".prev").addClass("disabled"):a==d.count-1?d.directionNav.removeClass("disabled").filter(".next").addClass("disabled"):d.directionNav.removeClass("disabled")),!d.vars.animationLoop&&a==d.count-1&&(d.pause(),d.vars.end(d)),d.vars.animation.toLowerCase()=="slide"?(d.currentSlide==0&&a==d.count-1&&d.vars.animationLoop?d.slideString="0px":d.currentSlide==d.count-1&&a==0&&d.vars.animationLoop?d.slideString=-1*(d.count+1)*d.slides.filter(":first").width()+"px":d.slideString=-1*(a+d.cloneOffset)*d.slides.filter(":first").width()+"px",d.container.animate({marginLeft:d.slideString},d.vars.animationDuration,function(){d.currentSlide==0&&a==d.count-1&&d.vars.animationLoop?d.container.css({marginLeft:-1*d.count*d.slides.filter(":first").width()+"px"}):d.currentSlide==d.count-1&&a==0&&d.vars.animationLoop&&d.container.css({marginLeft:-1*d.slides.filter(":first").width()+"px"}),d.animating=!1,d.currentSlide=a,d.vars.after(d)})):(d.slides.eq(d.currentSlide).fadeOut(d.vars.animationDuration),d.slides.eq(a).fadeIn(d.vars.animationDuration,function(){d.animating=!1,d.currentSlide=a,d.vars.after(d)})))},d.animateSlides=function(){if(!d.animating){var a=d.currentSlide==d.count-1?0:d.currentSlide+1;d.flexAnimate(a)}},d.pause=function(){clearInterval(d.animatedSlides),d.vars.pausePlay&&d.pausePlay.removeClass("pause").addClass("play").text(d.vars.playText)},d.resume=function(){d.animatedSlides=setInterval(d.animateSlides,d.vars.slideshowSpeed),d.vars.pausePlay&&d.pausePlay.removeClass("play").addClass("pause").text(d.vars.pauseText)},d.canAdvance=function(a){return!d.vars.animationLoop&&d.atEnd?d.currentSlide==0&&a==d.count-1&&d.direction!="next"?!1:d.currentSlide==d.count-1&&a==0&&d.direction=="next"?!1:!0:!0},d.getTarget=function(a){return d.direction=a,a=="next"?d.currentSlide==d.count-1?0:d.currentSlide+1:d.currentSlide==0?d.count-1:d.currentSlide-1},d.init()},a.flexslider.defaults={animation:"fade",slideshow:!0,slideshowSpeed:7e3,animationDuration:600,directionNav:!0,controlNav:!0,keyboardNav:!0,touchSwipe:!0,prevText:"Previous",nextText:"Next",pausePlay:!1,pauseText:"Pause",playText:"Play",randomize:!1,slideToStart:0,animationLoop:!0,pauseOnAction:!0,pauseOnHover:!1,controlsContainer:"",manualControls:"",start:function(){},before:function(){},after:function(){},end:function(){}},a.fn.flexslider=function(b){return this.each(function(){a(this).find(".slides li").length==1?a(this).find(".slides li").fadeIn(400):a(this).data("flexslider")!=1&&new a.flexslider(a(this),b)})}}(jQuery),function(a){a.fn.tweet=function(b){function e(a,b){if(typeof a=="string"){var c=a;for(var d in b){var e=b[d];c=c.replace(new RegExp("{"+d+"}","g"),e===null?"":e)}return c}return a(b)}function f(b,c){return function(){var d=[];return this.each(function(){d.push(this.replace(b,c))}),a(d)}}function g(a){return a.replace(/</g,"&lt;").replace(/>/g,"^&gt;")}function h(a,b){return a.replace(d,function(a){var c=/^[a-z]+:/i.test(a)?a:"http://"+a,d=a;for(var e=0;e<b.length;++e){var f=b[e];if(f.url==c&&f.expanded_url){c=f.expanded_url,d=f.display_url;break}}return'<a href="'+g(c)+'">'+g(d)+"</a>"})}function i(a){return Date.parse(a.replace(/^([a-z]{3})( [a-z]{3} \d\d?)(.*)( \d{4})$/i,"$1,$2$4$3"))}function j(a){var b=arguments.length>1?arguments[1]:new Date,c=parseInt((b.getTime()-a)/1e3,10),d="";return c<1?d="just now":c<60?d=c+" seconds ago":c<120?d="a minute ago":c<2700?d=parseInt(c/60,10).toString()+" minutes ago":c<7200?d="an hour ago":c<86400?d=""+parseInt(c/3600,10).toString()+" hours ago":c<172800?d="a day ago":d=parseInt(c/86400,10).toString()+" days ago","about "+d}function k(a){return a.match(/^(@([A-Za-z0-9-_]+)) .*/i)?c.auto_join_text_reply:a.match(d)?c.auto_join_text_url:a.match(/^((\w+ed)|just) .*/im)?c.auto_join_text_ed:a.match(/^(\w*ing) .*/i)?c.auto_join_text_ing:c.auto_join_text_default}function l(){var a="https:"==document.location.protocol?"https:":"http:",b=c.fetch===null?c.count:c.fetch,d="&include_entities=1&callback=?";if(c.list)return a+"//"+c.twitter_api_url+"/1/"+c.username[0]+"/lists/"+c.list+"/statuses.json?page="+c.page+"&per_page="+b+d;if(c.favorites)return a+"//"+c.twitter_api_url+"/favorites/"+c.username[0]+".json?page="+c.page+"&count="+b+d;if(c.query===null&&c.username.length==1)return a+"//"+c.twitter_api_url+"/1/statuses/user_timeline.json?screen_name="+c.username[0]+"&count="+b+(c.retweets?"&include_rts=1":"")+"&page="+c.page+d;var e=c.query||"from:"+c.username.join(" OR from:");return a+"//"+c.twitter_search_url+"/search.json?&q="+encodeURIComponent(e)+"&rpp="+b+"&page="+c.page+d}function m(a,b){return b?"user"in a?a.user.profile_image_url_https:m(a,!1):a.profile_image_url||a.user.profile_image_url}function n(b){var d={};return d.item=b,d.source=b.source,d.screen_name=b.from_user||b.user.screen_name,d.avatar_size=c.avatar_size,d.avatar_url=m(b,document.location.protocol==="https:"),d.retweet=typeof b.retweeted_status!="undefined",d.tweet_time=i(b.created_at),d.join_text=c.join_text=="auto"?k(b.text):c.join_text,d.tweet_id=b.id_str,d.twitter_base="http://"+c.twitter_url+"/",d.user_url=d.twitter_base+d.screen_name,d.tweet_url=d.user_url+"/status/"+d.tweet_id,d.reply_url=d.twitter_base+"intent/tweet?in_reply_to="+d.tweet_id,d.retweet_url=d.twitter_base+"intent/retweet?tweet_id="+d.tweet_id,d.favorite_url=d.twitter_base+"intent/favorite?tweet_id="+d.tweet_id,d.retweeted_screen_name=d.retweet&&b.retweeted_status.user.screen_name,d.tweet_relative_time=j(d.tweet_time),d.entities=b.entities?(b.entities.urls||[]).concat(b.entities.media||[]):[],d.tweet_raw_text=d.retweet?"RT @"+d.retweeted_screen_name+" "+b.retweeted_status.text:b.text,d.tweet_text=a([h(d.tweet_raw_text,d.entities)]).linkUser().linkHash()[0],d.tweet_text_fancy=a([d.tweet_text]).makeHeart().capAwesome().capEpic()[0],d.user=e('<a class="tweet_user" href="{user_url}">{screen_name}</a>',d),d.join=c.join_text?e(' <span class="tweet_join">{join_text}</span> ',d):" ",d.avatar=d.avatar_size?e('<a class="tweet_avatar" href="{user_url}"><img src="{avatar_url}" height="{avatar_size}" width="{avatar_size}" alt="{screen_name}\'s avatar" title="{screen_name}\'s avatar" border="0"/></a>',d):"",d.time=e('<span class="tweet_time"><a href="{tweet_url}" title="view tweet on twitter">{tweet_relative_time}</a></span>',d),d.text=e('<span class="tweet_text">{tweet_text_fancy}</span>',d),d.reply_action=e('<a class="tweet_action tweet_reply" href="{reply_url}">reply</a>',d),d.retweet_action=e('<a class="tweet_action tweet_retweet" href="{retweet_url}">retweet</a>',d),d.favorite_action=e('<a class="tweet_action tweet_favorite" href="{favorite_url}">favorite</a>',d),d}var c=a.extend({username:null,list:null,favorites:!1,query:null,avatar_size:null,count:3,fetch:null,page:1,retweets:!0,intro_text:null,outro_text:null,join_text:null,auto_join_text_default:"i said,",auto_join_text_ed:"i",auto_join_text_ing:"i am",auto_join_text_reply:"i replied to",auto_join_text_url:"i was looking at",loading_text:null,refresh_interval:null,twitter_url:"twitter.com",twitter_api_url:"api.twitter.com",twitter_search_url:"search.twitter.com",template:"{avatar}{time}{join}{text}",comparator:function(a,b){return b.tweet_time-a.tweet_time},filter:function(a){return!0}},b),d=/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/gi;return a.extend({tweet:{t:e}}),a.fn.extend({linkUser:f(/(^|[\W])@(\w+)/gi,'$1<a href="http://'+c.twitter_url+'/$2">@$2</a>'),linkHash:f(/(?:^| )[\#]+([\w\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u00ff\u0600-\u06ff]+)/gi,' <a href="http://'+c.twitter_search_url+"/search?q=&tag=$1&lang=all"+(c.username&&c.username.length==1&&!c.list?"&from="+c.username.join("%2BOR%2B"):"")+'">#$1</a>'),capAwesome:f(/\b(awesome)\b/gi,'<span class="awesome">$1</span>'),capEpic:f(/\b(epic)\b/gi,'<span class="epic">$1</span>'),makeHeart:f(/(&lt;)+[3]/gi,"<tt class='heart'>&#x2665;</tt>")}),this.each(function(b,d){var f=a('<ul class="tweet_list">'),g='<p class="tweet_intro">'+c.intro_text+"</p>",h='<p class="tweet_outro">'+c.outro_text+"</p>",i=a('<p class="loading">'+c.loading_text+"</p>");c.username&&typeof c.username=="string"&&(c.username=[c.username]),a(d).bind("tweet:load",function(){c.loading_text&&a(d).empty().append(i),a.getJSON(l(),function(b){a(d).empty().append(f),c.intro_text&&f.before(g),f.empty();var i=a.map(b.results||b,n);i=a.grep(i,c.filter).sort(c.comparator).slice(0,c.count),f.append(a.map(i,function(a){return"<li>"+e(c.template,a)+"</li>"}).join("")).children("li:first").addClass("tweet_first").end().children("li:odd").addClass("tweet_even").end().children("li:even").addClass("tweet_odd"),c.outro_text&&f.after(h),a(d).trigger("loaded").trigger(i.length===0?"empty":"full"),c.refresh_interval&&window.setTimeout(function(){a(d).trigger("tweet:load")},1e3*c.refresh_interval)})}).trigger("tweet:load")})}}(jQuery),!function(a){function d(){var a=this,c=setTimeout(function(){a.$element.unbind(b),e.call(a)},500);this.$element.one(b,function(){clearTimeout(c),e.call(a)})}function e(a){this.$element.hide().trigger("hidden"),f.call(this)}function f(c){var d=this,e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.settings.backdrop){var f=a.support.transition&&e;this.$backdrop=a('<div class="modal-backdrop '+e+'" />').appendTo(document.body),this.settings.backdrop!="static"&&this.$backdrop.click(a.proxy(this.hide,this)),f&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),f?this.$backdrop.one(b,c):c()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(b,a.proxy(g,this)):g.call(this)):c&&c()}function g(){this.$backdrop.remove(),this.$backdrop=null}function h(){var b=this;this.isShown&&this.settings.keyboard?a(document).bind("keyup.modal",function(a){a.which==27&&b.hide()}):this.isShown||a(document).unbind("keyup.modal")}"use strict";var b;a(document).ready(function(){a.support.transition=function(){var a=document.body||document.documentElement,b=a.style,c=b.transition!==undefined||b.WebkitTransition!==undefined||b.MozTransition!==undefined||b.MsTransition!==undefined||b.OTransition!==undefined;return c}(),a.support.transition&&(b="TransitionEnd",a.browser.webkit?b="webkitTransitionEnd":a.browser.mozilla?b="transitionend":a.browser.opera&&(b="oTransitionEnd"))});var c=function(b,c){return this.settings=a.extend({},a.fn.modal.defaults,c),this.$element=a(b).delegate(".close","click.modal",a.proxy(this.hide,this)),this.settings.show&&this.show(),this};c.prototype={toggle:function(){return this[this.isShown?"hide":"show"]()},show:function(){var c=this;return this.isShown=!0,this.$element.trigger("show"),h.call(this),f.call(this,function(){var d=a.support.transition&&c.$element.hasClass("fade");c.$element.appendTo(document.body).show(),d&&c.$element[0].offsetWidth,c.$element.addClass("in"),d?c.$element.one(b,function(){c.$element.trigger("shown")}):c.$element.trigger("shown")}),this},hide:function(b){b&&b.preventDefault();if(!this.isShown)return this;var c=this;return this.isShown=!1,h.call(this),this.$element.trigger("hide").removeClass("in"),a.support.transition&&this.$element.hasClass("fade")?d.call(this):e.call(this),this}},a.fn.modal=function(b){var d=this.data("modal");return d?b===!0?d:(typeof b=="string"?d[b]():d&&d.toggle(),this):(typeof b=="string"&&(b={show:/show|toggle/.test(b)}),this.each(function(){a(this).data("modal",new c(this,b))}))},a.fn.modal.Modal=c,a.fn.modal.defaults={backdrop:!1,keyboard:!1,show:!1},a(document).ready(function(){a("body").delegate("[data-controls-modal]","click",function(b){b.preventDefault();var c=a(this).data("show",!0);a("#"+c.attr("data-controls-modal")).modal(c.data())})})}(window.jQuery||window.ender),!function(a){function d(a,b,c){return typeof a=="function"?a.apply(b,c):a}"use strict";var b;a(document).ready(function(){a.support.transition=function(){var a=document.body||document.documentElement,b=a.style,c=b.transition!==undefined||b.WebkitTransition!==undefined||b.MozTransition!==undefined||b.MsTransition!==undefined||b.OTransition!==undefined;return c}(),a.support.transition&&(b="TransitionEnd",a.browser.webkit?b="webkitTransitionEnd":a.browser.mozilla?b="transitionend":a.browser.opera&&(b="oTransitionEnd"))});var c=function(b,c){this.$element=a(b),this.options=c,this.enabled=!0,this.fixTitle()};c.prototype={show:function(){var b,c,e,f,g,h;if(this.hasContent()&&this.enabled){g=this.tip(),this.setContent(),this.options.animate&&g.addClass("fade"),g.remove().css({top:0,left:0,display:"block"}).prependTo(document.body),b=a.extend({},this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight}),c=g[0].offsetWidth,e=g[0].offsetHeight,f=d(this.options.placement,this,[g[0],this.$element[0]]);switch(f){case"below":h={top:b.top+b.height+this.options.offset,left:b.left+b.width/2-c/2};break;case"above":h={top:b.top-e-this.options.offset,left:b.left+b.width/2-c/2};break;case"left":h={top:b.top+b.height/2-e/2,left:b.left-c-this.options.offset};break;case"right":h={top:b.top+b.height/2-e/2,left:b.left+b.width+this.options.offset}}g.css(h).addClass(f).addClass("in")}},setContent:function(){var a=this.tip();a.find(".twipsy-inner")[this.options.html?"html":"text"](this.getTitle()),a[0].className="twipsy"},hide:function(){function e(){d.remove()}var c=this,d=this.tip();d.removeClass("in"),a.support.transition&&this.$tip.hasClass("fade")?d.bind(b,e):e()},fixTitle:function(){var a=this.$element;(a.attr("title")||typeof a.attr("data-original-title")!="string")&&a.attr("data-original-title",a.attr("title")||"").removeAttr("title")},hasContent:function(){return this.getTitle()},getTitle:function(){var a,b=this.$element,c=this.options;return this.fixTitle(),typeof c.title=="string"?a=b.attr(c.title=="title"?"data-original-title":c.title):typeof c.title=="function"&&(a=c.title.call(b[0])),a=(""+a).replace(/(^\s*|\s*$)/,""),a||c.fallback},tip:function(){return this.$tip=this.$tip||a('<div class="twipsy" />').html(this.options.template)},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(){this[this.tip().hasClass("in")?"hide":"show"]()}},a.fn.twipsy=function(b){return a.fn.twipsy.initWith.call(this,b,c,"twipsy"),this},a.fn.twipsy.initWith=function(b,c,d){function i(e){var f=a.data(e,d);return f||(f=new c(e,a.fn.twipsy.elementOptions(e,b)),a.data(e,d,f)),f}function j(){var a=i(this);a.hoverState="in",b.delayIn==0?a.show():(a.fixTitle(),setTimeout(function(){a.hoverState=="in"&&a.show()},b.delayIn))}function k(){var a=i(this);a.hoverState="out",b.delayOut==0?a.hide():setTimeout(function(){a.hoverState=="out"&&a.hide()},b.delayOut)}var e,f,g,h;return b===!0?this.data(d):typeof b=="string"?(e=this.data(d),e&&e[b](),this):(b=a.extend({},a.fn[d].defaults,b),b.live||this.each(function(){i(this)}),b.trigger!="manual"&&(f=b.live?"live":"bind",g=b.trigger=="hover"?"mouseenter":"focus",h=b.trigger=="hover"?"mouseleave":"blur",this[f](g,j)[f](h,k)),this)},a.fn.twipsy.Twipsy=c,a.fn.twipsy.defaults={animate:!0,delayIn:0,delayOut:0,fallback:"",placement:"above",html:!1,live:!1,offset:0,title:"title",trigger:"hover",template:'<div class="twipsy-arrow"></div><div class="twipsy-inner"></div>'},a.fn.twipsy.rejectAttrOptions=["title"],a.fn.twipsy.elementOptions=function(b,c){var d=a(b).data(),e=a.fn.twipsy.rejectAttrOptions,f=e.length;while(f--)delete d[e[f]];return a.extend({},c,d)}}(window.jQuery||window.ender),$(document).ready(function(){function c(a){var c=$("#logo .active, #menu .active");c.removeClass("active"),c[0]===a[0]?b.addClass("active"):a.addClass("active"),b=c}function d(a,b){var c=[];for(var d=0;d<b.length;d++){var e=$(a[b[d]]);$.trim(e.val())===""&&c.push(e[0].name)}return c}function e(a){$(a).find(".error").removeClass("error")}function f(a,b){for(var c=0;c<b.length;c++){var d=$(a[b[c]]);d.parents(".clearfix").addClass("error")}}$("a[rel=twipsy]").twipsy({live:!0,placement:"below"});var a=500,b=$("#logo .active, #menu .active");$("#menu-contact, #menu-about").click(function(b){b.preventDefault(),c($(this));var d=$(this).attr("href"),e=$(d);if(!$(e).is(":visible")){var f=$(".drop-page:visible");f.length>0?f.slideUp(a,function(){e.slideDown(a)}):e.slideDown(a)}else e.slideUp(a)}),$(".flexslider").flexslider({animation:"slide",slideshow:!0,slideshowSpeed:7e3,animationDuration:500,directionNav:!1,controlsContainer:".flexslider-nav",slideToStart:0}),$(".submit-link").click(function(a){a.preventDefault(),$($(this).attr("href")).submit()}),$("#callback_form").submit(function(a){a.preventDefault(),e(this);var b=this,c=["name","telephone"],g=d(this,c);g.length>0?f(this,g):$.ajax({type:"POST",url:"contact",data:$(this).serialize(),success:function(){var a=$(b).siblings(".alert-message");a.show(),$(b).parents(".modal").bind("hidden",function(){a.hide()}),b.reset()},error:function(a){f(b,$.parseJSON(a.responseText).invalidFields)}})}),$("#audio-click").click(function(){$(this).find("audio")[0].play()})})
