/*ScrollTo 1.4.1*/
;(function($){var m=$.scrollTo=function(b,h,f){$(window).scrollTo(b,h,f)};m.defaults={axis:'xy',duration:parseFloat($.fn.jquery)>=1.3?0:1};m.window=function(b){return $(window).scrollable()};$.fn.scrollable=function(){return this.map(function(){var b=this,h=!b.nodeName||$.inArray(b.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!h)return b;var f=(b.contentWindow||b).document||b.ownerDocument||b;return $.browser.safari||f.compatMode=='BackCompat'?f.body:f.documentElement})};$.fn.scrollTo=function(l,j,a){if(typeof j=='object'){a=j;j=0}if(typeof a=='function')a={onAfter:a};if(l=='max')l=9e9;a=$.extend({},m.defaults,a);j=j||a.speed||a.duration;a.queue=a.queue&&a.axis.length>1;if(a.queue)j/=2;a.offset=n(a.offset);a.over=n(a.over);return this.scrollable().each(function(){var k=this,o=$(k),d=l,p,g={},q=o.is('html,body');switch(typeof d){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px)?$/.test(d)){d=n(d);break}d=$(d,this);case'object':if(d.is||d.style)p=(d=$(d)).offset()}$.each(a.axis.split(''),function(b,h){var f=h=='x'?'Left':'Top',i=f.toLowerCase(),c='scroll'+f,r=k[c],s=h=='x'?'Width':'Height';if(p){g[c]=p[i]+(q?0:r-o.offset()[i]);if(a.margin){g[c]-=parseInt(d.css('margin'+f))||0;g[c]-=parseInt(d.css('border'+f+'Width'))||0}g[c]+=a.offset[i]||0;if(a.over[i])g[c]+=d[s.toLowerCase()]()*a.over[i]}else g[c]=d[i];if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],u(s));if(!b&&a.queue){if(r!=g[c])t(a.onAfterFirst);delete g[c]}});t(a.onAfter);function t(b){o.animate(g,j,a.easing,b&&function(){b.call(this,l,a)})};function u(b){var h='scroll'+b;if(!q)return k[h];var f='client'+b,i=k.ownerDocument.documentElement,c=k.ownerDocument.body;return Math.max(i[h],c[h])-Math.min(i[f],c[f])}}).end()};function n(b){return typeof b=='object'?b:{top:b,left:b}}})(jQuery);
;(function($){var a='serialScroll',b='.'+a,c='bind',C=$[a]=function(b){$.scrollTo.window()[a](b)};C.defaults={duration:1e3,axis:'x',event:'click',start:0,step:1,lock:1,cycle:1,constant:1};$.fn[a]=function(y){y=$.extend({},C.defaults,y);var z=y.event,A=y.step,B=y.lazy;return this.each(function(){var j=y.target?this:document,k=$(y.target||this,j),l=k[0],m=y.items,o=y.start,p=y.interval,q=y.navigation,r;if(!B)m=w();if(y.force)t({},o);$(y.prev||[],j)[c](z,-A,s);$(y.next||[],j)[c](z,A,s);if(!l.ssbound)k[c]('prev'+b,-A,s)[c]('next'+b,A,s)[c]('goto'+b,t);if(p)k[c]('start'+b,function(e){if(!p){v();p=1;u()}})[c]('stop'+b,function(){v();p=0});k[c]('notify'+b,function(e,a){var i=x(a);if(i>-1)o=i});l.ssbound=1;if(y.jump)(B?k:w())[c](z,function(e){t(e,x(e.target))});if(q)q=$(q,j)[c](z,function(e){e.data=Math.round(w().length/q.length)*q.index(this);t(e,this)});function s(e){e.data+=o;t(e,this)};function t(e,a){if(!isNaN(a)){e.data=a;a=l}var c=e.data,n,d=e.type,f=y.exclude?w().slice(0,-y.exclude):w(),g=f.length,h=f[c],i=y.duration;if(d)e.preventDefault();if(p){v();r=setTimeout(u,y.interval)}if(!h){n=c<0?0:n=g-1;if(o!=n)c=n;else if(!y.cycle)return;else c=g-n-1;h=f[c]}if(!h||d&&o==c||y.lock&&k.is(':animated')||d&&y.onBefore&&y.onBefore.call(a,e,h,k,w(),c)===!1)return;if(y.stop)k.queue('fx',[]).stop();if(y.constant)i=Math.abs(i/A*(o-c));k.scrollTo(h,i,y).trigger('notify'+b,[c])};function u(){k.trigger('next'+b)};function v(){clearTimeout(r)};function w(){return $(m,l)};function x(a){if(!isNaN(a))return a;var b=w(),i;while((i=b.index(a))==-1&&a!=l)a=a.parentNode;return i}})}})(jQuery);


$.tabs = function(containerId, start) {var ON_CLASS = 'on';var id = '#' + containerId;var i = (typeof start == "number") ? start - 1 : 0;$(id + '>div:lt(' + i + ')').add(id + '>div:gt(' + i + ')').hide();$(id + '>ul>li:nth-child(' + (i+1) + ')').addClass(ON_CLASS);$(id + '>ul>li>a').click(function() {$(this).load( function() { alert("Hello"); } );if (!$(this.parentNode).is('.' + ON_CLASS)) {var re = /([_\-\w]+$)/i;var target = $('#' + re.exec(this.href)[1]);if (target.size() > 0) {$(id + '>div:visible').hide();target.show();$(id + '>ul>li').removeClass(ON_CLASS);$(this.parentNode).addClass(ON_CLASS);} else {/*alert('There is no such container.');*/}}return false;});};

/* // Accordion 1.6 // */
;(function($) {$.ui = $.ui || {};$.fn.extend({accordion: function(options, data) {var args = Array.prototype.slice.call(arguments, 1);return this.each(function() {if (typeof options == "string") {var accordion = $.data(this, "ui-accordion");accordion[options].apply(accordion, args);} else if (!$(this).is(".ui-accordion"))$.data(this, "ui-accordion", new $.ui.accordion(this, options));});},activate: function(index) {return this.accordion("activate", index);}});$.ui.accordion = function(container, options) {this.options = options = $.extend({}, $.ui.accordion.defaults, options);this.element = container;$(container).addClass("ui-accordion");if ( options.navigation ) {var current = $(container).find("a").filter(options.navigationFilter);if ( current.length ) {if ( current.filter(options.header).length ) {options.active = current;} else {options.active = current.parent().parent().prev();current.addClass("current");}}}options.headers = $(container).find(options.header);options.active = findActive(options.headers, options.active);if ( options.fillSpace ) {var maxHeight = $(container).parent().height();options.headers.each(function() {maxHeight -= $(this).outerHeight();});var maxPadding = 0;options.headers.next().each(function() {maxPadding = Math.max(maxPadding, $(this).innerHeight() - $(this).height());}).height(maxHeight - maxPadding);} else if ( options.autoheight ) {var maxHeight = 0;options.headers.next().each(function() {maxHeight = Math.max(maxHeight, $(this).outerHeight());}).height(maxHeight);}options.headers.not(options.active || "").next().hide();options.active.parent().andSelf().addClass(options.selectedClass);if (options.event)$(container).bind((options.event) + ".ui-accordion", clickHandler);};$.ui.accordion.prototype = {activate: function(index) {clickHandler.call(this.element, {target: findActive( this.options.headers, index )[0]});},
enable: function() {this.options.disabled = false;},disable: function() {this.options.disabled = true;},destroy: function() {this.options.headers.next().css("display", "");if ( this.options.fillSpace || this.options.autoheight ) {this.options.headers.next().css("height", "");}$.removeData(this.element, "ui-accordion");$(this.element).removeClass("ui-accordion").unbind(".ui-accordion");}}
function scopeCallback(callback, scope) {return function() {return callback.apply(scope, arguments);};}function completed(cancel) {if (!$.data(this, "ui-accordion"))return;var instance = $.data(this, "ui-accordion");var options = instance.options;options.running = cancel ? 0 : --options.running;if ( options.running )return;if ( options.clearStyle ) {options.toShow.add(options.toHide).css({height: "",overflow: ""});}$(this).triggerHandler("change.ui-accordion", [options.data], options.change);}function toggle(toShow, toHide, data, clickedActive, down) {var options = $.data(this, "ui-accordion").options;options.toShow = toShow;options.toHide = toHide;options.data = data;var complete = scopeCallback(completed, this);options.running = toHide.size() == 0 ? toShow.size() : toHide.size();if ( options.animated ) {if ( !options.alwaysOpen && clickedActive ) {$.ui.accordion.animations[options.animated]({toShow: jQuery([]),toHide: toHide,complete: complete,down: down,autoheight: options.autoheight});} else {$.ui.accordion.animations[options.animated]({toShow: toShow,toHide: toHide,complete: complete,down: down,autoheight: options.autoheight});}} else {if ( !options.alwaysOpen && clickedActive ) {toShow.toggle();} else {toHide.hide();toShow.show();}complete(true);}}function clickHandler(event) {var options = $.data(this, "ui-accordion").options;if (options.disabled)return false;if ( !event.target && !options.alwaysOpen ) {options.active.parent().andSelf().toggleClass(options.selectedClass);var toHide = options.active.next(),data = {instance: this,options: options,newHeader: jQuery([]),oldHeader: options.active,newContent: jQuery([]),oldContent: toHide},toShow = options.active = $([]);toggle.call(this, toShow, toHide, data );return false;}var clicked = $(event.target);if ( clicked.parents(options.header).length )while ( !clicked.is(options.header) )clicked = clicked.parent();var clickedActive = clicked[0] == options.active[0];if (options.running || (options.alwaysOpen && clickedActive))return false;if (!clicked.is(options.header))return;options.active.parent().andSelf().toggleClass(options.selectedClass);if ( !clickedActive ) {clicked.parent().andSelf().addClass(options.selectedClass);}var toShow = clicked.next(),toHide = options.active.next(),data = {instance: this,options: options,newHeader: clicked,oldHeader: options.active,newContent: toShow,oldContent: toHide},down = options.headers.index( options.active[0] ) > options.headers.index( clicked[0] );options.active = clickedActive ? $([]) : clicked;toggle.call(this, toShow, toHide, data, clickedActive, down );return false;};function findActive(headers, selector) {return selector != undefined ? typeof selector == "number" ? headers.filter(":eq(" + selector + ")") : headers.not(headers.not(selector)) : selector === false ? $([]) : headers.filter(":eq(0)");}$.extend($.ui.accordion, {defaults: {selectedClass: "selected",alwaysOpen: true,animated: 'slide',event: "click",header: "a",autoheight: true,running: 0,navigationFilter: function() {return this.href.toLowerCase() == location.href.toLowerCase();}},animations: {slide: function(options, additions) {options = $.extend({easing: "swing",duration: 300}, options, additions);if ( !options.toHide.size() ) {options.toShow.animate({height: "show"}, options);return;}var hideHeight = options.toHide.height(),showHeight = options.toShow.height(),difference = showHeight / hideHeight;options.toShow.css({ height: 0, overflow: 'hidden' }).show();options.toHide.filter(":hidden").each(options.complete).end().filter(":visible").animate({height:"hide"},{step: function(now) {var current = (hideHeight - now) * difference;if ($.browser.msie || $.browser.opera) {current = Math.ceil(current);}options.toShow.height( current );},duration: options.duration,easing: options.easing,complete: function() {if ( !options.autoheight ) {options.toShow.css("height", "auto");}options.complete();}});},bounceslide: function(options) {this.slide(options, {easing: options.down ? "bounceout" : "swing",duration: options.down ? 1000 : 200});},easeslide: function(options) {this.slide(options, {easing: "easeinout",duration: 700})}}});})(jQuery);

/* jQuery (PNG Fix) v1.2 */
(function($) {$.fn.pngfix = function(options) {var elements = this;var settings = $.extend({imageFixSrc: false,sizingMethod: false }, options);if(!$.browser.msie || ($.browser.msie &&  $.browser.version >= 7)) {return(elements);}function setFilter(el, path, mode) {var fs = el.attr("filters");var alpha = "DXImageTransform.Microsoft.AlphaImageLoader";if (fs[alpha]) {fs[alpha].enabled = true;fs[alpha].src = path; fs[alpha].sizingMethod = mode;} else {el.css("filter", 'progid:' + alpha + '(enabled="true", sizingMethod="' + mode + '", src="' + path + '")');	}}function setDOMElementWidth(el) {if(el.css("width") == "auto" & el.css("height") == "auto") {el.css("width", el.attr("offsetWidth") + "px");}}return(elements.each(function() {var el = $(this);if(el.attr("tagName").toUpperCase() == "IMG" && (/\.png/i).test(el.attr("src"))) {if(!settings.imageFixSrc) {el.wrap("<span></span>");var par = el.parent();par.css({height: 	el.height(),width: 		el.width(),display: 	"inline-block"});setFilter(par, el.attr("src"), "scale");el.remove();} else if((/\.gif/i).test(settings.imageFixSrc)) {setDOMElementWidth(el);setFilter(el, el.attr("src"), "image");el.attr("src", settings.imageFixSrc);}} else {var bg = new String(el.css("backgroundImage"));var matches = bg.match(/^url\("(.*)"\)$/);if(matches && matches.length) {setDOMElementWidth(el);el.css("backgroundImage", "none");var sc = "crop";if(settings.sizingMethod) {sc = settings.sizingMethod;} setFilter(el, matches[1], sc);el.find("a").each(function() {$(this).css("position", "relative");});}}}));}})(jQuery);
