/*!
 * jQuery JavaScript Library v1.4.2
 * http://jquery.com/
 *
 * Copyright 2010, John Resig
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://jquery.org/license
 *
 * Includes Sizzle.js
 * http://sizzlejs.com/
 * Copyright 2010, The Dojo Foundation
 * Released under the MIT, BSD, and GPL Licenses.
 *
 * Date: Sat Feb 13 22:33:48 2010 -0500
 */
(function(A,w){function ma(){if(!c.isReady){try{s.documentElement.doScroll("left")}catch(a){setTimeout(ma,1);return}c.ready()}}function Qa(a,b){b.src?c.ajax({url:b.src,async:false,dataType:"script"}):c.globalEval(b.text||b.textContent||b.innerHTML||"");b.parentNode&&b.parentNode.removeChild(b)}function X(a,b,d,f,e,j){var i=a.length;if(typeof b==="object"){for(var o in b)X(a,o,b[o],f,e,d);return a}if(d!==w){f=!j&&f&&c.isFunction(d);for(o=0;o<i;o++)e(a[o],b,f?d.call(a[o],o,e(a[o],b)):d,j);return a}return i?
e(a[0],b):w}function J(){return(new Date).getTime()}function Y(){return false}function Z(){return true}function na(a,b,d){d[0].type=a;return c.event.handle.apply(b,d)}function oa(a){var b,d=[],f=[],e=arguments,j,i,o,k,n,r;i=c.data(this,"events");if(!(a.liveFired===this||!i||!i.live||a.button&&a.type==="click")){a.liveFired=this;var u=i.live.slice(0);for(k=0;k<u.length;k++){i=u[k];i.origType.replace(O,"")===a.type?f.push(i.selector):u.splice(k--,1)}j=c(a.target).closest(f,a.currentTarget);n=0;for(r=
j.length;n<r;n++)for(k=0;k<u.length;k++){i=u[k];if(j[n].selector===i.selector){o=j[n].elem;f=null;if(i.preType==="mouseenter"||i.preType==="mouseleave")f=c(a.relatedTarget).closest(i.selector)[0];if(!f||f!==o)d.push({elem:o,handleObj:i})}}n=0;for(r=d.length;n<r;n++){j=d[n];a.currentTarget=j.elem;a.data=j.handleObj.data;a.handleObj=j.handleObj;if(j.handleObj.origHandler.apply(j.elem,e)===false){b=false;break}}return b}}function pa(a,b){return"live."+(a&&a!=="*"?a+".":"")+b.replace(/\./g,"`").replace(/ /g,
"&")}function qa(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function ra(a,b){var d=0;b.each(function(){if(this.nodeName===(a[d]&&a[d].nodeName)){var f=c.data(a[d++]),e=c.data(this,f);if(f=f&&f.events){delete e.handle;e.events={};for(var j in f)for(var i in f[j])c.event.add(this,j,f[j][i],f[j][i].data)}}})}function sa(a,b,d){var f,e,j;b=b&&b[0]?b[0].ownerDocument||b[0]:s;if(a.length===1&&typeof a[0]==="string"&&a[0].length<512&&b===s&&!ta.test(a[0])&&(c.support.checkClone||!ua.test(a[0]))){e=
true;if(j=c.fragments[a[0]])if(j!==1)f=j}if(!f){f=b.createDocumentFragment();c.clean(a,b,f,d)}if(e)c.fragments[a[0]]=j?f:1;return{fragment:f,cacheable:e}}function K(a,b){var d={};c.each(va.concat.apply([],va.slice(0,b)),function(){d[this]=a});return d}function wa(a){return"scrollTo"in a&&a.document?a:a.nodeType===9?a.defaultView||a.parentWindow:false}var c=function(a,b){return new c.fn.init(a,b)},Ra=A.jQuery,Sa=A.$,s=A.document,T,Ta=/^[^<]*(<[\w\W]+>)[^>]*$|^#([\w-]+)$/,Ua=/^.[^:#\[\.,]*$/,Va=/\S/,
Wa=/^(\s|\u00A0)+|(\s|\u00A0)+$/g,Xa=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,P=navigator.userAgent,xa=false,Q=[],L,$=Object.prototype.toString,aa=Object.prototype.hasOwnProperty,ba=Array.prototype.push,R=Array.prototype.slice,ya=Array.prototype.indexOf;c.fn=c.prototype={init:function(a,b){var d,f;if(!a)return this;if(a.nodeType){this.context=this[0]=a;this.length=1;return this}if(a==="body"&&!b){this.context=s;this[0]=s.body;this.selector="body";this.length=1;return this}if(typeof a==="string")if((d=Ta.exec(a))&&
(d[1]||!b))if(d[1]){f=b?b.ownerDocument||b:s;if(a=Xa.exec(a))if(c.isPlainObject(b)){a=[s.createElement(a[1])];c.fn.attr.call(a,b,true)}else a=[f.createElement(a[1])];else{a=sa([d[1]],[f]);a=(a.cacheable?a.fragment.cloneNode(true):a.fragment).childNodes}return c.merge(this,a)}else{if(b=s.getElementById(d[2])){if(b.id!==d[2])return T.find(a);this.length=1;this[0]=b}this.context=s;this.selector=a;return this}else if(!b&&/^\w+$/.test(a)){this.selector=a;this.context=s;a=s.getElementsByTagName(a);return c.merge(this,
a)}else return!b||b.jquery?(b||T).find(a):c(b).find(a);else if(c.isFunction(a))return T.ready(a);if(a.selector!==w){this.selector=a.selector;this.context=a.context}return c.makeArray(a,this)},selector:"",jquery:"1.4.2",length:0,size:function(){return this.length},toArray:function(){return R.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this.slice(a)[0]:this[a]},pushStack:function(a,b,d){var f=c();c.isArray(a)?ba.apply(f,a):c.merge(f,a);f.prevObject=this;f.context=this.context;if(b===
"find")f.selector=this.selector+(this.selector?" ":"")+d;else if(b)f.selector=this.selector+"."+b+"("+d+")";return f},each:function(a,b){return c.each(this,a,b)},ready:function(a){c.bindReady();if(c.isReady)a.call(s,c);else Q&&Q.push(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(R.apply(this,arguments),"slice",R.call(arguments).join(","))},map:function(a){return this.pushStack(c.map(this,
function(b,d){return a.call(b,d,b)}))},end:function(){return this.prevObject||c(null)},push:ba,sort:[].sort,splice:[].splice};c.fn.init.prototype=c.fn;c.extend=c.fn.extend=function(){var a=arguments[0]||{},b=1,d=arguments.length,f=false,e,j,i,o;if(typeof a==="boolean"){f=a;a=arguments[1]||{};b=2}if(typeof a!=="object"&&!c.isFunction(a))a={};if(d===b){a=this;--b}for(;b<d;b++)if((e=arguments[b])!=null)for(j in e){i=a[j];o=e[j];if(a!==o)if(f&&o&&(c.isPlainObject(o)||c.isArray(o))){i=i&&(c.isPlainObject(i)||
c.isArray(i))?i:c.isArray(o)?[]:{};a[j]=c.extend(f,i,o)}else if(o!==w)a[j]=o}return a};c.extend({noConflict:function(a){A.$=Sa;if(a)A.jQuery=Ra;return c},isReady:false,ready:function(){if(!c.isReady){if(!s.body)return setTimeout(c.ready,13);c.isReady=true;if(Q){for(var a,b=0;a=Q[b++];)a.call(s,c);Q=null}c.fn.triggerHandler&&c(s).triggerHandler("ready")}},bindReady:function(){if(!xa){xa=true;if(s.readyState==="complete")return c.ready();if(s.addEventListener){s.addEventListener("DOMContentLoaded",
L,false);A.addEventListener("load",c.ready,false)}else if(s.attachEvent){s.attachEvent("onreadystatechange",L);A.attachEvent("onload",c.ready);var a=false;try{a=A.frameElement==null}catch(b){}s.documentElement.doScroll&&a&&ma()}}},isFunction:function(a){return $.call(a)==="[object Function]"},isArray:function(a){return $.call(a)==="[object Array]"},isPlainObject:function(a){if(!a||$.call(a)!=="[object Object]"||a.nodeType||a.setInterval)return false;if(a.constructor&&!aa.call(a,"constructor")&&!aa.call(a.constructor.prototype,
"isPrototypeOf"))return false;var b;for(b in a);return b===w||aa.call(a,b)},isEmptyObject:function(a){for(var b in a)return false;return true},error:function(a){throw a;},parseJSON:function(a){if(typeof a!=="string"||!a)return null;a=c.trim(a);if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return A.JSON&&A.JSON.parse?A.JSON.parse(a):(new Function("return "+
a))();else c.error("Invalid JSON: "+a)},noop:function(){},globalEval:function(a){if(a&&Va.test(a)){var b=s.getElementsByTagName("head")[0]||s.documentElement,d=s.createElement("script");d.type="text/javascript";if(c.support.scriptEval)d.appendChild(s.createTextNode(a));else d.text=a;b.insertBefore(d,b.firstChild);b.removeChild(d)}},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,b,d){var f,e=0,j=a.length,i=j===w||c.isFunction(a);if(d)if(i)for(f in a){if(b.apply(a[f],
d)===false)break}else for(;e<j;){if(b.apply(a[e++],d)===false)break}else if(i)for(f in a){if(b.call(a[f],f,a[f])===false)break}else for(d=a[0];e<j&&b.call(d,e,d)!==false;d=a[++e]);return a},trim:function(a){return(a||"").replace(Wa,"")},makeArray:function(a,b){b=b||[];if(a!=null)a.length==null||typeof a==="string"||c.isFunction(a)||typeof a!=="function"&&a.setInterval?ba.call(b,a):c.merge(b,a);return b},inArray:function(a,b){if(b.indexOf)return b.indexOf(a);for(var d=0,f=b.length;d<f;d++)if(b[d]===
a)return d;return-1},merge:function(a,b){var d=a.length,f=0;if(typeof b.length==="number")for(var e=b.length;f<e;f++)a[d++]=b[f];else for(;b[f]!==w;)a[d++]=b[f++];a.length=d;return a},grep:function(a,b,d){for(var f=[],e=0,j=a.length;e<j;e++)!d!==!b(a[e],e)&&f.push(a[e]);return f},map:function(a,b,d){for(var f=[],e,j=0,i=a.length;j<i;j++){e=b(a[j],j,d);if(e!=null)f[f.length]=e}return f.concat.apply([],f)},guid:1,proxy:function(a,b,d){if(arguments.length===2)if(typeof b==="string"){d=a;a=d[b];b=w}else if(b&&
!c.isFunction(b)){d=b;b=w}if(!b&&a)b=function(){return a.apply(d||this,arguments)};if(a)b.guid=a.guid=a.guid||b.guid||c.guid++;return b},uaMatch:function(a){a=a.toLowerCase();a=/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version)?[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||!/compatible/.test(a)&&/(mozilla)(?:.*? rv:([\w.]+))?/.exec(a)||[];return{browser:a[1]||"",version:a[2]||"0"}},browser:{}});P=c.uaMatch(P);if(P.browser){c.browser[P.browser]=true;c.browser.version=P.version}if(c.browser.webkit)c.browser.safari=
true;if(ya)c.inArray=function(a,b){return ya.call(b,a)};T=c(s);if(s.addEventListener)L=function(){s.removeEventListener("DOMContentLoaded",L,false);c.ready()};else if(s.attachEvent)L=function(){if(s.readyState==="complete"){s.detachEvent("onreadystatechange",L);c.ready()}};(function(){c.support={};var a=s.documentElement,b=s.createElement("script"),d=s.createElement("div"),f="script"+J();d.style.display="none";d.innerHTML="   <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>";
var e=d.getElementsByTagName("*"),j=d.getElementsByTagName("a")[0];if(!(!e||!e.length||!j)){c.support={leadingWhitespace:d.firstChild.nodeType===3,tbody:!d.getElementsByTagName("tbody").length,htmlSerialize:!!d.getElementsByTagName("link").length,style:/red/.test(j.getAttribute("style")),hrefNormalized:j.getAttribute("href")==="/a",opacity:/^0.55$/.test(j.style.opacity),cssFloat:!!j.style.cssFloat,checkOn:d.getElementsByTagName("input")[0].value==="on",optSelected:s.createElement("select").appendChild(s.createElement("option")).selected,
parentNode:d.removeChild(d.appendChild(s.createElement("div"))).parentNode===null,deleteExpando:true,checkClone:false,scriptEval:false,noCloneEvent:true,boxModel:null};b.type="text/javascript";try{b.appendChild(s.createTextNode("window."+f+"=1;"))}catch(i){}a.insertBefore(b,a.firstChild);if(A[f]){c.support.scriptEval=true;delete A[f]}try{delete b.test}catch(o){c.support.deleteExpando=false}a.removeChild(b);if(d.attachEvent&&d.fireEvent){d.attachEvent("onclick",function k(){c.support.noCloneEvent=
false;d.detachEvent("onclick",k)});d.cloneNode(true).fireEvent("onclick")}d=s.createElement("div");d.innerHTML="<input type='radio' name='radiotest' checked='checked'/>";a=s.createDocumentFragment();a.appendChild(d.firstChild);c.support.checkClone=a.cloneNode(true).cloneNode(true).lastChild.checked;c(function(){var k=s.createElement("div");k.style.width=k.style.paddingLeft="1px";s.body.appendChild(k);c.boxModel=c.support.boxModel=k.offsetWidth===2;s.body.removeChild(k).style.display="none"});a=function(k){var n=
s.createElement("div");k="on"+k;var r=k in n;if(!r){n.setAttribute(k,"return;");r=typeof n[k]==="function"}return r};c.support.submitBubbles=a("submit");c.support.changeBubbles=a("change");a=b=d=e=j=null}})();c.props={"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};var G="jQuery"+J(),Ya=0,za={};c.extend({cache:{},expando:G,noData:{embed:true,object:true,
applet:true},data:function(a,b,d){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var f=a[G],e=c.cache;if(!f&&typeof b==="string"&&d===w)return null;f||(f=++Ya);if(typeof b==="object"){a[G]=f;e[f]=c.extend(true,{},b)}else if(!e[f]){a[G]=f;e[f]={}}a=e[f];if(d!==w)a[b]=d;return typeof b==="string"?a[b]:a}},removeData:function(a,b){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var d=a[G],f=c.cache,e=f[d];if(b){if(e){delete e[b];c.isEmptyObject(e)&&c.removeData(a)}}else{if(c.support.deleteExpando)delete a[c.expando];
else a.removeAttribute&&a.removeAttribute(c.expando);delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===w){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===w&&this.length)f=c.data(this[0],a);return f===w&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this,
a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b===
w)return c.queue(this[0],a);return this.each(function(){var d=c.queue(this,a,b);a==="fx"&&d[0]!=="inprogress"&&c.dequeue(this,a)})},dequeue:function(a){return this.each(function(){c.dequeue(this,a)})},delay:function(a,b){a=c.fx?c.fx.speeds[a]||a:a;b=b||"fx";return this.queue(b,function(){var d=this;setTimeout(function(){c.dequeue(d,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])}});var Aa=/[\n\t]/g,ca=/\s+/,Za=/\r/g,$a=/href|src|style/,ab=/(button|input)/i,bb=/(button|input|object|select|textarea)/i,
cb=/^(a|area)$/i,Ba=/radio|checkbox/;c.fn.extend({attr:function(a,b){return X(this,a,b,true,c.attr)},removeAttr:function(a){return this.each(function(){c.attr(this,a,"");this.nodeType===1&&this.removeAttribute(a)})},addClass:function(a){if(c.isFunction(a))return this.each(function(n){var r=c(this);r.addClass(a.call(this,n,r.attr("class")))});if(a&&typeof a==="string")for(var b=(a||"").split(ca),d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1)if(e.className){for(var j=" "+e.className+" ",
i=e.className,o=0,k=b.length;o<k;o++)if(j.indexOf(" "+b[o]+" ")<0)i+=" "+b[o];e.className=c.trim(i)}else e.className=a}return this},removeClass:function(a){if(c.isFunction(a))return this.each(function(k){var n=c(this);n.removeClass(a.call(this,k,n.attr("class")))});if(a&&typeof a==="string"||a===w)for(var b=(a||"").split(ca),d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1&&e.className)if(a){for(var j=(" "+e.className+" ").replace(Aa," "),i=0,o=b.length;i<o;i++)j=j.replace(" "+b[i]+" ",
" ");e.className=c.trim(j)}else e.className=""}return this},toggleClass:function(a,b){var d=typeof a,f=typeof b==="boolean";if(c.isFunction(a))return this.each(function(e){var j=c(this);j.toggleClass(a.call(this,e,j.attr("class"),b),b)});return this.each(function(){if(d==="string")for(var e,j=0,i=c(this),o=b,k=a.split(ca);e=k[j++];){o=f?o:!i.hasClass(e);i[o?"addClass":"removeClass"](e)}else if(d==="undefined"||d==="boolean"){this.className&&c.data(this,"__className__",this.className);this.className=
this.className||a===false?"":c.data(this,"__className__")||""}})},hasClass:function(a){a=" "+a+" ";for(var b=0,d=this.length;b<d;b++)if((" "+this[b].className+" ").replace(Aa," ").indexOf(a)>-1)return true;return false},val:function(a){if(a===w){var b=this[0];if(b){if(c.nodeName(b,"option"))return(b.attributes.value||{}).specified?b.value:b.text;if(c.nodeName(b,"select")){var d=b.selectedIndex,f=[],e=b.options;b=b.type==="select-one";if(d<0)return null;var j=b?d:0;for(d=b?d+1:e.length;j<d;j++){var i=
e[j];if(i.selected){a=c(i).val();if(b)return a;f.push(a)}}return f}if(Ba.test(b.type)&&!c.support.checkOn)return b.getAttribute("value")===null?"on":b.value;return(b.value||"").replace(Za,"")}return w}var o=c.isFunction(a);return this.each(function(k){var n=c(this),r=a;if(this.nodeType===1){if(o)r=a.call(this,k,n.val());if(typeof r==="number")r+="";if(c.isArray(r)&&Ba.test(this.type))this.checked=c.inArray(n.val(),r)>=0;else if(c.nodeName(this,"select")){var u=c.makeArray(r);c("option",this).each(function(){this.selected=
c.inArray(c(this).val(),u)>=0});if(!u.length)this.selectedIndex=-1}else this.value=r}})}});c.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(a,b,d,f){if(!a||a.nodeType===3||a.nodeType===8)return w;if(f&&b in c.attrFn)return c(a)[b](d);f=a.nodeType!==1||!c.isXMLDoc(a);var e=d!==w;b=f&&c.props[b]||b;if(a.nodeType===1){var j=$a.test(b);if(b in a&&f&&!j){if(e){b==="type"&&ab.test(a.nodeName)&&a.parentNode&&c.error("type property can't be changed");
a[b]=d}if(c.nodeName(a,"form")&&a.getAttributeNode(b))return a.getAttributeNode(b).nodeValue;if(b==="tabIndex")return(b=a.getAttributeNode("tabIndex"))&&b.specified?b.value:bb.test(a.nodeName)||cb.test(a.nodeName)&&a.href?0:w;return a[b]}if(!c.support.style&&f&&b==="style"){if(e)a.style.cssText=""+d;return a.style.cssText}e&&a.setAttribute(b,""+d);a=!c.support.hrefNormalized&&f&&j?a.getAttribute(b,2):a.getAttribute(b);return a===null?w:a}return c.style(a,b,d)}});var O=/\.(.*)$/,db=function(a){return a.replace(/[^\w\s\.\|`]/g,
function(b){return"\\"+b})};c.event={add:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){if(a.setInterval&&a!==A&&!a.frameElement)a=A;var e,j;if(d.handler){e=d;d=e.handler}if(!d.guid)d.guid=c.guid++;if(j=c.data(a)){var i=j.events=j.events||{},o=j.handle;if(!o)j.handle=o=function(){return typeof c!=="undefined"&&!c.event.triggered?c.event.handle.apply(o.elem,arguments):w};o.elem=a;b=b.split(" ");for(var k,n=0,r;k=b[n++];){j=e?c.extend({},e):{handler:d,data:f};if(k.indexOf(".")>-1){r=k.split(".");
k=r.shift();j.namespace=r.slice(0).sort().join(".")}else{r=[];j.namespace=""}j.type=k;j.guid=d.guid;var u=i[k],z=c.event.special[k]||{};if(!u){u=i[k]=[];if(!z.setup||z.setup.call(a,f,r,o)===false)if(a.addEventListener)a.addEventListener(k,o,false);else a.attachEvent&&a.attachEvent("on"+k,o)}if(z.add){z.add.call(a,j);if(!j.handler.guid)j.handler.guid=d.guid}u.push(j);c.event.global[k]=true}a=null}}},global:{},remove:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){var e,j=0,i,o,k,n,r,u,z=c.data(a),
C=z&&z.events;if(z&&C){if(b&&b.type){d=b.handler;b=b.type}if(!b||typeof b==="string"&&b.charAt(0)==="."){b=b||"";for(e in C)c.event.remove(a,e+b)}else{for(b=b.split(" ");e=b[j++];){n=e;i=e.indexOf(".")<0;o=[];if(!i){o=e.split(".");e=o.shift();k=new RegExp("(^|\\.)"+c.map(o.slice(0).sort(),db).join("\\.(?:.*\\.)?")+"(\\.|$)")}if(r=C[e])if(d){n=c.event.special[e]||{};for(B=f||0;B<r.length;B++){u=r[B];if(d.guid===u.guid){if(i||k.test(u.namespace)){f==null&&r.splice(B--,1);n.remove&&n.remove.call(a,u)}if(f!=
null)break}}if(r.length===0||f!=null&&r.length===1){if(!n.teardown||n.teardown.call(a,o)===false)Ca(a,e,z.handle);delete C[e]}}else for(var B=0;B<r.length;B++){u=r[B];if(i||k.test(u.namespace)){c.event.remove(a,n,u.handler,B);r.splice(B--,1)}}}if(c.isEmptyObject(C)){if(b=z.handle)b.elem=null;delete z.events;delete z.handle;c.isEmptyObject(z)&&c.removeData(a)}}}}},trigger:function(a,b,d,f){var e=a.type||a;if(!f){a=typeof a==="object"?a[G]?a:c.extend(c.Event(e),a):c.Event(e);if(e.indexOf("!")>=0){a.type=
e=e.slice(0,-1);a.exclusive=true}if(!d){a.stopPropagation();c.event.global[e]&&c.each(c.cache,function(){this.events&&this.events[e]&&c.event.trigger(a,b,this.handle.elem)})}if(!d||d.nodeType===3||d.nodeType===8)return w;a.result=w;a.target=d;b=c.makeArray(b);b.unshift(a)}a.currentTarget=d;(f=c.data(d,"handle"))&&f.apply(d,b);f=d.parentNode||d.ownerDocument;try{if(!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()]))if(d["on"+e]&&d["on"+e].apply(d,b)===false)a.result=false}catch(j){}if(!a.isPropagationStopped()&&
f)c.event.trigger(a,b,f,true);else if(!a.isDefaultPrevented()){f=a.target;var i,o=c.nodeName(f,"a")&&e==="click",k=c.event.special[e]||{};if((!k._default||k._default.call(d,a)===false)&&!o&&!(f&&f.nodeName&&c.noData[f.nodeName.toLowerCase()])){try{if(f[e]){if(i=f["on"+e])f["on"+e]=null;c.event.triggered=true;f[e]()}}catch(n){}if(i)f["on"+e]=i;c.event.triggered=false}}},handle:function(a){var b,d,f,e;a=arguments[0]=c.event.fix(a||A.event);a.currentTarget=this;b=a.type.indexOf(".")<0&&!a.exclusive;
if(!b){d=a.type.split(".");a.type=d.shift();f=new RegExp("(^|\\.)"+d.slice(0).sort().join("\\.(?:.*\\.)?")+"(\\.|$)")}e=c.data(this,"events");d=e[a.type];if(e&&d){d=d.slice(0);e=0;for(var j=d.length;e<j;e++){var i=d[e];if(b||f.test(i.namespace)){a.handler=i.handler;a.data=i.data;a.handleObj=i;i=i.handler.apply(this,arguments);if(i!==w){a.result=i;if(i===false){a.preventDefault();a.stopPropagation()}}if(a.isImmediatePropagationStopped())break}}}return a.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),
fix:function(a){if(a[G])return a;var b=a;a=c.Event(b);for(var d=this.props.length,f;d;){f=this.props[--d];a[f]=b[f]}if(!a.target)a.target=a.srcElement||s;if(a.target.nodeType===3)a.target=a.target.parentNode;if(!a.relatedTarget&&a.fromElement)a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement;if(a.pageX==null&&a.clientX!=null){b=s.documentElement;d=s.body;a.pageX=a.clientX+(b&&b.scrollLeft||d&&d.scrollLeft||0)-(b&&b.clientLeft||d&&d.clientLeft||0);a.pageY=a.clientY+(b&&b.scrollTop||
d&&d.scrollTop||0)-(b&&b.clientTop||d&&d.clientTop||0)}if(!a.which&&(a.charCode||a.charCode===0?a.charCode:a.keyCode))a.which=a.charCode||a.keyCode;if(!a.metaKey&&a.ctrlKey)a.metaKey=a.ctrlKey;if(!a.which&&a.button!==w)a.which=a.button&1?1:a.button&2?3:a.button&4?2:0;return a},guid:1E8,proxy:c.proxy,special:{ready:{setup:c.bindReady,teardown:c.noop},live:{add:function(a){c.event.add(this,a.origType,c.extend({},a,{handler:oa}))},remove:function(a){var b=true,d=a.origType.replace(O,"");c.each(c.data(this,
"events").live||[],function(){if(d===this.origType.replace(O,""))return b=false});b&&c.event.remove(this,a.origType,oa)}},beforeunload:{setup:function(a,b,d){if(this.setInterval)this.onbeforeunload=d;return false},teardown:function(a,b){if(this.onbeforeunload===b)this.onbeforeunload=null}}}};var Ca=s.removeEventListener?function(a,b,d){a.removeEventListener(b,d,false)}:function(a,b,d){a.detachEvent("on"+b,d)};c.Event=function(a){if(!this.preventDefault)return new c.Event(a);if(a&&a.type){this.originalEvent=
a;this.type=a.type}else this.type=a;this.timeStamp=J();this[G]=true};c.Event.prototype={preventDefault:function(){this.isDefaultPrevented=Z;var a=this.originalEvent;if(a){a.preventDefault&&a.preventDefault();a.returnValue=false}},stopPropagation:function(){this.isPropagationStopped=Z;var a=this.originalEvent;if(a){a.stopPropagation&&a.stopPropagation();a.cancelBubble=true}},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=Z;this.stopPropagation()},isDefaultPrevented:Y,isPropagationStopped:Y,
isImmediatePropagationStopped:Y};var Da=function(a){var b=a.relatedTarget;try{for(;b&&b!==this;)b=b.parentNode;if(b!==this){a.type=a.data;c.event.handle.apply(this,arguments)}}catch(d){}},Ea=function(a){a.type=a.data;c.event.handle.apply(this,arguments)};c.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){c.event.special[a]={setup:function(d){c.event.add(this,b,d&&d.selector?Ea:Da,a)},teardown:function(d){c.event.remove(this,b,d&&d.selector?Ea:Da)}}});if(!c.support.submitBubbles)c.event.special.submit=
{setup:function(){if(this.nodeName.toLowerCase()!=="form"){c.event.add(this,"click.specialSubmit",function(a){var b=a.target,d=b.type;if((d==="submit"||d==="image")&&c(b).closest("form").length)return na("submit",this,arguments)});c.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,d=b.type;if((d==="text"||d==="password")&&c(b).closest("form").length&&a.keyCode===13)return na("submit",this,arguments)})}else return false},teardown:function(){c.event.remove(this,".specialSubmit")}};
if(!c.support.changeBubbles){var da=/textarea|input|select/i,ea,Fa=function(a){var b=a.type,d=a.value;if(b==="radio"||b==="checkbox")d=a.checked;else if(b==="select-multiple")d=a.selectedIndex>-1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d},fa=function(a,b){var d=a.target,f,e;if(!(!da.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Fa(d);if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data",
e);if(!(f===w||e===f))if(f!=null||e){a.type="change";return c.event.trigger(a,b,d)}}};c.event.special.change={filters:{focusout:fa,click:function(a){var b=a.target,d=b.type;if(d==="radio"||d==="checkbox"||b.nodeName.toLowerCase()==="select")return fa.call(this,a)},keydown:function(a){var b=a.target,d=b.type;if(a.keyCode===13&&b.nodeName.toLowerCase()!=="textarea"||a.keyCode===32&&(d==="checkbox"||d==="radio")||d==="select-multiple")return fa.call(this,a)},beforeactivate:function(a){a=a.target;c.data(a,
"_change_data",Fa(a))}},setup:function(){if(this.type==="file")return false;for(var a in ea)c.event.add(this,a+".specialChange",ea[a]);return da.test(this.nodeName)},teardown:function(){c.event.remove(this,".specialChange");return da.test(this.nodeName)}};ea=c.event.special.change.filters}s.addEventListener&&c.each({focus:"focusin",blur:"focusout"},function(a,b){function d(f){f=c.event.fix(f);f.type=b;return c.event.handle.call(this,f)}c.event.special[b]={setup:function(){this.addEventListener(a,
d,true)},teardown:function(){this.removeEventListener(a,d,true)}}});c.each(["bind","one"],function(a,b){c.fn[b]=function(d,f,e){if(typeof d==="object"){for(var j in d)this[b](j,f,d[j],e);return this}if(c.isFunction(f)){e=f;f=w}var i=b==="one"?c.proxy(e,function(k){c(this).unbind(k,i);return e.apply(this,arguments)}):e;if(d==="unload"&&b!=="one")this.one(d,f,e);else{j=0;for(var o=this.length;j<o;j++)c.event.add(this[j],d,i,f)}return this}});c.fn.extend({unbind:function(a,b){if(typeof a==="object"&&
!a.preventDefault)for(var d in a)this.unbind(d,a[d]);else{d=0;for(var f=this.length;d<f;d++)c.event.remove(this[d],a,b)}return this},delegate:function(a,b,d,f){return this.live(b,d,f,a)},undelegate:function(a,b,d){return arguments.length===0?this.unbind("live"):this.die(b,null,d,a)},trigger:function(a,b){return this.each(function(){c.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0]){a=c.Event(a);a.preventDefault();a.stopPropagation();c.event.trigger(a,b,this[0]);return a.result}},
toggle:function(a){for(var b=arguments,d=1;d<b.length;)c.proxy(a,b[d++]);return this.click(c.proxy(a,function(f){var e=(c.data(this,"lastToggle"+a.guid)||0)%d;c.data(this,"lastToggle"+a.guid,e+1);f.preventDefault();return b[e].apply(this,arguments)||false}))},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var Ga={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};c.each(["live","die"],function(a,b){c.fn[b]=function(d,f,e,j){var i,o=0,k,n,r=j||this.selector,
u=j?this:c(this.context);if(c.isFunction(f)){e=f;f=w}for(d=(d||"").split(" ");(i=d[o++])!=null;){j=O.exec(i);k="";if(j){k=j[0];i=i.replace(O,"")}if(i==="hover")d.push("mouseenter"+k,"mouseleave"+k);else{n=i;if(i==="focus"||i==="blur"){d.push(Ga[i]+k);i+=k}else i=(Ga[i]||i)+k;b==="live"?u.each(function(){c.event.add(this,pa(i,r),{data:f,selector:r,handler:e,origType:i,origHandler:e,preType:n})}):u.unbind(pa(i,r),e)}}return this}});c.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error".split(" "),
function(a,b){c.fn[b]=function(d){return d?this.bind(b,d):this.trigger(b)};if(c.attrFn)c.attrFn[b]=true});A.attachEvent&&!A.addEventListener&&A.attachEvent("onunload",function(){for(var a in c.cache)if(c.cache[a].handle)try{c.event.remove(c.cache[a].handle.elem)}catch(b){}});(function(){function a(g){for(var h="",l,m=0;g[m];m++){l=g[m];if(l.nodeType===3||l.nodeType===4)h+=l.nodeValue;else if(l.nodeType!==8)h+=a(l.childNodes)}return h}function b(g,h,l,m,q,p){q=0;for(var v=m.length;q<v;q++){var t=m[q];
if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1&&!p){t.sizcache=l;t.sizset=q}if(t.nodeName.toLowerCase()===h){y=t;break}t=t[g]}m[q]=y}}}function d(g,h,l,m,q,p){q=0;for(var v=m.length;q<v;q++){var t=m[q];if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1){if(!p){t.sizcache=l;t.sizset=q}if(typeof h!=="string"){if(t===h){y=true;break}}else if(k.filter(h,[t]).length>0){y=t;break}}t=t[g]}m[q]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
e=0,j=Object.prototype.toString,i=false,o=true;[0,0].sort(function(){o=false;return 0});var k=function(g,h,l,m){l=l||[];var q=h=h||s;if(h.nodeType!==1&&h.nodeType!==9)return[];if(!g||typeof g!=="string")return l;for(var p=[],v,t,y,S,H=true,M=x(h),I=g;(f.exec(""),v=f.exec(I))!==null;){I=v[3];p.push(v[1]);if(v[2]){S=v[3];break}}if(p.length>1&&r.exec(g))if(p.length===2&&n.relative[p[0]])t=ga(p[0]+p[1],h);else for(t=n.relative[p[0]]?[h]:k(p.shift(),h);p.length;){g=p.shift();if(n.relative[g])g+=p.shift();
t=ga(g,t)}else{if(!m&&p.length>1&&h.nodeType===9&&!M&&n.match.ID.test(p[0])&&!n.match.ID.test(p[p.length-1])){v=k.find(p.shift(),h,M);h=v.expr?k.filter(v.expr,v.set)[0]:v.set[0]}if(h){v=m?{expr:p.pop(),set:z(m)}:k.find(p.pop(),p.length===1&&(p[0]==="~"||p[0]==="+")&&h.parentNode?h.parentNode:h,M);t=v.expr?k.filter(v.expr,v.set):v.set;if(p.length>0)y=z(t);else H=false;for(;p.length;){var D=p.pop();v=D;if(n.relative[D])v=p.pop();else D="";if(v==null)v=h;n.relative[D](y,v,M)}}else y=[]}y||(y=t);y||k.error(D||
g);if(j.call(y)==="[object Array]")if(H)if(h&&h.nodeType===1)for(g=0;y[g]!=null;g++){if(y[g]&&(y[g]===true||y[g].nodeType===1&&E(h,y[g])))l.push(t[g])}else for(g=0;y[g]!=null;g++)y[g]&&y[g].nodeType===1&&l.push(t[g]);else l.push.apply(l,y);else z(y,l);if(S){k(S,q,l,m);k.uniqueSort(l)}return l};k.uniqueSort=function(g){if(B){i=o;g.sort(B);if(i)for(var h=1;h<g.length;h++)g[h]===g[h-1]&&g.splice(h--,1)}return g};k.matches=function(g,h){return k(g,null,null,h)};k.find=function(g,h,l){var m,q;if(!g)return[];
for(var p=0,v=n.order.length;p<v;p++){var t=n.order[p];if(q=n.leftMatch[t].exec(g)){var y=q[1];q.splice(1,1);if(y.substr(y.length-1)!=="\\"){q[1]=(q[1]||"").replace(/\\/g,"");m=n.find[t](q,h,l);if(m!=null){g=g.replace(n.match[t],"");break}}}}m||(m=h.getElementsByTagName("*"));return{set:m,expr:g}};k.filter=function(g,h,l,m){for(var q=g,p=[],v=h,t,y,S=h&&h[0]&&x(h[0]);g&&h.length;){for(var H in n.filter)if((t=n.leftMatch[H].exec(g))!=null&&t[2]){var M=n.filter[H],I,D;D=t[1];y=false;t.splice(1,1);if(D.substr(D.length-
1)!=="\\"){if(v===p)p=[];if(n.preFilter[H])if(t=n.preFilter[H](t,v,l,p,m,S)){if(t===true)continue}else y=I=true;if(t)for(var U=0;(D=v[U])!=null;U++)if(D){I=M(D,t,U,v);var Ha=m^!!I;if(l&&I!=null)if(Ha)y=true;else v[U]=false;else if(Ha){p.push(D);y=true}}if(I!==w){l||(v=p);g=g.replace(n.match[H],"");if(!y)return[];break}}}if(g===q)if(y==null)k.error(g);else break;q=g}return v};k.error=function(g){throw"Syntax error, unrecognized expression: "+g;};var n=k.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF-]|\\.)+)/,
CLASS:/\.((?:[\w\u00c0-\uFFFF-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(g){return g.getAttribute("href")}},
relative:{"+":function(g,h){var l=typeof h==="string",m=l&&!/\W/.test(h);l=l&&!m;if(m)h=h.toLowerCase();m=0;for(var q=g.length,p;m<q;m++)if(p=g[m]){for(;(p=p.previousSibling)&&p.nodeType!==1;);g[m]=l||p&&p.nodeName.toLowerCase()===h?p||false:p===h}l&&k.filter(h,g,true)},">":function(g,h){var l=typeof h==="string";if(l&&!/\W/.test(h)){h=h.toLowerCase();for(var m=0,q=g.length;m<q;m++){var p=g[m];if(p){l=p.parentNode;g[m]=l.nodeName.toLowerCase()===h?l:false}}}else{m=0;for(q=g.length;m<q;m++)if(p=g[m])g[m]=
l?p.parentNode:p.parentNode===h;l&&k.filter(h,g,true)}},"":function(g,h,l){var m=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=h=h.toLowerCase();q=b}q("parentNode",h,m,g,p,l)},"~":function(g,h,l){var m=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=h=h.toLowerCase();q=b}q("previousSibling",h,m,g,p,l)}},find:{ID:function(g,h,l){if(typeof h.getElementById!=="undefined"&&!l)return(g=h.getElementById(g[1]))?[g]:[]},NAME:function(g,h){if(typeof h.getElementsByName!=="undefined"){var l=[];
h=h.getElementsByName(g[1]);for(var m=0,q=h.length;m<q;m++)h[m].getAttribute("name")===g[1]&&l.push(h[m]);return l.length===0?null:l}},TAG:function(g,h){return h.getElementsByTagName(g[1])}},preFilter:{CLASS:function(g,h,l,m,q,p){g=" "+g[1].replace(/\\/g,"")+" ";if(p)return g;p=0;for(var v;(v=h[p])!=null;p++)if(v)if(q^(v.className&&(" "+v.className+" ").replace(/[\t\n]/g," ").indexOf(g)>=0))l||m.push(v);else if(l)h[p]=false;return false},ID:function(g){return g[1].replace(/\\/g,"")},TAG:function(g){return g[1].toLowerCase()},
CHILD:function(g){if(g[1]==="nth"){var h=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(g[2]==="even"&&"2n"||g[2]==="odd"&&"2n+1"||!/\D/.test(g[2])&&"0n+"+g[2]||g[2]);g[2]=h[1]+(h[2]||1)-0;g[3]=h[3]-0}g[0]=e++;return g},ATTR:function(g,h,l,m,q,p){h=g[1].replace(/\\/g,"");if(!p&&n.attrMap[h])g[1]=n.attrMap[h];if(g[2]==="~=")g[4]=" "+g[4]+" ";return g},PSEUDO:function(g,h,l,m,q){if(g[1]==="not")if((f.exec(g[3])||"").length>1||/^\w/.test(g[3]))g[3]=k(g[3],null,null,h);else{g=k.filter(g[3],h,l,true^q);l||m.push.apply(m,
g);return false}else if(n.match.POS.test(g[0])||n.match.CHILD.test(g[0]))return true;return g},POS:function(g){g.unshift(true);return g}},filters:{enabled:function(g){return g.disabled===false&&g.type!=="hidden"},disabled:function(g){return g.disabled===true},checked:function(g){return g.checked===true},selected:function(g){return g.selected===true},parent:function(g){return!!g.firstChild},empty:function(g){return!g.firstChild},has:function(g,h,l){return!!k(l[3],g).length},header:function(g){return/h\d/i.test(g.nodeName)},
text:function(g){return"text"===g.type},radio:function(g){return"radio"===g.type},checkbox:function(g){return"checkbox"===g.type},file:function(g){return"file"===g.type},password:function(g){return"password"===g.type},submit:function(g){return"submit"===g.type},image:function(g){return"image"===g.type},reset:function(g){return"reset"===g.type},button:function(g){return"button"===g.type||g.nodeName.toLowerCase()==="button"},input:function(g){return/input|select|textarea|button/i.test(g.nodeName)}},
setFilters:{first:function(g,h){return h===0},last:function(g,h,l,m){return h===m.length-1},even:function(g,h){return h%2===0},odd:function(g,h){return h%2===1},lt:function(g,h,l){return h<l[3]-0},gt:function(g,h,l){return h>l[3]-0},nth:function(g,h,l){return l[3]-0===h},eq:function(g,h,l){return l[3]-0===h}},filter:{PSEUDO:function(g,h,l,m){var q=h[1],p=n.filters[q];if(p)return p(g,l,h,m);else if(q==="contains")return(g.textContent||g.innerText||a([g])||"").indexOf(h[3])>=0;else if(q==="not"){h=
h[3];l=0;for(m=h.length;l<m;l++)if(h[l]===g)return false;return true}else k.error("Syntax error, unrecognized expression: "+q)},CHILD:function(g,h){var l=h[1],m=g;switch(l){case "only":case "first":for(;m=m.previousSibling;)if(m.nodeType===1)return false;if(l==="first")return true;m=g;case "last":for(;m=m.nextSibling;)if(m.nodeType===1)return false;return true;case "nth":l=h[2];var q=h[3];if(l===1&&q===0)return true;h=h[0];var p=g.parentNode;if(p&&(p.sizcache!==h||!g.nodeIndex)){var v=0;for(m=p.firstChild;m;m=
m.nextSibling)if(m.nodeType===1)m.nodeIndex=++v;p.sizcache=h}g=g.nodeIndex-q;return l===0?g===0:g%l===0&&g/l>=0}},ID:function(g,h){return g.nodeType===1&&g.getAttribute("id")===h},TAG:function(g,h){return h==="*"&&g.nodeType===1||g.nodeName.toLowerCase()===h},CLASS:function(g,h){return(" "+(g.className||g.getAttribute("class"))+" ").indexOf(h)>-1},ATTR:function(g,h){var l=h[1];g=n.attrHandle[l]?n.attrHandle[l](g):g[l]!=null?g[l]:g.getAttribute(l);l=g+"";var m=h[2];h=h[4];return g==null?m==="!=":m===
"="?l===h:m==="*="?l.indexOf(h)>=0:m==="~="?(" "+l+" ").indexOf(h)>=0:!h?l&&g!==false:m==="!="?l!==h:m==="^="?l.indexOf(h)===0:m==="$="?l.substr(l.length-h.length)===h:m==="|="?l===h||l.substr(0,h.length+1)===h+"-":false},POS:function(g,h,l,m){var q=n.setFilters[h[2]];if(q)return q(g,l,h,m)}}},r=n.match.POS;for(var u in n.match){n.match[u]=new RegExp(n.match[u].source+/(?![^\[]*\])(?![^\(]*\))/.source);n.leftMatch[u]=new RegExp(/(^(?:.|\r|\n)*?)/.source+n.match[u].source.replace(/\\(\d+)/g,function(g,
h){return"\\"+(h-0+1)}))}var z=function(g,h){g=Array.prototype.slice.call(g,0);if(h){h.push.apply(h,g);return h}return g};try{Array.prototype.slice.call(s.documentElement.childNodes,0)}catch(C){z=function(g,h){h=h||[];if(j.call(g)==="[object Array]")Array.prototype.push.apply(h,g);else if(typeof g.length==="number")for(var l=0,m=g.length;l<m;l++)h.push(g[l]);else for(l=0;g[l];l++)h.push(g[l]);return h}}var B;if(s.documentElement.compareDocumentPosition)B=function(g,h){if(!g.compareDocumentPosition||
!h.compareDocumentPosition){if(g==h)i=true;return g.compareDocumentPosition?-1:1}g=g.compareDocumentPosition(h)&4?-1:g===h?0:1;if(g===0)i=true;return g};else if("sourceIndex"in s.documentElement)B=function(g,h){if(!g.sourceIndex||!h.sourceIndex){if(g==h)i=true;return g.sourceIndex?-1:1}g=g.sourceIndex-h.sourceIndex;if(g===0)i=true;return g};else if(s.createRange)B=function(g,h){if(!g.ownerDocument||!h.ownerDocument){if(g==h)i=true;return g.ownerDocument?-1:1}var l=g.ownerDocument.createRange(),m=
h.ownerDocument.createRange();l.setStart(g,0);l.setEnd(g,0);m.setStart(h,0);m.setEnd(h,0);g=l.compareBoundaryPoints(Range.START_TO_END,m);if(g===0)i=true;return g};(function(){var g=s.createElement("div"),h="script"+(new Date).getTime();g.innerHTML="<a name='"+h+"'/>";var l=s.documentElement;l.insertBefore(g,l.firstChild);if(s.getElementById(h)){n.find.ID=function(m,q,p){if(typeof q.getElementById!=="undefined"&&!p)return(q=q.getElementById(m[1]))?q.id===m[1]||typeof q.getAttributeNode!=="undefined"&&
q.getAttributeNode("id").nodeValue===m[1]?[q]:w:[]};n.filter.ID=function(m,q){var p=typeof m.getAttributeNode!=="undefined"&&m.getAttributeNode("id");return m.nodeType===1&&p&&p.nodeValue===q}}l.removeChild(g);l=g=null})();(function(){var g=s.createElement("div");g.appendChild(s.createComment(""));if(g.getElementsByTagName("*").length>0)n.find.TAG=function(h,l){l=l.getElementsByTagName(h[1]);if(h[1]==="*"){h=[];for(var m=0;l[m];m++)l[m].nodeType===1&&h.push(l[m]);l=h}return l};g.innerHTML="<a href='#'></a>";
if(g.firstChild&&typeof g.firstChild.getAttribute!=="undefined"&&g.firstChild.getAttribute("href")!=="#")n.attrHandle.href=function(h){return h.getAttribute("href",2)};g=null})();s.querySelectorAll&&function(){var g=k,h=s.createElement("div");h.innerHTML="<p class='TEST'></p>";if(!(h.querySelectorAll&&h.querySelectorAll(".TEST").length===0)){k=function(m,q,p,v){q=q||s;if(!v&&q.nodeType===9&&!x(q))try{return z(q.querySelectorAll(m),p)}catch(t){}return g(m,q,p,v)};for(var l in g)k[l]=g[l];h=null}}();
(function(){var g=s.createElement("div");g.innerHTML="<div class='test e'></div><div class='test'></div>";if(!(!g.getElementsByClassName||g.getElementsByClassName("e").length===0)){g.lastChild.className="e";if(g.getElementsByClassName("e").length!==1){n.order.splice(1,0,"CLASS");n.find.CLASS=function(h,l,m){if(typeof l.getElementsByClassName!=="undefined"&&!m)return l.getElementsByClassName(h[1])};g=null}}})();var E=s.compareDocumentPosition?function(g,h){return!!(g.compareDocumentPosition(h)&16)}:
function(g,h){return g!==h&&(g.contains?g.contains(h):true)},x=function(g){return(g=(g?g.ownerDocument||g:0).documentElement)?g.nodeName!=="HTML":false},ga=function(g,h){var l=[],m="",q;for(h=h.nodeType?[h]:h;q=n.match.PSEUDO.exec(g);){m+=q[0];g=g.replace(n.match.PSEUDO,"")}g=n.relative[g]?g+"*":g;q=0;for(var p=h.length;q<p;q++)k(g,h[q],l);return k.filter(m,l)};c.find=k;c.expr=k.selectors;c.expr[":"]=c.expr.filters;c.unique=k.uniqueSort;c.text=a;c.isXMLDoc=x;c.contains=E})();var eb=/Until$/,fb=/^(?:parents|prevUntil|prevAll)/,
gb=/,/;R=Array.prototype.slice;var Ia=function(a,b,d){if(c.isFunction(b))return c.grep(a,function(e,j){return!!b.call(e,j,e)===d});else if(b.nodeType)return c.grep(a,function(e){return e===b===d});else if(typeof b==="string"){var f=c.grep(a,function(e){return e.nodeType===1});if(Ua.test(b))return c.filter(b,f,!d);else b=c.filter(b,f)}return c.grep(a,function(e){return c.inArray(e,b)>=0===d})};c.fn.extend({find:function(a){for(var b=this.pushStack("","find",a),d=0,f=0,e=this.length;f<e;f++){d=b.length;
c.find(a,this[f],b);if(f>0)for(var j=d;j<b.length;j++)for(var i=0;i<d;i++)if(b[i]===b[j]){b.splice(j--,1);break}}return b},has:function(a){var b=c(a);return this.filter(function(){for(var d=0,f=b.length;d<f;d++)if(c.contains(this,b[d]))return true})},not:function(a){return this.pushStack(Ia(this,a,false),"not",a)},filter:function(a){return this.pushStack(Ia(this,a,true),"filter",a)},is:function(a){return!!a&&c.filter(a,this).length>0},closest:function(a,b){if(c.isArray(a)){var d=[],f=this[0],e,j=
{},i;if(f&&a.length){e=0;for(var o=a.length;e<o;e++){i=a[e];j[i]||(j[i]=c.expr.match.POS.test(i)?c(i,b||this.context):i)}for(;f&&f.ownerDocument&&f!==b;){for(i in j){e=j[i];if(e.jquery?e.index(f)>-1:c(f).is(e)){d.push({selector:i,elem:f});delete j[i]}}f=f.parentNode}}return d}var k=c.expr.match.POS.test(a)?c(a,b||this.context):null;return this.map(function(n,r){for(;r&&r.ownerDocument&&r!==b;){if(k?k.index(r)>-1:c(r).is(a))return r;r=r.parentNode}return null})},index:function(a){if(!a||typeof a===
"string")return c.inArray(this[0],a?c(a):this.parent().children());return c.inArray(a.jquery?a[0]:a,this)},add:function(a,b){a=typeof a==="string"?c(a,b||this.context):c.makeArray(a);b=c.merge(this.get(),a);return this.pushStack(qa(a[0])||qa(b[0])?b:c.unique(b))},andSelf:function(){return this.add(this.prevObject)}});c.each({parent:function(a){return(a=a.parentNode)&&a.nodeType!==11?a:null},parents:function(a){return c.dir(a,"parentNode")},parentsUntil:function(a,b,d){return c.dir(a,"parentNode",
d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previousSibling",d)},siblings:function(a){return c.sibling(a.parentNode.firstChild,a)},children:function(a){return c.sibling(a.firstChild)},contents:function(a){return c.nodeName(a,"iframe")?
a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);eb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||gb.test(f))&&fb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||a.nodeType!==1||!c(a).is(d));){a.nodeType===
1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ja=/ jQuery\d+="(?:\d+|null)"/g,V=/^\s+/,Ka=/(<([\w:]+)[^>]*?)\/>/g,hb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,La=/<([\w:]+)/,ib=/<tbody/i,jb=/<|&#?\w+;/,ta=/<script|<object|<embed|<option|<style/i,ua=/checked\s*(?:[^=]|=\s*.checked.)/i,Ma=function(a,b,d){return hb.test(d)?
a:b+"></"+d+">"},F={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]};F.optgroup=F.option;F.tbody=F.tfoot=F.colgroup=F.caption=F.thead;F.th=F.td;if(!c.support.htmlSerialize)F._default=[1,"div<div>","</div>"];c.fn.extend({text:function(a){if(c.isFunction(a))return this.each(function(b){var d=
c(this);d.text(a.call(this,b,d.text()))});if(typeof a!=="object"&&a!==w)return this.empty().append((this[0]&&this[0].ownerDocument||s).createTextNode(a));return c.text(this)},wrapAll:function(a){if(c.isFunction(a))return this.each(function(d){c(this).wrapAll(a.call(this,d))});if(this[0]){var b=c(a,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var d=this;d.firstChild&&d.firstChild.nodeType===1;)d=d.firstChild;return d}).append(this)}return this},
wrapInner:function(a){if(c.isFunction(a))return this.each(function(b){c(this).wrapInner(a.call(this,b))});return this.each(function(){var b=c(this),d=b.contents();d.length?d.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){c(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){c.nodeName(this,"body")||c(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.appendChild(a)})},
prepend:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this)});else if(arguments.length){var a=c(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,
this.nextSibling)});else if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,c(arguments[0]).toArray());return a}},remove:function(a,b){for(var d=0,f;(f=this[d])!=null;d++)if(!a||c.filter(a,[f]).length){if(!b&&f.nodeType===1){c.cleanData(f.getElementsByTagName("*"));c.cleanData([f])}f.parentNode&&f.parentNode.removeChild(f)}return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++)for(b.nodeType===1&&c.cleanData(b.getElementsByTagName("*"));b.firstChild;)b.removeChild(b.firstChild);
return this},clone:function(a){var b=this.map(function(){if(!c.support.noCloneEvent&&!c.isXMLDoc(this)){var d=this.outerHTML,f=this.ownerDocument;if(!d){d=f.createElement("div");d.appendChild(this.cloneNode(true));d=d.innerHTML}return c.clean([d.replace(Ja,"").replace(/=([^="'>\s]+\/)>/g,'="$1">').replace(V,"")],f)[0]}else return this.cloneNode(true)});if(a===true){ra(this,b);ra(this.find("*"),b.find("*"))}return b},html:function(a){if(a===w)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Ja,
""):null;else if(typeof a==="string"&&!ta.test(a)&&(c.support.leadingWhitespace||!V.test(a))&&!F[(La.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Ka,Ma);try{for(var b=0,d=this.length;b<d;b++)if(this[b].nodeType===1){c.cleanData(this[b].getElementsByTagName("*"));this[b].innerHTML=a}}catch(f){this.empty().append(a)}}else c.isFunction(a)?this.each(function(e){var j=c(this),i=j.html();j.empty().append(function(){return a.call(this,e,i)})}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&&
this[0].parentNode){if(c.isFunction(a))return this.each(function(b){var d=c(this),f=d.html();d.replaceWith(a.call(this,b,f))});if(typeof a!=="string")a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(u){return c.nodeName(u,"table")?u.getElementsByTagName("tbody")[0]||
u.appendChild(u.ownerDocument.createElement("tbody")):u}var e,j,i=a[0],o=[],k;if(!c.support.checkClone&&arguments.length===3&&typeof i==="string"&&ua.test(i))return this.each(function(){c(this).domManip(a,b,d,true)});if(c.isFunction(i))return this.each(function(u){var z=c(this);a[0]=i.call(this,u,b?z.html():w);z.domManip(a,b,d)});if(this[0]){e=i&&i.parentNode;e=c.support.parentNode&&e&&e.nodeType===11&&e.childNodes.length===this.length?{fragment:e}:sa(a,this,o);k=e.fragment;if(j=k.childNodes.length===
1?(k=k.firstChild):k.firstChild){b=b&&c.nodeName(j,"tr");for(var n=0,r=this.length;n<r;n++)d.call(b?f(this[n],j):this[n],n>0||e.cacheable||this.length>1?k.cloneNode(true):k)}o.length&&c.each(o,Qa)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var f=[];d=c(d);var e=this.length===1&&this[0].parentNode;if(e&&e.nodeType===11&&e.childNodes.length===1&&d.length===1){d[b](this[0]);
return this}else{e=0;for(var j=d.length;e<j;e++){var i=(e>0?this.clone(true):this).get();c.fn[b].apply(c(d[e]),i);f=f.concat(i)}return this.pushStack(f,a,d.selector)}}});c.extend({clean:function(a,b,d,f){b=b||s;if(typeof b.createElement==="undefined")b=b.ownerDocument||b[0]&&b[0].ownerDocument||s;for(var e=[],j=0,i;(i=a[j])!=null;j++){if(typeof i==="number")i+="";if(i){if(typeof i==="string"&&!jb.test(i))i=b.createTextNode(i);else if(typeof i==="string"){i=i.replace(Ka,Ma);var o=(La.exec(i)||["",
""])[1].toLowerCase(),k=F[o]||F._default,n=k[0],r=b.createElement("div");for(r.innerHTML=k[1]+i+k[2];n--;)r=r.lastChild;if(!c.support.tbody){n=ib.test(i);o=o==="table"&&!n?r.firstChild&&r.firstChild.childNodes:k[1]==="<table>"&&!n?r.childNodes:[];for(k=o.length-1;k>=0;--k)c.nodeName(o[k],"tbody")&&!o[k].childNodes.length&&o[k].parentNode.removeChild(o[k])}!c.support.leadingWhitespace&&V.test(i)&&r.insertBefore(b.createTextNode(V.exec(i)[0]),r.firstChild);i=r.childNodes}if(i.nodeType)e.push(i);else e=
c.merge(e,i)}}if(d)for(j=0;e[j];j++)if(f&&c.nodeName(e[j],"script")&&(!e[j].type||e[j].type.toLowerCase()==="text/javascript"))f.push(e[j].parentNode?e[j].parentNode.removeChild(e[j]):e[j]);else{e[j].nodeType===1&&e.splice.apply(e,[j+1,0].concat(c.makeArray(e[j].getElementsByTagName("script"))));d.appendChild(e[j])}return e},cleanData:function(a){for(var b,d,f=c.cache,e=c.event.special,j=c.support.deleteExpando,i=0,o;(o=a[i])!=null;i++)if(d=o[c.expando]){b=f[d];if(b.events)for(var k in b.events)e[k]?
c.event.remove(o,k):Ca(o,k,b.handle);if(j)delete o[c.expando];else o.removeAttribute&&o.removeAttribute(c.expando);delete f[d]}}});var kb=/z-?index|font-?weight|opacity|zoom|line-?height/i,Na=/alpha\([^)]*\)/,Oa=/opacity=([^)]*)/,ha=/float/i,ia=/-([a-z])/ig,lb=/([A-Z])/g,mb=/^-?\d+(?:px)?$/i,nb=/^-?\d/,ob={position:"absolute",visibility:"hidden",display:"block"},pb=["Left","Right"],qb=["Top","Bottom"],rb=s.defaultView&&s.defaultView.getComputedStyle,Pa=c.support.cssFloat?"cssFloat":"styleFloat",ja=
function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d=w;var f=a.style||a,e=d!==w;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter=
Na.test(a)?a.replace(Na,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Oa.exec(f.filter)[1])/100+"":""}if(ha.test(b))b=Pa;b=b.replace(ia,ja);if(e)f[b]=d;return f[b]},css:function(a,b,d,f){if(b==="width"||b==="height"){var e,j=b==="width"?pb:qb;function i(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(j,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a,
"border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test(b))b=Pa;if(!d&&e&&e[b])f=e[b];else if(rb){if(ha.test(b))b="float";b=b.replace(lb,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f=
a.getPropertyValue(b);if(b==="opacity"&&f==="")f="1"}else if(a.currentStyle){d=b.replace(ia,ja);f=a.currentStyle[b]||a.currentStyle[d];if(!mb.test(f)&&nb.test(f)){b=e.left;var j=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;e.left=d==="fontSize"?"1em":f||0;f=e.pixelLeft+"px";e.left=b;a.runtimeStyle.left=j}}return f},swap:function(a,b,d){var f={};for(var e in b){f[e]=a.style[e];a.style[e]=b[e]}d.call(a);for(e in b)a.style[e]=f[e]}});if(c.expr&&c.expr.filters){c.expr.filters.hidden=function(a){var b=
a.offsetWidth,d=a.offsetHeight,f=a.nodeName.toLowerCase()==="tr";return b===0&&d===0&&!f?true:b>0&&d>0&&!f?false:c.curCSS(a,"display")==="none"};c.expr.filters.visible=function(a){return!c.expr.filters.hidden(a)}}var sb=J(),tb=/<script(.|\s)*?\/script>/gi,ub=/select|textarea/i,vb=/color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i,N=/=\?(&|$)/,ka=/\?/,wb=/(\?|&)_=.*?(&|$)/,xb=/^(\w+:)?\/\/([^\/?#]+)/,yb=/%20/g,zb=c.fn.load;c.fn.extend({load:function(a,b,d){if(typeof a!==
"string")return zb.call(this,a);else if(!this.length)return this;var f=a.indexOf(" ");if(f>=0){var e=a.slice(f,a.length);a=a.slice(0,f)}f="GET";if(b)if(c.isFunction(b)){d=b;b=null}else if(typeof b==="object"){b=c.param(b,c.ajaxSettings.traditional);f="POST"}var j=this;c.ajax({url:a,type:f,dataType:"html",data:b,complete:function(i,o){if(o==="success"||o==="notmodified")j.html(e?c("<div />").append(i.responseText.replace(tb,"")).find(e):i.responseText);d&&j.each(d,[i.responseText,o,i])}});return this},
serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),
function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,
global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:A.XMLHttpRequest&&(A.location.protocol!=="file:"||!A.ActiveXObject)?function(){return new A.XMLHttpRequest}:function(){try{return new A.ActiveXObject("Microsoft.XMLHTTP")}catch(a){}},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},etag:{},ajax:function(a){function b(){e.success&&
e.success.call(k,o,i,x);e.global&&f("ajaxSuccess",[x,e])}function d(){e.complete&&e.complete.call(k,x,i);e.global&&f("ajaxComplete",[x,e]);e.global&&!--c.active&&c.event.trigger("ajaxStop")}function f(q,p){(e.context?c(e.context):c.event).trigger(q,p)}var e=c.extend(true,{},c.ajaxSettings,a),j,i,o,k=a&&a.context||e,n=e.type.toUpperCase();if(e.data&&e.processData&&typeof e.data!=="string")e.data=c.param(e.data,e.traditional);if(e.dataType==="jsonp"){if(n==="GET")N.test(e.url)||(e.url+=(ka.test(e.url)?
"&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||N.test(e.url))){j=e.jsonpCallback||"jsonp"+sb++;if(e.data)e.data=(e.data+"").replace(N,"="+j+"$1");e.url=e.url.replace(N,"="+j+"$1");e.dataType="script";A[j]=A[j]||function(q){o=q;b();d();A[j]=w;try{delete A[j]}catch(p){}z&&z.removeChild(C)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache===
false&&n==="GET"){var r=J(),u=e.url.replace(wb,"$1_="+r+"$2");e.url=u+(u===e.url?(ka.test(e.url)?"&":"?")+"_="+r:"")}if(e.data&&n==="GET")e.url+=(ka.test(e.url)?"&":"?")+e.data;e.global&&!c.active++&&c.event.trigger("ajaxStart");r=(r=xb.exec(e.url))&&(r[1]&&r[1]!==location.protocol||r[2]!==location.host);if(e.dataType==="script"&&n==="GET"&&r){var z=s.getElementsByTagName("head")[0]||s.documentElement,C=s.createElement("script");C.src=e.url;if(e.scriptCharset)C.charset=e.scriptCharset;if(!j){var B=
false;C.onload=C.onreadystatechange=function(){if(!B&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){B=true;b();d();C.onload=C.onreadystatechange=null;z&&C.parentNode&&z.removeChild(C)}}}z.insertBefore(C,z.firstChild);return w}var E=false,x=e.xhr();if(x){e.username?x.open(n,e.url,e.async,e.username,e.password):x.open(n,e.url,e.async);try{if(e.data||a&&a.contentType)x.setRequestHeader("Content-Type",e.contentType);if(e.ifModified){c.lastModified[e.url]&&x.setRequestHeader("If-Modified-Since",
c.lastModified[e.url]);c.etag[e.url]&&x.setRequestHeader("If-None-Match",c.etag[e.url])}r||x.setRequestHeader("X-Requested-With","XMLHttpRequest");x.setRequestHeader("Accept",e.dataType&&e.accepts[e.dataType]?e.accepts[e.dataType]+", */*":e.accepts._default)}catch(ga){}if(e.beforeSend&&e.beforeSend.call(k,x,e)===false){e.global&&!--c.active&&c.event.trigger("ajaxStop");x.abort();return false}e.global&&f("ajaxSend",[x,e]);var g=x.onreadystatechange=function(q){if(!x||x.readyState===0||q==="abort"){E||
d();E=true;if(x)x.onreadystatechange=c.noop}else if(!E&&x&&(x.readyState===4||q==="timeout")){E=true;x.onreadystatechange=c.noop;i=q==="timeout"?"timeout":!c.httpSuccess(x)?"error":e.ifModified&&c.httpNotModified(x,e.url)?"notmodified":"success";var p;if(i==="success")try{o=c.httpData(x,e.dataType,e)}catch(v){i="parsererror";p=v}if(i==="success"||i==="notmodified")j||b();else c.handleError(e,x,i,p);d();q==="timeout"&&x.abort();if(e.async)x=null}};try{var h=x.abort;x.abort=function(){x&&h.call(x);
g("abort")}}catch(l){}e.async&&e.timeout>0&&setTimeout(function(){x&&!E&&g("timeout")},e.timeout);try{x.send(n==="POST"||n==="PUT"||n==="DELETE"?e.data:null)}catch(m){c.handleError(e,x,null,m);d()}e.async||g();return x}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status===
1223||a.status===0}catch(b){}return false},httpNotModified:function(a,b){var d=a.getResponseHeader("Last-Modified"),f=a.getResponseHeader("Etag");if(d)c.lastModified[b]=d;if(f)c.etag[b]=f;return a.status===304||a.status===0},httpData:function(a,b,d){var f=a.getResponseHeader("content-type")||"",e=b==="xml"||!b&&f.indexOf("xml")>=0;a=e?a.responseXML:a.responseText;e&&a.documentElement.nodeName==="parsererror"&&c.error("parsererror");if(d&&d.dataFilter)a=d.dataFilter(a,b);if(typeof a==="string")if(b===
"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional;
if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var j in a)d(j,a[j]);return e.join("&").replace(yb,"+")}});var la={},Ab=/toggle|show|hide/,Bb=/^([+-]=)?([\d+-.]+)(.*)$/,W,va=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");
this[a].style.display=d||"";if(c.css(this[a],"display")==="none"){d=this[a].nodeName;var f;if(la[d])f=la[d];else{var e=c("<"+d+" />").appendTo("body");f=e.css("display");if(f==="none")f="block";e.remove();la[d]=f}c.data(this[a],"olddisplay",f)}}a=0;for(b=this.length;a<b;a++)this[a].style.display=c.data(this[a],"olddisplay")||"";return this}},hide:function(a,b){if(a||a===0)return this.animate(K("hide",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");!d&&d!=="none"&&c.data(this[a],
"olddisplay",c.css(this[a],"display"))}a=0;for(b=this.length;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b){var d=typeof a==="boolean";if(c.isFunction(a)&&c.isFunction(b))this._toggle.apply(this,arguments);else a==null||d?this.each(function(){var f=d?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(K("toggle",3),a,b);return this},fadeTo:function(a,b,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d)},
animate:function(a,b,d,f){var e=c.speed(b,d,f);if(c.isEmptyObject(a))return this.each(e.complete);return this[e.queue===false?"each":"queue"](function(){var j=c.extend({},e),i,o=this.nodeType===1&&c(this).is(":hidden"),k=this;for(i in a){var n=i.replace(ia,ja);if(i!==n){a[n]=a[i];delete a[i];i=n}if(a[i]==="hide"&&o||a[i]==="show"&&!o)return j.complete.call(this);if((i==="height"||i==="width")&&this.style){j.display=c.css(this,"display");j.overflow=this.style.overflow}if(c.isArray(a[i])){(j.specialEasing=
j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]);
this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration===
"number"?f.duration:c.fx.speeds[f.duration]||c.fx.speeds._default;f.old=f.complete;f.complete=function(){f.queue!==false&&c(this).dequeue();c.isFunction(f.old)&&f.old.call(this)};return f},easing:{linear:function(a,b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]||
c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(j){return e.step(j)}this.startTime=J();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start;
this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!W)W=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(a){var b=J(),d=true;if(a||b>=this.options.duration+this.startTime){this.now=
this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var f in this.options.curAnim)if(this.options.curAnim[f]!==true)d=false;if(d){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;a=c.data(this.elem,"olddisplay");this.elem.style.display=a?a:this.options.display;if(c.css(this.elem,"display")==="none")this.elem.style.display="block"}this.options.hide&&c(this.elem).hide();if(this.options.hide||this.options.show)for(var e in this.options.curAnim)c.style(this.elem,
e,this.options.orig[e]);this.options.complete.call(this.elem)}return false}else{e=b-this.startTime;this.state=e/this.options.duration;a=this.options.easing||(c.easing.swing?"swing":"linear");this.pos=c.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||a](this.state,e,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};c.extend(c.fx,{tick:function(){for(var a=c.timers,b=0;b<a.length;b++)a[b]()||a.splice(b--,1);a.length||
c.fx.stop()},stop:function(){clearInterval(W);W=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){c.style(a.elem,"opacity",a.now)},_default:function(a){if(a.elem.style&&a.elem.style[a.prop]!=null)a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit;else a.elem[a.prop]=a.now}}});if(c.expr&&c.expr.filters)c.expr.filters.animated=function(a){return c.grep(c.timers,function(b){return a===b.elem}).length};c.fn.offset="getBoundingClientRect"in s.documentElement?
function(a){var b=this[0];if(a)return this.each(function(e){c.offset.setOffset(this,a,e)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);var d=b.getBoundingClientRect(),f=b.ownerDocument;b=f.body;f=f.documentElement;return{top:d.top+(self.pageYOffset||c.support.boxModel&&f.scrollTop||b.scrollTop)-(f.clientTop||b.clientTop||0),left:d.left+(self.pageXOffset||c.support.boxModel&&f.scrollLeft||b.scrollLeft)-(f.clientLeft||b.clientLeft||0)}}:function(a){var b=
this[0];if(a)return this.each(function(r){c.offset.setOffset(this,a,r)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);c.offset.initialize();var d=b.offsetParent,f=b,e=b.ownerDocument,j,i=e.documentElement,o=e.body;f=(e=e.defaultView)?e.getComputedStyle(b,null):b.currentStyle;for(var k=b.offsetTop,n=b.offsetLeft;(b=b.parentNode)&&b!==o&&b!==i;){if(c.offset.supportsFixedPosition&&f.position==="fixed")break;j=e?e.getComputedStyle(b,null):b.currentStyle;
k-=b.scrollTop;n-=b.scrollLeft;if(b===d){k+=b.offsetTop;n+=b.offsetLeft;if(c.offset.doesNotAddBorder&&!(c.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(b.nodeName))){k+=parseFloat(j.borderTopWidth)||0;n+=parseFloat(j.borderLeftWidth)||0}f=d;d=b.offsetParent}if(c.offset.subtractsBorderForOverflowNotVisible&&j.overflow!=="visible"){k+=parseFloat(j.borderTopWidth)||0;n+=parseFloat(j.borderLeftWidth)||0}f=j}if(f.position==="relative"||f.position==="static"){k+=o.offsetTop;n+=o.offsetLeft}if(c.offset.supportsFixedPosition&&
f.position==="fixed"){k+=Math.max(i.scrollTop,o.scrollTop);n+=Math.max(i.scrollLeft,o.scrollLeft)}return{top:k,left:n}};c.offset={initialize:function(){var a=s.body,b=s.createElement("div"),d,f,e,j=parseFloat(c.curCSS(a,"marginTop",true))||0;c.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"});b.innerHTML="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";
a.insertBefore(b,a.firstChild);d=b.firstChild;f=d.firstChild;e=d.nextSibling.firstChild.firstChild;this.doesNotAddBorder=f.offsetTop!==5;this.doesAddBorderForTableAndCells=e.offsetTop===5;f.style.position="fixed";f.style.top="20px";this.supportsFixedPosition=f.offsetTop===20||f.offsetTop===15;f.style.position=f.style.top="";d.style.overflow="hidden";d.style.position="relative";this.subtractsBorderForOverflowNotVisible=f.offsetTop===-5;this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==j;a.removeChild(b);
c.offset.initialize=c.noop},bodyOffset:function(a){var b=a.offsetTop,d=a.offsetLeft;c.offset.initialize();if(c.offset.doesNotIncludeMarginInBodyOffset){b+=parseFloat(c.curCSS(a,"marginTop",true))||0;d+=parseFloat(c.curCSS(a,"marginLeft",true))||0}return{top:b,left:d}},setOffset:function(a,b,d){if(/static/.test(c.curCSS(a,"position")))a.style.position="relative";var f=c(a),e=f.offset(),j=parseInt(c.curCSS(a,"top",true),10)||0,i=parseInt(c.curCSS(a,"left",true),10)||0;if(c.isFunction(b))b=b.call(a,
d,e);d={top:b.top-e.top+j,left:b.left-e.left+i};"using"in b?b.using.call(a,d):f.css(d)}};c.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),d=this.offset(),f=/^body|html$/i.test(b[0].nodeName)?{top:0,left:0}:b.offset();d.top-=parseFloat(c.curCSS(a,"marginTop",true))||0;d.left-=parseFloat(c.curCSS(a,"marginLeft",true))||0;f.top+=parseFloat(c.curCSS(b[0],"borderTopWidth",true))||0;f.left+=parseFloat(c.curCSS(b[0],"borderLeftWidth",true))||0;return{top:d.top-
f.top,left:d.left-f.left}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||s.body;a&&!/^body|html$/i.test(a.nodeName)&&c.css(a,"position")==="static";)a=a.offsetParent;return a})}});c.each(["Left","Top"],function(a,b){var d="scroll"+b;c.fn[d]=function(f){var e=this[0],j;if(!e)return null;if(f!==w)return this.each(function(){if(j=wa(this))j.scrollTo(!a?f:c(j).scrollLeft(),a?f:c(j).scrollTop());else this[d]=f});else return(j=wa(e))?"pageXOffset"in j?j[a?"pageYOffset":
"pageXOffset"]:c.support.boxModel&&j.document.documentElement[d]||j.document.body[d]:e[d]}});c.each(["Height","Width"],function(a,b){var d=b.toLowerCase();c.fn["inner"+b]=function(){return this[0]?c.css(this[0],d,false,"padding"):null};c.fn["outer"+b]=function(f){return this[0]?c.css(this[0],d,false,f?"margin":"border"):null};c.fn[d]=function(f){var e=this[0];if(!e)return f==null?null:this;if(c.isFunction(f))return this.each(function(j){var i=c(this);i[d](f.call(this,j,i[d]()))});return"scrollTo"in
e&&e.document?e.document.compatMode==="CSS1Compat"&&e.document.documentElement["client"+b]||e.document.body["client"+b]:e.nodeType===9?Math.max(e.documentElement["client"+b],e.body["scroll"+b],e.documentElement["scroll"+b],e.body["offset"+b],e.documentElement["offset"+b]):f===w?c.css(e,d):this.css(d,typeof f==="string"?f:f+"px")}});A.jQuery=A.$=c})(window);


(function($){function toIntegersAtLease(n)
{return n<10?'0'+n:n;}
Date.prototype.toJSON=function(date)
{return this.getUTCFullYear()+'-'+
toIntegersAtLease(this.getUTCMonth())+'-'+
toIntegersAtLease(this.getUTCDate());};var escapeable=/["\\\x00-\x1f\x7f-\x9f]/g;var meta={'\b':'\\b','\t':'\\t','\n':'\\n','\f':'\\f','\r':'\\r','"':'\\"','\\':'\\\\'}
$.quoteString=function(string)
{if(escapeable.test(string))
{return'"'+string.replace(escapeable,function(a)
{var c=meta[a];if(typeof c==='string'){return c;}
c=a.charCodeAt();return'\\u00'+Math.floor(c/16).toString(16)+(c%16).toString(16);})+'"'}
return'"'+string+'"';}
$.toJSON=function(o,compact)
{var type=typeof(o);if(type=="undefined")
return"undefined";else if(type=="number"||type=="boolean")
return o+"";else if(o===null)
return"null";if(type=="string")
{return $.quoteString(o);}
if(type=="object"&&typeof o.toJSON=="function")
return o.toJSON(compact);if(type!="function"&&typeof(o.length)=="number")
{var ret=[];for(var i=0;i<o.length;i++){ret.push($.toJSON(o[i],compact));}
if(compact)
return"["+ret.join(",")+"]";else
return"["+ret.join(", ")+"]";}
if(type=="function"){throw new TypeError("Unable to convert object of type 'function' to json.");}
ret=[];for(var k in o){var name;var type=typeof(k);if(type=="number")
name='"'+k+'"';else if(type=="string")
name=$.quoteString(k);else
continue;val=$.toJSON(o[k],compact);if(typeof(val)!="string"){continue;}
if(compact)
ret.push(name+":"+val);else
ret.push(name+": "+val);}
return"{"+ret.join(", ")+"}";}
$.compactJSON=function(o)
{return $.toJSON(o,true);}
$.evalJSON=function(src)
{return eval("("+src+")");}
$.secureEvalJSON=function(src)
{var filtered=src;filtered=filtered.replace(/\\["\\\/bfnrtu]/g,'@');filtered=filtered.replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,']');filtered=filtered.replace(/(?:^|:|,)(?:\s*\[)+/g,'');if(/^[\],:{}\s]*$/.test(filtered))
return eval("("+src+")");else
throw new SyntaxError("Error parsing JSON, source is not valid.");}})(jQuery);

/**
 * jQuery hashchange 1.0.0
 * 
 * (based on jquery.history)
 *
 * Copyright (c) 2008 Chris Leishman (chrisleishman.com)
 * Dual licensed under the MIT (MIT-LICENSE.txt)
 * and GPL (GPL-LICENSE.txt) licenses.
 */
(function($) {

$.fn.extend({
    hashchange: function(callback) { this.bind('hashchange', callback) },
    openOnClick: function(href) {
		if (href === undefined || href.length == 0)
			href = '#';
		return this.click(function(ev) {
			if (href && href.charAt(0) == '#') {
				// execute load in separate call stack
				window.setTimeout(function() { $.locationHash(href) }, 0);
			} else {
				window.location(href);
			}
			ev.stopPropagation();
			return false;
		});
    }
});

// IE 8 introduces the hashchange event natively - so nothing more to do
if ($.browser.msie && document.documentMode && document.documentMode >= 8) {
	$.extend({
		locationHash: function(hash) {
	        if (!hash) hash = '#';
	        else if (hash.charAt(0) != '#') hash = '#' + hash;
	        location.hash = hash;
	    }
	});
	return;
}

var curHash;
// hidden iframe for IE (earlier than 8)
var iframe;

$.extend({
	locationHash: function(hash) {
		if (curHash === undefined) return;

		if (!hash) hash = '#';
		else if (hash.charAt(0) != '#') hash = '#' + hash;
		
		location.hash = hash;
		
		if (curHash == hash) return;
		curHash = hash;
		
		if ($.browser.msie) updateIEFrame(hash);
		$.event.trigger('hashchange');
	}
});

$(document).ready(function() {
    curHash = location.hash;
    if ($.browser.msie) {
        // stop the callback firing twice during init if no hash present
        if (curHash == '') curHash = '#';
        // add hidden iframe for IE
        iframe = $('<iframe />').hide().get(0);
        $('body').prepend(iframe);
        updateIEFrame(location.hash);
        setInterval(checkHashIE, 100);
    } else {
        setInterval(checkHash, 100);
    }
});
$(window).unload(function() { iframe = null });

function checkHash() {
    var hash = location.hash;
    if (hash != curHash) {
        curHash = hash;
        $.event.trigger('hashchange');
    }
}

if ($.browser.msie) {
    // Attach a live handler for any anchor links
    $('a[href^=#]').live('click', function() {
        var hash = $(this).attr('href');
        // Don't intercept the click if there is an existing anchor on the page
        // that matches this hash
        if ($(hash).length == 0 && $('a[name='+hash.slice(1)+']').length == 0) {
            $.locationHash(hash);
            return false;
        }
    });
}

function checkHashIE() {
    // On IE, check for location.hash of iframe
    var idoc = iframe.contentDocument || iframe.contentWindow.document;
    var hash = idoc.location.hash;
    if (hash == '') hash = '#';

    if (hash != curHash) {
        if (location.hash != hash) location.hash = hash;
        curHash = hash;
        $.event.trigger('hashchange');
    }
}

function updateIEFrame(hash) {
    if (hash == '#') hash = '';
    var idoc = iframe.contentWindow.document;
    idoc.open();
    idoc.close();
    if (idoc.location.hash != hash) idoc.location.hash = hash;
}

})(jQuery);

//A CLASS TO CONTAIN HTML TEMPLATES
function HotlistTemplate(){
	
	this.cached = [];
	
}
window["_tmpl"] = new HotlistTemplate();

//--------------------------------------------------------
_tmpl["mapPreviewURL"] = function(){
	
	//.host
	//.latitude
	//.longitude
	
	strCacheKey = "mapPreviewURL";
	
	if(!isUsable(_tmpl.cached[strCacheKey])){
		
		var html = [];
		
		html.push("{host}/gmap.php?markers=icon:{host}/images/icons/title_flame.png|size:tiny|{latitude},{longitude}");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["toolbarDialog"] = function(){
	
	strCacheKey = "toolbarDialog";
	
	if(!isUsable(_tmpl.cached[strCacheKey])){
		
		var html = [];
		
		html.push("<a class='spr_inside close fr' href='javascript:v();' onclick='$(\"#fade\").click();'></a><div class='title'>{title}</div><div class='content'>{content}</div>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["favorite"] = function(bolIncludeRemoveButton){

	//USED IN THE TOOLBAR DIALOG (WITH REMOVE BUTTON) AND IN THE PROFILE SIDEBAR (WITHOUT)
	var strCacheKey = "favorite_" + bolIncludeRemoveButton;

	//ALREADY CACHED?
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];
		html.push("<div class='fave mb20 fave{id}'>");
		html.push("  ");
		
		if(bolIncludeRemoveButton){
			html.push("  <a href='javascript:v();' onclick='_page.removeFavorite({id}, {latitude}, {longitude}, this);' class='fr remove f12 b tdn'>Remove</a>");
		}
		
		html.push("  ");
		html.push("  <a href='/places?type=venue&src={venue_src}&lat={latitude}&long={longitude}' class='f16'>{name}</a>");
		html.push("  <div>{address}</div>");
		html.push("  <div>{city}, {state} {zip}</div>");
		html.push("  ");
		html.push("  <div class='clear'>&nbsp;</div>");
		html.push("</div>");
		html.push("");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}

	//RETURN
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["calendarDialogItem"] = function(strType){

	var strCacheKey = "calendarDialogItem_" + strType;

	//ALREADY CACHED?
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];
		
		switch(strType){
			case "event":
	
				html.push("<div class='event mb20'>");
				html.push("");
				html.push("  <div class='cal_day fl'>");
				html.push("    <div class='day'>{date_day}</div>");
				html.push("    <div class='number'>{date_number}</div>");
				html.push("    <div class='month pt2'>{month}</div>");
				html.push("  </div>");
				html.push("");
				html.push("  <div class='info fl'>");
				html.push("  ");
				html.push("    <div><a href='{venue_url}' class='f14 b'>{venue}</a></div>");
				html.push("    <div><a href='{event_url}' class='f12'>{title}</a></div>");
				html.push("    <div>{start_time_formatted}</div>");
				html.push("    <div class='event_stats'>");
				
				html.push("    <div class='fl'>{total} people - </div>");
				html.push("    <div class='fl'>&nbsp;{male}% </div><div class='spr_inside boy fl'> </div> <div class='fl'> {female}% </div> <div class='spr_inside girl fl'></div>");
				
				html.push("    </div>");
				html.push("    ");
				html.push("    ");
				html.push("  ");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("");
				html.push("</div>");
		
				break;
			case "venue":
	
				html.push("<div class='venue mb20'>");
				html.push("");
				html.push("  <div class='cal_day fl'>");
				html.push("    <div class='day'>{date_day}</div>");
				html.push("    <div class='number'>{date_number}</div>");
				html.push("    <div class='month pt2'>{month}</div>");
				html.push("  </div>");
				html.push("");
				html.push("  <div class='info fl'>");
				html.push("  ");
				html.push("    <div><a href='{venue_url}' class='f14 b'>{venue}</a></div>");
				html.push("    <div class='event_stats'>");
				
				html.push("    <div class='fl'>{total} people - </div>");
				html.push("    <div class='fl'>&nbsp;{male}% </div><div class='spr_inside boy fl'> </div> <div class='fl'> {female}% </div> <div class='spr_inside girl fl'></div>");
				
				html.push("    </div>");
				html.push("    ");
				html.push("    ");
				html.push("  ");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("");
				html.push("</div>");
		
				break;
			default:
				log("unhandled strType (1599243)");
				break;
			
		}

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}

	//RETURN
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["planner"] = function(){

	//USED IN THE TOOLBAR DIALOG (WITH REMOVE BUTTON) AND IN THE PROFILE SIDEBAR (WITHOUT)
	var strCacheKey = "planner";

	//ALREADY CACHED?
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];
		html.push("<div id='preview' class='mtb10'>");
		html.push("  <div class='i gray f14 pb5'>Preview</div>");
		html.push("  <table>");
		html.push("    <tr>");
		html.push("      <td class='vt al' style='width: 60px; '>");
		html.push("        <img src='http://graph.facebook.com/" + _fb.user.uid + "/picture?type=square'/>");
		html.push("      </td>");
		html.push("      <td class='vt al'>");
		html.push("        <div id='divMessage' class='fb mb5'>");
		html.push("          <span id='username' class='fb link'>{username}</span> &#151; <span id='what'>{what}</span>");
		html.push("        </div>");
		html.push("        <div>");
		html.push("        <div id='previewMap' class='fl mr10'>");
		html.push("          <img src='{map}'/>");
		html.push("        </div>");
		html.push("        <div class='fb fl'>");
		html.push("          <span class='pl_venue fb link'>{venue}</span> <br/>");
		html.push("          <span id='address' class='fb details'>{address}</span> <span id='when' class='fb details'>{when}</span><br/>");
		html.push("        </div>");
		html.push("        <div class='clear'></div>");
		html.push("        </div>");
		html.push("      </td>");
		html.push("    </tr>");
		html.push("  </table>");
		html.push("</div>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}

	//RETURN
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["feedItem"] = function(strType){
	
	strCacheKey = "feedItem_" + strType;
	
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];
		
		switch(strType){
			
			case "hotlist":

				//THE HOTLIST TEMPLATE EXPECTS:
				//.type
				//.user
				//.uid
				//.img
				//.text
				//.id (post id)
				//.time
				
				html.push("<li class='{type}'>");
				html.push("<div class='comment'>");
				html.push("");
				html.push("<a title='{user}' href='/profiles/{uid}'>");
				html.push("<img class='spr default_user profile fl' src='{img}'/>");
				html.push("</a>");
				html.push("");
				html.push("<div class='text'>{text}</div>");
				html.push("<div class='pt5'>");
				html.push("  <div class='spr_inside logo fl m0'></div>");
				html.push("  ");
				html.push("  <div class='fl pt3'>");
				html.push("  &nbsp; {time} via The Hotlist");
				html.push("  </div>");
				html.push("  ");
				html.push("</div>");
				html.push("<div class='clear pt10'></div>");
				html.push("</div>");
				html.push("</li>");
				html.push("");
					
				break;
			case "twitter":

				//THE TWITTER TEMPLATE EXPECTS:
				//.type
				//.user
				//.img
				//.text
				//.id
				//.time
		
				var html = [];
						
				html.push("<li class='{type}'>");
				html.push("<div class='comment'>");
				html.push("");
				html.push("<a title='@{user} on Twitter' href='http://twitter.com/{user}' target='_blank'>");
				html.push("<img class='spr default_user profile fl' src='{img}'/>");
				html.push("</a>");
				html.push("");
				html.push("<div class='text'>{text}</div>");
				html.push("<div class='pt5'>");
				html.push("  <div class='spr_inside logo fl m0'></div>");
				html.push("  ");
				html.push("  <div class='fl pt3'>");
				html.push("  ");
				html.push("  &nbsp; <a href='http://twitter.com/{user}/statuses/{id}' title='view tweet on Twitter' target='_blank'>{time}</a> via Twitter");
				html.push("  ");
				html.push("  </div>");
				html.push("  ");
				html.push("</div>");
				html.push("<div class='clear pt10'></div>");
				html.push("</div>");
				html.push("</li>");
				html.push("");

				break;
			case "yelp":

				//THE YELP TEMPLATE EXPECTS:
				//.id (post id)
				//.type
				//.user
				//.user_url
				//.img
				//.text
				//.rating (img src)
				//.url
				//.time
				//.timestamp
				
				var html = [];
						
				html.push("<li class='{type}'>");
				html.push("<div class='comment'>");
				html.push("");
				html.push("<a title='{user} on Yelp' href='{user_url}' target='_blank'>");
				html.push("<img class='spr default_user profile fl' src='{img}'/>");
				html.push("</a>");
				html.push("");
				html.push("<div class='text'>{text}</div>");
				html.push("<div class='pt5'>");
				html.push("  ");
				html.push("  ");
				html.push("  <div class='fl pt3 vm'>");
				html.push("  ");
				html.push("  <a href='{url}' title='Review on Yelp' target='_blank' class='fr'><div class='spr_inside logo vm m0'></div></a> ");
				html.push("  <img src='{rating}' class='vm'/> <a href='{url}' title='Review on Yelp' target='_blank' class='vm'>{time}</a> <span class='vm'>via</span>&nbsp; ");
				html.push("  ");
				html.push("  </div>");
				html.push("  ");
				html.push("</div>");
				html.push("<div class='clear pt10'></div>");
				html.push("</div>");
				html.push("</li>");
				html.push("");
			
				break;
			case "event":
	
				//THE EVENT TEMPLATE EXPECTS:
				//.date_day
				//.date_number
				//.event_url
				//.title
				//.venue_url
				//.venue
				//.start_time_formatted
				//.total
				//.male
				//.female
				
				html.push("<li class='event'>");
				html.push("");
				html.push("  <div class='cal_day fl'>");
				html.push("    <div class='day'>{date_day}</div>");
				html.push("    <div class='number'>{date_number}</div>");
				html.push("    <div class='month pt2'>{month}</div>");
				html.push("  </div>");
				html.push("");
				html.push("  <div class='info fl'>");
				html.push("  ");
				html.push("    <div><a href='{venue_url}' class='f14 b'>{venue}</a></div>");
				html.push("    <div><a href='{event_url}' class='f12'>{title}</a></div>");
				html.push("    <div>{start_time_formatted}</div>");
				html.push("    <div class='event_stats'>");
				
				html.push("    <div class='fl'>{total} people - </div>");
				html.push("    <div class='fl'>&nbsp;{male}% </div><div class='spr_inside boy fl'> </div> <div class='fl'> {female}% </div> <div class='spr_inside girl fl'></div>");
				
				html.push("    </div>");
				html.push("    ");
				html.push("  ");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("  <div class='post_border'>&nbsp;</div>");
				html.push("</li>");
		
				break;
			case "hub_event":
	
				//THE HUB EVENT TEMPLATE EXPECTS:
				//
				//.count
				//.imgIndex
				//.event_id
				//.venue_name
				//.venue_url
				//.event_name
				//.event_url
				//.friends_going !!!
				//.total_going
				//.friend_count
				//.friendPlural
				//.isGoing
				//.isMaybe
				//.src
				
				html.push("<li class='event feed_item item_{count}' onclick='_feed.openItem({count});'>");
				html.push("");
				html.push("  <div class='icon fl'><img src='/images/icons/map/hot{imgIndex}.png'/></div>");
				html.push("");
				html.push("  <div class='name fl'>");
				html.push("    ");
				html.push("    <span class='friends_text hide'><!-- set at (3507292) --></span> <!-- RSVP'd for -->");
				html.push("    ");
				html.push("    <a class='f16 b' href='{venue_url}'>{venue_name}</a>");
				html.push("    {.section venue_name}");
				html.push("    <div class='pt5'><a href='{event_url}'>{event_name}</a></div> ");
				html.push("    {.end}");
				html.push("");
				html.push("        <div class='clear'></div>");
				html.push("        <div class='mt10 pb5 stat stat_friends gray'>{stats.summary}&nbsp;</div>");
				html.push("");
				html.push("  </div>");
				html.push("");
				
				html.push("  <div class='details fl'>");

				html.push("    <div class='clear'></div>");
				html.push("");
				html.push("    <div id='divFriends{count}' class='friends'>");
				html.push("      <div class='getting_msg gray ac clear pt20 f14'>Getting friend information...</div>");
				html.push("    </div>");
				html.push("");
				html.push("");
				
				html.push("    <div class='buttons pt5 pb10 ac mrl5'>");
				html.push("      <div onclick='_feed.rsvp(\"going\", \"f\", \"{event_id}\", this);' class='btn going p10 f18 m0a fl {.section isGoing}on{.end}' title='Going'>");
				html.push("        <div class='white di' style='margin-left: -18px;' >GOING</div>");
				html.push("        <div style='margin-top: -4px;' class='spr_inside check fl'/>");
				html.push("      </div>");
				html.push("      <div onclick='_feed.rsvp(\"maybe\", \"f\", \"{event_id}\", this);' class='btn maybe p10 f18 m0a fl {.section isMaybe}on{.end}' title='Maybe'>");
				html.push("        <div class='white di' style='margin-left: -18px;' >MAYBE</div>");
				html.push("        <div style='margin-top: -4px;' class='spr_inside check fl'/>");
				html.push("      </div>");
				html.push("      <div class='fl fb_share pt5' onclick='$(this).find(\".checkbox\").toggleClass(\"on\");'>");
				html.push("        <div class='spr_inside checkbox on fl'></div>");
				html.push("        Post on Facebook");
				html.push("      </div>");
				html.push("    </div>");

				html.push("");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("");
				html.push("</li>");
		
				break;
			case "hub_venue":
	
				//THE HUB VENUE TEMPLATE EXPECTS:
				//
				//.count
				//.imgIndex
				//.event_id
				//.venue_name
				//.venue_url
				//.event_name
				//.event_url
				//.friends_going !!!
				//.total_going
				//.friend_count
				//.friendPlural
				//.isGoing
				//.isMaybe
				//.src
				
				html.push("<li class='event feed_item item_{count}' onclick='_feed.openItem({count});'>");
				html.push("");
				html.push("  <div class='icon fl'><img src='/images/icons/map/hot{imgIndex}.png'/></div>");
				html.push("");
				html.push("  <div class='name fl'>");
				html.push("    ");
				html.push("    <span class='friends_text hide'><!-- set at (3507292) --></span> <!-- RSVP'd for -->");
				html.push("    ");
				html.push("    <a class='f16 b' href='{venue_url}'>{venue_name}</a> ");

				html.push("        <div class='clear'></div>");
				
				html.push("        <div class='mt10 pb5 stat stat_friends gray'><!--{friend_count} friend{friendPlural}--></div>");

				html.push("");
				html.push("  </div>");
				html.push("");
				
				html.push("  <div class='details fl'>");

				html.push("    <div class='clear'></div>");
				html.push("");
				html.push("    <div id='divFriends{count}' class='friends'>");
				html.push("      <div class='gray ac clear pt20 f14'>Getting friend information...</div>");
				html.push("    </div>");
				html.push("");
				
				html.push("    <div class='buttons pt5 pb10 ac mrl5'>");
				html.push("      <div onclick='_feed.checkin(this, \"going\");' class='btn going p10 f18 m0a fl {.section isGoing}on{.end}' title='Going'>");
				html.push("        <div class='white di' style='margin-left: -18px;' >GOING</div>");
				html.push("        <div style='margin-top: -4px;' class='spr_inside check fl'/>");
				html.push("      </div>");
				html.push("      <div onclick='_feed.checkin(this, \"maybe\");' class='btn maybe p10 f18 m0a fl {.section isMaybe}on{.end}' title='Maybe'>");
				html.push("        <div class='white di' style='margin-left: -18px;' >MAYBE</div>");
				html.push("        <div style='margin-top: -4px;' class='spr_inside check fl'/>");
				html.push("      </div>");
				html.push("      <div class='fl fb_share pt5' onclick='$(this).find(\".checkbox\").toggleClass(\"on\");'>");
				html.push("        <div class='spr_inside checkbox on fl'></div>");
				html.push("        Post on Facebook");
				html.push("      </div>");
				html.push("    </div>");
				html.push("");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("");
				html.push("</li>");
		
				break;
			case "venue":
	
				//THE VENUE TEMPLATE EXPECTS:
				//.date_day
				//.date_number
				//.venue_url
				//.venue
				//.total
				//.male
				//.female
					
				html.push("<li class='venue'>");
				html.push("");
				html.push("  <div class='cal_day fl'>");
				html.push("    <div class='day'>{date_day}</div>");
				html.push("    <div class='number'>{date_number}</div>");
				html.push("  </div>");
				html.push("");
				html.push("  <div class='info fl'>");
				html.push("  ");
				html.push("    <div><a href='{venue_url}' class='f14 b'>{venue}</a></div>");
				html.push("    <div class='event_stats'>");
				
				html.push("    <div class='fl'>{total} people - </div>");
				html.push("    <div class='fl'>&nbsp;{male}% </div><div class='spr_inside boy fl'> </div> <div class='fl'> {female}% </div> <div class='spr_inside girl fl'></div>");
				
				html.push("    </div>");
				html.push("    ");
				html.push("    ");
				html.push("  ");
				html.push("  </div>");
				html.push("  <div class='clear'>&nbsp;</div>");
				html.push("  <div class='post_border'>&nbsp;</div>");
				html.push("</li>");
		
				break;
			default:
				log("invalid feed item template strType (3047862)");
				break;
			
		}
		
		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["feedPager"] = function(){
	
	strCacheKey = "feedPager";

	var html = [];
	
	if(!isUsable(_tmpl.cached[strCacheKey])){
		
		html.push("<li class='more ac p5 next {.section show_pb}prev{.end} {.section hide_top}hide{.end}'>");
		html.push("");
		html.push("	 <table class='pager {.section show_pb}show_pb pb{current_page}{.end}'>");
		html.push("    <tr>");
		html.push("      <td class='prev' onclick='_feed.page(-1, this);'>");
		html.push("        <a class='spr_inside arrow left_arrow fl' title='Previous page' href='javascript:v();'></a>");
		//html.push("        <span class='arrow_text fl'>Prev</span>"); THIS IS NEVER SHOWN, SINCE THE TEXT LABELS DISAPPEAR WHEN THE PAGE BUTTONS ARE VISIBLE
		html.push("      </td>");
		html.push("      <td class='page pb1'><div class='page_button' onclick='_feed.pageButton({B1});'>{B1}</div></td>");
		html.push("      <td class='page pb2'><div class='page_button' onclick='_feed.pageButton({B2});'>{B2}</div></td>");
		html.push("      <td class='page pb3'><div class='page_button' onclick='_feed.pageButton({B3});'>{B3}</div></td>");
		html.push("      <td class='page pb4'><div class='page_button' onclick='_feed.pageButton({B4});'>{B4}</div></td>");
		html.push("      <td class='page pb5'><div class='page_button' onclick='_feed.pageButton({B5});'>{B5}</div></td>");
		html.push("      <td class='next' onclick='_feed.page(1, this);'>");
		html.push("        <a class='spr_inside arrow right_arrow fr' title='Next page' href='javascript:v();'></a>");
		html.push("        <span class='arrow_text fr'>Next</span>");
		html.push("      </td>");
		html.push("    </tr>");
		html.push("  </table>");
		html.push("");
		html.push("  <span class='loading'>Please wait...</span>");
		html.push("  <div class='clear'></div>");
		html.push("");
		html.push("</li>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}

	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["fbCarouselUser"] = function(){
	
	//.uid
	//.first_name
  //.pic_square
	
	strCacheKey = "fbCarouselUser";

	if(!isUsable(_tmpl.cached[strCacheKey])){
		
		var html = [];
		html.push("<li class='friend'><a class='user' href='/profiles/{uid}' title='{first_name}'><img class='fb_square u{uid}' src='{pic_square}'/></a>");
		html.push("<br/><a class='ac' href='/profiles/{uid}' title='{first_name}'>{first_name}</a>");
		html.push("</li>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}

	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["fbSidebarUser"] = function(){
	
	strCacheKey = "fbSidebarUser";
	
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];

		html.push("<div class='user'>");
		html.push("<a href='/profiles/{uid}' title='{first_name}'><img class='fb_square' src='{pic_square}'/><div>{first_name}</div></a>");
		html.push("</div>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["fbDialogUser"] = function(){
	
	strCacheKey = "fbDialogUser";
	
	if(!isUsable(_tmpl.cached[strCacheKey])){
		
		var html = [];

		html.push("<tr class='user'>");
		html.push("<td class='photo'>");
		html.push("<a class='user' href='/profiles/{uid}' title='{name}'><img class='fb_square' src='{pic_square}'/></a>");
		html.push("</td>");
		html.push("<td class='name b f16'");
		html.push("<a class='ac' href='/profiles/{uid}' title='{name}'>{name}</a>");
		html.push("</td>");
		html.push("<td class='status status_{user_status}'>");
		html.push("<span>&nbsp;</span>");
		html.push("</td>");
		html.push("</tr>");

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["gmapTooltip"] = function(strType){
	
	//log("tmpl.gmapTooltip(" + strType + ") (2992151)");
	
	strCacheKey = "gmapTooltip_" + strType;

	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];
		
		switch(strType){
			case "event":
				
				//EXPECTS:
				//.count
				//.event_url
				//.event_name
				//[.address]
				//[.stats]
				//> [.total_going]
				//> [.friend_count]
				//> [.gender_f]
				//> [.gender_m]
				
				html.push("<div id='divTooltip{count}' class='tooltip'>");
				html.push("<a class='title' href='{venue_url}' target='_top'>{venue_name}</a>");
				//html.push("<a class='title' href='{event_url}' target='_top'>{event_name}</a>");
				html.push("<div class='details'>");
				html.push("");
				html.push("{.section address}");
				html.push("<div class='address'>");
				html.push(" {address}");
				html.push("</div>");
				html.push("{.end}");
				html.push("");
				html.push("{.section stats}");
				html.push("	<div class='stat stat_crowd'>");
				html.push("   <span class='name'>Crowd:</span>");
				html.push("   <span class='value'>");
				html.push("	    <a class='crowd' href='javascript: void _dialog.attendees(\"event\", \"crowd\", this, true); '>{total_going} people</a>, ");
				html.push("	    <a class='friends' href='javascript: void _dialog.attendees(\"event\", \"friends\", this, true); '>{friend_count} friends</a>");
				html.push("	</span>");
				html.push("	");
				html.push("	</div>");
				html.push("	<div class='stat stat_gender'>");
				html.push("   <span class='name'>Gender:</span>");
				html.push("   <span class='value'>{gender_m}% male, {gender_f}% female</span>");
				html.push("	</div>");
				html.push("{.end}");
				
				html.push("");
			
				html.push("</div>");
				html.push("</div>");
		
				break;
			case "venue":
			
				//EXPECTS:
				//.count
				//.venue_name
				//.venue_url
				//[.address]
				//[.stats]
				//> [.total_going]
				//> [.friend_count]
				//> [.gender_f]
				//> [.gender_m]
				
				html.push("<div id='divTooltip{count}' class='tooltip'>");
				html.push("<a class='title' href='{venue_url}' target='_top'>{venue_name}</a>");
				html.push("<div class='details'>");
				html.push("");
				html.push("{.section address}");
				html.push("<div class='address'>");
				html.push(" {address}");
				html.push("</div>");
				html.push("{.end}");
				html.push("");
				html.push("{.section stats}");
				html.push("	<div class='stat stat_crowd'>");
				html.push("   <span class='name'>Crowd:</span>");
				html.push("   <span class='value'>");
				html.push("	    <a class='crowd' href='javascript: void _dialog.attendees(\"venue\", \"crowd\", this, true); '>{total_going} people</a>, ");
				html.push("	    <a class='friends' href='javascript: void _dialog.attendees(\"venue\", \"friends\", this, true); '>{friend_count} friends</a>");
				html.push("	</span>");
				html.push("	");
				html.push("	</div>");
				html.push("	<div class='stat stat_gender'>");
				html.push("   <span class='name'>Gender:</span>");
				html.push("   <span class='value'>{gender_m}% male, {gender_f}% female</span>");
				html.push("	</div>");
				html.push("{.end}");
				
				html.push("");
			
				html.push("</div>");
				html.push("</div>");
		
				break;
			default:
			
				log("unrecognized strType (5685351)");
				
			break;
		}
		
		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
				
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["attendeeURL"] = function(strType){
	
	strCacheKey = "attendeeURL_" + strType;
	
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];

		switch(strType){
			case "event":
			
				html.push("/pop/{pop}/going?type={type}&src=f&id={event_id}&count=" + _dialog.pageSize + "&page=%PAGE_INDEX%&format=json");
			
				break;
			case "venue":
		
				html.push("/pop/{pop}/going?type={type}&src=f&lat={lat}&long={lon}&start_datetime={start}&end_datetime={end}&count=" + _dialog.pageSize + "&page=%PAGE_INDEX%&format=json");
			
				break;
			default:
				log("invalid prms.type: " + strType + " (2062534)");
				break;
		}

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------
_tmpl["gmapDirectionsStep"] = function(){
	
	strCacheKey = "gmapDirectionsStep";
	
	if(!isUsable(_tmpl.cached[strCacheKey])){

		var html = [];

		html.push("<li class='step step_{index}'>");	
		html.push("   <span class='instr'>{instructions}</span>");	
		html.push("   <span class='details gray'>{distance}, {duration}</span>");	
		html.push("</li>");	

		//CACHE THIS TEMPLATE		
		_tmpl.cached[strCacheKey] = jsontemplate.Template(html.join(""));
		
	}
	
	return _tmpl.cached[strCacheKey];
	
};

//--------------------------------------------------------

//--------------------------------------------------------


// Copyright (C) 2009 Andy Chu
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//      http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

// $Id$

//
// JavaScript implementation of json-template.
//

// This is predefined in tests, shouldn't be defined anywhere else.  TODO: Do
// something nicer.
var log = log || function() {};
var repr = repr || function() {};


// The "module" exported by this script is called "jsontemplate":

var jsontemplate = function() {


// Regex escaping for metacharacters
function EscapeMeta(meta) {
  return meta.replace(/([\{\}\(\)\[\]\|\^\$\-\+\?])/g, '\\$1');
}

var token_re_cache = {};

function _MakeTokenRegex(meta_left, meta_right) {
  var key = meta_left + meta_right;
  var regex = token_re_cache[key];
  if (regex === undefined) {
    var str = '(' + EscapeMeta(meta_left) + '.*?' + EscapeMeta(meta_right) +
              '\n?)';
    regex = new RegExp(str, 'g');
  }
  return regex;
}

//
// Formatters
//

function HtmlEscape(s) {
  return s.replace(/&/g,'&amp;').
           replace(/>/g,'&gt;').
           replace(/</g,'&lt;');
}

function HtmlTagEscape(s) {
  return s.replace(/&/g,'&amp;').
           replace(/>/g,'&gt;').
           replace(/</g,'&lt;').
           replace(/"/g,'&quot;');
}

// Default ToString can be changed
function ToString(s) {
  if (s === null) {
    return 'null';
  }
  return s.toString();
}

// Formatter to pluralize words
function _Pluralize(value, unused_context, args) {
  var s, p;
  switch (args.length) {
    case 0:
      s = ''; p = 's';
      break;
    case 1:
      s = ''; p = args[0];
      break;
    case 2:
      s = args[0]; p = args[1];
      break;
    default:
      // Should have been checked at compile time
      throw {
        name: 'EvaluationError', message: 'pluralize got too many args'
      };
  }
  return (value > 1) ? p : s;
}

function _Cycle(value, unused_context, args) {
  // Cycle between various values on consecutive integers.
  // @index starts from 1, so use 1-based indexing.
  return args[(value - 1) % args.length];
}

var DEFAULT_FORMATTERS = {
  'html': HtmlEscape,
  'htmltag': HtmlTagEscape,
  'html-attr-value': HtmlTagEscape,
  'str': ToString,
  'raw': function(x) { return x; },
  'AbsUrl': function(value, context) {
    // TODO: Normalize leading/trailing slashes
    return context.get('base-url') + '/' + value;
  }
};

var DEFAULT_PREDICATES = {
  'singular?': function(x) { return  x == 1; },
  'plural?': function(x) { return x > 1; },
  'Debug?': function(unused, context) {
    try {
      return context.get('debug');
    } catch(err) {
      if (err.name == 'UndefinedVariable') {
        return false;
      } else {
        throw err;
      }
    }
  }
};

var FunctionRegistry = function() {
  return {
    lookup: function(user_str) {
      return [null, null];
    }
  };
};

var SimpleRegistry = function(obj) {
  return {
    lookup: function(user_str) {
      var func = obj[user_str] || null;
      return [func, null];
    }
  };
};

var CallableRegistry = function(callable) {
  return {
    lookup: function(user_str) {
      var func = callable(user_str);
      return [func, null];
    }
  };
};

// Default formatters which can't be expressed in DEFAULT_FORMATTERS
var PrefixRegistry = function(functions) {
  return {
    lookup: function(user_str) {
      for (var i = 0; i < functions.length; i++) {
        var name = functions[i].name, func = functions[i].func;
        if (user_str.slice(0, name.length) == name) {
          // Delimiter is usually a space, but could be something else
          var args;
          var splitchar = user_str.charAt(name.length);
          if (splitchar === '') {
            args = [];  // No arguments
          } else {
            args = user_str.split(splitchar).slice(1);
          }
          return [func, args];
        } 
      }
      return [null, null];  // No formatter
    }
  };
};

var ChainedRegistry = function(registries) {
  return {
    lookup: function(user_str) {
      for (var i=0; i<registries.length; i++) {
        var result = registries[i].lookup(user_str);
        if (result[0]) {
          return result;
        }
      }
      return [null, null];  // Nothing found
    }
  };
};

//
// Template implementation
//

function _ScopedContext(context, undefined_str) {
  // The stack contains:
  //   The current context (an object).
  //   An iteration index.  -1 means we're NOT iterating.
  var stack = [{context: context, index: -1}];

  return {
    PushSection: function(name) {
      if (name === undefined || name === null) {
        return null;
      }
      var new_context;
      if (name == '@') {
        new_context = stack[stack.length-1].context;
      } else {
        new_context = stack[stack.length-1].context[name] || null;
      }
      stack.push({context: new_context, index: -1});
      return new_context;
    },

    Pop: function() {
      stack.pop();
    },

    next: function() {
      var stacktop = stack[stack.length-1];

      // Now we're iterating -- push a new mutable object onto the stack
      if (stacktop.index == -1) {
        stacktop = {context: null, index: 0};
        stack.push(stacktop);
      }

      // The thing we're iterating over
      var context_array = stack[stack.length-2].context;

      // We're already done
      if (stacktop.index == context_array.length) {
        stack.pop();
        return undefined;  // sentinel to say that we're done
      }

      stacktop.context = context_array[stacktop.index++];
      return true;  // OK, we mutated the stack
    },

    _Undefined: function(name) {
      if (undefined_str === undefined) {
        throw {
          name: 'UndefinedVariable', message: name + ' is not defined'
        };
      } else {
        return undefined_str;
      }
    },

    _LookUpStack: function(name) {
      var i = stack.length - 1;
      while (true) {
        var frame = stack[i];
        if (name == '@index') {
          if (frame.index != -1) {  // -1 is undefined
            return frame.index;
          }
        } else {
          var context = frame.context;
          if (typeof context === 'object') {
            var value = context[name];
            if (value !== undefined) {
              return value;
            }
          }
        }
        i--;
        if (i <= -1) {
          return this._Undefined(name);
        }
      }
    },

    get: function(name) {
      if (name == '@') {
        return stack[stack.length-1].context;
      }
      var parts = name.split('.');
      var value = this._LookUpStack(parts[0]);
      if (parts.length > 1) {
        for (var i=1; i<parts.length; i++) {
          value = value[parts[i]];
          if (value === undefined) {
            return this._Undefined(parts[i]);
          }
        }
      }
      return value;
    }

  };
}


// Crockford's "functional inheritance" pattern

var _AbstractSection = function(spec) {
  var that = {};
  that.current_clause = [];

  that.Append = function(statement) {
    that.current_clause.push(statement);
  };

  that.AlternatesWith = function() {
    throw {
      name: 'TemplateSyntaxError',
      message:
          '{.alternates with} can only appear with in {.repeated section ...}'
    };
  };

  that.NewOrClause = function(pred) {
    throw { name: 'NotImplemented' };  // "Abstract"
  };

  return that;
};

var _Section = function(spec) {
  var that = _AbstractSection(spec);
  that.statements = {'default': that.current_clause};

  that.section_name = spec.section_name;

  that.Statements = function(clause) {
    clause = clause || 'default';
    return that.statements[clause] || [];
  };

  that.NewOrClause = function(pred) {
    if (pred) {
      throw {
        name: 'TemplateSyntaxError',
        message: '{.or} clause only takes a predicate inside predicate blocks'
      };
    }
    that.current_clause = [];
    that.statements['or'] = that.current_clause;
  };

  return that;
};

// Repeated section is like section, but it supports {.alternates with}
var _RepeatedSection = function(spec) {
  var that = _Section(spec);

  that.AlternatesWith = function() {
    that.current_clause = [];
    that.statements['alternate'] = that.current_clause;
  };

  return that;
};

// Represents a sequence of predicate clauses.
var _PredicateSection = function(spec) {
  var that = _AbstractSection(spec);
  // Array of func, statements
  that.clauses = [];

  that.NewOrClause = function(pred) {
    // {.or} always executes if reached, so use identity func with no args
    pred = pred || [function(x) { return true; }, null];
    that.current_clause = [];
    that.clauses.push([pred, that.current_clause]);
  };

  return that;
};


function _Execute(statements, context, callback) {
  for (var i=0; i<statements.length; i++) {
  	try{
	    var statement = statements[i];
	    if (typeof(statement) == 'string') {
	      callback(statement);
	    } else {
	      var func = statement[0];
	      var args = statement[1];
	      func(args, context, callback);
	    }
	}
	catch(e){
		log("json-template: " + e.message + " (8917087)");
	}
  }
}

function _DoSubstitute(statement, context, callback) {
  var value;
  value = context.get(statement.name);

  // Format values
  for (var i=0; i<statement.formatters.length; i++) {
    var pair = statement.formatters[i];
    var formatter = pair[0];
    var args = pair[1];
    value = formatter(value, context, args);
  }

  callback(value);
}

// for [section foo]
function _DoSection(args, context, callback) {

  var block = args;
  var value = context.PushSection(block.section_name);
  var do_section = false;

  // "truthy" values should have their sections executed.
  if (value) {
    do_section = true;
  }
  // Except: if the value is a zero-length array (which is "truthy")
  if (value && value.length === 0) {
    do_section = false;
  }

  if (do_section) {
    _Execute(block.Statements(), context, callback);
    context.Pop();
  } else {  // Empty list, None, False, etc.
    context.Pop();
    _Execute(block.Statements('or'), context, callback);
  }
}

// {.pred1?} A {.or pred2?} B ... {.or} Z {.end}
function _DoPredicates(args, context, callback) {
  // Here we execute the first clause that evaluates to true, and then stop.
  var block = args;
  var value = context.get('@');
  for (var i=0; i<block.clauses.length; i++) {
    var clause = block.clauses[i];
    var predicate = clause[0][0];
    var pred_args = clause[0][1];
    var statements = clause[1];

    var do_clause = predicate(value, context, pred_args);
    if (do_clause) {
      _Execute(statements, context, callback);
      break;
    }
  }
}


function _DoRepeatedSection(args, context, callback) {
  var block = args;

  items = context.PushSection(block.section_name);
  pushed = true;

  if (items && items.length > 0) {
    // TODO: check that items is an array; apparently this is hard in JavaScript
    //if type(items) is not list:
    //  raise EvaluationError('Expected a list; got %s' % type(items))

    // Execute the statements in the block for every item in the list.
    // Execute the alternate block on every iteration except the last.  Each
    // item could be an atom (string, integer, etc.) or a dictionary.
    
    var last_index = items.length - 1;
    var statements = block.Statements();
    var alt_statements = block.Statements('alternate');

    for (var i=0; context.next() !== undefined; i++) {
      _Execute(statements, context, callback);
      if (i != last_index) {
        _Execute(alt_statements, context, callback);
      }
    }
  } else {
    _Execute(block.Statements('or'), context, callback);
  }

  context.Pop();
}


var _SECTION_RE = /(repeated)?\s*(section)\s+(\S+)?/;
var _OR_RE = /or(?:\s+(.+))?/;
var _IF_RE = /if(?:\s+(.+))?/;


// Turn a object literal, function, or Registry into a Registry
function MakeRegistry(obj) {
  if (!obj) {
    // if null/undefined, use a totally empty FunctionRegistry
    return new FunctionRegistry();
  } else if (typeof obj === 'function') {
    return new CallableRegistry(obj);
  } else if (obj.lookup !== undefined) {
    // TODO: Is this a good pattern?  There is a namespace conflict where get
    // could be either a formatter or a method on a FunctionRegistry.
    // instanceof might be more robust.
    return obj;
  } else if (typeof obj === 'object') {
    return new SimpleRegistry(obj);
  }
}

// TODO: The compile function could be in a different module, in case we want to
// compile on the server side.
function _Compile(template_str, options) {
  var more_formatters = MakeRegistry(options.more_formatters);

  // default formatters with arguments
  var default_formatters = PrefixRegistry([
      {name: 'pluralize', func: _Pluralize},
      {name: 'cycle', func: _Cycle}
      ]);
  var all_formatters = new ChainedRegistry([
      more_formatters,
      SimpleRegistry(DEFAULT_FORMATTERS),
      default_formatters
      ]);

  var more_predicates = MakeRegistry(options.more_predicates);

  // TODO: Add defaults
  var all_predicates = new ChainedRegistry([
      more_predicates, SimpleRegistry(DEFAULT_PREDICATES)
      ]);

  // We want to allow an explicit null value for default_formatter, which means
  // that an error is raised if no formatter is specified.
  var default_formatter;
  if (options.default_formatter === undefined) {
    default_formatter = 'str';
  } else {
    default_formatter = options.default_formatter;
  }

  function GetFormatter(format_str) {
    var pair = all_formatters.lookup(format_str);
    if (!pair[0]) {
      throw {
        name: 'BadFormatter',
        message: format_str + ' is not a valid formatter'
      };
    }
    return pair;
  }

  function GetPredicate(pred_str) {
    var pair = all_predicates.lookup(pred_str);
    if (!pair[0]) {
      throw {
        name: 'BadPredicate',
        message: pred_str + ' is not a valid predicate'
      };
    }
    return pair;
  }

  var format_char = options.format_char || '|';
  if (format_char != ':' && format_char != '|') {
    throw {
      name: 'ConfigurationError',
      message: 'Only format characters : and | are accepted'
    };
  }

  var meta = options.meta || '{}';
  var n = meta.length;
  if (n % 2 == 1) {
    throw {
      name: 'ConfigurationError',
      message: meta + ' has an odd number of metacharacters'
    };
  }
  var meta_left = meta.substring(0, n/2);
  var meta_right = meta.substring(n/2, n);

  var token_re = _MakeTokenRegex(meta_left, meta_right);
  var current_block = _Section({});
  var stack = [current_block];

  var strip_num = meta_left.length;  // assume they're the same length

  var token_match;
  var last_index = 0;

  while (true) {
    token_match = token_re.exec(template_str);
    if (token_match === null) {
      break;
    } else {
      var token = token_match[0];
    }

    // Add the previous literal to the program
    if (token_match.index > last_index) {
      var tok = template_str.slice(last_index, token_match.index);
      current_block.Append(tok);
    }
    last_index = token_re.lastIndex;

    var had_newline = false;
    if (token.slice(-1) == '\n') {
      token = token.slice(null, -1);
      had_newline = true;
    }

    token = token.slice(strip_num, -strip_num);

    if (token.charAt(0) == '#') {
      continue;  // comment
    }

    if (token.charAt(0) == '.') {  // Keyword
      token = token.substring(1, token.length);

      var literal = {
          'meta-left': meta_left,
          'meta-right': meta_right,
          'space': ' ',
          'tab': '\t',
          'newline': '\n'
          }[token];

      if (literal !== undefined) {
        current_block.Append(literal);
        continue;
      }

      var new_block, func;

      var section_match = token.match(_SECTION_RE);
      if (section_match) {
        var repeated = section_match[1];
        var section_name = section_match[3];

        if (repeated) {
          func = _DoRepeatedSection;
          new_block = _RepeatedSection({section_name: section_name});
        } else {
          func = _DoSection;
          new_block = _Section({section_name: section_name});
        }
        current_block.Append([func, new_block]);
        stack.push(new_block);
        current_block = new_block;
        continue;
      }

      var pred_str, pred;

      // Check {.or pred?} before {.pred?}
      var or_match = token.match(_OR_RE);
      if (or_match) {
        pred_str = or_match[1];
        pred = pred_str ? GetPredicate(pred_str) : null;
        current_block.NewOrClause(pred);
        continue;
      }

      // Match either {.pred?} or {.if pred?}
      var matched = false;

      var if_match = token.match(_IF_RE);
      if (if_match) {
        pred_str = if_match[1];
        matched = true;
      } else if (token.charAt(token.length-1) == '?') {
        pred_str = token;
        matched = true;
      }
      if (matched) {
        pred = pred_str ? GetPredicate(pred_str) : null;
        new_block = _PredicateSection();
        new_block.NewOrClause(pred);
        current_block.Append([_DoPredicates, new_block]);
        stack.push(new_block);
        current_block = new_block;
        continue;
      }

      if (token == 'alternates with') {
        current_block.AlternatesWith();
        continue;
      }

      if (token == 'end') {
        // End the block
        stack.pop();
        if (stack.length > 0) {
          current_block = stack[stack.length-1];
        } else {
          throw {
            name: 'TemplateSyntaxError',
            message: 'Got too many {end} statements'
          };
        }
        continue;
      }
    }

    // A variable substitution
    var parts = token.split(format_char);
    var formatters;
    var name;
    if (parts.length == 1) {
      if (default_formatter === null) {
          throw {
            name: 'MissingFormatter',
            message: 'This template requires explicit formatters.'
          };
      }
      // If no formatter is specified, use the default.
      formatters = [GetFormatter(default_formatter)];
      name = token;
    } else {
      formatters = [];
      for (var j=1; j<parts.length; j++) {
        formatters.push(GetFormatter(parts[j]));
      }
      name = parts[0];
    }
    current_block.Append([_DoSubstitute, {name: name, formatters: formatters}]);
    if (had_newline) {
      current_block.Append('\n');
    }
  }

  // Add the trailing literal
  current_block.Append(template_str.slice(last_index));

  if (stack.length !== 1) {
    throw {
      name: 'TemplateSyntaxError',
      message: 'Got too few {end} statements'
    };
  }
  return current_block;
}

// The Template class is defined in the traditional style so that users can add
// methods by mutating the prototype attribute.  TODO: Need a good idiom for
// inheritance without mutating globals.

function Template(template_str, options) {

  // Add 'new' if we were not called with 'new', so prototyping works.
  if(!(this instanceof Template)) {
    return new Template(template_str, options);
  }

  this._options = options || {};
  this._program = _Compile(template_str, this._options);
}

Template.prototype.render = function(data_dict, callback) {
  // options.undefined_str can either be a string or undefined
  var context = _ScopedContext(data_dict, this._options.undefined_str);
  _Execute(this._program.Statements(), context, callback);
};

Template.prototype.expand = function(data_dict) {
  var tokens = [];
  this.render(data_dict, function(x) { tokens.push(x); });
  return tokens.join('');
};

// fromString is a construction method that allows metadata to be written at the
// beginning of the template string.  See Python's FromFile for a detailed
// description of the format.
//
// The argument 'options' takes precedence over the options in the template, and
// can be used for non-serializable options like template formatters.

var OPTION_RE = /^([a-zA-Z\-]+):\s*(.*)/;
var OPTION_NAMES = [
    'meta', 'format-char', 'default-formatter', 'undefined-str'];
// Use this "linear search" instead of Array.indexOf, which is nonstandard
var OPTION_NAMES_RE = new RegExp(OPTION_NAMES.join('|'));

function fromString(s, options) {
  var parsed = {};
  var begin = 0, end = 0;

  while (true) {
    var parsedOption = false;
    end = s.indexOf('\n', begin);
    if (end == -1) {
      break;
    }
    var line = s.slice(begin, end);
    begin = end+1;
    var match = line.match(OPTION_RE);
    if (match !== null) {
      var name = match[1].toLowerCase(), value = match[2];
      if (name.match(OPTION_NAMES_RE)) {
        name = name.replace('-', '_');
        value = value.replace(/^\s+/, '').replace(/\s+$/, '');
        if (name == 'default_formatter' && value.toLowerCase() == 'none') {
          value = null;
        }
        parsed[name] = value;
        parsedOption = true;
      }
    }
    if (!parsedOption) {
      break;
    }
  }
  // TODO: This doesn't enforce the blank line between options and template, but
  // that might be more trouble than it's worth
  if (parsed !== {}) {
    body = s.slice(begin);
  } else {
    body = s;
  }
  for (var o in options) {
    parsed[o] = options[o];
  }
  return Template(body, parsed);
}


// We just export one name for now, the Template "class".
// We need HtmlEscape in the browser tests, so might as well export it.

return {
    Template: Template, HtmlEscape: HtmlEscape,
    FunctionRegistry: FunctionRegistry, SimpleRegistry: SimpleRegistry,
    CallableRegistry: CallableRegistry, ChainedRegistry: ChainedRegistry,
    fromString: fromString,
    // Private but exposed for testing
    _Section: _Section
    };

}();


/*
    http://www.JSON.org/json2.js
    2008-05-25

    Public Domain.

    NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.

    See http://www.JSON.org/js.html

    This file creates a global JSON object containing two methods: stringify
    and parse.

        JSON.stringify(value, replacer, space)
            value       any JavaScript value, usually an object or array.

            replacer    an optional parameter that determines how object
                        values are stringified for objects without a toJSON
                        method. It can be a function or an array.

            space       an optional parameter that specifies the indentation
                        of nested structures. If it is omitted, the text will
                        be packed without extra whitespace. If it is a number,
                        it will specify the number of spaces to indent at each
                        level. If it is a string (such as '\t' or '&nbsp;'),
                        it contains the characters used to indent at each level.

            This method produces a JSON text from a JavaScript value.

            When an object value is found, if the object contains a toJSON
            method, its toJSON method will be called and the result will be
            stringified. A toJSON method does not serialize: it returns the
            value represented by the name/value pair that should be serialized,
            or undefined if nothing should be serialized. The toJSON method
            will be passed the key associated with the value, and this will be
            bound to the object holding the key.

            For example, this would serialize Dates as ISO strings.

                Date.prototype.toJSON = function (key) {
                    function f(n) {
                        // Format integers to have at least two digits.
                        return n < 10 ? '0' + n : n;
                    }

                    return this.getUTCFullYear()   + '-' +
                         f(this.getUTCMonth() + 1) + '-' +
                         f(this.getUTCDate())      + 'T' +
                         f(this.getUTCHours())     + ':' +
                         f(this.getUTCMinutes())   + ':' +
                         f(this.getUTCSeconds())   + 'Z';
                };

            You can provide an optional replacer method. It will be passed the
            key and value of each member, with this bound to the containing
            object. The value that is returned from your method will be
            serialized. If your method returns undefined, then the member will
            be excluded from the serialization.

            If the replacer parameter is an array, then it will be used to
            select the members to be serialized. It filters the results such
            that only members with keys listed in the replacer array are
            stringified.

            Values that do not have JSON representations, such as undefined or
            functions, will not be serialized. Such values in objects will be
            dropped; in arrays they will be replaced with null. You can use
            a replacer function to replace those with JSON values.
            JSON.stringify(undefined) returns undefined.

            The optional space parameter produces a stringification of the
            value that is filled with line breaks and indentation to make it
            easier to read.

            If the space parameter is a non-empty string, then that string will
            be used for indentation. If the space parameter is a number, then
            the indentation will be that many spaces.

            Example:

            text = JSON.stringify(['e', {pluribus: 'unum'}]);
            // text is '["e",{"pluribus":"unum"}]'


            text = JSON.stringify(['e', {pluribus: 'unum'}], null, '\t');
            // text is '[\n\t"e",\n\t{\n\t\t"pluribus": "unum"\n\t}\n]'

            text = JSON.stringify([new Date()], function (key, value) {
                return this[key] instanceof Date ?
                    'Date(' + this[key] + ')' : value;
            });
            // text is '["Date(---current time---)"]'


        JSON.parse(text, reviver)
            This method parses a JSON text to produce an object or array.
            It can throw a SyntaxError exception.

            The optional reviver parameter is a function that can filter and
            transform the results. It receives each of the keys and values,
            and its return value is used instead of the original value.
            If it returns what it received, then the structure is not modified.
            If it returns undefined then the member is deleted.

            Example:

            // Parse the text. Values that look like ISO date strings will
            // be converted to Date objects.

            myData = JSON.parse(text, function (key, value) {
                var a;
                if (typeof value === 'string') {
                    a =
/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/.exec(value);
                    if (a) {
                        return new Date(Date.UTC(+a[1], +a[2] - 1, +a[3], +a[4],
                            +a[5], +a[6]));
                    }
                }
                return value;
            });

            myData = JSON.parse('["Date(09/09/2001)"]', function (key, value) {
                var d;
                if (typeof value === 'string' &&
                        value.slice(0, 5) === 'Date(' &&
                        value.slice(-1) === ')') {
                    d = new Date(value.slice(5, -1));
                    if (d) {
                        return d;
                    }
                }
                return value;
            });


    This is a reference implementation. You are free to copy, modify, or
    redistribute.

    This code should be minified before deployment.
    See http://javascript.crockford.com/jsmin.html

    USE YOUR OWN COPY. IT IS EXTREMELY UNWISE TO LOAD CODE FROM SERVERS YOU DO
    NOT CONTROL.
*/

/*jslint evil: true */

/*global JSON */

/*members "", "\b", "\t", "\n", "\f", "\r", "\"", JSON, "\\", call,
    charCodeAt, getUTCDate, getUTCFullYear, getUTCHours, getUTCMinutes,
    getUTCMonth, getUTCSeconds, hasOwnProperty, join, lastIndex, length,
    parse, propertyIsEnumerable, prototype, push, replace, slice, stringify,
    test, toJSON, toString
*/

if (!this.JSON) {

// Create a JSON object only if one does not already exist. We create the
// object in a closure to avoid creating global variables.

    JSON = function () {

        function f(n) {
            // Format integers to have at least two digits.
            return n < 10 ? '0' + n : n;
        }

        Date.prototype.toJSON = function (key) {

            return this.getUTCFullYear()   + '-' +
                 f(this.getUTCMonth() + 1) + '-' +
                 f(this.getUTCDate())      + 'T' +
                 f(this.getUTCHours())     + ':' +
                 f(this.getUTCMinutes())   + ':' +
                 f(this.getUTCSeconds())   + 'Z';
        };

        var cx = /[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,
            escapeable = /[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,
            gap,
            indent,
            meta = {    // table of character substitutions
                '\b': '\\b',
                '\t': '\\t',
                '\n': '\\n',
                '\f': '\\f',
                '\r': '\\r',
                '"' : '\\"',
                '\\': '\\\\'
            },
            rep;


        function quote(string) {

// If the string contains no control characters, no quote characters, and no
// backslash characters, then we can safely slap some quotes around it.
// Otherwise we must also replace the offending characters with safe escape
// sequences.

            escapeable.lastIndex = 0;
            return escapeable.test(string) ?
                '"' + string.replace(escapeable, function (a) {
                    var c = meta[a];
                    if (typeof c === 'string') {
                        return c;
                    }
                    return '\\u' + ('0000' +
                            (+(a.charCodeAt(0))).toString(16)).slice(-4);
                }) + '"' :
                '"' + string + '"';
        }


        function str(key, holder) {

// Produce a string from holder[key].

            var i,          // The loop counter.
                k,          // The member key.
                v,          // The member value.
                length,
                mind = gap,
                partial,
                value = holder[key];

// If the value has a toJSON method, call it to obtain a replacement value.

            if (value && typeof value === 'object' &&
                    typeof value.toJSON === 'function') {
                value = value.toJSON(key);
            }

// If we were called with a replacer function, then call the replacer to
// obtain a replacement value.

            if (typeof rep === 'function') {
                value = rep.call(holder, key, value);
            }

// What happens next depends on the value's type.

            switch (typeof value) {
            case 'string':
                return quote(value);

            case 'number':

// JSON numbers must be finite. Encode non-finite numbers as null.

                return isFinite(value) ? String(value) : 'null';

            case 'boolean':
            case 'null':

// If the value is a boolean or null, convert it to a string. Note:
// typeof null does not produce 'null'. The case is included here in
// the remote chance that this gets fixed someday.

                return String(value);

// If the type is 'object', we might be dealing with an object or an array or
// null.

            case 'object':

// Due to a specification blunder in ECMAScript, typeof null is 'object',
// so watch out for that case.

                if (!value) {
                    return 'null';
                }

// Make an array to hold the partial results of stringifying this object value.

                gap += indent;
                partial = [];

// If the object has a dontEnum length property, we'll treat it as an array.

                if (typeof value.length === 'number' &&
                        !(value.propertyIsEnumerable('length'))) {

// The object is an array. Stringify every element. Use null as a placeholder
// for non-JSON values.

                    length = value.length;
                    for (i = 0; i < length; i += 1) {
                        partial[i] = str(i, value) || 'null';
                    }

// Join all of the elements together, separated with commas, and wrap them in
// brackets.

                    v = partial.length === 0 ? '[]' :
                        gap ? '[\n' + gap +
                                partial.join(',\n' + gap) + '\n' +
                                    mind + ']' :
                              '[' + partial.join(',') + ']';
                    gap = mind;
                    return v;
                }

// If the replacer is an array, use it to select the members to be stringified.

                if (rep && typeof rep === 'object') {
                    length = rep.length;
                    for (i = 0; i < length; i += 1) {
                        k = rep[i];
                        if (typeof k === 'string') {
                            v = str(k, value, rep);
                            if (v) {
                                partial.push(quote(k) + (gap ? ': ' : ':') + v);
                            }
                        }
                    }
                } else {

// Otherwise, iterate through all of the keys in the object.

                    for (k in value) {
                        if (Object.hasOwnProperty.call(value, k)) {
                            v = str(k, value, rep);
                            if (v) {
                                partial.push(quote(k) + (gap ? ': ' : ':') + v);
                            }
                        }
                    }
                }

// Join all of the member texts together, separated with commas,
// and wrap them in braces.

                v = partial.length === 0 ? '{}' :
                    gap ? '{\n' + gap + partial.join(',\n' + gap) + '\n' +
                            mind + '}' : '{' + partial.join(',') + '}';
                gap = mind;
                return v;
            }
        }

// Return the JSON object containing the stringify and parse methods.

        return {
            stringify: function (value, replacer, space) {

// The stringify method takes a value and an optional replacer, and an optional
// space parameter, and returns a JSON text. The replacer can be a function
// that can replace values, or an array of strings that will select the keys.
// A default replacer method can be provided. Use of the space parameter can
// produce text that is more easily readable.

                var i;
                gap = '';
                indent = '';

// If the space parameter is a number, make an indent string containing that
// many spaces.

                if (typeof space === 'number') {
                    for (i = 0; i < space; i += 1) {
                        indent += ' ';
                    }

// If the space parameter is a string, it will be used as the indent string.

                } else if (typeof space === 'string') {
                    indent = space;
                }

// If there is a replacer, it must be a function or an array.
// Otherwise, throw an error.

                rep = replacer;
                if (replacer && typeof replacer !== 'function' &&
                        (typeof replacer !== 'object' ||
                         typeof replacer.length !== 'number')) {
                    throw new Error('JSON.stringify');
                }

// Make a fake root object containing our value under the key of ''.
// Return the result of stringifying the value.

                return str('', {'': value});
            },


            parse: function (text, reviver) {

// The parse method takes a text and an optional reviver function, and returns
// a JavaScript value if the text is a valid JSON text.

                var j;

                function walk(holder, key) {

// The walk method is used to recursively walk the resulting structure so
// that modifications can be made.

                    var k, v, value = holder[key];
                    if (value && typeof value === 'object') {
                        for (k in value) {
                            if (Object.hasOwnProperty.call(value, k)) {
                                v = walk(value, k);
                                if (v !== undefined) {
                                    value[k] = v;
                                } else {
                                    delete value[k];
                                }
                            }
                        }
                    }
                    return reviver.call(holder, key, value);
                }


// Parsing happens in four stages. In the first stage, we replace certain
// Unicode characters with escape sequences. JavaScript handles many characters
// incorrectly, either silently deleting them, or treating them as line endings.

                cx.lastIndex = 0;
                if (cx.test(text)) {
                    text = text.replace(cx, function (a) {
                        return '\\u' + ('0000' +
                                (+(a.charCodeAt(0))).toString(16)).slice(-4);
                    });
                }

// In the second stage, we run the text against regular expressions that look
// for non-JSON patterns. We are especially concerned with '()' and 'new'
// because they can cause invocation, and '=' because it can cause mutation.
// But just to be safe, we want to reject all unexpected forms.

// We split the second stage into 4 regexp operations in order to work around
// crippling inefficiencies in IE's and Safari's regexp engines. First we
// replace the JSON backslash pairs with '@' (a non-JSON character). Second, we
// replace all simple value tokens with ']' characters. Third, we delete all
// open brackets that follow a colon or comma or that begin the text. Finally,
// we look to see that the remaining characters are only whitespace or ']' or
// ',' or ':' or '{' or '}'. If that is so, then the text is safe for eval.

                if (/^[\],:{}\s]*$/.
test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g, '@').
replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g, ']').
replace(/(?:^|:|,)(?:\s*\[)+/g, ''))) {

// In the third stage we use the eval function to compile the text into a
// JavaScript structure. The '{' operator is subject to a syntactic ambiguity
// in JavaScript: it can begin a block or an object literal. We wrap the text
// in parens to eliminate the ambiguity.

                    j = eval('(' + text + ')');

// In the optional fourth stage, we recursively walk the new structure, passing
// each name/value pair to a reviver function for possible transformation.

                    return typeof reviver === 'function' ?
                        walk({'': j}, '') : j;
                }

// If the text is not JSON parseable, then a SyntaxError is thrown.

                throw new SyntaxError('JSON.parse');
            }
        };
    }();
}


/**
 * Cookie plugin
 *
 * Copyright (c) 2006 Klaus Hartl (stilbuero.de)
 * Dual licensed under the MIT and GPL licenses:
 * http://www.opensource.org/licenses/mit-license.php
 * http://www.gnu.org/licenses/gpl.html
 *
 */

/**
 * Create a cookie with the given name and value and other optional parameters.
 *
 * @example $.cookie('the_cookie', 'the_value');
 * @desc Set the value of a cookie.
 * @example $.cookie('the_cookie', 'the_value', { expires: 7, path: '/', domain: 'jquery.com', secure: true });
 * @desc Create a cookie with all available options.
 * @example $.cookie('the_cookie', 'the_value');
 * @desc Create a session cookie.
 * @example $.cookie('the_cookie', null);
 * @desc Delete a cookie by passing null as value. Keep in mind that you have to use the same path and domain
 *       used when the cookie was set.
 *
 * @param String name The name of the cookie.
 * @param String value The value of the cookie.
 * @param Object options An object literal containing key/value pairs to provide optional cookie attributes.
 * @option Number|Date expires Either an integer specifying the expiration date from now on in days or a Date object.
 *                             If a negative value is specified (e.g. a date in the past), the cookie will be deleted.
 *                             If set to null or omitted, the cookie will be a session cookie and will not be retained
 *                             when the the browser exits.
 * @option String path The value of the path atribute of the cookie (default: path of page that created the cookie).
 * @option String domain The value of the domain attribute of the cookie (default: domain of page that created the cookie).
 * @option Boolean secure If true, the secure attribute of the cookie will be set and the cookie transmission will
 *                        require a secure protocol (like HTTPS).
 * @type undefined
 *
 * @name $.cookie
 * @cat Plugins/Cookie
 * @author Klaus Hartl/klaus.hartl@stilbuero.de
 */

/**
 * Get the value of a cookie with the given name.
 *
 * @example $.cookie('the_cookie');
 * @desc Get the value of a cookie.
 *
 * @param String name The name of the cookie.
 * @return The value of the cookie.
 * @type String
 *
 * @name $.cookie
 * @cat Plugins/Cookie
 * @author Klaus Hartl/klaus.hartl@stilbuero.de
 */
jQuery.cookie = function(name, value, options) {
    if (typeof value != 'undefined') { // name and value given, set cookie
        options = options || {};
        if (value === null) {
            value = '';
            options.expires = -1;
        }
        var expires = '';
        if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
            var date;
            if (typeof options.expires == 'number') {
                date = new Date();
                date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
            } else {
                date = options.expires;
            }
            expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
        }
        // CAUTION: Needed to parenthesize options.path and options.domain
        // in the following expressions, otherwise they evaluate to undefined
        // in the packed version for some reason...
        var path = options.path ? '; path=' + (options.path) : '';
        var domain = options.domain ? '; domain=' + (options.domain) : '';
        var secure = options.secure ? '; secure' : '';
        document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
    } else { // only name given, get cookie
        var cookieValue = null;
        if (document.cookie && document.cookie != '') {
            var cookies = document.cookie.split(';');
            for (var i = 0; i < cookies.length; i++) {
                var cookie = jQuery.trim(cookies[i]);
                // Does this cookie string begin with the name we want?
                if (cookie.substring(0, name.length + 1) == (name + '=')) {
                    cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
                    break;
                }
            }
        }
        return cookieValue;
    }
};

/** 
 * JSON Cookie - jquery.jsoncookie.js
 *
 * Sets and retreives native JavaScript objects as cookies.
 * Depends on the object serialization framework provided by JSON2.
 *
 * Dependencies: jQuery, jQuery Cookie, JSON2
 * 
 * @project JSON Cookie
 * @author Randall Morey
 * @version 0.9
 */
(function ($) {
	var isObject = function (x) {
		return (typeof x === 'object') && !(x instanceof Array) && (x !== null);
	};
	
	$.extend({
		getJSONCookie: function (cookieName) {
			var cookieData = $.cookie(cookieName);
			return cookieData ? JSON.parse(cookieData) : {};
		},
		setJSONCookie: function (cookieName, data, options) {
			var cookieData = '';
			
			options = $.extend({
				expires: 90,
				path: '/'
			}, options);
			
			if (!isObject(data)) {	// data must be a true object to be serialized
				throw new Error('JSONCookie data must be an object');
			}
			
			cookieData = JSON.stringify(data);
			
			return $.cookie(cookieName, cookieData, options);
		},
		removeJSONCookie: function (cookieName) {
			return $.cookie(cookieName, null);
		},
		JSONCookie: function (cookieName, data, options) {
			if (data) {
				$.setJSONCookie(cookieName, data, options);
			}
			return $.getJSONCookie(cookieName);
		}
	});
})(jQuery);


/*
 * jStore - Persistent Client-Side Storage
 *
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 * 
 * Dual licensed under:
 * 	MIT: http://www.opensource.org/licenses/mit-license.php
 *	GPLv3: http://www.opensource.org/licenses/gpl-3.0.html
 */
/*
 * jQuery JSON Plugin
 * version: 1.0 (2008-04-17)
 *
 * This document is licensed as free software under the terms of the
 * MIT License: http://www.opensource.org/licenses/mit-license.php
 *
 * Brantley Harris technically wrote this plugin, but it is based somewhat
 * on the JSON.org website's http://www.json.org/json2.js, which proclaims:
 * "NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.", a sentiment that
 * I uphold.  I really just cleaned it up.
 *
 * It is also based heavily on MochiKit's serializeJSON, which is 
 * copywrited 2005 by Bob Ippolito.
 */
(function($){function toIntegersAtLease(n){return n<10?"0"+n:n}Date.prototype.toJSON=function(date){return this.getUTCFullYear()+"-"+toIntegersAtLease(this.getUTCMonth())+"-"+toIntegersAtLease(this.getUTCDate())};var escapeable=/["\\\x00-\x1f\x7f-\x9f]/g;var meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};$.quoteString=function(string){if(escapeable.test(string)){return'"'+string.replace(escapeable,function(a){var c=meta[a];if(typeof c==="string"){return c}c=a.charCodeAt();return"\\u00"+Math.floor(c/16).toString(16)+(c%16).toString(16)})+'"'}return'"'+string+'"'};$.toJSON=function(o,compact){var type=typeof(o);if(type=="undefined"){return"undefined"}else{if(type=="number"||type=="boolean"){return o+""}else{if(o===null){return"null"}}}if(type=="string"){return $.quoteString(o)}if(type=="object"&&typeof o.toJSON=="function"){return o.toJSON(compact)}if(type!="function"&&typeof(o.length)=="number"){var ret=[];for(var i=0;i<o.length;i++){ret.push($.toJSON(o[i],compact))}if(compact){return"["+ret.join(",")+"]"}else{return"["+ret.join(", ")+"]"}}if(type=="function"){throw new TypeError("Unable to convert object of type 'function' to json.")}var ret=[];for(var k in o){var name;type=typeof(k);if(type=="number"){name='"'+k+'"'}else{if(type=="string"){name=$.quoteString(k)}else{continue}}var val=$.toJSON(o[k],compact);if(typeof(val)!="string"){continue}if(compact){ret.push(name+":"+val)}else{ret.push(name+": "+val)}}return"{"+ret.join(", ")+"}"};$.compactJSON=function(o){return $.toJSON(o,true)};$.evalJSON=function(src){return eval("("+src+")")};$.secureEvalJSON=function(src){var filtered=src;filtered=filtered.replace(/\\["\\\/bfnrtu]/g,"@");filtered=filtered.replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]");filtered=filtered.replace(/(?:^|:|,)(?:\s*\[)+/g,"");if(/^[\],:{}\s]*$/.test(filtered)){return eval("("+src+")")}else{throw new SyntaxError("Error parsing JSON, source is not valid.")}}})(jQuery);(function(){var a=false,b=/xyz/.test(function(){xyz})?/\b_super\b/:/.*/;this.Class=function(){};Class.extend=function(g){var f=this.prototype;a=true;var e=new this();a=false;for(var d in g){e[d]=typeof g[d]=="function"&&typeof f[d]=="function"&&b.test(g[d])?(function(h,i){return function(){var k=this._super;this._super=f[h];var j=i.apply(this,arguments);this._super=k;return j}})(d,g[d]):g[d]}function c(){if(!a&&this.init){this.init.apply(this,arguments)}}c.prototype=e;c.constructor=c;c.extend=arguments.callee;return c}})();
/*
 * jStore Delegate Framework
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 */
(function(a){this.jStoreDelegate=Class.extend({init:function(b){this.parent=b;this.callbacks={}},bind:function(b,c){if(!a.isFunction(c)){return this}if(!this.callbacks[b]){this.callbacks[b]=[]}this.callbacks[b].push(c);return this},trigger:function(){var d=this.parent,c=[].slice.call(arguments),e=c.shift(),b=this.callbacks[e];if(!b){return false}a.each(b,function(){this.apply(d,c)});return this}})})(jQuery);(function(b){var a;try{a=new RegExp('^("(\\\\.|[^"\\\\\\n\\r])*?"|[,:{}\\[\\]0-9.\\-+Eaeflnr-u \\n\\r\\t])+?$')}catch(c){a=/^(true|false|null|\[.*\]|\{.*\}|".*"|\d+|\d+\.\d+)$/}b.jStore={};b.extend(b.jStore,{EngineOrder:[],Availability:{},Engines:{},Instances:{},CurrentEngine:null,defaults:{project:null,engine:null,autoload:true,flash:"jStore.Flash.html"},isReady:false,isFlashReady:false,delegate:new jStoreDelegate(b.jStore).bind("jStore-ready",function(d){b.jStore.isReady=true;if(b.jStore.defaults.autoload){d.connect()}}).bind("flash-ready",function(){b.jStore.isFlashReady=true}),ready:function(d){if(b.jStore.isReady){d.apply(b.jStore,[b.jStore.CurrentEngine])}else{b.jStore.delegate.bind("jStore-ready",d)}},fail:function(d){b.jStore.delegate.bind("jStore-failure",d)},flashReady:function(d){if(b.jStore.isFlashReady){d.apply(b.jStore,[b.jStore.CurrentEngine])}else{b.jStore.delegate.bind("flash-ready",d)}},use:function(g,i,f){i=i||b.jStore.defaults.project||location.hostname.replace(/\./g,"-")||"unknown";var h=b.jStore.Engines[g.toLowerCase()]||null,d=(f?f+".":"")+i+"."+g;if(!h){throw"JSTORE_ENGINE_UNDEFINED"}h=new h(i,d);if(b.jStore.Instances[d]){throw"JSTORE_JRI_CONFLICT"}if(h.isAvailable()){b.jStore.Instances[d]=h;if(!b.jStore.CurrentEngine){b.jStore.CurrentEngine=h}b.jStore.delegate.trigger("jStore-ready",h)}else{if(!h.autoload){throw"JSTORE_ENGINE_UNAVILABLE"}else{h.included(function(){if(this.isAvailable()){b.jStore.Instances[d]=this;if(!b.jStore.CurrentEngine){b.jStore.CurrentEngine=this}b.jStore.delegate.trigger("jStore-ready",this)}else{b.jStore.delegate.trigger("jStore-failure",this)}}).include()}}},setCurrentEngine:function(d){if(!b.jStore.Instances.length){return b.jStore.FindEngine()}if(!d&&b.jStore.Instances.length>=1){b.jStore.delegate.trigger("jStore-ready",b.jStore.Instances[0]);return b.jStore.CurrentEngine=b.jStore.Instances[0]}if(d&&b.jStore.Instances[d]){b.jStore.delegate.trigger("jStore-ready",b.jStore.Instances[d]);return b.jStore.CurrentEngine=b.jStore.Instances[d]}throw"JSTORE_JRI_NO_MATCH"},FindEngine:function(){b.each(b.jStore.EngineOrder,function(d){if(b.jStore.Availability[this]()){b.jStore.use(this,b.jStore.defaults.project,"default");return false}})},load:function(){if(b.jStore.defaults.engine){return b.jStore.use(b.jStore.defaults.engine,b.jStore.defaults.project,"default")}try{b.jStore.FindEngine()}catch(d){}},safeStore:function(d){switch(typeof d){case"object":case"function":return b.jStore.compactJSON(d);case"number":case"boolean":case"string":case"xml":return d;case"undefined":default:return""}},safeResurrect:function(d){return a.test(d)?b.evalJSON(d):d},store:function(d,e){if(!b.jStore.CurrentEngine){return false}if(!e){return b.jStore.CurrentEngine.get(d)}return b.jStore.CurrentEngine.set(d,e)},remove:function(d){if(!b.jStore.CurrentEngine){return false}return b.jStore.CurrentEngine.rem(d)},get:function(d){return b.jStore.store(d)},set:function(d,e){return b.jStore.store(d,e)}});b.extend(b.fn,{store:function(e,f){if(!b.jStore.CurrentEngine){return this}var d=b.jStore.store(e,f);return !f?d:this},removeStore:function(d){b.jStore.remove(d);return this},getStore:function(d){return b.jStore.store(d)},setStore:function(d,e){b.jStore.store(d,e);return this}})})(jQuery);(function(a){this.StorageEngine=Class.extend({init:function(c,b){this.project=c;this.jri=b;this.data={};this.limit=-1;this.includes=[];this.delegate=new jStoreDelegate(this).bind("engine-ready",function(){this.isReady=true}).bind("engine-included",function(){this.hasIncluded=true});this.autoload=false;this.isReady=false;this.hasIncluded=false},include:function(){var b=this,d=this.includes.length,c=0;a.each(this.includes,function(){a.ajax({type:"get",url:this,dataType:"script",cache:true,success:function(){c++;if(c==d){b.delegate.trigger("engine-included")}}})})},isAvailable:function(){return false},interruptAccess:function(){if(!this.isReady){throw"JSTORE_ENGINE_NOT_READY"}},ready:function(b){if(this.isReady){b.apply(this)}else{this.delegate.bind("engine-ready",b)}return this},included:function(b){if(this.hasIncluded){b.apply(this)}else{this.delegate.bind("engine-included",b)}return this},get:function(b){this.interruptAccess();return this.data[b]||null},set:function(b,c){this.interruptAccess();this.data[b]=c;return c},rem:function(b){this.interruptAccess();var c=this.data[b];this.data[b]=null;return c}})})(jQuery);
/*
 * jStore DOM Storage Engine
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 */
(function(c){var b=c.jStore.Availability.session=function(){return !!window.sessionStorage},a=c.jStore.Availability.local=function(){return !!(window.localStorage||window.globalStorage)};this.jStoreDom=StorageEngine.extend({init:function(e,d){this._super(e,d);this.type="DOM";this.limit=5*1024*1024},connect:function(){this.delegate.trigger("engine-ready")},get:function(e){this.interruptAccess();var d=this.db.getItem(e);return c.jStore.safeResurrect((d&&d.value?d.value:d))},set:function(d,e){this.interruptAccess();this.db.setItem(d,c.jStore.safeStore(e));return e},rem:function(e){this.interruptAccess();var d=this.get(e);this.db.removeItem(e);return d}});this.jStoreLocal=jStoreDom.extend({connect:function(){this.db=!window.globalStorage?window.localStorage:window.globalStorage[location.hostname];this._super()},isAvailable:a});this.jStoreSession=jStoreDom.extend({connect:function(){this.db=sessionStorage;this._super()},isAvailable:b});c.jStore.Engines.local=jStoreLocal;c.jStore.Engines.session=jStoreSession;c.jStore.EngineOrder[1]="local"})(jQuery);
/*
 * jStore Flash Storage Engine
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 * jStore.swf Copyright (c) 2008 Daniel Bulli (http://www.nuff-respec.com)
 */
(function(b){var a=b.jStore.Availability.flash=function(){return !!(b.jStore.hasFlash("8.0.0"))};this.jStoreFlash=StorageEngine.extend({init:function(e,d){this._super(e,d);this.type="Flash";var c=this;b.jStore.flashReady(function(){c.flashReady()})},connect:function(){var c="jstore-flash-embed-"+this.project;b(document.body).append('<iframe style="height:1px;width:1px;position:absolute;left:0;top:0;margin-left:-100px;" id="jStoreFlashFrame" src="'+b.jStore.defaults.flash+'"></iframe>')},flashReady:function(f){var c=b("#jStoreFlashFrame")[0];if(c.Document&&b.isFunction(c.Document.jStoreFlash.f_get_cookie)){this.db=c.Document.jStoreFlash}else{if(c.contentWindow&&c.contentWindow.document){var d=c.contentWindow.document;if(b.isFunction(b("object",b(d))[0].f_get_cookie)){this.db=b("object",b(d))[0]}else{if(b.isFunction(b("embed",b(d))[0].f_get_cookie)){this.db=b("embed",b(d))[0]}}}}if(this.db){this.delegate.trigger("engine-ready")}},isAvailable:a,get:function(d){this.interruptAccess();var c=this.db.f_get_cookie(d);return c=="null"?null:b.jStore.safeResurrect(c)},set:function(c,d){this.interruptAccess();this.db.f_set_cookie(c,b.jStore.safeStore(d));return d},rem:function(c){this.interruptAccess();var d=this.get(c);this.db.f_delete_cookie(c);return d}});b.jStore.Engines.flash=jStoreFlash;b.jStore.EngineOrder[2]="flash";b.jStore.hasFlash=function(c){var e=b.jStore.flashVersion().match(/\d+/g),f=c.match(/\d+/g);for(var d=0;d<3;d++){e[d]=parseInt(e[d]||0);f[d]=parseInt(f[d]||0);if(e[d]<f[d]){return false}if(e[d]>f[d]){return true}}return true};b.jStore.flashVersion=function(){try{try{var c=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");try{c.AllowScriptAccess="always"}catch(d){return"6,0,0"}}catch(d){}return new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version").replace(/\D+/g,",").match(/^,?(.+),?$/)[1]}catch(d){try{if(navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin){return(navigator.plugins["Shockwave Flash 2.0"]||navigator.plugins["Shockwave Flash"]).description.replace(/\D+/g,",").match(/^,?(.+),?$/)[1]}}catch(d){}}return"0,0,0"}})(jQuery);function flash_ready(){$.jStore.delegate.trigger("flash-ready")}
/*
 * jStore Google Gears Storage Engine
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 */
(function(b){var a=b.jStore.Availability.gears=function(){return !!(window.google&&window.google.gears)};this.jStoreGears=StorageEngine.extend({init:function(d,c){this._super(d,c);this.type="Google Gears";this.includes.push("http://code.google.com/apis/gears/gears_init.js");this.autoload=true},connect:function(){var c=this.db=google.gears.factory.create("beta.database");c.open("jstore-"+this.project);c.execute("CREATE TABLE IF NOT EXISTS jstore (k TEXT UNIQUE NOT NULL PRIMARY KEY, v TEXT NOT NULL)");this.updateCache()},updateCache:function(){var c=this.db.execute("SELECT k,v FROM jstore");while(c.isValidRow()){this.data[c.field(0)]=b.jStore.safeResurrect(c.field(1));c.next()}c.close();this.delegate.trigger("engine-ready")},isAvailable:a,set:function(d,e){this.interruptAccess();var c=this.db;c.execute("BEGIN");c.execute("INSERT OR REPLACE INTO jstore(k, v) VALUES (?, ?)",[d,b.jStore.safeStore(e)]);c.execute("COMMIT");return this._super(d,e)},rem:function(d){this.interruptAccess();var c=this.db;c.execute("BEGIN");c.execute("DELETE FROM jstore WHERE k = ?",[d]);c.execute("COMMIT");return this._super(d)}});b.jStore.Engines.gears=jStoreGears;b.jStore.EngineOrder[3]="gears"})(jQuery);
/*
 * jStore HTML5 Specification Storage Engine
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 */
(function(b){var a=b.jStore.Availability.html5=function(){return !!window.openDatabase};this.jStoreHtml5=StorageEngine.extend({init:function(d,c){this._super(d,c);this.type="HTML5";this.limit=1024*200},connect:function(){var c=this.db=openDatabase("jstore-"+this.project,"1.0",this.project,this.limit);if(!c){throw"JSTORE_ENGINE_HTML5_NODB"}c.transaction(function(d){d.executeSql("CREATE TABLE IF NOT EXISTS jstore (k TEXT UNIQUE NOT NULL PRIMARY KEY, v TEXT NOT NULL)")});this.updateCache()},updateCache:function(){var c=this;this.db.transaction(function(d){d.executeSql("SELECT k,v FROM jstore",[],function(f,e){var h=e.rows,g=0,j;for(;g<h.length;++g){j=h.item(g);c.data[j.k]=b.jStore.safeResurrect(j.v)}c.delegate.trigger("engine-ready")})})},isAvailable:a,set:function(c,d){this.interruptAccess();this.db.transaction(function(e){e.executeSql("INSERT OR REPLACE INTO jstore(k, v) VALUES (?, ?)",[c,b.jStore.safeStore(d)])});return this._super(c,d)},rem:function(c){this.interruptAccess();this.db.transaction(function(d){d.executeSql("DELETE FROM jstore WHERE k = ?",[c])});return this._super(c)}});b.jStore.Engines.html5=jStoreHtml5;b.jStore.EngineOrder[0]="html5"})(jQuery);
/**
 * jStore IE Storage Engine
 * Copyright (c) 2009 Eric Garside (http://eric.garside.name)
 */
(function(b){var a=b.jStore.Availability.ie=function(){return !!window.ActiveXObject};this.jStoreIE=StorageEngine.extend({init:function(d,c){this._super(d,c);this.type="IE";this.limit=64*1024},connect:function(){this.db=b('<div style="display:none;behavior:url(\'#default#userData\')" id="jstore-'+this.project+'"></div>').appendTo(document.body).get(0);this.delegate.trigger("engine-ready")},isAvailable:a,get:function(c){this.interruptAccess();this.db.load(this.project);return b.jStore.safeResurrect(this.db.getAttribute(c))},set:function(c,d){this.interruptAccess();this.db.setAttribute(c,b.jStore.safeStore(d));this.db.save(this.project);return d},rem:function(c){this.interruptAccess();var d=this.get(c);this.db.removeAttribute(c);this.db.save(this.project);return d}});b.jStore.Engines.ie=jStoreIE;b.jStore.EngineOrder[4]="ie"})(jQuery);

// SETTINGS COOKIE ----------------------------------------------

function HotlistSettings(iVersion) {

    //IMPORTANT!! ALWAYS USE .set() and .get() METHODS RATHER THAN USING 
    //DOT NOTATION TO REFER TO VALUES WITHIN _pageData.Settings
    //e.g., _pageData.Settings.get("thisPreference"), NOT
    //		_pageData.Settings.thisPreference

    //GET EXISTING COOKIE VERSION
    if ($.cookie("ckyVersion") == null) {
        $.cookie("ckyVersion", iVersion, {path: "/"});
    }
    else {
        try {
            var iCurrentVersion = parseInt($.cookie("ckyVersion"));
            if (iCurrentVersion != iVersion) {
                $.cookie("ckySettings", null); //DELETE THE OLDER VERSION
                $.cookie("ckyVersion", iVersion, {path: "/"}); //UPDATE THE VERSION #
            }
        }
        catch (e) {
            log("Error getting old cookie version, or deleting the old cookie (7564989)");
        }
    }

    //IF NO SUCH COOKIE EXISTS, SET ONE
    if ($.cookie("ckySettings") == null) {
		$.JSONCookie("ckySettings", {}, {path: "/"});
    }

}

//INITIALIZE GLOBAL VARIABLE
window["_settings"] = new HotlistSettings(0);

//---------------------------------------------------------------------------------
//GET 
_settings["get"] = function(strName){
	
    //RETRIEVE COOKIE
    var settings = $.getJSONCookie("ckySettings"); //JSON2.parse($.cookie("ckySettings"));

    //RETURN SETTING FROM COOKIE
    var result = null;
	for(var name in settings){
		if(settings.hasOwnProperty(name) && name == strName){
			result = settings[name];
			break;
		}
	}
	
    return result;
	
};

//---------------------------------------------------------------------------------
//GET OR DEFAULT
_settings["getOrDefault"] = function(strName, strValue){
	
	var result = _settings.get(strName);
	if(!isUsable(result)){
		_settings.set(strName, strValue);
		result = strValue;
	}
	return result;
	
};

//---------------------------------------------------------------------------------
//SET
_settings["set"] = function(strName, strValue){
	
	var settings = $.getJSONCookie("ckySettings");
	settings[strName] = strValue;
	$.setJSONCookie("ckySettings", settings, {path: "/"});
	
};

//---------------------------------------------------------------------------------
//REMOVE
_settings["remove"] = function(strName){
	
	var settings = $.JSONCookie("ckySettings");
	for(var name in settings){
		if(settings.hasOwnProperty(name) && name == strName){
			settings[name] = null;
			$.setJSONCookie("ckySettings", settings, {path: "/"});
			break;
		}
	}
	
};


//---------------------------------------------------------------------------------
//REMOVE PREFIX
_settings["removePrefix"] = function(strPrefix){
	
	var settings = $.JSONCookie("ckySettings");
	var bolPropertiesFound = false;
	for(var name in settings){
		if(settings.hasOwnProperty(name) && name.indexOf(strPrefix) >= 0){
			bolPropertiesFound = true;
			settings[name] = null;
		}
	}
	if(bolPropertiesFound){
		$.setJSONCookie("ckySettings", settings, {path: "/"});
	}
	
};

//---------------------------------------------------------------------------------
//RESET
_settings["reset"] = function(){
	
	$.setJSONCookie("ckySettings", {}, {path: "/"});
	
};



(function($){$.fn.hint=function(blurClass){if(!blurClass){blurClass='blur'}return this.each(function(){var $input=$(this),title=$input.attr('title'),$form=$(this.form),$win=$(window);function remove(){if($input.val()===title&&$input.hasClass(blurClass)){$input.val('').removeClass(blurClass)}}if(title){$input.blur(function(){if(this.value===''){$input.val(title).addClass(blurClass)}}).focus(remove).blur();$form.submit(remove);$win.unload(remove)}})}})(jQuery);

/*
 ### jQuery Star Rating Plugin v3.12 - 2009-04-16 ###
 * Home: http://www.fyneworks.com/jquery/star-rating/
 * Code: http://code.google.com/p/jquery-star-rating-plugin/
 *
	* Dual licensed under the MIT and GPL licenses:
 *   http://www.opensource.org/licenses/mit-license.php
 *   http://www.gnu.org/licenses/gpl.html
 ###
*/
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}(';5(1O.1t)(7($){5($.29.1x)1I{1m.23("1u",P,z)}1F(e){}$.p.4=7(j){5(3.K==0)l 3;5(E J[0]==\'1j\'){5(3.K>1){8 k=J;l 3.W(7(){$.p.4.H($(3),k)})};$.p.4[J[0]].H(3,$.1T(J).21(1)||[]);l 3};8 j=$.10({},$.p.4.18,j||{});3.1v(\'.9-4-1l\').n(\'9-4-1l\').W(7(){8 a=(3.1J||\'1K-4\').1L(/\\[|\\]+/g,"1S");8 b=$(3.1U||1m.1X);8 c=$(3);8 d=b.6(\'4\')||{y:0};8 e=d[a];8 f;5(e)f=e.6(\'4\');5(e&&f){f.y++}B{f=$.10({},j||{},($.1k?c.1k():($.1H?c.6():s))||{},{y:0,C:[],u:[]});f.t=d.y++;e=$(\'<1M 12="9-4-1Q"/>\');c.1R(e);e.n(\'4-T-13-S\');5(c.R(\'Q\'))f.m=z;e.1a(f.A=$(\'<O 12="4-A"><a 14="\'+f.A+\'">\'+f.15+\'</a></O>\').1d(7(){$(3).4(\'N\');$(3).n(\'9-4-M\')}).1b(7(){$(3).4(\'v\');$(3).D(\'9-4-M\')}).1h(7(){$(3).4(\'w\')}).6(\'4\',f))};8 g=$(\'<O 12="9-4 q-\'+f.t+\'"><a 14="\'+(3.14||3.1p)+\'">\'+3.1p+\'</a></O>\');e.1a(g);5(3.U)g.R(\'U\',3.U);5(3.17)g.n(3.17);5(f.1V)f.x=2;5(E f.x==\'19\'&&f.x>0){8 h=($.p.11?g.11():0)||f.1c;8 i=(f.y%f.x),V=1y.1z(h/f.x);g.11(V).1A(\'a\').1B({\'1C-1D\':\'-\'+(i*V)+\'1E\'})};5(f.m)g.n(\'9-4-1e\');B g.n(\'9-4-1G\').1d(7(){$(3).4(\'1f\');$(3).4(\'G\')}).1b(7(){$(3).4(\'v\');$(3).4(\'F\')}).1h(7(){$(3).4(\'w\')});5(3.L)f.o=g;c.1i();c.1N(7(){$(3).4(\'w\')});g.6(\'4.r\',c.6(\'4.9\',g));f.C[f.C.K]=g[0];f.u[f.u.K]=c[0];f.q=d[a]=e;f.1P=b;c.6(\'4\',f);e.6(\'4\',f);g.6(\'4\',f);b.6(\'4\',d)});$(\'.4-T-13-S\').4(\'v\').D(\'4-T-13-S\');l 3};$.10($.p.4,{G:7(){8 a=3.6(\'4\');5(!a)l 3;5(!a.G)l 3;8 b=$(3).6(\'4.r\')||$(3.Z==\'X\'?3:s);5(a.G)a.G.H(b[0],[b.I(),$(\'a\',b.6(\'4.9\'))[0]])},F:7(){8 a=3.6(\'4\');5(!a)l 3;5(!a.F)l 3;8 b=$(3).6(\'4.r\')||$(3.Z==\'X\'?3:s);5(a.F)a.F.H(b[0],[b.I(),$(\'a\',b.6(\'4.9\'))[0]])},1f:7(){8 a=3.6(\'4\');5(!a)l 3;5(a.m)l;3.4(\'N\');3.1n().1o().Y(\'.q-\'+a.t).n(\'9-4-M\')},N:7(){8 a=3.6(\'4\');5(!a)l 3;5(a.m)l;a.q.1W().Y(\'.q-\'+a.t).D(\'9-4-1q\').D(\'9-4-M\')},v:7(){8 a=3.6(\'4\');5(!a)l 3;3.4(\'N\');5(a.o){a.o.6(\'4.r\').R(\'L\',\'L\');a.o.1n().1o().Y(\'.q-\'+a.t).n(\'9-4-1q\')}B $(a.u).1r(\'L\');a.A[a.m||a.1Y?\'1i\':\'1Z\']();3.20()[a.m?\'n\':\'D\'](\'9-4-1e\')},w:7(a){8 b=3.6(\'4\');5(!b)l 3;5(b.m)l;b.o=s;5(E a!=\'1s\'){5(E a==\'19\')l $(b.C[a]).4(\'w\');5(E a==\'1j\')$.W(b.C,7(){5($(3).6(\'4.r\').I()==a)$(3).4(\'w\')})}B b.o=3[0].Z==\'X\'?3.6(\'4.9\'):(3.22(\'.q-\'+b.t)?3:s);3.6(\'4\',b);3.4(\'v\');8 c=$(b.o?b.o.6(\'4.r\'):s);5(b.1g)b.1g.H(c[0],[c.I(),$(\'a\',b.o)[0]])},m:7(a,b){8 c=3.6(\'4\');5(!c)l 3;c.m=a||a==1s?z:P;5(b)$(c.u).R("Q","Q");B $(c.u).1r("Q");3.6(\'4\',c);3.4(\'v\')},24:7(){3.4(\'m\',z,z)},25:7(){3.4(\'m\',P,P)}});$.p.4.18={A:\'26 27\',15:\'\',x:0,1c:16};$(7(){$(\'r[28=1w].9\').4()})})(1t);',62,134,'|||this|rating|if|data|function|var|star||||||||||||return|readOnly|addClass|current|fn|rater|input|null|serial|inputs|draw|select|split|count|true|cancel|else|stars|removeClass|typeof|blur|focus|apply|val|arguments|length|checked|hover|drain|div|false|disabled|attr|drawn|to|id|spw|each|INPUT|filter|tagName|extend|width|class|be|title|cancelValue||className|options|number|append|mouseout|starWidth|mouseover|readonly|fill|callback|click|hide|string|metadata|applied|document|prevAll|andSelf|value|on|removeAttr|undefined|jQuery|BackgroundImageCache|not|radio|msie|Math|floor|find|css|margin|left|px|catch|live|meta|try|name|unnamed|replace|span|change|window|context|control|before|_|makeArray|form|half|children|body|required|show|siblings|slice|is|execCommand|disable|enable|Cancel|Rating|type|browser'.split('|'),0,{}))

/*
 * Copyright (c) 2009 Simo Kinnunen.
 * Licensed under the MIT license.
 *
 * @version 1.09
 */
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]-=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,G.type=="mouseover")}function E(F){C(this,F.type=="mouseenter")}function C(F,G){setTimeout(function(){var H=d.get(F).options;m.replace(F,G?h(H,H.hover):H,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 C={},B,F;for(var E=0,D=arguments.length;B=arguments[E],E<D;++E){for(F in B){if(k(B,F)){C[F]=B[F]}}}return C}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/.test("\u00a0")?/[^\S\u00a0]+/:/\s+/,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)}else{delete C.textGradient}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.getAttribute("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.setAttribute("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}})());

/*!
 * The following copyright notice may not be removed under any circumstances.
 * 
 * Copyright:
 * Digitized data copyright The Monotype Corporation 1991-2001. All rights
 * reserved. Gill Sans is a trademark of The Monotype Corporation Registered in the
 * U.S. Patent & Trademark Office and may be registered in certain jurisdictions
 * 
 * Trademark:
 * Gill Sans is a trademark of The Monotype Corporation Registered in the U.S.
 * Patent & Trademark Office and may be registered in certain jurisdictions
 * 
 * Designer:
 * Eric Gill
 * 
 * Vendor URL:
 * http://www.agfamonotype.com
 */
Cufon.registerFont({"w":180,"face":{"font-family":"Gill-Sans","font-weight":400,"font-stretch":"normal","units-per-em":"360","panose-1":"2 11 5 2 2 1 4 2 2 3","ascent":"288","descent":"-72","x-height":"3","bbox":"-22 -262.115 375 83","underline-thickness":"17.9297","underline-position":"-18.1055","unicode-range":"U+0020-U+00A9"},"glyphs":{" ":{"w":100,"k":{"Y":54,"W":45,"V":54,"T":45,"A":36}},"!":{"d":"49,-41v12,0,21,11,21,23v0,12,-9,21,-21,21v-12,0,-22,-9,-22,-21v0,-13,10,-23,22,-23xm49,-71v-15,-19,-20,-90,-20,-126v0,-34,7,-52,20,-52v37,19,17,141,0,178","w":97},"\"":{"d":"45,-166r-20,0v-5,-28,-10,-57,-8,-92r36,0v2,35,-3,64,-8,92xm103,-166r-20,0v-5,-28,-10,-57,-8,-92r36,0v2,35,-3,64,-8,92","w":127},"#":{"d":"1,-153r0,-22r57,0r15,-71r21,0r-15,71r74,0r15,-71r22,0r-15,71r35,0r0,22r-40,0r-13,65r53,0r0,22r-57,0r-15,70r-22,0r15,-70r-74,0r-15,70r-21,0r14,-70r-34,0r0,-22r39,0r14,-65r-53,0xm149,-153r-74,0r-14,65r75,0","w":210},"$":{"d":"19,-172v0,-37,32,-60,67,-64r0,-13r29,0r0,13v23,4,41,10,54,21r0,41v-15,-15,-33,-25,-54,-30r0,71v36,10,66,31,66,70v0,37,-27,61,-66,66r0,39r-29,0r0,-39v-20,-2,-43,-10,-68,-25r0,-44v21,18,38,30,68,37r0,-78v-40,-14,-67,-23,-67,-65xm86,-204v-23,0,-42,28,-26,47v4,5,17,11,26,15r0,-62xm115,-30v41,-6,38,-51,6,-62r-6,-3r0,65","w":195},"%":{"d":"188,-249r27,0r-161,252r-27,0xm124,-52v-1,-28,26,-55,55,-55v29,0,55,26,55,55v0,30,-26,54,-55,54v-29,0,-55,-25,-55,-54xm208,-52v0,-16,-14,-28,-29,-28v-16,-1,-28,13,-28,28v0,15,12,28,28,28v15,0,29,-14,29,-28xm9,-193v0,-29,26,-55,55,-55v29,0,54,26,54,55v0,28,-26,54,-54,54v-29,0,-55,-25,-55,-54xm92,-193v0,-15,-13,-29,-29,-29v-15,0,-28,14,-28,29v0,15,13,28,28,28v15,0,29,-14,29,-28","w":243},"&":{"d":"102,-241v34,-1,60,21,61,54v0,21,-17,47,-46,65r35,40v10,-11,18,-25,26,-40r35,0v-8,22,-22,43,-40,64r50,58r-45,0r-28,-33v-16,15,-48,35,-79,36v-32,0,-62,-25,-61,-57v1,-38,32,-57,58,-73v-48,-40,-31,-114,34,-114xm45,-56v3,36,60,27,75,5r8,-7r-40,-46v-16,12,-45,30,-43,48xm102,-211v-40,1,-27,52,-4,65v14,-9,33,-23,32,-40v0,-14,-12,-26,-28,-25","w":225},"'":{"d":"44,-166r-20,0v-5,-28,-10,-57,-8,-92r36,0v2,35,-3,64,-8,92","w":67},"(":{"d":"57,37v-56,-89,-36,-220,35,-286r20,0v-67,82,-71,246,0,331v-33,5,-43,-35,-55,-45","w":116},")":{"d":"4,82v69,-80,67,-254,0,-331v34,-5,43,35,55,45v17,28,35,78,34,121v-4,77,-27,115,-69,165r-20,0","w":116},"*":{"d":"23,-200v-21,-5,-20,-24,-4,-28v19,5,32,27,47,38v2,-2,4,-4,7,-4r-10,-51v0,-11,5,-16,13,-16v33,0,-12,60,9,71v15,-12,27,-33,47,-38v16,2,16,27,-2,28r-42,15r0,9v19,11,48,10,56,31v-17,32,-47,-19,-59,-26v-2,2,-5,3,-7,3v3,18,8,34,9,54v0,10,-4,15,-12,15v-25,-6,-4,-49,-2,-69v-2,0,-5,-1,-7,-3v-13,11,-32,34,-48,37v-21,-8,-12,-23,10,-30r35,-12r0,-9","w":150},"+":{"d":"90,-42r0,-70r-70,0r0,-30r70,0r0,-70r30,0r0,70r70,0r0,30r-70,0r0,70r-30,0","w":210},",":{"d":"35,-46v29,1,32,48,14,68v-8,10,-18,17,-31,21v2,-19,17,-19,14,-43v-26,-5,-22,-46,3,-46","w":78,"k":{" ":36}},"-":{"d":"14,-97r88,0r0,34r-88,0r0,-34","w":116},".":{"d":"18,-18v0,-12,9,-21,21,-21v12,0,22,10,22,21v0,12,-10,21,-22,21v-12,0,-21,-9,-21,-21","w":78,"k":{" ":36}},"\/":{"d":"1,3r71,-252r25,0r-71,252r-25,0","w":101},"0":{"d":"90,2v-108,-2,-106,-250,1,-251v104,5,106,248,-1,251xm90,-30v61,-7,61,-179,0,-185v-61,7,-61,178,0,185"},"1":{"d":"73,-246r35,0r0,246r-35,0r0,-246"},"2":{"d":"17,-225v58,-58,159,-2,128,84v-14,40,-39,69,-71,107r94,0r0,34v-50,-2,-110,4,-156,-2v33,-53,96,-95,103,-166v3,-27,-17,-46,-43,-46v-24,0,-42,16,-55,33r0,-44"},"3":{"d":"76,-249v72,0,99,95,41,119v66,23,33,133,-40,133v-19,0,-37,-5,-54,-14r0,-38v34,24,93,28,93,-21v0,-30,-18,-38,-51,-41v2,-10,-3,-26,2,-32v28,0,47,-10,47,-37v-1,-41,-52,-46,-85,-25r0,-33v14,-7,30,-11,47,-11"},"4":{"d":"128,-249r14,0r0,138r28,0r0,30r-28,0r0,81r-34,0r0,-81r-104,0r0,-15xm108,-111r0,-71r-57,71r57,0"},"5":{"d":"122,-76v2,-37,-50,-53,-86,-42r0,-128r109,0r0,32r-77,0r0,62v50,-6,90,29,90,76v0,70,-81,98,-140,64r0,-36v37,29,101,21,104,-28"},"6":{"d":"94,3v-70,1,-93,-82,-67,-147v18,-45,49,-76,87,-105r21,27v-36,24,-59,49,-75,90v50,-29,108,8,108,61v0,40,-34,74,-74,74xm133,-70v0,-41,-54,-51,-80,-25v-8,33,9,65,41,65v23,0,39,-18,39,-40"},"7":{"d":"18,-246r158,0r-111,249r-31,-13r90,-202r-106,0r0,-34"},"8":{"d":"46,-125v-54,-34,-23,-124,46,-124v68,0,101,89,42,124v64,32,29,136,-44,128v-71,7,-110,-95,-44,-128xm91,-142v20,0,39,-16,39,-37v0,-21,-17,-36,-39,-36v-22,0,-39,15,-39,36v0,20,19,37,39,37xm91,-31v24,0,42,-14,42,-38v0,-23,-19,-39,-43,-39v-24,0,-43,16,-43,39v0,23,19,38,44,38"},"9":{"d":"87,-249v86,1,98,115,51,180v-21,29,-42,55,-71,72r-21,-26v32,-20,64,-54,75,-92v-47,31,-108,-7,-108,-61v0,-40,34,-74,74,-73xm48,-176v0,38,50,51,79,26v11,-36,-8,-65,-40,-66v-23,-1,-39,18,-39,40"},":":{"d":"17,-18v0,-12,9,-22,21,-22v12,0,21,10,21,22v0,12,-9,21,-21,21v-12,0,-21,-9,-21,-21xm20,-143v0,-12,9,-22,21,-22v12,0,21,10,21,22v0,12,-9,21,-21,21v-12,0,-21,-9,-21,-21","w":78,"k":{" ":36}},";":{"d":"22,43v3,-18,16,-22,15,-43v-28,-5,-23,-46,3,-46v29,2,30,49,13,68v-8,10,-18,17,-31,21xm22,-143v0,-12,9,-22,21,-22v12,0,22,10,22,22v0,11,-10,21,-22,21v-12,0,-21,-9,-21,-21","w":82,"k":{" ":36}},"<":{"d":"20,-113r0,-29r170,-72r0,31r-135,56r135,56r0,31","w":210},"=":{"d":"190,-152r-170,0r0,-29r170,0r0,29xm190,-73r-170,0r0,-30r170,0r0,30","w":210},">":{"d":"190,-113r-170,73r0,-31r135,-56r-135,-56r0,-31r170,72r0,29","w":210},"?":{"d":"51,-63v-56,-29,15,-90,17,-130v1,-22,-25,-29,-45,-18r23,-38v34,1,58,19,58,52v0,48,-59,92,-53,134xm55,-40v12,0,23,9,22,22v0,12,-10,21,-22,21v-12,0,-21,-9,-21,-21v0,-12,10,-22,21,-22","w":119},"@":{"d":"87,-78v0,-79,94,-156,144,-80r6,-27r32,0r-31,145v1,6,6,11,12,12v36,-8,68,-51,68,-98v0,-65,-59,-111,-126,-111v-83,0,-146,67,-146,152v0,88,61,135,152,134v56,0,98,-18,123,-52r31,0v-26,46,-80,78,-155,78v-104,0,-180,-56,-178,-157v2,-105,66,-180,175,-180v84,0,153,57,151,137v-2,63,-43,125,-107,125v-25,0,-32,-7,-34,-29v-14,15,-31,28,-54,29v-38,1,-63,-38,-63,-78xm180,-165v-56,-2,-93,140,-23,140v34,0,66,-50,64,-89v0,-28,-15,-51,-41,-51","w":363},"A":{"d":"105,-247r25,0r110,247r-36,0r-33,-73r-104,0r-31,73r-36,0xm157,-104r-40,-89r-36,89r76,0","w":240,"k":{"y":9,"w":9,"v":9,"Y":40,"W":29,"V":29,"U":7,"T":36,"Q":14,"O":14,"G":14,"C":14}},"B":{"d":"195,-67v-1,75,-89,69,-168,67r0,-246v72,-2,147,-5,147,64v0,24,-13,42,-38,52v32,5,59,28,59,63xm62,-140v40,2,75,-3,75,-39v0,-35,-37,-37,-75,-35r0,74xm159,-70v0,-43,-49,-40,-97,-39r0,78v49,1,97,3,97,-39","w":202,"k":{"A":-7}},"C":{"d":"54,-122v0,92,117,117,185,65r0,39v-26,14,-56,21,-90,21v-79,-1,-130,-49,-131,-125v-2,-105,119,-159,218,-107r0,38v-74,-49,-182,-21,-182,69","w":254,"k":{"A":-9,".":-9,",":-9}},"D":{"d":"253,-123v0,82,-52,126,-148,123r-78,0r0,-246r83,0v91,-2,143,43,143,123xm217,-125v0,-74,-66,-97,-154,-89r0,182r45,0v72,4,109,-34,109,-93","w":270,"k":{"Y":36,"W":18,"V":18,"A":20,".":27,",":27}},"E":{"d":"27,-246r139,0r0,32r-104,0r0,75r101,0r0,31r-101,0r0,76r108,0r0,32r-143,0r0,-246"},"F":{"d":"27,-246r131,0r0,32r-95,0r0,68r95,0r0,32r-95,0r0,114r-36,0r0,-246","w":168,"k":{"o":5,"e":5,"A":18,".":50,",":50}},"G":{"d":"55,-123v0,77,76,116,152,85r0,-52r-47,0r0,-31r82,0r0,104v-98,50,-224,4,-224,-104v0,-108,127,-159,219,-107r0,36v-72,-50,-182,-22,-182,69","w":266},"H":{"d":"200,-246r35,0r0,246r-35,0r0,-107r-138,0r0,107r-35,0r0,-246r35,0r0,107r138,0r0,-107","w":262},"I":{"d":"27,-246r36,0r0,246r-36,0r0,-246","w":90},"J":{"d":"-22,49v41,0,49,-9,49,-56r0,-239r36,0r0,243v2,61,-23,88,-78,85","w":90,"k":{"u":7,"o":7,"e":7}},"K":{"d":"166,-246r44,0r-107,117r133,129r-48,0r-125,-121r0,121r-36,0r0,-246r36,0r0,113","w":236,"k":{"y":27,"u":18,"o":22,"e":22,"O":43}},"L":{"d":"27,-246r35,0r0,214r111,0r0,32r-146,0r0,-246","w":176,"k":{"y":11,"Y":40,"W":36,"V":36,"T":36}},"M":{"d":"223,-246r32,0r0,246r-35,0r0,-191r-76,95r-6,0r-76,-95r0,191r-36,0r0,-246r33,0r82,101","w":281},"N":{"d":"222,-246r34,0r0,246r-31,0r-164,-189r0,189r-33,0r0,-246r29,0r165,191r0,-191","w":281},"O":{"d":"16,-122v0,-74,58,-127,132,-127v73,0,132,55,132,126v0,72,-59,126,-134,126v-71,0,-130,-54,-130,-125xm244,-123v0,-52,-43,-93,-95,-93v-54,0,-96,41,-96,94v0,51,42,92,95,92v54,0,96,-40,96,-93","w":296,"k":{"Y":29,"X":29,"W":14,"V":14,"T":23,"A":14,".":22,",":22}},"P":{"d":"180,-176v-2,60,-50,74,-120,69r0,107r-35,0r0,-246r78,0v44,-1,78,27,77,70xm60,-138v42,2,84,2,84,-39v0,-38,-43,-40,-84,-38r0,77","w":183,"k":{"o":9,"e":9,"A":29,".":54,",":54}},"Q":{"d":"280,-123v0,63,-46,114,-102,123v39,13,64,28,97,15r-36,35v-54,-6,-78,-22,-120,-50v-56,-8,-102,-60,-103,-122v-1,-73,58,-127,132,-127v73,0,132,54,132,126xm244,-123v0,-53,-42,-93,-96,-93v-54,0,-96,41,-96,94v0,51,43,92,96,92v52,0,96,-42,96,-93","w":296},"R":{"d":"171,-177v0,31,-18,51,-42,60v35,22,59,82,88,117r-41,0v-25,-35,-45,-79,-79,-103v-6,-4,-22,-4,-34,-4r0,107r-35,0r0,-246v72,-4,144,1,143,69xm134,-178v0,-35,-29,-40,-71,-38r0,78v42,1,71,-3,71,-40","w":217,"k":{"Y":36,"W":27,"V":29,"U":11,"T":32,"O":22}},"S":{"d":"82,-28v48,0,48,-53,6,-75v-33,-18,-73,-34,-73,-81v0,-63,83,-83,129,-48r0,40v-18,-17,-38,-25,-58,-25v-30,0,-52,27,-31,49v27,29,98,51,98,104v0,70,-91,85,-137,44r0,-44v19,24,41,36,66,36","w":164},"T":{"d":"6,-246r205,0r0,31r-85,0r0,215r-36,0r0,-215r-84,0r0,-31","w":217,"k":{"y":45,"w":54,"u":50,"r":45,"o":54,"e":54,"a":45,"O":23,"A":36,";":11,":":11,".":45,"-":61,",":45}},"U":{"d":"127,-28v48,0,71,-22,71,-78r0,-140r35,0r0,140v3,77,-38,109,-105,109v-68,0,-106,-32,-106,-110r0,-139r35,0r0,140v-2,58,21,78,70,78","w":254,"k":{"A":9,".":9,",":9}},"V":{"d":"182,-246r35,0r-103,247r-8,0r-106,-247r35,0r74,173","w":217,"k":{"u":27,"o":36,"e":36,"a":22,"O":14,"G":14,"A":29,".":47,"-":36,",":47}},"W":{"d":"340,-246r35,0r-100,247r-7,0r-80,-200r-81,200r-8,0r-99,-247r35,0r68,170r68,-170r33,0r69,170","w":375,"k":{"y":11,"u":27,"o":32,"e":32,"a":22,"O":14,"A":29,".":47,"-":36,",":47}},"X":{"d":"205,-246r42,0r-98,119r105,127r-42,0r-84,-102r-84,102r-43,0r106,-127r-99,-119r43,0r77,94","w":254},"Y":{"d":"175,-246r42,0r-90,116r0,130r-36,0r0,-130r-91,-116r43,0r65,85","w":217,"k":{"u":43,"o":50,"e":47,"a":43,"S":7,"O":29,"A":40,";":11,":":11,".":47,"-":54,",":47}},"Z":{"d":"14,-246r212,0r-157,215r157,0r0,31r-222,0r158,-215r-148,0r0,-31","w":232},"[":{"d":"31,-246r84,0r0,29r-49,0r0,267r49,0r0,29r-84,0r0,-325","w":119},"\\":{"d":"75,3r-71,-252r26,0r70,252r-25,0","w":101},"]":{"d":"89,79r-84,0r0,-29r49,0r0,-267r-49,0r0,-29r84,0r0,325","w":119},"^":{"d":"84,-210r-42,105r-33,0r63,-141r25,0r62,141r-32,0","w":168},"_":{"d":"204,71r-209,0r0,-23r209,0r0,23","w":198},"`":{"d":"57,-249r25,52r-20,0r-40,-52r35,0","w":120},"a":{"d":"13,-143v34,-39,126,-27,111,46r0,69v3,16,13,6,24,-1r0,20v-15,13,-50,19,-56,-4v-29,26,-83,18,-82,-24v1,-41,50,-47,83,-60v4,-54,-55,-44,-80,-11r0,-35xm48,-59v-15,13,-5,39,17,39v10,0,19,-4,28,-12r0,-48v-15,5,-37,13,-45,21","w":153,"k":{"y":14,"w":13,"v":13,"p":4}},"b":{"d":"167,-82v0,77,-82,102,-146,73r0,-237r32,0r0,96v51,-39,114,2,114,68xm135,-81v0,-47,-49,-72,-82,-39r0,88v42,15,82,-4,82,-49","k":{"y":4,".":4,",":4}},"c":{"d":"46,-81v0,51,55,67,98,43r0,32v-63,26,-130,-6,-130,-74v0,-67,68,-106,126,-74r0,34v-39,-30,-94,-12,-94,39","w":157,"k":{".":-7,",":-7}},"d":{"d":"16,-83v0,-60,56,-99,115,-75r0,-88r32,0r0,246r-69,0v-48,0,-78,-34,-78,-83xm48,-80v0,48,31,57,83,53r0,-103v-41,-20,-83,3,-83,50","w":183,"k":{"d":4}},"e":{"d":"90,-165v45,0,72,37,70,87r-113,0v0,57,74,63,111,31r0,31v-19,12,-35,18,-64,18v-52,-1,-77,-34,-79,-84v-2,-47,30,-83,75,-83xm129,-97v2,-36,-42,-52,-67,-30v-7,7,-13,17,-15,30r82,0","w":172,"k":{"y":5,"w":5,"v":5,".":-7,",":-7}},"f":{"d":"107,-214v-35,-11,-53,11,-49,52r29,0r0,29r-29,0r0,133r-32,0r0,-133r-23,0r0,-29r23,0v-3,-58,25,-99,81,-84r0,32","w":90,"k":{"o":4,"e":4}},"g":{"d":"41,-11v-29,-13,-15,-39,9,-44v-24,-11,-36,-27,-36,-51v-1,-61,73,-58,138,-56r0,25r-33,0v36,35,5,90,-46,90v-18,0,-24,13,-12,22v35,12,90,10,90,57v0,35,-35,50,-75,50v-40,0,-75,-15,-76,-50v0,-22,14,-37,41,-43xm107,-104v0,-16,-14,-30,-32,-30v-17,0,-32,14,-32,30v0,17,14,29,32,29v17,0,31,-14,32,-29xm120,33v0,-31,-89,-37,-90,-1v0,17,15,25,45,25v23,0,45,-5,45,-24","w":153,"k":{"y":-7,"o":4}},"h":{"d":"94,-139v-20,0,-27,11,-40,23r0,116r-32,0r0,-246r32,0r0,106v35,-46,104,-26,104,48r0,92r-32,0v-5,-51,20,-139,-32,-139","k":{"y":13}},"i":{"d":"21,-211v-1,-10,9,-19,18,-19v9,0,20,9,19,19v1,10,-10,19,-19,19v-9,0,-19,-9,-18,-19xm23,-162r32,0r0,162r-32,0r0,-162","w":78},"j":{"d":"19,-211v-1,-10,9,-19,18,-19v10,0,20,9,20,19v0,9,-9,19,-19,19v-9,0,-20,-9,-19,-19xm-2,59v14,-5,24,-17,24,-36r0,-185r32,0r0,185v0,28,-10,47,-32,59","w":78},"k":{"d":"128,-162r38,0r-69,80r83,82r-43,0r-81,-82xm23,-246r32,0r0,246r-32,0r0,-246","w":172,"k":{"o":11,"e":11}},"l":{"d":"23,-246r32,0r0,246r-32,0r0,-246","w":78,"k":{"y":4,"w":4}},"m":{"d":"224,0v-6,-50,20,-135,-32,-137v-13,0,-26,7,-37,20r0,117r-32,0v-7,-49,21,-137,-32,-138v-20,0,-27,8,-38,21r0,117r-32,0r0,-162r32,0r0,22v30,-34,74,-34,96,4v37,-51,107,-31,107,41r0,95r-32,0","w":277,"k":{"y":13,"u":4}},"n":{"d":"126,0v-6,-50,21,-137,-33,-138v-15,0,-27,8,-38,23r0,115r-33,0r0,-162r33,0r0,21v38,-45,103,-23,103,49r0,92r-32,0","k":{"y":7,"v":5,"u":4}},"o":{"d":"13,-79v0,-47,39,-83,87,-83v49,0,86,37,86,84v0,47,-40,81,-87,81v-47,0,-86,-37,-86,-82xm153,-80v1,-31,-24,-53,-55,-53v-29,0,-52,22,-52,53v0,30,23,53,54,53v31,0,53,-23,53,-53","w":198,"k":{"y":7,"x":5,"w":4,"v":4,".":11,",":11}},"p":{"d":"168,-80v0,58,-56,101,-115,76r0,86r-32,0r0,-244v80,-5,147,7,147,82xm135,-81v0,-45,-34,-54,-82,-51r0,100v40,20,82,-5,82,-49","k":{"y":13,".":11,",":11}},"q":{"d":"13,-79v0,-74,65,-91,146,-83r0,244r-32,0r0,-85v-61,22,-114,-16,-114,-76xm45,-80v-2,45,45,69,82,49r0,-101v-51,-4,-80,9,-82,52"},"r":{"d":"126,-118v-29,-35,-69,-7,-69,33r0,85r-32,0r0,-162r32,0r0,37v26,-39,50,-55,86,-22","w":142,"k":{"y":-11,"v":-11,"t":-7,"r":4,"q":9,"o":9,"e":7,"d":5,"c":9,";":-14,":":-14,".":36,"-":29,",":36}},"s":{"d":"124,-43v0,51,-75,57,-109,31r0,-34v18,14,63,35,76,5v-12,-37,-78,-36,-75,-82v3,-45,63,-52,100,-29r0,32v-19,-11,-34,-17,-46,-17v-31,0,-22,27,2,37v26,11,52,35,52,57","w":138,"k":{"w":4}},"t":{"d":"120,-8v-42,23,-92,11,-92,-53r0,-72r-28,0v16,-25,41,-40,60,-62r0,33r51,0r0,29r-51,0v5,37,-16,105,23,107v11,0,24,-3,37,-11r0,29","w":119},"u":{"d":"54,-162v7,50,-22,138,33,138v15,0,28,-7,39,-22r0,-116r32,0r0,162r-32,0r0,-21v-34,41,-104,26,-104,-48r0,-93r32,0"},"v":{"d":"122,-162r34,0r-71,165r-11,0r-73,-165r35,0r44,100","w":157,"k":{"o":7,"e":7,".":22,",":22}},"w":{"d":"225,-162r34,0r-71,165r-10,0r-48,-113r-48,113r-10,0r-72,-165r34,0r43,98r41,-98r24,0r40,98","w":258,"k":{"o":7,"e":7,".":22,",":22}},"x":{"d":"134,-162r41,0r-66,80r71,82r-41,0r-51,-58r-48,58r-40,0r68,-82r-68,-80r40,0r48,56","k":{"e":11}},"y":{"d":"122,-162r36,0r-115,244r-35,0r55,-117r-63,-127r36,0r44,92","w":157,"k":{"o":7,"e":7,".":29,",":29}},"z":{"d":"8,-162r138,0r-86,132r86,0r0,30r-142,0r85,-132r-81,0r0,-30","w":150},"{":{"d":"46,-11v0,-44,-2,-64,-36,-68r0,-29v34,-3,37,-24,36,-68v-1,-64,6,-88,66,-86r0,27v-41,-6,-36,26,-36,63v0,44,-7,65,-37,79v38,12,37,53,37,105v0,31,7,37,36,36r0,27v-60,2,-67,-23,-66,-86","w":119},"|":{"d":"33,83r0,-329r28,0r0,329r-28,0","w":93},"}":{"d":"44,-172v-1,-35,6,-70,-36,-63r0,-27v59,-2,67,24,66,86v0,44,1,65,36,68r0,29v-34,3,-37,25,-37,68v0,64,-6,88,-65,86r0,-27v41,6,36,-26,36,-62v1,-45,6,-66,37,-79v-30,-13,-37,-35,-37,-79","w":119},"~":{"d":"195,-114v-49,60,-134,-44,-180,20r0,-36v50,-62,133,43,180,-22r0,38","w":209},"\u00a9":{"d":"88,-115v-8,60,78,71,88,20r21,6v-7,29,-30,50,-64,49v-42,0,-69,-32,-69,-76v0,-78,109,-104,131,-33r-21,5v-18,-48,-95,-27,-86,29xm0,-117v0,-77,57,-132,133,-132v77,0,133,55,133,132v0,77,-56,133,-133,133v-76,0,-133,-55,-133,-133xm244,-117v0,-58,-52,-110,-111,-110v-58,0,-110,52,-110,110v0,60,50,111,110,111v59,0,111,-53,111,-111","w":266},"\u00a0":{"w":100,"k":{"Y":54,"W":45,"V":54,"T":45,"A":36}}}});
/*!
 * The following copyright notice may not be removed under any circumstances.
 * 
 * Copyright:
 * Digitized data copyright © 1991-2001 Agfa Monotype Corporation. All rights
 * reserved. Gill Sans is a trademark of The Monotype Corporation. Registered in
 * the U.S. Patent & Trademark Office and may be registered in certain
 * jurisdictions
 * 
 * Trademark:
 * Gill Sans is a trademark of The Monotype Corporation. Registered in the U.S.
 * Patent & Trademark Office and may be registered in certain jurisdictions
 * 
 * Vendor URL:
 * http://www.agfamonotype.com
 */
Cufon.registerFont({"w":213,"face":{"font-family":"Gill-Sans","font-weight":700,"font-stretch":"normal","units-per-em":"360","panose-1":"2 11 9 2 3 0 4 2 2 3","ascent":"288","descent":"-72","x-height":"3","bbox":"-13 -258 425 85.6361","underline-thickness":"17.9297","underline-position":"-18.1055","unicode-range":"U+0020-U+00A9"},"glyphs":{" ":{"w":106},"!":{"d":"55,-247v63,0,32,131,8,165v-36,8,-34,-46,-43,-76v-12,-42,-1,-89,35,-89xm55,-72v21,0,36,15,37,37v0,21,-16,38,-37,38v-21,-1,-38,-16,-38,-38v1,-22,16,-37,38,-37","w":108},"\"":{"d":"171,-244v2,38,-4,66,-11,95r-48,0v-7,-29,-15,-57,-12,-95r71,0xm80,-244v2,38,-5,67,-12,95r-48,0v-7,-29,-13,-57,-11,-95r71,0","w":180},"#":{"d":"227,-60r-53,0r-14,66r-38,0r14,-66r-58,0r-13,66r-39,0r14,-66r-27,0r0,-38r35,0r10,-48r-45,0r0,-38r53,0r14,-65r38,0r-14,65r58,0r14,-65r38,0r-14,65r27,0r0,38r-35,0r-10,48r45,0r0,38xm154,-146r-58,0r-10,48r58,0","w":240},"$":{"d":"123,-148v41,16,80,31,80,80v0,44,-35,67,-80,71r0,31r-26,0r0,-31v-25,-3,-57,-14,-75,-26r0,-50v21,15,43,31,75,34r0,-59v-44,-12,-78,-24,-78,-72v0,-43,33,-65,78,-69r0,-16r26,0r0,16v31,4,48,11,71,26r0,53v-17,-14,-44,-31,-71,-36r0,48xm97,-198v-19,-1,-37,18,-21,33v4,5,11,8,21,10r0,-43xm123,-38v22,-2,37,-23,21,-41v-4,-4,-11,-8,-21,-12r0,53","w":225},"%":{"d":"78,-247v36,0,61,24,61,60v0,36,-25,61,-61,61v-36,0,-60,-25,-60,-61v0,-35,24,-60,60,-60xm250,-247r-175,254r-37,0r177,-254r35,0xm210,-114v35,0,60,25,60,60v0,36,-26,61,-60,61v-34,0,-60,-25,-60,-61v0,-37,24,-60,60,-60xm78,-163v12,0,24,-11,24,-24v0,-13,-12,-23,-24,-23v-12,0,-23,11,-23,23v0,12,11,24,23,24xm210,-30v13,0,25,-11,24,-24v0,-13,-12,-23,-24,-23v-12,0,-24,10,-23,23v-2,12,11,24,23,24","w":288},"&":{"d":"203,-187v0,29,-23,51,-47,62r33,35v10,-9,19,-21,27,-35r58,0v-15,29,-32,52,-52,70r52,55r-82,0r-16,-16v-46,33,-164,26,-159,-43v3,-39,21,-44,53,-69v-13,-14,-26,-27,-26,-53v1,-45,37,-66,83,-66v43,0,76,22,76,60xm129,-207v-37,1,-20,43,-2,52v33,-10,37,-49,2,-52xm78,-66v-1,28,45,33,66,16r-43,-45v-16,10,-23,19,-23,29","w":296},"'":{"d":"86,-244v2,38,-4,66,-11,95r-49,0v-7,-29,-15,-57,-12,-95r72,0","w":100},"(":{"d":"80,-81v0,81,31,124,71,166r-46,0v-45,-36,-92,-84,-92,-165v0,-81,46,-129,92,-167r46,0v-39,41,-71,87,-71,166","w":138,"k":{"y":-15,"p":-21,"j":-25,"g":-15,"f":-10,"J":-25}},")":{"d":"34,-247v43,34,91,86,91,165v0,81,-47,129,-91,167r-47,0v39,-41,72,-87,72,-166v0,-80,-31,-125,-72,-166r47,0","w":138},"*":{"d":"163,-207v18,-6,25,23,26,39v-3,21,-45,7,-68,11v0,4,-1,6,-3,9v15,12,43,26,52,41v-3,14,-30,38,-44,27v-8,-16,-13,-41,-19,-59r-10,0r-21,58v-17,13,-60,-20,-32,-39r41,-28v-2,-4,-3,-6,-3,-9v-23,-4,-65,10,-68,-11v-2,-16,14,-57,33,-33r40,30v2,-2,4,-4,7,-5r-19,-59v1,-11,13,-12,27,-12v53,-1,7,47,6,71v2,1,5,3,8,5","w":202},"+":{"d":"219,-100r-77,0r0,77r-44,0r0,-77r-77,0r0,-44r77,0r0,-77r44,0r0,77r77,0r0,44","w":240},",":{"d":"50,-72v50,-1,56,75,26,103v-15,14,-37,25,-63,29r0,-11v19,-7,28,-24,27,-50v-18,-5,-27,-17,-27,-35v0,-22,16,-35,37,-36","w":108},"-":{"d":"146,-61r-115,0r0,-59r115,0r0,59","w":176},".":{"d":"51,-72v22,1,37,15,38,37v0,21,-17,38,-38,38v-19,0,-38,-17,-38,-38v0,-21,19,-37,38,-37","w":101},"\/":{"d":"185,-247r-132,250r-48,0r133,-250r47,0","w":190},"0":{"d":"107,-247v68,0,95,55,95,125v0,71,-27,125,-95,125v-68,0,-95,-54,-95,-125v0,-71,27,-125,95,-125xm107,-49v28,-3,26,-38,26,-73v0,-34,1,-70,-26,-73v-28,4,-26,41,-26,73v0,36,-2,70,26,73"},"1":{"d":"140,0r-67,0r0,-244r67,0r0,244"},"2":{"d":"181,-172v-3,57,-36,81,-60,117r79,0r0,55r-185,0v27,-51,102,-79,102,-155v0,-53,-66,-43,-94,-6r0,-58v45,-43,162,-38,158,47"},"3":{"d":"148,-127v19,11,37,28,37,59v0,79,-103,82,-159,54r0,-55v19,22,91,41,91,-4v0,-24,-21,-35,-49,-33r0,-39v25,2,45,-8,45,-28v0,-39,-59,-31,-81,-12r0,-47v53,-29,149,-15,149,50v0,25,-16,45,-33,55"},"4":{"d":"201,-53r-29,0r0,53r-65,0r0,-53r-99,0r0,-46r112,-145r52,0r0,150r29,0r0,41xm107,-94r0,-78r-60,78r60,0"},"5":{"d":"90,-150v54,-9,95,23,97,74v4,84,-113,97,-167,56r0,-53v20,18,97,48,99,-3v2,-37,-53,-38,-83,-26r0,-142r141,0r0,52r-87,0r0,42"},"6":{"d":"107,-162v56,-7,96,24,95,78v-1,55,-38,84,-94,87v-96,5,-117,-112,-69,-179v20,-28,42,-51,70,-71r60,20v-25,20,-44,39,-62,65xm107,-52v21,0,31,-14,32,-33v1,-21,-13,-32,-31,-33v-20,-1,-32,16,-33,33v-1,17,13,33,32,33"},"7":{"d":"201,-237r-104,240r-57,-18r75,-175r-99,0r0,-54r185,0r0,7"},"8":{"d":"163,-126v20,12,39,31,39,60v0,48,-39,69,-95,69v-56,0,-95,-20,-95,-69v0,-28,18,-50,39,-60v-19,-12,-31,-24,-31,-52v0,-45,36,-69,87,-69v51,0,87,22,87,69v0,29,-12,39,-31,52xm107,-141v15,0,26,-15,25,-32v0,-15,-7,-33,-24,-33v-18,0,-26,17,-26,33v-1,17,10,32,25,32xm107,-36v19,0,33,-16,32,-36v-1,-21,-12,-36,-32,-36v-17,0,-32,16,-32,36v0,21,14,35,32,36"},"9":{"d":"105,-247v81,-2,117,79,85,152v-17,40,-50,74,-85,99r-60,-20v28,-24,49,-46,62,-66v-54,9,-96,-25,-95,-77v1,-55,38,-86,93,-88xm106,-126v21,1,32,-15,33,-32v2,-18,-13,-34,-32,-34v-21,0,-31,15,-32,34v-1,21,13,31,31,32"},":":{"d":"51,-182v21,1,37,16,37,38v0,21,-17,38,-38,38v-20,0,-37,-18,-37,-38v0,-22,19,-38,38,-38xm51,-72v22,1,37,15,38,37v0,21,-17,38,-38,38v-19,0,-38,-17,-38,-38v0,-21,19,-37,38,-37","w":101},";":{"d":"51,-182v21,1,37,16,37,38v0,21,-17,38,-38,38v-20,0,-37,-18,-37,-38v0,-22,19,-38,38,-38xm50,-72v50,0,56,75,26,103v-15,14,-37,25,-63,29r0,-11v19,-7,28,-24,27,-50v-42,-8,-31,-71,10,-71","w":108},"<":{"d":"219,-20r-198,-82r0,-40r198,-82r0,47r-137,55r137,55r0,47","w":240},"=":{"d":"219,-142r-198,0r0,-44r198,0r0,44xm219,-57r-198,0r0,-44r198,0r0,44","w":240},">":{"d":"219,-102r-198,82r0,-47r137,-55r-137,-55r0,-47r198,82r0,40","w":240},"?":{"d":"30,-242v46,-15,95,2,97,46v2,49,-55,58,-58,105v0,8,-4,11,-13,11v-17,2,-15,-20,-17,-33v-1,-26,18,-44,20,-66v2,-21,-27,-20,-46,-14xm57,-72v20,0,37,17,37,37v0,20,-17,38,-37,38v-19,0,-38,-17,-38,-38v0,-21,19,-37,38,-37","w":138},"@":{"d":"188,53v57,0,95,-17,119,-46r36,0v-25,52,-78,78,-152,78v-106,0,-181,-50,-181,-158v0,-107,67,-174,178,-174v87,0,147,50,147,132v0,68,-45,123,-114,125v-21,0,-27,-5,-32,-19v-39,39,-119,12,-113,-55v5,-57,34,-111,92,-113v21,0,37,8,47,24r3,-19r46,0r-28,139v0,6,2,8,7,8v33,-8,60,-48,60,-91v0,-64,-45,-99,-116,-99v-94,1,-145,56,-145,144v0,83,57,123,146,124xm151,-21v39,0,52,-46,52,-84v0,-20,-7,-41,-30,-41v-36,0,-49,46,-51,84v-1,23,10,41,29,41","w":345},"A":{"d":"298,0r-75,0r-20,-49r-106,0r-20,49r-75,0r108,-244r81,0xm186,-92r-36,-89r-36,89r72,0","w":299,"k":{"y":5,"w":5,"v":10,"u":-5,"p":-5,"Y":36,"W":21,"V":26,"U":10,"T":36,"Q":5,"G":5,"C":5}},"B":{"d":"202,-133v29,13,50,27,51,64v1,94,-131,65,-222,69r0,-244v82,5,200,-23,205,57v2,27,-15,47,-34,54xm104,-144v33,-1,63,3,63,-29v0,-33,-30,-29,-63,-30r0,59xm179,-72v3,-31,-39,-33,-75,-31r0,62v35,1,79,0,75,-31","w":269,"k":{"U":5,"A":10,".":-10,",":-5}},"C":{"d":"90,-121v0,80,115,78,159,41r0,62v-26,13,-58,21,-96,21v-83,0,-137,-43,-138,-125v-2,-119,126,-148,233,-107r0,65v-45,-40,-158,-36,-158,43","w":267,"k":{"O":5,"C":5,".":-5}},"D":{"d":"132,-244v137,-20,195,147,103,223v-41,34,-133,17,-204,21r0,-244r101,0xm104,-50v61,3,102,-7,102,-71v0,-61,-39,-79,-102,-74r0,145","w":295,"k":{"Y":15,"V":5,"A":15,".":5,",":10}},"E":{"d":"214,0r-183,0r0,-244r180,0r0,49r-107,0r0,45r102,0r0,49r-102,0r0,52r110,0r0,49","w":232},"F":{"d":"205,-99r-101,0r0,99r-73,0r0,-244r174,0r0,49r-101,0r0,47r101,0r0,49","w":223,"k":{"o":5,"e":5,"a":-5,"A":21,".":26,",":31}},"G":{"d":"90,-121v0,54,51,78,106,64r0,-28r-33,0r0,-49r97,0r0,117v-30,12,-65,20,-107,20v-82,-1,-138,-42,-138,-125v0,-83,55,-127,142,-125v44,0,65,8,99,18r0,57v-49,-36,-166,-31,-166,51","w":287,"k":{"A":5,".":-5}},"H":{"d":"288,0r-73,0r0,-95r-111,0r0,95r-73,0r0,-244r73,0r0,90r111,0r0,-90r73,0r0,244","w":318},"I":{"d":"104,0r-73,0r0,-244r73,0r0,244","w":135},"J":{"d":"112,-30v4,76,-30,119,-109,106r-11,-59v47,2,46,-20,46,-72r0,-189r74,0r0,214","w":142,"k":{"u":-10,"a":-5,"A":5,".":-5}},"K":{"d":"287,0r-90,0r-93,-114r0,114r-73,0r0,-244r73,0r0,109r88,-109r80,0r-91,114","w":288,"k":{"y":21,"w":15,"v":21,"u":10,"o":15,"e":15,"O":15,"G":15,"C":15,")":-21}},"L":{"d":"216,0r-185,0r0,-244r73,0r0,186r112,0r0,58","w":227,"k":{"y":26,"w":26,"Y":46,"W":36,"V":36,"U":21,"T":46,"S":21,"O":21,"G":21,"C":21,"A":5}},"M":{"d":"314,0r-74,0r0,-141r-66,82r-6,0r-66,-82r0,141r-71,0r0,-244r66,0r75,92r75,-92r67,0r0,244","w":344},"N":{"d":"295,0r-65,0r-127,-136r0,136r-72,0r0,-244r65,0r126,135r0,-135r73,0r0,244","w":325,"k":{"A":5,".":-5}},"O":{"d":"153,-247v84,0,138,44,138,125v0,81,-55,124,-138,125v-84,1,-138,-47,-138,-125v0,-79,55,-125,138,-125xm153,-59v40,-1,63,-24,63,-63v0,-39,-22,-62,-63,-62v-39,0,-63,24,-63,62v0,37,25,63,63,63","w":306,"k":{"Y":15,"X":15,"W":5,"V":5,"T":21,"N":5,"A":15,".":5,",":10}},"P":{"d":"152,-244v54,0,90,27,90,77v0,67,-62,82,-138,76r0,91r-73,0r0,-244r121,0xm104,-138v33,0,64,3,63,-29v-1,-32,-29,-29,-63,-30r0,59","w":251,"k":{"o":10,"e":10,"a":10,"A":31,".":41,",":46}},"Q":{"d":"215,-7v26,11,49,21,85,21r2,4r-52,47v-56,-14,-118,-38,-155,-71v-45,-17,-81,-53,-80,-116v1,-79,55,-125,138,-125v84,0,136,44,138,125v1,62,-33,96,-76,115xm153,-59v40,-1,63,-24,63,-63v0,-39,-22,-62,-63,-62v-39,0,-63,24,-63,62v0,37,25,63,63,63","w":306,"k":{"p":-10,"j":-10,"g":-5,"f":-10,"Y":15,"W":5,"V":5,"T":15,"A":10,".":-5,",":-10,")":-5}},"R":{"d":"242,-168v0,32,-18,50,-40,61v33,18,44,70,64,107r-78,0v-24,-37,-23,-99,-84,-95r0,95r-73,0r0,-244r125,0v51,0,86,31,86,76xm104,-138v33,-1,63,3,63,-29v0,-31,-29,-30,-63,-30r0,59","w":269,"k":{"v":5,"u":-5,"e":5,"a":-10,"Y":10,"W":5,"V":5,"U":5,"T":15}},"S":{"d":"118,-197v-39,2,-27,32,2,44v43,18,79,29,81,82v4,84,-117,86,-178,55r0,-60v22,14,43,25,75,27v28,2,38,-23,20,-35v-36,-24,-97,-32,-97,-92v0,-81,119,-84,169,-50r0,57v-19,-12,-42,-29,-72,-28","w":220,"k":{".":-10,",":-5}},"T":{"d":"264,-184r-89,0r0,184r-73,0r0,-184r-90,0r0,-60r252,0r0,60","w":276,"k":{"z":5,"y":10,"w":5,"u":10,"s":31,"r":10,"o":36,"m":10,"l":5,"i":5,"e":41,"c":36,"a":21,"T":5,"Q":21,"O":21,"G":21,"C":21,"A":31,";":10,":":5,".":46,"-":21,",":52}},"U":{"d":"156,-58v79,0,50,-112,55,-186r73,0r0,135v0,77,-53,112,-128,112v-74,0,-128,-36,-129,-112r0,-135r73,0v5,75,-23,186,56,186","w":311,"k":{"A":15,".":10,",":15}},"V":{"d":"269,-244r-110,247r-48,0r-108,-247r76,0r56,141r57,-141r77,0","w":271,"k":{"y":10,"u":10,"r":5,"o":21,"i":5,"e":21,"a":10,"Q":10,"O":10,"G":10,"C":10,"A":26,";":5,".":31,"-":21,",":36}},"W":{"d":"425,-244r-105,247r-43,0r-63,-143r-65,143r-43,0r-103,-247r76,0r51,135r58,-135r52,0r57,135r53,-135r75,0","w":428,"k":{"y":5,"u":5,"r":5,"o":15,"i":5,"e":15,"d":15,"a":10,"A":21,";":5,".":15,"-":15,",":21}},"X":{"d":"306,0r-95,0r-59,-72r-57,72r-93,0r103,-127r-98,-117r93,0r52,65v21,-31,30,-42,49,-65r92,0r-94,117","w":307,"k":{"O":15,"G":15,"C":15}},"Y":{"d":"268,-244r-95,132r0,112r-74,0r0,-110r-97,-134r76,0r56,77r56,-77r78,0","w":270,"k":{"v":21,"u":21,"q":36,"p":21,"o":36,"i":10,"e":36,"d":31,"a":21,"S":10,"O":15,"G":15,"C":15,"A":36,";":15,":":10,".":36,"-":36,",":41}},"Z":{"d":"254,0r-247,0r126,-185r-116,0r0,-59r237,0r-126,186r126,0r0,58","w":262},"[":{"d":"153,81r-124,0r0,-325r124,0r0,42r-64,0r0,242r64,0r0,41","w":161},"\\":{"d":"185,3r-47,0r-133,-250r48,0","w":190},"]":{"d":"133,81r-125,0r0,-41r64,0r0,-242r-64,0r0,-42r125,0r0,325","w":161},"^":{"d":"215,-101r-62,0r-34,-86r-34,86r-62,0r71,-143r49,0","w":237},"_":{"d":"182,45r-184,0r0,-18r184,0r0,18","w":180},"`":{"d":"99,-203r-34,0r-65,-55r68,0","w":119},"a":{"d":"206,-9v-23,12,-77,23,-85,-7v-25,29,-111,29,-108,-26v3,-55,65,-52,105,-72v-1,-19,-7,-28,-28,-28v-32,0,-54,15,-71,33r0,-49v41,-32,163,-41,162,32r0,69v-1,21,9,24,25,15r0,33xm75,-49v0,26,32,18,43,6r0,-43v-22,11,-43,13,-43,37","w":205,"k":{"w":-5,"u":-5,"r":-5,"p":-5,"n":-5,"m":-5,"k":-5,"i":-5,"h":-5,"g":-5,"f":-5,"b":-5}},"b":{"d":"131,-182v56,2,82,38,86,94v6,77,-84,116,-134,72r0,16r-63,0r0,-244r63,0r0,76v11,-8,27,-15,48,-14xm83,-57v26,25,67,12,67,-33v0,-42,-35,-61,-67,-35r0,68","w":229,"k":{"y":5,"v":5,"l":5,".":-5}},"c":{"d":"79,-90v0,48,56,49,94,32r0,50v-72,29,-160,-1,-160,-82v0,-79,86,-110,158,-82r0,50v-45,-17,-92,-15,-92,32","w":184,"k":{".":-10,",":-5}},"d":{"d":"13,-88v-8,-74,75,-118,133,-80r0,-76r64,0r0,244r-64,0r0,-16v-48,44,-142,5,-133,-72xm79,-90v-5,44,44,58,67,33r0,-68v-28,-24,-71,-8,-67,35","w":229},"e":{"d":"115,-182v60,0,93,40,89,108r-126,0v13,48,76,43,121,19r0,39v-22,11,-48,20,-84,19v-62,-1,-102,-32,-102,-93v0,-61,40,-92,102,-92xm144,-105v5,-34,-36,-50,-58,-28v-7,7,-10,17,-10,28r68,0","w":214,"k":{"w":-5,"p":-5,"b":-5,".":-10,",":-5}},"f":{"d":"32,-170v-3,-61,46,-87,108,-74r0,46v-26,-9,-48,-2,-45,28r32,0r0,43r-32,0r0,127r-63,0r0,-127r-30,0r0,-43r30,0","w":132,"k":{"u":-10,"l":5,"f":-10,"a":-10,"?":-21,",":5,")":-36,"!":-15," ":-10}},"g":{"d":"14,-111v1,-83,103,-67,186,-68r0,38r-31,0v39,41,-2,97,-55,94v-24,-1,-30,19,-10,21v41,4,91,7,89,54v-2,45,-41,56,-91,57v-51,1,-93,-10,-93,-48v0,-23,17,-34,43,-37v-24,-9,-18,-52,11,-53v-24,-7,-50,-27,-49,-58xm99,-81v17,1,31,-14,31,-30v1,-17,-14,-28,-30,-29v-18,-1,-32,15,-31,30v2,17,11,29,30,29xm103,54v20,0,40,-4,40,-21v0,-27,-80,-26,-80,1v0,13,13,20,40,20","w":202,"k":{"y":-5,"r":-15,"p":-5,"l":-5,"a":-5,".":-5}},"h":{"d":"83,-153v35,-46,128,-40,128,43r0,110r-63,0r0,-99v0,-18,-6,-35,-26,-34v-20,1,-28,15,-39,28r0,105r-63,0r0,-244r63,0r0,91","w":229},"i":{"d":"55,-247v14,0,27,13,27,27v0,14,-12,27,-27,26v-16,0,-26,-11,-27,-26v-1,-14,13,-27,27,-27xm87,0r-64,0r0,-179r64,0r0,179","w":110},"j":{"d":"55,-247v14,0,27,13,27,27v0,14,-12,27,-27,26v-16,0,-26,-11,-27,-26v-1,-14,13,-27,27,-27xm-3,36v24,-6,26,-22,26,-55r0,-160r64,0r0,189v0,46,-28,72,-69,75","w":110},"k":{"d":"233,0r-80,0r-69,-85r0,85r-64,0r0,-244r64,0r0,143r63,-78r76,0r-70,84","w":232,"k":{"y":5,"u":5,"s":10,"q":15,"o":15,"g":10,"e":15,"d":15,"c":15}},"l":{"d":"87,0r-64,0r0,-244r64,0r0,244","w":110,"k":{"o":5}},"m":{"d":"205,-147v32,-51,134,-48,134,38r0,109r-63,0r0,-95v0,-23,-5,-38,-26,-38v-21,0,-28,14,-39,28r0,105r-63,0r0,-95v-1,-21,-5,-38,-26,-38v-20,0,-31,18,-39,28r0,105r-63,0r0,-179r63,0r0,26v24,-37,108,-41,122,6","w":356},"n":{"d":"83,-153v36,-48,128,-39,128,48r0,105r-63,0r0,-97v-1,-20,-4,-36,-26,-36v-21,1,-29,16,-39,28r0,105r-63,0r0,-179r63,0r0,26","w":229,"k":{"w":-5}},"o":{"d":"115,-182v64,0,103,31,103,92v0,60,-40,93,-103,93v-62,0,-102,-32,-102,-93v0,-61,40,-92,102,-92xm115,-44v26,0,36,-19,36,-46v0,-26,-11,-45,-36,-45v-25,0,-36,20,-36,45v0,26,11,46,36,46","w":230,"k":{"z":5,"y":5,"x":10,"w":5,"v":5,",":10}},"p":{"d":"83,-163v48,-44,144,-5,134,72v6,75,-73,116,-134,81r0,91r-63,0r0,-260r63,0r0,16xm83,-54v26,23,72,8,67,-35v6,-44,-43,-58,-67,-33r0,68","w":229,"k":{"z":10,"y":10,"w":5,".":5,",":10}},"q":{"d":"13,-91v-9,-77,83,-116,133,-72r0,-16r64,0r0,260r-64,0r0,-91v-60,36,-141,-7,-133,-81xm79,-89v-4,42,38,59,67,35r0,-68v-22,-24,-73,-12,-67,33","w":229},"r":{"d":"83,-136v9,-34,58,-63,95,-33r-24,63v-29,-29,-62,-7,-71,29r0,77r-63,0r0,-179r63,0r0,43","w":177,"k":{"u":5,"t":5,"s":10,"q":15,"p":5,"o":15,"l":5,"k":5,"j":5,"i":15,"g":10,"e":15,"d":15,"c":15,"a":5,";":5,".":26,"-":15,",":31}},"s":{"d":"99,-142v-29,0,-21,22,4,30v31,10,56,22,57,60v3,63,-94,64,-140,41r0,-45v19,10,29,18,53,19v31,2,28,-21,8,-29v-27,-11,-64,-24,-64,-62v0,-59,89,-64,134,-40r0,44v-15,-9,-29,-18,-52,-18","w":174,"k":{",":5}},"t":{"d":"96,-135v4,35,-15,91,26,88v10,0,23,-5,39,-13r0,50v-47,23,-138,19,-128,-54r0,-71r-29,0r0,-11r85,-87r7,0r0,54r61,0r0,44r-61,0","w":168},"u":{"d":"107,-46v22,-1,27,-14,38,-28r0,-105r64,0r0,179r-64,0r0,-25v-17,17,-32,28,-63,28v-88,4,-59,-103,-64,-182r63,0r0,97v1,20,4,36,26,36","w":229},"v":{"d":"209,-179r-82,179r-46,0r-80,-179r68,0r37,94r41,-94r62,0","w":209,"k":{"q":5,"o":5,"e":5,"d":5,"c":5,".":21,",":26}},"w":{"d":"305,-179r-71,179r-40,0r-39,-98r-40,98r-40,0r-73,-179r65,0r32,90r35,-90r41,0r35,90r32,-90r63,0","w":307,"k":{"q":5,"o":5,"e":5,"d":5,"c":5,"a":5,".":15,",":21}},"x":{"d":"220,0r-78,0r-35,-51r-35,51r-69,0r69,-88r-70,-91r78,0r33,49r33,-49r69,0r-67,85","w":221,"k":{"o":10,"e":15,"d":10,"c":10}},"y":{"d":"212,-179r-122,260r-64,0r50,-104r-71,-156r68,0r36,89r41,-89r62,0","w":209,"k":{"e":5,".":21,",":26}},"z":{"d":"190,-173r-85,126r84,0r0,47r-184,0r0,-6r86,-126r-79,0r0,-47r178,0r0,6","w":198,"k":{"o":5,"e":10,"d":5,"c":5}},"{":{"d":"98,-8v-1,32,5,45,35,44r0,49v-65,4,-89,-17,-89,-82v0,-35,-1,-59,-36,-59r0,-50v31,0,36,-21,36,-52v0,-71,20,-93,89,-89r0,49v-30,-2,-35,8,-35,36v1,40,-3,71,-31,81v27,13,33,31,31,73","w":138},"|":{"d":"75,85r-44,0r0,-332r44,0r0,332","w":105},"}":{"d":"95,-166v0,34,3,60,36,60r0,50v-31,0,-38,19,-36,52v3,70,-20,94,-90,89r0,-49v28,0,35,-6,35,-36v0,-39,4,-70,32,-81v-26,-14,-32,-33,-32,-74v0,-33,-2,-44,-35,-43r0,-49v66,-3,90,14,90,81","w":138},"~":{"d":"167,-130v25,0,37,-14,52,-26r0,45v-18,14,-32,24,-56,25v-28,1,-61,-28,-87,-28v-24,0,-39,12,-55,26r0,-45v15,-11,32,-25,58,-25v22,0,61,27,88,28","w":240},"\u00a9":{"d":"144,-247v81,0,135,54,135,134v0,78,-57,134,-135,134v-77,0,-134,-57,-134,-134v0,-81,54,-134,134,-134xm144,-5v64,0,109,-46,109,-108v0,-64,-44,-108,-109,-108v-65,0,-108,44,-108,108v0,62,44,108,108,108xm111,-114v1,25,5,53,33,51v16,0,27,-12,32,-34r36,9v-9,28,-28,52,-67,51v-45,-1,-70,-31,-73,-76v-6,-80,120,-105,138,-27r-34,6v-4,-19,-15,-28,-32,-28v-25,0,-33,23,-33,48","w":288},"\u00a0":{"w":106}}});



//CONTEXTS OBJECT FOR MORE EFFICIENT jQuery SELECTIONS
window["_top"] = window.top;
window["_ctx"] = {"cache": function(strName, strSelector, oContext){
	//THIS CACHES A jQuery CONTEXT UNLESS IT ALREADY EXISTS
	if(!isUsable(_ctx[strName])){
		if(isUsable(oContext)){
			_ctx[strName] = $(oContext).find(strSelector);
		}
		else{
			_ctx[strName] = $(strSelector);
		}
	}
	return _ctx[strName];
}};
//alert("about to define _data (8520904)");
window["_data"] = {};
//GLOBAL FUNCTIONS

//---------------------------------------------------------------------------------
window["v"] = function(){};
window["_errors"] = [];
window["_chromelog"] = [];
window["log"] = function(str, obj){_chromelog.push(str);if(isUsable(obj)){dump(obj);}if(window.console){try{console.log(str);}catch(err){/*DO NOTHING ON ERROR*/}}}
window["dump"] = function(obj){if(!isUsable(window["_dump"])){window["_dump"] = [];}_dump.push(obj);};
window["showdump"] = function(){$.each(_dump, function(i, obj){log(obj);});};
window["obj_id"] = function(obj){
	if(obj.type == "event"){
		return "e" + obj.event_id;
	}
	else if(obj.type == "venue"){
		return "v" + obj.venue_id;
	}
	else{
		log("no obj type (3501583)");
	}
};

//---------------------------------------------------------------------------------
//TESTING & ASSERTIONS
window["test"] = {};
test["assert"] = function(bolCondition, strError){if(!bolCondition){_errors.push(strError);}};
test["require"] = function(param, strError){test.assert(u(param), strError);};
test["ok"] = function(){var bolOK=(_errors.length==0);if(bolOK){return bolOK;}else{log(_errors.join("; "));_errors=[];return !bolOK;}};

//---------------------------------------------------------------------------------
window["u"] = function(o){return (!(o === null) && !(typeof o === "undefined"));};
window["isUsable"] = function(o, ifnot){
	if(arguments.length == 1){
		return u(o);
	}
	else{
		if(u(o)){
			return o;
		}
		else{
			return ifnot;
		}
	}
};
window["tryCallback"] = function(fn, data){if(isUsable(fn)){fn(data);}};

//---------------------------------------------------------------------------------
window["bind"] = function(strEvent, fnHandler){
	//NOTE -- IF DATA WILL NEED TO BE PASSED, MAKE SURE THE fnHandler HAS PARAMETERS (e, data) 
	//NEED TO USE "e" AS A PLACEHOLDER EVEN IF IT'S NOT PASSED THROUGH IN THE CALLBACK
	if(isUsable(fnHandler)){
		$(window.top).unbind(strEvent).bind(strEvent, function(e, data){
			fnHandler(e, data);
		});	
	}
	else{
		$(window.top).unbind(strEvent);	
	}
};

//---------------------------------------------------------------------------------
window["trigger"] = function(strEvent, oData, bolUnbind){
	$(window.top).trigger(strEvent, oData);
	if(isUsable(bolUnbind)){
		if(bolUnbind){$(window.top).unbind(strEvent);}
	}
};

//---------------------------------------------------------------------------------
window["waitfor"] = function(bol, strEventName, fnCallback){
	if(bol){
		tryCallback(fnCallback);
	}
	else{
		//log("waitfor '" + strEventName + "' (1380040)");
		bind(strEventName, function(){
			log("unbinding '" + strEventName + "' (1254132)");
			bind(strEventName);
			tryCallback(fnCallback);
		});
	}
};

//---------------------------------------------------------------------------------
window["track"] = function(strCategory, strAction, strLabel, iValue){
	//SUBMITS A JS EVENT TO GOOGLE ANALYTICS
	//options. category, action [, label[, value]]
	setTimeout(function(){
		try{
			if(isUsable(strCategory) && isUsable(strAction)){
				var strLabel = isUsable(strLabel) ? strLabel : "";
				var strValue = isUsable(strValue) ? strValue : "";
				if(isUsable(window["_gaq"])){
					_gaq.push(['_trackEvent', strCategory, strAction, strLabel, strValue]);
				}
			}
			else{
				log("Required arguments are strCategory and strAction (4986843)");
			}
		}
		catch(e){
			//DO NOTHING
			log("error during trackEvent(): " + e + " (3249153)");
		}
	}, 100);
};

// jQuery PLUGINS -----------------------------------------------------------------

//DEEP-CLONE AN OBJECT + TOP-LEVEL ARRAYS...
jQuery["clone"] = function(o){return jQuery.extend(true, {}, o);}
jQuery.fn["stripHTML"] = function() {
	
	var text = [];

	this.each(function(i, el){
		text.push($(el).html().replace(/<\/?[^>]+>/gi, "")); //REMOVE HTML 
	});
	
	return $.trim(text.join("").replace(/(\r\n|\n|\r)/gm, " ").replace(/\s+/g, " ")); //REMOVE LINE BREAKS AND DOUBLE WHITE SPACES
	
};
jQuery.fn["reverse"] = [].reverse; 

//---------------------------------------------------------------------------------




window["crs"] = { //i.e. "Cursor"

	//THIS CLASS ENCAPSULATES THE VARIOUS PROPERTIES THAT DETERMINE THE PAGE'S CURRENT "view"
	//e.g., cursor.dt, cursor.lat, cursor.lon, cursor.items
	//RATHER THAN USING THE "key" PROPERTY, e.g. (dt20100629_tab-undefined_lat--200_lon--200_rad-undefined_who--1_what--1),
	//TO STORE ITEMS, IT STORES THE KEYS IN crs.keyDB AND THEN USES A "KeyID" TO KEEP TRACK OF THE ITEMS
	
	//.reset -----------------------------------------
	reset: function(){
		crs._key = null;
		crs._dtkey = null;
	},

	//.makeKey ---------------------------------------
	makeKey: function(dt){
		
		//THIS RETURNS A KEY BASED ON:
		//1) THE CURRENT DATE, 
		//2) THE CURRENT GEOGRAPHICAL LOCATION,
		//3) THE CURRENT PAGE INDEX,
		//4) THE 'Who' AND 'What' PARAMETERS ON A HUB PAGE
		var strDate = _utils.formatDate(new Date(), "-");
		//var dtDate = _utils.parseDate(strDate, "-");
		if(!isUsable(crs.dt())){crs.dt_set(_utils.parseDate(strDate, "-"));}
		var dtToUse = crs.dt();
		if(isUsable(dt)){dtToUse = dt;}
	
		var prms = {};
		prms.dt = _utils.formatDate(dtToUse, "dtkey");
		prms.lat = crs.lat();
		prms.lon = crs.lon();
		prms.radius = _data.radius;
		prms.page = isUsable(window["_feed"]) ? _feed.pageIndex : 0;
		prms.who = crs.who();
		prms.what = crs.what();
	
		var strDataKey = prms.dt 
						+ "_tab-" 	+ prms.tab 
						+ "_lat-" 	+ prms.lat 
						+ "_lon-" 	+ prms.lon 
						+ "_rad-" 	+ prms.radius
						+ "_who-" 	+ prms.who
						+ "_what-" 	+ prms.what;
	
		return strDataKey;
		
	},
	
	//.dt --------------------------------------------
	dt: function(){
		if(!isUsable(crs._currentDate)){crs._currentDate = new Date();}
		return crs._currentDate;
	},
	dt_set: function(thisDate){
		crs.reset();
		crs._currentDate = thisDate;
	},

	//.key -------------------------------------------
	key: function(){
		if(!isUsable(crs._key)){crs._key = crs.makeKey();}
		if(!isUsable(crs._keys)){crs._keys = [crs._key];}
		if(crs._key != crs._keys[crs._keys.length - 1]){crs._keys.push(crs._key);}
		return crs._key;
	},

	//.keyID -----------------------------------------
	keyID: function(key){
		var iID = -1;
		if(!isUsable(crs.keyDB)){crs.keyDB = _utils.initializeTaffy({type: "keys"});}
		var keyToUse = isUsable(key, crs.key());
		var rows = crs.keyDB.find({key: keyToUse});
		if(rows.length == 0){
			iID = crs.keyDB.insert({key: keyToUse})[0];
		}
		else{
			iID = rows[0];
		}
		return iID;
	},

	//.last_key --------------------------------------
	last_key: function(){
		if(!isUsable(crs._key)){var tmp = crs.key();}
		var tmp = crs._keys[crs._keys.length - 2];
		if(!isUsable(tmp)){
			tmp = crs.key();
		}
		return tmp;
	},

	//.who -------------------------------------------
	who: function(){
		if(!isUsable(crs._who)){crs._who = _settings.getOrDefault("hub.who", "-1");}
		return crs._who;
	},
	who_set: function(strWho){
		crs.reset();
		crs._who = strWho;
	},

	//.what ------------------------------------------
	what: function(){
		if(!isUsable(crs._what)){crs._what = _settings.getOrDefault("hub.what", "-1");}
		return crs._what;
	},
	what_set: function(strWhat){
		crs.reset();
		crs._what = strWhat;
	},

	//.dom_key ---------------------------------------
	dom_key: function(){
		return "div_" + crs.key().replace(/\./g, "");
	},

	//.dtkey -----------------------------------------
	dtkey: function(){
		if(!isUsable(crs._dtkey)){crs._dtkey = _utils.formatDate(crs.dt(), "dtkey");}
		return crs._dtkey;
	},

	//.items -----------------------------------------
	items: function(){
		return _feed.db.get({keyID: crs.keyID()});
	},
	
	//.items -----------------------------------------
	all_items: function(){
		return _feed.db.get();
	},
	
	//.pageIndex -------------------------------------
	pageIndex: function(){
		return _feed.pageIndexes[crs.key()];
	},
	pageIndex_set: function(value){
		_feed.pageIndexes[crs.key()] = value;
	},
	
	//.page ------------------------------------------
	page: function(){
		return _feed.db.get({keyID: crs.keyID(), pageIndex: crs.pageIndex()});
	},
	
	//.lat -------------------------------------------
	lat: function(){
		if(!isUsable(crs._lat)){crs._lat = -200;}
		return crs._lat;
	},
	lat_set: function(fLat){
		crs._key = null;
		crs._lat = fLat;
	},

	//.lon -------------------------------------------
	lon: function(){
		if(!isUsable(crs._lon)){crs._lon = -200;}
		return crs._lon;
	},
	lon_set: function(fLon){
		crs._key = null;
		crs._lon = fLon;
	},
	//.radius ----------------------------------------
	radius: function(){
		if(!isUsable(crs._radius)){crs._radius = 5 ;}
		return crs._radius;
	},
	radius_set: function(fRadius){
		crs._key = null;
		crs._radius = fRadius;
	}

};

//--------------------------------------------------------

//--------------------------------------------------------


/**
 * @constructor
 */
function HotListURL() {

}
window["_url"] = new HotListURL();



/**
 * @constructor
 */
function HotListUtils() {
	
	this.shortdays = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
	this.longdays = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
	this.shortmonths = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Nov", "Dec"];
	this.longmonths = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "November", "December"];

}
window["_utils"] = new HotListUtils(); 

//--------------------------------------------------------
//OVERLAY THE BG IMAGE 
_utils["content_loader"] = function(url){

	if(document.getElementById("TB_overlay") === null){
		$("body").append("<div id='TB_overlay'></div>");
		$("#TB_overlay").addClass("TB_overlayBG");//use background and opacity
	}
	$("body").append("<div id='TB_load'><img src='/images/loadingAnimation.gif' /></div>");//add loader to the page
	$('#TB_load').show();//show loader
	window.location = url;

};

//--------------------------------------------------------
_utils["formatThousands"] = function(str){
	
	dblValue = parseFloat(str);
	dblValue = Math.floor(dblValue*100+0.50000000001);
	dblValue = Math.floor(dblValue/100).toString();

	for (var i = 0; i < Math.floor((dblValue.length - (1 + i)) / 3); i++) {
		dblValue = dblValue.substring(0, dblValue.length - (4 * i + 3)) + ',' + dblValue.substring(dblValue.length - (4 * i + 3));
	}

	return dblValue;
	
};

//--------------------------------------------------------
_utils["formatSentence"] = function(arrItems, iMax){
	
	var html = [];
	var iTotal = iMax < arrItems.length ? iMax : arrItems.length;

	for(var i = 0; i < iTotal; i++){
		var strSeparator = "";
		if((iTotal != 1) && (i != iTotal - 1)){
			strSeparator = ((i == iTotal - 2) ? " and " : ", ");
			if((iMax < arrItems.length) && i == 1){
				strSeparator = ", ";
			}
		}
		html.push(arrItems[i] + strSeparator);
	}
	
	//AND X MORE?
	if(iMax < arrItems.length){
		html.push(" and <span class='x_more'>" + (arrItems.length - iMax) + " more</span>");
	}

	return html.join("");
	
};

//--------------------------------------------------------
_utils["hackNewJSONFormat"] = function(pt, bolOverrideStats){

	log("HACK!! _utils.hackNewJSONFormat (9098829)");

	pt.type = isUsable(pt.type, pt.tooltipJSON.type);
	//log("NEW CROWD from hackNewJSONFormat (1255761)");
	pt.crowd = new TAFFY(pt.goingIDs);
	
	//EVENT ID / VENUE ID	
	if(!isUsable(pt.event_id)){
		pt.event_id = isUsable(pt.id) ? pt.id : -1;
	}
	if(!isUsable(pt.venue_id)){
		pt.venue_id = -1;
	}

	pt.event_name = pt.tooltipJSON.title;
	pt.event_url = pt.tooltipJSON.href;
	
	if(!isUsable(pt.venue_name)){
		pt.venue_name = pt.event_name;
	}
	if(!isUsable(pt.venue_url)){
		pt.venue_url = pt.event_url;
	}
	
	//DEFAULT DISPLAY NAME AND URL
	pt.display_name = (pt.type == "event") ? pt.event_name : pt.venue_name;
	pt.display_url = (pt.type == "event") ? pt.event_url : pt.venue_url;
		
	pt.lat = pt.lat;
	pt.lon = pt['long'];
	pt.start = pt.start_timestamp;
	pt.end = pt.end_timestamp;
		
	//STATS
	if(bolOverrideStats){
		pt.stats = {};
	}
	var strTotalGoing = (pt.tooltipJSON.stats[0].value.substr(76, 5)).replace("p", "");
	var arrGenders = (pt.tooltipJSON.stats[1].value).split("%");
	pt.stats.total_going = parseInt(strTotalGoing);
	pt.stats.gender_m = arrGenders[0];
	pt.stats.gender_f = arrGenders[1].replace(" Male, ", "");
	pt.stats.friend_count = pt.friendCount;
	
	return pt;
	
};

//--------------------------------------------------------
_utils["formatDate"] = function(dt, strType){
	var html = [];
	switch(strType){
		case "dn": // "Sun"
			html.push(_utils.shortdays[dt.getDay()]);
			break;
		case "dn m/d": // "Sun, 4/12"
			html.push(_utils.shortdays[dt.getDay()] + " ");
			html.push((dt.getMonth() + 1) + "/" + dt.getDate());
			break;
		case "dn * m/d": // "e.g. Sun night, 4/12"
			html.push(_utils.shortdays[dt.getDay()] + " * ");
			html.push((dt.getMonth() + 1) + "/" + dt.getDate());
			break;
		case "DN * m/d": // "e.g. Sunday night, 4/12"
			html.push(_utils.longdays[dt.getDay()] + " * ");
			html.push((dt.getMonth() + 1) + "/" + dt.getDate());
			break;
		case "DN M d": // "Sunday, April 12"
			html.push(_utils.longdays[dt.getDay()] + ", " + _utils.longmonths[dt.getMonth()] + " " + dt.getDate());
			break;
		case "m/d": // "4/12"
			html.push((dt.getMonth() + 1) + "/" + dt.getDate());
			break;
		case "mn": // "Apr"
			html.push(_utils.shortmonths[dt.getMonth()]);
			break;
		case "-": // 2010-04-12
			html.push(dt.getFullYear() + "-" + _utils.strTwoDigits((dt.getMonth() + 1)) + "-" + _utils.strTwoDigits(dt.getDate()));
			break;
		case "": // 20100412
			html.push(dt.getFullYear() + _utils.strTwoDigits((dt.getMonth() + 1)) + _utils.strTwoDigits(dt.getDate()));
			break;
		case "dtkey": // dt20100412
			html.push("dt" + dt.getFullYear() + _utils.strTwoDigits((dt.getMonth() + 1)) + _utils.strTwoDigits(dt.getDate()));
			break;
		case "timestamp": //UNIX TIMESTAMP == JS TIMESTAMP / 1000
			html.push(dt.getTime() / 1000);
			break;
		default:
			alert("invalid strType [" + strType + "] (1442422)");
			break;
	}
	return html.join("");
};

//--------------------------------------------------------
_utils["parseDate"] = function(str, strFormat){
	var dt = new Date();
	switch(strFormat){
		case "-": // 2010-04-12
			var parts = str.split("-");
			dt = new Date(parts[0], parseInt(parts[1], 10) - 1, parts[2]);
			break;
		case "/": // 04/12/2010
			var parts = str.split("/");
			dt = new Date(parts[2], parseInt(parts[0], 10) - 1, parts[1]);
			break;
		case "dtkey": // dt20100412
			var strDate = str.replace("dt", "");
			dt = new Date(strDate.substr(0, 4), (parseInt(strDate.substr(4, 2), 10) - 1) + "", parseInt(strDate.substr(6, 2), 10) + "");
			break;
		case "timestamp": // 1274801041556
			str = str + "";
			if(str.length < 13){str = str + "000";} //MULTIPLY UNIX TIMESTAMPS BY 1000
			dt = new Date(parseInt(str, 10));
			break;
		default:
			alert("invalid strFormat [" + strFormat + "] (3763452)");
			break;
	}
	return dt;
};

//--------------------------------------------------------
_utils["getPosition"] = function(el){
	
	var curleft = 0;
	var curtop = 0;
	if (el.offsetParent) {
		do {
			curleft += el.offsetLeft;
			curtop += el.offsetTop;
		} while (el = el.offsetParent);
    }
    return [curleft,curtop];
	
};

//--------------------------------------------------------
_utils["dateDiff"] = function(dt1, dt2){

	//RETURNS SECONDS BETWEEN THESE DATES
	var diff = dt1.getTime() - dt2.getTime();
	if(diff < 0){diff = diff * -1;}
	return diff / 1000;
	
};

//--------------------------------------------------------
_utils["parseAndFormatDate"] = function(str, strParse, strFormat){
	//log("_utils.parseAndFormatDate(" + str + ", " + strParse + ", " + strFormat + ") (3850346)");
	return _utils.formatDate(_utils.parseDate(str, strParse), strFormat);
};

//--------------------------------------------------------
_utils["addDays"] = function(dt, iDays){
	return new Date(dt.getTime() + (iDays * 86400000));
};

//--------------------------------------------------------
_utils["formatTime"] = function(strTime){
	
	var timeParts = strTime.split(":");
	var iHour = parseInt(timeParts[0]);
	var bolPM = iHour > 11;
	if(iHour == 0){
		iHour = 12;
	}
	else if(iHour > 12){
		iHour -= 12;
	}
	
	return iHour + ":" + timeParts[1] + " " + (bolPM ? "pm" : "am");
};

//----------------------------------------------------------------
_utils["strTwoDigits"] = function(iNumber){
    if (iNumber == 0) {return "00";}
	else if (iNumber < 10) {return "0" + iNumber;}
	else {return "" + iNumber;}
};

//--------------------------------------------------------
_utils["isFuzzyDate"] = function(dt1, dt2){
	return (dt1.getDate() == dt2.getDate() && dt1.getMonth() == dt2.getMonth() && dt1.getFullYear() == dt2.getFullYear());
};

//--------------------------------------------------------
_utils["linkEmail"] = function(strUsername, strLinkText){
	var strEmail = strUsername + "@thehotlist.com";
	var strLinkText2 = strLinkText;
	if(!isUsable(strLinkText)){
		strLinkText2 = strEmail;
	}
	document.write("<a title='Send email to " + strEmail + "' href='mailto:" + strEmail + "'>" + strLinkText2 + "</a>");
};

//--------------------------------------------------------
_utils["updateURL"] = function(strAppend){
	
	_utils.expectedFragment = strAppend;
	var url = document.location.toString();
	url = url.split("#")[0] + "#" + strAppend + "&ts=" + (new Date()).getTime();
	document.location = url;
	
};

//--------------------------------------------------------
_utils["parseURL"] = function(){
	
	var result = {};
	var fragment = document.location.toString().split("#")[1];
	if(isUsable(fragment)){
		var pairs = fragment.split("&");
		$.each(pairs, function(i, pair){
			var parts = pair.split("=");
			result[parts[0]] = parts[1];
		});
	}
	
	return result;
	
};

//--------------------------------------------------------
_utils["initializeTaffy"] = function(prms){
	
	var result = null;
	
	switch(prms.type){
		case "keys":
		
			result = new TAFFY([{key: "asdf"}]);
			result.remove();

		case "feed":
		
			result = new TAFFY([{
				key: -1,
				type: "event",
				event_id: -1,
				event_name: "MK bday",
				event_url: "#",
				venue_id: -1,
				venue_name: "MK house",
				venue_url: "#",
				lat: -200,
				lon: -200,
				created: 229665600,
				start: 229665600,
				end: 229665600,
				crowd_ids: [],
				friend_count: 0,
				user_status: "",
				address: "",
				city: "",
				state: "",
				country: "",
				stats: []
			}]);
			result.remove();
		
			break;
		default:
			log("invalid prms.type " + prms.type + " (7694465)");
			break;
	}
	
	return result;
	
};

//--------------------------------------------------------
_utils["randomReload"] = function(bolActivate){
	
	if(isUsable(bolActivate)){
		_settings.set("randomReload", bolActivate);
		if(bolActivate){
			_utils.randomReload();
		}
	}

	var urls = ["/friends", 
					"/places", 
					"/friends", 
					"/places?type=venue&src=f&lat=40.714029&long=-73.961305&start_time=1275112800&end_time=1275130800", 
					"/friends", 
					"/places?type=venue&src=f&lat=40.730681&long=-73.953996&start_time=1275109200&end_time=1275130800", 
					"/friends", 
					"/places?type=venue&src=f&lat=40.763795&long=-73.997477&start_time=1275109200&end_time=1275138000", 
					"/friends", 
					"/profiles/1060161243", 
					"/places?type=venue&src=f&lat=40.639258&long=-74.166035&start_datetime=1274857200&end_datetime=1274943599",
					"/places?type=venue&src=f&lat=40.756991&long=-73.979391&start_time=1275084000&end_time=1275112800"];
	if(_settings.getOrDefault("randomReload", false)){
		log("randomReload (4980781)");
		var timer = 3000;
		var iURL = Math.floor(Math.random() * urls.length); //_settings.getOrDefault("iURL", 0);
		//var nextURL = isUsable(urls[iURL + 1]) ? iURL + 1 : 0;
		//_settings.set("iURL", nextURL);
		var url = urls[iURL];
		log("reloading in " + timer + "ms");
		setTimeout(function(){
			_top.location = "http://localhost" + url;
		}, timer);
	}
	
};

//--------------------------------------------------------
_utils["randomClick"] = function(bolActivate){

	//ADD CANCEL LINK
	$("body").find(".rclickdiv").remove().end().prepend("<div class='rclickdiv ac' style='border: 2px solid green; padding: 4px; font-weight: bold; '><a class='crandomlink' href='#' onclick='_utils.randomClick(false);'>Cancel random clicks</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a class='crandomlink' href='#' onclick='_utils.randomClick(true);'>Start random clicks</a></div>");

	
	if(isUsable(bolActivate)){
		_settings.set("randomClick", bolActivate);
		if(bolActivate){
			_utils.randomClick();
		}
		else{
			clearInterval(window.randomClickInterval);
		}
	}

	if(_settings.getOrDefault("randomClick", false)){
		if(!isUsable(window.randomClickInterval)){
			window.randomClickInterval = setInterval(function(){

				//PICK A LINK AT RANDOM
				var els = $("a,div,span");
				var index = Math.floor(Math.random() * els.length);
				//log("checking index " + index + ".... (3285436)");
				for(var i = 0; i < 100; i++){
					var el = $(els[index]);
					//DON'T CLICK IF...
					if((el.closest(".footer").length > 0) 
					|| el.hasClass("logout") 
					|| el.hasClass("invite") 
					|| el.hasClass("remove") 
					|| el.hasClass("crandomlink") 
					|| el.hasClass("maybe") 
					|| el.hasClass("going")
					|| (isUsable(el.attr("id")) && el.attr("id") == "hlCheckin")){
						index = Math.floor(Math.random() * els.length);
					}
					else{
						i = 1000;
						els.removeClass("highlight");
						$("#fade").click();
						//log("clicking...");
						//log(el);
						el.addClass("highlight").click();
						if(el.is(":visible") && isUsable(el.attr("href")) && (el.attr("href") != "javascript:v();") && (el.attr("href") != "#")){// && isUsable(window.randomClickInterval)){
						
							//DON'T LEAVE HOTLIST
							var href = el.attr("href");
							if(href.indexOf("/") == 0){
								log("real link clicked! (2496039)");
								log(el.attr("href"));
								document.location = el.attr("href");
								clearInterval(window.randomClickInterval);
							}
						}
					}
				}
				
			}, 1000);
		}
	}
	
};

//--------------------------------------------------------



/**
  * @constructor
  */
function HotListFB() {
 	this.connected = false;
 	this.atListFQLAttempts = 0;
 	this.overrideConnectionActions = false;
	this.userImages = [];
}

window["_fb"] = new HotListFB(); 

//--------------------------------------------------------
_fb["setupCarousel"] = function(prms){

	//log("fb.setupCarousel prms (6363567)");
	//log(prms);
	
	waitfor(_fb.connected, "fb.onConnected", function(){
	
		var last_line = "";
		try {
		
			test.require(prms.points, "prms.points required (3929059)");
			test.require(prms.points[prms.indexInPage], "invalid prms.points[" + prms.indexInPage + "] (1237504)");
			test.require(prms.containers, "prms.containers required (1852645)");
			test.require(prms['class'], "prms.class required (2900736)"); //prms.class triggers error in Safari;
			test.require(prms.visible, "prms.visible required (1062290)");
			if (test.ok()) {
			
				//CHECK THE REQUESTED DATAPOINT
				var singlePoint = prms.points[prms.indexInPage];
				
				if (!isUsable(singlePoint.carousel)) {
				
					//GET REFERENCE TO THE SINGLE POINT'S divFriends
					var singlePointDivFriends = $(prms.containers[prms.indexInPage]).find("div.friends");
					
					//IF ATTENDEES HAVE ALREADY BEEN FETCHED,
					if (isUsable(singlePoint.carouselHTML)) {
					
						//SINCE THIS divAtX PARENT SHOULD BE "on", CALL carousel 
						log("Loading single point (6090225)");
						singlePoint.carousel = singlePointDivFriends.html(singlePoint.carouselHTML).find(".carousel").jCarouselLite({
							btnPrev: ".prev",
							btnNext: ".next",
							scroll: 2,
							circular: false,
							visible: prms.visible
						});
						setTimeout(function(){
							if (singlePointDivFriends.find("*").length == 0) {
								alert("Show 'Getting friend info' (2860778)");
							}
						}, 100);
						
					}
					else {
					
						//IF FB DATA HAS BEEN FETCHED FOR THIS FIRST POINT, MAKE A CAROUSEL
						if (isUsable(singlePoint.crowd.first().name)) {
						
							//BUILD AND CACHE CAROUSEL
							_fb.buildAndCacheCarousel(singlePoint, prms.containers[prms.indexInPage], prms['class'], prms.suffix);
							
							//CALL jCarousel
							singlePoint.carousel = singlePointDivFriends.find("div.carousel").jCarouselLite({
								btnPrev: ".prev_" + prms.suffix,
								btnNext: ".next_" + prms.suffix,
								scroll: 2,
								circular: false,
								visible: prms.visible,
								callback: function(){
									_fb.preloadCarouselImages();
									tryCallback(prms.callback);
								}
							});
							
						}
						
						//FETCH ANY UN-FETCHED FRIENDS FOR ALL POINTS -----------------------
						//GROUP ALL QUERIES TO BE SENT TO FB
						errors = [];
						//var sequencer = new FB.BatchSequencer();
						var queries = [];
						var requestedPoints = [];
						var requestedContainers = [];
						$.each(prms.points, function(i, point){
						
							//ONLY INCLUDE POINTS WHOSE FRIENDS HAVEN'T BEEN FETCHED
							if (!isUsable(point.crowd.first().name)) {
							
								if (point.crowd.find().length > 0) {
								
									//BUILD QUERY TO GET THIS POINT'S FRIENDS
									var query = FB.Data.query("SELECT uid, name, first_name, pic_square FROM user WHERE uid in (" + _fb.joinCrowdUIDs(point) + ")");
									requestedPoints.push(point);
									requestedContainers.push(prms.containers[i]);
									queries.push(query);
									
								}
								else {
								
									$(prms.containers[point.count]).find("div.friends").html("<div class='gray ac clear pt20'>No friends returned from Facebook</div>");
									errors.push("point.crowd.find().length == 0 for prms.points[" + point.count + "] (1647081)");
									
								}
								
							}
							else {
								//ATTENDEES WERE ALREADY FETCHED; INSERT THE HTML AND CALL jCarousel
								//log("attendees already fetched? (9530808)");
							}
							
						});//-----------------------------------------------------------------
						//EXECUTE THE SEQUENCER
						if (queries.length > 0) {
							//log("about to call FB.Data.waitOn (5279855)");
							//log(queries);
							
							FB.Data.waitOn(queries, function(args){
							
								//log("FB data returned: (2088019)");
								//log("args.length == " + args.length);
								
								//FOR EACH RESULT RETURNED,
								$.each(args, function(i, arg){
								
									//GET THIS DATAPOINT AND FRIENDS DIV
									var point = requestedPoints[i];
									var container = requestedContainers[i];
									var divFriends = $(container).find("div.friends");
									
									//IF THERE ARE ROWS,
									if (isUsable(arg) && arg.length > 0) {
									
										//MERGE DATA FROM FB WITH DATA FROM SERVER
										_fb.mergeRows(point.crowd, arg);
										
										//BUILD AND CACHE CAROUSEL
										_fb.buildAndCacheCarousel(point, container, prms['class'], prms.suffix);
										
										//IF THIS IS THE REQUESTED ITEM, CALL carousel
										if (prms.indexInDataset == point.count) {
											point.carousel = divFriends.find("div.carousel").jCarouselLite({
												btnPrev: ".prev_" + prms.suffix,
												btnNext: ".next_" + prms.suffix,
												scroll: 2,
												circular: false,
												visible: prms.visible,
												callback: function(){
													_fb.preloadCarouselImages();
													tryCallback(prms.callback);
												}
											});
										}
										
									}
									else {
									
										point.carouselHTML = "<div class='gray ac clear pt20'>No friends returned from Facebook</div>";
										divFriends.html(point.carouselHTML);
										//log("No friends returned from Facebook for At #" + index + " (5438648)");
									
									}
								});
								//LOG ANY ERRORS
								if (errors.length > 0) {
									log(errors.join(", "));
								}
							});
						}
						else {
						
							//LOG ANY ERRORS
							$(prms.containers[prms.indexInPage]).find("div.friends").html("<div class='gray ac clear pt20'>No friends returned from Facebook</div>");
							errors.push("no queries to submit to FB (6195881)");
							log(errors.join(", "));
						}
						
					}
					
					
				}
				else {
					//log("carousel already called for the requested point (4498667)");
				}
				
			}
			
		} 
		catch (e2) {
			log(e2);
			log("last line reached: " + last_line + " ||||  (5846579)")
		}
	
	});
	
};

//--------------------------------------------------------
_fb["buildAndCacheCarousel"] = function(point, container, carouselClass, carouselSuffix){
	
	//GENERATE A STRING OF THE FRIENDS' NAMES
	var arrFriends = [];
	var iAttendeeCount = point.crowd.find().length;
	point.crowd.forEach(function(user, i){
		arrFriends.push(user.name);
	}, {friend: 1});
	var divFriendsSummary = $(container).find("div.stat_friends");
	if(arrFriends.length > 0){ //INSERTED AT (3507292)
		var strFriends = arrFriends.join(", ");
		point.stats.summary = strFriends + " and " + (point.stats.total_going - arrFriends.length) + " others.";
	}
	else{
		point.stats.summary = point.stats.total_going + " people";
	}
	divFriendsSummary.html(point.stats.summary);

	//INSERT CAROUSEL DOM ELEMENTS
	point.carouselHTML = _fb.makeCarousel(point.crowd, carouselClass, carouselSuffix);
	$(container).find("div.friends").html(point.carouselHTML).find("img").each(function(i, img){
		//CACHE THESE IMAGES OFFSCREEN
		img = $(img);
		_ctx.offscreen.append("<img src='" + img.attr("src") + "'/>");
	});

};

//--------------------------------------------------------
_fb["joinCrowdUIDs"] = function(point){
	
	test.require(point.crowd, "point.crowd is required (8631146)");
	var uids = [];
	
	if(point.crowd.TAFFY){
		point.crowd.forEach(function(user, i){
			if(isUsable(user.uid)){
				uids.push(user.uid);
			}
		});
	}
	else{
		for(var i = 0; i < point.crowd.find().length; i++){
			if(isUsable(point.crowd[i].uid)){
				uids.push(point.crowd[i].uid);
			}
			else{
				uids.push(point.crowd[i]);
			}	
		}
	}
	
	return uids.join(",");
	
};

//--------------------------------------------------------
_fb["preloadCarouselImages"] = function(){
	
	//log("_fb.preloadCarouselImages (7899621)");
	
	$.each(crs.all_items(), function(i, point){
		if(!isUsable(point.carousel) && !isUsable(point.imagesPreloaded) && isUsable(point.crowd.first().name)){

			var images = [];
			point.crowd.forEach(function(user, i){
				images.push("<img src='" + user.pic_square + "'/>");
			});
			
			_ctx.offscreen.append(images.join(""));
			
			point.imagesPreloaded = true;
			
		}
	});	
	
};

//--------------------------------------------------------
_fb["makeCarousel"] = function(crowd, strClass, strSuffix){
	
	var userTemplate = _tmpl.fbCarouselUser();
	
	//ROWS CONTAIN .uid, .pic_square, .first_name
	var html = [];
	html.push("");
	html.push("<div class='carousel_frame " + strClass + "'>");
	html.push("<table>");
	html.push("<tr>");
	html.push("<td class='carousel_arrow'>");
	html.push("<a class='spr_inside arrow prev prev_" + strSuffix + " disabled'>&nbsp;&nbsp;&nbsp;</a>");
	html.push("</td>");
	html.push("<td>");
	html.push("<div class='carousel'>");
	html.push("<ul>");

	//ADD LI's
	crowd.forEach(function(user, i){
		html.push(userTemplate.expand(user));
	});
	
	html.push("</ul>");
	html.push("</div>");
	html.push("</td>");
	html.push("<td class='carousel_arrow'>");
	html.push("<a class='spr_inside arrow next next_" + strSuffix + "'>&nbsp;&nbsp;&nbsp;</a>");
	html.push("</td>");
	html.push("</tr>");
	html.push("</table>");
	html.push("</div>");
	html.push("");
	
	return html.join("");
	
};

//--------------------------------------------------------
_fb["setupPivotPage"] = function(prms){

	//CACHE CONTEXTS
	_ctx.cache("crowdCarousel", "#divCrowdCarousel", _ctx.right);

	if (_fb.connected) {
	
		//GET A HANDLE FOR THE FIRST POINT
		var point = crs.items()[0];		
	
		//MAKE 3-4 "gettos"; OPTIONAL ONE FOR THE CURRENT USER'S PROFILE PIC,
		var gettos = [];
		if(_fb.user.uid > -1){
			var gettoProfilePic = {fbids: [_fb.user.uid], callback: function(){
				//[{uid, name, first_name, pic_square}]
				_fb.name = gettoProfilePic.rows[0].name;
				_fb.first_name = gettoProfilePic.rows[0].first_name;
				_fb.pic_square = gettoProfilePic.rows[0].pic_square;
				trigger("fb.profile");
			}};
			gettos.push(gettoProfilePic);
		}
		
		//ONE FOR THE FEED COMMENTERS
		var gettoCommenters = {};
		gettoCommenters.fbids = point.commenterIDs;
		gettoCommenters.callback = function(){
			_data.commenters = gettoCommenters.rows;
			trigger("fb.commenters");
		};
		gettos.push(gettoCommenters);
		
		//... AND ONE FOR THE "TODAY'S CROWD" CAROUSEL
		if(point.crowd.find().length > 0){
	
			var gettoTodaysCrowd = {};
			gettoTodaysCrowd.fbids = [];
			point.crowd.forEach(function(user, i){
				gettoTodaysCrowd.fbids.push(user.uid);
			});
			gettoTodaysCrowd.callback = function(){
		
				//SETUP CAROUSEL
				var strSuffix = "c";
				_ctx.crowdCarousel.find("div.friends").html(_fb.makeCarousel(gettoTodaysCrowd.rows, "pivot", strSuffix));
				_ctx.crowdCarousel.find("div.carousel").jCarouselLite({btnPrev: ".prev_" + strSuffix, btnNext: ".next_" + strSuffix, scroll: 4, circular: false, visible: 8, callback: function(){
					_fb.mergeRows(point.crowd, gettoTodaysCrowd.rows);
				}});
				
				//SELECT THIS EVENT GROUP
				if(isUsable(point.date)){
					_ctx.eventsContainer.find("div.dt" + point.date).addClass("on");
				}
				
			};
			gettos.push(gettoTodaysCrowd);
		}
		else{
			
			//JUST INSERT THE CAROUSEL TEMPLATE
			_ctx.crowdCarousel.find("div.friends").html(_fb.makeCarousel(new TAFFY([]), "pivot", "c"));

			//NO RESULTS FOR TODAY
			_page.fill({type: "pivot_empty_day", date: crs.dt()});
			
		}
	
		//BATCH THESE QUERIES
		_fb.batchQuery(gettos);

		

	}
	else{ //WAIT UNTIL FB IS CONNECTED		
		
		bind("fb.onConnected", function(){
			_fb.setupPivotPage(prms);
		});

	}

};

//--------------------------------------------------------
_fb["getCrowdInfo"] = function(point, fnCallback){
	
	//GETS NAME & PHOTO FOR ANY UNIDENTIFIED CROWD MEMBERS
	
	//MAKE GETTO (THOUGH IT MAY NOT BE CALLED)
	var getto = {fbids: [], callback: function(){

		//ONCE THIS RETURNS, UPDATE EACH USER'S INFO
		for(var i = 0; i < getto.rows.length; i++){
			var user = getto.rows[i];
			point.crowd.update({
				name: user.name,
				first_name: user.first_name,
				pic_square: user.pic_square
			}, {uid: user.uid});
		}

		//CALLBACK
		tryCallback(fnCallback);
		
	}};
	
	//ADD ANY UNKNOWN USERS TO THE ARRAY OF fbids
	point.crowd.forEach(function(partial_user, i){
		if(!isUsable(partial_user.name)){
			getto.fbids.push(partial_user.uid);
		}
	});
	
	//CALL FB OR CALLBACK IMMEDIATELY
	if(getto.fbids.length > 0){
		window.fbtimer = new Date();
		_fb.batchQuery([getto]);
	}
	else{
		tryCallback(fnCallback);
	}
	
};

//--------------------------------------------------------
_fb["batchQuery"] = function(arrGettos){

	//EACH "getto" OBJECT CONTAINS A LIST OF FBIDs TO FETCH, PLUS A CALLBACK TO CALL ONCE THE QUERY IS RETURNED
	//e.g.:
	//getto.fbids = [];
	//getto.callback = function(){}
	//[getto.limit]

	//MAKE FB SEQUENCER OBJECTS	
	//var batch = new FB.BatchSequencer();
	var queries = [];
	var errors = [];

	//MAKE A QUERY FOR getto
	$.each(arrGettos, function(i, getto){

		test.require(getto.fbids, "each getto must contain fbids (4268616)");
		test.require(getto.callback, "each getto must contain a callback (5213786)");
		if(test.ok()){
			
			var limit = isUsable(getto.limit) ? " LIMIT " + getto.limit : "";
			var query = FB.Data.query("SELECT uid, name, first_name, pic_square FROM user WHERE uid in (" + getto.fbids.join(",") + ")" + limit);
			query.index = i; 
			queries.push(query);

		}
		
	});

	//EXECUTE BATCH
	FB.Data.waitOn(queries, function(results){
	
		//FOR EACH QUERY RETURNED,
		$.each(results, function(i, result){

			//IF THERE ARE ROWS,
			if(isUsable(result) && result.length > 0){
				
				//CLEAN THE ROWS
				arrGettos[i].rows = _fb.cleanRows(result);
				
				//CALL THE CALLBACK
				arrGettos[i].callback();
				
			}
			
		});				
		
	});
	
};

//--------------------------------------------------------
_fb["mergeRows"] = function(crowd, rows){
	
	//console.time('_fb.mergeRows'); 
	
	//MERGE PROPERTIES FROM FB INTO JSON FROM SERVER
	$.each(rows, function(i, user){
		user.uid = user.uid + "";
		crowd.update(user, {uid: user.uid});
	});

	//REMOVE ANY INVALID ENTRIES
	crowd.remove({name: {isUndefined: true}});
	
	//console.timeEnd('_fb.mergeRows'); 

};

//--------------------------------------------------------
_fb["cleanRows"] = function(rows){

	var goodRows = [];
	$.each(rows, function(i, row){
		var bolGood = true;
		
		if(isUsable(row.name)){
			if(row.name != "null"){row.name = row.name.replace(/'/g, "");}
			else{bolGood = false;}
		}
		if(bolGood && isUsable(row.first_name)){
			if(row.first_name != "null"){row.first_name = row.first_name.replace(/'/g, ""); row.first_name = row.first_name.split(" ")[0];}
			else{bolGood = false;}
		}
		
		//IF THIS ROW IS VALID,
		if(bolGood){goodRows.push(row);}
	});
					
	//RETURN
	return goodRows;
	
};

//--------------------------------------------------------
//--------------------------------------------------------
//--------------------------------------------------------

_fb["init"] = function(){
	
	//ONLY CALL FB.init IF AT LEAST ONE HANDLER ACTION WAS SPECIFIED
	//log("_fb.init running (4633628)");
	FB.init({ appId: _fb.appID,
							status: true,
							cookie: true,
							status: true,
							xfbml:true});
		
	FB.Connect = {};
	FB.Connect.requireSession = function(cb_a, cb_b) {
		FB.login(function(response) {
							if(response.status == 'connected') {
								_fb.onConnected();	
							}
						}, {'perms':
							 'offline_access, publish_stream, rsvp_event, create_event, email, user_birthday, friends_birthday, user_events, ' +
							 'friends_events, user_groups, friends_groups, user_likes, friends_likes, friends_location, read_friendlists, friends_hometown, user_checkins, friends_checkins'});
	}

	FB.Connect.logoutAndRedirect = function(redirectURL) {
		try {
			FB.logout(function(response) {
				// EJ: Use timer to make sure there are enough time for FB's javascript SDK to log user out.
				// Otherwise user will log into system again
					window.setTimeout(function() {
						_fb.onConnected = false;
						window.location = redirectURL;
					}, 2000);
				});
		} catch(err) {
		
		} finally {
			// EJ: Use timer to make sure there are enough time for FB's javascript SDK to log user out.
			// Otherwise user will log into system again
			window.setTimeout(function() {
				_fb.onConnected = false;
				window.location = redirectURL;
			}, 2000);
		}
	}
	
	// Check loggin status
	FB.getLoginStatus(function(response) {
		if(response.session) {
			_fb.onConnected();
		}
		else{
			_fb.onNotConnected();
		}
	}, false);
	
	//log("_fb.init done running (4633629)");
};

//--------------------------------------------------------
_fb["connect"] = function(hl, bolLoadJSLibrary){

	_fb.overrideConnectionActions = false;
	$(hl).blur();

	//LOAD JS LIBRARY? (SO FAR, ONLY USED ON THE "Why you'll love The Hotlist" PAGE)
	if(isUsable(bolLoadJSLibrary) && bolLoadJSLibrary){

		bind("fb.onNotConnected", function(){
			_fb.connect(hl);
		});
		
		_fb.connectedAction = 1;
		_fb.init();
		
	}
	else{
		
		//IF WE'RE ON THE HOMEPAGE, CLICK THE BIG BUTTON
		var loginButton = $(".login_button");
		if(loginButton.length > 0 && !$(hl).hasClass("login_button")){
			loginButton.click();
		}
		else{
			
			hl = $(hl).find(".login").addClass("on");
			
			_fb.connectedAction = 0;

			FB.getLoginStatus(function(response) {
				if(response.session) {
					_fb.onConnected();
				}	else {
					//_fb.onNotConnected();
					FB.login(function(response) {
						if(response.status == 'connected') {
							_fb.onConnected();	
						}	else {
							hl.removeClass("on");								
						}
					}, {'perms': 'offline_access, publish_stream, rsvp_event, create_event, email, user_birthday, friends_birthday, user_events, ' +
							 'friends_events, user_groups, friends_groups, user_likes, friends_likes, friends_location, read_friendlists, friends_hometown'});
				}
			}, false);
			
		}
		
	}
	
};

//--------------------------------------------------------
_fb["onConnected"] = function(){

	//log("_fb.onConnected (2034200)");
	
	if(!_fb.overrideConnectionActions){
		
		_fb.connected = true;
		trigger("fb.onConnected");
	
		if(isUsable(_fb.connectedAction)) {
			
			switch(_fb.connectedAction){
	
				default:
				
					//ASSUMES THAT A DELAY IN MILLISECONDS WAS PASSED IN _fb.connectedAction
			        window.setTimeout(function() {
			          window.location = _url.postauth;
			        }, _fb.connectedAction);
	
					break;
				
			}
	
		}

	}

};

//--------------------------------------------------------
_fb["onNotConnected"] = function(){

	//log("_fb.onNotConnected (9981436)");

	if (!_fb.overrideConnectionActions) {
	
		trigger("fb.onNotConnected");

		if (isUsable(_fb.disconnectedAction)) {
			switch (_fb.disconnectedAction) {
			
				default:
					
					FB.Connect.logoutAndRedirect('/logout');

					/*
					//ASSUMES THAT A DELAY IN MILLISECONDS WAS PASSED IN _fb.disconnectedAction
					$.get(_url.logout, {}, function(){
						
						//GO TO ROOT
						window.setTimeout(function(){
							window.location = _url.root;
						}, _fb.disconnectedAction);
						
					}, 'html');
					*/
							
					break;
					
			}
		}
		
	}

};