;(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||document;if(E.nodeType){this[0]=E;this.length=1;this.context=E;return this}if(typeof E==="string"){var G=D.exec(E);if(G&&(G[1]||!H)){if(G[1]){E=o.clean([G[1]],H)}else{var I=document.getElementById(G[3]);if(I&&I.id!=G[3]){return o().find(E)}var F=o(I||[]);F.context=document;F.selector=E;return F}}else{return o(H).find(E)}}else{if(o.isFunction(E)){return o(document).ready(E)}}if(E.selector&&E.context){this.selector=E.selector;this.context=E.context}return this.setArray(o.isArray(E)?E:o.makeArray(E))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(E){return E===g?Array.prototype.slice.call(this):this[E]},pushStack:function(F,H,E){var G=o(F);G.prevObject=this;G.context=this.context;if(H==="find"){G.selector=this.selector+(this.selector?" ":"")+E}else{if(H){G.selector=this.selector+"."+H+"("+E+")"}}return G},setArray:function(E){this.length=0;Array.prototype.push.apply(this,E);return this},each:function(F,E){return o.each(this,F,E)},index:function(E){return o.inArray(E&&E.jquery?E[0]:E,this)},attr:function(F,H,G){var E=F;if(typeof F==="string"){if(H===g){return this[0]&&o[G||"attr"](this[0],F)}else{E={};E[F]=H}}return this.each(function(I){for(F in E){o.attr(G?this.style:this,F,o.prop(this,E[F],G,I,F))}})},css:function(E,F){if((E=="width"||E=="height")&&parseFloat(F)<0){F=g}return this.attr(E,F,"curCSS")},text:function(F){if(typeof F!=="object"&&F!=null){return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(F))}var E="";o.each(F||this,function(){o.each(this.childNodes,function(){if(this.nodeType!=8){E+=this.nodeType!=1?this.nodeValue:o.fn.text([this])}})});return E},wrapAll:function(E){if(this[0]){var F=o(E,this[0].ownerDocument).clone();if(this[0].parentNode){F.insertBefore(this[0])}F.map(function(){var G=this;while(G.firstChild){G=G.firstChild}return G}).append(this)}return this},wrapInner:function(E){return this.each(function(){o(this).contents().wrapAll(E)})},wrap:function(E){return this.each(function(){o(this).wrapAll(E)})},append:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.appendChild(E)}})},prepend:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.insertBefore(E,this.firstChild)}})},before:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this)})},after:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this.nextSibling)})},end:function(){return this.prevObject||o([])},push:[].push,sort:[].sort,splice:[].splice,find:function(E){if(this.length===1){var F=this.pushStack([],"find",E);F.length=0;o.find(E,this[0],F);return F}else{return this.pushStack(o.unique(o.map(this,function(G){return o.find(E,G)})),"find",E)}},clone:function(G){var E=this.map(function(){if(!o.support.noCloneEvent&&!o.isXMLDoc(this)){var I=this.outerHTML;if(!I){var J=this.ownerDocument.createElement("div");J.appendChild(this.cloneNode(true));I=J.innerHTML}return o.clean([I.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else{return this.cloneNode(true)}});if(G===true){var H=this.find("*").andSelf(),F=0;E.find("*").andSelf().each(function(){if(this.nodeName!==H[F].nodeName){return}var I=o.data(H[F],"events");for(var K in I){for(var J in I[K]){o.event.add(this,K,I[K][J],I[K][J].data)}}F++})}return E},filter:function(E){return this.pushStack(o.isFunction(E)&&o.grep(this,function(G,F){return E.call(G,F)})||o.multiFilter(E,o.grep(this,function(F){return F.nodeType===1})),"filter",E)},closest:function(E){var G=o.expr.match.POS.test(E)?o(E):null,F=0;return this.map(function(){var H=this;while(H&&H.ownerDocument){if(G?G.index(H)>-1:o(H).is(E)){o.data(H,"closest",F);return H}H=H.parentNode;F++}})},not:function(E){if(typeof E==="string"){if(f.test(E)){return this.pushStack(o.multiFilter(E,this,true),"not",E)}else{E=o.multiFilter(E,this)}}var F=E.length&&E[E.length-1]!==g&&!E.nodeType;return this.filter(function(){return F?o.inArray(this,E)<0:this!=E})},add:function(E){return this.pushStack(o.unique(o.merge(this.get(),typeof E==="string"?o(E):o.makeArray(E))))},is:function(E){return!!E&&o.multiFilter(E,this).length>0},hasClass:function(E){return!!E&&this.is("."+E)},val:function(K){if(K===g){var E=this[0];if(E){if(o.nodeName(E,"option")){return(E.attributes.value||{}).specified?E.value:E.text}if(o.nodeName(E,"select")){var I=E.selectedIndex,L=[],M=E.options,H=E.type=="select-one";if(I<0){return null}for(var F=H?I:0,J=H?I+1:M.length;F<J;F++){var G=M[F];if(G.selected){K=o(G).val();if(H){return K}L.push(K)}}return L}return(E.value||"").replace(/\r/g,"")}return g}if(typeof K==="number"){K+=""}return this.each(function(){if(this.nodeType!=1){return}if(o.isArray(K)&&/radio|checkbox/.test(this.type)){this.checked=(o.inArray(this.value,K)>=0||o.inArray(this.name,K)>=0)}else{if(o.nodeName(this,"select")){var N=o.makeArray(K);o("option",this).each(function(){this.selected=(o.inArray(this.value,N)>=0||o.inArray(this.text,N)>=0)});if(!N.length){this.selectedIndex=-1}}else{this.value=K}}})},html:function(E){return E===g?(this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null):this.empty().append(E)},replaceWith:function(E){return this.after(E).remove()},eq:function(E){return this.slice(E,+E+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(E){return this.pushStack(o.map(this,function(G,F){return E.call(G,F,G)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(J,M,L){if(this[0]){var I=(this[0].ownerDocument||this[0]).createDocumentFragment(),F=o.clean(J,(this[0].ownerDocument||this[0]),I),H=I.firstChild;if(H){for(var G=0,E=this.length;G<E;G++){L.call(K(this[G],H),this.length>1||G>0?I.cloneNode(true):I)}}if(F){o.each(F,z)}}return this;function K(N,O){return M&&o.nodeName(N,"table")&&o.nodeName(O,"tr")?(N.getElementsByTagName("tbody")[0]||N.appendChild(N.ownerDocument.createElement("tbody"))):N}}};o.fn.init.prototype=o.fn;function z(E,F){if(F.src){o.ajax({url:F.src,async:false,dataType:"script"})}else{o.globalEval(F.text||F.textContent||F.innerHTML||"")}if(F.parentNode){F.parentNode.removeChild(F)}}function e(){return+new Date}o.extend=o.fn.extend=function(){var J=arguments[0]||{},H=1,I=arguments.length,E=false,G;if(typeof J==="boolean"){E=J;J=arguments[1]||{};H=2}if(typeof J!=="object"&&!o.isFunction(J)){J={}}if(I==H){J=this;--H}for(;H<I;H++){if((G=arguments[H])!=null){for(var F in G){var K=J[F],L=G[F];if(J===L){continue}if(E&&L&&typeof L==="object"&&!L.nodeType){J[F]=o.extend(E,K||(L.length!=null?[]:{}),L)}else{if(L!==g){J[F]=L}}}}}return J};var b=/z-?index|font-?weight|opacity|zoom|line-?height/i,q=document.defaultView||{},s=Object.prototype.toString;o.extend({noConflict:function(E){l.$=p;if(E){l.jQuery=y}return o},isFunction:function(E){return s.call(E)==="[object Function]"},isArray:function(E){return s.call(E)==="[object Array]"},isXMLDoc:function(E){return E.nodeType===9&&E.documentElement.nodeName!=="HTML"||!!E.ownerDocument&&o.isXMLDoc(E.ownerDocument)},globalEval:function(G){if(G&&/\S/.test(G)){var F=document.getElementsByTagName("head")[0]||document.documentElement,E=document.createElement("script");E.type="text/javascript";if(o.support.scriptEval){E.appendChild(document.createTextNode(G))}else{E.text=G}F.insertBefore(E,F.firstChild);F.removeChild(E)}},nodeName:function(F,E){return F.nodeName&&F.nodeName.toUpperCase()==E.toUpperCase()},each:function(G,K,F){var E,H=0,I=G.length;if(F){if(I===g){for(E in G){if(K.apply(G[E],F)===false){break}}}else{for(;H<I;){if(K.apply(G[H++],F)===false){break}}}}else{if(I===g){for(E in G){if(K.call(G[E],E,G[E])===false){break}}}else{for(var J=G[0];H<I&&K.call(J,H,J)!==false;J=G[++H]){}}}return G},prop:function(H,I,G,F,E){if(o.isFunction(I)){I=I.call(H,F)}return typeof I==="number"&&G=="curCSS"&&!b.test(E)?I+"px":I},className:{add:function(E,F){o.each((F||"").split(/\s+/),function(G,H){if(E.nodeType==1&&!o.className.has(E.className,H)){E.className+=(E.className?" ":"")+H}})},remove:function(E,F){if(E.nodeType==1){E.className=F!==g?o.grep(E.className.split(/\s+/),function(G){return!o.className.has(F,G)}).join(" "):""}},has:function(F,E){return F&&o.inArray(E,(F.className||F).toString().split(/\s+/))>-1}},swap:function(H,G,I){var E={};for(var F in G){E[F]=H.style[F];H.style[F]=G[F]}I.call(H);for(var F in G){H.style[F]=E[F]}},css:function(H,F,J,E){if(F=="width"||F=="height"){var L,G={position:"absolute",visibility:"hidden",display:"block"},K=F=="width"?["Left","Right"]:["Top","Bottom"];function I(){L=F=="width"?H.offsetWidth:H.offsetHeight;if(E==="border"){return}o.each(K,function(){if(!E){L-=parseFloat(o.curCSS(H,"padding"+this,true))||0}if(E==="margin"){L+=parseFloat(o.curCSS(H,"margin"+this,true))||0}else{L-=parseFloat(o.curCSS(H,"border"+this+"Width",true))||0}})}if(H.offsetWidth!==0){I()}else{o.swap(H,G,I)}return Math.max(0,Math.round(L))}return o.curCSS(H,F,J)},curCSS:function(I,F,G){var L,E=I.style;if(F=="opacity"&&!o.support.opacity){L=o.attr(E,"opacity");return L==""?"1":L}if(F.match(/float/i)){F=w}if(!G&&E&&E[F]){L=E[F]}else{if(q.getComputedStyle){if(F.match(/float/i)){F="float"}F=F.replace(/([A-Z])/g,"-$1").toLowerCase();var M=q.getComputedStyle(I,null);if(M){L=M.getPropertyValue(F)}if(F=="opacity"&&L==""){L="1"}}else{if(I.currentStyle){var J=F.replace(/\-(\w)/g,function(N,O){return O.toUpperCase()});L=I.currentStyle[F]||I.currentStyle[J];if(!/^\d+(px)?$/i.test(L)&&/^\d/.test(L)){var H=E.left,K=I.runtimeStyle.left;I.runtimeStyle.left=I.currentStyle.left;E.left=L||0;L=E.pixelLeft+"px";E.left=H;I.runtimeStyle.left=K}}}}return L},clean:function(F,K,I){K=K||document;if(typeof K.createElement==="undefined"){K=K.ownerDocument||K[0]&&K[0].ownerDocument||document}if(!I&&F.length===1&&typeof F[0]==="string"){var H=/^<(\w+)\s*\/?>$/.exec(F[0]);if(H){return[K.createElement(H[1])]}}var G=[],E=[],L=K.createElement("div");o.each(F,function(P,S){if(typeof S==="number"){S+=""}if(!S){return}if(typeof S==="string"){S=S.replace(/(<(\w+)[^>]*?)\/>/g,function(U,V,T){return T.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?U:V+"></"+T+">"});var O=S.replace(/^\s+/,"").substring(0,10).toLowerCase();var Q=!O.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!O.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||O.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!O.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!O.indexOf("<td")||!O.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!O.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||!o.support.htmlSerialize&&[1,"div<div>","</div>"]||[0,"",""];L.innerHTML=Q[1]+S+Q[2];while(Q[0]--){L=L.lastChild}if(!o.support.tbody){var R=/<tbody/i.test(S),N=!O.indexOf("<table")&&!R?L.firstChild&&L.firstChild.childNodes:Q[1]=="<table>"&&!R?L.childNodes:[];for(var M=N.length-1;M>=0;--M){if(o.nodeName(N[M],"tbody")&&!N[M].childNodes.length){N[M].parentNode.removeChild(N[M])}}}if(!o.support.leadingWhitespace&&/^\s/.test(S)){L.insertBefore(K.createTextNode(S.match(/^\s*/)[0]),L.firstChild)}S=o.makeArray(L.childNodes)}if(S.nodeType){G.push(S)}else{G=o.merge(G,S)}});if(I){for(var J=0;G[J];J++){if(o.nodeName(G[J],"script")&&(!G[J].type||G[J].type.toLowerCase()==="text/javascript")){E.push(G[J].parentNode?G[J].parentNode.removeChild(G[J]):G[J])}else{if(G[J].nodeType===1){G.splice.apply(G,[J+1,0].concat(o.makeArray(G[J].getElementsByTagName("script"))))}I.appendChild(G[J])}}return E}return G},attr:function(J,G,K){if(!J||J.nodeType==3||J.nodeType==8){return g}var H=!o.isXMLDoc(J),L=K!==g;G=H&&o.props[G]||G;if(J.tagName){var F=/href|src|style/.test(G);if(G=="selected"&&J.parentNode){J.parentNode.selectedIndex}if(G in J&&H&&!F){if(L){if(G=="type"&&o.nodeName(J,"input")&&J.parentNode){throw"type property can't be changed"}J[G]=K}if(o.nodeName(J,"form")&&J.getAttributeNode(G)){return J.getAttributeNode(G).nodeValue}if(G=="tabIndex"){var I=J.getAttributeNode("tabIndex");return I&&I.specified?I.value:J.nodeName.match(/(button|input|object|select|textarea)/i)?0:J.nodeName.match(/^(a|area)$/i)&&J.href?0:g}return J[G]}if(!o.support.style&&H&&G=="style"){return o.attr(J.style,"cssText",K)}if(L){J.setAttribute(G,""+K)}var E=!o.support.hrefNormalized&&H&&F?J.getAttribute(G,2):J.getAttribute(G);return E===null?g:E}if(!o.support.opacity&&G=="opacity"){if(L){J.zoom=1;J.filter=(J.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(K)+""=="NaN"?"":"alpha(opacity="+K*100+")")}return J.filter&&J.filter.indexOf("opacity=")>=0?(parseFloat(J.filter.match(/opacity=([^)]*)/)[1])/100)+"":""}G=G.replace(/-([a-z])/ig,function(M,N){return N.toUpperCase()});if(L){J[G]=K}return J[G]},trim:function(E){return(E||"").replace(/^\s+|\s+$/g,"")},makeArray:function(G){var E=[];if(G!=null){var F=G.length;if(F==null||typeof G==="string"||o.isFunction(G)||G.setInterval){E[0]=G}else{while(F){E[--F]=G[F]}}}return E},inArray:function(G,H){for(var E=0,F=H.length;E<F;E++){if(H[E]===G){return E}}return-1},merge:function(H,E){var F=0,G,I=H.length;if(!o.support.getAll){while((G=E[F++])!=null){if(G.nodeType!=8){H[I++]=G}}}else{while((G=E[F++])!=null){H[I++]=G}}return H},unique:function(K){var F=[],E={};try{for(var G=0,H=K.length;G<H;G++){var J=o.data(K[G]);if(!E[J]){E[J]=true;F.push(K[G])}}}catch(I){F=K}return F},grep:function(F,J,E){var G=[];for(var H=0,I=F.length;H<I;H++){if(!E!=!J(F[H],H)){G.push(F[H])}}return G},map:function(E,J){var F=[];for(var G=0,H=E.length;G<H;G++){var I=J(E[G],G);if(I!=null){F[F.length]=I}}return F.concat.apply([],F)}});var C=navigator.userAgent.toLowerCase();o.browser={version:(C.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[0,"0"])[1],safari:/webkit/.test(C),opera:/opera/.test(C),msie:/msie/.test(C)&&!/opera/.test(C),mozilla:/mozilla/.test(C)&&!/(compatible|webkit)/.test(C)};o.each({parent:function(E){return E.parentNode},parents:function(E){return o.dir(E,"parentNode")},next:function(E){return o.nth(E,2,"nextSibling")},prev:function(E){return o.nth(E,2,"previousSibling")},nextAll:function(E){return o.dir(E,"nextSibling")},prevAll:function(E){return o.dir(E,"previousSibling")},siblings:function(E){return o.sibling(E.parentNode.firstChild,E)},children:function(E){return o.sibling(E.firstChild)},contents:function(E){return o.nodeName(E,"iframe")?E.contentDocument||E.contentWindow.document:o.makeArray(E.childNodes)}},function(E,F){o.fn[E]=function(G){var H=o.map(this,F);if(G&&typeof G=="string"){H=o.multiFilter(G,H)}return this.pushStack(o.unique(H),E,G)}});o.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(E,F){o.fn[E]=function(G){var J=[],L=o(G);for(var K=0,H=L.length;K<H;K++){var I=(K>0?this.clone(true):this).get();o.fn[F].apply(o(L[K]),I);J=J.concat(I)}return this.pushStack(J,E,G)}});o.each({removeAttr:function(E){o.attr(this,E,"");if(this.nodeType==1){this.removeAttribute(E)}},addClass:function(E){o.className.add(this,E)},removeClass:function(E){o.className.remove(this,E)},toggleClass:function(F,E){if(typeof E!=="boolean"){E=!o.className.has(this,F)}o.className[E?"add":"remove"](this,F)},remove:function(E){if(!E||o.filter(E,[this]).length){o("*",this).add([this]).each(function(){o.event.remove(this);o.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){o(this).children().remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(E,F){o.fn[E]=function(){return this.each(F,arguments)}});function j(E,F){return E[0]&&parseInt(o.curCSS(E[0],F,true),10)||0}var h="jQuery"+e(),v=0,A={};o.extend({cache:{},data:function(F,E,G){F=F==l?A:F;var H=F[h];if(!H){H=F[h]=++v}if(E&&!o.cache[H]){o.cache[H]={}}if(G!==g){o.cache[H][E]=G}return E?o.cache[H][E]:H},removeData:function(F,E){F=F==l?A:F;var H=F[h];if(E){if(o.cache[H]){delete o.cache[H][E];E="";for(E in o.cache[H]){break}if(!E){o.removeData(F)}}}else{try{delete F[h]}catch(G){if(F.removeAttribute){F.removeAttribute(h)}}delete o.cache[H]}},queue:function(F,E,H){if(F){E=(E||"fx")+"queue";var G=o.data(F,E);if(!G||o.isArray(H)){G=o.data(F,E,o.makeArray(H))}else{if(H){G.push(H)}}}return G},dequeue:function(H,G){var E=o.queue(H,G),F=E.shift();if(!G||G==="fx"){F=E[0]}if(F!==g){F.call(H)}}});o.fn.extend({data:function(E,G){var H=E.split(".");H[1]=H[1]?"."+H[1]:"";if(G===g){var F=this.triggerHandler("getData"+H[1]+"!",[H[0]]);if(F===g&&this.length){F=o.data(this[0],E)}return F===g&&H[1]?this.data(H[0]):F}else{return this.trigger("setData"+H[1]+"!",[H[0],G]).each(function(){o.data(this,E,G)})}},removeData:function(E){return this.each(function(){o.removeData(this,E)})},queue:function(E,F){if(typeof E!=="string"){F=E;E="fx"}if(F===g){return o.queue(this[0],E)}return this.each(function(){var G=o.queue(this,E,F);if(E=="fx"&&G.length==1){G[0].call(this)}})},dequeue:function(E){return this.each(function(){o.dequeue(this,E)})}});(function(){var R=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,L=0,H=Object.prototype.toString;var F=function(Y,U,ab,ac){ab=ab||[];U=U||document;if(U.nodeType!==1&&U.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return ab}var Z=[],W,af,ai,T,ad,V,X=true;R.lastIndex=0;while((W=R.exec(Y))!==null){Z.push(W[1]);if(W[2]){V=RegExp.rightContext;break}}if(Z.length>1&&M.exec(Y)){if(Z.length===2&&I.relative[Z[0]]){af=J(Z[0]+Z[1],U)}else{af=I.relative[Z[0]]?[U]:F(Z.shift(),U);while(Z.length){Y=Z.shift();if(I.relative[Y]){Y+=Z.shift()}af=J(Y,af)}}}else{var ae=ac?{expr:Z.pop(),set:E(ac)}:F.find(Z.pop(),Z.length===1&&U.parentNode?U.parentNode:U,Q(U));af=F.filter(ae.expr,ae.set);if(Z.length>0){ai=E(af)}else{X=false}while(Z.length){var ah=Z.pop(),ag=ah;if(!I.relative[ah]){ah=""}else{ag=Z.pop()}if(ag==null){ag=U}I.relative[ah](ai,ag,Q(U))}}if(!ai){ai=af}if(!ai){throw"Syntax error, unrecognized expression: "+(ah||Y)}if(H.call(ai)==="[object Array]"){if(!X){ab.push.apply(ab,ai)}else{if(U.nodeType===1){for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&(ai[aa]===true||ai[aa].nodeType===1&&K(U,ai[aa]))){ab.push(af[aa])}}}else{for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&ai[aa].nodeType===1){ab.push(af[aa])}}}}}else{E(ai,ab)}if(V){F(V,U,ab,ac);if(G){hasDuplicate=false;ab.sort(G);if(hasDuplicate){for(var aa=1;aa<ab.length;aa++){if(ab[aa]===ab[aa-1]){ab.splice(aa--,1)}}}}}return ab};F.matches=function(T,U){return F(T,null,null,U)};F.find=function(aa,T,ab){var Z,X;if(!aa){return[]}for(var W=0,V=I.order.length;W<V;W++){var Y=I.order[W],X;if((X=I.match[Y].exec(aa))){var U=RegExp.leftContext;if(U.substr(U.length-1)!=="\\"){X[1]=(X[1]||"").replace(/\\/g,"");Z=I.find[Y](X,T,ab);if(Z!=null){aa=aa.replace(I.match[Y],"");break}}}}if(!Z){Z=T.getElementsByTagName("*")}return{set:Z,expr:aa}};F.filter=function(ad,ac,ag,W){var V=ad,ai=[],aa=ac,Y,T,Z=ac&&ac[0]&&Q(ac[0]);while(ad&&ac.length){for(var ab in I.filter){if((Y=I.match[ab].exec(ad))!=null){var U=I.filter[ab],ah,af;T=false;if(aa==ai){ai=[]}if(I.preFilter[ab]){Y=I.preFilter[ab](Y,aa,ag,ai,W,Z);if(!Y){T=ah=true}else{if(Y===true){continue}}}if(Y){for(var X=0;(af=aa[X])!=null;X++){if(af){ah=U(af,Y,X,aa);var ae=W^!!ah;if(ag&&ah!=null){if(ae){T=true}else{aa[X]=false}}else{if(ae){ai.push(af);T=true}}}}}if(ah!==g){if(!ag){aa=ai}ad=ad.replace(I.match[ab],"");if(!T){return[]}break}}}if(ad==V){if(T==null){throw"Syntax error, unrecognized expression: "+ad}else{break}}V=ad}return aa};var I=F.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\(\)]*)+)\2\))?/},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(T){return T.getAttribute("href")}},relative:{"+":function(aa,T,Z){var X=typeof T==="string",ab=X&&!/\W/.test(T),Y=X&&!ab;if(ab&&!Z){T=T.toUpperCase()}for(var W=0,V=aa.length,U;W<V;W++){if((U=aa[W])){while((U=U.previousSibling)&&U.nodeType!==1){}aa[W]=Y||U&&U.nodeName===T?U||false:U===T}}if(Y){F.filter(T,aa,true)}},">":function(Z,U,aa){var X=typeof U==="string";if(X&&!/\W/.test(U)){U=aa?U:U.toUpperCase();for(var V=0,T=Z.length;V<T;V++){var Y=Z[V];if(Y){var W=Y.parentNode;Z[V]=W.nodeName===U?W:false}}}else{for(var V=0,T=Z.length;V<T;V++){var Y=Z[V];if(Y){Z[V]=X?Y.parentNode:Y.parentNode===U}}if(X){F.filter(U,Z,true)}}},"":function(W,U,Y){var V=L++,T=S;if(!U.match(/\W/)){var X=U=Y?U:U.toUpperCase();T=P}T("parentNode",U,V,W,X,Y)},"~":function(W,U,Y){var V=L++,T=S;if(typeof U==="string"&&!U.match(/\W/)){var X=U=Y?U:U.toUpperCase();T=P}T("previousSibling",U,V,W,X,Y)}},find:{ID:function(U,V,W){if(typeof V.getElementById!=="undefined"&&!W){var T=V.getElementById(U[1]);return T?[T]:[]}},NAME:function(V,Y,Z){if(typeof Y.getElementsByName!=="undefined"){var U=[],X=Y.getElementsByName(V[1]);for(var W=0,T=X.length;W<T;W++){if(X[W].getAttribute("name")===V[1]){U.push(X[W])}}return U.length===0?null:U}},TAG:function(T,U){return U.getElementsByTagName(T[1])}},preFilter:{CLASS:function(W,U,V,T,Z,aa){W=" "+W[1].replace(/\\/g,"")+" ";if(aa){return W}for(var X=0,Y;(Y=U[X])!=null;X++){if(Y){if(Z^(Y.className&&(" "+Y.className+" ").indexOf(W)>=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(/\\/g,"")},TAG:function(U,T){for(var V=0;T[V]===false;V++){}return T[V]&&Q(T[V])?U[1]:U[1].toUpperCase()},CHILD:function(T){if(T[1]=="nth"){var U=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(T[2]=="even"&&"2n"||T[2]=="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1].replace(/\\/g,"");if(!Z&&I.attrMap[W]){X[1]=I.attrMap[W]}if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if(X[3].match(R).length>1||/^\w/.test(X[3])){X[3]=F(X[3],null,null,U)}else{var W=F.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(I.match.POS.test(X[0])||I.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){T.parentNode.selectedIndex;return T.selected===true},parent:function(T){return!!T.firstChild},empty:function(T){return!T.firstChild},has:function(V,U,T){return!!F(T[3],V).length},header:function(T){return/h\d/i.test(T.nodeName)},text:function(T){return"text"===T.type},radio:function(T){return"radio"===T.type},checkbox:function(T){return"checkbox"===T.type},file:function(T){return"file"===T.type},password:function(T){return"password"===T.type},submit:function(T){return"submit"===T.type},image:function(T){return"image"===T.type},reset:function(T){return"reset"===T.type},button:function(T){return"button"===T.type||T.nodeName.toUpperCase()==="BUTTON"},input:function(T){return/input|select|textarea|button/i.test(T.nodeName)}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return U<T[3]-0},gt:function(V,U,T){return U>T[3]-0},nth:function(V,U,T){return T[3]-0==U},eq:function(V,U,T){return T[3]-0==U}},filter:{PSEUDO:function(Z,V,W,aa){var U=V[1],X=I.filters[U];if(X){return X(Z,W,V,aa)}else{if(U==="contains"){return(Z.textContent||Z.innerText||"").indexOf(V[3])>=0}else{if(U==="not"){var Y=V[3];for(var W=0,T=Y.length;W<T;W++){if(Y[W]===Z){return false}}return true}}}},CHILD:function(T,W){var Z=W[1],U=T;switch(Z){case"only":case"first":while(U=U.previousSibling){if(U.nodeType===1){return false}}if(Z=="first"){return true}U=T;case"last":while(U=U.nextSibling){if(U.nodeType===1){return false}}return true;case"nth":var V=W[2],ac=W[3];if(V==1&&ac==0){return true}var Y=W[0],ab=T.parentNode;if(ab&&(ab.sizcache!==Y||!T.nodeIndex)){var X=0;for(U=ab.firstChild;U;U=U.nextSibling){if(U.nodeType===1){U.nodeIndex=++X}}ab.sizcache=Y}var aa=T.nodeIndex-ac;if(V==0){return aa==0}else{return(aa%V==0&&aa/V>=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=I.attrHandle[V]?I.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!=U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=I.setFilters[T];if(W){return W(X,V,U,Y)}}}};var M=I.match.POS;for(var O in I.match){I.match[O]=RegExp(I.match[O].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var E=function(U,T){U=Array.prototype.slice.call(U);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(N){E=function(X,W){var U=W||[];if(H.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var V=0,T=X.length;V<T;V++){U.push(X[V])}}else{for(var V=0;X[V];V++){U.push(X[V])}}}return U}}var G;if(document.documentElement.compareDocumentPosition){G=function(U,T){var V=U.compareDocumentPosition(T)&4?-1:U===T?0:1;if(V===0){hasDuplicate=true}return V}}else{if("sourceIndex"in document.documentElement){G=function(U,T){var V=U.sourceIndex-T.sourceIndex;if(V===0){hasDuplicate=true}return V}}else{if(document.createRange){G=function(W,U){var V=W.ownerDocument.createRange(),T=U.ownerDocument.createRange();V.selectNode(W);V.collapse(true);T.selectNode(U);T.collapse(true);var X=V.compareBoundaryPoints(Range.START_TO_END,T);if(X===0){hasDuplicate=true}return X}}}}(function(){var U=document.createElement("form"),V="script"+(new Date).getTime();U.innerHTML="<input name='"+V+"'/>";var T=document.documentElement;T.insertBefore(U,T.firstChild);if(!!document.getElementById(V)){I.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:g:[]}};I.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U)})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){I.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="<a href='#'></a>";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){I.attrHandle.href=function(U){return U.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var T=F,U=document.createElement("div");U.innerHTML="<p class='TEST'></p>";if(U.querySelectorAll&&U.querySelectorAll(".TEST").length===0){return}F=function(Y,X,V,W){X=X||document;if(!W&&X.nodeType===9&&!Q(X)){try{return E(X.querySelectorAll(Y),V)}catch(Z){}}return T(Y,X,V,W)};F.find=T.find;F.filter=T.filter;F.selectors=T.selectors;F.matches=T.matches})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var T=document.createElement("div");T.innerHTML="<div class='test e'></div><div class='test'></div>";if(T.getElementsByClassName("e").length===0){return}T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return}I.order.splice(1,0,"CLASS");I.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}}})()}function P(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W<V;W++){var T=ad[W];if(T){if(ab&&T.nodeType===1){T.sizcache=Y;T.sizset=W}T=T[U];var X=false;while(T){if(T.sizcache===Y){X=ad[T.sizset];break}if(T.nodeType===1&&!ac){T.sizcache=Y;T.sizset=W}if(T.nodeName===Z){X=T;break}T=T[U]}ad[W]=X}}}function S(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W<V;W++){var T=ad[W];if(T){if(ab&&T.nodeType===1){T.sizcache=Y;T.sizset=W}T=T[U];var X=false;while(T){if(T.sizcache===Y){X=ad[T.sizset];break}if(T.nodeType===1){if(!ac){T.sizcache=Y;T.sizset=W}if(typeof Z!=="string"){if(T===Z){X=true;break}}else{if(F.filter(Z,[T]).length>0){X=T;break}}}T=T[U]}ad[W]=X}}}var K=document.compareDocumentPosition?function(U,T){return U.compareDocumentPosition(T)&16}:function(U,T){return U!==T&&(U.contains?U.contains(T):true)};var Q=function(T){return T.nodeType===9&&T.documentElement.nodeName!=="HTML"||!!T.ownerDocument&&Q(T.ownerDocument)};var J=function(T,aa){var W=[],X="",Y,V=aa.nodeType?[aa]:aa;while((Y=I.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(I.match.PSEUDO,"")}T=I.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z<U;Z++){F(T,V[Z],W)}return F.filter(X,W)};o.find=F;o.filter=F.filter;o.expr=F.selectors;o.expr[":"]=o.expr.filters;F.selectors.filters.hidden=function(T){return T.offsetWidth===0||T.offsetHeight===0};F.selectors.filters.visible=function(T){return T.offsetWidth>0||T.offsetHeight>0};F.selectors.filters.animated=function(T){return o.grep(o.timers,function(U){return T===U.elem}).length};o.multiFilter=function(V,T,U){if(U){V=":not("+V+")"}return F.matches(V,T)};o.dir=function(V,U){var T=[],W=V[U];while(W&&W!=document){if(W.nodeType==1){T.push(W)}W=W[U]}return T};o.nth=function(X,T,V,W){T=T||1;var U=0;for(;X;X=X[V]){if(X.nodeType==1&&++U==T){break}}return X};o.sibling=function(V,U){var T=[];for(;V;V=V.nextSibling){if(V.nodeType==1&&V!=U){T.push(V)}}return T};return;l.Sizzle=F})();o.event={add:function(I,F,H,K){if(I.nodeType==3||I.nodeType==8){return}if(I.setInterval&&I!=l){I=l}if(!H.guid){H.guid=this.guid++}if(K!==g){var G=H;H=this.proxy(G);H.data=K}var E=o.data(I,"events")||o.data(I,"events",{}),J=o.data(I,"handle")||o.data(I,"handle",function(){return typeof o!=="undefined"&&!o.event.triggered?o.event.handle.apply(arguments.callee.elem,arguments):g});J.elem=I;o.each(F.split(/\s+/),function(M,N){var O=N.split(".");N=O.shift();H.type=O.slice().sort().join(".");var L=E[N];if(o.event.specialAll[N]){o.event.specialAll[N].setup.call(I,K,O)}if(!L){L=E[N]={};if(!o.event.special[N]||o.event.special[N].setup.call(I,K,O)===false){if(I.addEventListener){I.addEventListener(N,J,false)}else{if(I.attachEvent){I.attachEvent("on"+N,J)}}}}L[H.guid]=H;o.event.global[N]=true});I=null},guid:1,global:{},remove:function(K,H,J){if(K.nodeType==3||K.nodeType==8){return}var G=o.data(K,"events"),F,E;if(G){if(H===g||(typeof H==="string"&&H.charAt(0)==".")){for(var I in G){this.remove(K,I+(H||""))}}else{if(H.type){J=H.handler;H=H.type}o.each(H.split(/\s+/),function(M,O){var Q=O.split(".");O=Q.shift();var N=RegExp("(^|\\.)"+Q.slice().sort().join(".*\\.")+"(\\.|$)");if(G[O]){if(J){delete G[O][J.guid]}else{for(var P in G[O]){if(N.test(G[O][P].type)){delete G[O][P]}}}if(o.event.specialAll[O]){o.event.specialAll[O].teardown.call(K,Q)}for(F in G[O]){break}if(!F){if(!o.event.special[O]||o.event.special[O].teardown.call(K,Q)===false){if(K.removeEventListener){K.removeEventListener(O,o.data(K,"handle"),false)}else{if(K.detachEvent){K.detachEvent("on"+O,o.data(K,"handle"))}}}F=null;delete G[O]}}})}for(F in G){break}if(!F){var L=o.data(K,"handle");if(L){L.elem=null}o.removeData(K,"events");o.removeData(K,"handle")}}},trigger:function(I,K,H,E){var G=I.type||I;if(!E){I=typeof I==="object"?I[h]?I:o.extend(o.Event(G),I):o.Event(G);if(G.indexOf("!")>=0){I.type=G=G.slice(0,-1);I.exclusive=true}if(!H){I.stopPropagation();if(this.global[G]){o.each(o.cache,function(){if(this.events&&this.events[G]){o.event.trigger(I,K,this.handle.elem)}})}}if(!H||H.nodeType==3||H.nodeType==8){return g}I.result=g;I.target=H;K=o.makeArray(K);K.unshift(I)}I.currentTarget=H;var J=o.data(H,"handle");if(J){J.apply(H,K)}if((!H[G]||(o.nodeName(H,"a")&&G=="click"))&&H["on"+G]&&H["on"+G].apply(H,K)===false){I.result=false}if(!E&&H[G]&&!I.isDefaultPrevented()&&!(o.nodeName(H,"a")&&G=="click")){this.triggered=true;try{H[G]()}catch(L){}}this.triggered=false;if(!I.isPropagationStopped()){var F=H.parentNode||H.ownerDocument;if(F){o.event.trigger(I,K,F,true)}}},handle:function(K){var J,E;K=arguments[0]=o.event.fix(K||l.event);K.currentTarget=this;var L=K.type.split(".");K.type=L.shift();J=!L.length&&!K.exclusive;var I=RegExp("(^|\\.)"+L.slice().sort().join(".*\\.")+"(\\.|$)");E=(o.data(this,"events")||{})[K.type];for(var G in E){var H=E[G];if(J||I.test(H.type)){K.handler=H;K.data=H.data;var F=H.apply(this,arguments);if(F!==g){K.result=F;if(F===false){K.preventDefault();K.stopPropagation()}}if(K.isImmediatePropagationStopped()){break}}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(H){if(H[h]){return H}var F=H;H=o.Event(F);for(var G=this.props.length,J;G;){J=this.props[--G];H[J]=F[J]}if(!H.target){H.target=H.srcElement||document}if(H.target.nodeType==3){H.target=H.target.parentNode}if(!H.relatedTarget&&H.fromElement){H.relatedTarget=H.fromElement==H.target?H.toElement:H.fromElement}if(H.pageX==null&&H.clientX!=null){var I=document.documentElement,E=document.body;H.pageX=H.clientX+(I&&I.scrollLeft||E&&E.scrollLeft||0)-(I.clientLeft||0);H.pageY=H.clientY+(I&&I.scrollTop||E&&E.scrollTop||0)-(I.clientTop||0)}if(!H.which&&((H.charCode||H.charCode===0)?H.charCode:H.keyCode)){H.which=H.charCode||H.keyCode}if(!H.metaKey&&H.ctrlKey){H.metaKey=H.ctrlKey}if(!H.which&&H.button){H.which=(H.button&1?1:(H.button&2?3:(H.button&4?2:0)))}return H},proxy:function(F,E){E=E||function(){return F.apply(this,arguments)};E.guid=F.guid=F.guid||E.guid||this.guid++;return E},special:{ready:{setup:B,teardown:function(){}}},specialAll:{live:{setup:function(E,F){o.event.add(this,F[0],c)},teardown:function(G){if(G.length){var E=0,F=RegExp("(^|\\.)"+G[0]+"(\\.|$)");o.each((o.data(this,"events").live||{}),function(){if(F.test(this.type)){E++}});if(E<1){o.event.remove(this,G[0],c)}}}}}};o.Event=function(E){if(!this.preventDefault){return new o.Event(E)}if(E&&E.type){this.originalEvent=E;this.type=E.type}else{this.type=E}this.timeStamp=e();this[h]=true};function k(){return false}function u(){return true}o.Event.prototype={preventDefault:function(){this.isDefaultPrevented=u;var E=this.originalEvent;if(!E){return}if(E.preventDefault){E.preventDefault()}E.returnValue=false},stopPropagation:function(){this.isPropagationStopped=u;var E=this.originalEvent;if(!E){return}if(E.stopPropagation){E.stopPropagation()}E.cancelBubble=true},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=u;this.stopPropagation()},isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k};var a=function(F){var E=F.relatedTarget;while(E&&E!=this){try{E=E.parentNode}catch(G){E=this}}if(E!=this){F.type=F.data;o.event.handle.apply(this,arguments)}};o.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(F,E){o.event.special[E]={setup:function(){o.event.add(this,F,a,E)},teardown:function(){o.event.remove(this,F,a)}}});o.fn.extend({bind:function(F,G,E){return F=="unload"?this.one(F,G,E):this.each(function(){o.event.add(this,F,E||G,E&&G)})},one:function(G,H,F){var E=o.event.proxy(F||H,function(I){o(this).unbind(I,E);return(F||H).apply(this,arguments)});return this.each(function(){o.event.add(this,G,E,F&&H)})},unbind:function(F,E){return this.each(function(){o.event.remove(this,F,E)})},trigger:function(E,F){return this.each(function(){o.event.trigger(E,F,this)})},triggerHandler:function(E,G){if(this[0]){var F=o.Event(E);F.preventDefault();F.stopPropagation();o.event.trigger(F,G,this[0]);return F.result}},toggle:function(G){var E=arguments,F=1;while(F<E.length){o.event.proxy(G,E[F++])}return this.click(o.event.proxy(G,function(H){this.lastToggle=(this.lastToggle||0)%F;H.preventDefault();return E[this.lastToggle++].apply(this,arguments)||false}))},hover:function(E,F){return this.mouseenter(E).mouseleave(F)},ready:function(E){B();if(o.isReady){E.call(document,o)}else{o.readyList.push(E)}return this},live:function(G,F){var E=o.event.proxy(F);E.guid+=this.selector+G;o(document).bind(i(G,this.selector),this.selector,E);return this},die:function(F,E){o(document).unbind(i(F,this.selector),E?{guid:E.guid+this.selector+F}:null);return this}});function c(H){var E=RegExp("(^|\\.)"+H.type+"(\\.|$)"),G=true,F=[];o.each(o.data(this,"events").live||[],function(I,J){if(E.test(J.type)){var K=o(H.target).closest(J.data)[0];if(K){F.push({elem:K,fn:J})}}});F.sort(function(J,I){return o.data(J.elem,"closest")-o.data(I.elem,"closest")});o.each(F,function(){if(this.fn.call(this.elem,H,this.fn.data)===false){return(G=false)}});return G}function i(F,E){return["live",F,E.replace(/\./g,"`").replace(/ /g,"|")].join(".")}o.extend({isReady:false,readyList:[],ready:function(){if(!o.isReady){o.isReady=true;if(o.readyList){o.each(o.readyList,function(){this.call(document,o)});o.readyList=null}o(document).triggerHandler("ready")}}});var x=false;function B(){if(x){return}x=true;if(document.addEventListener){document.addEventListener("DOMContentLoaded",function(){document.removeEventListener("DOMContentLoaded",arguments.callee,false);o.ready()},false)}else{if(document.attachEvent){document.attachEvent("onreadystatechange",function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",arguments.callee);o.ready()}});if(document.documentElement.doScroll&&l==l.top){(function(){if(o.isReady){return}try{document.documentElement.doScroll("left")}catch(E){setTimeout(arguments.callee,0);return}o.ready()})()}}}o.event.add(l,"load",o.ready)}o.each(("blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,mouseenter,mouseleave,change,select,submit,keydown,keypress,keyup,error").split(","),function(F,E){o.fn[E]=function(G){return G?this.bind(E,G):this.trigger(E)}});o(l).bind("unload",function(){for(var E in o.cache){if(E!=1&&o.cache[E].handle){o.event.remove(o.cache[E].handle.elem)}}});(function(){o.support={};var F=document.documentElement,G=document.createElement("script"),K=document.createElement("div"),J="script"+(new Date).getTime();K.style.display="none";K.innerHTML='   <link/><table></table><a href="/a" style="color:red;float:left;opacity:.5;">a</a><select><option>text</option></select><object><param/></object>';var H=K.getElementsByTagName("*"),E=K.getElementsByTagName("a")[0];if(!H||!H.length||!E){return}o.support={leadingWhitespace:K.firstChild.nodeType==3,tbody:!K.getElementsByTagName("tbody").length,objectAll:!!K.getElementsByTagName("object")[0].getElementsByTagName("*").length,htmlSerialize:!!K.getElementsByTagName("link").length,style:/red/.test(E.getAttribute("style")),hrefNormalized:E.getAttribute("href")==="/a",opacity:E.style.opacity==="0.5",cssFloat:!!E.style.cssFloat,scriptEval:false,noCloneEvent:true,boxModel:null};G.type="text/javascript";try{G.appendChild(document.createTextNode("window."+J+"=1;"))}catch(I){}F.insertBefore(G,F.firstChild);if(l[J]){o.support.scriptEval=true;delete l[J]}F.removeChild(G);if(K.attachEvent&&K.fireEvent){K.attachEvent("onclick",function(){o.support.noCloneEvent=false;K.detachEvent("onclick",arguments.callee)});K.cloneNode(true).fireEvent("onclick")}o(function(){var L=document.createElement("div");L.style.width=L.style.paddingLeft="1px";document.body.appendChild(L);o.boxModel=o.support.boxModel=L.offsetWidth===2;document.body.removeChild(L).style.display="none"})})();var w=o.support.cssFloat?"cssFloat":"styleFloat";o.props={"for":"htmlFor","class":"className","float":w,cssFloat:w,styleFloat:w,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",tabindex:"tabIndex"};o.fn.extend({_load:o.fn.load,load:function(G,J,K){if(typeof G!=="string"){return this._load(G)}var I=G.indexOf(" ");if(I>=0){var E=G.slice(I,G.length);G=G.slice(0,I)}var H="GET";if(J){if(o.isFunction(J)){K=J;J=null}else{if(typeof J==="object"){J=o.param(J);H="POST"}}}var F=this;o.ajax({url:G,type:H,dataType:"html",data:J,complete:function(M,L){if(L=="success"||L=="notmodified"){F.html(E?o("<div/>").append(M.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(E):M.responseText)}if(K){F.each(K,[M.responseText,L,M])}}});return this},serialize:function(){return o.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?o.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(E,F){var G=o(this).val();return G==null?null:o.isArray(G)?o.map(G,function(I,H){return{name:F.name,value:I}}):{name:F.name,value:G}}).get()}});o.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(E,F){o.fn[F]=function(G){return this.bind(F,G)}});var r=e();o.extend({get:function(E,G,H,F){if(o.isFunction(G)){H=G;G=null}return o.ajax({type:"GET",url:E,data:G,success:H,dataType:F})},getScript:function(E,F){return o.get(E,null,F,"script")},getJSON:function(E,F,G){return o.get(E,F,G,"json")},post:function(E,G,H,F){if(o.isFunction(G)){H=G;G={}}return o.ajax({type:"POST",url:E,data:G,success:H,dataType:F})},ajaxSetup:function(E){o.extend(o.ajaxSettings,E)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return l.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest()},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(M){M=o.extend(true,M,o.extend(true,{},o.ajaxSettings,M));var W,F=/=\?(&|$)/g,R,V,G=M.type.toUpperCase();if(M.data&&M.processData&&typeof M.data!=="string"){M.data=o.param(M.data)}if(M.dataType=="jsonp"){if(G=="GET"){if(!M.url.match(F)){M.url+=(M.url.match(/\?/)?"&":"?")+(M.jsonp||"callback")+"=?"}}else{if(!M.data||!M.data.match(F)){M.data=(M.data?M.data+"&":"")+(M.jsonp||"callback")+"=?"}}M.dataType="json"}if(M.dataType=="json"&&(M.data&&M.data.match(F)||M.url.match(F))){W="jsonp"+r++;if(M.data){M.data=(M.data+"").replace(F,"="+W+"$1")}M.url=M.url.replace(F,"="+W+"$1");M.dataType="script";l[W]=function(X){V=X;I();L();l[W]=g;try{delete l[W]}catch(Y){}if(H){H.removeChild(T)}}}if(M.dataType=="script"&&M.cache==null){M.cache=false}if(M.cache===false&&G=="GET"){var E=e();var U=M.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+E+"$2");M.url=U+((U==M.url)?(M.url.match(/\?/)?"&":"?")+"_="+E:"")}if(M.data&&G=="GET"){M.url+=(M.url.match(/\?/)?"&":"?")+M.data;M.data=null}if(M.global&&!o.active++){o.event.trigger("ajaxStart")}var Q=/^(\w+:)?\/\/([^\/?#]+)/.exec(M.url);if(M.dataType=="script"&&G=="GET"&&Q&&(Q[1]&&Q[1]!=location.protocol||Q[2]!=location.host)){var H=document.getElementsByTagName("head")[0];var T=document.createElement("script");T.src=M.url;if(M.scriptCharset){T.charset=M.scriptCharset}if(!W){var O=false;T.onload=T.onreadystatechange=function(){if(!O&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){O=true;I();L();T.onload=T.onreadystatechange=null;H.removeChild(T)}}}H.appendChild(T);return g}var K=false;var J=M.xhr();if(M.username){J.open(G,M.url,M.async,M.username,M.password)}else{J.open(G,M.url,M.async)}try{if(M.data){J.setRequestHeader("Content-Type",M.contentType)}if(M.ifModified){J.setRequestHeader("If-Modified-Since",o.lastModified[M.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}J.setRequestHeader("X-Requested-With","XMLHttpRequest");J.setRequestHeader("Accept",M.dataType&&M.accepts[M.dataType]?M.accepts[M.dataType]+", */*":M.accepts._default)}catch(S){}if(M.beforeSend&&M.beforeSend(J,M)===false){if(M.global&&!--o.active){o.event.trigger("ajaxStop")}J.abort();return false}if(M.global){o.event.trigger("ajaxSend",[J,M])}var N=function(X){if(J.readyState==0){if(P){clearInterval(P);P=null;if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}}else{if(!K&&J&&(J.readyState==4||X=="timeout")){K=true;if(P){clearInterval(P);P=null}R=X=="timeout"?"timeout":!o.httpSuccess(J)?"error":M.ifModified&&o.httpNotModified(J,M.url)?"notmodified":"success";if(R=="success"){try{V=o.httpData(J,M.dataType,M)}catch(Z){R="parsererror"}}if(R=="success"){var Y;try{Y=J.getResponseHeader("Last-Modified")}catch(Z){}if(M.ifModified&&Y){o.lastModified[M.url]=Y}if(!W){I()}}else{o.handleError(M,J,R)}L();if(X){J.abort()}if(M.async){J=null}}}};if(M.async){var P=setInterval(N,13);if(M.timeout>0){setTimeout(function(){if(J&&!K){N("timeout")}},M.timeout)}}try{J.send(M.data)}catch(S){o.handleError(M,J,null,S)}if(!M.async){N()}function I(){if(M.success){M.success(V,R)}if(M.global){o.event.trigger("ajaxSuccess",[J,M])}}function L(){if(M.complete){M.complete(J,R)}if(M.global){o.event.trigger("ajaxComplete",[J,M])}if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}return J},handleError:function(F,H,E,G){if(F.error){F.error(H,E,G)}if(F.global){o.event.trigger("ajaxError",[H,F,G])}},active:0,httpSuccess:function(F){try{return!F.status&&location.protocol=="file:"||(F.status>=200&&F.status<300)||F.status==304||F.status==1223}catch(E){}return false},httpNotModified:function(G,E){try{var H=G.getResponseHeader("Last-Modified");return G.status==304||H==o.lastModified[E]}catch(F){}return false},httpData:function(J,H,G){var F=J.getResponseHeader("content-type"),E=H=="xml"||!H&&F&&F.indexOf("xml")>=0,I=E?J.responseXML:J.responseText;if(E&&I.documentElement.tagName=="parsererror"){throw"parsererror"}if(G&&G.dataFilter){I=G.dataFilter(I,H)}if(typeof I==="string"){if(H=="script"){o.globalEval(I)}if(H=="json"){I=l["eval"]("("+I+")")}}return I},param:function(E){var G=[];function H(I,J){G[G.length]=encodeURIComponent(I)+"="+encodeURIComponent(J)}if(o.isArray(E)||E.jquery){o.each(E,function(){H(this.name,this.value)})}else{for(var F in E){if(o.isArray(E[F])){o.each(E[F],function(){H(F,this)})}else{H(F,o.isFunction(E[F])?E[F]():E[F])}}}return G.join("&").replace(/%20/g,"+")}});var m={},n,d=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];function t(F,E){var G={};o.each(d.concat.apply([],d.slice(0,E)),function(){G[this]=F});return G}o.fn.extend({show:function(J,L){if(J){return this.animate(t("show",3),J,L)}else{for(var H=0,F=this.length;H<F;H++){var E=o.data(this[H],"olddisplay");this[H].style.display=E||"";if(o.css(this[H],"display")==="none"){var G=this[H].tagName,K;if(m[G]){K=m[G]}else{var I=o("<"+G+" />").appendTo("body");K=I.css("display");if(K==="none"){K="block"}I.remove();m[G]=K}o.data(this[H],"olddisplay",K)}}for(var H=0,F=this.length;H<F;H++){this[H].style.display=o.data(this[H],"olddisplay")||""}return this}},hide:function(H,I){if(H){return this.animate(t("hide",3),H,I)}else{for(var G=0,F=this.length;G<F;G++){var E=o.data(this[G],"olddisplay");if(!E&&E!=="none"){o.data(this[G],"olddisplay",o.css(this[G],"display"))}}for(var G=0,F=this.length;G<F;G++){this[G].style.display="none"}return this}},_toggle:o.fn.toggle,toggle:function(G,F){var E=typeof G==="boolean";return o.isFunction(G)&&o.isFunction(F)?this._toggle.apply(this,arguments):G==null||E?this.each(function(){var H=E?G:o(this).is(":hidden");o(this)[H?"show":"hide"]()}):this.animate(t("toggle",3),G,F)},fadeTo:function(E,G,F){return this.animate({opacity:G},E,F)},animate:function(I,F,H,G){var E=o.speed(F,H,G);return this[E.queue===false?"each":"queue"](function(){var K=o.extend({},E),M,L=this.nodeType==1&&o(this).is(":hidden"),J=this;for(M in I){if(I[M]=="hide"&&L||I[M]=="show"&&!L){return K.complete.call(this)}if((M=="height"||M=="width")&&this.style){K.display=o.css(this,"display");K.overflow=this.style.overflow}}if(K.overflow!=null){this.style.overflow="hidden"}K.curAnim=o.extend({},I);o.each(I,function(O,S){var R=new o.fx(J,K,O);if(/toggle|show|hide/.test(S)){R[S=="toggle"?L?"show":"hide":S](I)}else{var Q=S.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),T=R.cur(true)||0;if(Q){var N=parseFloat(Q[2]),P=Q[3]||"px";if(P!="px"){J.style[O]=(N||1)+P;T=((N||1)/R.cur(true))*T;J.style[O]=T+P}if(Q[1]){N=((Q[1]=="-="?-1:1)*N)+T}R.custom(T,N,P)}else{R.custom(T,S,"")}}});return true})},stop:function(F,E){var G=o.timers;if(F){this.queue([])}this.each(function(){for(var H=G.length-1;H>=0;H--){if(G[H].elem==this){if(E){G[H](true)}G.splice(H,1)}}});if(!E){this.dequeue()}return this}});o.each({slideDown:t("show",1),slideUp:t("hide",1),slideToggle:t("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(E,F){o.fn[E]=function(G,H){return this.animate(F,G,H)}});o.extend({speed:function(G,H,F){var E=typeof G==="object"?G:{complete:F||!F&&H||o.isFunction(G)&&G,duration:G,easing:F&&H||H&&!o.isFunction(H)&&H};E.duration=o.fx.off?0:typeof E.duration==="number"?E.duration:o.fx.speeds[E.duration]||o.fx.speeds._default;E.old=E.complete;E.complete=function(){if(E.queue!==false){o(this).dequeue()}if(o.isFunction(E.old)){E.old.call(this)}};return E},easing:{linear:function(G,H,E,F){return E+F*G},swing:function(G,H,E,F){return((-Math.cos(G*Math.PI)/2)+0.5)*F+E}},timers:[],fx:function(F,E,G){this.options=E;this.elem=F;this.prop=G;if(!E.orig){E.orig={}}}});o.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(o.fx.step[this.prop]||o.fx.step._default)(this);if((this.prop=="height"||this.prop=="width")&&this.elem.style){this.elem.style.display="block"}},cur:function(F){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var E=parseFloat(o.css(this.elem,this.prop,F));return E&&E>-10000?E:parseFloat(o.curCSS(this.elem,this.prop))||0},custom:function(I,H,G){this.startTime=e();this.start=I;this.end=H;this.unit=G||this.unit||"px";this.now=this.start;this.pos=this.state=0;var E=this;function F(J){return E.step(J)}F.elem=this.elem;if(F()&&o.timers.push(F)&&!n){n=setInterval(function(){var K=o.timers;for(var J=0;J<K.length;J++){if(!K[J]()){K.splice(J--,1)}}if(!K.length){clearInterval(n);n=g}},13)}},show:function(){this.options.orig[this.prop]=o.attr(this.elem.style,this.prop);this.options.show=true;this.custom(this.prop=="width"||this.prop=="height"?1:0,this.cur());o(this.elem).show()},hide:function(){this.options.orig[this.prop]=o.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(H){var G=e();if(H||G>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var E=true;for(var F in this.options.curAnim){if(this.options.curAnim[F]!==true){E=false}}if(E){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(o.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){o(this.elem).hide()}if(this.options.hide||this.options.show){for(var I in this.options.curAnim){o.attr(this.elem.style,I,this.options.orig[I])}}this.options.complete.call(this.elem)}return false}else{var J=G-this.startTime;this.state=J/this.options.duration;this.pos=o.easing[this.options.easing||(o.easing.swing?"swing":"linear")](this.state,J,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};o.extend(o.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(E){o.attr(E.elem.style,"opacity",E.now)},_default:function(E){if(E.elem.style&&E.elem.style[E.prop]!=null){E.elem.style[E.prop]=E.now+E.unit}else{E.elem[E.prop]=E.now}}}});if(document.documentElement.getBoundingClientRect){o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}var G=this[0].getBoundingClientRect(),J=this[0].ownerDocument,F=J.body,E=J.documentElement,L=E.clientTop||F.clientTop||0,K=E.clientLeft||F.clientLeft||0,I=G.top+(self.pageYOffset||o.boxModel&&E.scrollTop||F.scrollTop)-L,H=G.left+(self.pageXOffset||o.boxModel&&E.scrollLeft||F.scrollLeft)-K;return{top:I,left:H}}}else{o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}o.offset.initialized||o.offset.initialize();var J=this[0],G=J.offsetParent,F=J,O=J.ownerDocument,M,H=O.documentElement,K=O.body,L=O.defaultView,E=L.getComputedStyle(J,null),N=J.offsetTop,I=J.offsetLeft;while((J=J.parentNode)&&J!==K&&J!==H){M=L.getComputedStyle(J,null);N-=J.scrollTop,I-=J.scrollLeft;if(J===G){N+=J.offsetTop,I+=J.offsetLeft;if(o.offset.doesNotAddBorder&&!(o.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(J.tagName))){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}F=G,G=J.offsetParent}if(o.offset.subtractsBorderForOverflowNotVisible&&M.overflow!=="visible"){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}E=M}if(E.position==="relative"||E.position==="static"){N+=K.offsetTop,I+=K.offsetLeft}if(E.position==="fixed"){N+=Math.max(H.scrollTop,K.scrollTop),I+=Math.max(H.scrollLeft,K.scrollLeft)}return{top:N,left:I}}}o.offset={initialize:function(){if(this.initialized){return}var L=document.body,F=document.createElement("div"),H,G,N,I,M,E,J=L.style.marginTop,K='<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>';M={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(E in M){F.style[E]=M[E]}F.innerHTML=K;L.insertBefore(F,L.firstChild);H=F.firstChild,G=H.firstChild,I=H.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(G.offsetTop!==5);this.doesAddBorderForTableAndCells=(I.offsetTop===5);H.style.overflow="hidden",H.style.position="relative";this.subtractsBorderForOverflowNotVisible=(G.offsetTop===-5);L.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=(L.offsetTop===0);L.style.marginTop=J;L.removeChild(F);this.initialized=true},bodyOffset:function(E){o.offset.initialized||o.offset.initialize();var G=E.offsetTop,F=E.offsetLeft;if(o.offset.doesNotIncludeMarginInBodyOffset){G+=parseInt(o.curCSS(E,"marginTop",true),10)||0,F+=parseInt(o.curCSS(E,"marginLeft",true),10)||0}return{top:G,left:F}}};o.fn.extend({position:function(){var I=0,H=0,F;if(this[0]){var G=this.offsetParent(),J=this.offset(),E=/^body|html$/i.test(G[0].tagName)?{top:0,left:0}:G.offset();J.top-=j(this,"marginTop");J.left-=j(this,"marginLeft");E.top+=j(G,"borderTopWidth");E.left+=j(G,"borderLeftWidth");F={top:J.top-E.top,left:J.left-E.left}}return F},offsetParent:function(){var E=this[0].offsetParent||document.body;while(E&&(!/^body|html$/i.test(E.tagName)&&o.css(E,"position")=="static")){E=E.offsetParent}return o(E)}});o.each(["Left","Top"],function(F,E){var G="scroll"+E;o.fn[G]=function(H){if(!this[0]){return null}return H!==g?this.each(function(){this==l||this==document?l.scrollTo(!F?H:o(l).scrollLeft(),F?H:o(l).scrollTop()):this[G]=H}):this[0]==l||this[0]==document?self[F?"pageYOffset":"pageXOffset"]||o.boxModel&&document.documentElement[G]||document.body[G]:this[0][G]}});o.each(["Height","Width"],function(I,G){var E=I?"Left":"Top",H=I?"Right":"Bottom",F=G.toLowerCase();o.fn["inner"+G]=function(){return this[0]?o.css(this[0],F,false,"padding"):null};o.fn["outer"+G]=function(K){return this[0]?o.css(this[0],F,false,K?"margin":"border"):null};var J=G.toLowerCase();o.fn[J]=function(K){return this[0]==l?document.compatMode=="CSS1Compat"&&document.documentElement["client"+G]||document.body["client"+G]:this[0]==document?Math.max(document.documentElement["client"+G],document.body["scroll"+G],document.documentElement["scroll"+G],document.body["offset"+G],document.documentElement["offset"+G]):K===g?(this.length?o.css(this[0],J):null):this.css(J,typeof K==="string"?K:K+"px")}})})();;jQuery.each(["id","title","name","href","src","rel"],function(i,n){jQuery.fn[n]=function(h){return h==undefined?this.length?this[0][n]:null:this.attr(n,h);};});jQuery.each("top,left,position,float,overflow,color,background".split(","),function(i,n){jQuery.fn[n]=function(h){return h==undefined?(this.length?jQuery.css(this[0],n):null):this.css(n,h);};});var e=("blur,focus,load,resize,scroll,unload,click,dblclick,"+"mousedown,mouseup,mousemove,mouseover,mouseout,change,reset,select,"+"submit,keydown,keypress,keyup,error").split(",");for(var i=0;i<e.length;i++)new function(){var o=e[i];jQuery.fn["un"+o]=function(f){return this.unbind(o,f);};jQuery.fn["one"+o]=function(f){var element=jQuery(this);var handler=function(){element.unbind(o,handler);element=null;return f.apply(this,arguments);};return this.bind(o,handler);};};jQuery.fn.ancestors=jQuery.fn.parents;jQuery.expr[":"]["nth-child"]="jQuery.nth(a.parentNode.firstChild,parseInt(m[3])+1,'nextSibling')==a";jQuery.fn._filter=jQuery.fn.filter;jQuery.fn.filter=function(arr){return this._filter(arr.constructor==Array?arr.join(","):arr);};;var Drupal=Drupal||{};Drupal.jsEnabled=document.getElementsByTagName&&document.createElement&&document.createTextNode&&document.documentElement&&document.getElementById;Drupal.extend=function(obj){for(var i in obj){if(this[i]&&(typeof(this[i])=='function'||typeof(this[i])=='object')){Drupal.extend.apply(this[i],[obj[i]]);}
else{this[i]=obj[i];}}};Drupal.redirectFormButton=function(uri,button,handler){button.onmouseover=button.onfocus=function(){button.onclick=function(){Drupal.createIframe();var button=this;var action=button.form.action;var target=button.form.target;this.form.action=uri;this.form.target='redirect-target';handler.onsubmit();window.iframeHandler=function(){var iframe=$('#redirect-target').get(0);button.form.action=action;button.form.target=target;try{response=(iframe.contentWindow||iframe.contentDocument||iframe).document.body.innerHTML;response=response.replace(/[\f\n\r\t]/g,' ');if(window.opera){response=response.replace(/&quot;/g,'"');}}
catch(e){response=null;}
response=Drupal.parseJson(response);if(response.status==0){handler.onerror(response.data);return;}
handler.oncomplete(response.data);return true;}
return true;}}
button.onmouseout=button.onblur=function(){button.onclick=null;}};Drupal.absolutePosition=function(el){var sLeft=0,sTop=0;var isDiv=/^div$/i.test(el.tagName);if(isDiv&&el.scrollLeft){sLeft=el.scrollLeft;}
if(isDiv&&el.scrollTop){sTop=el.scrollTop;}
var r={x:el.offsetLeft-sLeft,y:el.offsetTop-sTop};if(el.offsetParent){var tmp=Drupal.absolutePosition(el.offsetParent);r.x+=tmp.x;r.y+=tmp.y;}
return r;};Drupal.dimensions=function(el){return{width:el.offsetWidth,height:el.offsetHeight};};Drupal.mousePosition=function(e){return{x:e.clientX+document.documentElement.scrollLeft,y:e.clientY+document.documentElement.scrollTop};};Drupal.parseJson=function(data){if((data.substring(0,1)!='{')&&(data.substring(0,1)!='[')){return{status:0,data:data.length?data:'Unspecified error'};}
return eval('('+data+');');};Drupal.createIframe=function(){if($('#redirect-holder').size()){return;}
window.iframeHandler=function(){};var div=document.createElement('div');div.id='redirect-holder';$(div).html('<iframe name="redirect-target" id="redirect-target" class="redirect" onload="window.iframeHandler();"></iframe>');var iframe=div.firstChild;$(iframe).attr({name:'redirect-target',id:'redirect-target'}).css({position:'absolute',height:'1px',width:'1px',visibility:'hidden'});$('body').append(div);};Drupal.deleteIframe=function(){$('#redirect-holder').remove();};Drupal.freezeHeight=function(){Drupal.unfreezeHeight();var div=document.createElement('div');$(div).css({position:'absolute',top:'0px',left:'0px',width:'1px',height:$('body').css('height')}).attr('id','freeze-height');$('body').append(div);};Drupal.unfreezeHeight=function(){$('#freeze-height').remove();};Drupal.encodeURIComponent=function(item,uri){uri=uri||location.href;item=encodeURIComponent(item).replace(/%2F/g,'/');return(uri.indexOf('?q=')!=-1)?item:item.replace(/%26/g,'%2526').replace(/%23/g,'%2523').replace(/\/\//g,'/%252F');};if(Drupal.jsEnabled){$(document.documentElement).addClass('js');};window.Raphael=(function(){var separator=/[, ]+/,doc=document,win=window,oldRaphael={was:"Raphael"in win,is:win.Raphael},R=function(){if(R.is(arguments[0],"array")){var a=arguments[0],cnv=create[apply](R,a.splice(0,3+R.is(a[0],nu))),res=cnv.set();for(var i=0,ii=a[length];i<ii;i++){var j=a[i]||{};({circle:1,rect:1,path:1,ellipse:1,text:1,image:1})[has](j.type)&&res[push](cnv[j.type]().attr(j));}
return res;}
return create[apply](R,arguments);},appendChild="appendChild",apply="apply",concat="concat",E="",events=["click","dblclick","mousedown","mousemove","mouseout","mouseover","mouseup"],has="hasOwnProperty",isit=/^\[object\s+|\]$/gi,join="join",length="length",proto="prototype",lowerCase=String[proto].toLowerCase,mmax=Math.max,mmin=Math.min,nu="number",toString="toString",objectToString=Object[proto][toString],paper={},pow=Math.pow,push="push",rg=/^(?=[\da-f]$)/,ISURL=/^url\(['"]?([^\)]+)['"]?\)$/i,round=Math.round,S=" ",setAttribute="setAttribute",split="split",toFloat=parseFloat,toInt=parseInt,upperCase=String[proto].toUpperCase,availableAttrs={"clip-rect":"0 0 10e9 10e9",cursor:"default",cx:0,cy:0,fill:"#fff","fill-opacity":1,font:'10px "Arial"',"font-family":'"Arial"',"font-size":"10","font-style":"normal","font-weight":400,gradient:0,height:0,href:"http://raphaeljs.com/",opacity:1,path:"M0,0",r:0,rotation:0,rx:0,ry:0,scale:"1 1",src:"",stroke:"#000","stroke-dasharray":"","stroke-linecap":"butt","stroke-linejoin":"butt","stroke-miterlimit":0,"stroke-opacity":1,"stroke-width":1,target:"_blank","text-anchor":"middle",title:"Raphael",translation:"0 0",width:0,x:0,y:0},availableAnimAttrs={"clip-rect":"csv",cx:nu,cy:nu,fill:"colour","fill-opacity":nu,"font-size":nu,height:nu,opacity:nu,path:"path",r:nu,rotation:"csv",rx:nu,ry:nu,scale:"csv",stroke:"colour","stroke-opacity":nu,"stroke-width":nu,translation:"csv",width:nu,x:nu,y:nu},rp="replace";R.version="1.2.3";R.type=(win.SVGAngle||doc.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")?"SVG":"VML");R.svg=!(R.vml=R.type=="VML");R._id=0;R._oid=0;R.fn={};R.is=function(o,type){type=lowerCase.call(type);return((type=="object"||type=="undefined")&&typeof o==type)||(o==null&&type=="null")||lowerCase.call(objectToString.call(o)[rp](isit,E))==type;};R.setWindow=function(newwin){win=newwin;doc=win.document;};var toHex=function(color){if(R.vml){var trim=/^\s+|\s+$/g;toHex=cacher(function(color){var bod;color=(color+E).replace(trim,E);try{var document=new ActiveXObject("htmlfile");document.write("<body>");document.close();bod=document.body;}catch(e){bod=createPopup().document.body;}
var range=bod.createTextRange();try{bod.style.color=color;var value=range.queryCommandValue("ForeColor");value=((value&255)<<16)|(value&65280)|((value&16711680)>>>16);return"#"+("000000"+value[toString](16)).slice(-6);}catch(e){return"none";}});}else{var i=doc.createElement("i");i.className="Rapha\xebl Colour Picker";i.style.cssText="display:none";doc.body[appendChild](i);toHex=cacher(function(color){i.style.color=color;return doc.defaultView.getComputedStyle(i,E).getPropertyValue("color");});}
return toHex(color);};R.hsb2rgb=cacher(function(hue,saturation,brightness){if(R.is(hue,"object")&&"h"in hue&&"s"in hue&&"b"in hue){brightness=hue.b;saturation=hue.s;hue=hue.h;}
var red,green,blue;if(brightness==0){return{r:0,g:0,b:0,hex:"#000"};}
if(hue>1||saturation>1||brightness>1){hue/=255;saturation/=255;brightness/=255;}
var i=~~(hue*6),f=(hue*6)-i,p=brightness*(1-saturation),q=brightness*(1-(saturation*f)),t=brightness*(1-(saturation*(1-f)));red=[brightness,q,p,p,t,brightness,brightness][i];green=[t,brightness,brightness,q,p,p,t][i];blue=[p,p,t,brightness,brightness,q,p][i];red*=255;green*=255;blue*=255;var rgb={r:red,g:green,b:blue},r=(~~red)[toString](16),g=(~~green)[toString](16),b=(~~blue)[toString](16);r=r[rp](rg,"0");g=g[rp](rg,"0");b=b[rp](rg,"0");rgb.hex="#"+r+g+b;return rgb;},R);R.rgb2hsb=cacher(function(red,green,blue){if(R.is(red,"object")&&"r"in red&&"g"in red&&"b"in red){blue=red.b;green=red.g;red=red.r;}
if(R.is(red,"string")){var clr=R.getRGB(red);red=clr.r;green=clr.g;blue=clr.b;}
if(red>1||green>1||blue>1){red/=255;green/=255;blue/=255;}
var max=mmax(red,green,blue),min=mmin(red,green,blue),hue,saturation,brightness=max;if(min==max){return{h:0,s:0,b:max};}else{var delta=(max-min);saturation=delta/max;if(red==max){hue=(green-blue)/delta;}else if(green==max){hue=2+((blue-red)/delta);}else{hue=4+((red-green)/delta);}
hue/=6;hue<0&&hue++;hue>1&&hue--;}
return{h:hue,s:saturation,b:brightness};},R);var p2s=/,?([achlmqrstvxz]),?/gi;R._path2string=function(){return this.join(",")[rp](p2s,"$1");};function cacher(f,scope,postprocessor){function newf(){var arg=Array[proto].slice.call(arguments,0),args=arg[join]("\u25ba"),cache=newf.cache=newf.cache||{},count=newf.count=newf.count||[];if(cache[has](args)){return postprocessor?postprocessor(cache[args]):cache[args];}
count[length]>=1e3&&delete cache[count.shift()];count[push](args);cache[args]=f[apply](scope,arg);return postprocessor?postprocessor(cache[args]):cache[args];}
return newf;}
R.getRGB=cacher(function(colour){if(!colour||!!((colour+E).indexOf("-")+1)){return{r:-1,g:-1,b:-1,hex:"none",error:1};}
colour=colour+E;if(colour=="none"){return{r:-1,g:-1,b:-1,hex:"none"};}!({hs:1,rg:1})[has](colour.substring(0,2))&&(colour=toHex(colour));var res,red,green,blue,rgb=colour.match(/^\s*((#[a-f\d]{6})|(#[a-f\d]{3})|rgb\(\s*([\d\.]+\s*,\s*[\d\.]+\s*,\s*[\d\.]+)\s*\)|rgb\(\s*([\d\.]+%\s*,\s*[\d\.]+%\s*,\s*[\d\.]+%)\s*\)|hs[bl]\(\s*([\d\.]+\s*,\s*[\d\.]+\s*,\s*[\d\.]+)\s*\)|hs[bl]\(\s*([\d\.]+%\s*,\s*[\d\.]+%\s*,\s*[\d\.]+%)\s*\))\s*$/i);if(rgb){if(rgb[2]){blue=toInt(rgb[2].substring(5),16);green=toInt(rgb[2].substring(3,5),16);red=toInt(rgb[2].substring(1,3),16);}
if(rgb[3]){blue=toInt(rgb[3].substring(3)+rgb[3].substring(3),16);green=toInt(rgb[3].substring(2,3)+rgb[3].substring(2,3),16);red=toInt(rgb[3].substring(1,2)+rgb[3].substring(1,2),16);}
if(rgb[4]){rgb=rgb[4][split](/\s*,\s*/);red=toFloat(rgb[0]);green=toFloat(rgb[1]);blue=toFloat(rgb[2]);}
if(rgb[5]){rgb=rgb[5][split](/\s*,\s*/);red=toFloat(rgb[0])*2.55;green=toFloat(rgb[1])*2.55;blue=toFloat(rgb[2])*2.55;}
if(rgb[6]){rgb=rgb[6][split](/\s*,\s*/);red=toFloat(rgb[0]);green=toFloat(rgb[1]);blue=toFloat(rgb[2]);return R.hsb2rgb(red,green,blue);}
if(rgb[7]){rgb=rgb[7][split](/\s*,\s*/);red=toFloat(rgb[0])*2.55;green=toFloat(rgb[1])*2.55;blue=toFloat(rgb[2])*2.55;return R.hsb2rgb(red,green,blue);}
rgb={r:red,g:green,b:blue};var r=(~~red)[toString](16),g=(~~green)[toString](16),b=(~~blue)[toString](16);r=r[rp](rg,"0");g=g[rp](rg,"0");b=b[rp](rg,"0");rgb.hex="#"+r+g+b;return rgb;}
return{r:-1,g:-1,b:-1,hex:"none",error:1};},R);R.getColor=function(value){var start=this.getColor.start=this.getColor.start||{h:0,s:1,b:value||.75},rgb=this.hsb2rgb(start.h,start.s,start.b);start.h+=.075;if(start.h>1){start.h=0;start.s-=.2;start.s<=0&&(this.getColor.start={h:0,s:1,b:start.b});}
return rgb.hex;};R.getColor.reset=function(){delete this.start;};R.parsePathString=cacher(function(pathString){if(!pathString){return null;}
var paramCounts={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},data=[];if(R.is(pathString,"array")&&R.is(pathString[0],"array")){data=pathClone(pathString);}
if(!data[length]){(pathString+E)[rp](/([achlmqstvz])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?\s*,?\s*)+)/ig,function(a,b,c){var params=[],name=lowerCase.call(b);c[rp](/(-?\d*\.?\d*(?:e[-+]?\d+)?)\s*,?\s*/ig,function(a,b){b&&params[push](+b);});while(params[length]>=paramCounts[name]){data[push]([b][concat](params.splice(0,paramCounts[name])));if(!paramCounts[name]){break;};}});}
data[toString]=R._path2string;return data;});var pathDimensions=cacher(function(path){if(!path){return{x:0,y:0,width:0,height:0};}
path=path2curve(path);var x=0,y=0,X=[],Y=[];for(var i=0,ii=path[length];i<ii;i++){if(path[i][0]=="M"){x=path[i][1];y=path[i][2];X[push](x);Y[push](y);}else{var dim=curveDim(x,y,path[i][1],path[i][2],path[i][3],path[i][4],path[i][5],path[i][6]);X=X[concat](dim.min.x,dim.max.x);Y=Y[concat](dim.min.y,dim.max.y);}}
var xmin=mmin[apply](0,X),ymin=mmin[apply](0,Y);return{x:xmin,y:ymin,width:mmax[apply](0,X)-xmin,height:mmax[apply](0,Y)-ymin};}),pathClone=function(pathArray){var res=[];if(!R.is(pathArray,"array")||!R.is(pathArray&&pathArray[0],"array")){pathArray=R.parsePathString(pathArray);}
for(var i=0,ii=pathArray[length];i<ii;i++){res[i]=[];for(var j=0,jj=pathArray[i][length];j<jj;j++){res[i][j]=pathArray[i][j];}}
res[toString]=R._path2string;return res;},pathToRelative=cacher(function(pathArray){if(!R.is(pathArray,"array")||!R.is(pathArray&&pathArray[0],"array")){pathArray=R.parsePathString(pathArray);}
var res=[],x=0,y=0,mx=0,my=0,start=0;if(pathArray[0][0]=="M"){x=pathArray[0][1];y=pathArray[0][2];mx=x;my=y;start++;res[push](["M",x,y]);}
for(var i=start,ii=pathArray[length];i<ii;i++){var r=res[i]=[],pa=pathArray[i];if(pa[0]!=lowerCase.call(pa[0])){r[0]=lowerCase.call(pa[0]);switch(r[0]){case"a":r[1]=pa[1];r[2]=pa[2];r[3]=pa[3];r[4]=pa[4];r[5]=pa[5];r[6]=+(pa[6]-x).toFixed(3);r[7]=+(pa[7]-y).toFixed(3);break;case"v":r[1]=+(pa[1]-y).toFixed(3);break;case"m":mx=pa[1];my=pa[2];default:for(var j=1,jj=pa[length];j<jj;j++){r[j]=+(pa[j]-((j%2)?x:y)).toFixed(3);}}}else{r=res[i]=[];if(pa[0]=="m"){mx=pa[1]+x;my=pa[2]+y;}
for(var k=0,kk=pa[length];k<kk;k++){res[i][k]=pa[k];}}
var len=res[i][length];switch(res[i][0]){case"z":x=mx;y=my;break;case"h":x+=+res[i][len-1];break;case"v":y+=+res[i][len-1];break;default:x+=+res[i][len-2];y+=+res[i][len-1];}}
res[toString]=R._path2string;return res;},0,pathClone),pathToAbsolute=cacher(function(pathArray){if(!R.is(pathArray,"array")||!R.is(pathArray&&pathArray[0],"array")){pathArray=R.parsePathString(pathArray);}
var res=[],x=0,y=0,mx=0,my=0,start=0;if(pathArray[0][0]=="M"){x=+pathArray[0][1];y=+pathArray[0][2];mx=x;my=y;start++;res[0]=["M",x,y];}
for(var i=start,ii=pathArray[length];i<ii;i++){var r=res[i]=[],pa=pathArray[i];if(pa[0]!=upperCase.call(pa[0])){r[0]=upperCase.call(pa[0]);switch(r[0]){case"A":r[1]=pa[1];r[2]=pa[2];r[3]=pa[3];r[4]=pa[4];r[5]=pa[5];r[6]=+(pa[6]+x);r[7]=+(pa[7]+y);break;case"V":r[1]=+pa[1]+y;break;case"H":r[1]=+pa[1]+x;break;case"M":mx=+pa[1]+x;my=+pa[2]+y;default:for(var j=1,jj=pa[length];j<jj;j++){r[j]=+pa[j]+((j%2)?x:y);}}}else{for(var k=0,kk=pa[length];k<kk;k++){res[i][k]=pa[k];}}
switch(r[0]){case"Z":x=mx;y=my;break;case"H":x=r[1];break;case"V":y=r[1];break;default:x=res[i][res[i][length]-2];y=res[i][res[i][length]-1];}}
res[toString]=R._path2string;return res;},null,pathClone),l2c=function(x1,y1,x2,y2){return[x1,y1,x2,y2,x2,y2];},q2c=function(x1,y1,ax,ay,x2,y2){var _13=1/3,_23=2/3;return[_13*x1+_23*ax,_13*y1+_23*ay,_13*x2+_23*ax,_13*y2+_23*ay,x2,y2];},a2c=function(x1,y1,rx,ry,angle,large_arc_flag,sweep_flag,x2,y2,recursive){var PI=Math.PI,_120=PI*120/180,rad=PI/180*(+angle||0),res=[],xy,rotate=cacher(function(x,y,rad){var X=x*Math.cos(rad)-y*Math.sin(rad),Y=x*Math.sin(rad)+y*Math.cos(rad);return{x:X,y:Y};});if(!recursive){xy=rotate(x1,y1,-rad);x1=xy.x;y1=xy.y;xy=rotate(x2,y2,-rad);x2=xy.x;y2=xy.y;var cos=Math.cos(PI/180*angle),sin=Math.sin(PI/180*angle),x=(x1-x2)/2,y=(y1-y2)/2;rx=mmax(rx,Math.abs(x));ry=mmax(ry,Math.abs(y));var rx2=rx*rx,ry2=ry*ry,k=(large_arc_flag==sweep_flag?-1:1)*Math.sqrt(Math.abs((rx2*ry2-rx2*y*y-ry2*x*x)/(rx2*y*y+ry2*x*x))),cx=k*rx*y/ry+(x1+x2)/2,cy=k*-ry*x/rx+(y1+y2)/2,f1=Math.asin((y1-cy)/ry),f2=Math.asin((y2-cy)/ry);f1=x1<cx?PI-f1:f1;f2=x2<cx?PI-f2:f2;f1<0&&(f1=PI*2+f1);f2<0&&(f2=PI*2+f2);if(sweep_flag&&f1>f2){f1=f1-PI*2;}
if(!sweep_flag&&f2>f1){f2=f2-PI*2;}}else{f1=recursive[0];f2=recursive[1];cx=recursive[2];cy=recursive[3];}
var df=f2-f1;if(Math.abs(df)>_120){var f2old=f2,x2old=x2,y2old=y2;f2=f1+_120*(sweep_flag&&f2>f1?1:-1);x2=cx+rx*Math.cos(f2);y2=cy+ry*Math.sin(f2);res=a2c(x2,y2,rx,ry,angle,0,sweep_flag,x2old,y2old,[f2,f2old,cx,cy]);}
df=f2-f1;var c1=Math.cos(f1),s1=Math.sin(f1),c2=Math.cos(f2),s2=Math.sin(f2),t=Math.tan(df/4),hx=4/3*rx*t,hy=4/3*ry*t,m1=[x1,y1],m2=[x1+hx*s1,y1-hy*c1],m3=[x2+hx*s2,y2-hy*c2],m4=[x2,y2];m2[0]=2*m1[0]-m2[0];m2[1]=2*m1[1]-m2[1];if(recursive){return[m2,m3,m4][concat](res);}else{res=[m2,m3,m4][concat](res)[join](",")[split](",");var newres=[];for(var i=0,ii=res[length];i<ii;i++){newres[i]=i%2?rotate(res[i-1],res[i],rad).y:rotate(res[i],res[i+1],rad).x;}
return newres;}},findDotAtSegment=cacher(function(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y,t){var x=pow(1-t,3)*p1x+pow(1-t,2)*3*t*c1x+(1-t)*3*t*t*c2x+pow(t,3)*p2x,y=pow(1-t,3)*p1y+pow(1-t,2)*3*t*c1y+(1-t)*3*t*t*c2y+pow(t,3)*p2y,mx=p1x+2*t*(c1x-p1x)+t*t*(c2x-2*c1x+p1x),my=p1y+2*t*(c1y-p1y)+t*t*(c2y-2*c1y+p1y),nx=c1x+2*t*(c2x-c1x)+t*t*(p2x-2*c2x+c1x),ny=c1y+2*t*(c2y-c1y)+t*t*(p2y-2*c2y+c1y),ax=(1-t)*p1x+t*c1x,ay=(1-t)*p1y+t*c1y,cx=(1-t)*c2x+t*p2x,cy=(1-t)*c2y+t*p2y;return{x:x,y:y,m:{x:mx,y:my},n:{x:nx,y:ny},start:{x:ax,y:ay},end:{x:cx,y:cy}};}),curveDim=cacher(function(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y){var a=(c2x-2*c1x+p1x)-(p2x-2*c2x+c1x),b=2*(c1x-p1x)-2*(c2x-c1x),c=p1x-c1x,t1=(-b+Math.sqrt(b*b-4*a*c))/2/a,t2=(-b-Math.sqrt(b*b-4*a*c))/2/a,y=[p1y,p2y],x=[p1x,p2x],dot1=findDotAtSegment(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y,t1>0&&t1<1?t1:0),dot2=findDotAtSegment(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y,t2>0&&t2<1?t2:0);x=x[concat](dot1.x,dot2.x);y=y[concat](dot1.y,dot2.y);a=(c2y-2*c1y+p1y)-(p2y-2*c2y+c1y);b=2*(c1y-p1y)-2*(c2y-c1y);c=p1y-c1y;t1=(-b+Math.sqrt(b*b-4*a*c))/2/a;t2=(-b-Math.sqrt(b*b-4*a*c))/2/a;dot1=findDotAtSegment(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y,t1>0&&t1<1?t1:0);dot2=findDotAtSegment(p1x,p1y,c1x,c1y,c2x,c2y,p2x,p2y,t2>0&&t2<1?t2:0);x=x[concat](dot1.x,dot2.x);y=y[concat](dot1.y,dot2.y);return{min:{x:mmin[apply](0,x),y:mmin[apply](0,y)},max:{x:mmax[apply](0,x),y:mmax[apply](0,y)}};}),path2curve=cacher(function(path,path2){var p=pathToAbsolute(path),p2=path2&&pathToAbsolute(path2),attrs={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},attrs2={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},processPath=function(path,d){var nx,ny;if(!path){return["C",d.x,d.y,d.x,d.y,d.x,d.y];}!(path[0]in{T:1,Q:1})&&(d.qx=d.qy=null);switch(path[0]){case"M":d.X=path[1];d.Y=path[2];break;case"A":path=["C"][concat](a2c[apply](0,[d.x,d.y][concat](path.slice(1))));break;case"S":nx=d.x+(d.x-(d.bx||d.x));ny=d.y+(d.y-(d.by||d.y));path=["C",nx,ny][concat](path.slice(1));break;case"T":d.qx=d.x+(d.x-(d.qx||d.x));d.qy=d.y+(d.y-(d.qy||d.y));path=["C"][concat](q2c(d.x,d.y,d.qx,d.qy,path[1],path[2]));break;case"Q":d.qx=path[1];d.qy=path[2];path=["C"][concat](q2c(d.x,d.y,path[1],path[2],path[3],path[4]));break;case"L":path=["C"][concat](l2c(d.x,d.y,path[1],path[2]));break;case"H":path=["C"][concat](l2c(d.x,d.y,path[1],d.y));break;case"V":path=["C"][concat](l2c(d.x,d.y,d.x,path[1]));break;case"Z":path=["C"][concat](l2c(d.x,d.y,d.X,d.Y));break;}
return path;},fixArc=function(pp,i){if(pp[i][length]>7){pp[i].shift();var pi=pp[i];while(pi[length]){pp.splice(i++,0,["C"][concat](pi.splice(0,6)));}
pp.splice(i,1);ii=mmax(p[length],p2&&p2[length]||0);}},fixM=function(path1,path2,a1,a2,i){if(path1&&path2&&path1[i][0]=="M"&&path2[i][0]!="M"){path2.splice(i,0,["M",a2.x,a2.y]);a1.bx=0;a1.by=0;a1.x=path1[i][1];a1.y=path1[i][2];ii=mmax(p[length],p2&&p2[length]||0);}};for(var i=0,ii=mmax(p[length],p2&&p2[length]||0);i<ii;i++){p[i]=processPath(p[i],attrs);fixArc(p,i);p2&&(p2[i]=processPath(p2[i],attrs2));p2&&fixArc(p2,i);fixM(p,p2,attrs,attrs2,i);fixM(p2,p,attrs2,attrs,i);var seg=p[i],seg2=p2&&p2[i],seglen=seg[length],seg2len=p2&&seg2[length];attrs.x=seg[seglen-2];attrs.y=seg[seglen-1];attrs.bx=toFloat(seg[seglen-4])||attrs.x;attrs.by=toFloat(seg[seglen-3])||attrs.y;attrs2.bx=p2&&(toFloat(seg2[seg2len-4])||attrs2.x);attrs2.by=p2&&(toFloat(seg2[seg2len-3])||attrs2.y);attrs2.x=p2&&seg2[seg2len-2];attrs2.y=p2&&seg2[seg2len-1];}
return p2?[p,p2]:p;},null,pathClone),parseDots=cacher(function(gradient){var dots=[];for(var i=0,ii=gradient[length];i<ii;i++){var dot={},par=gradient[i].match(/^([^:]*):?([\d\.]*)/);dot.color=R.getRGB(par[1]);if(dot.color.error){return null;}
dot.color=dot.color.hex;par[2]&&(dot.offset=par[2]+"%");dots[push](dot);}
for(var i=1,ii=dots[length]-1;i<ii;i++){if(!dots[i].offset){var start=toFloat(dots[i-1].offset||0),end=0;for(var j=i+1;j<ii;j++){if(dots[j].offset){end=dots[j].offset;break;}}
if(!end){end=100;j=ii;}
end=toFloat(end);var d=(end-start)/(j-i+1);for(;i<j;i++){start+=d;dots[i].offset=start+"%";}}}
return dots;}),getContainer=function(){var container,x,y,width,height;if(R.is(arguments[0],"string")||R.is(arguments[0],"object")){if(R.is(arguments[0],"string")){container=doc.getElementById(arguments[0]);}else{container=arguments[0];}
if(container.tagName){if(arguments[1]==null){return{container:container,width:container.style.pixelWidth||container.offsetWidth,height:container.style.pixelHeight||container.offsetHeight};}else{return{container:container,width:arguments[1],height:arguments[2]};}}}else if(R.is(arguments[0],nu)&&arguments[length]>3){return{container:1,x:arguments[0],y:arguments[1],width:arguments[2],height:arguments[3]};}},plugins=function(con,add){var that=this;for(var prop in add)if(add[has](prop)&&!(prop in con)){switch(typeof add[prop]){case"function":(function(f){con[prop]=con===that?f:function(){return f[apply](that,arguments);};})(add[prop]);break;case"object":con[prop]=con[prop]||{};plugins.call(this,con[prop],add[prop]);break;default:con[prop]=add[prop];break;}}},tear=function(el,paper){el==paper.top&&(paper.top=el.prev);el==paper.bottom&&(paper.bottom=el.next);el.next&&(el.next.prev=el.prev);el.prev&&(el.prev.next=el.next);},tofront=function(el,paper){if(paper.top===el){return;}
tear(el,paper);el.next=null;el.prev=paper.top;paper.top.next=el;paper.top=el;},toback=function(el,paper){if(paper.bottom===el){return;}
tear(el,paper);el.next=paper.bottom;el.prev=null;paper.bottom.prev=el;paper.bottom=el;},insertafter=function(el,el2,paper){tear(el,paper);el2==paper.top&&(paper.top=el);el2.next&&(el2.next.prev=el);el.next=el2.next;el.prev=el2;el2.next=el;},insertbefore=function(el,el2,paper){tear(el,paper);el2==paper.bottom&&(paper.bottom=el);el2.prev&&(el2.prev.next=el);el.prev=el2.prev;el2.prev=el;el.next=el2;};if(R.svg){paper.svgns="http://www.w3.org/2000/svg";paper.xlink="http://www.w3.org/1999/xlink";var round=function(num){return+num+(~~num===num)*.5;},roundPath=function(path){for(var i=0,ii=path[length];i<ii;i++){if(lowerCase.call(path[i][0])!="a"){for(var j=1,jj=path[i][length];j<jj;j++){path[i][j]=round(path[i][j]);}}else{path[i][6]=round(path[i][6]);path[i][7]=round(path[i][7]);}}
return path;},$=function(el,attr){if(attr){for(var key in attr)if(attr[has](key)){el[setAttribute](key,attr[key]);}}else{return doc.createElementNS(paper.svgns,el);}};R[toString]=function(){return"Your browser supports SVG.\nYou are running Rapha\xebl "+this.version;};var thePath=function(pathString,SVG){var el=$("path");SVG.canvas&&SVG.canvas[appendChild](el);var p=new Element(el,SVG);p.type="path";setFillAndStroke(p,{fill:"none",stroke:"#000",path:pathString});return p;};var addGradientFill=function(o,gradient,SVG){var type="linear",fx=.5,fy=.5,s=o.style;gradient=(gradient+E)[rp](/^r(?:\(([^,]+?)\s*,\s*([^\)]+?)\))?/,function(all,_fx,_fy){type="radial";if(_fx&&_fy){fx=toFloat(_fx);fy=toFloat(_fy);if(pow(fx-.5,2)+pow(fy-.5,2)>.25){fy=Math.sqrt(.25-pow(fx-.5,2))+.5;}}
return E;});gradient=gradient[split](/\s*\-\s*/);if(type=="linear"){var angle=gradient.shift();angle=-toFloat(angle);if(isNaN(angle)){return null;}
var vector=[0,0,Math.cos(angle*Math.PI/180),Math.sin(angle*Math.PI/180)],max=1/(mmax(Math.abs(vector[2]),Math.abs(vector[3]))||1);vector[2]*=max;vector[3]*=max;if(vector[2]<0){vector[0]=-vector[2];vector[2]=0;}
if(vector[3]<0){vector[1]=-vector[3];vector[3]=0;}}
var dots=parseDots(gradient);if(!dots){return null;}
var el=$(type+"Gradient");el.id="r"+(R._id++)[toString](36);type=="radial"?$(el,{fx:fx,fy:fy}):$(el,{x1:vector[0],y1:vector[1],x2:vector[2],y2:vector[3]});SVG.defs[appendChild](el);for(var i=0,ii=dots[length];i<ii;i++){var stop=$("stop");$(stop,{offset:dots[i].offset?dots[i].offset:!i?"0%":"100%","stop-color":dots[i].color||"#fff"});el[appendChild](stop);};$(o,{fill:"url(#"+el.id+")",opacity:1,"fill-opacity":1});s.fill=E;s.opacity=1;s.fillOpacity=1;return 1;};var updatePosition=function(o){var bbox=o.getBBox();$(o.pattern,{patternTransform:R.format("translate({0},{1})",bbox.x,bbox.y)});};var setFillAndStroke=function(o,params){var dasharray={"":[0],"none":[0],"-":[3,1],".":[1,1],"-.":[3,1,1,1],"-..":[3,1,1,1,1,1],". ":[1,3],"- ":[4,3],"--":[8,3],"- .":[4,3,1,3],"--.":[8,3,1,3],"--..":[8,3,1,3,1,3]},node=o.node,attrs=o.attrs,rot=o.rotate(),addDashes=function(o,value){value=dasharray[lowerCase.call(value)];if(value){var width=o.attrs["stroke-width"]||"1",butt={round:width,square:width,butt:0}[o.attrs["stroke-linecap"]||params["stroke-linecap"]]||0,dashes=[];var i=value[length];while(i--){dashes[i]=value[i]*width+((i%2)?1:-1)*butt;}
$(node,{"stroke-dasharray":dashes[join](",")});}};params[has]("rotation")&&(rot=params.rotation);var rotxy=(rot+E)[split](separator);if(!(rotxy.length-1)){rotxy=null;}else{rotxy[1]=+rotxy[1];rotxy[2]=+rotxy[2];}
toFloat(rot)&&o.rotate(0,true);for(var att in params)if(params[has](att)){if(!availableAttrs[has](att)){continue;}
var value=params[att];attrs[att]=value;switch(att){case"rotation":o.rotate(value,true);break;case"href":case"title":case"target":var pn=node.parentNode;if(lowerCase.call(pn.tagName)!="a"){var hl=$("a");pn.insertBefore(hl,node);hl[appendChild](node);pn=hl;}
pn.setAttributeNS(o.paper.xlink,att,value);break;case"cursor":node.style.cursor=value;break;case"clip-rect":var rect=(value+E)[split](separator);if(rect[length]==4){o.clip&&o.clip.parentNode.parentNode.removeChild(o.clip.parentNode);var el=$("clipPath"),rc=$("rect");el.id="r"+(R._id++)[toString](36);$(rc,{x:rect[0],y:rect[1],width:rect[2],height:rect[3]});el[appendChild](rc);o.paper.defs[appendChild](el);$(node,{"clip-path":"url(#"+el.id+")"});o.clip=rc;}
if(!value){var clip=doc.getElementById(node.getAttribute("clip-path")[rp](/(^url\(#|\)$)/g,E));clip&&clip.parentNode.removeChild(clip);$(node,{"clip-path":E});delete o.clip;}
break;case"path":if(value&&o.type=="path"){attrs.path=roundPath(pathToAbsolute(value));$(node,{d:attrs.path});}
break;case"width":node[setAttribute](att,value);if(attrs.fx){att="x";value=attrs.x;}else{break;}
case"x":if(attrs.fx){value=-attrs.x-(attrs.width||0);}
case"rx":if(att=="rx"&&o.type=="rect"){break;}
case"cx":rotxy&&(att=="x"||att=="cx")&&(rotxy[1]+=value-attrs[att]);node[setAttribute](att,round(value));o.pattern&&updatePosition(o);break;case"height":node[setAttribute](att,value);if(attrs.fy){att="y";value=attrs.y;}else{break;}
case"y":if(attrs.fy){value=-attrs.y-(attrs.height||0);}
case"ry":if(att=="ry"&&o.type=="rect"){break;}
case"cy":rotxy&&(att=="y"||att=="cy")&&(rotxy[2]+=value-attrs[att]);node[setAttribute](att,round(value));o.pattern&&updatePosition(o);break;case"r":if(o.type=="rect"){$(node,{rx:value,ry:value});}else{node[setAttribute](att,value);}
break;case"src":if(o.type=="image"){node.setAttributeNS(o.paper.xlink,"href",value);}
break;case"stroke-width":node.style.strokeWidth=value;node[setAttribute](att,value);if(attrs["stroke-dasharray"]){addDashes(o,attrs["stroke-dasharray"]);}
break;case"stroke-dasharray":addDashes(o,value);break;case"translation":var xy=(value+E)[split](separator);if(rotxy){rotxy[1]+=+xy[0];rotxy[2]+=+xy[1];}
translate.call(o,(+xy[0]+1||2)-1,(+xy[1]+1||2)-1);break;case"scale":var xy=(value+E)[split](separator);o.scale(+xy[0]||1,+xy[1]||+xy[0]||1,+xy[2]||null,+xy[3]||null);break;case"fill":var isURL=(value+E).match(ISURL);if(isURL){var el=$("pattern"),ig=$("image");el.id="r"+(R._id++)[toString](36);$(el,{x:0,y:0,patternUnits:"userSpaceOnUse"});$(ig,{x:0,y:0});ig.setAttributeNS(o.paper.xlink,"href",isURL[1]);el[appendChild](ig);var img=doc.createElement("img");img.style.cssText="position:absolute;left:-9999em;top-9999em";img.onload=function(){$(el,{width:this.offsetWidth,height:this.offsetHeight});$(ig,{width:this.offsetWidth,height:this.offsetHeight});doc.body.removeChild(this);paper.safari();};doc.body[appendChild](img);img.src=isURL[1];o.paper.defs[appendChild](el);node.style.fill="url(#"+el.id+")";$(node,{fill:"url(#"+el.id+")"});o.pattern=el;o.pattern&&updatePosition(o);break;}
if(!R.getRGB(value).error){delete params.gradient;delete attrs.gradient;!R.is(attrs.opacity,"undefined")&&R.is(params.opacity,"undefined")&&$(node,{opacity:attrs.opacity});!R.is(attrs["fill-opacity"],"undefined")&&R.is(params["fill-opacity"],"undefined")&&$(node,{"fill-opacity":attrs["fill-opacity"]});}else if((({circle:1,ellipse:1})[has](o.type)||(value+E).charAt()!="r")&&addGradientFill(node,value,o.paper)){attrs.gradient=value;attrs.fill="none";break;}
case"stroke":node[setAttribute](att,R.getRGB(value).hex);break;case"gradient":(({circle:1,ellipse:1})[has](o.type)||(value+E).charAt()!="r")&&addGradientFill(node,value,o.paper);break;case"opacity":case"fill-opacity":if(attrs.gradient){var gradient=doc.getElementById(node.getAttribute("fill")[rp](/^url\(#|\)$/g,E));if(gradient){var stops=gradient.getElementsByTagName("stop");stops[stops[length]-1][setAttribute]("stop-opacity",value);}
break;}
default:att=="font-size"&&(value=toInt(value,10)+"px");var cssrule=att[rp](/(\-.)/g,function(w){return upperCase.call(w.substring(1));});node.style[cssrule]=value;node[setAttribute](att,value);break;}}
tuneText(o,params);if(rotxy){o.rotate(rotxy.join(S));}else{toFloat(rot)&&o.rotate(rot,true);}};var leading=1.2;var tuneText=function(el,params){if(el.type!="text"||!(params[has]("text")||params[has]("font")||params[has]("font-size")||params[has]("x")||params[has]("y"))){return;}
var a=el.attrs,node=el.node,fontSize=node.firstChild?toInt(doc.defaultView.getComputedStyle(node.firstChild,E).getPropertyValue("font-size"),10):10;if(params[has]("text")){a.text=params.text;while(node.firstChild){node.removeChild(node.firstChild);}
var texts=(params.text+E)[split]("\n");for(var i=0,ii=texts[length];i<ii;i++)if(texts[i]){var tspan=$("tspan");i&&$(tspan,{dy:fontSize*leading,x:a.x});tspan[appendChild](doc.createTextNode(texts[i]));node[appendChild](tspan);}}else{var texts=node.getElementsByTagName("tspan");for(var i=0,ii=texts[length];i<ii;i++){i&&$(texts[i],{dy:fontSize*leading,x:a.x});}}
$(node,{y:a.y});var bb=el.getBBox(),dif=a.y-(bb.y+bb.height/2);dif&&isFinite(dif)&&$(node,{y:a.y+dif});};var Element=function(node,svg){var X=0,Y=0;this[0]=node;this.id=R._oid++;this.node=node;node.raphael=this;this.paper=svg;this.attrs=this.attrs||{};this.transformations=[];this._={tx:0,ty:0,rt:{deg:0,cx:0,cy:0},sx:1,sy:1};!svg.bottom&&(svg.bottom=this);this.prev=svg.top;svg.top&&(svg.top.next=this);svg.top=this;this.next=null;};Element[proto].rotate=function(deg,cx,cy){if(this.removed){return this;}
if(deg==null){if(this._.rt.cx){return[this._.rt.deg,this._.rt.cx,this._.rt.cy][join](S);}
return this._.rt.deg;}
var bbox=this.getBBox();deg=(deg+E)[split](separator);if(deg[length]-1){cx=toFloat(deg[1]);cy=toFloat(deg[2]);}
deg=toFloat(deg[0]);if(cx!=null){this._.rt.deg=deg;}else{this._.rt.deg+=deg;}
(cy==null)&&(cx=null);this._.rt.cx=cx;this._.rt.cy=cy;cx=cx==null?bbox.x+bbox.width/2:cx;cy=cy==null?bbox.y+bbox.height/2:cy;if(this._.rt.deg){this.transformations[0]=R.format("rotate({0} {1} {2})",this._.rt.deg,cx,cy);this.clip&&$(this.clip,{transform:R.format("rotate({0} {1} {2})",-this._.rt.deg,cx,cy)});}else{this.transformations[0]=E;this.clip&&$(this.clip,{transform:E});}
$(this.node,{transform:this.transformations[join](S)});return this;};Element[proto].hide=function(){!this.removed&&(this.node.style.display="none");return this;};Element[proto].show=function(){!this.removed&&(this.node.style.display="");return this;};Element[proto].remove=function(){if(this.removed){return;}
tear(this,this.paper);this.node.parentNode.removeChild(this.node);for(var i in this){delete this[i];}
this.removed=true;};Element[proto].getBBox=function(){if(this.removed){return this;}
if(this.type=="path"){return pathDimensions(this.attrs.path);}
if(this.node.style.display=="none"){this.show();var hide=true;}
var bbox={};try{bbox=this.node.getBBox();}catch(e){}finally{bbox=bbox||{};}
if(this.type=="text"){bbox={x:bbox.x,y:Infinity,width:0,height:0};for(var i=0,ii=this.node.getNumberOfChars();i<ii;i++){var bb=this.node.getExtentOfChar(i);(bb.y<bbox.y)&&(bbox.y=bb.y);(bb.y+bb.height-bbox.y>bbox.height)&&(bbox.height=bb.y+bb.height-bbox.y);(bb.x+bb.width-bbox.x>bbox.width)&&(bbox.width=bb.x+bb.width-bbox.x);}}
hide&&this.hide();return bbox;};Element[proto].attr=function(){if(this.removed){return this;}
if(arguments[length]==0){var res={};for(var i in this.attrs)if(this.attrs[has](i)){res[i]=this.attrs[i];}
return res;}
if(arguments[length]==1&&R.is(arguments[0],"string")){if(arguments[0]=="translation"){return translate.call(this);}
if(arguments[0]=="rotation"){return this.rotate();}
if(arguments[0]=="scale"){return this.scale();}
return this.attrs[arguments[0]];}
if(arguments[length]==1&&R.is(arguments[0],"array")){var values={};for(var j in arguments[0])if(arguments[0][has](j)){values[arguments[0][j]]=this.attrs[arguments[0][j]];}
return values;}
if(arguments[length]==2){var params={};params[arguments[0]]=arguments[1];setFillAndStroke(this,params);}else if(arguments[length]==1&&R.is(arguments[0],"object")){setFillAndStroke(this,arguments[0]);}
return this;};Element[proto].toFront=function(){if(this.removed){return this;}
this.node.parentNode[appendChild](this.node);var svg=this.paper;svg.top!=this&&tofront(this,svg);return this;};Element[proto].toBack=function(){if(this.removed){return this;}
if(this.node.parentNode.firstChild!=this.node){this.node.parentNode.insertBefore(this.node,this.node.parentNode.firstChild);toback(this,this.paper);var svg=this.paper;}
return this;};Element[proto].insertAfter=function(element){if(this.removed){return this;}
var svg=this.paper,node=element.node;if(node.nextSibling){node.parentNode.insertBefore(this.node,node.nextSibling);}else{node.parentNode[appendChild](this.node);}
insertafter(this,element,this.paper);return this;};Element[proto].insertBefore=function(element){if(this.removed){return this;}
var node=element.node;node.parentNode.insertBefore(this.node,node);insertbefore(this,element,this.paper);return this;};var theCircle=function(svg,x,y,r){x=round(x);y=round(y);var el=$("circle");svg.canvas&&svg.canvas[appendChild](el);var res=new Element(el,svg);res.attrs={cx:x,cy:y,r:r,fill:"none",stroke:"#000"};res.type="circle";$(el,res.attrs);return res;};var theRect=function(svg,x,y,w,h,r){x=round(x);y=round(y);var el=$("rect");svg.canvas&&svg.canvas[appendChild](el);var res=new Element(el,svg);res.attrs={x:x,y:y,width:w,height:h,r:r||0,rx:r||0,ry:r||0,fill:"none",stroke:"#000"};res.type="rect";$(el,res.attrs);return res;};var theEllipse=function(svg,x,y,rx,ry){x=round(x);y=round(y);var el=$("ellipse");svg.canvas&&svg.canvas[appendChild](el);var res=new Element(el,svg);res.attrs={cx:x,cy:y,rx:rx,ry:ry,fill:"none",stroke:"#000"};res.type="ellipse";$(el,res.attrs);return res;};var theImage=function(svg,src,x,y,w,h){var el=$("image");$(el,{x:x,y:y,width:w,height:h,preserveAspectRatio:"none"});el.setAttributeNS(svg.xlink,"href",src);svg.canvas&&svg.canvas[appendChild](el);var res=new Element(el,svg);res.attrs={x:x,y:y,width:w,height:h,src:src};res.type="image";return res;};var theText=function(svg,x,y,text){var el=$("text");$(el,{x:x,y:y,"text-anchor":"middle"});svg.canvas&&svg.canvas[appendChild](el);var res=new Element(el,svg);res.attrs={x:x,y:y,"text-anchor":"middle",text:text,font:availableAttrs.font,stroke:"none",fill:"#000"};res.type="text";setFillAndStroke(res,res.attrs);return res;};var setSize=function(width,height){this.width=width||this.width;this.height=height||this.height;this.canvas[setAttribute]("width",this.width);this.canvas[setAttribute]("height",this.height);return this;};var create=function(){var con=getContainer[apply](null,arguments),container=con&&con.container,x=con.x,y=con.y,width=con.width,height=con.height;if(!container){throw new Error("SVG container not found.");}
paper.canvas=$("svg");var cnvs=paper.canvas;paper.width=width||512;paper.height=height||342;cnvs[setAttribute]("width",paper.width);cnvs[setAttribute]("height",paper.height);if(container==1){cnvs.style.cssText="position:absolute;left:"+x+"px;top:"+y+"px";doc.body[appendChild](cnvs);}else{if(container.firstChild){container.insertBefore(cnvs,container.firstChild);}else{container[appendChild](cnvs);}}
container={canvas:cnvs};for(var prop in paper)if(paper[has](prop)){container[prop]=paper[prop];}
container.bottom=container.top=null;plugins.call(container,container,R.fn);container.clear();container.raphael=R;return container;};paper.clear=function(){var c=this.canvas;while(c.firstChild){c.removeChild(c.firstChild);}
this.bottom=this.top=null;(this.desc=$("desc"))[appendChild](doc.createTextNode("Created with Rapha\xebl"));c[appendChild](this.desc);c[appendChild](this.defs=$("defs"));};paper.remove=function(){this.canvas.parentNode&&this.canvas.parentNode.removeChild(this.canvas);for(var i in this){delete this[i];}};}
if(R.vml){var path2vml=function(path){var total=/[ahqtv]/ig,command=pathToAbsolute;(path+E).match(total)&&(command=path2curve);total=/[clmz]/g;if(command==pathToAbsolute&&!(path+E).match(total)){var map={M:"m",L:"l",C:"c",Z:"x",m:"t",l:"r",c:"v",z:"x"},bites=/([clmz]),?([^clmz]*)/gi,val=/-?[^,\s-]+/g;var res=(path+E)[rp](bites,function(all,command,args){var vals=[];args[rp](val,function(value){vals[push](round(value));});return map[command]+vals;});return res;}
var pa=command(path),p,res=[],r;for(var i=0,ii=pa[length];i<ii;i++){p=pa[i];r=lowerCase.call(pa[i][0]);r=="z"&&(r="x");for(var j=1,jj=p[length];j<jj;j++){r+=round(p[j])+(j!=jj-1?",":E);}
res[push](r);}
return res[join](S);};R[toString]=function(){return"Your browser doesn\u2019t support SVG. Falling down to VML.\nYou are running Rapha\xebl "+this.version;};var thePath=function(pathString,VML){var g=createNode("group");g.style.cssText="position:absolute;left:0;top:0;width:"+VML.width+"px;height:"+VML.height+"px";g.coordsize=VML.coordsize;g.coordorigin=VML.coordorigin;var el=createNode("shape"),ol=el.style;ol.width=VML.width+"px";ol.height=VML.height+"px";el.coordsize=this.coordsize;el.coordorigin=this.coordorigin;g[appendChild](el);var p=new Element(el,g,VML);p.isAbsolute=true;p.type="path";p.path=[];p.Path=E;pathString&&setFillAndStroke(p,{fill:"none",stroke:"#000",path:pathString});VML.canvas[appendChild](g);return p;};var setFillAndStroke=function(o,params){o.attrs=o.attrs||{};var node=o.node,a=o.attrs,s=node.style,xy,res=o;for(var par in params)if(params[has](par)){a[par]=params[par];}
params.href&&(node.href=params.href);params.title&&(node.title=params.title);params.target&&(node.target=params.target);params.cursor&&(s.cursor=params.cursor);if(params.path&&o.type=="path"){a.path=params.path;node.path=path2vml(a.path);}
if(params.rotation!=null){o.rotate(params.rotation,true);}
if(params.translation){xy=(params.translation+E)[split](separator);translate.call(o,xy[0],xy[1]);if(o._.rt.cx!=null){o._.rt.cx+=+xy[0];o._.rt.cy+=+xy[1];o.setBox(o.attrs,xy[0],xy[1]);}}
if(params.scale){xy=(params.scale+E)[split](separator);o.scale(+xy[0]||1,+xy[1]||+xy[0]||1,+xy[2]||null,+xy[3]||null);}
if("clip-rect"in params){var rect=(params["clip-rect"]+E)[split](separator);if(rect[length]==4){rect[2]=+rect[2]+(+rect[0]);rect[3]=+rect[3]+(+rect[1]);var div=node.clipRect||doc.createElement("div"),dstyle=div.style,group=node.parentNode;dstyle.clip=R.format("rect({1}px {2}px {3}px {0}px)",rect);if(!node.clipRect){dstyle.position="absolute";dstyle.top=0;dstyle.left=0;dstyle.width=o.paper.width+"px";dstyle.height=o.paper.height+"px";group.parentNode.insertBefore(div,group);div[appendChild](group);node.clipRect=div;}}
if(!params["clip-rect"]){node.clipRect&&(node.clipRect.style.clip=E);}}
if(o.type=="image"&&params.src){node.src=params.src;}
if(o.type=="image"&&params.opacity){node.filterOpacity=" progid:DXImageTransform.Microsoft.Alpha(opacity="+(params.opacity*100)+")";s.filter=(node.filterMatrix||E)+(node.filterOpacity||E);}
params.font&&(s.font=params.font);params["font-family"]&&(s.fontFamily='"'+params["font-family"][split](",")[0][rp](/^['"]+|['"]+$/g,E)+'"');params["font-size"]&&(s.fontSize=params["font-size"]);params["font-weight"]&&(s.fontWeight=params["font-weight"]);params["font-style"]&&(s.fontStyle=params["font-style"]);if(params.opacity!=null||params["stroke-width"]!=null||params.fill!=null||params.stroke!=null||params["stroke-width"]!=null||params["stroke-opacity"]!=null||params["fill-opacity"]!=null||params["stroke-dasharray"]!=null||params["stroke-miterlimit"]!=null||params["stroke-linejoin"]!=null||params["stroke-linecap"]!=null){node=o.shape||node;var fill=(node.getElementsByTagName("fill")&&node.getElementsByTagName("fill")[0]),newfill=false;!fill&&(newfill=fill=createNode("fill"));if("fill-opacity"in params||"opacity"in params){var opacity=((+a["fill-opacity"]+1||2)-1)*((+a.opacity+1||2)-1);opacity<0&&(opacity=0);opacity>1&&(opacity=1);fill.opacity=opacity;}
params.fill&&(fill.on=true);if(fill.on==null||params.fill=="none"){fill.on=false;}
if(fill.on&&params.fill){var isURL=params.fill.match(ISURL);if(isURL){fill.src=isURL[1];fill.type="tile";}else{fill.color=R.getRGB(params.fill).hex;fill.src=E;fill.type="solid";if(R.getRGB(params.fill).error&&(res.type in{circle:1,ellipse:1}||(params.fill+E).charAt()!="r")&&addGradientFill(res,params.fill)){a.fill="none";a.gradient=params.fill;}}}
newfill&&node[appendChild](fill);var stroke=(node.getElementsByTagName("stroke")&&node.getElementsByTagName("stroke")[0]),newstroke=false;!stroke&&(newstroke=stroke=createNode("stroke"));if((params.stroke&&params.stroke!="none")||params["stroke-width"]||params["stroke-opacity"]!=null||params["stroke-dasharray"]||params["stroke-miterlimit"]||params["stroke-linejoin"]||params["stroke-linecap"]){stroke.on=true;}
(params.stroke=="none"||stroke.on==null||params.stroke==0||params["stroke-width"]==0)&&(stroke.on=false);stroke.on&&params.stroke&&(stroke.color=R.getRGB(params.stroke).hex);var opacity=((+a["stroke-opacity"]+1||2)-1)*((+a.opacity+1||2)-1),width=(toFloat(params["stroke-width"])||1)*.75;opacity<0&&(opacity=0);opacity>1&&(opacity=1);params["stroke-width"]==null&&(width=a["stroke-width"]);params["stroke-width"]&&(stroke.weight=width);width&&width<1&&(opacity*=width)&&(stroke.weight=1);stroke.opacity=opacity;params["stroke-linejoin"]&&(stroke.joinstyle=params["stroke-linejoin"]||"miter");stroke.miterlimit=params["stroke-miterlimit"]||8;params["stroke-linecap"]&&(stroke.endcap=params["stroke-linecap"]=="butt"?"flat":params["stroke-linecap"]=="square"?"square":"round");if(params["stroke-dasharray"]){var dasharray={"-":"shortdash",".":"shortdot","-.":"shortdashdot","-..":"shortdashdotdot",". ":"dot","- ":"dash","--":"longdash","- .":"dashdot","--.":"longdashdot","--..":"longdashdotdot"};stroke.dashstyle=dasharray[has](params["stroke-dasharray"])?dasharray[params["stroke-dasharray"]]:E;}
newstroke&&node[appendChild](stroke);}
if(res.type=="text"){var s=res.paper.span.style;a.font&&(s.font=a.font);a["font-family"]&&(s.fontFamily=a["font-family"]);a["font-size"]&&(s.fontSize=a["font-size"]);a["font-weight"]&&(s.fontWeight=a["font-weight"]);a["font-style"]&&(s.fontStyle=a["font-style"]);res.node.string&&(res.paper.span.innerHTML=(res.node.string+E)[rp](/</g,"&#60;")[rp](/&/g,"&#38;")[rp](/\n/g,"<br>"));res.W=a.w=res.paper.span.offsetWidth;res.H=a.h=res.paper.span.offsetHeight;res.X=a.x;res.Y=a.y+round(res.H/2);switch(a["text-anchor"]){case"start":res.node.style["v-text-align"]="left";res.bbx=round(res.W/2);break;case"end":res.node.style["v-text-align"]="right";res.bbx=-round(res.W/2);break;default:res.node.style["v-text-align"]="center";break;}}};var addGradientFill=function(o,gradient){o.attrs=o.attrs||{};var attrs=o.attrs,fill=o.node.getElementsByTagName("fill"),type="linear",fxfy=".5 .5";o.attrs.gradient=gradient;gradient=(gradient+E)[rp](/^r(?:\(([^,]+?)\s*,\s*([^\)]+?)\))?/,function(all,fx,fy){type="radial";if(fx&&fy){fx=toFloat(fx);fy=toFloat(fy);if(pow(fx-.5,2)+pow(fy-.5,2)>.25){fy=Math.sqrt(.25-pow(fx-.5,2))+.5;}
fxfy=fx+S+fy;}
return E;});gradient=gradient[split](/\s*\-\s*/);if(type=="linear"){var angle=gradient.shift();angle=-toFloat(angle);if(isNaN(angle)){return null;}}
var dots=parseDots(gradient);if(!dots){return null;}
o=o.shape||o.node;fill=fill[0]||createNode("fill");if(dots[length]){fill.on=true;fill.method="none";fill.type=(type=="radial")?"gradientradial":"gradient";fill.color=dots[0].color;fill.color2=dots[dots[length]-1].color;var clrs=[];for(var i=0,ii=dots[length];i<ii;i++){dots[i].offset&&clrs[push](dots[i].offset+S+dots[i].color);}
fill.colors.value=clrs[length]?clrs[join](","):"0% "+fill.color;if(type=="radial"){fill.focus="100%";fill.focussize=fxfy;fill.focusposition=fxfy;}else{fill.angle=(270-angle)%360;}}
return 1;};var Element=function(node,group,vml){var Rotation=0,RotX=0,RotY=0,Scale=1;this[0]=node;this.id=R._oid++;this.node=node;node.raphael=this;this.X=0;this.Y=0;this.attrs={};this.Group=group;this.paper=vml;this._={tx:0,ty:0,rt:{deg:0},sx:1,sy:1};!vml.bottom&&(vml.bottom=this);this.prev=vml.top;vml.top&&(vml.top.next=this);vml.top=this;this.next=null;};Element[proto].rotate=function(deg,cx,cy){if(this.removed){return this;}
if(deg==null){if(this._.rt.cx){return[this._.rt.deg,this._.rt.cx,this._.rt.cy][join](S);}
return this._.rt.deg;}
deg=(deg+E)[split](separator);if(deg[length]-1){cx=toFloat(deg[1]);cy=toFloat(deg[2]);}
deg=toFloat(deg[0]);if(cx!=null){this._.rt.deg=deg;}else{this._.rt.deg+=deg;}
cy==null&&(cx=null);this._.rt.cx=cx;this._.rt.cy=cy;this.setBox(this.attrs,cx,cy);this.Group.style.rotation=this._.rt.deg;return this;};Element[proto].setBox=function(params,cx,cy){if(this.removed){return this;}
var gs=this.Group.style,os=(this.shape&&this.shape.style)||this.node.style;params=params||{};for(var i in params)if(params[has](i)){this.attrs[i]=params[i];}
cx=cx||this._.rt.cx;cy=cy||this._.rt.cy;var attr=this.attrs,x,y,w,h;switch(this.type){case"circle":x=attr.cx-attr.r;y=attr.cy-attr.r;w=h=attr.r*2;break;case"ellipse":x=attr.cx-attr.rx;y=attr.cy-attr.ry;w=attr.rx*2;h=attr.ry*2;break;case"rect":case"image":x=+attr.x;y=+attr.y;w=attr.width||0;h=attr.height||0;break;case"text":this.textpath.v=["m",round(attr.x),", ",round(attr.y-2),"l",round(attr.x)+1,", ",round(attr.y-2)][join](E);x=attr.x-round(this.W/2);y=attr.y-this.H/2;w=this.W;h=this.H;break;case"path":if(!this.attrs.path){x=0;y=0;w=this.paper.width;h=this.paper.height;}else{var dim=pathDimensions(this.attrs.path);x=dim.x;y=dim.y;w=dim.width;h=dim.height;}
break;default:x=0;y=0;w=this.paper.width;h=this.paper.height;break;}
cx=(cx==null)?x+w/2:cx;cy=(cy==null)?y+h/2:cy;var left=cx-this.paper.width/2,top=cy-this.paper.height/2;if(this.type=="path"||this.type=="text"){(gs.left!=left+"px")&&(gs.left=left+"px");(gs.top!=top+"px")&&(gs.top=top+"px");this.X=this.type=="text"?x:-left;this.Y=this.type=="text"?y:-top;this.W=w;this.H=h;(os.left!=-left+"px")&&(os.left=-left+"px");(os.top!=-top+"px")&&(os.top=-top+"px");}else{(gs.left!=left+"px")&&(gs.left=left+"px");(gs.top!=top+"px")&&(gs.top=top+"px");this.X=x;this.Y=y;this.W=w;this.H=h;(gs.width!=this.paper.width+"px")&&(gs.width=this.paper.width+"px");(gs.height!=this.paper.height+"px")&&(gs.height=this.paper.height+"px");(os.left!=x-left+"px")&&(os.left=x-left+"px");(os.top!=y-top+"px")&&(os.top=y-top+"px");(os.width!=w+"px")&&(os.width=w+"px");(os.height!=h+"px")&&(os.height=h+"px");var arcsize=(+params.r||0)/(mmin(w,h));if(this.type=="rect"&&this.arcsize!=arcsize&&(arcsize||this.arcsize)){var o=createNode(arcsize?"roundrect":"rect");o.arcsize=arcsize;this.Group[appendChild](o);this.node.parentNode.removeChild(this.node);this.node=o;this.arcsize=arcsize;this.attr(this.attrs);}}};Element[proto].hide=function(){!this.removed&&(this.Group.style.display="none");return this;};Element[proto].show=function(){!this.removed&&(this.Group.style.display="block");return this;};Element[proto].getBBox=function(){if(this.removed){return this;}
if(this.type=="path"){return pathDimensions(this.attrs.path);}
return{x:this.X+(this.bbx||0),y:this.Y,width:this.W,height:this.H};};Element[proto].remove=function(){if(this.removed){return;}
tear(this,this.paper);this.node.parentNode.removeChild(this[0]);this.Group.parentNode.removeChild(this.Group);this.shape&&this.shape.parentNode.removeChild(this.shape);for(var i in this){delete this[i];}
this.removed=true;};Element[proto].attr=function(){if(this.removed){return this;}
if(arguments[length]==0){var res={};for(var i in this.attrs)if(this.attrs[has](i)){res[i]=this.attrs[i];}
return res;}
if(arguments[length]==1&&R.is(arguments[0],"string")){if(arguments[0]=="translation"){return translate.call(this);}
if(arguments[0]=="rotation"){return this.rotate();}
if(arguments[0]=="scale"){return this.scale();}
return this.attrs[arguments[0]];}
if(this.attrs&&arguments[length]==1&&R.is(arguments[0],"array")){var values={};for(var i=0,ii=arguments[0][length];i<ii;i++){values[arguments[0][i]]=this.attrs[arguments[0][i]];};return values;}
var params;if(arguments[length]==2){params={};params[arguments[0]]=arguments[1];}
arguments[length]==1&&R.is(arguments[0],"object")&&(params=arguments[0]);if(params){if(params.text&&this.type=="text"){this.node.string=params.text;}
setFillAndStroke(this,params);if(params.gradient&&(({circle:1,ellipse:1})[has](this.type)||(params.gradient+E).charAt()!="r")){addGradientFill(this,params.gradient);}
(this.type!="path"||this._.rt.deg)&&this.setBox(this.attrs);}
return this;};Element[proto].toFront=function(){!this.removed&&this.Group.parentNode[appendChild](this.Group);this.paper.top!=this&&tofront(this,this.paper);return this;};Element[proto].toBack=function(){if(this.removed){return this;}
if(this.Group.parentNode.firstChild!=this.Group){this.Group.parentNode.insertBefore(this.Group,this.Group.parentNode.firstChild);toback(this,this.paper);}
return this;};Element[proto].insertAfter=function(element){if(this.removed){return this;}
if(element.Group.nextSibling){element.Group.parentNode.insertBefore(this.Group,element.Group.nextSibling);}else{element.Group.parentNode[appendChild](this.Group);}
insertafter(this,element,this.paper);return this;};Element[proto].insertBefore=function(element){if(this.removed){return this;}
element.Group.parentNode.insertBefore(this.Group,element.Group);insertbefore(this,element,this.paper);return this;};var theCircle=function(vml,x,y,r){var g=createNode("group"),o=createNode("oval"),ol=o.style;g.style.cssText="position:absolute;left:0;top:0;width:"+vml.width+"px;height:"+vml.height+"px";g.coordsize=vml.coordsize;g.coordorigin=vml.coordorigin;g[appendChild](o);var res=new Element(o,g,vml);res.type="circle";setFillAndStroke(res,{stroke:"#000",fill:"none"});res.attrs.cx=x;res.attrs.cy=y;res.attrs.r=r;res.setBox({x:x-r,y:y-r,width:r*2,height:r*2});vml.canvas[appendChild](g);return res;};var theRect=function(vml,x,y,w,h,r){var g=createNode("group"),o=createNode(r?"roundrect":"rect"),arcsize=(+r||0)/(mmin(w,h));o.arcsize=arcsize;g.style.cssText="position:absolute;left:0;top:0;width:"+vml.width+"px;height:"+vml.height+"px";g.coordsize=vml.coordsize;g.coordorigin=vml.coordorigin;g[appendChild](o);var res=new Element(o,g,vml);res.type="rect";setFillAndStroke(res,{stroke:"#000"});res.arcsize=arcsize;res.setBox({x:x,y:y,width:w,height:h,r:+r});vml.canvas[appendChild](g);return res;};var theEllipse=function(vml,x,y,rx,ry){var g=createNode("group"),o=createNode("oval"),ol=o.style;g.style.cssText="position:absolute;left:0;top:0;width:"+vml.width+"px;height:"+vml.height+"px";g.coordsize=vml.coordsize;g.coordorigin=vml.coordorigin;g[appendChild](o);var res=new Element(o,g,vml);res.type="ellipse";setFillAndStroke(res,{stroke:"#000"});res.attrs.cx=x;res.attrs.cy=y;res.attrs.rx=rx;res.attrs.ry=ry;res.setBox({x:x-rx,y:y-ry,width:rx*2,height:ry*2});vml.canvas[appendChild](g);return res;};var theImage=function(vml,src,x,y,w,h){var g=createNode("group"),o=createNode("image"),ol=o.style;g.style.cssText="position:absolute;left:0;top:0;width:"+vml.width+"px;height:"+vml.height+"px";g.coordsize=vml.coordsize;g.coordorigin=vml.coordorigin;o.src=src;g[appendChild](o);var res=new Element(o,g,vml);res.type="image";res.attrs.src=src;res.attrs.x=x;res.attrs.y=y;res.attrs.w=w;res.attrs.h=h;res.setBox({x:x,y:y,width:w,height:h});vml.canvas[appendChild](g);return res;};var theText=function(vml,x,y,text){var g=createNode("group"),el=createNode("shape"),ol=el.style,path=createNode("path"),ps=path.style,o=createNode("textpath");g.style.cssText="position:absolute;left:0;top:0;width:"+vml.width+"px;height:"+vml.height+"px";g.coordsize=vml.coordsize;g.coordorigin=vml.coordorigin;path.v=R.format("m{0},{1}l{2},{1}",round(x),round(y),round(x)+1);path.textpathok=true;ol.width=vml.width;ol.height=vml.height;o.string=text+E;o.on=true;el[appendChild](o);el[appendChild](path);g[appendChild](el);var res=new Element(o,g,vml);res.shape=el;res.textpath=path;res.type="text";res.attrs.text=text;res.attrs.x=x;res.attrs.y=y;res.attrs.w=1;res.attrs.h=1;setFillAndStroke(res,{font:availableAttrs.font,stroke:"none",fill:"#000"});res.setBox();vml.canvas[appendChild](g);return res;};var setSize=function(width,height){var cs=this.canvas.style;this.width=toFloat(width||this.width);this.height=toFloat(height||this.height);cs.width=this.width+"px";cs.height=this.height+"px";cs.clip="rect(0 "+this.width+"px "+this.height+"px 0)";this.coordsize=this.width+S+this.height;var bot=this.bottom;while(bot){bot.Group.coordsize=this.coordsize;bot.attr(bot.attrs);bot=bot.next;}
return this;};doc.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{!doc.namespaces.rvml&&doc.namespaces.add("rvml","urn:schemas-microsoft-com:vml");var createNode=function(tagName){return doc.createElement('<rvml:'+tagName+' class="rvml">');};}catch(e){var createNode=function(tagName){return doc.createElement('<'+tagName+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">');};}
var create=function(){var con=getContainer[apply](null,arguments),container=con.container,height=con.height,s,width=con.width,x=con.x,y=con.y;if(!container){throw new Error("VML container not found.");}
var res={},c=res.canvas=doc.createElement("div"),cs=c.style;width=toFloat(width)||512;height=toFloat(height)||342;res.width=width;res.height=height;res.coordsize=width+S+height;res.coordorigin="0 0";res.span=doc.createElement("span");res.span.style.cssText="position:absolute;left:-9999px;top:-9999px;padding:0;margin:0;line-height:1;display:inline;";c[appendChild](res.span);cs.cssText=R.format("width:{0}px;height:{1}px;position:absolute;clip:rect(0 {0}px {1}px 0)",width,height);if(container==1){doc.body[appendChild](c);cs.left=x+"px";cs.top=y+"px";container={style:{width:width,height:height}};}else{container.style.width=width;container.style.height=height;if(container.firstChild){container.insertBefore(c,container.firstChild);}else{container[appendChild](c);}}
for(var prop in paper)if(paper[has](prop)){res[prop]=paper[prop];}
plugins.call(res,res,R.fn);res.top=res.bottom=null;res.raphael=R;return res;};paper.clear=function(){this.canvas.innerHTML=E;this.bottom=this.top=null;};paper.remove=function(){this.canvas.parentNode.removeChild(this.canvas);for(var i in this){delete this[i];}};}
if({"Apple Computer, Inc.":1,"Google Inc.":1}[navigator.vendor]&&!(navigator.userAgent.indexOf("Version/4.0")+1)){paper.safari=function(){var rect=this.rect(-99,-99,this.width+99,this.height+99);setTimeout(function(){rect.remove();});};}else{paper.safari=function(){};}
var addEvent=(function(){if(doc.addEventListener){return function(obj,type,fn,element){var f=function(e){return fn.call(element,e);};obj.addEventListener(type,f,false);return function(){obj.removeEventListener(type,f,false);return true;};};}else if(doc.attachEvent){return function(obj,type,fn,element){var f=function(e){return fn.call(element,e||win.event);};obj.attachEvent("on"+type,f);var detacher=function(){obj.detachEvent("on"+type,f);return true;};if(type=="mouseover"){obj.attachEvent("onmouseenter",f);return function(){obj.detachEvent("onmouseenter",f);return detacher();};}else if(type=="mouseout"){obj.attachEvent("onmouseleave",f);return function(){obj.detachEvent("onmouseleave",f);return detacher();};}
return detacher;};}})();for(var i=events[length];i--;){(function(eventName){Element[proto][eventName]=function(fn){if(R.is(fn,"function")){this.events=this.events||{};this.events[eventName]=this.events[eventName]||{};this.events[eventName][fn]=this.events[eventName][fn]||[];this.events[eventName][fn][push](addEvent(this.shape||this.node,eventName,fn,this));}
return this;};Element[proto]["un"+eventName]=function(fn){var e=this.events;e&&e[eventName]&&e[eventName][fn]&&e[eventName][fn][length]&&e[eventName][fn].shift()()&&!e[eventName][fn][length]&&delete e[eventName][fn];return this;};})(events[i]);}
Element[proto].hover=function(f_in,f_out){return this.mouseover(f_in).mouseout(f_out);};paper.circle=function(x,y,r){return theCircle(this,x||0,y||0,r||0);};paper.rect=function(x,y,w,h,r){return theRect(this,x||0,y||0,w||0,h||0,r||0);};paper.ellipse=function(x,y,rx,ry){return theEllipse(this,x||0,y||0,rx||0,ry||0);};paper.path=function(pathString){pathString&&!R.is(pathString,"string")&&!R.is(pathString[0],"array")&&(pathString+=E);return thePath(R.format[apply](R,arguments),this);};paper.image=function(src,x,y,w,h){return theImage(this,src||"about:blank",x||0,y||0,w||0,h||0);};paper.text=function(x,y,text){return theText(this,x||0,y||0,text||E);};paper.set=function(itemsArray){arguments[length]>1&&(itemsArray=Array[proto].splice.call(arguments,0,arguments[length]));return new Set(itemsArray);};paper.setSize=setSize;Element[proto].scale=function(x,y,cx,cy){if(x==null&&y==null){return{x:this._.sx,y:this._.sy,toString:function(){return this.x+S+this.y;}};}
y=y||x;!+y&&(y=x);var dx,dy,dcx,dcy,a=this.attrs;if(x!=0){var bb=this.getBBox(),rcx=bb.x+bb.width/2,rcy=bb.y+bb.height/2,kx=x/this._.sx,ky=y/this._.sy;cx=(+cx||cx==0)?cx:rcx;cy=(+cy||cy==0)?cy:rcy;var dirx=~~(x/Math.abs(x)),diry=~~(y/Math.abs(y)),s=this.node.style,ncx=cx+(rcx-cx)*kx,ncy=cy+(rcy-cy)*ky;switch(this.type){case"rect":case"image":var neww=a.width*dirx*kx,newh=a.height*diry*ky,newr=a.r*mmin(kx,ky),newx=ncx-neww/2,newy=ncy-newh/2;this.attr({width:neww,height:newh,x:newx,y:newy,r:newr});break;case"circle":case"ellipse":this.attr({rx:a.rx*dirx*kx,ry:a.ry*diry*ky,r:a.r*mmin(dirx*kx,diry*ky),cx:ncx,cy:ncy});break;case"path":var path=pathToRelative(a.path),skip=true;for(var i=0,ii=path[length];i<ii;i++){var p=path[i],j,P0=upperCase.call(p[0]);if(P0=="M"&&skip){continue;}else{skip=false;}
if(R.svg&&P0=="A"){p[path[i][length]-2]*=kx;p[path[i][length]-1]*=ky;p[1]*=dirx*kx;p[2]*=diry*ky;p[5]=+(dirx+diry?!!+p[5]:!+p[5]);}else if(P0=="H"){for(j=1,jj=p[length];j<jj;j++){p[j]*=kx;}}else if(P0=="V"){for(j=1,jj=p[length];j<jj;j++){p[j]*=ky;}}else{for(j=1,jj=p[length];j<jj;j++){p[j]*=(j%2)?kx:ky;}}}
var dim2=pathDimensions(path),dx=ncx-dim2.x-dim2.width/2,dy=ncy-dim2.y-dim2.height/2;path[0][1]+=dx;path[0][2]+=dy;this.attr({path:path});break;}
if(this.type in{text:1,image:1}&&(dirx!=1||diry!=1)){if(this.transformations){this.transformations[2]="scale("[concat](dirx,",",diry,")");this.node[setAttribute]("transform",this.transformations[join](S));dx=(dirx==-1)?-a.x-(neww||0):a.x;dy=(diry==-1)?-a.y-(newh||0):a.y;this.attr({x:dx,y:dy});a.fx=dirx-1;a.fy=diry-1;}else{this.node.filterMatrix=" progid:DXImageTransform.Microsoft.Matrix(M11="[concat](dirx,", M12=0, M21=0, M22=",diry,", Dx=0, Dy=0, sizingmethod='auto expand', filtertype='bilinear')");s.filter=(this.node.filterMatrix||E)+(this.node.filterOpacity||E);}}else{if(this.transformations){this.transformations[2]=E;this.node[setAttribute]("transform",this.transformations[join](S));a.fx=0;a.fy=0;}else{this.node.filterMatrix=E;s.filter=(this.node.filterMatrix||E)+(this.node.filterOpacity||E);}}
a.scale=[x,y,cx,cy][join](S);this._.sx=x;this._.sy=y;}
return this;};R.easing_formulas={linear:function(n){return n;},"<":function(n){return pow(n,3);},">":function(n){return pow(n-1,3)+1;},"<>":function(n){n=n*2;if(n<1){return pow(n,3)/2;}
n-=2;return(pow(n,3)+2)/2;},backIn:function(n){var s=1.70158;return n*n*((s+1)*n-s);},backOut:function(n){n=n-1;var s=1.70158;return n*n*((s+1)*n+s)+1;},elastic:function(n){if(n==0||n==1){return n;}
var p=.3,s=p/4;return pow(2,-10*n)*Math.sin((n-s)*(2*Math.PI)/p)+1;},bounce:function(n){var s=7.5625,p=2.75,l;if(n<(1/p)){l=s*n*n;}else{if(n<(2/p)){n-=(1.5/p);l=s*n*n+.75;}else{if(n<(2.5/p)){n-=(2.25/p);l=s*n*n+.9375;}else{n-=(2.625/p);l=s*n*n+.984375;}}}
return l;}};var animationElements={length:0},animation=function(){var Now=+new Date;for(var l in animationElements)if(l!="length"&&animationElements[has](l)){var e=animationElements[l];if(e.stop){delete animationElements[l];animationElements[length]--;continue;}
var time=Now-e.start,ms=e.ms,easing=e.easing,from=e.from,diff=e.diff,to=e.to,t=e.t,prev=e.prev||0,that=e.el,callback=e.callback,set={},now;if(time<ms){var pos=R.easing_formulas[easing]?R.easing_formulas[easing](time/ms):time/ms;for(var attr in from)if(from[has](attr)){switch(availableAnimAttrs[attr]){case"number":now=+from[attr]+pos*ms*diff[attr];break;case"colour":now="rgb("+[upto255(round(from[attr].r+pos*ms*diff[attr].r)),upto255(round(from[attr].g+pos*ms*diff[attr].g)),upto255(round(from[attr].b+pos*ms*diff[attr].b))][join](",")+")";break;case"path":now=[];for(var i=0,ii=from[attr][length];i<ii;i++){now[i]=[from[attr][i][0]];for(var j=1,jj=from[attr][i][length];j<jj;j++){now[i][j]=+from[attr][i][j]+pos*ms*diff[attr][i][j];}
now[i]=now[i][join](S);}
now=now[join](S);break;case"csv":switch(attr){case"translation":var x=diff[attr][0]*(time-prev),y=diff[attr][1]*(time-prev);t.x+=x;t.y+=y;now=x+S+y;break;case"rotation":now=+from[attr][0]+pos*ms*diff[attr][0];from[attr][1]&&(now+=","+from[attr][1]+","+from[attr][2]);break;case"scale":now=[+from[attr][0]+pos*ms*diff[attr][0],+from[attr][1]+pos*ms*diff[attr][1],(2 in to[attr]?to[attr][2]:E),(3 in to[attr]?to[attr][3]:E)][join](S);break;case"clip-rect":now=[];var i=4;while(i--){now[i]=+from[attr][i]+pos*ms*diff[attr][i];}
break;}
break;}
set[attr]=now;}
that.attr(set);that._run&&that._run.call(that);}else{(t.x||t.y)&&that.translate(-t.x,-t.y);to.scale&&(to.scale=to.scale+E);that.attr(to);delete animationElements[l];animationElements[length]--;that.in_animation=null;R.is(callback,"function")&&callback.call(that);}
e.prev=time;}
R.svg&&paper.safari();animationElements[length]&&setTimeout(animation);},upto255=function(color){return color>255?255:(color<0?0:color);},translate=function(x,y){if(x==null){return{x:this._.tx,y:this._.ty};}
this._.tx+=+x;this._.ty+=+y;switch(this.type){case"circle":case"ellipse":this.attr({cx:+x+this.attrs.cx,cy:+y+this.attrs.cy});break;case"rect":case"image":case"text":this.attr({x:+x+this.attrs.x,y:+y+this.attrs.y});break;case"path":var path=pathToRelative(this.attrs.path);path[0][1]+=+x;path[0][2]+=+y;this.attr({path:path});break;}
return this;};Element[proto].animateWith=function(element,params,ms,easing,callback){animationElements[element.id]&&(params.start=animationElements[element.id].start);return this.animate(params,ms,easing,callback);};Element[proto].onAnimation=function(f){this._run=f||null;return this;};Element[proto].animate=function(params,ms,easing,callback){if(R.is(easing,"function")||!easing){callback=easing||null;}
var from={},to={},diff={};for(var attr in params)if(params[has](attr)){if(availableAnimAttrs[has](attr)){from[attr]=this.attr(attr);(from[attr]==null)&&(from[attr]=availableAttrs[attr]);to[attr]=params[attr];switch(availableAnimAttrs[attr]){case"number":diff[attr]=(to[attr]-from[attr])/ms;break;case"colour":from[attr]=R.getRGB(from[attr]);var toColour=R.getRGB(to[attr]);diff[attr]={r:(toColour.r-from[attr].r)/ms,g:(toColour.g-from[attr].g)/ms,b:(toColour.b-from[attr].b)/ms};break;case"path":var pathes=path2curve(from[attr],to[attr]);from[attr]=pathes[0];to[attr]=pathes[1];diff[attr]=[];for(var i=0,ii=from[attr][length];i<ii;i++){diff[attr][i]=[0];for(var j=1,jj=from[attr][i][length];j<jj;j++){diff[attr][i][j]=(to[attr][i][j]-from[attr][i][j])/ms;}}
break;case"csv":var values=(params[attr]+E)[split](separator),from2=(from[attr]+E)[split](separator);switch(attr){case"translation":from[attr]=[0,0];diff[attr]=[values[0]/ms,values[1]/ms];break;case"rotation":from[attr]=(from2[1]==values[1]&&from2[2]==values[2])?from2:[0,values[1],values[2]];diff[attr]=[(values[0]-from[attr][0])/ms,0,0];break;case"scale":params[attr]=values;from[attr]=(from[attr]+E)[split](separator);diff[attr]=[(values[0]-from[attr][0])/ms,(values[1]-from[attr][1])/ms,0,0];break;case"clip-rect":from[attr]=(from[attr]+E)[split](separator);diff[attr]=[];var i=4;while(i--){diff[attr][i]=(values[i]-from[attr][i])/ms;}
break;}
to[attr]=values;}}}
this.stop();this.in_animation=1;animationElements[this.id]={start:params.start||+new Date,ms:ms,easing:easing,from:from,diff:diff,to:to,el:this,callback:callback,t:{x:0,y:0}};++animationElements[length]==1&&animation();return this;};Element[proto].stop=function(){animationElements[this.id]&&animationElements[length]--;delete animationElements[this.id];return this;};Element[proto].translate=function(x,y){return this.attr({translation:x+" "+y});};Element[proto][toString]=function(){return"Rapha\xebl\u2019s object";};R.ae=animationElements;var Set=function(items){this.items=[];this[length]=0;if(items){for(var i=0,ii=items[length];i<ii;i++){if(items[i]&&(items[i].constructor==Element||items[i].constructor==Set)){this[this.items[length]]=this.items[this.items[length]]=items[i];this[length]++;}}}};Set[proto][push]=function(){var item,len;for(var i=0,ii=arguments[length];i<ii;i++){item=arguments[i];if(item&&(item.constructor==Element||item.constructor==Set)){len=this.items[length];this[len]=this.items[len]=item;this[length]++;}}
return this;};Set[proto].pop=function(){delete this[this[length]--];return this.items.pop();};for(var method in Element[proto])if(Element[proto][has](method)){Set[proto][method]=(function(methodname){return function(){for(var i=0,ii=this.items[length];i<ii;i++){this.items[i][methodname][apply](this.items[i],arguments);}
return this;};})(method);}
Set[proto].attr=function(name,value){if(name&&R.is(name,"array")&&R.is(name[0],"object")){for(var j=0,jj=name[length];j<jj;j++){this.items[j].attr(name[j]);}}else{for(var i=0,ii=this.items[length];i<ii;i++){this.items[i].attr[apply](this.items[i],arguments);}}
return this;};Set[proto].animate=function(params,ms,easing,callback){(R.is(easing,"function")||!easing)&&(callback=easing||null);var len=this.items[length],i=len,set=this,collector;callback&&(collector=function(){!--len&&callback.call(set);});this.items[--i].animate(params,ms,easing||collector,collector);while(i--){this.items[i].animateWith(this.items[len-1],params,ms,easing||collector,collector);}
return this;};Set[proto].insertAfter=function(el){var i=this.items[length];while(i--){this.items[i].insertAfter(el);}};Set[proto].getBBox=function(){var x=[],y=[],w=[],h=[];for(var i=this.items[length];i--;){var box=this.items[i].getBBox();x[push](box.x);y[push](box.y);w[push](box.x+box.width);h[push](box.y+box.height);}
x=mmin[apply](0,x);y=mmin[apply](0,y);return{x:x,y:y,width:mmax[apply](0,w)-x,height:mmax[apply](0,h)-y};};R.registerFont=function(font){if(!font.face){return font;}
this.fonts=this.fonts||{};var fontcopy={w:font.w,face:{},glyphs:{}},family=font.face["font-family"];for(var prop in font.face)if(font.face[has](prop)){fontcopy.face[prop]=font.face[prop];}
if(this.fonts[family]){this.fonts[family][push](fontcopy);}else{this.fonts[family]=[fontcopy];}
if(!font.svg){fontcopy.face["units-per-em"]=toInt(font.face["units-per-em"],10);for(var glyph in font.glyphs)if(font.glyphs[has](glyph)){var path=font.glyphs[glyph];fontcopy.glyphs[glyph]={w:path.w,k:{},d:path.d&&"M"+path.d[rp](/[mlcxtrv]/g,function(command){return{l:"L",c:"C",x:"z",t:"m",r:"l",v:"c"}[command]||"M";})+"z"};if(path.k){for(var k in path.k)if(path[has](k)){fontcopy.glyphs[glyph].k[k]=path.k[k];}}}}
return font;};paper.getFont=function(family,weight,style,stretch){stretch=stretch||"normal";style=style||"normal";weight=+weight||{normal:400,bold:700,lighter:300,bolder:800}[weight]||400;var font=R.fonts[family];if(!font){var name=new RegExp("(^|\\s)"+family[rp](/[^\w\d\s+!~.:_-]/g,E)+"(\\s|$)","i");for(var fontName in R.fonts)if(R.fonts[has](fontName)){if(name.test(fontName)){font=R.fonts[fontName];break;}}}
var thefont;if(font){for(var i=0,ii=font[length];i<ii;i++){thefont=font[i];if(thefont.face["font-weight"]==weight&&(thefont.face["font-style"]==style||!thefont.face["font-style"])&&thefont.face["font-stretch"]==stretch){break;}}}
return thefont;};paper.print=function(x,y,string,font,size){var out=this.set(),letters=(string+E)[split](E),shift=0,path=E,scale;R.is(font,"string")&&(font=this.getFont(font));if(font){scale=(size||16)/font.face["units-per-em"];var bb=font.face.bbox.split(separator),top=+bb[0],height=+bb[1]+(bb[3]-bb[1])/2;for(var i=0,ii=letters[length];i<ii;i++){var prev=i&&font.glyphs[letters[i-1]]||{},curr=font.glyphs[letters[i]];shift+=i?(prev.w||font.w)+(prev.k&&prev.k[letters[i]]||0):0;curr&&curr.d&&out[push](this.path(curr.d).attr({fill:"#000",stroke:"none",translation:[shift,0]}));}
out.scale(scale,scale,top,height).translate(x-top,y-height);}
return out;};R.format=function(token){var args=R.is(arguments[1],"array")?[0][concat](arguments[1]):arguments,rg=/\{(\d+)\}/g;token&&R.is(token,"string")&&args[length]-1&&(token=token[rp](rg,function(str,i){return args[++i]==null?E:args[i];}));return token||E;};R.ninja=function(){var r=win.Raphael,u;if(oldRaphael.was){win.Raphael=oldRaphael.is;}else{try{delete win.Raphael;}catch(e){win.Raphael=u;}}
return r;};R.el=Element[proto];return R;})();;Raphael.fn.lineChartDefaultOptions=function(env,localOpt){return{width:env.paper.width,height:env.paper.height,margins:[10,10,10,10],pixelWorkaround:0,tooltipsHtml:1,defaultPlotProps:{rounded:10,color:'blue',lineCenter:0,lineProps:{"stroke-width":2,"stroke-linejoin":"round"},fillProps:{stroke:"none",opacity:.3},dotProps:{size:4,stroke:"#000"},tooltipProps:env.paper.tooltipsDefaultOptions(env,localOpt),barProps:{"width-perc":100,"stroke-width":1,"fill-opacity":.3}},plotProps:[],barMargins:0,defaultAxisProps:{normalize:10,min:0,labels:1,labelsDistance:8,labelsRotate:0,labelsProps:{font:'10px Arial',fill:"#000"},titleDistance:25,titleDistanceIE:.75,titleProps:{font:'12px Arial',fill:"#000","font-weight":"bold"}},axisProps:{x:{titleDistanceIE:1.2}},labelsCenter:0,gridNX:"auto",gridNY:10,gridProps:{stroke:'#e0e0e0',"stroke-width":1},gridExtra:[0,0,0,0],gridForceBorder:true,legend:[],legendProps:env.paper.legendDefaultOptions(env,localOpt),shadowProps:{"stroke-width":0,"fill":"black","fill-opacity":.2},nop:0};}
Raphael.fn.pieChartDefaultOptions=function(env,localOpt){return{width:env.paper.width,height:env.paper.height,cx:Math.floor(env.paper.width/2),cy:Math.floor(env.paper.height/2),r:env.r,pixelWorkaround:0,labels:[],defaultPlotProps:{sectorProps:{stroke:'#909090',"stroke-width":1,"fill-opacity":.3},label:1,labelShowOnMouseOverDelay:500,labelShowOnMouseOverEasing:'<>',labelDeltaX:-Math.floor(env.r/2.4),labelDeltaY:-Math.floor(env.r/2.4),labelProps:{fill:'black',stroke:"none","font-family":'Arial',"font-size":Math.round(env.r/10)+"px"},tooltipProps:env.paper.tooltipsDefaultOptions(env,localOpt)},plotProps:[{color:'red'},{color:'blue'},{color:'green'}],shadowProps:{"stroke-width":0,"fill":"black","fill-opacity":.3},tooltipsHtml:1,legend:[],legendProps:env.paper.legendDefaultOptions(env,localOpt),nop:0};}
Raphael.fn.tooltipsDefaultOptions=function(env,localOpt){return{width:100,height:50,roundedCorners:5,padding:[6,6],highlightTarget:1,frameProps:{fill:"white","stroke-width":2},contentStyle:{"font-family":"Arial","font-size":"12px","line-height":"16px",color:"black"},contentProps:{font:'12px Arial',fill:"black"},align:'left','vertical-align':'top'};}
Raphael.fn.legendDefaultOptions=function(env,localOpt){var w=localOpt.legendProps&&localOpt.legendProps.horizontal?(localOpt.legend?localOpt.legend.length*80+20:250):100;var h=localOpt.legendProps&&localOpt.legendProps.horizontal?30:(localOpt.legend?localOpt.legend.length*20+20:100);return{horizontal:0,x:localOpt.legendProps&&localOpt.legendProps.horizontal?Math.floor(env.paper.width-w)/2:10,y:10,width:w,height:h,itemWidth:"fixed",margins:[10,10,10,0],dotMargins:[10,5],borderProps:{fill:"white",stroke:"black","stroke-width":1},defaultDotProps:{type:"rect",width:10,height:10},dotProps:[],defaultTextProps:{font:'12px Arial',fill:"#000"},textProps:[]};}
Raphael.fn._clone=function(obj){if(obj==null||typeof(obj)!='object')
return obj;if(obj.constructor==Array)
return[].concat(obj);var temp=new obj.constructor();for(var key in obj)
temp[key]=this._clone(obj[key]);return temp;}
Raphael.fn._mergeObjects=function(o1,o2){for(var idx in o2)
if(typeof o1[idx]=='undefined')
o1[idx]=this._clone(o2[idx]);else if(typeof o2[idx]=='object'){if(typeof o1[idx]=='object')
o1[idx]=this._mergeObjects(o1[idx],o2[idx]);else
o1[idx]=this._mergeObjects({},o2[idx]);}
else
o1[idx]=this._clone(o2[idx]);return o1;}
var getChartCanvas=function(div){var r=Raphael(div,$('#'+div).width(),$('#'+div).height());r.container=div;return r;};Raphael.fn.lineChart=function(labels,values,tooltips,options){var env={paper:this,labels:labels,values:values,tooltips:tooltips,opt:{},plots:[],plotsOrdered:[],axis:{x:{}},barno:0};env.opt=this.lineChartDefaultOptions(env,options);env.opt=this._mergeObjects(env.opt,options);var paper=env.paper;var opt=env.opt;var plots=env.plots;var axis=env.axis;var offs=(opt.pixelWorkaround?.5:0);for(var lidx in values){var plot={};var props=this._clone(opt.defaultPlotProps);if(opt.plotProps&&opt.plotProps.length>lidx&&opt.plotProps[lidx])
props=this._mergeObjects(props,opt.plotProps[lidx]);if(props.color){if(props.lineProps&&!props.lineProps.stroke)
props.lineProps.stroke=props.color;if(props.fillProps&&!props.fillProps.fill)
props.fillProps.fill=props.color;if(props.dotProps&&!props.dotProps.fill)
props.dotProps.fill=props.color;if(props.tooltipProps&&props.tooltipProps.frameProps&&!props.tooltipProps.frameProps.stroke)
props.tooltipProps.frameProps.stroke=props.color;if(props.barProps&&!props.barProps.stroke)
props.barProps.stroke=props.color;if(props.barProps&&!props.barProps.fill)
props.barProps.fill=props.color;}
plot.props=props;if(typeof props.stackedWith=='undefined'||props.stackedWith==lidx){plot.ref=lidx;if(props.type=='bar')
plot.barno=env.barno++;plot.from=[];plot.to=values[lidx];for(var i=0;i<values[lidx].length;i++)
plot.from.push(0);}else{plot.ref=props.stackedWith;if(props.type=='bar')
plot.barno=plots[props.stackedWith].barno;plot.from=plots[props.stackedWith].stack;plot.to=[];for(var i=0;i<values[lidx].length;i++)
plot.to.push(plot.from[i]+values[lidx][i]);plots[props.stackedWith].stack=plot.to;}
plot.stack=plot.to;plot.max=Math.max.apply(Math,plot.from.concat(plot.to));plot.min=Math.min.apply(Math,plot.from.concat(plot.to));if(props.axis){if(!axis[props.axis])
axis[props.axis]={plots:[]};axis[props.axis].plots.push(lidx);if(typeof axis[props.axis].max=='undefined')
axis[props.axis].max=plot.max;else
axis[props.axis].max=Math.max(axis[props.axis].max,plot.max);if(typeof axis[props.axis].min=='undefined')
axis[props.axis].min=plot.min;else
axis[props.axis].min=Math.min(axis[props.axis].min,plot.min);}
plots.push(plot);if(typeof props.behind=='undefined'||props.behind<0)
env.plotsOrdered.push(plot);else{var ins=false;for(var i in env.plotsOrdered)
if(env.plotsOrdered[i]==plots[props.behind]){ins=true;env.plotsOrdered.splice(i,0,plot);break;}
if(!ins)
env.plotsOrdered.push(plot);}}
for(var lidx in axis){var props=this._clone(opt.defaultAxisProps);if(opt.axisProps[lidx])
props=this._mergeObjects(props,opt.axisProps[lidx]);axis[lidx].props=props;if(typeof props.max!='undefined')
axis[lidx].max=props.max;if(typeof props.min!='undefined')
axis[lidx].min=props.min;if(props.normalize){if(props.normalize=='auto'||props.normalize=='autony'){var v=Math.abs(axis[lidx].max);if(axis[lidx].min&&Math.abs(axis[lidx].min)>v)
v=Math.abs(axis[lidx].min);if(v){var basev=Math.pow(10,Math.floor(Math.log(v)/Math.LN10));v=Math.ceil(v/basev)*basev;if(props.normalize=='autony')
v=Math.ceil(v/opt.gridNY)*opt.gridNY;props.normalize=v;}else
props.normalize=false;}
if(props.normalize){if(axis[lidx].max)
axis[lidx].max=Math.ceil(axis[lidx].max/props.normalize)*props.normalize;if(axis[lidx].min)
axis[lidx].min=Math.floor(axis[lidx].min/props.normalize)*props.normalize;}}
if(axis[lidx].plots)
for(var ii in axis[lidx].plots){plots[axis[lidx].plots[ii]].max=axis[lidx].max;plots[axis[lidx].plots[ii]].min=axis[lidx].min;}}
var deltaX=(opt.width-opt.margins[3]-opt.margins[1])/(labels.length>1?labels.length-1:1);var deltaBarX=(opt.width-opt.margins[3]-opt.margins[1])/(labels.length>0?labels.length:1);if(axis.x&&axis.x.props.labels)
for(var i=0;i<labels.length;i++)
if(axis.x.props.labelsSkip&&i<axis.x.props.labelsSkip)
labels[i]=false;else if(typeof labels[i]!='boolean'||labels[i]){var txt=(axis.x.props.prefix?axis.x.props.prefix:"")+labels[i]+(axis.x.props.suffix?axis.x.props.suffix:"");var labx=(opt.labelsCenter&&axis.x.props.labelsAnchor!="start"?Math.round(deltaBarX/2):0)+opt.margins[3]+i*(opt.labelsCenter?deltaBarX:deltaX)+(axis.x.props.labelsMargin?axis.x.props.labelsMargin:0);var laby=opt.height-opt.margins[2]+axis.x.props.labelsDistance;var labe=paper.text(labx,laby,txt).attr(axis.x.props.labelsProps).toBack();if(axis.x.props.labelsRotate)
labe.attr({"text-anchor":"start"}).rotate(axis.x.props.labelsRotate,labx,laby).toBack();else if(opt.gridNX=='auto'&&labx+labe.getBBox().width/(axis.x.props.labelsAnchor&&axis.x.props.labelsAnchor=="start"?1:2)>opt.width-opt.margins[1]){labe.hide();labels[i]=false;}else if(opt.gridNX=='auto'&&(!axis.x.props.labelsAnchor||axis.x.props.labelsAnchor!="start")&&labx-labe.getBBox().width/2<0){labe.hide();labels[i]=false;}else if(axis.x.props.labelsAnchor&&axis.x.props.labelsAnchor=="start"){labe.attr({"text-anchor":"start"});var lw=labe.getBBox().width+(axis.x.props.labelsMargin?axis.x.props.labelsMargin:0)+(axis.x.props.labelsMarginRight?axis.x.props.labelsMarginRight:0)-(opt.labelsCenter?deltaBarX:deltaX);if(axis.x.props.labelsHideCovered&&lw>0){var j=i+Math.ceil(lw/(opt.labelsCenter?deltaBarX:deltaX));for(;i<j&&i+1<labels.length;i++)
labels[i+1]=false;}}else if(axis.x.props.labelsHideCovered){var lw=(labe.getBBox().width+(axis.x.props.labelsMargin?axis.x.props.labelsMargin:0)+(axis.x.props.labelsMarginRight?axis.x.props.labelsMarginRight:0))/1-(opt.labelsCenter?deltaBarX:deltaX);if(lw>0){var j=i+Math.ceil(lw/(opt.labelsCenter?deltaBarX:deltaX));for(;i<j&&i+1<labels.length;i++)
labels[i+1]=false;}}}
if(axis.x&&axis.x.props.title){var x=opt.margins[3]+Math.floor((opt.width-opt.margins[1]-opt.margins[3])/2);var y=opt.height-opt.margins[2]+axis.x.props.titleDistance*($.browser.msie?axis.x.props.titleDistanceIE:1);paper.text(x,y,axis.x.props.title).attr(axis.x.props.titleProps);}
for(var jj in['l','r']){var j=['l','r'][jj];if(axis[j]&&axis[j].props.labels){for(var i=axis[j].props.labelsSkip?axis[j].props.labelsSkip:0;i<=opt.gridNY;i++){var deltaY=(opt.height-opt.margins[2]-opt.margins[0])/opt.gridNY;if(j=='r'){var labx=opt.width-opt.margins[1]+axis[j].props.labelsDistance;axis[j].props.labelsProps["text-anchor"]="start";}else{var labx=opt.margins[3]-axis[j].props.labelsDistance;axis[j].props.labelsProps["text-anchor"]="end";}
var txt=(axis[j].props.prefix?axis[j].props.prefix:"")+(axis[j].min+(i*(axis[j].max-axis[j].min)/opt.gridNY))+(axis[j].props.suffix?axis[j].props.suffix:"");var laby=opt.height-opt.margins[2]-i*deltaY;var labe=paper.text(labx,laby+(axis[j].props.labelsMargin?axis[j].props.labelsMargin:0),txt).attr(axis[j].props.labelsProps).toBack();}}
if(axis[j]&&axis[j].props.title){if(j=='r')
var x=opt.width-opt.margins[1]+axis[j].props.titleDistance*($.browser.msie?axis[j].props.titleDistanceIE:1);else
var x=opt.margins[3]-axis[j].props.titleDistance*($.browser.msie?axis[j].props.titleDistanceIE:1);paper.text(x,opt.margins[0]+Math.floor((opt.height-opt.margins[0]-opt.margins[2])/2),axis[j].props.title).attr(axis[j].props.titleProps).attr({rotation:j=='l'?270:90});}}
var gridElement=false;if(opt.gridNX||opt.gridNY){var nx=opt.gridNX=='auto'?(opt.labelsCenter?labels.length:labels.length-1):opt.gridNX,ny=opt.gridNY,path=[],t,rowHeight=(opt.height-opt.margins[2]-opt.margins[0])/ny,columnWidth=(opt.width-opt.margins[1]-opt.margins[3])/nx;for(var i=0;i<ny+1;i++)
path=path.concat(["M",opt.margins[3]-opt.gridExtra[3]+offs,opt.margins[0]+offs+Math.round(i*rowHeight),"L",opt.width-opt.margins[1]+opt.gridExtra[1]+offs,opt.margins[0]+offs+Math.round(i*rowHeight)]);for(var i=0;i<nx+1;i++)
if((t=opt.gridNX!='auto'||typeof labels[i]!='boolean'||labels[i])||(opt.gridForceBorder&&(i==0||i==nx)))
path=path.concat(["M",opt.margins[3]+offs+Math.round(i*columnWidth),opt.margins[0]-(t?opt.gridExtra[0]:0)+offs,"L",opt.margins[3]+offs+Math.round(i*columnWidth),opt.height-opt.margins[2]+(t?opt.gridExtra[2]:0)+offs]);gridElement=paper.path(path.join(",")).attr(opt.gridProps);}
for(var lidx in values){var data=values[lidx];var tips=tooltips&&tooltips.length>lidx&&tooltips[lidx]?tooltips[lidx]:false;var plot=plots[lidx];plot.element=false;var props=plot.props;var deltaY=(opt.height-opt.margins[2]-opt.margins[0])/(plot.max-plot.min);if(!props.type||props.type=='line'){if(props.lineProps){var path=paper.path("").attr(props.lineProps);var pathLn="";var pathLast=false;plot.element=path;if((typeof props.behind!='undefined')&&props.behind>=0&&plots[props.behind].element)
path.insertBefore(plots[props.behind].element);}
if(props.fillProps){var bgp=paper.path("").attr(props.fillProps);var bgpLn="";var bgpLast=false;if((typeof props.behind!='undefined')&&props.behind>=0&&plots[props.behind].element){if(plot.element)
bgp.insertBefore(plot.element);else
bgp.insertBefore(plots[props.behind].element);}else
bgp.insertBefore(plots[plot.ref].element);if(!plot.element)
plot.element=bgp;bgpLn+=["M",opt.margins[3]+(props.lineCenter?deltaBarX/2:0),opt.height-opt.margins[2]+offs];var bgp_back=[];}}
for(var i=0,ii=labels.length;i<ii;i++){var rect=false,dot=false,area=false;if(!props.type||props.type=='line'){var d=plot.to[i]>plot.max?plot.max:(plot.to[i]<plot.min?plot.min:plot.to[i]);var x=Math.round((props.lineCenter?deltaBarX/2:0)+opt.margins[3]+i*(props.lineCenter?deltaBarX:deltaX))+offs;var y=Math.round(opt.height-opt.margins[2]-deltaY*(d-plot.min))+offs;var dd=plot.from[i]>plot.max?plot.max:(plot.from[i]<plot.min?plot.min:plot.from[i]);var yy=Math.round(opt.height-opt.margins[2]-deltaY*(dd-plot.min))+offs+($.browser.msie?1:0);if(props.lineProps){if(!props.rounded||!pathLast)
pathLn+=[pathLn==""?"M":"L",x,y];else
pathLn+=["C",pathLast[0]+props.rounded,pathLast[1],x-props.rounded,y,x,y];pathLast=[x,y];}
if(props.fillProps){if(!props.rounded||!bgpLast)
bgpLn+=["L",x,y];else
bgpLn+=["C",bgpLast[0]+props.rounded,bgpLast[1],x-props.rounded,y,x,y];bgpLast=[x,y];bgp_back.push([x,yy,props.rounded]);}
if(props.dotProps){var dot=paper.circle(x,y,props.dotProps.size).attr(props.dotProps);if((typeof props.behind!='undefined')&&props.behind>=0&&plots[props.behind].element)
dot.insertBefore(plots[props.behind].element);if(!plot.element)
plot.element=dot;}}else{if(props.barProps){if(plot.from[i]!=plot.to[i]){var bwid=Math.floor((deltaBarX-opt.barMargins)/env.barno);var bpad=bwid*(100-props.barProps["width-perc"])/200;var boff=opt.barMargins/2+plot.barno*bwid;var x1=Math.floor(opt.margins[3]+i*deltaBarX+boff+bpad)+offs;var y1=Math.round(opt.height-opt.margins[2]-deltaY*(plot.to[i]-plot.min))+offs;var y2=Math.round(opt.height-opt.margins[2]-deltaY*(plot.from[i]-plot.min))+offs;if(opt.shadowOffset&&(opt.shadowOffset[0]||opt.shadowOffset[1])){var rectShad=paper.absrect(x1+opt.shadowOffset[1],y1+opt.shadowOffset[0],x1+bwid-bpad*2+opt.shadowOffset[1],opt.shadowOffset[0]<0||plot.from[i]!=0?y2+opt.shadowOffset[0]:y2).attr(opt.shadowProps);if(!gridElement)
rectShad.toBack();else
rectShad.insertAfter(gridElement);}
var rect=paper.absrect(x1,y1,x1+bwid-bpad*2,y2).attr(props.barProps);if((typeof props.behind!='undefined')&&props.behind>=0&&plots[props.behind].element)
rect.insertBefore(plots[props.behind].element);if(!plot.element)
plot.element=rect;}}}
if(props.tooltipProps&&tips){var tip=tips[i];if(!props.type||props.type=='line'){var area=paper.rect(x-10,y-10,20,20);}else if(rect){var area=paper.rect(x1,y1,bwid-bpad*2,y2-y1);var x=x1+Math.round(bwid/2);var y=y1;}
if(area)
paper.tooltipGenerate(env,lidx,props,tip,area,0,x,y,rect,dot);}}
if(!props.type||props.type=='line'){if(props.lineProps)
path.attr({path:pathLn});if(props.fillProps){bgpLast=false;while(bgp_back.length>0){var c=bgp_back.pop();if(!c[2]||!bgpLast)
bgpLn+=["L",c[0],c[1]];else
bgpLn+=["C",bgpLast[0]-c[2],bgpLast[1],c[0]+c[2],c[1],c[0],c[1]];bgpLast=[c[0],c[1]];}
bgpLn+="z";bgp.attr({path:bgpLn});}}}
paper.legendDraw(env);paper.tooltipActivate(env);}
Raphael.fn.pieChart=function(values,tooltips,options){var rad=Math.PI/180;var env={paper:this,values:values,tooltips:tooltips,opt:{},plots:[],plotsOrdered:[],r:Math.floor((this.width<this.height?this.width:this.height)/2.5)};env.opt=this.pieChartDefaultOptions(env,options);env.opt=this._mergeObjects(env.opt,options);var paper=env.paper;var opt=env.opt;var r=env.r;var offs=(opt.pixelWorkaround?.5:0);if(opt.shadowOffset&&(opt.shadowOffset[0]||opt.shadowOffset[1]))
paper.circle(opt.cx+opt.shadowOffset[1],opt.cy+opt.shadowOffset[0],opt.r).attr(opt.shadowProps);function sector(cx,cy,r,re,startAngleFin,endAngleFin,props){var path=["M",cx+re*Math.cos(-startAngleFin*rad),cy+re*Math.sin(-startAngleFin*rad)];var startAngle,endAngle=startAngleFin,delta=(endAngleFin-startAngleFin)/2;do{startAngle=endAngle;endAngle+=delta;var x1=cx+r*Math.cos(-startAngle*rad),x2=cx+r*Math.cos(-endAngle*rad),y1=cy+r*Math.sin(-startAngle*rad),y2=cy+r*Math.sin(-endAngle*rad);if(endAngle<(endAngleFin-1))
path+=["L",x1,y1];path+=["A",r,r,0,+(Math.abs(endAngle-startAngle)>180),0,x2,y2];}while(endAngle<(endAngleFin-1));if(re>0){path+=["L",cx+re*Math.cos(-endAngle*rad),cy+re*Math.sin(-endAngle*rad)];do{startAngle=endAngle;endAngle-=delta;var x1=cx+re*Math.cos(-startAngle*rad),x2=cx+re*Math.cos(-endAngle*rad),y1=cy+re*Math.sin(-startAngle*rad),y2=cy+re*Math.sin(-endAngle*rad);path+=["A",re,re,0,+(Math.abs(endAngle-startAngle)>180),1,x2,y2];}while(endAngle>(startAngleFin+1));}
path+=["z"];return paper.path(path).attr(props);}
var angle=0,total=0,angleplus=0,anglelimit=0;var process=function(j){var props=env.paper._clone(opt.defaultPlotProps);if(opt.plotProps&&opt.plotProps.length>j&&opt.plotProps[j])
props=env.paper._mergeObjects(props,opt.plotProps[j]);if(typeof props.inside=='undefined'){angle+=anglelimit;angleplus=360*values[j]/total;anglelimit=angleplus;}else{angleplus=360*values[props.inside]/total*values[j]/values[props.inside];}
var value=values[j];var popangle=angle+(angleplus/2);if(props.color){if(props.sectorProps&&!props.sectorProps.fill)
props.sectorProps.fill=props.color;if(props.tooltipProps&&props.tooltipProps.frameProps&&!props.tooltipProps.frameProps.stroke)
props.tooltipProps.frameProps.stroke=props.color;}
var plot={props:props};env.plots.push(plot);env.plotsOrdered.push(plot);var r=opt.r;var re=0;if(props.r){if(props.r>0){if(props.r<=1)
r=r*props.r;else
r=props.r;}else{if(props.r>=-1)
re=r*-props.r;else
re=-props.r;}}
plot.element=sector(opt.cx,opt.cy,r,re,angle,angle+angleplus,props.sectorProps);if(props.label&&opt.labels&&opt.labels[j]){var lprops=props.labelProps;if(props.labelShowOnMouseOver)
lprops.opacity=0;var txt=paper.text(opt.cx+(opt.r+props.labelDeltaX)*Math.cos(-popangle*rad),opt.cy+(opt.r+props.labelDeltaY)*Math.sin(-popangle*rad),opt.labels[j]).attr(lprops);}
if(props.sectorOnMouseOver){var f=function(){props.sectorOnMouseOver(plot.element,env,j,props)};txt.mouseover(f);plot.element.mouseover(f);}
if(props.sectorOnMouseOut)
plot.element.mouseout(function(){props.sectorOnMouseOut(plot.element,env,j,props)});if(props.tooltipProps&&tooltips&&tooltips[j]){var tipangle=360-popangle;var x=opt.cx+opt.r*Math.cos(-tipangle*rad);var y=opt.cy+opt.r*Math.sin(-tipangle*rad);paper.tooltipGenerate(env,j,props,tooltips[j],plot.element,1,x,y,plot.element,false);}};for(var i=0,ii=values.length;i<ii;i++)
if((typeof opt.plotProps[i].inside)=='undefined')
total+=values[i];for(var i=0;i<ii;i++)
process(i);paper.legendDraw(env);paper.tooltipActivate(env);};Raphael.fn.tooltipGenerate=function(env,lidx,props,tip,area,areaSelf,x,y,rect,dot){var paper=env.paper;var opt=env.opt;var plot=env.plots[lidx];if(typeof env.tippaper=='undefined'){env.tipTimer=false;env.areasTipped=[];$(paper.canvas.parentNode).prepend('<div id="'+paper.canvas.parentNode.id+'_sub" style="position: absolute; z-index: 10"></div>');if(!opt.tooltipsHtml){env.tippaper=Raphael(paper.canvas.parentNode.id+'_sub',1,1);env.tippaper.canvas.style.position="absolute";}else{env.tippaper=document.getElementById(paper.canvas.parentNode.id+'_sub');$(env.tippaper).css({overflow:"hidden","white-space":"nowrap"});}}
if(props.tooltipProps&&(typeof plot.tipFrame=='undefined')){plot.tipFrame=paper.rect(0,0,props.tooltipProps.width,props.tooltipProps.height,props.tooltipProps.roundedCorners).attr(props.tooltipProps.frameProps).hide();if(!opt.tooltipsHtml){plot.tipContent=env.tippaper.text("",0,0).attr(props.tooltipProps.contentProps).hide();if(!props.tooltipProps['align']||props.tooltipProps['align']=='left')
plot.tipContent.attr({"text-anchor":"start"});}}
if(typeof plot.mouseareas=='undefined')
plot.mouseareas=[];if(!areaSelf)
plot.mouseareas.push(area.attr({stroke:"none",fill:"#fff",opacity:0}));(function(env,lidx,props,tip,x,y,dot,rect){var opt=env.opt;function hideTips(){for(var j in env.plots){if(env.plots[j].tipFrame)
env.plots[j].tipFrame.hide();if(env.plots[j].tipContent)
env.plots[j].tipContent.hide();}
if(!opt.tooltipsHtml)
env.tippaper.setSize(1,1);else
$(env.tippaper).hide();for(var j in env.areasTipped){env.areasTipped[j][0].attr(env.areasTipped[j][1]);}
if(env.areaHi)
env.areaHi.hide();}
function tipMouseOver(){env.tipOut=false;clearTimeout(env.tipTimer);if(!env.tipIn||env.tipIn!=''+lidx+'_'+x+'y'){hideTips();env.tipIn=''+lidx+'_'+x+'y';var ttx=x-10;var tty=y-props.tooltipProps.height-10;if(ttx<0)
ttx=5;if(ttx+props.tooltipProps.width>opt.width)
ttx=opt.width-props.tooltipProps.width-5;if(tty<0)
tty=y+10;if(tty+props.tooltipProps.height>opt.height)
tty=opt.height-props.tooltipProps.height-5;env.plots[lidx].tipFrame.attr({x:ttx,y:tty}).show();if(!opt.tooltipsHtml){var tipContent=env.plots[lidx].tipContent;env.tippaper.setSize(opt.width,opt.height);env.tippaper.canvas.style.clip="rect("+
Math.floor(tty+props.tooltipProps.padding[0])+"px, "+
Math.floor(ttx+props.tooltipProps.width-props.tooltipProps.padding[1])+"px, "+
Math.floor(tty+props.tooltipProps.height-props.tooltipProps.padding[0])+"px, "+
Math.floor(ttx+props.tooltipProps.padding[1])+"px)";tipContent.attr({text:tip,x:!props.tooltipProps['align']||props.tooltipProps['align']=='left'?ttx+props.tooltipProps.padding[1]:ttx+Math.round(props.tooltipProps.width/2),y:tty+Math.round(props.tooltipProps.height/2)});if(!props.tooltipProps['vertical-align']||props.tooltipProps['vertical-align']=='top')
tipContent.attr("y",tty+props.tooltipProps.padding[0]+Math.round(tipContent.getBBox().height/2));tipContent.show();}else{$(env.tippaper).css(props.tooltipProps.contentStyle);$(env.tippaper).css({width:props.tooltipProps.width-props.tooltipProps.padding[1]*2,height:props.tooltipProps.height-props.tooltipProps.padding[0]*2,margin:(tty+props.tooltipProps.padding[0])+"px 0 0 "+(ttx+props.tooltipProps.padding[1])+"px"});$(env.tippaper).html(tip);$(env.tippaper).show();$(env.tippaper).unbind();$(env.tippaper).hover(tipMouseOver,tipMouseOut)}
if(props.tooltipProps.highlightTarget){if(dot){if(props.tooltipProps.highlightTargetProps)
env.areaHi=env.paper.path(dot.attrs["path"]).attr(props.tooltipProps.highlightTargetProps);else{dot.attr("r",Math.ceil(props.dotProps.size*1.3));env.areasTipped.push([dot,{r:props.dotProps.size}]);}}
if(rect){if(props.tooltipProps.highlightTargetProps)
env.areaHi=env.paper.path(rect.attrs["path"]).attr(props.tooltipProps.highlightTargetProps);else{var sw=rect.attrs["stroke-width"]?rect.attrs["stroke-width"]:1;var fo=rect.attrs["fill-opacity"]?rect.attrs["fill-opacity"]:1;env.areasTipped.push([rect,{scale:"1,1","stroke-width":sw,"stroke-opacity":rect.attrs["stroke-opacity"]?rect.attrs["stroke-opacity"]:1,"fill-opacity":fo}]);rect.attr({"stroke-width":sw*2,"fill-opacity":fo+fo*.5});}}
if(env.areaHi)
env.areaHi.insertBefore(env.plots[lidx].tipFrame);}
env.paper.safari();}}
function tipMouseOut(){env.tipOut=true;env.tipTimer=setTimeout(function(){if(env.tipOut||env.tipIn!=''+lidx+'_'+x+'y'){env.tipIn=false;env.tipOut=false;hideTips();env.paper.safari();}},200);}
$(area.node).hover(tipMouseOver,tipMouseOut);})(env,lidx,props,tip,x,y,dot,rect);}
Raphael.fn.tooltipActivate=function(env){for(var j in env.plots){if(env.plots[j].tipFrame)
env.plots[j].tipFrame.toFront();if(env.plots[j].tipContent)
env.plots[j].tipContent.toFront();}
var blanket=env.paper.set();for(var j in env.plotsOrdered){for(var k in env.plotsOrdered[j].mouseareas)
blanket.push(env.plotsOrdered[j].mouseareas[k]);}
blanket.toFront();}
Raphael.fn.legendDraw=function(env){if(!env.opt.legend||env.opt.legend.length==0)
return;var props=env.opt.legendProps;var offs=(env.opt.pixelWorkaround?.5:0);if(props.x=='auto'){var autox=1;props.x=0;}
if(props.width=='auto'){var autowidth=1;props.width=env.paper.width;}
var border=env.paper.rect(props.x+offs,props.y+offs,props.width,props.height,props.r).attr(props.borderProps);if(autox||autowidth)
border.hide();var wauto=0;var items=[];for(var i in env.plots)
if(env.opt.legend[i]){var text=env.opt.legend[i];var dprops=this._clone(props.defaultDotProps);if(props.dotProps&&props.dotProps.length>i)
dprops=this._mergeObjects(dprops,props.dotProps);var tprops=this._clone(props.defaultTextProps);if(props.TextProps&&props.TextProps.length>i)
tprops=this._mergeObjects(dprops,props.TextProps);if(env.plots[i].props.color){if(!dprops.fill)
dprops.fill=env.plots[i].props.color;}
if(!props.horizontal){var h=(props.height-props.margins[0]-props.margins[2])/env.opt.legend.length;var w=props.width-props.margins[1]-props.margins[3];var x=Math.floor(props.x+props.margins[3])+offs;var y=Math.floor(props.y+props.margins[0]+h*i)+offs;}else{var h=props.height-props.margins[0]-props.margins[2];if(!props.itemWidth||props.itemWidth=='fixed'){var w=(props.width-props.margins[1]-props.margins[3])/env.opt.legend.length;var x=Math.floor(props.x+props.margins[3]+w*i)+offs;}else{var w=(props.width-props.margins[1]-props.margins[3])-wauto;var x=props.x+props.margins[3]+wauto+offs;}
var y=Math.floor(props.y+props.margins[0])+offs;}
if(dprops.type=="rect"){items.push(env.paper.rect(props.dotMargins[0]+x,y+Math.floor((h-dprops.height)/2),dprops.width,dprops.height,dprops.r).attr(dprops));var xd=props.dotMargins[0]+dprops.width+props.dotMargins[1];}else if(dprops.type=="circle"){items.push(env.paper.circle(props.dotMargins[0]+x+dprops.r,y+dprops.r,dprops.r).attr(dprops));var xd=props.dotMargins[0]+dprops.r*2+props.dotMargins[1];}
var t=env.paper.text(x+xd,y+Math.ceil(h/2)+($.browser.msie?2:0),text).attr({"text-anchor":"start"}).attr(tprops).hide();items.push(t);while(t.getBBox().width>(w-xd)&&t.getBBox().width>10){text=text.substring(0,text.length-1);t.attr({text:text});}
t.show();if(props.horizontal&&props.itemWidth=='auto')
wauto+=xd+t.getBBox().width+4;else if(!props.horizontal&&autowidth)
wauto=t.getBBox().width+xd>wauto?t.getBBox().width+xd:wauto;else
wauto+=w;}
if(autowidth)
props.width=wauto+props.margins[3]+props.margins[1];if(autox){props.x=Math.floor((env.paper.width-props.width)/2);for(var i in items)
items[i].attr('x',items[i].attrs.x+props.x);}
if(autowidth||autox){border.attr({width:props.width,x:props.x});border.show();}}
Raphael.fn.absrect=function(x1,y1,x2,y2){return this.path('M {0} {1} L {0} {3} L {2} {3} L {2} {1} z',x1,y1,x2,y2);};jQuery.ui||(function(c){var i=c.fn.remove,d=c.browser.mozilla&&(parseFloat(c.browser.version)<1.9);c.ui={version:"1.7.2",plugin:{add:function(k,l,n){var m=c.ui[k].prototype;for(var j in n){m.plugins[j]=m.plugins[j]||[];m.plugins[j].push([l,n[j]])}},call:function(j,l,k){var n=j.plugins[l];if(!n||!j.element[0].parentNode){return}for(var m=0;m<n.length;m++){if(j.options[n[m][0]]){n[m][1].apply(j.element,k)}}}},contains:function(k,j){return document.compareDocumentPosition?k.compareDocumentPosition(j)&16:k!==j&&k.contains(j)},hasScroll:function(m,k){if(c(m).css("overflow")=="hidden"){return false}var j=(k&&k=="left")?"scrollLeft":"scrollTop",l=false;if(m[j]>0){return true}m[j]=1;l=(m[j]>0);m[j]=0;return l},isOverAxis:function(k,j,l){return(k>j)&&(k<(j+l))},isOver:function(o,k,n,m,j,l){return c.ui.isOverAxis(o,n,j)&&c.ui.isOverAxis(k,m,l)},keyCode:{BACKSPACE:8,CAPS_LOCK:20,COMMA:188,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,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}};if(d){var f=c.attr,e=c.fn.removeAttr,h="http://www.w3.org/2005/07/aaa",a=/^aria-/,b=/^wairole:/;c.attr=function(k,j,l){var m=l!==undefined;return(j=="role"?(m?f.call(this,k,j,"wairole:"+l):(f.apply(this,arguments)||"").replace(b,"")):(a.test(j)?(m?k.setAttributeNS(h,j.replace(a,"aaa:"),l):f.call(this,k,j.replace(a,"aaa:"))):f.apply(this,arguments)))};c.fn.removeAttr=function(j){return(a.test(j)?this.each(function(){this.removeAttributeNS(h,j.replace(a,""))}):e.call(this,j))}}c.fn.extend({remove:function(){c("*",this).add(this).each(function(){c(this).triggerHandler("remove")});return i.apply(this,arguments)},enableSelection:function(){return this.attr("unselectable","off").css("MozUserSelect","").unbind("selectstart.ui")},disableSelection:function(){return this.attr("unselectable","on").css("MozUserSelect","none").bind("selectstart.ui",function(){return false})},scrollParent:function(){var j;if((c.browser.msie&&(/(static|relative)/).test(this.css("position")))||(/absolute/).test(this.css("position"))){j=this.parents().filter(function(){return(/(relative|absolute|fixed)/).test(c.curCSS(this,"position",1))&&(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}else{j=this.parents().filter(function(){return(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}return(/fixed/).test(this.css("position"))||!j.length?c(document):j}});c.extend(c.expr[":"],{data:function(l,k,j){return!!c.data(l,j[3])},focusable:function(k){var l=k.nodeName.toLowerCase(),j=c.attr(k,"tabindex");return(/input|select|textarea|button|object/.test(l)?!k.disabled:"a"==l||"area"==l?k.href||!isNaN(j):!isNaN(j))&&!c(k)["area"==l?"parents":"closest"](":hidden").length},tabbable:function(k){var j=c.attr(k,"tabindex");return(isNaN(j)||j>=0)&&c(k).is(":focusable")}});function g(m,n,o,l){function k(q){var p=c[m][n][q]||[];return(typeof p=="string"?p.split(/,?\s+/):p)}var j=k("getter");if(l.length==1&&typeof l[0]=="string"){j=j.concat(k("getterSetter"))}return(c.inArray(o,j)!=-1)}c.widget=function(k,j){var l=k.split(".")[0];k=k.split(".")[1];c.fn[k]=function(p){var n=(typeof p=="string"),o=Array.prototype.slice.call(arguments,1);if(n&&p.substring(0,1)=="_"){return this}if(n&&g(l,k,p,o)){var m=c.data(this[0],k);return(m?m[p].apply(m,o):undefined)}return this.each(function(){var q=c.data(this,k);(!q&&!n&&c.data(this,k,new c[l][k](this,p))._init());(q&&n&&c.isFunction(q[p])&&q[p].apply(q,o))})};c[l]=c[l]||{};c[l][k]=function(o,n){var m=this;this.namespace=l;this.widgetName=k;this.widgetEventPrefix=c[l][k].eventPrefix||k;this.widgetBaseClass=l+"-"+k;this.options=c.extend({},c.widget.defaults,c[l][k].defaults,c.metadata&&c.metadata.get(o)[k],n);this.element=c(o).bind("setData."+k,function(q,p,r){if(q.target==o){return m._setData(p,r)}}).bind("getData."+k,function(q,p){if(q.target==o){return m._getData(p)}}).bind("remove",function(){return m.destroy()})};c[l][k].prototype=c.extend({},c.widget.prototype,j);c[l][k].getterSetter="option"};c.widget.prototype={_init:function(){},destroy:function(){this.element.removeData(this.widgetName).removeClass(this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").removeAttr("aria-disabled")},option:function(l,m){var k=l,j=this;if(typeof l=="string"){if(m===undefined){return this._getData(l)}k={};k[l]=m}c.each(k,function(n,o){j._setData(n,o)})},_getData:function(j){return this.options[j]},_setData:function(j,k){this.options[j]=k;if(j=="disabled"){this.element[k?"addClass":"removeClass"](this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").attr("aria-disabled",k)}},enable:function(){this._setData("disabled",false)},disable:function(){this._setData("disabled",true)},_trigger:function(l,m,n){var p=this.options[l],j=(l==this.widgetEventPrefix?l:this.widgetEventPrefix+l);m=c.Event(m);m.type=j;if(m.originalEvent){for(var k=c.event.props.length,o;k;){o=c.event.props[--k];m[o]=m.originalEvent[o]}}this.element.trigger(m,n);return!(c.isFunction(p)&&p.call(this.element[0],m,n)===false||m.isDefaultPrevented())}};c.widget.defaults={disabled:false};c.ui.mouse={_mouseInit:function(){var j=this;this.element.bind("mousedown."+this.widgetName,function(k){return j._mouseDown(k)}).bind("click."+this.widgetName,function(k){if(j._preventClickEvent){j._preventClickEvent=false;k.stopImmediatePropagation();return false}});if(c.browser.msie){this._mouseUnselectable=this.element.attr("unselectable");this.element.attr("unselectable","on")}this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName);(c.browser.msie&&this.element.attr("unselectable",this._mouseUnselectable))},_mouseDown:function(l){l.originalEvent=l.originalEvent||{};if(l.originalEvent.mouseHandled){return}(this._mouseStarted&&this._mouseUp(l));this._mouseDownEvent=l;var k=this,m=(l.which==1),j=(typeof this.options.cancel=="string"?c(l.target).parents().add(l.target).filter(this.options.cancel).length:false);if(!m||j||!this._mouseCapture(l)){return true}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){k.mouseDelayMet=true},this.options.delay)}if(this._mouseDistanceMet(l)&&this._mouseDelayMet(l)){this._mouseStarted=(this._mouseStart(l)!==false);if(!this._mouseStarted){l.preventDefault();return true}}this._mouseMoveDelegate=function(n){return k._mouseMove(n)};this._mouseUpDelegate=function(n){return k._mouseUp(n)};c(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);(c.browser.safari||l.preventDefault());l.originalEvent.mouseHandled=true;return true},_mouseMove:function(j){if(c.browser.msie&&!j.button){return this._mouseUp(j)}if(this._mouseStarted){this._mouseDrag(j);return j.preventDefault()}if(this._mouseDistanceMet(j)&&this._mouseDelayMet(j)){this._mouseStarted=(this._mouseStart(this._mouseDownEvent,j)!==false);(this._mouseStarted?this._mouseDrag(j):this._mouseUp(j))}return!this._mouseStarted},_mouseUp:function(j){c(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;this._preventClickEvent=(j.target==this._mouseDownEvent.target);this._mouseStop(j)}return false},_mouseDistanceMet:function(j){return(Math.max(Math.abs(this._mouseDownEvent.pageX-j.pageX),Math.abs(this._mouseDownEvent.pageY-j.pageY))>=this.options.distance)},_mouseDelayMet:function(j){return this.mouseDelayMet},_mouseStart:function(j){},_mouseDrag:function(j){},_mouseStop:function(j){},_mouseCapture:function(j){return true}};c.ui.mouse.defaults={cancel:null,distance:1,delay:0}})(jQuery);;;(function($){$.extend($.ui,{datepicker:{version:"1.7.2"}});var PROP_NAME="datepicker";function Datepicker(){this.debug=false;this._curInst=null;this._keyEvent=false;this._disabledInputs=[];this._datepickerShowing=false;this._inDialog=false;this._mainDivId="ui-datepicker-div";this._inlineClass="ui-datepicker-inline";this._appendClass="ui-datepicker-append";this._triggerClass="ui-datepicker-trigger";this._dialogClass="ui-datepicker-dialog";this._disableClass="ui-datepicker-disabled";this._unselectableClass="ui-datepicker-unselectable";this._currentClass="ui-datepicker-current-day";this._dayOverClass="ui-datepicker-days-cell-over";this.regional=[];this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],dateFormat:"mm/dd/yy",firstDay:0,isRTL:false};this._defaults={showOn:"focus",showAnim:"show",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:false,hideIfNoPrevNext:false,navigationAsDateFormat:false,gotoCurrent:false,changeMonth:false,changeYear:false,showMonthAfterYear:false,yearRange:"-10:+10",showOtherMonths:false,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"normal",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:true,showButtonPanel:false};$.extend(this._defaults,this.regional[""]);this.dpDiv=$('<div id="'+this._mainDivId+'" class="ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all ui-helper-hidden-accessible"></div>')}$.extend(Datepicker.prototype,{markerClassName:"hasDatepicker",log:function(){if(this.debug){console.log.apply("",arguments)}},setDefaults:function(settings){extendRemove(this._defaults,settings||{});return this},_attachDatepicker:function(target,settings){var inlineSettings=null;for(var attrName in this._defaults){var attrValue=target.getAttribute("date:"+attrName);if(attrValue){inlineSettings=inlineSettings||{};try{inlineSettings[attrName]=eval(attrValue)}catch(err){inlineSettings[attrName]=attrValue}}}var nodeName=target.nodeName.toLowerCase();var inline=(nodeName=="div"||nodeName=="span");if(!target.id){target.id="dp"+(++this.uuid)}var inst=this._newInst($(target),inline);inst.settings=$.extend({},settings||{},inlineSettings||{});if(nodeName=="input"){this._connectDatepicker(target,inst)}else{if(inline){this._inlineDatepicker(target,inst)}}},_newInst:function(target,inline){var id=target[0].id.replace(/([:\[\]\.])/g,"\\\\$1");return{id:id,input:target,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:inline,dpDiv:(!inline?this.dpDiv:$('<div class="'+this._inlineClass+' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>'))}},_connectDatepicker:function(target,inst){var input=$(target);inst.append=$([]);inst.trigger=$([]);if(input.hasClass(this.markerClassName)){return}var appendText=this._get(inst,"appendText");var isRTL=this._get(inst,"isRTL");if(appendText){inst.append=$('<span class="'+this._appendClass+'">'+appendText+"</span>");input[isRTL?"before":"after"](inst.append)}var showOn=this._get(inst,"showOn");if(showOn=="focus"||showOn=="both"){input.focus(this._showDatepicker)}if(showOn=="button"||showOn=="both"){var buttonText=this._get(inst,"buttonText");var buttonImage=this._get(inst,"buttonImage");inst.trigger=$(this._get(inst,"buttonImageOnly")?$("<img/>").addClass(this._triggerClass).attr({src:buttonImage,alt:buttonText,title:buttonText}):$('<button type="button"></button>').addClass(this._triggerClass).html(buttonImage==""?buttonText:$("<img/>").attr({src:buttonImage,alt:buttonText,title:buttonText})));input[isRTL?"before":"after"](inst.trigger);inst.trigger.click(function(){if($.datepicker._datepickerShowing&&$.datepicker._lastInput==target){$.datepicker._hideDatepicker()}else{$.datepicker._showDatepicker(target)}return false})}input.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).bind("setData.datepicker",function(event,key,value){inst.settings[key]=value}).bind("getData.datepicker",function(event,key){return this._get(inst,key)});$.data(target,PROP_NAME,inst)},_inlineDatepicker:function(target,inst){var divSpan=$(target);if(divSpan.hasClass(this.markerClassName)){return}divSpan.addClass(this.markerClassName).append(inst.dpDiv).bind("setData.datepicker",function(event,key,value){inst.settings[key]=value}).bind("getData.datepicker",function(event,key){return this._get(inst,key)});$.data(target,PROP_NAME,inst);this._setDate(inst,this._getDefaultDate(inst));this._updateDatepicker(inst);this._updateAlternate(inst)},_dialogDatepicker:function(input,dateText,onSelect,settings,pos){var inst=this._dialogInst;if(!inst){var id="dp"+(++this.uuid);this._dialogInput=$('<input type="text" id="'+id+'" size="1" style="position: absolute; top: -100px;"/>');this._dialogInput.keydown(this._doKeyDown);$("body").append(this._dialogInput);inst=this._dialogInst=this._newInst(this._dialogInput,false);inst.settings={};$.data(this._dialogInput[0],PROP_NAME,inst)}extendRemove(inst.settings,settings||{});this._dialogInput.val(dateText);this._pos=(pos?(pos.length?pos:[pos.pageX,pos.pageY]):null);if(!this._pos){var browserWidth=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth;var browserHeight=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;var scrollX=document.documentElement.scrollLeft||document.body.scrollLeft;var scrollY=document.documentElement.scrollTop||document.body.scrollTop;this._pos=[(browserWidth/2)-100+scrollX,(browserHeight/2)-150+scrollY]}this._dialogInput.css("left",this._pos[0]+"px").css("top",this._pos[1]+"px");inst.settings.onSelect=onSelect;this._inDialog=true;this.dpDiv.addClass(this._dialogClass);this._showDatepicker(this._dialogInput[0]);if($.blockUI){$.blockUI(this.dpDiv)}$.data(this._dialogInput[0],PROP_NAME,inst);return this},_destroyDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();$.removeData(target,PROP_NAME);if(nodeName=="input"){inst.append.remove();inst.trigger.remove();$target.removeClass(this.markerClassName).unbind("focus",this._showDatepicker).unbind("keydown",this._doKeyDown).unbind("keypress",this._doKeyPress)}else{if(nodeName=="div"||nodeName=="span"){$target.removeClass(this.markerClassName).empty()}}},_enableDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();if(nodeName=="input"){target.disabled=false;inst.trigger.filter("button").each(function(){this.disabled=false}).end().filter("img").css({opacity:"1.0",cursor:""})}else{if(nodeName=="div"||nodeName=="span"){var inline=$target.children("."+this._inlineClass);inline.children().removeClass("ui-state-disabled")}}this._disabledInputs=$.map(this._disabledInputs,function(value){return(value==target?null:value)})},_disableDatepicker:function(target){var $target=$(target);var inst=$.data(target,PROP_NAME);if(!$target.hasClass(this.markerClassName)){return}var nodeName=target.nodeName.toLowerCase();if(nodeName=="input"){target.disabled=true;inst.trigger.filter("button").each(function(){this.disabled=true}).end().filter("img").css({opacity:"0.5",cursor:"default"})}else{if(nodeName=="div"||nodeName=="span"){var inline=$target.children("."+this._inlineClass);inline.children().addClass("ui-state-disabled")}}this._disabledInputs=$.map(this._disabledInputs,function(value){return(value==target?null:value)});this._disabledInputs[this._disabledInputs.length]=target},_isDisabledDatepicker:function(target){if(!target){return false}for(var i=0;i<this._disabledInputs.length;i++){if(this._disabledInputs[i]==target){return true}}return false},_getInst:function(target){try{return $.data(target,PROP_NAME)}catch(err){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(target,name,value){var inst=this._getInst(target);if(arguments.length==2&&typeof name=="string"){return(name=="defaults"?$.extend({},$.datepicker._defaults):(inst?(name=="all"?$.extend({},inst.settings):this._get(inst,name)):null))}var settings=name||{};if(typeof name=="string"){settings={};settings[name]=value}if(inst){if(this._curInst==inst){this._hideDatepicker(null)}var date=this._getDateDatepicker(target);extendRemove(inst.settings,settings);this._setDateDatepicker(target,date);this._updateDatepicker(inst)}},_changeDatepicker:function(target,name,value){this._optionDatepicker(target,name,value)},_refreshDatepicker:function(target){var inst=this._getInst(target);if(inst){this._updateDatepicker(inst)}},_setDateDatepicker:function(target,date,endDate){var inst=this._getInst(target);if(inst){this._setDate(inst,date,endDate);this._updateDatepicker(inst);this._updateAlternate(inst)}},_getDateDatepicker:function(target){var inst=this._getInst(target);if(inst&&!inst.inline){this._setDateFromField(inst)}return(inst?this._getDate(inst):null)},_doKeyDown:function(event){var inst=$.datepicker._getInst(event.target);var handled=true;var isRTL=inst.dpDiv.is(".ui-datepicker-rtl");inst._keyEvent=true;if($.datepicker._datepickerShowing){switch(event.keyCode){case 9:$.datepicker._hideDatepicker(null,"");break;case 13:var sel=$("td."+$.datepicker._dayOverClass+", td."+$.datepicker._currentClass,inst.dpDiv);if(sel[0]){$.datepicker._selectDay(event.target,inst.selectedMonth,inst.selectedYear,sel[0])}else{$.datepicker._hideDatepicker(null,$.datepicker._get(inst,"duration"))}return false;break;case 27:$.datepicker._hideDatepicker(null,$.datepicker._get(inst,"duration"));break;case 33:$.datepicker._adjustDate(event.target,(event.ctrlKey?-$.datepicker._get(inst,"stepBigMonths"):-$.datepicker._get(inst,"stepMonths")),"M");break;case 34:$.datepicker._adjustDate(event.target,(event.ctrlKey?+$.datepicker._get(inst,"stepBigMonths"):+$.datepicker._get(inst,"stepMonths")),"M");break;case 35:if(event.ctrlKey||event.metaKey){$.datepicker._clearDate(event.target)}handled=event.ctrlKey||event.metaKey;break;case 36:if(event.ctrlKey||event.metaKey){$.datepicker._gotoToday(event.target)}handled=event.ctrlKey||event.metaKey;break;case 37:if(event.ctrlKey||event.metaKey){$.datepicker._adjustDate(event.target,(isRTL?+1:-1),"D")}handled=event.ctrlKey||event.metaKey;if(event.originalEvent.altKey){$.datepicker._adjustDate(event.target,(event.ctrlKey?-$.datepicker._get(inst,"stepBigMonths"):-$.datepicker._get(inst,"stepMonths")),"M")}break;case 38:if(event.ctrlKey||event.metaKey){$.datepicker._adjustDate(event.target,-7,"D")}handled=event.ctrlKey||event.metaKey;break;case 39:if(event.ctrlKey||event.metaKey){$.datepicker._adjustDate(event.target,(isRTL?-1:+1),"D")}handled=event.ctrlKey||event.metaKey;if(event.originalEvent.altKey){$.datepicker._adjustDate(event.target,(event.ctrlKey?+$.datepicker._get(inst,"stepBigMonths"):+$.datepicker._get(inst,"stepMonths")),"M")}break;case 40:if(event.ctrlKey||event.metaKey){$.datepicker._adjustDate(event.target,+7,"D")}handled=event.ctrlKey||event.metaKey;break;default:handled=false}}else{if(event.keyCode==36&&event.ctrlKey){$.datepicker._showDatepicker(this)}else{handled=false}}if(handled){event.preventDefault();event.stopPropagation()}},_doKeyPress:function(event){var inst=$.datepicker._getInst(event.target);if($.datepicker._get(inst,"constrainInput")){var chars=$.datepicker._possibleChars($.datepicker._get(inst,"dateFormat"));var chr=String.fromCharCode(event.charCode==undefined?event.keyCode:event.charCode);return event.ctrlKey||(chr<" "||!chars||chars.indexOf(chr)>-1)}},_showDatepicker:function(input){input=input.target||input;if(input.nodeName.toLowerCase()!="input"){input=$("input",input.parentNode)[0]}if($.datepicker._isDisabledDatepicker(input)||$.datepicker._lastInput==input){return}var inst=$.datepicker._getInst(input);var beforeShow=$.datepicker._get(inst,"beforeShow");extendRemove(inst.settings,(beforeShow?beforeShow.apply(input,[input,inst]):{}));$.datepicker._hideDatepicker(null,"");$.datepicker._lastInput=input;$.datepicker._setDateFromField(inst);if($.datepicker._inDialog){input.value=""}if(!$.datepicker._pos){$.datepicker._pos=$.datepicker._findPos(input);$.datepicker._pos[1]+=input.offsetHeight}var isFixed=false;$(input).parents().each(function(){isFixed|=$(this).css("position")=="fixed";return!isFixed});if(isFixed&&$.browser.opera){$.datepicker._pos[0]-=document.documentElement.scrollLeft;$.datepicker._pos[1]-=document.documentElement.scrollTop}var offset={left:$.datepicker._pos[0],top:$.datepicker._pos[1]};$.datepicker._pos=null;inst.rangeStart=null;inst.dpDiv.css({position:"absolute",display:"block",top:"-1000px"});$.datepicker._updateDatepicker(inst);offset=$.datepicker._checkOffset(inst,offset,isFixed);inst.dpDiv.css({position:($.datepicker._inDialog&&$.blockUI?"static":(isFixed?"fixed":"absolute")),display:"none",left:offset.left+"px",top:offset.top+"px"});if(!inst.inline){var showAnim=$.datepicker._get(inst,"showAnim")||"show";var duration=$.datepicker._get(inst,"duration");var postProcess=function(){$.datepicker._datepickerShowing=true;if($.browser.msie&&parseInt($.browser.version,10)<7){$("iframe.ui-datepicker-cover").css({width:inst.dpDiv.width()+4,height:inst.dpDiv.height()+4})}};if($.effects&&$.effects[showAnim]){inst.dpDiv.show(showAnim,$.datepicker._get(inst,"showOptions"),duration,postProcess)}else{inst.dpDiv[showAnim](duration,postProcess)}if(duration==""){postProcess()}if(inst.input[0].type!="hidden"){inst.input[0].focus()}$.datepicker._curInst=inst}},_updateDatepicker:function(inst){var dims={width:inst.dpDiv.width()+4,height:inst.dpDiv.height()+4};var self=this;inst.dpDiv.empty().append(this._generateHTML(inst)).find("iframe.ui-datepicker-cover").css({width:dims.width,height:dims.height}).end().find("button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a").bind("mouseout",function(){$(this).removeClass("ui-state-hover");if(this.className.indexOf("ui-datepicker-prev")!=-1){$(this).removeClass("ui-datepicker-prev-hover")}if(this.className.indexOf("ui-datepicker-next")!=-1){$(this).removeClass("ui-datepicker-next-hover")}}).bind("mouseover",function(){if(!self._isDisabledDatepicker(inst.inline?inst.dpDiv.parent()[0]:inst.input[0])){$(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover");$(this).addClass("ui-state-hover");if(this.className.indexOf("ui-datepicker-prev")!=-1){$(this).addClass("ui-datepicker-prev-hover")}if(this.className.indexOf("ui-datepicker-next")!=-1){$(this).addClass("ui-datepicker-next-hover")}}}).end().find("."+this._dayOverClass+" a").trigger("mouseover").end();var numMonths=this._getNumberOfMonths(inst);var cols=numMonths[1];var width=17;if(cols>1){inst.dpDiv.addClass("ui-datepicker-multi-"+cols).css("width",(width*cols)+"em")}else{inst.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width("")}inst.dpDiv[(numMonths[0]!=1||numMonths[1]!=1?"add":"remove")+"Class"]("ui-datepicker-multi");inst.dpDiv[(this._get(inst,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl");if(inst.input&&inst.input[0].type!="hidden"&&inst==$.datepicker._curInst){$(inst.input[0]).focus()}},_checkOffset:function(inst,offset,isFixed){var dpWidth=inst.dpDiv.outerWidth();var dpHeight=inst.dpDiv.outerHeight();var inputWidth=inst.input?inst.input.outerWidth():0;var inputHeight=inst.input?inst.input.outerHeight():0;var viewWidth=(window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth)+$(document).scrollLeft();var viewHeight=(window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight)+$(document).scrollTop();offset.left-=(this._get(inst,"isRTL")?(dpWidth-inputWidth):0);offset.left-=(isFixed&&offset.left==inst.input.offset().left)?$(document).scrollLeft():0;offset.top-=(isFixed&&offset.top==(inst.input.offset().top+inputHeight))?$(document).scrollTop():0;offset.left-=(offset.left+dpWidth>viewWidth&&viewWidth>dpWidth)?Math.abs(offset.left+dpWidth-viewWidth):0;offset.top-=(offset.top+dpHeight>viewHeight&&viewHeight>dpHeight)?Math.abs(offset.top+dpHeight+inputHeight*2-viewHeight):0;return offset},_findPos:function(obj){while(obj&&(obj.type=="hidden"||obj.nodeType!=1)){obj=obj.nextSibling}var position=$(obj).offset();return[position.left,position.top]},_hideDatepicker:function(input,duration){var inst=this._curInst;if(!inst||(input&&inst!=$.data(input,PROP_NAME))){return}if(inst.stayOpen){this._selectDate("#"+inst.id,this._formatDate(inst,inst.currentDay,inst.currentMonth,inst.currentYear))}inst.stayOpen=false;if(this._datepickerShowing){duration=(duration!=null?duration:this._get(inst,"duration"));var showAnim=this._get(inst,"showAnim");var postProcess=function(){$.datepicker._tidyDialog(inst)};if(duration!=""&&$.effects&&$.effects[showAnim]){inst.dpDiv.hide(showAnim,$.datepicker._get(inst,"showOptions"),duration,postProcess)}else{inst.dpDiv[(duration==""?"hide":(showAnim=="slideDown"?"slideUp":(showAnim=="fadeIn"?"fadeOut":"hide")))](duration,postProcess)}if(duration==""){this._tidyDialog(inst)}var onClose=this._get(inst,"onClose");if(onClose){onClose.apply((inst.input?inst.input[0]:null),[(inst.input?inst.input.val():""),inst])}this._datepickerShowing=false;this._lastInput=null;if(this._inDialog){this._dialogInput.css({position:"absolute",left:"0",top:"-100px"});if($.blockUI){$.unblockUI();$("body").append(this.dpDiv)}}this._inDialog=false}this._curInst=null},_tidyDialog:function(inst){inst.dpDiv.removeClass(this._dialogClass).unbind(".ui-datepicker-calendar")},_checkExternalClick:function(event){if(!$.datepicker._curInst){return}var $target=$(event.target);if(($target.parents("#"+$.datepicker._mainDivId).length==0)&&!$target.hasClass($.datepicker.markerClassName)&&!$target.hasClass($.datepicker._triggerClass)&&$.datepicker._datepickerShowing&&!($.datepicker._inDialog&&$.blockUI)){$.datepicker._hideDatepicker(null,"")}},_adjustDate:function(id,offset,period){var target=$(id);var inst=this._getInst(target[0]);if(this._isDisabledDatepicker(target[0])){return}this._adjustInstDate(inst,offset+(period=="M"?this._get(inst,"showCurrentAtPos"):0),period);this._updateDatepicker(inst)},_gotoToday:function(id){var target=$(id);var inst=this._getInst(target[0]);if(this._get(inst,"gotoCurrent")&&inst.currentDay){inst.selectedDay=inst.currentDay;inst.drawMonth=inst.selectedMonth=inst.currentMonth;inst.drawYear=inst.selectedYear=inst.currentYear}else{var date=new Date();inst.selectedDay=date.getDate();inst.drawMonth=inst.selectedMonth=date.getMonth();inst.drawYear=inst.selectedYear=date.getFullYear()}this._notifyChange(inst);this._adjustDate(target)},_selectMonthYear:function(id,select,period){var target=$(id);var inst=this._getInst(target[0]);inst._selectingMonthYear=false;inst["selected"+(period=="M"?"Month":"Year")]=inst["draw"+(period=="M"?"Month":"Year")]=parseInt(select.options[select.selectedIndex].value,10);this._notifyChange(inst);this._adjustDate(target)},_clickMonthYear:function(id){var target=$(id);var inst=this._getInst(target[0]);if(inst.input&&inst._selectingMonthYear&&!$.browser.msie){inst.input[0].focus()}inst._selectingMonthYear=!inst._selectingMonthYear},_selectDay:function(id,month,year,td){var target=$(id);if($(td).hasClass(this._unselectableClass)||this._isDisabledDatepicker(target[0])){return}var inst=this._getInst(target[0]);inst.selectedDay=inst.currentDay=$("a",td).html();inst.selectedMonth=inst.currentMonth=month;inst.selectedYear=inst.currentYear=year;if(inst.stayOpen){inst.endDay=inst.endMonth=inst.endYear=null}this._selectDate(id,this._formatDate(inst,inst.currentDay,inst.currentMonth,inst.currentYear));if(inst.stayOpen){inst.rangeStart=this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay));this._updateDatepicker(inst)}},_clearDate:function(id){var target=$(id);var inst=this._getInst(target[0]);inst.stayOpen=false;inst.endDay=inst.endMonth=inst.endYear=inst.rangeStart=null;this._selectDate(target,"")},_selectDate:function(id,dateStr){var target=$(id);var inst=this._getInst(target[0]);dateStr=(dateStr!=null?dateStr:this._formatDate(inst));if(inst.input){inst.input.val(dateStr)}this._updateAlternate(inst);var onSelect=this._get(inst,"onSelect");if(onSelect){onSelect.apply((inst.input?inst.input[0]:null),[dateStr,inst])}else{if(inst.input){inst.input.trigger("change")}}if(inst.inline){this._updateDatepicker(inst)}else{if(!inst.stayOpen){this._hideDatepicker(null,this._get(inst,"duration"));this._lastInput=inst.input[0];if(typeof(inst.input[0])!="object"){inst.input[0].focus()}this._lastInput=null}}},_updateAlternate:function(inst){var altField=this._get(inst,"altField");if(altField){var altFormat=this._get(inst,"altFormat")||this._get(inst,"dateFormat");var date=this._getDate(inst);dateStr=this.formatDate(altFormat,date,this._getFormatConfig(inst));$(altField).each(function(){$(this).val(dateStr)})}},noWeekends:function(date){var day=date.getDay();return[(day>0&&day<6),""]},iso8601Week:function(date){var checkDate=new Date(date.getFullYear(),date.getMonth(),date.getDate());var firstMon=new Date(checkDate.getFullYear(),1-1,4);var firstDay=firstMon.getDay()||7;firstMon.setDate(firstMon.getDate()+1-firstDay);if(firstDay<4&&checkDate<firstMon){checkDate.setDate(checkDate.getDate()-3);return $.datepicker.iso8601Week(checkDate)}else{if(checkDate>new Date(checkDate.getFullYear(),12-1,28)){firstDay=new Date(checkDate.getFullYear()+1,1-1,4).getDay()||7;if(firstDay>4&&(checkDate.getDay()||7)<firstDay-3){return 1}}}return Math.floor(((checkDate-firstMon)/86400000)/7)+1},parseDate:function(format,value,settings){if(format==null||value==null){throw"Invalid arguments"}value=(typeof value=="object"?value.toString():value+"");if(value==""){return null}var shortYearCutoff=(settings?settings.shortYearCutoff:null)||this._defaults.shortYearCutoff;var dayNamesShort=(settings?settings.dayNamesShort:null)||this._defaults.dayNamesShort;var dayNames=(settings?settings.dayNames:null)||this._defaults.dayNames;var monthNamesShort=(settings?settings.monthNamesShort:null)||this._defaults.monthNamesShort;var monthNames=(settings?settings.monthNames:null)||this._defaults.monthNames;var year=-1;var month=-1;var day=-1;var doy=-1;var literal=false;var lookAhead=function(match){var matches=(iFormat+1<format.length&&format.charAt(iFormat+1)==match);if(matches){iFormat++}return matches};var getNumber=function(match){lookAhead(match);var origSize=(match=="@"?14:(match=="y"?4:(match=="o"?3:2)));var size=origSize;var num=0;while(size>0&&iValue<value.length&&value.charAt(iValue)>="0"&&value.charAt(iValue)<="9"){num=num*10+parseInt(value.charAt(iValue++),10);size--}if(size==origSize){throw"Missing number at position "+iValue}return num};var getName=function(match,shortNames,longNames){var names=(lookAhead(match)?longNames:shortNames);var size=0;for(var j=0;j<names.length;j++){size=Math.max(size,names[j].length)}var name="";var iInit=iValue;while(size>0&&iValue<value.length){name+=value.charAt(iValue++);for(var i=0;i<names.length;i++){if(name==names[i]){return i+1}}size--}throw"Unknown name at position "+iInit};var checkLiteral=function(){if(value.charAt(iValue)!=format.charAt(iFormat)){throw"Unexpected literal at position "+iValue}iValue++};var iValue=0;for(var iFormat=0;iFormat<format.length;iFormat++){if(literal){if(format.charAt(iFormat)=="'"&&!lookAhead("'")){literal=false}else{checkLiteral()}}else{switch(format.charAt(iFormat)){case"d":day=getNumber("d");break;case"D":getName("D",dayNamesShort,dayNames);break;case"o":doy=getNumber("o");break;case"m":month=getNumber("m");break;case"M":month=getName("M",monthNamesShort,monthNames);break;case"y":year=getNumber("y");break;case"@":var date=new Date(getNumber("@"));year=date.getFullYear();month=date.getMonth()+1;day=date.getDate();break;case"'":if(lookAhead("'")){checkLiteral()}else{literal=true}break;default:checkLiteral()}}}if(year==-1){year=new Date().getFullYear()}else{if(year<100){year+=new Date().getFullYear()-new Date().getFullYear()%100+(year<=shortYearCutoff?0:-100)}}if(doy>-1){month=1;day=doy;do{var dim=this._getDaysInMonth(year,month-1);if(day<=dim){break}month++;day-=dim}while(true)}var date=this._daylightSavingAdjust(new Date(year,month-1,day));if(date.getFullYear()!=year||date.getMonth()+1!=month||date.getDate()!=day){throw"Invalid date"}return date},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TIMESTAMP:"@",W3C:"yy-mm-dd",formatDate:function(format,date,settings){if(!date){return""}var dayNamesShort=(settings?settings.dayNamesShort:null)||this._defaults.dayNamesShort;var dayNames=(settings?settings.dayNames:null)||this._defaults.dayNames;var monthNamesShort=(settings?settings.monthNamesShort:null)||this._defaults.monthNamesShort;var monthNames=(settings?settings.monthNames:null)||this._defaults.monthNames;var lookAhead=function(match){var matches=(iFormat+1<format.length&&format.charAt(iFormat+1)==match);if(matches){iFormat++}return matches};var formatNumber=function(match,value,len){var num=""+value;if(lookAhead(match)){while(num.length<len){num="0"+num}}return num};var formatName=function(match,value,shortNames,longNames){return(lookAhead(match)?longNames[value]:shortNames[value])};var output="";var literal=false;if(date){for(var iFormat=0;iFormat<format.length;iFormat++){if(literal){if(format.charAt(iFormat)=="'"&&!lookAhead("'")){literal=false}else{output+=format.charAt(iFormat)}}else{switch(format.charAt(iFormat)){case"d":output+=formatNumber("d",date.getDate(),2);break;case"D":output+=formatName("D",date.getDay(),dayNamesShort,dayNames);break;case"o":var doy=date.getDate();for(var m=date.getMonth()-1;m>=0;m--){doy+=this._getDaysInMonth(date.getFullYear(),m)}output+=formatNumber("o",doy,3);break;case"m":output+=formatNumber("m",date.getMonth()+1,2);break;case"M":output+=formatName("M",date.getMonth(),monthNamesShort,monthNames);break;case"y":output+=(lookAhead("y")?date.getFullYear():(date.getYear()%100<10?"0":"")+date.getYear()%100);break;case"@":output+=date.getTime();break;case"'":if(lookAhead("'")){output+="'"}else{literal=true}break;default:output+=format.charAt(iFormat)}}}}return output},_possibleChars:function(format){var chars="";var literal=false;for(var iFormat=0;iFormat<format.length;iFormat++){if(literal){if(format.charAt(iFormat)=="'"&&!lookAhead("'")){literal=false}else{chars+=format.charAt(iFormat)}}else{switch(format.charAt(iFormat)){case"d":case"m":case"y":case"@":chars+="0123456789";break;case"D":case"M":return null;case"'":if(lookAhead("'")){chars+="'"}else{literal=true}break;default:chars+=format.charAt(iFormat)}}}return chars},_get:function(inst,name){return inst.settings[name]!==undefined?inst.settings[name]:this._defaults[name]},_setDateFromField:function(inst){var dateFormat=this._get(inst,"dateFormat");var dates=inst.input?inst.input.val():null;inst.endDay=inst.endMonth=inst.endYear=null;var date=defaultDate=this._getDefaultDate(inst);var settings=this._getFormatConfig(inst);try{date=this.parseDate(dateFormat,dates,settings)||defaultDate}catch(event){this.log(event);date=defaultDate}inst.selectedDay=date.getDate();inst.drawMonth=inst.selectedMonth=date.getMonth();inst.drawYear=inst.selectedYear=date.getFullYear();inst.currentDay=(dates?date.getDate():0);inst.currentMonth=(dates?date.getMonth():0);inst.currentYear=(dates?date.getFullYear():0);this._adjustInstDate(inst)},_getDefaultDate:function(inst){var date=this._determineDate(this._get(inst,"defaultDate"),new Date());var minDate=this._getMinMaxDate(inst,"min",true);var maxDate=this._getMinMaxDate(inst,"max");date=(minDate&&date<minDate?minDate:date);date=(maxDate&&date>maxDate?maxDate:date);return date},_determineDate:function(date,defaultDate){var offsetNumeric=function(offset){var date=new Date();date.setDate(date.getDate()+offset);return date};var offsetString=function(offset,getDaysInMonth){var date=new Date();var year=date.getFullYear();var month=date.getMonth();var day=date.getDate();var pattern=/([+-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g;var matches=pattern.exec(offset);while(matches){switch(matches[2]||"d"){case"d":case"D":day+=parseInt(matches[1],10);break;case"w":case"W":day+=parseInt(matches[1],10)*7;break;case"m":case"M":month+=parseInt(matches[1],10);day=Math.min(day,getDaysInMonth(year,month));break;case"y":case"Y":year+=parseInt(matches[1],10);day=Math.min(day,getDaysInMonth(year,month));break}matches=pattern.exec(offset)}return new Date(year,month,day)};date=(date==null?defaultDate:(typeof date=="string"?offsetString(date,this._getDaysInMonth):(typeof date=="number"?(isNaN(date)?defaultDate:offsetNumeric(date)):date)));date=(date&&date.toString()=="Invalid Date"?defaultDate:date);if(date){date.setHours(0);date.setMinutes(0);date.setSeconds(0);date.setMilliseconds(0)}return this._daylightSavingAdjust(date)},_daylightSavingAdjust:function(date){if(!date){return null}date.setHours(date.getHours()>12?date.getHours()+2:0);return date},_setDate:function(inst,date,endDate){var clear=!(date);var origMonth=inst.selectedMonth;var origYear=inst.selectedYear;date=this._determineDate(date,new Date());inst.selectedDay=inst.currentDay=date.getDate();inst.drawMonth=inst.selectedMonth=inst.currentMonth=date.getMonth();inst.drawYear=inst.selectedYear=inst.currentYear=date.getFullYear();if(origMonth!=inst.selectedMonth||origYear!=inst.selectedYear){this._notifyChange(inst)}this._adjustInstDate(inst);if(inst.input){inst.input.val(clear?"":this._formatDate(inst))}},_getDate:function(inst){var startDate=(!inst.currentYear||(inst.input&&inst.input.val()=="")?null:this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));return startDate},_generateHTML:function(inst){var today=new Date();today=this._daylightSavingAdjust(new Date(today.getFullYear(),today.getMonth(),today.getDate()));var isRTL=this._get(inst,"isRTL");var showButtonPanel=this._get(inst,"showButtonPanel");var hideIfNoPrevNext=this._get(inst,"hideIfNoPrevNext");var navigationAsDateFormat=this._get(inst,"navigationAsDateFormat");var numMonths=this._getNumberOfMonths(inst);var showCurrentAtPos=this._get(inst,"showCurrentAtPos");var stepMonths=this._get(inst,"stepMonths");var stepBigMonths=this._get(inst,"stepBigMonths");var isMultiMonth=(numMonths[0]!=1||numMonths[1]!=1);var currentDate=this._daylightSavingAdjust((!inst.currentDay?new Date(9999,9,9):new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));var minDate=this._getMinMaxDate(inst,"min",true);var maxDate=this._getMinMaxDate(inst,"max");var drawMonth=inst.drawMonth-showCurrentAtPos;var drawYear=inst.drawYear;if(drawMonth<0){drawMonth+=12;drawYear--}if(maxDate){var maxDraw=this._daylightSavingAdjust(new Date(maxDate.getFullYear(),maxDate.getMonth()-numMonths[1]+1,maxDate.getDate()));maxDraw=(minDate&&maxDraw<minDate?minDate:maxDraw);while(this._daylightSavingAdjust(new Date(drawYear,drawMonth,1))>maxDraw){drawMonth--;if(drawMonth<0){drawMonth=11;drawYear--}}}inst.drawMonth=drawMonth;inst.drawYear=drawYear;var prevText=this._get(inst,"prevText");prevText=(!navigationAsDateFormat?prevText:this.formatDate(prevText,this._daylightSavingAdjust(new Date(drawYear,drawMonth-stepMonths,1)),this._getFormatConfig(inst)));var prev=(this._canAdjustMonth(inst,-1,drawYear,drawMonth)?'<a class="ui-datepicker-prev ui-corner-all" onclick="DP_jQuery.datepicker._adjustDate(\'#'+inst.id+"', -"+stepMonths+", 'M');\" title=\""+prevText+'"><span class="ui-icon ui-icon-circle-triangle-'+(isRTL?"e":"w")+'">'+prevText+"</span></a>":(hideIfNoPrevNext?"":'<a class="ui-datepicker-prev ui-corner-all ui-state-disabled" title="'+prevText+'"><span class="ui-icon ui-icon-circle-triangle-'+(isRTL?"e":"w")+'">'+prevText+"</span></a>"));var nextText=this._get(inst,"nextText");nextText=(!navigationAsDateFormat?nextText:this.formatDate(nextText,this._daylightSavingAdjust(new Date(drawYear,drawMonth+stepMonths,1)),this._getFormatConfig(inst)));var next=(this._canAdjustMonth(inst,+1,drawYear,drawMonth)?'<a class="ui-datepicker-next ui-corner-all" onclick="DP_jQuery.datepicker._adjustDate(\'#'+inst.id+"', +"+stepMonths+", 'M');\" title=\""+nextText+'"><span class="ui-icon ui-icon-circle-triangle-'+(isRTL?"w":"e")+'">'+nextText+"</span></a>":(hideIfNoPrevNext?"":'<a class="ui-datepicker-next ui-corner-all ui-state-disabled" title="'+nextText+'"><span class="ui-icon ui-icon-circle-triangle-'+(isRTL?"w":"e")+'">'+nextText+"</span></a>"));var currentText=this._get(inst,"currentText");var gotoDate=(this._get(inst,"gotoCurrent")&&inst.currentDay?currentDate:today);currentText=(!navigationAsDateFormat?currentText:this.formatDate(currentText,gotoDate,this._getFormatConfig(inst)));var controls=(!inst.inline?'<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" onclick="DP_jQuery.datepicker._hideDatepicker();">'+this._get(inst,"closeText")+"</button>":"");var buttonPanel=(showButtonPanel)?'<div class="ui-datepicker-buttonpane ui-widget-content">'+(isRTL?controls:"")+(this._isInRange(inst,gotoDate)?'<button type="button" class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" onclick="DP_jQuery.datepicker._gotoToday(\'#'+inst.id+"');\">"+currentText+"</button>":"")+(isRTL?"":controls)+"</div>":"";var firstDay=parseInt(this._get(inst,"firstDay"),10);firstDay=(isNaN(firstDay)?0:firstDay);var dayNames=this._get(inst,"dayNames");var dayNamesShort=this._get(inst,"dayNamesShort");var dayNamesMin=this._get(inst,"dayNamesMin");var monthNames=this._get(inst,"monthNames");var monthNamesShort=this._get(inst,"monthNamesShort");var beforeShowDay=this._get(inst,"beforeShowDay");var showOtherMonths=this._get(inst,"showOtherMonths");var calculateWeek=this._get(inst,"calculateWeek")||this.iso8601Week;var endDate=inst.endDay?this._daylightSavingAdjust(new Date(inst.endYear,inst.endMonth,inst.endDay)):currentDate;var defaultDate=this._getDefaultDate(inst);var html="";for(var row=0;row<numMonths[0];row++){var group="";for(var col=0;col<numMonths[1];col++){var selectedDate=this._daylightSavingAdjust(new Date(drawYear,drawMonth,inst.selectedDay));var cornerClass=" ui-corner-all";var calender="";if(isMultiMonth){calender+='<div class="ui-datepicker-group ui-datepicker-group-';switch(col){case 0:calender+="first";cornerClass=" ui-corner-"+(isRTL?"right":"left");break;case numMonths[1]-1:calender+="last";cornerClass=" ui-corner-"+(isRTL?"left":"right");break;default:calender+="middle";cornerClass="";break}calender+='">'}calender+='<div class="ui-datepicker-header ui-widget-header ui-helper-clearfix'+cornerClass+'">'+(/all|left/.test(cornerClass)&&row==0?(isRTL?next:prev):"")+(/all|right/.test(cornerClass)&&row==0?(isRTL?prev:next):"")+this._generateMonthYearHeader(inst,drawMonth,drawYear,minDate,maxDate,selectedDate,row>0||col>0,monthNames,monthNamesShort)+'</div><table class="ui-datepicker-calendar"><thead><tr>';var thead="";for(var dow=0;dow<7;dow++){var day=(dow+firstDay)%7;thead+="<th"+((dow+firstDay+6)%7>=5?' class="ui-datepicker-week-end"':"")+'><span title="'+dayNames[day]+'">'+dayNamesMin[day]+"</span></th>"}calender+=thead+"</tr></thead><tbody>";var daysInMonth=this._getDaysInMonth(drawYear,drawMonth);if(drawYear==inst.selectedYear&&drawMonth==inst.selectedMonth){inst.selectedDay=Math.min(inst.selectedDay,daysInMonth)}var leadDays=(this._getFirstDayOfMonth(drawYear,drawMonth)-firstDay+7)%7;var numRows=(isMultiMonth?6:Math.ceil((leadDays+daysInMonth)/7));var printDate=this._daylightSavingAdjust(new Date(drawYear,drawMonth,1-leadDays));for(var dRow=0;dRow<numRows;dRow++){calender+="<tr>";var tbody="";for(var dow=0;dow<7;dow++){var daySettings=(beforeShowDay?beforeShowDay.apply((inst.input?inst.input[0]:null),[printDate]):[true,""]);var otherMonth=(printDate.getMonth()!=drawMonth);var unselectable=otherMonth||!daySettings[0]||(minDate&&printDate<minDate)||(maxDate&&printDate>maxDate);tbody+='<td class="'+((dow+firstDay+6)%7>=5?" ui-datepicker-week-end":"")+(otherMonth?" ui-datepicker-other-month":"")+((printDate.getTime()==selectedDate.getTime()&&drawMonth==inst.selectedMonth&&inst._keyEvent)||(defaultDate.getTime()==printDate.getTime()&&defaultDate.getTime()==selectedDate.getTime())?" "+this._dayOverClass:"")+(unselectable?" "+this._unselectableClass+" ui-state-disabled":"")+(otherMonth&&!showOtherMonths?"":" "+daySettings[1]+(printDate.getTime()>=currentDate.getTime()&&printDate.getTime()<=endDate.getTime()?" "+this._currentClass:"")+(printDate.getTime()==today.getTime()?" ui-datepicker-today":""))+'"'+((!otherMonth||showOtherMonths)&&daySettings[2]?' title="'+daySettings[2]+'"':"")+(unselectable?"":" onclick=\"DP_jQuery.datepicker._selectDay('#"+inst.id+"',"+drawMonth+","+drawYear+', this);return false;"')+">"+(otherMonth?(showOtherMonths?printDate.getDate():"&#xa0;"):(unselectable?'<span class="ui-state-default">'+printDate.getDate()+"</span>":'<a class="ui-state-default'+(printDate.getTime()==today.getTime()?" ui-state-highlight":"")+(printDate.getTime()>=currentDate.getTime()&&printDate.getTime()<=endDate.getTime()?" ui-state-active":"")+'" href="#">'+printDate.getDate()+"</a>"))+"</td>";printDate.setDate(printDate.getDate()+1);printDate=this._daylightSavingAdjust(printDate)}calender+=tbody+"</tr>"}drawMonth++;if(drawMonth>11){drawMonth=0;drawYear++}calender+="</tbody></table>"+(isMultiMonth?"</div>"+((numMonths[0]>0&&col==numMonths[1]-1)?'<div class="ui-datepicker-row-break"></div>':""):"");group+=calender}html+=group}html+=buttonPanel+($.browser.msie&&parseInt($.browser.version,10)<7&&!inst.inline?'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>':"");inst._keyEvent=false;return html},_generateMonthYearHeader:function(inst,drawMonth,drawYear,minDate,maxDate,selectedDate,secondary,monthNames,monthNamesShort){minDate=(inst.rangeStart&&minDate&&selectedDate<minDate?selectedDate:minDate);var changeMonth=this._get(inst,"changeMonth");var changeYear=this._get(inst,"changeYear");var showMonthAfterYear=this._get(inst,"showMonthAfterYear");var html='<div class="ui-datepicker-title">';var monthHtml="";if(secondary||!changeMonth){monthHtml+='<span class="ui-datepicker-month">'+monthNames[drawMonth]+"</span> "}else{var inMinYear=(minDate&&minDate.getFullYear()==drawYear);var inMaxYear=(maxDate&&maxDate.getFullYear()==drawYear);monthHtml+='<select class="ui-datepicker-month" onchange="DP_jQuery.datepicker._selectMonthYear(\'#'+inst.id+"', this, 'M');\" onclick=\"DP_jQuery.datepicker._clickMonthYear('#"+inst.id+"');\">";for(var month=0;month<12;month++){if((!inMinYear||month>=minDate.getMonth())&&(!inMaxYear||month<=maxDate.getMonth())){monthHtml+='<option value="'+month+'"'+(month==drawMonth?' selected="selected"':"")+">"+monthNamesShort[month]+"</option>"}}monthHtml+="</select>"}if(!showMonthAfterYear){html+=monthHtml+((secondary||changeMonth||changeYear)&&(!(changeMonth&&changeYear))?"&#xa0;":"")}if(secondary||!changeYear){html+='<span class="ui-datepicker-year">'+drawYear+"</span>"}else{var years=this._get(inst,"yearRange").split(":");var year=0;var endYear=0;if(years.length!=2){year=drawYear-10;endYear=drawYear+10}else{if(years[0].charAt(0)=="+"||years[0].charAt(0)=="-"){year=drawYear+parseInt(years[0],10);endYear=drawYear+parseInt(years[1],10)}else{year=parseInt(years[0],10);endYear=parseInt(years[1],10)}}year=(minDate?Math.max(year,minDate.getFullYear()):year);endYear=(maxDate?Math.min(endYear,maxDate.getFullYear()):endYear);html+='<select class="ui-datepicker-year" onchange="DP_jQuery.datepicker._selectMonthYear(\'#'+inst.id+"', this, 'Y');\" onclick=\"DP_jQuery.datepicker._clickMonthYear('#"+inst.id+"');\">";for(;year<=endYear;year++){html+='<option value="'+year+'"'+(year==drawYear?' selected="selected"':"")+">"+year+"</option>"}html+="</select>"}if(showMonthAfterYear){html+=(secondary||changeMonth||changeYear?"&#xa0;":"")+monthHtml}html+="</div>";return html},_adjustInstDate:function(inst,offset,period){var year=inst.drawYear+(period=="Y"?offset:0);var month=inst.drawMonth+(period=="M"?offset:0);var day=Math.min(inst.selectedDay,this._getDaysInMonth(year,month))+(period=="D"?offset:0);var date=this._daylightSavingAdjust(new Date(year,month,day));var minDate=this._getMinMaxDate(inst,"min",true);var maxDate=this._getMinMaxDate(inst,"max");date=(minDate&&date<minDate?minDate:date);date=(maxDate&&date>maxDate?maxDate:date);inst.selectedDay=date.getDate();inst.drawMonth=inst.selectedMonth=date.getMonth();inst.drawYear=inst.selectedYear=date.getFullYear();if(period=="M"||period=="Y"){this._notifyChange(inst)}},_notifyChange:function(inst){var onChange=this._get(inst,"onChangeMonthYear");if(onChange){onChange.apply((inst.input?inst.input[0]:null),[inst.selectedYear,inst.selectedMonth+1,inst])}},_getNumberOfMonths:function(inst){var numMonths=this._get(inst,"numberOfMonths");return(numMonths==null?[1,1]:(typeof numMonths=="number"?[1,numMonths]:numMonths))},_getMinMaxDate:function(inst,minMax,checkRange){var date=this._determineDate(this._get(inst,minMax+"Date"),null);return(!checkRange||!inst.rangeStart?date:(!date||inst.rangeStart>date?inst.rangeStart:date))},_getDaysInMonth:function(year,month){return 32-new Date(year,month,32).getDate()},_getFirstDayOfMonth:function(year,month){return new Date(year,month,1).getDay()},_canAdjustMonth:function(inst,offset,curYear,curMonth){var numMonths=this._getNumberOfMonths(inst);var date=this._daylightSavingAdjust(new Date(curYear,curMonth+(offset<0?offset:numMonths[1]),1));if(offset<0){date.setDate(this._getDaysInMonth(date.getFullYear(),date.getMonth()))}return this._isInRange(inst,date)},_isInRange:function(inst,date){var newMinDate=(!inst.rangeStart?null:this._daylightSavingAdjust(new Date(inst.selectedYear,inst.selectedMonth,inst.selectedDay)));newMinDate=(newMinDate&&inst.rangeStart<newMinDate?inst.rangeStart:newMinDate);var minDate=newMinDate||this._getMinMaxDate(inst,"min");var maxDate=this._getMinMaxDate(inst,"max");return((!minDate||date>=minDate)&&(!maxDate||date<=maxDate))},_getFormatConfig:function(inst){var shortYearCutoff=this._get(inst,"shortYearCutoff");shortYearCutoff=(typeof shortYearCutoff!="string"?shortYearCutoff:new Date().getFullYear()%100+parseInt(shortYearCutoff,10));return{shortYearCutoff:shortYearCutoff,dayNamesShort:this._get(inst,"dayNamesShort"),dayNames:this._get(inst,"dayNames"),monthNamesShort:this._get(inst,"monthNamesShort"),monthNames:this._get(inst,"monthNames")}},_formatDate:function(inst,day,month,year){if(!day){inst.currentDay=inst.selectedDay;inst.currentMonth=inst.selectedMonth;inst.currentYear=inst.selectedYear}var date=(day?(typeof day=="object"?day:this._daylightSavingAdjust(new Date(year,month,day))):this._daylightSavingAdjust(new Date(inst.currentYear,inst.currentMonth,inst.currentDay)));return this.formatDate(this._get(inst,"dateFormat"),date,this._getFormatConfig(inst))}});function extendRemove(target,props){$.extend(target,props);for(var name in props){if(props[name]==null||props[name]==undefined){target[name]=props[name]}}return target}function isArray(a){return(a&&(($.browser.safari&&typeof a=="object"&&a.length)||(a.constructor&&a.constructor.toString().match(/\Array\(\)/))))}$.fn.datepicker=function(options){if(!$.datepicker.initialized){$(document).mousedown($.datepicker._checkExternalClick).find("body").append($.datepicker.dpDiv);$.datepicker.initialized=true}var otherArgs=Array.prototype.slice.call(arguments,1);if(typeof options=="string"&&(options=="isDisabled"||options=="getDate")){return $.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this[0]].concat(otherArgs))}if(options=="option"&&arguments.length==2&&typeof arguments[1]=="string"){return $.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this[0]].concat(otherArgs))}return this.each(function(){typeof options=="string"?$.datepicker["_"+options+"Datepicker"].apply($.datepicker,[this].concat(otherArgs)):$.datepicker._attachDatepicker(this,options)})};$.datepicker=new Datepicker();$.datepicker.initialized=false;$.datepicker.uuid=new Date().getTime();$.datepicker.version="1.7.2";window.DP_jQuery=$})(jQuery);;;jQuery.fn.daterangepicker=function(settings){var rangeInput=jQuery(this);var options=jQuery.extend({presetRanges:[{text:'Today',dateStart:'today',dateEnd:'today'},{text:'Last 7 days',dateStart:'today-7days',dateEnd:'today'},{text:'Month to date',dateStart:function(){return Date.parse('today').moveToFirstDayOfMonth();},dateEnd:'today'},{text:'Year to date',dateStart:function(){var x=Date.parse('today');x.setMonth(0);x.setDate(1);return x;},dateEnd:'today'},{text:'The previous Month',dateStart:function(){return Date.parse('1 month ago').moveToFirstDayOfMonth();},dateEnd:function(){return Date.parse('1 month ago').moveToLastDayOfMonth();}}],presets:{specificDate:'Specific Date',allDatesBefore:'All Dates Before',allDatesAfter:'All Dates After',dateRange:'Date Range'},rangeStartTitle:'Start date',rangeEndTitle:'End date',nextLinkText:'Next',prevLinkText:'Prev',doneButtonText:'Done',earliestDate:Date.parse('-15years'),latestDate:Date.parse('+15years'),rangeSplitter:'-',dateFormat:'m/d/yy',closeOnSelect:true,arrows:false,posX:rangeInput.offset().left,posY:rangeInput.offset().top+rangeInput.outerHeight(),appendTo:'body',onClose:function(){},onOpen:function(){},onChange:function(){},datepickerOptions:null},settings);var datepickerOptions={onSelect:function(){if(rp.find('.ui-daterangepicker-specificDate').is('.ui-state-active')){rp.find('.range-end').datepicker('setDate',rp.find('.range-start').datepicker('getDate'));}
var rangeA=fDate(rp.find('.range-start').datepicker('getDate'));var rangeB=fDate(rp.find('.range-end').datepicker('getDate'));if(rangeInput.length==2){rangeInput.eq(0).val(rangeA);rangeInput.eq(1).val(rangeB);}
else{rangeInput.val((rangeA!=rangeB)?rangeA+' '+options.rangeSplitter+' '+rangeB:rangeA);}
if(options.closeOnSelect){if(!rp.find('li.ui-state-active').is('.ui-daterangepicker-dateRange')&&!rp.is(':animated')){hideRP();}}
options.onChange();},defaultDate:+0};rangeInput.change(options.onChange);options.datepickerOptions=(settings)?jQuery.extend(datepickerOptions,settings.datepickerOptions):datepickerOptions;var inputDateA,inputDateB=Date.parse('today');var inputDateAtemp,inputDateBtemp;if(rangeInput.size()==2){inputDateAtemp=Date.parse(rangeInput.eq(0).val());inputDateBtemp=Date.parse(rangeInput.eq(1).val());if(inputDateAtemp==null){inputDateAtemp=inputDateBtemp;}
if(inputDateBtemp==null){inputDateBtemp=inputDateAtemp;}}
else{inputDateAtemp=Date.parse(rangeInput.val().split(options.rangeSplitter)[0]);inputDateBtemp=Date.parse(rangeInput.val().split(options.rangeSplitter)[1]);if(inputDateBtemp==null){inputDateBtemp=inputDateAtemp;}}
if(inputDateAtemp!=null){inputDateA=inputDateAtemp;}
if(inputDateBtemp!=null){inputDateB=inputDateBtemp;}
var rp=jQuery('<div class="ui-daterangepicker ui-widget ui-helper-clearfix ui-widget-content ui-corner-all"></div>');var rpPresets=(function(){var ul=jQuery('<ul class="ui-widget-content"></ul>').appendTo(rp);jQuery.each(options.presetRanges,function(){jQuery('<li class="ui-daterangepicker-'+this.text.replace(/ /g,'')+' ui-corner-all"><a href="#">'+this.text+'</a></li>').data('dateStart',this.dateStart).data('dateEnd',this.dateEnd).appendTo(ul);});var x=0;jQuery.each(options.presets,function(key,value){jQuery('<li class="ui-daterangepicker-'+key+' preset_'+x+' ui-helper-clearfix ui-corner-all"><span class="ui-icon ui-icon-triangle-1-e"></span><a href="#">'+value+'</a></li>').appendTo(ul);x++;});ul.find('li').hover(function(){jQuery(this).addClass('ui-state-hover');},function(){jQuery(this).removeClass('ui-state-hover');}).click(function(){rp.find('.ui-state-active').removeClass('ui-state-active');jQuery(this).addClass('ui-state-active').clickActions(rp,rpPickers,doneBtn);return false;});return ul;})();function fDate(date){if(!date.getDate()){return'';}
var day=date.getDate();var month=date.getMonth();var year=date.getFullYear();month++;var dateFormat=options.dateFormat;return jQuery.datepicker.formatDate(dateFormat,date);}
jQuery.fn.restoreDateFromData=function(){if(jQuery(this).data('saveDate')){jQuery(this).datepicker('setDate',jQuery(this).data('saveDate')).removeData('saveDate');}
return this;}
jQuery.fn.saveDateToData=function(){if(!jQuery(this).data('saveDate')){jQuery(this).data('saveDate',jQuery(this).datepicker('getDate'));}
return this;}
function showRP(){if(rp.data('state')=='closed'){rp.data('state','open');rp.fadeIn(300);options.onOpen();}}
function hideRP(){if(rp.data('state')=='open'){rp.data('state','closed');rp.fadeOut(300);options.onClose();}}
function toggleRP(){if(rp.data('state')=='open'){hideRP();}
else{showRP();}}
rp.data('state','closed');jQuery.fn.clickActions=function(rp,rpPickers,doneBtn){if(jQuery(this).is('.ui-daterangepicker-specificDate')){doneBtn.hide();rpPickers.show();rp.find('.title-start').text(options.presets.specificDate);rp.find('.range-start').restoreDateFromData().show(400);rp.find('.range-end').restoreDateFromData().hide(400);setTimeout(function(){doneBtn.fadeIn();},400);}
else if(jQuery(this).is('.ui-daterangepicker-allDatesBefore')){doneBtn.hide();rpPickers.show();rp.find('.title-end').text(options.presets.allDatesBefore);rp.find('.range-start').saveDateToData().datepicker('setDate',options.earliestDate).hide(400);rp.find('.range-end').restoreDateFromData().show(400);setTimeout(function(){doneBtn.fadeIn();},400);}
else if(jQuery(this).is('.ui-daterangepicker-allDatesAfter')){doneBtn.hide();rpPickers.show();rp.find('.title-start').text(options.presets.allDatesAfter);rp.find('.range-start').restoreDateFromData().show(400);rp.find('.range-end').saveDateToData().datepicker('setDate',options.latestDate).hide(400);setTimeout(function(){doneBtn.fadeIn();},400);}
else if(jQuery(this).is('.ui-daterangepicker-dateRange')){doneBtn.hide();rpPickers.show();rp.find('.title-start').text(options.rangeStartTitle);rp.find('.title-end').text(options.rangeEndTitle);rp.find('.range-start').restoreDateFromData().show(400);rp.find('.range-end').restoreDateFromData().show(400);setTimeout(function(){doneBtn.fadeIn();},400);}
else{doneBtn.hide();rp.find('.range-start, .range-end').hide(400,function(){rpPickers.hide();});var dateStart=(typeof jQuery(this).data('dateStart')=='string')?Date.parse(jQuery(this).data('dateStart')):jQuery(this).data('dateStart')();var dateEnd=(typeof jQuery(this).data('dateEnd')=='string')?Date.parse(jQuery(this).data('dateEnd')):jQuery(this).data('dateEnd')();rp.find('.range-start').datepicker('setDate',dateStart).find('.ui-datepicker-current-day').trigger('click');rp.find('.range-end').datepicker('setDate',dateEnd).find('.ui-datepicker-current-day').trigger('click');}
return false;}
var rpPickers=jQuery('<div class="ranges ui-widget-header ui-corner-all ui-helper-clearfix"><div class="range-start"><span class="title-start">Start Date</span></div><div class="range-end"><span class="title-end">End Date</span></div></div>').appendTo(rp);rpPickers.find('.range-start, .range-end').datepicker(options.datepickerOptions);rpPickers.find('.range-start').datepicker('setDate',inputDateA);rpPickers.find('.range-end').datepicker('setDate',inputDateB);var doneBtn=jQuery('<button class="btnDone ui-state-default ui-corner-all">'+options.doneButtonText+'</button>').click(function(){rp.find('.ui-datepicker-current-day').trigger('click');hideRP();}).hover(function(){jQuery(this).addClass('ui-state-hover');},function(){jQuery(this).removeClass('ui-state-hover');}).appendTo(rpPickers);jQuery(this).click(function(){toggleRP();return false;});rpPickers.css('display','none').find('.range-start, .range-end, .btnDone').css('display','none');jQuery(options.appendTo).append(rp);rp.wrap('<div class="ui-daterangepickercontain"></div>');if(options.posX){rp.parent().css('left',options.posX);}
if(options.posY){rp.parent().css('top',options.posY);}
if(options.arrows&&rangeInput.size()==1){var prevLink=jQuery('<a href="#" class="ui-daterangepicker-prev ui-corner-all" title="'+options.prevLinkText+'"><span class="ui-icon ui-icon-circle-triangle-w">'+options.prevLinkText+'</span></a>');var nextLink=jQuery('<a href="#" class="ui-daterangepicker-next ui-corner-all" title="'+options.nextLinkText+'"><span class="ui-icon ui-icon-circle-triangle-e">'+options.nextLinkText+'</span></a>');jQuery(this).addClass('ui-rangepicker-input ui-widget-content').wrap('<div class="ui-daterangepicker-arrows ui-widget ui-widget-header ui-helper-clearfix ui-corner-all"></div>').before(prevLink).before(nextLink).parent().find('a').click(function(){var dateA=rpPickers.find('.range-start').datepicker('getDate');var dateB=rpPickers.find('.range-end').datepicker('getDate');var diff=Math.abs(new TimeSpan(dateA-dateB).getTotalMilliseconds())+86400000;if(jQuery(this).is('.ui-daterangepicker-prev')){diff=-diff;}
rpPickers.find('.range-start, .range-end ').each(function(){var thisDate=jQuery(this).datepicker("getDate");if(thisDate==null){return false;}
jQuery(this).datepicker("setDate",thisDate.add({milliseconds:diff})).find('.ui-datepicker-current-day').trigger('click');});return false;}).hover(function(){jQuery(this).addClass('ui-state-hover');},function(){jQuery(this).removeClass('ui-state-hover');});}
jQuery(document).click(function(){if(rp.is(':visible')){hideRP();}});rp.click(function(){return false;}).hide();return this;}
Date.CultureInfo={name:"en-US",englishName:"English (United States)",nativeName:"English (United States)",dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],abbreviatedDayNames:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],shortestDayNames:["Su","Mo","Tu","We","Th","Fr","Sa"],firstLetterDayNames:["S","M","T","W","T","F","S"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],abbreviatedMonthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],amDesignator:"AM",pmDesignator:"PM",firstDayOfWeek:0,twoDigitYearMax:2029,dateElementOrder:"mdy",formatPatterns:{shortDate:"M/d/yyyy",longDate:"dddd, MMMM dd, yyyy",shortTime:"h:mm tt",longTime:"h:mm:ss tt",fullDateTime:"dddd, MMMM dd, yyyy h:mm:ss tt",sortableDateTime:"yyyy-MM-ddTHH:mm:ss",universalSortableDateTime:"yyyy-MM-dd HH:mm:ssZ",rfc1123:"ddd, dd MMM yyyy HH:mm:ss GMT",monthDay:"MMMM dd",yearMonth:"MMMM, yyyy"},regexPatterns:{jan:/^jan(uary)?/i,feb:/^feb(ruary)?/i,mar:/^mar(ch)?/i,apr:/^apr(il)?/i,may:/^may/i,jun:/^jun(e)?/i,jul:/^jul(y)?/i,aug:/^aug(ust)?/i,sep:/^sep(t(ember)?)?/i,oct:/^oct(ober)?/i,nov:/^nov(ember)?/i,dec:/^dec(ember)?/i,sun:/^su(n(day)?)?/i,mon:/^mo(n(day)?)?/i,tue:/^tu(e(s(day)?)?)?/i,wed:/^we(d(nesday)?)?/i,thu:/^th(u(r(s(day)?)?)?)?/i,fri:/^fr(i(day)?)?/i,sat:/^sa(t(urday)?)?/i,future:/^next/i,past:/^last|past|prev(ious)?/i,add:/^(\+|after|from)/i,subtract:/^(\-|before|ago)/i,yesterday:/^yesterday/i,today:/^t(oday)?/i,tomorrow:/^tomorrow/i,now:/^n(ow)?/i,millisecond:/^ms|milli(second)?s?/i,second:/^sec(ond)?s?/i,minute:/^min(ute)?s?/i,hour:/^h(ou)?rs?/i,week:/^w(ee)?k/i,month:/^m(o(nth)?s?)?/i,day:/^d(ays?)?/i,year:/^y((ea)?rs?)?/i,shortMeridian:/^(a|p)/i,longMeridian:/^(a\.?m?\.?|p\.?m?\.?)/i,timezone:/^((e(s|d)t|c(s|d)t|m(s|d)t|p(s|d)t)|((gmt)?\s*(\+|\-)\s*\d\d\d\d?)|gmt)/i,ordinalSuffix:/^\s*(st|nd|rd|th)/i,timeContext:/^\s*(\:|a|p)/i},abbreviatedTimeZoneStandard:{GMT:"-000",EST:"-0400",CST:"-0500",MST:"-0600",PST:"-0700"},abbreviatedTimeZoneDST:{GMT:"-000",EDT:"-0500",CDT:"-0600",MDT:"-0700",PDT:"-0800"}};Date.getMonthNumberFromName=function(name){var n=Date.CultureInfo.monthNames,m=Date.CultureInfo.abbreviatedMonthNames,s=name.toLowerCase();for(var i=0;i<n.length;i++){if(n[i].toLowerCase()==s||m[i].toLowerCase()==s){return i;}}
return-1;};Date.getDayNumberFromName=function(name){var n=Date.CultureInfo.dayNames,m=Date.CultureInfo.abbreviatedDayNames,o=Date.CultureInfo.shortestDayNames,s=name.toLowerCase();for(var i=0;i<n.length;i++){if(n[i].toLowerCase()==s||m[i].toLowerCase()==s){return i;}}
return-1;};Date.isLeapYear=function(year){return(((year%4===0)&&(year%100!==0))||(year%400===0));};Date.getDaysInMonth=function(year,month){return[31,(Date.isLeapYear(year)?29:28),31,30,31,30,31,31,30,31,30,31][month];};Date.getTimezoneOffset=function(s,dst){return(dst||false)?Date.CultureInfo.abbreviatedTimeZoneDST[s.toUpperCase()]:Date.CultureInfo.abbreviatedTimeZoneStandard[s.toUpperCase()];};Date.getTimezoneAbbreviation=function(offset,dst){var n=(dst||false)?Date.CultureInfo.abbreviatedTimeZoneDST:Date.CultureInfo.abbreviatedTimeZoneStandard,p;for(p in n){if(n[p]===offset){return p;}}
return null;};Date.prototype.clone=function(){return new Date(this.getTime());};Date.prototype.compareTo=function(date){if(isNaN(this)){throw new Error(this);}
if(date instanceof Date&&!isNaN(date)){return(this>date)?1:(this<date)?-1:0;}else{throw new TypeError(date);}};Date.prototype.equals=function(date){return(this.compareTo(date)===0);};Date.prototype.between=function(start,end){var t=this.getTime();return t>=start.getTime()&&t<=end.getTime();};Date.prototype.addMilliseconds=function(value){this.setMilliseconds(this.getMilliseconds()+value);return this;};Date.prototype.addSeconds=function(value){return this.addMilliseconds(value*1000);};Date.prototype.addMinutes=function(value){return this.addMilliseconds(value*60000);};Date.prototype.addHours=function(value){return this.addMilliseconds(value*3600000);};Date.prototype.addDays=function(value){return this.addMilliseconds(value*86400000);};Date.prototype.addWeeks=function(value){return this.addMilliseconds(value*604800000);};Date.prototype.addMonths=function(value){var n=this.getDate();this.setDate(1);this.setMonth(this.getMonth()+value);this.setDate(Math.min(n,this.getDaysInMonth()));return this;};Date.prototype.addYears=function(value){return this.addMonths(value*12);};Date.prototype.add=function(config){if(typeof config=="number"){this._orient=config;return this;}
var x=config;if(x.millisecond||x.milliseconds){this.addMilliseconds(x.millisecond||x.milliseconds);}
if(x.second||x.seconds){this.addSeconds(x.second||x.seconds);}
if(x.minute||x.minutes){this.addMinutes(x.minute||x.minutes);}
if(x.hour||x.hours){this.addHours(x.hour||x.hours);}
if(x.month||x.months){this.addMonths(x.month||x.months);}
if(x.year||x.years){this.addYears(x.year||x.years);}
if(x.day||x.days){this.addDays(x.day||x.days);}
return this;};Date._validate=function(value,min,max,name){if(typeof value!="number"){throw new TypeError(value+" is not a Number.");}else if(value<min||value>max){throw new RangeError(value+" is not a valid value for "+name+".");}
return true;};Date.validateMillisecond=function(n){return Date._validate(n,0,999,"milliseconds");};Date.validateSecond=function(n){return Date._validate(n,0,59,"seconds");};Date.validateMinute=function(n){return Date._validate(n,0,59,"minutes");};Date.validateHour=function(n){return Date._validate(n,0,23,"hours");};Date.validateDay=function(n,year,month){return Date._validate(n,1,Date.getDaysInMonth(year,month),"days");};Date.validateMonth=function(n){return Date._validate(n,0,11,"months");};Date.validateYear=function(n){return Date._validate(n,1,9999,"seconds");};Date.prototype.set=function(config){var x=config;if(!x.millisecond&&x.millisecond!==0){x.millisecond=-1;}
if(!x.second&&x.second!==0){x.second=-1;}
if(!x.minute&&x.minute!==0){x.minute=-1;}
if(!x.hour&&x.hour!==0){x.hour=-1;}
if(!x.day&&x.day!==0){x.day=-1;}
if(!x.month&&x.month!==0){x.month=-1;}
if(!x.year&&x.year!==0){x.year=-1;}
if(x.millisecond!=-1&&Date.validateMillisecond(x.millisecond)){this.addMilliseconds(x.millisecond-this.getMilliseconds());}
if(x.second!=-1&&Date.validateSecond(x.second)){this.addSeconds(x.second-this.getSeconds());}
if(x.minute!=-1&&Date.validateMinute(x.minute)){this.addMinutes(x.minute-this.getMinutes());}
if(x.hour!=-1&&Date.validateHour(x.hour)){this.addHours(x.hour-this.getHours());}
if(x.month!==-1&&Date.validateMonth(x.month)){this.addMonths(x.month-this.getMonth());}
if(x.year!=-1&&Date.validateYear(x.year)){this.addYears(x.year-this.getFullYear());}
if(x.day!=-1&&Date.validateDay(x.day,this.getFullYear(),this.getMonth())){this.addDays(x.day-this.getDate());}
if(x.timezone){this.setTimezone(x.timezone);}
if(x.timezoneOffset){this.setTimezoneOffset(x.timezoneOffset);}
return this;};Date.prototype.clearTime=function(){this.setHours(0);this.setMinutes(0);this.setSeconds(0);this.setMilliseconds(0);return this;};Date.prototype.isLeapYear=function(){var y=this.getFullYear();return(((y%4===0)&&(y%100!==0))||(y%400===0));};Date.prototype.isWeekday=function(){return!(this.is().sat()||this.is().sun());};Date.prototype.getDaysInMonth=function(){return Date.getDaysInMonth(this.getFullYear(),this.getMonth());};Date.prototype.moveToFirstDayOfMonth=function(){return this.set({day:1});};Date.prototype.moveToLastDayOfMonth=function(){return this.set({day:this.getDaysInMonth()});};Date.prototype.moveToDayOfWeek=function(day,orient){var diff=(day-this.getDay()+7*(orient||+1))%7;return this.addDays((diff===0)?diff+=7*(orient||+1):diff);};Date.prototype.moveToMonth=function(month,orient){var diff=(month-this.getMonth()+12*(orient||+1))%12;return this.addMonths((diff===0)?diff+=12*(orient||+1):diff);};Date.prototype.getDayOfYear=function(){return Math.floor((this-new Date(this.getFullYear(),0,1))/86400000);};Date.prototype.getWeekOfYear=function(firstDayOfWeek){var y=this.getFullYear(),m=this.getMonth(),d=this.getDate();var dow=firstDayOfWeek||Date.CultureInfo.firstDayOfWeek;var offset=7+1-new Date(y,0,1).getDay();if(offset==8){offset=1;}
var daynum=((Date.UTC(y,m,d,0,0,0)-Date.UTC(y,0,1,0,0,0))/86400000)+1;var w=Math.floor((daynum-offset+7)/7);if(w===dow){y--;var prevOffset=7+1-new Date(y,0,1).getDay();if(prevOffset==2||prevOffset==8){w=53;}else{w=52;}}
return w;};Date.prototype.isDST=function(){return this.toString().match(/(E|C|M|P)(S|D)T/)[2]=="D";};Date.prototype.getTimezone=function(){return Date.getTimezoneAbbreviation(this.getUTCOffset,this.isDST());};Date.prototype.setTimezoneOffset=function(s){var here=this.getTimezoneOffset(),there=Number(s)*-6/10;this.addMinutes(there-here);return this;};Date.prototype.setTimezone=function(s){return this.setTimezoneOffset(Date.getTimezoneOffset(s));};Date.prototype.getUTCOffset=function(){var n=this.getTimezoneOffset()*-10/6,r;if(n<0){r=(n-10000).toString();return r[0]+r.substr(2);}else{r=(n+10000).toString();return"+"+r.substr(1);}};Date.prototype.getDayName=function(abbrev){return abbrev?Date.CultureInfo.abbreviatedDayNames[this.getDay()]:Date.CultureInfo.dayNames[this.getDay()];};Date.prototype.getMonthName=function(abbrev){return abbrev?Date.CultureInfo.abbreviatedMonthNames[this.getMonth()]:Date.CultureInfo.monthNames[this.getMonth()];};Date.prototype._toString=Date.prototype.toString;Date.prototype.toString=function(format){var self=this;var p=function p(s){return(s.toString().length==1)?"0"+s:s;};return format?format.replace(/dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?/g,function(format){switch(format){case"hh":return p(self.getHours()<13?self.getHours():(self.getHours()-12));case"h":return self.getHours()<13?self.getHours():(self.getHours()-12);case"HH":return p(self.getHours());case"H":return self.getHours();case"mm":return p(self.getMinutes());case"m":return self.getMinutes();case"ss":return p(self.getSeconds());case"s":return self.getSeconds();case"yyyy":return self.getFullYear();case"yy":return self.getFullYear().toString().substring(2,4);case"dddd":return self.getDayName();case"ddd":return self.getDayName(true);case"dd":return p(self.getDate());case"d":return self.getDate().toString();case"MMMM":return self.getMonthName();case"MMM":return self.getMonthName(true);case"MM":return p((self.getMonth()+1));case"M":return self.getMonth()+1;case"t":return self.getHours()<12?Date.CultureInfo.amDesignator.substring(0,1):Date.CultureInfo.pmDesignator.substring(0,1);case"tt":return self.getHours()<12?Date.CultureInfo.amDesignator:Date.CultureInfo.pmDesignator;case"zzz":case"zz":case"z":return"";}}):this._toString();};Date.now=function(){return new Date();};Date.today=function(){return Date.now().clearTime();};Date.prototype._orient=+1;Date.prototype.next=function(){this._orient=+1;return this;};Date.prototype.last=Date.prototype.prev=Date.prototype.previous=function(){this._orient=-1;return this;};Date.prototype._is=false;Date.prototype.is=function(){this._is=true;return this;};Number.prototype._dateElement="day";Number.prototype.fromNow=function(){var c={};c[this._dateElement]=this;return Date.now().add(c);};Number.prototype.ago=function(){var c={};c[this._dateElement]=this*-1;return Date.now().add(c);};(function(){var $D=Date.prototype,$N=Number.prototype;var dx=("sunday monday tuesday wednesday thursday friday saturday").split(/\s/),mx=("january february march april may june july august september october november december").split(/\s/),px=("Millisecond Second Minute Hour Day Week Month Year").split(/\s/),de;var df=function(n){return function(){if(this._is){this._is=false;return this.getDay()==n;}
return this.moveToDayOfWeek(n,this._orient);};};for(var i=0;i<dx.length;i++){$D[dx[i]]=$D[dx[i].substring(0,3)]=df(i);}
var mf=function(n){return function(){if(this._is){this._is=false;return this.getMonth()===n;}
return this.moveToMonth(n,this._orient);};};for(var j=0;j<mx.length;j++){$D[mx[j]]=$D[mx[j].substring(0,3)]=mf(j);}
var ef=function(j){return function(){if(j.substring(j.length-1)!="s"){j+="s";}
return this["add"+j](this._orient);};};var nf=function(n){return function(){this._dateElement=n;return this;};};for(var k=0;k<px.length;k++){de=px[k].toLowerCase();$D[de]=$D[de+"s"]=ef(px[k]);$N[de]=$N[de+"s"]=nf(de);}}());Date.prototype.toJSONString=function(){return this.toString("yyyy-MM-ddThh:mm:ssZ");};Date.prototype.toShortDateString=function(){return this.toString(Date.CultureInfo.formatPatterns.shortDatePattern);};Date.prototype.toLongDateString=function(){return this.toString(Date.CultureInfo.formatPatterns.longDatePattern);};Date.prototype.toShortTimeString=function(){return this.toString(Date.CultureInfo.formatPatterns.shortTimePattern);};Date.prototype.toLongTimeString=function(){return this.toString(Date.CultureInfo.formatPatterns.longTimePattern);};Date.prototype.getOrdinal=function(){switch(this.getDate()){case 1:case 21:case 31:return"st";case 2:case 22:return"nd";case 3:case 23:return"rd";default:return"th";}};(function(){Date.Parsing={Exception:function(s){this.message="Parse error at '"+s.substring(0,10)+" ...'";}};var $P=Date.Parsing;var _=$P.Operators={rtoken:function(r){return function(s){var mx=s.match(r);if(mx){return([mx[0],s.substring(mx[0].length)]);}else{throw new $P.Exception(s);}};},token:function(s){return function(s){return _.rtoken(new RegExp("^\s*"+s+"\s*"))(s);};},stoken:function(s){return _.rtoken(new RegExp("^"+s));},until:function(p){return function(s){var qx=[],rx=null;while(s.length){try{rx=p.call(this,s);}catch(e){qx.push(rx[0]);s=rx[1];continue;}
break;}
return[qx,s];};},many:function(p){return function(s){var rx=[],r=null;while(s.length){try{r=p.call(this,s);}catch(e){return[rx,s];}
rx.push(r[0]);s=r[1];}
return[rx,s];};},optional:function(p){return function(s){var r=null;try{r=p.call(this,s);}catch(e){return[null,s];}
return[r[0],r[1]];};},not:function(p){return function(s){try{p.call(this,s);}catch(e){return[null,s];}
throw new $P.Exception(s);};},ignore:function(p){return p?function(s){var r=null;r=p.call(this,s);return[null,r[1]];}:null;},product:function(){var px=arguments[0],qx=Array.prototype.slice.call(arguments,1),rx=[];for(var i=0;i<px.length;i++){rx.push(_.each(px[i],qx));}
return rx;},cache:function(rule){var cache={},r=null;return function(s){try{r=cache[s]=(cache[s]||rule.call(this,s));}catch(e){r=cache[s]=e;}
if(r instanceof $P.Exception){throw r;}else{return r;}};},any:function(){var px=arguments;return function(s){var r=null;for(var i=0;i<px.length;i++){if(px[i]==null){continue;}
try{r=(px[i].call(this,s));}catch(e){r=null;}
if(r){return r;}}
throw new $P.Exception(s);};},each:function(){var px=arguments;return function(s){var rx=[],r=null;for(var i=0;i<px.length;i++){if(px[i]==null){continue;}
try{r=(px[i].call(this,s));}catch(e){throw new $P.Exception(s);}
rx.push(r[0]);s=r[1];}
return[rx,s];};},all:function(){var px=arguments,_=_;return _.each(_.optional(px));},sequence:function(px,d,c){d=d||_.rtoken(/^\s*/);c=c||null;if(px.length==1){return px[0];}
return function(s){var r=null,q=null;var rx=[];for(var i=0;i<px.length;i++){try{r=px[i].call(this,s);}catch(e){break;}
rx.push(r[0]);try{q=d.call(this,r[1]);}catch(ex){q=null;break;}
s=q[1];}
if(!r){throw new $P.Exception(s);}
if(q){throw new $P.Exception(q[1]);}
if(c){try{r=c.call(this,r[1]);}catch(ey){throw new $P.Exception(r[1]);}}
return[rx,(r?r[1]:s)];};},between:function(d1,p,d2){d2=d2||d1;var _fn=_.each(_.ignore(d1),p,_.ignore(d2));return function(s){var rx=_fn.call(this,s);return[[rx[0][0],r[0][2]],rx[1]];};},list:function(p,d,c){d=d||_.rtoken(/^\s*/);c=c||null;return(p instanceof Array?_.each(_.product(p.slice(0,-1),_.ignore(d)),p.slice(-1),_.ignore(c)):_.each(_.many(_.each(p,_.ignore(d))),px,_.ignore(c)));},set:function(px,d,c){d=d||_.rtoken(/^\s*/);c=c||null;return function(s){var r=null,p=null,q=null,rx=null,best=[[],s],last=false;for(var i=0;i<px.length;i++){q=null;p=null;r=null;last=(px.length==1);try{r=px[i].call(this,s);}catch(e){continue;}
rx=[[r[0]],r[1]];if(r[1].length>0&&!last){try{q=d.call(this,r[1]);}catch(ex){last=true;}}else{last=true;}
if(!last&&q[1].length===0){last=true;}
if(!last){var qx=[];for(var j=0;j<px.length;j++){if(i!=j){qx.push(px[j]);}}
p=_.set(qx,d).call(this,q[1]);if(p[0].length>0){rx[0]=rx[0].concat(p[0]);rx[1]=p[1];}}
if(rx[1].length<best[1].length){best=rx;}
if(best[1].length===0){break;}}
if(best[0].length===0){return best;}
if(c){try{q=c.call(this,best[1]);}catch(ey){throw new $P.Exception(best[1]);}
best[1]=q[1];}
return best;};},forward:function(gr,fname){return function(s){return gr[fname].call(this,s);};},replace:function(rule,repl){return function(s){var r=rule.call(this,s);return[repl,r[1]];};},process:function(rule,fn){return function(s){var r=rule.call(this,s);return[fn.call(this,r[0]),r[1]];};},min:function(min,rule){return function(s){var rx=rule.call(this,s);if(rx[0].length<min){throw new $P.Exception(s);}
return rx;};}};var _generator=function(op){return function(){var args=null,rx=[];if(arguments.length>1){args=Array.prototype.slice.call(arguments);}else if(arguments[0]instanceof Array){args=arguments[0];}
if(args){for(var i=0,px=args.shift();i<px.length;i++){args.unshift(px[i]);rx.push(op.apply(null,args));args.shift();return rx;}}else{return op.apply(null,arguments);}};};var gx="optional not ignore cache".split(/\s/);for(var i=0;i<gx.length;i++){_[gx[i]]=_generator(_[gx[i]]);}
var _vector=function(op){return function(){if(arguments[0]instanceof Array){return op.apply(null,arguments[0]);}else{return op.apply(null,arguments);}};};var vx="each any all".split(/\s/);for(var j=0;j<vx.length;j++){_[vx[j]]=_vector(_[vx[j]]);}}());(function(){var flattenAndCompact=function(ax){var rx=[];for(var i=0;i<ax.length;i++){if(ax[i]instanceof Array){rx=rx.concat(flattenAndCompact(ax[i]));}else{if(ax[i]){rx.push(ax[i]);}}}
return rx;};Date.Grammar={};Date.Translator={hour:function(s){return function(){this.hour=Number(s);};},minute:function(s){return function(){this.minute=Number(s);};},second:function(s){return function(){this.second=Number(s);};},meridian:function(s){return function(){this.meridian=s.slice(0,1).toLowerCase();};},timezone:function(s){return function(){var n=s.replace(/[^\d\+\-]/g,"");if(n.length){this.timezoneOffset=Number(n);}else{this.timezone=s.toLowerCase();}};},day:function(x){var s=x[0];return function(){this.day=Number(s.match(/\d+/)[0]);};},month:function(s){return function(){this.month=((s.length==3)?Date.getMonthNumberFromName(s):(Number(s)-1));};},year:function(s){return function(){var n=Number(s);this.year=((s.length>2)?n:(n+(((n+2000)<Date.CultureInfo.twoDigitYearMax)?2000:1900)));};},rday:function(s){return function(){switch(s){case"yesterday":this.days=-1;break;case"tomorrow":this.days=1;break;case"today":this.days=0;break;case"now":this.days=0;this.now=true;break;}};},finishExact:function(x){x=(x instanceof Array)?x:[x];var now=new Date();this.year=now.getFullYear();this.month=now.getMonth();this.day=1;this.hour=0;this.minute=0;this.second=0;for(var i=0;i<x.length;i++){if(x[i]){x[i].call(this);}}
this.hour=(this.meridian=="p"&&this.hour<13)?this.hour+12:this.hour;if(this.day>Date.getDaysInMonth(this.year,this.month)){throw new RangeError(this.day+" is not a valid value for days.");}
var r=new Date(this.year,this.month,this.day,this.hour,this.minute,this.second);if(this.timezone){r.set({timezone:this.timezone});}else if(this.timezoneOffset){r.set({timezoneOffset:this.timezoneOffset});}
return r;},finish:function(x){x=(x instanceof Array)?flattenAndCompact(x):[x];if(x.length===0){return null;}
for(var i=0;i<x.length;i++){if(typeof x[i]=="function"){x[i].call(this);}}
if(this.now){return new Date();}
var today=Date.today();var method=null;var expression=!!(this.days!=null||this.orient||this.operator);if(expression){var gap,mod,orient;orient=((this.orient=="past"||this.operator=="subtract")?-1:1);if(this.weekday){this.unit="day";gap=(Date.getDayNumberFromName(this.weekday)-today.getDay());mod=7;this.days=gap?((gap+(orient*mod))%mod):(orient*mod);}
if(this.month){this.unit="month";gap=(this.month-today.getMonth());mod=12;this.months=gap?((gap+(orient*mod))%mod):(orient*mod);this.month=null;}
if(!this.unit){this.unit="day";}
if(this[this.unit+"s"]==null||this.operator!=null){if(!this.value){this.value=1;}
if(this.unit=="week"){this.unit="day";this.value=this.value*7;}
this[this.unit+"s"]=this.value*orient;}
return today.add(this);}else{if(this.meridian&&this.hour){this.hour=(this.hour<13&&this.meridian=="p")?this.hour+12:this.hour;}
if(this.weekday&&!this.day){this.day=(today.addDays((Date.getDayNumberFromName(this.weekday)-today.getDay()))).getDate();}
if(this.month&&!this.day){this.day=1;}
return today.set(this);}}};var _=Date.Parsing.Operators,g=Date.Grammar,t=Date.Translator,_fn;g.datePartDelimiter=_.rtoken(/^([\s\-\.\,\/\x27]+)/);g.timePartDelimiter=_.stoken(":");g.whiteSpace=_.rtoken(/^\s*/);g.generalDelimiter=_.rtoken(/^(([\s\,]|at|on)+)/);var _C={};g.ctoken=function(keys){var fn=_C[keys];if(!fn){var c=Date.CultureInfo.regexPatterns;var kx=keys.split(/\s+/),px=[];for(var i=0;i<kx.length;i++){px.push(_.replace(_.rtoken(c[kx[i]]),kx[i]));}
fn=_C[keys]=_.any.apply(null,px);}
return fn;};g.ctoken2=function(key){return _.rtoken(Date.CultureInfo.regexPatterns[key]);};g.h=_.cache(_.process(_.rtoken(/^(0[0-9]|1[0-2]|[1-9])/),t.hour));g.hh=_.cache(_.process(_.rtoken(/^(0[0-9]|1[0-2])/),t.hour));g.H=_.cache(_.process(_.rtoken(/^([0-1][0-9]|2[0-3]|[0-9])/),t.hour));g.HH=_.cache(_.process(_.rtoken(/^([0-1][0-9]|2[0-3])/),t.hour));g.m=_.cache(_.process(_.rtoken(/^([0-5][0-9]|[0-9])/),t.minute));g.mm=_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.minute));g.s=_.cache(_.process(_.rtoken(/^([0-5][0-9]|[0-9])/),t.second));g.ss=_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.second));g.hms=_.cache(_.sequence([g.H,g.mm,g.ss],g.timePartDelimiter));g.t=_.cache(_.process(g.ctoken2("shortMeridian"),t.meridian));g.tt=_.cache(_.process(g.ctoken2("longMeridian"),t.meridian));g.z=_.cache(_.process(_.rtoken(/^(\+|\-)?\s*\d\d\d\d?/),t.timezone));g.zz=_.cache(_.process(_.rtoken(/^(\+|\-)\s*\d\d\d\d/),t.timezone));g.zzz=_.cache(_.process(g.ctoken2("timezone"),t.timezone));g.timeSuffix=_.each(_.ignore(g.whiteSpace),_.set([g.tt,g.zzz]));g.time=_.each(_.optional(_.ignore(_.stoken("T"))),g.hms,g.timeSuffix);g.d=_.cache(_.process(_.each(_.rtoken(/^([0-2]\d|3[0-1]|\d)/),_.optional(g.ctoken2("ordinalSuffix"))),t.day));g.dd=_.cache(_.process(_.each(_.rtoken(/^([0-2]\d|3[0-1])/),_.optional(g.ctoken2("ordinalSuffix"))),t.day));g.ddd=g.dddd=_.cache(_.process(g.ctoken("sun mon tue wed thu fri sat"),function(s){return function(){this.weekday=s;};}));g.M=_.cache(_.process(_.rtoken(/^(1[0-2]|0\d|\d)/),t.month));g.MM=_.cache(_.process(_.rtoken(/^(1[0-2]|0\d)/),t.month));g.MMM=g.MMMM=_.cache(_.process(g.ctoken("jan feb mar apr may jun jul aug sep oct nov dec"),t.month));g.y=_.cache(_.process(_.rtoken(/^(\d\d?)/),t.year));g.yy=_.cache(_.process(_.rtoken(/^(\d\d)/),t.year));g.yyy=_.cache(_.process(_.rtoken(/^(\d\d?\d?\d?)/),t.year));g.yyyy=_.cache(_.process(_.rtoken(/^(\d\d\d\d)/),t.year));_fn=function(){return _.each(_.any.apply(null,arguments),_.not(g.ctoken2("timeContext")));};g.day=_fn(g.d,g.dd);g.month=_fn(g.M,g.MMM);g.year=_fn(g.yyyy,g.yy);g.orientation=_.process(g.ctoken("past future"),function(s){return function(){this.orient=s;};});g.operator=_.process(g.ctoken("add subtract"),function(s){return function(){this.operator=s;};});g.rday=_.process(g.ctoken("yesterday tomorrow today now"),t.rday);g.unit=_.process(g.ctoken("minute hour day week month year"),function(s){return function(){this.unit=s;};});g.value=_.process(_.rtoken(/^\d\d?(st|nd|rd|th)?/),function(s){return function(){this.value=s.replace(/\D/g,"");};});g.expression=_.set([g.rday,g.operator,g.value,g.unit,g.orientation,g.ddd,g.MMM]);_fn=function(){return _.set(arguments,g.datePartDelimiter);};g.mdy=_fn(g.ddd,g.month,g.day,g.year);g.ymd=_fn(g.ddd,g.year,g.month,g.day);g.dmy=_fn(g.ddd,g.day,g.month,g.year);g.date=function(s){return((g[Date.CultureInfo.dateElementOrder]||g.mdy).call(this,s));};g.format=_.process(_.many(_.any(_.process(_.rtoken(/^(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?)/),function(fmt){if(g[fmt]){return g[fmt];}else{throw Date.Parsing.Exception(fmt);}}),_.process(_.rtoken(/^[^dMyhHmstz]+/),function(s){return _.ignore(_.stoken(s));}))),function(rules){return _.process(_.each.apply(null,rules),t.finishExact);});var _F={};var _get=function(f){return _F[f]=(_F[f]||g.format(f)[0]);};g.formats=function(fx){if(fx instanceof Array){var rx=[];for(var i=0;i<fx.length;i++){rx.push(_get(fx[i]));}
return _.any.apply(null,rx);}else{return _get(fx);}};g._formats=g.formats(["yyyy-MM-ddTHH:mm:ss","ddd, MMM dd, yyyy H:mm:ss tt","ddd MMM d yyyy HH:mm:ss zzz","d"]);g._start=_.process(_.set([g.date,g.time,g.expression],g.generalDelimiter,g.whiteSpace),t.finish);g.start=function(s){try{var r=g._formats.call({},s);if(r[1].length===0){return r;}}catch(e){}
return g._start.call({},s);};}());Date._parse=Date.parse;Date.parse=function(s){var r=null;if(!s){return null;}
try{r=Date.Grammar.start.call({},s);}catch(e){return null;}
return((r[1].length===0)?r[0]:null);};Date.getParseFunction=function(fx){var fn=Date.Grammar.formats(fx);return function(s){var r=null;try{r=fn.call({},s);}catch(e){return null;}
return((r[1].length===0)?r[0]:null);};};Date.parseExact=function(s,fx){return Date.getParseFunction(fx)(s);};var TimeSpan=function(days,hours,minutes,seconds,milliseconds){var attrs="days hours minutes seconds milliseconds".split(/\s+/);var gFn=function(attr){return function(){return this[attr];};};var sFn=function(attr){return function(val){this[attr]=val;return this;};};for(var i=0;i<attrs.length;i++){var $a=attrs[i],$b=$a.slice(0,1).toUpperCase()+$a.slice(1);TimeSpan.prototype[$a]=0;TimeSpan.prototype["get"+$b]=gFn($a);TimeSpan.prototype["set"+$b]=sFn($a);}
if(arguments.length==4){this.setDays(days);this.setHours(hours);this.setMinutes(minutes);this.setSeconds(seconds);}else if(arguments.length==5){this.setDays(days);this.setHours(hours);this.setMinutes(minutes);this.setSeconds(seconds);this.setMilliseconds(milliseconds);}else if(arguments.length==1&&typeof days=="number"){var orient=(days<0)?-1:+1;this.setMilliseconds(Math.abs(days));this.setDays(Math.floor(this.getMilliseconds()/86400000)*orient);this.setMilliseconds(this.getMilliseconds()%86400000);this.setHours(Math.floor(this.getMilliseconds()/3600000)*orient);this.setMilliseconds(this.getMilliseconds()%3600000);this.setMinutes(Math.floor(this.getMilliseconds()/60000)*orient);this.setMilliseconds(this.getMilliseconds()%60000);this.setSeconds(Math.floor(this.getMilliseconds()/1000)*orient);this.setMilliseconds(this.getMilliseconds()%1000);this.setMilliseconds(this.getMilliseconds()*orient);}
this.getTotalMilliseconds=function(){return(this.getDays()*86400000)+(this.getHours()*3600000)+(this.getMinutes()*60000)+(this.getSeconds()*1000);};this.compareTo=function(time){var t1=new Date(1970,1,1,this.getHours(),this.getMinutes(),this.getSeconds()),t2;if(time===null){t2=new Date(1970,1,1,0,0,0);}
else{t2=new Date(1970,1,1,time.getHours(),time.getMinutes(),time.getSeconds());}
return(t1<t2)?-1:(t1>t2)?1:0;};this.equals=function(time){return(this.compareTo(time)===0);};this.add=function(time){return(time===null)?this:this.addSeconds(time.getTotalMilliseconds()/1000);};this.subtract=function(time){return(time===null)?this:this.addSeconds(-time.getTotalMilliseconds()/1000);};this.addDays=function(n){return new TimeSpan(this.getTotalMilliseconds()+(n*86400000));};this.addHours=function(n){return new TimeSpan(this.getTotalMilliseconds()+(n*3600000));};this.addMinutes=function(n){return new TimeSpan(this.getTotalMilliseconds()+(n*60000));};this.addSeconds=function(n){return new TimeSpan(this.getTotalMilliseconds()+(n*1000));};this.addMilliseconds=function(n){return new TimeSpan(this.getTotalMilliseconds()+n);};this.get12HourHour=function(){return(this.getHours()>12)?this.getHours()-12:(this.getHours()===0)?12:this.getHours();};this.getDesignator=function(){return(this.getHours()<12)?Date.CultureInfo.amDesignator:Date.CultureInfo.pmDesignator;};this.toString=function(format){this._toString=function(){if(this.getDays()!==null&&this.getDays()>0){return this.getDays()+"."+this.getHours()+":"+this.p(this.getMinutes())+":"+this.p(this.getSeconds());}
else{return this.getHours()+":"+this.p(this.getMinutes())+":"+this.p(this.getSeconds());}};this.p=function(s){return(s.toString().length<2)?"0"+s:s;};var me=this;return format?format.replace(/dd?|HH?|hh?|mm?|ss?|tt?/g,function(format){switch(format){case"d":return me.getDays();case"dd":return me.p(me.getDays());case"H":return me.getHours();case"HH":return me.p(me.getHours());case"h":return me.get12HourHour();case"hh":return me.p(me.get12HourHour());case"m":return me.getMinutes();case"mm":return me.p(me.getMinutes());case"s":return me.getSeconds();case"ss":return me.p(me.getSeconds());case"t":return((me.getHours()<12)?Date.CultureInfo.amDesignator:Date.CultureInfo.pmDesignator).substring(0,1);case"tt":return(me.getHours()<12)?Date.CultureInfo.amDesignator:Date.CultureInfo.pmDesignator;}}):this._toString();};return this;};Date.prototype.getTimeOfDay=function(){return new TimeSpan(0,this.getHours(),this.getMinutes(),this.getSeconds(),this.getMilliseconds());};var TimePeriod=function(years,months,days,hours,minutes,seconds,milliseconds){var attrs="years months days hours minutes seconds milliseconds".split(/\s+/);var gFn=function(attr){return function(){return this[attr];};};var sFn=function(attr){return function(val){this[attr]=val;return this;};};for(var i=0;i<attrs.length;i++){var $a=attrs[i],$b=$a.slice(0,1).toUpperCase()+$a.slice(1);TimePeriod.prototype[$a]=0;TimePeriod.prototype["get"+$b]=gFn($a);TimePeriod.prototype["set"+$b]=sFn($a);}
if(arguments.length==7){this.years=years;this.months=months;this.setDays(days);this.setHours(hours);this.setMinutes(minutes);this.setSeconds(seconds);this.setMilliseconds(milliseconds);}else if(arguments.length==2&&arguments[0]instanceof Date&&arguments[1]instanceof Date){var d1=years.clone();var d2=months.clone();var temp=d1.clone();var orient=(d1>d2)?-1:+1;this.years=d2.getFullYear()-d1.getFullYear();temp.addYears(this.years);if(orient==+1){if(temp>d2){if(this.years!==0){this.years--;}}}else{if(temp<d2){if(this.years!==0){this.years++;}}}
d1.addYears(this.years);if(orient==+1){while(d1<d2&&d1.clone().addDays(Date.getDaysInMonth(d1.getYear(),d1.getMonth()))<d2){d1.addMonths(1);this.months++;}}
else{while(d1>d2&&d1.clone().addDays(-d1.getDaysInMonth())>d2){d1.addMonths(-1);this.months--;}}
var diff=d2-d1;if(diff!==0){var ts=new TimeSpan(diff);this.setDays(ts.getDays());this.setHours(ts.getHours());this.setMinutes(ts.getMinutes());this.setSeconds(ts.getSeconds());this.setMilliseconds(ts.getMilliseconds());}}
return this;};;var browser_ok=($.browser.safari&&$.browser.version>412)||($.browser.opera&&$.browser.version>='9')||($.browser.msie&&$.browser.version>='6')||($.browser.mozilla&&$.browser.version>='1.8');if(!browser_ok)Drupal.jsEnabled=false;function elysia_process_document(){if(typeof elysia_quotes=='function')elysia_quotes();if(typeof spamspan=='function')spamspan();if(typeof KarmaRenderForm=='function'){$("form.karma_form,form.karma_form_promoted").submit(KarmaSendForm).each(KarmaRenderForm);}
elysia_popup_process();}
function elysia_quotes(){var innerbq=$('blockquote blockquote');$('blockquote[processed!=1]').each(function(){$(this).attr('processed','1');for(var i=0;i<innerbq.length;i++)
if(this==innerbq.get(i)){$(this).css('display','block');return;}
var size=160;var content=$(this).html();if(content.length>(size*2)){content=content.replace(/(<br>|<br[ ]*\/>|<\/p>)/gi,'#-OP-#br /#-CL-#');content=content.replace(/<a[ ]+/gi,'#-OP-#a ');content=content.replace(/<(\/a|b|\/b|i|\/i|u|\/u|ul|\/ul|li|\/li|ol|\/ol)>/gi,'#-OP-#$1#-CL-#');content=content.replace(/<[^>]+>/g,'');content=content.replace(/#-OP-#/g,'<');content=content.replace(/#-CL-#/g,'>');var intag=false;var i=0;var d=0;for(;i<content.length;i++){if(content.charAt(i)=='<'){intag=true;if(i+1<content.length&&content.charAt(i+1)=='/')d--;else d++;}
else if(content.charAt(i)=='>'){intag=false;if(i-1>0&&content.charAt(i-1)=='/')d--;}
else if(i>size&&content.charAt(i)==' '&&!intag&&d==0)break;}
if(i<content.length){content=content.substring(0,i);$(this).after('<blockquote processed="1" style="display: none">'+content+'<a href="javascript:void(0)" title="Mostra tutta la citazione" class="quoteshrink"> &gt;&gt;&gt; </a></blockquote>');$(this).next().slideDown(100);$(this).next().find('.quoteshrink').click(function(){$(this).parent().hide();$(this).parent().prev().show();});}}else{$(this).css('display','block');}});}
var elysia_popups=[];var elysia_popups_lastcluetip=null;function elysia_popup_add(selector,options){elysia_popups.push({selector:selector,options:options});}
function elysia_popup_process(){for(var i=0;i<elysia_popups.length;i++){var options=elysia_popups[i].options;$(elysia_popups[i].selector+'[processed!=1]').each(function(i){$(this).attr('processed','1');if(options.intreq){var href=$(this).attr('href');href+=(href.indexOf('?')>0?'&':'?')+'getcontent_intreq';$(this).attr('href_popup',href);if(!options.attribute)options.attribute='href_popup';}else{if(!options.attribute)options.attribute='href';}
if(!options.activation)options.activation='click';if(!options.closePosition)options.closePosition='title';if(!options.closeText)options.closeText='Chiudi';if(!options.dropShadow)options.dropShadow=true;if(!options.onShow)options.onShow=function(cluetip,cluetipInner){elysia_popups_lastcluetip=cluetip;if(typeof elysia_process_document=='function')elysia_process_document();};$(this).cluetip(options);});}}
function elysia_popup_close(){cluetipObjectClose();}
if(Drupal.jsEnabled){$(document).ready(elysia_popup_process);}
function autocomplete_onchange(data,jsAC){if(jsAC.input&&jsAC.input.className.indexOf('relations_autocomplete')>=0){var div=document.getElementById(jsAC.input.name+'_preview');$(div).load(drupalBasePath+'relations/preview/'+encodeURIComponent(jsAC.input.name)+'/'+encodeURIComponent(data));}
if(jsAC.input&&jsAC.input.className.indexOf('channels_autocomplete_node')>=0)
elysia_channel_preview(data,'node');if(jsAC.input&&jsAC.input.className.indexOf('channels_autocomplete_user')>=0)
elysia_channel_preview(data,'user');}
function elysia_channel_add(name){var input=$('#edit-channels-string');var val=input.val();input.val((val!=''?val+', ':'')+name);elysia_channel_preview();return false;}
function elysia_channel_preview(data,type){if(typeof data=='undefined')
data=$('#edit-channels-string').val();if(typeof type=='undefined')
type='node';if(type=='node'){var input=$('#edit-channels-string');if(input&&input.length>0&&input.attr('nodetype'))
type=input.attr('nodetype');else
type='_'+type+'_';}else
type='_'+type+'_';$('#channels_form_preview').load(drupalBasePath+'channels/preview/'+type+'/'+encodeURIComponent(data));}
var _help_jeditable_on=false;function elysia_help_process(){if(typeof $.editable!='undefined')
$.editable.addInputType('locale',{element:function(settings,original){var len=$(original).attr('ehtlen');if(len<40&&settings.height<20&&settings.width<500){var input=$('<input>');if(settings.width!='none'){input.width(settings.width);}
if(settings.height!='none'){input.height(settings.height);}
input.attr('autocomplete','off');$(this).append(input);return(input);}else{var input=$('<textarea>');if(settings.width!='none'){input.width(settings.width+100);}
if(settings.height!='none'){input.height(settings.height+36);}
$(this).append(input);var button=$('<input type="submit" value="save">');$(this).append(button);return(input);}},content:function(string,settings,original){var i=$(':input:first',this);var len=$(original).attr('ehtlen');if($(original).attr('local_site')){string='__'+string;if(len<40&&settings.height<20&&settings.width<500)
i.width(settings.width+20);}
i.val(string);}});if((typeof inlineedit_enable!='undefined')&&inlineedit_enable){var links=$('.elysia_help_link');var locales=$('.ehttedit');if((links&&links.length>0)||(locales&&locales.length>0)){$('div.elysia_help .elysia_help_link').hide();var html=$('<div class="elysia_help_js">Help/Locale</div>');$(document.body).prepend(html);html.css({cursor:'pointer',position:'fixed',top:'4px',right:'2px',backgroundColor:'#FFA0A0',color:'black',border:'1px solid #c0c0c0',padding:'0px 2px',fontSize:'10px',lineHeight:'10px',width:'60px',height:'12px',zIndex:'100'});if($.browser.msie&&$.browser.version<'7')
html.css('position','absolute');$('div.elysia_help_js').one('click',elysia_help_show);}}}
function elysia_help_show(){$('div.elysia_help .elysia_help_link').show();$('div.elysia_help').css('border','1px solid red');$('div.elysia_help_js').one('click',elysia_help_hide);$('div.elysia_help_js').html('Hide Help');if(!_help_jeditable_on){$('#ehttedit_full').css('display','block');$('span.ehttedit').css('border-bottom','1px dotted red');$(document).ready(function(){$(".ehttedit").each(function(){$(this).editable(drupalBasePath+'_save_tt',{tooltip:"Doubleclick to edit "+this.id,type:'locale',event:"dblclick",style:"inherit",placeholder:"...editable..."});})});_help_jeditable_on=true;}}
function elysia_help_hide(){$('div.elysia_help .elysia_help_link').hide();$('div.elysia_help').css('border','inherit');$('div.elysia_help_js').one('click',elysia_help_show);$('div.elysia_help_js').html('Show Help');}
if(Drupal.jsEnabled){$(document).ready(elysia_help_process);}
if($.browser.msie){var ieBookmark;function ieSaveSelect(evt){ieBookmark=tinyMCE.activeEditor.selection.getBookmark();}
function ieLoadSelect(offset){tinyMCE.activeEditor.selection.moveToBookmark(ieBookmark);if(offset>0){}}}
function mceOnInit(){if($.browser.msie){var ed=$(tinyMCE.activeEditor.getBody());ed.select(ieSaveSelect);ed.click(ieSaveSelect);ed.keyup(ieSaveSelect);ed.focus(function(evt){if(ieBookmark)
ieLoadSelect(0);});}}
function mceToggleOn(id,linkid){if(typeof tinyMCE=='undefined'||!tinyMCE)return;if(document.getElementById(linkid)==null){var n=document.createElement('div');n.setAttribute('id',linkid);n.style.display='none';document.body.appendChild(n);}
var editor=tinyMCE.get(id);if(editor&&editor.isHidden())
mceToggle(id,linkid);}
function mceToggleOff(id,linkid){if(typeof tinyMCE=='undefined'||!tinyMCE)return;if(document.getElementById(linkid)==null){var n=document.createElement('div');n.setAttribute('id',linkid);n.style.display='none';document.body.appendChild(n);}
var editor=tinyMCE.get(id);if(editor&&!editor.isHidden())
mceToggle(id,linkid);}
function getQuotesSelText(){if(window.getSelection)return''+window.getSelection();if(document.getSelection)return''+document.getSelection();if(document.selection)return''+document.selection.createRange().text;return'-';}
function doQuote(){if((typeof tinyMCE!='undefined')&&(typeof tinyMCE.activeEditor!='undefined')){var sel=getQuotesSelText();if(!sel)return;if(sel!='-'){sel='</p><blockquote><p>'+sel.replace(/\n/g,'</p><p>')+'</p></blockquote><p>';var editor=tinyMCE.activeEditor;if(ieBookmark){editor.getWin().focus();ieLoadSelect(0);}
editor.execCommand('mceInsertContent',false,sel);return;}}
alert('Le citazioni non sono supportate dal tuo browser!');}
var elysia_editors={};function elysia_init_editor(element,contenttype,editor,options){elysia_editors[element]={'contenttype':contenttype,'editor':editor,'options':options};if(contenttype=='text/html')
elysia_init_editor_text_html(element,editor,options);else if(contenttype=='text/simplehtml')
elysia_init_editor_text_simplehtml(element,editor,options);else if(contenttype=='text/mail_html')
elysia_init_editor_text_mail_html(element,editor,options);else if(contenttype=='text/mail_plain')
elysia_init_editor_text_mail_plain(element,editor,options);else if(contenttype=='text/php')
elysia_init_editor_text_php(element,editor,options);}
function elysia_remove_editor(element){if(elysia_editors[element]){var contenttype=elysia_editors[element].contenttype;var editor=elysia_editors[element].editor;if(contenttype=='text/html')
elysia_remove_editor_text_html(element,editor);else if(contenttype=='text/simplehtml')
elysia_remove_editor_text_simplehtml(element,editor);else if(contenttype=='text/mail_html')
elysia_remove_editor_text_mail_html(element,editor);else if(contenttype=='text/mail_plain')
elysia_remove_editor_text_mail_plain(element,editor);else if(contenttype=='text/php')
elysia_remove_editor_text_php(element,editor);elysia_editors[element]=false;}}
function elysia_switch_editor(element,contenttype,editor,options){elysia_remove_editor(element);elysia_init_editor(element,contenttype,editor,options);}
function elysia_remove_editor_int(element,editor){if(editor=='tinymce'){var editor=tinyMCE.get(element);if(editor)
editor.remove();}else if(editor=='editarea'){editAreaLoader.delete_instance(element);}}
function elysia_init_editor_text_html(element,editor,options){var opts={elements:element,language:"it",content_css:"",height:500,mode:"exact",theme:"advanced",relative_urls:false,safari_warning:false,entity_encoding:"raw",verify_html:false,preformatted:false,convert_fonts_to_spans:false,remove_linebreaks:true,apply_source_formatting:true,theme_advanced_resize_horizontal:false,theme_advanced_resizing_use_cookie:false,plugins:"contextmenu,inlinepopups,paste,style,table",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_path_location:"bottom",theme_advanced_resizing:true,theme_advanced_blockformats:"p,address,pre,h1,h2,h3,h4,h5,h6",theme_advanced_buttons1:"formatselect,fontselect,fontsizeselect,styleprops,removeformat,separator,bold,italic,underline,strikethrough,forecolor,backcolor,sup,sub",theme_advanced_buttons2:"justifyleft,justifycenter,justifyright,justifyfull,bullist,numlist,outdent,indent,separator,image,charmap,hr,tablecontrols",theme_advanced_buttons3:"code,separator,selectall,cut,copy,paste,pastetext,undo,redo,separator,link,unlink,anchor",tab_focus:":prev,:next",convert_urls:false,oninit:"mceOnInit"};if(typeof drupalBasePath!='undefined')
opts.document_base_url=drupalBasePath;if(options)
for(var prop in options)
opts[prop]=options[prop];tinyMCE.init(opts);}
function elysia_remove_editor_text_html(element,editor){elysia_remove_editor_int(element,editor);}
function elysia_init_editor_text_simplehtml(element,editor,options){var opts={elements:element,language:"it",content_css:"",height:200,mode:"exact",theme:"advanced",relative_urls:false,document_base_url:"/",safari_warning:false,entity_encoding:"raw",verify_html:false,preformatted:false,convert_fonts_to_spans:false,remove_linebreaks:false,apply_source_formatting:false,theme_advanced_statusbar_location:'bottom',theme_advanced_path:false,theme_advanced_resizing:true,theme_advanced_resize_horizontal:false,theme_advanced_resizing_use_cookie:false,plugins:"simplehtml,simplepaste",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_blockformats:"p,address,pre,h1,h2,h3,h4,h5,h6",theme_advanced_buttons1:"bold,italic,underline,simplehtml_quote,bullist,simplehtml_debug_1,simplehtml_debug_2",theme_advanced_buttons2:"",theme_advanced_buttons3:"",force_p_newlines:true,cleanup_on_startup:true,inline_styles:false,fix_nesting:true,paste_force_cleanup_wordpaste:false,valid_elements:"b/strong,i/em,u,hr,blockquote",tab_focus:":prev,:next",convert_urls:false,oninit:"mceOnInit"};if(typeof drupalBasePath!='undefined')
opts.document_base_url=drupalBasePath;if(options)
for(var prop in options)
opts[prop]=options[prop];tinyMCE.init(opts);}
function elysia_remove_editor_text_simplehtml(element,editor){elysia_remove_editor_int(element,editor);}
function elysia_init_editor_text_mail_html(element,editor,options){if(editor=='tinymce'){var opts={elements:element,height:600,language:"it",content_css:"",mode:"exact",theme:"advanced",relative_urls:false,safari_warning:false,entity_encoding:"raw",preformatted:false,convert_fonts_to_spans:false,remove_linebreaks:false,apply_source_formatting:false,theme_advanced_resize_horizontal:false,theme_advanced_resizing_use_cookie:false,plugins:"contextmenu,inlinepopups,style,table,fullpage,newsletter",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_path_location:"bottom",theme_advanced_resizing:true,theme_advanced_blockformats:"p,address,pre,h1,h2,h3,h4,h5,h6",theme_advanced_buttons1:"formatselect,fontselect,fontsizeselect,styleprops,removeformat,separator,bold,italic,underline,strikethrough,forecolor,backcolor,sup,sub",theme_advanced_buttons2:"justifyleft,justifycenter,justifyright,justifyfull,bullist,numlist,outdent,indent,separator,image,charmap,hr,tablecontrols",theme_advanced_buttons3:"fullpage,code,separator,cut,copy,paste,undo,redo,separator,link,unlink,anchor,separator,newsletter_profile,newsletter_optlink,newsletter_unsubscribe,newsletter_showlink",inline_styles:false,verify_css_classes:false,skin:"default_raw",convert_urls:false};if(typeof drupalBasePath!='undefined')
opts.document_base_url=drupalBasePath;if(options)
for(var prop in options)
opts[prop]=options[prop];tinyMCE.init(opts);}else{editAreaLoader.init({id:element,start_highlight:true,allow_resize:"both",allow_toggle:false,language:"it",syntax:"html",min_height:600});}}
function elysia_remove_editor_text_mail_html(element,editor){elysia_remove_editor_int(element,editor);}
function elysia_init_editor_text_mail_plain(element,editor,options){var opts={elements:element,height:300,language:"it",content_css:"",mode:"exact",theme:"advanced",relative_urls:false,safari_warning:false,entity_encoding:"raw",verify_html:false,preformatted:true,convert_fonts_to_spans:false,remove_linebreaks:"1",apply_source_formatting:true,theme_advanced_resize_horizontal:false,theme_advanced_resizing_use_cookie:false,plugins:"inlinepopups,contextmenu,newsletter",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_path_location:"bottom",theme_advanced_resizing:true,theme_advanced_blockformats:"p,address,pre,h1,h2,h3,h4,h5,h6",theme_advanced_buttons1:"newsletter_copy_html,newsletter_link,newsletter_profile,newsletter_optlink,newsletter_unsubscribe,newsletter_showlink",theme_advanced_buttons2:"",theme_advanced_buttons3:"",valid_elements:"",convert_newlines_to_brs:true,force_br_newlines:true,force_p_newlines:false,forced_root_block:false,theme_advanced_path:false,skin:"default_raw",convert_urls:false};if(typeof drupalBasePath!='undefined')
opts.document_base_url=drupalBasePath;if(options)
for(var prop in options)
opts[prop]=options[prop];tinyMCE.init(opts);}
function elysia_remove_editor_text_mail_plain(element,editor){elysia_remove_editor_int(element,editor);}
function elysia_init_editor_text_php(element,editor,options){editAreaLoader.init({id:element,start_highlight:true,allow_resize:"both",allow_toggle:false,language:"it",syntax:"php",min_height:500});}
function elysia_remove_editor_text_php(element,editor){elysia_remove_editor_int(element,editor);}
var table_filters={};function _refreshExtendedTablesRows(wrapper,table){$(".FilterTextBoxRows",wrapper).text($("tr:visible",table).length-$("tr.detailrow:visible",table).length-1);}
function _doTableCol(table,col,func){$("tr",table).each(function(){$("td:eq("+col+")",this).each(func);});$("th:eq("+col+")",table).each(func);}
function initExtendedTables(){$("table.table_extended").each(function(){if(this.id&&table_filters[this.id]){var id=this.id;var table=this;$(this).wrap('<div class="table_filter_container" style="position:relative;width:'+$(this).width()+'px"></div>');var wrapper=$(table).parent();$(this).width('100%');var groups='<a href="#" class="groupFilter selected">Tutti ('+($("tr:visible",table).length-$("tr.detailrow:visible",table).length-1)+')</a>';var grouped=false;$("th[group]",table).each(function(){var groupType=$(this).attr('group');var cellData={};var cellDataL=0;var cellIndex=this.cellIndex;$("tr",table).each(function(){$("td:eq("+cellIndex+")",this).each(function(){var text=$(this).attr('groupdata')?$(this).attr('groupdata'):(groupType=='text'?$(this).text():this.innerHTML);var key=text.replace(/[^a-z0-9]+/g,'');if(text){if(typeof cellData[text]=='undefined'){cellData[text]=1;cellDataL++;}else
cellData[text]++;$(this).attr('group',cellIndex+'_'+key);}});});if(cellDataL>1)
for(var i in cellData){var key=i.replace(/[^a-z0-9]+/g,'');groups+='<a href="#" class="groupFilter" groupfilter="'+cellIndex+'_'+key+'">'+i+' ('+cellData[i]+')</a>';grouped=true;}});if(grouped){$(table).before('<div class="extended_table_buttons">'+groups+'</div>');$("a.groupFilter",wrapper).click(function(){$("a.groupFilter",wrapper).removeClass("selected");$("tr",table).show();if($(this).attr('groupfilter'))
$("tr:has(td):not(:has(td[group="+$(this).attr('groupfilter')+"]))").hide();$('.extended_table_filter',wrapper).hide();$('.extended_table_filter_button',wrapper).show();$(this).addClass("selected");$(this).blur();return false;});}else
$(table).before('<div class="extended_table_buttons"></div>');if($(table).hasClass('searchable')){$(table).before('<div class="extended_table_filter" style="display:none">'+table_filters[id][1]+'</div>');$(".extended_table_buttons",wrapper).append('<div class="extended_table_filter_button"><a href="#">'+table_filters[id][0]+'</a></div>');$('.extended_table_filter_button a',wrapper).click(function(){$("tr:hidden",table).show();$('.extended_table_filter',wrapper).show();$('.extended_table_filter_button',wrapper).hide();$(".FilterTextBox",wrapper).val("");_refreshExtendedTablesRows(wrapper,table);return false;});$("tr:has(td)",table).each(function(){var t=$(this).text().toLowerCase();$("<td class='indexColumn' style='display:none'></td>").hide().text(t).appendTo(this);});$(".FilterTextBox",wrapper).keyup(function(){var s=$(this).val().toLowerCase().split(" ");var not=$(".FilterTextBoxNot",wrapper)[0].checked;$("tr:hidden",table).show();if($(this).val().length>0)
$("tr.detailrow",table).hide();$.each(s,function(){if(not)
$("tr:visible .indexColumn:contains('"+this+"')",table).parent().hide();else
$("tr:visible .indexColumn:not(:contains('"+this+"'))",table).parent().hide();});_refreshExtendedTablesRows(wrapper,table);});$(".FilterTextBoxNot",wrapper).click(function(){$(".FilterTextBox",wrapper).keyup();});_refreshExtendedTablesRows(wrapper,table);}
var switchData={};var switchDataOrder=[];$("th[colswitch]",table).each(function(){var key=$(this).attr('colswitch');if(typeof switchData[key]=='undefined'){switchData[key]=[this.cellIndex];switchDataOrder.push(key);}else
switchData[key].push(this.cellIndex);if(switchDataOrder.length>1)
_doTableCol(table,this.cellIndex,function(){$(this).hide()});});if(switchDataOrder.length>1){$(".extended_table_buttons",wrapper).append('<div class="extended_table_colswitch_button"><a href="#">'+switchDataOrder[1]+'</a></div>');$(".extended_table_colswitch_button",wrapper).click(function(){var cur=switchDataOrder.shift();switchDataOrder.push(cur);for(var c in switchData[cur])
_doTableCol(table,switchData[cur][c],function(){$(this).hide()});for(var c in switchData[switchDataOrder[0]])
_doTableCol(table,switchData[switchDataOrder[0]][c],function(){$(this).show()});this.childNodes[0].innerHTML=switchDataOrder[1];$(this).blur();return false;});}
$(".extended_table_buttons",wrapper).append('<div style="clear:both"></div>');}});}
if(Drupal.jsEnabled){$(document).ready(function(){if((typeof tableSorter_enable!='undefined')&&tableSorter_enable){$.tablesorter.isDigit=function(s,config){var exp=/^[-+]?[0-9]+(\.[0-9]{3})*(,[0-9]+)?$/;return RegExp(exp).test($.trim(s));};$.tablesorter.formatFloat=function(s){var i=parseFloat(s.replace(new RegExp(/[^0-9,-]/g),"").replace(new RegExp(/,/g),"."));return(isNaN(i))?0:i;};$('table.tablesorter').each(function(){$(this).tablesorter({textExtraction:function(node){var data=$(node).attr('sortdata');if(typeof data!='undefined')
return data;var mode=$(node).attr('sortmode');if(!mode)
mode='simple';var t="";if(mode=="simple"){if(node.childNodes[0]&&node.childNodes[0].hasChildNodes())
t=node.childNodes[0].innerHTML;else
t=node.innerHTML;}else
t=$(node).text();return t;}})});$('table.tablesorter').bind("sortStart",function(){$("tr.detailrow",this).hide()});}
initExtendedTables();});}
$.fn.extend({caret:function(begin,end){if(this.length==0)return;if(typeof begin=='number'){end=(typeof end=='number')?end:begin;return this.each(function(){if(this.setSelectionRange){this.focus();this.setSelectionRange(begin,end);}else if(this.createTextRange){var range=this.createTextRange();range.collapse(true);range.moveEnd('character',end);range.moveStart('character',begin);range.select();}});}else{if(this[0].setSelectionRange){begin=this[0].selectionStart;end=this[0].selectionEnd;}else if(document.selection&&document.selection.createRange){var range=document.selection.createRange();begin=0-range.duplicate().moveStart('character',-100000);end=begin+range.text.length;}
return{begin:begin,end:end};}}});function CSSStyleSheet(){this.rules=[];this.ruleIndex=[];if(document.createStyleSheet){this.sheet=document.createStyleSheet();}else{this.styleElement=document.createElement("style");document.getElementsByTagName("head")[0].appendChild(this.styleElement);this.sheet=this.styleElement.styleSheet?this.styleElement.styleSheet:this.styleElement.sheet;}}
CSSStyleSheet.prototype.addRule=function(selectorText,ruleText){var result;if(!this.sheet){ruleText=ruleText.replace(/^\{?([^\}])/,"$1");if(!this.ruleIndex[selectorText])
this.ruleIndex[selectorText]=this.rules.length;this.rules[this.ruleIndex[selectorText]]=ruleText;var cssText="";for(var sel in this.ruleIndex)
cssText=sel+" {"+this.rules[this.ruleIndex[sel]]+"}";this.styleElement.innerHTML=cssText;}
else if(this.sheet.addRule){ruleText=ruleText.replace(/^\{?([^\}])/,"$1");var r=this.sheet.rules.length;this.sheet.addRule(selectorText,ruleText);result=this.sheet.rules[r];this.ruleIndex[selectorText]=r;if(this.rules.length==0)
this.rules=this.sheet.rules;}
else if(this.sheet.insertRule){if(!/^\{[^\}]*\}$/.test(ruleText))
ruleText="{"+ruleText+"}";var r=this.sheet.cssRules.length;this.sheet.insertRule(selectorText+" "+ruleText,r);result=this.sheet.cssRules[r];this.ruleIndex[selectorText]=r;if(this.rules.length==0)
this.rules=this.sheet.cssRules;}
else{alert("Cannot create rule");}
return result;}
CSSStyleSheet.prototype.changeRule=function(selectorText,property,value){var index=this.ruleIndex[selectorText];if(typeof index=="undefined"){this.addRule(selectorText,property+":"+value);}
if(!this.sheet){var cssText=this.rules[index];if(cssText){var propSearch=new RegExp("^(.*"+property+"\\s*\:\\s*)([^;]*)(.*)$");var ruleText=propSearch.exec(cssText);if(ruleText){if(ruleText[4]!=value){this.rules[index]=ruleText[1]+value+ruleText[3];}}else{this.rules[index]=cssText+"; "+property+": "+value+";";}
cssText="";for(var sel in this.ruleIndex)
cssText=sel+" {"+this.rules[this.ruleIndex[sel]]+"}";this.styleElement.innerHTML=cssText;}
var cssText="";var cssText="";for(var sel in this.ruleIndex)
cssText=sel+" {"+this.rules[this.ruleIndex[sel]]+"}";}
else if(this.rules[index].style){var m=/^([^-]*)-([a-z])(.*)$/.exec(property);while(m){property=m[1]+m[2].toUpperCase()+m[3];m=/^([^-]*)-([a-z])(.*)$/.exec(property);}
this.rules[index].style[property]=value;}
else if(this.sheet.insertRule){var oldRule=this.rules[index];if(oldRule){var cssText=oldRule.cssText;var propSearch=new RegExp("^[^\\{]*(\\{.*"+property+"\\s*\\:\\s*)([^};]*)([^}]*})");var ruleText=propSearch.exec(cssText);if(ruleText){if(ruleText[4]!=value){cssText=ruleText[1]+value+ruleText[3];this.sheet.deleteRule(index);this.sheet.insertRule(selectorText+" "+cssText,index);}}else{var propSearch=new RegExp("\\{([^}]*)}");ruleText=propSearch.exec(cssText);cssText="{ "+ruleText[1]+"; "+property+": "+value+" }";this.sheet.deleteRule(index);this.sheet.insertRule(selectorText+" "+cssText,index);}}}}
CSSStyleSheet.prototype.getRuleProperty=function(selectorText,property){var index=this.ruleIndex[selectorText];if(typeof index=="undefined"){return;}
if(!this.sheet){var cssText=this.rules[index];if(cssText){var propSearch=new RegExp("^.*"+property+"\s*\:\s*([^;]*)");var ruleText=propSearch.exec(cssText);if(ruleText){return ruleText[1];}}}
else if(this.rules[index].style){var m=/^([^-]*)-([a-z])(.*)$/.exec(property);while(m){property=m[1]+m[2].toUpperCase()+m[3];m=/^([^-]*)-([a-z])(.*)$/.exec(property);}
var style=this.rules[index].style;return style[property];}
else if(this.sheet.insertRule){var oldRule=this.rules[index];if(oldRule){cssText=oldRule.cssText;var propSearch=new RegExp("^.*"+property+"\\s*\\:\\s*([^};]*)");var ruleText=propSearch.exec(cssText);if(ruleText){return ruleText[1];}}}};(function($){$.fn.bgIframe=$.fn.bgiframe=function(s){if($.browser.msie&&/6.0/.test(navigator.userAgent)){s=$.extend({top:'auto',left:'auto',width:'auto',height:'auto',opacity:true,src:'javascript:false;'},s||{});var prop=function(n){return n&&n.constructor==Number?n+'px':n;},html='<iframe class="bgiframe"frameborder="0"tabindex="-1"src="'+s.src+'"'+'style="display:block;position:absolute;z-index:-1;'+(s.opacity!==false?'filter:Alpha(Opacity=\'0\');':'')+'top:'+(s.top=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderTopWidth)||0)*-1)+\'px\')':prop(s.top))+';'+'left:'+(s.left=='auto'?'expression(((parseInt(this.parentNode.currentStyle.borderLeftWidth)||0)*-1)+\'px\')':prop(s.left))+';'+'width:'+(s.width=='auto'?'expression(this.parentNode.offsetWidth+\'px\')':prop(s.width))+';'+'height:'+(s.height=='auto'?'expression(this.parentNode.offsetHeight+\'px\')':prop(s.height))+';'+'"/>';return this.each(function(){if($('> iframe.bgiframe',this).length==0)this.insertBefore(document.createElement(html),this.firstChild);});}return this;};})(jQuery);;var cluetipObjectClose=null;;(function($){$.cluetip={version:'1.0.4'};var $cluetip,$cluetipInner,$cluetipOuter,$cluetipTitle,$cluetipArrows,$cluetipWait,$dropShadow,imgCount;$.fn.cluetip=function(js,options){if(typeof js=='object'){options=js;js=null;}
if(js=='destroy'){return this.unbind('.cluetip');}
return this.each(function(index){var link=this,$this=$(this);var opts=$.extend(true,{},$.fn.cluetip.defaults,options||{},$.metadata?$this.metadata():$.meta?$this.data():{});var cluetipContents=false;var cluezIndex=+opts.cluezIndex;$this.data('thisInfo',{title:link.title,zIndex:cluezIndex});var isActive=false,closeOnDelay=0;if(!$('#cluetip').length){$(['<div id="cluetip">','<div id="cluetip-outer">','<h3 id="cluetip-title"></h3>','<div id="cluetip-inner"></div>','</div>','<div id="cluetip-extra"></div>','<div id="cluetip-arrows" class="cluetip-arrows"></div>','</div>'].join(''))
[insertionType](insertionElement).hide();$cluetip=$('#cluetip').css({position:'absolute'});$cluetipOuter=$('#cluetip-outer').css({position:'relative',zIndex:cluezIndex});$cluetipInner=$('#cluetip-inner');$cluetipTitle=$('#cluetip-title');$cluetipArrows=$('#cluetip-arrows');$cluetipWait=$('<div id="cluetip-waitimage"></div>').css({position:'absolute'}).insertBefore($cluetip).hide();}
var dropShadowSteps=(opts.dropShadow)?+opts.dropShadowSteps:0;if(!$dropShadow){$dropShadow=$([]);for(var i=0;i<dropShadowSteps;i++){$dropShadow=$dropShadow.add($('<div></div>').css({zIndex:cluezIndex-1,opacity:.1,top:1+i,left:1+i}));};$dropShadow.css({position:'absolute',backgroundColor:'#000'}).prependTo($cluetip);}
var tipAttribute=$this.attr(opts.attribute),ctClass=opts.cluetipClass;if(!tipAttribute&&!opts.splitTitle&&!js)return true;if(opts.local&&opts.localPrefix){tipAttribute=opts.localPrefix+tipAttribute;}
if(opts.local&&opts.hideLocal){$(tipAttribute+':first').hide();}
var tOffset=parseInt(opts.topOffset,10),lOffset=parseInt(opts.leftOffset,10);var tipHeight,wHeight,defHeight=isNaN(parseInt(opts.height,10))?'auto':(/\D/g).test(opts.height)?opts.height:opts.height+'px';var sTop,linkTop,posY,tipY,mouseY,baseline;var tipInnerWidth=parseInt(opts.width,10)||275,tipWidth=tipInnerWidth+(parseInt($cluetip.css('paddingLeft'),10)||0)+(parseInt($cluetip.css('paddingRight'),10)||0)+dropShadowSteps,linkWidth=this.offsetWidth,linkLeft,posX,tipX,mouseX,winWidth;var tipParts;var tipTitle=(opts.attribute!='title')?(opts.titleAttribute=='CONTENT'?$this.text():$this.attr(opts.titleAttribute)):'';if(opts.splitTitle){if(tipTitle==undefined){tipTitle='';}
tipParts=tipTitle.split(opts.splitTitle);tipTitle=tipParts.shift();}
if(opts.escapeTitle){tipTitle=tipTitle.replace(/&/g,'&amp;').replace(/>/g,'&gt;').replace(/</g,'&lt;');}
var localContent;function returnFalse(){return false;}
var activate=function(event){if(!opts.onActivate($this)){return false;}
isActive=true;$cluetip.removeClass().css({width:tipInnerWidth});if(tipAttribute==$this.attr('href')){$this.css('cursor',opts.cursor);}
if(opts.hoverClass){$this.addClass(opts.hoverClass);}
linkTop=posY=$this.offset().top;linkLeft=$this.offset().left;mouseX=event.pageX;mouseY=event.pageY;if(link.tagName.toLowerCase()!='area'){sTop=$(document).scrollTop();winWidth=$(window).width();}
if(opts.positionBy=='fixed'){posX=linkWidth+linkLeft+lOffset;$cluetip.css({left:posX});}else{posX=(linkWidth>linkLeft&&linkLeft>tipWidth)||linkLeft+linkWidth+tipWidth+lOffset>winWidth?linkLeft-tipWidth-lOffset:linkWidth+linkLeft+lOffset;if(link.tagName.toLowerCase()=='area'||opts.positionBy=='mouse'||linkWidth+tipWidth>winWidth){if(mouseX+20+tipWidth>winWidth){$cluetip.addClass(' cluetip-'+ctClass);posX=(mouseX-tipWidth-lOffset)>=0?mouseX-tipWidth-lOffset-parseInt($cluetip.css('marginLeft'),10)+parseInt($cluetipInner.css('marginRight'),10):mouseX-(tipWidth/2);}else{posX=mouseX+lOffset;}}
var pY=posX<0?event.pageY+tOffset:event.pageY;$cluetip.css({left:(posX>0&&opts.positionBy!='bottomTop')?posX:(mouseX+(tipWidth/2)>winWidth)?winWidth/2-tipWidth/2:Math.max(mouseX-(tipWidth/2),0),zIndex:$this.data('thisInfo').zIndex});$cluetipArrows.css({zIndex:$this.data('thisInfo').zIndex+1});}
wHeight=$(window).height();if(js){if(typeof js=='function'){js=js(link);}
$cluetipInner.html(js);cluetipShow(pY);}
else if(tipParts){var tpl=tipParts.length;$cluetipInner.html(tipParts[0]);if(tpl>1){for(var i=1;i<tpl;i++){$cluetipInner.append('<div class="split-body">'+tipParts[i]+'</div>');}}
cluetipShow(pY);}
else if(!opts.local&&tipAttribute.indexOf('#')!=0){if(/\.(jpe?g|tiff?|gif|png)$/i.test(tipAttribute)){$cluetipInner.html('<img src="'+tipAttribute+'" alt="'+tipTitle+'" />');cluetipShow(pY);}else if(cluetipContents&&opts.ajaxCache){$cluetipInner.html(cluetipContents);cluetipShow(pY);}else{var optionBeforeSend=opts.ajaxSettings.beforeSend,optionError=opts.ajaxSettings.error,optionSuccess=opts.ajaxSettings.success,optionComplete=opts.ajaxSettings.complete;var ajaxSettings={cache:false,url:tipAttribute,beforeSend:function(xhr){if(optionBeforeSend){optionBeforeSend.call(link,xhr,$cluetip,$cluetipInner);}
$cluetipOuter.children().empty();if(opts.waitImage){$cluetipWait.css({top:mouseY+20,left:mouseX+20,zIndex:$this.data('thisInfo').zIndex-1}).show();}},error:function(xhr,textStatus){if(isActive){if(optionError){optionError.call(link,xhr,textStatus,$cluetip,$cluetipInner);}else{$cluetipInner.html(opts.errorMsg);}}},success:function(data,textStatus){cluetipContents=opts.ajaxProcess.call(link,data);if(isActive){if(optionSuccess){optionSuccess.call(link,data,textStatus,$cluetip,$cluetipInner);}
$cluetipInner.html(cluetipContents);}},complete:function(xhr,textStatus){if(optionComplete){optionComplete.call(link,xhr,textStatus,$cluetip,$cluetipInner);}
imgCount=$('#cluetip-inner img').length;if(imgCount&&!$.browser.opera){$('#cluetip-inner img').bind('load error',function(){imgCount--;if(imgCount<1){$cluetipWait.hide();if(isActive)cluetipShow(pY);}});}else{$cluetipWait.hide();if(isActive){cluetipShow(pY);}}}};var ajaxMergedSettings=$.extend(true,{},opts.ajaxSettings,ajaxSettings);$.ajax(ajaxMergedSettings);}}else if(opts.local){var $localContent=$(tipAttribute+(/#\S+$/.test(tipAttribute)?'':':eq('+index+')')).clone(true).show();$cluetipInner.html($localContent);cluetipShow(pY);}};var cluetipShow=function(bpY){$cluetip.addClass('cluetip-'+ctClass);if(opts.truncate){var $truncloaded=$cluetipInner.text().slice(0,opts.truncate)+'...';$cluetipInner.html($truncloaded);}
function doNothing(){};tipTitle?$cluetipTitle.show().html(tipTitle):(opts.showTitle)?$cluetipTitle.show().html('&nbsp;'):$cluetipTitle.hide();if(opts.sticky){var $closeLink=$('<div id="cluetip-close"><a href="#">'+opts.closeText+'</a></div>');(opts.closePosition=='bottom')?$closeLink.appendTo($cluetipInner):(opts.closePosition=='title')?$closeLink.prependTo($cluetipTitle):$closeLink.prependTo($cluetipInner);$closeLink.bind('click.cluetip',function(){cluetipClose();return false;});if(opts.mouseOutClose){$cluetip.bind('mouseleave.cluetip',function(){cluetipClose();});}else{$cluetip.unbind('mouseleave.cluetip');}}
if(opts.closeOnGenericClick){$(document).one("click",function(){cluetipClose();});}
var direction='';$cluetipOuter.css({zIndex:$this.data('thisInfo').zIndex,overflow:defHeight=='auto'?'visible':'auto',height:defHeight});tipHeight=defHeight=='auto'?Math.max($cluetip.outerHeight(),$cluetip.height()):parseInt(defHeight,10);tipY=posY;baseline=sTop+wHeight;if(opts.positionBy=='fixed'){tipY=posY-opts.dropShadowSteps+tOffset;}else if((posX<mouseX&&Math.max(posX,0)+tipWidth>mouseX)||opts.positionBy=='bottomTop'){if(posY+tipHeight+tOffset>baseline&&mouseY-sTop>tipHeight+tOffset){tipY=mouseY-tipHeight-tOffset;direction='top';}else{tipY=mouseY+tOffset;direction='bottom';}}else if(posY+tipHeight+tOffset>baseline){tipY=(tipHeight>=wHeight)?sTop:baseline-tipHeight-tOffset;}else if($this.css('display')=='block'||link.tagName.toLowerCase()=='area'||opts.positionBy=="mouse"){tipY=bpY-tOffset;}else{tipY=posY-opts.dropShadowSteps;}
if(direction==''){posX<linkLeft?direction='left':direction='right';}
$cluetip.css({top:tipY+'px'}).removeClass().addClass('clue-'+direction+'-'+ctClass).addClass(' cluetip-'+ctClass);if(opts.arrows){var bgY=(posY-tipY-opts.dropShadowSteps);$cluetipArrows.css({top:(/(left|right)/.test(direction)&&posX>=0&&bgY>0)?bgY+'px':/(left|right)/.test(direction)?0:''}).show();}else{$cluetipArrows.hide();}
$dropShadow.hide();$cluetip.hide()[opts.fx.open](opts.fx.open!='show'&&opts.fx.openSpeed);if(opts.dropShadow){$dropShadow.css({height:tipHeight,width:tipInnerWidth,zIndex:$this.data('thisInfo').zIndex-1}).show();}
if($.fn.bgiframe){$cluetip.bgiframe();}
if(opts.delayedClose>0){closeOnDelay=setTimeout(cluetipClose,opts.delayedClose);}
opts.onShow.call(link,$cluetip,$cluetipInner);};var inactivate=function(event){isActive=false;$cluetipWait.hide();if(!opts.sticky||(/click|toggle/).test(opts.activation)){cluetipClose();clearTimeout(closeOnDelay);};if(opts.hoverClass){$this.removeClass(opts.hoverClass);}};var cluetipClose=function(){$cluetipOuter.parent().hide().removeClass();opts.onHide.call(link,$cluetip,$cluetipInner);$this.removeClass('cluetip-clicked');if(tipTitle){$this.attr(opts.titleAttribute,tipTitle);}
$this.css('cursor','');if(opts.arrows)$cluetipArrows.css({top:''});};cluetipObjectClose=cluetipClose;$(document).bind('hideCluetip',function(e){cluetipClose();});if((/click|toggle/).test(opts.activation)){$this.bind('click.cluetip',function(event){if($cluetip.is(':hidden')||!$this.is('.cluetip-clicked')){activate(event);$('.cluetip-clicked').removeClass('cluetip-clicked');$this.addClass('cluetip-clicked');}else{inactivate(event);}
this.blur();return false;});}else if(opts.activation=='focus'){$this.bind('focus.cluetip',function(event){activate(event);});$this.bind('blur.cluetip',function(event){inactivate(event);});}else{$this[opts.clickThrough?'unbind':'bind']('click',returnFalse);var mouseTracks=function(evt){if(opts.tracking==true){var trackX=posX-evt.pageX;var trackY=tipY?tipY-evt.pageY:posY-evt.pageY;$this.bind('mousemove.cluetip',function(evt){$cluetip.css({left:evt.pageX+trackX,top:evt.pageY+trackY});});}};if($.fn.hoverIntent&&opts.hoverIntent){$this.hoverIntent({sensitivity:opts.hoverIntent.sensitivity,interval:opts.hoverIntent.interval,over:function(event){activate(event);mouseTracks(event);},timeout:opts.hoverIntent.timeout,out:function(event){inactivate(event);$this.unbind('mousemove.cluetip');}});}else{$this.bind('mouseenter.cluetip',function(event){activate(event);mouseTracks(event);}).bind('mouseleave.cluetip',function(event){inactivate(event);$this.unbind('mousemove.cluetip');});}
$this.bind('mouseenter.cluetip',function(event){$this.attr('title','');}).bind('mouseleave.cluetip',function(event){$this.attr('title',$this.data('thisInfo').title);});}});};$.fn.cluetip.defaults={width:275,height:'auto',cluezIndex:97,positionBy:'auto',topOffset:15,leftOffset:15,local:false,localPrefix:null,hideLocal:true,attribute:'rel',titleAttribute:'title',splitTitle:'',escapeTitle:false,showTitle:true,cluetipClass:'default',hoverClass:'',waitImage:true,cursor:'help',arrows:false,dropShadow:true,dropShadowSteps:6,sticky:false,mouseOutClose:false,activation:'hover',clickThrough:false,tracking:false,delayedClose:0,closePosition:'top',closeText:'Close',truncate:0,fx:{open:'show',openSpeed:''},hoverIntent:{sensitivity:3,interval:50,timeout:0},onActivate:function(e){return true;},onShow:function(ct,ci){},onHide:function(ct,ci){},ajaxCache:true,ajaxProcess:function(data){data=data.replace(/<(script|style|title)[^<]+<\/(script|style|title)>/gm,'').replace(/<(link|meta)[^>]+>/g,'');return data;},ajaxSettings:{dataType:'html'},errorMsg:'<i>sorry, the contents could not be loaded</i>',debug:false};var insertionType='appendTo',insertionElement='body';$.cluetip.setup=function(options){if(options&&options.insertionType&&(options.insertionType).match(/appendTo|prependTo|insertBefore|insertAfter/)){insertionType=options.insertionType;}
if(options&&options.insertionElement){insertionElement=options.insertionElement;}};})(jQuery);;(function(a){a.widget("ui.tabs",{_init:function(){if(this.options.deselectable!==undefined){this.options.collapsible=this.options.deselectable}this._tabify(true)},_setData:function(b,c){if(b=="selected"){if(this.options.collapsible&&c==this.options.selected){return}this.select(c)}else{this.options[b]=c;if(b=="deselectable"){this.options.collapsible=c}this._tabify()}},_tabId:function(b){return b.title&&b.title.replace(/\s/g,"_").replace(/[^A-Za-z0-9\-_:\.]/g,"")||this.options.idPrefix+a.data(b)},_sanitizeSelector:function(b){return b.replace(/:/g,"\\:")},_cookie:function(){var b=this.cookie||(this.cookie=this.options.cookie.name||"ui-tabs-"+a.data(this.list[0]));return a.cookie.apply(null,[b].concat(a.makeArray(arguments)))},_ui:function(c,b){return{tab:c,panel:b,index:this.anchors.index(c)}},_cleanup:function(){this.lis.filter(".ui-state-processing").removeClass("ui-state-processing").find("span:data(label.tabs)").each(function(){var b=a(this);b.html(b.data("label.tabs")).removeData("label.tabs")})},_tabify:function(n){this.list=this.element.children("ul:first");this.lis=a("li:has(a[href])",this.list);this.anchors=this.lis.map(function(){return a("a",this)[0]});this.panels=a([]);var p=this,d=this.options;var c=/^#.+/;this.anchors.each(function(r,o){var q=a(o).attr("href");var s=q.split("#")[0],u;if(s&&(s===location.toString().split("#")[0]||(u=a("base")[0])&&s===u.href)){q=o.hash;o.href=q}if(c.test(q)){p.panels=p.panels.add(p._sanitizeSelector(q))}else{if(q!="#"){a.data(o,"href.tabs",q);a.data(o,"load.tabs",q.replace(/#.*$/,""));var w=p._tabId(o);o.href="#"+w;var v=a("#"+w);if(!v.length){v=a(d.panelTemplate).attr("id",w).addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").insertAfter(p.panels[r-1]||p.list);v.data("destroy.tabs",true)}p.panels=p.panels.add(v)}else{d.disabled.push(r)}}});if(n){this.element.addClass("ui-tabs ui-widget ui-widget-content ui-corner-all");this.list.addClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");this.lis.addClass("ui-state-default ui-corner-top");this.panels.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom");if(d.selected===undefined){if(location.hash){this.anchors.each(function(q,o){if(o.hash==location.hash){d.selected=q;return false}})}if(typeof d.selected!="number"&&d.cookie){d.selected=parseInt(p._cookie(),10)}if(typeof d.selected!="number"&&this.lis.filter(".ui-tabs-selected").length){d.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"))}d.selected=d.selected||0}else{if(d.selected===null){d.selected=-1}}d.selected=((d.selected>=0&&this.anchors[d.selected])||d.selected<0)?d.selected:0;d.disabled=a.unique(d.disabled.concat(a.map(this.lis.filter(".ui-state-disabled"),function(q,o){return p.lis.index(q)}))).sort();if(a.inArray(d.selected,d.disabled)!=-1){d.disabled.splice(a.inArray(d.selected,d.disabled),1)}this.panels.addClass("ui-tabs-hide");this.lis.removeClass("ui-tabs-selected ui-state-active");if(d.selected>=0&&this.anchors.length){this.panels.eq(d.selected).removeClass("ui-tabs-hide");this.lis.eq(d.selected).addClass("ui-tabs-selected ui-state-active");p.element.queue("tabs",function(){p._trigger("show",null,p._ui(p.anchors[d.selected],p.panels[d.selected]))});this.load(d.selected)}a(window).bind("unload",function(){p.lis.add(p.anchors).unbind(".tabs");p.lis=p.anchors=p.panels=null})}else{d.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"))}this.element[d.collapsible?"addClass":"removeClass"]("ui-tabs-collapsible");if(d.cookie){this._cookie(d.selected,d.cookie)}for(var g=0,m;(m=this.lis[g]);g++){a(m)[a.inArray(g,d.disabled)!=-1&&!a(m).hasClass("ui-tabs-selected")?"addClass":"removeClass"]("ui-state-disabled")}if(d.cache===false){this.anchors.removeData("cache.tabs")}this.lis.add(this.anchors).unbind(".tabs");if(d.event!="mouseover"){var f=function(o,i){if(i.is(":not(.ui-state-disabled)")){i.addClass("ui-state-"+o)}};var j=function(o,i){i.removeClass("ui-state-"+o)};this.lis.bind("mouseover.tabs",function(){f("hover",a(this))});this.lis.bind("mouseout.tabs",function(){j("hover",a(this))});this.anchors.bind("focus.tabs",function(){f("focus",a(this).closest("li"))});this.anchors.bind("blur.tabs",function(){j("focus",a(this).closest("li"))})}var b,h;if(d.fx){if(a.isArray(d.fx)){b=d.fx[0];h=d.fx[1]}else{b=h=d.fx}}function e(i,o){i.css({display:""});if(a.browser.msie&&o.opacity){i[0].style.removeAttribute("filter")}}var k=h?function(i,o){a(i).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");o.hide().removeClass("ui-tabs-hide").animate(h,h.duration||"normal",function(){e(o,h);p._trigger("show",null,p._ui(i,o[0]))})}:function(i,o){a(i).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");o.removeClass("ui-tabs-hide");p._trigger("show",null,p._ui(i,o[0]))};var l=b?function(o,i){i.animate(b,b.duration||"normal",function(){p.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");i.addClass("ui-tabs-hide");e(i,b);p.element.dequeue("tabs")})}:function(o,i,q){p.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");i.addClass("ui-tabs-hide");p.element.dequeue("tabs")};this.anchors.bind(d.event+".tabs",function(){var o=this,r=a(this).closest("li"),i=p.panels.filter(":not(.ui-tabs-hide)"),q=a(p._sanitizeSelector(this.hash));if((r.hasClass("ui-tabs-selected")&&!d.collapsible)||r.hasClass("ui-state-disabled")||r.hasClass("ui-state-processing")||p._trigger("select",null,p._ui(this,q[0]))===false){this.blur();return false}d.selected=p.anchors.index(this);p.abort();if(d.collapsible){if(r.hasClass("ui-tabs-selected")){d.selected=-1;if(d.cookie){p._cookie(d.selected,d.cookie)}p.element.queue("tabs",function(){l(o,i)}).dequeue("tabs");this.blur();return false}else{if(!i.length){if(d.cookie){p._cookie(d.selected,d.cookie)}p.element.queue("tabs",function(){k(o,q)});p.load(p.anchors.index(this));this.blur();return false}}}if(d.cookie){p._cookie(d.selected,d.cookie)}if(q.length){if(i.length){p.element.queue("tabs",function(){l(o,i)})}p.element.queue("tabs",function(){k(o,q)});p.load(p.anchors.index(this))}else{throw"jQuery UI Tabs: Mismatching fragment identifier."}if(a.browser.msie){this.blur()}});this.anchors.bind("click.tabs",function(){return false})},destroy:function(){var b=this.options;this.abort();this.element.unbind(".tabs").removeClass("ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible").removeData("tabs");this.list.removeClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");this.anchors.each(function(){var c=a.data(this,"href.tabs");if(c){this.href=c}var d=a(this).unbind(".tabs");a.each(["href","load","cache"],function(e,f){d.removeData(f+".tabs")})});this.lis.unbind(".tabs").add(this.panels).each(function(){if(a.data(this,"destroy.tabs")){a(this).remove()}else{a(this).removeClass(["ui-state-default","ui-corner-top","ui-tabs-selected","ui-state-active","ui-state-hover","ui-state-focus","ui-state-disabled","ui-tabs-panel","ui-widget-content","ui-corner-bottom","ui-tabs-hide"].join(" "))}});if(b.cookie){this._cookie(null,b.cookie)}},add:function(e,d,c){if(c===undefined){c=this.anchors.length}var b=this,g=this.options,i=a(g.tabTemplate.replace(/#\{href\}/g,e).replace(/#\{label\}/g,d)),h=!e.indexOf("#")?e.replace("#",""):this._tabId(a("a",i)[0]);i.addClass("ui-state-default ui-corner-top").data("destroy.tabs",true);var f=a("#"+h);if(!f.length){f=a(g.panelTemplate).attr("id",h).data("destroy.tabs",true)}f.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom ui-tabs-hide");if(c>=this.lis.length){i.appendTo(this.list);f.appendTo(this.list[0].parentNode)}else{i.insertBefore(this.lis[c]);f.insertBefore(this.panels[c])}g.disabled=a.map(g.disabled,function(k,j){return k>=c?++k:k});this._tabify();if(this.anchors.length==1){i.addClass("ui-tabs-selected ui-state-active");f.removeClass("ui-tabs-hide");this.element.queue("tabs",function(){b._trigger("show",null,b._ui(b.anchors[0],b.panels[0]))});this.load(0)}this._trigger("add",null,this._ui(this.anchors[c],this.panels[c]))},remove:function(b){var d=this.options,e=this.lis.eq(b).remove(),c=this.panels.eq(b).remove();if(e.hasClass("ui-tabs-selected")&&this.anchors.length>1){this.select(b+(b+1<this.anchors.length?1:-1))}d.disabled=a.map(a.grep(d.disabled,function(g,f){return g!=b}),function(g,f){return g>=b?--g:g});this._tabify();this._trigger("remove",null,this._ui(e.find("a")[0],c[0]))},enable:function(b){var c=this.options;if(a.inArray(b,c.disabled)==-1){return}this.lis.eq(b).removeClass("ui-state-disabled");c.disabled=a.grep(c.disabled,function(e,d){return e!=b});this._trigger("enable",null,this._ui(this.anchors[b],this.panels[b]))},disable:function(c){var b=this,d=this.options;if(c!=d.selected){this.lis.eq(c).addClass("ui-state-disabled");d.disabled.push(c);d.disabled.sort();this._trigger("disable",null,this._ui(this.anchors[c],this.panels[c]))}},select:function(b){if(typeof b=="string"){b=this.anchors.index(this.anchors.filter("[href$="+b+"]"))}else{if(b===null){b=-1}}if(b==-1&&this.options.collapsible){b=this.options.selected}this.anchors.eq(b).trigger(this.options.event+".tabs")},load:function(e){var c=this,g=this.options,b=this.anchors.eq(e)[0],d=a.data(b,"load.tabs");this.abort();if(!d||this.element.queue("tabs").length!==0&&a.data(b,"cache.tabs")){this.element.dequeue("tabs");return}this.lis.eq(e).addClass("ui-state-processing");if(g.spinner){var f=a("span",b);f.data("label.tabs",f.html()).html(g.spinner)}this.xhr=a.ajax(a.extend({},g.ajaxOptions,{url:d,success:function(i,h){a(c._sanitizeSelector(b.hash)).html(i);c._cleanup();if(g.cache){a.data(b,"cache.tabs",true)}c._trigger("load",null,c._ui(c.anchors[e],c.panels[e]));try{g.ajaxOptions.success(i,h)}catch(j){}c.element.dequeue("tabs")}}))},abort:function(){this.element.queue([]);this.panels.stop(false,true);if(this.xhr){this.xhr.abort();delete this.xhr}this._cleanup()},url:function(c,b){this.anchors.eq(c).removeData("cache.tabs").data("load.tabs",b)},length:function(){return this.anchors.length}});a.extend(a.ui.tabs,{version:"1.7.2",getter:"length",defaults:{ajaxOptions:null,cache:false,cookie:null,collapsible:false,disabled:[],event:"click",fx:null,idPrefix:"ui-tabs-",panelTemplate:"<div></div>",spinner:"<em>Loading&#8230;</em>",tabTemplate:'<li><a href="#{href}"><span>#{label}</span></a></li>'}});a.extend(a.ui.tabs.prototype,{rotation:null,rotate:function(d,f){var b=this,g=this.options;var c=b._rotate||(b._rotate=function(h){clearTimeout(b.rotation);b.rotation=setTimeout(function(){var i=g.selected;b.select(++i<b.anchors.length?i:0)},d);if(h){h.stopPropagation()}});var e=b._unrotate||(b._unrotate=!f?function(h){if(h.clientX){b.rotate(null)}}:function(h){t=g.selected;c()});if(d){this.element.bind("tabsshow",c);this.anchors.bind(g.event+".tabs",e);c()}else{clearTimeout(b.rotation);this.element.unbind("tabsshow",c);this.anchors.unbind(g.event+".tabs",e);delete this._rotate;delete this._unrotate}}})})(jQuery);;;var elysia_tree_loadqueue=[];var elysia_tree_loading=0;var elysia_tree_maxload=4;var elysia_tree_ajaxon=false;var elysia_tree_nodes=[];var elysia_tree_currentNode=-1;var elysia_tree_nodes_nids={};var elysia_tree_locale={access_denied:'Accesso negato',error_during_load:'Errore durante il caricamento'};function elysia_tree_load(jqel,href,callback){if(elysia_tree_loading<elysia_tree_maxload){elysia_tree_loading++;_elysia_tree_load(jqel,href,callback);}else{elysia_tree_loadqueue.push([jqel,href,callback]);}}
function _elysia_tree_load(jqel,href,callback){jqel.load(href,function(responseText,textStatus,XMLHttpRequest){if(textStatus=='error'){if(XMLHttpRequest.status=='403'){$(this).html('<div class="elysia_tree_forbidden">'+elysia_tree_locale.access_denied+'</div>');}else{$(this).html('<div class="elysia_tree_error">'+elysia_tree_locale.error_during_load+' <!--'+XMLHttpRequest.statusText+'--></div>');}}
if(elysia_tree_loadqueue.length>0){var row=elysia_tree_loadqueue.shift();_elysia_tree_load(row[0],row[1],row[2]);}else
elysia_tree_loading--;if(callback)callback(responseText,textStatus,XMLHttpRequest);});}
function elysia_tree_load_add_locale(type,value){elysia_tree_locale[type]=value;}
function elysia_tree_toggle_event(){if(this.className.indexOf('elysia_disabled')>=0)return false;var nid=this.getAttribute('nid');var treeno=this.getAttribute('treeno');if($(this).is('.elysia_tree_exp_button')){this.className='elysia_tree_comp_button';if(elysia_tree_nodes_nids[nid])
elysia_tree_nodes[elysia_tree_nodes_nids[nid]].setAttribute('open','1');}else{this.className='elysia_tree_exp_button';if(elysia_tree_nodes_nids[nid])
elysia_tree_nodes[elysia_tree_nodes_nids[nid]].setAttribute('open','0');if(elysia_tree_ajaxon)elysia_tree_closeall(treeno,nid);}
$('table#elysia_tree_'+treeno+' tr.elysia_tree_subtree-'+nid).each(function(){if(this.className.indexOf('elysia_tree_hidden')>=0)this.className=this.className.replace('elysia_tree_hidden','elysia_tree_visible');else this.className=this.className.replace('elysia_tree_visible','elysia_tree_hidden');});return false;}
function elysia_tree_expandall_event(){var treeno=$(this).attr('treeno');var bb=$('table'+(treeno?'#elysia_tree_'+treeno:'.elysia_tree')+' a.elysia_tree_exp_button');for(var i=0;i<bb.length;i++)
elysia_tree_toggle_event.call(bb.get(i));}
function elysia_tree_compressall_event(){var treeno=$(this).attr('treeno');var bb=$('table'+(treeno?'#elysia_tree_'+treeno:'.elysia_tree')+' a.elysia_tree_comp_button');for(var i=0;i<bb.length;i++)
elysia_tree_toggle_event.call(bb.get(i));}
function elysia_tree_expand_if_compressed(tr){var expbutt=$(tr).find('.elysia_tree_exp_button');if(expbutt.length>0)
$(expbutt[0]).click();}
function elysia_tree_nodeclick_event(e){e.preventDefault();elysia_tree_nodeclick(this,2);return false;}
function elysia_tree_nodeclick(obj,mode){elysia_tree_currentNode=parseInt(obj.getAttribute('pos'));var nid=$(obj).attr('nid');var treeno=$(obj).attr('treeno');var ref=$('#elysia_tree_gottr_'+treeno+'_'+nid);var tr=$(obj).parents('tr:eq(0)');if(ref.length<=0||!ref.is(":visible"))
elysia_tree_expand_if_compressed(tr);if(ref.length<=0){if(mode==0)return;var href=$(obj).attr('href');href+=(href.indexOf('?')>0?'&':'?')+'getcontent_intreq';var treeln=$(obj).attr('treeln');var trchilds=tr.get(0).childNodes;var emptytd=0;var size=0;for(var i=0;i<trchilds.length;i++){size+=trchilds[i].getAttribute('colspan')?parseInt(trchilds[i].getAttribute('colspan')):1;if(trchilds[i].className.indexOf('elysia_tree_col_title')>=0){if($.browser.msie){trchilds[i].width=trchilds[i].clientWidth;}
emptytd=i;}}
var content='<tr id="elysia_tree_gottr_'+treeno+'_'+nid+'">';if(emptytd)content+='<td'+(emptytd>1?' colspan="'+emptytd+'"':'')+'></td>';content+='<td colspan="'+(size-emptytd)+'"><table border="0" cellpadding="0" cellspacing="0" class="elysia_tree_gotcontent"><tr>';if(treeln)for(var i=0;i<treeln.length;i++)
content+=treeln.charAt(i)=='I'?'<td class="elysia_tree_line_dn"><div></div></td>':'<td class="elysia_tree_line_em"><div></div></td>';content+='<td class="elysia_tree_gotcontent"><div class="elysia_tree_loading"></div></td></tr></table></td></tr>';var ptr=$(content);ptr.addClass(tr.is('.even')?'even':'odd');ptr.addClass('elysia_tree_nodecontent');tr.after(ptr);var el=ptr.find('td.elysia_tree_gotcontent');elysia_tree_load(el,href,function(responseText,textStatus,XMLHttpRequest){if(typeof elysia_process_document=='function')elysia_process_document();});}else{if(mode==2)ref.toggle();else if(mode==1)ref.show();else if(mode==0)ref.hide();}
return false;}
function elysia_tree_readfullclick_event(){var rootnid=$(this).attr('nid');var treeno=$(this).attr('treeno');var nodelinks=$('table#elysia_tree_'+treeno+' a.elysia_tree_node_link[rootnid='+rootnid+']');var allvisible=true;for(var i=0;allvisible&&i<nodelinks.length;i++){var nid=$(nodelinks[i]).attr('nid');var ref=$('#elysia_tree_gottr_'+treeno+'_'+nid);if(ref.length<=0||!ref.is(':visible'))allvisible=false;}
for(var i=0;i<nodelinks.length;i++){var nid=$(nodelinks[i]).attr('nid');var ref=$('#elysia_tree_gottr_'+treeno+'_'+nid);if(allvisible||ref.length<=0||!ref.is(':visible'))$(nodelinks[i]).click();}
return false;}
function elysia_tree_readfullnewclick_event(){elysia_tree_expand_if_compressed($(this).parents('tr:eq(0)'));var rootnid=$(this).attr('nid');var treeno=$(this).attr('treeno');var nodelinks=$('table#elysia_tree_'+treeno+' a.elysia_tree_node_link[rootnid='+rootnid+'][new=1]');for(var i=0;i<nodelinks.length;i++){var nid=$(nodelinks[i]).attr('nid');var ref=$('#elysia_tree_gottr_'+treeno+'_'+nid);if(ref.length<=0||!ref.is(':visible'))$(nodelinks[i]).click();}
return false;}
function elysia_tree_closeall(treeno,rootnid){var nodelinks=$('table#elysia_tree_'+treeno+' a.elysia_tree_node_link[rootnid='+rootnid+']');for(var i=0;i<nodelinks.length;i++){var nid=$(nodelinks[i]).attr('nid');var ref=$('#elysia_tree_gottr_'+treeno+'_'+nid);if(ref.length>0&&ref.is(':visible'))$(nodelinks[i]).click();}
return false;}
function elysia_tree_go(i){var root=elysia_tree_nodes[i].getAttribute('rootnid');var treeno=elysia_tree_nodes[i].getAttribute('treeno');if(root&&elysia_tree_nodes_nids[root]&&elysia_tree_nodes[elysia_tree_nodes_nids[root]].getAttribute('open')!='1')
$('table#elysia_tree_'+treeno+' a.elysia_tree_exp_button[nid='+root+']').click();elysia_tree_nodeclick(elysia_tree_nodes[i],1);$.scrollTo(elysia_tree_nodes[i],500,{axis:'y',offset:{top:-50}});}
function elysia_tree_go_next(){if(elysia_tree_currentNode<elysia_tree_nodes.length-1)
elysia_tree_go(elysia_tree_currentNode+1);}
function elysia_tree_go_prev(){if(elysia_tree_currentNode>0)
elysia_tree_go(elysia_tree_currentNode-1);}
function elysia_tree_go_next_new(){var i=elysia_tree_currentNode;while(++i<elysia_tree_nodes.length-1&&elysia_tree_nodes[i].getAttribute('new')!='1'){}
if(i<elysia_tree_nodes.length-1)
elysia_tree_go(i);}
function elysia_tree_go_prev_new(){var i=elysia_tree_currentNode;while(--i>=0&&elysia_tree_nodes[i].getAttribute('new')!='1'){}
if(i>=0)
elysia_tree_go(i);}
function elysia_tree_go_next_topic(){var i=elysia_tree_currentNode;while(++i<elysia_tree_nodes.length-1&&elysia_tree_nodes[i].getAttribute('root')!='1'){}
if(i<elysia_tree_nodes.length-1)
elysia_tree_go(i);}
function elysia_tree_go_prev_topic(){var i=elysia_tree_currentNode;while(--i>=0&&elysia_tree_nodes[i].getAttribute('root')!='1'){}
if(i>=0)
elysia_tree_go(i);}
if(Drupal.jsEnabled){var elysia_tree_loaded=false;$(document).click(function(e){if(!elysia_tree_loaded){if(!e)
var e=window.event;var targ=e.target?e.target:e.srcElement;if(targ&&targ.nodeType==3)
targ=targ.parentNode;if(targ&&targ.getAttribute('href')){var href=targ.getAttribute('href');return false;}}});}
function elysia_tree_initNoAjax(){$('table.elysia_tree a.elysia_tree_exp_button').click(elysia_tree_toggle_event);$('a.elysia_tree_expandall').click(elysia_tree_expandall_event);$('a.elysia_tree_compressall').each(function(){if(!$(this).is('.elysia_disabled'))
$(this).click(elysia_tree_compressall_event)});elysia_tree_loaded=true;}
function elysia_tree_initAjax(){elysia_tree_ajaxon=true;if(Drupal.jsEnabled){elysia_tree_nodes=$('table.elysia_tree a.elysia_tree_node_link');for(var i=0;i<elysia_tree_nodes.length;i++){elysia_tree_nodes[i].setAttribute('pos',i);elysia_tree_nodes_nids[elysia_tree_nodes[i].getAttribute('nid')]=i;}
elysia_tree_nodes.click(elysia_tree_nodeclick_event);$('table.elysia_tree a.elysia_tree_readfull_button').click(elysia_tree_readfullclick_event);$('table.elysia_tree a.elysia_tree_readfullnew_button').click(elysia_tree_readfullnewclick_event);$(document).bind('keydown',{combi:'j',disableInInput:true},elysia_tree_go_next);$(document).bind('keydown',{combi:'k',disableInInput:true},elysia_tree_go_prev);$(document).bind('keydown',{combi:'n',disableInInput:true},elysia_tree_go_next_new);$(document).bind('keydown',{combi:'m',disableInInput:true},elysia_tree_go_prev_new);$(document).bind('keydown',{combi:'i',disableInInput:true},elysia_tree_go_next_topic);$(document).bind('keydown',{combi:'o',disableInInput:true},elysia_tree_go_prev_topic);}}
$(document).ready(elysia_tree_initNoAjax);function elysia_tree_select_parent(){$('#elysia_tree_select_parent').show();$('#elysia_tree_select_parent_in').load(drupalBasePath+'elysia_tree_select_parent',null,elysia_tree_select_parent_show);return false;}
function elysia_tree_select_parent_show(){elysia_tree_initNoAjax();elysia_tree_initAjax();for(var i=0;i<elysia_tree_nodes.length;i++){$(elysia_tree_nodes[i]).before('<a class="elysia_tree_select_parent" href="javascript:void(0)" onclick="elysia_tree_select_parent_set(\''+elysia_tree_nodes[i].getAttribute('nid')+'\')" title="Scegli genitore">[X]</a> ');}}
function elysia_tree_select_parent_set(nid){$('#edit-treeparentnid').val(nid);}
$(document).ready(function(){$('a.elysia_tree_show_select_parent').click(elysia_tree_select_parent);});;(function(jQuery){jQuery.fn.__bind__=jQuery.fn.bind;jQuery.fn.__unbind__=jQuery.fn.unbind;jQuery.fn.__find__=jQuery.fn.find;var hotkeys={version:'0.7.9',override:/keypress|keydown|keyup/g,triggersMap:{},specialKeys:{27:'esc',9:'tab',32:'space',13:'return',8:'backspace',145:'scroll',20:'capslock',144:'numlock',19:'pause',45:'insert',36:'home',46:'del',35:'end',33:'pageup',34:'pagedown',37:'left',38:'up',39:'right',40:'down',109:'-',112:'f1',113:'f2',114:'f3',115:'f4',116:'f5',117:'f6',118:'f7',119:'f8',120:'f9',121:'f10',122:'f11',123:'f12',191:'/'},shiftNums:{"`":"~","1":"!","2":"@","3":"#","4":"$","5":"%","6":"^","7":"&","8":"*","9":"(","0":")","-":"_","=":"+",";":":","'":"\"",",":"<",".":">","/":"?","\\":"|"},newTrigger:function(type,combi,callback){var result={};result[type]={};result[type][combi]={cb:callback,disableInInput:false};return result;}};hotkeys.specialKeys=jQuery.extend(hotkeys.specialKeys,{96:'0',97:'1',98:'2',99:'3',100:'4',101:'5',102:'6',103:'7',104:'8',105:'9',106:'*',107:'+',109:'-',110:'.',111:'/'});jQuery.fn.find=function(selector){this.query=selector;return jQuery.fn.__find__.apply(this,arguments);};jQuery.fn.unbind=function(type,combi,fn){if(jQuery.isFunction(combi)){fn=combi;combi=null;}
if(combi&&typeof combi==='string'){var selectorId=((this.prevObject&&this.prevObject.query)||(this[0].id&&this[0].id)||this[0]).toString();var hkTypes=type.split(' ');for(var x=0;x<hkTypes.length;x++){delete hotkeys.triggersMap[selectorId][hkTypes[x]][combi];}}
return this.__unbind__(type,fn);};jQuery.fn.bind=function(type,data,fn){var handle=type.match(hotkeys.override);if(jQuery.isFunction(data)||!handle){return this.__bind__(type,data,fn);}
else{var result=null,pass2jq=jQuery.trim(type.replace(hotkeys.override,''));if(pass2jq){result=this.__bind__(pass2jq,data,fn);}
if(typeof data==="string"){data={'combi':data};}
if(data.combi){for(var x=0;x<handle.length;x++){var eventType=handle[x];var combi=data.combi.toLowerCase(),trigger=hotkeys.newTrigger(eventType,combi,fn),selectorId=((this.prevObject&&this.prevObject.query)||(this[0].id&&this[0].id)||this[0]).toString();trigger[eventType][combi].disableInInput=data.disableInInput;if(!hotkeys.triggersMap[selectorId]){hotkeys.triggersMap[selectorId]=trigger;}
else if(!hotkeys.triggersMap[selectorId][eventType]){hotkeys.triggersMap[selectorId][eventType]=trigger[eventType];}
var mapPoint=hotkeys.triggersMap[selectorId][eventType][combi];if(!mapPoint){hotkeys.triggersMap[selectorId][eventType][combi]=[trigger[eventType][combi]];}
else if(mapPoint.constructor!==Array){hotkeys.triggersMap[selectorId][eventType][combi]=[mapPoint];}
else{hotkeys.triggersMap[selectorId][eventType][combi][mapPoint.length]=trigger[eventType][combi];}
this.each(function(){var jqElem=jQuery(this);if(jqElem.attr('hkId')&&jqElem.attr('hkId')!==selectorId){selectorId=jqElem.attr('hkId')+";"+selectorId;}
jqElem.attr('hkId',selectorId);});result=this.__bind__(handle.join(' '),data,hotkeys.handler)}}
return result;}};hotkeys.findElement=function(elem){if(!jQuery(elem).attr('hkId')){if(jQuery.browser.opera||jQuery.browser.safari){while(!jQuery(elem).attr('hkId')&&elem.parentNode){elem=elem.parentNode;}}}
return elem;};hotkeys.handler=function(event){var target=hotkeys.findElement(event.currentTarget),jTarget=jQuery(target),ids=jTarget.attr('hkId');if(ids){ids=ids.split(';');var code=event.which,type=event.type,special=hotkeys.specialKeys[code],character=!special&&String.fromCharCode(code).toLowerCase(),shift=event.shiftKey,ctrl=event.ctrlKey,alt=event.altKey||event.originalEvent.altKey,mapPoint=null;for(var x=0;x<ids.length;x++){if(hotkeys.triggersMap[ids[x]][type]){mapPoint=hotkeys.triggersMap[ids[x]][type];break;}}
if(mapPoint){var trigger;if(!shift&&!ctrl&&!alt){trigger=mapPoint[special]||(character&&mapPoint[character]);}
else{var modif='';if(alt)modif+='alt+';if(ctrl)modif+='ctrl+';if(shift)modif+='shift+';trigger=mapPoint[modif+special];if(!trigger){if(character){trigger=mapPoint[modif+character]||mapPoint[modif+hotkeys.shiftNums[character]]||(modif==='shift+'&&mapPoint[hotkeys.shiftNums[character]]);}}}
if(trigger){var result=false;for(var x=0;x<trigger.length;x++){if(trigger[x].disableInInput){var elem=jQuery(event.target);if(jTarget.is("input")||jTarget.is("textarea")||jTarget.is("select")||elem.is("input")||elem.is("textarea")||elem.is("select")){return true;}}
result=result||trigger[x].cb.apply(this,[event]);}
return result;}}}};window.hotkeys=hotkeys;return jQuery;})(jQuery);;;(function(d){var k=d.scrollTo=function(a,i,e){d(window).scrollTo(a,i,e)};k.defaults={axis:'xy',duration:parseFloat(d.fn.jquery)>=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);;var KarmaSendForm=function(){var form=$(this);var args={};var destination=form.find("input[name=js_destination]").val();var karma_url=Drupal.settings.extra_voting_forms.base_path+'extra_voting_forms/handle';var karma_timeout=Drupal.settings.extra_voting_forms.jquery_timeout;if(destination){top.location='/'+Drupal.settings.extra_voting_forms.login_page+'?destination='+destination;return false;}
else if(form.find('.tmpClicked').length>0){var tmpclicked=$(form.find('.tmpClicked')[0]);tmpclicked.removeClass('tmpClicked');if(karma_clicked_indicator(tmpclicked)=='clicked'){return false;}
else{tmpclicked.addClass('tmpClicked');}}
args.karma_vote=form.find(":selected").val()||form.find(":checked").val();args.oid=form.find("input[name=oid]").val();args.otype=form.find("input[name=otype]").val();args.form_type='ajax';form.addClass("karma_sending");if(Drupal.settings.extra_voting_forms.hide_karma_form){if(form.hasClass("karma_form_promoted")){form.removeClass("karma_form_promoted");var karma_form_promoted_REMOVED=1;}
if(form.hasClass("karma_form")){form.removeClass("karma_form");var karma_form_REMOVED=1;}}
$.ajax({data:args,url:karma_url,type:'POST',dataType:'json',timeout:karma_timeout,success:function(json){var ts;for(var x in json){args[x]=json[x];}
if(karma_form_promoted_REMOVED==1){form.addClass("karma_form_promoted");}
if(karma_form_REMOVED==1){form.addClass("karma_form");}
form.removeClass("karma_sending");if(json.error){form.find(".tmpClicked").removeClass("tmpClicked");alert(json.error);}else{var tmpclicked=form.find(".tmpClicked");form.addClass("karma_success");form.find("label").each(function(){karma_clicked($(this),"not_clicked");})
tmpclicked.each(function(){{karma_clicked($(this),"clicked")}});KarmaStripForm(form,args);}},error:function(xhr,msg){form.find(".tmpClicked").removeClass("tmpClicked");if(xhr.status==404||!msg){alert("Karma Error: Communication (0)");}else{alert("Karma Error: "+msg);}},complete:function(xhr,stat){(function(form,args){window.setTimeout(function(){form.removeClass("karma_sending");if(karma_form_promoted_REMOVED==1){form.addClass("karma_form_promoted");}
if(karma_form_REMOVED==1){form.addClass("karma_form");}},karma_timeout);})(form,args);}});return false;}
var KarmaStripForm=function(form,args){if(Drupal.settings.extra_voting_forms.only_one_vote){form.find("select").attr("disabled","disabled");form.find("label").each(function(){karma_clickable($(this),'not_clickable');}).unbind('click');}
var fid=form.attr("id");if(args.karma_aggregate!="Undefined"){for(var prefix in({'w':1,'x':1,'y':1,'z':1})){var did=prefix+args.otype+args.oid;$("#"+did+" span.karma_score").text(args.karma_aggregate);var did=prefix+args.oid;if(did!=fid){$("#"+did+" *").attr("disabled","true");$("#"+did+" label").each(function(){karma_clickable($(this),'not_clickable');}).unbind('click');}}}}
var KarmaRenderForm=function(){var form=$(this);var submit=form.find("input[type=submit]");if(!submit.attr("disabled")){form.find(":checked").attr("checked",false);form.find("select").change(function(){form.submit();});form.find("label").click(function(){form.find("#"+$(this).attr("for")).attr("checked",true);if($('.karma_sending').length>0){return;}
$(this).addClass("tmpClicked");form.submit();});}}
function karma_up_down_indicator(element){if(element.attr('class').substring(0,8)=="karma_up"){return"karma_up";}
else{return"karma_down";}}
function karma_clickable_indicator(element){if(element.attr('class').substr(-13)=="not_clickable"){return"not_clickable";}
else{return"clickable";}}
function karma_clicked_indicator(element){if(element.attr('class').substring(0,16)=="karma_up_clicked"||element.attr('class').substring(0,18)=="karma_down_clicked"){return"clicked";}
else{return"not_clicked";}}
function karma_clicked(element,clicked){var up_down=karma_up_down_indicator(element);var clickable=karma_clickable_indicator(element);element.removeAttr('class').attr('class',up_down+'_'+clicked+'_'+clickable);}
function karma_clickable(element,clickable){var up_down=karma_up_down_indicator(element);var clicked=karma_clicked_indicator(element);element.removeAttr('class').addClass(up_down+'_'+clicked+'_'+clickable);}
$(function(){$("form.karma_form,form.karma_form_promoted").submit(KarmaSendForm).each(KarmaRenderForm);});;Drupal.behaviors=Drupal.behaviors||{};Drupal.attachBehaviors=function(context){context=context||document;if(Drupal.jsEnabled&&Drupal.behaviors){jQuery.each(Drupal.behaviors,function(){this(context);});}};Drupal.preventSelect=function(elt){if(document.onselectstart){elt.onselectstart=function(){return false;}}
else{$(elt).mousedown(function(){return false;});}};Drupal.getTarget=function(e){if(!e)e=window.event;var target=e.target?e.target:e.srcElement;if(!target)return null;if(target.nodeType==3)target=target.parentNode;if(target.tagName.toUpperCase()=='LABEL'&&e.type=='click'){if(target.getAttribute('for')){target=document.getElementById(target.getAttribute('for'));}}
return target;};Drupal.url=function(path,query,fragment){query=query?query:'';fragment=fragment?'#'+fragment:'';var base=Drupal.settings.jstools.basePath;if(!Drupal.settings.jstools.cleanurls){if(query){return base+'?q='+path+'&'+query+fragment;}
else{return base+'?q='+path+fragment;}}
else{if(query){return base+path+'?'+query+fragment;}
else{return base+path+fragment;}}};Drupal.getPath=function(href){href=Drupal.pathPortion(href);href=href.substring(Drupal.settings.jstools.basePath.length+(Drupal.settings.jstools.cleanurls?0:3),href.length);var chars=['#','?','&'];for(i in chars){if(href.indexOf(chars[i])>-1){href=href.substr(0,href.indexOf(chars[i]));}}
return href;};Drupal.prependPath=function(href,segment){href=Drupal.pathPortion(href);var baseLength=Drupal.settings.jstools.basePath.length+(Drupal.settings.jstools.cleanurls?0:3);var base=href.substring(0,baseLength);return base+segment+'/'+href.substring(baseLength,href.length);};Drupal.pathPortion=function(href){var protocol=window.location.protocol;if(href.substring(0,protocol.length)==protocol){href=href.substring(href.indexOf('/',protocol.length+2));}
return href;};Drupal.redirectFormSubmit=function(uri,form,handler){$(form).submit(function(){Drupal.createIframe();var form=this;this.action=uri;this.target='redirect-target';handler.onsubmit();window.iframeHandler=function(){var iframe=$('#redirect-target').get(0);try{response=(iframe.contentWindow||iframe.contentDocument||iframe).document.body.innerHTML;response=response.replace(/[\f\n\r\t]/g,' ');if(window.opera){response=response.replace(/&quot;/g,'"');}}
catch(e){response=null;}
response=Drupal.parseJson(response);if(response.status==0){handler.onerror(response.data);return;}
handler.oncomplete(response.data);return true;};return true;});};Drupal.scrollTo=function(el){var pos=Drupal.absolutePosition(el);window.scrollTo(0,pos.y);};Drupal.elementChildren=function(element){var children=[];for(i in element){if(i.substr(0,1)!='#'){children[children.length]=i;}}
return children;};Drupal.elementProperties=function(element){var properties=[];for(i in element){if(i.substr(0,1)=='#'){properties[properties.length]=i;}}
return properties;};Drupal.parseQueryString=function(href){query=Drupal.getQueryString(href);var args={};var pairs=query.split("&");for(var i=0;i<pairs.length;i++){var pos=pairs[i].indexOf('=');if(pos==-1)continue;var argname=pairs[i].substring(0,pos);var value=pairs[i].substring(pos+1);args[argname]=unescape(value.replace(/\+/g," "));}
return args;};Drupal.getQueryString=function(href){if(href){var index=href.indexOf('?');href=(index==-1)?'':href.substring(index+1);}
query=href?href:location.search.substring(1);if(!Drupal.settings.jstools.cleanurls){var index=query.indexOf('&');query=(index==-1)?'':query.substring(index+1);}
return query;};Drupal.pathMatch=function(path,paths,type){paths='^'+paths+'$';paths=paths.replace(/\n/g,'$|^');paths=paths.replace(/\*/g,'.*');var search=path.search(new RegExp(paths))>-1?true:false;return(type==0)?search:!search;};if(Drupal.jsEnabled){document.cookie='has_js=1';$(document).ready(function(){Drupal.attachBehaviors(this);});};Drupal.behaviors.activeMenu=function(context){var menus=Drupal.settings.activemenu;for(var menu in menus){$(menu+' li.expanded:not(.activemenu-processed)').each(function(){Drupal.preventSelect(this);$(this).click(function(e){Drupal.activemenuToggle(this,e);}).addClass('activemenu-processed')});$(menu+' li.collapsed:not(.activemenu-processed)').each(function(){if($(this).children('ul').length>0){return;}
var path=Drupal.getPath($('a:first',this).attr('href'));var url=Drupal.url(menus[menu]);var elt=this;Drupal.preventSelect(this);$(this).click(function(e){var offset=Drupal.mousePosition(e).x-Drupal.absolutePosition(this).x;var padding=$(this).css('padding-left');if(offset<(padding.slice(-2)=="px"?parseInt(padding):18)){$(elt).addClass('loading');$.ajax({type:'POST',url:url,data:'path='+path,success:function(data){$(elt).removeClass('loading');if($(elt).children('ul').length>0){return;}
data=Drupal.parseJson(data);$(elt).append(data.content).removeClass('collapsed').addClass('expanded').unbind('click').click(function(e){Drupal.activemenuToggle(this,e);}).find('ul:first').slideDown(200);Drupal.attachBehaviors(elt);},error:function(xmlhttp){if(xmlhttp.status>=400)
alert('An HTTP error '+xmlhttp.status+' occured.\n'+url);}});return false;}}).addClass('activemenu-processed');});}};Drupal.activemenuToggle=function(menu,e){if(menu==Drupal.getTarget(e)&&!$(menu).is('.animating')){if($(menu).is('.collapsed')){$(menu).addClass('animating').removeClass('collapsed').addClass('expanded').find('ul:first').slideDown(200,function(){$(this).parents('.animating').removeClass('animating')});}
else{$(menu).addClass('animating').removeClass('expanded').addClass('collapsed').find('ul:first').slideUp(200,function(){$(this).parents('.animating').removeClass('animating')});}}};;Drupal.behaviors.collapsiblock=function(context){$('div.block:not(.collapsiblock-processed)',context).addClass('collapsiblock-processed').each(function(){var selector=Drupal.settings.collapsiblock&&Drupal.settings.collapsiblock.titleSelector?Drupal.settings.collapsiblock.titleSelector:'h2';var id=this.id;var titleElt=$(selector+':first',this);if(titleElt.size()){titleElt=titleElt[0];var status=Drupal.settings.collapsiblock.blocks[this.id]?Drupal.settings.collapsiblock.blocks[this.id]:Drupal.settings.collapsiblock.default_state;if(status==1){return;}
titleElt.target=$(this).find('div.content');$(titleElt).addClass('collapsiblock').click(function(){var st=$.cookie('collapsiblock-'+id);$.cookie('collapsiblock-'+id,st==0?1:0,{path:Drupal.settings.jstools.basePath});if($(this).is(".collapsiblockCollapsed")){$(this).removeClass('collapsiblockCollapsed');$(this.target).slideDown(200);}
else{$(this).addClass('collapsiblockCollapsed');$(this.target).slideUp(200);}});if(((status==3&&(!$.cookie('collapsiblock-'+id)))||$.cookie('collapsiblock-'+id)==1)&&!$(this).find('a.active').size()){$(titleElt).addClass('collapsiblockCollapsed');$(titleElt.target).hide();}
else{$.cookie('collapsiblock-'+id,0,{path:Drupal.settings.jstools.basePath});}}});};;jQuery.cookie=function(name,value,options){if(typeof value!='undefined'){options=options||{};if(value===null){value='';options.expires=-1;}
var expires='';if(options.expires&&(typeof options.expires=='number'||options.expires.toUTCString)){var date;if(typeof options.expires=='number'){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000));}else{date=options.expires;}
expires='; expires='+date.toUTCString();}
var path=options.path?'; path='+options.path:'';var domain=options.domain?'; domain='+options.domain:'';var secure=options.secure?'; secure':'';document.cookie=[name,'=',encodeURIComponent(value),expires,path,domain,secure].join('');}else{var cookieValue=null;if(document.cookie&&document.cookie!=''){var cookies=document.cookie.split(';');for(var i=0;i<cookies.length;i++){var cookie=jQuery.trim(cookies[i]);if(cookie.substring(0,name.length+1)==(name+'=')){cookieValue=decodeURIComponent(cookie.substring(name.length+1));break;}}}
return cookieValue;}};;Drupal.toggleFieldset=function(fieldset){if($(fieldset).is('.collapsed')){var content=$('> div',fieldset).hide();$(fieldset).removeClass('collapsed');content.slideDown(300,function(){$(this).css('height','auto');Drupal.collapseScrollIntoView(this.parentNode);this.parentNode.animating=false;});if(typeof Drupal.textareaAttach!='undefined'){Drupal.textareaAttach(null,fieldset);}}
else{var content=$('> div',fieldset).slideUp('medium',function(){$(this.parentNode).addClass('collapsed');this.parentNode.animating=false;});}}
Drupal.collapseScrollIntoView=function(node){var h=self.innerHeight||document.documentElement.clientHeight||$('body')[0].clientHeight||0;var offset=self.pageYOffset||document.documentElement.scrollTop||$('body')[0].scrollTop||0;var pos=Drupal.absolutePosition(node);var fudge=55;if(pos.y+node.offsetHeight+fudge>h+offset){if(node.offsetHeight>h){window.scrollTo(0,pos.y);}else{window.scrollTo(0,pos.y+node.offsetHeight-h+fudge);}}}
if(Drupal.jsEnabled){$(document).ready(function(){$('fieldset.collapsible > legend').each(function(){var fieldset=$(this.parentNode);if($('input.error, textarea.error, select.error',fieldset).size()>0){fieldset.removeClass('collapsed');}
var text=this.innerHTML;$(this).empty().append($('<a href="#">'+text+'</a>').click(function(){var fieldset=$(this).parents('fieldset:first')[0];if(!fieldset.animating){fieldset.animating=true;Drupal.toggleFieldset(fieldset);}
return false;})).after($('<div class="fieldset-wrapper"></div>').append(fieldset.children(':not(legend)')));});});};if(typeof(Drupal)=="undefined"||!Drupal.advpoll){Drupal.advpoll={};}
Drupal.advpoll.attachVoteAjax=function(){$("form.advpoll-vote").each(function(){var thisForm=this;var options={dataType:"json",after:function(data){$("div.messages").remove();if(data.errors){$(data.errors).insertBefore(thisForm).fadeIn();}
else{$(thisForm).hide();$(data.statusMsgs).insertBefore(thisForm).fadeIn();$(data.response).insertBefore(thisForm);}
$(".form-submit",thisForm).removeAttr("disabled");},before:function(){$(".form-submit",thisForm).attr("disabled","disabled");}};$("input.ajax",thisForm).val(true);$(this).ajaxForm(options);});};Drupal.advpoll.nodeVoteAutoAttach=function(){Drupal.advpoll.attachVoteAjax();};Drupal.advpoll.handleWriteins=function(){$("div.poll").each(function(){var poll=this;if($(".writein-choice",poll).length==0){return;}
var ranOnce=false;$(".vote-choices input[type=radio], .vote-choices input[type=checkbox]",poll).click(function(){var isLast=$(this).val()==$(".vote-choices input[type=radio]:last, .vote-choices input[type=checkbox]:last",poll).val();var type=$(this).attr("type");if(isLast||type=="radio"){var showChoice=isLast&&(type=="radio"||$(this).attr("checked"));if(!ranOnce&&showChoice){$(".writein-choice input",poll).clone().addClass("writein-choice").insertAfter($(this).parent()).end().parent().parent().remove();ranOnce=true;}
$(".writein-choice",poll).css("display",showChoice?"inline":"none");if(showChoice){$(".writein-choice",poll)[0].focus();}
else{$(".writein-choice",poll).val("");}}});$(".vote-choices select:last",poll).change(function(){if(!ranOnce){$(".writein-choice input",poll).clone().addClass("writein-choice").insertAfter($(this)).end().parent().parent().remove();ranOnce=true;}
var showChoice=$(this).val()>0;var alreadyVisible=$(".writein-choice",poll).css("display")=="inline";$(".writein-choice",poll).css("display",showChoice?"inline":"none");if(!showChoice){$(".writein-choice",poll).val("");}
else if(!alreadyVisible){$(".writein-choice",poll)[0].focus();}});});};if(Drupal.jsEnabled){$(document).ready(function(){Drupal.advpoll.nodeVoteAutoAttach();Drupal.advpoll.handleWriteins();});};;eval(function(p,a,c,k,e,d){e=function(c){return(c<a?"":e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[(function(e){return d[e]})];e=(function(){return'\\w+'});c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('6(!5.1d[\':\'][\'p\'])5.X(5.1d[\':\'],{p:"/p|k|19|N/i.1A(a.1k)"});5.o.18=d(3){3=5.X({S:g,I:2.1c(\'1l\')||\'\',A:2.1c(\'A\')||\'10\',R:g,Z:g,11:g,r:H},3||{});3.V=3.V||3.Z;4 a=2.U(3.r);6(3.R&&3.R(a,2)===H)9;4 q=5.Q(a);4 G=(3.A&&3.A.1n()==\'10\');6(G)3.I+=(3.I.1o(\'?\')>=0?\'&\':\'?\')+q;6(!3.11&&3.S)5(3.S).1p(3.I,G?g:a,3.V);m{3.M=3.A;3.1q=G?g:q;5.1r(3)}9 2};5.o.1s=d(3){9 2.O(d(){5("p:K,p:J",2).1t(d(j){2.b.P=2;6(j.13!=s){2.b.B=j.13;2.b.L=j.1u}m 6(z 5.o.y==\'d\'){4 y=$(2).y();2.b.B=j.14-y.1v;2.b.L=j.Y-y.1x}m{2.b.B=j.14-2.1y;2.b.L=j.Y-2.1B}})}).K(d(e){5(2).18(3);9 H})};5.o.U=d(r){4 a=[];4 q=r?\':p\':\'p,19,k,N\';5(q,2).O(d(){4 n=2.c;4 t=2.M;4 u=2.12.15();6(!n||2.16||t==\'17\'||(t==\'T\'||t==\'1a\')&&!2.1b||(t==\'K\'||t==\'J\'||t==\'N\')&&2.b&&2.b.P!=2||u==\'k\'&&2.W==-1)9;6(t==\'J\'&&2.b.B!=s)9 a.l({c:n+\'1C\',f:2.b.B},{c:n+\'1D\',f:2.b.L});6(u==\'k\'){4 7=5.w(2,H);6(t==\'k-1F\'){C(4 i=0;i<7.F;i++)a.l({c:n,f:7[i]})}m a.l({c:n,f:7})}m a.l({c:n,f:2.f})});9 a};5.o.1G=d(r){9 5.Q(2.U(r))};5.o.1e=d(h){4 a=[];2.O(d(){6(!2.c)9;4 7=5.w(2,h);6(7&&7.1f==1h){C(4 i=0;i<7.F;i++)a.l({c:2.c,f:7[i]})}m 6(7!==g&&z 7!=\'s\')a.l({c:2.c,f:7})});9 5.Q(a)};5.o.w=d(h){4 E=[],D=g;C(4 i=0;i<2.F;i++){4 8=2[i];6(8.M==\'T\'){6(!D)D=8.c||\'1j\';6(D!=8.c)9 E;4 7=5.w(8,h);6(7!==g&&z 7!=\'s\')E.l(7)}m{4 7=5.w(8,h);6(7!==g&&z 7!=\'s\')9 7}}9 E};5.w=d(8,h){4 n=8.c;4 t=8.M;4 u=8.12.15();6(z h==\'s\')h=1w;6(h&&(!n||8.16||t==\'17\'||(t==\'T\'||t==\'1a\')&&!8.1b||(t==\'K\'||t==\'J\'||t==\'N\')&&8.b&&8.b.P!=8||u==\'k\'&&8.W==-1))9 g;6(u==\'k\'){4 a=[];C(4 i=0;i<8.3.F;i++){4 x=8.3[i];6(x.1z){4 v=5.1E.1H&&!(x.1g[\'f\'].1i)?x.1m:x.f;6(t==\'k-1I\')9 v;a.l(v)}}9 a}9 8.f};',62,107,'||this|options|var|jQuery|if|val|el|return||form|name|function||value|null|successful||ev|select|push|else||fn|input||semantic|undefined||tag||fieldValue|op|offset|typeof|method|clk_x|for|cbName|cbVal|length|get|false|url|image|submit|clk_y|type|button|each|clk|param|before|target|checkbox|formToArray|success|selectedIndex|extend|pageY|after|GET|dataType|tagName|offsetX|pageX|toLowerCase|disabled|reset|ajaxSubmit|textarea|radio|checked|attr|expr|fieldSerialize|constructor|attributes|Array|specified|unnamed|nodeName|action|text|toUpperCase|indexOf|load|data|ajax|ajaxForm|click|offsetY|left|true|top|offsetLeft|selected|test|offsetTop|_x|_y|browser|multiple|formSerialize|msie|one'.split('|'),0,{}));Drupal.behaviors.collapse=function(context){$('fieldset.collapsible > legend:not(.collapse-processed)',context).each(function(){var fieldset=$(this.parentNode);if($('input.error, textarea.error, select.error',fieldset).size()>0){fieldset.removeClass('collapsed');}
var text=this.innerHTML;$(this).empty().append($('<a href="#">'+text+'</a>').click(function(){var fieldset=$(this).parents('fieldset:first')[0];if(!fieldset.animating){fieldset.animating=true;Drupal.toggleFieldset(fieldset);}
return false;})).after($('<div class="fieldset-wrapper"></div>').append(fieldset.children(':not(legend)')));});};$(document).ready(function(){$('fieldset.collapsible > legend').addClass('collapse-processed');});;if(Drupal.jsEnabled){function spamspan(){$("span."+Drupal.settings.spamspan.m).each(function(a){var b=($("span."+Drupal.settings.spamspan.u,this).text()+"@"+$("span."+Drupal.settings.spamspan.d,this).text()).replace(/\s+/g,'').replace(/\[dot\]/g,'.');var c=$("span."+Drupal.settings.spamspan.t,this).text();$(this).after($("<a></a>").attr("href","mailto:"+b).html(c?c:b).addClass("spamspan")).remove()})}$(spamspan)}