/*
 * jQuery JavaScript Library v1.4.4
 * http://jquery.com/
 *
 * Copyright 2010, John Resig
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * Includes Sizzle.js
 * http://sizzlejs.com/
 * Copyright 2010, The Dojo Foundation
 * Released under the MIT, BSD, and GPL Licenses.
 *
 * Date: Thu Nov 11 19:04:53 2010 -0500
 */
(function(ax,aB){function i(t,c,E){if(E===aB&&t.nodeType===1){E=t.getAttribute("data-"+c);if(typeof E==="string"){try{E=E==="true"?true:E==="false"?false:E==="null"?null:!R.isNaN(E)?parseFloat(E):ac.test(E)?R.parseJSON(E):E}catch(B){}R.data(t,c,E)}else{E=aB}}return E}function am(){return false}function K(){return true}function aZ(t,c,B){B[0].type=t;return R.event.handle.apply(c,B)}function C(aa){var X,W,V,U,T,P,S,E,Z,c,B,t=[];U=[];T=R.data(this,this.nodeType?"events":"__events__");if(typeof T==="function"){T=T.events}if(!(aa.liveFired===this||!T||!T.live||aa.button&&aa.type==="click")){if(aa.namespace){B=RegExp("(^|\\.)"+aa.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")}aa.liveFired=this;var Y=T.live.slice(0);for(S=0;S<Y.length;S++){T=Y[S];T.origType.replace(aj,"")===aa.type?U.push(T.selector):Y.splice(S--,1)}U=R(aa.target).closest(U,aa.currentTarget);E=0;for(Z=U.length;E<Z;E++){c=U[E];for(S=0;S<Y.length;S++){T=Y[S];if(c.selector===T.selector&&(!B||B.test(T.namespace))){P=c.elem;V=null;if(T.preType==="mouseenter"||T.preType==="mouseleave"){aa.type=T.preType;V=R(aa.relatedTarget).closest(T.selector)[0]}if(!V||V!==P){t.push({elem:P,handleObj:T,level:c.level})}}}}E=0;for(Z=t.length;E<Z;E++){U=t[E];if(W&&U.level>W){break}aa.currentTarget=U.elem;aa.data=U.handleObj.data;aa.handleObj=U.handleObj;B=U.handleObj.origHandler.apply(U.elem,arguments);if(B===false||aa.isPropagationStopped()){W=U.level;if(B===false){X=false}if(aa.isImmediatePropagationStopped()){break}}}return X}}function ai(t,c){return(t&&t!=="*"?t+".":"")+c.replace(m,"`").replace(a3,"&")}function aM(t,c,E){if(R.isFunction(c)){return R.grep(t,function(S,P){return !!c.call(S,P,S)===E})}else{if(c.nodeType){return R.grep(t,function(P){return P===c===E})}else{if(typeof c==="string"){var B=R.grep(t,function(P){return P.nodeType===1});if(aR.test(c)){return R.filter(c,B,!E)}else{c=R.filter(c,B)}}}}return R.grep(t,function(P){return R.inArray(P,c)>=0===E})}function ay(t,c){var B=0;c.each(function(){if(this.nodeName===(t[B]&&t[B].nodeName)){var T=R.data(t[B++]),S=R.data(this,T);if(T=T&&T.events){delete S.handle;S.events={};for(var P in T){for(var E in T[P]){R.event.add(this,P,T[P][E],T[P][E].data)}}}}})}function aE(t,c){c.src?R.ajax({url:c.src,async:false,dataType:"script"}):R.globalEval(c.text||c.textContent||c.innerHTML||"");c.parentNode&&c.parentNode.removeChild(c)}function Q(t,c,E){var B=c==="width"?t.offsetWidth:t.offsetHeight;if(E==="border"){return B}R.each(c==="width"?af:G,function(){E||(B-=parseFloat(R.css(t,"padding"+this))||0);if(E==="margin"){B+=parseFloat(R.css(t,"margin"+this))||0}else{B-=parseFloat(R.css(t,"border"+this+"Width"))||0}});return B}function v(t,c,E,B){if(R.isArray(c)&&c.length){R.each(c,function(S,P){E||r.test(t)?B(t,P):v(t+"["+(typeof P==="object"||R.isArray(P)?S:"")+"]",P,E,B)})}else{if(!E&&c!=null&&typeof c==="object"){R.isEmptyObject(c)?B(t,""):R.each(c,function(S,P){v(t+"["+S+"]",P,E,B)})}else{B(t,c)}}}function ao(t,c){var B={};R.each(A.concat.apply([],A.slice(0,c)),function(){B[this]=t});return B}function l(t){if(!g[t]){var c=R("<"+t+">").appendTo("body"),B=c.css("display");c.remove();if(B==="none"||B===""){B="block"}g[t]=B}return g[t]}function aW(c){return R.isWindow(c)?c:c.nodeType===9?c.defaultView||c.parentWindow:false}var I=ax.document,R=function(){function bj(){if(!bi.isReady){try{I.documentElement.doScroll("left")}catch(bk){setTimeout(bj,1);return}bi.ready()}}var bi=function(bk,bl){return new bi.fn.init(bk,bl)},bh=ax.jQuery,bg=ax.$,bf,bd=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]+)$)/,ba=/\S/,bb=/^\s+/,a7=/\s+$/,V=/\W/,ab=/\d/,a6=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,aa=/^[\],:{}\s]*$/,T=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,W=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,U=/(?:^|:|,)(?:\s*\[)+/g,P=/(webkit)[ \/]([\w.]+)/,be=/(opera)(?:.*version)?[ \/]([\w.]+)/,bc=/(msie) ([\w.]+)/,a8=/(mozilla)(?:.*? rv:([\w.]+))?/,a9=navigator.userAgent,a5=false,a4=[],Y,S=Object.prototype.toString,X=Object.prototype.hasOwnProperty,E=Array.prototype.push,B=Array.prototype.slice,t=String.prototype.trim,Z=Array.prototype.indexOf,c={};bi.fn=bi.prototype={init:function(bl,bn){var bk,bo,bm;if(!bl){return this}if(bl.nodeType){this.context=this[0]=bl;this.length=1;return this}if(bl==="body"&&!bn&&I.body){this.context=I;this[0]=I.body;this.selector="body";this.length=1;return this}if(typeof bl==="string"){if((bk=bd.exec(bl))&&(bk[1]||!bn)){if(bk[1]){bm=bn?bn.ownerDocument||bn:I;if(bo=a6.exec(bl)){if(bi.isPlainObject(bn)){bl=[I.createElement(bo[1])];bi.fn.attr.call(bl,bn,true)}else{bl=[bm.createElement(bo[1])]}}else{bo=bi.buildFragment([bk[1]],[bm]);bl=(bo.cacheable?bo.fragment.cloneNode(true):bo.fragment).childNodes}return bi.merge(this,bl)}else{if((bo=I.getElementById(bk[2]))&&bo.parentNode){if(bo.id!==bk[2]){return bf.find(bl)}this.length=1;this[0]=bo}this.context=I;this.selector=bl;return this}}else{if(!bn&&!V.test(bl)){this.selector=bl;this.context=I;bl=I.getElementsByTagName(bl);return bi.merge(this,bl)}else{return !bn||bn.jquery?(bn||bf).find(bl):bi(bn).find(bl)}}}else{if(bi.isFunction(bl)){return bf.ready(bl)}}if(bl.selector!==aB){this.selector=bl.selector;this.context=bl.context}return bi.makeArray(bl,this)},selector:"",jquery:"1.4.4",length:0,size:function(){return this.length},toArray:function(){return B.call(this,0)},get:function(bk){return bk==null?this.toArray():bk<0?this.slice(bk)[0]:this[bk]},pushStack:function(bl,bm,bk){var bn=bi();bi.isArray(bl)?E.apply(bn,bl):bi.merge(bn,bl);bn.prevObject=this;bn.context=this.context;if(bm==="find"){bn.selector=this.selector+(this.selector?" ":"")+bk}else{if(bm){bn.selector=this.selector+"."+bm+"("+bk+")"}}return bn},each:function(bk,bl){return bi.each(this,bk,bl)},ready:function(bk){bi.bindReady();if(bi.isReady){bk.call(I,bi)}else{a4&&a4.push(bk)}return this},eq:function(bk){return bk===-1?this.slice(bk):this.slice(bk,+bk+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(B.apply(this,arguments),"slice",B.call(arguments).join(","))},map:function(bk){return this.pushStack(bi.map(this,function(bm,bl){return bk.call(bm,bl,bm)}))},end:function(){return this.prevObject||bi(null)},push:E,sort:[].sort,splice:[].splice};bi.fn.init.prototype=bi.fn;bi.extend=bi.fn.extend=function(){var bk,bs,bp,bm,bo,bq=arguments[0]||{},bn=1,bl=arguments.length,br=false;if(typeof bq==="boolean"){br=bq;bq=arguments[1]||{};bn=2}if(typeof bq!=="object"&&!bi.isFunction(bq)){bq={}}if(bl===bn){bq=this;--bn}for(;bn<bl;bn++){if((bk=arguments[bn])!=null){for(bs in bk){bp=bq[bs];bm=bk[bs];if(bq!==bm){if(br&&bm&&(bi.isPlainObject(bm)||(bo=bi.isArray(bm)))){if(bo){bo=false;bp=bp&&bi.isArray(bp)?bp:[]}else{bp=bp&&bi.isPlainObject(bp)?bp:{}}bq[bs]=bi.extend(br,bp,bm)}else{if(bm!==aB){bq[bs]=bm}}}}}}return bq};bi.extend({noConflict:function(bk){ax.$=bg;if(bk){ax.jQuery=bh}return bi},isReady:false,readyWait:1,ready:function(bl){bl===true&&bi.readyWait--;if(!bi.readyWait||bl!==true&&!bi.isReady){if(!I.body){return setTimeout(bi.ready,1)}bi.isReady=true;if(!(bl!==true&&--bi.readyWait>0)){if(a4){var bm=0,bk=a4;for(a4=null;bl=bk[bm++];){bl.call(I,bi)}bi.fn.trigger&&bi(I).trigger("ready").unbind("ready")}}}},bindReady:function(){if(!a5){a5=true;if(I.readyState==="complete"){return setTimeout(bi.ready,1)}if(I.addEventListener){I.addEventListener("DOMContentLoaded",Y,false);ax.addEventListener("load",bi.ready,false)}else{if(I.attachEvent){I.attachEvent("onreadystatechange",Y);ax.attachEvent("onload",bi.ready);var bk=false;try{bk=ax.frameElement==null}catch(bl){}I.documentElement.doScroll&&bk&&bj()}}}},isFunction:function(bk){return bi.type(bk)==="function"},isArray:Array.isArray||function(bk){return bi.type(bk)==="array"},isWindow:function(bk){return bk&&typeof bk==="object"&&"setInterval" in bk},isNaN:function(bk){return bk==null||!ab.test(bk)||isNaN(bk)},type:function(bk){return bk==null?String(bk):c[S.call(bk)]||"object"},isPlainObject:function(bk){if(!bk||bi.type(bk)!=="object"||bk.nodeType||bi.isWindow(bk)){return false}if(bk.constructor&&!X.call(bk,"constructor")&&!X.call(bk.constructor.prototype,"isPrototypeOf")){return false}for(var bl in bk){}return bl===aB||X.call(bk,bl)},isEmptyObject:function(bk){for(var bl in bk){return false}return true},error:function(bk){throw bk},parseJSON:function(bk){if(typeof bk!=="string"||!bk){return null}bk=bi.trim(bk);if(aa.test(bk.replace(T,"@").replace(W,"]").replace(U,""))){return ax.JSON&&ax.JSON.parse?ax.JSON.parse(bk):(new Function("return "+bk))()}else{bi.error("Invalid JSON: "+bk)}},noop:function(){},globalEval:function(bl){if(bl&&ba.test(bl)){var bm=I.getElementsByTagName("head")[0]||I.documentElement,bk=I.createElement("script");bk.type="text/javascript";if(bi.support.scriptEval){bk.appendChild(I.createTextNode(bl))}else{bk.text=bl}bm.insertBefore(bk,bm.firstChild);bm.removeChild(bk)}},nodeName:function(bk,bl){return bk.nodeName&&bk.nodeName.toUpperCase()===bl.toUpperCase()},each:function(bm,bp,bl){var bq,bn=0,bo=bm.length,bk=bo===aB||bi.isFunction(bm);if(bl){if(bk){for(bq in bm){if(bp.apply(bm[bq],bl)===false){break}}}else{for(;bn<bo;){if(bp.apply(bm[bn++],bl)===false){break}}}}else{if(bk){for(bq in bm){if(bp.call(bm[bq],bq,bm[bq])===false){break}}}else{for(bl=bm[0];bn<bo&&bp.call(bl,bn,bl)!==false;bl=bm[++bn]){}}}return bm},trim:t?function(bk){return bk==null?"":t.call(bk)}:function(bk){return bk==null?"":bk.toString().replace(bb,"").replace(a7,"")},makeArray:function(bl,bm){var bk=bm||[];if(bl!=null){var bn=bi.type(bl);bl.length==null||bn==="string"||bn==="function"||bn==="regexp"||bi.isWindow(bl)?E.call(bk,bl):bi.merge(bk,bl)}return bk},inArray:function(bl,bm){if(bm.indexOf){return bm.indexOf(bl)}for(var bk=0,bn=bm.length;bk<bn;bk++){if(bm[bk]===bl){return bk}}return -1},merge:function(bl,bn){var bk=bl.length,bo=0;if(typeof bn.length==="number"){for(var bm=bn.length;bo<bm;bo++){bl[bk++]=bn[bo]}}else{for(;bn[bo]!==aB;){bl[bk++]=bn[bo++]}}bl.length=bk;return bl},grep:function(bm,bp,bl){var bq=[],bn;bl=!!bl;for(var bo=0,bk=bm.length;bo<bk;bo++){bn=!!bp(bm[bo],bo);bl!==bn&&bq.push(bm[bo])}return bq},map:function(bm,bp,bl){for(var bq=[],bn,bo=0,bk=bm.length;bo<bk;bo++){bn=bp(bm[bo],bo,bl);if(bn!=null){bq[bq.length]=bn}}return bq.concat.apply([],bq)},guid:1,proxy:function(bl,bm,bk){if(arguments.length===2){if(typeof bm==="string"){bk=bl;bl=bk[bm];bm=aB}else{if(bm&&!bi.isFunction(bm)){bk=bm;bm=aB}}}if(!bm&&bl){bm=function(){return bl.apply(bk||this,arguments)}}if(bl){bm.guid=bl.guid=bl.guid||bm.guid||bi.guid++}return bm},access:function(bm,bp,bl,br,bn,bo){var bk=bm.length;if(typeof bp==="object"){for(var bq in bp){bi.access(bm,bq,bp[bq],br,bn,bl)}return bm}if(bl!==aB){br=!bo&&br&&bi.isFunction(bl);for(bq=0;bq<bk;bq++){bn(bm[bq],bp,br?bl.call(bm[bq],bq,bn(bm[bq],bp)):bl,bo)}return bm}return bk?bn(bm[0],bp):aB},now:function(){return(new Date).getTime()},uaMatch:function(bk){bk=bk.toLowerCase();bk=P.exec(bk)||be.exec(bk)||bc.exec(bk)||bk.indexOf("compatible")<0&&a8.exec(bk)||[];return{browser:bk[1]||"",version:bk[2]||"0"}},browser:{}});bi.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(bk,bl){c["[object "+bl+"]"]=bl.toLowerCase()});a9=bi.uaMatch(a9);if(a9.browser){bi.browser[a9.browser]=true;bi.browser.version=a9.version}if(bi.browser.webkit){bi.browser.safari=true}if(Z){bi.inArray=function(bk,bl){return Z.call(bl,bk)}}if(!/\s/.test("\u00a0")){bb=/^[\s\xA0]+/;a7=/[\s\xA0]+$/}bf=bi(I);if(I.addEventListener){Y=function(){I.removeEventListener("DOMContentLoaded",Y,false);bi.ready()}}else{if(I.attachEvent){Y=function(){if(I.readyState==="complete"){I.detachEvent("onreadystatechange",Y);bi.ready()}}}}return ax.jQuery=ax.$=bi}();(function(){R.support={};var X=I.documentElement,V=I.createElement("script"),U=I.createElement("div"),T="script"+R.now();U.style.display="none";U.innerHTML="   <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>";var S=U.getElementsByTagName("*"),P=U.getElementsByTagName("a")[0],B=I.createElement("select"),E=B.appendChild(I.createElement("option"));if(!(!S||!S.length||!P)){R.support={leadingWhitespace:U.firstChild.nodeType===3,tbody:!U.getElementsByTagName("tbody").length,htmlSerialize:!!U.getElementsByTagName("link").length,style:/red/.test(P.getAttribute("style")),hrefNormalized:P.getAttribute("href")==="/a",opacity:/^0.55$/.test(P.style.opacity),cssFloat:!!P.style.cssFloat,checkOn:U.getElementsByTagName("input")[0].value==="on",optSelected:E.selected,deleteExpando:true,optDisabled:false,checkClone:false,scriptEval:false,noCloneEvent:true,boxModel:null,inlineBlockNeedsLayout:false,shrinkWrapBlocks:false,reliableHiddenOffsets:true};B.disabled=true;R.support.optDisabled=!E.disabled;V.type="text/javascript";try{V.appendChild(I.createTextNode("window."+T+"=1;"))}catch(t){}X.insertBefore(V,X.firstChild);if(ax[T]){R.support.scriptEval=true;delete ax[T]}try{delete V.test}catch(W){R.support.deleteExpando=false}X.removeChild(V);if(U.attachEvent&&U.fireEvent){U.attachEvent("onclick",function c(){R.support.noCloneEvent=false;U.detachEvent("onclick",c)});U.cloneNode(true).fireEvent("onclick")}U=I.createElement("div");U.innerHTML="<input type='radio' name='radiotest' checked='checked'/>";X=I.createDocumentFragment();X.appendChild(U.firstChild);R.support.checkClone=X.cloneNode(true).cloneNode(true).lastChild.checked;R(function(){var Z=I.createElement("div");Z.style.width=Z.style.paddingLeft="1px";I.body.appendChild(Z);R.boxModel=R.support.boxModel=Z.offsetWidth===2;if("zoom" in Z.style){Z.style.display="inline";Z.style.zoom=1;R.support.inlineBlockNeedsLayout=Z.offsetWidth===2;Z.style.display="";Z.innerHTML="<div style='width:4px;'></div>";R.support.shrinkWrapBlocks=Z.offsetWidth!==2}Z.innerHTML="<table><tr><td style='padding:0;display:none'></td><td>t</td></tr></table>";var Y=Z.getElementsByTagName("td");R.support.reliableHiddenOffsets=Y[0].offsetHeight===0;Y[0].style.display="";Y[1].style.display="none";R.support.reliableHiddenOffsets=R.support.reliableHiddenOffsets&&Y[0].offsetHeight===0;Z.innerHTML="";I.body.removeChild(Z).style.display="none"});X=function(Z){var Y=I.createElement("div");Z="on"+Z;var aa=Z in Y;if(!aa){Y.setAttribute(Z,"return;");aa=typeof Y[Z]==="function"}return aa};R.support.submitBubbles=X("submit");R.support.changeBubbles=X("change");X=V=U=S=P=null}})();var a2={},ac=/^(?:\{.*\}|\[.*\])$/;R.extend({cache:{},uuid:0,expando:"jQuery"+R.now(),noData:{embed:true,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:true},data:function(t,c,S){if(R.acceptData(t)){t=t==ax?a2:t;var P=t.nodeType,E=P?t[R.expando]:null,B=R.cache;if(!(P&&!E&&typeof c==="string"&&S===aB)){if(P){E||(t[R.expando]=E=++R.uuid)}else{B=t}if(typeof c==="object"){if(P){B[E]=R.extend(B[E],c)}else{R.extend(B,c)}}else{if(P&&!B[E]){B[E]={}}}t=P?B[E]:B;if(S!==aB){t[c]=S}return typeof c==="string"?t[c]:t}}},removeData:function(B,c){if(R.acceptData(B)){B=B==ax?a2:B;var T=B.nodeType,S=T?B[R.expando]:B,P=R.cache,E=T?P[S]:S;if(c){if(E){delete E[c];T&&R.isEmptyObject(E)&&R.removeData(B)}}else{if(T&&R.support.deleteExpando){delete B[R.expando]}else{if(B.removeAttribute){B.removeAttribute(R.expando)}else{if(T){delete P[S]}else{for(var t in B){delete B[t]}}}}}}},acceptData:function(t){if(t.nodeName){var c=R.noData[t.nodeName.toLowerCase()];if(c){return !(c===true||t.getAttribute("classid")!==c)}}return true}});R.fn.extend({data:function(B,c){var U=null;if(typeof B==="undefined"){if(this.length){var T=this[0].attributes,S;U=R.data(this[0]);for(var P=0,t=T.length;P<t;P++){S=T[P].name;if(S.indexOf("data-")===0){S=S.substr(5);i(this[0],S,U[S])}}}return U}else{if(typeof B==="object"){return this.each(function(){R.data(this,B)})}}var E=B.split(".");E[1]=E[1]?"."+E[1]:"";if(c===aB){U=this.triggerHandler("getData"+E[1]+"!",[E[0]]);if(U===aB&&this.length){U=R.data(this[0],B);U=i(this[0],B,U)}return U===aB&&E[1]?this.data(E[0]):U}else{return this.each(function(){var W=R(this),V=[E[0],c];W.triggerHandler("setData"+E[1]+"!",V);R.data(this,B,c);W.triggerHandler("changeData"+E[1]+"!",V)})}},removeData:function(c){return this.each(function(){R.removeData(this,c)})}});R.extend({queue:function(t,c,E){if(t){c=(c||"fx")+"queue";var B=R.data(t,c);if(!E){return B||[]}if(!B||R.isArray(E)){B=R.data(t,c,R.makeArray(E))}else{B.push(E)}return B}},dequeue:function(t,c){c=c||"fx";var E=R.queue(t,c),B=E.shift();if(B==="inprogress"){B=E.shift()}if(B){c==="fx"&&E.unshift("inprogress");B.call(t,function(){R.dequeue(t,c)})}}});R.fn.extend({queue:function(t,c){if(typeof t!=="string"){c=t;t="fx"}if(c===aB){return R.queue(this[0],t)}return this.each(function(){var B=R.queue(this,t,c);t==="fx"&&B[0]!=="inprogress"&&R.dequeue(this,t)})},dequeue:function(c){return this.each(function(){R.dequeue(this,c)})},delay:function(t,c){t=R.fx?R.fx.speeds[t]||t:t;c=c||"fx";return this.queue(c,function(){var B=this;setTimeout(function(){R.dequeue(B,c)},t)})},clearQueue:function(c){return this.queue(c||"fx",[])}});var aQ=/[\n\t]/g,au=/\s+/,d=/\r/g,aT=/^(?:href|src|style)$/,aG=/^(?:button|input)$/i,ah=/^(?:button|input|object|select|textarea)$/i,H=/^a(?:rea)?$/i,aD=/^(?:radio|checkbox)$/i;R.props={"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};R.fn.extend({attr:function(t,c){return R.access(this,t,c,true,R.attr)},removeAttr:function(c){return this.each(function(){R.attr(this,c,"");this.nodeType===1&&this.removeAttribute(c)})},addClass:function(V){if(R.isFunction(V)){return this.each(function(W){var X=R(this);X.addClass(V.call(this,W,X.attr("class")))})}if(V&&typeof V==="string"){for(var U=(V||"").split(au),T=0,S=this.length;T<S;T++){var P=this[T];if(P.nodeType===1){if(P.className){for(var E=" "+P.className+" ",t=P.className,B=0,c=U.length;B<c;B++){if(E.indexOf(" "+U[B]+" ")<0){t+=" "+U[B]}}P.className=R.trim(t)}else{P.className=V}}}}return this},removeClass:function(B){if(R.isFunction(B)){return this.each(function(W){var V=R(this);V.removeClass(B.call(this,W,V.attr("class")))})}if(B&&typeof B==="string"||B===aB){for(var c=(B||"").split(au),U=0,T=this.length;U<T;U++){var S=this[U];if(S.nodeType===1&&S.className){if(B){for(var P=(" "+S.className+" ").replace(aQ," "),t=0,E=c.length;t<E;t++){P=P.replace(" "+c[t]+" "," ")}S.className=R.trim(P)}else{S.className=""}}}}return this},toggleClass:function(t,c){var E=typeof t,B=typeof c==="boolean";if(R.isFunction(t)){return this.each(function(S){var P=R(this);P.toggleClass(t.call(this,S,P.attr("class"),c),c)})}return this.each(function(){if(E==="string"){for(var U,T=0,P=R(this),S=c,V=t.split(au);U=V[T++];){S=B?S:!P.hasClass(U);P[S?"addClass":"removeClass"](U)}}else{if(E==="undefined"||E==="boolean"){this.className&&R.data(this,"__className__",this.className);this.className=this.className||t===false?"":R.data(this,"__className__")||""}}})},hasClass:function(t){t=" "+t+" ";for(var c=0,B=this.length;c<B;c++){if((" "+this[c].className+" ").replace(aQ," ").indexOf(t)>-1){return true}}return false},val:function(B){if(!arguments.length){var c=this[0];if(c){if(R.nodeName(c,"option")){var U=c.attributes.value;return !U||U.specified?c.value:c.text}if(R.nodeName(c,"select")){var T=c.selectedIndex;U=[];var S=c.options;c=c.type==="select-one";if(T<0){return null}var P=c?T:0;for(T=c?T+1:S.length;P<T;P++){var t=S[P];if(t.selected&&(R.support.optDisabled?!t.disabled:t.getAttribute("disabled")===null)&&(!t.parentNode.disabled||!R.nodeName(t.parentNode,"optgroup"))){B=R(t).val();if(c){return B}U.push(B)}}return U}if(aD.test(c.type)&&!R.support.checkOn){return c.getAttribute("value")===null?"on":c.value}return(c.value||"").replace(d,"")}return aB}var E=R.isFunction(B);return this.each(function(Y){var W=R(this),X=B;if(this.nodeType===1){if(E){X=B.call(this,Y,W.val())}if(X==null){X=""}else{if(typeof X==="number"){X+=""}else{if(R.isArray(X)){X=R.map(X,function(Z){return Z==null?"":Z+""})}}}if(R.isArray(X)&&aD.test(this.type)){this.checked=R.inArray(W.val(),X)>=0}else{if(R.nodeName(this,"select")){var V=R.makeArray(X);R("option",this).each(function(){this.selected=R.inArray(R(this).val(),V)>=0});if(!V.length){this.selectedIndex=-1}}else{this.value=X}}}})}});R.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(t,c,S,P){if(!t||t.nodeType===3||t.nodeType===8){return aB}if(P&&c in R.attrFn){return R(t)[c](S)}P=t.nodeType!==1||!R.isXMLDoc(t);var E=S!==aB;c=P&&R.props[c]||c;var B=aT.test(c);if((c in t||t[c]!==aB)&&P&&!B){if(E){c==="type"&&aG.test(t.nodeName)&&t.parentNode&&R.error("type property can't be changed");if(S===null){t.nodeType===1&&t.removeAttribute(c)}else{t[c]=S}}if(R.nodeName(t,"form")&&t.getAttributeNode(c)){return t.getAttributeNode(c).nodeValue}if(c==="tabIndex"){return(c=t.getAttributeNode("tabIndex"))&&c.specified?c.value:ah.test(t.nodeName)||H.test(t.nodeName)&&t.href?0:aB}return t[c]}if(!R.support.style&&P&&c==="style"){if(E){t.style.cssText=""+S}return t.style.cssText}E&&t.setAttribute(c,""+S);if(!t.attributes[c]&&t.hasAttribute&&!t.hasAttribute(c)){return aB}t=!R.support.hrefNormalized&&P&&B?t.getAttribute(c,2):t.getAttribute(c);return t===null?aB:t}});var aj=/\.(.*)$/,M=/^(?:textarea|input|select)$/i,m=/\./g,a3=/ /g,s=/[^\w\s.|`]/g,e=function(c){return c.replace(s,"\\$&")},ae={focusin:0,focusout:0};R.event={add:function(Z,X,W,V){if(!(Z.nodeType===3||Z.nodeType===8)){if(R.isWindow(Z)&&Z!==ax&&!Z.frameElement){Z=ax}if(W===false){W=am}else{if(!W){return}}var U,T;if(W.handler){U=W;W=U.handler}if(!W.guid){W.guid=R.guid++}if(T=R.data(Z)){var P=Z.nodeType?"events":"__events__",S=T[P],E=T.handle;if(typeof S==="function"){E=S.handle;S=S.events}else{if(!S){Z.nodeType||(T[P]=T=function(){});T.events=S={}}}if(!E){T.handle=E=function(){return typeof R!=="undefined"&&!R.event.triggered?R.event.handle.apply(E.elem,arguments):aB}}E.elem=Z;X=X.split(" ");for(var Y=0,c;P=X[Y++];){T=U?R.extend({},U):{handler:W,data:V};if(P.indexOf(".")>-1){c=P.split(".");P=c.shift();T.namespace=c.slice(0).sort().join(".")}else{c=[];T.namespace=""}T.type=P;if(!T.guid){T.guid=W.guid}var B=S[P],t=R.event.special[P]||{};if(!B){B=S[P]=[];if(!t.setup||t.setup.call(Z,V,c,E)===false){if(Z.addEventListener){Z.addEventListener(P,E,false)}else{Z.attachEvent&&Z.attachEvent("on"+P,E)}}}if(t.add){t.add.call(Z,T);if(!T.handler.guid){T.handler.guid=W.guid}}B.push(T);R.event.global[P]=true}Z=null}}},global:{},remove:function(aa,X,W,V){if(!(aa.nodeType===3||aa.nodeType===8)){if(W===false){W=am}var U,T,P=0,S,E,Z,c,B,t,Y=aa.nodeType?"events":"__events__",a4=R.data(aa),ab=a4&&a4[Y];if(a4&&ab){if(typeof ab==="function"){a4=ab;ab=ab.events}if(X&&X.type){W=X.handler;X=X.type}if(!X||typeof X==="string"&&X.charAt(0)==="."){X=X||"";for(U in ab){R.event.remove(aa,U+X)}}else{for(X=X.split(" ");U=X[P++];){c=U;S=U.indexOf(".")<0;E=[];if(!S){E=U.split(".");U=E.shift();Z=RegExp("(^|\\.)"+R.map(E.slice(0).sort(),e).join("\\.(?:.*\\.)?")+"(\\.|$)")}if(B=ab[U]){if(W){c=R.event.special[U]||{};for(T=V||0;T<B.length;T++){t=B[T];if(W.guid===t.guid){if(S||Z.test(t.namespace)){V==null&&B.splice(T--,1);c.remove&&c.remove.call(aa,t)}if(V!=null){break}}}if(B.length===0||V!=null&&B.length===1){if(!c.teardown||c.teardown.call(aa,E)===false){R.removeEvent(aa,U,a4.handle)}delete ab[U]}}else{for(T=0;T<B.length;T++){t=B[T];if(S||Z.test(t.namespace)){R.event.remove(aa,c,t.handler,T);B.splice(T--,1)}}}}}if(R.isEmptyObject(ab)){if(X=a4.handle){X.elem=null}delete a4.events;delete a4.handle;if(typeof a4==="function"){R.removeData(aa,Y)}else{R.isEmptyObject(a4)&&R.removeData(aa)}}}}}},trigger:function(X,V,U,T){var S=X.type||X;if(!T){X=typeof X==="object"?X[R.expando]?X:R.extend(R.Event(S),X):R.Event(S);if(S.indexOf("!")>=0){X.type=S=S.slice(0,-1);X.exclusive=true}if(!U){X.stopPropagation();R.event.global[S]&&R.each(R.cache,function(){this.events&&this.events[S]&&R.event.trigger(X,V,this.handle.elem)})}if(!U||U.nodeType===3||U.nodeType===8){return aB}X.result=aB;X.target=U;V=R.makeArray(V);V.unshift(X)}X.currentTarget=U;(T=U.nodeType?R.data(U,"handle"):(R.data(U,"__events__")||{}).handle)&&T.apply(U,V);T=U.parentNode||U.ownerDocument;try{if(!(U&&U.nodeName&&R.noData[U.nodeName.toLowerCase()])){if(U["on"+S]&&U["on"+S].apply(U,V)===false){X.result=false;X.preventDefault()}}}catch(P){}if(!X.isPropagationStopped()&&T){R.event.trigger(X,V,T,true)}else{if(!X.isDefaultPrevented()){var B;T=X.target;var E=S.replace(aj,""),t=R.nodeName(T,"a")&&E==="click",W=R.event.special[E]||{};if((!W._default||W._default.call(U,X)===false)&&!t&&!(T&&T.nodeName&&R.noData[T.nodeName.toLowerCase()])){try{if(T[E]){if(B=T["on"+E]){T["on"+E]=null}R.event.triggered=true;T[E]()}}catch(c){}if(B){T["on"+E]=B}R.event.triggered=false}}}},handle:function(B){var c,U,T,S;U=[];var P=R.makeArray(arguments);B=P[0]=R.event.fix(B||ax.event);B.currentTarget=this;c=B.type.indexOf(".")<0&&!B.exclusive;if(!c){T=B.type.split(".");B.type=T.shift();U=T.slice(0).sort();T=RegExp("(^|\\.)"+U.join("\\.(?:.*\\.)?")+"(\\.|$)")}B.namespace=B.namespace||U.join(".");S=R.data(this,this.nodeType?"events":"__events__");if(typeof S==="function"){S=S.events}U=(S||{})[B.type];if(S&&U){U=U.slice(0);S=0;for(var t=U.length;S<t;S++){var E=U[S];if(c||T.test(E.namespace)){B.handler=E.handler;B.data=E.data;B.handleObj=E;E=E.handler.apply(this,P);if(E!==aB){B.result=E;if(E===false){B.preventDefault();B.stopPropagation()}}if(B.isImmediatePropagationStopped()){break}}}}return B.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(t){if(t[R.expando]){return t}var c=t;t=R.Event(c);for(var E=this.props.length,B;E;){B=this.props[--E];t[B]=c[B]}if(!t.target){t.target=t.srcElement||I}if(t.target.nodeType===3){t.target=t.target.parentNode}if(!t.relatedTarget&&t.fromElement){t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement}if(t.pageX==null&&t.clientX!=null){c=I.documentElement;E=I.body;t.pageX=t.clientX+(c&&c.scrollLeft||E&&E.scrollLeft||0)-(c&&c.clientLeft||E&&E.clientLeft||0);t.pageY=t.clientY+(c&&c.scrollTop||E&&E.scrollTop||0)-(c&&c.clientTop||E&&E.clientTop||0)}if(t.which==null&&(t.charCode!=null||t.keyCode!=null)){t.which=t.charCode!=null?t.charCode:t.keyCode}if(!t.metaKey&&t.ctrlKey){t.metaKey=t.ctrlKey}if(!t.which&&t.button!==aB){t.which=t.button&1?1:t.button&2?3:t.button&4?2:0}return t},guid:100000000,proxy:R.proxy,special:{ready:{setup:R.bindReady,teardown:R.noop},live:{add:function(c){R.event.add(this,ai(c.origType,c.selector),R.extend({},c,{handler:C,guid:c.handler.guid}))},remove:function(c){R.event.remove(this,ai(c.origType,c.selector),c)}},beforeunload:{setup:function(t,c,B){if(R.isWindow(this)){this.onbeforeunload=B}},teardown:function(t,c){if(this.onbeforeunload===c){this.onbeforeunload=null}}}}};R.removeEvent=I.removeEventListener?function(t,c,B){t.removeEventListener&&t.removeEventListener(c,B,false)}:function(t,c,B){t.detachEvent&&t.detachEvent("on"+c,B)};R.Event=function(c){if(!this.preventDefault){return new R.Event(c)}if(c&&c.type){this.originalEvent=c;this.type=c.type}else{this.type=c}this.timeStamp=R.now();this[R.expando]=true};R.Event.prototype={preventDefault:function(){this.isDefaultPrevented=K;var c=this.originalEvent;if(c){if(c.preventDefault){c.preventDefault()}else{c.returnValue=false}}},stopPropagation:function(){this.isPropagationStopped=K;var c=this.originalEvent;if(c){c.stopPropagation&&c.stopPropagation();c.cancelBubble=true}},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=K;this.stopPropagation()},isDefaultPrevented:am,isPropagationStopped:am,isImmediatePropagationStopped:am};var F=function(t){var c=t.relatedTarget;try{for(;c&&c!==this;){c=c.parentNode}if(c!==this){t.type=t.data;R.event.handle.apply(this,arguments)}}catch(B){}},q=function(c){c.type=c.data;R.event.handle.apply(this,arguments)};R.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(t,c){R.event.special[t]={setup:function(B){R.event.add(this,c,B&&B.selector?q:F,t)},teardown:function(B){R.event.remove(this,c,B&&B.selector?q:F)}}});if(!R.support.submitBubbles){R.event.special.submit={setup:function(){if(this.nodeName.toLowerCase()!=="form"){R.event.add(this,"click.specialSubmit",function(t){var c=t.target,B=c.type;if((B==="submit"||B==="image")&&R(c).closest("form").length){t.liveFired=aB;return aZ("submit",this,arguments)}});R.event.add(this,"keypress.specialSubmit",function(t){var c=t.target,B=c.type;if((B==="text"||B==="password")&&R(c).closest("form").length&&t.keyCode===13){t.liveFired=aB;return aZ("submit",this,arguments)}})}else{return false}},teardown:function(){R.event.remove(this,".specialSubmit")}}}if(!R.support.changeBubbles){var al,b=function(t){var c=t.type,B=t.value;if(c==="radio"||c==="checkbox"){B=t.checked}else{if(c==="select-multiple"){B=t.selectedIndex>-1?R.map(t.options,function(E){return E.selected}).join("-"):""}else{if(t.nodeName.toLowerCase()==="select"){B=t.selectedIndex}}}return B},ag=function(t,c){var P=t.target,E,B;if(!(!M.test(P.nodeName)||P.readOnly)){E=R.data(P,"_change_data");B=b(P);if(t.type!=="focusout"||P.type!=="radio"){R.data(P,"_change_data",B)}if(!(E===aB||B===E)){if(E!=null||B){t.type="change";t.liveFired=aB;return R.event.trigger(t,c,P)}}}};R.event.special.change={filters:{focusout:ag,beforedeactivate:ag,click:function(t){var c=t.target,B=c.type;if(B==="radio"||B==="checkbox"||c.nodeName.toLowerCase()==="select"){return ag.call(this,t)}},keydown:function(t){var c=t.target,B=c.type;if(t.keyCode===13&&c.nodeName.toLowerCase()!=="textarea"||t.keyCode===32&&(B==="checkbox"||B==="radio")||B==="select-multiple"){return ag.call(this,t)}},beforeactivate:function(c){c=c.target;R.data(c,"_change_data",b(c))}},setup:function(){if(this.type==="file"){return false}for(var c in al){R.event.add(this,c+".specialChange",al[c])}return M.test(this.nodeName)},teardown:function(){R.event.remove(this,".specialChange");return M.test(this.nodeName)}};al=R.event.special.change.filters;al.focus=al.beforeactivate}I.addEventListener&&R.each({focus:"focusin",blur:"focusout"},function(t,c){function B(E){E=R.event.fix(E);E.type=c;return R.event.trigger(E,null,E.target)}R.event.special[c]={setup:function(){ae[c]++===0&&I.addEventListener(t,B,true)},teardown:function(){--ae[c]===0&&I.removeEventListener(t,B,true)}}});R.each(["bind","one"],function(t,c){R.fn[c]=function(U,T,S){if(typeof U==="object"){for(var P in U){this[c](P,T,U[P],S)}return this}if(R.isFunction(T)||T===false){S=T;T=aB}var B=c==="one"?R.proxy(S,function(V){R(this).unbind(V,B);return S.apply(this,arguments)}):S;if(U==="unload"&&c!=="one"){this.one(U,T,S)}else{P=0;for(var E=this.length;P<E;P++){R.event.add(this[P],U,B,T)}}return this}});R.fn.extend({unbind:function(t,c){if(typeof t==="object"&&!t.preventDefault){for(var E in t){this.unbind(E,t[E])}}else{E=0;for(var B=this.length;E<B;E++){R.event.remove(this[E],t,c)}}return this},delegate:function(t,c,E,B){return this.live(c,E,B,t)},undelegate:function(t,c,B){return arguments.length===0?this.unbind("live"):this.die(c,null,B,t)},trigger:function(t,c){return this.each(function(){R.event.trigger(t,c,this)})},triggerHandler:function(t,c){if(this[0]){var B=R.Event(t);B.preventDefault();B.stopPropagation();R.event.trigger(B,c,this[0]);return B.result}},toggle:function(t){for(var c=arguments,B=1;B<c.length;){R.proxy(t,c[B++])}return this.click(R.proxy(t,function(P){var E=(R.data(this,"lastToggle"+t.guid)||0)%B;R.data(this,"lastToggle"+t.guid,E+1);P.preventDefault();return c[E].apply(this,arguments)||false}))},hover:function(t,c){return this.mouseenter(t).mouseleave(c||t)}});var aS={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};R.each(["live","die"],function(t,c){R.fn[c]=function(X,W,V,U){var S,T=0,P,Y,B=U||this.selector;U=U?this:R(this.context);if(typeof X==="object"&&!X.preventDefault){for(S in X){U[c](S,W,X[S],B)}return this}if(R.isFunction(W)){V=W;W=aB}for(X=(X||"").split(" ");(S=X[T++])!=null;){P=aj.exec(S);Y="";if(P){Y=P[0];S=S.replace(aj,"")}if(S==="hover"){X.push("mouseenter"+Y,"mouseleave"+Y)}else{P=S;if(S==="focus"||S==="blur"){X.push(aS[S]+Y);S+=Y}else{S=(aS[S]||S)+Y}if(c==="live"){Y=0;for(var E=U.length;Y<E;Y++){R.event.add(U[Y],"live."+ai(S,B),{data:W,selector:B,handler:V,origType:S,origHandler:V,preType:P})}}else{U.unbind("live."+ai(S,B),V)}}}return this}});R.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error".split(" "),function(t,c){R.fn[c]=function(E,B){if(B==null){B=E;E=null}return arguments.length>0?this.bind(c,E,B):this.trigger(c)};if(R.attrFn){R.attrFn[c]=true}});ax.attachEvent&&!ax.addEventListener&&R(ax).bind("unload",function(){for(var t in R.cache){if(R.cache[t].handle){try{R.event.remove(R.cache[t].handle.elem)}catch(c){}}}});(function(){function ab(bb,ba,a8,a9,a7,a6){a7=0;for(var bd=a9.length;a7<bd;a7++){var bc=a9[a7];if(bc){var be=false;for(bc=bc[bb];bc;){if(bc.sizcache===a8){be=a9[bc.sizset];break}if(bc.nodeType===1&&!a6){bc.sizcache=a8;bc.sizset=a7}if(bc.nodeName.toLowerCase()===ba){be=bc;break}bc=bc[bb]}a9[a7]=be}}}function Y(bb,ba,a8,a9,a7,a6){a7=0;for(var bd=a9.length;a7<bd;a7++){var bc=a9[a7];if(bc){var be=false;for(bc=bc[bb];bc;){if(bc.sizcache===a8){be=a9[bc.sizset];break}if(bc.nodeType===1){if(!a6){bc.sizcache=a8;bc.sizset=a7}if(typeof ba!=="string"){if(bc===ba){be=true;break}}else{if(S.filter(ba,[bc]).length>0){be=bc;break}}}bc=bc[bb]}a9[a7]=be}}}var W=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,V=0,U=Object.prototype.toString,T=false,P=true;[0,0].sort(function(){P=false;return 0});var S=function(bd,bc,a9,ba){a9=a9||[];var a8=bc=bc||I;if(bc.nodeType!==1&&bc.nodeType!==9){return[]}if(!bd||typeof bd!=="string"){return a9}var a7,bi,bh,bj,bg,bf=true,be=S.isXML(bc),a6=[],bb=bd;do{W.exec("");if(a7=W.exec(bb)){bb=a7[3];a6.push(a7[1]);if(a7[2]){bj=a7[3];break}}}while(a7);if(a6.length>1&&aa.exec(bd)){if(a6.length===2&&E.relative[a6[0]]){bi=X(a6[0]+a6[1],bc)}else{for(bi=E.relative[a6[0]]?[bc]:S(a6.shift(),bc);a6.length;){bd=a6.shift();if(E.relative[bd]){bd+=a6.shift()}bi=X(bd,bi)}}}else{if(!ba&&a6.length>1&&bc.nodeType===9&&!be&&E.match.ID.test(a6[0])&&!E.match.ID.test(a6[a6.length-1])){a7=S.find(a6.shift(),bc,be);bc=a7.expr?S.filter(a7.expr,a7.set)[0]:a7.set[0]}if(bc){a7=ba?{expr:a6.pop(),set:t(ba)}:S.find(a6.pop(),a6.length===1&&(a6[0]==="~"||a6[0]==="+")&&bc.parentNode?bc.parentNode:bc,be);bi=a7.expr?S.filter(a7.expr,a7.set):a7.set;if(a6.length>0){bh=t(bi)}else{bf=false}for(;a6.length;){a7=bg=a6.pop();if(E.relative[bg]){a7=a6.pop()}else{bg=""}if(a7==null){a7=bc}E.relative[bg](bh,a7,be)}}else{bh=[]}}bh||(bh=bi);bh||S.error(bg||bd);if(U.call(bh)==="[object Array]"){if(bf){if(bc&&bc.nodeType===1){for(bd=0;bh[bd]!=null;bd++){if(bh[bd]&&(bh[bd]===true||bh[bd].nodeType===1&&S.contains(bc,bh[bd]))){a9.push(bi[bd])}}}else{for(bd=0;bh[bd]!=null;bd++){bh[bd]&&bh[bd].nodeType===1&&a9.push(bi[bd])}}}else{a9.push.apply(a9,bh)}}else{t(bh,a9)}if(bj){S(bj,a8,a9,ba);S.uniqueSort(a9)}return a9};S.uniqueSort=function(a7){if(a5){T=P;a7.sort(a5);if(T){for(var a6=1;a6<a7.length;a6++){a7[a6]===a7[a6-1]&&a7.splice(a6--,1)}}}return a7};S.matches=function(a7,a6){return S(a7,null,null,a6)};S.matchesSelector=function(a7,a6){return S(a6,null,null,[a7]).length>0};S.find=function(bb,ba,a8){var a9;if(!bb){return[]}for(var a7=0,a6=E.order.length;a7<a6;a7++){var bd,bc=E.order[a7];if(bd=E.leftMatch[bc].exec(bb)){var be=bd[1];bd.splice(1,1);if(be.substr(be.length-1)!=="\\"){bd[1]=(bd[1]||"").replace(/\\/g,"");a9=E.find[bc](bd,ba,a8);if(a9!=null){bb=bb.replace(E.match[bc],"");break}}}}a9||(a9=ba.getElementsByTagName("*"));return{set:a9,expr:bb}};S.filter=function(be,bd,a9,ba){for(var a8,a7,bj=be,bi=[],bk=bd,bh=bd&&bd[0]&&S.isXML(bd[0]);be&&bd.length;){for(var bg in E.filter){if((a8=E.leftMatch[bg].exec(be))!=null&&a8[2]){var bf,a6,bc=E.filter[bg];a6=a8[1];a7=false;a8.splice(1,1);if(a6.substr(a6.length-1)!=="\\"){if(bk===bi){bi=[]}if(E.preFilter[bg]){if(a8=E.preFilter[bg](a8,bk,a9,bi,ba,bh)){if(a8===true){continue}}else{a7=bf=true}}if(a8){for(var bb=0;(a6=bk[bb])!=null;bb++){if(a6){bf=bc(a6,a8,bb,bk);var bl=ba^!!bf;if(a9&&bf!=null){if(bl){a7=true}else{bk[bb]=false}}else{if(bl){bi.push(a6);a7=true}}}}}if(bf!==aB){a9||(bk=bi);be=be.replace(E.match[bg],"");if(!a7){return[]}break}}}}if(be===bj){if(a7==null){S.error(be)}else{break}}bj=be}return bk};S.error=function(a6){throw"Syntax error, unrecognized expression: "+a6};var E=S.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+\-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a6){return a6.getAttribute("href")}},relative:{"+":function(a8,a7){var bb=typeof a7==="string",a6=bb&&!/\W/.test(a7);bb=bb&&!a6;if(a6){a7=a7.toLowerCase()}a6=0;for(var ba=a8.length,a9;a6<ba;a6++){if(a9=a8[a6]){for(;(a9=a9.previousSibling)&&a9.nodeType!==1;){}a8[a6]=bb||a9&&a9.nodeName.toLowerCase()===a7?a9||false:a9===a7}}bb&&S.filter(a7,a8,true)},">":function(a8,a7){var bb,a6=typeof a7==="string",ba=0,a9=a8.length;if(a6&&!/\W/.test(a7)){for(a7=a7.toLowerCase();ba<a9;ba++){if(bb=a8[ba]){bb=bb.parentNode;a8[ba]=bb.nodeName.toLowerCase()===a7?bb:false}}}else{for(;ba<a9;ba++){if(bb=a8[ba]){a8[ba]=a6?bb.parentNode:bb.parentNode===a7}}a6&&S.filter(a7,a8,true)}},"":function(a8,a7,bb){var a6,ba=V++,a9=Y;if(typeof a7==="string"&&!/\W/.test(a7)){a6=a7=a7.toLowerCase();a9=ab}a9("parentNode",a7,ba,a8,a6,bb)},"~":function(a8,a7,bb){var a6,ba=V++,a9=Y;if(typeof a7==="string"&&!/\W/.test(a7)){a6=a7=a7.toLowerCase();a9=ab}a9("previousSibling",a7,ba,a8,a6,bb)}},find:{ID:function(a7,a6,a8){if(typeof a6.getElementById!=="undefined"&&!a8){return(a7=a6.getElementById(a7[1]))&&a7.parentNode?[a7]:[]}},NAME:function(a8,a7){if(typeof a7.getElementsByName!=="undefined"){for(var bb=[],a6=a7.getElementsByName(a8[1]),ba=0,a9=a6.length;ba<a9;ba++){a6[ba].getAttribute("name")===a8[1]&&bb.push(a6[ba])}return bb.length===0?null:bb}},TAG:function(a7,a6){return a6.getElementsByTagName(a7[1])}},preFilter:{CLASS:function(a9,a8,bc,a6,bb,ba){a9=" "+a9[1].replace(/\\/g,"")+" ";if(ba){return a9}ba=0;for(var a7;(a7=a8[ba])!=null;ba++){if(a7){if(bb^(a7.className&&(" "+a7.className+" ").replace(/[\t\n]/g," ").indexOf(a9)>=0)){bc||a6.push(a7)}else{if(bc){a8[ba]=false}}}}return false},ID:function(a6){return a6[1].replace(/\\/g,"")},TAG:function(a6){return a6[1].toLowerCase()},CHILD:function(a7){if(a7[1]==="nth"){var a6=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(a7[2]==="even"&&"2n"||a7[2]==="odd"&&"2n+1"||!/\D/.test(a7[2])&&"0n+"+a7[2]||a7[2]);a7[2]=a6[1]+(a6[2]||1)-0;a7[3]=a6[3]-0}a7[0]=V++;return a7},ATTR:function(a8,a7,bb,a6,ba,a9){a7=a8[1].replace(/\\/g,"");if(!a9&&E.attrMap[a7]){a8[1]=E.attrMap[a7]}if(a8[2]==="~="){a8[4]=" "+a8[4]+" "}return a8},PSEUDO:function(a8,a7,ba,a6,a9){if(a8[1]==="not"){if((W.exec(a8[3])||"").length>1||/^\w/.test(a8[3])){a8[3]=S(a8[3],null,null,a7)}else{a8=S.filter(a8[3],a7,ba,true^a9);ba||a6.push.apply(a6,a8);return false}}else{if(E.match.POS.test(a8[0])||E.match.CHILD.test(a8[0])){return true}}return a8},POS:function(a6){a6.unshift(true);return a6}},filters:{enabled:function(a6){return a6.disabled===false&&a6.type!=="hidden"},disabled:function(a6){return a6.disabled===true},checked:function(a6){return a6.checked===true},selected:function(a6){return a6.selected===true},parent:function(a6){return !!a6.firstChild},empty:function(a6){return !a6.firstChild},has:function(a7,a6,a8){return !!S(a8[3],a7).length},header:function(a6){return/h\d/i.test(a6.nodeName)},text:function(a6){return"text"===a6.type},radio:function(a6){return"radio"===a6.type},checkbox:function(a6){return"checkbox"===a6.type},file:function(a6){return"file"===a6.type},password:function(a6){return"password"===a6.type},submit:function(a6){return"submit"===a6.type},image:function(a6){return"image"===a6.type},reset:function(a6){return"reset"===a6.type},button:function(a6){return"button"===a6.type||a6.nodeName.toLowerCase()==="button"},input:function(a6){return/input|select|textarea|button/i.test(a6.nodeName)}},setFilters:{first:function(a7,a6){return a6===0},last:function(a8,a7,a9,a6){return a7===a6.length-1},even:function(a7,a6){return a6%2===0},odd:function(a7,a6){return a6%2===1},lt:function(a7,a6,a8){return a6<a8[3]-0},gt:function(a7,a6,a8){return a6>a8[3]-0},nth:function(a7,a6,a8){return a8[3]-0===a6},eq:function(a7,a6,a8){return a8[3]-0===a6}},filter:{PSEUDO:function(a8,a7,bb,a6){var ba=a7[1],a9=E.filters[ba];if(a9){return a9(a8,bb,a7,a6)}else{if(ba==="contains"){return(a8.textContent||a8.innerText||S.getText([a8])||"").indexOf(a7[3])>=0}else{if(ba==="not"){a7=a7[3];bb=0;for(a6=a7.length;bb<a6;bb++){if(a7[bb]===a8){return false}}return true}else{S.error("Syntax error, unrecognized expression: "+ba)}}}},CHILD:function(a9,a8){var bd=a8[1],a6=a9;switch(bd){case"only":case"first":for(;a6=a6.previousSibling;){if(a6.nodeType===1){return false}}if(bd==="first"){return true}a6=a9;case"last":for(;a6=a6.nextSibling;){if(a6.nodeType===1){return false}}return true;case"nth":bd=a8[2];var bb=a8[3];if(bd===1&&bb===0){return true}var ba=a8[0],a7=a9.parentNode;if(a7&&(a7.sizcache!==ba||!a9.nodeIndex)){var bc=0;for(a6=a7.firstChild;a6;a6=a6.nextSibling){if(a6.nodeType===1){a6.nodeIndex=++bc}}a7.sizcache=ba}a6=a9.nodeIndex-bb;return bd===0?a6===0:a6%bd===0&&a6/bd>=0}},ID:function(a7,a6){return a7.nodeType===1&&a7.getAttribute("id")===a6},TAG:function(a7,a6){return a6==="*"&&a7.nodeType===1||a7.nodeName.toLowerCase()===a6},CLASS:function(a7,a6){return(" "+(a7.className||a7.getAttribute("class"))+" ").indexOf(a6)>-1},ATTR:function(a8,a7){var bb=a7[1];bb=E.attrHandle[bb]?E.attrHandle[bb](a8):a8[bb]!=null?a8[bb]:a8.getAttribute(bb);var a6=bb+"",ba=a7[2],a9=a7[4];return bb==null?ba==="!=":ba==="="?a6===a9:ba==="*="?a6.indexOf(a9)>=0:ba==="~="?(" "+a6+" ").indexOf(a9)>=0:!a9?a6&&bb!==false:ba==="!="?a6!==a9:ba==="^="?a6.indexOf(a9)===0:ba==="$="?a6.substr(a6.length-a9.length)===a9:ba==="|="?a6===a9||a6.substr(0,a9.length+1)===a9+"-":false},POS:function(a8,a7,ba,a6){var a9=E.setFilters[a7[2]];if(a9){return a9(a8,ba,a7,a6)}}}},aa=E.match.POS,c=function(a7,a6){return"\\"+(a6-0+1)},B;for(B in E.match){E.match[B]=RegExp(E.match[B].source+/(?![^\[]*\])(?![^\(]*\))/.source);E.leftMatch[B]=RegExp(/(^(?:.|\r|\n)*?)/.source+E.match[B].source.replace(/\\(\d+)/g,c))}var t=function(a7,a6){a7=Array.prototype.slice.call(a7,0);if(a6){a6.push.apply(a6,a7);return a6}return a7};try{Array.prototype.slice.call(I.documentElement.childNodes,0)}catch(Z){t=function(a8,a7){var ba=0,a6=a7||[];if(U.call(a8)==="[object Array]"){Array.prototype.push.apply(a6,a8)}else{if(typeof a8.length==="number"){for(var a9=a8.length;ba<a9;ba++){a6.push(a8[ba])}}else{for(;a8[ba];ba++){a6.push(a8[ba])}}}return a6}}var a5,a4;if(I.documentElement.compareDocumentPosition){a5=function(a7,a6){if(a7===a6){T=true;return 0}if(!a7.compareDocumentPosition||!a6.compareDocumentPosition){return a7.compareDocumentPosition?-1:1}return a7.compareDocumentPosition(a6)&4?-1:1}}else{a5=function(a9,a8){var bc,a6,bb=[],ba=[];bc=a9.parentNode;a6=a8.parentNode;var a7=bc;if(a9===a8){T=true;return 0}else{if(bc===a6){return a4(a9,a8)}else{if(bc){if(!a6){return 1}}else{return -1}}}for(;a7;){bb.unshift(a7);a7=a7.parentNode}for(a7=a6;a7;){ba.unshift(a7);a7=a7.parentNode}bc=bb.length;a6=ba.length;for(a7=0;a7<bc&&a7<a6;a7++){if(bb[a7]!==ba[a7]){return a4(bb[a7],ba[a7])}}return a7===bc?a4(a9,ba[a7],-1):a4(bb[a7],a8,1)};a4=function(a7,a6,a8){if(a7===a6){return a8}for(a7=a7.nextSibling;a7;){if(a7===a6){return -1}a7=a7.nextSibling}return 1}}S.getText=function(a8){for(var a7="",a9,a6=0;a8[a6];a6++){a9=a8[a6];if(a9.nodeType===3||a9.nodeType===4){a7+=a9.nodeValue}else{if(a9.nodeType!==8){a7+=S.getText(a9.childNodes)}}}return a7};(function(){var a7=I.createElement("div"),a6="script"+(new Date).getTime(),a8=I.documentElement;a7.innerHTML="<a name='"+a6+"'/>";a8.insertBefore(a7,a8.firstChild);if(I.getElementById(a6)){E.find.ID=function(a9,bb,ba){if(typeof bb.getElementById!=="undefined"&&!ba){return(bb=bb.getElementById(a9[1]))?bb.id===a9[1]||typeof bb.getAttributeNode!=="undefined"&&bb.getAttributeNode("id").nodeValue===a9[1]?[bb]:aB:[]}};E.filter.ID=function(a9,bb){var ba=typeof a9.getAttributeNode!=="undefined"&&a9.getAttributeNode("id");return a9.nodeType===1&&ba&&ba.nodeValue===bb}}a8.removeChild(a7);a8=a7=null})();(function(){var a6=I.createElement("div");a6.appendChild(I.createComment(""));if(a6.getElementsByTagName("*").length>0){E.find.TAG=function(a8,bb){var a7=bb.getElementsByTagName(a8[1]);if(a8[1]==="*"){for(var ba=[],a9=0;a7[a9];a9++){a7[a9].nodeType===1&&ba.push(a7[a9])}a7=ba}return a7}}a6.innerHTML="<a href='#'></a>";if(a6.firstChild&&typeof a6.firstChild.getAttribute!=="undefined"&&a6.firstChild.getAttribute("href")!=="#"){E.attrHandle.href=function(a7){return a7.getAttribute("href",2)}}a6=null})();I.querySelectorAll&&function(){var a7=S,a6=I.createElement("div");a6.innerHTML="<p class='TEST'></p>";if(!(a6.querySelectorAll&&a6.querySelectorAll(".TEST").length===0)){S=function(a9,bd,bc,ba){bd=bd||I;a9=a9.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!ba&&!S.isXML(bd)){if(bd.nodeType===9){try{return t(bd.querySelectorAll(a9),bc)}catch(bg){}}else{if(bd.nodeType===1&&bd.nodeName.toLowerCase()!=="object"){var bb=bd.getAttribute("id"),bf=bb||"__sizzle__";bb||bd.setAttribute("id",bf);try{return t(bd.querySelectorAll("#"+bf+" "+a9),bc)}catch(be){}finally{bb||bd.removeAttribute("id")}}}}return a7(a9,bd,bc,ba)};for(var a8 in a7){S[a8]=a7[a8]}a6=null}}();(function(){var a8=I.documentElement,a7=a8.matchesSelector||a8.mozMatchesSelector||a8.webkitMatchesSelector||a8.msMatchesSelector,a9=false;try{a7.call(I.documentElement,"[test!='']:sizzle")}catch(a6){a9=true}if(a7){S.matchesSelector=function(bc,bb){bb=bb.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!S.isXML(bc)){try{if(a9||!E.match.PSEUDO.test(bb)&&!/!=/.test(bb)){return a7.call(bc,bb)}}catch(ba){}}return S(bb,null,null,[bc]).length>0}}})();(function(){var a6=I.createElement("div");a6.innerHTML="<div class='test e'></div><div class='test'></div>";if(!(!a6.getElementsByClassName||a6.getElementsByClassName("e").length===0)){a6.lastChild.className="e";if(a6.getElementsByClassName("e").length!==1){E.order.splice(1,0,"CLASS");E.find.CLASS=function(a8,a9,a7){if(typeof a9.getElementsByClassName!=="undefined"&&!a7){return a9.getElementsByClassName(a8[1])}};a6=null}}})();S.contains=I.documentElement.contains?function(a7,a6){return a7!==a6&&(a7.contains?a7.contains(a6):true)}:I.documentElement.compareDocumentPosition?function(a7,a6){return !!(a7.compareDocumentPosition(a6)&16)}:function(){return false};S.isXML=function(a6){return(a6=(a6?a6.ownerDocument||a6:0).documentElement)?a6.nodeName!=="HTML":false};var X=function(a9,a8){for(var bc,a6=[],bb="",ba=a8.nodeType?[a8]:a8;bc=E.match.PSEUDO.exec(a9);){bb+=bc[0];a9=a9.replace(E.match.PSEUDO,"")}a9=E.relative[a9]?a9+"*":a9;bc=0;for(var a7=ba.length;bc<a7;bc++){S(a9,ba[bc],a6)}return S.filter(bb,a6)};R.find=S;R.expr=S.selectors;R.expr[":"]=R.expr.filters;R.unique=S.uniqueSort;R.text=S.getText;R.isXMLDoc=S.isXML;R.contains=S.contains})();var aU=/Until$/,aA=/^(?:parents|prevUntil|prevAll)/,aH=/,/,aR=/^.[^:#\[\.,]*$/,ap=Array.prototype.slice,J=R.expr.match.POS;R.fn.extend({find:function(B){for(var c=this.pushStack("","find",B),T=0,S=0,P=this.length;S<P;S++){T=c.length;R.find(B,this[S],c);if(S>0){for(var E=T;E<c.length;E++){for(var t=0;t<T;t++){if(c[t]===c[E]){c.splice(E--,1);break}}}}}return c},has:function(t){var c=R(t);return this.filter(function(){for(var E=0,B=c.length;E<B;E++){if(R.contains(this,c[E])){return true}}})},not:function(c){return this.pushStack(aM(this,c,false),"not",c)},filter:function(c){return this.pushStack(aM(this,c,true),"filter",c)},is:function(c){return !!c&&R.filter(c,this).length>0},closest:function(V,U){var T=[],S,P,E=this[0];if(R.isArray(V)){var t,B={},c=1;if(E&&V.length){S=0;for(P=V.length;S<P;S++){t=V[S];B[t]||(B[t]=R.expr.match.POS.test(t)?R(t,U||this.context):t)}for(;E&&E.ownerDocument&&E!==U;){for(t in B){S=B[t];if(S.jquery?S.index(E)>-1:R(E).is(S)){T.push({selector:t,elem:E,level:c})}}E=E.parentNode;c++}}return T}t=J.test(V)?R(V,U||this.context):null;S=0;for(P=this.length;S<P;S++){for(E=this[S];E;){if(t?t.index(E)>-1:R.find.matchesSelector(E,V)){T.push(E);break}else{E=E.parentNode;if(!E||!E.ownerDocument||E===U){break}}}}T=T.length>1?R.unique(T):T;return this.pushStack(T,"closest",V)},index:function(c){if(!c||typeof c==="string"){return R.inArray(this[0],c?R(c):this.parent().children())}return R.inArray(c.jquery?c[0]:c,this)},add:function(t,c){var E=typeof t==="string"?R(t,c||this.context):R.makeArray(t),B=R.merge(this.get(),E);return this.pushStack(!E[0]||!E[0].parentNode||E[0].parentNode.nodeType===11||!B[0]||!B[0].parentNode||B[0].parentNode.nodeType===11?B:R.unique(B))},andSelf:function(){return this.add(this.prevObject)}});R.each({parent:function(c){return(c=c.parentNode)&&c.nodeType!==11?c:null},parents:function(c){return R.dir(c,"parentNode")},parentsUntil:function(t,c,B){return R.dir(t,"parentNode",B)},next:function(c){return R.nth(c,2,"nextSibling")},prev:function(c){return R.nth(c,2,"previousSibling")},nextAll:function(c){return R.dir(c,"nextSibling")},prevAll:function(c){return R.dir(c,"previousSibling")},nextUntil:function(t,c,B){return R.dir(t,"nextSibling",B)},prevUntil:function(t,c,B){return R.dir(t,"previousSibling",B)},siblings:function(c){return R.sibling(c.parentNode.firstChild,c)},children:function(c){return R.sibling(c.firstChild)},contents:function(c){return R.nodeName(c,"iframe")?c.contentDocument||c.contentWindow.document:R.makeArray(c.childNodes)}},function(t,c){R.fn[t]=function(P,E){var B=R.map(this,c,P);aU.test(t)||(E=P);if(E&&typeof E==="string"){B=R.filter(E,B)}B=this.length>1?R.unique(B):B;if((this.length>1||aH.test(E))&&aA.test(t)){B=B.reverse()}return this.pushStack(B,t,ap.call(arguments).join(","))}});R.extend({filter:function(t,c,B){if(B){t=":not("+t+")"}return c.length===1?R.find.matchesSelector(c[0],t)?[c[0]]:[]:R.find.matches(t,c)},dir:function(t,c,E){var B=[];for(t=t[c];t&&t.nodeType!==9&&(E===aB||t.nodeType!==1||!R(t).is(E));){t.nodeType===1&&B.push(t);t=t[c]}return B},nth:function(t,c,E){c=c||1;for(var B=0;t;t=t[E]){if(t.nodeType===1&&++B===c){break}}return t},sibling:function(t,c){for(var B=[];t;t=t.nextSibling){t.nodeType===1&&t!==c&&B.push(t)}return B}});var aF=/ jQuery\d+="(?:\d+|null)"/g,aO=/^\s+/,aX=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,aK=/<([\w:]+)/,u=/<tbody/i,f=/<|&#?\w+;/,av=/<(?:script|object|embed|option|style)/i,N=/checked\s*(?:[^=]|=\s*.checked.)/i,aV=/\=([^="'>\s]+\/)>/g,aq={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]};aq.optgroup=aq.option;aq.tbody=aq.tfoot=aq.colgroup=aq.caption=aq.thead;aq.th=aq.td;if(!R.support.htmlSerialize){aq._default=[1,"div<div>","</div>"]}R.fn.extend({text:function(c){if(R.isFunction(c)){return this.each(function(t){var B=R(this);B.text(c.call(this,t,B.text()))})}if(typeof c!=="object"&&c!==aB){return this.empty().append((this[0]&&this[0].ownerDocument||I).createTextNode(c))}return R.text(this)},wrapAll:function(t){if(R.isFunction(t)){return this.each(function(B){R(this).wrapAll(t.call(this,B))})}if(this[0]){var c=R(t,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&c.insertBefore(this[0]);c.map(function(){for(var B=this;B.firstChild&&B.firstChild.nodeType===1;){B=B.firstChild}return B}).append(this)}return this},wrapInner:function(c){if(R.isFunction(c)){return this.each(function(t){R(this).wrapInner(c.call(this,t))})}return this.each(function(){var t=R(this),B=t.contents();B.length?B.wrapAll(c):t.append(c)})},wrap:function(c){return this.each(function(){R(this).wrapAll(c)})},unwrap:function(){return this.parent().each(function(){R.nodeName(this,"body")||R(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(c){this.nodeType===1&&this.appendChild(c)})},prepend:function(){return this.domManip(arguments,true,function(c){this.nodeType===1&&this.insertBefore(c,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode){return this.domManip(arguments,false,function(t){this.parentNode.insertBefore(t,this)})}else{if(arguments.length){var c=R(arguments[0]);c.push.apply(c,this.toArray());return this.pushStack(c,"before",arguments)}}},after:function(){if(this[0]&&this[0].parentNode){return this.domManip(arguments,false,function(t){this.parentNode.insertBefore(t,this.nextSibling)})}else{if(arguments.length){var c=this.pushStack(this,"after",arguments);c.push.apply(c,R(arguments[0]).toArray());return c}}},remove:function(t,c){for(var E=0,B;(B=this[E])!=null;E++){if(!t||R.filter(t,[B]).length){if(!c&&B.nodeType===1){R.cleanData(B.getElementsByTagName("*"));R.cleanData([B])}B.parentNode&&B.parentNode.removeChild(B)}}return this},empty:function(){for(var t=0,c;(c=this[t])!=null;t++){for(c.nodeType===1&&R.cleanData(c.getElementsByTagName("*"));c.firstChild;){c.removeChild(c.firstChild)}}return this},clone:function(t){var c=this.map(function(){if(!R.support.noCloneEvent&&!R.isXMLDoc(this)){var E=this.outerHTML,B=this.ownerDocument;if(!E){E=B.createElement("div");E.appendChild(this.cloneNode(true));E=E.innerHTML}return R.clean([E.replace(aF,"").replace(aV,'="$1">').replace(aO,"")],B)[0]}else{return this.cloneNode(true)}});if(t===true){ay(this,c);ay(this.find("*"),c.find("*"))}return c},html:function(t){if(t===aB){return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(aF,""):null}else{if(typeof t==="string"&&!av.test(t)&&(R.support.leadingWhitespace||!aO.test(t))&&!aq[(aK.exec(t)||["",""])[1].toLowerCase()]){t=t.replace(aX,"<$1></$2>");try{for(var c=0,E=this.length;c<E;c++){if(this[c].nodeType===1){R.cleanData(this[c].getElementsByTagName("*"));this[c].innerHTML=t}}}catch(B){this.empty().append(t)}}else{R.isFunction(t)?this.each(function(S){var P=R(this);P.html(t.call(this,S,P.html()))}):this.empty().append(t)}}return this},replaceWith:function(c){if(this[0]&&this[0].parentNode){if(R.isFunction(c)){return this.each(function(t){var E=R(this),B=E.html();E.replaceWith(c.call(this,t,B))})}if(typeof c!=="string"){c=R(c).detach()}return this.each(function(){var t=this.nextSibling,B=this.parentNode;R(this).remove();t?R(t).before(c):R(B).append(c)})}else{return this.pushStack(R(R.isFunction(c)?c():c),"replaceWith",c)}},detach:function(c){return this.remove(c,true)},domManip:function(V,U,T){var S,P,E,t=V[0],B=[];if(!R.support.checkClone&&arguments.length===3&&typeof t==="string"&&N.test(t)){return this.each(function(){R(this).domManip(V,U,T,true)})}if(R.isFunction(t)){return this.each(function(W){var X=R(this);V[0]=t.call(this,W,U?X.html():aB);X.domManip(V,U,T)})}if(this[0]){S=t&&t.parentNode;S=R.support.parentNode&&S&&S.nodeType===11&&S.childNodes.length===this.length?{fragment:S}:R.buildFragment(V,this,B);E=S.fragment;if(P=E.childNodes.length===1?E=E.firstChild:E.firstChild){U=U&&R.nodeName(P,"tr");P=0;for(var c=this.length;P<c;P++){T.call(U?R.nodeName(this[P],"table")?this[P].getElementsByTagName("tbody")[0]||this[P].appendChild(this[P].ownerDocument.createElement("tbody")):this[P]:this[P],P>0||S.cacheable||this.length>1?E.cloneNode(true):E)}}B.length&&R.each(B,aE)}return this}});R.buildFragment=function(t,c,S){var P,E,B;c=c&&c[0]?c[0].ownerDocument||c[0]:I;if(t.length===1&&typeof t[0]==="string"&&t[0].length<512&&c===I&&!av.test(t[0])&&(R.support.checkClone||!N.test(t[0]))){E=true;if(B=R.fragments[t[0]]){if(B!==1){P=B}}}if(!P){P=c.createDocumentFragment();R.clean(t,c,P,S)}if(E){R.fragments[t[0]]=B?P:1}return{fragment:P,cacheable:E}};R.fragments={};R.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,c){R.fn[t]=function(T){var S=[];T=R(T);var P=this.length===1&&this[0].parentNode;if(P&&P.nodeType===11&&P.childNodes.length===1&&T.length===1){T[c](this[0]);return this}else{P=0;for(var E=T.length;P<E;P++){var B=(P>0?this.clone(true):this).get();R(T[P])[c](B);S=S.concat(B)}return this.pushStack(S,t,T.selector)}}});R.extend({clean:function(X,V,U,T){V=V||I;if(typeof V.createElement==="undefined"){V=V.ownerDocument||V[0]&&V[0].ownerDocument||I}for(var S=[],P=0,B;(B=X[P])!=null;P++){if(typeof B==="number"){B+=""}if(B){if(typeof B==="string"&&!f.test(B)){B=V.createTextNode(B)}else{if(typeof B==="string"){B=B.replace(aX,"<$1></$2>");var E=(aK.exec(B)||["",""])[1].toLowerCase(),t=aq[E]||aq._default,W=t[0],c=V.createElement("div");for(c.innerHTML=t[1]+B+t[2];W--;){c=c.lastChild}if(!R.support.tbody){W=u.test(B);E=E==="table"&&!W?c.firstChild&&c.firstChild.childNodes:t[1]==="<table>"&&!W?c.childNodes:[];for(t=E.length-1;t>=0;--t){R.nodeName(E[t],"tbody")&&!E[t].childNodes.length&&E[t].parentNode.removeChild(E[t])}}!R.support.leadingWhitespace&&aO.test(B)&&c.insertBefore(V.createTextNode(aO.exec(B)[0]),c.firstChild);B=c.childNodes}}if(B.nodeType){S.push(B)}else{S=R.merge(S,B)}}}if(U){for(P=0;S[P];P++){if(T&&R.nodeName(S[P],"script")&&(!S[P].type||S[P].type.toLowerCase()==="text/javascript")){T.push(S[P].parentNode?S[P].parentNode.removeChild(S[P]):S[P])}else{S[P].nodeType===1&&S.splice.apply(S,[P+1,0].concat(R.makeArray(S[P].getElementsByTagName("script"))));U.appendChild(S[P])}}}return S},cleanData:function(V){for(var U,T,S=R.cache,P=R.event.special,E=R.support.deleteExpando,t=0,B;(B=V[t])!=null;t++){if(!(B.nodeName&&R.noData[B.nodeName.toLowerCase()])){if(T=B[R.expando]){if((U=S[T])&&U.events){for(var c in U.events){P[c]?R.event.remove(B,c):R.removeEvent(B,c,U.handle)}}if(E){delete B[R.expando]}else{B.removeAttribute&&B.removeAttribute(R.expando)}delete S[T]}}}}});var y=/alpha\([^)]*\)/i,aJ=/opacity=([^)]*)/,at=/-([a-z])/ig,L=/([A-Z])/g,j=/^-?\d+(?:px)?$/i,w=/^-?\d/,h={position:"absolute",visibility:"hidden",display:"block"},af=["Left","Right"],G=["Top","Bottom"],ak,a0,aI,aY=function(t,c){return c.toUpperCase()};R.fn.css=function(t,c){if(arguments.length===2&&c===aB){return this}return R.access(this,t,c,true,function(P,E,B){return B!==aB?R.style(P,E,B):R.css(P,E)})};R.extend({cssHooks:{opacity:{get:function(t,c){if(c){var B=ak(t,"opacity","opacity");return B===""?"1":B}else{return t.style.opacity}}}},cssNumber:{zIndex:true,fontWeight:true,opacity:true,zoom:true,lineHeight:true},cssProps:{"float":R.support.cssFloat?"cssFloat":"styleFloat"},style:function(V,U,T,S){if(!(!V||V.nodeType===3||V.nodeType===8||!V.style)){var P,E=R.camelCase(U),t=V.style,B=R.cssHooks[E];U=R.cssProps[E]||E;if(T!==aB){if(!(typeof T==="number"&&isNaN(T)||T==null)){if(typeof T==="number"&&!R.cssNumber[E]){T+="px"}if(!B||!("set" in B)||(T=B.set(V,T))!==aB){try{t[U]=T}catch(c){}}}}else{if(B&&"get" in B&&(P=B.get(V,false,S))!==aB){return P}return t[U]}}},css:function(t,c,S){var P,E=R.camelCase(c),B=R.cssHooks[E];c=R.cssProps[E]||E;if(B&&"get" in B&&(P=B.get(t,true,S))!==aB){return P}else{if(ak){return ak(t,c,E)}}},swap:function(t,c,P){var E={},B;for(B in c){E[B]=t.style[B];t.style[B]=c[B]}P.call(t);for(B in c){t.style[B]=E[B]}},camelCase:function(c){return c.replace(at,aY)}});R.curCSS=R.css;R.each(["height","width"],function(t,c){R.cssHooks[c]={get:function(S,P,E){var B;if(P){if(S.offsetWidth!==0){B=Q(S,c,E)}else{R.swap(S,h,function(){B=Q(S,c,E)})}if(B<=0){B=ak(S,c,c);if(B==="0px"&&aI){B=aI(S,c,c)}if(B!=null){return B===""||B==="auto"?"0px":B}}if(B<0||B==null){B=S.style[c];return B===""||B==="auto"?"0px":B}return typeof B==="string"?B:B+"px"}},set:function(E,B){if(j.test(B)){B=parseFloat(B);if(B>=0){return B+"px"}}else{return B}}}});if(!R.support.opacity){R.cssHooks.opacity={get:function(t,c){return aJ.test((c&&t.currentStyle?t.currentStyle.filter:t.style.filter)||"")?parseFloat(RegExp.$1)/100+"":c?"1":""},set:function(t,c){var P=t.style;P.zoom=1;var E=R.isNaN(c)?"":"alpha(opacity="+c*100+")",B=P.filter||"";P.filter=y.test(B)?B.replace(y,E):P.filter+" "+E}}}if(I.defaultView&&I.defaultView.getComputedStyle){a0=function(t,c,E){var B;E=E.replace(L,"-$1").toLowerCase();if(!(c=t.ownerDocument.defaultView)){return aB}if(c=c.getComputedStyle(t,null)){B=c.getPropertyValue(E);if(B===""&&!R.contains(t.ownerDocument.documentElement,t)){B=R.style(t,E)}}return B}}if(I.documentElement.currentStyle){aI=function(t,c){var S,P,E=t.currentStyle&&t.currentStyle[c],B=t.style;if(!j.test(E)&&w.test(E)){S=B.left;P=t.runtimeStyle.left;t.runtimeStyle.left=t.currentStyle.left;B.left=c==="fontSize"?"1em":E||0;E=B.pixelLeft+"px";B.left=S;t.runtimeStyle.left=P}return E===""?"auto":E}}ak=a0||aI;if(R.expr&&R.expr.filters){R.expr.filters.hidden=function(t){var c=t.offsetHeight;return t.offsetWidth===0&&c===0||!R.support.reliableHiddenOffsets&&(t.style.display||R.css(t,"display"))==="none"};R.expr.filters.visible=function(c){return !R.expr.filters.hidden(c)}}var aL=R.now(),aw=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,O=/^(?:select|textarea)/i,z=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,k=/^(?:GET|HEAD)$/,r=/\[\]$/,an=/\=\?(&|$)/,x=/\?/,a1=/([?&])_=[^&]*/,aP=/^(\w+:)?\/\/([^\/?#]+)/,aC=/%20/g,ad=/#.*$/,aN=R.fn.load;R.fn.extend({load:function(t,c,S){if(typeof t!=="string"&&aN){return aN.apply(this,arguments)}else{if(!this.length){return this}}var P=t.indexOf(" ");if(P>=0){var E=t.slice(P,t.length);t=t.slice(0,P)}P="GET";if(c){if(R.isFunction(c)){S=c;c=null}else{if(typeof c==="object"){c=R.param(c,R.ajaxSettings.traditional);P="POST"}}}var B=this;R.ajax({url:t,type:P,dataType:"html",data:c,complete:function(T,U){if(U==="success"||U==="notmodified"){B.html(E?R("<div>").append(T.responseText.replace(aw,"")).find(E):T.responseText)}S&&B.each(S,[T.responseText,U,T])}});return this},serialize:function(){return R.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?R.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||O.test(this.nodeName)||z.test(this.type))}).map(function(t,c){var B=R(this).val();return B==null?null:R.isArray(B)?R.map(B,function(E){return{name:c.name,value:E}}):{name:c.name,value:B}}).get()}});R.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(t,c){R.fn[c]=function(B){return this.bind(c,B)}});R.extend({get:function(t,c,E,B){if(R.isFunction(c)){B=B||E;E=c;c=null}return R.ajax({type:"GET",url:t,data:c,success:E,dataType:B})},getScript:function(t,c){return R.get(t,null,c,"script")},getJSON:function(t,c,B){return R.get(t,c,B,"json")},post:function(t,c,E,B){if(R.isFunction(c)){B=B||E;E=c;c={}}return R.ajax({type:"POST",url:t,data:c,success:E,dataType:B})},ajaxSetup:function(c){R.extend(R.ajaxSettings,c)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return new ax.XMLHttpRequest},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},ajax:function(a8){var a7=R.extend(true,{},R.ajaxSettings,a8),a6,a5,a4,aa=a7.type.toUpperCase(),X=k.test(aa);a7.url=a7.url.replace(ad,"");a7.context=a8&&a8.context!=null?a8.context:a7;if(a7.data&&a7.processData&&typeof a7.data!=="string"){a7.data=R.param(a7.data,a7.traditional)}if(a7.dataType==="jsonp"){if(aa==="GET"){an.test(a7.url)||(a7.url+=(x.test(a7.url)?"&":"?")+(a7.jsonp||"callback")+"=?")}else{if(!a7.data||!an.test(a7.data)){a7.data=(a7.data?a7.data+"&":"")+(a7.jsonp||"callback")+"=?"}}a7.dataType="json"}if(a7.dataType==="json"&&(a7.data&&an.test(a7.data)||an.test(a7.url))){a6=a7.jsonpCallback||"jsonp"+aL++;if(a7.data){a7.data=(a7.data+"").replace(an,"="+a6+"$1")}a7.url=a7.url.replace(an,"="+a6+"$1");a7.dataType="script";var Y=ax[a6];ax[a6]=function(a9){if(R.isFunction(Y)){Y(a9)}else{ax[a6]=aB;try{delete ax[a6]}catch(ba){}}a4=a9;R.handleSuccess(a7,P,a5,a4);R.handleComplete(a7,P,a5,a4);T&&T.removeChild(U)}}if(a7.dataType==="script"&&a7.cache===null){a7.cache=false}if(a7.cache===false&&X){var V=R.now(),E=a7.url.replace(a1,"$1_="+V);a7.url=E+(E===a7.url?(x.test(a7.url)?"&":"?")+"_="+V:"")}if(a7.data&&X){a7.url+=(x.test(a7.url)?"&":"?")+a7.data}a7.global&&R.active++===0&&R.event.trigger("ajaxStart");V=(V=aP.exec(a7.url))&&(V[1]&&V[1].toLowerCase()!==location.protocol||V[2].toLowerCase()!==location.host);if(a7.dataType==="script"&&aa==="GET"&&V){var T=I.getElementsByTagName("head")[0]||I.documentElement,U=I.createElement("script");if(a7.scriptCharset){U.charset=a7.scriptCharset}U.src=a7.url;if(!a6){var S=false;U.onload=U.onreadystatechange=function(){if(!S&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){S=true;R.handleSuccess(a7,P,a5,a4);R.handleComplete(a7,P,a5,a4);U.onload=U.onreadystatechange=null;T&&U.parentNode&&T.removeChild(U)}}}T.insertBefore(U,T.firstChild);return aB}var t=false,P=a7.xhr();if(P){a7.username?P.open(aa,a7.url,a7.async,a7.username,a7.password):P.open(aa,a7.url,a7.async);try{if(a7.data!=null&&!X||a8&&a8.contentType){P.setRequestHeader("Content-Type",a7.contentType)}if(a7.ifModified){R.lastModified[a7.url]&&P.setRequestHeader("If-Modified-Since",R.lastModified[a7.url]);R.etag[a7.url]&&P.setRequestHeader("If-None-Match",R.etag[a7.url])}V||P.setRequestHeader("X-Requested-With","XMLHttpRequest");P.setRequestHeader("Accept",a7.dataType&&a7.accepts[a7.dataType]?a7.accepts[a7.dataType]+", */*; q=0.01":a7.accepts._default)}catch(B){}if(a7.beforeSend&&a7.beforeSend.call(a7.context,P,a7)===false){a7.global&&R.active--===1&&R.event.trigger("ajaxStop");P.abort();return false}a7.global&&R.triggerGlobal(a7,"ajaxSend",[P,a7]);var c=P.onreadystatechange=function(a9){if(!P||P.readyState===0||a9==="abort"){t||R.handleComplete(a7,P,a5,a4);t=true;if(P){P.onreadystatechange=R.noop}}else{if(!t&&P&&(P.readyState===4||a9==="timeout")){t=true;P.onreadystatechange=R.noop;a5=a9==="timeout"?"timeout":!R.httpSuccess(P)?"error":a7.ifModified&&R.httpNotModified(P,a7.url)?"notmodified":"success";var bb;if(a5==="success"){try{a4=R.httpData(P,a7.dataType,a7)}catch(ba){a5="parsererror";bb=ba}}if(a5==="success"||a5==="notmodified"){a6||R.handleSuccess(a7,P,a5,a4)}else{R.handleError(a7,P,a5,bb)}a6||R.handleComplete(a7,P,a5,a4);a9==="timeout"&&P.abort();if(a7.async){P=null}}}};try{var ab=P.abort;P.abort=function(){P&&Function.prototype.call.call(ab,P);c("abort")}}catch(Z){}a7.async&&a7.timeout>0&&setTimeout(function(){P&&!t&&c("timeout")},a7.timeout);try{P.send(X||a7.data==null?null:a7.data)}catch(W){R.handleError(a7,P,null,W);R.handleComplete(a7,P,a5,a4)}a7.async||c();return P}},param:function(t,c){var P=[],E=function(T,S){S=R.isFunction(S)?S():S;P[P.length]=encodeURIComponent(T)+"="+encodeURIComponent(S)};if(c===aB){c=R.ajaxSettings.traditional}if(R.isArray(t)||t.jquery){R.each(t,function(){E(this.name,this.value)})}else{for(var B in t){v(B,t[B],c,E)}}return P.join("&").replace(aC,"+")}});R.extend({active:0,lastModified:{},etag:{},handleError:function(t,c,E,B){t.error&&t.error.call(t.context,c,E,B);t.global&&R.triggerGlobal(t,"ajaxError",[c,t,B])},handleSuccess:function(t,c,E,B){t.success&&t.success.call(t.context,B,E,c);t.global&&R.triggerGlobal(t,"ajaxSuccess",[c,t])},handleComplete:function(t,c,B){t.complete&&t.complete.call(t.context,c,B);t.global&&R.triggerGlobal(t,"ajaxComplete",[c,t]);t.global&&R.active--===1&&R.event.trigger("ajaxStop")},triggerGlobal:function(t,c,B){(t.context&&t.context.url==null?R(t.context):R.event).trigger(c,B)},httpSuccess:function(t){try{return !t.status&&location.protocol==="file:"||t.status>=200&&t.status<300||t.status===304||t.status===1223}catch(c){}return false},httpNotModified:function(t,c){var E=t.getResponseHeader("Last-Modified"),B=t.getResponseHeader("Etag");if(E){R.lastModified[c]=E}if(B){R.etag[c]=B}return t.status===304},httpData:function(t,c,P){var E=t.getResponseHeader("content-type")||"",B=c==="xml"||!c&&E.indexOf("xml")>=0;t=B?t.responseXML:t.responseText;B&&t.documentElement.nodeName==="parsererror"&&R.error("parsererror");if(P&&P.dataFilter){t=P.dataFilter(t,c)}if(typeof t==="string"){if(c==="json"||!c&&E.indexOf("json")>=0){t=R.parseJSON(t)}else{if(c==="script"||!c&&E.indexOf("javascript")>=0){R.globalEval(t)}}}return t}});if(ax.ActiveXObject){R.ajaxSettings.xhr=function(){if(ax.location.protocol!=="file:"){try{return new ax.XMLHttpRequest}catch(t){}}try{return new ax.ActiveXObject("Microsoft.XMLHTTP")}catch(c){}}}R.support.ajax=!!R.ajaxSettings.xhr();var g={},D=/^(?:toggle|show|hide)$/,o=/^([+\-]=)?([\d+.\-]+)(.*)$/,ar,A=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];R.fn.extend({show:function(t,c,E){if(t||t===0){return this.animate(ao("show",3),t,c,E)}else{E=0;for(var B=this.length;E<B;E++){t=this[E];c=t.style.display;if(!R.data(t,"olddisplay")&&c==="none"){c=t.style.display=""}c===""&&R.css(t,"display")==="none"&&R.data(t,"olddisplay",l(t.nodeName))}for(E=0;E<B;E++){t=this[E];c=t.style.display;if(c===""||c==="none"){t.style.display=R.data(t,"olddisplay")||""}}return this}},hide:function(t,c,B){if(t||t===0){return this.animate(ao("hide",3),t,c,B)}else{t=0;for(c=this.length;t<c;t++){B=R.css(this[t],"display");B!=="none"&&R.data(this[t],"olddisplay",B)}for(t=0;t<c;t++){this[t].style.display="none"}return this}},_toggle:R.fn.toggle,toggle:function(t,c,E){var B=typeof t==="boolean";if(R.isFunction(t)&&R.isFunction(c)){this._toggle.apply(this,arguments)}else{t==null||B?this.each(function(){var P=B?t:R(this).is(":hidden");R(this)[P?"show":"hide"]()}):this.animate(ao("toggle",3),t,c,E)}return this},fadeTo:function(t,c,E,B){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:c},t,E,B)},animate:function(t,c,P,E){var B=R.speed(c,P,E);if(R.isEmptyObject(t)){return this.each(B.complete)}return this[B.queue===false?"each":"queue"](function(){var V=R.extend({},B),T,U=this.nodeType===1,X=U&&R(this).is(":hidden"),S=this;for(T in t){var W=R.camelCase(T);if(T!==W){t[W]=t[T];delete t[T];T=W}if(t[T]==="hide"&&X||t[T]==="show"&&!X){return V.complete.call(this)}if(U&&(T==="height"||T==="width")){V.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY];if(R.css(this,"display")==="inline"&&R.css(this,"float")==="none"){if(R.support.inlineBlockNeedsLayout){if(l(this.nodeName)==="inline"){this.style.display="inline-block"}else{this.style.display="inline";this.style.zoom=1}}else{this.style.display="inline-block"}}}if(R.isArray(t[T])){(V.specialEasing=V.specialEasing||{})[T]=t[T][1];t[T]=t[T][0]}}if(V.overflow!=null){this.style.overflow="hidden"}V.curAnim=R.extend({},t);R.each(t,function(Z,a6){var ab=new R.fx(S,V,Z);if(D.test(a6)){ab[a6==="toggle"?X?"show":"hide":a6](t)}else{var aa=o.exec(a6),a4=ab.cur()||0;if(aa){var Y=parseFloat(aa[2]),a5=aa[3]||"px";if(a5!=="px"){R.style(S,Z,(Y||1)+a5);a4=(Y||1)/ab.cur()*a4;R.style(S,Z,a4+a5)}if(aa[1]){Y=(aa[1]==="-="?-1:1)*Y+a4}ab.custom(a4,Y,a5)}else{ab.custom(a4,a6,"")}}});return true})},stop:function(t,c){var B=R.timers;t&&this.queue([]);this.each(function(){for(var E=B.length-1;E>=0;E--){if(B[E].elem===this){c&&B[E](true);B.splice(E,1)}}});c||this.dequeue();return this}});R.each({slideDown:ao("show",1),slideUp:ao("hide",1),slideToggle:ao("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,c){R.fn[t]=function(P,E,B){return this.animate(c,P,E,B)}});R.extend({speed:function(t,c,E){var B=t&&typeof t==="object"?R.extend({},t):{complete:E||!E&&c||R.isFunction(t)&&t,duration:t,easing:E&&c||c&&!R.isFunction(c)&&c};B.duration=R.fx.off?0:typeof B.duration==="number"?B.duration:B.duration in R.fx.speeds?R.fx.speeds[B.duration]:R.fx.speeds._default;B.old=B.complete;B.complete=function(){B.queue!==false&&R(this).dequeue();R.isFunction(B.old)&&B.old.call(this)};return B},easing:{linear:function(t,c,E,B){return E+B*t},swing:function(t,c,E,B){return(-Math.cos(t*Math.PI)/2+0.5)*B+E}},timers:[],fx:function(t,c,B){this.options=c;this.elem=t;this.prop=B;if(!c.orig){c.orig={}}}});R.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(R.fx.step[this.prop]||R.fx.step._default)(this)},cur:function(){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var c=parseFloat(R.css(this.elem,this.prop));return c&&c>-10000?c:0},custom:function(t,c,S){function P(T){return E.step(T)}var E=this,B=R.fx;this.startTime=R.now();this.start=t;this.end=c;this.unit=S||this.unit||"px";this.now=this.start;this.pos=this.state=0;P.elem=this.elem;if(P()&&R.timers.push(P)&&!ar){ar=setInterval(B.tick,B.interval)}},show:function(){this.options.orig[this.prop]=R.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());R(this.elem).show()},hide:function(){this.options.orig[this.prop]=R.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(B){var c=R.now(),T=true;if(B||c>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var S in this.options.curAnim){if(this.options.curAnim[S]!==true){T=false}}if(T){if(this.options.overflow!=null&&!R.support.shrinkWrapBlocks){var P=this.elem,E=this.options;R.each(["","X","Y"],function(U,V){P.style["overflow"+V]=E.overflow[U]})}this.options.hide&&R(this.elem).hide();if(this.options.hide||this.options.show){for(var t in this.options.curAnim){R.style(this.elem,t,this.options.orig[t])}}this.options.complete.call(this.elem)}return false}else{B=c-this.startTime;this.state=B/this.options.duration;c=this.options.easing||(R.easing.swing?"swing":"linear");this.pos=R.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||c](this.state,B,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};R.extend(R.fx,{tick:function(){for(var t=R.timers,c=0;c<t.length;c++){t[c]()||t.splice(c--,1)}t.length||R.fx.stop()},interval:13,stop:function(){clearInterval(ar);ar=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(c){R.style(c.elem,"opacity",c.now)},_default:function(c){if(c.elem.style&&c.elem.style[c.prop]!=null){c.elem.style[c.prop]=(c.prop==="width"||c.prop==="height"?Math.max(0,c.now):c.now)+c.unit}else{c.elem[c.prop]=c.now}}}});if(R.expr&&R.expr.filters){R.expr.filters.animated=function(c){return R.grep(R.timers,function(t){return c===t.elem}).length}}var a=/^t(?:able|d|h)$/i,az=/^(?:body|html)$/i;R.fn.offset="getBoundingClientRect" in I.documentElement?function(t){var c=this[0],S;if(t){return this.each(function(T){R.offset.setOffset(this,t,T)})}if(!c||!c.ownerDocument){return null}if(c===c.ownerDocument.body){return R.offset.bodyOffset(c)}try{S=c.getBoundingClientRect()}catch(P){}var E=c.ownerDocument,B=E.documentElement;if(!S||!R.contains(B,c)){return S||{top:0,left:0}}c=E.body;E=aW(E);return{top:S.top+(E.pageYOffset||R.support.boxModel&&B.scrollTop||c.scrollTop)-(B.clientTop||c.clientTop||0),left:S.left+(E.pageXOffset||R.support.boxModel&&B.scrollLeft||c.scrollLeft)-(B.clientLeft||c.clientLeft||0)}}:function(V){var U=this[0];if(V){return this.each(function(W){R.offset.setOffset(this,V,W)})}if(!U||!U.ownerDocument){return null}if(U===U.ownerDocument.body){return R.offset.bodyOffset(U)}R.offset.initialize();var T,S=U.offsetParent,P=U.ownerDocument,E=P.documentElement,t=P.body;T=(P=P.defaultView)?P.getComputedStyle(U,null):U.currentStyle;for(var B=U.offsetTop,c=U.offsetLeft;(U=U.parentNode)&&U!==t&&U!==E;){if(R.offset.supportsFixedPosition&&T.position==="fixed"){break}T=P?P.getComputedStyle(U,null):U.currentStyle;B-=U.scrollTop;c-=U.scrollLeft;if(U===S){B+=U.offsetTop;c+=U.offsetLeft;if(R.offset.doesNotAddBorder&&!(R.offset.doesAddBorderForTableAndCells&&a.test(U.nodeName))){B+=parseFloat(T.borderTopWidth)||0;c+=parseFloat(T.borderLeftWidth)||0}S=U.offsetParent}if(R.offset.subtractsBorderForOverflowNotVisible&&T.overflow!=="visible"){B+=parseFloat(T.borderTopWidth)||0;c+=parseFloat(T.borderLeftWidth)||0}T=T}if(T.position==="relative"||T.position==="static"){B+=t.offsetTop;c+=t.offsetLeft}if(R.offset.supportsFixedPosition&&T.position==="fixed"){B+=Math.max(E.scrollTop,t.scrollTop);c+=Math.max(E.scrollLeft,t.scrollLeft)}return{top:B,left:c}};R.offset={initialize:function(){var t=I.body,c=I.createElement("div"),S,P,E,B=parseFloat(R.css(t,"marginTop"))||0;R.extend(c.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"});c.innerHTML="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";t.insertBefore(c,t.firstChild);S=c.firstChild;P=S.firstChild;E=S.nextSibling.firstChild.firstChild;this.doesNotAddBorder=P.offsetTop!==5;this.doesAddBorderForTableAndCells=E.offsetTop===5;P.style.position="fixed";P.style.top="20px";this.supportsFixedPosition=P.offsetTop===20||P.offsetTop===15;P.style.position=P.style.top="";S.style.overflow="hidden";S.style.position="relative";this.subtractsBorderForOverflowNotVisible=P.offsetTop===-5;this.doesNotIncludeMarginInBodyOffset=t.offsetTop!==B;t.removeChild(c);R.offset.initialize=R.noop},bodyOffset:function(t){var c=t.offsetTop,B=t.offsetLeft;R.offset.initialize();if(R.offset.doesNotIncludeMarginInBodyOffset){c+=parseFloat(R.css(t,"marginTop"))||0;B+=parseFloat(R.css(t,"marginLeft"))||0}return{top:c,left:B}},setOffset:function(W,U,T){var S=R.css(W,"position");if(S==="static"){W.style.position="relative"}var P=R(W),E=P.offset(),t=R.css(W,"top"),B=R.css(W,"left"),c=S==="absolute"&&R.inArray("auto",[t,B])>-1;S={};var V={};if(c){V=P.position()}t=c?V.top:parseInt(t,10)||0;B=c?V.left:parseInt(B,10)||0;if(R.isFunction(U)){U=U.call(W,T,E)}if(U.top!=null){S.top=U.top-E.top+t}if(U.left!=null){S.left=U.left-E.left+B}"using" in U?U.using.call(W,S):P.css(S)}};R.fn.extend({position:function(){if(!this[0]){return null}var t=this[0],c=this.offsetParent(),E=this.offset(),B=az.test(c[0].nodeName)?{top:0,left:0}:c.offset();E.top-=parseFloat(R.css(t,"marginTop"))||0;E.left-=parseFloat(R.css(t,"marginLeft"))||0;B.top+=parseFloat(R.css(c[0],"borderTopWidth"))||0;B.left+=parseFloat(R.css(c[0],"borderLeftWidth"))||0;return{top:E.top-B.top,left:E.left-B.left}},offsetParent:function(){return this.map(function(){for(var c=this.offsetParent||I.body;c&&!az.test(c.nodeName)&&R.css(c,"position")==="static";){c=c.offsetParent}return c})}});R.each(["Left","Top"],function(t,c){var B="scroll"+c;R.fn[B]=function(S){var P=this[0],E;if(!P){return null}if(S!==aB){return this.each(function(){if(E=aW(this)){E.scrollTo(!t?S:R(E).scrollLeft(),t?S:R(E).scrollTop())}else{this[B]=S}})}else{return(E=aW(P))?"pageXOffset" in E?E[t?"pageYOffset":"pageXOffset"]:R.support.boxModel&&E.document.documentElement[B]||E.document.body[B]:P[B]}}});R.each(["Height","Width"],function(t,c){var B=c.toLowerCase();R.fn["inner"+c]=function(){return this[0]?parseFloat(R.css(this[0],B,"padding")):null};R.fn["outer"+c]=function(E){return this[0]?parseFloat(R.css(this[0],B,E?"margin":"border")):null};R.fn[B]=function(S){var P=this[0];if(!P){return S==null?null:this}if(R.isFunction(S)){return this.each(function(T){var U=R(this);U[B](S.call(this,T,U[B]()))})}if(R.isWindow(P)){return P.document.compatMode==="CSS1Compat"&&P.document.documentElement["client"+c]||P.document.body["client"+c]}else{if(P.nodeType===9){return Math.max(P.documentElement["client"+c],P.body["scroll"+c],P.documentElement["scroll"+c],P.body["offset"+c],P.documentElement["offset"+c])}else{if(S===aB){P=R.css(P,B);var E=parseFloat(P);return R.isNaN(E)?P:E}else{return this.css(B,typeof S==="string"?S:S+"px")}}}}})})(window);
/*
 * jQuery UI 1.8.10
 *
 * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * http://docs.jquery.com/UI
 */
(function(d,b){function a(c){return !d(c).parents().andSelf().filter(function(){return d.curCSS(this,"visibility")==="hidden"||d.expr.filters.hidden(this)}).length}d.ui=d.ui||{};if(!d.ui.version){d.extend(d.ui,{version:"1.8.10",keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}});d.fn.extend({_focus:d.fn.focus,focus:function(e,c){return typeof e==="number"?this.each(function(){var f=this;setTimeout(function(){d(f).focus();c&&c.call(f)},e)}):this._focus.apply(this,arguments)},scrollParent:function(){var c;c=d.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(d.curCSS(this,"position",1))&&/(auto|scroll)/.test(d.curCSS(this,"overflow",1)+d.curCSS(this,"overflow-y",1)+d.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(d.curCSS(this,"overflow",1)+d.curCSS(this,"overflow-y",1)+d.curCSS(this,"overflow-x",1))}).eq(0);return/fixed/.test(this.css("position"))||!c.length?d(document):c},zIndex:function(e){if(e!==b){return this.css("zIndex",e)}if(this.length){e=d(this[0]);for(var c;e.length&&e[0]!==document;){c=e.css("position");if(c==="absolute"||c==="relative"||c==="fixed"){c=parseInt(e.css("zIndex"),10);if(!isNaN(c)&&c!==0){return c}}e=e.parent()}}return 0},disableSelection:function(){return this.bind((d.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(c){c.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}});d.each(["Width","Height"],function(f,c){function l(o,i,h,e){d.each(k,function(){i-=parseFloat(d.curCSS(o,"padding"+this,true))||0;if(h){i-=parseFloat(d.curCSS(o,"border"+this+"Width",true))||0}if(e){i-=parseFloat(d.curCSS(o,"margin"+this,true))||0}});return i}var k=c==="Width"?["Left","Right"]:["Top","Bottom"],j=c.toLowerCase(),g={innerWidth:d.fn.innerWidth,innerHeight:d.fn.innerHeight,outerWidth:d.fn.outerWidth,outerHeight:d.fn.outerHeight};d.fn["inner"+c]=function(e){if(e===b){return g["inner"+c].call(this)}return this.each(function(){d(this).css(j,l(this,e)+"px")})};d.fn["outer"+c]=function(h,e){if(typeof h!=="number"){return g["outer"+c].call(this,h)}return this.each(function(){d(this).css(j,l(this,h,true,e)+"px")})}});d.extend(d.expr[":"],{data:function(e,c,f){return !!d.data(e,f[3])},focusable:function(e){var c=e.nodeName.toLowerCase(),f=d.attr(e,"tabindex");if("area"===c){c=e.parentNode;f=c.name;if(!e.href||!f||c.nodeName.toLowerCase()!=="map"){return false}e=d("img[usemap=#"+f+"]")[0];return !!e&&a(e)}return(/input|select|textarea|button|object/.test(c)?!e.disabled:"a"==c?e.href||!isNaN(f):!isNaN(f))&&a(e)},tabbable:function(e){var c=d.attr(e,"tabindex");return(isNaN(c)||c>=0)&&d(e).is(":focusable")}});d(function(){var e=document.body,c=e.appendChild(c=document.createElement("div"));d.extend(c.style,{minHeight:"100px",height:"auto",padding:0,borderWidth:0});d.support.minHeight=c.offsetHeight===100;d.support.selectstart="onselectstart" in c;e.removeChild(c).style.display="none"});d.extend(d.ui,{plugin:{add:function(f,c,h){f=d.ui[f].prototype;for(var g in h){f.plugins[g]=f.plugins[g]||[];f.plugins[g].push([c,h[g]])}},call:function(f,c,h){if((c=f.plugins[c])&&f.element[0].parentNode){for(var g=0;g<c.length;g++){f.options[c[g][0]]&&c[g][1].apply(f.element,h)}}}},contains:function(e,c){return document.compareDocumentPosition?e.compareDocumentPosition(c)&16:e!==c&&e.contains(c)},hasScroll:function(e,c){if(d(e).css("overflow")==="hidden"){return false}c=c&&c==="left"?"scrollLeft":"scrollTop";var f=false;if(e[c]>0){return true}e[c]=1;f=e[c]>0;e[c]=0;return f},isOverAxis:function(e,c,f){return e>c&&e<c+f},isOver:function(f,c,l,k,j,g){return d.ui.isOverAxis(f,l,j)&&d.ui.isOverAxis(c,k,g)}})}})(jQuery);
/*
 * jQuery UI Widget 1.8.10
 *
 * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * http://docs.jquery.com/UI/Widget
 */
(function(a,e){if(a.cleanData){var d=a.cleanData;a.cleanData=function(b){for(var g=0,f;(f=b[g])!=null;g++){a(f).triggerHandler("remove")}d(b)}}else{var c=a.fn.remove;a.fn.remove=function(b,f){return this.each(function(){if(!f){if(!b||a.filter(b,[this]).length){a("*",this).add([this]).each(function(){a(this).triggerHandler("remove")})}}return c.call(a(this),b,f)})}}a.widget=function(b,j,i){var h=b.split(".")[0],g;b=b.split(".")[1];g=h+"-"+b;if(!i){i=j;j=a.Widget}a.expr[":"][g]=function(f){return !!a.data(f,b)};a[h]=a[h]||{};a[h][b]=function(f,k){arguments.length&&this._createWidget(f,k)};j=new j;j.options=a.extend(true,{},j.options);a[h][b].prototype=a.extend(true,j,{namespace:h,widgetName:b,widgetEventPrefix:a[h][b].prototype.widgetEventPrefix||b,widgetBaseClass:g},i);a.widget.bridge(b,a[h][b])};a.widget.bridge=function(b,f){a.fn[b]=function(k){var j=typeof k==="string",i=Array.prototype.slice.call(arguments,1),g=this;k=!j&&i.length?a.extend.apply(null,[true,k].concat(i)):k;if(j&&k.charAt(0)==="_"){return g}j?this.each(function(){var l=a.data(this,b),h=l&&a.isFunction(l[k])?l[k].apply(l,i):l;if(h!==l&&h!==e){g=h;return false}}):this.each(function(){var h=a.data(this,b);h?h.option(k||{})._init():a.data(this,b,new f(k,this))});return g}};a.Widget=function(b,f){arguments.length&&this._createWidget(b,f)};a.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",options:{disabled:false},_createWidget:function(b,g){a.data(g,this.widgetName,this);this.element=a(g);this.options=a.extend(true,{},this.options,this._getCreateOptions(),b);var f=this;this.element.bind("remove."+this.widgetName,function(){f.destroy()});this._create();this._trigger("create");this._init()},_getCreateOptions:function(){return a.metadata&&a.metadata.get(this.element[0])[this.widgetName]},_create:function(){},_init:function(){},destroy:function(){this.element.unbind("."+this.widgetName).removeData(this.widgetName);this.widget().unbind("."+this.widgetName).removeAttr("aria-disabled").removeClass(this.widgetBaseClass+"-disabled ui-state-disabled")},widget:function(){return this.element},option:function(b,g){var f=b;if(arguments.length===0){return a.extend({},this.options)}if(typeof b==="string"){if(g===e){return this.options[b]}f={};f[b]=g}this._setOptions(f);return this},_setOptions:function(b){var f=this;a.each(b,function(h,g){f._setOption(h,g)});return this},_setOption:function(b,f){this.options[b]=f;if(b==="disabled"){this.widget()[f?"addClass":"removeClass"](this.widgetBaseClass+"-disabled ui-state-disabled").attr("aria-disabled",f)}return this},enable:function(){return this._setOption("disabled",false)},disable:function(){return this._setOption("disabled",true)},_trigger:function(b,j,i){var h=this.options[b];j=a.Event(j);j.type=(b===this.widgetEventPrefix?b:this.widgetEventPrefix+b).toLowerCase();i=i||{};if(j.originalEvent){b=a.event.props.length;for(var g;b;){g=a.event.props[--b];j[g]=j.originalEvent[g]}}this.element.trigger(j,i);return !(a.isFunction(h)&&h.call(this.element[0],j,i)===false||j.isDefaultPrevented())}}})(jQuery);
/*
 * jQuery UI Mouse 1.8.10
 *
 * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * http://docs.jquery.com/UI/Mouse
 *
 * Depends:
 *	jquery.ui.widget.js
 */
(function(a){a.widget("ui.mouse",{options:{cancel:":input,option",distance:1,delay:0},_mouseInit:function(){var b=this;this.element.bind("mousedown."+this.widgetName,function(c){return b._mouseDown(c)}).bind("click."+this.widgetName,function(c){if(true===a.data(c.target,b.widgetName+".preventClickEvent")){a.removeData(c.target,b.widgetName+".preventClickEvent");c.stopImmediatePropagation();return false}});this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName)},_mouseDown:function(d){d.originalEvent=d.originalEvent||{};if(!d.originalEvent.mouseHandled){this._mouseStarted&&this._mouseUp(d);this._mouseDownEvent=d;var c=this,h=d.which==1,g=typeof this.options.cancel=="string"?a(d.target).parents().add(d.target).filter(this.options.cancel).length:false;if(!h||g||!this._mouseCapture(d)){return true}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){c.mouseDelayMet=true},this.options.delay)}if(this._mouseDistanceMet(d)&&this._mouseDelayMet(d)){this._mouseStarted=this._mouseStart(d)!==false;if(!this._mouseStarted){d.preventDefault();return true}}this._mouseMoveDelegate=function(b){return c._mouseMove(b)};this._mouseUpDelegate=function(b){return c._mouseUp(b)};a(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);d.preventDefault();return d.originalEvent.mouseHandled=true}},_mouseMove:function(b){if(a.browser.msie&&!(document.documentMode>=9)&&!b.button){return this._mouseUp(b)}if(this._mouseStarted){this._mouseDrag(b);return b.preventDefault()}if(this._mouseDistanceMet(b)&&this._mouseDelayMet(b)){(this._mouseStarted=this._mouseStart(this._mouseDownEvent,b)!==false)?this._mouseDrag(b):this._mouseUp(b)}return !this._mouseStarted},_mouseUp:function(b){a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;b.target==this._mouseDownEvent.target&&a.data(b.target,this.widgetName+".preventClickEvent",true);this._mouseStop(b)}return false},_mouseDistanceMet:function(b){return Math.max(Math.abs(this._mouseDownEvent.pageX-b.pageX),Math.abs(this._mouseDownEvent.pageY-b.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return true}})})(jQuery);(function(f){f.ui=f.ui||{};var e=/left|center|right/,d=/top|center|bottom/,b=f.fn.position,a=f.fn.offset;f.fn.position=function(c){if(!c||!c.of){return b.apply(this,arguments)}c=f.extend({},c);var i=f(c.of),s=i[0],q=(c.collision||"flip").split(" "),r=c.offset?c.offset.split(" "):[0,0],o,l,m;if(s.nodeType===9){o=i.width();l=i.height();m={top:0,left:0}}else{if(s.setTimeout){o=i.width();l=i.height();m={top:i.scrollTop(),left:i.scrollLeft()}}else{if(s.preventDefault){c.at="left top";o=l=0;m={top:c.of.pageY,left:c.of.pageX}}else{o=i.outerWidth();l=i.outerHeight();m=i.offset()}}}f.each(["my","at"],function(){var g=(c[this]||"").split(" ");if(g.length===1){g=e.test(g[0])?g.concat(["center"]):d.test(g[0])?["center"].concat(g):["center","center"]}g[0]=e.test(g[0])?g[0]:"center";g[1]=d.test(g[1])?g[1]:"center";c[this]=g});if(q.length===1){q[1]=q[0]}r[0]=parseInt(r[0],10)||0;if(r.length===1){r[1]=r[0]}r[1]=parseInt(r[1],10)||0;if(c.at[0]==="right"){m.left+=o}else{if(c.at[0]==="center"){m.left+=o/2}}if(c.at[1]==="bottom"){m.top+=l}else{if(c.at[1]==="center"){m.top+=l/2}}m.left+=r[0];m.top+=r[1];return this.each(function(){var x=f(this),t=x.outerWidth(),k=x.outerHeight(),j=parseInt(f.curCSS(this,"marginLeft",true))||0,h=parseInt(f.curCSS(this,"marginTop",true))||0,z=t+j+(parseInt(f.curCSS(this,"marginRight",true))||0),y=k+h+(parseInt(f.curCSS(this,"marginBottom",true))||0),u=f.extend({},m),g;if(c.my[0]==="right"){u.left-=t}else{if(c.my[0]==="center"){u.left-=t/2}}if(c.my[1]==="bottom"){u.top-=k}else{if(c.my[1]==="center"){u.top-=k/2}}u.left=Math.round(u.left);u.top=Math.round(u.top);g={left:u.left-j,top:u.top-h};f.each(["left","top"],function(w,v){f.ui.position[q[w]]&&f.ui.position[q[w]][v](u,{targetWidth:o,targetHeight:l,elemWidth:t,elemHeight:k,collisionPosition:g,collisionWidth:z,collisionHeight:y,offset:r,my:c.my,at:c.at})});f.fn.bgiframe&&x.bgiframe();x.offset(f.extend(u,{using:c.using}))})};f.ui.position={fit:{left:function(c,g){var h=f(window);h=g.collisionPosition.left+g.collisionWidth-h.width()-h.scrollLeft();c.left=h>0?c.left-h:Math.max(c.left-g.collisionPosition.left,c.left)},top:function(c,g){var h=f(window);h=g.collisionPosition.top+g.collisionHeight-h.height()-h.scrollTop();c.top=h>0?c.top-h:Math.max(c.top-g.collisionPosition.top,c.top)}},flip:{left:function(c,i){if(i.at[0]!=="center"){var m=f(window);m=i.collisionPosition.left+i.collisionWidth-m.width()-m.scrollLeft();var k=i.my[0]==="left"?-i.elemWidth:i.my[0]==="right"?i.elemWidth:0,l=i.at[0]==="left"?i.targetWidth:-i.targetWidth,j=-2*i.offset[0];c.left+=i.collisionPosition.left<0?k+l+j:m>0?k+l+j:0}},top:function(c,i){if(i.at[1]!=="center"){var m=f(window);m=i.collisionPosition.top+i.collisionHeight-m.height()-m.scrollTop();var k=i.my[1]==="top"?-i.elemHeight:i.my[1]==="bottom"?i.elemHeight:0,l=i.at[1]==="top"?i.targetHeight:-i.targetHeight,j=-2*i.offset[1];c.top+=i.collisionPosition.top<0?k+l+j:m>0?k+l+j:0}}}};if(!f.offset.setOffset){f.offset.setOffset=function(c,i){if(/static/.test(f.curCSS(c,"position"))){c.style.position="relative"}var m=f(c),k=m.offset(),l=parseInt(f.curCSS(c,"top",true),10)||0,j=parseInt(f.curCSS(c,"left",true),10)||0;k={top:i.top-k.top+l,left:i.left-k.left+j};"using" in i?i.using.call(c,k):m.css(k)};f.fn.offset=function(c){var g=this[0];if(!g||!g.ownerDocument){return null}if(c){return this.each(function(){f.offset.setOffset(this,c)})}return a.call(this)}}})(jQuery);jQuery.effects||function(l,i){function e(j){var f;if(j&&j.constructor==Array&&j.length==3){return j}if(f=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(j)){return[parseInt(f[1],10),parseInt(f[2],10),parseInt(f[3],10)]}if(f=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(j)){return[parseFloat(f[1])*2.55,parseFloat(f[2])*2.55,parseFloat(f[3])*2.55]}if(f=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(j)){return[parseInt(f[1],16),parseInt(f[2],16),parseInt(f[3],16)]}if(f=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(j)){return[parseInt(f[1]+f[1],16),parseInt(f[2]+f[2],16),parseInt(f[3]+f[3],16)]}if(/rgba\(0, 0, 0, 0\)/.exec(j)){return d.transparent}return d[l.trim(j).toLowerCase()]}function x(k,j){var f;do{f=l.curCSS(k,j);if(f!=""&&f!="transparent"||l.nodeName(k,"body")){break}j="backgroundColor"}while(k=k.parentNode);return e(f)}function c(){var o=document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle,j={},f,m;if(o&&o.length&&o[0]&&o[o[0]]){for(var k=o.length;k--;){f=o[k];if(typeof o[f]=="string"){m=f.replace(/\-(\w)/g,function(r,q){return q.toUpperCase()});j[m]=o[f]}}}else{for(f in o){if(typeof o[f]==="string"){j[f]=o[f]}}}return j}function b(k){var j,f;for(j in k){f=k[j];if(f==null||l.isFunction(f)||j in w||/scrollbar/.test(j)||!/color/i.test(j)&&isNaN(parseFloat(f))){delete k[j]}}return k}function v(m,j){var f={_:0},k;for(k in j){if(m[k]!=j[k]){f[k]=j[k]}}return f}function h(m,j,f,k){if(typeof m=="object"){k=j;f=null;j=m;m=j.effect}if(l.isFunction(j)){k=j;f=null;j={}}if(typeof j=="number"||l.fx.speeds[j]){k=f;f=j;j={}}if(l.isFunction(f)){k=f;f=null}j=j||{};f=f||j.duration;f=l.fx.off?0:typeof f=="number"?f:f in l.fx.speeds?l.fx.speeds[f]:l.fx.speeds._default;k=k||j.complete;return[m,j,f,k]}function g(f){if(!f||typeof f==="number"||l.fx.speeds[f]){return true}if(typeof f==="string"&&!l.effects[f]){return true}return false}l.effects={};l.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","borderColor","color","outlineColor"],function(j,f){l.fx.step[f]=function(k){if(!k.colorInit){k.start=x(k.elem,f);k.end=e(k.end);k.colorInit=true}k.elem.style[f]="rgb("+Math.max(Math.min(parseInt(k.pos*(k.end[0]-k.start[0])+k.start[0],10),255),0)+","+Math.max(Math.min(parseInt(k.pos*(k.end[1]-k.start[1])+k.start[1],10),255),0)+","+Math.max(Math.min(parseInt(k.pos*(k.end[2]-k.start[2])+k.start[2],10),255),0)+")"}});var d={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0],transparent:[255,255,255]},a=["add","remove","toggle"],w={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};l.effects.animateClass=function(m,j,f,k){if(l.isFunction(f)){k=f;f=null}return this.queue("fx",function(){var t=l(this),s=t.attr("style")||" ",r=b(c.call(this)),o,q=t.attr("className");l.each(a,function(u,y){m[y]&&t[y+"Class"](m[y])});o=b(c.call(this));t.attr("className",q);t.animate(v(r,o),j,f,function(){l.each(a,function(u,y){m[y]&&t[y+"Class"](m[y])});if(typeof t.attr("style")=="object"){t.attr("style").cssText="";t.attr("style").cssText=s}else{t.attr("style",s)}k&&k.apply(this,arguments)});r=l.queue(this);o=r.splice(r.length-1,1)[0];r.splice(1,0,o);l.dequeue(this)})};l.fn.extend({_addClass:l.fn.addClass,addClass:function(m,j,f,k){return j?l.effects.animateClass.apply(this,[{add:m},j,f,k]):this._addClass(m)},_removeClass:l.fn.removeClass,removeClass:function(m,j,f,k){return j?l.effects.animateClass.apply(this,[{remove:m},j,f,k]):this._removeClass(m)},_toggleClass:l.fn.toggleClass,toggleClass:function(o,j,f,m,k){return typeof j=="boolean"||j===i?f?l.effects.animateClass.apply(this,[j?{add:o}:{remove:o},f,m,k]):this._toggleClass(o,j):l.effects.animateClass.apply(this,[{toggle:o},j,f,m])},switchClass:function(o,j,f,m,k){return l.effects.animateClass.apply(this,[{add:j,remove:o},f,m,k])}});l.extend(l.effects,{version:"1.8.10",save:function(k,j){for(var f=0;f<j.length;f++){j[f]!==null&&k.data("ec.storage."+j[f],k[0].style[j[f]])}},restore:function(k,j){for(var f=0;f<j.length;f++){j[f]!==null&&k.css(j[f],k.data("ec.storage."+j[f]))}},setMode:function(j,f){if(f=="toggle"){f=j.is(":hidden")?"show":"hide"}return f},getBaseline:function(k,j){var f;switch(k[0]){case"top":f=0;break;case"middle":f=0.5;break;case"bottom":f=1;break;default:f=k[0]/j.height}switch(k[1]){case"left":k=0;break;case"center":k=0.5;break;case"right":k=1;break;default:k=k[1]/j.width}return{x:k,y:f}},createWrapper:function(k){if(k.parent().is(".ui-effects-wrapper")){return k.parent()}var j={width:k.outerWidth(true),height:k.outerHeight(true),"float":k.css("float")},f=l("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0});k.wrap(f);f=k.parent();if(k.css("position")=="static"){f.css({position:"relative"});k.css({position:"relative"})}else{l.extend(j,{position:k.css("position"),zIndex:k.css("z-index")});l.each(["top","left","bottom","right"],function(o,m){j[m]=k.css(m);if(isNaN(parseInt(j[m],10))){j[m]="auto"}});k.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})}return f.css(j).show()},removeWrapper:function(f){if(f.parent().is(".ui-effects-wrapper")){return f.parent().replaceWith(f)}return f},setTransition:function(m,j,f,k){k=k||{};l.each(j,function(q,o){unit=m.cssUnit(o);if(unit[0]>0){k[o]=unit[0]*f+unit[1]}});return k}});l.fn.extend({effect:function(m){var j=h.apply(this,arguments),f={options:j[1],duration:j[2],callback:j[3]};j=f.options.mode;var k=l.effects[m];if(l.fx.off||!k){return j?this[j](f.duration,f.callback):this.each(function(){f.callback&&f.callback.call(this)})}return k.call(this,f)},_show:l.fn.show,show:function(j){if(g(j)){return this._show.apply(this,arguments)}else{var f=h.apply(this,arguments);f[1].mode="show";return this.effect.apply(this,f)}},_hide:l.fn.hide,hide:function(j){if(g(j)){return this._hide.apply(this,arguments)}else{var f=h.apply(this,arguments);f[1].mode="hide";return this.effect.apply(this,f)}},__toggle:l.fn.toggle,toggle:function(j){if(g(j)||typeof j==="boolean"||l.isFunction(j)){return this.__toggle.apply(this,arguments)}else{var f=h.apply(this,arguments);f[1].mode="toggle";return this.effect.apply(this,f)}},cssUnit:function(k){var j=this.css(k),f=[];l.each(["em","px","%","pt"],function(o,m){if(j.indexOf(m)>0){f=[parseFloat(j),m]}});return f}});l.easing.jswing=l.easing.swing;l.extend(l.easing,{def:"easeOutQuad",swing:function(o,j,f,m,k){return l.easing[l.easing.def](o,j,f,m,k)},easeInQuad:function(o,j,f,m,k){return m*(j/=k)*j+f},easeOutQuad:function(o,j,f,m,k){return -m*(j/=k)*(j-2)+f},easeInOutQuad:function(o,j,f,m,k){if((j/=k/2)<1){return m/2*j*j+f}return -m/2*(--j*(j-2)-1)+f},easeInCubic:function(o,j,f,m,k){return m*(j/=k)*j*j+f},easeOutCubic:function(o,j,f,m,k){return m*((j=j/k-1)*j*j+1)+f},easeInOutCubic:function(o,j,f,m,k){if((j/=k/2)<1){return m/2*j*j*j+f}return m/2*((j-=2)*j*j+2)+f},easeInQuart:function(o,j,f,m,k){return m*(j/=k)*j*j*j+f},easeOutQuart:function(o,j,f,m,k){return -m*((j=j/k-1)*j*j*j-1)+f},easeInOutQuart:function(o,j,f,m,k){if((j/=k/2)<1){return m/2*j*j*j*j+f}return -m/2*((j-=2)*j*j*j-2)+f},easeInQuint:function(o,j,f,m,k){return m*(j/=k)*j*j*j*j+f},easeOutQuint:function(o,j,f,m,k){return m*((j=j/k-1)*j*j*j*j+1)+f},easeInOutQuint:function(o,j,f,m,k){if((j/=k/2)<1){return m/2*j*j*j*j*j+f}return m/2*((j-=2)*j*j*j*j+2)+f},easeInSine:function(o,j,f,m,k){return -m*Math.cos(j/k*(Math.PI/2))+m+f},easeOutSine:function(o,j,f,m,k){return m*Math.sin(j/k*(Math.PI/2))+f},easeInOutSine:function(o,j,f,m,k){return -m/2*(Math.cos(Math.PI*j/k)-1)+f},easeInExpo:function(o,j,f,m,k){return j==0?f:m*Math.pow(2,10*(j/k-1))+f},easeOutExpo:function(o,j,f,m,k){return j==k?f+m:m*(-Math.pow(2,-10*j/k)+1)+f},easeInOutExpo:function(o,j,f,m,k){if(j==0){return f}if(j==k){return f+m}if((j/=k/2)<1){return m/2*Math.pow(2,10*(j-1))+f}return m/2*(-Math.pow(2,-10*--j)+2)+f},easeInCirc:function(o,j,f,m,k){return -m*(Math.sqrt(1-(j/=k)*j)-1)+f},easeOutCirc:function(o,j,f,m,k){return m*Math.sqrt(1-(j=j/k-1)*j)+f},easeInOutCirc:function(o,j,f,m,k){if((j/=k/2)<1){return -m/2*(Math.sqrt(1-j*j)-1)+f}return m/2*(Math.sqrt(1-(j-=2)*j)+1)+f},easeInElastic:function(r,j,f,q,o){r=1.70158;var m=0,k=q;if(j==0){return f}if((j/=o)==1){return f+q}m||(m=o*0.3);if(k<Math.abs(q)){k=q;r=m/4}else{r=m/(2*Math.PI)*Math.asin(q/k)}return -(k*Math.pow(2,10*(j-=1))*Math.sin((j*o-r)*2*Math.PI/m))+f},easeOutElastic:function(r,j,f,q,o){r=1.70158;var m=0,k=q;if(j==0){return f}if((j/=o)==1){return f+q}m||(m=o*0.3);if(k<Math.abs(q)){k=q;r=m/4}else{r=m/(2*Math.PI)*Math.asin(q/k)}return k*Math.pow(2,-10*j)*Math.sin((j*o-r)*2*Math.PI/m)+q+f},easeInOutElastic:function(r,j,f,q,o){r=1.70158;var m=0,k=q;if(j==0){return f}if((j/=o/2)==2){return f+q}m||(m=o*0.3*1.5);if(k<Math.abs(q)){k=q;r=m/4}else{r=m/(2*Math.PI)*Math.asin(q/k)}if(j<1){return -0.5*k*Math.pow(2,10*(j-=1))*Math.sin((j*o-r)*2*Math.PI/m)+f}return k*Math.pow(2,-10*(j-=1))*Math.sin((j*o-r)*2*Math.PI/m)*0.5+q+f},easeInBack:function(q,j,f,o,m,k){if(k==i){k=1.70158}return o*(j/=m)*j*((k+1)*j-k)+f},easeOutBack:function(q,j,f,o,m,k){if(k==i){k=1.70158}return o*((j=j/m-1)*j*((k+1)*j+k)+1)+f},easeInOutBack:function(q,j,f,o,m,k){if(k==i){k=1.70158}if((j/=m/2)<1){return o/2*j*j*(((k*=1.525)+1)*j-k)+f}return o/2*((j-=2)*j*(((k*=1.525)+1)*j+k)+2)+f},easeInBounce:function(o,j,f,m,k){return m-l.easing.easeOutBounce(o,k-j,0,m,k)+f},easeOutBounce:function(o,j,f,m,k){return(j/=k)<1/2.75?m*7.5625*j*j+f:j<2/2.75?m*(7.5625*(j-=1.5/2.75)*j+0.75)+f:j<2.5/2.75?m*(7.5625*(j-=2.25/2.75)*j+0.9375)+f:m*(7.5625*(j-=2.625/2.75)*j+0.984375)+f},easeInOutBounce:function(o,j,f,m,k){if(j<k/2){return l.easing.easeInBounce(o,j*2,0,m,k)*0.5+f}return l.easing.easeOutBounce(o,j*2-k,0,m,k)*0.5+m*0.5+f}})}(jQuery);(function(a){a.effects.blind=function(b){return this.queue(function(){var c=a(this),l=["position","top","bottom","left","right"],m=a.effects.setMode(c,b.options.mode||"hide"),q=b.options.direction||"vertical";a.effects.save(c,l);c.show();var o=a.effects.createWrapper(c).css({overflow:"hidden"}),k=q=="vertical"?"height":"width";q=q=="vertical"?o.height():o.width();m=="show"&&o.css(k,0);var j={};j[k]=m=="show"?q:0;o.animate(j,b.duration,b.options.easing,function(){m=="hide"&&c.hide();a.effects.restore(c,l);a.effects.removeWrapper(c);b.callback&&b.callback.apply(c[0],arguments);c.dequeue()})})}})(jQuery);(function(a){a.effects.bounce=function(c){return this.queue(function(){var x=a(this),e=["position","top","bottom","left","right"],s=a.effects.setMode(x,c.options.mode||"effect"),v=c.options.direction||"up",w=c.options.distance||20,b=c.options.times||5,r=c.duration||250;/show|hide/.test(s)&&e.push("opacity");a.effects.save(x,e);x.show();a.effects.createWrapper(x);var u=v=="up"||v=="down"?"top":"left";v=v=="up"||v=="left"?"pos":"neg";w=c.options.distance||(u=="top"?x.outerHeight({margin:true})/3:x.outerWidth({margin:true})/3);if(s=="show"){x.css("opacity",0).css(u,v=="pos"?-w:w)}if(s=="hide"){w/=b*2}s!="hide"&&b--;if(s=="show"){var t={opacity:1};t[u]=(v=="pos"?"+=":"-=")+w;x.animate(t,r/2,c.options.easing);w/=2;b--}for(t=0;t<b;t++){var q={},o={};q[u]=(v=="pos"?"-=":"+=")+w;o[u]=(v=="pos"?"+=":"-=")+w;x.animate(q,r/2,c.options.easing).animate(o,r/2,c.options.easing);w=s=="hide"?w*2:w/2}if(s=="hide"){t={opacity:0};t[u]=(v=="pos"?"-=":"+=")+w;x.animate(t,r/2,c.options.easing,function(){x.hide();a.effects.restore(x,e);a.effects.removeWrapper(x);c.callback&&c.callback.apply(this,arguments)})}else{q={};o={};q[u]=(v=="pos"?"-=":"+=")+w;o[u]=(v=="pos"?"+=":"-=")+w;x.animate(q,r/2,c.options.easing).animate(o,r/2,c.options.easing,function(){a.effects.restore(x,e);a.effects.removeWrapper(x);c.callback&&c.callback.apply(this,arguments)})}x.queue("fx",function(){x.dequeue()});x.dequeue()})}})(jQuery);(function(a){a.effects.clip=function(b){return this.queue(function(){var e=a(this),j=["position","top","bottom","left","right","height","width"],m=a.effects.setMode(e,b.options.mode||"hide"),q=b.options.direction||"vertical";a.effects.save(e,j);e.show();var o=a.effects.createWrapper(e).css({overflow:"hidden"});o=e[0].tagName=="IMG"?o:e;var l={size:q=="vertical"?"height":"width",position:q=="vertical"?"top":"left"};q=q=="vertical"?o.height():o.width();if(m=="show"){o.css(l.size,0);o.css(l.position,q/2)}var k={};k[l.size]=m=="show"?q:0;k[l.position]=m=="show"?0:q/2;o.animate(k,{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){m=="hide"&&e.hide();a.effects.restore(e,j);a.effects.removeWrapper(e);b.callback&&b.callback.apply(e[0],arguments);e.dequeue()}})})}})(jQuery);(function(a){a.effects.drop=function(b){return this.queue(function(){var d=a(this),k=["position","top","bottom","left","right","opacity"],o=a.effects.setMode(d,b.options.mode||"hide"),c=b.options.direction||"left";a.effects.save(d,k);d.show();a.effects.createWrapper(d);var m=c=="up"||c=="down"?"top":"left";c=c=="up"||c=="left"?"pos":"neg";var l=b.options.distance||(m=="top"?d.outerHeight({margin:true})/2:d.outerWidth({margin:true})/2);if(o=="show"){d.css("opacity",0).css(m,c=="pos"?-l:l)}var j={opacity:o=="show"?1:0};j[m]=(o=="show"?c=="pos"?"+=":"-=":c=="pos"?"-=":"+=")+l;d.animate(j,{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){o=="hide"&&d.hide();a.effects.restore(d,k);a.effects.removeWrapper(d);b.callback&&b.callback.apply(this,arguments);d.dequeue()}})})}})(jQuery);(function(a){a.effects.explode=function(b){return this.queue(function(){var s=b.options.pieces?Math.round(Math.sqrt(b.options.pieces)):3,r=b.options.pieces?Math.round(Math.sqrt(b.options.pieces)):3;b.options.mode=b.options.mode=="toggle"?a(this).is(":visible")?"hide":"show":b.options.mode;var j=a(this).show().css("visibility","hidden"),m=j.offset();m.top-=parseInt(j.css("marginTop"),10)||0;m.left-=parseInt(j.css("marginLeft"),10)||0;for(var l=j.outerWidth(true),k=j.outerHeight(true),q=0;q<s;q++){for(var o=0;o<r;o++){j.clone().appendTo("body").wrap("<div></div>").css({position:"absolute",visibility:"visible",left:-o*(l/r),top:-q*(k/s)}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:l/r,height:k/s,left:m.left+o*(l/r)+(b.options.mode=="show"?(o-Math.floor(r/2))*(l/r):0),top:m.top+q*(k/s)+(b.options.mode=="show"?(q-Math.floor(s/2))*(k/s):0),opacity:b.options.mode=="show"?0:1}).animate({left:m.left+o*(l/r)+(b.options.mode=="show"?0:(o-Math.floor(r/2))*(l/r)),top:m.top+q*(k/s)+(b.options.mode=="show"?0:(q-Math.floor(s/2))*(k/s)),opacity:b.options.mode=="show"?1:0},b.duration||500)}}setTimeout(function(){b.options.mode=="show"?j.css({visibility:"visible"}):j.css({visibility:"visible"}).hide();b.callback&&b.callback.apply(j[0]);j.dequeue();a("div.ui-effects-explode").remove()},b.duration||500)})}})(jQuery);(function(a){a.effects.fade=function(b){return this.queue(function(){var f=a(this),e=a.effects.setMode(f,b.options.mode||"hide");f.animate({opacity:e},{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){b.callback&&b.callback.apply(this,arguments);f.dequeue()}})})}})(jQuery);(function(a){a.effects.fold=function(b){return this.queue(function(){var w=a(this),o=["position","top","bottom","left","right"],v=a.effects.setMode(w,b.options.mode||"hide"),s=b.options.size||15,r=!!b.options.horizFirst,m=b.duration?b.duration/2:a.fx.speeds._default/2;a.effects.save(w,o);w.show();var u=a.effects.createWrapper(w).css({overflow:"hidden"}),t=v=="show"!=r,c=t?["width","height"]:["height","width"];t=t?[u.width(),u.height()]:[u.height(),u.width()];var q=/([0-9]+)%/.exec(s);if(q){s=parseInt(q[1],10)/100*t[v=="hide"?0:1]}if(v=="show"){u.css(r?{height:0,width:s}:{height:s,width:0})}r={};q={};r[c[0]]=v=="show"?t[0]:s;q[c[1]]=v=="show"?t[1]:0;u.animate(r,m,b.options.easing).animate(q,m,b.options.easing,function(){v=="hide"&&w.hide();a.effects.restore(w,o);a.effects.removeWrapper(w);b.callback&&b.callback.apply(w[0],arguments);w.dequeue()})})}})(jQuery);(function(a){a.effects.highlight=function(b){return this.queue(function(){var c=a(this),h=["backgroundImage","backgroundColor","opacity"],i=a.effects.setMode(c,b.options.mode||"show"),g={backgroundColor:c.css("backgroundColor")};if(i=="hide"){g.opacity=0}a.effects.save(c,h);c.show().css({backgroundImage:"none",backgroundColor:b.options.color||"#ffff99"}).animate(g,{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){i=="hide"&&c.hide();a.effects.restore(c,h);i=="show"&&!a.support.opacity&&this.style.removeAttribute("filter");b.callback&&b.callback.apply(this,arguments);c.dequeue()}})})}})(jQuery);(function(a){a.effects.pulsate=function(b){return this.queue(function(){var d=a(this),e=a.effects.setMode(d,b.options.mode||"show");times=(b.options.times||5)*2-1;duration=b.duration?b.duration/2:a.fx.speeds._default/2;isVisible=d.is(":visible");animateTo=0;if(!isVisible){d.css("opacity",0).show();animateTo=1}if(e=="hide"&&isVisible||e=="show"&&!isVisible){times--}for(e=0;e<times;e++){d.animate({opacity:animateTo},duration,b.options.easing);animateTo=(animateTo+1)%2}d.animate({opacity:animateTo},duration,b.options.easing,function(){animateTo==0&&d.hide();b.callback&&b.callback.apply(this,arguments)});d.queue("fx",function(){d.dequeue()}).dequeue()})}})(jQuery);(function(a){a.effects.puff=function(c){return this.queue(function(){var b=a(this),k=a.effects.setMode(b,c.options.mode||"hide"),j=parseInt(c.options.percent,10)||150,f=j/100,d={height:b.height(),width:b.width()};a.extend(c.options,{fade:true,mode:k,percent:k=="hide"?j:100,from:k=="hide"?d:{height:d.height*f,width:d.width*f}});b.effect("scale",c.options,c.duration,c.callback);b.dequeue()})};a.effects.scale=function(c){return this.queue(function(){var b=a(this),m=a.extend(true,{},c.options),k=a.effects.setMode(b,c.options.mode||"effect"),j=parseInt(c.options.percent,10)||(parseInt(c.options.percent,10)==0?0:k=="hide"?0:100),d=c.options.direction||"both",l=c.options.origin;if(k!="effect"){m.origin=l||["middle","center"];m.restore=true}l={height:b.height(),width:b.width()};b.from=c.options.from||(k=="show"?{height:0,width:0}:l);j={y:d!="horizontal"?j/100:1,x:d!="vertical"?j/100:1};b.to={height:l.height*j.y,width:l.width*j.x};if(c.options.fade){if(k=="show"){b.from.opacity=0;b.to.opacity=1}if(k=="hide"){b.from.opacity=1;b.to.opacity=0}}m.from=b.from;m.to=b.to;m.mode=k;b.effect("size",m,c.duration,c.callback);b.dequeue()})};a.effects.size=function(c){return this.queue(function(){var A=a(this),y=["position","top","bottom","left","right","width","height","overflow","opacity"],w=["position","top","bottom","left","right","overflow","opacity"],v=["width","height","overflow"],u=["fontSize"],x=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],s=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],b=a.effects.setMode(A,c.options.mode||"effect"),o=c.options.restore||false,q=c.options.scale||"both",r=c.options.origin,t={height:A.height(),width:A.width()};A.from=c.options.from||t;A.to=c.options.to||t;if(r){r=a.effects.getBaseline(r,t);A.from.top=(t.height-A.from.height)*r.y;A.from.left=(t.width-A.from.width)*r.x;A.to.top=(t.height-A.to.height)*r.y;A.to.left=(t.width-A.to.width)*r.x}var z={from:{y:A.from.height/t.height,x:A.from.width/t.width},to:{y:A.to.height/t.height,x:A.to.width/t.width}};if(q=="box"||q=="both"){if(z.from.y!=z.to.y){y=y.concat(x);A.from=a.effects.setTransition(A,x,z.from.y,A.from);A.to=a.effects.setTransition(A,x,z.to.y,A.to)}if(z.from.x!=z.to.x){y=y.concat(s);A.from=a.effects.setTransition(A,s,z.from.x,A.from);A.to=a.effects.setTransition(A,s,z.to.x,A.to)}}if(q=="content"||q=="both"){if(z.from.y!=z.to.y){y=y.concat(u);A.from=a.effects.setTransition(A,u,z.from.y,A.from);A.to=a.effects.setTransition(A,u,z.to.y,A.to)}}a.effects.save(A,o?y:w);A.show();a.effects.createWrapper(A);A.css("overflow","hidden").css(A.from);if(q=="content"||q=="both"){x=x.concat(["marginTop","marginBottom"]).concat(u);s=s.concat(["marginLeft","marginRight"]);v=y.concat(x).concat(s);A.find("*[width]").each(function(){child=a(this);o&&a.effects.save(child,v);var d={height:child.height(),width:child.width()};child.from={height:d.height*z.from.y,width:d.width*z.from.x};child.to={height:d.height*z.to.y,width:d.width*z.to.x};if(z.from.y!=z.to.y){child.from=a.effects.setTransition(child,x,z.from.y,child.from);child.to=a.effects.setTransition(child,x,z.to.y,child.to)}if(z.from.x!=z.to.x){child.from=a.effects.setTransition(child,s,z.from.x,child.from);child.to=a.effects.setTransition(child,s,z.to.x,child.to)}child.css(child.from);child.animate(child.to,c.duration,c.options.easing,function(){o&&a.effects.restore(child,v)})})}A.animate(A.to,{queue:false,duration:c.duration,easing:c.options.easing,complete:function(){A.to.opacity===0&&A.css("opacity",A.from.opacity);b=="hide"&&A.hide();a.effects.restore(A,o?y:w);a.effects.removeWrapper(A);c.callback&&c.callback.apply(this,arguments);A.dequeue()}})})}})(jQuery);(function(a){a.effects.shake=function(b){return this.queue(function(){var w=a(this),o=["position","top","bottom","left","right"];a.effects.setMode(w,b.options.mode||"effect");var v=b.options.direction||"left",u=b.options.distance||20,d=b.options.times||3,t=b.duration||b.options.duration||140;a.effects.save(w,o);w.show();a.effects.createWrapper(w);var s=v=="up"||v=="down"?"top":"left",r=v=="up"||v=="left"?"pos":"neg";v={};var q={},m={};v[s]=(r=="pos"?"-=":"+=")+u;q[s]=(r=="pos"?"+=":"-=")+u*2;m[s]=(r=="pos"?"-=":"+=")+u*2;w.animate(v,t,b.options.easing);for(u=1;u<d;u++){w.animate(q,t,b.options.easing).animate(m,t,b.options.easing)}w.animate(q,t,b.options.easing).animate(v,t/2,b.options.easing,function(){a.effects.restore(w,o);a.effects.removeWrapper(w);b.callback&&b.callback.apply(this,arguments)});w.queue("fx",function(){w.dequeue()});w.dequeue()})}})(jQuery);(function(a){a.effects.slide=function(b){return this.queue(function(){var d=a(this),k=["position","top","bottom","left","right"],m=a.effects.setMode(d,b.options.mode||"show"),c=b.options.direction||"left";a.effects.save(d,k);d.show();a.effects.createWrapper(d).css({overflow:"hidden"});var l=c=="up"||c=="down"?"top":"left";c=c=="up"||c=="left"?"pos":"neg";var o=b.options.distance||(l=="top"?d.outerHeight({margin:true}):d.outerWidth({margin:true}));if(m=="show"){d.css(l,c=="pos"?isNaN(o)?"-"+o:-o:o)}var j={};j[l]=(m=="show"?c=="pos"?"+=":"-=":c=="pos"?"-=":"+=")+o;d.animate(j,{queue:false,duration:b.duration,easing:b.options.easing,complete:function(){m=="hide"&&d.hide();a.effects.restore(d,k);a.effects.removeWrapper(d);b.callback&&b.callback.apply(this,arguments);d.dequeue()}})})}})(jQuery);(function(a){a.effects.transfer=function(b){return this.queue(function(){var e=a(this),i=a(b.options.to),h=i.offset();i={top:h.top,left:h.left,height:i.innerHeight(),width:i.innerWidth()};h=e.offset();var g=a('<div class="ui-effects-transfer"></div>').appendTo(document.body).addClass(b.options.className).css({top:h.top,left:h.left,height:e.innerHeight(),width:e.innerWidth(),position:"absolute"}).animate(i,b.duration,b.options.easing,function(){g.remove();b.callback&&b.callback.apply(e[0],arguments);e.dequeue()})})}})(jQuery);jQuery.cookie=function(b,j,m){if(typeof j!="undefined"){m=m||{};if(j===null){j="";m.expires=-1}var e="";if(m.expires&&(typeof m.expires=="number"||m.expires.toUTCString)){var f;if(typeof m.expires=="number"){f=new Date();f.setTime(f.getTime()+(m.expires*24*60*60*1000))}else{f=m.expires}e="; expires="+f.toUTCString()}var l=m.path?"; path="+(m.path):"";var g=m.domain?"; domain="+(m.domain):"";var a=m.secure?"; secure":"";document.cookie=[b,"=",encodeURIComponent(j),e,l,g,a].join("")}else{var d=null;if(document.cookie&&document.cookie!=""){var k=document.cookie.split(";");for(var h=0;h<k.length;h++){var c=jQuery.trim(k[h]);if(c.substring(0,b.length+1)==(b+"=")){d=decodeURIComponent(c.substring(b.length+1));break}}}return d}};(function(i){var l="2.99";if(i.support==undefined){i.support={opacity:!(i.browser.msie)}}function a(t){i.fn.cycle.debug&&f(t)}function f(){window.console&&console.log&&console.log("[cycle] "+Array.prototype.join.call(arguments," "))}i.expr[":"].paused=function(s){return s.cyclePause};i.fn.cycle=function(t,s){var u={s:this.selector,c:this.context};if(this.length===0&&t!="stop"){if(!i.isReady&&u.s){f("DOM not ready, queuing slideshow");i(function(){i(u.s,u.c).cycle(t,s)});return this}f("terminating; zero elements found by selector"+(i.isReady?"":" (DOM not ready)"));return this}return this.each(function(){var y=m(this,t,s);if(y===false){return}y.updateActivePagerLink=y.updateActivePagerLink||i.fn.cycle.updateActivePagerLink;if(this.cycleTimeout){clearTimeout(this.cycleTimeout)}this.cycleTimeout=this.cyclePause=0;var z=i(this);var A=y.slideExpr?i(y.slideExpr,this):z.children();var w=A.get();if(w.length<2){f("terminating; too few slides: "+w.length);return}var v=k(z,A,w,y,u);if(v===false){return}var x=v.continuous?10:h(w[v.currSlide],w[v.nextSlide],v,!v.backwards);if(x){x+=(v.delay||0);if(x<10){x=10}a("first timeout: "+x);this.cycleTimeout=setTimeout(function(){e(w,v,0,!y.backwards)},x)}})};function m(s,v,t){if(s.cycleStop==undefined){s.cycleStop=0}if(v===undefined||v===null){v={}}if(v.constructor==String){switch(v){case"destroy":case"stop":var x=i(s).data("cycle.opts");if(!x){return false}s.cycleStop++;if(s.cycleTimeout){clearTimeout(s.cycleTimeout)}s.cycleTimeout=0;i(s).removeData("cycle.opts");if(v=="destroy"){r(x)}return false;case"toggle":s.cyclePause=(s.cyclePause===1)?0:1;w(s.cyclePause,t,s);return false;case"pause":s.cyclePause=1;return false;case"resume":s.cyclePause=0;w(false,t,s);return false;case"prev":case"next":var x=i(s).data("cycle.opts");if(!x){f('options not found, "prev/next" ignored');return false}i.fn.cycle[v](x);return false;default:v={fx:v}}return v}else{if(v.constructor==Number){var u=v;v=i(s).data("cycle.opts");if(!v){f("options not found, can not advance slide");return false}if(u<0||u>=v.elements.length){f("invalid slide index: "+u);return false}v.nextSlide=u;if(s.cycleTimeout){clearTimeout(s.cycleTimeout);s.cycleTimeout=0}if(typeof t=="string"){v.oneTimeFx=t}e(v.elements,v,1,u>=v.currSlide);return false}}return v;function w(z,A,y){if(!z&&A===true){var B=i(y).data("cycle.opts");if(!B){f("options not found, can not resume");return false}if(y.cycleTimeout){clearTimeout(y.cycleTimeout);y.cycleTimeout=0}e(B.elements,B,1,!B.backwards)}}}function b(s,t){if(!i.support.opacity&&t.cleartype&&s.style.filter){try{s.style.removeAttribute("filter")}catch(u){}}}function r(s){if(s.next){i(s.next).unbind(s.prevNextEvent)}if(s.prev){i(s.prev).unbind(s.prevNextEvent)}if(s.pager||s.pagerAnchorBuilder){i.each(s.pagerAnchors||[],function(){this.unbind().remove()})}s.pagerAnchors=null;if(s.destroy){s.destroy(s)}}function k(A,M,x,v,G){var E=i.extend({},i.fn.cycle.defaults,v||{},i.metadata?A.metadata():i.meta?A.data():{});if(E.autostop){E.countdown=E.autostopCount||x.length}var t=A[0];A.data("cycle.opts",E);E.$cont=A;E.stopCount=t.cycleStop;E.elements=x;E.before=E.before?[E.before]:[];E.after=E.after?[E.after]:[];if(!i.support.opacity&&E.cleartype){E.after.push(function(){b(this,E)})}if(E.continuous){E.after.push(function(){e(x,E,0,!E.backwards)})}o(E);if(!i.support.opacity&&E.cleartype&&!E.cleartypeNoBg){g(M)}if(A.css("position")=="static"){A.css("position","relative")}if(E.width){A.width(E.width)}if(E.height&&E.height!="auto"){A.height(E.height)}if(E.startingSlide){E.startingSlide=parseInt(E.startingSlide)}else{if(E.backwards){E.startingSlide=x.length-1}}if(E.random){E.randomMap=[];for(var K=0;K<x.length;K++){E.randomMap.push(K)}E.randomMap.sort(function(O,w){return Math.random()-0.5});E.randomIndex=1;E.startingSlide=E.randomMap[1]}else{if(E.startingSlide>=x.length){E.startingSlide=0}}E.currSlide=E.startingSlide||0;var z=E.startingSlide;M.css({position:"absolute",top:0,left:0}).hide().each(function(w){var O;if(E.backwards){O=z?w<=z?x.length+(w-z):z-w:x.length-w}else{O=z?w>=z?x.length-(w-z):z-w:x.length-w}i(this).css("z-index",O)});i(x[z]).css("opacity",1).show();b(x[z],E);if(E.fit&&E.width){M.width(E.width)}if(E.fit&&E.height&&E.height!="auto"){M.height(E.height)}var F=E.containerResize&&!A.innerHeight();if(F){var y=0,D=0;for(var I=0;I<x.length;I++){var s=i(x[I]),N=s[0],C=s.outerWidth(),L=s.outerHeight();if(!C){C=N.offsetWidth||N.width||s.attr("width")}if(!L){L=N.offsetHeight||N.height||s.attr("height")}y=C>y?C:y;D=L>D?L:D}if(y>0&&D>0){A.css({width:y+"px",height:D+"px"})}}if(E.pause){A.hover(function(){this.cyclePause++},function(){this.cyclePause--})}if(c(E)===false){return false}var u=false;v.requeueAttempts=v.requeueAttempts||0;M.each(function(){var Q=i(this);this.cycleH=(E.fit&&E.height)?E.height:(Q.height()||this.offsetHeight||this.height||Q.attr("height")||0);this.cycleW=(E.fit&&E.width)?E.width:(Q.width()||this.offsetWidth||this.width||Q.attr("width")||0);if(Q.is("img")){var O=(i.browser.msie&&this.cycleW==28&&this.cycleH==30&&!this.complete);var R=(i.browser.mozilla&&this.cycleW==34&&this.cycleH==19&&!this.complete);var P=(i.browser.opera&&((this.cycleW==42&&this.cycleH==19)||(this.cycleW==37&&this.cycleH==17))&&!this.complete);var w=(this.cycleH==0&&this.cycleW==0&&!this.complete);if(O||R||P||w){if(G.s&&E.requeueOnImageNotLoaded&&++v.requeueAttempts<100){f(v.requeueAttempts," - img slide not loaded, requeuing slideshow: ",this.src,this.cycleW,this.cycleH);setTimeout(function(){i(G.s,G.c).cycle(v)},E.requeueTimeout);u=true;return false}else{f("could not determine size of image: "+this.src,this.cycleW,this.cycleH)}}}return true});if(u){return false}E.cssBefore=E.cssBefore||{};E.cssAfter=E.cssAfter||{};E.cssFirst=E.cssFirst||{};E.animIn=E.animIn||{};E.animOut=E.animOut||{};M.not(":eq("+z+")").css(E.cssBefore);i(M[z]).css(E.cssFirst);if(E.timeout){E.timeout=parseInt(E.timeout);if(E.speed.constructor==String){E.speed=i.fx.speeds[E.speed]||parseInt(E.speed)}if(!E.sync){E.speed=E.speed/2}var H=E.fx=="none"?0:E.fx=="shuffle"?500:250;while((E.timeout-E.speed)<H){E.timeout+=E.speed}}if(E.easing){E.easeIn=E.easeOut=E.easing}if(!E.speedIn){E.speedIn=E.speed}if(!E.speedOut){E.speedOut=E.speed}E.slideCount=x.length;E.currSlide=E.lastSlide=z;if(E.random){if(++E.randomIndex==x.length){E.randomIndex=0}E.nextSlide=E.randomMap[E.randomIndex]}else{if(E.backwards){E.nextSlide=E.startingSlide==0?(x.length-1):E.startingSlide-1}else{E.nextSlide=E.startingSlide>=(x.length-1)?0:E.startingSlide+1}}if(!E.multiFx){var J=i.fn.cycle.transitions[E.fx];if(i.isFunction(J)){J(A,M,E)}else{if(E.fx!="custom"&&!E.multiFx){f("unknown transition: "+E.fx,"; slideshow terminating");return false}}}var B=M[z];if(E.before.length){E.before[0].apply(B,[B,B,E,true])}if(E.after.length){E.after[0].apply(B,[B,B,E,true])}if(E.next){i(E.next).bind(E.prevNextEvent,function(){return q(E,1)})}if(E.prev){i(E.prev).bind(E.prevNextEvent,function(){return q(E,0)})}if(E.pager||E.pagerAnchorBuilder){d(x,E)}j(E,x);return E}function o(s){s.original={before:[],after:[]};s.original.cssBefore=i.extend({},s.cssBefore);s.original.cssAfter=i.extend({},s.cssAfter);s.original.animIn=i.extend({},s.animIn);s.original.animOut=i.extend({},s.animOut);i.each(s.before,function(){s.original.before.push(this)});i.each(s.after,function(){s.original.after.push(this)})}function c(y){var w,u,t=i.fn.cycle.transitions;if(y.fx.indexOf(",")>0){y.multiFx=true;y.fxs=y.fx.replace(/\s*/g,"").split(",");for(w=0;w<y.fxs.length;w++){var x=y.fxs[w];u=t[x];if(!u||!t.hasOwnProperty(x)||!i.isFunction(u)){f("discarding unknown transition: ",x);y.fxs.splice(w,1);w--}}if(!y.fxs.length){f("No valid transitions named; slideshow terminating.");return false}}else{if(y.fx=="all"){y.multiFx=true;y.fxs=[];for(p in t){u=t[p];if(t.hasOwnProperty(p)&&i.isFunction(u)){y.fxs.push(p)}}}}if(y.multiFx&&y.randomizeEffects){var v=Math.floor(Math.random()*20)+30;for(w=0;w<v;w++){var s=Math.floor(Math.random()*y.fxs.length);y.fxs.push(y.fxs.splice(s,1)[0])}a("randomized fx sequence: ",y.fxs)}return true}function j(t,s){t.addSlide=function(v,w){var u=i(v),x=u[0];if(!t.autostopCount){t.countdown++}s[w?"unshift":"push"](x);if(t.els){t.els[w?"unshift":"push"](x)}t.slideCount=s.length;u.css("position","absolute");u[w?"prependTo":"appendTo"](t.$cont);if(w){t.currSlide++;t.nextSlide++}if(!i.support.opacity&&t.cleartype&&!t.cleartypeNoBg){g(u)}if(t.fit&&t.width){u.width(t.width)}if(t.fit&&t.height&&t.height!="auto"){u.height(t.height)}x.cycleH=(t.fit&&t.height)?t.height:u.height();x.cycleW=(t.fit&&t.width)?t.width:u.width();u.css(t.cssBefore);if(t.pager||t.pagerAnchorBuilder){i.fn.cycle.createPagerAnchor(s.length-1,x,i(t.pager),s,t)}if(i.isFunction(t.onAddSlide)){t.onAddSlide(u)}else{u.hide()}}}i.fn.cycle.resetState=function(t,s){s=s||t.fx;t.before=[];t.after=[];t.cssBefore=i.extend({},t.original.cssBefore);t.cssAfter=i.extend({},t.original.cssAfter);t.animIn=i.extend({},t.original.animIn);t.animOut=i.extend({},t.original.animOut);t.fxFn=null;i.each(t.original.before,function(){t.before.push(this)});i.each(t.original.after,function(){t.after.push(this)});var u=i.fn.cycle.transitions[s];if(i.isFunction(u)){u(t.$cont,i(t.elements),t)}};function e(z,s,y,B){if(y&&s.busy&&s.manualTrump){a("manualTrump in go(), stopping active transition");i(z).stop(true,true);s.busy=0}if(s.busy){a("transition active, ignoring new tx request");return}var w=s.$cont[0],D=z[s.currSlide],C=z[s.nextSlide];if(w.cycleStop!=s.stopCount||w.cycleTimeout===0&&!y){return}if(!y&&!w.cyclePause&&!s.bounce&&((s.autostop&&(--s.countdown<=0))||(s.nowrap&&!s.random&&s.nextSlide<s.currSlide))){if(s.end){s.end(s)}return}var A=false;if((y||!w.cyclePause)&&(s.nextSlide!=s.currSlide)){A=true;var x=s.fx;D.cycleH=D.cycleH||i(D).height();D.cycleW=D.cycleW||i(D).width();C.cycleH=C.cycleH||i(C).height();C.cycleW=C.cycleW||i(C).width();if(s.multiFx){if(s.lastFx==undefined||++s.lastFx>=s.fxs.length){s.lastFx=0}x=s.fxs[s.lastFx];s.currFx=x}if(s.oneTimeFx){x=s.oneTimeFx;s.oneTimeFx=null}i.fn.cycle.resetState(s,x);if(s.before.length){i.each(s.before,function(E,F){if(w.cycleStop!=s.stopCount){return}F.apply(C,[D,C,s,B])})}var u=function(){s.busy=0;i.each(s.after,function(E,F){if(w.cycleStop!=s.stopCount){return}F.apply(C,[D,C,s,B])})};a("tx firing("+x+"); currSlide: "+s.currSlide+"; nextSlide: "+s.nextSlide);s.busy=1;if(s.fxFn){s.fxFn(D,C,s,u,B,y&&s.fastOnEvent)}else{if(i.isFunction(i.fn.cycle[s.fx])){i.fn.cycle[s.fx](D,C,s,u,B,y&&s.fastOnEvent)}else{i.fn.cycle.custom(D,C,s,u,B,y&&s.fastOnEvent)}}}if(A||s.nextSlide==s.currSlide){s.lastSlide=s.currSlide;if(s.random){s.currSlide=s.nextSlide;if(++s.randomIndex==z.length){s.randomIndex=0}s.nextSlide=s.randomMap[s.randomIndex];if(s.nextSlide==s.currSlide){s.nextSlide=(s.currSlide==s.slideCount-1)?0:s.currSlide+1}}else{if(s.backwards){var v=(s.nextSlide-1)<0;if(v&&s.bounce){s.backwards=!s.backwards;s.nextSlide=1;s.currSlide=0}else{s.nextSlide=v?(z.length-1):s.nextSlide-1;s.currSlide=v?0:s.nextSlide+1}}else{var v=(s.nextSlide+1)==z.length;if(v&&s.bounce){s.backwards=!s.backwards;s.nextSlide=z.length-2;s.currSlide=z.length-1}else{s.nextSlide=v?0:s.nextSlide+1;s.currSlide=v?z.length-1:s.nextSlide-1}}}}if(A&&s.pager){s.updateActivePagerLink(s.pager,s.currSlide,s.activePagerClass)}var t=0;if(s.timeout&&!s.continuous){t=h(z[s.currSlide],z[s.nextSlide],s,B)}else{if(s.continuous&&w.cyclePause){t=10}}if(t>0){w.cycleTimeout=setTimeout(function(){e(z,s,0,!s.backwards)},t)}}i.fn.cycle.updateActivePagerLink=function(s,u,t){i(s).each(function(){i(this).children().removeClass(t).eq(u).addClass(t)})};function h(x,v,w,u){if(w.timeoutFn){var s=w.timeoutFn.call(x,x,v,w,u);while(w.fx!="none"&&(s-w.speed)<250){s+=w.speed}a("calculated timeout: "+s+"; speed: "+w.speed);if(s!==false){return s}}return w.timeout}i.fn.cycle.next=function(s){q(s,1)};i.fn.cycle.prev=function(s){q(s,0)};function q(v,u){var y=u?1:-1;var t=v.elements;var x=v.$cont[0],w=x.cycleTimeout;if(w){clearTimeout(w);x.cycleTimeout=0}if(v.random&&y<0){v.randomIndex--;if(--v.randomIndex==-2){v.randomIndex=t.length-2}else{if(v.randomIndex==-1){v.randomIndex=t.length-1}}v.nextSlide=v.randomMap[v.randomIndex]}else{if(v.random){v.nextSlide=v.randomMap[v.randomIndex]}else{v.nextSlide=v.currSlide+y;if(v.nextSlide<0){if(v.nowrap){return false}v.nextSlide=t.length-1}else{if(v.nextSlide>=t.length){if(v.nowrap){return false}v.nextSlide=0}}}}var s=v.onPrevNextEvent||v.prevNextClick;if(i.isFunction(s)){s(y>0,v.nextSlide,t[v.nextSlide])}e(t,v,1,u);return false}function d(t,u){var s=i(u.pager);i.each(t,function(v,w){i.fn.cycle.createPagerAnchor(v,w,s,t,u)});u.updateActivePagerLink(u.pager,u.startingSlide,u.activePagerClass)}i.fn.cycle.createPagerAnchor=function(w,x,u,v,y){var t;if(i.isFunction(y.pagerAnchorBuilder)){t=y.pagerAnchorBuilder(w,x);a("pagerAnchorBuilder("+w+", el) returned: "+t)}else{t='<a href="#">'+(w+1)+"</a>"}if(!t){return}var z=i(t);if(z.parents("body").length===0){var s=[];if(u.length>1){u.each(function(){var A=z.clone(true);i(this).append(A);s.push(A[0])});z=i(s)}else{z.appendTo(u)}}y.pagerAnchors=y.pagerAnchors||[];y.pagerAnchors.push(z);z.bind(y.pagerEvent,function(D){D.preventDefault();y.nextSlide=w;var C=y.$cont[0],B=C.cycleTimeout;if(B){clearTimeout(B);C.cycleTimeout=0}var A=y.onPagerEvent||y.pagerClick;if(i.isFunction(A)){A(y.nextSlide,v[y.nextSlide])}e(v,y,1,y.currSlide<w)});if(!/^click/.test(y.pagerEvent)&&!y.allowPagerClickBubble){z.bind("click.cycle",function(){return false})}if(y.pauseOnPagerHover){z.hover(function(){y.$cont[0].cyclePause++},function(){y.$cont[0].cyclePause--})}};i.fn.cycle.hopsFromLast=function(v,u){var t,s=v.lastSlide,w=v.currSlide;if(u){t=w>s?w-s:v.slideCount-s}else{t=w<s?s-w:s+v.slideCount-w}return t};function g(u){a("applying clearType background-color hack");function t(v){v=parseInt(v).toString(16);return v.length<2?"0"+v:v}function s(y){for(;y&&y.nodeName.toLowerCase()!="html";y=y.parentNode){var w=i.css(y,"background-color");if(w&&w.indexOf("rgb")>=0){var x=w.match(/\d+/g);return"#"+t(x[0])+t(x[1])+t(x[2])}if(w&&w!="transparent"){return w}}return"#ffffff"}u.each(function(){i(this).css("background-color",s(this))})}i.fn.cycle.commonReset=function(y,v,x,t,u,s){i(x.elements).not(y).hide();if(typeof x.cssBefore.opacity=="undefined"){x.cssBefore.opacity=1}x.cssBefore.display="block";if(x.slideResize&&t!==false&&v.cycleW>0){x.cssBefore.width=v.cycleW}if(x.slideResize&&u!==false&&v.cycleH>0){x.cssBefore.height=v.cycleH}x.cssAfter=x.cssAfter||{};x.cssAfter.display="none";i(y).css("zIndex",x.slideCount+(s===true?1:0));i(v).css("zIndex",x.slideCount+(s===true?0:1))};i.fn.cycle.custom=function(E,y,s,v,x,t){var D=i(E),z=i(y);var u=s.speedIn,C=s.speedOut,w=s.easeIn,B=s.easeOut;z.css(s.cssBefore);if(t){if(typeof t=="number"){u=C=t}else{u=C=1}w=B=null}var A=function(){z.animate(s.animIn,u,w,function(){v()})};D.animate(s.animOut,C,B,function(){D.css(s.cssAfter);if(!s.sync){A()}});if(s.sync){A()}};i.fn.cycle.transitions={fade:function(t,u,s){u.not(":eq("+s.currSlide+")").css("opacity",0);s.before.push(function(x,v,w){i.fn.cycle.commonReset(x,v,w);w.cssBefore.opacity=0});s.animIn={opacity:1};s.animOut={opacity:0};s.cssBefore={top:0,left:0}}};i.fn.cycle.ver=function(){return l};i.fn.cycle.defaults={activePagerClass:"activeSlide",after:null,allowPagerClickBubble:false,animIn:null,animOut:null,autostop:0,autostopCount:0,backwards:false,before:null,cleartype:!i.support.opacity,cleartypeNoBg:false,containerResize:1,continuous:0,cssAfter:null,cssBefore:null,delay:0,easeIn:null,easeOut:null,easing:null,end:null,fastOnEvent:0,fit:0,fx:"fade",fxFn:null,height:"auto",manualTrump:true,next:null,nowrap:0,onPagerEvent:null,onPrevNextEvent:null,pager:null,pagerAnchorBuilder:null,pagerEvent:"click.cycle",pause:0,pauseOnPagerHover:0,prev:null,prevNextEvent:"click.cycle",random:0,randomizeEffects:1,requeueOnImageNotLoaded:true,requeueTimeout:250,rev:0,shuffle:null,slideExpr:null,slideResize:1,speed:1000,speedIn:null,speedOut:null,startingSlide:0,sync:1,timeout:4000,timeoutFn:null,updateActivePagerLink:null}})(jQuery);(function(a){a.fn.cycle.transitions.none=function(c,d,b){b.fxFn=function(g,e,f,h){a(e).show();a(g).hide();h()}};a.fn.cycle.transitions.fadeout=function(c,d,b){d.not(":eq("+b.currSlide+")").css({display:"block",opacity:1});b.before.push(function(k,i,j,f,g,e){a(k).css("zIndex",j.slideCount+(!e===true?1:0));a(i).css("zIndex",j.slideCount+(!e===true?0:1))});b.animIn.opacity=1;b.animOut.opacity=0;b.cssBefore.opacity=1;b.cssBefore.display="block";b.cssAfter.zIndex=0};a.fn.cycle.transitions.scrollUp=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssBefore.top=b;c.cssBefore.left=0;c.cssFirst.top=0;c.animIn.top=0;c.animOut.top=-b};a.fn.cycle.transitions.scrollDown=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssFirst.top=0;c.cssBefore.top=-b;c.cssBefore.left=0;c.animIn.top=0;c.animOut.top=b};a.fn.cycle.transitions.scrollLeft=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=0-b};a.fn.cycle.transitions.scrollRight=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=-b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=b};a.fn.cycle.transitions.scrollHorz=function(c,d,b){c.css("overflow","hidden").width();b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.left=e?(f.cycleW-1):(1-f.cycleW);g.animOut.left=e?-h.cycleW:h.cycleW});b.cssFirst.left=0;b.cssBefore.top=0;b.animIn.left=0;b.animOut.top=0};a.fn.cycle.transitions.scrollVert=function(c,d,b){c.css("overflow","hidden");b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.top=e?(1-f.cycleH):(f.cycleH-1);g.animOut.top=e?h.cycleH:-h.cycleH});b.cssFirst.top=0;b.cssBefore.left=0;b.animIn.top=0;b.animOut.left=0};a.fn.cycle.transitions.slideX=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,false,true);f.animIn.width=e.cycleW});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.width=0;b.animIn.width="show";b.animOut.width=0};a.fn.cycle.transitions.slideY=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,true,false);f.animIn.height=e.cycleH});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.height=0;b.animIn.height="show";b.animOut.height=0};a.fn.cycle.transitions.shuffle=function(e,f,d){var c,b=e.css("overflow","visible").width();f.css({left:0,top:0});d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h,true,true,true)});if(!d.speedAdjusted){d.speed=d.speed/2;d.speedAdjusted=true}d.random=0;d.shuffle=d.shuffle||{left:-b,top:15};d.els=[];for(c=0;c<f.length;c++){d.els.push(f[c])}for(c=0;c<d.currSlide;c++){d.els.push(d.els.shift())}d.fxFn=function(m,j,l,g,i){if(l.rev){i=!i}var h=i?a(m):a(j);a(j).css(l.cssBefore);var k=l.slideCount;h.animate(l.shuffle,l.speedIn,l.easeIn,function(){var q=a.fn.cycle.hopsFromLast(l,i);for(var r=0;r<q;r++){i?l.els.push(l.els.shift()):l.els.unshift(l.els.pop())}if(i){for(var s=0,o=l.els.length;s<o;s++){a(l.els[s]).css("z-index",o-s+k)}}else{var t=a(m).css("z-index");h.css("z-index",parseInt(t)+1+k)}h.animate({left:0,top:0},l.speedOut,l.easeOut,function(){a(i?this:m).hide();if(g){g()}})})};a.extend(d.cssBefore,{display:"block",opacity:1,top:0,left:0})};a.fn.cycle.transitions.turnUp=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.cssBefore.top=e.cycleH;f.animIn.height=e.cycleH;f.animOut.width=e.cycleW});b.cssFirst.top=0;b.cssBefore.left=0;b.cssBefore.height=0;b.animIn.top=0;b.animOut.height=0};a.fn.cycle.transitions.turnDown=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.animIn.height=e.cycleH;f.animOut.top=g.cycleH});b.cssFirst.top=0;b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.height=0;b.animOut.height=0};a.fn.cycle.transitions.turnLeft=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.cssBefore.left=e.cycleW;f.animIn.width=e.cycleW});b.cssBefore.top=0;b.cssBefore.width=0;b.animIn.left=0;b.animOut.width=0};a.fn.cycle.transitions.turnRight=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.animIn.width=e.cycleW;f.animOut.left=g.cycleW});a.extend(b.cssBefore,{top:0,left:0,width:0});b.animIn.left=0;b.animOut.width=0};a.fn.cycle.transitions.zoom=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,false,true);f.cssBefore.top=e.cycleH/2;f.cssBefore.left=e.cycleW/2;a.extend(f.animIn,{top:0,left:0,width:e.cycleW,height:e.cycleH});a.extend(f.animOut,{width:0,height:0,top:g.cycleH/2,left:g.cycleW/2})});b.cssFirst.top=0;b.cssFirst.left=0;b.cssBefore.width=0;b.cssBefore.height=0};a.fn.cycle.transitions.fadeZoom=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,false);f.cssBefore.left=e.cycleW/2;f.cssBefore.top=e.cycleH/2;a.extend(f.animIn,{top:0,left:0,width:e.cycleW,height:e.cycleH})});b.cssBefore.width=0;b.cssBefore.height=0;b.animOut.opacity=0};a.fn.cycle.transitions.blindX=function(d,e,c){var b=d.css("overflow","hidden").width();c.before.push(function(h,f,g){a.fn.cycle.commonReset(h,f,g);g.animIn.width=f.cycleW;g.animOut.left=h.cycleW});c.cssBefore.left=b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=b};a.fn.cycle.transitions.blindY=function(d,e,c){var b=d.css("overflow","hidden").height();c.before.push(function(h,f,g){a.fn.cycle.commonReset(h,f,g);g.animIn.height=f.cycleH;g.animOut.top=h.cycleH});c.cssBefore.top=b;c.cssBefore.left=0;c.animIn.top=0;c.animOut.top=b};a.fn.cycle.transitions.blindZ=function(e,f,d){var c=e.css("overflow","hidden").height();var b=e.width();d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h);h.animIn.height=g.cycleH;h.animOut.top=i.cycleH});d.cssBefore.top=c;d.cssBefore.left=b;d.animIn.top=0;d.animIn.left=0;d.animOut.top=c;d.animOut.left=b};a.fn.cycle.transitions.growX=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.cssBefore.left=this.cycleW/2;f.animIn.left=0;f.animIn.width=this.cycleW;f.animOut.left=0});b.cssBefore.top=0;b.cssBefore.width=0};a.fn.cycle.transitions.growY=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.cssBefore.top=this.cycleH/2;f.animIn.top=0;f.animIn.height=this.cycleH;f.animOut.top=0});b.cssBefore.height=0;b.cssBefore.left=0};a.fn.cycle.transitions.curtainX=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true,true);f.cssBefore.left=e.cycleW/2;f.animIn.left=0;f.animIn.width=this.cycleW;f.animOut.left=g.cycleW/2;f.animOut.width=0});b.cssBefore.top=0;b.cssBefore.width=0};a.fn.cycle.transitions.curtainY=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false,true);f.cssBefore.top=e.cycleH/2;f.animIn.top=0;f.animIn.height=e.cycleH;f.animOut.top=g.cycleH/2;f.animOut.height=0});b.cssBefore.height=0;b.cssBefore.left=0};a.fn.cycle.transitions.cover=function(f,g,e){var i=e.direction||"left";var b=f.css("overflow","hidden").width();var c=f.height();e.before.push(function(j,d,h){a.fn.cycle.commonReset(j,d,h);if(i=="right"){h.cssBefore.left=-b}else{if(i=="up"){h.cssBefore.top=c}else{if(i=="down"){h.cssBefore.top=-c}else{h.cssBefore.left=b}}}});e.animIn.left=0;e.animIn.top=0;e.cssBefore.top=0;e.cssBefore.left=0};a.fn.cycle.transitions.uncover=function(f,g,e){var i=e.direction||"left";var b=f.css("overflow","hidden").width();var c=f.height();e.before.push(function(j,d,h){a.fn.cycle.commonReset(j,d,h,true,true,true);if(i=="right"){h.animOut.left=b}else{if(i=="up"){h.animOut.top=-c}else{if(i=="down"){h.animOut.top=c}else{h.animOut.left=-b}}}});e.animIn.left=0;e.animIn.top=0;e.cssBefore.top=0;e.cssBefore.left=0};a.fn.cycle.transitions.toss=function(e,f,d){var b=e.css("overflow","visible").width();var c=e.height();d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h,true,true,true);if(!h.animOut.left&&!h.animOut.top){a.extend(h.animOut,{left:b*2,top:-c/2,opacity:0})}else{h.animOut.opacity=0}});d.cssBefore.left=0;d.cssBefore.top=0;d.animIn.left=0};a.fn.cycle.transitions.wipe=function(u,m,e){var s=u.css("overflow","hidden").width();var j=u.height();e.cssBefore=e.cssBefore||{};var g;if(e.clip){if(/l2r/.test(e.clip)){g="rect(0px 0px "+j+"px 0px)"}else{if(/r2l/.test(e.clip)){g="rect(0px "+s+"px "+j+"px "+s+"px)"}else{if(/t2b/.test(e.clip)){g="rect(0px "+s+"px 0px 0px)"}else{if(/b2t/.test(e.clip)){g="rect("+j+"px "+s+"px "+j+"px 0px)"}else{if(/zoom/.test(e.clip)){var q=parseInt(j/2);var f=parseInt(s/2);g="rect("+q+"px "+f+"px "+q+"px "+f+"px)"}}}}}}e.cssBefore.clip=e.cssBefore.clip||g||"rect(0px 0px 0px 0px)";var k=e.cssBefore.clip.match(/(\d+)/g);var v=parseInt(k[0]),c=parseInt(k[1]),o=parseInt(k[2]),i=parseInt(k[3]);e.before.push(function(x,h,t){if(x==h){return}var d=a(x),b=a(h);a.fn.cycle.commonReset(x,h,t,true,true,false);t.cssAfter.display="block";var r=1,l=parseInt((t.speedIn/13))-1;(function w(){var z=v?v-parseInt(r*(v/l)):0;var A=i?i-parseInt(r*(i/l)):0;var B=o<j?o+parseInt(r*((j-o)/l||1)):j;var y=c<s?c+parseInt(r*((s-c)/l||1)):s;b.css({clip:"rect("+z+"px "+y+"px "+B+"px "+A+"px)"});(r++<=l)?setTimeout(w,13):d.css("display","none")})()});a.extend(e.cssBefore,{display:"block",opacity:1,top:0,left:0});e.animIn={left:0};e.animOut={left:0}}})(jQuery);(function(i,f){var v=i.fn.domManip,h="_tmplitem",w=/^[^<]*(<[\w\W]+>)[^>]*$|\{\{\! /,r={},e={},A,z={key:0,data:{}},y=0,s=0,g=[];function k(D,C,F,G){var E={data:G||(C?C.data:{}),_wrap:C?C._wrap:null,tmpl:null,parent:C||null,nodes:[],calls:c,nest:b,wrap:o,html:t,update:B};if(D){i.extend(E,D,{nodes:[],parent:C})}if(F){E.tmpl=F;E._ctnt=E._ctnt||E.tmpl(i,E);E.key=++y;(g.length?e:r)[y]=E}return E}i.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(C,D){i.fn[C]=function(E){var H=[],K=i(E),G,I,F,L,J=this.length===1&&this[0].parentNode;A=r||{};if(J&&J.nodeType===11&&J.childNodes.length===1&&K.length===1){K[D](this[0]);H=this}else{for(I=0,F=K.length;I<F;I++){s=I;G=(I>0?this.clone(true):this).get();i.fn[D].apply(i(K[I]),G);H=H.concat(G)}s=0;H=this.pushStack(H,C,K.selector)}L=A;A=null;i.tmpl.complete(L);return H}});i.fn.extend({tmpl:function(E,D,C){return i.tmpl(this[0],E,D,C)},tmplItem:function(){return i.tmplItem(this[0])},template:function(C){return i.template(C,this[0])},domManip:function(E,I,J,D){if(E[0]&&E[0].nodeType){var H=i.makeArray(arguments),G=E.length,F=0,C;while(F<G&&!(C=i.data(E[F++],"tmplItem"))){}if(G>1){H[0]=[i.makeArray(E)]}if(C&&s){H[2]=function(K){i.tmpl.afterManip(this,K,J)}}v.apply(this,H)}else{v.apply(this,arguments)}s=0;if(!A){i.tmpl.complete(r)}return this}});i.extend({tmpl:function(E,H,G,D){var F,C=!D;if(C){D=z;E=i.template[E]||i.template(null,E);e={}}else{if(!E){E=D.tmpl;r[D.key]=D;D.nodes=[];if(D.wrapped){u(D,D.wrapped)}return i(m(D,null,D.tmpl(i,D)))}}if(!E){return[]}if(typeof H==="function"){H=H.call(D||{})}if(G&&G.wrapped){u(G,G.wrapped)}F=i.isArray(H)?i.map(H,function(I){return I?k(G,D,E,I):null}):[k(G,D,E,H)];return C?i(m(D,null,F)):F},tmplItem:function(D){var C;if(D instanceof i){D=D[0]}while(D&&D.nodeType===1&&!(C=i.data(D,"tmplItem"))&&(D=D.parentNode)){}return C||z},template:function(D,C){if(C){if(typeof C==="string"){C=l(C)}else{if(C instanceof i){C=C[0]||{}}}if(C.nodeType){C=i.data(C,"tmpl")||i.data(C,"tmpl",l(C.innerHTML))}return typeof D==="string"?(i.template[D]=C):C}return D?(typeof D!=="string"?i.template(null,D):(i.template[D]||i.template(null,w.test(D)?D:i(D)))):null},encode:function(C){return(""+C).split("<").join("&lt;").split(">").join("&gt;").split('"').join("&#34;").split("'").join("&#39;")}});i.extend(i.tmpl,{tag:{tmpl:{_default:{$2:"null"},open:"if($notnull_1){_=_.concat($item.nest($1,$2));}"},wrap:{_default:{$2:"null"},open:"$item.calls(_,$1,$2);_=[];",close:"call=$item.calls();_=call._.concat($item.wrap(call,_));"},each:{_default:{$2:"$index, $value"},open:"if($notnull_1){$.each($1a,function($2){with(this){",close:"}});}"},"if":{open:"if(($notnull_1) && $1a){",close:"}"},"else":{_default:{$1:"true"},open:"}else if(($notnull_1) && $1a){"},html:{open:"if($notnull_1){_.push($1a);}"},"=":{_default:{$1:"$data"},open:"if($notnull_1){_.push($.encode($1a));}"},"!":{open:""}},complete:function(C){r={}},afterManip:function x(E,C,F){var D=C.nodeType===11?i.makeArray(C.childNodes):C.nodeType===1?[C]:[];F.call(E,C);q(D);s++}});function m(C,G,E){var F,D=E?i.map(E,function(H){return(typeof H==="string")?(C.key?H.replace(/(<\w+)(?=[\s>])(?![^>]*_tmplitem)([^>]*)/g,"$1 "+h+'="'+C.key+'" $2'):H):m(H,C,H._ctnt)}):C;if(G){return D}D=D.join("");D.replace(/^\s*([^<\s][^<]*)?(<[\w\W]+>)([^>]*[^>\s])?\s*$/,function(I,J,H,K){F=i(H).get();q(F);if(J){F=a(J).concat(F)}if(K){F=F.concat(a(K))}});return F?F:a(D)}function a(D){var C=document.createElement("div");C.innerHTML=D;return i.makeArray(C.childNodes)}function l(C){return new Function("jQuery","$item","var $=jQuery,call,_=[],$data=$item.data;with($data){_.push('"+i.trim(C).replace(/([\\'])/g,"\\$1").replace(/[\r\t\n]/g," ").replace(/\$\{([^\}]*)\}/g,"{{= $1}}").replace(/\{\{(\/?)(\w+|.)(?:\(((?:[^\}]|\}(?!\}))*?)?\))?(?:\s+(.*?)?)?(\(((?:[^\}]|\}(?!\}))*?)\))?\s*\}\}/g,function(K,E,I,F,G,L,H){var N=i.tmpl.tag[I],D,J,M;if(!N){throw"Template command not found: "+I}D=N._default||[];if(L&&!/\w$/.test(G)){G+=L;L=""}if(G){G=j(G);H=H?(","+j(H)+")"):(L?")":"");J=L?(G.indexOf(".")>-1?G+L:("("+G+").call($item"+H)):G;M=L?J:"(typeof("+G+")==='function'?("+G+").call($item):("+G+"))"}else{M=J=D.$1||"null"}F=j(F);return"');"+N[E?"close":"open"].split("$notnull_1").join(G?"typeof("+G+")!=='undefined' && ("+G+")!=null":"true").split("$1a").join(M).split("$1").join(J).split("$2").join(F?F.replace(/\s*([^\(]+)\s*(\((.*?)\))?/g,function(P,O,Q,R){R=R?(","+R+")"):(Q?")":"");return R?("("+O+").call($item"+R):P}):(D.$2||""))+"_.push('"})+"');}return _;")}function u(D,C){D._wrap=m(D,true,i.isArray(C)?C:[w.test(C)?C:i(C).html()]).join("")}function j(C){return C?C.replace(/\\'/g,"'").replace(/\\\\/g,"\\"):null}function d(C){var D=document.createElement("div");D.appendChild(C.cloneNode(true));return D.innerHTML}function q(I){var K="_"+s,D,C,G={},H,F,E;for(H=0,F=I.length;H<F;H++){if((D=I[H]).nodeType!==1){continue}C=D.getElementsByTagName("*");for(E=C.length-1;E>=0;E--){J(C[E])}J(D)}function J(Q){var N,P=Q,O,L,M;if((M=Q.getAttribute(h))){while(P.parentNode&&(P=P.parentNode).nodeType===1&&!(N=P.getAttribute(h))){}if(N!==M){P=P.parentNode?(P.nodeType===11?0:(P.getAttribute(h)||0)):0;if(!(L=r[M])){L=e[M];L=k(L,r[P]||e[P],null,true);L.key=++y;r[y]=L}if(s){R(M)}}Q.removeAttribute(h)}else{if(s&&(L=i.data(Q,"tmplItem"))){R(L.key);r[L.key]=L;P=i.data(Q.parentNode,"tmplItem");P=P?P.key:0}}if(L){O=L;while(O&&O.key!=P){O.nodes.push(Q);O=O.parent}delete L._ctnt;delete L._wrap;i.data(Q,"tmplItem",L)}function R(S){S=S+K;L=G[S]=(G[S]||k(L,r[L.parent.key+K]||L.parent,null,true))}}}function c(E,C,F,D){if(!E){return g.pop()}g.push({_:E,tmpl:C,item:this,data:F,options:D})}function b(C,E,D){return i.tmpl(i.template(C),E,D,this)}function o(E,C){var D=E.options||{};D.wrapped=C;return i.tmpl(i.template(E.tmpl),E.data,D,E.item)}function t(D,E){var C=this._wrap;return i.map(i(i.isArray(C)?C.join(""):C).filter(D||"*"),function(F){return E?F.innerText||F.textContent:F.outerHTML||d(F)})}function B(){var C=this.nodes;i.tmpl(null,null,null,this).insertBefore(C[0]);i(C).remove()}})(jQuery);new function(a){a.fn.cexplaceholder=function(f){f=f||{};var b=f.attr||"ph";var e=f.className||"cexplaceholder";var c=f.className||"focus-cexplaceholder";var g=["padding-left","margin-left","margin-top","border-left","border-top","font-size","font-weight"];var d=function(){while(true){var h="rid_"+Math.floor(Math.random()*100001);if(a("#"+h).length==0){return h}}};return this.each(function(){if(!a(this).prev().hasClass(e)){if(!a(this).attr("id")){a(this).attr("id",d())}a(this).before("<label></label")}a(this).prev().addClass(e).attr("for",a(this).attr("id")).css({position:"absolute"});var h=a(this).position();var k=f.style||{};k.top=h.top;k.left=h.left;k.height=k["line-height"]=a(this).get(0).offsetHeight+"px";for(var j=0;j<g.length;j++){k[g[j]]=a(this).css(g[j])}a(this).prev().css(k).html(a(this).attr(b))}).focus(function(){a(this).prev().addClass(c);if(a(this).val()){a(this).prev().hide()}else{a(this).prev().show()}}).blur(function(){a(this).prev().removeClass(c);if(!a(this).val()){a(this).prev().show()}}).keyup(function(){if(a(this).val()){a(this).prev().hide()}else{a(this).prev().show()}}).hover(function(){a(this).prev().addClass("cexplaceholder-mouseon")},function(){a(this).prev().removeClass("cexplaceholder-mouseon")}).unload(function(){if(a(this).prev().hasClass(e)){a(this).prev().remove()}})}}(jQuery);new function(a){a.fn.setCursorPosition=function(b){this.each(function(e,d){if(d.setSelectionRange){d.setSelectionRange(b,b)}else{if(d.createTextRange()){var c=d.createTextRange();c.collapse(true);c.moveEnd("character",b);c.moveStart("character",b);c.select()}}});return this};a.fn.enter=function(b){this.unbind("keypress");return this.bind("keypress",function(d){var c=(d.keyCode?d.keyCode:d.which);if(c==13){b(d)}})};a.fn.getval=function(){if(this.hasClass("placeholder")){return""}return this.val().replace(/^\s+|\s+$/g,"")};a.fn.loading=function(){this.addClass("loading");return this};a.fn.unloading=function(){this.removeClass("loading");return this};a.fn.add_error=function(b){this.after('<div class="error-message">'+b+"</div>");return this};a.fn.remove_error=function(){if(this.next().hasClass("error-message")){this.next().remove()}return this}}(jQuery);jQuery.wait=(function($){var my={};my.queue=[];my.init=function(){my.timer=setInterval("$.wait.check()",3000)};my.check=function(){var success_queue=$.grep(my.queue,function(v,i){return eval(v.clause)});my.queue=$.grep(my.queue,function(v,i){return !eval(v.clause)});$.each(success_queue,function(i,v){v.func(v.params)})};my.add=function(clause,func,params){my.queue.push({clause:clause,func:func,params:params})};my.init();return my})(jQuery);var cex=cex||{};var strip_tags=function(a){a=a.replace(/([<])/g,"&lt;");a=a.replace(/([>])/g,"&gt;");return a};var strip_object=function(c){var b=typeof(c);if(b!="object"||c===null){if(b=="string"){c=Url.decode(strip_tags(c))}return c}else{var d,a;for(d in c){a=c[d];c[d]=strip_object(a)}return c}};var encode_object=function(c){var b=typeof(c);if(b!="object"||c===null){if(b=="string"){c=Url.encode(c)}return c}else{var d,a;for(d in c){a=c[d];c[d]=encode_object(a)}return c}};var ajax_call=function(c,d,f,b,a){a=a||{};d=d||{};if(cex.session_id){d.session_id=cex.session_id}d.fb_connected=cex.fb.connected;var e={url:c,dataType:a.dataType||"json",data:d,type:"POST"};if(e.dataType=="json"){d.json=1}if(f){e.success=function(g){f(strip_object(g))}}if(b){e.error=b}$.ajax(e)};var serdes={make_static_url:function(a){var b="";if(a.charAt(0)!="/"){b="/"}var c="/version/"+config.version_id+b+a;return"http://"+config.ver_domain+c}};var Url={encode:function(a){return escape(this._utf8_encode(a))},decode:function(a){return this._utf8_decode(unescape(a))},_utf8_encode:function(b){b=b.replace(/\r\n/g,"\n");var a="";for(var e=0;e<b.length;e++){var d=b.charCodeAt(e);if(d<128){a+=String.fromCharCode(d)}else{if((d>127)&&(d<2048)){a+=String.fromCharCode((d>>6)|192);a+=String.fromCharCode((d&63)|128)}else{a+=String.fromCharCode((d>>12)|224);a+=String.fromCharCode(((d>>6)&63)|128);a+=String.fromCharCode((d&63)|128)}}}return a},_utf8_decode:function(a){var b="";var d=0;var e=c1=c2=0;while(d<a.length){e=a.charCodeAt(d);if(e<128){b+=String.fromCharCode(e);d++}else{if((e>191)&&(e<224)){c2=a.charCodeAt(d+1);b+=String.fromCharCode(((e&31)<<6)|(c2&63));d+=2}else{c2=a.charCodeAt(d+1);c3=a.charCodeAt(d+2);b+=String.fromCharCode(((e&15)<<12)|((c2&63)<<6)|(c3&63));d+=3}}}return b}};cex.util={};cex.util.is_valid_name=function(a){return !(a.match(/[^0-9a-zA-Z\-\_\s]/g))};cex.util.is_valid_email=function(a){return a.match(/([0-9a-z+-_]+)@([0-9a-z]+)\.([0-9a-zA-Z]+)/gi)};var parseUrl=function(c){var a=c.split("?");var b=a[0];var g={};if(a.length==2){var e=a[1].split("&");for(var d=0;d<e.length;d++){var f=e[d].split("=");g[f[0]]=f[1]}}return{url:b,params:g}};cex.util.overlay={show:function(){$(".overlay").show()},hide:function(){$(".overlay").hide()}};cex.util.json_encoder=function(e){var d=typeof(e);if(d!="object"||e===null){if(d=="string"){e='"'+e+'"'}return String(e)}else{var f,b,c=[],a=(e&&e.constructor==Array);for(f in e){b=e[f];d=typeof(b);if(d=="string"){b='"'+b+'"'}else{if(d=="object"&&b!==null){b=cex.util.json_encoder(b)}}c.push((a?"":'"'+f+'":')+String(b))}return(a?"[":"{")+String(c)+(a?"]":"}")}};cex.util.is_input_blank=function(a){if(a===""){return true}else{if(a.match(/^\s+$/g)){return true}else{return false}}};cex.phonenumber=(function(){var a={};a.init=function(){var b=function(f){var d=$(this);var c=[37,39];if($.inArray(f.keyCode,c)>-1){return}if(d.getval()!==""){d.val(a.to_number(d.val()))}};(function(c){c("body").delegate(".inputphone","keyup",b);c("body").delegate(".inputphone","blur",b)})(jQuery)};a.to_number=function(b){var c=a.to_digital(b);if(c.length<=3){return c}else{if(c.length<7){return c.slice(0,3)+"-"+c.slice(3)}else{if(c.length<11){return"("+c.slice(0,3)+") "+c.slice(3,6)+"-"+c.slice(6)}else{return"("+c.slice(1,4)+") "+c.slice(4,7)+"-"+c.slice(7,11)}}}};a.to_digital=function(b){return b.toString().replace(/[^0-9]/g,"")};a.compare=function(c,b){return(a.to_number(c)==a.to_number(b))};a.init();return a})();cex.redirect=function(a){window.location=a};cex.page_reload=function(){window.location.reload(true)};cex.go_to_home=function(){cex.redirect("/")};cex.go_to_login=function(b){var a="/signin";if(b&&b!==undefined){a+="?";for(n in b){a+=encode_object(n)+"="+encode_object(b[n])+"&"}}cex.redirect(a)};cex.logout=function(){$.cookie("cex_sig",null,{domain:cex.domain,path:"/"});cex.go_to_login()};cex.ajax_log=function(a,b,d){var c={event:a,data:cex.util.json_encoder(b)};ajax_call("/logger/log",c,d)};cex.popup=(function(a){var b={};b.list=[];b.current=null;b.get_button_id=function(c){return"generic-dialog-button-"+escape(c)};b.get_button=function(d){var c=b.get_button_id(d);return $("#"+c)};b.show=function(){var g=b.current.buttons;$(".pop-up-dialog .dialog-title").html(b.current.caption);$(".pop-up-dialog .dialog-content").html(b.current.content);$(".pop-up-dialog .dialog-buttons").empty();for(var c in g){var i=b.get_button_id(c);var f=g[c].style||"";var d=g[c].value||c;var e='<a id="'+i+'" class="button '+f+'">'+d+"</a>";$(".pop-up-dialog .dialog-buttons").append(e);if(g[c].func){$("#"+i).die().live("click",g[c].func)}}if(b.current.button_desc){$(".pop-up-dialog .dialog-buttons").append(b.current.button_desc)}$(".pop-up-dialog").show();if(f!==undefined){$(".pop-up-dialog .pop-up").css(b.current.style)}$(".pop-up-dialog .dialog-content input").each(function(){$(this).cexplaceholder()})};b.next=function(){if(b.current===null){if(b.list.length>0){b.current=b.list.shift();b.show()}}};b.append=function(c){b.list.push(c);b.next()};b.insert=function(c){b.list.unshift(c);b.next()};b.close=function(){$(".pop-up-dialog").hide();b.current=null;b.next()};return b})(cex);cex.user=(function(a){var b={};b.get=function(c){ajax_call("/user/get_info",{},function(e){if(!e.rc){for(var d in e.data){b[d]=e.data[d]}}else{a.go_to_home()}if(c!==undefined){c(e)}})};b.update=function(c,d){ajax_call("/user/update_info",c,d)};b.validate=function(d,c,e){ajax_call("/user/signin",{name:d,password:c},e)};b.switch_user=function(c,d){ajax_call("/user/switch_user",{name:c},d)};b.get_new_password=function(c,d){ajax_call("/user/resend_pwd",{name:c},d)};b.create=function(c,e){ajax_call("/user/create",encode_object(c),e)};b.deleteUser=function(d,c){ajax_call("/user/delete",{forever:d},c)};return b})(cex);cex.signin=(function(a){var b={};b.init=function(){$("#btn_account_sign_in").click(b.verification);$("#resend_pwd").click(function(){a.password.forget()});$("#phone_user").click(function(){a.password.forget()});$("#password").enter(function(){$("#signin-form .button").trigger("click")});$("#username").val($.cookie("cex_number")).cexplaceholder().enter(function(){$("#signin-form .button").trigger("click")});$(document).click(function(){$("#signin-form").hide();$("#signin-button-box").removeClass("grey").addClass("darkgray")});$("#signin-form").click(function(c){c.stopPropagation()});$(".signin-button").click(function(c){c.stopPropagation();if(!$("#signin-form").is(":visible")){$("#password").remove_error();$("#signin-form").show();$("#signin-button-box").addClass("grey").removeClass("darkgray");$("#password").cexplaceholder();$("#username").cexplaceholder().focus()}else{$("#signin-form").hide();$("#signin-button-box").removeClass("grey").addClass("darkgray")}})};b.callback=function(d){if(!d.rc){if($("#cookiecheck").is(":checked")){$.cookie("cex_number",$("#username").getval(),{domain:a.domain,path:"/",expires:300})}var c=parseUrl(window.location.href)["params"]["origin_url"];a.go_to_home()}else{$("#password").add_error(d.error);$("#signin-form .button").die().live("click",b.verification).removeClass("disable")}};b.verification=function(){a.ajax_log(cex_event.BUTTON_CLICK,{foreign_id:"sign up page sign-in button",data:""});if($("#signin-form .button").hasClass("disable")){return}var d=$("#password").getval();var c=$("#username").getval();$("#password").remove_error();if((d==="")||(c==="")){$("#password").add_error("Username and password are needed");return}$("#btn_account_sign_in").die();$("#signin-form .button").die().addClass("disable");a.user.validate(c,d,b.callback)};return b})(cex);cex.password=(function(a){var b={};b.forget=function(c){if(c===undefined){var c=""}c=a.phonenumber.to_number(c);var d=$.tmpl("tmpl_forgot_pwd_popup",{number:c});a.popup.insert({caption:"Get password",content:d,buttons:{Cancel:{style:"light-grey",value:"Cancel",func:a.popup.close},Send:{style:"blue",value:"Send",func:function(){var f=a.popup.get_button_id("Send");var e=$("#number_forget_password").getval();if(e===""){return}$("#"+f).die().addClass("disable").html("Sending...");a.user.get_new_password(e,function(g){if(!g.rc){b.send_pwd_success(e)}else{b.send_pwd_fail(e)}a.popup.close()})}}},style:{width:"400px"}})};b.send_pwd_success=function(c){c=a.phonenumber.to_number(c);var d=$.tmpl("tmpl_send_pwd_success",{number:c});a.popup.insert({caption:"Get password",content:d,buttons:{Close:{style:"blue",value:"Done",func:a.popup.close}},style:{width:"400px"}})};b.send_pwd_fail=function(c){c=a.phonenumber.to_number(c);var d=" 				We fail to send a temporary password to you. Please check your account and try again.			";a.popup.insert({caption:"Get password",content:d,buttons:{Close:{style:"blue",value:"Cancel",func:a.popup.close},Resend:{style:"blue",value:"Resend",func:function(){b.forget(c);a.popup.close()}}},style:{width:"400px"}})};return b})(cex);cex.signup=(function(a){var b={};b.values={};b.init=function(){$("#btn_start_group").live("click",b.clickSubmit);$("#number").val("").focus().cexplaceholder().enter(b.clickSubmit);var d=parseUrl(window.location.href)["params"];var c="";if(d.fname!=undefined&&d.fname!=""){c+=d.fname}if(d.lname!=undefined&&d.lname!=""){if(c!=""){c+=" "}c+=d.lname}$("#fullname").val(c).cexplaceholder().focus()};b.clickSubmit=function(){$("#fullname").removeClass("error-input");$("#number").removeClass("error-input");$("#fullname-error").hide();$("#number-error").hide();var e=$("#fb-connection").attr("checked");a.ajax_log(cex_event.BUTTON_CLICK,{foreign_id:"sign up page create button",data:e});var d=$("#fullname").getval();var c=$("#number").getval();if(d==""){a.ajax_log(cex_event.SIGN_UP_ERROR,{data:e});$("#fullname").addClass("error-input");$("#fullname-error").html("Full name is required").show()}else{if(!a.util.is_valid_name(d)){a.ajax_log(cex_event.SIGN_UP_ERROR,{data:e});$("#fullname").addClass("error-input");$("#fullname-error").html("English character only").show()}else{if(c==""){a.ajax_log(cex_event.SIGN_UP_ERROR,{data:e});$("#number").addClass("error-input");$("#number-error").html("Mobile number is required").show()}else{if(!(a.phonenumber.to_digital(c).length===10)){a.ajax_log(cex_event.SIGN_UP_ERROR,{data:e});$("#number").addClass("error-input");$("#number-error").html("Mobile number is invalid").show()}else{var f=d.indexOf(" ");if(f==-1){f=d.length}fname=d.slice(0,f);lname=d.slice(f+1);b.values={fname:fname,lname:lname,phone:c};if(e){a.fb.login(b.submit)}else{b.submit()}}}}}};b.submit=function(){$("#btn_start_group").die().addClass("disable");a.user.create(b.values,function(c){if(!c.rc){a.redirect(c.redirect+"?fname="+Url.encode(b.values.fname)+"					&lname="+Url.encode(b.values.lname))}else{$("#btn_start_group").live("click",b.submit).removeClass("disable");a.ajax_log(cex_event.SIGN_UP_ERROR,{data:$("#fb-connection").attr("checked")})}})};return b})(cex);cex.group=(function(a){var b={};b.gid_token="";b.number="";b.members=[];b.name="";b.own=[];b.group_list=[];b.g={};b.create=function(c,d){ajax_call("/group/create",{name:c},function(e){if(!e.rc){}else{}if(d!==undefined){d(e)}})};b.createWithMember=function(c,d){ajax_call("/group/create_with_member",{data:c},function(e){if(!e.rc){}else{}if(d!==undefined){d(e)}})};b.create_tmp=function(c){ajax_call("/group/create_tmp",{},function(d){if(!d.rc){b.gid_token=d.gid_token;b.number=a.phonenumber.to_number(d.no)}else{}if(c!==undefined){c(d)}})};b.update=function(c,d){c.gid_token=c.gid_token||b.gid_token||"";ajax_call("/group/update",{data:a.util.json_encoder(encode_object(c))},function(g){if(!g.rc&&(g.group!==undefined)){for(var e in b.group_list){var f=b.group_list[e];if(f.gid_token===g.group.gid_token){b.group_list[e]=g.group;if(b.gid_token===g.group.gid_token){b.members=b.format_member_phone(g.group.m);b.name=g.group.n;b.g=g.group;b.number=a.phonenumber.to_number(g.group.no)}break}}}else{}d(g)})};b.all=function(c){ajax_call("/group/all",{},function(d){if(!d.rc){b.group_list=d.gs}else{}if(c!==undefined){c(d)}})};b.switch_group=function(d){for(var c=0;c<b.group_list.length;c++){var e=b.group_list[c];if(e.gid_token===d){b.gid_token=d;b.members=b.format_member_phone(e.m);b.name=e.n;b.g=e;b.number=a.phonenumber.to_number(e.no);b.own=e.own;return}}};b.format_member_phone=function(c){for(var d=0;d<c.length;d++){c[d].phone=a.phonenumber.to_number(c[d].phone)}return c};b.getCreatedGroupAmount=function(){var d=0;for(var c=0;c<b.group_list.length;c++){if(b.group_list[c].own){d++}}return d};return b})(cex);cex.msg=(function(a){var b={};b.MAX_MSG_LENGTH=140;b.msg_list=[];b.large_id="";b.small_id="";b.timer=undefined;b.checkcallback=undefined;b.checklock=false;b.post=function(c,d){ajax_call("/message/send",{gid_token:a.group.gid_token,msg:c},function(e){if(!e.rc){b.check()}else{}if(d!==undefined){d(e)}})};b.get=function(c){b.stop_check();ajax_call("/message/read",{gid_token:a.group.gid_token},function(d){if(!d.rc&&a.group.gid_token==d.gid_token){b.msg_list=d.m;if(d.m.length>0){b.large_id=d.m[0].id;b.small_id=d.m[d.m.length-1].id}else{b.large_id="";b.small_id=""}}else{}if(c!==undefined){c(d)}})};b.get_older=function(c){ajax_call("/message/get_more",{gid_token:a.group.gid_token,mid:b.small_id},function(d){if(!d.rc&&a.group.gid_token==d.gid_token){if(d.m.length&&d.m[0]["id"]<b.small_id){b.msg_list=b.msg_list.concat(d.m);b.small_id=d.m[d.m.length-1].id}}else{}if(c!==undefined){c(d)}})};b.start_check=function(c){if(b.timer!==undefined){clearTimeout(b.timer)}b.timer=setTimeout("cex.msg.check()",5000);b.checkcallback=c};b.stop_check=function(){if(b.timer!==undefined){clearTimeout(b.timer)}};b.check=function(){clearTimeout(b.timer);b.timer=setTimeout("cex.msg.check()",5000);if(!b.large_id||b.large_id==undefined){return}ajax_call("/message/check",{gid_token:a.group.gid_token,mid:b.large_id},function(c){if(!c.rc&&a.group.gid_token==c.gid_token){if(c.m.length&&c.m[c.m.length-1]["id"]>b.large_id){if(b.checkcallback!==undefined){b.checkcallback(c.m)}b.msg_list=c.m.concat(b.msg_list);b.large_id=b.msg_list[0].id}}else{}});b.checklock=false};return b})(cex);cex.fb=(function(a){var b={};b.connected=0;b.appid=0;b.data={};b.required_perms=["email","publish_stream"];b.grant_perms=[];b.init=function(c){window.fbAsyncInit=function(){FB.init({appId:c,status:true,cookie:true,xfbml:true});b.appid=c;FB.getLoginStatus(function(d){if(d.session){b.get_info(function(e){b.uid=e.id;ajax_call("/user/update_fb_info",{d:a.util.json_encoder(e)});b.check_permission()})}})};(function(){var d=document.createElement("script");d.type="text/javascript";d.src=document.location.protocol+"//connect.facebook.net/en_US/all.js";d.async=true;document.getElementById("fb-root").appendChild(d)}())};b.login=function(c){FB.ui({method:"oauth",client_id:b.appid,scope:b.required_perms.join(","),display:"popup",redirect_uri:config.fb_redirect_url},function(d){if(c!==undefined){c(d)}})};b.check_permission=function(d){var c=FB.Data.query("select uid,"+b.required_perms.join(",")+" FROM permissions WHERE uid=={0}",b.uid);c.wait(function(g){var f=g[0];b.grant_perms=[];for(var e in b.required_perms){if(parseInt(f[b.required_perms[e]])){b.grant_perms.push(b.required_perms[e])}}if(d!==undefined){d()}})};b.get_info=function(c){FB.api("/me",function(d){b.data=d;if(!d.error){c(d)}})};b.has_permission=function(c){return($.inArray(c,b.grant_perms)>-1)};return b})(cex);cex.fb.feed=(function(a){var b={};b.publish=function(c){FB.api("me/feed","post",b.template,function(){a.ajax_log(cex_event.VIRAL_SENT,{foreign_id:"publish a feed story",data:b.name},function(){if(c!==undefined){c()}})})};b.popup=function(d,e){var c=$.tmpl("tmpl_send_feed",d);a.popup.insert({caption:d.name,content:c,buttons:{Cancel:{style:"blue",value:"Cancel",func:function(f){a.popup.close();if(e!==undefined){e()}}},Share:{style:"blue",value:"Send",func:function(g){var f=$(this);f.html("Sharing&nbsp;&nbsp;&nbsp;").addClass("disable");b.publish(function(h){a.popup.close();if(e!==undefined){e()}})}}},style:{width:"400px"}})};b.get=function(c,d,e){ajax_call("/feed/get_feed",{name:c,params:a.util.json_encoder(d)},function(f){if(!f.rc){b.name=c;b.template=f.tmpl}if(e!==undefined){e(f)}})};return b})(cex);cex.fb.feed.first_group=(function(a){var b={};b.init=function(c){if(a.fb.has_permission("publish_stream")){a.fb.feed.get("newgroup",{name:a.user.name},function(d){a.fb.feed.publish(c)})}else{if(c!==undefined){c()}}};return b})(cex);cex.new_group=(function(a){var b={};b.index=1;b.lock=false;b.init=function(){a.bg_resize($("#create-bg"),1.4);$(window).resize(function(){a.bg_resize($("#create-bg"),1.4)});b.page_count=$(".add-member-item").length;a.user.get(function(){if(!a.user.group_number){a.group.create_tmp(function(c){if(!c.rc){$("#group-number").text(a.group.number);$("#group-name").cexplaceholder()}else{a.popup.insert({caption:"Sorry! Create group fail",content:"Sorry, create group fail. Please go to home page and try again, or contact with us, try later.",buttons:{gohome:{style:"blue",value:"Go to home page",func:a.go_to_home}},style:{width:"400px"}})}});$(".add-member-list input").cexplaceholder();$("body").delegate(".add-more","click",b.get_more);$("body").delegate(".add-member-nav #pre","click",b.show_pre);$("body").delegate(".add-member-nav #next","click",b.show_next);$("#create_button_start").live("click",b.update)}else{a.go_to_home()}})};b.show_next=function(){if(b.lock){return}b.lock=true;if(b.index<b.page_count){b.index+=1;$(".add-member-item").eq(b.index-2).hide("slide",{direction:"left"},200);$(".add-member-item").eq(b.index-1).show("slide",{direction:"right"},200,function(){$(this).find("input").cexplaceholder();b.lock=false});b.set_button()}b.lock=false};b.set_button=function(){if(b.index>=b.page_count){$("#next").addClass("black-link");$("#pre").removeClass("black-link")}else{if(b.index<=1){$("#next").removeClass("black-link");$("#pre").addClass("black-link")}else{$("#pre").removeClass("black-link");$("#next").removeClass("black-link")}}};b.show_pre=function(){if(b.lock){return}b.lock=true;if(b.index>1){b.index-=1;$(".add-member-item").eq(b.index).hide("slide",{direction:"right"},200);$(".add-member-item").eq(b.index-1).show("slide",{direction:"left"},200,function(){$(this).find("input").cexplaceholder()});b.set_button()}b.lock=false};b.get_more=function(){$(".add-more-members").hide();$(".add-member-nav").show();b.show_next()};b.update=function(){var c=b.get_value();var e=0;for(var d in c.member){if(c.member.hasOwnProperty(d)){e++}}a.fb.feed.first_group.init();a.ajax_log(cex_event.BUTTON_CLICK,{foreign_id:"group creation page start chatting",data:e});a.pin_verify.init(function(){$("#create_button_start").die().addClass("disable").html("Starting...");a.group.update(c,b.callback)},function(){})};b.callback=function(c){a.go_to_home()};b.get_value=function(e){var c={};var d={};$(".add-member-entry").each(function(){var f=$(this).children(".member-name").getval()||"";var g=a.phonenumber.to_digital($(this).children(".member-number").getval())||"";if(g.length){d[g]=f}});c={member:d};c.name=$("#group-name").getval();c.create_msg=1;return c};return b})(cex);cex.group.manager=(function(a){var b={};b.init=function(){$("#leave").die().live("click",b.leave);$("#side-column").delegate(".others","mouseenter",function(){if(a.group.own){var d=$(this).attr("token");var c=$(this).find(".member-name").text();$(this).append(' 						<div class="member-delete"> 							<div id="btn_delete_member" class="delete"></div> 						</div>');$("#btn_delete_member").die().live("click",function(){var e=$.tmpl("tmpl_delete_member_popup",{name:c});a.popup.append({caption:"Remove Member",content:e,buttons:{Confirm:{style:"light-grey",value:"Confirm",func:function(){b.update({remove:d},function(f){a.popup.close()})}},Cancel:{style:"blue",value:"Cancel",func:a.popup.close}},style:{width:"400px"}})})}});$("#side-column").delegate(".others","mouseleave",function(){$(this).find(".member-delete").remove()});$("#btn-change-nick-name").die().live("click",function(){$("#change-nick-name").slideDown();$("#change_nick_name").val($(".member .ower .member-name").text()).enter(function(){$("#btn-change-nick-name-confirm").trigger("click")}).remove_error().focus();$("#btn-change-nick-name-confirm").removeClass("black-link").html("save").die().live("click",b.do_change_nick_name);$("#btn-change-nick-name-cancel").die().live("click",b.close_change_nick_name)});$("#btn_add_member").toggle(b.show_add_member,b.hide_add_member);$("#btn-change-group-name").click(b.show_change_group_name)};b.update=function(d,c){a.group.update(d,function(e){if(!e.rc){b.refresh_info()}if(c!==undefined){c(e)}})};b.refresh_info=function(){if(a.group.g.muted){$("#mute").hide();$("#unmute").show();$("#unmute").die().live("click",b.unmute);$("#unmute").html("unmute");$("#unmute").removeClass("black-link")}else{$("#mute").show();$("#mute").die().live("click",b.mute);$("#mute").html("mute");$("#mute").removeClass("black-link");$("#unmute").hide()}if(a.group.g.announcement_mode){$("#state-announce").html("on").show()}else{$("#state-announce").html("off").show()}if(a.group.g.own){$("#action-announce-toggle").html("toggle").removeClass("black-link").die().live("click",b.toggleAnnouncement).show()}$("#side-column .group-name").text(a.group.name);$("#side-column .group-number").text(a.group.number);$("#member").empty();for(var c=0;c<a.group.members.length;c++){var d=$.tmpl("tmpl_member_item",a.group.members[c]);if(a.group.members[c].is_self){d.prependTo("#member")}else{d.appendTo("#member")}}a.group.nav.update_group_name(a.group.gid_token,a.group.g.n)};b.show_change_group_name=function(){$("#btn-change-group-name-confirm").html("save");$("#group-info .normal").slideUp();$("#group-info .change").slideDown();$("#change-group-name").remove_error().removeClass("error-input").val($(".group-name").text()).focus().enter(function(){$("#btn-change-group-name-confirm").trigger("click")});$("#btn-change-group-name-confirm").removeClass("black-link").die().live("click",b.do_change_group_name);$("#btn-change-group-name-cancel").die().live("click",b.hide_change_group_name);if($("#add-member").is(":visible")){$("#btn_add_member").click()}};b.hide_change_group_name=function(){$("#group-info .normal").slideDown();$("#group-info .change").slideUp();if($("#add-member").is(":visible")){$("#btn_add_member").click()}};b.do_change_group_name=function(){$("#change-group-name").remove_error().removeClass("error-input");if($("#change-group-name").getval()===$(".group-name").text()){$("#change-group-name").add_error("Use a different name").addClass("error-input");return}else{if($("#change-group-name").getval().length>16){$("#change-group-name").add_error("Too long!").addClass("error-input");return}else{if($("#change-group-name").getval()===""){$("#change-group-name").add_error("Enter a group name").addClass("error-input");return}else{if(!a.util.is_valid_name($("#change-group-name").getval())){$("#change-group-name").add_error("Invalid character!").addClass("error-input");return}}}}$("#btn-change-group-name-confirm").die().html("saving...").addClass("black-link");if($("#change-group-name").getval()!==""){$("#change-group-name").loading();$("#btn-change-group-name-confirm").die();b.update({name:$("#change-group-name").getval()},function(c){if(!c.rc){b.hide_change_group_name()}$("#change-group-name").unloading();$("#btn-change-group-name-confirm").html("save").removeClass("black-link").die().live("click",b.do_change_group_name);$("#change-group-name").remove_error().removeClass("error-input")})}};b.do_change_nick_name=function(){$("#change_nick_name").remove_error();var c=$("#change_nick_name").getval();if(c===""){$("#change_nick_name").add_error("Please enter the nick name");return}else{if(c.length>16){$("#change_nick_name").add_error("Too long!");return}else{if(!a.util.is_valid_name(c)){$("#change_nick_name").add_error("Invalid character");return}}}if(c===$(".member .ower .member-name").text()){$("#change_nick_name").add_error("Please enter another name");return}$("#btn-change-nick-name-confirm").die().addClass("black-link").html("saving...");b.update({nickname:c},function(d){if(!d.rc){b.close_change_nick_name()}else{$("#change_nick_name").add_error(d.error)}$("#btn-change-nick-name-confirm").removeClass("black-link").html("save").die().live("click",b.do_change_nick_name)})};b.close_change_nick_name=function(){$("#change-nick-name").slideUp()};b.show_add_member=function(){$("#add-member").slideDown("fast",function(){$("#add-member-name").val("").cexplaceholder().focus();$("#add-member-number").val("").cexplaceholder();$("#add-member-error").html("");$("#add-member-number").enter(function(){$("#btn_add_member_confirm").eq(0).trigger("click")});$("#add-member-name").enter(function(){$("#btn_add_member_confirm").eq(0).trigger("click")});$("#btn_add_member_confirm").html("add").removeClass("black-link").die().live("click",b.do_add_member);$("#btn_add_member_cancel").die().live("click",function(){$("#btn_add_member").click()})})};b.hide_add_member=function(){$("#add-member").slideUp()};b.do_add_member=function(){var e=$("#add-member-number").getval();var c=$("#add-member-name").getval();$("#add-member-error").html("");if(c===""){$("#add-member-error").html("Please fill the name")}else{if(c.length>16){$("#add-member-error").html("Please use a short name")}else{if(!a.util.is_valid_name(c)){$("#add-member-error").html("Invalid name")}else{if(e===""){$("#add-member-error").html("Please fill the number")}else{if(a.phonenumber.to_digital(e).length!==10){$("#add-member-error").html("Please fill valid number")}else{if($("#btn_add_member_confirm").hasClass("black-link")){return}$("#add-member-number").loading();$("#add-member-name").loading();$("#btn_add_member_confirm").die().addClass("black-link").html("adding...");var d={};d[e]=c;b.update({member:d},function(f){if(!f.rc){$("#add-member-number").val("").focus();$("#add-member-name").val("").focus()}else{$("#add-member-error").html(f.error)}$("#add-member-number").unloading();$("#add-member-name").unloading();$("#btn_add_member_confirm").removeClass("black-link").html("add").die().live("click",b.do_add_member)})}}}}}};b.mute=function(){$("#mute").die().html("muting...").addClass("black-link");b.update({mute:1})};b.unmute=function(){$("#unmute").die().html("unmuting...").addClass("black-link");b.update({unmute:1})};b.toggleAnnouncement=function(){$("#action-announce-toggle").die().html("toggling...").addClass("black-link");b.update({announcement:1})};b.leave=function(){var d="leave";op_cap="Leave";if(a.group.own){d="delete";op_cap="Delete"}var c=$.tmpl("tmpl_leave_popup",{actionname:d,gname:a.group.name});a.popup.append({caption:op_cap+" group",content:c,buttons:{Confirm:{style:"light-grey",value:"Confirm",func:function(){b.update({leave:1},function(e){a.go_to_home()});a.popup.close()}},Cancel:{style:"blue",value:"Cancel",func:a.popup.close}},style:{width:"400px"}})};b.show_detail=function(){$("#group-info .normal").show();$("#group-info .change").hide();if(a.group.own){$("#leave").html("delete group")}else{$("#leave").html("leave group")}b.refresh_info();b.close_change_nick_name();b.hide_add_member();b.show()};b.show=function(){$("#side-column").show("slide",{direction:"left"},500)};b.hide=function(){if($("#side-column").is(":visible")){$("#side-column").hide("slide",{direction:"left"},500)}};return b})(cex);cex.group.nav=(function(a){var b={};b.init=function(c){$("#left-nav .nav-style ul").delegate("li","click",b.select_group);b.select_group_callback=c};b.reload=function(){$("#left-nav .nav-style ul").empty();if(a.group.group_list.length){$("#no_group").hide();$.tmpl("tmpl_group_nav_item",a.group.group_list).appendTo("#left-nav .nav-style ul")}else{$("#no_group").show();$("#messages").hide()}};b.select=function(d){if(d==undefined){$("#left-nav .nav-style ul li").eq(0).trigger("click")}else{for(var c=0;c<a.group.group_list.length;c++){var e=a.group.group_list[c];if(e.gid_token===d){$("#left-nav .nav-style ul li").eq(c).trigger("click");return}}$("#left-nav .nav-style ul li").eq(0).trigger("click")}};b.select_group=function(c){b.clear_nav_selection();$(this).children("a").addClass("selected");a.group.switch_group($(this).attr("gid_token"));b.select_group_callback();a.group.manager.show_detail()};b.clear_nav_selection=function(){$("#left-nav .selected").each(function(){$(this).removeClass("selected")})};b.update_group_name=function(d,c){$("#left-nav .nav-style ul li").each(function(){if($(this).attr("gid_token")===d){$(this).find(".subitem").text(c)}})};return b})(cex);cex.home=(function(a){var b={};b.older_msg_checker_timer;b.page="";b.msg_box_origin_height=0;b.init=function(){b.page=parseUrl(window.location.href)["params"]["p"];a.group.manager.init();a.user.get(function(){$("#user-number").text(a.phonenumber.to_number(a.user.number));$(".detail-info .name").text(a.user.name);$(".owner-info img").attr("src",a.user.img);if(a.user.is_temp){a.pin_verify.init(function(){a.page_reload()},function(){a.logout()})}else{b.start()}})};b.start=function(){a.group.nav.init(b.select_group_callback);$("#btn_new_group").live("click",b.toggleNewGroup);$("#btn_new_group_cancel").live("click",b.toggleNewGroup);$(".link_new_group").live("click",b.toggleNewGroup);$("#msg-composer").val("").bind("keyup",b.compose).cexplaceholder();if($.browser.msie){b.msg_box_origin_height=$("#msg-composer").height()}else{b.msg_box_origin_height=$("#msg-composer").get(0).offsetHeight}b.msg_box_origin_scroll_height=$("#msg-composer").get(0).scrollHeight;$("#msg-send").click(b.send_message);$(window).scroll(b.onChange);$(window).resize(b.onChange);b.reload()};b.reload=function(c){a.group.all(function(){a.msg.stop_check();a.group.nav.reload();$("#usersettings").removeClass("black-link");$("#usersettings").die().live("click",b.set_user);if(b.page==="setting"){b.page="";$("#usersettings").eq(0).trigger("click")}else{a.group.nav.select(c)}})};b.select_group_callback=function(){$("#user-settings").hide();$("#usersettings").removeClass("black-link");$("#usersettings").die().live("click",b.set_user);$("#messages").show();$(".message-list").empty();$("#message-loading").show();a.msg.get(b.msg_get_callback)};b.toggleNewGroup=function(){if($("#add-group").is(":visible")){$("#add-group input").prev().hide();$("#add-group").slideUp()}else{$("#add-group").slideDown();$("#add-group input").cexplaceholder().val("").remove_error().focus().unloading().enter(function(){$("#btn_new_group_create").eq(0).trigger("click")});$("#btn_new_group_create").die().live("click",b.doNewGroup)}};b.doNewGroup=function(){$("#add-group input").remove_error();if($("#add-group input").getval()===""){$("#add-group input").add_error("Please enter the group name");return}else{if($("#add-group input").getval().length>16){$("#add-group input").add_error("Please enter a short name");return}else{if(!a.util.is_valid_name($("#add-group input").getval())){$("#add-group input").add_error("Invalid character");return}else{$("#btn_new_group_create").die();$("#btn_new_group_create").html("creating...").addClass("black-link");$("#add-group input").loading().empty();a.group.create($("#add-group input").getval(),function(c){if(!c.rc){b.toggleNewGroup();b.reload()}else{$("#add-group input").add_error(c.error)}$("#add-group input").unloading();$("#btn_new_group_create").removeClass("black-link").html("create")})}}}};b.onChange=function(){var d=$(window).height();var c=$(window).scrollTop();var e=$("#left-column").height();if(d<e){$("#left-column").addClass("left-column-short");if(d+c<=e){$("#left-column").css({top:0})}else{$("#left-column").css({top:c+d-e})}}else{$("#left-column").css({top:0});$("#left-column").removeClass("left-column-short")}};b.msg_get_callback=function(d){if(a.group.gid_token==d.gid_token){$(".message-list").empty();for(var c in a.msg.msg_list){b.add_old_message(a.msg.msg_list[c])}$(window).scrollTop($(document).height());a.msg.start_check(b.msg_check_callback);if(b.older_msg_checker_timer!==undefined){clearInterval(b.older_msg_checker_timer)}b.older_msg_checker_timer=setInterval("cex.home.older_msg_check()",2000)}};b.older_msg_check=function(){if($(window).scrollTop()<($("#messages").height()*0.1)){if(a.msg.small_id===""){clearInterval(b.older_msg_checker_timer);$("#message-loading").slideUp()}else{$("#message-loading").show();a.msg.get_older(function(d){if(!d.rc){$("#message-loading").slideUp();if(a.group.gid_token==d.gid_token){for(var c in d.m){b.add_old_message(d.m[c])}}if(d.m.length===0){clearInterval(b.older_msg_checker_timer)}}})}}};b.msg_check_callback=function(c){for(var d in c){b.add_new_message(c[c.length-d-1])}};b.add_new_message=function(c){$.tmpl("tmpl_message_item",c).appendTo(".message-list");b.onChange();$(window).scrollTop($(document).height())};b.add_old_message=function(c){$.tmpl("tmpl_message_item",c).prependTo(".message-list");b.onChange()};b.compose=function(f){var c=(f.keyCode?f.keyCode:f.which);if(c==13){b.send_message(f)}else{if($(this).val().length>a.msg.MAX_MSG_LENGTH){$(this).val($(this).val().slice(0,a.msg.MAX_MSG_LENGTH))}$("#msg-left-char").text(a.msg.MAX_MSG_LENGTH-$(this).val().length);var d=this.scrollHeight-b.msg_box_origin_scroll_height;if(d>0){$(this).css({height:b.msg_box_origin_height+d})}else{$(this).css({height:b.msg_box_origin_height})}}};b.send_message=function(c){if($("#msg-send").hasClass("disable")){return}if(!$("#msg-composer").getval()){return}$("#msg-send").addClass("disable");$("#msg-composer").attr({disabled:"disabled"});a.msg.post($("#msg-composer").getval());$("#msg-left-char").text(a.msg.MAX_MSG_LENGTH);$("#msg-composer").val("").css({height:b.msg_box_origin_height}).removeAttr("disabled").blur();$("#msg-send").removeClass("disable");$("#msg-composer").focus()};b.set_user=function(){a.group.nav.clear_nav_selection();$("#usersettings").die();$("#usersettings").addClass("black-link");$("#user-settings").show();$("#messages").hide();$("#no_group").hide();a.group.manager.hide();a.usersetting.init()};return b})(cex);cex.usersetting=(function(a){var b={};b.fname="";b.lname="";b.number="";b.email="";b.img="";b.img_uploaded="";b.config={fname:{obj:"#fn_settings",name:"First name"},lname:{obj:"#ln_settings",name:"Last name"},email:{obj:"#email_settings",name:"Email"},opwd:{obj:"#setting_old_pwd",name:"Old password"},npwd:{obj:"#setting_new_pwd",name:"New password"}};b.init=function(){b.img=a.user.img;$("#email_settings").val(a.user.email).focus();$("#ln_settings").val(a.user.lname).focus();$("#fn_settings").val(a.user.fname).focus();$("#setting-user-pic img").attr({src:b.img});$("#timezone_settings").empty();$.tmpl("tmpl_timezone_option",a.tz.values).appendTo("#timezone_settings");$("#timezone_settings").val(a.user.tz);$("#btn_save_setting").die().live("click",b.update);$("#btn_del_account").die().live("click",b.delAccount)};b.get_img=function(){var d=/(mugshot_url=[^&#]*)/g;var c=$("#memb_photo_uploader").get(0).src.match(d);if(c!==null){var e=c[0].split("=");return unescape(e[1])}else{return b.img}};b.error_input=function(d,e){d=$(d);$(".setting-field input").each(function(){$(this).removeClass("error-input")});$(".setting-field .setting-error").remove();d.addClass("error-input");var c=' 			<div class="setting-error"> 				'+e+" 			</div>";d.parent().append(c)};b.update=function(){var f=$("#fn_settings").getval();var g=$("#ln_settings").getval();var e=$("#email_settings").getval();var c=$("#setting_old_pwd").getval();var h=$("#setting_new_pwd").getval();if((f==="")!==(g==="")){if(f===""){b.error_input(b.config.fname.obj,"Empty first name")}else{b.error_input(b.config.lname.obj,"Empty last name")}}else{if(!a.util.is_valid_name(f)){b.error_input(b.config.fname.obj,"Invalid character")}else{if(f.length>16){b.error_input(b.config.fname.obj,"Too long")}else{if(!a.util.is_valid_name(g)){b.error_input(b.config.lname.obj,"Invalid character")}else{if(g.length>16){b.error_input(b.config.lname.obj,"Too long")}else{if(!a.util.is_valid_email(e)&&e){b.error_input(b.config.email.obj,"Invalid email address")}else{if(e.length>32){b.error_input(b.config.email.obj,"Too long")}else{if((c!=="")!==(h!=="")){b.error_input(b.config.opwd.obj,"You must provide your both old password and new password")}else{var i={};i.name={first_name:f,last_name:g};if(e!==""&&e!==a.user.email){i.email=e}if(c!==""){i.password={oldp:c,newp:h}}var d=b.get_img();if((b.img!==b.img_uploaded)&&(b.img_uploaded!=="")){i.img=b.img_uploaded}i.tz=$("#timezone_settings").val();$("#btn_save_setting").die().addClass("disable").html("Saving...");a.user.update({d:a.util.json_encoder(encode_object(i))},function(j){if(!j.rc){a.go_to_home()}else{b.error_input(b.config[j.target].obj,j.error);$("#btn_save_setting").die().live("click",b.update);$("#btn_save_setting").removeClass("disable");$("#btn_save_setting").html("Save Changes")}})}}}}}}}}};b.delAccount=function(){var c=$.tmpl("tmpl_del_account",{own_group:a.group.getCreatedGroupAmount()});var d=$.tmpl("tmpl_del_account_bottom",{});a.popup.insert({caption:"Deactivate your account?",content:c,buttons:{Delete:{style:"light-grey",value:"Delete",func:b.doDelAccount},Close:{style:"blue",value:"Cancel",func:a.popup.close}},button_desc:d,style:{width:"535px"}})};b.doDelAccount=function(){if(a.popup.get_button("Delete").hasClass("disable")){return}a.popup.get_button("Delete").addClass("disable");var c=$("#del-account-opt-out").attr("checked");a.user.deleteUser(c,function(d){a.popup.close();if(!d.rc){a.logout()}else{a.popup.insert({caption:"Error",content:"Fail to delete your account, please try again or contact help.",buttons:{OK:{style:"blue",value:"OK",func:a.popup.close}},style:{width:"400px"}})}})};return b})(cex);cex.pin_verify=(function(a){var b={};b.resend_times=0;b.pno="";b.init=function(d,c){b.callback=d;b.cancel_callback=c;a.user.get(function(){if(!a.user.is_temp){b.callback();return}b.pno=a.user.number;$("#btn_resend_pwd").live("click",b.resend_pwd);$("body").delegate("#btn_reset_no","click",function(){var f=parseUrl(window.location.href)["params"];var h=f.fname;var e=f.lname;var g={};if(h&&e&&h!==undefined&&e!==undefined){g={fname:h,lname:e}}a.go_to_login(g)});b.show_enter_pin();if(!a.user.has_password&&b.resend_times==0){b.resend_pwd()}})};b.resend_pwd=function(d){var c=$(this);c.die().addClass("black-link").html("Sending...");a.user.get_new_password(b.pno,function(e){c.removeClass("black-link").live("click",b.resend_pwd).html("<b>Resend</b>");if(a.user.has_password||b.resend_times){$("#pwd_resent_success").show()}b.resend_times+=1})};b.reset_pwd=function(d,e){var c=$.tmpl("tmpl_change_pwd_popup",{});a.popup.append({caption:"Almost there! Create a password",content:c,buttons:{Cancel:{style:"light-grey",value:"Cancel",func:function(){a.popup.close();if(b.cancel_callback){b.cancel_callback()}}},Change:{style:"blue",value:"Done!",func:function(){if(a.popup.get_button("Change").hasClass("disable")){return}if($("#popup_new_pwd_2").val()!=$("#popup_new_pwd_1").val()){$("#popup_change_pwd_msg").html("The two passwords do not match. Please try again!");return}var f={};a.popup.get_button("Change").addClass("disable");f.password={oldp:d,newp:$("#popup_new_pwd_2").val()};a.user.update({d:a.util.json_encoder(encode_object(f))},function(g){a.popup.get_button("Change").removeClass("disable");if(!g.rc){a.popup.close();if(e!==undefined){e()}}else{$("#popup_change_pwd_msg").html(g.error)}})}}},style:{width:"400px"}})};b.verify_pin=function(f){var d=$("#pin").getval();var c=a.popup.get_button_id("Verify");$("#"+c).die().addClass("disable").html("Verifing...");$("#popup_verify_msg").html("");a.user.validate(b.pno,d,function(e){if(!e.rc){a.popup.close();if(!e.has_password){b.reset_pwd(d,b.callback)}else{b.callback(e)}}else{$("#popup_verify_msg").html("The password is incorrect. Please try again!");$("#"+c).die().live("click",b.verify_pin).html("Verify").removeClass("disable")}})};b.show_enter_pin=function(){var d=$.tmpl("tmpl_verify_popup",{number:a.phonenumber.to_number(b.pno),has_password:a.user.has_password});if(a.user.has_password){var c="Already have an account!"}else{var c="Verify your number"}a.popup.append({caption:c,content:d,buttons:{Cancel:{style:"light-grey",value:"Cancel",func:function(){a.popup.close();if(b.cancel_callback){b.cancel_callback()}}},Verify:{style:"blue",value:"Verify",func:function(){b.verify_pin()}}},style:{width:"400px"}})};return b})(cex);cex.help=(function(a){var b={};b.config=[{name:"faq",div_id:"faq-service"},{name:"commands",div_id:"command-service"},{name:"support",div_id:"contact-service"},{name:"privacy",div_id:"privacy-service"},{name:"terms",div_id:"terms-service"}];b.init=function(){$("#btn_send_email").die().live("click",b.send_email)};b.select_service=function(f){$("#left-nav .selected").each(function(){$(this).removeClass("selected")});$(this).addClass("selected");var c=$("#left-nav .nav-style ul a").index($(this));for(var d in b.config){if(d==c){$("#"+b.config[d].div_id).show()}else{$("#"+b.config[d].div_id).hide()}}};b.send_email=function(){var d=$("#ct_name").getval();var c=$("#ct_email").getval();var e=$("#ct_subject").getval();var f=$("#ct_content").getval();if(!(d&&c&&e&&f&&a.util.is_valid_email(c))){a.popup.insert({caption:"Warning",content:"Please fill in all fields correctly and send again!",buttons:{Close:{style:"blue",value:"Close",func:a.popup.close}},style:{width:"400px"}});return}$("#btn_send_email").html("Sending...").die().addClass("disable");ajax_call("/help/support_request",{name:d,email:c,subject:e,message:f},function(g){$("#btn_send_email").html("Send").live("click",b.send_email).removeClass("disable");if(!g.rc){$("#ct_name").val("");$("#ct_email").val("");$("#ct_subject").val("");$("#ct_content").val("");a.popup.insert({caption:"Success",content:"Email sent successfully!",buttons:{Close:{style:"blue",value:"Close",func:a.popup.close}},style:{width:"400px"}})}})};return b})(cex);cex.pager=(function(a){var b={};b.get_url=function(d){var c=a.domain;if(d){c+="/"+d}return c};b.get_page_id=function(c){if(!c){return 0}for(var d in a.site_map){if(c.search(b.get_url(a.site_map[d][0]))!==-1){return a.site_map[d][1]}}return 0};b.log_page_view=function(){a.ajax_log(cex_event.PAGE_VIEW,{prev_pid:b.get_page_id(document.referrer),pid:b.get_page_id(window.location.href)})};b.get_token=function(){var d=parseUrl(window.location.href)["params"]["t"];if(!d||d==undefined){var c=parseUrl(window.location.href)["params"]["origin_url"];d=parseUrl(unescape(unescape(c)))["params"]["t"]}if(d){a.token.init(d)}};b.init=function(){b.get_token();b.log_page_view()};return b})(cex);cex.token=(function(a){var b={};b.code="";b.params={};b.handler={email:function(c){a.ajax_log(cex_event.EMAIL_CLICK,{email_name:c.name})},feed:function(c){a.ajax_log(cex_event.VIRAL_CLICK,{foreign_id:"click a feed story",data:c.name})}};b.decode=function(c,d){ajax_call("/logger/decode",{data:c},function(e){if(!e.rc){b.code=e.data[0];b.params=e.data[1];d(e)}})};b.init=function(c){b.decode(c,function(){if(b.code){b.handler[b.code](b.params)}})};return b})(cex);cex.bg_resize=function(b,g){var d=$(window).width();var a=$(window).height();var f=0;var e=0;if((d/a)>g){var c=d/g;f=(a-c)/2;a=c}else{var c=a*g;e=(d-c)/2;d=c}b.css({top:f,left:e,height:a,width:d})};cex.newLanding=(function(a){var b={};b.bg_default_ratio=1.4;b.fbConnected=0;b.resize=function(){var e=$(window).width();var c=$(window).height();var g=0;var f=0;if((e/c)>b.bg_default_ratio){var d=e/b.bg_default_ratio;g=(c-d)/2;c=d}else{var d=c*b.bg_default_ratio;f=(e-d)/2;e=d}$("#landing-bg").css({top:g,left:f,height:c,width:e})};b.init=function(){$(".slide-box").cycle({fx:"scrollHorz",containerResize:0,easing:"easeOutQuart",speed:800,timeout:7000,cssAfter:"slide-after",cssBefore:"slide-before",pager:".slide-bar",pagerAnchorBuilder:function(f,e){return'<a class="slide-dot">Large Groups</a>'}});a.signin.init();a.bg_resize($("#landing-bg"),b.bg_default_ratio);$(window).resize(function(){a.bg_resize($("#landing-bg"),b.bg_default_ratio)});$("#btn_start_group").live("click",b.clickSignUp);$("#number").val("").focus().cexplaceholder().enter(b.clickSignUp);var d=parseUrl(window.location.href)["params"];var c="";if(d.fname!=undefined&&d.fname!=""){c+=d.fname}if(d.lname!=undefined&&d.lname!=""){if(c!=""){c+=" "}c+=d.lname}$("#fullname").val(c).cexplaceholder().focus()};b.clickSignUp=function(){$("#fullname").removeClass("error-input");$("#number").removeClass("error-input");$("#fullname-error").hide();$("#number-error").hide();a.ajax_log(cex_event.BUTTON_CLICK,{foreign_id:"sign up page create button",data:b.fbConnected});var d=$("#fullname").getval();var c=$("#number").getval();var e=false;if(d==""){$("#fullname").addClass("error-input");$("#fullname-error").html("Full name is required").show();e=true}else{if(!a.util.is_valid_name(d)){$("#fullname").addClass("error-input");$("#fullname-error").html("English character only").show();e=true}}if(c==""){$("#number").addClass("error-input");$("#number-error").html("Mobile number is required").show();e=true}else{if(!(a.phonenumber.to_digital(c).length===10)){$("#number").addClass("error-input");$("#number-error").html("Mobile number is invalid").show();e=true}}if(e){a.ajax_log(cex_event.SIGN_UP_ERROR,{data:b.fbConnected})}else{var f=d.indexOf(" ");if(f==-1){f=d.length}fname=d.slice(0,f);lname=d.slice(f+1);b.values={fname:fname,lname:lname,phone:c};b.signUpSubmit()}};b.signUpSubmit=function(){$("#btn_start_group").die().addClass("disable");a.user.create(b.values,function(c){if(!c.rc){if(c.exist){a.redirect(c.redirect+"?fname="+Url.encode(b.values.fname)+"						&lname="+Url.encode(b.values.lname))}else{$(".signin-box").hide();$("#landing-main-content").slideUp();a.newAddMember.init()}}else{$("#btn_start_group").live("click",b.submit).removeClass("disable");a.ajax_log(cex_event.SIGN_UP_ERROR,{data:b.fbConnected})}})};return b})(cex);cex.newAddMember=(function(a){var b={};b.init=function(){$("#addmember-main-content").height(404).slideDown();$("#create_button_start").live("click",b.clickCreate);$("#group-name").cexplaceholder().val("").focus();$("#addmember-list input").cexplaceholder();$("#btn-addmore").live("click",b.addMore);$("#addmember-back").live("click",b.showBack);$("#addmember-next").live("click",b.showNext);var c=0;for(var d in a.site_map){if(a.site_map[d][0]=="group/new"){c=a.site_map[d][1]}}a.ajax_log(cex_event.PAGE_VIEW,{prev_pid:a.pager.get_page_id(window.location.href),pid:c})};b.clickCreate=function(){var c=b.getGroupValue();a.ajax_log(cex_event.BUTTON_CLICK,{foreign_id:"group creation page start chatting",data:c.member.length});a.pin_verify.init(function(){$("#create_button_start").die().addClass("disable").html("Starting...");a.group.createWithMember(a.util.json_encoder(c),b.afterCreation)},function(){})};b.afterCreation=function(){a.go_to_home()};b.getGroupValue=function(){var d={};var c=[];$(".addmember-entry").each(function(){var e=$(this).children(".addmember-member-name").getval()||"";var f=a.phonenumber.to_digital($(this).children(".addmember-member-number").getval())||"";if(f.length){c.push({name:e,phone_no:f})}});d={member:c};d.name=$("#group-name").getval();return d};b.setButtons=function(d,c,e){if($(".addmember-entry").length>=99){$("#btn-addmore").hide()}if(c>0){$("#addmember-back").show()}else{$("#addmember-back").hide()}if($(e).next().length>0){$("#addmember-next").show()}else{$("#addmember-next").hide()}};b.addMore=function(){if($(".addmember-entry").length<99){$("#btn-addmore").die();var c=$.tmpl("tmpl_add_more_member",{start_index:$(".addmember-entry").length+1}).appendTo($("#addmember-list"));c.find("input").cexplaceholder();b.restartCycle()}$("#btn-addmore").live("click",b.addMore)};b.restartCycle=function(){$("#addmember-list").cycle({fx:"scrollHorz",containerResize:0,timeout:0,onPrevNextEvent:b.setButtons});var d=$(".addmember-entries").length;for(var c=0;c<d-1;c++){b.showNext()}};b.showNext=function(){if($(".addmember-entry:visible").next().length>0){$("#addmember-list").cycle("next")}};b.showBack=function(){if($(".addmember-entry:visible").prev().length>0){$("#addmember-list").cycle("prev")}};return b})(cex);cex.landing=(function(){var a={};a.bg_default_ratio=1.4;a.resize=function(){var d=$(window).width();var b=$(window).height();var f=0;var e=0;if((d/b)>a.bg_default_ratio){var c=d/a.bg_default_ratio;f=(b-c)/2;b=c}else{var c=b*a.bg_default_ratio;e=(d-c)/2;d=c}$("#landing-bg").css({top:f,left:e,height:b,width:d})};a.init=function(){cex.signin.init();cex.signup.init();cex.bg_resize($("#landing-bg"),a.bg_default_ratio);$(window).resize(function(){cex.bg_resize($("#landing-bg"),a.bg_default_ratio)})};return a})(cex);cex.forum={};cex.forum.topic_creation=(function(a){var b={};b.init=function(){$("#btn_create_topic_submit").click(b.submit);b.base_url="/forum/"+$("#forum").val()+"/";$("#subject").cexplaceholder();$("#message").cexplaceholder({style:{height:"40px","line-height":"40px"}})};b.submit=function(){if($("#btn_create_topic_submit").hasClass("disable")){return}if(!$("#subject").getval()){$("#forum-create-error").html("Please enter the subject.")}else{if(!$("#message").getval()){$("#forum-create-error").html("Please enter the message.")}else{$("#forum-create-error").html("");$("#btn_create_topic_submit").addClass("disable");var c={subject:$("#subject").val(),message:$("#message").val()};ajax_call(b.base_url+"create_topic",c,function(d){if(!d.rc){a.redirect(d.redirect)}})}}};return b})(cex);cex.forum.topic_reply=(function(a){var b={};b.init=function(){$("#btn_reply_topic_submit").click(b.submit);b.base_url="/forum/"+$("#forum").val()+"/"};b.submit=function(){if($("#btn_reply_topic_submit").hasClass("disable")){return}if(!$("#message").getval()){$("#forum-reply-error").html("Please enter the message.")}else{$("#forum-reply-error").html("");$("#btn_reply_topic_submit").addClass("disable");var c={topic:$("#topic").val(),message:$("#message").val(),p:$("#post").val()};ajax_call(b.base_url+"reply_topic",c,function(d){if(!d.rc){a.redirect(d.redirect)}else{$("#btn_reply_topic_submit").removeClass("disable");$("#forum-reply-error").html(d.error)}})}};return b})(cex);cex.forum.topic_view=(function(a){var b={};b.init=function(){$("#btn_stick_topic").click(b.stick);$("#btn_unstick_topic").click(b.unstick);$("#btn_lock_topic").click(b.lock);$("#btn_unlock_topic").click(b.unlock);$("#btn_del_topic").click(b.delTopic);b.base_url="/forum/"+$("#forum").val()+"/";b.data={topic:$("#topic").val()}};b.stick=function(){ajax_call(b.base_url+"stick_topic",b.data,function(c){if(!c.rc){a.redirect(c.redirect)}})};b.unstick=function(){ajax_call(b.base_url+"unstick_topic",b.data,function(c){if(!c.rc){a.redirect(c.redirect)}})};b.lock=function(){ajax_call(b.base_url+"lock_topic",b.data,function(c){if(!c.rc){a.redirect(c.redirect)}})};b.unlock=function(){ajax_call(b.base_url+"unlock_topic",b.data,function(c){if(!c.rc){a.redirect(c.redirect)}})};b.delTopic=function(){ajax_call(b.base_url+"del_topic",b.data,function(c){if(!c.rc){a.redirect(c.redirect)}})};b.delPost=function(c){b.data.pid_token=c;ajax_call(b.base_url+"del_post",b.data,function(d){if(!d.rc){a.redirect(d.redirect)}})};return b})(cex);cex.template=(function(a){var b={};b.tmpl={tmpl_timezone_option:'<option value="${name}">${name}</option>',tmpl_delete_member_popup:' 			<div>				<div style="border-bottom: 1px solid #D9D9DB;">Are you sure you want to remove the following member?</div> 				<div style="word-break: break-all; margin-top: 10px">Name&nbsp: <b class="name">${name}</b></div> 			</div>',tmpl_member_item:' 			<div token="${token}" class="member-item {{if is_self}}owner{{else}}others{{/if}} clearfix"> 				<img class="member-pic" src="${pic}" /> 				<div class="member-item-right"> 					<span class="member-name">${name}</span> 					{{if is_self}} 						<a id="btn-change-nick-name" class="edit"> <span>edit</span> </a> 					{{else}} 						{{if mute}}<span class="muted">(muted)</span>{{/if}} 					{{/if}} 					<br/> 					{{if phone}} 						<span class="member-number">${phone}</span> 					{{/if}} 				</div> 			</div> 			',tmpl_leave_popup:' 			<div> 				<div style="border-bottom: 1px solid #D9D9DB;">Are you sure you want to ${actionname} the following group?</div> 				<div style="word-break: break-all; margin-top: 10px">Group&nbsp: <b class="name">${gname}</b></div> 			</div>',tmpl_group_nav_item:'<li gid_token="${gid_token}" ><a class="subitem">${n}</a></li>',tmpl_message_item:'			<li class="message-block"> 				<div class="clearfix"> 					<img class="user-pic" src="${pic}"> 					<div class="user-message"> 						<span class="name">${name}</span><br/> 						<span class="body-text">${content}</span><br/> 						<span class="timestamp">${time}</span> 					</div> 				</div> 			</li> 			',tmpl_verify_popup:'			<div id="verifypin"> 				{{if has_password}} 					Looks like you <span class="name">${number}</span> already have an account. <br />Enter your password below to <b>sign in</b>! 				{{else}} 					A temporary password has been sent to your phone <span class="name">${number}</span>. <br />Enter it below to <b>verify your number</b>! 				{{/if}} 			</div> 			<input id="pin" type="password" class="inputtext">  			<div id="popup_verify_msg"  class="error-message"></div> 			<div id="pwd_resent_success" style="display: none">The password has been resent! Please try again!</div> 			<div class="left-links"> 				{{if has_password}} 					Forgot password? <a id="btn_resend_pwd"><b>Send it to my phone</b></a> <br /> 				{{else}} 					Didn\'t receive password? <a id="btn_resend_pwd"><b>Resend it</b></a> <br /> 				{{/if}} 				Wrong phone number? <a id="btn_reset_no"><b>Start over</b></a><br /> 			</div> 			',tmpl_forgot_pwd_popup:'			Enter your phone number below to get the password.<br /> 			<input id="number_forget_password" type="text" class="inputtext inputphone" value="${number}"> 			',tmpl_send_pwd_success:"				We sent a temporary password to ${number}. Please check it on your phone.			",tmpl_send_feed:"			<div>${description}</div>			",tmpl_change_pwd_popup:'			<div> 				Your number is verified. Now create a password for your account and start chatting with friends! 			</div> 			<input id="popup_new_pwd_1" ph="Create a password" type="password" class="inputtext">  			<input id="popup_new_pwd_2" ph="Verify password" type="password" class="inputtext">  			<div id="popup_change_pwd_msg" class="error-message"></div> 			<div class="left-links"> 				Input the same passwords. 			</div> 			',tmpl_del_account:'			<div id="del-account-img"> 			</div> 			<div id="del-account-content"> 				<span id="del-account-content-caption">Are you sure you want to deactivate your account?</span><br /> 				Deactivating your account will remove you from all groups and delete 				the ones you created. All members will be informed. 			</div> 			',tmpl_del_account_bottom:'			<div id="del-account-opt-out-check"> 				<span><input type="checkbox" value="0" id="del-account-opt-out"></span> 				<span id="del-account-opt-out-desc"><label for="del-account-opt-out"> 					Stop receiving group texts from your friends permanently. 					They\'ll never be able to chat with you or add you to a group. 				</label></span> 			</div> 			',tmpl_add_more_member:'			<div class="addmember-entries"> 				<div class="addmember-entry"> 					<span class="addmember-index">${start_index}</span> 					<input autocomplete="off" ph="Name" class="addmember-member-name inputtext landing-inputbox"> 					<input ph="Mobile Number (US only)" maxlength="14" class="addmember-member-number inputtext inputphone landing-inputbox"> 				</div> 				<div class="addmember-entry"> 					<span class="addmember-index">${start_index + 1}</span> 					<input autocomplete="off" ph="Name" class="addmember-member-name inputtext landing-inputbox"> 					<input ph="Mobile Number (US only)" maxlength="14" class="addmember-member-number inputtext inputphone landing-inputbox"> 				</div> 				<div class="addmember-entry"> 					<span class="addmember-index">${start_index + 2}</span> 					<input autocomplete="off" ph="Name" class="addmember-member-name inputtext landing-inputbox"> 					<input ph="Mobile Number (US only)" maxlength="14" class="addmember-member-number inputtext inputphone landing-inputbox"> 				</div> 			</div> 			'};b.compile=function(){for(var c in b.tmpl){$.template(c,b.tmpl[c])}};return b})(cex);
