/*
 * jQuery JavaScript Library v1.3.2
 * http://jquery.com/
 *
 * Copyright (c) 2009 John Resig
 * Dual licensed under the MIT and GPL licenses.
 * http://docs.jquery.com/License
 *
 * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009)
 * Revision: 6246
 */
(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)})}});
/*
 * Sizzle CSS Selector Engine - v0.9.3
 *  Copyright 2009, The Dojo Foundation
 *  Released under the MIT, BSD, and GPL Licenses.
 *  More information: http://sizzlejs.com/
 */
(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")}})})();;

var Drupal = Drupal || { 'settings': {}, 'behaviors': {}, 'themes': {}, 'locale': {} };

/**
 * Set the variable that indicates if JavaScript behaviors should be applied
 */
Drupal.jsEnabled = document.getElementsByTagName && document.createElement && document.createTextNode && document.documentElement && document.getElementById;

/**
 * Attach all registered behaviors to a page element.
 *
 * Behaviors are event-triggered actions that attach to page elements, enhancing
 * default non-Javascript UIs. Behaviors are registered in the Drupal.behaviors
 * object as follows:
 * @code
 *    Drupal.behaviors.behaviorName = function () {
 *      ...
 *    };
 * @endcode
 *
 * Drupal.attachBehaviors is added below to the jQuery ready event and so
 * runs on initial page load. Developers implementing AHAH/AJAX in their
 * solutions should also call this function after new page content has been
 * loaded, feeding in an element to be processed, in order to attach all
 * behaviors to the new content.
 *
 * Behaviors should use a class in the form behaviorName-processed to ensure
 * the behavior is attached only once to a given element. (Doing so enables
 * the reprocessing of given elements, which may be needed on occasion despite
 * the ability to limit behavior attachment to a particular element.)
 *
 * @param context
 *   An element to attach behaviors to. If none is given, the document element
 *   is used.
 */
Drupal.attachBehaviors = function(context) {
  context = context || document;
  if (Drupal.jsEnabled) {
    // Execute all of them.
    jQuery.each(Drupal.behaviors, function() {
      this(context);
    });
  }
};

/**
 * Encode special characters in a plain-text string for display as HTML.
 */
Drupal.checkPlain = function(str) {
  str = String(str);
  var replace = { '&': '&amp;', '"': '&quot;', '<': '&lt;', '>': '&gt;' };
  for (var character in replace) {
    var regex = new RegExp(character, 'g');
    str = str.replace(regex, replace[character]);
  }
  return str;
};

/**
 * Translate strings to the page language or a given language.
 *
 * See the documentation of the server-side t() function for further details.
 *
 * @param str
 *   A string containing the English string to translate.
 * @param args
 *   An object of replacements pairs to make after translation. Incidences
 *   of any key in this array are replaced with the corresponding value.
 *   Based on the first character of the key, the value is escaped and/or themed:
 *    - !variable: inserted as is
 *    - @variable: escape plain text to HTML (Drupal.checkPlain)
 *    - %variable: escape text and theme as a placeholder for user-submitted
 *      content (checkPlain + Drupal.theme('placeholder'))
 * @return
 *   The translated string.
 */
Drupal.t = function(str, args) {
  // Fetch the localized version of the string.
  if (Drupal.locale.strings && Drupal.locale.strings[str]) {
    str = Drupal.locale.strings[str];
  }

  if (args) {
    // Transform arguments before inserting them
    for (var key in args) {
      switch (key.charAt(0)) {
        // Escaped only
        case '@':
          args[key] = Drupal.checkPlain(args[key]);
        break;
        // Pass-through
        case '!':
          break;
        // Escaped and placeholder
        case '%':
        default:
          args[key] = Drupal.theme('placeholder', args[key]);
          break;
      }
      str = str.replace(key, args[key]);
    }
  }
  return str;
};

/**
 * Format a string containing a count of items.
 *
 * This function ensures that the string is pluralized correctly. Since Drupal.t() is
 * called by this function, make sure not to pass already-localized strings to it.
 *
 * See the documentation of the server-side format_plural() function for further details.
 *
 * @param count
 *   The item count to display.
 * @param singular
 *   The string for the singular case. Please make sure it is clear this is
 *   singular, to ease translation (e.g. use "1 new comment" instead of "1 new").
 *   Do not use @count in the singular string.
 * @param plural
 *   The string for the plural case. Please make sure it is clear this is plural,
 *   to ease translation. Use @count in place of the item count, as in "@count
 *   new comments".
 * @param args
 *   An object of replacements pairs to make after translation. Incidences
 *   of any key in this array are replaced with the corresponding value.
 *   Based on the first character of the key, the value is escaped and/or themed:
 *    - !variable: inserted as is
 *    - @variable: escape plain text to HTML (Drupal.checkPlain)
 *    - %variable: escape text and theme as a placeholder for user-submitted
 *      content (checkPlain + Drupal.theme('placeholder'))
 *   Note that you do not need to include @count in this array.
 *   This replacement is done automatically for the plural case.
 * @return
 *   A translated string.
 */
Drupal.formatPlural = function(count, singular, plural, args) {
  var args = args || {};
  args['@count'] = count;
  // Determine the index of the plural form.
  var index = Drupal.locale.pluralFormula ? Drupal.locale.pluralFormula(args['@count']) : ((args['@count'] == 1) ? 0 : 1);

  if (index == 0) {
    return Drupal.t(singular, args);
  }
  else if (index == 1) {
    return Drupal.t(plural, args);
  }
  else {
    args['@count['+ index +']'] = args['@count'];
    delete args['@count'];
    return Drupal.t(plural.replace('@count', '@count['+ index +']'));
  }
};

/**
 * Generate the themed representation of a Drupal object.
 *
 * All requests for themed output must go through this function. It examines
 * the request and routes it to the appropriate theme function. If the current
 * theme does not provide an override function, the generic theme function is
 * called.
 *
 * For example, to retrieve the HTML that is output by theme_placeholder(text),
 * call Drupal.theme('placeholder', text).
 *
 * @param func
 *   The name of the theme function to call.
 * @param ...
 *   Additional arguments to pass along to the theme function.
 * @return
 *   Any data the theme function returns. This could be a plain HTML string,
 *   but also a complex object.
 */
Drupal.theme = function(func) {
  for (var i = 1, args = []; i < arguments.length; i++) {
    args.push(arguments[i]);
  }

  return (Drupal.theme[func] || Drupal.theme.prototype[func]).apply(this, args);
};

/**
 * Parse a JSON response.
 *
 * The result is either the JSON object, or an object with 'status' 0 and 'data' an error message.
 */
Drupal.parseJson = function (data) {
  if ((data.substring(0, 1) != '{') && (data.substring(0, 1) != '[')) {
    return { status: 0, data: data.length ? data : Drupal.t('Unspecified error') };
  }
  return eval('(' + data + ');');
};

/**
 * Freeze the current body height (as minimum height). Used to prevent
 * unnecessary upwards scrolling when doing DOM manipulations.
 */
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);
};

/**
 * Unfreeze the body height
 */
Drupal.unfreezeHeight = function () {
  $('#freeze-height').remove();
};

/**
 * Wrapper around encodeURIComponent() which avoids Apache quirks (equivalent of
 * drupal_urlencode() in PHP). This function should only be used on paths, not
 * on query string arguments.
 */
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');
};

/**
 * Get the text selection in a textarea.
 */
Drupal.getSelection = function (element) {
  if (typeof(element.selectionStart) != 'number' && document.selection) {
    // The current selection
    var range1 = document.selection.createRange();
    var range2 = range1.duplicate();
    // Select all text.
    range2.moveToElementText(element);
    // Now move 'dummy' end point to end point of original range.
    range2.setEndPoint('EndToEnd', range1);
    // Now we can calculate start and end points.
    var start = range2.text.length - range1.text.length;
    var end = start + range1.text.length;
    return { 'start': start, 'end': end };
  }
  return { 'start': element.selectionStart, 'end': element.selectionEnd };
};

/**
 * Build an error message from ahah response.
 */
Drupal.ahahError = function(xmlhttp, uri) {
  if (xmlhttp.status == 200) {
    if (jQuery.trim($(xmlhttp.responseText).text())) {
      var message = Drupal.t("An error occurred. \n@uri\n@text", {'@uri': uri, '@text': xmlhttp.responseText });
    }
    else {
      var message = Drupal.t("An error occurred. \n@uri\n(no information available).", {'@uri': uri, '@text': xmlhttp.responseText });
    }
  }
  else {
    var message = Drupal.t("An HTTP error @status occurred. \n@uri", {'@uri': uri, '@status': xmlhttp.status });
  }
  return message;
}

// Global Killswitch on the <html> element
if (Drupal.jsEnabled) {
  // Global Killswitch on the <html> element
  $(document.documentElement).addClass('js');
  // 'js enabled' cookie
  document.cookie = 'has_js=1; path=/';
  // Attach all behaviors.
  $(document).ready(function() {
    Drupal.attachBehaviors(this);
  });
}

/**
 * The default themes.
 */
Drupal.theme.prototype = {

  /**
   * Formats text for emphasized display in a placeholder inside a sentence.
   *
   * @param str
   *   The text to format (plain-text).
   * @return
   *   The formatted text (html).
   */
  placeholder: function(str) {
    return '<em>' + Drupal.checkPlain(str) + '</em>';
  }
};
;
/**
 * Javascript helpers for Facebook Streams.  Loaded by fb_stream.module.
 */
FB_Stream = function(){};

/**
 * Display a stream dialog on Facebook Connect pages, via
 * http://developers.facebook.com/docs/reference/javascript/FB.ui
 *
 * @param json is the json-encoded output of fb_stream_get_stream_dialog_data().
 */
FB_Stream.stream_publish = function(json) {
  var data_array = Drupal.parseJson(json);
  var len = data_array.length;
  for (var i=0; i < len; i++) {
    var data = data_array[i];
    data.method = 'stream.publish';
    FB.ui(data);
  }
};

;

// This function called by facebook's javascript when it is loaded.
// http://developers.facebook.com/docs/reference/javascript/
window.fbAsyncInit = function() {

  if (Drupal.settings.fb) {
    FB.init(Drupal.settings.fb.fb_init_settings);
  }

  if (FB._apiKey) {
    // Check the login status.  If offline_access granted, this
    // is the only whay to know if user has logged out of facebook.
    FB.getLoginStatus(function(response) {
      FB_JS.initFinal(response);
    });
  }
  else {
    // No application.  Not safe to call FB.getLoginStatus().
    // We still want to initialize XFBML, third-party modules, etc.
    FB_JS.initFinal({'session' : null});
  }
};

FB_JS = function(){};

/**
 * Finish initializing, whether there is an application or not.
 */
FB_JS.initFinal = function(response) {
  var status = {
    'session' : response.authResponse, // deprecated
    'auth': response.authResponse,
    'response': response
  };
  jQuery.event.trigger('fb_init', status);  // Trigger event for third-party modules.

  FB_JS.authResponseChange(response); // This will act only if fbu changed.

  FB_JS.eventSubscribe();

  FB.XFBML.parse();
}

/**
 * Tell facebook to notify us of events we may need to act on.
 */
FB_JS.eventSubscribe = function() {
  // Use FB.Event to detect Connect login/logout.
  FB.Event.subscribe('auth.authResponseChange', FB_JS.authResponseChange);

  // Q: what the heck is "edge.create"? A: the like button was clicked.
  FB.Event.subscribe('edge.create', FB_JS.edgeCreate);

}

/**
 * Helper parses URL params.
 *
 * http://jquery-howto.blogspot.com/2009/09/get-url-parameters-values-with-jquery.html
 */
FB_JS.getUrlVars = function(href) {
  var vars = [], hash;
  var hashes = href.slice(href.indexOf('?') + 1).split('&');
  for(var i = 0; i < hashes.length; i++)
  {
    hash = hashes[i].split('=');
    vars[hash[0]] = hash[1];
    if (hash[0] != 'fbu')
      vars.push(hashes[i]); // i.e. "foo=bar"
  }
  return vars;
}

/**
 * Reload the current page, whether on canvas page or facebook connect.
 *
 * append fbsig, a hash of the session data, to avoid infinite reloads
 * in some cases.
 */
FB_JS.reload = function(destination) {
  // Determine url hash.
  var auth = FB.getAuthResponse();

  var fbhash;
  if (auth != null)
    fbhash = auth.signedRequest; // Use sig rather than compute a new hash.
  else
    fbhash = 0;

  // Avoid infinite reloads.  Still needed? It would be nice to do away with this code if not needed.
  ///@TODO - does not work on iframe because facebook does not pass url args to canvas frame when cookies not accepted.  http://forum.developers.facebook.net/viewtopic.php?id=77236
  var vars = FB_JS.getUrlVars(window.location.href);
  if (vars.fbhash == fbhash) {
    return; // Do not reload (again)
  }

  // Determine where to send user.
  if (typeof(destination) != 'undefined' && destination) {
    // Use destination passed in.
  }
  else if (typeof(Drupal.settings.fb.reload_url) != 'undefined') {
    destination = Drupal.settings.fb.reload_url;
  }
  else {
    destination = window.location.href;
  }

  // Split and parse destination
  var path;
  if (destination.indexOf('?') == -1) {
    vars = [];
    path = destination;
  }
  else {
    vars = FB_JS.getUrlVars(destination);
    path = destination.substr(0, destination.indexOf('?'));
  }

  // Add fbhash to params before reload.
  if (Drupal.settings.fb.reload_url_append_hash) {
    vars.push('fbhash=' + fbhash);
  }

  // Use window.top for iframe canvas pages.
  destination = vars.length ? (path + '?' + vars.join('&')) : path;

  if(Drupal.settings.fb.reload_url_fragment) {
    destination = destination + "#" + Drupal.settings.fb.reload_url_fragment;
  }

  // Feedback that entire page may be reloading.
  // @TODO improve the appearance of this, make it customizable.
  jQuery('body').prepend('<div id="fb_js_pb" class="progress"><div class="bar"><div class="filled"></div></div></div>');

  window.top.location = destination;
  //alert(destination);
};

// Facebook pseudo-event handlers.
FB_JS.authResponseChange = function(response) {
  //debugger;
  if (response.status == 'unknown') {
    // @TODO can we test if third-party cookies are disabled?
  }

  var status = {
    'changed': false,
    'fbu': null,
    'session': response.authResponse, // deprecated,  still needed???
    'auth': response.authResponse, // still needed???
    'response' : response
  };

  if (response.authResponse) {
    status.fbu = response.authResponse.userID;
    if (Drupal.settings.fb.fbu != status.fbu) {
      // A user has logged in.
      status.changed = true;
    }
  }
  else if (Drupal.settings.fb && Drupal.settings.fb.fbu) {
    // A user has logged out.
    status.changed = true;

    // Sometimes Facebook's invalid cookies are left around.  Let's try to clean up their crap.
    // Can get left behind when third-party cookies disabled.
    // @TODO: Still needed with new oauth??? Have cookies been renamed (fbsr_...)???
    FB_JS.deleteCookie('fbs_' + FB._apiKey, '/', '');
    FB_JS.deleteCookie('fbs_' + Drupal.settings.fb.apikey, '/', '');
  }

  if (status.changed) {
    // fbu has changed since server built the page.
    jQuery.event.trigger('fb_session_change', status);

    // Remember the fbu.
    Drupal.settings.fb.fbu = status.fbu;
  }

};

// edgeCreate is handler for Like button.
FB_JS.edgeCreate = function(href, widget) {
  var status = {'href': href};
  FB_JS.ajaxEvent('edge.create', status);
};

// JQuery pseudo-event handler.
FB_JS.sessionChangeHandler = function(context, status) {
  // Pass data to ajax event.
  var data = {
    'event_type': 'session_change'
  };

  if (status.session) {
    data.fbu = status.session.userID;
    // Suppress facebook-controlled session.
    data.fb_session_handoff = true;
  }

  FB_JS.ajaxEvent(data.event_type, data);
  // No need to call window.location.reload().  It will be called from ajaxEvent, if needed.
};


// Helper to pass events via AJAX.
// A list of javascript functions to be evaluated is returned.
FB_JS.ajaxEvent = function(event_type, request_data) {
  if (Drupal.settings.fb.ajax_event_url) {

    // Session data helpful in ajax callbacks.  See fb_settings.inc.
    // request_data.fb_js_session = JSON.stringify(FB.getSession()); // FB.getSession() FAILS! REMOVE or REPLACE.
    if (typeof(Drupal.settings.fb_page_type) != 'undefined') {
      request_data.fb_js_page_type = Drupal.settings.fb_page_type;
    }

    // FB._apikey might be an apikey or might be an appid!
    if (FB._apiKey == Drupal.settings.fb.fb_init_settings.appId ||
        FB._apiKey == Drupal.settings.fb.fb_init_settings.apiKey) {
      request_data.apikey = Drupal.settings.fb.fb_init_settings.apiKey; // deprecated
      request_data.appId = Drupal.settings.fb.fb_init_settings.appId;
    }

    // Other values to pass to ajax handler.
    if (Drupal.settings.fb.controls) {
      request_data.fb_controls = Drupal.settings.fb.controls;
    }

    jQuery.ajax({
      url: Drupal.settings.fb.ajax_event_url + '/' + event_type,
      data : request_data,
      type: 'POST',
      dataType: 'json',
      success: function(js_array, textStatus, XMLHttpRequest) {
        if (js_array.length > 0) {
          for (var i = 0; i < js_array.length; i++) {
            eval(js_array[i]);
          }
        }
        else {
          if (event_type == 'session_change') {
            // No instructions from ajax, reload entire page.
            FB_JS.reload();
          }
        }
      },
      error: function(jqXHR, textStatus, errorThrown) {
        // Unexpected error (i.e. ajax did not return json-encoded data).
        var headers = jqXHR.getAllResponseHeaders(); // debug info.
        var responseText = jqXHR.responseText; // debug info.
        debugger;
        // @TODO: handle error, but how?
      }
    });
  }
};

// Delete a cookie.
// Facebook's JS SDK attempts to delete, but I'm not convinced it always works.
FB_JS.deleteCookie = function( name, path, domain ) {
  document.cookie = name + "=" +
    ( ( path ) ? ";path=" + path : "") +
    ( ( domain ) ? ";domain=" + domain : "" ) +
    ";expires=Thu, 01-Jan-1970 00:00:01 GMT";
};

/**
 * Drupal behaviors hook.
 *
 * Called when page is loaded, or content added via javascript.
 */
Drupal.behaviors.fb = function(context) {
  // Respond to our jquery pseudo-events
  var events = jQuery(document).data('events');
  if (!events || !events.fb_session_change) {
    jQuery(document).bind('fb_session_change', FB_JS.sessionChangeHandler);
  }

  // Once upon a time, we initialized facebook's JS SDK here, but now that is done in fb_footer().

  if (typeof(FB) != 'undefined') {
    // Render any XFBML markup that may have been added by AJAX.
    $(context).each(function() {
      var elem = $(this).get(0);
      FB.XFBML.parse(elem);
    });
  }

  // Markup with class .fb_show should be visible if javascript is enabled.  .fb_hide should be hidden.
  jQuery('.fb_hide', context).hide();
  jQuery('.fb_show', context).show();

};
;

$(document).ready(function() {

  // Attach onclick event to document only and catch clicks on all elements.
  $(document.body).click(function(event) {
    // Catch only the first parent link of a clicked element.
    $(event.target).parents("a:first,area:first").andSelf().filter("a,area").each(function() {

      var ga = Drupal.settings.googleanalytics;
      // Expression to check for absolute internal links.
      var isInternal = new RegExp("^(https?):\/\/" + window.location.host, "i");
      // Expression to check for special links like gotwo.module /go/* links.
      var isInternalSpecial = new RegExp("(\/go\/.*)$", "i");
      // Expression to check for download links.
      var isDownload = new RegExp("\\.(" + ga.trackDownloadExtensions + ")$", "i");

      // Is the clicked URL internal?
      if (isInternal.test(this.href)) {
        // Is download tracking activated and the file extension configured for download tracking?
        if (ga.trackDownload && isDownload.test(this.href)) {
          // Download link clicked.
          var extension = isDownload.exec(this.href);
          _gaq.push(["_trackEvent", "Downloads", extension[1].toUpperCase(), this.href.replace(isInternal, '')]);
        }
        else if (isInternalSpecial.test(this.href)) {
          // Keep the internal URL for Google Analytics website overlay intact.
          _gaq.push(["_trackPageview", this.href.replace(isInternal, '')]);
        }
      }
      else {
        if (ga.trackMailto && $(this).is("a[href^=mailto:],area[href^=mailto:]")) {
          // Mailto link clicked.
          _gaq.push(["_trackEvent", "Mails", "Click", this.href.substring(7)]);
        }
        else if (ga.trackOutgoing && this.href) {
          if (ga.trackOutboundAsPageview) {
            // Track all external links as page views after URL cleanup.
            // Currently required, if click should be tracked as goal.
            _gaq.push(["_trackPageview", '/outbound/' + this.href.replace(/^(https?|ftp|news|nntp|telnet|irc|ssh|sftp|webcal):\/\//i, '').split('/').join('--')]);
          }
          else {
            // External link clicked.
            _gaq.push(["_trackEvent", "Outbound links", "Click", this.href]);
          }
        }
      }
    });
  });
});
;
/* $Id: lightbox.js,v 1.5.2.6.2.136 2010/09/24 08:39:40 snpower Exp $ */

/**
 * jQuery Lightbox
 * @author
 *   Stella Power, <http://drupal.org/user/66894>
 *
 * Based on Lightbox v2.03.3 by Lokesh Dhakar
 * <http://www.huddletogether.com/projects/lightbox2/>
 * Also partially based on the jQuery Lightbox by Warren Krewenki
 *   <http://warren.mesozen.com>
 *
 * Permission has been granted to Mark Ashmead & other Drupal Lightbox2 module
 * maintainers to distribute this file via Drupal.org
 * Under GPL license.
 *
 * Slideshow, iframe and video functionality added by Stella Power.
 */

var Lightbox = {
  auto_modal : false,
  overlayOpacity : 0.8, // Controls transparency of shadow overlay.
  overlayColor : '000', // Controls colour of shadow overlay.
  disableCloseClick : true,
  // Controls the order of the lightbox resizing animation sequence.
  resizeSequence: 0, // 0: simultaneous, 1: width then height, 2: height then width.
  resizeSpeed: 'normal', // Controls the speed of the lightbox resizing animation.
  fadeInSpeed: 'normal', // Controls the speed of the image appearance.
  slideDownSpeed: 'slow', // Controls the speed of the image details appearance.
  minWidth: 240,
  borderSize : 10,
  boxColor : 'fff',
  fontColor : '000',
  topPosition : '',
  infoHeight: 20,
  alternative_layout : false,
  imageArray : [],
  imageNum : null,
  total : 0,
  activeImage : null,
  inprogress : false,
  disableResize : false,
  disableZoom : false,
  isZoomedIn : false,
  rtl : false,
  loopItems : false,
  keysClose : ['c', 'x', 27],
  keysPrevious : ['p', 37],
  keysNext : ['n', 39],
  keysZoom : ['z'],
  keysPlayPause : [32],

  // Slideshow options.
  slideInterval : 5000, // In milliseconds.
  showPlayPause : true,
  autoStart : true,
  autoExit : true,
  pauseOnNextClick : false, // True to pause the slideshow when the "Next" button is clicked.
  pauseOnPrevClick : true, // True to pause the slideshow when the "Prev" button is clicked.
  slideIdArray : [],
  slideIdCount : 0,
  isSlideshow : false,
  isPaused : false,
  loopSlides : false,

  // Iframe options.
  isLightframe : false,
  iframe_width : 600,
  iframe_height : 400,
  iframe_border : 1,

  // Video and modal options.
  enableVideo : false,
  flvPlayer : '/flvplayer.swf',
  flvFlashvars : '',
  isModal : false,
  isVideo : false,
  videoId : false,
  modalWidth : 400,
  modalHeight : 400,
  modalHTML : null,


  // initialize()
  // Constructor runs on completion of the DOM loading.
  // The function inserts html at the bottom of the page which is used
  // to display the shadow overlay and the image container.
  initialize: function() {

    var s = Drupal.settings.lightbox2;
    Lightbox.overlayOpacity = s.overlay_opacity;
    Lightbox.overlayColor = s.overlay_color;
    Lightbox.disableCloseClick = s.disable_close_click;
    Lightbox.resizeSequence = s.resize_sequence;
    Lightbox.resizeSpeed = s.resize_speed;
    Lightbox.fadeInSpeed = s.fade_in_speed;
    Lightbox.slideDownSpeed = s.slide_down_speed;
    Lightbox.borderSize = s.border_size;
    Lightbox.boxColor = s.box_color;
    Lightbox.fontColor = s.font_color;
    Lightbox.topPosition = s.top_position;
    Lightbox.rtl = s.rtl;
    Lightbox.loopItems = s.loop_items;
    Lightbox.keysClose = s.keys_close.split(" ");
    Lightbox.keysPrevious = s.keys_previous.split(" ");
    Lightbox.keysNext = s.keys_next.split(" ");
    Lightbox.keysZoom = s.keys_zoom.split(" ");
    Lightbox.keysPlayPause = s.keys_play_pause.split(" ");
    Lightbox.disableResize = s.disable_resize;
    Lightbox.disableZoom = s.disable_zoom;
    Lightbox.slideInterval = s.slideshow_interval;
    Lightbox.showPlayPause = s.show_play_pause;
    Lightbox.showCaption = s.show_caption;
    Lightbox.autoStart = s.slideshow_automatic_start;
    Lightbox.autoExit = s.slideshow_automatic_exit;
    Lightbox.pauseOnNextClick = s.pause_on_next_click;
    Lightbox.pauseOnPrevClick = s.pause_on_previous_click;
    Lightbox.loopSlides = s.loop_slides;
    Lightbox.alternative_layout = s.use_alt_layout;
    Lightbox.iframe_width = s.iframe_width;
    Lightbox.iframe_height = s.iframe_height;
    Lightbox.iframe_border = s.iframe_border;
    Lightbox.enableVideo = s.enable_video;
    if (s.enable_video) {
      Lightbox.flvPlayer = s.flvPlayer;
      Lightbox.flvFlashvars = s.flvFlashvars;
    }

    // Make the lightbox divs.
    var layout_class = (s.use_alt_layout ? 'lightbox2-alt-layout' : 'lightbox2-orig-layout');
    var output = '<div id="lightbox2-overlay" style="display: none;"></div>\
      <div id="lightbox" style="display: none;" class="' + layout_class + '">\
        <div id="outerImageContainer"></div>\
        <div id="imageDataContainer" class="clearfix">\
          <div id="imageData"></div>\
        </div>\
      </div>';
    var loading = '<div id="loading"><a href="#" id="loadingLink"></a></div>';
    var modal = '<div id="modalContainer" style="display: none;"></div>';
    var frame = '<div id="frameContainer" style="display: none;"></div>';
    var imageContainer = '<div id="imageContainer" style="display: none;"></div>';
    var details = '<div id="imageDetails"></div>';
    var bottomNav = '<div id="bottomNav"></div>';
    var image = '<img id="lightboxImage" alt="" />';
    var hoverNav = '<div id="hoverNav"><a id="prevLink" href="#"></a><a id="nextLink" href="#"></a></div>';
    var frameNav = '<div id="frameHoverNav"><a id="framePrevLink" href="#"></a><a id="frameNextLink" href="#"></a></div>';
    var hoverNav = '<div id="hoverNav"><a id="prevLink" title="' + Drupal.t('Previous') + '" href="#"></a><a id="nextLink" title="' + Drupal.t('Next') + '" href="#"></a></div>';
    var frameNav = '<div id="frameHoverNav"><a id="framePrevLink" title="' + Drupal.t('Previous') + '" href="#"></a><a id="frameNextLink" title="' + Drupal.t('Next') + '" href="#"></a></div>';
    var caption = '<span id="caption"></span>';
    var numberDisplay = '<span id="numberDisplay"></span>';
    var close = '<a id="bottomNavClose" title="' + Drupal.t('Close') + '" href="#"></a>';
    var zoom = '<a id="bottomNavZoom" href="#"></a>';
    var zoomOut = '<a id="bottomNavZoomOut" href="#"></a>';
    var pause = '<a id="lightshowPause" title="' + Drupal.t('Pause Slideshow') + '" href="#" style="display: none;"></a>';
    var play = '<a id="lightshowPlay" title="' + Drupal.t('Play Slideshow') + '" href="#" style="display: none;"></a>';

    $("body").append(output);
    $('#outerImageContainer').append(modal + frame + imageContainer + loading);
    if (!s.use_alt_layout) {
      $('#imageContainer').append(image + hoverNav);
      $('#imageData').append(details + bottomNav);
      $('#imageDetails').append(caption + numberDisplay);
      $('#bottomNav').append(frameNav + close + zoom + zoomOut + pause + play);
    }
    else {
      $('#outerImageContainer').append(bottomNav);
      $('#imageContainer').append(image);
      $('#bottomNav').append(close + zoom + zoomOut);
      $('#imageData').append(hoverNav + details);
      $('#imageDetails').append(caption + numberDisplay + pause + play);
    }

    // Setup onclick handlers.
    if (Lightbox.disableCloseClick) {
      $('#lightbox2-overlay').click(function() { Lightbox.end(); return false; } ).hide();
    }
    $('#loadingLink, #bottomNavClose').click(function() { Lightbox.end('forceClose'); return false; } );
    $('#prevLink, #framePrevLink').click(function() { Lightbox.changeData(Lightbox.activeImage - 1); return false; } );
    $('#nextLink, #frameNextLink').click(function() { Lightbox.changeData(Lightbox.activeImage + 1); return false; } );
    $('#bottomNavZoom').click(function() { Lightbox.changeData(Lightbox.activeImage, true); return false; } );
    $('#bottomNavZoomOut').click(function() { Lightbox.changeData(Lightbox.activeImage, false); return false; } );
    $('#lightshowPause').click(function() { Lightbox.togglePlayPause("lightshowPause", "lightshowPlay"); return false; } );
    $('#lightshowPlay').click(function() { Lightbox.togglePlayPause("lightshowPlay", "lightshowPause"); return false; } );

    // Fix positioning.
    $('#prevLink, #nextLink, #framePrevLink, #frameNextLink').css({ 'paddingTop': Lightbox.borderSize + 'px'});
    $('#imageContainer, #frameContainer, #modalContainer').css({ 'padding': Lightbox.borderSize + 'px'});
    $('#outerImageContainer, #imageDataContainer, #bottomNavClose').css({'backgroundColor': '#' + Lightbox.boxColor, 'color': '#'+Lightbox.fontColor});
    if (Lightbox.alternative_layout) {
      $('#bottomNavZoom, #bottomNavZoomOut').css({'bottom': Lightbox.borderSize + 'px', 'right': Lightbox.borderSize + 'px'});
    }
    else if (Lightbox.rtl == 1 && $.browser.msie) {
      $('#bottomNavZoom, #bottomNavZoomOut').css({'left': '0px'});
    }

    // Force navigation links to always be displayed
    if (s.force_show_nav) {
      $('#prevLink, #nextLink').addClass("force_show_nav");
    }

  },

  // initList()
  // Loops through anchor tags looking for 'lightbox', 'lightshow' and
  // 'lightframe', etc, references and applies onclick events to appropriate
  // links. You can rerun after dynamically adding images w/ajax.
  initList : function(context) {

    if (context == undefined || context == null) {
      context = document;
    }

    // Attach lightbox to any links with rel 'lightbox', 'lightshow' or
    // 'lightframe', etc.
    $("a[rel^='lightbox']:not(.lightbox-processed), area[rel^='lightbox']:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
      if (Lightbox.disableCloseClick) {
        $('#lightbox').unbind('click');
        $('#lightbox').click(function() { Lightbox.end('forceClose'); } );
      }
      Lightbox.start(this, false, false, false, false);
      if (e.preventDefault) { e.preventDefault(); }
      return false;
    });
    $("a[rel^='lightshow']:not(.lightbox-processed), area[rel^='lightshow']:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
      if (Lightbox.disableCloseClick) {
        $('#lightbox').unbind('click');
        $('#lightbox').click(function() { Lightbox.end('forceClose'); } );
      }
      Lightbox.start(this, true, false, false, false);
      if (e.preventDefault) { e.preventDefault(); }
      return false;
    });
    $("a[rel^='lightframe']:not(.lightbox-processed), area[rel^='lightframe']:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
      if (Lightbox.disableCloseClick) {
        $('#lightbox').unbind('click');
        $('#lightbox').click(function() { Lightbox.end('forceClose'); } );
      }
      Lightbox.start(this, false, true, false, false);
      if (e.preventDefault) { e.preventDefault(); }
      return false;
    });
    if (Lightbox.enableVideo) {
      $("a[rel^='lightvideo']:not(.lightbox-processed), area[rel^='lightvideo']:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
        if (Lightbox.disableCloseClick) {
          $('#lightbox').unbind('click');
          $('#lightbox').click(function() { Lightbox.end('forceClose'); } );
        }
        Lightbox.start(this, false, false, true, false);
        if (e.preventDefault) { e.preventDefault(); }
        return false;
      });
    }
    $("a[rel^='lightmodal']:not(.lightbox-processed), area[rel^='lightmodal']:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
      $('#lightbox').unbind('click');
      // Add classes from the link to the lightbox div - don't include lightbox-processed
      $('#lightbox').addClass($(this).attr('class'));
      $('#lightbox').removeClass('lightbox-processed');
      Lightbox.start(this, false, false, false, true);
      if (e.preventDefault) { e.preventDefault(); }
      return false;
    });
    $("#lightboxAutoModal:not(.lightbox-processed)", context).addClass('lightbox-processed').click(function(e) {
      Lightbox.auto_modal = true;
      $('#lightbox').unbind('click');
      Lightbox.start(this, false, false, false, true);
      if (e.preventDefault) { e.preventDefault(); }
      return false;
    });
  },

  // start()
  // Display overlay and lightbox. If image is part of a set, add siblings to
  // imageArray.
  start: function(imageLink, slideshow, lightframe, lightvideo, lightmodal) {

    Lightbox.isPaused = !Lightbox.autoStart;

    // Replaces hideSelectBoxes() and hideFlash() calls in original lightbox2.
    Lightbox.toggleSelectsFlash('hide');

    // Stretch overlay to fill page and fade in.
    var arrayPageSize = Lightbox.getPageSize();
    $("#lightbox2-overlay").hide().css({
      'width': '100%',
      'zIndex': '10090',
      'height': arrayPageSize[1] + 'px',
      'backgroundColor' : '#' + Lightbox.overlayColor
    });
    // Detect OS X FF2 opacity + flash issue.
    if (lightvideo && this.detectMacFF2()) {
      $("#lightbox2-overlay").removeClass("overlay_default");
      $("#lightbox2-overlay").addClass("overlay_macff2");
      $("#lightbox2-overlay").css({'opacity' : null});
    }
    else {
      $("#lightbox2-overlay").removeClass("overlay_macff2");
      $("#lightbox2-overlay").addClass("overlay_default");
      $("#lightbox2-overlay").css({'opacity' : Lightbox.overlayOpacity});
    }
    $("#lightbox2-overlay").fadeIn(Lightbox.fadeInSpeed);


    Lightbox.isSlideshow = slideshow;
    Lightbox.isLightframe = lightframe;
    Lightbox.isVideo = lightvideo;
    Lightbox.isModal = lightmodal;
    Lightbox.imageArray = [];
    Lightbox.imageNum = 0;

    var anchors = $(imageLink.tagName);
    var anchor = null;
    var rel_parts = Lightbox.parseRel(imageLink);
    var rel = rel_parts["rel"];
    var rel_group = rel_parts["group"];
    var title = (rel_parts["title"] ? rel_parts["title"] : imageLink.title);
    var rel_style = null;
    var i = 0;

    if (rel_parts["flashvars"]) {
      Lightbox.flvFlashvars = Lightbox.flvFlashvars + '&' + rel_parts["flashvars"];
    }

    // Set the title for image alternative text.
    var alt = imageLink.title;
    if (!alt) {
      var img = $(imageLink).find("img");
      if (img && $(img).attr("alt")) {
        alt = $(img).attr("alt");
      }
      else {
        alt = title;
      }
    }

    if ($(imageLink).attr('id') == 'lightboxAutoModal') {
      rel_style = rel_parts["style"];
      Lightbox.imageArray.push(['#lightboxAutoModal > *', title, alt, rel_style, 1]);
    }
    else {
      // Handle lightbox images with no grouping.
      if ((rel == 'lightbox' || rel == 'lightshow') && !rel_group) {
        Lightbox.imageArray.push([imageLink.href, title, alt]);
      }

      // Handle other items with no grouping.
      else if (!rel_group) {
        rel_style = rel_parts["style"];
        Lightbox.imageArray.push([imageLink.href, title, alt, rel_style]);
      }

      // Handle grouped items.
      else {

        // Loop through anchors and add them to imageArray.
        for (i = 0; i < anchors.length; i++) {
          anchor = anchors[i];
          if (anchor.href && typeof(anchor.href) == "string" && $(anchor).attr('rel')) {
            var rel_data = Lightbox.parseRel(anchor);
            var anchor_title = (rel_data["title"] ? rel_data["title"] : anchor.title);
            img_alt = anchor.title;
            if (!img_alt) {
              var anchor_img = $(anchor).find("img");
              if (anchor_img && $(anchor_img).attr("alt")) {
                img_alt = $(anchor_img).attr("alt");
              }
              else {
                img_alt = title;
              }
            }
            if (rel_data["rel"] == rel) {
              if (rel_data["group"] == rel_group) {
                if (Lightbox.isLightframe || Lightbox.isModal || Lightbox.isVideo) {
                  rel_style = rel_data["style"];
                }
                Lightbox.imageArray.push([anchor.href, anchor_title, img_alt, rel_style]);
              }
            }
          }
        }

        // Remove duplicates.
        for (i = 0; i < Lightbox.imageArray.length; i++) {
          for (j = Lightbox.imageArray.length-1; j > i; j--) {
            if (Lightbox.imageArray[i][0] == Lightbox.imageArray[j][0]) {
              Lightbox.imageArray.splice(j,1);
            }
          }
        }
        while (Lightbox.imageArray[Lightbox.imageNum][0] != imageLink.href) {
          Lightbox.imageNum++;
        }
      }
    }

    if (Lightbox.isSlideshow && Lightbox.showPlayPause && Lightbox.isPaused) {
      $('#lightshowPlay').show();
      $('#lightshowPause').hide();
    }

    // Calculate top and left offset for the lightbox.
    var arrayPageScroll = Lightbox.getPageScroll();
    var lightboxTop = arrayPageScroll[1] + (Lightbox.topPosition == '' ? (arrayPageSize[3] / 10) : Lightbox.topPosition) * 1;
    var lightboxLeft = arrayPageScroll[0];
    $('#frameContainer, #modalContainer, #lightboxImage').hide();
    $('#hoverNav, #prevLink, #nextLink, #frameHoverNav, #framePrevLink, #frameNextLink').hide();
    $('#imageDataContainer, #numberDisplay, #bottomNavZoom, #bottomNavZoomOut').hide();
    $('#outerImageContainer').css({'width': '250px', 'height': '250px'});
    $('#lightbox').css({
      'zIndex': '10500',
      'top': lightboxTop + 'px',
      'left': lightboxLeft + 'px'
    }).show();

    Lightbox.total = Lightbox.imageArray.length;
    Lightbox.changeData(Lightbox.imageNum);
  },

  // changeData()
  // Hide most elements and preload image in preparation for resizing image
  // container.
  changeData: function(imageNum, zoomIn) {

    if (Lightbox.inprogress === false) {
      if (Lightbox.total > 1 && ((Lightbox.isSlideshow && Lightbox.loopSlides) || (!Lightbox.isSlideshow && Lightbox.loopItems))) {
        if (imageNum >= Lightbox.total) imageNum = 0;
        if (imageNum < 0) imageNum = Lightbox.total - 1;
      }

      if (Lightbox.isSlideshow) {
        for (var i = 0; i < Lightbox.slideIdCount; i++) {
          window.clearTimeout(Lightbox.slideIdArray[i]);
        }
      }
      Lightbox.inprogress = true;
      Lightbox.activeImage = imageNum;

      if (Lightbox.disableResize && !Lightbox.isSlideshow) {
        zoomIn = true;
      }
      Lightbox.isZoomedIn = zoomIn;


      // Hide elements during transition.
      $('#loading').css({'zIndex': '10500'}).show();
      if (!Lightbox.alternative_layout) {
        $('#imageContainer').hide();
      }
      $('#frameContainer, #modalContainer, #lightboxImage').hide();
      $('#hoverNav, #prevLink, #nextLink, #frameHoverNav, #framePrevLink, #frameNextLink').hide();
      $('#imageDataContainer, #numberDisplay, #bottomNavZoom, #bottomNavZoomOut').hide();

      // Preload image content, but not iframe pages.
      if (!Lightbox.isLightframe && !Lightbox.isVideo && !Lightbox.isModal) {
        $("#lightbox #imageDataContainer").removeClass('lightbox2-alt-layout-data');
        imgPreloader = new Image();
        imgPreloader.onerror = function() { Lightbox.imgNodeLoadingError(this); };

        imgPreloader.onload = function() {
          var photo = document.getElementById('lightboxImage');
          photo.src = Lightbox.imageArray[Lightbox.activeImage][0];
          photo.alt = Lightbox.imageArray[Lightbox.activeImage][2];

          var imageWidth = imgPreloader.width;
          var imageHeight = imgPreloader.height;

          // Resize code.
          var arrayPageSize = Lightbox.getPageSize();
          var targ = { w:arrayPageSize[2] - (Lightbox.borderSize * 2), h:arrayPageSize[3] - (Lightbox.borderSize * 6) - (Lightbox.infoHeight * 4) - (arrayPageSize[3] / 10) };
          var orig = { w:imgPreloader.width, h:imgPreloader.height };

          // Image is very large, so show a smaller version of the larger image
          // with zoom button.
          if (zoomIn !== true) {
            var ratio = 1.0; // Shrink image with the same aspect.
            $('#bottomNavZoomOut, #bottomNavZoom').hide();
            if ((orig.w >= targ.w || orig.h >= targ.h) && orig.h && orig.w) {
              ratio = ((targ.w / orig.w) < (targ.h / orig.h)) ? targ.w / orig.w : targ.h / orig.h;
              if (!Lightbox.disableZoom && !Lightbox.isSlideshow) {
                $('#bottomNavZoom').css({'zIndex': '10500'}).show();
              }
            }

            imageWidth  = Math.floor(orig.w * ratio);
            imageHeight = Math.floor(orig.h * ratio);
          }

          else {
            $('#bottomNavZoom').hide();
            // Only display zoom out button if the image is zoomed in already.
            if ((orig.w >= targ.w || orig.h >= targ.h) && orig.h && orig.w) {
              // Only display zoom out button if not a slideshow and if the
              // buttons aren't disabled.
              if (!Lightbox.disableResize && Lightbox.isSlideshow === false && !Lightbox.disableZoom) {
                $('#bottomNavZoomOut').css({'zIndex': '10500'}).show();
              }
            }
          }

          photo.style.width = (imageWidth) + 'px';
          photo.style.height = (imageHeight) + 'px';
          Lightbox.resizeContainer(imageWidth, imageHeight);

          // Clear onLoad, IE behaves irratically with animated gifs otherwise.
          imgPreloader.onload = function() {};
        };

        imgPreloader.src = Lightbox.imageArray[Lightbox.activeImage][0];
        imgPreloader.alt = Lightbox.imageArray[Lightbox.activeImage][2];
      }

      // Set up frame size, etc.
      else if (Lightbox.isLightframe) {
        $("#lightbox #imageDataContainer").addClass('lightbox2-alt-layout-data');
        var src = Lightbox.imageArray[Lightbox.activeImage][0];
        $('#frameContainer').html('<iframe id="lightboxFrame" style="display: none;" src="'+src+'"></iframe>');

        // Enable swf support in Gecko browsers.
        if ($.browser.mozilla && src.indexOf('.swf') != -1) {
          setTimeout(function () {
            document.getElementById("lightboxFrame").src = Lightbox.imageArray[Lightbox.activeImage][0];
          }, 1000);
        }

        if (!Lightbox.iframe_border) {
          $('#lightboxFrame').css({'border': 'none'});
          $('#lightboxFrame').attr('frameborder', '0');
        }
        var iframe = document.getElementById('lightboxFrame');
        var iframeStyles = Lightbox.imageArray[Lightbox.activeImage][3];
        iframe = Lightbox.setStyles(iframe, iframeStyles);
        Lightbox.resizeContainer(parseInt(iframe.width, 10), parseInt(iframe.height, 10));
      }
      else if (Lightbox.isVideo || Lightbox.isModal) {
        $("#lightbox #imageDataContainer").addClass('lightbox2-alt-layout-data');
        var container = document.getElementById('modalContainer');
        var modalStyles = Lightbox.imageArray[Lightbox.activeImage][3];
        container = Lightbox.setStyles(container, modalStyles);
        if (Lightbox.isVideo) {
          Lightbox.modalHeight =  parseInt(container.height, 10) - 10;
          Lightbox.modalWidth =  parseInt(container.width, 10) - 10;
          Lightvideo.startVideo(Lightbox.imageArray[Lightbox.activeImage][0]);
        }
        Lightbox.resizeContainer(parseInt(container.width, 10), parseInt(container.height, 10));
      }
    }
  },

  // imgNodeLoadingError()
  imgNodeLoadingError: function(image) {
    var s = Drupal.settings.lightbox2;
    var original_image = Lightbox.imageArray[Lightbox.activeImage][0];
    if (s.display_image_size !== "") {
      original_image = original_image.replace(new RegExp("."+s.display_image_size), "");
    }
    Lightbox.imageArray[Lightbox.activeImage][0] = original_image;
    image.onerror = function() { Lightbox.imgLoadingError(image); };
    image.src = original_image;
  },

  // imgLoadingError()
  imgLoadingError: function(image) {
    var s = Drupal.settings.lightbox2;
    Lightbox.imageArray[Lightbox.activeImage][0] = s.default_image;
    image.src = s.default_image;
  },

  // resizeContainer()
  resizeContainer: function(imgWidth, imgHeight) {

    imgWidth = (imgWidth < Lightbox.minWidth ? Lightbox.minWidth : imgWidth);

    this.widthCurrent = $('#outerImageContainer').width();
    this.heightCurrent = $('#outerImageContainer').height();

    var widthNew = (imgWidth  + (Lightbox.borderSize * 2));
    var heightNew = (imgHeight  + (Lightbox.borderSize * 2));

    // Scalars based on change from old to new.
    this.xScale = ( widthNew / this.widthCurrent) * 100;
    this.yScale = ( heightNew / this.heightCurrent) * 100;

    // Calculate size difference between new and old image, and resize if
    // necessary.
    wDiff = this.widthCurrent - widthNew;
    hDiff = this.heightCurrent - heightNew;

    $('#modalContainer').css({'width': imgWidth, 'height': imgHeight});
    // Detect animation sequence.
    if (Lightbox.resizeSequence) {
      var animate1 = {width: widthNew};
      var animate2 = {height: heightNew};
      if (Lightbox.resizeSequence == 2) {
        animate1 = {height: heightNew};
        animate2 = {width: widthNew};
      }
      $('#outerImageContainer').animate(animate1, Lightbox.resizeSpeed).animate(animate2, Lightbox.resizeSpeed, 'linear', function() { Lightbox.showData(); });
    }
    // Simultaneous.
    else {
      $('#outerImageContainer').animate({'width': widthNew, 'height': heightNew}, Lightbox.resizeSpeed, 'linear', function() { Lightbox.showData(); });
    }

    // If new and old image are same size and no scaling transition is necessary
    // do a quick pause to prevent image flicker.
    if ((hDiff === 0) && (wDiff === 0)) {
      if ($.browser.msie) {
        Lightbox.pause(250);
      }
      else {
        Lightbox.pause(100);
      }
    }

    var s = Drupal.settings.lightbox2;
    if (!s.use_alt_layout) {
      $('#prevLink, #nextLink').css({'height': imgHeight + 'px'});
    }
    $('#imageDataContainer').css({'width': widthNew + 'px'});
  },

  // showData()
  // Display image and begin preloading neighbors.
  showData: function() {
    $('#loading').hide();

    if (Lightbox.isLightframe || Lightbox.isVideo || Lightbox.isModal) {
      Lightbox.updateDetails();
      if (Lightbox.isLightframe) {
        $('#frameContainer').show();
        if ($.browser.safari || Lightbox.fadeInSpeed === 0) {
          $('#lightboxFrame').css({'zIndex': '10500'}).show();
        }
        else {
          $('#lightboxFrame').css({'zIndex': '10500'}).fadeIn(Lightbox.fadeInSpeed);
        }
      }
      else {
        if (Lightbox.isVideo) {
          $("#modalContainer").html(Lightbox.modalHTML).click(function(){return false;}).css('zIndex', '10500').show();
        }
        else {
          var src = unescape(Lightbox.imageArray[Lightbox.activeImage][0]);
          if (Lightbox.imageArray[Lightbox.activeImage][4]) {
            $(src).appendTo("#modalContainer");
            $('#modalContainer').css({'zIndex': '10500'}).show();
          }
          else {
            // Use a callback to show the new image, otherwise you get flicker.
            $("#modalContainer").hide().load(src, function () {$('#modalContainer').css({'zIndex': '10500'}).show();});
          }
          $('#modalContainer').unbind('click');
        }
        // This might be needed in the Lightframe section above.
        //$('#modalContainer').css({'zIndex': '10500'}).show();
      }
    }

    // Handle display of image content.
    else {
      $('#imageContainer').show();
      if ($.browser.safari || Lightbox.fadeInSpeed === 0) {
        $('#lightboxImage').css({'zIndex': '10500'}).show();
      }
      else {
        $('#lightboxImage').css({'zIndex': '10500'}).fadeIn(Lightbox.fadeInSpeed);
      }
      Lightbox.updateDetails();
      this.preloadNeighborImages();
    }
    Lightbox.inprogress = false;

    // Slideshow specific stuff.
    if (Lightbox.isSlideshow) {
      if (!Lightbox.loopSlides && Lightbox.activeImage == (Lightbox.total - 1)) {
        if (Lightbox.autoExit) {
          Lightbox.slideIdArray[Lightbox.slideIdCount++] = setTimeout(function () {Lightbox.end('slideshow');}, Lightbox.slideInterval);
        }
      }
      else {
        if (!Lightbox.isPaused && Lightbox.total > 1) {
          Lightbox.slideIdArray[Lightbox.slideIdCount++] = setTimeout(function () {Lightbox.changeData(Lightbox.activeImage + 1);}, Lightbox.slideInterval);
        }
      }
      if (Lightbox.showPlayPause && Lightbox.total > 1 && !Lightbox.isPaused) {
        $('#lightshowPause').show();
        $('#lightshowPlay').hide();
      }
      else if (Lightbox.showPlayPause && Lightbox.total > 1) {
        $('#lightshowPause').hide();
        $('#lightshowPlay').show();
      }
    }

    // Adjust the page overlay size.
    var arrayPageSize = Lightbox.getPageSize();
    var arrayPageScroll = Lightbox.getPageScroll();
    var pageHeight = arrayPageSize[1];
    if (Lightbox.isZoomedIn && arrayPageSize[1] > arrayPageSize[3]) {
      var lightboxTop = (Lightbox.topPosition == '' ? (arrayPageSize[3] / 10) : Lightbox.topPosition) * 1;
      pageHeight = pageHeight + arrayPageScroll[1] + lightboxTop;
    }
    $('#lightbox2-overlay').css({'height': pageHeight + 'px', 'width': arrayPageSize[0] + 'px'});

    // Gecko browsers (e.g. Firefox, SeaMonkey, etc) don't handle pdfs as
    // expected.
    if ($.browser.mozilla) {
      if (Lightbox.imageArray[Lightbox.activeImage][0].indexOf(".pdf") != -1) {
        setTimeout(function () {
          document.getElementById("lightboxFrame").src = Lightbox.imageArray[Lightbox.activeImage][0];
        }, 1000);
      }
    }
  },

  // updateDetails()
  // Display caption, image number, and bottom nav.
  updateDetails: function() {

    $("#imageDataContainer").hide();

    var s = Drupal.settings.lightbox2;

    if (s.show_caption) {
      var caption = Lightbox.filterXSS(Lightbox.imageArray[Lightbox.activeImage][1]);
      if (!caption) caption = '';
      $('#caption').html(caption).css({'zIndex': '10500'}).show();
    }

    // If image is part of set display 'Image x of x'.
    var numberDisplay = null;
    if (s.image_count && Lightbox.total > 1) {
      var currentImage = Lightbox.activeImage + 1;
      if (!Lightbox.isLightframe && !Lightbox.isModal && !Lightbox.isVideo) {
        numberDisplay = s.image_count.replace(/\!current/, currentImage).replace(/\!total/, Lightbox.total);
      }
      else if (Lightbox.isVideo) {
        numberDisplay = s.video_count.replace(/\!current/, currentImage).replace(/\!total/, Lightbox.total);
      }
      else {
        numberDisplay = s.page_count.replace(/\!current/, currentImage).replace(/\!total/, Lightbox.total);
      }
      $('#numberDisplay').html(numberDisplay).css({'zIndex': '10500'}).show();
    }
    else {
      $('#numberDisplay').hide();
    }

    $("#imageDataContainer").hide().slideDown(Lightbox.slideDownSpeed, function() {
      $("#bottomNav").show();
    });
    if (Lightbox.rtl == 1) {
      $("#bottomNav").css({'float': 'left'});
    }
    Lightbox.updateNav();
  },

  // updateNav()
  // Display appropriate previous and next hover navigation.
  updateNav: function() {

    $('#hoverNav').css({'zIndex': '10500'}).show();
    var prevLink = '#prevLink';
    var nextLink = '#nextLink';

    // Slideshow is separated as we need to show play / pause button.
    if (Lightbox.isSlideshow) {
      if ((Lightbox.total > 1 && Lightbox.loopSlides) || Lightbox.activeImage !== 0) {
        $(prevLink).css({'zIndex': '10500'}).show().click(function() {
          if (Lightbox.pauseOnPrevClick) {
            Lightbox.togglePlayPause("lightshowPause", "lightshowPlay");
          }
          Lightbox.changeData(Lightbox.activeImage - 1); return false;
        });
      }
      else {
        $(prevLink).hide();
      }

      // If not last image in set, display next image button.
      if ((Lightbox.total > 1 && Lightbox.loopSlides) || Lightbox.activeImage != (Lightbox.total - 1)) {
        $(nextLink).css({'zIndex': '10500'}).show().click(function() {
          if (Lightbox.pauseOnNextClick) {
            Lightbox.togglePlayPause("lightshowPause", "lightshowPlay");
          }
          Lightbox.changeData(Lightbox.activeImage + 1); return false;
        });
      }
      // Safari browsers need to have hide() called again.
      else {
        $(nextLink).hide();
      }
    }

    // All other types of content.
    else {

      if ((Lightbox.isLightframe || Lightbox.isModal || Lightbox.isVideo) && !Lightbox.alternative_layout) {
        $('#frameHoverNav').css({'zIndex': '10500'}).show();
        $('#hoverNav').css({'zIndex': '10500'}).hide();
        prevLink = '#framePrevLink';
        nextLink = '#frameNextLink';
      }

      // If not first image in set, display prev image button.
      if ((Lightbox.total > 1 && Lightbox.loopItems) || Lightbox.activeImage !== 0) {
        // Unbind any other click handlers, otherwise this adds a new click handler
        // each time the arrow is clicked.
        $(prevLink).css({'zIndex': '10500'}).show().unbind().click(function() {
          Lightbox.changeData(Lightbox.activeImage - 1); return false;
        });
      }
      // Safari browsers need to have hide() called again.
      else {
        $(prevLink).hide();
      }

      // If not last image in set, display next image button.
      if ((Lightbox.total > 1 && Lightbox.loopItems) || Lightbox.activeImage != (Lightbox.total - 1)) {
        // Unbind any other click handlers, otherwise this adds a new click handler
        // each time the arrow is clicked.
        $(nextLink).css({'zIndex': '10500'}).show().unbind().click(function() {
          Lightbox.changeData(Lightbox.activeImage + 1); return false;
        });
      }
      // Safari browsers need to have hide() called again.
      else {
        $(nextLink).hide();
      }
    }

    // Don't enable keyboard shortcuts so forms will work.
    if (!Lightbox.isModal) {
      this.enableKeyboardNav();
    }
  },


  // enableKeyboardNav()
  enableKeyboardNav: function() {
    $(document).bind("keydown", this.keyboardAction);
  },

  // disableKeyboardNav()
  disableKeyboardNav: function() {
    $(document).unbind("keydown", this.keyboardAction);
  },

  // keyboardAction()
  keyboardAction: function(e) {
    if (e === null) { // IE.
      keycode = event.keyCode;
      escapeKey = 27;
    }
    else { // Mozilla.
      keycode = e.keyCode;
      escapeKey = e.DOM_VK_ESCAPE;
    }

    key = String.fromCharCode(keycode).toLowerCase();

    // Close lightbox.
    if (Lightbox.checkKey(Lightbox.keysClose, key, keycode)) {
      Lightbox.end('forceClose');
    }
    // Display previous image (p, <-).
    else if (Lightbox.checkKey(Lightbox.keysPrevious, key, keycode)) {
      if ((Lightbox.total > 1 && ((Lightbox.isSlideshow && Lightbox.loopSlides) || (!Lightbox.isSlideshow && Lightbox.loopItems))) || Lightbox.activeImage !== 0) {
        Lightbox.changeData(Lightbox.activeImage - 1);
      }

    }
    // Display next image (n, ->).
    else if (Lightbox.checkKey(Lightbox.keysNext, key, keycode)) {
      if ((Lightbox.total > 1 && ((Lightbox.isSlideshow && Lightbox.loopSlides) || (!Lightbox.isSlideshow && Lightbox.loopItems))) || Lightbox.activeImage != (Lightbox.total - 1)) {
        Lightbox.changeData(Lightbox.activeImage + 1);
      }
    }
    // Zoom in.
    else if (Lightbox.checkKey(Lightbox.keysZoom, key, keycode) && !Lightbox.disableResize && !Lightbox.disableZoom && !Lightbox.isSlideshow && !Lightbox.isLightframe) {
      if (Lightbox.isZoomedIn) {
        Lightbox.changeData(Lightbox.activeImage, false);
      }
      else if (!Lightbox.isZoomedIn) {
        Lightbox.changeData(Lightbox.activeImage, true);
      }
      return false;
    }
    // Toggle play / pause (space).
    else if (Lightbox.checkKey(Lightbox.keysPlayPause, key, keycode) && Lightbox.isSlideshow) {

      if (Lightbox.isPaused) {
        Lightbox.togglePlayPause("lightshowPlay", "lightshowPause");
      }
      else {
        Lightbox.togglePlayPause("lightshowPause", "lightshowPlay");
      }
      return false;
    }
  },

  preloadNeighborImages: function() {

    if ((Lightbox.total - 1) > Lightbox.activeImage) {
      preloadNextImage = new Image();
      preloadNextImage.src = Lightbox.imageArray[Lightbox.activeImage + 1][0];
    }
    if (Lightbox.activeImage > 0) {
      preloadPrevImage = new Image();
      preloadPrevImage.src = Lightbox.imageArray[Lightbox.activeImage - 1][0];
    }

  },

  end: function(caller) {
    var closeClick = (caller == 'slideshow' ? false : true);
    if (Lightbox.isSlideshow && Lightbox.isPaused && !closeClick) {
      return;
    }
    // To prevent double clicks on navigation links.
    if (Lightbox.inprogress === true && caller != 'forceClose') {
      return;
    }
    Lightbox.disableKeyboardNav();
    $('#lightbox').hide();
    $("#lightbox2-overlay").fadeOut();
    Lightbox.isPaused = true;
    Lightbox.inprogress = false;
    // Replaces calls to showSelectBoxes() and showFlash() in original
    // lightbox2.
    Lightbox.toggleSelectsFlash('visible');
    if (Lightbox.isSlideshow) {
      for (var i = 0; i < Lightbox.slideIdCount; i++) {
        window.clearTimeout(Lightbox.slideIdArray[i]);
      }
      $('#lightshowPause, #lightshowPlay').hide();
    }
    else if (Lightbox.isLightframe) {
      $('#frameContainer').empty().hide();
    }
    else if (Lightbox.isVideo || Lightbox.isModal) {
      if (!Lightbox.auto_modal) {
        $('#modalContainer').hide().html("");
      }
      Lightbox.auto_modal = false;
    }
  },


  // getPageScroll()
  // Returns array with x,y page scroll values.
  // Core code from - quirksmode.com.
  getPageScroll : function() {

    var xScroll, yScroll;

    if (self.pageYOffset || self.pageXOffset) {
      yScroll = self.pageYOffset;
      xScroll = self.pageXOffset;
    }
    else if (document.documentElement && (document.documentElement.scrollTop || document.documentElement.scrollLeft)) {  // Explorer 6 Strict.
      yScroll = document.documentElement.scrollTop;
      xScroll = document.documentElement.scrollLeft;
    }
    else if (document.body) {// All other Explorers.
      yScroll = document.body.scrollTop;
      xScroll = document.body.scrollLeft;
    }

    arrayPageScroll = [xScroll,yScroll];
    return arrayPageScroll;
  },

  // getPageSize()
  // Returns array with page width, height and window width, height.
  // Core code from - quirksmode.com.
  // Edit for Firefox by pHaez.

  getPageSize : function() {

    var xScroll, yScroll;

    if (window.innerHeight && window.scrollMaxY) {
      xScroll = window.innerWidth + window.scrollMaxX;
      yScroll = window.innerHeight + window.scrollMaxY;
    }
    else if (document.body.scrollHeight > document.body.offsetHeight) { // All but Explorer Mac.
      xScroll = document.body.scrollWidth;
      yScroll = document.body.scrollHeight;
    }
    else { // Explorer Mac...would also work in Explorer 6 Strict, Mozilla and Safari.
      xScroll = document.body.offsetWidth;
      yScroll = document.body.offsetHeight;
    }

    var windowWidth, windowHeight;

    if (self.innerHeight) { // All except Explorer.
      if (document.documentElement.clientWidth) {
        windowWidth = document.documentElement.clientWidth;
      }
      else {
        windowWidth = self.innerWidth;
      }
      windowHeight = self.innerHeight;
    }
    else if (document.documentElement && document.documentElement.clientHeight) { // Explorer 6 Strict Mode.
      windowWidth = document.documentElement.clientWidth;
      windowHeight = document.documentElement.clientHeight;
    }
    else if (document.body) { // Other Explorers.
      windowWidth = document.body.clientWidth;
      windowHeight = document.body.clientHeight;
    }
    // For small pages with total height less than height of the viewport.
    if (yScroll < windowHeight) {
      pageHeight = windowHeight;
    }
    else {
      pageHeight = yScroll;
    }
    // For small pages with total width less than width of the viewport.
    if (xScroll < windowWidth) {
      pageWidth = xScroll;
    }
    else {
      pageWidth = windowWidth;
    }
    arrayPageSize = new Array(pageWidth,pageHeight,windowWidth,windowHeight);
    return arrayPageSize;
  },


  // pause(numberMillis)
  pause : function(ms) {
    var date = new Date();
    var curDate = null;
    do { curDate = new Date(); }
    while (curDate - date < ms);
  },


  // toggleSelectsFlash()
  // Hide / unhide select lists and flash objects as they appear above the
  // lightbox in some browsers.
  toggleSelectsFlash: function (state) {
    if (state == 'visible') {
      $("select.lightbox_hidden, embed.lightbox_hidden, object.lightbox_hidden").show();
    }
    else if (state == 'hide') {
      $("select:visible, embed:visible, object:visible").not('#lightboxAutoModal select, #lightboxAutoModal embed, #lightboxAutoModal object').addClass("lightbox_hidden");
      $("select.lightbox_hidden, embed.lightbox_hidden, object.lightbox_hidden").hide();
    }
  },


  // parseRel()
  parseRel: function (link) {
    var parts = [];
    parts["rel"] = parts["title"] = parts["group"] = parts["style"] = parts["flashvars"] = null;
    if (!$(link).attr('rel')) return parts;
    parts["rel"] = $(link).attr('rel').match(/\w+/)[0];

    if ($(link).attr('rel').match(/\[(.*)\]/)) {
      var info = $(link).attr('rel').match(/\[(.*?)\]/)[1].split('|');
      parts["group"] = info[0];
      parts["style"] = info[1];
      if (parts["style"] != undefined && parts["style"].match(/flashvars:\s?(.*?);/)) {
        parts["flashvars"] = parts["style"].match(/flashvars:\s?(.*?);/)[1];
      }
    }
    if ($(link).attr('rel').match(/\[.*\]\[(.*)\]/)) {
      parts["title"] = $(link).attr('rel').match(/\[.*\]\[(.*)\]/)[1];
    }
    return parts;
  },

  // setStyles()
  setStyles: function(item, styles) {
    item.width = Lightbox.iframe_width;
    item.height = Lightbox.iframe_height;
    item.scrolling = "auto";

    if (!styles) return item;
    var stylesArray = styles.split(';');
    for (var i = 0; i< stylesArray.length; i++) {
      if (stylesArray[i].indexOf('width:') >= 0) {
        var w = stylesArray[i].replace('width:', '');
        item.width = jQuery.trim(w);
      }
      else if (stylesArray[i].indexOf('height:') >= 0) {
        var h = stylesArray[i].replace('height:', '');
        item.height = jQuery.trim(h);
      }
      else if (stylesArray[i].indexOf('scrolling:') >= 0) {
        var scrolling = stylesArray[i].replace('scrolling:', '');
        item.scrolling = jQuery.trim(scrolling);
      }
      else if (stylesArray[i].indexOf('overflow:') >= 0) {
        var overflow = stylesArray[i].replace('overflow:', '');
        item.overflow = jQuery.trim(overflow);
      }
    }
    return item;
  },


  // togglePlayPause()
  // Hide the pause / play button as appropriate.  If pausing the slideshow also
  // clear the timers, otherwise move onto the next image.
  togglePlayPause: function(hideId, showId) {
    if (Lightbox.isSlideshow && hideId == "lightshowPause") {
      for (var i = 0; i < Lightbox.slideIdCount; i++) {
        window.clearTimeout(Lightbox.slideIdArray[i]);
      }
    }
    $('#' + hideId).hide();
    $('#' + showId).show();

    if (hideId == "lightshowPlay") {
      Lightbox.isPaused = false;
      if (!Lightbox.loopSlides && Lightbox.activeImage == (Lightbox.total - 1)) {
        Lightbox.end();
      }
      else if (Lightbox.total > 1) {
        Lightbox.changeData(Lightbox.activeImage + 1);
      }
    }
    else {
      Lightbox.isPaused = true;
    }
  },

  triggerLightbox: function (rel_type, rel_group) {
    if (rel_type.length) {
      if (rel_group && rel_group.length) {
        $("a[rel^='" + rel_type +"\[" + rel_group + "\]'], area[rel^='" + rel_type +"\[" + rel_group + "\]']").eq(0).trigger("click");
      }
      else {
        $("a[rel^='" + rel_type +"'], area[rel^='" + rel_type +"']").eq(0).trigger("click");
      }
    }
  },

  detectMacFF2: function() {
    var ua = navigator.userAgent.toLowerCase();
    if (/firefox[\/\s](\d+\.\d+)/.test(ua)) {
      var ffversion = new Number(RegExp.$1);
      if (ffversion < 3 && ua.indexOf('mac') != -1) {
        return true;
      }
    }
    return false;
  },

  checkKey: function(keys, key, code) {
    return (jQuery.inArray(key, keys) != -1 || jQuery.inArray(String(code), keys) != -1);
  },

  filterXSS: function(str, allowed_tags) {
    var output = "";
    $.ajax({
      url: Drupal.settings.basePath + 'system/lightbox2/filter-xss',
      data: {
        'string' : str,
        'allowed_tags' : allowed_tags
      },
      type: "POST",
      async: false,
      dataType:  "json",
      success: function(data) {
        output = data;
      }
    });
    return output;
  }

};

// Initialize the lightbox.
Drupal.behaviors.initLightbox = function (context) {
  $('body:not(.lightbox-processed)', context).addClass('lightbox-processed').each(function() {
    Lightbox.initialize();
    return false; // Break the each loop.
  });

  // Attach lightbox to any links with lightbox rels.
  Lightbox.initList(context);
  $('#lightboxAutoModal', context).triggerHandler('click');
};

;
(function ($) {

/**
 * Open Mollom privacy policy link in a new window.
 *
 * Required for valid XHTML Strict markup.
 */
Drupal.behaviors.mollomPrivacy = function (context) {
  $('.mollom-privacy a', context).click(function () {
    this.target = '_blank';
  });
};

/**
 * Attach click event handlers for CAPTCHA links.
 */
Drupal.behaviors.mollomCaptcha = function (context) {
  $('a.mollom-switch-captcha', context).click(getMollomCaptcha);
};

/**
 * Fetch a Mollom CAPTCHA and output the image or audio into the form.
 */
function getMollomCaptcha() {
  // Get the current requested CAPTCHA type from the clicked link.
  var newCaptchaType = $(this).hasClass('mollom-audio-captcha') ? 'audio' : 'image';

  var context = $(this).parents('form');

  // Extract the Mollom session id from the form.
  var mollomSessionId = $('input.mollom-session-id', context).val();

  // Retrieve a CAPTCHA:
  $.getJSON(Drupal.settings.basePath + 'mollom/captcha/' + newCaptchaType + '/' + mollomSessionId,
    function (data) {
      if (!(data && data.content)) {
        return;
      }
      // Inject new CAPTCHA.
      $('.mollom-captcha-content', context).parent().html(data.content);
      // Update session id.
      $('input.mollom-session-id', context).val(data.session_id);
      // Add an onclick-event handler for the new link.
      Drupal.attachBehaviors(context);
      // Focus on the CATPCHA input.
      $('input[name="mollom[captcha]"]', context).focus();
    }
  );
  return false;
}

})(jQuery);
;
$.extend({URLEncode:function(c){var o='';var x=0;c=c.toString();var r=/(^[a-zA-Z0-9_.]*)/;
  while(x<c.length){var m=r.exec(c.substr(x));
    if(m!=null && m.length>1 && m[1]!=''){o+=m[1];x+=m[1].length;
    }else{if(c[x]==' ')o+='+';else{var d=c.charCodeAt(x);var h=d.toString(16);
    o+='%'+(h.length<2?'0':'')+h.toUpperCase();}x++;}}return o;},
URLDecode:function(s){var o=s;var binVal,t;var r=/(%[^%]{2})/;
  while((m=r.exec(o))!=null && m.length>1 && m[1]!=''){b=parseInt(m[1].substr(1),16);
  t=String.fromCharCode(b);o=o.replace(m[1],t);}return o;}
});;
/*
 * JTip
 * By Cody Lindley (http://www.codylindley.com)
 * Under an Attribution, Share Alike License
 * JTip is built on top of the very light weight jquery library.
 */

//on page load (as soon as its ready) call JT_init
jQuery(document).ready(JT_init);

function JT_init(){
	       jQuery("a.jTip")
		   .hover(	function(){
						JT_show(this.href,this,this.name)},
					function(){
						jQuery('#JT').remove()
						})
           .click(function(){return false});	   
}

function JT_show(url,linkId,title){
	if(title == false)title="&nbsp;";
	var de = document.documentElement;
	var w = self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth;
	var hasArea = w - getAbsoluteLeft(linkId);
	var clickElementy = getAbsoluteTop(linkId) - 3; //set y position
	
	//check if the tooltip would overlap
	var pScroll = getPageScroll();
	var pSize = getPageSize();
	var overLap = false;
	if ( ( clickElementy + 290 ) > ( pScroll[1] + pSize[3] ) ){
		clickElementy -= 266;
		overLap = true;
	}
	
	var queryString = url.replace(/^[^\?]+\??/,'');
	var params = parseQuery( queryString );
	if(params['width'] === undefined){params['width'] = 250};
	if(params['link'] !== undefined){
	jQuery(linkId).bind('click',function(){window.location = params['link']});
	jQuery(linkId).css('cursor','pointer');
	}
	
	if(hasArea>((params['width']*1)+75)){
		jQuery("body").append("<div id='JT' style='display:none;width:"+params['width']*1+"px'><div id='JT_arrow'></div><div id='JT_copy'></div>");//right side
		var arrowOffset = getElementWidth(linkId) + 11;
		var clickElementx = getAbsoluteLeft(linkId) + arrowOffset; //set x position
		jQuery('#JT_arrow').addClass('JT_arrow_left');
	}else{
		jQuery("body").append("<div id='JT' style='display:none;width:"+params['width']*1+"px'><div id='JT_arrow' style='left:"+((params['width']*1)+1)+"px'></div><div id='JT_copy'></div>");//left side
		var clickElementx = getAbsoluteLeft(linkId) - ((params['width']*1) + 15); //set x position
		jQuery('#JT_arrow').addClass('JT_arrow_right');
	}
	
	jQuery('#JT').css({left: clickElementx+"px", top: clickElementy+"px"});
	
	if ( overLap ){
		jQuery('#JT_arrow').addClass('JT_arrow_bottom');
	}else{
		jQuery('#JT_arrow').addClass('JT_arrow_top');
	}
	//jQuery('#JT').show();
	
	jQuery('#JT').fadeIn("slow");
	jQuery('#JT_copy').load(url);

}

function getElementWidth(objectId) {
	x = objectId;
	return x.offsetWidth;
}

function getAbsoluteLeft(objectId) {
	// Get an object left position from the upper left viewport corner
	o = objectId;
	oLeft = o.offsetLeft            // Get left position from the parent object
	while(o.offsetParent!=null) {   // Parse the parent hierarchy up to the document element
		oParent = o.offsetParent    // Get parent object reference
		oLeft += oParent.offsetLeft // Add parent left position
		o = oParent
	}
	return oLeft
}

function getAbsoluteTop(objectId) {
	// Get an object top position from the upper left viewport corner
	o = objectId;
	oTop = o.offsetTop            // Get top position from the parent object
	while(o.offsetParent!=null) { // Parse the parent hierarchy up to the document element
		oParent = o.offsetParent  // Get parent object reference
		oTop += oParent.offsetTop // Add parent top position
		o = oParent
	}
	return oTop
}

function parseQuery ( query ) {
   var Params = new Object ();
   if ( ! query ) return Params; // return empty object
   var Pairs = query.split(/[;&]/);
   for ( var i = 0; i < Pairs.length; i++ ) {
      var KeyVal = Pairs[i].split('=');
      if ( ! KeyVal || KeyVal.length != 2 ) continue;
      var key = unescape( KeyVal[0] );
      var val = unescape( KeyVal[1] );
      val = val.replace(/\+/g, ' ');
      Params[key] = val;
   }
   return Params;
}

function blockEvents(evt) {
              if(evt.target){
              evt.preventDefault();
              }else{
              evt.returnValue = false;
              }
}

//cardzoomer for the draft view
jQuery(document).ready(cardzoomer_init);
function cardzoomer_init(){
	jQuery("img.cardzoomer")
	.hover( function(){
		show_card(this, this.src, "zoom")
	},
	function(){
	}
	)
	.click(function(){return false});
	
	jQuery("img.cardfader")
	.hover( function(){
		show_card(this, this.src, "fade")
	},
	function(){
	}
	)
	.click(function(){return false});
}

function show_card(element, src, mode){
	var dim = jQuery(element).offset();
	
	speed_zoom		= 400; 
	speed_fade = 600;
	e_top 		= dim['top'];
	e_left 		= dim['left'];
	e_height	= jQuery(element).innerHeight();
	e_width		= jQuery(element).innerWidth();
	
	jQuery("body").append("<div id='card_hider' onmouseout='card_hider();'></div>"+
					"<div id='display_card_box' onmouseout='card_hider();'><img id='display_card' src=''/></div>");
	
	jQuery('#display_card_box').css('display','block')
							.css('position','absolute')
							.css('top',e_top)
							.css('left',e_left)
							.css('height',e_height)
							.css('width',e_width)
							.css('background-color','#000000');
	jQuery('#display_card').attr('src',src)
						.css('width',e_width)
						.css('height',e_height)
						.css('z-index','100');
	jQuery('#card_hider').css('position','absolute')
					.css('top',e_top)
					.css('left',e_left)
					.css('width',e_width)
					.css('height',e_height)
					.css('z-index','101');
	
	if(jQuery(element).hasClass('cardpick_border')){
		jQuery('#display_card_box').addClass('cardpick_border');
	}
	
	if( mode == "fade" ){
	
		var top = e_top-parseInt((285-e_height)/2);
		var left = e_left-parseInt((200-e_width)/2);
	
		jQuery('#display_card_box').css('display','block')
							.css('position','absolute')
							.css('top', (top+'px'))
							.css('left', (left+'px'))
							.css('height', '285px')
							.css('width', '200px')
							.css('background-color','#000000');
		jQuery('#display_card').attr('src',src)
							.css('width', '200px')
							.css('height', '285px')
							.css('z-index','100px');

		jQuery("#display_card_box").stop().css('display','none').fadeIn(speed_fade);
	}else{
		jQuery("#display_card").stop().animate({ 
			width: '200px',
			height: '285px'
			}, speed_zoom );

		jQuery("#display_card_box").stop().animate({ 
			width: '200px',
			height: '285px',
			top: e_top-((285-e_height)/2)+'px',
			left: e_left-((200-e_width)/2)+'px'
			}, speed_zoom );
	}
}
function card_hider(){
	if(jQuery('#display_card_box').length > 0){
		jQuery('#display_card_box').stop().remove();
		jQuery('#card_hider').stop().remove();
	}
}

function toggle_pick(elem){
	parent = jQuery(elem).parent().parent().parent().attr('id');
	jQuery('#'+parent+' .cardpick').each(function()
	{
		a_element = jQuery(this);

		if( a_element.is('img') ){
			if ( a_element.hasClass('cardpick_border') )
			{
				a_element.removeClass('cardpick_border');
				var n_width = (parseInt(a_element.css('width'))+4)+'px';
				a_element.css('width',n_width);
				var n_height = (parseInt(a_element.css('height'))+4)+'px';
				a_element.css('height',n_height);
				jQuery(elem).html('show pick');
			} else {
				a_element.addClass('cardpick_border');
				var n_width = (parseInt(a_element.css('width'))-4)+'px';
				a_element.css('width',n_width);
				var n_height = (parseInt(a_element.css('height'))-4)+'px';
				a_element.css('height',n_height);
				jQuery(elem).html('hide pick');
			}
		}
		if( a_element.is('a') ){
			if ( a_element.hasClass('cardpick_border') )
			{
				a_element.removeClass('cardpick_border');
				jQuery(elem).html('show pick');
			} else {
				a_element.addClass('cardpick_border');
				jQuery(elem).html('hide pick');
			}		
		}
	});
	return false;
}

// getPageScroll()
// Returns array with x,y page scroll values.
// Core code from - quirksmode.com
//
function getPageScroll(){

	var xScroll, yScroll;

	if (self.pageYOffset) {
		yScroll = self.pageYOffset;
		xScroll = self.pageXOffset;
	} else if (document.documentElement && document.documentElement.scrollTop){	 // Explorer 6 Strict
		yScroll = document.documentElement.scrollTop;
		xScroll = document.documentElement.scrollLeft;
	} else if (document.body) {// all other Explorers
		yScroll = document.body.scrollTop;
		xScroll = document.body.scrollLeft;
	}

	arrayPageScroll = new Array(xScroll,yScroll)
	return arrayPageScroll;
}

//
// getPageSize()
// Returns array with page width, height and window width, height
// Core code from - quirksmode.com
// Edit for Firefox by pHaez
//
function getPageSize(){

	var xScroll, yScroll;

	if (window.innerHeight && window.scrollMaxY) {
		xScroll = window.innerWidth + window.scrollMaxX;
		yScroll = window.innerHeight + window.scrollMaxY;
	} else if (document.body.scrollHeight > document.body.offsetHeight){ // all but Explorer Mac
		xScroll = document.body.scrollWidth;
		yScroll = document.body.scrollHeight;
	} else { // Explorer Mac...would also work in Explorer 6 Strict, Mozilla and Safari
		xScroll = document.body.offsetWidth;
		yScroll = document.body.offsetHeight;
	}

	var windowWidth, windowHeight;

//	console.log(self.innerWidth);
//	console.log(document.documentElement.clientWidth);

	if (self.innerHeight) {	// all except Explorer
		if(document.documentElement.clientWidth){
			windowWidth = document.documentElement.clientWidth;
		} else {
			windowWidth = self.innerWidth;
		}
		windowHeight = self.innerHeight;
	} else if (document.documentElement && document.documentElement.clientHeight) { // Explorer 6 Strict Mode
		windowWidth = document.documentElement.clientWidth;
		windowHeight = document.documentElement.clientHeight;
	} else if (document.body) { // other Explorers
		windowWidth = document.body.clientWidth;
		windowHeight = document.body.clientHeight;
	}

	// for small pages with total height less then height of the viewport
	if(yScroll < windowHeight){
		pageHeight = windowHeight;
	} else {
		pageHeight = yScroll;
	}

//	console.log("xScroll " + xScroll)
//	console.log("windowWidth " + windowWidth)

	// for small pages with total width less then width of the viewport
	if(xScroll < windowWidth){
		pageWidth = xScroll;
	} else {
		pageWidth = windowWidth;
	}
//	console.log("pageWidth " + pageWidth)

	arrayPageSize = new Array(pageWidth,pageHeight,windowWidth,windowHeight)
	return arrayPageSize;
}
;
Drupal.behaviors.mtgfilterBehavior = function(context) {
  $('a.mtgfilter-cardbox', context).bind('mouseover', function() {
    var $this = $(this),
      id = $this.parents('.mtgfilter:eq(0)').attr('id');
      
      $('#'+id+'_box').show().attr('src', $.mtgFilter.getSource($this.html()));
  }) // end $.bind()
  .bind('click', function() {
    return false;
  }); // end $.bind()
  
  $('div.mtgfilter-tabs li a', context).bind('click', function() {
    var $this = $(this),
      $parent = $this.parents('li:eq(0)'),
      $container = $parent.parents('div.mtgfilter:eq(0)'),
      tabIndex = $parent.attr('id').match(/mtgfilter-.*?-tab-(\d)/)[1];
    
    // de-select any currently selected tabs
    $container.find('div.mtgfilter-tabs li.mtgfilter-active')
      .removeClass('mtgfilter-active');
    
    // select the currently selected tab
    $parent.addClass('mtgfilter-active');
    
    // hide any currently selected tabs
    $container.find('div.mtgfilter-content div.mtgfilter-active')
        .removeClass('mtgfilter-active')
        .addClass('mtgfilter-hidden');
    
    // select the appropriate tab
    $container
      .find('div.mtgfilter-content div.mtgfilter-tabcontent:eq('+tabIndex+')')
        .removeClass('mtgfilter-hidden')
        .addClass('mtgfilter-active');
  }); // end $.bind()
  
  // bind the click event to the toggle link
  $('.mtgfilter-toggle', context).bind('click', function() {
    var $parent = $(this).parents('.mtgfilter:eq(0)');
    
    // toggle the content and tabs
    $('.mtgfilter-tabs, .mtgfilter-content', $parent).slideToggle('slow');
  }); // end $.bind()
}; // end function Drupal.behaviors.mtgfilterBehavior()

$.mtgFilter = {
  /**
   * Returns the url for a card based on its name
   * 
   * @param {String} name
   * @return {String}
   */
  getSource: function(name) {
    name = name.replace(/[,-]/g, ' ').replace(/'/g, '').replace(/[ ]+/g, ' ').replace(/ /g, '_');
    name = $('<span>').text(name).html();
    name = $.URLEncode(name);
    
    return 'http://www.wizards.com/global/images/magic/general/'+name+'.jpg';
  } // end function getSource()
};


;
/*
 * Based on easing equations by Robert Penner. Adapted from jqueryt easing plugin by George McGinley Smith. See below for copyright notice of equations
 *
*/

/*
 *
 * TERMS OF USE - EASING EQUATIONS
 * 
 * Open source under the BSD License. 
 * 
 * Copyright © 2001 Robert Penner
 * All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without modification, 
 * are permitted provided that the following conditions are met:
 * 
 * Redistributions of source code must retain the above copyright notice, this list of 
 * conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright notice, this list 
 * of conditions and the following disclaimer in the documentation and/or other materials 
 * provided with the distribution.
 * 
 * Neither the name of the author nor the names of contributors may be used to endorse 
 * or promote products derived from this software without specific prior written permission.
 * 
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
 *  COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
 *  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 *  GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 
 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 *  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 
 * OF THE POSSIBILITY OF SUCH DAMAGE. 
 *
 */

// t: current time, b: begInnIng value, c: change In value, d: duration
jQuery.easing['jswing'] = jQuery.easing['swing'];

jQuery.extend( jQuery.easing,
{
	def: 'easeOutTurbo',
	swing: function (x, t, b, c, d) {
		//alert(jQuery.easing.default);
		return jQuery.easing[jQuery.easing.def](x, t, b, c, d);
	},
  easeInTurbo: function (x, t, b, c, d) {
    return c*(t/=d)*t + b;
  },
  easeOutTurbo: function (x, t, b, c, d) {
    return -c *(t/=d)*(t-2) + b;
  },
  easeInTurbo2: function (x, t, b, c, d) {
    return c*(t/=d)*t*t + b;
  },
  easeOutTurbo2: function (x, t, b, c, d) {
    return c*((t=t/d-1)*t*t + 1) + b;
  },
  easeInTurbo3: function (x, t, b, c, d) {
    return c*(t/=d)*t*t*t + b;
  },
  easeOutTurbo3: function (x, t, b, c, d) {
    return -c * ((t=t/d-1)*t*t*t - 1) + b;
  },
  easeInSine: function (x, t, b, c, d) {
    return -c * Math.cos(t/d * (Math.PI/2)) + c + b;
  },
  easeOutSine: function (x, t, b, c, d) {
    return c * Math.sin(t/d * (Math.PI/2)) + b;
  },
  easeInExpo: function (x, t, b, c, d) {
    return (t==0) ? b : c * Math.pow(2, 10 * (t/d - 1)) + b;
  },
  easeOutExpo: function (x, t, b, c, d) {
    return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b;
  },
  easeInCirc: function (x, t, b, c, d) {
    return -c * (Math.sqrt(1 - (t/=d)*t) - 1) + b;
  },
  easeOutCirc: function (x, t, b, c, d) {
    return c * Math.sqrt(1 - (t=t/d-1)*t) + b;
  },
  easeInElastic: function (x, t, b, c, d) {
    var s=1.70158;var p=0;var a=c;
    if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
    if (a < Math.abs(c)) { a=c; var s=p/4; }
    else var s = p/(2*Math.PI) * Math.asin (c/a);
    return -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b;
  },
  easeOutElastic: function (x, t, b, c, d) {
    var s=1.70158;var p=0;var a=c;
    if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
    if (a < Math.abs(c)) { a=c; var s=p/4; }
    else var s = p/(2*Math.PI) * Math.asin (c/a);
    return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b;
  },
  easeInOvershoot: function (x, t, b, c, d, s) {
    if (s == undefined) s = 1.70158;
    return c*(t/=d)*t*((s+1)*t - s) + b;
  },
  easeOutOvershoot: function (x, t, b, c, d, s) {
    if (s == undefined) s = 1.70158;
    return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b;
  },
  easeInOvershootTurbo: function (x, t, b, c, d, s) {
    if (s == undefined) s = 1.70158;
    return c*(t/=d)*t*t*((s+1)*t - s) + b;
  },
  easeOutOvershootTurbo: function (x, t, b, c, d, s) {
    if (s == undefined) s = 1.70158;
    return c*((t=t/d-1)*t*t*((s+1)*t + s) + 1) + b;
  },
  easeInBounce: function (x, t, b, c, d) {
    return c - jQuery.easing.easeOutBounce (x, d-t, 0, c, d) + b;
  },
  easeOutBounce: function (x, t, b, c, d) {
    if ((t/=d) < (1/2.75)) {
      return c*(7.5625*t*t) + b;
    } else if (t < (2/2.75)) {
      return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b;
    } else if (t < (2.5/2.75)) {
      return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b;
    } else {
      return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b;
    }
  }
});

/*
 *
 * TERMS OF USE - EASING EQUATIONS
 * 
 * Open source under the BSD License. 
 * 
 * Copyright © 2001 Robert Penner
 * All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without modification, 
 * are permitted provided that the following conditions are met:
 * 
 * Redistributions of source code must retain the above copyright notice, this list of 
 * conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright notice, this list 
 * of conditions and the following disclaimer in the documentation and/or other materials 
 * provided with the distribution.
 * 
 * Neither the name of the author nor the names of contributors may be used to endorse 
 * or promote products derived from this software without specific prior written permission.
 * 
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
 *  COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
 *  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 *  GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 
 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 *  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 
 * OF THE POSSIBILITY OF SUCH DAMAGE. 
 *
 */;
/*
 * Copyright (c) 2009 Simo Kinnunen.
 * Licensed under the MIT license.
 *
 * @version 1.05
 */
var Cufon=(function(){var m=function(){return m.replace.apply(null,arguments)};var x=m.DOM={ready:(function(){var C=false,E={loaded:1,complete:1};var B=[],D=function(){if(C){return}C=true;for(var F;F=B.shift();F()){}};if(document.addEventListener){document.addEventListener("DOMContentLoaded",D,false);window.addEventListener("pageshow",D,false)}if(!window.opera&&document.readyState){(function(){E[document.readyState]?D():setTimeout(arguments.callee,10)})()}if(document.readyState&&document.createStyleSheet){(function(){try{document.body.doScroll("left");D()}catch(F){setTimeout(arguments.callee,1)}})()}q(window,"load",D);return function(F){if(!arguments.length){D()}else{C?F():B.push(F)}}})(),root:function(){return document.documentElement||document.body}};var n=m.CSS={Size:function(C,B){this.value=parseFloat(C);this.unit=String(C).match(/[a-z%]*$/)[0]||"px";this.convert=function(D){return D/B*this.value};this.convertFrom=function(D){return D/this.value*B};this.toString=function(){return this.value+this.unit}},addClass:function(C,B){var D=C.className;C.className=D+(D&&" ")+B;return C},color:j(function(C){var B={};B.color=C.replace(/^rgba\((.*?),\s*([\d.]+)\)/,function(E,D,F){B.opacity=parseFloat(F);return"rgb("+D+")"});return B}),fontStretch:j(function(B){if(typeof B=="number"){return B}if(/%$/.test(B)){return parseFloat(B)/100}return{"ultra-condensed":0.5,"extra-condensed":0.625,condensed:0.75,"semi-condensed":0.875,"semi-expanded":1.125,expanded:1.25,"extra-expanded":1.5,"ultra-expanded":2}[B]||1}),getStyle:function(C){var B=document.defaultView;if(B&&B.getComputedStyle){return new a(B.getComputedStyle(C,null))}if(C.currentStyle){return new a(C.currentStyle)}return new a(C.style)},gradient:j(function(F){var G={id:F,type:F.match(/^-([a-z]+)-gradient\(/)[1],stops:[]},C=F.substr(F.indexOf("(")).match(/([\d.]+=)?(#[a-f0-9]+|[a-z]+\(.*?\)|[a-z]+)/ig);for(var E=0,B=C.length,D;E<B;++E){D=C[E].split("=",2).reverse();G.stops.push([D[1]||E/(B-1),D[0]])}return G}),quotedList:j(function(E){var D=[],C=/\s*((["'])([\s\S]*?[^\\])\2|[^,]+)\s*/g,B;while(B=C.exec(E)){D.push(B[3]||B[1])}return D}),recognizesMedia:j(function(G){var E=document.createElement("style"),D,C,B;E.type="text/css";E.media=G;try{E.appendChild(document.createTextNode("/**/"))}catch(F){}C=g("head")[0];C.insertBefore(E,C.firstChild);D=(E.sheet||E.styleSheet);B=D&&!D.disabled;C.removeChild(E);return B}),removeClass:function(D,C){var B=RegExp("(?:^|\\s+)"+C+"(?=\\s|$)","g");D.className=D.className.replace(B,"");return D},supports:function(D,C){var B=document.createElement("span").style;if(B[D]===undefined){return false}B[D]=C;return B[D]===C},textAlign:function(E,D,B,C){if(D.get("textAlign")=="right"){if(B>0){E=" "+E}}else{if(B<C-1){E+=" "}}return E},textShadow:j(function(F){if(F=="none"){return null}var E=[],G={},B,C=0;var D=/(#[a-f0-9]+|[a-z]+\(.*?\)|[a-z]+)|(-?[\d.]+[a-z%]*)|,/ig;while(B=D.exec(F)){if(B[0]==","){E.push(G);G={};C=0}else{if(B[1]){G.color=B[1]}else{G[["offX","offY","blur"][C++]]=B[2]}}}E.push(G);return E}),textTransform:(function(){var B={uppercase:function(C){return C.toUpperCase()},lowercase:function(C){return C.toLowerCase()},capitalize:function(C){return C.replace(/\b./g,function(D){return D.toUpperCase()})}};return function(E,D){var C=B[D.get("textTransform")];return C?C(E):E}})(),whiteSpace:(function(){var D={inline:1,"inline-block":1,"run-in":1};var C=/^\s+/,B=/\s+$/;return function(H,F,G,E){if(E){if(E.nodeName.toLowerCase()=="br"){H=H.replace(C,"")}}if(D[F.get("display")]){return H}if(!G.previousSibling){H=H.replace(C,"")}if(!G.nextSibling){H=H.replace(B,"")}return H}})()};n.ready=(function(){var B=!n.recognizesMedia("all"),E=false;var D=[],H=function(){B=true;for(var K;K=D.shift();K()){}};var I=g("link"),J=g("style");function C(K){return K.disabled||G(K.sheet,K.media||"screen")}function G(M,P){if(!n.recognizesMedia(P||"all")){return true}if(!M||M.disabled){return false}try{var Q=M.cssRules,O;if(Q){search:for(var L=0,K=Q.length;O=Q[L],L<K;++L){switch(O.type){case 2:break;case 3:if(!G(O.styleSheet,O.media.mediaText)){return false}break;default:break search}}}}catch(N){}return true}function F(){if(document.createStyleSheet){return true}var L,K;for(K=0;L=I[K];++K){if(L.rel.toLowerCase()=="stylesheet"&&!C(L)){return false}}for(K=0;L=J[K];++K){if(!C(L)){return false}}return true}x.ready(function(){if(!E){E=n.getStyle(document.body).isUsable()}if(B||(E&&F())){H()}else{setTimeout(arguments.callee,10)}});return function(K){if(B){K()}else{D.push(K)}}})();function s(D){var C=this.face=D.face,B={"\u0020":1,"\u00a0":1,"\u3000":1};this.glyphs=D.glyphs;this.w=D.w;this.baseSize=parseInt(C["units-per-em"],10);this.family=C["font-family"].toLowerCase();this.weight=C["font-weight"];this.style=C["font-style"]||"normal";this.viewBox=(function(){var F=C.bbox.split(/\s+/);var E={minX:parseInt(F[0],10),minY:parseInt(F[1],10),maxX:parseInt(F[2],10),maxY:parseInt(F[3],10)};E.width=E.maxX-E.minX;E.height=E.maxY-E.minY;E.toString=function(){return[this.minX,this.minY,this.width,this.height].join(" ")};return E})();this.ascent=-parseInt(C.ascent,10);this.descent=-parseInt(C.descent,10);this.height=-this.ascent+this.descent;this.spacing=function(L,N,E){var O=this.glyphs,M,K,G,P=[],F=0,J=-1,I=-1,H;while(H=L[++J]){M=O[H]||this.missingGlyph;if(!M){continue}if(K){F-=G=K[H]||0;P[I-1]-=G}F+=P[++I]=~~(M.w||this.w)+N+(B[H]?E:0);K=M.k}P.total=F;return P}}function f(){var C={},B={oblique:"italic",italic:"oblique"};this.add=function(D){(C[D.style]||(C[D.style]={}))[D.weight]=D};this.get=function(H,I){var G=C[H]||C[B[H]]||C.normal||C.italic||C.oblique;if(!G){return null}I={normal:400,bold:700}[I]||parseInt(I,10);if(G[I]){return G[I]}var E={1:1,99:0}[I%100],K=[],F,D;if(E===undefined){E=I>400}if(I==500){I=400}for(var J in G){if(!k(G,J)){continue}J=parseInt(J,10);if(!F||J<F){F=J}if(!D||J>D){D=J}K.push(J)}if(I<F){I=F}if(I>D){I=D}K.sort(function(M,L){return(E?(M>=I&&L>=I)?M<L:M>L:(M<=I&&L<=I)?M>L:M<L)?-1:1});return G[K[0]]}}function r(){function D(F,G){if(F.contains){return F.contains(G)}return F.compareDocumentPosition(G)&16}function B(G){var F=G.relatedTarget;if(!F||D(this,F)){return}C(this)}function E(F){C(this)}function C(F){setTimeout(function(){m.replace(F,d.get(F).options,true)},10)}this.attach=function(F){if(F.onmouseenter===undefined){q(F,"mouseover",B);q(F,"mouseout",B)}else{q(F,"mouseenter",E);q(F,"mouseleave",E)}}}function u(){var C=[],D={};function B(H){var E=[],G;for(var F=0;G=H[F];++F){E[F]=C[D[G]]}return E}this.add=function(F,E){D[F]=C.push(E)-1};this.repeat=function(){var E=arguments.length?B(arguments):C,F;for(var G=0;F=E[G++];){m.replace(F[0],F[1],true)}}}function A(){var D={},B=0;function C(E){return E.cufid||(E.cufid=++B)}this.get=function(E){var F=C(E);return D[F]||(D[F]={})}}function a(B){var D={},C={};this.extend=function(E){for(var F in E){if(k(E,F)){D[F]=E[F]}}return this};this.get=function(E){return D[E]!=undefined?D[E]:B[E]};this.getSize=function(F,E){return C[F]||(C[F]=new n.Size(this.get(F),E))};this.isUsable=function(){return !!B}}function q(C,B,D){if(C.addEventListener){C.addEventListener(B,D,false)}else{if(C.attachEvent){C.attachEvent("on"+B,function(){return D.call(C,window.event)})}}}function v(C,B){var D=d.get(C);if(D.options){return C}if(B.hover&&B.hoverables[C.nodeName.toLowerCase()]){b.attach(C)}D.options=B;return C}function j(B){var C={};return function(D){if(!k(C,D)){C[D]=B.apply(null,arguments)}return C[D]}}function c(F,E){var B=n.quotedList(E.get("fontFamily").toLowerCase()),D;for(var C=0;D=B[C];++C){if(i[D]){return i[D].get(E.get("fontStyle"),E.get("fontWeight"))}}return null}function g(B){return document.getElementsByTagName(B)}function k(C,B){return C.hasOwnProperty(B)}function h(){var B={},D,F;for(var E=0,C=arguments.length;D=arguments[E],E<C;++E){for(F in D){if(k(D,F)){B[F]=D[F]}}}return B}function o(E,M,C,N,F,D){var K=document.createDocumentFragment(),H;if(M===""){return K}var L=N.separate;var I=M.split(p[L]),B=(L=="words");if(B&&t){if(/^\s/.test(M)){I.unshift("")}if(/\s$/.test(M)){I.push("")}}for(var J=0,G=I.length;J<G;++J){H=z[N.engine](E,B?n.textAlign(I[J],C,J,G):I[J],C,N,F,D,J<G-1);if(H){K.appendChild(H)}}return K}function l(D,M){var C=D.nodeName.toLowerCase();if(M.ignore[C]){return}var E=!M.textless[C];var B=n.getStyle(v(D,M)).extend(M);var F=c(D,B),G,K,I,H,L,J;if(!F){return}for(G=D.firstChild;G;G=I){K=G.nodeType;I=G.nextSibling;if(E&&K==3){if(H){H.appendData(G.data);D.removeChild(G)}else{H=G}if(I){continue}}if(H){D.replaceChild(o(F,n.whiteSpace(H.data,B,H,J),B,M,G,D),H);H=null}if(K==1){if(G.firstChild){if(G.nodeName.toLowerCase()=="cufon"){z[M.engine](F,null,B,M,G,D)}else{arguments.callee(G,M)}}J=G}}}var t=" ".split(/\s+/).length==0;var d=new A();var b=new r();var y=new u();var e=false;var z={},i={},w={autoDetect:false,engine:null,forceHitArea:false,hover:false,hoverables:{a:true},ignore:{applet:1,canvas:1,col:1,colgroup:1,head:1,iframe:1,map:1,optgroup:1,option:1,script:1,select:1,style:1,textarea:1,title:1,pre:1},printable:true,selector:(window.Sizzle||(window.jQuery&&function(B){return jQuery(B)})||(window.dojo&&dojo.query)||(window.Ext&&Ext.query)||(window.YAHOO&&YAHOO.util&&YAHOO.util.Selector&&YAHOO.util.Selector.query)||(window.$$&&function(B){return $$(B)})||(window.$&&function(B){return $(B)})||(document.querySelectorAll&&function(B){return document.querySelectorAll(B)})||g),separate:"words",textless:{dl:1,html:1,ol:1,table:1,tbody:1,thead:1,tfoot:1,tr:1,ul:1},textShadow:"none"};var p={words:/[^\S\u00a0]+/,characters:"",none:/^/};m.now=function(){x.ready();return m};m.refresh=function(){y.repeat.apply(y,arguments);return m};m.registerEngine=function(C,B){if(!B){return m}z[C]=B;return m.set("engine",C)};m.registerFont=function(D){if(!D){return m}var B=new s(D),C=B.family;if(!i[C]){i[C]=new f()}i[C].add(B);return m.set("fontFamily",'"'+C+'"')};m.replace=function(D,C,B){C=h(w,C);if(!C.engine){return m}if(!e){n.addClass(x.root(),"cufon-active cufon-loading");n.ready(function(){n.addClass(n.removeClass(x.root(),"cufon-loading"),"cufon-ready")});e=true}if(C.hover){C.forceHitArea=true}if(C.autoDetect){delete C.fontFamily}if(typeof C.textShadow=="string"){C.textShadow=n.textShadow(C.textShadow)}if(typeof C.color=="string"&&/^-/.test(C.color)){C.textGradient=n.gradient(C.color)}if(!B){y.add(D,arguments)}if(D.nodeType||typeof D=="string"){D=[D]}n.ready(function(){for(var F=0,E=D.length;F<E;++F){var G=D[F];if(typeof G=="string"){m.replace(C.selector(G),C,true)}else{l(G,C)}}});return m};m.set=function(B,C){w[B]=C;return m};return m})();Cufon.registerEngine("canvas",(function(){var b=document.createElement("canvas");if(!b||!b.getContext||!b.getContext.apply){return}b=null;var a=Cufon.CSS.supports("display","inline-block");var e=!a&&(document.compatMode=="BackCompat"||/frameset|transitional/i.test(document.doctype.publicId));var f=document.createElement("style");f.type="text/css";f.appendChild(document.createTextNode(("cufon{text-indent:0;}@media screen,projection{cufon{display:inline;display:inline-block;position:relative;vertical-align:middle;"+(e?"":"font-size:1px;line-height:1px;")+"}cufon cufontext{display:-moz-inline-box;display:inline-block;width:0;height:0;overflow:hidden;text-indent:-10000in;}"+(a?"cufon canvas{position:relative;}":"cufon canvas{position:absolute;}")+"}@media print{cufon{padding:0;}cufon canvas{display:none;}}").replace(/;/g,"!important;")));document.getElementsByTagName("head")[0].appendChild(f);function d(p,h){var n=0,m=0;var g=[],o=/([mrvxe])([^a-z]*)/g,k;generate:for(var j=0;k=o.exec(p);++j){var l=k[2].split(",");switch(k[1]){case"v":g[j]={m:"bezierCurveTo",a:[n+~~l[0],m+~~l[1],n+~~l[2],m+~~l[3],n+=~~l[4],m+=~~l[5]]};break;case"r":g[j]={m:"lineTo",a:[n+=~~l[0],m+=~~l[1]]};break;case"m":g[j]={m:"moveTo",a:[n=~~l[0],m=~~l[1]]};break;case"x":g[j]={m:"closePath"};break;case"e":break generate}h[g[j].m].apply(h,g[j].a)}return g}function c(m,k){for(var j=0,h=m.length;j<h;++j){var g=m[j];k[g.m].apply(k,g.a)}}return function(V,w,P,t,C,W){var k=(w===null);if(k){w=C.alt}var A=V.viewBox;var m=P.getSize("fontSize",V.baseSize);var B=0,O=0,N=0,u=0;var z=t.textShadow,L=[];if(z){for(var U=z.length;U--;){var F=z[U];var K=m.convertFrom(parseFloat(F.offX));var I=m.convertFrom(parseFloat(F.offY));L[U]=[K,I];if(I<B){B=I}if(K>O){O=K}if(I>N){N=I}if(K<u){u=K}}}var Z=Cufon.CSS.textTransform(w,P).split("");var E=V.spacing(Z,~~m.convertFrom(parseFloat(P.get("letterSpacing"))||0),~~m.convertFrom(parseFloat(P.get("wordSpacing"))||0));if(!E.length){return null}var h=E.total;O+=A.width-E[E.length-1];u+=A.minX;var s,n;if(k){s=C;n=C.firstChild}else{s=document.createElement("cufon");s.className="cufon cufon-canvas";s.alt=w;n=document.createElement("canvas");s.appendChild(n);if(t.printable){var S=document.createElement("cufontext");S.appendChild(document.createTextNode(w));s.appendChild(S)}}var aa=s.style;var H=n.style;var j=m.convert(A.height);var Y=Math.ceil(j);var M=Y/j;var G=M*Cufon.CSS.fontStretch(P.get("fontStretch"));var J=h*G;var Q=Math.ceil(m.convert(J+O-u));var o=Math.ceil(m.convert(A.height-B+N));n.width=Q;n.height=o;H.width=Q+"px";H.height=o+"px";B+=A.minY;H.top=Math.round(m.convert(B-V.ascent))+"px";H.left=Math.round(m.convert(u))+"px";var r=Math.max(Math.ceil(m.convert(J)),0)+"px";if(a){aa.width=r;aa.height=m.convert(V.height)+"px"}else{aa.paddingLeft=r;aa.paddingBottom=(m.convert(V.height)-1)+"px"}var X=n.getContext("2d"),D=j/A.height;X.scale(D,D*M);X.translate(-u,-B);X.save();function T(){var x=V.glyphs,ab,l=-1,g=-1,y;X.scale(G,1);while(y=Z[++l]){var ab=x[Z[l]]||V.missingGlyph;if(!ab){continue}if(ab.d){X.beginPath();if(ab.code){c(ab.code,X)}else{ab.code=d("m"+ab.d,X)}X.fill()}X.translate(E[++g],0)}X.restore()}if(z){for(var U=z.length;U--;){var F=z[U];X.save();X.fillStyle=F.color;X.translate.apply(X,L[U]);T()}}var q=t.textGradient;if(q){var v=q.stops,p=X.createLinearGradient(0,A.minY,0,A.maxY);for(var U=0,R=v.length;U<R;++U){p.addColorStop.apply(p,v[U])}X.fillStyle=p}else{X.fillStyle=P.get("color")}T();return s}})());Cufon.registerEngine("vml",(function(){var e=document.namespaces;if(!e){return}e.add("cvml","urn:schemas-microsoft-com:vml");e=null;var b=document.createElement("cvml:shape");b.style.behavior="url(#default#VML)";if(!b.coordsize){return}b=null;var h=(document.documentMode||0)<8;document.write(('<style type="text/css">cufoncanvas{text-indent:0;}@media screen{cvml\\:shape,cvml\\:rect,cvml\\:fill,cvml\\:shadow{behavior:url(#default#VML);display:block;antialias:true;position:absolute;}cufoncanvas{position:absolute;text-align:left;}cufon{display:inline-block;position:relative;vertical-align:'+(h?"middle":"text-bottom")+";}cufon cufontext{position:absolute;left:-10000in;font-size:1px;}a cufon{cursor:pointer}}@media print{cufon cufoncanvas{display:none;}}</style>").replace(/;/g,"!important;"));function c(i,j){return a(i,/(?:em|ex|%)$|^[a-z-]+$/i.test(j)?"1em":j)}function a(l,m){if(m==="0"){return 0}if(/px$/i.test(m)){return parseFloat(m)}var k=l.style.left,j=l.runtimeStyle.left;l.runtimeStyle.left=l.currentStyle.left;l.style.left=m.replace("%","em");var i=l.style.pixelLeft;l.style.left=k;l.runtimeStyle.left=j;return i}function f(l,k,j,n){var i="computed"+n,m=k[i];if(isNaN(m)){m=k.get(n);k[i]=m=(m=="normal")?0:~~j.convertFrom(a(l,m))}return m}var g={};function d(p){var q=p.id;if(!g[q]){var n=p.stops,o=document.createElement("cvml:fill"),i=[];o.type="gradient";o.angle=180;o.focus="0";o.method="sigma";o.color=n[0][1];for(var m=1,l=n.length-1;m<l;++m){i.push(n[m][0]*100+"% "+n[m][1])}o.colors=i.join(",");o.color2=n[l][1];g[q]=o}return g[q]}return function(ac,G,Y,C,K,ad,W){var n=(G===null);if(n){G=K.alt}var I=ac.viewBox;var p=Y.computedFontSize||(Y.computedFontSize=new Cufon.CSS.Size(c(ad,Y.get("fontSize"))+"px",ac.baseSize));var y,q;if(n){y=K;q=K.firstChild}else{y=document.createElement("cufon");y.className="cufon cufon-vml";y.alt=G;q=document.createElement("cufoncanvas");y.appendChild(q);if(C.printable){var Z=document.createElement("cufontext");Z.appendChild(document.createTextNode(G));y.appendChild(Z)}if(!W){y.appendChild(document.createElement("cvml:shape"))}}var ai=y.style;var R=q.style;var l=p.convert(I.height),af=Math.ceil(l);var V=af/l;var P=V*Cufon.CSS.fontStretch(Y.get("fontStretch"));var U=I.minX,T=I.minY;R.height=af;R.top=Math.round(p.convert(T-ac.ascent));R.left=Math.round(p.convert(U));ai.height=p.convert(ac.height)+"px";var F=Y.get("color");var ag=Cufon.CSS.textTransform(G,Y).split("");var L=ac.spacing(ag,f(ad,Y,p,"letterSpacing"),f(ad,Y,p,"wordSpacing"));if(!L.length){return null}var k=L.total;var x=-U+k+(I.width-L[L.length-1]);var ah=p.convert(x*P),X=Math.round(ah);var O=x+","+I.height,m;var J="r"+O+"ns";var u=C.textGradient&&d(C.textGradient);var o=ac.glyphs,S=0;var H=C.textShadow;var ab=-1,aa=0,w;while(w=ag[++ab]){var D=o[ag[ab]]||ac.missingGlyph,v;if(!D){continue}if(n){v=q.childNodes[aa];while(v.firstChild){v.removeChild(v.firstChild)}}else{v=document.createElement("cvml:shape");q.appendChild(v)}v.stroked="f";v.coordsize=O;v.coordorigin=m=(U-S)+","+T;v.path=(D.d?"m"+D.d+"xe":"")+"m"+m+J;v.fillcolor=F;if(u){v.appendChild(u.cloneNode(false))}var ae=v.style;ae.width=X;ae.height=af;if(H){var s=H[0],r=H[1];var B=Cufon.CSS.color(s.color),z;var N=document.createElement("cvml:shadow");N.on="t";N.color=B.color;N.offset=s.offX+","+s.offY;if(r){z=Cufon.CSS.color(r.color);N.type="double";N.color2=z.color;N.offset2=r.offX+","+r.offY}N.opacity=B.opacity||(z&&z.opacity)||1;v.appendChild(N)}S+=L[aa++]}var M=v.nextSibling,t,A;if(C.forceHitArea){if(!M){M=document.createElement("cvml:rect");M.stroked="f";M.className="cufon-vml-cover";t=document.createElement("cvml:fill");t.opacity=0;M.appendChild(t);q.appendChild(M)}A=M.style;A.width=X;A.height=af}else{if(M){q.removeChild(M)}}ai.width=Math.max(Math.ceil(p.convert(k*P)),0);if(h){var Q=Y.computedYAdjust;if(Q===undefined){var E=Y.get("lineHeight");if(E=="normal"){E="1em"}else{if(!isNaN(E)){E+="em"}}Y.computedYAdjust=Q=0.5*(a(ad,E)-parseFloat(ai.height))}if(Q){ai.marginTop=Math.ceil(Q)+"px";ai.marginBottom=Q+"px"}}return y}})());;
Cufon.registerFont({"w":604,"face":{"font-family":"Transport Heavy","font-weight":400,"font-stretch":"normal","units-per-em":"2048","panose-1":"2 0 0 0 0 0 0 0 0 0","ascent":"1638","descent":"-410","bbox":"-386 -1998 4632 343.738","underline-thickness":"48","underline-position":"-140","unicode-range":"U+0020-U+007E"},"glyphs":{" ":{"w":600},"!":{"d":"1056,-418v49,107,25,183,-72,228v-103,20,-169,-19,-196,-116v3,-90,44,-146,124,-168v59,0,107,19,144,56xm784,-605r300,0r0,-1159r-300,0r0,1159","w":1274},"\"":{"d":"304,-1838r332,0r-128,228v-29,29,-38,79,-68,108v-12,30,-35,64,-48,88r-332,0v14,-22,24,-48,40,-68v3,-14,13,-22,16,-36r8,-4v14,-40,39,-68,52,-100v24,-22,34,-67,56,-88v3,-28,26,-35,32,-60xm740,-1838r328,0v-8,32,-31,49,-40,80v-17,31,-39,57,-52,92r-8,4v-7,21,-17,37,-28,48v-17,44,-38,67,-52,100v-14,5,-11,26,-24,32v-13,29,-25,52,-36,68r-328,0v18,-47,46,-90,72,-128v19,-53,49,-78,68,-128v18,-13,20,-41,36,-56v6,-18,16,-33,28,-44v11,-29,23,-52,36,-68","w":1096},"#":{"w":216},"$":{"d":"676,-870v-258,-46,-432,-168,-432,-408v0,-301,182,-483,532,-508v274,-20,499,77,672,252v-23,21,-49,39,-68,64v-21,9,-36,26,-48,44v-29,14,-37,41,-64,52v-15,19,-37,40,-52,52v-168,-137,-341,-181,-520,-132v-10,9,-21,16,-32,20v-16,20,-36,25,-44,44r-20,48v1,53,19,96,52,128v79,34,187,41,268,72v32,-2,43,18,76,16r116,36v50,18,99,44,132,76v30,18,58,41,76,64v101,132,122,276,72,420v-52,148,-145,249,-280,292v-415,132,-757,47,-1020,-244v9,-16,29,-26,44,-36v22,-30,57,-34,76,-64v15,-9,24,-24,44,-28v9,-15,24,-24,40,-32r56,-48v177,173,374,236,592,188v8,-8,24,-8,28,-20r60,-40v9,-23,19,-41,28,-56v8,-73,-15,-130,-68,-172v-95,-36,-215,-62,-316,-80xm942,31r0,-238r-296,0r0,238r296,0xm940,-1759r0,-233r-296,0r0,233r296,0xm940,-175r0,-31r-294,0r0,31r294,0xm936,-1763r0,-31r-294,0r0,31r294,0","w":1588},"&":{"d":"988,-1558v87,239,7,415,-240,528v-10,23,23,30,28,52v17,21,29,39,36,56v21,11,25,39,40,56v13,15,23,27,28,40v21,14,28,41,44,60v15,19,29,35,36,52v39,-55,57,-112,56,-172r272,0v-10,163,-62,299,-156,408v53,16,104,19,152,8v4,66,21,122,24,184v7,15,9,31,8,48v-173,71,-307,55,-400,-48v-165,97,-330,122,-496,76v-199,-55,-325,-192,-344,-412v-19,-219,77,-381,252,-484v-87,-137,-108,-274,-52,-408v60,-143,177,-224,340,-224v163,0,287,61,372,180xm572,-1270r12,24v95,-29,147,-89,156,-180v-23,-47,-59,-71,-108,-72v-109,48,-129,124,-60,228xm408,-562v7,12,13,23,16,32v115,87,227,93,336,20v-16,-14,-27,-31,-36,-52v-7,-2,-10,-8,-12,-16v-39,-39,-56,-84,-92,-124v-16,-30,-42,-51,-56,-84v-11,-8,-16,-14,-20,-28r-52,-64v-128,85,-156,190,-84,316","w":1376},"'":{"d":"128,-1294v-7,-25,-24,-50,-28,-72v65,-19,118,-47,160,-84v-2,-13,-6,-24,-12,-32v-91,10,-148,-25,-172,-104v-8,-96,31,-161,120,-176v98,-16,165,26,200,108v8,196,-81,316,-268,360","w":444},"(":{"d":"764,-1998v35,20,43,66,68,96v9,23,23,41,32,64v15,17,26,34,32,52v-291,185,-455,436,-468,752v-16,392,148,686,468,880v-40,61,-74,128,-112,192v-12,18,-23,16,-36,4v-29,-17,-52,-33,-68,-48v-381,-234,-576,-557,-576,-968v0,-437,210,-754,556,-952v31,-30,76,-47,104,-72","w":1236},")":{"d":"1132,-968v0,432,-195,746,-536,944v-38,34,-87,57,-128,88r-16,-8v-4,-26,-24,-37,-32,-60v-17,-18,-31,-49,-40,-72r-8,-4v-13,-26,-25,-47,-36,-64v322,-209,488,-491,472,-844v-17,-363,-183,-625,-472,-788v12,-23,27,-42,36,-68v17,-20,26,-48,44,-68v11,-29,33,-54,40,-76v439,229,676,569,676,1020","w":1236},"*":{"d":"-50,-966r725,0r0,172r-725,3r0,-175xm-6,-684r512,-513r122,122r-54,59r-456,456xm224,-517r0,-725r172,0r3,725r-175,0xm504,-562r-512,-512r122,-122r514,511","w":874},"+":{"d":"-28,-1007r677,0r0,253v-203,13,-451,1,-677,5r0,-258xm181,-540r0,-677r253,0v13,203,1,451,5,677r-258,0","w":828},",":{"d":"436,-450v7,200,-83,321,-272,364v-11,-23,-18,-48,-28,-72v19,-8,44,-10,56,-24v45,-15,81,-37,108,-64r0,-20r-16,-12v-125,9,-184,-49,-176,-172v31,-67,80,-108,148,-112v90,-5,150,36,180,112","w":736},"-":{"d":"112,-994r476,0r0,232r-476,0r0,-232","w":768},"\u2010":{"d":"112,-994r476,0r0,232r-476,0r0,-232","w":768},".":{"d":"472,-362v17,87,-16,158,-92,184v-121,41,-201,-10,-232,-128v4,-109,56,-171,156,-188v91,9,153,52,168,132"},"\/":{"d":"584,-1786r236,64v-26,117,-58,225,-92,336v-16,54,-38,117,-52,168v-40,148,-84,283,-120,432v-12,47,-33,87,-40,140v-22,56,-40,122,-56,180r-88,316r-80,284v-90,-12,-151,-44,-236,-60r24,-92r52,-180v9,-33,17,-64,28,-100r28,-96v4,-23,17,-33,16,-60r204,-708v9,-46,24,-63,28,-104r36,-116v15,-61,38,-114,48,-180v26,-68,43,-150,64,-224","w":876},"0":{"d":"1432,-1050v11,251,-47,471,-168,660v-22,11,-32,40,-52,48v-18,19,-33,35,-48,44v-211,128,-424,152,-632,64v-219,-92,-332,-267,-368,-508v-36,-238,-30,-456,48,-656v99,-254,286,-388,556,-388v420,0,643,261,664,736xm484,-746r44,124v32,39,50,74,92,96r4,8v21,9,39,19,52,28v337,73,492,-164,420,-704v-28,-210,-161,-307,-356,-300v-185,55,-273,187,-264,396v-10,51,-7,109,-8,164v9,40,7,85,12,132v-9,13,7,43,4,56","w":1572},"1":{"d":"388,-1742r280,0r0,1528r-316,0r0,-1028r-256,0r0,-268v87,2,161,-17,224,-56v14,-30,40,-43,40,-76","w":908},"2":{"d":"1200,-1354v40,219,-33,409,-164,552v-20,33,-49,60,-68,76v-21,28,-45,48,-72,60r-4,8v-37,31,-67,39,-92,64v-23,9,-37,27,-60,36v-20,27,-61,35,-84,56r520,0r0,244v1,15,-2,30,-8,44r-1060,0r0,-288v27,-17,51,-37,84,-48v38,-30,78,-53,120,-76v23,-25,55,-44,84,-60v40,-34,62,-48,100,-72v29,-19,47,-43,80,-56v8,-12,26,-14,32,-28v19,-6,30,-21,48,-28v23,-23,44,-41,64,-52v28,-38,67,-66,100,-100v14,-34,40,-59,52,-92v27,-74,28,-146,16,-212v-19,-27,-27,-66,-56,-84v-15,-28,-55,-34,-72,-56v-255,-52,-382,51,-380,308r-316,0v-9,-369,155,-576,492,-612v365,-38,587,102,644,416","w":1352},"3":{"d":"428,-1270r-208,-24v-34,-8,-76,-10,-112,-16v77,-297,267,-458,572,-472v285,-13,479,98,568,328v34,88,30,173,12,252v-22,97,-71,163,-156,196v147,69,194,192,180,372v-16,215,-118,387,-304,432v-490,119,-787,-57,-872,-464v9,-26,62,-10,88,-24r12,0v40,-10,60,-14,100,-16v48,-13,88,-19,120,-20v31,151,115,245,256,260v185,19,288,-62,288,-220v0,-68,-38,-117,-92,-148v-27,-1,-42,-14,-72,-12v-64,-10,-151,-5,-216,-16r0,-280v121,2,225,-19,312,-64v13,-15,25,-27,36,-36v45,-148,-17,-239,-188,-252v-192,-14,-301,67,-324,224","w":1480},"4":{"d":"36,-478r0,-292r72,-92v16,-20,26,-46,48,-60v10,-30,39,-41,48,-72r12,-8v29,-57,63,-78,88,-124v28,-28,47,-65,72,-96r12,-8v24,-42,48,-74,72,-96v23,-46,50,-64,72,-104v62,-68,107,-151,168,-216v2,-10,8,-16,16,-20v15,-30,36,-54,56,-80r404,0r0,980r196,0r0,280v-20,18,-72,8,-116,8r-80,0r0,260r-316,0r0,-260r-824,0xm860,-1390v-12,4,-12,20,-20,28v-16,14,-30,31,-40,52v-39,43,-67,91,-104,132v-9,10,-10,27,-24,32v-6,13,-16,19,-20,32v-22,12,-25,42,-44,56v-16,24,-38,42,-52,68v-29,31,-41,69,-72,92v-3,20,-25,25,-28,44v-15,7,-19,24,-28,36r-40,52r472,0r0,-624r-4,0r4,0","w":1496},"5":{"d":"224,-1394v21,-110,34,-235,52,-352r4,-4r-4,4v205,-11,480,-4,712,-4r236,0r0,288r-664,0r-16,12v-4,73,-21,137,-28,208v153,-93,306,-114,456,-52v144,60,260,155,292,292v113,482,-62,774,-468,816v-341,35,-555,-119,-636,-420v34,-9,61,-25,100,-28v42,-19,90,-23,136,-40v25,-9,47,-19,68,-20v9,57,28,105,64,140v98,97,210,117,316,44v120,-83,160,-208,116,-344v-34,-106,-111,-169,-212,-180v-119,-13,-208,37,-264,132r-112,-16v-55,-15,-123,-16,-176,-32r-36,-4r40,-280v11,-48,15,-111,24,-160","w":1408},"6":{"d":"1236,-1442r-164,56v-10,12,-40,11,-52,20r-68,28v-57,-126,-153,-180,-284,-148v-148,36,-224,148,-232,324v234,-149,469,-167,668,-8v161,129,193,323,156,540v-39,229,-150,381,-360,420v-480,89,-749,-154,-780,-696v-31,-549,164,-842,564,-868v308,-20,492,95,552,332xm464,-774v-15,155,64,256,204,284v124,24,218,-22,260,-132v65,-168,13,-293,-136,-368v-26,0,-49,-11,-68,-8v-148,16,-247,89,-260,224","w":1400},"7":{"d":"36,-1750r1076,0r0,296v-19,21,-25,57,-36,84r-88,216v-27,47,-42,105,-68,152v-31,100,-71,182,-108,272v-22,53,-44,113,-72,164v-9,40,-37,82,-44,112v-20,35,-30,85,-52,116v2,11,-3,16,-8,20v-7,34,-29,68,-36,96r-344,0v36,-102,80,-195,120,-292v19,-47,35,-98,60,-140v14,-43,28,-71,40,-100v12,-29,21,-54,32,-72v4,-39,25,-60,36,-92v14,-42,35,-77,48,-120v17,-26,27,-75,44,-96v-3,-16,11,-15,8,-32r80,-192v15,-11,15,-39,24,-56v10,-18,16,-35,20,-48r-732,0r0,-288","w":1160},"8":{"d":"1300,-1458v75,197,14,349,-152,444v139,75,204,184,204,328v0,157,-42,288,-156,372v-188,138,-399,161,-620,100v-216,-59,-343,-188,-368,-396v-23,-194,49,-326,204,-396v-159,-106,-219,-246,-164,-416v70,-218,235,-338,480,-352v284,-16,486,89,572,316xm568,-1378v-30,154,33,238,188,248v163,11,245,-60,248,-208v-45,-112,-130,-163,-256,-148v-81,10,-141,47,-180,108xm528,-646v13,117,95,172,216,172v203,0,299,-63,288,-244v-47,-109,-144,-158,-292,-144v-145,14,-226,89,-212,216","w":1496},"9":{"d":"1204,-1362v22,9,14,48,28,68v8,35,16,76,20,112r16,132v23,499,-139,790,-488,848v-340,57,-551,-59,-628,-320r92,-32v35,-14,69,-31,108,-40v33,-8,52,-31,92,-32v43,120,131,175,260,148v156,-32,244,-138,248,-324v-179,115,-361,146,-540,76v-183,-72,-273,-210,-288,-392v-34,-404,124,-632,488,-652v319,-17,517,130,592,408xm440,-1302v-39,190,46,305,220,336v183,-19,286,-118,264,-292v-20,-155,-129,-228,-280,-224v-105,26,-184,83,-204,180","w":1400},":":{"d":"476,-902v3,69,-19,123,-64,164v-117,55,-203,29,-256,-76v-27,-125,20,-199,140,-224v95,5,155,51,180,136xm472,-358v15,82,-18,149,-88,176v-121,47,-204,0,-240,-120v2,-111,55,-175,160,-192v91,9,153,54,168,136"},";":{"d":"476,-902v3,69,-19,123,-64,164v-117,55,-203,29,-256,-76v-27,-125,20,-199,140,-224v95,5,155,51,180,136xm475,-358v7,200,-83,321,-272,364v-11,-23,-18,-48,-28,-72v19,-8,44,-10,56,-24v45,-15,81,-37,108,-64r0,-20r-16,-12v-125,9,-184,-49,-176,-172v31,-67,80,-108,148,-112v90,-5,150,36,180,112"},"<":{"d":"1092,-1838r940,0v63,-4,115,-1,156,8v-23,25,-50,46,-76,68v-26,38,-55,47,-76,80v-14,10,-28,20,-36,36v-20,12,-31,37,-48,44v-20,18,-40,48,-60,60v-3,14,-19,15,-24,28v-26,17,-34,43,-60,56v-2,6,-6,10,-12,12v-58,65,-116,122,-180,180v-9,17,-25,21,-32,36v-21,12,-28,35,-48,44v-10,11,-14,22,-28,28v-2,6,-6,10,-12,12v-10,13,-19,24,-28,32r2900,0r0,728r-2900,0v23,27,41,38,60,64v32,24,44,47,68,68v18,15,29,31,44,44v33,29,57,55,76,76v30,34,67,61,96,96v19,23,47,38,64,64v16,13,29,20,36,36v27,17,36,40,60,56v18,24,43,39,60,64v17,9,23,28,40,36v16,23,46,44,60,64v25,20,44,40,56,60r-1096,0v-24,-32,-58,-53,-80,-84v-16,-14,-32,-27,-44,-44v-6,-2,-10,-6,-12,-12v-24,-17,-35,-32,-52,-52v-14,-3,-15,-19,-28,-24v-12,-21,-35,-28,-44,-48v-31,-24,-45,-48,-68,-68v-52,-45,-76,-89,-128,-128v-25,-30,-54,-55,-80,-84v-6,-2,-10,-6,-12,-12v-29,-21,-38,-42,-64,-60v-14,-23,-45,-40,-56,-60v-13,-11,-27,-21,-36,-36v-27,-19,-34,-40,-56,-56v-25,-19,-36,-40,-60,-56v-34,-40,-76,-70,-108,-112v-24,-14,-37,-40,-60,-56v-16,-19,-30,-39,-52,-52v-12,-20,-37,-31,-44,-48v12,-11,22,-23,36,-32v14,-18,23,-30,40,-40v21,-26,41,-46,60,-60v20,-31,49,-49,72,-76v38,-45,73,-63,104,-108v18,-16,31,-36,52,-48v27,-26,49,-58,80,-80v2,-6,6,-10,12,-12v19,-30,44,-37,60,-64v14,-10,28,-20,36,-36v20,-12,31,-37,48,-44v20,-18,40,-48,60,-60v3,-14,19,-15,24,-28v26,-17,34,-43,60,-56v2,-6,6,-10,12,-12v58,-65,116,-122,180,-180v9,-17,25,-21,32,-36v21,-12,28,-35,48,-44v10,-11,14,-22,28,-28v2,-6,6,-10,12,-12v10,-13,19,-24,28,-32","w":4376},"=":{"d":"76,-761r650,0r0,224v-178,10,-389,1,-584,4r-66,0r0,-228xm76,-1216r650,0r0,224v-178,10,-389,1,-584,4r-66,0r0,-228","w":797},">":{"d":"2188,-1838r1096,0v28,28,54,58,84,84v26,22,44,52,72,72v25,30,54,55,80,84v6,2,10,6,12,12v18,13,31,27,40,40v25,19,43,38,56,56v24,17,32,29,48,48v16,18,39,30,52,52v6,2,10,6,12,12v28,19,36,40,60,56v20,28,55,49,68,72v22,14,34,39,56,52v10,14,20,28,36,36v12,20,37,31,44,48v22,14,34,38,56,52v12,20,37,31,44,48v17,9,23,27,40,36v12,20,37,31,44,48v29,24,48,48,72,76v26,16,37,46,64,60v12,20,37,31,44,48v-18,19,-40,35,-56,56v-35,27,-57,65,-92,88v-10,18,-32,24,-40,44v-20,12,-31,37,-48,44v-36,32,-78,77,-108,108r-152,156v-33,22,-51,58,-84,80v-3,14,-19,15,-24,28v-30,21,-41,51,-72,68v-16,17,-27,40,-48,52v-28,37,-59,58,-88,92v-30,21,-51,58,-76,72v-25,37,-55,50,-80,84v-25,16,-37,46,-64,60r-52,56r-940,0v-63,4,-115,1,-156,-8v31,-24,53,-56,84,-80v9,-17,25,-21,32,-36v21,-12,28,-35,48,-44v10,-11,14,-22,28,-28v2,-6,6,-10,12,-12v17,-24,32,-35,52,-52v18,-26,36,-35,52,-56v29,-19,43,-52,72,-68v2,-6,6,-10,12,-12v58,-65,116,-122,180,-180v9,-17,25,-21,32,-36v21,-12,28,-35,48,-44v10,-11,14,-22,28,-28v2,-6,6,-10,12,-12v10,-13,19,-24,28,-32r-2900,0r0,-728r2900,0v-14,-23,-45,-40,-56,-60v-8,-8,-20,-12,-24,-24v-41,-34,-72,-67,-108,-104v-27,-28,-54,-55,-80,-84v-6,-2,-10,-6,-12,-12v-40,-31,-58,-63,-96,-92r-4,-8v-19,-13,-33,-28,-44,-44v-25,-17,-33,-36,-52,-52v-24,-20,-43,-38,-56,-56v-25,-19,-43,-38,-56,-56v-19,-13,-33,-28,-44,-44v-13,-9,-22,-18,-28,-28v-26,-17,-46,-37,-60,-60","w":4376},"?":{"d":"1448,-1366v64,284,-46,493,-292,620v-35,39,-76,106,-72,168r-292,0v2,-213,106,-376,312,-488v31,-39,52,-75,64,-108v16,-169,-53,-292,-212,-292v-157,0,-242,84,-256,236r-292,0v25,-291,170,-467,436,-528r80,-8v279,19,467,149,524,400xm1056,-418v49,107,25,183,-72,228v-103,20,-169,-19,-196,-116v3,-90,44,-146,124,-168v59,0,107,19,144,56","w":1572},"@":{"d":"960,-1218v20,40,55,70,56,120v8,26,12,49,12,68r0,392v-3,66,0,121,8,164v33,34,121,64,266,90r-182,239v-169,-24,-284,-74,-344,-149v-114,113,-254,137,-424,84v-154,-47,-272,-135,-272,-284v0,-215,106,-329,304,-376v92,-22,226,-47,340,-48v17,-155,-90,-200,-256,-148v-45,3,-72,24,-112,32v-21,14,-39,23,-56,28v-23,17,-45,29,-68,36r-28,-52v-13,-7,-17,-22,-24,-36v-17,-20,-29,-39,-36,-56v-11,-10,-17,-21,-20,-32v-17,-17,-28,-34,-32,-52v35,-17,66,-46,108,-56v21,-24,64,-21,80,-40v27,1,31,-20,56,-16v18,-9,35,-15,52,-16v205,-71,429,-14,572,108xm724,-698v-106,12,-219,36,-300,68v-28,37,-36,76,-24,116v67,93,163,109,288,48v48,-38,36,-140,36,-232xm-386,-737v0,-515,434,-954,950,-954v520,0,954,437,954,954v0,512,-441,950,-954,950v-510,0,-950,-440,-950,-950xm1363,-739v0,-431,-365,-796,-796,-796v-432,0,-797,365,-797,796v0,431,365,797,797,797v429,0,796,-368,796,-797","w":2060},"A":{"d":"568,-1746r412,0r60,188v7,26,22,44,24,76v13,25,21,47,24,68v24,57,28,99,52,148v-1,23,15,37,16,56v14,41,32,78,40,124v20,34,27,85,44,120v-1,23,15,37,16,56r48,136v15,65,50,140,60,192v21,47,34,87,40,120v22,33,20,89,44,120v8,47,31,87,40,128r-348,0v-8,-14,-5,-40,-16,-52v-18,-81,-45,-142,-64,-220r-572,0v-22,96,-57,178,-80,272r-344,0r68,-220r108,-316r56,-172v15,-61,38,-113,56,-172v12,-41,31,-78,40,-124v20,-40,28,-92,48,-132v18,-75,42,-141,64,-208v21,-64,40,-126,64,-188xm772,-1414v-25,115,-70,210,-96,324r-32,88v-3,21,-8,40,-16,56v-14,67,-42,121,-56,188r404,0r-108,-348v-9,-47,-26,-87,-36,-132v-28,-58,-34,-119,-60,-176","w":1540},"B":{"d":"244,-1746r736,0v39,7,85,9,120,24v115,47,199,123,244,224v84,188,41,340,-116,452v113,53,187,134,208,244v50,267,-47,452,-276,552r-12,0v-197,70,-494,23,-776,36r-128,0r0,-1532xm1052,-1334v-26,-61,-64,-107,-144,-112v-103,-6,-232,-1,-352,-4r0,320r368,0r24,-4v88,-45,123,-111,104,-200xm556,-514r336,0v35,0,65,-3,88,-8v93,-49,139,-122,120,-216v-14,-67,-57,-112,-112,-140v-21,-3,-38,-7,-52,-12r-380,0r0,376","w":1584},"C":{"d":"1532,-1302v-25,23,-70,26,-100,44v-35,9,-54,29,-88,32v-4,10,-23,6,-28,16v-16,-3,-15,11,-32,8v-16,16,-47,17,-68,28v-67,-242,-227,-358,-464,-292v-193,54,-276,213,-276,420v0,217,22,384,156,488v101,78,217,92,332,56v146,-46,228,-142,248,-284v25,5,47,13,64,24v64,17,103,43,164,60v28,17,60,25,92,36v-107,296,-305,457,-596,480v-294,23,-527,-72,-668,-300v-172,-278,-188,-567,-72,-844v112,-266,303,-426,568,-448v388,-32,645,139,768,476","w":1640},"D":{"d":"752,-1746v54,-1,105,2,152,4v19,9,49,5,72,12v407,131,592,430,528,884v-73,517,-450,685,-1060,632r-196,0r0,-1532r504,0xm560,-526r284,0v44,-3,77,-17,116,-24v176,-98,255,-251,236,-460v-27,-320,-195,-453,-512,-424r-124,0r0,908","w":1628},"E":{"d":"240,-1746r1004,0r0,304r-688,0r0,308r624,0r0,284r-624,0r0,320v8,21,34,12,60,12r688,0r0,304r-1064,0r0,-1532","w":1476},"F":{"d":"236,-1746r1008,0r0,304r-692,0r0,308r624,0r0,288r-624,0r0,632r-316,0r4,0v-8,1,-3,-11,-4,-16r0,-1516","w":1312},"G":{"d":"1488,-1398r-104,48v-19,15,-40,14,-52,28v-29,12,-61,22,-84,40v-21,8,-39,16,-52,24v-65,-128,-161,-200,-288,-216v-165,-20,-293,60,-372,176v-72,182,-82,356,-36,524v59,215,203,327,428,288v173,-30,276,-146,280,-340r-384,0r0,-272r672,0r0,884r-292,0r0,-100v-113,101,-239,145,-376,132r-8,4v-87,-1,-162,-19,-228,-48v-251,-109,-399,-295,-444,-564v-47,-276,-2,-514,144,-712v130,-176,301,-270,504,-280v331,-16,561,115,692,384","w":1696},"H":{"d":"248,-1742r316,0r0,580r612,0r0,-580r316,0r0,1528r-316,0r0,-648r-612,0r0,648r-316,0r0,-1528","w":1724},"I":{"d":"240,-1742r316,0r0,1528r-316,0r0,-1528","w":788},"J":{"d":"92,-526v99,6,197,31,296,12r24,0v23,-16,42,-32,56,-48v39,-214,16,-529,16,-804r0,-376r316,0r0,1176v-7,30,-6,54,-12,80v-10,43,-25,72,-40,108v-81,111,-183,171,-308,180v-23,14,-68,2,-84,12v-114,2,-217,-17,-316,-28r40,-316","w":1028},"K":{"d":"232,-1742r316,0r0,520v10,-10,25,-15,28,-32v44,-33,68,-84,112,-116v12,-27,37,-40,52,-64v31,-20,45,-57,76,-76v21,-34,54,-55,76,-88v8,-13,19,-21,28,-28v18,-26,37,-46,56,-60v16,-23,31,-42,44,-56r428,0v-27,45,-74,75,-100,116r-8,4v-52,68,-102,107,-152,172v-18,10,-26,30,-40,44v-25,26,-51,51,-72,80v-22,13,-34,45,-56,56v-35,50,-78,89,-120,132v8,21,21,34,28,56v8,14,22,29,28,44v11,9,20,20,24,36v27,36,43,58,60,96r8,4v24,47,57,97,84,140v38,60,87,129,120,192v34,36,54,84,84,124v21,48,57,84,76,128v10,2,13,17,16,24v23,26,39,53,48,80r-372,0v-11,-25,-29,-44,-40,-68v-26,-31,-39,-62,-64,-92v-15,-39,-45,-66,-60,-104v-29,-28,-44,-68,-68,-100v-10,-27,-35,-47,-40,-68v-28,-28,-39,-74,-68,-100v-10,-8,-7,-28,-20,-32v-10,-37,-47,-64,-56,-96r-16,-12v-10,23,-33,34,-44,56v-33,27,-51,59,-80,84r0,532r-316,0r0,-1528","w":1504},"L":{"d":"244,-1746r316,0r0,1224r672,0r0,304r-988,0r0,-1528","w":1280},"M":{"d":"244,-1746r404,0v26,44,70,96,92,136v18,33,43,54,60,88v6,5,10,11,12,20v27,22,32,51,56,72v6,10,13,19,16,32v35,38,53,75,80,116v7,2,10,8,12,16v17,19,29,37,36,52r12,-4v20,-46,54,-78,80,-120v29,-47,59,-95,96,-136v6,-12,11,-27,24,-32v11,-30,35,-44,44,-72v22,-25,32,-40,48,-64v25,-37,47,-66,68,-104r408,0r0,1528r-300,0v-28,-3,-16,-29,-16,-56r0,-972v1,-25,0,-46,-4,-64v-46,58,-82,121,-124,180v-42,59,-84,132,-132,184v-18,41,-48,67,-64,100v-18,19,-35,56,-52,68v-22,50,-64,98,-88,124v-13,-24,-26,-30,-32,-52v-31,-36,-54,-87,-88,-120v-8,-21,-23,-38,-32,-56v-44,-43,-64,-99,-100,-140v-10,-23,-32,-39,-40,-60v-20,-15,-24,-45,-44,-60v-13,-24,-26,-30,-32,-52v-14,-11,-19,-33,-32,-44v-16,-27,-37,-50,-56,-76r0,1096r-312,0r4,0v-12,-209,-4,-498,-4,-736r0,-792","w":2024},"N":{"d":"1232,-222v-9,-18,-23,-32,-28,-48v-38,-39,-46,-72,-72,-108v-32,-44,-58,-81,-84,-128v-23,-23,-31,-46,-48,-64v-33,-64,-77,-111,-108,-172v-16,-7,-18,-27,-28,-40v-19,-26,-26,-49,-48,-68v-9,-13,-19,-27,-24,-44v-14,-5,-16,-21,-24,-32v-18,-27,-38,-52,-52,-84v-10,-10,-20,-20,-24,-36v-36,-34,-48,-81,-80,-112v-16,-32,-36,-60,-56,-88r0,1024r-316,0r0,-1528r360,0v31,45,56,96,92,136v11,32,42,54,48,80v39,46,57,89,92,132v21,48,67,88,80,128v30,47,65,89,92,140v15,29,43,45,52,80v33,31,38,67,68,96v20,31,28,48,48,72v2,7,4,14,12,16v11,28,28,39,36,64v25,27,42,53,52,76v11,-190,4,-421,4,-632r0,-388r316,0r0,1528r-264,0r8,0r-104,0","w":1824},"O":{"d":"1588,-1090v44,412,-110,711,-436,848v-302,127,-583,79,-788,-132v-242,-249,-301,-561,-192,-896v105,-323,324,-516,640,-516v453,0,727,234,776,696xm468,-922v12,192,89,328,236,408v41,7,65,28,104,28v281,0,424,-147,440,-432v21,-367,-118,-555,-428,-564v-256,49,-372,235,-352,560","w":1712},"P":{"d":"248,-1750r696,0r116,24v250,120,375,314,316,568v-73,317,-297,439,-628,400r-184,0r0,536r-316,0r0,-1528xm564,-1046r336,0v17,-7,31,-11,44,-12v111,-66,152,-158,112,-272v-21,-59,-63,-97,-116,-120v-117,-25,-237,-7,-376,-12r0,416","w":1456},"Q":{"d":"1588,-1242v100,386,-7,703,-268,932v21,17,28,48,44,72v18,27,33,49,40,72r-92,44v-22,23,-58,23,-80,44v-42,13,-85,49,-120,56v-12,-17,-11,-34,-24,-44v-21,-48,-51,-91,-60,-124v-22,0,-44,8,-60,4v-261,30,-470,-39,-624,-212v-124,-139,-192,-295,-208,-464v-24,-252,28,-470,160,-648v135,-182,316,-276,536,-276v405,0,661,180,756,544xm472,-934v9,186,77,351,232,416v46,20,125,37,176,32v-13,-29,-30,-54,-40,-84v-20,-27,-33,-53,-40,-80v26,-16,48,-18,68,-36v34,-13,73,-36,104,-48v29,-20,56,-33,80,-40v19,29,20,51,40,68v10,26,32,47,36,68v15,18,25,34,32,48v8,-12,16,-21,24,-28v10,-18,21,-33,32,-44v71,-175,86,-345,44,-508v-54,-209,-185,-326,-392,-312v-283,18,-413,213,-396,548","w":1748},"R":{"d":"240,-1750r716,0v42,7,72,3,104,16v31,2,52,17,80,24v123,65,209,152,244,268v84,280,-13,483,-276,604r8,4r60,112v18,26,42,63,52,88v16,20,27,39,32,56v35,43,47,80,72,124v34,35,48,93,80,128v18,42,48,78,56,108r-364,0v-17,-27,-36,-52,-48,-84v-13,-15,-21,-30,-24,-44v-16,-17,-27,-34,-32,-52v-30,-41,-41,-71,-64,-112v-33,-39,-47,-74,-68,-116v-22,-25,-31,-47,-44,-76v-15,-6,-16,-29,-24,-40v-19,-27,-35,-50,-44,-72r-200,0r0,596r-316,0r0,-1532xm556,-1102r384,0r48,-12v79,-49,121,-117,104,-200v-13,-61,-54,-104,-104,-132v-113,-30,-283,-11,-432,-16r0,360","w":1604},"S":{"d":"676,-870v-258,-46,-432,-168,-432,-408v0,-301,182,-483,532,-508v274,-20,499,77,672,252v-23,21,-49,39,-68,64v-21,9,-36,26,-48,44v-29,14,-37,41,-64,52v-15,19,-37,40,-52,52v-168,-137,-341,-181,-520,-132v-10,9,-21,16,-32,20v-16,20,-36,25,-44,44r-20,48v1,53,19,96,52,128v79,34,187,41,268,72v32,-2,43,18,76,16r116,36v50,18,99,44,132,76v30,18,58,41,76,64v101,132,122,276,72,420v-52,148,-145,249,-280,292v-415,132,-757,47,-1020,-244v9,-16,29,-26,44,-36v22,-30,57,-34,76,-64v15,-9,24,-24,44,-28v9,-15,24,-24,40,-32r56,-48v177,173,374,236,592,188v8,-8,24,-8,28,-20r60,-40v9,-23,19,-41,28,-56v8,-73,-15,-130,-68,-172v-95,-36,-215,-62,-316,-80","w":1588},"T":{"d":"48,-1750r1180,0r0,304r-432,0r0,1228r-316,0r0,-1228r-432,0r0,-304","w":1276},"U":{"d":"1132,-682v61,-124,36,-291,36,-472r0,-584r312,0r0,984v-5,17,-1,30,-8,40v-3,35,-8,65,-16,88v-60,168,-161,290,-300,364v-170,91,-340,109,-504,48v-334,-123,-436,-391,-436,-800r0,-728v92,10,209,1,316,4r4,964r24,88v67,118,162,188,284,188v132,0,227,-67,288,-172r0,-12","w":1704},"V":{"d":"388,-1742r72,256v22,64,39,132,56,200v24,49,25,105,48,152v13,64,37,118,48,184v29,68,36,141,64,208v7,54,27,96,40,144v22,-101,52,-198,80,-292r80,-272v-1,-28,18,-38,16,-68r48,-164v16,-25,17,-77,32,-100v5,-57,36,-96,40,-156r28,-92r332,0r-60,212r-20,60r-48,180r-68,220r-140,504r-100,348v-127,11,-294,0,-440,4v-9,-46,-31,-78,-36,-128v-11,-30,-20,-61,-24,-88v-20,-43,-20,-86,-40,-124v-3,-38,-21,-62,-24,-100v-24,-52,-32,-113,-52,-168v-7,-45,-18,-81,-32,-124v-36,-113,-62,-237,-104,-348v-5,-31,-10,-62,-24,-84v-4,-59,-36,-95,-40,-156v-15,-22,-13,-62,-28,-84v-5,-46,-31,-89,-32,-124r328,0","w":1440},"W":{"d":"1660,-1470v10,-74,33,-135,44,-208v9,-25,15,-46,16,-64r324,0v2,40,-11,60,-20,96r-16,68r-56,232v-6,75,-37,139,-44,208v-21,50,-28,104,-40,156r-60,264v-17,61,-27,143,-48,196v-5,63,-26,94,-32,152v-16,48,-23,105,-36,156r-308,0v-36,2,-67,1,-92,-4v-14,-100,-40,-212,-60,-304v-10,-45,-17,-100,-32,-144v-3,-55,-29,-122,-32,-168v-23,-86,-42,-191,-60,-280v-9,-46,-17,-89,-28,-132r-40,180r-72,360v-17,45,-17,111,-36,152r-68,340r-308,0v-36,2,-67,1,-92,-4v-4,-44,-25,-92,-24,-124v-31,-98,-45,-213,-76,-308v-1,-35,-18,-62,-16,-88v-27,-82,-40,-161,-60,-244v-17,-71,-28,-133,-44,-200v-18,-75,-24,-120,-44,-192v-14,-50,-27,-121,-40,-172v-8,-32,-19,-59,-20,-84v-9,-26,-14,-40,-16,-68v-7,-16,-11,-31,-12,-44r236,0v36,-2,67,-1,92,4v9,80,33,142,48,220v8,43,22,81,28,124v17,48,19,83,32,132v10,37,19,67,20,92v15,34,18,66,24,100v10,25,15,47,16,68v11,28,13,56,20,84v20,75,30,138,52,208r44,-208r104,-492v8,-72,32,-131,40,-204v13,-39,19,-87,28,-128r368,0r72,364v19,43,18,111,36,152r72,348v4,56,31,118,32,168v26,-62,40,-148,56,-216r104,-452v12,-26,10,-67,24,-92","w":2096},"X":{"d":"84,-1742r372,0v23,25,39,71,60,92v5,12,12,22,20,32v24,52,51,76,72,124v19,17,24,48,44,64v6,11,7,28,20,32v15,31,31,55,48,72v42,-84,96,-154,140,-236v11,-21,31,-33,36,-60v18,-16,26,-44,40,-64r8,-4v8,-21,17,-38,28,-52r372,0v-16,38,-39,56,-52,92r-80,124v-18,39,-47,67,-64,108v-17,17,-29,50,-44,64v-7,16,-15,29,-24,40v-28,51,-58,97,-88,144r-92,148v20,25,26,52,48,72v7,33,39,53,44,80v16,17,27,35,32,52v11,2,11,16,16,24v38,51,56,98,92,144v14,37,48,69,60,104v17,28,39,52,52,84v13,15,23,30,28,44v14,17,25,34,32,52v14,17,25,34,32,52v17,20,29,40,36,60v12,13,20,26,24,40r-372,0v-10,-8,-7,-28,-20,-32v-9,-30,-38,-54,-44,-80v-22,-27,-32,-60,-56,-84r-40,-72v-34,-35,-39,-70,-68,-104v-7,-21,-24,-34,-28,-52r-8,-4v-14,-31,-30,-55,-48,-72v-23,49,-56,88,-80,136v-11,11,-16,29,-28,40v-17,34,-40,64,-56,96v-36,40,-54,95,-88,136v-11,32,-43,65,-52,92r-372,0v28,-71,78,-122,108,-188v12,-26,37,-40,44,-72v11,-17,27,-29,32,-52v36,-48,66,-102,96,-156v20,-16,25,-47,44,-64v8,-23,19,-42,36,-56v2,-9,3,-18,12,-20v9,-27,24,-37,32,-60v23,-20,29,-55,52,-76v11,-25,23,-45,36,-60v-14,-37,-48,-69,-60,-104v-12,-3,-10,-19,-20,-24v-21,-33,-36,-71,-60,-100v-28,-54,-57,-77,-76,-128v-24,-32,-44,-62,-60,-92v-20,-36,-45,-64,-60,-104v-25,-28,-41,-66,-64,-96v-10,-30,-38,-53,-44,-76","w":1412},"Y":{"d":"28,-1742r360,0v32,49,61,103,88,156v19,37,48,78,60,112v24,32,29,59,52,88v17,41,47,70,60,116v5,3,7,5,8,8v15,31,29,55,44,72v36,-77,81,-146,120,-220r76,-140v18,-21,26,-52,44,-72v18,-44,43,-79,64,-120r364,0r-80,144v-2,7,-4,14,-12,16v-45,105,-106,190,-156,292v-23,47,-48,96,-80,136v-17,47,-45,70,-60,116v-6,6,-13,11,-16,20v-18,47,-43,75,-60,108v-18,35,-31,66,-48,88r0,608r-316,0r0,-608v-49,-69,-68,-127,-108,-192v-35,-57,-54,-100,-88,-152v-18,-44,-41,-70,-60,-108r-44,-88v-12,-3,-11,-18,-16,-28v-25,-27,-27,-56,-48,-76r-68,-128v-14,-31,-39,-55,-44,-84v-19,-22,-31,-43,-36,-64","w":1392},"Z":{"d":"104,-1742r1052,0r0,320v-39,33,-58,86,-96,120v-1,13,-15,15,-16,28r-12,8v-17,37,-47,56,-64,92v-42,45,-77,105,-116,148v-16,35,-48,53,-64,88r-68,88r-64,84v-38,53,-82,99,-116,156v-11,2,-8,18,-20,20v-12,22,-30,40,-44,60r704,0r0,284v11,54,-65,32,-124,32r-976,0r0,-320v24,-20,35,-53,56,-76v24,-26,49,-67,72,-88v8,-11,10,-27,24,-32v20,-35,41,-50,56,-80v38,-38,62,-87,100,-124v1,-15,16,-16,20,-28r88,-120v14,-20,35,-34,44,-60v43,-46,79,-104,116,-152v17,-11,25,-31,36,-48v17,-8,18,-33,36,-40v10,-19,19,-33,28,-44r-652,0r0,-316","w":1292},"[":{"d":"8,39r244,0r245,-497r-349,0","w":731},"]":{},"^":{"d":"1540,-1210v38,19,96,18,136,36v36,2,62,15,96,20r0,-684r1096,0r0,684v32,-2,55,-18,80,-16v10,-3,17,-9,32,-8v48,-16,91,-22,140,-36v32,-1,50,-17,84,-16v11,-5,17,-8,32,-8v55,-17,95,-22,152,-36v26,-6,48,-15,68,-16v47,-17,85,-16,124,-32v94,-16,175,-39,268,-60v63,-14,124,-26,188,-44v41,-11,70,-14,104,-28v49,-5,82,-25,132,-28v91,-28,188,-41,280,-68v32,-2,55,-18,80,-16v-15,22,-32,23,-48,40v-59,34,-112,85,-172,116v-9,20,-39,20,-48,40v-40,20,-69,50,-108,72v-17,9,-27,27,-48,32v-2,10,-12,12,-20,16v-23,21,-45,35,-64,44v-2,7,-8,10,-16,12v-23,21,-44,35,-64,44v-29,27,-66,46,-96,72v-33,17,-67,54,-96,64v-17,16,-35,32,-56,40v-37,31,-65,49,-104,72v-22,26,-49,33,-72,52v-44,37,-98,65,-140,104v-14,2,-18,14,-32,16v-2,7,-8,10,-16,12v-23,23,-46,39,-68,48r-4,8v-26,19,-58,33,-80,56v-23,8,-32,29,-56,36v-9,11,-24,16,-36,24v-40,41,-81,53,-120,88v-34,30,-77,51,-112,80v-50,26,-84,70,-136,92v-8,11,-14,16,-28,20v-5,14,-21,16,-32,24v-40,32,-66,48,-104,76v-32,24,-72,46,-100,72v-31,15,-55,35,-80,56v-29,9,-41,36,-68,44v-5,10,-21,8,-24,20r-64,44r-124,-84r-136,-100v-29,-19,-60,-36,-84,-60v-16,-3,-26,-20,-36,-24v-27,-17,-48,-33,-64,-48v-17,-9,-31,-18,-40,-28v-55,-32,-109,-71,-152,-108v-48,-20,-93,-61,-132,-88v-42,-29,-78,-51,-112,-84v-12,-4,-24,-8,-28,-20v-35,-14,-48,-39,-80,-52v-34,-31,-80,-51,-112,-84v-41,-18,-56,-44,-92,-60r-4,-8v-43,-21,-64,-47,-104,-68v-31,-25,-67,-45,-96,-72v-22,-7,-33,-25,-52,-36v-45,-27,-65,-48,-104,-72v-37,-22,-74,-50,-104,-72r-116,-84v-49,-34,-92,-70,-144,-100v-15,-18,-42,-24,-56,-44v-20,-12,-44,-20,-56,-40v-16,-2,-20,-18,-36,-20v-13,-10,-22,-24,-40,-28v-14,-13,-25,-21,-40,-28r-4,-8v-28,-16,-47,-26,-64,-44v-44,-27,-77,-51,-100,-72v16,-1,27,2,36,8r208,48r200,48v78,10,143,31,220,48v78,17,164,42,240,60v95,23,174,40,268,60v40,8,89,24,124,32r200,44v9,6,20,10,36,8","w":4644},"_":{"w":490},"`":{"d":"304,-1838r332,0r-56,104r-8,4v-18,55,-52,80,-72,132v-23,32,-27,60,-52,84v-18,33,-38,77,-56,100r-332,0v26,-58,65,-113,92,-168v28,-26,35,-71,60,-100v18,-34,43,-61,56,-100r8,-4v8,-21,17,-39,28,-52xm252,-1222r524,0r0,256v-128,23,-351,0,-524,8r0,-264","w":956},"a":{"d":"960,-1218v20,40,55,70,56,120v8,26,12,49,12,68r0,392v-3,66,0,121,8,164v33,34,70,55,112,64v-38,73,-67,154,-104,228v-119,1,-208,-37,-268,-112v-114,113,-254,137,-424,84v-154,-47,-272,-135,-272,-284v0,-215,106,-329,304,-376v92,-22,226,-47,340,-48v17,-155,-90,-200,-256,-148v-45,3,-72,24,-112,32v-21,14,-39,23,-56,28v-23,17,-45,29,-68,36r-28,-52v-13,-7,-17,-22,-24,-36v-17,-20,-29,-39,-36,-56v-11,-10,-17,-21,-20,-32v-17,-17,-28,-34,-32,-52v35,-17,66,-46,108,-56v21,-24,64,-21,80,-40v27,1,31,-20,56,-16v18,-9,35,-15,52,-16v205,-71,429,-14,572,108xm724,-698v-106,12,-219,36,-300,68v-28,37,-36,76,-24,116v67,93,163,109,288,48v48,-38,36,-140,36,-232","w":1204},"b":{"d":"144,-1742r300,0r0,476v210,-121,401,-111,584,12v39,26,55,47,84,76v125,229,152,457,68,680v-67,179,-192,278,-364,304v-145,22,-268,-7,-368,-92v-5,25,-7,47,-4,68r-300,0r0,-1524xm460,-954r-16,68r0,248v49,131,140,199,268,180v139,-21,199,-115,208,-256v17,-245,-68,-369,-280,-372v-81,23,-141,67,-180,132","w":1324},"c":{"d":"1092,-994v-67,29,-143,47,-208,76v-29,13,-55,21,-76,24v-41,-127,-122,-191,-244,-192v-131,55,-192,150,-192,284v0,119,11,220,84,296v65,67,142,81,216,44v74,-37,118,-98,136,-172v23,0,34,13,56,16r8,8v58,14,98,37,152,52v16,16,52,16,68,28v-111,259,-299,389,-560,352v-287,-41,-446,-224,-464,-516v-23,-376,139,-624,476,-660v273,-30,459,117,548,360","w":1160},"d":{"d":"848,-286v-198,160,-521,124,-660,-72v-121,-170,-154,-363,-112,-572v41,-203,145,-339,320,-396v170,-55,322,-29,452,64r0,-480r300,0r0,1524r-300,0r0,-68xm380,-882v-43,196,26,412,192,424v108,8,196,-29,248,-116v44,-73,20,-200,24,-316v-41,-141,-134,-218,-272,-196v-115,19,-169,100,-192,204","w":1296},"e":{"d":"1076,-858v8,49,19,145,16,196v-199,-11,-453,0,-676,-4r-48,0v15,116,74,189,180,208v131,24,241,-13,328,-100r32,36v17,9,21,25,36,32v12,21,35,28,44,48v11,10,22,14,28,28v6,2,10,6,12,12v13,10,24,19,32,28v-126,160,-299,219,-520,180v-270,-47,-433,-209,-460,-492v-34,-356,123,-573,440,-648v326,-5,505,155,556,476xm372,-890r436,0v-30,-120,-103,-185,-220,-196v-123,19,-195,85,-216,196","w":1192},"f":{"d":"524,-1754v38,-4,62,4,100,4v70,0,127,16,188,28v1,35,-15,53,-16,88v-14,49,-23,107,-36,160v-115,-27,-191,-8,-228,56r0,104r208,0r0,248r-208,0r0,852r-304,0r0,-852r-172,0r0,-248r172,0v-34,-265,65,-414,296,-440","w":856},"g":{"d":"804,-1258v5,-20,6,-37,4,-52r300,0r0,1052v-7,48,-17,104,-32,144r-8,8v-27,60,-59,110,-108,144v-21,8,-33,28,-56,32v-18,16,-47,23,-68,36v-277,68,-528,37,-752,-92v14,-44,45,-73,60,-116v30,-44,51,-88,76,-128v25,9,45,19,60,32v147,65,293,84,436,56v12,-10,24,-17,36,-20v9,-17,24,-21,32,-36v9,-17,19,-34,24,-56r0,-72v-187,80,-359,76,-512,-20v-143,-90,-217,-219,-224,-380v-15,-358,133,-564,444,-600v110,-13,207,16,288,68xm376,-846v-14,111,1,205,80,264v66,49,142,50,216,32v111,-28,171,-143,136,-344v-22,-124,-123,-187,-256,-164v-112,20,-162,102,-176,212","w":1272},"h":{"d":"140,-1742r300,0r0,508v132,-101,271,-129,412,-72v129,52,215,144,260,264r0,16v17,43,24,83,24,120r0,692r-300,0r0,-680v-2,-27,-19,-52,-20,-72v-51,-71,-119,-105,-200,-88v-62,13,-111,49,-148,92v-7,30,-28,59,-28,84r0,664r-300,0r0,-1528","w":1296},"i":{"d":"452,-1610v2,75,-23,134,-76,176v-121,48,-206,19,-256,-88v-27,-120,16,-197,128,-232v110,-2,178,46,204,144xm132,-1306r300,0r0,1092r-300,0r0,-1092","w":596},"j":{"d":"620,-1618v5,75,-18,135,-68,180v-123,53,-211,25,-264,-84v-24,-127,24,-205,144,-232v98,5,161,50,188,136xm300,-1306r296,0r4,1244r-20,72v-26,42,-55,74,-88,96v-159,54,-312,58,-460,12v-1,-27,10,-44,16,-64r56,-188v83,28,147,15,192,-40v10,-159,4,-345,4,-520r0,-612","w":768},"k":{"d":"132,-1742r300,0r0,812v22,-18,36,-44,60,-60v13,-16,20,-29,36,-36v16,-25,39,-36,56,-56v15,-17,28,-33,44,-44v9,-13,18,-22,28,-28v9,-17,25,-21,32,-36v21,-12,28,-35,48,-44v10,-11,14,-22,28,-28v2,-6,6,-10,12,-12v16,-18,18,-32,52,-32r376,0v-12,25,-37,38,-52,60v-20,18,-36,41,-60,56v-13,18,-27,31,-40,40v-22,28,-40,40,-60,64v-38,28,-62,68,-100,96v-13,16,-27,32,-44,44v-9,13,-18,22,-28,28v-19,26,-37,46,-56,60v2,7,4,14,12,16v35,66,81,122,112,184v28,26,41,69,64,100v30,39,50,78,76,116v16,23,23,41,40,60r36,64v16,8,17,31,28,44v17,19,29,37,36,56r-356,0v-16,-27,-37,-48,-48,-80v-29,-29,-34,-55,-56,-80v-14,-37,-48,-69,-60,-104v-24,-28,-41,-63,-64,-92v-13,-26,-26,-47,-40,-64v-27,24,-42,55,-72,72v-13,18,-26,33,-40,44r0,304r-300,0r0,-1524","w":1232},"l":{"d":"128,-1742r304,0r0,1216v41,49,100,59,176,32r20,176v10,26,7,62,12,92r-160,24v-178,36,-294,-21,-348,-172v-10,-175,-4,-383,-4,-576r0,-792","w":680},"m":{"d":"976,-1194v137,-145,293,-183,464,-108v106,46,183,118,232,212v6,42,27,69,32,116v3,31,8,57,8,80r0,676r-300,0r0,-668v-8,-31,-8,-49,-16,-72v-10,-12,-17,-24,-20,-36v-6,-2,-10,-6,-12,-12v-19,-19,-37,-34,-52,-44v-109,-15,-186,28,-232,128r-8,56r0,648r-296,0r0,-636r-16,-100v-29,-51,-67,-86,-116,-104v-89,7,-154,47,-196,120v-8,29,-12,55,-12,76r0,644r-300,0r0,-1092r300,0r0,72v69,-55,142,-91,220,-100v145,-16,252,35,320,144","w":1876},"n":{"d":"1084,-1114v25,63,52,166,52,244r0,652r-304,0r0,-692v-7,-17,-11,-31,-12,-44v-32,-56,-75,-92,-128,-108v-111,-3,-192,40,-244,128r-8,28r0,688r-304,0r0,-1092r304,0v-1,27,0,50,4,68v67,-53,137,-91,212,-96v182,-12,325,69,428,224","w":1292},"o":{"d":"1076,-1026v9,12,17,24,20,36v58,232,42,446,-84,612v-146,193,-350,249,-568,180v-232,-73,-360,-242,-376,-492v-24,-381,138,-628,480,-664v260,-27,439,107,528,328xm372,-750v0,171,67,273,212,304v175,-12,258,-140,236,-384v-16,-169,-106,-254,-256,-256v-145,63,-192,174,-192,336","w":1248},"p":{"d":"1200,-686v-16,234,-126,398,-320,468v-173,62,-329,32,-460,-68r0,396r-300,0r0,-1416r300,0r0,44v77,-51,155,-92,236,-92v386,0,574,226,544,668xm432,-950v0,29,-10,48,-16,72r0,228v33,113,103,181,212,192v122,12,204,-39,240,-144v39,-112,36,-218,4,-320v-38,-120,-122,-176,-260,-164v-81,25,-141,70,-180,136","w":1296},"q":{"d":"880,-1262v4,-16,5,-31,4,-44r304,0r0,1416r-304,0r0,-396v-144,106,-293,129,-448,72v-174,-64,-272,-182,-308,-352v-35,-164,-33,-315,16,-456v69,-200,202,-317,408,-332v126,-9,236,27,328,92xm620,-1086v-58,6,-96,40,-136,60v-91,135,-111,283,-48,440v70,175,342,169,428,8v41,-76,16,-202,20,-316v-41,-135,-130,-205,-264,-192","w":1304},"r":{"d":"440,-1202v98,-93,178,-134,348,-124r0,288v-154,-20,-265,29,-332,148v-4,39,-16,69,-16,104r0,568r-300,0r0,-1088r300,0r0,104","w":920},"s":{"d":"996,-1178r-76,80v-17,24,-36,32,-48,56v-25,16,-39,44,-60,64v-174,-145,-309,-159,-404,-44v-1,31,6,57,20,80v43,17,101,22,148,36v146,1,265,47,356,136v77,114,95,230,48,344v-42,101,-110,172,-204,200v-298,90,-550,31,-752,-160v18,-22,28,-38,52,-48v29,-38,64,-57,92,-92r16,-8v19,-25,38,-43,56,-56v133,131,268,177,404,136r4,-8v19,-12,33,-27,44,-44v3,-41,-11,-71,-40,-92v-17,0,-24,-10,-44,-12r-8,-8v-41,-7,-74,-15,-100,-24v-235,-11,-396,-113,-396,-312v0,-237,131,-370,384,-388v204,-15,373,43,508,164","w":1084},"t":{"d":"540,-1726r0,408r276,0r0,252r-276,0r0,544r8,24v51,52,133,57,244,16v9,43,28,76,32,124v17,36,22,87,36,124v-166,52,-323,63,-472,32v-45,-23,-81,-49,-108,-80v-22,-48,-40,-63,-40,-116v0,-195,0,-448,-4,-668r-176,0r0,-252r176,0r0,-340r172,-48v35,-18,92,-25,124,-40v5,6,8,13,8,20","w":912},"u":{"d":"132,-1310r304,0r4,716v70,135,175,169,304,88v43,-27,68,-69,84,-112r0,-692r304,0r0,1092r-304,0r0,-72v-159,115,-319,131,-476,40v-74,-43,-125,-101,-160,-164v-20,-14,-25,-51,-32,-72v-59,-186,-17,-441,-28,-696r0,-128","w":1300},"v":{"d":"116,-1066v-2,-43,-30,-61,-32,-104v-5,-16,-17,-26,-16,-48v-5,-4,-10,-9,-8,-20v-13,-25,-21,-47,-24,-68r312,0r36,108v15,33,22,71,36,108v26,71,41,129,68,196v21,51,26,98,52,140v-1,21,10,30,16,44v7,30,16,55,28,76v18,-68,45,-129,64,-196v11,-20,16,-52,28,-68v13,-58,30,-104,52,-152v5,-41,27,-64,32,-104v12,-27,17,-43,24,-72v15,-30,24,-57,28,-80r316,0r-64,192v-32,72,-48,137,-76,204v-12,28,-16,59,-28,84v-9,37,-20,67,-32,88v-17,68,-38,112,-56,176v-20,38,-29,90,-48,128v-14,28,-16,64,-32,88v-9,47,-31,86,-44,132r-336,0v-25,-77,-51,-147,-76,-228v-21,-67,-49,-129,-68,-192v-12,-41,-38,-86,-40,-120v-32,-69,-50,-151,-80,-220v-2,-31,-24,-56,-24,-80","w":1160},"w":{"d":"72,-1154v-6,-57,-29,-100,-40,-152r300,0v18,97,54,175,72,272v29,71,37,137,60,200v11,28,12,63,24,88v6,38,26,83,28,112v27,-47,28,-111,44,-168v14,-50,22,-106,40,-152v11,-78,33,-154,52,-224v3,-42,25,-90,28,-128r332,0v11,77,31,140,48,216v15,66,32,140,52,204v8,28,7,63,20,84v8,59,26,116,40,168r112,-404v21,-52,39,-114,52,-168r24,-100r300,0v2,12,-4,18,-8,24v-10,62,-25,101,-40,156r-156,556r-48,164v-15,70,-35,126,-52,192r-352,0v-5,-28,-19,-66,-20,-88v-8,-30,-17,-76,-24,-104r-64,-260v-2,-32,-18,-55,-16,-80v-8,-19,-12,-37,-12,-52v-12,-30,-19,-57,-20,-80r-56,224v-9,72,-33,129,-44,200v-27,73,-36,169,-60,240r-352,0v3,-26,-14,-30,-12,-56v-24,-66,-42,-146,-60,-216v-22,-42,-18,-78,-36,-112v2,-34,-21,-59,-20,-88v-23,-50,-28,-83,-40,-128v-18,-64,-29,-122,-48,-184v-15,-49,-28,-109,-48,-156","w":1736},"x":{"d":"72,-1306r340,0v8,29,36,42,40,68v24,28,43,51,56,84v12,9,16,19,24,32v18,28,35,49,44,68v55,-57,90,-134,136,-196v16,-21,28,-40,36,-56r340,0v-23,36,-43,74,-72,104v-26,50,-61,91,-88,140v-25,25,-36,66,-64,88v-17,39,-45,67,-64,104v-23,19,-32,55,-52,72v20,31,50,68,64,100v7,6,14,13,16,24v16,15,27,31,32,48v42,43,56,76,84,120r80,124v19,25,24,42,40,64v20,13,30,36,40,60v14,14,23,29,28,44r-332,0v-14,-26,-41,-53,-48,-76v-32,-36,-55,-81,-84,-120v-14,-30,-36,-51,-52,-80v-13,-24,-28,-40,-40,-52v-26,47,-63,93,-88,140v-16,13,-26,42,-40,52v-5,24,-25,33,-32,56v-24,20,-36,60,-56,80r-332,0v39,-80,92,-137,132,-208r8,-4v16,-41,40,-54,52,-88v20,-24,33,-55,56,-76v16,-44,48,-62,64,-104v29,-26,46,-78,72,-100v-44,-76,-99,-146,-144,-220v-9,-15,-15,-26,-28,-36v-11,-15,-14,-39,-32,-48v-15,-31,-43,-62,-52,-84v-16,-15,-27,-31,-32,-48v-25,-27,-42,-53,-52,-76","w":1192},"y":{"d":"96,114v0,-50,15,-92,16,-144v10,-36,11,-86,20,-124v147,37,234,17,260,-60v1,-95,-54,-163,-68,-240v-7,-10,-11,-21,-12,-32v-25,-49,-38,-95,-56,-144r-80,-224v-26,-74,-53,-142,-76,-216v-12,-17,-10,-49,-24,-64r-60,-172r308,0r84,244v11,22,17,42,20,60v21,47,32,82,48,132v4,6,10,12,8,24v21,37,26,73,40,112v5,7,9,17,12,32v9,15,14,29,16,44v54,-118,96,-255,140,-376v28,-77,56,-144,76,-220r20,-52r308,0v-13,26,-15,61,-32,84v-2,33,-24,45,-24,80r-80,212v-23,81,-57,164,-84,240v-18,50,-40,122,-60,156v-22,79,-52,144,-76,216v-19,58,-38,97,-52,152v-15,31,-23,70,-40,100v-14,61,-47,118,-84,152v-40,16,-60,49,-104,48v-65,15,-112,12,-176,4","w":1148},"z":{"d":"80,-1306r824,0r0,260v-22,13,-31,42,-52,56v-28,39,-68,92,-100,120v-16,28,-38,50,-56,76r-8,4v-26,40,-47,58,-72,92v-22,14,-31,44,-52,56v-23,39,-61,82,-88,108v-2,7,-4,14,-12,16r-32,44r484,0r0,232v8,45,-53,28,-100,28r-764,0r0,-264v4,-5,9,-9,16,-12v13,-23,28,-42,44,-56v24,-36,46,-53,68,-80v10,-26,31,-42,48,-60v29,-33,49,-74,84,-100v4,-8,6,-18,16,-20v13,-26,33,-34,44,-60v14,-4,14,-23,28,-28v41,-60,85,-100,124,-156r-444,0r0,-256","w":1004},"{":{"d":"228,-1822r220,0r0,1076r-244,0r0,-752r-152,0r0,-164v110,-6,169,-59,176,-160xm1364,-970v67,143,26,253,-96,316v97,55,144,133,144,236v0,130,-57,236,-148,296v-143,51,-280,62,-412,36v-170,-34,-273,-127,-308,-284r0,-24v39,3,62,-17,96,-16r148,-28v19,102,87,148,204,148v106,0,163,-45,172,-136v-29,-93,-116,-132,-260,-116r0,-196v196,1,268,-57,216,-176r-32,-36v-153,-56,-250,-17,-292,116r-236,-32v32,-193,156,-303,372,-320v204,-16,357,55,432,216","w":1476},"|":{"d":"240,-1990r316,0r0,1961r-316,0r0,-1961","w":788},"}":{"d":"860,-1518v10,7,-2,30,8,40v2,33,-4,75,-4,100v-12,41,-28,98,-44,128r-8,4v-81,131,-183,228,-304,292r-4,8r356,0v-4,69,10,156,-8,212r-776,0r0,-212r156,-96v37,-31,71,-51,112,-76v16,-22,40,-24,52,-44v7,-5,14,-10,24,-12v13,-17,31,-19,40,-36v16,-3,22,-16,32,-24v39,-30,72,-54,88,-80v75,-123,55,-225,-48,-300v-37,-10,-72,-13,-104,-8v-95,49,-138,125,-128,228r-244,0v-2,-276,130,-432,396,-444v236,-10,373,105,408,320xm948,-866v34,-192,158,-302,372,-320v204,-17,355,56,432,216v69,143,33,250,-92,312v115,72,159,170,140,296v-16,104,-55,190,-140,232v-145,72,-294,74,-436,40v-166,-40,-265,-134,-292,-292v7,-25,49,-12,72,-24v27,-2,45,-10,72,-12v28,-10,71,-13,100,-20v25,108,98,152,220,144v114,-7,165,-56,152,-160v-45,-72,-129,-101,-252,-88r0,-196v197,1,268,-59,212,-180r-36,-36v-157,-50,-252,-10,-284,120","w":1864},"~":{"w":636},"\u00a0":{"w":600}}});;
Cufon.replace('h1#sitename a, h1.nodetitle a, #navbar > ul > li > a', {
    hover: true
});
Cufon.replace('h1, h2, h3, h4, h5, h6, p.mission, p.slogan, .views-field-title, legend:not(.collapse-processed)');;
/*
 * SooperFish 0.1
 * (c) 2010 Jurriaan Roelofs - SooperThemes.com
 * Inspired by Suckerfish, Superfish and Droppy
 */
$.fn.sooperfish = function(op) {

  var sf = $.fn.sooperfish;
  sf.o = [];
  sf.op = {};
  sf.c = {
    menuClass   : 'sf-js-enabled',
    isParent : 'sf-parent',
    arrowClass  : 'sf-arrow'
  };
  sf.defaults = {
    sooperfishWidth : 150, //match with the width you gave submenu list items in CSS (including margin and padding applied to these list items)
    multiColumn  : true,
    dualColumn  : 6, //if a submenu has at least this many items it will be divided in 2 columns
    tripleColumn  : 12, //if a submenu has at least this many items it will be divided in 3 columns
    hoverClass  : 'sfHover',
    delay    : 500, //make sure menus only disappear when intended, 500ms is advised by Jacob Nielsen
    animationShow  : {height:'show'},
    speedShow    : 600,
    easingShow      : 'easeOutBounce',
    animationHide  : {height:'hide',opacity:'hide'},
    speedHide    : 200,
    easingHide      : 'easeInTurbo',
    autoArrows  : true, //Adds span elements to parent li elements, projecting arrow images on these items to indicate submenus. I added an alternative image file with white arrows.
    onShow    : function(){}, //callback after showing menu
    onHide    : function(){} //callback after hiding menu
  };
  

  //Merge default settings with o function parameter
  var o = $.extend({},sf.defaults,op);
  if (!o.sooperfishWidth) {
  o.sooperfishWidth = $('ul:first li:first', this).width();
  alert(o.sooperfishWidth);
  }

  this.each(function() {
  
    
    //Check dom for submenus
    var parentLi = $('li:has(ul)', this);
    parentLi.each(function(){
      if (o.autoArrows) { //Add autoArrows if requested
      $('>a',this).append('<span class="'+sf.c.arrowClass+'"></span>');
      }
      $(this).addClass(sf.c.isParent);
    });

    //Divide menu in columns
    //Set width override
    if (o.multiColumn) {
    var uls = $('ul',this);
    uls.each(function(){
      var ulsize = $('>li:not(.backLava)',this).length; //Skip list items added by Lavalamp plugin
      if (ulsize >= o.dualColumn) {
        if (ulsize >= o.tripleColumn) {
          $(this).width(3*o.sooperfishWidth);
        } else {
          $(this).width(2*o.sooperfishWidth);
        }
      }
    });
    }

    var root = this, zIndex = 1000;

    function getSubmenu(ele) {
      if (ele.nodeName.toLowerCase() == 'li') {
        var submenu = $('> ul', ele);
        return submenu.length ? submenu[0] : null;
      } else {
        return ele;
      }
    }

    function getActuator(ele) {
      if (ele.nodeName.toLowerCase() == 'ul') {
        return $(ele).parents('li')[0];
      } else {
        return ele;
      }
    }

    function hideSooperfishUl() {
      var submenu = getSubmenu(this);
      if (!submenu) return;
      $.data(submenu, 'cancelHide', false);
      setTimeout(function() {
        if (!$.data(submenu, 'cancelHide')) {
          $(submenu).animate(o.animationHide,o.speedHide,o.easingHide,function(){ o.onHide.call(submenu); });
        }
      }, o.delay);
    }

    function showSooperfishUl() {
      var submenu = getSubmenu(this);
      if (!submenu) return;
      $.data(submenu, 'cancelHide', true);
      $(submenu).css({zIndex: zIndex++}).animate(o.animationShow,o.speedShow,o.easingShow,function(){ o.onShow.call(submenu); });
      if (this.nodeName.toLowerCase() == 'ul') {
        var li = getActuator(this);
        $(li).addClass('hover');
        $('> a', li).addClass('hover');
      }
    }
    
    // Bind Events. Yes it's that simple!
    $('li', this).hover(showSooperfishUl, hideSooperfishUl);

  });

};
;
		// initialise plugins
  $(document).ready(function() {
    $('#navbar > ul ul').hide().css('left','auto');
    $('#navbar > ul').sooperfish({
      sooperfishWidth: Drupal.settings.sooperfish.sooperfishWidth,
      hoverClass:  'over',           // hover class
      delay:     Drupal.settings.sooperfish.delay,                // 500ms delay on mouseout as per Jacob Nielsen advice
      dualColumn:     Drupal.settings.sooperfish.dualColumn,
      tripleColumn:     Drupal.settings.sooperfish.tripleColumn,
      animationShow:   Drupal.settings.sooperfish.animationShow,
      speedShow:     parseInt(Drupal.settings.sooperfish.speedShow),
      easingShow:    Drupal.settings.sooperfish.easingShow,
      animationHide:   Drupal.settings.sooperfish.animationHide,
      speedHide:     parseInt(Drupal.settings.sooperfish.speedHide),
      easingHide:    Drupal.settings.sooperfish.easingHide,
      autoArrows:  false,              // generation of arrow mark-up
      dropShadows: false               // drop shadows
    });
  });;
(function(A){A.fn.example=function(E,C){var D=A.isFunction(E);var B=A.extend({},C,{example:E});return this.each(function(){var F=A(this);if(A.metadata){var G=A.extend({},A.fn.example.defaults,F.metadata(),B)}else{var G=A.extend({},A.fn.example.defaults,B)}if(!A.fn.example.boundClassNames[G.className]){A(window).unload(function(){A("."+G.className).val("")});A("form").submit(function(){A(this).find("."+G.className).val("")});A.fn.example.boundClassNames[G.className]=true}if(A.browser.msie&&!F.attr("defaultValue")&&(D||F.val()==G.example)){F.val("")}if(F.val()==""&&this!=document.activeElement){F.addClass(G.className);F.val(D?G.example.call(this):G.example)}F.focus(function(){if(A(this).is("."+G.className)){A(this).val("");A(this).removeClass(G.className)}});F.blur(function(){if(A(this).val()==""){A(this).addClass(G.className);A(this).val(D?G.example.call(this):G.example)}})})};A.fn.example.defaults={className:"example"};A.fn.example.boundClassNames=[]})(jQuery);
/* Invoke example functino: */
$(document).ready(function(){    
  $('.block-search input.form-text, #search-theme-form input.form-text').example('Enter search...');
});;
(function(a){a.fn.lavaLamp=function(b){b=a.extend({fx:"swing",speed:500,click:function(){return true},startItem:"no",autoReturn:true,returnDelay:0,setOnClick:true,homeTop:0,homeLeft:0,homeWidth:0,homeHeight:0,returnHome:false},b||{});return this.each(function(){var h=location.pathname+location.search+location.hash;var e=new Object;var d;var i;var f;var g;if(b.homeTop||b.homeLeft){f=a('<li class="homeLava selectedLava"></li>').css({left:b.homeLeft,top:b.homeTop,width:b.homeWidth,height:b.homeHeight,position:"absolute"});a(this).prepend(f)}var j=a("li",this);if(b.startItem=="no"){e=a('li a[href$="'+h+'"]',this).parent("li")}if(e.length==0&&b.startItem=="no"&&location.hash){e=a('li a[href$="'+location.hash+'"]',this).parent("li")}if(e.length==0||b.startItem!="no"){if(b.startItem=="no"){b.startItem=0}e=a(j[b.startItem])}g=a("li.selectedLava",this)[0]||a(e).addClass("selectedLava")[0];j.mouseover(function(){if(a(this).hasClass("homeLava")){g=a(this)[0]}c(this)});i=a('<li class="backLava"><div class="innerLava"></div></li>').appendTo(this);a(this).mouseout(function(){if(b.autoReturn){if(b.returnHome&&f){c(f[0])}else{if(b.returnDelay){if(d){clearTimeout(d)}d=setTimeout(c,b.returnDelay+b.speed)}else{c()}}}});j.click(function(k){if(b.setOnClick){a(g).removeClass("selectedLava");a(this).addClass("selectedLava");g=this}return b.click.apply(this,[k,this])});if(b.homeTop||b.homeLeft){i.css({left:b.homeLeft,top:b.homeTop,width:b.homeWidth,height:b.homeHeight})}else{i.css({left:g.offsetLeft,top:g.offsetTop,width:g.offsetWidth,height:g.offsetHeight})}function c(k){if(!k){k=g}var m=0,l=0;if(!a.browser.msie){m=(i.outerWidth()-i.innerWidth())/2;l=(i.outerHeight()-i.innerHeight())/2}i.stop().animate({left:k.offsetLeft-m,top:k.offsetTop-l,width:k.offsetWidth,height:k.offsetHeight},b.speed,b.fx)}})}})(jQuery);;
$(function() {
	var query = new Object();

	easing = query['e'] || 'Expo';


// for dynamic easing changes
	function loadLamps(easing) {
    $('#navbar .menu').lavaLamp({
      speed: 200,
      returnDelay:1000
    });
  }

	$(function() {
		loadLamps(easing);
	});
});;
$(function() {
  var themePath = Drupal.settings.theme_path;

  $("a.cufon-set").mouseover(function () {
    Cufon.set('fontFamily', $(this).attr('id'));
    Cufon.replace('h1#sitename a,.nodetitle a, #navbar > ul > li > a', {
        hover: true
    });
    Cufon.replace('h1, h2, h3, h4, h5, h6, p.mission, p.slogan, .views-field-title, legend:not(.collapse-processed)');
  });

  $("a.bg-set").mouseover(function () {
    $('body').css('background-image','url('+themePath+'images/backgrounds/'+$(this).attr('id')+'.jpg)');
  });
  
  $("body.page-configurator #content input#edit-submit,body.page-configurator #content input#edit-reset").click(function () {
    alert('Sorry, you cannot change the settings of this demo site!');
	return false;
  });  

  $("div.play-animation").click(function () {
    $('#container').css('min-width', '0');
    $('#container').css('max-width', 'none');
    pagerAnim();
    containerAnim();
  });

  function pagerAnim()  {
    $('#ch1').animate(
      {'fontSize': '200%'},
      1000,
      "swing"
    ).css('color','#b91553').animate({opacity: 1.0}, 9000).animate(
      {'fontSize': '100%'},
      1000,
      "swing"
    );
    $('#ch2').animate({opacity: 1.0}, 10000).animate(
      {'fontSize': '200%'},
      1000,
      "swing"
    ).css('color','#b91553').animate({opacity: 1.0}, 6100).animate(
      {'fontSize': '100%'},
      1000,
      "swing"
    );
    $('#ch3').animate({opacity: 1.0}, 17100).animate(
      {'fontSize': '200%'},
      1000,
      "swing"
    ).css('color','#b91553').animate({opacity: 1.0}, 6000).animate(
      {'fontSize': '100%'},
      1000,
      "swing"
    ).animate({opacity: 1.0}, 2000, cleanUp);
  }

  function cleanUp()  {
    $('.sooperblocks .render').remove();
    $('.sooperblocks .block').css('width', '100%');
    $('#anim-chapters li').css('color','#222222')
  }


  function containerAnim() {
    $('#container').animate(
      {'width': '95%'},
      4000,
      "swing"
    ).animate(
      {'width': '600px'},
      4000,
      "swing"
    ).animate(
      {'width': '960px'},
      2000,
      "swing",
      columnsAnim
    );
  }

  function columnsAnim() {
    $('#content').animate(
      {'width': '30%'},
      3000,
      "swing"
    ).animate(
      {'width': '70%'},
      100,
      "swing"
    ).animate(
      {'width': '54%'},
      3000,
      "swing",
      addBlock1
    );
    $('.sidebar').animate(
      {'width': '35%'},
      3000,
      "swing"
    ).animate(
      {'width': '15%'},
      100,
      "swing"
    ).animate(
      {'width': '23%'},
      3000,
      "swing"
    );
  }

  function addBlock1() {
    $('.preblocks .block').animate(
      {'width': '50%'},
      2000,
      "swing",
      function () { preblocks1() }
    );
    $('.postblocks .block').animate(
      {'width': '50%'},
      2000,
      "swing",
      function () { postblocks1() }
    );
  }

  function preblocks1() {
    $('.preblocks').prepend('<div class="block block-block region-odd odd region-count-1 count-1 first callout-1 render" ><div class="block-inner clearfix"> <h2 class="title blocktitle"><span>Dynamic Region 1</span></h2> <div class="content"> <p>This is the "pre-blocks" region.<br /> You can put as many blocks as you like in here</p>  </div> </div></div><!-- end .inner --><!-- end .block --> ');
    $('.preblocks .block').css('width', '50%');
  }
  function postblocks1() {
    $('.postblocks').prepend('<div class="block block-block region-odd odd region-count-1 count-1 first callout-1 render" ><div class="block-inner clearfix"> <h2 class="title blocktitle"><span>Dynamic Region 2</span></h2> <div class="content"> <p>This is the "post-blocks" region.<br /> You can put as many blocks as you like in here</p></p>  </div> </div></div><!-- end .inner --><!-- end .block --> ');
    $('.postblocks .block').css('width', '50%');
    addBlock2();
  }

  function addBlock2() {
    $('.preblocks .block').animate({opacity: 1.0}, 2000).animate(
      {'width': '25%'},
      2000,
      "swing",
      function () { preblocks2() }
    );
    $('.postblocks .block').animate({opacity: 1.0}, 2000).animate(
      {'width': '25%'},
      2000,
      "swing",
      function () { postblocks2() }
    );
  }

  function preblocks2() {
    $('.preblocks .last').before('<div class="block block-block region-odd odd region-count-1 count-1 callout-3 render" ><div class="block-inner clearfix"> <h2 class="title blocktitle"><span>Dynamic Region 1</span></h2> <div class="content"> <p>This is the "pre-blocks" region.<br /> You can put as many blocks as you like in here</p>  </div> </div></div><!-- end .inner --><!-- end .block --> ');
    $('.preblocks .block').css('width', '25%');
  }
  function postblocks2() {
    $('.postblocks .last').before('<div class="block block-block region-odd odd region-count-1 count-1 callout-3 render" ><div class="block-inner clearfix"> <h2 class="title blocktitle"><span>Dynamic Region 2</span></h2> <div class="content"> <p>This is the "post-blocks" region.<br /> You can put as many blocks as you like in here</p></p>  </div> </div></div><!-- end .inner --><!-- end .block --> ');
    $('.postblocks .block').css('width', '25%');
  }

});;
/**
 * @file base.js
 *
 * Some basic behaviors and utility functions for Views.
 */

Drupal.Views = {};

/**
 * jQuery UI tabs, Views integration component
 */
Drupal.behaviors.viewsTabs = function (context) {
  $('#views-tabset:not(.views-processed)').addClass('views-processed').each(function() {
    new Drupal.Views.Tabs($(this), {selectedClass: 'active'});
  });

  $('a.views-remove-link')
    .addClass('views-processed')
    .click(function() {
      var id = $(this).attr('id').replace('views-remove-link-', '');
      $('#views-row-' + id).hide();
      $('#views-removed-' + id).attr('checked', true);
      return false;
    });
}

/**
 * For IE, attach some javascript so that our hovers do what they're supposed
 * to do.
 */
Drupal.behaviors.viewsHoverlinks = function() {
  if ($.browser.msie) {
    // If IE, attach a hover event so we can see our admin links.
    $("div.view:not(.views-hover-processed)").addClass('views-hover-processed').hover(
      function() {
        $('div.views-hide', this).addClass("views-hide-hover"); return true;
      },
      function(){
        $('div.views-hide', this).removeClass("views-hide-hover"); return true;
      }
    );
    $("div.views-admin-links:not(.views-hover-processed)")
      .addClass('views-hover-processed')
      .hover(
        function() {
          $(this).addClass("views-admin-links-hover"); return true;
        },
        function(){
          $(this).removeClass("views-admin-links-hover"); return true;
        }
      );
  }
}

/**
 * Helper function to parse a querystring.
 */
Drupal.Views.parseQueryString = function (query) {
  var args = {};
  var pos = query.indexOf('?');
  if (pos != -1) {
    query = query.substring(pos + 1);
  }
  var pairs = query.split('&');
  for(var i in pairs) {
    if (typeof(pairs[i]) == 'string') {
      var pair = pairs[i].split('=');
      // Ignore the 'q' path argument, if present.
      if (pair[0] != 'q' && pair[1]) {
        args[pair[0]] = decodeURIComponent(pair[1].replace(/\+/g, ' '));
      }
    }
  }
  return args;
};

/**
 * Helper function to return a view's arguments based on a path.
 */
Drupal.Views.parseViewArgs = function (href, viewPath) {
  var returnObj = {};
  var path = Drupal.Views.getPath(href);
  // Ensure we have a correct path.
  if (viewPath && path.substring(0, viewPath.length + 1) == viewPath + '/') {
    var args = decodeURIComponent(path.substring(viewPath.length + 1, path.length));
    returnObj.view_args = args;
    returnObj.view_path = path;
  }
  return returnObj;
};

/**
 * Strip off the protocol plus domain from an href.
 */
Drupal.Views.pathPortion = function (href) {
  // Remove e.g. http://example.com if present.
  var protocol = window.location.protocol;
  if (href.substring(0, protocol.length) == protocol) {
    // 2 is the length of the '//' that normally follows the protocol
    href = href.substring(href.indexOf('/', protocol.length + 2));
  }
  return href;
};

/**
 * Return the Drupal path portion of an href.
 */
Drupal.Views.getPath = function (href) {
  href = Drupal.Views.pathPortion(href);
  href = href.substring(Drupal.settings.basePath.length, href.length);
  // 3 is the length of the '?q=' added to the url without clean urls.
  if (href.substring(0, 3) == '?q=') {
    href = href.substring(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;
};
;

/**
 * @file ajaxView.js
 *
 * Handles AJAX fetching of views, including filter submission and response.
 */

Drupal.Views.Ajax = Drupal.Views.Ajax || {};

/**
 * An ajax responder that accepts a packet of JSON data and acts appropriately.
 *
 * The following fields control behavior.
 * - 'display': Display the associated data in the view area.
 */
Drupal.Views.Ajax.ajaxViewResponse = function(target, response) {

  if (response.debug) {
    alert(response.debug);
  }

  var $view = $(target);

  // Check the 'display' for data.
  if (response.status && response.display) {
    var $newView = $(response.display);
    $view.replaceWith($newView);
    $view = $newView;
    Drupal.attachBehaviors($view.parent());
  }

  if (response.messages) {
    // Show any messages (but first remove old ones, if there are any).
    $view.find('.views-messages').remove().end().prepend(response.messages);
  }
};

/**
 * Ajax behavior for views.
 */
Drupal.behaviors.ViewsAjaxView = function() {
  if (Drupal.settings && Drupal.settings.views && Drupal.settings.views.ajaxViews) {
    var ajax_path = Drupal.settings.views.ajax_path;
    // If there are multiple views this might've ended up showing up multiple times.
    if (ajax_path.constructor.toString().indexOf("Array") != -1) {
      ajax_path = ajax_path[0];
    }
    $.each(Drupal.settings.views.ajaxViews, function(i, settings) {
      if (settings.view_dom_id) {
        var view = '.view-dom-id-' + settings.view_dom_id;
        if (!$(view).size()) {
          // Backward compatibility: if 'views-view.tpl.php' is old and doesn't
          // contain the 'view-dom-id-#' class, we fall back to the old way of
          // locating the view:
          view = '.view-id-' + settings.view_name + '.view-display-id-' + settings.view_display_id;
        }
      }


      // Process exposed filter forms.
      $('form#views-exposed-form-' + settings.view_name.replace(/_/g, '-') + '-' + settings.view_display_id.replace(/_/g, '-'))
      .filter(':not(.views-processed)')
      .each(function () {
        // remove 'q' from the form; it's there for clean URLs
        // so that it submits to the right place with regular submit
        // but this method is submitting elsewhere.
        $('input[name=q]', this).remove();
        var form = this;
        // ajaxSubmit doesn't accept a data argument, so we have to
        // pass additional fields this way.
        $.each(settings, function(key, setting) {
          $(form).append('<input type="hidden" name="'+ key + '" value="'+ setting +'"/>');
        });
      })
      .addClass('views-processed')
      .submit(function () {
        $('input[type=submit], button', this).after('<span class="views-throbbing">&nbsp</span>');
        var object = this;
        $(this).ajaxSubmit({
          url: ajax_path,
          type: 'GET',
          success: function(response) {
            // Call all callbacks.
            if (response.__callbacks) {
              $.each(response.__callbacks, function(i, callback) {
                eval(callback)(view, response);
              });
              $('.views-throbbing', object).remove();
            }
          },
          error: function(xhr) { Drupal.Views.Ajax.handleErrors(xhr, ajax_path); $('.views-throbbing', object).remove(); },
          dataType: 'json'
        });

        return false;
      });

      $(view).filter(':not(.views-processed)')
        // Don't attach to nested views. Doing so would attach multiple behaviors
        // to a given element.
        .filter(function() {
          // If there is at least one parent with a view class, this view
          // is nested (e.g., an attachment). Bail.
          return !$(this).parents('.view').size();
        })
        .each(function() {
          // Set a reference that will work in subsequent calls.
          var target = this;
          $(this)
            .addClass('views-processed')
            // Process pager, tablesort, and attachment summary links.
            .find('ul.pager > li > a, th.views-field a, .attachment .views-summary a')
            .each(function () {
              var viewData = { 'js': 1 };
              // Construct an object using the settings defaults and then overriding
              // with data specific to the link.
              $.extend(
                viewData,
                Drupal.Views.parseQueryString($(this).attr('href')),
                // Extract argument data from the URL.
                Drupal.Views.parseViewArgs($(this).attr('href'), settings.view_base_path),
                // Settings must be used last to avoid sending url aliases to the server.
                settings
              );
              $(this).click(function () {
                $.extend(viewData, Drupal.Views.parseViewArgs($(this).attr('href'), settings.view_base_path));
                $(this).addClass('views-throbbing');
                $.ajax({
                  url: ajax_path,
                  type: 'GET',
                  data: viewData,
                  success: function(response) {
                    $(this).removeClass('views-throbbing');
                    // Scroll to the top of the view. This will allow users
                    // to browse newly loaded content after e.g. clicking a pager
                    // link.
                    var offset = $(target).offset();
                    // We can't guarantee that the scrollable object should be
                    // the body, as the view could be embedded in something
                    // more complex such as a modal popup. Recurse up the DOM
                    // and scroll the first element that has a non-zero top.
                    var scrollTarget = target;
                    while ($(scrollTarget).scrollTop() == 0 && $(scrollTarget).parent()) {
                      scrollTarget = $(scrollTarget).parent()
                    }
                    // Only scroll upward
                    if (offset.top - 10 < $(scrollTarget).scrollTop()) {
                      $(scrollTarget).animate({scrollTop: (offset.top - 10)}, 500);
                    }
                    // Call all callbacks.
                    if (response.__callbacks) {
                      $.each(response.__callbacks, function(i, callback) {
                        eval(callback)(target, response);
                      });
                    }
                  },
                  error: function(xhr) { $(this).removeClass('views-throbbing'); Drupal.Views.Ajax.handleErrors(xhr, ajax_path); },
                  dataType: 'json'
                });

                return false;
              });
            }); // .each function () {
      }); // $view.filter().each
    }); // .each Drupal.settings.views.ajaxViews
  } // if
};
;

