function NavMenuDisplay(){}function setSearchBarValue(n){var t=document.getElementById("appendedPrependedInputSearch");t.value=n}function PopulatePaging(n,t){for(var e=document.getElementById("pging-content"),u="<div class='container-pging'>",o="<div class='container-pging container-pging-active'>",f="<\/div>",s="<button type='button' class='btns btn-sml btn-one'>",h="<\/button>",i="",r=1;r<=n;)i+=r==1?o:u,i+=r,i+=f,r++;i+=u,i+="...",i+=f,i+=u,i+=t,i+=f,i+=s,i+="Next >",i+=h,e.innerHTML=i}function showToolTip(){var n=event.target.id+"_tooltip";document.getElementById(n).style.display="block"}function hideToolTip(){var n=event.target.id+"_tooltip";document.getElementById(n).style.display="none"}function drawShape(){var t=document.getElementById("myCanvas"),n=t.getContext("2d");n.beginPath(),n.moveTo(75,0),n.lineTo(100,50),n.lineTo(50,50),n.closePath(),n.fill()}function ToggleDisplay(n,t){var i=n+"_show",r=n+"_hide";t=="show"?(document.getElementById(i).style.display="none",document.getElementById(r).style.display="block"):(document.getElementById(i).style.display="block",document.getElementById(r).style.display="none")}function expandContent(){var t=event.target,i=t.parentNode,n=i.getElementsByTagName("ul"),r=document.getElementById(n[0].id);document.getElementById(n[0].id).style.display=r.style.display=="none"?"block":"none"}function ShowHide(n){document.getElementById(n).style.display=document.getElementById(n).style.display==none?block:none}function GetSearchDropDownData(n,t){var u,i,r;return}function GetTopicsDropDownData(n,t){var u,i,r;$.ajaxSetup({cache:!1}),n.length>2&&(i="/api/fwd",r=$("#contentApi").val().split("http://")[1].split("/")[0],$.ajax({url:i+"/topics",data:{_search:n},type:"GET",headers:{Accept:"application/json","ds-send-to-api":r+", api"},cache:!1}).done(function(n){t(n)}).fail(function(n,t,i){typeof console!="undefined"&&console.log({statusCode:n.status,error:i,status:t,response:n.responseText})}))}function LinkedInShare(n){var t=n.split("/"),i=t[4],r=t[3];ds.track.adapter.socialShare(n,"LinkedIn share","LinkedIn","LinkedIn Share",i,r),console.log("GA: LinkedIn-Share")}function trackTwitter(n){var t;if(n){n.target&&n.target.nodeName=="IFRAME"&&(t=extractParamFromUri(n.target.src,"url"));var i=t.split("/"),r=i[4],u=i[3];ds.track.adapter.socialShare(t,"Tweet","Twitter","Twitter Tweet",r,u)}}function extractParamFromUri(n,t){if(n){var r=new RegExp("[\\?&#]"+t+"=([^&#]*)"),i=r.exec(n);if(i!=null)return unescape(i[1])}}function trackEmail(){var n=window.location.pathname.split("/"),t=n[2],i=n[1];ds.track.adapter.socialShare(window.location,"Email Share","Email","Email Share",t,i)}function registerTW(){twttr.ready(function(){twttr.events.bind("tweet",trackTwitter)})}var JSON,fordebuggingbreak,myOfficePreviewCookie,myOfficePreview,modal,loginModal,docCookies,fbHandleLogin;(function(n,t){function dt(n){var t=n.length,r=i.type(n);return i.isWindow(n)?!1:1===n.nodeType&&t?!0:"array"===r||"function"!==r&&(0===t||"number"==typeof t&&t>0&&t-1 in n)}function kf(n){var t=gt[n]={};return i.each(n.match(s)||[],function(n,i){t[i]=!0}),t}function ir(n,r,u,f){if(i.acceptData(n)){var s,h,c=i.expando,a="string"==typeof r,l=n.nodeType,o=l?i.cache:n,e=l?n[c]:n[c]&&c;if(e&&o[e]&&(f||o[e].data)||!a||u!==t)return e||(l?n[c]=e=b.pop()||i.guid++:e=c),o[e]||(o[e]={},l||(o[e].toJSON=i.noop)),("object"==typeof r||"function"==typeof r)&&(f?o[e]=i.extend(o[e],r):o[e].data=i.extend(o[e].data,r)),s=o[e],f||(s.data||(s.data={}),s=s.data),u!==t&&(s[i.camelCase(r)]=u),a?(h=s[r],null==h&&(h=s[i.camelCase(r)])):h=s,h}}function rr(n,t,r){if(i.acceptData(n)){var o,h,e,s=n.nodeType,u=s?i.cache:n,f=s?n[i.expando]:i.expando;if(u[f]){if(t&&(e=r?u[f]:u[f].data)){for(i.isArray(t)?t=t.concat(i.map(t,i.camelCase)):(t in e)?t=[t]:(t=i.camelCase(t),t=t in e?[t]:t.split(" ")),o=0,h=t.length;h>o;o++)delete e[t[o]];if(!(r?ni:i.isEmptyObject)(e))return}(r||(delete u[f].data,ni(u[f])))&&(s?i.cleanData([n],!0):i.support.deleteExpando||u!=u.window?delete u[f]:u[f]=null)}}}function ur(n,r,u){if(u===t&&1===n.nodeType){var f="data-"+r.replace(tr,"-$1").toLowerCase();if(u=n.getAttribute(f),"string"==typeof u){try{u="true"===u?!0:"false"===u?!1:"null"===u?null:+u+""===u?+u:nr.test(u)?i.parseJSON(u):u}catch(e){}i.data(n,r,u)}else u=t}return u}function ni(n){var t;for(t in n)if(("data"!==t||!i.isEmptyObject(n[t]))&&"toJSON"!==t)return!1;return!0}function ht(){return!0}function d(){return!1}function cr(n,t){do n=n[t];while(n&&1!==n.nodeType);return n}function lr(n,t,r){if(t=t||0,i.isFunction(t))return i.grep(n,function(n,i){var u=!!t.call(n,i,n);return u===r});if(t.nodeType)return i.grep(n,function(n){return n===t===r});if("string"==typeof t){var u=i.grep(n,function(n){return 1===n.nodeType});if(fe.test(t))return i.filter(t,u,!r);t=i.filter(t,u)}return i.grep(n,function(n){return i.inArray(n,t)>=0===r})}function ar(n){var i=vr.split("|"),t=n.createDocumentFragment();if(t.createElement)while(i.length)t.createElement(i.pop());return t}function ye(n,t){return n.getElementsByTagName(t)[0]||n.appendChild(n.ownerDocument.createElement(t))}function dr(n){var t=n.getAttributeNode("type");return n.type=(t&&t.specified)+"/"+n.type,n}function gr(n){var t=le.exec(n.type);return t?n.type=t[1]:n.removeAttribute("type"),n}function si(n,t){for(var u,r=0;null!=(u=n[r]);r++)i._data(u,"globalEval",!t||i._data(t[r],"globalEval"))}function nu(n,t){if(1===t.nodeType&&i.hasData(n)){var u,f,o,s=i._data(n),r=i._data(t,s),e=s.events;if(e){delete r.handle,r.events={};for(u in e)for(f=0,o=e[u].length;o>f;f++)i.event.add(t,u,e[u][f])}r.data&&(r.data=i.extend({},r.data))}}function pe(n,t){var r,f,u;if(1===t.nodeType){if(r=t.nodeName.toLowerCase(),!i.support.noCloneEvent&&t[i.expando]){u=i._data(t);for(f in u.events)i.removeEvent(t,f,u.handle);t.removeAttribute(i.expando)}"script"===r&&t.text!==n.text?(dr(t).text=n.text,gr(t)):"object"===r?(t.parentNode&&(t.outerHTML=n.outerHTML),i.support.html5Clone&&n.innerHTML&&!i.trim(t.innerHTML)&&(t.innerHTML=n.innerHTML)):"input"===r&&ei.test(n.type)?(t.defaultChecked=t.checked=n.checked,t.value!==n.value&&(t.value=n.value)):"option"===r?t.defaultSelected=t.selected=n.defaultSelected:("input"===r||"textarea"===r)&&(t.defaultValue=n.defaultValue)}}function u(n,r){var s,e,h=0,f=typeof n.getElementsByTagName!==o?n.getElementsByTagName(r||"*"):typeof n.querySelectorAll!==o?n.querySelectorAll(r||"*"):t;if(!f)for(f=[],s=n.childNodes||n;null!=(e=s[h]);h++)!r||i.nodeName(e,r)?f.push(e):i.merge(f,u(e,r));return r===t||r&&i.nodeName(n,r)?i.merge([n],f):f}function we(n){ei.test(n.type)&&(n.defaultChecked=n.checked)}function fu(n,t){if(t in n)return t;for(var r=t.charAt(0).toUpperCase()+t.slice(1),u=t,i=uu.length;i--;)if(t=uu[i]+r,t in n)return t;return u}function ut(n,t){return n=t||n,"none"===i.css(n,"display")||!i.contains(n.ownerDocument,n)}function eu(n,t){for(var f,r,o,e=[],u=0,s=n.length;s>u;u++)r=n[u],r.style&&(e[u]=i._data(r,"olddisplay"),f=r.style.display,t?(e[u]||"none"!==f||(r.style.display=""),""===r.style.display&&ut(r)&&(e[u]=i._data(r,"olddisplay",cu(r.nodeName)))):e[u]||(o=ut(r),(f&&"none"!==f||!o)&&i._data(r,"olddisplay",o?f:i.css(r,"display"))));for(u=0;s>u;u++)r=n[u],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?e[u]||"":"none"));return n}function ou(n,t,i){var r=ge.exec(t);return r?Math.max(0,r[1]-(i||0))+(r[2]||"px"):t}function su(n,t,r,u,f){for(var e=r===(u?"border":"content")?4:"width"===t?1:0,o=0;4>e;e+=2)"margin"===r&&(o+=i.css(n,r+p[e],!0,f)),u?("content"===r&&(o-=i.css(n,"padding"+p[e],!0,f)),"margin"!==r&&(o-=i.css(n,"border"+p[e]+"Width",!0,f))):(o+=i.css(n,"padding"+p[e],!0,f),"padding"!==r&&(o+=i.css(n,"border"+p[e]+"Width",!0,f)));return o}function hu(n,t,r){var e=!0,u="width"===t?n.offsetWidth:n.offsetHeight,f=v(n),o=i.support.boxSizing&&"border-box"===i.css(n,"boxSizing",!1,f);if(0>=u||null==u){if(u=y(n,t,f),(0>u||null==u)&&(u=n.style[t]),ct.test(u))return u;e=o&&(i.support.boxSizingReliable||u===n.style[t]),u=parseFloat(u)||0}return u+su(n,t,r||(o?"border":"content"),e,f)+"px"}function cu(n){var u=r,t=iu[n];return t||(t=lu(n,u),"none"!==t&&t||(rt=(rt||i("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(u.documentElement),u=(rt[0].contentWindow||rt[0].contentDocument).document,u.write("<!doctype html><html><body>"),u.close(),t=lu(n,u),rt.detach()),iu[n]=t),t}function lu(n,t){var r=i(t.createElement(n)).appendTo(t.body),u=i.css(r[0],"display");return r.remove(),u}function ci(n,t,r,u){var f;if(i.isArray(t))i.each(t,function(t,i){r||ro.test(n)?u(n,i):ci(n+"["+("object"==typeof i?t:"")+"]",i,r,u)});else if(r||"object"!==i.type(t))u(n,t);else for(f in t)ci(n+"["+f+"]",t[f],r,u)}function ku(n){return function(t,r){"string"!=typeof t&&(r=t,t="*");var u,f=0,e=t.toLowerCase().match(s)||[];if(i.isFunction(r))while(u=e[f++])"+"===u[0]?(u=u.slice(1)||"*",(n[u]=n[u]||[]).unshift(r)):(n[u]=n[u]||[]).push(r)}}function du(n,r,u,f){function o(h){var c;return e[h]=!0,i.each(n[h]||[],function(n,i){var h=i(r,u,f);return"string"!=typeof h||s||e[h]?s?!(c=h):t:(r.dataTypes.unshift(h),o(h),!1)}),c}var e={},s=n===vi;return o(r.dataTypes[0])||!e["*"]&&o("*")}function yi(n,r){var f,u,e=i.ajaxSettings.flatOptions||{};for(u in r)r[u]!==t&&((e[u]?n:f||(f={}))[u]=r[u]);return f&&i.extend(!0,n,f),n}function lo(n,i,r){var s,o,e,u,h=n.contents,f=n.dataTypes,c=n.responseFields;for(u in c)u in r&&(i[c[u]]=r[u]);while("*"===f[0])f.shift(),o===t&&(o=n.mimeType||i.getResponseHeader("Content-Type"));if(o)for(u in h)if(h[u]&&h[u].test(o)){f.unshift(u);break}if(f[0]in r)e=f[0];else{for(u in r){if(!f[0]||n.converters[u+" "+f[0]]){e=u;break}s||(s=u)}e=e||s}return e?(e!==f[0]&&f.unshift(e),r[e]):t}function ao(n,t){var o,r,i,e,u={},h=0,s=n.dataTypes.slice(),f=s[0];if(n.dataFilter&&(t=n.dataFilter(t,n.dataType)),s[1])for(i in n.converters)u[i.toLowerCase()]=n.converters[i];for(;r=s[++h];)if("*"!==r){if("*"!==f&&f!==r){if(i=u[f+" "+r]||u["* "+r],!i)for(o in u)if(e=o.split(" "),e[1]===r&&(i=u[f+" "+e[0]]||u["* "+e[0]])){i===!0?i=u[o]:u[o]!==!0&&(r=e[0],s.splice(h--,0,r));break}if(i!==!0)if(i&&n.throws)t=i(t);else try{t=i(t)}catch(c){return{state:"parsererror",error:i?c:"No conversion from "+f+" to "+r}}}f=r}return{state:"success",data:t}}function nf(){try{return new n.XMLHttpRequest}catch(t){}}function vo(){try{return new n.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}function tf(){return setTimeout(function(){tt=t}),tt=i.now()}function bo(n,t){i.each(t,function(t,i){for(var u=(ft[t]||[]).concat(ft["*"]),r=0,f=u.length;f>r;r++)if(u[r].call(n,t,i))return})}function rf(n,t,r){var h,e,o=0,l=yt.length,f=i.Deferred().always(function(){delete c.elem}),c=function(){if(e)return!1;for(var s=tt||tf(),t=Math.max(0,u.startTime+u.duration-s),h=t/u.duration||0,i=1-h,r=0,o=u.tweens.length;o>r;r++)u.tweens[r].run(i);return f.notifyWith(n,[u,i,t]),1>i&&o?t:(f.resolveWith(n,[u]),!1)},u=f.promise({elem:n,props:i.extend({},t),opts:i.extend(!0,{specialEasing:{}},r),originalProperties:t,originalOptions:r,startTime:tt||tf(),duration:r.duration,tweens:[],createTween:function(t,r){var f=i.Tween(n,u.opts,t,r,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(f),f},stop:function(t){var i=0,r=t?u.tweens.length:0;if(e)return this;for(e=!0;r>i;i++)u.tweens[i].run(1);return t?f.resolveWith(n,[u,t]):f.rejectWith(n,[u,t]),this}}),s=u.props;for(ko(s,u.opts.specialEasing);l>o;o++)if(h=yt[o].call(u,n,s,u.opts))return h;return bo(u,s),i.isFunction(u.opts.start)&&u.opts.start.call(n,u),i.fx.timer(i.extend(c,{elem:n,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}function ko(n,t){var u,f,r,e,o;for(r in n)if(f=i.camelCase(r),e=t[f],u=n[r],i.isArray(u)&&(e=u[1],u=n[r]=u[0]),r!==f&&(n[f]=u,delete n[r]),o=i.cssHooks[f],o&&"expand"in o){u=o.expand(u),delete n[f];for(r in u)r in n||(n[r]=u[r],t[r]=e)}else t[f]=e}function go(n,t,r){var u,o,w,a,s,v,l,f,b,h=this,e=n.style,y={},p=[],c=n.nodeType&&ut(n);r.queue||(f=i._queueHooks(n,"fx"),null==f.unqueued&&(f.unqueued=0,b=f.empty.fire,f.empty.fire=function(){f.unqueued||b()}),f.unqueued++,h.always(function(){h.always(function(){f.unqueued--,i.queue(n,"fx").length||f.empty.fire()})})),1===n.nodeType&&("height"in t||"width"in t)&&(r.overflow=[e.overflow,e.overflowX,e.overflowY],"inline"===i.css(n,"display")&&"none"===i.css(n,"float")&&(i.support.inlineBlockNeedsLayout&&"inline"!==cu(n.nodeName)?e.zoom=1:e.display="inline-block")),r.overflow&&(e.overflow="hidden",i.support.shrinkWrapBlocks||h.always(function(){e.overflow=r.overflow[0],e.overflowX=r.overflow[1],e.overflowY=r.overflow[2]}));for(o in t)if(a=t[o],yo.exec(a)){if(delete t[o],v=v||"toggle"===a,a===(c?"hide":"show"))continue;p.push(o)}if(w=p.length)for(s=i._data(n,"fxshow")||i._data(n,"fxshow",{}),("hidden"in s)&&(c=s.hidden),v&&(s.hidden=!c),c?i(n).show():h.done(function(){i(n).hide()}),h.done(function(){var t;i._removeData(n,"fxshow");for(t in y)i.style(n,t,y[t])}),o=0;w>o;o++)u=p[o],l=h.createTween(u,c?s[u]:0),y[u]=s[u]||i.style(n,u),u in s||(s[u]=l.start,c&&(l.end=l.start,l.start="width"===u||"height"===u?1:0))}function f(n,t,i,r,u){return new f.prototype.init(n,t,i,r,u)}function pt(n,t){var r,i={height:n},u=0;for(t=t?1:0;4>u;u+=2-t)r=p[u],i["margin"+r]=i["padding"+r]=n;return t&&(i.opacity=i.width=n),i}function uf(n){return i.isWindow(n)?n:9===n.nodeType?n.defaultView||n.parentWindow:!1}var et,wi,o=typeof t,r=n.document,ff=n.location,ef=n.jQuery,of=n.$,ot={},b=[],wt="1.9.1",bi=b.concat,bt=b.push,l=b.slice,ki=b.indexOf,sf=ot.toString,it=ot.hasOwnProperty,kt=wt.trim,i=function(n,t){return new i.fn.init(n,t,wi)},st=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,s=/\S+/g,hf=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,cf=/^(?:(<[\w\W]+>)[^>]*|#([\w-]*))$/,di=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,lf=/^[\],:{}\s]*$/,af=/(?:^|:|,)(?:\s*\[)+/g,vf=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,yf=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,pf=/^-ms-/,wf=/-([\da-z])/gi,bf=function(n,t){return t.toUpperCase()},h=function(n){(r.addEventListener||"load"===n.type||"complete"===r.readyState)&&(gi(),i.ready())},gi=function(){r.addEventListener?(r.removeEventListener("DOMContentLoaded",h,!1),n.removeEventListener("load",h,!1)):(r.detachEvent("onreadystatechange",h),n.detachEvent("onload",h))},gt,nr,tr,pi,lt,g,nt,gu,at;i.fn=i.prototype={jquery:wt,constructor:i,init:function(n,u,f){var e,o;if(!n)return this;if("string"==typeof n){if(e="<"===n.charAt(0)&&">"===n.charAt(n.length-1)&&n.length>=3?[null,n,null]:cf.exec(n),!e||!e[1]&&u)return!u||u.jquery?(u||f).find(n):this.constructor(u).find(n);if(e[1]){if(u=u instanceof i?u[0]:u,i.merge(this,i.parseHTML(e[1],u&&u.nodeType?u.ownerDocument||u:r,!0)),di.test(e[1])&&i.isPlainObject(u))for(e in u)i.isFunction(this[e])?this[e](u[e]):this.attr(e,u[e]);return this}if(o=r.getElementById(e[2]),o&&o.parentNode){if(o.id!==e[2])return f.find(n);this.length=1,this[0]=o}return this.context=r,this.selector=n,this}return n.nodeType?(this.context=this[0]=n,this.length=1,this):i.isFunction(n)?f.ready(n):(n.selector!==t&&(this.selector=n.selector,this.context=n.context),i.makeArray(n,this))},selector:"",length:0,size:function(){return this.length},toArray:function(){return l.call(this)},get:function(n){return null==n?this.toArray():0>n?this[this.length+n]:this[n]},pushStack:function(n){var t=i.merge(this.constructor(),n);return t.prevObject=this,t.context=this.context,t},each:function(n,t){return i.each(this,n,t)},ready:function(n){return i.ready.promise().done(n),this},slice:function(){return this.pushStack(l.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(n){var i=this.length,t=+n+(0>n?i:0);return this.pushStack(t>=0&&i>t?[this[t]]:[])},map:function(n){return this.pushStack(i.map(this,function(t,i){return n.call(t,i,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:bt,sort:[].sort,splice:[].splice},i.fn.init.prototype=i.fn,i.extend=i.fn.extend=function(){var u,o,r,e,s,h,n=arguments[0]||{},f=1,l=arguments.length,c=!1;for("boolean"==typeof n&&(c=n,n=arguments[1]||{},f=2),"object"==typeof n||i.isFunction(n)||(n={}),l===f&&(n=this,--f);l>f;f++)if(null!=(s=arguments[f]))for(e in s)u=n[e],r=s[e],n!==r&&(c&&r&&(i.isPlainObject(r)||(o=i.isArray(r)))?(o?(o=!1,h=u&&i.isArray(u)?u:[]):h=u&&i.isPlainObject(u)?u:{},n[e]=i.extend(c,h,r)):r!==t&&(n[e]=r));return n},i.extend({noConflict:function(t){return n.$===i&&(n.$=of),t&&n.jQuery===i&&(n.jQuery=ef),i},isReady:!1,readyWait:1,holdReady:function(n){n?i.readyWait++:i.ready(!0)},ready:function(n){if(n===!0?!--i.readyWait:!i.isReady){if(!r.body)return setTimeout(i.ready);i.isReady=!0,n!==!0&&--i.readyWait>0||(et.resolveWith(r,[i]),i.fn.trigger&&i(r).trigger("ready").off("ready"))}},isFunction:function(n){return"function"===i.type(n)},isArray:Array.isArray||function(n){return"array"===i.type(n)},isWindow:function(n){return null!=n&&n==n.window},isNumeric:function(n){return!isNaN(parseFloat(n))&&isFinite(n)},type:function(n){return null==n?n+"":"object"==typeof n||"function"==typeof n?ot[sf.call(n)]||"object":typeof n},isPlainObject:function(n){if(!n||"object"!==i.type(n)||n.nodeType||i.isWindow(n))return!1;try{if(n.constructor&&!it.call(n,"constructor")&&!it.call(n.constructor.prototype,"isPrototypeOf"))return!1}catch(u){return!1}var r;for(r in n);return r===t||it.call(n,r)},isEmptyObject:function(n){var t;for(t in n)return!1;return!0},error:function(n){throw Error(n);},parseHTML:function(n,t,u){if(!n||"string"!=typeof n)return null;"boolean"==typeof t&&(u=t,t=!1),t=t||r;var f=di.exec(n),e=!u&&[];return f?[t.createElement(f[1])]:(f=i.buildFragment([n],t,e),e&&i(e).remove(),i.merge([],f.childNodes))},parseJSON:function(r){return n.JSON&&n.JSON.parse?n.JSON.parse(r):null===r?r:"string"==typeof r&&(r=i.trim(r),r&&lf.test(r.replace(vf,"@").replace(yf,"]").replace(af,"")))?Function("return "+r)():(i.error("Invalid JSON: "+r),t)},parseXML:function(r){var u,f;if(!r||"string"!=typeof r)return null;try{n.DOMParser?(f=new DOMParser,u=f.parseFromString(r,"text/xml")):(u=new ActiveXObject("Microsoft.XMLDOM"),u.async="false",u.loadXML(r))}catch(e){u=t}return u&&u.documentElement&&!u.getElementsByTagName("parsererror").length||i.error("Invalid XML: "+r),u},noop:function(){},globalEval:function(t){t&&i.trim(t)&&(n.execScript||function(t){n.eval.call(n,t)})(t)},camelCase:function(n){return n.replace(pf,"ms-").replace(wf,bf)},nodeName:function(n,t){return n.nodeName&&n.nodeName.toLowerCase()===t.toLowerCase()},each:function(n,t,i){var u,r=0,f=n.length,e=dt(n);if(i){if(e){for(;f>r;r++)if(u=t.apply(n[r],i),u===!1)break}else for(r in n)if(u=t.apply(n[r],i),u===!1)break}else if(e){for(;f>r;r++)if(u=t.call(n[r],r,n[r]),u===!1)break}else for(r in n)if(u=t.call(n[r],r,n[r]),u===!1)break;return n},trim:kt&&!kt.call("﻿ ")?function(n){return null==n?"":kt.call(n)}:function(n){return null==n?"":(n+"").replace(hf,"")},makeArray:function(n,t){var r=t||[];return null!=n&&(dt(Object(n))?i.merge(r,"string"==typeof n?[n]:n):bt.call(r,n)),r},inArray:function(n,t,i){var r;if(t){if(ki)return ki.call(t,n,i);for(r=t.length,i=i?0>i?Math.max(0,r+i):i:0;r>i;i++)if(i in t&&t[i]===n)return i}return-1},merge:function(n,i){var f=i.length,u=n.length,r=0;if("number"==typeof f)for(;f>r;r++)n[u++]=i[r];else while(i[r]!==t)n[u++]=i[r++];return n.length=u,n},grep:function(n,t,i){var u,f=[],r=0,e=n.length;for(i=!!i;e>r;r++)u=!!t(n[r],r),i!==u&&f.push(n[r]);return f},map:function(n,t,i){var u,r=0,e=n.length,o=dt(n),f=[];if(o)for(;e>r;r++)u=t(n[r],r,i),null!=u&&(f[f.length]=u);else for(r in n)u=t(n[r],r,i),null!=u&&(f[f.length]=u);return bi.apply([],f)},guid:1,proxy:function(n,r){var f,u,e;return"string"==typeof r&&(e=n[r],r=n,n=e),i.isFunction(n)?(f=l.call(arguments,2),u=function(){return n.apply(r||this,f.concat(l.call(arguments)))},u.guid=n.guid=n.guid||i.guid++,u):t},access:function(n,r,u,f,e,o,s){var h=0,l=n.length,c=null==u;if("object"===i.type(u)){e=!0;for(h in u)i.access(n,r,h,u[h],!0,o,s)}else if(f!==t&&(e=!0,i.isFunction(f)||(s=!0),c&&(s?(r.call(n,f),r=null):(c=r,r=function(n,t,r){return c.call(i(n),r)})),r))for(;l>h;h++)r(n[h],u,s?f:f.call(n[h],h,r(n[h],u)));return e?n:c?r.call(n):l?r(n[0],u):o},now:function(){return+new Date}}),i.ready.promise=function(t){if(!et)if(et=i.Deferred(),"complete"===r.readyState)setTimeout(i.ready);else if(r.addEventListener)r.addEventListener("DOMContentLoaded",h,!1),n.addEventListener("load",h,!1);else{r.attachEvent("onreadystatechange",h),n.attachEvent("onload",h);var u=!1;try{u=null==n.frameElement&&r.documentElement}catch(e){}u&&u.doScroll&&function f(){if(!i.isReady){try{u.doScroll("left")}catch(n){return setTimeout(f,50)}gi(),i.ready()}}()}return et.promise(t)},i.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(n,t){ot["[object "+t+"]"]=t.toLowerCase()}),wi=i(r),gt={},i.Callbacks=function(n){n="string"==typeof n?gt[n]||kf(n):i.extend({},n);var o,f,c,s,e,l,r=[],u=!n.once&&[],a=function(t){for(f=n.memory&&t,c=!0,e=l||0,l=0,s=r.length,o=!0;r&&s>e;e++)if(r[e].apply(t[0],t[1])===!1&&n.stopOnFalse){f=!1;break}o=!1,r&&(u?u.length&&a(u.shift()):f?r=[]:h.disable())},h={add:function(){if(r){var t=r.length;(function u(t){i.each(t,function(t,f){var e=i.type(f);"function"===e?n.unique&&h.has(f)||r.push(f):f&&f.length&&"string"!==e&&u(f)})})(arguments),o?s=r.length:f&&(l=t,a(f))}return this},remove:function(){return r&&i.each(arguments,function(n,t){for(var u;(u=i.inArray(t,r,u))>-1;)r.splice(u,1),o&&(s>=u&&s--,e>=u&&e--)}),this},has:function(n){return n?i.inArray(n,r)>-1:!(!r||!r.length)},empty:function(){return r=[],this},disable:function(){return r=u=f=t,this},disabled:function(){return!r},lock:function(){return u=t,f||h.disable(),this},locked:function(){return!u},fireWith:function(n,t){return t=t||[],t=[n,t.slice?t.slice():t],!r||c&&!u||(o?u.push(t):a(t)),this},fire:function(){return h.fireWith(this,arguments),this},fired:function(){return!!c}};return h},i.extend({Deferred:function(n){var u=[["resolve","done",i.Callbacks("once memory"),"resolved"],["reject","fail",i.Callbacks("once memory"),"rejected"],["notify","progress",i.Callbacks("memory")]],f="pending",r={state:function(){return f},always:function(){return t.done(arguments).fail(arguments),this},then:function(){var n=arguments;return i.Deferred(function(f){i.each(u,function(u,e){var s=e[0],o=i.isFunction(n[u])&&n[u];t[e[1]](function(){var n=o&&o.apply(this,arguments);n&&i.isFunction(n.promise)?n.promise().done(f.resolve).fail(f.reject).progress(f.notify):f[s+"With"](this===r?f.promise():this,o?[n]:arguments)})}),n=null}).promise()},promise:function(n){return null!=n?i.extend(n,r):r}},t={};return r.pipe=r.then,i.each(u,function(n,i){var e=i[2],o=i[3];r[i[1]]=e.add,o&&e.add(function(){f=o},u[1^n][2].disable,u[2][2].lock),t[i[0]]=function(){return t[i[0]+"With"](this===t?r:this,arguments),this},t[i[0]+"With"]=e.fireWith}),r.promise(t),n&&n.call(t,t),t},when:function(n){var t=0,u=l.call(arguments),r=u.length,e=1!==r||n&&i.isFunction(n.promise)?r:0,f=1===e?n:i.Deferred(),h=function(n,t,i){return function(r){t[n]=this,i[n]=arguments.length>1?l.call(arguments):r,i===o?f.notifyWith(t,i):--e||f.resolveWith(t,i)}},o,c,s;if(r>1)for(o=Array(r),c=Array(r),s=Array(r);r>t;t++)u[t]&&i.isFunction(u[t].promise)?u[t].promise().done(h(t,s,u)).fail(f.reject).progress(h(t,c,o)):--e;return e||f.resolveWith(s,u),f.promise()}}),i.support=function(){var u,s,e,f,h,c,l,a,y,v,t=r.createElement("div");if(t.setAttribute("className","t"),t.innerHTML="  <link/><table><\/table><a href='/a'>a<\/a><input type='checkbox'/>",s=t.getElementsByTagName("*"),e=t.getElementsByTagName("a")[0],!s||!e||!s.length)return{};h=r.createElement("select"),l=h.appendChild(r.createElement("option")),f=t.getElementsByTagName("input")[0],e.style.cssText="top:1px;float:left;opacity:.5",u={getSetAttribute:"t"!==t.className,leadingWhitespace:3===t.firstChild.nodeType,tbody:!t.getElementsByTagName("tbody").length,htmlSerialize:!!t.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:"/a"===e.getAttribute("href"),opacity:/^0.5/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:!!f.value,optSelected:l.selected,enctype:!!r.createElement("form").enctype,html5Clone:"<:nav><\/:nav>"!==r.createElement("nav").cloneNode(!0).outerHTML,boxModel:"CSS1Compat"===r.compatMode,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},f.checked=!0,u.noCloneChecked=f.cloneNode(!0).checked,h.disabled=!0,u.optDisabled=!l.disabled;try{delete t.test}catch(p){u.deleteExpando=!1}f=r.createElement("input"),f.setAttribute("value",""),u.input=""===f.getAttribute("value"),f.value="t",f.setAttribute("type","radio"),u.radioValue="t"===f.value,f.setAttribute("checked","t"),f.setAttribute("name","t"),c=r.createDocumentFragment(),c.appendChild(f),u.appendChecked=f.checked,u.checkClone=c.cloneNode(!0).cloneNode(!0).lastChild.checked,t.attachEvent&&(t.attachEvent("onclick",function(){u.noCloneEvent=!1}),t.cloneNode(!0).click());for(v in{submit:!0,change:!0,focusin:!0})t.setAttribute(a="on"+v,"t"),u[v+"Bubbles"]=a in n||t.attributes[a].expando===!1;return t.style.backgroundClip="content-box",t.cloneNode(!0).style.backgroundClip="",u.clearCloneStyle="content-box"===t.style.backgroundClip,i(function(){var e,f,i,h="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",s=r.getElementsByTagName("body")[0];s&&(e=r.createElement("div"),e.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",s.appendChild(e).appendChild(t),t.innerHTML="<table><tr><td><\/td><td>t<\/td><\/tr><\/table>",i=t.getElementsByTagName("td"),i[0].style.cssText="padding:0;margin:0;border:0;display:none",y=0===i[0].offsetHeight,i[0].style.display="",i[1].style.display="none",u.reliableHiddenOffsets=y&&0===i[0].offsetHeight,t.innerHTML="",t.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",u.boxSizing=4===t.offsetWidth,u.doesNotIncludeMarginInBodyOffset=1!==s.offsetTop,n.getComputedStyle&&(u.pixelPosition="1%"!==(n.getComputedStyle(t,null)||{}).top,u.boxSizingReliable="4px"===(n.getComputedStyle(t,null)||{width:"4px"}).width,f=t.appendChild(r.createElement("div")),f.style.cssText=t.style.cssText=h,f.style.marginRight=f.style.width="0",t.style.width="1px",u.reliableMarginRight=!parseFloat((n.getComputedStyle(f,null)||{}).marginRight)),typeof t.style.zoom!==o&&(t.innerHTML="",t.style.cssText=h+"width:1px;padding:1px;display:inline;zoom:1",u.inlineBlockNeedsLayout=3===t.offsetWidth,t.style.display="block",t.innerHTML="<div><\/div>",t.firstChild.style.width="5px",u.shrinkWrapBlocks=3!==t.offsetWidth,u.inlineBlockNeedsLayout&&(s.style.zoom=1)),s.removeChild(e),e=t=i=f=null)}),s=h=c=l=e=f=null,u}(),nr=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,tr=/([A-Z])/g,i.extend({cache:{},expando:"jQuery"+(wt+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(n){return n=n.nodeType?i.cache[n[i.expando]]:n[i.expando],!!n&&!ni(n)},data:function(n,t,i){return ir(n,t,i)},removeData:function(n,t){return rr(n,t)},_data:function(n,t,i){return ir(n,t,i,!0)},_removeData:function(n,t){return rr(n,t,!0)},acceptData:function(n){if(n.nodeType&&1!==n.nodeType&&9!==n.nodeType)return!1;var t=n.nodeName&&i.noData[n.nodeName.toLowerCase()];return!t||t!==!0&&n.getAttribute("classid")===t}}),i.fn.extend({data:function(n,r){var e,f,u=this[0],o=0,s=null;if(n===t){if(this.length&&(s=i.data(u),1===u.nodeType&&!i._data(u,"parsedAttrs"))){for(e=u.attributes;e.length>o;o++)f=e[o].name,f.indexOf("data-")||(f=i.camelCase(f.slice(5)),ur(u,f,s[f]));i._data(u,"parsedAttrs",!0)}return s}return"object"==typeof n?this.each(function(){i.data(this,n)}):i.access(this,function(r){return r===t?u?ur(u,n,i.data(u,n)):null:(this.each(function(){i.data(this,n,r)}),t)},null,r,arguments.length>1,null,!0)},removeData:function(n){return this.each(function(){i.removeData(this,n)})}}),i.extend({queue:function(n,r,u){var f;return n?(r=(r||"fx")+"queue",f=i._data(n,r),u&&(!f||i.isArray(u)?f=i._data(n,r,i.makeArray(u)):f.push(u)),f||[]):t},dequeue:function(n,t){t=t||"fx";var f=i.queue(n,t),e=f.length,r=f.shift(),u=i._queueHooks(n,t),o=function(){i.dequeue(n,t)};"inprogress"===r&&(r=f.shift(),e--),u.cur=r,r&&("fx"===t&&f.unshift("inprogress"),delete u.stop,r.call(n,o,u)),!e&&u&&u.empty.fire()},_queueHooks:function(n,t){var r=t+"queueHooks";return i._data(n,r)||i._data(n,r,{empty:i.Callbacks("once memory").add(function(){i._removeData(n,t+"queue"),i._removeData(n,r)})})}}),i.fn.extend({queue:function(n,r){var u=2;return"string"!=typeof n&&(r=n,n="fx",u--),u>arguments.length?i.queue(this[0],n):r===t?this:this.each(function(){var t=i.queue(this,n,r);i._queueHooks(this,n),"fx"===n&&"inprogress"!==t[0]&&i.dequeue(this,n)})},dequeue:function(n){return this.each(function(){i.dequeue(this,n)})},delay:function(n,t){return n=i.fx?i.fx.speeds[n]||n:n,t=t||"fx",this.queue(t,function(t,i){var r=setTimeout(t,n);i.stop=function(){clearTimeout(r)}})},clearQueue:function(n){return this.queue(n||"fx",[])},promise:function(n,r){var u,e=1,o=i.Deferred(),f=this,s=this.length,h=function(){--e||o.resolveWith(f,[f])};for("string"!=typeof n&&(r=n,n=t),n=n||"fx";s--;)u=i._data(f[s],n+"queueHooks"),u&&u.empty&&(e++,u.empty.add(h));return h(),o.promise(r)}});var k,fr,ti=/[\t\r\n]/g,df=/\r/g,gf=/^(?:input|select|textarea|button|object)$/i,ne=/^(?:a|area)$/i,er=/^(?:checked|selected|autofocus|autoplay|async|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped)$/i,ii=/^(?:checked|selected)$/i,a=i.support.getSetAttribute,ri=i.support.input;i.fn.extend({attr:function(n,t){return i.access(this,i.attr,n,t,arguments.length>1)},removeAttr:function(n){return this.each(function(){i.removeAttr(this,n)})},prop:function(n,t){return i.access(this,i.prop,n,t,arguments.length>1)},removeProp:function(n){return n=i.propFix[n]||n,this.each(function(){try{this[n]=t,delete this[n]}catch(i){}})},addClass:function(n){var e,t,r,u,o,f=0,h=this.length,c="string"==typeof n&&n;if(i.isFunction(n))return this.each(function(t){i(this).addClass(n.call(this,t,this.className))});if(c)for(e=(n||"").match(s)||[];h>f;f++)if(t=this[f],r=1===t.nodeType&&(t.className?(" "+t.className+" ").replace(ti," "):" ")){for(o=0;u=e[o++];)0>r.indexOf(" "+u+" ")&&(r+=u+" ");t.className=i.trim(r)}return this},removeClass:function(n){var e,t,r,u,o,f=0,h=this.length,c=0===arguments.length||"string"==typeof n&&n;if(i.isFunction(n))return this.each(function(t){i(this).removeClass(n.call(this,t,this.className))});if(c)for(e=(n||"").match(s)||[];h>f;f++)if(t=this[f],r=1===t.nodeType&&(t.className?(" "+t.className+" ").replace(ti," "):"")){for(o=0;u=e[o++];)while(r.indexOf(" "+u+" ")>=0)r=r.replace(" "+u+" "," ");t.className=n?i.trim(r):""}return this},toggleClass:function(n,t){var r=typeof n,u="boolean"==typeof t;return i.isFunction(n)?this.each(function(r){i(this).toggleClass(n.call(this,r,this.className,t),t)}):this.each(function(){if("string"===r)for(var f,c=0,h=i(this),e=t,l=n.match(s)||[];f=l[c++];)e=u?e:!h.hasClass(f),h[e?"addClass":"removeClass"](f);else(r===o||"boolean"===r)&&(this.className&&i._data(this,"__className__",this.className),this.className=this.className||n===!1?"":i._data(this,"__className__")||"")})},hasClass:function(n){for(var i=" "+n+" ",t=0,r=this.length;r>t;t++)if(1===this[t].nodeType&&(" "+this[t].className+" ").replace(ti," ").indexOf(i)>=0)return!0;return!1},val:function(n){var u,r,e,f=this[0];return arguments.length?(e=i.isFunction(n),this.each(function(u){var f,o=i(this);1===this.nodeType&&(f=e?n.call(this,u,o.val()):n,null==f?f="":"number"==typeof f?f+="":i.isArray(f)&&(f=i.map(f,function(n){return null==n?"":n+""})),r=i.valHooks[this.type]||i.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,f,"value")!==t||(this.value=f))})):f?(r=i.valHooks[f.type]||i.valHooks[f.nodeName.toLowerCase()],r&&"get"in r&&(u=r.get(f,"value"))!==t?u:(u=f.value,"string"==typeof u?u.replace(df,""):null==u?"":u)):void 0}}),i.extend({valHooks:{option:{get:function(n){var t=n.attributes.value;return!t||t.specified?n.value:n.text}},select:{get:function(n){for(var e,t,o=n.options,r=n.selectedIndex,u="select-one"===n.type||0>r,s=u?null:[],h=u?r+1:o.length,f=0>r?h:u?r:0;h>f;f++)if(t=o[f],!(!t.selected&&f!==r||(i.support.optDisabled?t.disabled:null!==t.getAttribute("disabled"))||t.parentNode.disabled&&i.nodeName(t.parentNode,"optgroup"))){if(e=i(t).val(),u)return e;s.push(e)}return s},set:function(n,t){var r=i.makeArray(t);return i(n).find("option").each(function(){this.selected=i.inArray(i(this).val(),r)>=0}),r.length||(n.selectedIndex=-1),r}}},attr:function(n,r,u){var f,s,e,h=n.nodeType;if(n&&3!==h&&8!==h&&2!==h)return typeof n.getAttribute===o?i.prop(n,r,u):(s=1!==h||!i.isXMLDoc(n),s&&(r=r.toLowerCase(),f=i.attrHooks[r]||(er.test(r)?fr:k)),u===t?f&&s&&"get"in f&&null!==(e=f.get(n,r))?e:(typeof n.getAttribute!==o&&(e=n.getAttribute(r)),null==e?t:e):null!==u?f&&s&&"set"in f&&(e=f.set(n,u,r))!==t?e:(n.setAttribute(r,u+""),u):(i.removeAttr(n,r),t))},removeAttr:function(n,t){var r,u,e=0,f=t&&t.match(s);if(f&&1===n.nodeType)while(r=f[e++])u=i.propFix[r]||r,er.test(r)?!a&&ii.test(r)?n[i.camelCase("default-"+r)]=n[u]=!1:n[u]=!1:i.attr(n,r,""),n.removeAttribute(a?r:u)},attrHooks:{type:{set:function(n,t){if(!i.support.radioValue&&"radio"===t&&i.nodeName(n,"input")){var r=n.value;return n.setAttribute("type",t),r&&(n.value=r),t}}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(n,r,u){var e,f,s,o=n.nodeType;if(n&&3!==o&&8!==o&&2!==o)return s=1!==o||!i.isXMLDoc(n),s&&(r=i.propFix[r]||r,f=i.propHooks[r]),u!==t?f&&"set"in f&&(e=f.set(n,u,r))!==t?e:n[r]=u:f&&"get"in f&&null!==(e=f.get(n,r))?e:n[r]},propHooks:{tabIndex:{get:function(n){var i=n.getAttributeNode("tabindex");return i&&i.specified?parseInt(i.value,10):gf.test(n.nodeName)||ne.test(n.nodeName)&&n.href?0:t}}}}),fr={get:function(n,r){var u=i.prop(n,r),f="boolean"==typeof u&&n.getAttribute(r),e="boolean"==typeof u?ri&&a?null!=f:ii.test(r)?n[i.camelCase("default-"+r)]:!!f:n.getAttributeNode(r);return e&&e.value!==!1?r.toLowerCase():t},set:function(n,t,r){return t===!1?i.removeAttr(n,r):ri&&a||!ii.test(r)?n.setAttribute(!a&&i.propFix[r]||r,r):n[i.camelCase("default-"+r)]=n[r]=!0,r}},ri&&a||(i.attrHooks.value={get:function(n,r){var u=n.getAttributeNode(r);return i.nodeName(n,"input")?n.defaultValue:u&&u.specified?u.value:t},set:function(n,r,u){return i.nodeName(n,"input")?(n.defaultValue=r,t):k&&k.set(n,r,u)}}),a||(k=i.valHooks.button={get:function(n,i){var r=n.getAttributeNode(i);return r&&("id"===i||"name"===i||"coords"===i?""!==r.value:r.specified)?r.value:t},set:function(n,i,r){var u=n.getAttributeNode(r);return u||n.setAttributeNode(u=n.ownerDocument.createAttribute(r)),u.value=i+="","value"===r||i===n.getAttribute(r)?i:t}},i.attrHooks.contenteditable={get:k.get,set:function(n,t,i){k.set(n,""===t?!1:t,i)}},i.each(["width","height"],function(n,r){i.attrHooks[r]=i.extend(i.attrHooks[r],{set:function(n,i){return""===i?(n.setAttribute(r,"auto"),i):t}})})),i.support.hrefNormalized||(i.each(["href","src","width","height"],function(n,r){i.attrHooks[r]=i.extend(i.attrHooks[r],{get:function(n){var i=n.getAttribute(r,2);return null==i?t:i}})}),i.each(["href","src"],function(n,t){i.propHooks[t]={get:function(n){return n.getAttribute(t,4)}}})),i.support.style||(i.attrHooks.style={get:function(n){return n.style.cssText||t},set:function(n,t){return n.style.cssText=t+""}}),i.support.optSelected||(i.propHooks.selected=i.extend(i.propHooks.selected,{get:function(n){var t=n.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}})),i.support.enctype||(i.propFix.enctype="encoding"),i.support.checkOn||i.each(["radio","checkbox"],function(){i.valHooks[this]={get:function(n){return null===n.getAttribute("value")?"on":n.value}}}),i.each(["radio","checkbox"],function(){i.valHooks[this]=i.extend(i.valHooks[this],{set:function(n,r){return i.isArray(r)?n.checked=i.inArray(i(n).val(),r)>=0:t}})});var ui=/^(?:input|select|textarea)$/i,te=/^key/,ie=/^(?:mouse|contextmenu)|click/,or=/^(?:focusinfocus|focusoutblur)$/,sr=/^([^.]*)(?:\.(.+)|)$/;i.event={global:{},add:function(n,r,u,f,e){var b,p,k,w,c,l,a,v,h,d,g,y=i._data(n);if(y){for(u.handler&&(w=u,u=w.handler,e=w.selector),u.guid||(u.guid=i.guid++),(p=y.events)||(p=y.events={}),(l=y.handle)||(l=y.handle=function(n){return typeof i===o||n&&i.event.triggered===n.type?t:i.event.dispatch.apply(l.elem,arguments)},l.elem=n),r=(r||"").match(s)||[""],k=r.length;k--;)b=sr.exec(r[k])||[],h=g=b[1],d=(b[2]||"").split(".").sort(),c=i.event.special[h]||{},h=(e?c.delegateType:c.bindType)||h,c=i.event.special[h]||{},a=i.extend({type:h,origType:g,data:f,handler:u,guid:u.guid,selector:e,needsContext:e&&i.expr.match.needsContext.test(e),namespace:d.join(".")},w),(v=p[h])||(v=p[h]=[],v.delegateCount=0,c.setup&&c.setup.call(n,f,d,l)!==!1||(n.addEventListener?n.addEventListener(h,l,!1):n.attachEvent&&n.attachEvent("on"+h,l))),c.add&&(c.add.call(n,a),a.handler.guid||(a.handler.guid=u.guid)),e?v.splice(v.delegateCount++,0,a):v.push(a),i.event.global[h]=!0;n=null}},remove:function(n,t,r,u,f){var y,o,h,b,p,a,c,l,e,w,k,v=i.hasData(n)&&i._data(n);if(v&&(a=v.events)){for(t=(t||"").match(s)||[""],p=t.length;p--;)if(h=sr.exec(t[p])||[],e=k=h[1],w=(h[2]||"").split(".").sort(),e){for(c=i.event.special[e]||{},e=(u?c.delegateType:c.bindType)||e,l=a[e]||[],h=h[2]&&RegExp("(^|\\.)"+w.join("\\.(?:.*\\.|)")+"(\\.|$)"),b=y=l.length;y--;)o=l[y],!f&&k!==o.origType||r&&r.guid!==o.guid||h&&!h.test(o.namespace)||u&&u!==o.selector&&("**"!==u||!o.selector)||(l.splice(y,1),o.selector&&l.delegateCount--,c.remove&&c.remove.call(n,o));b&&!l.length&&(c.teardown&&c.teardown.call(n,w,v.handle)!==!1||i.removeEvent(n,e,v.handle),delete a[e])}else for(e in a)i.event.remove(n,e+t[p],r,u,!0);i.isEmptyObject(a)&&(delete v.handle,i._removeData(n,"events"))}},trigger:function(u,f,e,o){var a,v,h,p,l,c,w,b=[e||r],s=it.call(u,"type")?u.type:u,y=it.call(u,"namespace")?u.namespace.split("."):[];if(h=c=e=e||r,3!==e.nodeType&&8!==e.nodeType&&!or.test(s+i.event.triggered)&&(s.indexOf(".")>=0&&(y=s.split("."),s=y.shift(),y.sort()),v=0>s.indexOf(":")&&"on"+s,u=u[i.expando]?u:new i.Event(s,"object"==typeof u&&u),u.isTrigger=!0,u.namespace=y.join("."),u.namespace_re=u.namespace?RegExp("(^|\\.)"+y.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,u.result=t,u.target||(u.target=e),f=null==f?[u]:i.makeArray(f,[u]),l=i.event.special[s]||{},o||!l.trigger||l.trigger.apply(e,f)!==!1)){if(!o&&!l.noBubble&&!i.isWindow(e)){for(p=l.delegateType||s,or.test(p+s)||(h=h.parentNode);h;h=h.parentNode)b.push(h),c=h;c===(e.ownerDocument||r)&&b.push(c.defaultView||c.parentWindow||n)}for(w=0;(h=b[w++])&&!u.isPropagationStopped();)u.type=w>1?p:l.bindType||s,a=(i._data(h,"events")||{})[u.type]&&i._data(h,"handle"),a&&a.apply(h,f),a=v&&h[v],a&&i.acceptData(h)&&a.apply&&a.apply(h,f)===!1&&u.preventDefault();if(u.type=s,!(o||u.isDefaultPrevented()||l._default&&l._default.apply(e.ownerDocument,f)!==!1||"click"===s&&i.nodeName(e,"a")||!i.acceptData(e)||!v||!e[s]||i.isWindow(e))){c=e[v],c&&(e[v]=null),i.event.triggered=s;try{e[s]()}catch(k){}i.event.triggered=t,c&&(e[v]=c)}return u.result}},dispatch:function(n){n=i.event.fix(n);var o,e,r,u,s,h=[],c=l.call(arguments),a=(i._data(this,"events")||{})[n.type]||[],f=i.event.special[n.type]||{};if(c[0]=n,n.delegateTarget=this,!f.preDispatch||f.preDispatch.call(this,n)!==!1){for(h=i.event.handlers.call(this,n,a),o=0;(u=h[o++])&&!n.isPropagationStopped();)for(n.currentTarget=u.elem,s=0;(r=u.handlers[s++])&&!n.isImmediatePropagationStopped();)(!n.namespace_re||n.namespace_re.test(r.namespace))&&(n.handleObj=r,n.data=r.data,e=((i.event.special[r.origType]||{}).handle||r.handler).apply(u.elem,c),e!==t&&(n.result=e)===!1&&(n.preventDefault(),n.stopPropagation()));return f.postDispatch&&f.postDispatch.call(this,n),n.result}},handlers:function(n,r){var e,o,f,s,c=[],h=r.delegateCount,u=n.target;if(h&&u.nodeType&&(!n.button||"click"!==n.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==n.type)){for(f=[],s=0;h>s;s++)o=r[s],e=o.selector+" ",f[e]===t&&(f[e]=o.needsContext?i(e,this).index(u)>=0:i.find(e,this,null,[u]).length),f[e]&&f.push(o);f.length&&c.push({elem:u,handlers:f})}return r.length>h&&c.push({elem:this,handlers:r.slice(h)}),c},fix:function(n){if(n[i.expando])return n;var e,o,s,u=n.type,f=n,t=this.fixHooks[u];for(t||(this.fixHooks[u]=t=ie.test(u)?this.mouseHooks:te.test(u)?this.keyHooks:{}),s=t.props?this.props.concat(t.props):this.props,n=new i.Event(f),e=s.length;e--;)o=s[e],n[o]=f[o];return n.target||(n.target=f.srcElement||r),3===n.target.nodeType&&(n.target=n.target.parentNode),n.metaKey=!!n.metaKey,t.filter?t.filter(n,f):n},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(n,t){return null==n.which&&(n.which=null!=t.charCode?t.charCode:t.keyCode),n}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(n,i){var u,o,f,e=i.button,s=i.fromElement;return null==n.pageX&&null!=i.clientX&&(o=n.target.ownerDocument||r,f=o.documentElement,u=o.body,n.pageX=i.clientX+(f&&f.scrollLeft||u&&u.scrollLeft||0)-(f&&f.clientLeft||u&&u.clientLeft||0),n.pageY=i.clientY+(f&&f.scrollTop||u&&u.scrollTop||0)-(f&&f.clientTop||u&&u.clientTop||0)),!n.relatedTarget&&s&&(n.relatedTarget=s===n.target?i.toElement:s),n.which||e===t||(n.which=1&e?1:2&e?3:4&e?2:0),n}},special:{load:{noBubble:!0},click:{trigger:function(){return i.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t}},focus:{trigger:function(){if(this!==r.activeElement&&this.focus)try{return this.focus(),!1}catch(n){}},delegateType:"focusin"},blur:{trigger:function(){return this===r.activeElement&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},beforeunload:{postDispatch:function(n){n.result!==t&&(n.originalEvent.returnValue=n.result)}}},simulate:function(n,t,r,u){var f=i.extend(new i.Event,r,{type:n,isSimulated:!0,originalEvent:{}});u?i.event.trigger(f,null,t):i.event.dispatch.call(t,f),f.isDefaultPrevented()&&r.preventDefault()}},i.removeEvent=r.removeEventListener?function(n,t,i){n.removeEventListener&&n.removeEventListener(t,i,!1)}:function(n,t,i){var r="on"+t;n.detachEvent&&(typeof n[r]===o&&(n[r]=null),n.detachEvent(r,i))},i.Event=function(n,r){return this instanceof i.Event?(n&&n.type?(this.originalEvent=n,this.type=n.type,this.isDefaultPrevented=n.defaultPrevented||n.returnValue===!1||n.getPreventDefault&&n.getPreventDefault()?ht:d):this.type=n,r&&i.extend(this,r),this.timeStamp=n&&n.timeStamp||i.now(),this[i.expando]=!0,t):new i.Event(n,r)},i.Event.prototype={isDefaultPrevented:d,isPropagationStopped:d,isImmediatePropagationStopped:d,preventDefault:function(){var n=this.originalEvent;this.isDefaultPrevented=ht,n&&(n.preventDefault?n.preventDefault():n.returnValue=!1)},stopPropagation:function(){var n=this.originalEvent;this.isPropagationStopped=ht,n&&(n.stopPropagation&&n.stopPropagation(),n.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=ht,this.stopPropagation()}},i.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(n,t){i.event.special[n]={delegateType:t,bindType:t,handle:function(n){var u,f=this,r=n.relatedTarget,e=n.handleObj;return(!r||r!==f&&!i.contains(f,r))&&(n.type=e.origType,u=e.handler.apply(this,arguments),n.type=t),u}}}),i.support.submitBubbles||(i.event.special.submit={setup:function(){return i.nodeName(this,"form")?!1:(i.event.add(this,"click._submit keypress._submit",function(n){var u=n.target,r=i.nodeName(u,"input")||i.nodeName(u,"button")?u.form:t;r&&!i._data(r,"submitBubbles")&&(i.event.add(r,"submit._submit",function(n){n._submit_bubble=!0}),i._data(r,"submitBubbles",!0))}),t)},postDispatch:function(n){n._submit_bubble&&(delete n._submit_bubble,this.parentNode&&!n.isTrigger&&i.event.simulate("submit",this.parentNode,n,!0))},teardown:function(){return i.nodeName(this,"form")?!1:(i.event.remove(this,"._submit"),t)}}),i.support.changeBubbles||(i.event.special.change={setup:function(){return ui.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(i.event.add(this,"propertychange._change",function(n){"checked"===n.originalEvent.propertyName&&(this._just_changed=!0)}),i.event.add(this,"click._change",function(n){this._just_changed&&!n.isTrigger&&(this._just_changed=!1),i.event.simulate("change",this,n,!0)})),!1):(i.event.add(this,"beforeactivate._change",function(n){var t=n.target;ui.test(t.nodeName)&&!i._data(t,"changeBubbles")&&(i.event.add(t,"change._change",function(n){!this.parentNode||n.isSimulated||n.isTrigger||i.event.simulate("change",this.parentNode,n,!0)}),i._data(t,"changeBubbles",!0))}),t)},handle:function(n){var i=n.target;return this!==i||n.isSimulated||n.isTrigger||"radio"!==i.type&&"checkbox"!==i.type?n.handleObj.handler.apply(this,arguments):t},teardown:function(){return i.event.remove(this,"._change"),!ui.test(this.nodeName)}}),i.support.focusinBubbles||i.each({focus:"focusin",blur:"focusout"},function(n,t){var u=0,f=function(n){i.event.simulate(t,n.target,i.event.fix(n),!0)};i.event.special[t]={setup:function(){0==u++&&r.addEventListener(n,f,!0)},teardown:function(){0==--u&&r.removeEventListener(n,f,!0)}}}),i.fn.extend({on:function(n,r,u,f,e){var s,o;if("object"==typeof n){"string"!=typeof r&&(u=u||r,r=t);for(s in n)this.on(s,r,u,n[s],e);return this}if(null==u&&null==f?(f=r,u=r=t):null==f&&("string"==typeof r?(f=u,u=t):(f=u,u=r,r=t)),f===!1)f=d;else if(!f)return this;return 1===e&&(o=f,f=function(n){return i().off(n),o.apply(this,arguments)},f.guid=o.guid||(o.guid=i.guid++)),this.each(function(){i.event.add(this,n,f,u,r)})},one:function(n,t,i,r){return this.on(n,t,i,r,1)},off:function(n,r,u){var f,e;if(n&&n.preventDefault&&n.handleObj)return f=n.handleObj,i(n.delegateTarget).off(f.namespace?f.origType+"."+f.namespace:f.origType,f.selector,f.handler),this;if("object"==typeof n){for(e in n)this.off(e,r,n[e]);return this}return(r===!1||"function"==typeof r)&&(u=r,r=t),u===!1&&(u=d),this.each(function(){i.event.remove(this,n,u,r)})},bind:function(n,t,i){return this.on(n,null,t,i)},unbind:function(n,t){return this.off(n,null,t)},delegate:function(n,t,i,r){return this.on(t,n,i,r)},undelegate:function(n,t,i){return 1===arguments.length?this.off(n,"**"):this.off(t,n||"**",i)},trigger:function(n,t){return this.each(function(){i.event.trigger(n,t,this)})},triggerHandler:function(n,r){var u=this[0];return u?i.event.trigger(n,r,u,!0):t}}),function(n,t){function ti(n){return ir.test(n+"")}function ii(){var n,t=[];return n=function(i,u){return t.push(i+=" ")>r.cacheLength&&delete n[t.shift()],n[i]=u}}function l(n){return n[f]=!0,n}function b(n){var t=s.createElement("div");try{return n(t)}catch(i){return!1}finally{t=null}}function u(n,t,i,r){var y,u,e,l,p,v,w,h,d,b;if((t?t.ownerDocument||t:k)!==s&&it(t),t=t||s,i=i||[],!n||"string"!=typeof n)return i;if(1!==(l=t.nodeType)&&9!==l)return[];if(!c&&!r){if(y=rr.exec(n))if(e=y[1]){if(9===l){if(u=t.getElementById(e),!u||!u.parentNode)return i;if(u.id===e)return i.push(u),i}else if(t.ownerDocument&&(u=t.ownerDocument.getElementById(e))&&et(t,u)&&u.id===e)return i.push(u),i}else{if(y[2])return ut.apply(i,ft.call(t.getElementsByTagName(n),0)),i;if((e=y[3])&&o.getByClassName&&t.getElementsByClassName)return ut.apply(i,ft.call(t.getElementsByClassName(e),0)),i}if(o.qsa&&!a.test(n)){if(w=!0,h=f,d=t,b=9===l&&n,1===l&&"object"!==t.nodeName.toLowerCase()){for(v=yt(n),(w=t.getAttribute("id"))?h=w.replace(er,"\\$&"):t.setAttribute("id",h),h="[id='"+h+"'] ",p=v.length;p--;)v[p]=h+pt(v[p]);d=ni.test(n)&&t.parentNode||t,b=v.join(",")}if(b)try{return ut.apply(i,ft.call(d.querySelectorAll(b),0)),i}catch(g){}finally{w||t.removeAttribute("id")}}}return ar(n.replace(at,"$1"),t,i,r)}function yi(n,t){var i=t&&n,r=i&&(~t.sourceIndex||li)-(~n.sourceIndex||li);if(r)return r;if(i)while(i=i.nextSibling)if(i===t)return-1;return n?1:-1}function sr(n){return function(t){var i=t.nodeName.toLowerCase();return"input"===i&&t.type===n}}function hr(n){return function(t){var i=t.nodeName.toLowerCase();return("input"===i||"button"===i)&&t.type===n}}function g(n){return l(function(t){return t=+t,l(function(i,r){for(var u,f=n([],i.length,t),e=f.length;e--;)i[u=f[e]]&&(i[u]=!(r[u]=i[u]))})})}function yt(n,t){var e,f,s,o,i,h,c,l=hi[n+" "];if(l)return t?0:l.slice(0);for(i=n,h=[],c=r.preFilter;i;){(!e||(f=di.exec(i)))&&(f&&(i=i.slice(f[0].length)||i),h.push(s=[])),e=!1,(f=gi.exec(i))&&(e=f.shift(),s.push({value:e,type:f[0].replace(at," ")}),i=i.slice(e.length));for(o in r.filter)(f=vt[o].exec(i))&&(!c[o]||(f=c[o](f)))&&(e=f.shift(),s.push({value:e,type:o,matches:f}),i=i.slice(e.length));if(!e)break}return t?i.length:i?u.error(n):hi(n,h).slice(0)}function pt(n){for(var t=0,r=n.length,i="";r>t;t++)i+=n[t].value;return i}function ri(n,t,i){var r=t.dir,u=i&&"parentNode"===r,e=wi++;return t.first?function(t,i,f){while(t=t[r])if(1===t.nodeType||u)return n(t,i,f)}:function(t,i,o){var h,s,c,l=v+" "+e;if(o){while(t=t[r])if((1===t.nodeType||u)&&n(t,i,o))return!0}else while(t=t[r])if(1===t.nodeType||u)if(c=t[f]||(t[f]={}),(s=c[r])&&s[0]===l){if((h=s[1])===!0||h===ot)return h===!0}else if(s=c[r]=[l],s[1]=n(t,i,o)||ot,s[1]===!0)return!0}}function ui(n){return n.length>1?function(t,i,r){for(var u=n.length;u--;)if(!n[u](t,i,r))return!1;return!0}:n[0]}function wt(n,t,i,r,u){for(var e,o=[],f=0,s=n.length,h=null!=t;s>f;f++)(e=n[f])&&(!i||i(e,r,u))&&(o.push(e),h&&t.push(f));return o}function fi(n,t,i,r,u,e){return r&&!r[f]&&(r=fi(r)),u&&!u[f]&&(u=fi(u,e)),l(function(f,e,o,s){var l,c,a,p=[],y=[],w=e.length,b=f||lr(t||"*",o.nodeType?[o]:o,[]),v=!n||!f&&t?b:wt(b,p,n,o,s),h=i?u||(f?n:w||r)?[]:e:v;if(i&&i(v,h,o,s),r)for(l=wt(h,y),r(l,[],o,s),c=l.length;c--;)(a=l[c])&&(h[y[c]]=!(v[y[c]]=a));if(f){if(u||n){if(u){for(l=[],c=h.length;c--;)(a=h[c])&&l.push(v[c]=a);u(null,h=[],l,s)}for(c=h.length;c--;)(a=h[c])&&(l=u?dt.call(f,a):p[c])>-1&&(f[l]=!(e[l]=a))}}else h=wt(h===e?h.splice(w,h.length):h),u?u(null,e,h,s):ut.apply(e,h)})}function ei(n){for(var s,u,i,o=n.length,h=r.relative[n[0].type],c=h||r.relative[" "],t=h?1:0,l=ri(function(n){return n===s},c,!0),a=ri(function(n){return dt.call(s,n)>-1},c,!0),e=[function(n,t,i){return!h&&(i||t!==ht)||((s=t).nodeType?l(n,t,i):a(n,t,i))}];o>t;t++)if(u=r.relative[n[t].type])e=[ri(ui(e),u)];else{if(u=r.filter[n[t].type].apply(null,n[t].matches),u[f]){for(i=++t;o>i;i++)if(r.relative[n[i].type])break;return fi(t>1&&ui(e),t>1&&pt(n.slice(0,t-1)).replace(at,"$1"),u,i>t&&ei(n.slice(t,i)),o>i&&ei(n=n.slice(i)),o>i&&pt(n))}e.push(u)}return ui(e)}function cr(n,t){var f=0,i=t.length>0,e=n.length>0,o=function(o,h,c,l,a){var p,d,b,w=[],k=0,y="0",g=o&&[],nt=null!=a,tt=ht,rt=o||e&&r.find.TAG("*",a&&h.parentNode||h),it=v+=null==tt?1:Math.random()||.1;for(nt&&(ht=h!==s&&h,ot=f);null!=(p=rt[y]);y++){if(e&&p){for(d=0;b=n[d++];)if(b(p,h,c)){l.push(p);break}nt&&(v=it,ot=++f)}i&&((p=!b&&p)&&k--,o&&g.push(p))}if(k+=y,i&&y!==k){for(d=0;b=t[d++];)b(g,w,h,c);if(o){if(k>0)while(y--)g[y]||w[y]||(w[y]=bi.call(l));w=wt(w)}ut.apply(l,w),nt&&!o&&w.length>0&&k+t.length>1&&u.uniqueSort(l)}return nt&&(v=it,ht=tt),g};return i?l(o):o}function lr(n,t,i){for(var r=0,f=t.length;f>r;r++)u(n,t[r],i);return i}function ar(n,t,i,u){var o,f,e,h,l,s=yt(n);if(!u&&1===s.length){if(f=s[0]=s[0].slice(0),f.length>2&&"ID"===(e=f[0]).type&&9===t.nodeType&&!c&&r.relative[f[1].type]){if(t=r.find.ID(e.matches[0].replace(p,w),t)[0],!t)return i;n=n.slice(f.shift().value.length)}for(o=vt.needsContext.test(n)?0:f.length;o--;){if(e=f[o],r.relative[h=e.type])break;if((l=r.find[h])&&(u=l(e.matches[0].replace(p,w),ni.test(f[0].type)&&t.parentNode||t))){if(f.splice(o,1),n=u.length&&pt(f),!n)return ut.apply(i,ft.call(u,0)),i;break}}}return bt(n,s)(u,t,c,i,ni.test(n)),i}function pi(){}var nt,ot,r,st,oi,bt,tt,ht,it,s,h,c,a,rt,ct,et,kt,f="sizzle"+-new Date,k=n.document,o={},v=0,wi=0,si=ii(),hi=ii(),ci=ii(),y=typeof t,li=-2147483648,lt=[],bi=lt.pop,ut=lt.push,ft=lt.slice,dt=lt.indexOf||function(n){for(var t=0,i=this.length;i>t;t++)if(this[t]===n)return t;return-1},e="[\\x20\\t\\r\\n\\f]",d="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",ai=d.replace("w","w#"),ki="([*^$|!~]?=)",vi="\\["+e+"*("+d+")"+e+"*(?:"+ki+e+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+ai+")|)|)"+e+"*\\]",gt=":("+d+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+vi.replace(3,8)+")*)|.*)\\)|)",at=RegExp("^"+e+"+|((?:^|[^\\\\])(?:\\\\.)*)"+e+"+$","g"),di=RegExp("^"+e+"*,"+e+"*"),gi=RegExp("^"+e+"*([\\x20\\t\\r\\n\\f>+~])"+e+"*"),nr=RegExp(gt),tr=RegExp("^"+ai+"$"),vt={ID:RegExp("^#("+d+")"),CLASS:RegExp("^\\.("+d+")"),NAME:RegExp("^\\[name=['\"]?("+d+")['\"]?\\]"),TAG:RegExp("^("+d.replace("w","w*")+")"),ATTR:RegExp("^"+vi),PSEUDO:RegExp("^"+gt),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+e+"*(even|odd|(([+-]|)(\\d*)n|)"+e+"*(?:([+-]|)"+e+"*(\\d+)|))"+e+"*\\)|)","i"),needsContext:RegExp("^"+e+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+e+"*((?:-\\d)?\\d*)"+e+"*\\)|)(?=[^-]|$)","i")},ni=/[\x20\t\r\n\f]*[+~]/,ir=/^[^{]+\{\s*\[native code/,rr=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ur=/^(?:input|select|textarea|button)$/i,fr=/^h\d$/i,er=/'|\\/g,or=/\=[\x20\t\r\n\f]*([^'"\]]*)[\x20\t\r\n\f]*\]/g,p=/\\([\da-fA-F]{1,6}[\x20\t\r\n\f]?|.)/g,w=function(n,t){var i="0x"+t-65536;return i!==i?t:0>i?String.fromCharCode(i+65536):String.fromCharCode(55296|i>>10,56320|1023&i)};try{ft.call(k.documentElement.childNodes,0)[0].nodeType}catch(vr){ft=function(n){for(var t,i=[];t=this[n++];)i.push(t);return i}}oi=u.isXML=function(n){var t=n&&(n.ownerDocument||n).documentElement;return t?"HTML"!==t.nodeName:!1},it=u.setDocument=function(n){var i=n?n.ownerDocument||n:k;return i!==s&&9===i.nodeType&&i.documentElement?(s=i,h=i.documentElement,c=oi(i),o.tagNameNoComments=b(function(n){return n.appendChild(i.createComment("")),!n.getElementsByTagName("*").length}),o.attributes=b(function(n){n.innerHTML="<select><\/select>";var t=typeof n.lastChild.getAttribute("multiple");return"boolean"!==t&&"string"!==t}),o.getByClassName=b(function(n){return n.innerHTML="<div class='hidden e'><\/div><div class='hidden'><\/div>",n.getElementsByClassName&&n.getElementsByClassName("e").length?(n.lastChild.className="e",2===n.getElementsByClassName("e").length):!1}),o.getByName=b(function(n){n.id=f+0,n.innerHTML="<a name='"+f+"'><\/a><div name='"+f+"'><\/div>",h.insertBefore(n,h.firstChild);var t=i.getElementsByName&&i.getElementsByName(f).length===2+i.getElementsByName(f+0).length;return o.getIdNotName=!i.getElementById(f),h.removeChild(n),t}),r.attrHandle=b(function(n){return n.innerHTML="<a href='#'><\/a>",n.firstChild&&typeof n.firstChild.getAttribute!==y&&"#"===n.firstChild.getAttribute("href")})?{}:{href:function(n){return n.getAttribute("href",2)},type:function(n){return n.getAttribute("type")}},o.getIdNotName?(r.find.ID=function(n,t){if(typeof t.getElementById!==y&&!c){var i=t.getElementById(n);return i&&i.parentNode?[i]:[]}},r.filter.ID=function(n){var t=n.replace(p,w);return function(n){return n.getAttribute("id")===t}}):(r.find.ID=function(n,i){if(typeof i.getElementById!==y&&!c){var r=i.getElementById(n);return r?r.id===n||typeof r.getAttributeNode!==y&&r.getAttributeNode("id").value===n?[r]:t:[]}},r.filter.ID=function(n){var t=n.replace(p,w);return function(n){var i=typeof n.getAttributeNode!==y&&n.getAttributeNode("id");return i&&i.value===t}}),r.find.TAG=o.tagNameNoComments?function(n,i){return typeof i.getElementsByTagName!==y?i.getElementsByTagName(n):t}:function(n,t){var i,r=[],f=0,u=t.getElementsByTagName(n);if("*"===n){while(i=u[f++])1===i.nodeType&&r.push(i);return r}return u},r.find.NAME=o.getByName&&function(n,i){return typeof i.getElementsByName!==y?i.getElementsByName(name):t},r.find.CLASS=o.getByClassName&&function(n,i){return typeof i.getElementsByClassName===y||c?t:i.getElementsByClassName(n)},rt=[],a=[":focus"],(o.qsa=ti(i.querySelectorAll))&&(b(function(n){n.innerHTML="<select><option selected=''><\/option><\/select>",n.querySelectorAll("[selected]").length||a.push("\\["+e+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),n.querySelectorAll(":checked").length||a.push(":checked")}),b(function(n){n.innerHTML="<input type='hidden' i=''/>",n.querySelectorAll("[i^='']").length&&a.push("[*^$]="+e+"*(?:\"\"|'')"),n.querySelectorAll(":enabled").length||a.push(":enabled",":disabled"),n.querySelectorAll("*,:x"),a.push(",.*:")})),(o.matchesSelector=ti(ct=h.matchesSelector||h.mozMatchesSelector||h.webkitMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&b(function(n){o.disconnectedMatch=ct.call(n,"div"),ct.call(n,"[s!='']:x"),rt.push("!=",gt)}),a=RegExp(a.join("|")),rt=RegExp(rt.join("|")),et=ti(h.contains)||h.compareDocumentPosition?function(n,t){var r=9===n.nodeType?n.documentElement:n,i=t&&t.parentNode;return n===i||!(!i||1!==i.nodeType||!(r.contains?r.contains(i):n.compareDocumentPosition&&16&n.compareDocumentPosition(i)))}:function(n,t){if(t)while(t=t.parentNode)if(t===n)return!0;return!1},kt=h.compareDocumentPosition?function(n,t){var r;return n===t?(tt=!0,0):(r=t.compareDocumentPosition&&n.compareDocumentPosition&&n.compareDocumentPosition(t))?1&r||n.parentNode&&11===n.parentNode.nodeType?n===i||et(k,n)?-1:t===i||et(k,t)?1:0:4&r?-1:1:n.compareDocumentPosition?-1:1}:function(n,t){var r,u=0,o=n.parentNode,s=t.parentNode,f=[n],e=[t];if(n===t)return tt=!0,0;if(!o||!s)return n===i?-1:t===i?1:o?-1:s?1:0;if(o===s)return yi(n,t);for(r=n;r=r.parentNode;)f.unshift(r);for(r=t;r=r.parentNode;)e.unshift(r);while(f[u]===e[u])u++;return u?yi(f[u],e[u]):f[u]===k?-1:e[u]===k?1:0},tt=!1,[0,0].sort(kt),o.detectDuplicates=tt,s):s},u.matches=function(n,t){return u(n,null,null,t)},u.matchesSelector=function(n,t){if((n.ownerDocument||n)!==s&&it(n),t=t.replace(or,"='$1']"),!(!o.matchesSelector||c||rt&&rt.test(t)||a.test(t)))try{var i=ct.call(n,t);if(i||o.disconnectedMatch||n.document&&11!==n.document.nodeType)return i}catch(r){}return u(t,s,null,[n]).length>0},u.contains=function(n,t){return(n.ownerDocument||n)!==s&&it(n),et(n,t)},u.attr=function(n,t){var i;return(n.ownerDocument||n)!==s&&it(n),c||(t=t.toLowerCase()),(i=r.attrHandle[t])?i(n):c||o.attributes?n.getAttribute(t):((i=n.getAttributeNode(t))||n.getAttribute(t))&&n[t]===!0?t:i&&i.specified?i.value:null},u.error=function(n){throw Error("Syntax error, unrecognized expression: "+n);},u.uniqueSort=function(n){var r,u=[],t=1,i=0;if(tt=!o.detectDuplicates,n.sort(kt),tt){for(;r=n[t];t++)r===n[t-1]&&(i=u.push(t));while(i--)n.splice(u[i],1)}return n},st=u.getText=function(n){var r,i="",u=0,t=n.nodeType;if(t){if(1===t||9===t||11===t){if("string"==typeof n.textContent)return n.textContent;for(n=n.firstChild;n;n=n.nextSibling)i+=st(n)}else if(3===t||4===t)return n.nodeValue}else for(;r=n[u];u++)i+=st(r);return i},r=u.selectors={cacheLength:50,createPseudo:l,match:vt,find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(n){return n[1]=n[1].replace(p,w),n[3]=(n[4]||n[5]||"").replace(p,w),"~="===n[2]&&(n[3]=" "+n[3]+" "),n.slice(0,4)},CHILD:function(n){return n[1]=n[1].toLowerCase(),"nth"===n[1].slice(0,3)?(n[3]||u.error(n[0]),n[4]=+(n[4]?n[5]+(n[6]||1):2*("even"===n[3]||"odd"===n[3])),n[5]=+(n[7]+n[8]||"odd"===n[3])):n[3]&&u.error(n[0]),n},PSEUDO:function(n){var i,t=!n[5]&&n[2];return vt.CHILD.test(n[0])?null:(n[4]?n[2]=n[4]:t&&nr.test(t)&&(i=yt(t,!0))&&(i=t.indexOf(")",t.length-i)-t.length)&&(n[0]=n[0].slice(0,i),n[2]=t.slice(0,i)),n.slice(0,3))}},filter:{TAG:function(n){return"*"===n?function(){return!0}:(n=n.replace(p,w).toLowerCase(),function(t){return t.nodeName&&t.nodeName.toLowerCase()===n})},CLASS:function(n){var t=si[n+" "];return t||(t=RegExp("(^|"+e+")"+n+"("+e+"|$)"))&&si(n,function(n){return t.test(n.className||typeof n.getAttribute!==y&&n.getAttribute("class")||"")})},ATTR:function(n,t,i){return function(r){var f=u.attr(r,n);return null==f?"!="===t:t?(f+="","="===t?f===i:"!="===t?f!==i:"^="===t?i&&0===f.indexOf(i):"*="===t?i&&f.indexOf(i)>-1:"$="===t?i&&f.slice(-i.length)===i:"~="===t?(" "+f+" ").indexOf(i)>-1:"|="===t?f===i||f.slice(0,i.length+1)===i+"-":!1):!0}},CHILD:function(n,t,i,r,u){var s="nth"!==n.slice(0,3),o="last"!==n.slice(-4),e="of-type"===t;return 1===r&&0===u?function(n){return!!n.parentNode}:function(t,i,h){var a,k,c,l,y,w,b=s!==o?"nextSibling":"previousSibling",p=t.parentNode,g=e&&t.nodeName.toLowerCase(),d=!h&&!e;if(p){if(s){while(b){for(c=t;c=c[b];)if(e?c.nodeName.toLowerCase()===g:1===c.nodeType)return!1;w=b="only"===n&&!w&&"nextSibling"}return!0}if(w=[o?p.firstChild:p.lastChild],o&&d){for(k=p[f]||(p[f]={}),a=k[n]||[],y=a[0]===v&&a[1],l=a[0]===v&&a[2],c=y&&p.childNodes[y];c=++y&&c&&c[b]||(l=y=0)||w.pop();)if(1===c.nodeType&&++l&&c===t){k[n]=[v,y,l];break}}else if(d&&(a=(t[f]||(t[f]={}))[n])&&a[0]===v)l=a[1];else while(c=++y&&c&&c[b]||(l=y=0)||w.pop())if((e?c.nodeName.toLowerCase()===g:1===c.nodeType)&&++l&&(d&&((c[f]||(c[f]={}))[n]=[v,l]),c===t))break;return l-=u,l===r||0==l%r&&l/r>=0}}},PSEUDO:function(n,t){var e,i=r.pseudos[n]||r.setFilters[n.toLowerCase()]||u.error("unsupported pseudo: "+n);return i[f]?i(t):i.length>1?(e=[n,n,"",t],r.setFilters.hasOwnProperty(n.toLowerCase())?l(function(n,r){for(var u,f=i(n,t),e=f.length;e--;)u=dt.call(n,f[e]),n[u]=!(r[u]=f[e])}):function(n){return i(n,0,e)}):i}},pseudos:{not:l(function(n){var i=[],r=[],t=bt(n.replace(at,"$1"));return t[f]?l(function(n,i,r,u){for(var e,o=t(n,null,u,[]),f=n.length;f--;)(e=o[f])&&(n[f]=!(i[f]=e))}):function(n,u,f){return i[0]=n,t(i,null,f,r),!r.pop()}}),has:l(function(n){return function(t){return u(n,t).length>0}}),contains:l(function(n){return function(t){return(t.textContent||t.innerText||st(t)).indexOf(n)>-1}}),lang:l(function(n){return tr.test(n||"")||u.error("unsupported lang: "+n),n=n.replace(p,w).toLowerCase(),function(t){var i;do if(i=c?t.getAttribute("xml:lang")||t.getAttribute("lang"):t.lang)return i=i.toLowerCase(),i===n||0===i.indexOf(n+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var i=n.location&&n.location.hash;return i&&i.slice(1)===t.id},root:function(n){return n===h},focus:function(n){return n===s.activeElement&&(!s.hasFocus||s.hasFocus())&&!!(n.type||n.href||~n.tabIndex)},enabled:function(n){return n.disabled===!1},disabled:function(n){return n.disabled===!0},checked:function(n){var t=n.nodeName.toLowerCase();return"input"===t&&!!n.checked||"option"===t&&!!n.selected},selected:function(n){return n.parentNode&&n.parentNode.selectedIndex,n.selected===!0},empty:function(n){for(n=n.firstChild;n;n=n.nextSibling)if(n.nodeName>"@"||3===n.nodeType||4===n.nodeType)return!1;return!0},parent:function(n){return!r.pseudos.empty(n)},header:function(n){return fr.test(n.nodeName)},input:function(n){return ur.test(n.nodeName)},button:function(n){var t=n.nodeName.toLowerCase();return"input"===t&&"button"===n.type||"button"===t},text:function(n){var t;return"input"===n.nodeName.toLowerCase()&&"text"===n.type&&(null==(t=n.getAttribute("type"))||t.toLowerCase()===n.type)},first:g(function(){return[0]}),last:g(function(n,t){return[t-1]}),eq:g(function(n,t,i){return[0>i?i+t:i]}),even:g(function(n,t){for(var i=0;t>i;i+=2)n.push(i);return n}),odd:g(function(n,t){for(var i=1;t>i;i+=2)n.push(i);return n}),lt:g(function(n,t,i){for(var r=0>i?i+t:i;--r>=0;)n.push(r);return n}),gt:g(function(n,t,i){for(var r=0>i?i+t:i;t>++r;)n.push(r);return n})}};for(nt in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[nt]=sr(nt);for(nt in{submit:!0,reset:!0})r.pseudos[nt]=hr(nt);bt=u.compile=function(n,t){var r,u=[],e=[],i=ci[n+" "];if(!i){for(t||(t=yt(n)),r=t.length;r--;)i=ei(t[r]),i[f]?u.push(i):e.push(i);i=ci(n,cr(e,u))}return i},r.pseudos.nth=r.pseudos.eq,r.filters=pi.prototype=r.pseudos,r.setFilters=new pi,it(),u.attr=i.attr,i.find=u,i.expr=u.selectors,i.expr[":"]=i.expr.pseudos,i.unique=u.uniqueSort,i.text=u.getText,i.isXMLDoc=u.isXML,i.contains=u.contains}(n);var re=/Until$/,ue=/^(?:parents|prev(?:Until|All))/,fe=/^.[^:#\[\.,]*$/,hr=i.expr.match.needsContext,ee={children:!0,contents:!0,next:!0,prev:!0};i.fn.extend({find:function(n){var t,r,f,u=this.length;if("string"!=typeof n)return f=this,this.pushStack(i(n).filter(function(){for(t=0;u>t;t++)if(i.contains(f[t],this))return!0}));for(r=[],t=0;u>t;t++)i.find(n,this[t],r);return r=this.pushStack(u>1?i.unique(r):r),r.selector=(this.selector?this.selector+" ":"")+n,r},has:function(n){var t,r=i(n,this),u=r.length;return this.filter(function(){for(t=0;u>t;t++)if(i.contains(this,r[t]))return!0})},not:function(n){return this.pushStack(lr(this,n,!1))},filter:function(n){return this.pushStack(lr(this,n,!0))},is:function(n){return!!n&&("string"==typeof n?hr.test(n)?i(n,this.context).index(this[0])>=0:i.filter(n,this).length>0:this.filter(n).length>0)},closest:function(n,t){for(var r,f=0,o=this.length,u=[],e=hr.test(n)||"string"!=typeof n?i(n,t||this.context):0;o>f;f++)for(r=this[f];r&&r.ownerDocument&&r!==t&&11!==r.nodeType;){if(e?e.index(r)>-1:i.find.matchesSelector(r,n)){u.push(r);break}r=r.parentNode}return this.pushStack(u.length>1?i.unique(u):u)},index:function(n){return n?"string"==typeof n?i.inArray(this[0],i(n)):i.inArray(n.jquery?n[0]:n,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(n,t){var r="string"==typeof n?i(n,t):i.makeArray(n&&n.nodeType?[n]:n),u=i.merge(this.get(),r);return this.pushStack(i.unique(u))},addBack:function(n){return this.add(null==n?this.prevObject:this.prevObject.filter(n))}}),i.fn.andSelf=i.fn.addBack,i.each({parent:function(n){var t=n.parentNode;return t&&11!==t.nodeType?t:null},parents:function(n){return i.dir(n,"parentNode")},parentsUntil:function(n,t,r){return i.dir(n,"parentNode",r)},next:function(n){return cr(n,"nextSibling")},prev:function(n){return cr(n,"previousSibling")},nextAll:function(n){return i.dir(n,"nextSibling")},prevAll:function(n){return i.dir(n,"previousSibling")},nextUntil:function(n,t,r){return i.dir(n,"nextSibling",r)},prevUntil:function(n,t,r){return i.dir(n,"previousSibling",r)},siblings:function(n){return i.sibling((n.parentNode||{}).firstChild,n)},children:function(n){return i.sibling(n.firstChild)},contents:function(n){return i.nodeName(n,"iframe")?n.contentDocument||n.contentWindow.document:i.merge([],n.childNodes)}},function(n,t){i.fn[n]=function(r,u){var f=i.map(this,t,r);return re.test(n)||(u=r),u&&"string"==typeof u&&(f=i.filter(u,f)),f=this.length>1&&!ee[n]?i.unique(f):f,this.length>1&&ue.test(n)&&(f=f.reverse()),this.pushStack(f)}}),i.extend({filter:function(n,t,r){return r&&(n=":not("+n+")"),1===t.length?i.find.matchesSelector(t[0],n)?[t[0]]:[]:i.find.matches(n,t)},dir:function(n,r,u){for(var e=[],f=n[r];f&&9!==f.nodeType&&(u===t||1!==f.nodeType||!i(f).is(u));)1===f.nodeType&&e.push(f),f=f[r];return e},sibling:function(n,t){for(var i=[];n;n=n.nextSibling)1===n.nodeType&&n!==t&&i.push(n);return i}});var vr="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",oe=/ jQuery\d+="(?:null|\d+)"/g,yr=RegExp("<(?:"+vr+")[\\s/>]","i"),fi=/^\s+/,pr=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,wr=/<([\w:]+)/,br=/<tbody/i,se=/<|&#?\w+;/,he=/<(?:script|style|link)/i,ei=/^(?:checkbox|radio)$/i,ce=/checked\s*(?:[^=]|=\s*.checked.)/i,kr=/^$|\/(?:java|ecma)script/i,le=/^true\/(.*)/,ae=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,e={option:[1,"<select multiple='multiple'>","<\/select>"],legend:[1,"<fieldset>","<\/fieldset>"],area:[1,"<map>","<\/map>"],param:[1,"<object>","<\/object>"],thead:[1,"<table>","<\/table>"],tr:[2,"<table><tbody>","<\/tbody><\/table>"],col:[2,"<table><tbody><\/tbody><colgroup>","<\/colgroup><\/table>"],td:[3,"<table><tbody><tr>","<\/tr><\/tbody><\/table>"],_default:i.support.htmlSerialize?[0,"",""]:[1,"X<div>","<\/div>"]},ve=ar(r),oi=ve.appendChild(r.createElement("div"));e.optgroup=e.option,e.tbody=e.tfoot=e.colgroup=e.caption=e.thead,e.th=e.td,i.fn.extend({text:function(n){return i.access(this,function(n){return n===t?i.text(this):this.empty().append((this[0]&&this[0].ownerDocument||r).createTextNode(n))},null,n,arguments.length)},wrapAll:function(n){if(i.isFunction(n))return this.each(function(t){i(this).wrapAll(n.call(this,t))});if(this[0]){var t=i(n,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var n=this;n.firstChild&&1===n.firstChild.nodeType;)n=n.firstChild;return n}).append(this)}return this},wrapInner:function(n){return i.isFunction(n)?this.each(function(t){i(this).wrapInner(n.call(this,t))}):this.each(function(){var t=i(this),r=t.contents();r.length?r.wrapAll(n):t.append(n)})},wrap:function(n){var t=i.isFunction(n);return this.each(function(r){i(this).wrapAll(t?n.call(this,r):n)})},unwrap:function(){return this.parent().each(function(){i.nodeName(this,"body")||i(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(n){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&this.appendChild(n)})},prepend:function(){return this.domManip(arguments,!0,function(n){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&this.insertBefore(n,this.firstChild)})},before:function(){return this.domManip(arguments,!1,function(n){this.parentNode&&this.parentNode.insertBefore(n,this)})},after:function(){return this.domManip(arguments,!1,function(n){this.parentNode&&this.parentNode.insertBefore(n,this.nextSibling)})},remove:function(n,t){for(var r,f=0;null!=(r=this[f]);f++)(!n||i.filter(n,[r]).length>0)&&(t||1!==r.nodeType||i.cleanData(u(r)),r.parentNode&&(t&&i.contains(r.ownerDocument,r)&&si(u(r,"script")),r.parentNode.removeChild(r)));return this},empty:function(){for(var n,t=0;null!=(n=this[t]);t++){for(1===n.nodeType&&i.cleanData(u(n,!1));n.firstChild;)n.removeChild(n.firstChild);n.options&&i.nodeName(n,"select")&&(n.options.length=0)}return this},clone:function(n,t){return n=null==n?!1:n,t=null==t?n:t,this.map(function(){return i.clone(this,n,t)})},html:function(n){return i.access(this,function(n){var r=this[0]||{},f=0,o=this.length;if(n===t)return 1===r.nodeType?r.innerHTML.replace(oe,""):t;if(!("string"!=typeof n||he.test(n)||!i.support.htmlSerialize&&yr.test(n)||!i.support.leadingWhitespace&&fi.test(n)||e[(wr.exec(n)||["",""])[1].toLowerCase()])){n=n.replace(pr,"<$1><\/$2>");try{for(;o>f;f++)r=this[f]||{},1===r.nodeType&&(i.cleanData(u(r,!1)),r.innerHTML=n);r=0}catch(s){}}r&&this.empty().append(n)},null,n,arguments.length)},replaceWith:function(n){var t=i.isFunction(n);return t||"string"==typeof n||(n=i(n).not(this).detach()),this.domManip([n],!0,function(n){var r=this.nextSibling,t=this.parentNode;t&&(i(this).remove(),t.insertBefore(n,r))})},detach:function(n){return this.remove(n,!0)},domManip:function(n,r,f){n=bi.apply([],n);var c,e,l,s,y,h,o=0,a=this.length,w=this,b=a-1,v=n[0],p=i.isFunction(v);if(p||!(1>=a||"string"!=typeof v||i.support.checkClone)&&ce.test(v))return this.each(function(i){var u=w.eq(i);p&&(n[0]=v.call(this,i,r?u.html():t)),u.domManip(n,r,f)});if(a&&(h=i.buildFragment(n,this[0].ownerDocument,!1,this),c=h.firstChild,1===h.childNodes.length&&(h=c),c)){for(r=r&&i.nodeName(c,"tr"),s=i.map(u(h,"script"),dr),l=s.length;a>o;o++)e=h,o!==b&&(e=i.clone(e,!0,!0),l&&i.merge(s,u(e,"script"))),f.call(r&&i.nodeName(this[o],"table")?ye(this[o],"tbody"):this[o],e,o);if(l)for(y=s[s.length-1].ownerDocument,i.map(s,gr),o=0;l>o;o++)e=s[o],kr.test(e.type||"")&&!i._data(e,"globalEval")&&i.contains(y,e)&&(e.src?i.ajax({url:e.src,type:"GET",dataType:"script",async:!1,global:!1,throws:!0}):i.globalEval((e.text||e.textContent||e.innerHTML||"").replace(ae,"")));h=c=null}return this}}),i.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(n,t){i.fn[n]=function(n){for(var u,r=0,f=[],e=i(n),o=e.length-1;o>=r;r++)u=r===o?this:this.clone(!0),i(e[r])[t](u),bt.apply(f,u.get());return this.pushStack(f)}}),i.extend({clone:function(n,t,r){var f,h,o,e,s,c=i.contains(n.ownerDocument,n);if(i.support.html5Clone||i.isXMLDoc(n)||!yr.test("<"+n.nodeName+">")?o=n.cloneNode(!0):(oi.innerHTML=n.outerHTML,oi.removeChild(o=oi.firstChild)),!(i.support.noCloneEvent&&i.support.noCloneChecked||1!==n.nodeType&&11!==n.nodeType||i.isXMLDoc(n)))for(f=u(o),s=u(n),e=0;null!=(h=s[e]);++e)f[e]&&pe(h,f[e]);if(t)if(r)for(s=s||u(n),f=f||u(o),e=0;null!=(h=s[e]);e++)nu(h,f[e]);else nu(n,o);return f=u(o,"script"),f.length>0&&si(f,!c&&u(n,"script")),f=s=h=null,o},buildFragment:function(n,t,r,f){for(var h,o,w,s,y,p,l,b=n.length,a=ar(t),c=[],v=0;b>v;v++)if(o=n[v],o||0===o)if("object"===i.type(o))i.merge(c,o.nodeType?[o]:o);else if(se.test(o)){for(s=s||a.appendChild(t.createElement("div")),y=(wr.exec(o)||["",""])[1].toLowerCase(),l=e[y]||e._default,s.innerHTML=l[1]+o.replace(pr,"<$1><\/$2>")+l[2],h=l[0];h--;)s=s.lastChild;if(!i.support.leadingWhitespace&&fi.test(o)&&c.push(t.createTextNode(fi.exec(o)[0])),!i.support.tbody)for(o="table"!==y||br.test(o)?"<table>"!==l[1]||br.test(o)?0:s:s.firstChild,h=o&&o.childNodes.length;h--;)i.nodeName(p=o.childNodes[h],"tbody")&&!p.childNodes.length&&o.removeChild(p);for(i.merge(c,s.childNodes),s.textContent="";s.firstChild;)s.removeChild(s.firstChild);s=a.lastChild}else c.push(t.createTextNode(o));for(s&&a.removeChild(s),i.support.appendChecked||i.grep(u(c,"input"),we),v=0;o=c[v++];)if((!f||-1===i.inArray(o,f))&&(w=i.contains(o.ownerDocument,o),s=u(a.appendChild(o),"script"),w&&si(s),r))for(h=0;o=s[h++];)kr.test(o.type||"")&&r.push(o);return s=null,a},cleanData:function(n,t){for(var r,f,u,e,c=0,s=i.expando,h=i.cache,l=i.support.deleteExpando,a=i.event.special;null!=(r=n[c]);c++)if((t||i.acceptData(r))&&(u=r[s],e=u&&h[u])){if(e.events)for(f in e.events)a[f]?i.event.remove(r,f):i.removeEvent(r,f,e.handle);h[u]&&(delete h[u],l?delete r[s]:typeof r.removeAttribute!==o?r.removeAttribute(s):r[s]=null,b.push(u))}}});var rt,v,y,hi=/alpha\([^)]*\)/i,be=/opacity\s*=\s*([^)]*)/,ke=/^(top|right|bottom|left)$/,de=/^(none|table(?!-c[ea]).+)/,tu=/^margin/,ge=RegExp("^("+st+")(.*)$","i"),ct=RegExp("^("+st+")(?!px)[a-z%]+$","i"),no=RegExp("^([+-])=("+st+")","i"),iu={BODY:"block"},to={position:"absolute",visibility:"hidden",display:"block"},ru={letterSpacing:0,fontWeight:400},p=["Top","Right","Bottom","Left"],uu=["Webkit","O","Moz","ms"];i.fn.extend({css:function(n,r){return i.access(this,function(n,r,u){var e,o,s={},f=0;if(i.isArray(r)){for(o=v(n),e=r.length;e>f;f++)s[r[f]]=i.css(n,r[f],!1,o);return s}return u!==t?i.style(n,r,u):i.css(n,r)},n,r,arguments.length>1)},show:function(){return eu(this,!0)},hide:function(){return eu(this)},toggle:function(n){var t="boolean"==typeof n;return this.each(function(){(t?n:ut(this))?i(this).show():i(this).hide()})}}),i.extend({cssHooks:{opacity:{get:function(n,t){if(t){var i=y(n,"opacity");return""===i?"1":i}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:i.support.cssFloat?"cssFloat":"styleFloat"},style:function(n,r,u,f){if(n&&3!==n.nodeType&&8!==n.nodeType&&n.style){var o,s,e,h=i.camelCase(r),c=n.style;if(r=i.cssProps[h]||(i.cssProps[h]=fu(c,h)),e=i.cssHooks[r]||i.cssHooks[h],u===t)return e&&"get"in e&&(o=e.get(n,!1,f))!==t?o:c[r];if(s=typeof u,"string"===s&&(o=no.exec(u))&&(u=(o[1]+1)*o[2]+parseFloat(i.css(n,r)),s="number"),!(null==u||"number"===s&&isNaN(u)||("number"!==s||i.cssNumber[h]||(u+="px"),i.support.clearCloneStyle||""!==u||0!==r.indexOf("background")||(c[r]="inherit"),e&&"set"in e&&(u=e.set(n,u,f))===t)))try{c[r]=u}catch(l){}}},css:function(n,r,u,f){var h,e,o,s=i.camelCase(r);return r=i.cssProps[s]||(i.cssProps[s]=fu(n.style,s)),o=i.cssHooks[r]||i.cssHooks[s],o&&"get"in o&&(e=o.get(n,!0,u)),e===t&&(e=y(n,r,f)),"normal"===e&&r in ru&&(e=ru[r]),""===u||u?(h=parseFloat(e),u===!0||i.isNumeric(h)?h||0:e):e},swap:function(n,t,i,r){var f,u,e={};for(u in t)e[u]=n.style[u],n.style[u]=t[u];f=i.apply(n,r||[]);for(u in t)n.style[u]=e[u];return f}}),n.getComputedStyle?(v=function(t){return n.getComputedStyle(t,null)},y=function(n,r,u){var s,h,c,o=u||v(n),e=o?o.getPropertyValue(r)||o[r]:t,f=n.style;return o&&(""!==e||i.contains(n.ownerDocument,n)||(e=i.style(n,r)),ct.test(e)&&tu.test(r)&&(s=f.width,h=f.minWidth,c=f.maxWidth,f.minWidth=f.maxWidth=f.width=e,e=o.width,f.width=s,f.minWidth=h,f.maxWidth=c)),e}):r.documentElement.currentStyle&&(v=function(n){return n.currentStyle},y=function(n,i,r){var s,e,o,h=r||v(n),u=h?h[i]:t,f=n.style;return null==u&&f&&f[i]&&(u=f[i]),ct.test(u)&&!ke.test(i)&&(s=f.left,e=n.runtimeStyle,o=e&&e.left,o&&(e.left=n.currentStyle.left),f.left="fontSize"===i?"1em":u,u=f.pixelLeft+"px",f.left=s,o&&(e.left=o)),""===u?"auto":u}),i.each(["height","width"],function(n,r){i.cssHooks[r]={get:function(n,u,f){return u?0===n.offsetWidth&&de.test(i.css(n,"display"))?i.swap(n,to,function(){return hu(n,r,f)}):hu(n,r,f):t},set:function(n,t,u){var f=u&&v(n);return ou(n,t,u?su(n,r,u,i.support.boxSizing&&"border-box"===i.css(n,"boxSizing",!1,f),f):0)}}}),i.support.opacity||(i.cssHooks.opacity={get:function(n,t){return be.test((t&&n.currentStyle?n.currentStyle.filter:n.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(n,t){var r=n.style,u=n.currentStyle,e=i.isNumeric(t)?"alpha(opacity="+100*t+")":"",f=u&&u.filter||r.filter||"";r.zoom=1,(t>=1||""===t)&&""===i.trim(f.replace(hi,""))&&r.removeAttribute&&(r.removeAttribute("filter"),""===t||u&&!u.filter)||(r.filter=hi.test(f)?f.replace(hi,e):f+" "+e)}}),i(function(){i.support.reliableMarginRight||(i.cssHooks.marginRight={get:function(n,r){return r?i.swap(n,{display:"inline-block"},y,[n,"marginRight"]):t}}),!i.support.pixelPosition&&i.fn.position&&i.each(["top","left"],function(n,r){i.cssHooks[r]={get:function(n,u){return u?(u=y(n,r),ct.test(u)?i(n).position()[r]+"px":u):t}}})}),i.expr&&i.expr.filters&&(i.expr.filters.hidden=function(n){return 0>=n.offsetWidth&&0>=n.offsetHeight||!i.support.reliableHiddenOffsets&&"none"===(n.style&&n.style.display||i.css(n,"display"))},i.expr.filters.visible=function(n){return!i.expr.filters.hidden(n)}),i.each({margin:"",padding:"",border:"Width"},function(n,t){i.cssHooks[n+t]={expand:function(i){for(var r=0,f={},u="string"==typeof i?i.split(" "):[i];4>r;r++)f[n+p[r]+t]=u[r]||u[r-2]||u[0];return f}},tu.test(n)||(i.cssHooks[n+t].set=ou)});var io=/%20/g,ro=/\[\]$/,au=/\r?\n/g,uo=/^(?:submit|button|image|reset|file)$/i,fo=/^(?:input|select|textarea|keygen)/i;i.fn.extend({serialize:function(){return i.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var n=i.prop(this,"elements");return n?i.makeArray(n):this}).filter(function(){var n=this.type;return this.name&&!i(this).is(":disabled")&&fo.test(this.nodeName)&&!uo.test(n)&&(this.checked||!ei.test(n))}).map(function(n,t){var r=i(this).val();return null==r?null:i.isArray(r)?i.map(r,function(n){return{name:t.name,value:n.replace(au,"\r\n")}}):{name:t.name,value:r.replace(au,"\r\n")}}).get()}}),i.param=function(n,r){var u,f=[],e=function(n,t){t=i.isFunction(t)?t():null==t?"":t,f[f.length]=encodeURIComponent(n)+"="+encodeURIComponent(t)};if(r===t&&(r=i.ajaxSettings&&i.ajaxSettings.traditional),i.isArray(n)||n.jquery&&!i.isPlainObject(n))i.each(n,function(){e(this.name,this.value)});else for(u in n)ci(u,n[u],r,e);return f.join("&").replace(io,"+")},i.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 contextmenu".split(" "),function(n,t){i.fn[t]=function(n,i){return arguments.length>0?this.on(t,null,n,i):this.trigger(t)}}),i.fn.hover=function(n,t){return this.mouseenter(n).mouseleave(t||n)};var w,c,li=i.now(),ai=/\?/,eo=/#.*$/,vu=/([?&])_=[^&]*/,oo=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,so=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,ho=/^(?:GET|HEAD)$/,co=/^\/\//,yu=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,pu=i.fn.load,wu={},vi={},bu="*/".concat("*");try{c=ff.href}catch(ns){c=r.createElement("a"),c.href="",c=c.href}w=yu.exec(c.toLowerCase())||[],i.fn.load=function(n,r,u){if("string"!=typeof n&&pu)return pu.apply(this,arguments);var f,s,h,e=this,o=n.indexOf(" ");return o>=0&&(f=n.slice(o,n.length),n=n.slice(0,o)),i.isFunction(r)?(u=r,r=t):r&&"object"==typeof r&&(h="POST"),e.length>0&&i.ajax({url:n,type:h,dataType:"html",data:r}).done(function(n){s=arguments,e.html(f?i("<div>").append(i.parseHTML(n)).find(f):n)}).complete(u&&function(n,t){e.each(u,s||[n.responseText,t,n])}),this},i.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(n,t){i.fn[t]=function(n){return this.on(t,n)}}),i.each(["get","post"],function(n,r){i[r]=function(n,u,f,e){return i.isFunction(u)&&(e=e||f,f=u,u=t),i.ajax({url:n,type:r,dataType:e,data:u,success:f})}}),i.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:c,type:"GET",isLocal:so.test(w[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":bu,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":n.String,"text html":!0,"text json":i.parseJSON,"text xml":i.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(n,t){return t?yi(yi(n,i.ajaxSettings),t):yi(i.ajaxSettings,n)},ajaxPrefilter:ku(wu),ajaxTransport:ku(vi),ajax:function(n,r){function k(n,r,s,c){var l,k,w,rt,p,a=r;2!==o&&(o=2,g&&clearTimeout(g),y=t,d=c||"",f.readyState=n>0?4:0,s&&(rt=lo(u,f,s)),n>=200&&300>n||304===n?(u.ifModified&&(p=f.getResponseHeader("Last-Modified"),p&&(i.lastModified[e]=p),p=f.getResponseHeader("etag"),p&&(i.etag[e]=p)),204===n?(l=!0,a="nocontent"):304===n?(l=!0,a="notmodified"):(l=ao(u,rt),a=l.state,k=l.data,w=l.error,l=!w)):(w=a,(n||!a)&&(a="error",0>n&&(n=0))),f.status=n,f.statusText=(r||a)+"",l?tt.resolveWith(h,[k,a,f]):tt.rejectWith(h,[f,a,w]),f.statusCode(b),b=t,v&&nt.trigger(l?"ajaxSuccess":"ajaxError",[f,u,l?k:w]),it.fireWith(h,[f,a]),v&&(nt.trigger("ajaxComplete",[f,u]),--i.active||i.event.trigger("ajaxStop")))}"object"==typeof n&&(r=n,n=t),r=r||{};var l,a,e,d,g,v,y,p,u=i.ajaxSetup({},r),h=u.context||u,nt=u.context&&(h.nodeType||h.jquery)?i(h):i.event,tt=i.Deferred(),it=i.Callbacks("once memory"),b=u.statusCode||{},rt={},ut={},o=0,ft="canceled",f={readyState:0,getResponseHeader:function(n){var t;if(2===o){if(!p)for(p={};t=oo.exec(d);)p[t[1].toLowerCase()]=t[2];t=p[n.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===o?d:null},setRequestHeader:function(n,t){var i=n.toLowerCase();return o||(n=ut[i]=ut[i]||n,rt[n]=t),this},overrideMimeType:function(n){return o||(u.mimeType=n),this},statusCode:function(n){var t;if(n)if(2>o)for(t in n)b[t]=[b[t],n[t]];else f.always(n[f.status]);return this},abort:function(n){var t=n||ft;return y&&y.abort(t),k(0,t),this}};if(tt.promise(f).complete=it.add,f.success=f.done,f.error=f.fail,u.url=((n||u.url||c)+"").replace(eo,"").replace(co,w[1]+"//"),u.type=r.method||r.type||u.method||u.type,u.dataTypes=i.trim(u.dataType||"*").toLowerCase().match(s)||[""],null==u.crossDomain&&(l=yu.exec(u.url.toLowerCase()),u.crossDomain=!(!l||l[1]===w[1]&&l[2]===w[2]&&(l[3]||("http:"===l[1]?80:443))==(w[3]||("http:"===w[1]?80:443)))),u.data&&u.processData&&"string"!=typeof u.data&&(u.data=i.param(u.data,u.traditional)),du(wu,u,r,f),2===o)return f;v=u.global,v&&0==i.active++&&i.event.trigger("ajaxStart"),u.type=u.type.toUpperCase(),u.hasContent=!ho.test(u.type),e=u.url,u.hasContent||(u.data&&(e=u.url+=(ai.test(e)?"&":"?")+u.data,delete u.data),u.cache===!1&&(u.url=vu.test(e)?e.replace(vu,"$1_="+li++):e+(ai.test(e)?"&":"?")+"_="+li++)),u.ifModified&&(i.lastModified[e]&&f.setRequestHeader("If-Modified-Since",i.lastModified[e]),i.etag[e]&&f.setRequestHeader("If-None-Match",i.etag[e])),(u.data&&u.hasContent&&u.contentType!==!1||r.contentType)&&f.setRequestHeader("Content-Type",u.contentType),f.setRequestHeader("Accept",u.dataTypes[0]&&u.accepts[u.dataTypes[0]]?u.accepts[u.dataTypes[0]]+("*"!==u.dataTypes[0]?", "+bu+"; q=0.01":""):u.accepts["*"]);for(a in u.headers)f.setRequestHeader(a,u.headers[a]);if(u.beforeSend&&(u.beforeSend.call(h,f,u)===!1||2===o))return f.abort();ft="abort";for(a in{success:1,error:1,complete:1})f[a](u[a]);if(y=du(vi,u,r,f)){f.readyState=1,v&&nt.trigger("ajaxSend",[f,u]),u.async&&u.timeout>0&&(g=setTimeout(function(){f.abort("timeout")},u.timeout));try{o=1,y.send(rt,k)}catch(et){if(!(2>o))throw et;k(-1,et)}}else k(-1,"No Transport");return f},getScript:function(n,r){return i.get(n,t,r,"script")},getJSON:function(n,t,r){return i.get(n,t,r,"json")}}),i.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(n){return i.globalEval(n),n}}}),i.ajaxPrefilter("script",function(n){n.cache===t&&(n.cache=!1),n.crossDomain&&(n.type="GET",n.global=!1)}),i.ajaxTransport("script",function(n){if(n.crossDomain){var u,f=r.head||i("head")[0]||r.documentElement;return{send:function(t,i){u=r.createElement("script"),u.async=!0,n.scriptCharset&&(u.charset=n.scriptCharset),u.src=n.url,u.onload=u.onreadystatechange=function(n,t){(t||!u.readyState||/loaded|complete/.test(u.readyState))&&(u.onload=u.onreadystatechange=null,u.parentNode&&u.parentNode.removeChild(u),u=null,t||i(200,"success"))},f.insertBefore(u,f.firstChild)},abort:function(){u&&u.onload(t,!0)}}}}),pi=[],lt=/(=)\?(?=&|$)|\?\?/,i.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var n=pi.pop()||i.expando+"_"+li++;return this[n]=!0,n}}),i.ajaxPrefilter("json jsonp",function(r,u,f){var e,s,o,h=r.jsonp!==!1&&(lt.test(r.url)?"url":"string"==typeof r.data&&!(r.contentType||"").indexOf("application/x-www-form-urlencoded")&&lt.test(r.data)&&"data");return h||"jsonp"===r.dataTypes[0]?(e=r.jsonpCallback=i.isFunction(r.jsonpCallback)?r.jsonpCallback():r.jsonpCallback,h?r[h]=r[h].replace(lt,"$1"+e):r.jsonp!==!1&&(r.url+=(ai.test(r.url)?"&":"?")+r.jsonp+"="+e),r.converters["script json"]=function(){return o||i.error(e+" was not called"),o[0]},r.dataTypes[0]="json",s=n[e],n[e]=function(){o=arguments},f.always(function(){n[e]=s,r[e]&&(r.jsonpCallback=u.jsonpCallback,pi.push(e)),o&&i.isFunction(s)&&s(o[0]),o=s=t}),"script"):t}),gu=0,at=n.ActiveXObject&&function(){var n;for(n in g)g[n](t,!0)},i.ajaxSettings.xhr=n.ActiveXObject?function(){return!this.isLocal&&nf()||vo()}:nf,nt=i.ajaxSettings.xhr(),i.support.cors=!!nt&&"withCredentials"in nt,nt=i.support.ajax=!!nt,nt&&i.ajaxTransport(function(r){if(!r.crossDomain||i.support.cors){var u;return{send:function(f,e){var h,s,o=r.xhr();if(r.username?o.open(r.type,r.url,r.async,r.username,r.password):o.open(r.type,r.url,r.async),r.xhrFields)for(s in r.xhrFields)o[s]=r.xhrFields[s];r.mimeType&&o.overrideMimeType&&o.overrideMimeType(r.mimeType),r.crossDomain||f["X-Requested-With"]||(f["X-Requested-With"]="XMLHttpRequest");try{for(s in f)o.setRequestHeader(s,f[s])}catch(c){}o.send(r.hasContent&&r.data||null),u=function(n,f){var s,a,l,c;try{if(u&&(f||4===o.readyState))if(u=t,h&&(o.onreadystatechange=i.noop,at&&delete g[h]),f)4!==o.readyState&&o.abort();else{c={},s=o.status,a=o.getAllResponseHeaders(),"string"==typeof o.responseText&&(c.text=o.responseText);try{l=o.statusText}catch(v){l=""}s||!r.isLocal||r.crossDomain?1223===s&&(s=204):s=c.text?200:404}}catch(y){f||e(-1,y)}c&&e(s,l,c,a)},r.async?4===o.readyState?setTimeout(u):(h=++gu,at&&(g||(g={},i(n).unload(at)),g[h]=u),o.onreadystatechange=u):u()},abort:function(){u&&u(t,!0)}}}});var tt,vt,yo=/^(?:toggle|show|hide)$/,po=RegExp("^(?:([+-])=|)("+st+")([a-z%]*)$","i"),wo=/queueHooks$/,yt=[go],ft={"*":[function(n,t){var o,s,r=this.createTween(n,t),e=po.exec(t),h=r.cur(),u=+h||0,f=1,c=20;if(e){if(o=+e[2],s=e[3]||(i.cssNumber[n]?"":"px"),"px"!==s&&u){u=i.css(r.elem,n,!0)||o||1;do f=f||".5",u/=f,i.style(r.elem,n,u+s);while(f!==(f=r.cur()/h)&&1!==f&&--c)}r.unit=s,r.start=u,r.end=e[1]?u+(e[1]+1)*o:o}return r}]};i.Animation=i.extend(rf,{tweener:function(n,t){i.isFunction(n)?(t=n,n=["*"]):n=n.split(" ");for(var r,u=0,f=n.length;f>u;u++)r=n[u],ft[r]=ft[r]||[],ft[r].unshift(t)},prefilter:function(n,t){t?yt.unshift(n):yt.push(n)}}),i.Tween=f,f.prototype={constructor:f,init:function(n,t,r,u,f,e){this.elem=n,this.prop=r,this.easing=f||"swing",this.options=t,this.start=this.now=this.cur(),this.end=u,this.unit=e||(i.cssNumber[r]?"":"px")},cur:function(){var n=f.propHooks[this.prop];return n&&n.get?n.get(this):f.propHooks._default.get(this)},run:function(n){var r,t=f.propHooks[this.prop];return this.pos=r=this.options.duration?i.easing[this.easing](n,this.options.duration*n,0,1,this.options.duration):n,this.now=(this.end-this.start)*r+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),t&&t.set?t.set(this):f.propHooks._default.set(this),this}},f.prototype.init.prototype=f.prototype,f.propHooks={_default:{get:function(n){var t;return null==n.elem[n.prop]||n.elem.style&&null!=n.elem.style[n.prop]?(t=i.css(n.elem,n.prop,""),t&&"auto"!==t?t:0):n.elem[n.prop]},set:function(n){i.fx.step[n.prop]?i.fx.step[n.prop](n):n.elem.style&&(null!=n.elem.style[i.cssProps[n.prop]]||i.cssHooks[n.prop])?i.style(n.elem,n.prop,n.now+n.unit):n.elem[n.prop]=n.now}}},f.propHooks.scrollTop=f.propHooks.scrollLeft={set:function(n){n.elem.nodeType&&n.elem.parentNode&&(n.elem[n.prop]=n.now)}},i.each(["toggle","show","hide"],function(n,t){var r=i.fn[t];i.fn[t]=function(n,i,u){return null==n||"boolean"==typeof n?r.apply(this,arguments):this.animate(pt(t,!0),n,i,u)}}),i.fn.extend({fadeTo:function(n,t,i,r){return this.filter(ut).css("opacity",0).show().end().animate({opacity:t},n,i,r)},animate:function(n,t,r,u){var o=i.isEmptyObject(n),e=i.speed(t,r,u),f=function(){var t=rf(this,i.extend({},n),e);f.finish=function(){t.stop(!0)},(o||i._data(this,"finish"))&&t.stop(!0)};return f.finish=f,o||e.queue===!1?this.each(f):this.queue(e.queue,f)},stop:function(n,r,u){var f=function(n){var t=n.stop;delete n.stop,t(u)};return"string"!=typeof n&&(u=r,r=n,n=t),r&&n!==!1&&this.queue(n||"fx",[]),this.each(function(){var o=!0,t=null!=n&&n+"queueHooks",e=i.timers,r=i._data(this);if(t)r[t]&&r[t].stop&&f(r[t]);else for(t in r)r[t]&&r[t].stop&&wo.test(t)&&f(r[t]);for(t=e.length;t--;)e[t].elem!==this||null!=n&&e[t].queue!==n||(e[t].anim.stop(u),o=!1,e.splice(t,1));(o||!u)&&i.dequeue(this,n)})},finish:function(n){return n!==!1&&(n=n||"fx"),this.each(function(){var t,f=i._data(this),r=f[n+"queue"],e=f[n+"queueHooks"],u=i.timers,o=r?r.length:0;for(f.finish=!0,i.queue(this,n,[]),e&&e.cur&&e.cur.finish&&e.cur.finish.call(this),t=u.length;t--;)u[t].elem===this&&u[t].queue===n&&(u[t].anim.stop(!0),u.splice(t,1));for(t=0;o>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete f.finish})}}),i.each({slideDown:pt("show"),slideUp:pt("hide"),slideToggle:pt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(n,t){i.fn[n]=function(n,i,r){return this.animate(t,n,i,r)}}),i.speed=function(n,t,r){var u=n&&"object"==typeof n?i.extend({},n):{complete:r||!r&&t||i.isFunction(n)&&n,duration:n,easing:r&&t||t&&!i.isFunction(t)&&t};return u.duration=i.fx.off?0:"number"==typeof u.duration?u.duration:u.duration in i.fx.speeds?i.fx.speeds[u.duration]:i.fx.speeds._default,(null==u.queue||u.queue===!0)&&(u.queue="fx"),u.old=u.complete,u.complete=function(){i.isFunction(u.old)&&u.old.call(this),u.queue&&i.dequeue(this,u.queue)},u},i.easing={linear:function(n){return n},swing:function(n){return.5-Math.cos(n*Math.PI)/2}},i.timers=[],i.fx=f.prototype.init,i.fx.tick=function(){var u,n=i.timers,r=0;for(tt=i.now();n.length>r;r++)u=n[r],u()||n[r]!==u||n.splice(r--,1);n.length||i.fx.stop(),tt=t},i.fx.timer=function(n){n()&&i.timers.push(n)&&i.fx.start()},i.fx.interval=13,i.fx.start=function(){vt||(vt=setInterval(i.fx.tick,i.fx.interval))},i.fx.stop=function(){clearInterval(vt),vt=null},i.fx.speeds={slow:600,fast:200,_default:400},i.fx.step={},i.expr&&i.expr.filters&&(i.expr.filters.animated=function(n){return i.grep(i.timers,function(t){return n===t.elem}).length}),i.fn.offset=function(n){if(arguments.length)return n===t?this:this.each(function(t){i.offset.setOffset(this,n,t)});var r,e,f={top:0,left:0},u=this[0],s=u&&u.ownerDocument;if(s)return r=s.documentElement,i.contains(r,u)?(typeof u.getBoundingClientRect!==o&&(f=u.getBoundingClientRect()),e=uf(s),{top:f.top+(e.pageYOffset||r.scrollTop)-(r.clientTop||0),left:f.left+(e.pageXOffset||r.scrollLeft)-(r.clientLeft||0)}):f},i.offset={setOffset:function(n,t,r){var f=i.css(n,"position");"static"===f&&(n.style.position="relative");var e=i(n),o=e.offset(),l=i.css(n,"top"),a=i.css(n,"left"),v=("absolute"===f||"fixed"===f)&&i.inArray("auto",[l,a])>-1,u={},s={},h,c;v?(s=e.position(),h=s.top,c=s.left):(h=parseFloat(l)||0,c=parseFloat(a)||0),i.isFunction(t)&&(t=t.call(n,r,o)),null!=t.top&&(u.top=t.top-o.top+h),null!=t.left&&(u.left=t.left-o.left+c),"using"in t?t.using.call(n,u):e.css(u)}},i.fn.extend({position:function(){if(this[0]){var n,r,t={top:0,left:0},u=this[0];return"fixed"===i.css(u,"position")?r=u.getBoundingClientRect():(n=this.offsetParent(),r=this.offset(),i.nodeName(n[0],"html")||(t=n.offset()),t.top+=i.css(n[0],"borderTopWidth",!0),t.left+=i.css(n[0],"borderLeftWidth",!0)),{top:r.top-t.top-i.css(u,"marginTop",!0),left:r.left-t.left-i.css(u,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var n=this.offsetParent||r.documentElement;n&&!i.nodeName(n,"html")&&"static"===i.css(n,"position");)n=n.offsetParent;return n||r.documentElement})}}),i.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(n,r){var u=/Y/.test(r);i.fn[n]=function(f){return i.access(this,function(n,f,e){var o=uf(n);return e===t?o?r in o?o[r]:o.document.documentElement[f]:n[f]:(o?o.scrollTo(u?i(o).scrollLeft():e,u?e:i(o).scrollTop()):n[f]=e,t)},n,f,arguments.length,null)}}),i.each({Height:"height",Width:"width"},function(n,r){i.each({padding:"inner"+n,content:r,"":"outer"+n},function(u,f){i.fn[f]=function(f,e){var o=arguments.length&&(u||"boolean"!=typeof f),s=u||(f===!0||e===!0?"margin":"border");return i.access(this,function(r,u,f){var e;return i.isWindow(r)?r.document.documentElement["client"+n]:9===r.nodeType?(e=r.documentElement,Math.max(r.body["scroll"+n],e["scroll"+n],r.body["offset"+n],e["offset"+n],e["client"+n])):f===t?i.css(r,u,s):i.style(r,u,f,s)},r,o?f:t,o,null)}})}),n.jQuery=n.$=i,"function"==typeof define&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return i})})(window),function(n){function r(t){var i=t||window.event,e=[].slice.call(arguments,1),r=0,o=!0,f=0,u=0;return t=n.event.fix(i),t.type="mousewheel",i.wheelDelta&&(r=i.wheelDelta/120),i.detail&&(r=-i.detail/3),u=r,i.axis!==undefined&&i.axis===i.HORIZONTAL_AXIS&&(u=0,f=-1*r),i.wheelDeltaY!==undefined&&(u=i.wheelDeltaY/120),i.wheelDeltaX!==undefined&&(f=i.wheelDeltaX/-120),e.unshift(t,r,f,u),(n.event.dispatch||n.event.handle).apply(this,e)}var t=["DOMMouseScroll","mousewheel"],i;if(n.event.fixHooks)for(i=t.length;i;)n.event.fixHooks[t[--i]]=n.event.mouseHooks;n.event.special.mousewheel={setup:function(){if(this.addEventListener)for(var n=t.length;n;)this.addEventListener(t[--n],r,!1);else this.onmousewheel=r},teardown:function(){if(this.removeEventListener)for(var n=t.length;n;)this.removeEventListener(t[--n],r,!1);else this.onmousewheel=null}},n.fn.extend({mousewheel:function(n){return n?this.bind("mousewheel",n):this.trigger("mousewheel")},unmousewheel:function(n){return this.unbind("mousewheel",n)}})}(jQuery),JSON||(JSON={}),function(){"use strict";function i(n){return n<10?"0"+n:n}function f(n){return o.lastIndex=0,o.test(n)?'"'+n.replace(o,function(n){var t=s[n];return typeof t=="string"?t:"\\u"+("0000"+n.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+n+'"'}function r(i,e){var s,l,h,a,v=n,c,o=e[i];o&&typeof o=="object"&&typeof o.toJSON=="function"&&(o=o.toJSON(i)),typeof t=="function"&&(o=t.call(e,i,o));switch(typeof o){case"string":return f(o);case"number":return isFinite(o)?String(o):"null";case"boolean":case"null":return String(o);case"object":if(!o)return"null";if(n+=u,c=[],Object.prototype.toString.apply(o)==="[object Array]"){for(a=o.length,s=0;s<a;s+=1)c[s]=r(s,o)||"null";return h=c.length===0?"[]":n?"[\n"+n+c.join(",\n"+n)+"\n"+v+"]":"["+c.join(",")+"]",n=v,h}if(t&&typeof t=="object")for(a=t.length,s=0;s<a;s+=1)typeof t[s]=="string"&&(l=t[s],h=r(l,o),h&&c.push(f(l)+(n?": ":":")+h));else for(l in o)Object.prototype.hasOwnProperty.call(o,l)&&(h=r(l,o),h&&c.push(f(l)+(n?": ":":")+h));return h=c.length===0?"{}":n?"{\n"+n+c.join(",\n"+n)+"\n"+v+"}":"{"+c.join(",")+"}",n=v,h}}typeof Date.prototype.toJSON!="function"&&(Date.prototype.toJSON=function(){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+i(this.getUTCMonth()+1)+"-"+i(this.getUTCDate())+"T"+i(this.getUTCHours())+":"+i(this.getUTCMinutes())+":"+i(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()});var e=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,o=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,n,u,s={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},t;typeof JSON.stringify!="function"&&(JSON.stringify=function(i,f,e){var o;if(n="",u="",typeof e=="number")for(o=0;o<e;o+=1)u+=" ";else typeof e=="string"&&(u=e);if(t=f,f&&typeof f!="function"&&(typeof f!="object"||typeof f.length!="number"))throw new Error("JSON.stringify");return r("",{"":i})}),typeof JSON.parse!="function"&&(JSON.parse=function(n,t){function r(n,i){var f,e,u=n[i];if(u&&typeof u=="object")for(f in u)Object.prototype.hasOwnProperty.call(u,f)&&(e=r(u,f),e!==undefined?u[f]=e:delete u[f]);return t.call(n,i,u)}var i;if(n=String(n),e.lastIndex=0,e.test(n)&&(n=n.replace(e,function(n){return"\\u"+("0000"+n.charCodeAt(0).toString(16)).slice(-4)})),/^[\],:{}\s]*$/.test(n.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return i=eval("("+n+")"),typeof t=="function"?r({"":i},""):i;throw new SyntaxError("JSON.parse");})}(),!function(n){"use strict";function r(){n(".dropdown-backdrop").remove(),n(i).each(function(){u(n(this)).removeClass("open")})}function u(t){var i=t.attr("data-target"),r;return i||(i=t.attr("href"),i=i&&/#/.test(i)&&i.replace(/.*(?=#[^\s]*$)/,"")),r=i&&n(i),r&&r.length||(r=t.parent()),r}var i="[data-toggle=dropdown]",t=function(t){var i=n(t).on("click.dropdown.data-api",this.toggle);n("html").on("click.dropdown.data-api",function(){i.parent().removeClass("open")})},f;t.prototype={constructor:t,toggle:function(){var i=n(this),f,e;if(!i.is(".disabled, :disabled")){if(f=u(i),e=f.hasClass("open"),r(),!e){if("ontouchstart"in document.documentElement)n('<div class="dropdown-backdrop"/>').insertBefore(n(this)).on("click",r);f.toggleClass("open")}return i.focus(),!1}},keydown:function(t){var e,f,h,o,s,r;if(/(38|40|27)/.test(t.keyCode)&&(e=n(this),t.preventDefault(),t.stopPropagation(),!e.is(".disabled, :disabled"))){if(o=u(e),s=o.hasClass("open"),!s||s&&t.keyCode==27)return t.which==27&&o.find(i).focus(),e.click();(f=n("[role=menu] li:not(.divider):visible a",o),f.length)&&(r=f.index(f.filter(":focus")),t.keyCode==38&&r>0&&r--,t.keyCode==40&&r<f.length-1&&r++,~r||(r=0),f.eq(r).focus())}}},f=n.fn.dropdown,n.fn.dropdown=function(i){return this.each(function(){var r=n(this),u=r.data("dropdown");u||r.data("dropdown",u=new t(this)),typeof i=="string"&&u[i].call(r)})},n.fn.dropdown.Constructor=t,n.fn.dropdown.noConflict=function(){return n.fn.dropdown=f,this};n(document).on("click.dropdown.data-api",r).on("click.dropdown.data-api",".dropdown form",function(n){n.stopPropagation()}).on("click.dropdown.data-api",i,t.prototype.toggle).on("keydown.dropdown.data-api",i+", [role=menu]",t.prototype.keydown)}(window.jQuery),!function(n){"use strict";var t=function(t,i){this.$element=n(t),this.options=n.extend({},n.fn.typeahead.defaults,i),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highlighter,this.updater=this.options.updater||this.updater,this.source=this.options.source,this.$menu=n(this.options.menu),this.shown=!1,this.select=this.options.select||this.select,this.render=this.options.render||this.highlighter,this.mouseleave=this.options.mouseleave,this.listen()},i;t.prototype={constructor:t,select:function(){var n=this.$menu.find(".active").attr("data-value"),t;return this.form=this.$menu.parent("form").get(0),n==undefined&&(n=this.query),t="/Search/"+n.replace(/ /g,"-"),location.href=t,this.hide()},updater:function(n){return n},show:function(){var t=n.extend({},this.$element.position(),{height:this.$element[0].offsetHeight});return this.$menu.insertAfter(this.$element).css({top:t.top+t.height,left:t.left}).show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(){var i;return(this.query=this.$element.val(),!this.query||this.query.length<this.options.minLength)?this.shown?this.hide():this:(i=n.isFunction(this.source)?this.source(this.query,n.proxy(this.process,this)):this.source,i?this.process(i):this)},process:function(t){var i=this;return(t=n.grep(t,function(n){return i.matcher(n)}),t=this.sorter(t),!t.length)?this.shown?this.hide():this:this.render(t.slice(0,this.options.items)).show()},matcher:function(n){return~n.toLowerCase().indexOf(this.query.toLowerCase())},sorter:function(n){for(var i=[],r=[],u=[],t;t=n.shift();)t.toLowerCase().indexOf(this.query.toLowerCase())?~t.indexOf(this.query)?r.push(t):u.push(t):i.push(t);return i.concat(r,u)},highlighter:function(n){var t=this.query.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&");return n.replace(new RegExp("("+t+")","ig"),function(n,t){return"<strong>"+t+"<\/strong>"})},render:function(t){var i=this;return t=n(t).map(function(t,r){return t=n(i.options.item).attr("data-value",r),t.find("a").html(i.highlighter(r)),t[0]}),t.first().addClass("active"),this.$menu.html(t),this},next:function(){var r=this.$menu.find(".active").removeClass("active"),i=r.next();i.length||(i=n(this.$menu.find("li")[0])),i.addClass("active")},prev:function(){var i=this.$menu.find(".active").removeClass("active"),t=i.prev();t.length||(t=this.$menu.find("li").last()),t.addClass("active")},listen:function(){this.$element.on("focus",n.proxy(this.focus,this)).on("blur",n.proxy(this.blur,this)).on("keypress",n.proxy(this.keypress,this)).on("keyup",n.proxy(this.keyup,this));if(this.eventSupported("keydown"))this.$element.on("keydown",n.proxy(this.keydown,this));this.$menu.on("click",n.proxy(this.click,this)).on("mouseenter","li",n.proxy(this.mouseenter,this)).on("mouseleave","li",n.proxy(this.mouseleave,this))},eventSupported:function(n){var t=n in this.$element;return t||(this.$element.setAttribute(n,"return;"),t=typeof this.$element[n]=="function"),t},move:function(n){if(this.shown){switch(n.keyCode){case 9:case 13:case 27:n.preventDefault();break;case 38:n.preventDefault(),this.prev();break;case 40:n.preventDefault(),this.next()}n.stopPropagation()}},keydown:function(t){this.suppressKeyPressRepeat=~n.inArray(t.keyCode,[40,38,9,13,27]),this.move(t)},keypress:function(n){this.suppressKeyPressRepeat||this.move(n)},keyup:function(n){switch(n.keyCode){case 40:case 38:case 16:case 17:case 18:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:if(!this.shown)return;this.hide();break;default:this.lookup()}n.stopPropagation(),n.preventDefault()},focus:function(){this.focused=!0},blur:function(){this.focused=!1,!this.mousedover&&this.shown&&this.hide()},click:function(n){n.stopPropagation(),n.preventDefault(),this.select(),this.$element.focus()},mouseenter:function(t){this.mousedover=!0,this.$menu.find(".active").removeClass("active"),n(t.currentTarget).addClass("active")},mouseleave:function(){this.mousedover=!1,!this.focused&&this.shown&&this.hide()}},i=n.fn.typeahead,n.fn.typeahead=function(i){return this.each(function(){var u=n(this),r=u.data("typeahead"),f=typeof i=="object"&&i;r||u.data("typeahead",r=new t(this,f)),typeof i=="string"&&r[i]()})},n.fn.typeahead.defaults={source:[],items:8,menu:'<ul class="typeahead dropdown-menu"><\/ul>',item:'<li><a href="#"><\/a><\/li>',minLength:1},n.fn.typeahead.Constructor=t,n.fn.typeahead.noConflict=function(){return n.fn.typeahead=i,this};n(document).on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(){var i=n(this);i.data("typeahead")||i.typeahead(i.data())})}(window.jQuery),!function(n){"use strict";var t=function(n,t){this.init("tooltip",n,t)},i;t.prototype={constructor:t,init:function(t,i,r){var o,s,f,u,e;for(this.type=t,this.$element=n(i),this.options=this.getOptions(r),this.enabled=!0,f=this.options.trigger.split(" "),e=f.length;e--;)if(u=f[e],u=="click")this.$element.on("click."+this.type,this.options.selector,n.proxy(this.toggle,this));else if(u!="manual"){o=u=="hover"?"mouseenter":"focus",s=u=="hover"?"mouseleave":"blur";this.$element.on(o+"."+this.type,this.options.selector,n.proxy(this.enter,this));this.$element.on(s+"."+this.type,this.options.selector,n.proxy(this.leave,this))}this.options.selector?this._options=n.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(t){return t=n.extend({},n.fn[this.type].defaults,this.$element.data(),t),t.delay&&typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),t},enter:function(t){var u=n.fn[this.type].defaults,r={},i;if(this._options&&n.each(this._options,function(n,t){u[n]!=t&&(r[n]=t)},this),i=n(t.currentTarget)[this.type](r).data(this.type),!i.options.delay||!i.options.delay.show)return i.show();clearTimeout(this.timeout),i.hoverState="in",this.timeout=setTimeout(function(){i.hoverState=="in"&&i.show()},i.options.delay.show)},leave:function(t){var i=n(t.currentTarget)[this.type](this._options).data(this.type);if(this.timeout&&clearTimeout(this.timeout),!i.options.delay||!i.options.delay.hide)return i.hide();i.hoverState="out",this.timeout=setTimeout(function(){i.hoverState=="out"&&i.hide()},i.options.delay.hide)},show:function(){var i,t,u,f,e,r,o=n.Event("show");if(this.hasContent()&&this.enabled){if(this.$element.trigger(o),o.isDefaultPrevented())return;i=this.tip(),this.setContent(),this.options.animation&&i.addClass("fade"),e=typeof this.options.placement=="function"?this.options.placement.call(this,i[0],this.$element[0]):this.options.placement,i.detach().css({top:0,left:0,display:"block"}),this.options.container?i.appendTo(this.options.container):i.insertAfter(this.$element),t=this.getPosition(),u=i[0].offsetWidth,f=i[0].offsetHeight;switch(e){case"bottom":r={top:t.top+t.height,left:t.left+t.width/2-u/2};break;case"top":r={top:t.top-f,left:t.left+t.width/2-u/2};break;case"left":r={top:t.top+t.height/2-f/2,left:t.left-u};break;case"right":r={top:t.top+t.height/2-f/2,left:t.left+t.width}}this.applyPlacement(r,e),this.$element.trigger("shown")}},applyPlacement:function(n,t){var i=this.tip(),s=i[0].offsetWidth,f=i[0].offsetHeight,u,r,e,o;i.offset(n).addClass(t).addClass("in"),u=i[0].offsetWidth,r=i[0].offsetHeight,t=="top"&&r!=f&&(n.top=n.top+f-r,o=!0),t=="bottom"||t=="top"?(e=0,n.left<0&&(e=n.left*-2,n.left=0,i.offset(n),u=i[0].offsetWidth,r=i[0].offsetHeight),this.replaceArrow(e-s+u,u,"left")):this.replaceArrow(r-f,r,"top"),o&&i.offset(n)},replaceArrow:function(n,t,i){this.arrow().css(i,n?50*(1-n/t)+"%":"")},setContent:function(){var n=this.tip(),t=this.getTitle();n.find(".tooltip-inner")[this.options.html?"html":"text"](t),n.removeClass("fade in top bottom left right")},hide:function(){function r(){var i=setTimeout(function(){t.off(n.support.transition.end).detach()},500);t.one(n.support.transition.end,function(){clearTimeout(i),t.detach()})}var u=this,t=this.tip(),i=n.Event("hide");if(this.$element.trigger(i),!i.isDefaultPrevented())return t.removeClass("in"),n.support.transition&&this.$tip.hasClass("fade")?r():t.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var n=this.$element;(n.attr("title")||typeof n.attr("data-original-title")!="string")&&n.attr("data-original-title",n.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var t=this.$element[0];return n.extend({},typeof t.getBoundingClientRect=="function"?t.getBoundingClientRect():{width:t.offsetWidth,height:t.offsetHeight},this.$element.offset())},getTitle:function(){var t,i=this.$element,n=this.options;return t=i.attr("data-original-title")||(typeof n.title=="function"?n.title.call(i[0]):n.title)},tip:function(){return this.$tip=this.$tip||n(this.options.template)},arrow:function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(t){var i=t?n(t.currentTarget)[this.type](this._options).data(this.type):this;i.tip().hasClass("in")?i.hide():i.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}},i=n.fn.tooltip,n.fn.tooltip=function(i){return this.each(function(){var u=n(this),r=u.data("tooltip"),f=typeof i=="object"&&i;r||u.data("tooltip",r=new t(this,f)),typeof i=="string"&&r[i]()})},n.fn.tooltip.Constructor=t,n.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"><\/div><div class="tooltip-inner"><\/div><\/div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},n.fn.tooltip.noConflict=function(){return n.fn.tooltip=i,this}}(window.jQuery),function(n,t,i,r,u,f){function k(n,t){var i=typeof n[t];return i=="function"||!!(i=="object"&&n[t])||i=="unknown"}function gt(n,t){return!!(typeof n[t]=="object"&&n[t])}function ni(n){return Object.prototype.toString.call(n)==="[object Array]"}function yt(){var i="Shockwave Flash",r="application/x-shockwave-flash",n,t,u,f;if(a(navigator.plugins)||typeof navigator.plugins[i]!="object"||(n=navigator.plugins[i].description,n&&!a(navigator.mimeTypes)&&navigator.mimeTypes[r]&&navigator.mimeTypes[r].enabledPlugin&&(p=n.match(/\d+/g))),!p)try{t=new ActiveXObject("ShockwaveFlash.ShockwaveFlash"),p=Array.prototype.slice.call(t.GetVariable("$version").match(/(\d+),(\d+),(\d+),(\d+)/),1),t=null}catch(e){}return p?(u=parseInt(p[0],10),f=parseInt(p[1],10),ht=u>9&&f>0,!0):!1}function ft(){if(!v){v=!0;for(var n=0;n<nt.length;n++)nt[n]();nt.length=0}}function w(n,t){if(v){n.call(t);return}nt.push(function(){n.call(t)})}function ti(){var t=parent,n,i;if(b!=="")for(n=0,i=b.split(".");n<i.length;n++)t=t[i[n]];return t.easyXDM}function ii(t){return n.easyXDM=dt,b=t,b&&(c="easyXDM_"+b.replace(".","_")+"_"),e}function pt(n){return n.match(st)[3]}function ri(n){return n.match(st)[4]||""}function o(n){var i=n.toLowerCase().match(st),r=i[2],u=i[3],t=i[4]||"";return(r=="http:"&&t==":80"||r=="https:"&&t==":443")&&(t=""),r+"//"+u+t}function tt(n){if(n=n.replace(kt,"$1/"),!n.match(/^(http||https):\/\//)){var t=n.substring(0,1)==="/"?"":i.pathname;t.substring(t.length-1)!=="/"&&(t=t.substring(0,t.lastIndexOf("/")+1)),n=i.protocol+"//"+i.host+t+n}while(at.test(n))n=n.replace(at,"");return n}function g(n,t){var e="",r=n.indexOf("#"),u,i;r!==-1&&(e=n.substring(r),n=n.substring(0,r)),u=[];for(i in t)t.hasOwnProperty(i)&&u.push(i+"="+f(t[i]));return n+(vt?"#":n.indexOf("?")==-1?"?":"&")+u.join("&")+e}function a(n){return typeof n=="undefined"}function s(n,t,i){var u,r;for(r in t)t.hasOwnProperty(r)&&(r in n?(u=t[r],typeof u=="object"?s(n[r],u,i):i||(n[r]=t[r])):n[r]=t[r]);return n}function ui(){var n=t.body.appendChild(t.createElement("form")),i=n.appendChild(t.createElement("input"));i.name=c+"TEST"+lt,rt=i!==n.elements[i.name],t.body.removeChild(n)}function y(n){var i,e,r,u,f;if(a(rt)&&ui(),rt?i=t.createElement('<iframe name="'+n.props.name+'"/>'):(i=t.createElement("IFRAME"),i.name=n.props.name),i.id=i.name=n.props.name,delete n.props.name,typeof n.container=="string"&&(n.container=t.getElementById(n.container)),n.container||(s(i.style,{position:"absolute",top:"-2000px",left:"0px"}),n.container=t.body),e=n.props.src,n.props.src="javascript:false",s(i,n.props),i.border=i.frameBorder=0,i.allowTransparency=!0,n.container.appendChild(i),n.onLoad&&l(i,"load",n.onLoad),n.usePost){if(r=n.container.appendChild(t.createElement("form")),r.target=i.name,r.action=e,r.method="POST",typeof n.usePost=="object")for(f in n.usePost)n.usePost.hasOwnProperty(f)&&(rt?u=t.createElement('<input name="'+f+'"/>'):(u=t.createElement("INPUT"),u.name=f),u.value=n.usePost[f],r.appendChild(u));r.submit(),r.parentNode.removeChild(r)}else i.src=e;return n.props.src=e,i}function fi(n,t){typeof n=="string"&&(n=[n]);for(var i,r=n.length;r--;)if(i=n[r],i=new RegExp(i.substr(0,1)=="^"?i:"^"+i.replace(/(\*)/g,".$1").replace(/\?/g,".")+"$"),i.test(t))return!0;return!1}function wt(r){var u=r.protocol,f,c;if(r.isHost=r.isHost||a(h.xdm_p),vt=r.hash||!1,r.props||(r.props={}),r.isHost)r.remote=tt(r.remote),r.channel=r.channel||"default"+lt++,r.secret=Math.random().toString(16).substring(2),a(u)&&(u=o(i.href)==o(r.remote)?"4":k(n,"postMessage")||k(t,"postMessage")?"1":r.swf&&k(n,"ActiveXObject")&&yt()?"6":navigator.product==="Gecko"&&"frameElement"in n&&navigator.userAgent.indexOf("WebKit")==-1?"5":r.remoteHelper?"2":"0");else if(r.channel=h.xdm_c.replace(/["'<>\\]/g,""),r.secret=h.xdm_s,r.remote=h.xdm_e.replace(/["'<>\\]/g,""),u=h.xdm_p,r.acl&&!fi(r.acl,r.remote))throw new Error("Access denied for "+r.remote);r.protocol=u;switch(u){case"0":if(s(r,{interval:100,delay:2e3,useResize:!0,useParent:!1,usePolling:!1},!0),r.isHost){if(!r.local){for(var v=i.protocol+"//"+i.host,y=t.body.getElementsByTagName("img"),l,w=y.length;w--;)if(l=y[w],l.src.substring(0,v.length)===v){r.local=l.src;break}r.local||(r.local=n)}c={xdm_c:r.channel,xdm_p:0},r.local===n?(r.usePolling=!0,r.useParent=!0,r.local=i.protocol+"//"+i.host+i.pathname+i.search,c.xdm_e=r.local,c.xdm_pa=1):c.xdm_e=tt(r.local),r.container&&(r.useResize=!1,c.xdm_po=1),r.remote=g(r.remote,c)}else s(r,{channel:h.xdm_c,remote:h.xdm_e,useParent:!a(h.xdm_pa),usePolling:!a(h.xdm_po),useResize:r.useParent?!1:r.useResize});f=[new e.stack.HashTransport(r),new e.stack.ReliableBehavior({}),new e.stack.QueueBehavior({encode:!0,maxLength:4e3-r.remote.length}),new e.stack.VerifyBehavior({initiate:r.isHost})];break;case"1":f=[new e.stack.PostMessageTransport(r)];break;case"2":r.remoteHelper=tt(r.remoteHelper),f=[new e.stack.NameTransport(r),new e.stack.QueueBehavior,new e.stack.VerifyBehavior({initiate:r.isHost})];break;case"3":f=[new e.stack.NixTransport(r)];break;case"4":f=[new e.stack.SameOriginTransport(r)];break;case"5":f=[new e.stack.FrameElementTransport(r)];break;case"6":p||yt(),f=[new e.stack.FlashTransport(r)]}return f.push(new e.stack.QueueBehavior({lazy:r.lazy,remove:!0})),f}function bt(n){for(var i,u={incoming:function(n,t){this.up.incoming(n,t)},outgoing:function(n,t){this.down.outgoing(n,t)},callback:function(n){this.up.callback(n)},init:function(){this.down.init()},destroy:function(){this.down.destroy()}},t=0,r=n.length;t<r;t++)i=n[t],s(i,u,!0),t!==0&&(i.down=n[t-1]),t!==r-1&&(i.up=n[t+1]);return i}function ei(n){n.up.down=n.down,n.down.up=n.up,n.up=n.down=null}var it=this,lt=Math.floor(Math.random()*1e4),ot=Function.prototype,st=/^((http.?:)\/\/([^:\/\s]+)(:\d+)*)/,at=/[\-\w]+\/\.\.\//,kt=/([^:])\/\//g,b="",e={},dt=n.easyXDM,c="easyXDM_",rt,vt=!1,p,ht,l,d,v,nt,ut,ct,h,et;if(k(n,"addEventListener"))l=function(n,t,i){n.addEventListener(t,i,!1)},d=function(n,t,i){n.removeEventListener(t,i,!1)};else if(k(n,"attachEvent"))l=function(n,t,i){n.attachEvent("on"+t,i)},d=function(n,t,i){n.detachEvent("on"+t,i)};else throw new Error("Browser not supported");v=!1,nt=[],"readyState"in t?(ut=t.readyState,v=ut=="complete"||~navigator.userAgent.indexOf("AppleWebKit/")&&(ut=="loaded"||ut=="interactive")):v=!!t.body,v||(k(n,"addEventListener")?l(t,"DOMContentLoaded",ft):(l(t,"readystatechange",function(){t.readyState=="complete"&&ft()}),t.documentElement.doScroll&&n===top&&(ct=function(){if(!v){try{t.documentElement.doScroll("left")}catch(n){r(ct,1);return}ft()}},ct())),l(n,"load",ft)),h=function(n){n=n.substring(1).split("&");for(var i={},t,r=n.length;r--;)t=n[r].split("="),i[t[0]]=u(t[1]);return i}(/xdm_e=/.test(i.search)?i.search:i.hash),et=function(){var n={},t={a:[1,2,3]},i='{"a":[1,2,3]}';return typeof JSON!="undefined"&&typeof JSON.stringify=="function"&&JSON.stringify(t).replace(/\s/g,"")===i?JSON:(Object.toJSON&&Object.toJSON(t).replace(/\s/g,"")===i&&(n.stringify=Object.toJSON),typeof String.prototype.evalJSON=="function"&&(t=i.evalJSON(),t.a&&t.a.length===3&&t.a[2]===3&&(n.parse=function(n){return n.evalJSON()})),n.stringify&&n.parse)?(et=function(){return n},n):null},s(e,{version:"2.4.17.1",query:h,stack:{},apply:s,getJSONObject:et,whenReady:w,noConflict:ii}),e.DomHelper={on:l,un:d,requiresJSON:function(i){gt(n,"JSON")||t.write('<script type="text/javascript" src="'+i+'"><\/script>')}},function(){var n={};e.Fn={set:function(t,i){n[t]=i},get:function(t,i){var r=n[t];return i&&delete n[t],r}}}(),e.Socket=function(n){var t=bt(wt(n).concat([{incoming:function(t,i){n.onMessage(t,i)},callback:function(t){if(n.onReady)n.onReady(t)}}])),i=o(n.remote);this.origin=o(n.remote),this.destroy=function(){t.destroy()},this.postMessage=function(n){t.outgoing(n,i)},t.init()},e.Rpc=function(n,t){var i,r,u;if(t.local)for(i in t.local)t.local.hasOwnProperty(i)&&(r=t.local[i],typeof r=="function"&&(t.local[i]={method:r}));u=bt(wt(n).concat([new e.stack.RpcBehavior(this,t),{callback:function(t){if(n.onReady)n.onReady(t)}}])),this.origin=o(n.remote),this.destroy=function(){u.destroy()},u.init()},e.stack.SameOriginTransport=function(n){var t,u,f,h;return t={outgoing:function(n,t,i){f(n),i&&i()},destroy:function(){u&&(u.parentNode.removeChild(u),u=null)},onDOMReady:function(){h=o(n.remote),n.isHost?(s(n.props,{src:g(n.remote,{xdm_e:i.protocol+"//"+i.host+i.pathname,xdm_c:n.channel,xdm_p:4}),name:c+n.channel+"_provider"}),u=y(n),e.Fn.set(n.channel,function(n){return f=n,r(function(){t.up.callback(!0)},0),function(n){t.up.incoming(n,h)}})):(f=ti().Fn.get(n.channel,!0)(function(n){t.up.incoming(n,h)}),r(function(){t.up.callback(!0)},0))},init:function(){w(t.onDOMReady,t)}}},e.stack.FlashTransport=function(n){function v(n){r(function(){h.up.incoming(n,a)},0)}function p(i){var r=n.swf+"?host="+n.isHost,h="easyXDM_swf_"+Math.floor(Math.random()*1e4),o;e.Fn.set("flash_loaded"+i.replace(/[\-.]/g,"_"),function(){var n,t;for(e.stack.FlashTransport[i].swf=u=f.firstChild,n=e.stack.FlashTransport[i].queue,t=0;t<n.length;t++)n[t]();n.length=0}),n.swfContainer?f=typeof n.swfContainer=="string"?t.getElementById(n.swfContainer):n.swfContainer:(f=t.createElement("div"),s(f.style,ht&&n.swfNoThrottle?{height:"20px",width:"20px",position:"fixed",right:0,top:0}:{height:"1px",width:"1px",position:"absolute",overflow:"hidden",right:0,top:0}),t.body.appendChild(f)),o="callback=flash_loaded"+i.replace(/[\-.]/g,"_")+"&proto="+it.location.protocol+"&domain="+pt(it.location.href)+"&port="+ri(it.location.href)+"&ns="+b,f.innerHTML="<object height='20' width='20' type='application/x-shockwave-flash' id='"+h+"' data='"+r+"'><param name='allowScriptAccess' value='always'><\/param><param name='wmode' value='transparent'><param name='movie' value='"+r+"'><\/param><param name='flashvars' value='"+o+"'><\/param><embed type='application/x-shockwave-flash' FlashVars='"+o+"' allowScriptAccess='always' wmode='transparent' src='"+r+"' height='1' width='1'><\/embed><\/object>"}var h,l,k,a,u,f;return h={outgoing:function(t,i,r){u.postMessage(n.channel,t.toString()),r&&r()},destroy:function(){try{u.destroyChannel(n.channel)}catch(t){}u=null,l&&(l.parentNode.removeChild(l),l=null)},onDOMReady:function(){a=n.remote,e.Fn.set("flash_"+n.channel+"_init",function(){r(function(){h.up.callback(!0)})}),e.Fn.set("flash_"+n.channel+"_onMessage",v),n.swf=tt(n.swf);var t=pt(n.swf),f=function(){e.stack.FlashTransport[t].init=!0,u=e.stack.FlashTransport[t].swf,u.createChannel(n.channel,n.secret,o(n.remote),n.isHost),n.isHost&&(ht&&n.swfNoThrottle&&s(n.props,{position:"fixed",right:0,top:0,height:"20px",width:"20px"}),s(n.props,{src:g(n.remote,{xdm_e:o(i.href),xdm_c:n.channel,xdm_p:6,xdm_s:n.secret}),name:c+n.channel+"_provider"}),l=y(n))};e.stack.FlashTransport[t]&&e.stack.FlashTransport[t].init?f():e.stack.FlashTransport[t]?e.stack.FlashTransport[t].queue.push(f):(e.stack.FlashTransport[t]={queue:[f]},p(t))},init:function(){w(h.onDOMReady,h)}}},e.stack.PostMessageTransport=function(t){function v(n){if(n.origin)return o(n.origin);if(n.uri)return o(n.uri);if(n.domain)return i.protocol+"//"+n.domain;throw"Unable to retrieve the origin of the event";}function a(n){var i=v(n);i==h&&n.data.substring(0,t.channel.length+1)==t.channel+" "&&f.up.incoming(n.data.substring(t.channel.length+1),i)}var f,u,e,h;return f={outgoing:function(n,i,r){e.postMessage(t.channel+" "+n,i||h),r&&r()},destroy:function(){d(n,"message",a),u&&(e=null,u.parentNode.removeChild(u),u=null)},onDOMReady:function(){if(h=o(t.remote),t.isHost){var v=function(i){i.data==t.channel+"-ready"&&(e="postMessage"in u.contentWindow?u.contentWindow:u.contentWindow.document,d(n,"message",v),l(n,"message",a),r(function(){f.up.callback(!0)},0))};l(n,"message",v),s(t.props,{src:g(t.remote,{xdm_e:o(i.href),xdm_c:t.channel,xdm_p:1}),name:c+t.channel+"_provider"}),u=y(t)}else l(n,"message",a),e="postMessage"in n.parent?n.parent:n.parent.document,e.postMessage(t.channel+"-ready",h),r(function(){f.up.callback(!0)},0)},init:function(){w(f.onDOMReady,f)}}},e.stack.FrameElementTransport=function(u){var f,e,l,a;return f={outgoing:function(n,t,i){l.call(this,n),i&&i()},destroy:function(){e&&(e.parentNode.removeChild(e),e=null)},onDOMReady:function(){a=o(u.remote),u.isHost?(s(u.props,{src:g(u.remote,{xdm_e:o(i.href),xdm_c:u.channel,xdm_p:5}),name:c+u.channel+"_provider"}),e=y(u),e.fn=function(n){return delete e.fn,l=n,r(function(){f.up.callback(!0)},0),function(n){f.up.incoming(n,a)}}):(t.referrer&&o(t.referrer)!=h.xdm_e&&(n.top.location=h.xdm_e),l=n.frameElement.fn(function(n){f.up.incoming(n,a)}),f.up.callback(!0))},init:function(){w(f.onDOMReady,f)}}},e.stack.NameTransport=function(n){function p(i){var r=n.remoteHelper+(t?"#_3":"#_2")+n.channel;u.contentWindow.sendMessage(i,r)}function b(){t?++l!=2&&t||i.up.callback(!0):(p("ready"),i.up.callback(!0))}function k(n){i.up.incoming(n,a)}function nt(){h&&r(function(){h(!0)},0)}var i,t,u,f,l,h,a,v;return i={outgoing:function(n,t,i){h=i,p(n)},destroy:function(){u.parentNode.removeChild(u),u=null,t&&(f.parentNode.removeChild(f),f=null)},onDOMReady:function(){t=n.isHost,l=0,a=o(n.remote),n.local=tt(n.local),t?(e.Fn.set(n.channel,function(i){t&&i==="ready"&&(e.Fn.set(n.channel,k),b())}),v=g(n.remote,{xdm_e:n.local,xdm_c:n.channel,xdm_p:2}),s(n.props,{src:v+"#"+n.channel,name:c+n.channel+"_provider"}),f=y(n)):(n.remoteHelper=n.remote,e.Fn.set(n.channel,k));var i=function(){var t=u||this;d(t,"load",i),e.Fn.set(n.channel+"_load",nt),function f(){typeof t.contentWindow.sendMessage=="function"?b():r(f,50)}()};u=y({props:{src:n.local+"#_4"+n.channel},onLoad:i})},init:function(){w(i.onDOMReady,i)}}},e.stack.HashTransport=function(t){function d(n){if(i){var r=t.remote+"#"+b+++"_"+n;(l||!h?i.contentWindow:i).location=r}}function g(n){e=n,u.up.incoming(e.substring(e.indexOf("_")+1),k)}function nt(){if(f){var t=f.location.href,n="",i=t.indexOf("#");i!=-1&&(n=t.substring(i)),n&&n!=e&&g(n)}}function a(){v=setInterval(nt,p)}var u,tt=this,l,v,p,e,b,f,i,h,k;return u={outgoing:function(n){d(n)},destroy:function(){n.clearInterval(v),(l||!h)&&i.parentNode.removeChild(i),i=null},onDOMReady:function(){if(l=t.isHost,p=t.interval,e="#"+t.channel,b=0,h=t.useParent,k=o(t.remote),l){if(s(t.props,{src:t.remote,name:c+t.channel+"_provider"}),h)t.onLoad=function(){f=n,a(),u.up.callback(!0)};else{var v=0,w=t.delay/50;(function d(){if(++v>w)throw new Error("Unable to reference listenerwindow");try{f=i.contentWindow.frames[c+t.channel+"_consumer"]}catch(n){}f?(a(),u.up.callback(!0)):r(d,50)})()}i=y(t)}else f=n,a(),h?(i=parent,u.up.callback(!0)):(s(t,{props:{src:t.remote+"#"+t.channel+new Date,name:c+t.channel+"_consumer"},onLoad:function(){u.up.callback(!0)}}),i=y(t))},init:function(){w(u.onDOMReady,u)}}},e.stack.ReliableBehavior=function(){var t,i,r=0,u=0,f="";return t={incoming:function(n,e){var s=n.indexOf("_"),o=n.substring(0,s).split(",");n=n.substring(s+1),o[0]==r&&(f="",i&&(i(!0),i=null)),n.length>0&&(t.down.outgoing(o[1]+","+r+"_"+f,e),u!=o[1]&&(u=o[1],t.up.incoming(n,e)))},outgoing:function(n,e,o){f=n,i=o,t.down.outgoing(u+","+ ++r+"_"+n,e)}}},e.stack.QueueBehavior=function(n){function h(){if(n.remove&&i.length===0){ei(t);return}if(!o&&i.length!==0&&!c){o=!0;var u=i.shift();t.down.outgoing(u.data,u.origin,function(n){o=!1,u.callback&&r(function(){u.callback(n)},0),h()})}}var t,i=[],o=!0,e="",c,l=0,v=!1,s=!1;return t={init:function(){a(n)&&(n={}),n.maxLength&&(l=n.maxLength,s=!0),n.lazy?v=!0:t.down.init()},callback:function(n){o=!1;var i=t.up;h(),i.callback(n)},incoming:function(i,r){if(s){var f=i.indexOf("_"),o=parseInt(i.substring(0,f),10);e+=i.substring(f+1),o===0&&(n.encode&&(e=u(e)),t.up.incoming(e,r),e="")}else t.up.incoming(i,r)},outgoing:function(r,u,e){n.encode&&(r=f(r));var c=[],o;if(s){while(r.length!==0)o=r.substring(0,l),r=r.substring(o.length),c.push(o);while(o=c.shift())i.push({data:c.length+"_"+o,origin:u,callback:c.length===0?e:null})}else i.push({data:r,origin:u,callback:e});v?t.down.init():h()},destroy:function(){c=!0,t.down.destroy()}}},e.stack.VerifyBehavior=function(n){function u(){i=Math.random().toString(16).substring(2),t.down.outgoing(i)}var t,i,r,f=!1;return t={incoming:function(f,e){var o=f.indexOf("_");o===-1?f===i?t.up.callback(!0):r||(r=f,n.initiate||u(),t.down.outgoing(f)):f.substring(0,o)===r&&t.up.incoming(f.substring(o+1),e)},outgoing:function(n,r,u){t.down.outgoing(i+"_"+n,r,u)},callback:function(){n.initiate&&u()}}},e.stack.RpcBehavior=function(n,t){function i(n){n.jsonrpc="2.0",r.down.outgoing(f.stringify(n))}function o(n,t){var r=Array.prototype.slice;return function(){var f=arguments.length,s,o={method:t};f>0&&typeof arguments[f-1]=="function"?(f>1&&typeof arguments[f-2]=="function"?(s={success:arguments[f-2],error:arguments[f-1]},o.params=r.call(arguments,0,f-2)):(s={success:arguments[f-1]},o.params=r.call(arguments,0,f-1)),u[""+ ++e]=s,o.id=e):o.params=r.call(arguments,0),n.namedParams&&o.params.length===1&&(o.params=o.params[0]),i(o)}}function s(n,t,r,u){var f,e,o;if(!r){t&&i({id:t,error:{code:-32601,message:"Procedure not found."}});return}t?(f=function(n){f=ot,i({id:t,result:n})},e=function(n,r){e=ot;var u={id:t,error:{code:-32099,message:n}};r&&(u.error.data=r),i(u)}):f=e=ot,ni(u)||(u=[u]);try{o=r.method.apply(r.scope,u.concat([f,e])),a(o)||f(o)}catch(s){e(s.message)}}var r,f=t.serializer||et(),e=0,u={};return r={incoming:function(n){var e=f.parse(n),o;e.method?t.handle?t.handle(e,i):s(e.method,e.id,t.local[e.method],e.params):(o=u[e.id],e.error?o.error&&o.error(e.error):o.success&&o.success(e.result),delete u[e.id])},init:function(){if(t.remote)for(var i in t.remote)t.remote.hasOwnProperty(i)&&(n[i]=o(t.remote[i],i));r.down.init()},destroy:function(){for(var i in t.remote)t.remote.hasOwnProperty(i)&&n.hasOwnProperty(i)&&delete n[i];r.down.destroy()}}},it.easyXDM=e}(window,document,location,window.setTimeout,decodeURIComponent,encodeURIComponent),this.JSON||(this.JSON={}),function(){function i(n){return n<10?"0"+n:n}function o(n){return e.lastIndex=0,e.test(n)?'"'+n.replace(e,function(n){var t=s[n];return typeof t=="string"?t:"\\u"+("0000"+n.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+n+'"'}function u(i,f){var c,l,s,a,v=n,h,e=f[i];e&&typeof e=="object"&&typeof e.toJSON=="function"&&(e=e.toJSON(i)),typeof t=="function"&&(e=t.call(f,i,e));switch(typeof e){case"string":return o(e);case"number":return isFinite(e)?String(e):"null";case"boolean":case"null":return String(e);case"object":if(!e)return"null";if(n+=r,h=[],Object.prototype.toString.apply(e)==="[object Array]"){for(a=e.length,c=0;c<a;c+=1)h[c]=u(c,e)||"null";return s=h.length===0?"[]":n?"[\n"+n+h.join(",\n"+n)+"\n"+v+"]":"["+h.join(",")+"]",n=v,s}if(t&&typeof t=="object")for(a=t.length,c=0;c<a;c+=1)l=t[c],typeof l=="string"&&(s=u(l,e),s&&h.push(o(l)+(n?": ":":")+s));else for(l in e)Object.hasOwnProperty.call(e,l)&&(s=u(l,e),s&&h.push(o(l)+(n?": ":":")+s));return s=h.length===0?"{}":n?"{\n"+n+h.join(",\n"+n)+"\n"+v+"}":"{"+h.join(",")+"}",n=v,s}}typeof Date.prototype.toJSON!="function"&&(Date.prototype.toJSON=function(){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+i(this.getUTCMonth()+1)+"-"+i(this.getUTCDate())+"T"+i(this.getUTCHours())+":"+i(this.getUTCMinutes())+":"+i(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()});var f=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,e=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,n,r,s={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},t;typeof JSON.stringify!="function"&&(JSON.stringify=function(i,f,e){var o;if(n="",r="",typeof e=="number")for(o=0;o<e;o+=1)r+=" ";else typeof e=="string"&&(r=e);if(t=f,f&&typeof f!="function"&&(typeof f!="object"||typeof f.length!="number"))throw new Error("JSON.stringify");return u("",{"":i})}),typeof JSON.parse!="function"&&(JSON.parse=function(text,reviver){function walk(n,t){var r,u,i=n[t];if(i&&typeof i=="object")for(r in i)Object.hasOwnProperty.call(i,r)&&(u=walk(i,r),u!==undefined?i[r]=u:delete i[r]);return reviver.call(n,t,i)}var j;if(text=String(text),f.lastIndex=0,f.test(text)&&(text=text.replace(f,function(n){return"\\u"+("0000"+n.charCodeAt(0).toString(16)).slice(-4)})),/^[\],:{}\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,"")))return j=eval("("+text+")"),typeof reviver=="function"?walk({"":j},""):j;throw new SyntaxError("JSON.parse");})}(),function(n,t,i){var u=0,r=null,f={x:0,y:0};n("[data-toggle=dropdown-hover]").closest("li").on("mouseenter",function(){r&&r.removeClass("open"),t.clearTimeout(u),r=n(this),u=t.setTimeout(function(){r.addClass("open")},i)}).on("mousemove",function(e){if(Math.abs(f.x-e.ScreenX)>4||Math.abs(f.y-e.ScreenY)>4){f.x=e.ScreenX,f.y=e.ScreenY;return}(r||(r=n(this)),r.hasClass("open"))||(t.clearTimeout(u),u=t.setTimeout(function(){r.addClass("open")},i))}).on("mouseleave",function(){t.clearTimeout(u),r=n(this),u=t.setTimeout(function(){r.removeClass("open")},i)})}(jQuery,window,0),$(document).ready(function(){$(".doc-footer .icon-plus").click(function(){$(this).closest(".doc-footer ").css({height:"auto"}),$(this).hide()})}),$("#appendedPrependedInputSearch").typeahead({source:function(n,t){states=[],map={},GetSearchDropDownData(n,function(n){states=$.map(n,function(n){return n.Name}),t(states)})},select:function(){var n=this.$menu.find(".active").attr("data-value"),t;return this.form=this.$menu.parent("form").get(0),n==undefined&&(n=this.query),t="/Search/"+n.replace(/ /g,"-"),location.href=t,this.hide()},render:function(n){var t=this;return n=$(n).map(function(n,i){return n=$(t.options.item).attr("data-value",i),n.find("a").html(t.highlighter(i)),n[0]}),this.$menu.html(n),this},mouseleave:function(){this.mousedover=!1,this.$menu.find(".active").removeClass("active"),!this.focused&&this.shown&&this.hide()}}),$("#headerSearchForm").submit(function(n){n.preventDefault(),document.location="/search/"+encodeURIComponent($("#appendedPrependedInputSearch",this).val())}),$("#reSearch").typeahead({source:function(n,t){states=[],map={},GetSearchDropDownData(n,function(n){states=$.map(n,function(n){return n.Name}),t(states)})},select:function(){var n=this.$menu.find(".active").attr("data-value"),t;return this.form=this.$menu.parent("form").get(0),n==undefined&&(n=this.query),t="/Search/"+n.replace(/ /g,"-"),location.href=t,this.hide()},render:function(n){var t=this;return n=$(n).map(function(n,i){return n=$(t.options.item).attr("data-value",i),n.find("a").html(t.highlighter(i)),n[0]}),this.$menu.html(n),this},mouseleave:function(){this.mousedover=!1,this.$menu.find(".active").removeClass("active"),!this.focused&&this.shown&&this.hide()}}),$("#partialInputSearch").keypress(function(n){if(n.which==13)return!1}),$("#partialInputSearch").typeahead({source:function(n,t){topics=[],states=[],map={},GetTopicsDropDownData(n,function(n){topics=n,states=$.map(n,function(n){return n.Name}),t(states)})},select:function(){var n=this.$menu.find(".active").attr("data-value"),t=$.map(topics,function(t){if(n==t.Name)return t.UrlPath}),i="/Topics"+t[0];return location.href=i,this.hide()},render:function(n){var t=this;return n=$(n).map(function(n,i){return n=$(t.options.item).attr("data-value",i),n.find("a").html(t.highlighter(i)),n[0]}),n.first().addClass("active"),this.$menu.html(n),this}}),$(document).ready(function(){for(var t=$(".card-side-img"),n=0;t.length>n;n++){if(n==6)break;t[n].setAttribute("src",t[n].getAttribute("data-src"))}for(t=$(".doc-card-img"),n=0;t.length>n;n++){if(n==6)break;t[n].setAttribute("src",t[n].getAttribute("data-src"))}$("li.nav-slide-submenu-text").on("mouseenter",function(){var n=$(this).children().find(".slide-subnavmenu");$(n).is(":visible")||$(n).slideDown("slow")}).on("mouseleave",function(){var n=$(this).children().find(".slide-subnavmenu");$(n).slideUp("fast")});$("a.signup-container").click(function(n){n.preventDefault(),$(document).trigger("join")}),$(".facebookBtn").click(function(){event.preventDefault(),ds.account.fbLogin("0",function(){location.href="https://"+location.host+"/account/RedirectBack?next="+encodeURIComponent(location.href)},function(){alert("Error logging into facebook.")})})}),$(window).load(function(){for(var t=$(".card-side-img"),n=6;t.length>n;n++)t[n].setAttribute("src",t[n].getAttribute("data-src"));for(t=$(".doc-card-img"),n=6;t.length>n;n++)t[n].setAttribute("src",t[n].getAttribute("data-src"))}),function(n,t,i,r){function u(n,t){return typeof t=="function"?t(n):n!==r?n:t}function f(n){var u,i;if(typeof n=="object")return n;if(u={},n!==r)for(n=t.isArray(n)?n:[n],i=0;i<n.length;i++)u[""+n[i]]=1;return u}n!==r&&(i=i||"utils",n[i]=n[i]||{},n[i].noop=function(){},n[i].callLogger=function(t,u){if(t===r)return n[i].noop;var f=t;return function(){var n=Array.prototype.slice.call(arguments);return console.log(u||"function called with:",n,"on:",this),f.call(this,n)}},n[i].readCookie=function(n){for(var r=n+"=",u=document.cookie.split(";"),t,i=0;i<u.length;i++){for(t=u[i];t.charAt(0)==" ";)t=t.substring(1,t.length);if(t.indexOf(r)==0)return t.substring(r.length,t.length)}return null},n[i].setCookie=function(n,t,i){n&&t&&(i=i?"; expires="+i:"",document.cookie=n+"="+t+i+"; path=/")},n[i].log=function(){function e(){}var t="off",f="log_level",u=n[i].readCookie(f);return u&&(t=u.toLowerCase(),u!==t&&n[i].setCookie(f,t)),e.prototype={level:function(u){return u===r?t:(typeof u=="string"&&u?(t=u.toLowerCase(),n[i].setCookie(f,t)):console&&console.log&&console.log("logger level could not be set - invalid argument - current = "+t),this)},verbose:function(n){return n===r||t!=="verbose"&&t!=="debug"?this:(typeof n=="string"?console.log(n):typeof n=="function"&&n(),this)}},u?new e:(new e).level(n.config&&n.config.LogLevel?n.config.LogLevel:r)}(),t?n[i].logEvents=function(){function o(){u=!0,t.prototype.trigger=e}function s(){u=!1,t.prototype.trigger=f}var f=t.prototype.trigger,e,u;return f?(e=n[i].callLogger(f,"Triggered event:"),u=!1,function(n){(n=n===r?!0:!!n,n!==u)&&(n?o():s())}):n[i].noop}():(t={when:n[i].noop,Deferred:n[i].noop,isArray:function(n){return Object.prototype.toString.call(n)==="[object Array]"}},n[i].logEvents=n[i].noop),n[i].equalityComp=function(n,t,i){if(n===r){if(t===r)return!0}else if(t===r)return!1;return i?n===t:n==t},n[i].arrayMatches=function(u,f,e,o,s,h){var c,l,a,v;if((typeof u!="function"&&(u=u?function(n,t){return t}:function(n){return n}),c=[],!f||!e)||(t.isArray(f)||(f=[f]),t.isArray(e)||(e=[e]),!f.length||!e.length))return c;for(o=n[i].functated(o),s=n[i].functated(s),h=h||n[i].equalityComp,l=0;l<e.length;l++)for(a=0;a<f.length;a++)h(o(f[a]),s(e[l]))&&(v=u(f[a],e[l]),v!==r&&c.push(v));return c},n[i].noopPromise=function(){var r=t.when(!1);return function(){return r.always(function(){n[i].log.verbose("Returning noopPromise")})}}(),n[i].noopCb=function(t){return t<-1?n[i].noop:function(){for(var i=Array.prototype.slice.call(arguments),n=0;n<i.length;n++)if(typeof i[n]=="function"){t>-1?setTimeout(function(){i[n]()},t):i[n]();break}}},n[i].oneTimePromise=function(t){return function(){var r=null;return t?(typeof t=="object"&&t.done&&(r=t),function(){return r?r:r=t()}):n[i].noopPromise}()},n[i].valuator=function(n,t){var i=typeof n=="function"?n():n;return t&&(i=u(i,t)),i},n[i].functor=function(n,t){return typeof n=="function"?t?function(){var i=n();return u(i,t)}:n:(t&&(n=u(n,t)),function(){return n})},n[i].functorSingle=function(n,i){return typeof n=="function"?function(){var r=n();return r=t.isArray(r)?r[0]:r,i&&(r=u(r,i)),r}:(n=t.isArray(n)?n[0]:n,i&&(n=u(n,i)),function(){return n})},n[i].functorArray=function(n){return typeof n=="function"?function(){var i=n();return t.isArray(i)?i:[i]}:(n=t.isArray(n)?n:[n],function(){return n})},n[i].functorDictionary=function(n){return typeof n=="function"?function(){return f(n())}:(n=f(n),function(){return n})},n[i].functated=function(n,t){return n&&typeof n=="function"?n:t?function(n){return n||t}:function(n){return n}})}(window.ds=window.ds||{},jQuery,"utils"),function(n,t,i){t.apis=t.apis||{};var r={isLoggedIn:{path:"/account/isloggedin",fwd:0,type:"GET"},getClassifications:{path:"/account/GetClassifications",fwd:0,type:"GET"},saveClassifications:{path:"/Account/UpdateQuestionnaire",fwd:0,type:"POST"},bucketUser:{path:"/api/UserRevenueBucket",fwd:0,type:"POST"}};if(!n){t.apis.MembersApi=function(){var i={},n;for(n in r)i[n]=r[n].path?t.utils.noopPromise:t.utils.noop}();return}t.apis.MembersApi=function(){function f(n){return(n.fwd?s:"")+n.path}function e(n){return n.fwd?h:c}var o="",s="/api/fwd",h={"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json","ds-send-to-api":o+", api"},c={"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json"},u={};return u.isLoggedIn=function(i,u){t.utils&&t.utils.log&&t.utils.log.verbose("ds.apis.MembersApi.isLoggedIn::calling to check if current user is logged in");var o=n.Deferred(),s=f(r.isLoggedIn),h={doc_id:i||0,print:u||0};return n.ajax(s,{type:r.isLoggedIn.type,data:h,dataType:"json",cache:!1,headers:e(r.isLoggedIn)}).done(function(n){o.resolve(n)}).fail(function(n,t,i){o.reject(i)}),o.promise()},u.getClassifications=function(){var t=n.Deferred(),i=f(r.getClassifications);return n.ajax(i,{type:r.getClassifications.type,dataType:"json",cache:!1,headers:e(r.getClassifications)}).done(function(n){n=n&&n.ClassificationList?n.ClassificationList:[],t.resolve(n)}).fail(function(n,i,r){t.reject(r)}),t.promise()},u.saveClassifications=function(i){var u,o;return(i=i?n.isArray(i)?i:[i]:[],u=n.Deferred(),!i.length)?(u.reject("No classifications to save"),u.promise()):(o=f(r.saveClassifications),n.ajax(o,{type:r.saveClassifications.type,dataType:"json",data:JSON.stringify({Answers:i}),headers:e(r.saveClassifications)}).done(function(n){typeof n=="string"&&(n=JSON.parse(n)),n?u.resolve(n):u.reject("No result")}).fail(function(n,i,r){t.utils&&t.utils.log&&t.utils.log.verbose(function(){console.log("saveClassifications failed on error: ",r)}),u.reject(r)}),u.promise())},u.bucketUser=function(t,u,o,s,h){var c={},v=!1,l,a;return typeof t=="object"?c=t:(t&&(c.DocId=+t),u&&(c.Page=u),o!==i&&(c.Force=!!o),s&&(c.CampaignClassId=+s),h&&(c.GroupId=+h)),l=n.Deferred(),a=f(r.bucketUser),n.ajax(a,{type:r.bucketUser.type,dataType:"json",data:JSON.stringify(c),headers:e(r.bucketUser)}).done(function(n){l.resolve(n)}).fail(function(n){l.reject(n)}),l.promise()},u}()}(window.jQuery,window.ds=window.ds||{}),function(n,t,i){t.apis=t.apis||{};var r={getSurvey:{path:"/surveys/",fwd:1,type:"GET"},getResponses:{path:"/responses/",fwd:1,type:"GET"},saveResponses:{path:"/responses/",fwd:1,type:"POST"},getTopic:{path:"/topics/",fwd:1,type:"GET"},saveComment:{path:"/comments/",fwd:1,type:"POST"}};if(!n||!t.config||!t.config.surveysApi){t.apis.SurveyApi=function(){var i={},n;for(n in r)i[n]=t.utils.noopPromise}();return}t.apis.SurveyApi=function(){function e(n){return(n.fwd?h:"")+n.path}function o(n){return n.fwd?c:l}function s(n,t,i){var r=null;try{r=JSON.parse(n.responseText)}catch(u){r=null}return r||(r={Elapsed:0,StatusCode:n.status,Message:i,DeveloperMessage:n.responseText}),r}for(var u=t.config.surveysApi,f,u=u.replace("https://","").replace("http://","");u[u.length-1]=="/";)u=u.substring(0,u.length-1);var h="/api/fwd",c={"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json","ds-send-to-api":u+", api"},l={"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json"};return f={},f.getSurvey=function(t,i){var u=n.Deferred(),f;return t?(f=e(r.getSurvey)+t+(i?"/"+i:""),n.ajax(f,{type:r.getSurvey.type,dataType:"json",headers:o(r.getSurvey)}).done(function(n){n&&n.ResponseData&&n.ResponseData.SurveyId?u.resolve(n.ResponseData):u.reject("No Survey Data")}).fail(function(n,t,i){u.reject(i)}),u.promise()):(u.reject('No "id" in request'),u.promise())},f.getResponses=function(t,i){var u=n.Deferred(),f;return!t||!i?(u.reject('No "'+(!t&&!i?'id" nor "user':t?"user":"id")+'" in request'),u.promise()):(f=e(r.getResponses)+t+"/"+i,n.ajax(f,{type:r.getResponses.type,dataType:"json",headers:o(r.getResponses)}).done(function(n){n&&n.ResponseData?u.resolve(n.ResponseData.Responses||[]):u.reject({Elapsed:n.Elapsed||0,Message:n.Message||"Problem with Request",DeveloperMessage:n.DeveloperMessage||"Ask Alex Z.",StatusCode:n.StatusCode})}).fail(function(n,t,i){var r=s(n,t,i);r.StatusCode===404?u.resolve([]):u.reject(r)}),u.promise())},f.saveResponses=function(t,i,u){var f=n.Deferred(),c,h,l;if(!t||!i)return f.reject('No "'+(!t&&!i?'id" nor "user':t?"user":"id")+'" in request'),f.promise();for(u=n.isArray(u)?u:[u],c=[],h=0;h<u.length;h++)u[h]&&c.push(u[h]);return c.length?(l=e(r.saveResponses)+t+"/"+i,n.ajax(l,{type:r.saveResponses.type,dataType:"json",data:JSON.stringify({Responses:c}),headers:o(r.saveResponses)}).done(function(n){n&&n.ResponseData&&n.ResponseData.Responses&&n.ResponseData.Responses.length?f.resolve(n.ResponseData.Responses):f.reject({Elapsed:n.Elapsed||0,Message:n.Message||"Problem with Request",DeveloperMessage:n.DeveloperMessage||"Ask Alex Z.",StatusCode:n.StatusCode})}).fail(function(n,t,i){f.reject(s(n,t,i))}),f.promise()):(f.reject("No responses to send in request"),f.promise())},f.getTopics=function(){var t=n.Deferred(),i=e(r.getTopic),u;return n.ajax(i,{type:r.getTopic.type,dataType:"json",headers:o(r.getTopic)}).done(function(n){n&&n.length?t.resolve(n):t.reject({Elapsed:n.Elapsed||0,Message:n.Message||"Problem with Request",DeveloperMessage:n.DeveloperMessage||"Ask Alex Z.",StatusCode:n.StatusCode})}).fail(function(n,i,r){t.reject(s(n,i,r))}),t.promise()},f.saveComment=function(t){var i=n.Deferred(),u=e(r.saveComment);return n.each(t,function(t,f){n.ajax(u,{type:r.saveComment.type,dataType:"json",traditional:!0,data:JSON.stringify(f),headers:o(r.saveComment)}).done(function(){}).fail(function(n,t,r){i.reject(s(n,t,r))})}),i.promise()},f}()}(window.jQuery,window.ds=window.ds||{}),function(n,t,i,r){t.utils.log.verbose("Inside qController definition scope"),t.components=t.components||{},t.components.qController=function(){return function(i){function st(){f&&!y&&(y=!0,f.trigger("modal-questionnaire-open"))}function ht(){f&&y&&(y=!1,f.trigger("modal-questionnaire-close"))}function ct(n,t,r){return ds.utils.log.verbose(function(){console.log("Getting handlers for event:",n,"holder:",t,"bus:",r)}),function(n){var f=i.eventNs()+n.type+(n.namespace?"."+n.namespace:"");if(ds.utils.log.verbose(function(){console.log("handling event:",f)}),l.push(f),s.state()==="pending")return v.push(n.data.q),k(t,o+1),!0;nt(r,f)}}function lt(){if(!e)return r;if(!l||!l.length)return e[0];for(var n=l.length-1;n>=0;n--){if(e[l[n]])return e[l[n]];if(e[l[n]]===0)return e[0]}return e[0]}function nt(t,i){var u,f;if(typeof t=="string"?(i=t,t=n(document)):t!==r&&typeof t=="object"&&t.trigger||(t=n(document),i=i||""),u=lt(),u)for(u=n.isArray(u)?u:[u],ds.utils.log.verbose(function(){console.log("Triggering lastEvents:",u)}),f=0;f<u.length;f++)i!==u[f]&&(e.Map!==r?t.trigger(u[f],[e.Map]):t.trigger(u[f]))}function at(t){return i.getQuestionnairePromise().done(function(r){var o,u,a,p,l,f,c,v,y;if(!r){s.resolve({responses:[],map:null});return}if(r.Properties&&r.Properties.Push)for(o=n.isArray(r.Properties.Push)?r.Properties.Push:[r.Properties.Push],e.Map=r.Properties.Map,u=0;u<o.length;u++)if(o[u])if(typeof o[u]=="string")e[0].push(o[u]);else if(typeof o[u]=="object")for(a in o[u])e[a]=o[u][a];if(r.Questions&&r.Questions.length){for(p=i.prefetch(),l=0;l<r.Questions.length;l++)if(f=r.Questions[l],f.Properties&&f.Properties.Triggers&&f.Properties.Triggers.length)for(c=0;c<f.Properties.Triggers.length;c++){p[f.Properties.Triggers[c]]&&it(f),v=i.eventNs()+f.Properties.Triggers[c];n(document).on(v,{q:f},ct(v,t,t))}}else s.resolve({responses:[],map:null});r.Properties&&r.Properties.Init&&(y=[],h(r.Properties.Init,y),rt(y))})}function vt(){return v[o]}function yt(n,t){o>-1&&pt(n,v[o].Id),o=t,u={},o<v.length?gt(n,v[o]):(nt(n),s.resolve({responses:w,map:{responses:c,matches:a}}),ht())}function pt(n,t){n.find("#"+t).remove()}function wt(n,i){return t.utils.arrayMatches(!0,n.Properties.Match,i)}function bt(n){return t.utils.arrayMatches(!1,n.Answers,n.Responses,function(n){return n.Id},function(n){return n.AnswerId})}function kt(i,u){var f={};return t.utils.arrayMatches(function(n){return f[n.Id]?r:(f[n.Id]=n,n)},i,u,function(n){return n.Properties&&n.Properties.Map?n.Properties.Map:r},r,function(i,r){if(!n.isArray(i))return t.utils.equalityComp(i,r);for(var u=0;u<i.length;u++)if(t.utils.equalityComp(i[u],r))return!0;return!1})}function dt(t,i){var r,f,u,e;if(!i)return t;if(!t||(r=[],f={},t=n.isArray(t)?t:[t],i=n.isArray(i)?i:[i],!t.length))return i;if(!i.length)return t;for(r=r.concat(t,i),u=0;u<r.length;u++)f[r[u].Id]||(f[r[u].Id]=r[u]);r=[];for(e in f)r.push(f[e]);return r}function gt(t,f){var e=d;i.getMatchMapsPromise().done(function(t){e=n.isArray(t)?t:[t],ds.utils.log.verbose(function(){console.log("qController.pushQuestion::received matchData, setting maps2Match to:",e)})}).fail(function(n){ds.utils.log.verbose(function(){console.log("qController.pushQuestion::Failed to get match maps on error:",n)}),ds.utils.log.verbose(function(){consoel.log("qController.pushQuestion::Using original matchMaps:",e)})}).always(function(){var v=wt(f,e),l=[],y,o,s,c;if(v&&v.length||f.Responses&&f.Responses.length){if(y=bt(f),o=kt(f.Answers,v),o=dt(o,y),o&&o.length){for(s=0;s<o.length;s++)o[s].Properties&&(o[s].Properties.Map!==r&&i.pushMap(a,o[s].Properties.Map),o[s].Properties.Push&&h(o[s].Properties.Push,l,o[s].Properties.Map));(f.Properties.PushAlways||f.Properties.PushOnly!==r&&!f.Properties.PushOnly)&&(f.Properties.Map!==r&&i.pushMap(a,f.Properties.Map),f.Properties.Push&&h(f.Properties.Push,l,f.Properties.Map)),p(t,l);return}if(f.Properties.PushAlways||f.Properties.PushOnly!==r){f.Properties.Map!==r&&i.pushMap(a,f.Properties.Map),f.Properties.Push&&(h(f.Properties.Push,l,f.Properties.Map),p(t,l));return}}for(c=0;c<f.Answers.length;c++)f.Answers[c].Properties&&f.Answers[c].Properties.GetValue&&(u[f.Answers[c].Id]=f.Answers[c]);it(f).done(function(i){var u=n('<div id="'+f.Id+'"><\/div>').appendTo(t);u.html(i),st()}).fail(function(n,t){ds.utils.log.verbose(function(){console.log("Failed to get question html for:",this)}),ds.utils.log.verbose(function(){console.log("error:",n)}),ds.utils.log.verbose(function(){console.log("respText:",t)})})})}function tt(n,t){return n.Id+"_"+t.Id}function it(t){var u,f,r;if(t.htmlPromise)return t.htmlPromise;for(u=n.Deferred(),t.htmlPromise=u.promise(),f={id:t.Id,title:i.templateTitle(),questionText:t.DisplayText,isMulti:t.MaxResponseCount>1,answers:[],data:i.templateData(b,t)},r=0;r<t.Answers.length;r++)f.answers.push({Id:tt(t,t.Answers[r]),AnswerText:t.Answers[r].DisplayText});return n.ajax({type:"POST",url:t.TemplateUri,data:JSON.stringify(f),dataType:"html",contentType:"application/json",success:function(n,i,r){u.resolveWith(t,[n,r.responseText])},error:function(n,i,r){ds.utils.log.verbose(function(){console.log("jqXhr.responseText:",n.responseText)}),ds.utils.log.verbose(function(){console.log("error:",r)}),u.rejectWith(t,[r,n.responseText])}}),t.htmlPromise}function h(t,i,r){var u,f;if(typeof t=="string")i.push({event:t,map:r});else if(n.isArray(t))for(u=0;u<t.length;u++)i.push({event:t[u],map:r});else for(f in t)i.push({event:f,map:t[f]})}function rt(t,r,u){if(t){n.isArray(t)||(t=[t]),r=r||n(document);for(var f=0;f<t.length;f++)r.trigger((u?i.eventNs():"")+t[f].event,[t[f].map])}}function p(n,t){rt(t,n,!0),k(n,o+1)}function ni(){ds.utils.readCookie(et)&&s.reject([])}function ft(n,t,i){if(!i.Properties.GetValue)return r;var u=tt(t,i);return n.find('[data-id="'+u+'"]').val()}var et="DocstocCustomerSupportQuestionnaireToggle",k,ut;i=n.extend({},{containerId:"#qHolder",locked:!0,prefetch:r,progressNotify:"",pushMap:r,getQuestionnairePromise:t.utils.noopPromise,getMatchMapsPromise:t.utils.noopPromise,eventNs:"Questions",waitFor:t.utils.noopPromise,templateTitle:"",templateData:null},i),i.containerId=t.utils.functorSingle(i.containerId,function(n){return n.charAt(0)!=="#"&&(n="#"+n),n}),i.locked=t.utils.functorSingle(i.locked),i.progressNotify=t.utils.functorSingle(i.progressNotify,function(n){return n&&n.toLowerCase&&typeof n.toLowerCase=="function"?n.toLowerCase():""}),i.prefetch=t.utils.functorDictionary(i.prefetch),i.eventNs=t.utils.functorSingle(i.eventNs,function(n){return n?n.charAt(n.length-1)==="."?n:n+".":""}),i.waitFor=t.utils.functor(i.waitFor),i.pushMap=i.pushMap||function(t,i){if(i){i=n.isArray(i)?i:[i];for(var r=0;r<i.length;r++)t.push(i[r])}},i.templateTitle=t.utils.functorSingle(i.templateTitle),i.templateData=t.utils.functated(i.templateData);var d=[],v=[],o=-1,u={},a=[],c=[],f=null,y=!1,g=".modal-backdrop"+(i.locked()?"-lockable":""),ot=".modal-backdrop"+(i.locked()?"":"-lockable"),s=n.Deferred(),e={};e[0]=[];var l=[],w=[],b={};k=function(){var n=0;return function(t,r){n||(n=setTimeout(function(){i.waitFor().done(function(){n=0,yt(t,r)})},0))}}(),ut=i.getMatchMapsPromise(),n(function(){var t=i.containerId();n(t).length||n("body").prepend(n('<div id="'+t.substring(1)+'"><\/div>')),f=n(t).on("click","[data-id]",function(t){var k,o,g,nt,tt,v,d,l,it,rt,et;t.preventDefault();var ot=n(t.currentTarget),ut=ot.data("id"),y=null,e=vt();if(e)if(k=ut.replace(e.Id,""),k&&k.charAt(0)=="_"&&(k=k.slice(1)),k){for(o=null,g=0;g<e.Answers.length;g++)if(e.Answers[g].Id==k){o=e.Answers[g];break}o&&(o.Properties&&o.Properties.MoveNext||e.MaxResponseCount==1&&!f.find('[data-role="submit"]').length?(v=[],nt=[],o.Properties&&(y=ft(f,e,o),y&&(o.Value=y),y=null,o.Properties.Map!==r&&(i.pushMap(c,o.Properties.Map),i.pushMap(nt,o.Properties.Map)),o.Properties.Push&&h(o.Properties.Push,v,o.Properties.Map),o.Properties.Forward&&(b[o.Properties.Forward]=o.Value||o.Properties.Map||o.Id)),e.Properties&&(e.Properties.PushAlways||e.Properties.PushOnly!==r&&!e.Properties.PushOnly)&&(e.Properties.Map!==r&&(i.pushMap(c,e.Properties.Map),i.pushMap(nt,e.Properties.Map)),e.Properties.Push&&h(e.Properties.Push,v,e.Properties.Map)),tt={},tt[o.Id]=o,it={qid:e.Id,answers:tt,map:nt},w.push(it),rt=i.progressNotify()==="complete"?{responses:c,matched:a}:nt,s.notify({qid:e.Id,answers:tt,map:rt}),v.length&&p(f,v)):e.MaxResponseCount==1?u[o.Id]||(u={},u[o.Id]=o):u[o.Id]?u[o.Id].Properties&&u[o.Id].Properties.GetValue||delete u[o.Id]:u[o.Id]=o)}else if(ut!=e.Id||n.isEmptyObject(u))et=n(this).siblings(".questionnaire-alert"),et.length===0&&n(this).after('<div class="alert-negative questionnaire-alert">please select an answer<\/div>');else{v=[],d=[];for(l in u)u[l]&&u[l].Properties&&(y=ft(f,e,u[l]),y&&(u[l].Value=y),y=null,u[l].Properties.Map!==r&&(i.pushMap(c,u[l].Properties.Map),i.pushMap(d,u[l].Properties.Map)),u[l].Properties.Push&&h(u[l].Properties.Push,v,u[l].Properties.Map),u[l].Properties.Forward&&(b[u[l].Properties.Forward]=u[l].Value||u[l].Properties.Map||l));e.Properties&&(e.Properties.PushAlways||e.Properties.PushOnly&&!d.length||e.Properties.PushOnly!==r&&!e.Properties.PushOnly)&&(e.Properties.Map!==r&&(i.pushMap(c,e.Properties.Map),i.pushMap(d,e.Properties.Map)),e.Properties.Push&&h(e.Properties.Push,v,e.Properties.Map)),it={qid:e.Id,answers:u,map:d},w.push(it),rt=i.progressNotify()==="complete"?{responses:c,matched:a}:d,s.notify({qid:e.Id,answers:u,map:rt}),v.length&&p(f,v)}}).on("modal-questionnaire-close",function(){f&&(n(g).hide(),f.hide())}).on("modal-questionnaire-open",function(){f&&(n(ot).hide(),n(g).show(),f.show(),n(window).scrollTop()<80&&n(document.body).animate({scrollTop:n("#regPopModal").offset().top}))}).hide(),at(f).done(function(){ut.done(function(t){d=n.isArray(t)?t:[t]}).fail(function(n){ds.utils.log.verbose(function(){console.log("qController::Failed to get match maps on error:",n)})})}).fail(function(n){ds.utils.log.verbose(function(){console.log("Unable to Init Questionnaire b/c:",n)})}).always(function(){ni()})}),this.promise=function(){return s.promise()}}}()}(window.jQuery,window.ds=window.ds||{}),function(n){function e(n,t){var i=(n&65535)+(t&65535),r=(n>>16)+(t>>16)+(i>>16);return r<<16|i&65535}function c(n,t){return n<<t|n>>>32-t}function s(n,t,i,r,u,f){return e(c(e(e(t,n),e(r,f)),u),i)}function i(n,t,i,r,u,f,e){return s(t&i|~t&r,n,t,u,f,e)}function r(n,t,i,r,u,f,e){return s(t&r|i&~r,n,t,u,f,e)}function u(n,t,i,r,u,f,e){return s(t^i^r,n,t,u,f,e)}function f(n,t,i,r,u,f,e){return s(i^(t|~r),n,t,u,f,e)}function l(n,t){var l;n[t>>5]|=128<<t%32,n[(t+64>>>9<<4)+14]=t;var o=1732584193,s=-271733879,h=-1732584194,c=271733878;for(l=0;l<n.length;l+=16){var a=o,v=s,y=h,p=c;o=i(o,s,h,c,n[l+0],7,-680876936),c=i(c,o,s,h,n[l+1],12,-389564586),h=i(h,c,o,s,n[l+2],17,606105819),s=i(s,h,c,o,n[l+3],22,-1044525330),o=i(o,s,h,c,n[l+4],7,-176418897),c=i(c,o,s,h,n[l+5],12,1200080426),h=i(h,c,o,s,n[l+6],17,-1473231341),s=i(s,h,c,o,n[l+7],22,-45705983),o=i(o,s,h,c,n[l+8],7,1770035416),c=i(c,o,s,h,n[l+9],12,-1958414417),h=i(h,c,o,s,n[l+10],17,-42063),s=i(s,h,c,o,n[l+11],22,-1990404162),o=i(o,s,h,c,n[l+12],7,1804603682),c=i(c,o,s,h,n[l+13],12,-40341101),h=i(h,c,o,s,n[l+14],17,-1502002290),s=i(s,h,c,o,n[l+15],22,1236535329),o=r(o,s,h,c,n[l+1],5,-165796510),c=r(c,o,s,h,n[l+6],9,-1069501632),h=r(h,c,o,s,n[l+11],14,643717713),s=r(s,h,c,o,n[l+0],20,-373897302),o=r(o,s,h,c,n[l+5],5,-701558691),c=r(c,o,s,h,n[l+10],9,38016083),h=r(h,c,o,s,n[l+15],14,-660478335),s=r(s,h,c,o,n[l+4],20,-405537848),o=r(o,s,h,c,n[l+9],5,568446438),c=r(c,o,s,h,n[l+14],9,-1019803690),h=r(h,c,o,s,n[l+3],14,-187363961),s=r(s,h,c,o,n[l+8],20,1163531501),o=r(o,s,h,c,n[l+13],5,-1444681467),c=r(c,o,s,h,n[l+2],9,-51403784),h=r(h,c,o,s,n[l+7],14,1735328473),s=r(s,h,c,o,n[l+12],20,-1926607734),o=u(o,s,h,c,n[l+5],4,-378558),c=u(c,o,s,h,n[l+8],11,-2022574463),h=u(h,c,o,s,n[l+11],16,1839030562),s=u(s,h,c,o,n[l+14],23,-35309556),o=u(o,s,h,c,n[l+1],4,-1530992060),c=u(c,o,s,h,n[l+4],11,1272893353),h=u(h,c,o,s,n[l+7],16,-155497632),s=u(s,h,c,o,n[l+10],23,-1094730640),o=u(o,s,h,c,n[l+13],4,681279174),c=u(c,o,s,h,n[l+0],11,-358537222),h=u(h,c,o,s,n[l+3],16,-722521979),s=u(s,h,c,o,n[l+6],23,76029189),o=u(o,s,h,c,n[l+9],4,-640364487),c=u(c,o,s,h,n[l+12],11,-421815835),h=u(h,c,o,s,n[l+15],16,530742520),s=u(s,h,c,o,n[l+2],23,-995338651),o=f(o,s,h,c,n[l+0],6,-198630844),c=f(c,o,s,h,n[l+7],10,1126891415),h=f(h,c,o,s,n[l+14],15,-1416354905),s=f(s,h,c,o,n[l+5],21,-57434055),o=f(o,s,h,c,n[l+12],6,1700485571),c=f(c,o,s,h,n[l+3],10,-1894986606),h=f(h,c,o,s,n[l+10],15,-1051523),s=f(s,h,c,o,n[l+1],21,-2054922799),o=f(o,s,h,c,n[l+8],6,1873313359),c=f(c,o,s,h,n[l+15],10,-30611744),h=f(h,c,o,s,n[l+6],15,-1560198380),s=f(s,h,c,o,n[l+13],21,1309151649),o=f(o,s,h,c,n[l+4],6,-145523070),c=f(c,o,s,h,n[l+11],10,-1120210379),h=f(h,c,o,s,n[l+2],15,718787259),s=f(s,h,c,o,n[l+9],21,-343485551),o=e(o,a),s=e(s,v),h=e(h,y),c=e(c,p)}return Array(o,s,h,c)}function a(n){for(var i=Array(),r=(1<<o)-1,t=0;t<n.length*o;t+=o)i[t>>5]|=(n.charCodeAt(t/o)&r)<<t%32;return i}function v(n){for(var i=h?"0123456789ABCDEF":"0123456789abcdef",r="",t=0;t<n.length*4;t++)r+=i.charAt(n[t>>2]>>t%4*8+4&15)+i.charAt(n[t>>2]>>t%4*8&15);return r}n=n||{};var h=0,o=8;n.compute=function(n){return v(l(a(n),n.length*o))}}(window.ds_hash=window.ds_hash||{}),function(n,r,u,f){function c(n){t="",n=n.toLowerCase();var r=n.replace("\n","n");for(r=r.replace(/\/\\/g,""),i=0;i<n.length;i++)n.charAt(i)!="\n"&&n.charAt(i)!="/"&&n.charAt(i)!="\\"?t+=n.charAt(i):n.charAt(i)=="\n"&&(t+="n");return t}function l(n,t){return fileName=n,filenameStart=0,filenameStart=fileName.lastIndexOf(t),filenameStart<0&&(filenameStart=0),filenameFinish=fileName.length,fileName=fileName.substring(filenameStart+t.length,filenameFinish)}function a(){var n="",t,r;if(window.navigator.plugins.length>0)if(opera){for(t="",r="Plugins",i=0;i<window.navigator.plugins.length;i++)plugin=window.navigator.plugins[i],t+=l(plugin.filename,r)+"|";t=t.substring(0,t.length-1),n=c(t)}else{for(i=0;i<window.navigator.plugins.length;i++)plugin=window.navigator.plugins[i],n+=plugin.filename+"|";n=n.substring(0,n.length-1)}else if(window.navigator.mimeTypes.length>0){for(i=0;i<window.navigator.mimeTypes.length;i++)mimeType=window.navigator.mimeTypes[i],n+=mimeType.type+"|";n=n.substring(0,n.length-1)}else if(ie){for(components=["7790769C-0471-11D2-AF11-00C04FA35D02","89820200-ECBD-11CF-8B85-00AA005B4340","283807B5-2C60-11D0-A31D-00AA00B92C03","4F216970-C90C-11D1-B5C7-0000F8051515","44BBA848-CC51-11CF-AAFA-00AA00B6015C","9381D8F2-0288-11D0-9501-00AA00B911A5","4F216970-C90C-11D1-B5C7-0000F8051515","5A8D6EE0-3E18-11D0-821E-444553540000","89820200-ECBD-11CF-8B85-00AA005B4383","08B0E5C0-4FCB-11CF-AAA5-00401C608555","45EA75A0-A269-11D1-B5BF-0000F8051515","DE5AED00-A4BF-11D1-9948-00C04F98BBC9","22D6F312-B0F6-11D0-94AB-0080C74C7E95","44BBA842-CC51-11CF-AAFA-00AA00B6015B","3AF36230-A269-11D1-B5BF-0000F8051515","44BBA840-CC51-11CF-AAFA-00AA00B6015C","CC2A9BA0-3BDD-11D0-821E-444553540000","08B0E5C0-4FCB-11CF-AAA5-00401C608500","D27CDB6E-AE6D-11CF-96B8-444553540000","2A202491-F00D-11CF-87CC-0020AFEECF20"],document.body.addBehavior("#default#clientCaps"),i=0;i<components.length;i++)ver=activeXDetect(components[i]),n+=ver?ver+"|":"null|";n=n.substring(0,n.length-1)}return n}var e=function(){for(var t={},n=u.config&&u.config.tracking?u.config.tracking:"tracking.docstoc.api",n=n.replace("https://","").replace("http://","");n[n.length-1]=="/";)n=n.substring(0,n.length-1);var i="/api/fwd",r="/bot/fingerprint",f="/activities";return t.Version="0.1.0-alpha",t.ForwardSendTo=function(){return n},t.FingerprintLocation=function(){return i+r},t.ActivityLocation=function(){return i+f},t.UseFontSwf=!1,t}(),o=n!==f,s=function(){},v=function(n){return typeof n=="function"?n():n},y=function(n){return typeof n=="function"?n:function(){return n}},h;if(u=u||{},u.track)try{delete u.track}catch(p){o&&n.log("unable to delete ds.track - will attempt redefinition")}if(r===f){o&&n.info("no jQuery, ds.track disabled!"),u.track={activity:s};return}try{h="|",ua=window.navigator.userAgent.toLowerCase(),opera=ua.indexOf("opera")>=0,ie=ua.indexOf("msie")>=0&&!opera,iemac=ie&&ua.indexOf("mac")>=0,moz=ua.indexOf("mozilla")&&!ie&&!opera,os=window.navigator.platform}catch(p){}u.track=function(){function o(){var t=r.Deferred();return setTimeout(function(){if(e.UseFontSwf)try{window.dsmetrics={},dsmetrics.fingerprint={},dsmetrics.fingerprint.FingerprintId="",dsmetrics.fingerprint.Fonts="",dsmetrics.fingerprint.Plugins="",dsmetrics.fingerprint.UserAgent="",dsmetrics.fingerprint.Resolution="";var i='<object id="fontListSWF" name="fontListSWF" type="application/x-shockwave-flash" data="/swf/FontList.swf" width="1" height="1" ><param name="movie" value="/swf/FontList.swf"><embed src="/swf/FontList.swf" width="1" height="1"><\/embed><\/object><\/body>',n=r("<div><\/div>");n.html(i),n.css("display","block"),n.appendTo(document.body)}catch(f){}setTimeout(function(){var i,r;try{if(dsmetrics.fingerprint.Fonts==""){try{i="",self.screen&&(i+=screen.colorDepth+"|"+screen.width+"|"+screen.height+"|"+screen.availHeight)}catch(f){i=""}dsmetrics.fingerprint.Resolution=ds_hash.compute(i);try{r=a()}catch(f){r=""}dsmetrics.fingerprint.Plugins=ds_hash.compute(r)}n.remove(),dsmetrics.fingerprint.Plugins.length>32&&(dsmetrics.fingerprint.Plugins=ds_hash.compute(dsmetrics.fingerprint.Plugins)),dsmetrics.fingerprint.Fonts.length>32&&(dsmetrics.fingerprint.Fonts=ds_hash.compute(dsmetrics.fingerprint.Fonts)),t.resolve(new u(dsmetrics.fingerprint.Fonts,dsmetrics.fingerprint.Plugins,dsmetrics.fingerprint.Resolution))}catch(f){t.reject(f)}},1e3)},0)}var n={},c="",l="",i=function(n,t,i){var r=this;if(!n)throw Error("Cannot create Activity with no Action name");return r.Action=n,r.Page=t||"",r.Location=i||"",r},u=function(n,t,i){var r=this;return r.fn=n,r.pl=t,r.res=i,r},s=function(n,t){if(!n||n===f)throw new Error("Cannot add an empty activity");t=t||r.Deferred();try{r.ajax(e.ActivityLocation(),{type:"POST",data:JSON.stringify(n),dataType:"json",headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json","ds-send-to-api":e.ForwardSendTo()}}).done(function(n,i,r){r.status==201?t.resolve():t.reject("Not created")}).fail(function(n,i,r){t.reject(r)})}catch(i){t.reject(i)}},h=function(n,t){if(!n||n===f)throw new Error("Cannot update an empty fingerprint");t=t||r.Deferred(),r.ajax(e.FingerprintLocation(),{type:"PUT",data:JSON.stringify(n),dataType:"json",contentType:"application/json"}).done(function(n,i,r){r.status===204?t.resolve():r.status>300?t.reject("Not modified"):t.reject("Rejected for unknown reason")}).fail(function(n,i,r){t.reject(r)})},t=function(n){return n.then||(n.then=function(i,r,u){return t(n.done(i).fail(r)).progress(u)}),n.otherwise||(n.otherwise=function(t){return n.then(f,t)}),n.ensure||(n.ensure=function(i){return t(n.always(i))}),n},c={};return!1&&o().done(function(n){c.fingerprint=n,n&&h(n)}),n.activity=function(n,t,u,e){var o,c,h;if(t=t||window.location.pathname,o=new i(n,t,u),e!==f&&e!==null){try{c=JSON.stringify(e)}catch(l){e={derr:"unable to serialize data",error:l}}o=r.extend({},o,{Data:e})}return h=r.Deferred(),s(o,h),h.promise()},n}(),u.track.Version=e.Version}(window.console,window.jQuery,window.ds=window.ds||{}),fordebuggingbreak=0,function(n,t,i,r){var u=!0;if(i.regPop)try{delete i.regPop}catch(f){u&&console.log("Unable to delete ds.track.adapter.regPop",f)}if(i.regPop=function(n,i,r,u){var f=u?"view-reg-popup-on-pkg":"view-reg-popup-on-doc",e=u?{packageid:r}:{docid:r};return t.push({event:f,control:i}),ds.track.activity(f,n,i,e)},i.regSuccess)try{delete i.regSuccess}catch(f){u&&console.log("Unable to delete ds.track.adapter.regSuccess",f)}if(i.regSuccess=function(){},i.regDocPageSuccess)try{delete i.regDocPageSuccess}catch(f){u&&console.log("Unable to delete ds.track.adapter.regDocPageSuccess",f)}if(i.regDocPageSuccess=function(n,i,r,u){var f="registered-member-on-doc";return t.push({event:f,control:i}),ds.track.activity(f,n,i,{docid:r,memid:u||0})},i.loginDocPage)try{delete i.loginDocPage}catch(f){u&&console.log("Unable to delete ds.track.adapter.loginDocPage",f)}if(i.loginDocPage=function(){},i.questionResponse)try{delete i.questionResponse}catch(f){u&&console.log("Unable to delete ds.track.adapter.questionResponse",f)}if(i.questionResponse=function(n,i){var f="register-questionnaire-response",r,u;if(!i){t.push({event:f,"question.seq":n});return}if(r=[],i.answers)for(u in i.answers)i.answers[u]&&r.push(i.answers[u]);t.push({event:f,"question.seq":n,"question.id":i.qid,"question.responses":r})},i.finishQuestionnaire)try{delete i.finishQuestionnaire}catch(f){u&&console.log("Unable to delete ds.track.adapter.finishQuestionnaire",f)}if(i.finishQuestionnaire=function(n){var i="register-questionnaire-completed";t.push({event:i,"questions.total":n})},i.submitSubscription)try{delete i.submitSubscription}catch(f){u&&console.log("Unable to delete ds.track.adapter.submitSubscription",f)}if(i.submitSubscription=function(n,i,r,u,f,e){var s="submit-subscribe",o={event:s};n&&(o["subscription.campaign"]=n),i&&(o["subscription.group"]=i),r&&(o["subscription.plan"]=r),u&&(o["subscription.interval"]=u),f&&(o["subscription.every"]=f),e&&(o["subscription.priceUSD"]=e),t.push(o)},i.subscribeSuccess)try{delete i.subscribeSuccess}catch(f){u&&console.log("Unable to delete ds.track.adapter.subscribeSuccess",f)}i.subscribeSuccess=function(n,i,r){var u="subscribed";t.push({event:u,"subscription.interval":n,"subscription.every":i,"subscription.priceUSD":r})},i.subPeriodLabel=function(n){function i(n,t,i){return i?n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()+" ("+t+")":n+" ("+t+")"}var t={choices:["Daily","Weekly","BiWeekly","Monthly","Quarterly","Semi-Annually","Annually","BiAnnually"],Daily:0,Weekly:1,BiWeekly:2,Monthly:3,Quarterly:4,SemiAnnually:5,Annually:6,BiAnnually:7,monthly:function(n){switch(n){case 1:return t.choices[t.Monthly];case 3:return t.choices[t.Quarterly];case 6:return t.choices[t.SemiAnnually];case 12:return t.choices[t.Annually]}return i(t.choices[t.Monthly],n)},daily:function(n){switch(n){case 1:return t.choices[t.Daily];case 5:return t.choices[t.Weekly];case 7:return t.choices[t.Weekly];case 14:return t.choices[t.BiWeekly];case 28:return t.choices[t.Monthly];case 30:return t.choices[t.Monthly];case 31:return t.choices[t.Monthly];case 365:return t.choices[t.Annually]}return i(t.choices[t.Daily],n)},weekly:function(n){switch(n){case 1:return t.choices[t.Weekly];case 4:return t.choices[t.Monthly];case 52:return t.choices[t.Annually]}return i(t.choices[t.Weekly],n)},yearly:function(n){switch(n){case 1:return t.choices[t.Annually];case 2:return t.choices[t.BiAnnually]}return i(t.choices[t.Annually],n)}};return n?(n.interval||(n.interval=n.period||""),!n.interval)?r:(n.interval=n.interval.toLowerCase(),n.every=+(n.every||"1"),t[n.interval])?t[n.interval](n.every):i(n.interval,n.every,!0):r},i.ecommerceTransaction=function(n,r,u,f,e,o,s){s=s||0;var h="Subscription - "+(i.subPeriodLabel({interval:u,every:f})||"Unknown");t.push({transactionId:""+n,transactionAffiliation:"Docstoc.com",transactionTotal:o,transactionTax:s,transactionShipping:0,transactionProducts:[{sku:r,name:h,category:""+e,price:o,quantity:1}]})},i.youtubePlay=function(n,i,r,u,f,e){var o=u?"course-play":"video-play";return u?(window.dataLayer&&t.push({event:o,"course.id":r,"course.chapter":f,"course.lesson":e}),ds.track.activity(o,n,i,{courseId:r,chapterId:f,lessonId:e})):(window.dataLayer&&t.push({event:o,"video.id":r}),ds.track.activity(o,n,i,{videoId:r}))},i.socialShare=function(n,i,r,u,f,e){var o="social-share";return window.dataLayer&&t.push({event:o,"social.network":r,"social.action":u,"social.target":n}),ds.track.activity(o,n,i,{id:f,resourceType:e,socialMediaType:r,socialAction:u})},i.articleWidgetTrack=function(n,i,r,u,f){window.dataLayer&&t.push({event:n,"topic.asked":r,"article.widget.source":u,"article.widget.comment":f})},i.foodieBanner=function(n,i,r){window.dataLayer&&t.push({event:n,memberId:r,url:i})},i.myBusiness=function(n,i,r){window.dataLayer&&t.push({event:n,mbIndustry:i,mbSubscribed:r})}}(ds.track,window.dataLayer=window.dataLayer||[],ds.track.adapter=ds.track.adapter||{}),function(n,t,i){function h(n){var t,i,r,u,e,f;if(!n)return n;if(t=[],n.responses){if(!n.responses.length)return t;t=t.concat(n.matches||[],n.responses)}else $.isArray(n)?t=t.concat(n):t.push(n);for(i={},r=0;r<t.length;r++)u=""+t[r],i[u]||(i[u]=0),i[u]++;t=[];for(e in i)f=+e,f&&t.push(f);return t}function e(t){return(t=h(t),!t||!t.length||!n.apis||!n.apis.MembersApi)?n.utils.noopPromise():n.apis.MembersApi.saveClassifications(t).then(function(t){return n.utils.log.verbose((t?"Successfully saved":"Failed to save")+" MemberClassifications"),t},function(t){return n.utils.log.verbose("Error trying to save MemberClassifications"),t})}function a(t,r,u){for(var h=[],f=null,s=null,o,e=0;e<u.length;e++)if(u[e]&&u[e].answers){f=u[e];for(o in f.answers)s={QuestionId:f.qid,AnswerId:o},f.answers[o].Value!==i&&(s.Value=f.answers[o].Value),f.answers[o].Properties!==i&&(s.Properties=f.answers[o].Properties),h.push(s),s=null;f=null}return n.apis.SurveyApi.saveResponses(t,r,h)}var o=function(){function r(t,i){return function(){n&&clearInterval(n),n=0,u(t,i)()}}function u(n,r){return function(){var f=t,u;t<i.length&&(u=i.slice(t),t=i.length,a(n,r,u).fail(function(){t=f}))}}var n=0,t=0,i=null;return function(t,f,e){return n||!e?r:(i=e,n=setInterval(u(t,f),100),r(t,f))}}(),c=function(){var n={140:"Intl",12:"FoodieReg",120:"FoodieReg_Intl",100:"IndiaQBOOffer",7:"None",2:"Foodie",20:"Foodie_Intl"};return function(t,i){if(typeof t=="string")return t;if(t===12)switch(i){case 24:case 180:return t=120,n[t];case 179:case 1:return t=12,n[t];default:return n[t]}else if(t===2)switch(i){case 24:case 180:return t=20,n[t];case 179:case 1:return t=2,n[t];default:return n[t]}else{switch(i){case 24:case 180:return t=140,n[t];case 179:case 1:return t=14,n[t];default:return n[t]}return n[t]}}}(),r=function(){var y=[],r=t.memId,f=!1,l=!0,a="",e=n.config.RegPopSurveyId,u=[],s=null,v=$.Deferred(),p=1;$(document).on("Registered",function(n,t){r=+t,l=!0,s=o(e,r,u)});$(document).on("LoggedIn",function(n,t){r=+t,l=!0,s=o(e,r,u)});$(document).on("UpdateBucket",function(i,r){if(r&&r.DocId&&t.docId&&(r.DocId=t.docId),n.utils.log.verbose(function(){console.log("Going to rebucket the user to:",r)}),r===!1){v.resolve(r);return}n.apis.MembersApi.bucketUser(r).done(function(n){v.resolve(n)}).fail(function(n){v.reject(n)})});return{isLoggedIn:function(){if(f||!l)return $.when(f).promise();var t=$.Deferred();return n.apis.MembersApi.isLoggedIn().done(function(n){f=n&&n.Success,r=n.MemId||r,l=!1,t.resolve(f),f&&(s=o(e,r,u))}).fail(function(i){n.utils.log.verbose(function(){console.log("Error checking isLoggedIn:",i)}),t.resolve(r>0)}),t.promise()},getMemId:function(){return r>0?r:i},setMemId:function(n){r=n},updateClassifications:function(n){y=h(n)},getClasses:function(){return y},getRegFlow:function(){return a},setRegFlow:function(t,i){var r;a=c(t,i)||"",a&&(r=n.config["RegPopSurveyId_"+a],r&&(e=r))},getSurveyId:function(){return e},getBucketingPromise:function(){return v.promise()},getSurveyResponses:function(){return u},saveSurveyResponses:function(n){$.isArray(n)?u=u.concat(n):u.push(n)},stopSavingResponses:function(){s&&s()},qCount:function(){return u.length}}}(),v=n.utils.oneTimePromise(function(){return n&&n.apis&&n.apis.MembersApi?n.apis.MembersApi.getClassifications().done(function(t){n.utils.log.verbose(function(){console.log("Retrieved classifications for member:",t)})}):noopPromise()}),l={},u=n.config.RegPopPrefetch,f,s;if(u&&u.length)for(f=0;f<u.length;f++)u[f]&&(l[u[f]]=1);n.runtime=n.runtime||{},s=n.utils.oneTimePromise(function(){return n.apis.MembersApi.bucketUser(t.docId||i,"")}),n.runtime.registrationQuestionnaire=n.utils.oneTimePromise(new n.components.qController({progressNotify:"complete",getQuestionnairePromise:function(){return s().then(function(t){if(c(t.SubscriptionGroup.RegistrationFlow,t.SubscriptionGroup.CampaignClassId)=="None")return $(document).trigger("UpdateBucket",[!1]),n.utils.noopPromise();r.setRegFlow(t.SubscriptionGroup.RegistrationFlow,t.SubscriptionGroup.CampaignClassId);var i=n.apis.SurveyApi.getSurvey(r.getSurveyId(),r.getMemId());return n.utils.log.verbose(function(){i.done(function(n){console.log("Retrieved Survey:",n)})}),i},function(t){n.utils.log.verbose(function(){console.log("Failed to get user bucket on error:",t),console.log("Will use default Survey Id")});var i=n.apis.SurveyApi.getSurvey(r.getSurveyId(),r.getMemId());return n.utils.log.verbose(function(){i.done(function(n){console.log("Retrieved Survey:",n)})}),i})},getMatchMapsPromise:function(){return r.isLoggedIn().then(function(n){return n?v():$.when(r.getClasses()).promise()})},prefetch:l,eventNs:"",templateTitle:t.docId?t.Title||"Document":""}).promise().then(function(t){return n.utils.log.verbose(function(){console.log("RegQs.Promise: Got all data:",t)}),t.responses&&t.responses.length&&n.track.adapter.finishQuestionnaire(t.responses.length),r.isLoggedIn().then(function(n){if(n)return $.when(r.getBucketingPromise(),e(t.map));var i=$.Deferred();r.updateClassifications(t.map);$(document).on("Registered",function(){e(r.getClasses()).done(function(){i.resolve(t)}).fail(function(n){i.reject("Unable to save after Registered w/ error:",n)})});$(document).on("LoggedIn",function(){e(r.getClasses()).done(function(){i.resolve(t)}).fail(function(n){i.reject("Unable to save after LoggedIn w/ error:",n)})});return $.when(r.getBucketingPromise(),i.promise())})},function(t){n.utils.log.verbose(function(){console.log("Error in qController:",t)})},function(t){n.utils.log.verbose(function(){console.log("RegQs.Promise: Got response data:",t)}),r.saveSurveyResponses(t),n.track.adapter.questionResponse(r.qCount(),t),r.isLoggedIn().done(function(n){n?e(t.map):r.updateClassifications(t.map)}).fail(function(t){n.utils.log.verbose(function(){console.log("Unable to save regQsState update on progress, error:",t)})}),s().then(function(i){var u,f,r;if(i.SubscriptionGroup.Id==404||i.SubscriptionGroup.Id==269){u=window.dataLayer||[];for(f in t.answers)r={event:"registration-question-answered","question.id":t.qid,"answer.id":f},u.push(r),n.utils.log.verbose(function(){console.log("GTM Event: ",r)})}})})),n.runtime.registrationQuestionnaire().always(function(){r.stopSavingResponses()})}(window.ds,{memId:window.CurrentUserID||-10,docId:window.RegFlowData?RegFlowData.DocID||0:0,Title:window.swfParams?swfParams.DocTitle:""}),window.ds=window.ds||{},ds.xhr||(easyXDM.DomHelper.requiresJSON("../json2.js"),ds.xhr=new easyXDM.Rpc({local:"/content/easyxdm/name.html",swf:REMOTE+"/content/easyxdm/easyxdm.swf",remote:REMOTE+"/content/easyxdm/cors/",remoteHelper:REMOTE+"/content/easyxdm/src/name.html"},{remote:{request:{}}})),ds.account=ds.account||{},ds.account.login=function(n,t,i,r){var u={UserName:n,Password:t};ds.xhr.request({url:"/account/logindata",method:"POST",data:JSON.stringify(u),headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json"}},function(n){if(n.data){var t=JSON.parse(n.data);t.Success?i(t):r(t)}})},ds.account.fbLogin=function(n,t,i){FB.login(function(r){var u=r.authResponse.accessToken,f={authToken:u,DocId:n};jQuery.ajax({url:"/account/facebookLogin",type:"GET",cache:!1,data:f,dataType:"json",error:function(){i()},success:function(n){ds.isOxnardKissEnabled&&_kmdoc("Registered Oxford With Facebook"),t(n)}})},{scope:"email,publish_stream,offline_access"})},ds.account.register=function(n,t,i,r,u,f){var e={UserName:n,Password:t,DocstocPurpose:i,DocId:r};ds.xhr.request({url:"/account/registerdata",method:"POST",data:JSON.stringify(e),headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json"}},function(n){if(n.data){var t=JSON.parse(n.data);t.Success?u(t):f(t)}},function(n){console.log(n)})},ds.account.questionnare=function(n,t,i){console.log("account questionnare");var r={Answers:n};ds&&ds.track&&ds.track.activity("questions-updating",window.location.pathname||"unknown?","account.js_ds.account.questionnaire",{quesdata:r}),ds.xhr.request({url:"/account/updatequestionnaire",method:"POST",data:JSON.stringify(r),headers:{"Content-Type":"application/json","X-Requested-With":"XMLHttpRequest",Accept:"application/json"}},function(n){typeof n=="string"&&(n=JSON.parse(n)),n?(ds&&ds.track&&ds.track.activity("questions-updated-success",window.location.pathname||"unknown?","account.js_ds.account.questionnaire.success",{resp:n||"null",quesdata:r}),t(n)):(ds&&ds.track&&ds.track.activity("questions-updated-error",window.location.pathname||"unknown?","account.js_ds.account.questionnaire.success",{resp:n||"null",quesdata:r}),i(n))},function(n){ds&&ds.track&&ds.track.activity("questions-updated-error",window.location.pathname||"unknown?","account.js_ds.account.questionnaire.error",{resp:n||"noerrormsg",quesdata:r}),console.log(n)})},ds.account.isLoggedIn=function(n,t,i,r){var u={doc_id:n,print:t};jQuery.ajax({url:"/account/isloggedin",type:"GET",cache:!1,data:u,dataType:"json",error:function(){r()},success:function(n){i(n)}})},myOfficePreviewCookie=document.cookie,myOfficePreview=!1,ds.account.Download=function(n,t,i,r){myOfficePreviewCookie.indexOf("; showMyOfficePreview=")==-1&&(myOfficePreview=!0);var u={doc_id:n,print:t,preview_office:myOfficePreview};jQuery.ajax({url:"/account/download",type:"GET",cache:!1,data:u,dataType:"json",error:function(){r()},success:function(n){i(n)}})},ds.account.PackageDownload=function(n,t,i){myOfficePreviewCookie.indexOf("; showMyOfficePreview=")==-1&&(myOfficePreview=!0);var r={id:docId,preview_office:myOfficePreview};jQuery.ajax({url:"/account/downloadpackage",type:"GET",cache:!1,data:r,success:function(n){t(n)},error:function(){i()}})},ds.account.getAction=function(n,t,i,r){myOfficePreviewCookie.indexOf("; showMyOfficePreview=")==-1&&(myOfficePreview=!0);var u={doc_id:n,print:t,preview_office:myOfficePreview};jQuery.ajax({url:"/account/getaction",type:"GET",cache:!1,data:u,dataType:"json",error:function(){r()},success:function(n){i(n)}})},ds.account.registerModelOptions={},ds.account.registerModal=function(n,t){function l(){r.find("form").submit(function(n){n.preventDefault(),r.find("form").data("submitting")!==!0&&($("input[type=submit]",r).val("Loading..."),r.find("form").data("submitting",!0),i.register())}),u.keyup(function(){i.checkEmail()}),$(".facebookBtn",r).unbind("click").click(function(n){n.preventDefault();var t=c();t==!0&&ds.account.fbLogin(i.docId,function(n){i.registerSuccess(n)},function(){alert("Error logging into facebook.")})}),r.find(".signIn").click(i.signIn),$("#signInNav").click(function(n){n.preventDefault(),i.resetErrors(),$(document).trigger("signIn")});$(document).on("doc.share.end",function(){i.triggerquestionnaire="True";var n="/scripts/shared/ds.questionnaire.js",t=$.ajax({url:n,async:!1}).responseText;ds.questionnaire.Begin(null,{IsBackdropClosable:!1,triggerDownload:!1})})}function s(n){var t=/^([a-zA-Z0-9_\.\-\+])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;return t.test(n)?!0:!1}function a(n){var t=new RegExp("^(?=.*[a-zA-Z])(?=.*[0-9]).{7,32}$","g");return t.test(n)}function c(){var u=$("#joinModal .join-docstoc"),t=i.getPurposeVal(),r=!0,n=[];return(typeof t=="undefined"||t.length<0)&&!u.is(":hidden")&&(r=!1,$(".join-docstoc").css({"background-color":"#fbe1e1",color:"#39434c"}),n.push("Please choose Business or Personal."),n.length>0&&i.showErrors(e,n)),r}var t=$.extend({},ds.account.registerModelOptions,t),i=this,r=n,h;this.root=r;var u=$("#reguserName",n),f=$("#regpassword",n),v=t.docId,e="input:radio[name=purpose]",y,o=[];this.emailValid=!0,this.currentEmailTimeout=0,this.emailCheckCancelled=!0,this.triggerquestionnaire=!1,console.log("DOM triggerquestionnaire = "+this.triggerquestionnaire),this.isDownload=$(".myoffice-container").attr("data-triggerdownload"),this.setDocId=function(n){this.docId=n},this.signIn=function(n){typeof n!="undefined"&&typeof n.preventDefault=="function"&&n.preventDefault(),$("#joinModal").hide(),$(document).trigger("signIn")},this.loadQuestionnaire=function(){$(document).trigger("modal-close"),$(document).trigger("questionnaire"),$("section[id='content']").hide(),$("section[id^='q-']").hide(),$(".heading-wrapper .title[data-trigger^='q-']").hide(),$(".footer-wrapper span[id^='footer-q-']").removeClass("active"),$("#quest-footer").hide(),$("section[id='q-1']").show(),$(".heading-wrapper .title[data-trigger='q-1']").show(),$(".footer-wrapper span[id='footer-q-1']").addClass("active")},this.getUserNameVal=function(){return u.val()},this.getPasswordVal=function(){return f.val()},this.getPurposeVal=function(){return $(e+":checked").val()},this.registerSuccess=function(){$("#joinModal").hide(),$("#loginModal").hide();var t="https://"+location.host+"/account/redirectback?next="+encodeURIComponent(location.href);ds.runtime&&ds.runtime.registrationQuestionnaire?ds.runtime.registrationQuestionnaire().always(function(){location.href=t}):location.href=t},this.register=function(){i.cancelEmailCheck();var n=i.getUserNameVal(),s=i.getPasswordVal(),t=i.getPurposeVal();i.resetErrors(),i.validate()?ds.account.register(n,s,t,i.docId,function(r){ds&&ds.track&&ds.track.activity(!r||!r.Success||!r.MemId||r.MemId<1?"registration-failure":"registration-successful",location.pathname||"","account.js.register.success",{response:r,userName:n}),ds.isOxnardKissEnabled&&_kmdoc("Registered Oxford"),$(document).trigger("Registered",[r.MemId]);var u=[];u.push(t),ds.isOxnardUser&&(o=ds.OxnardClassifications),o.length>0?(console.log("QUESTIONNAIRE CODE ENTERED"),$.merge(u,o),ds.account.questionnare(u,function(){i.registerSuccess(r)},function(){i.registerSuccess(r)})):i.registerSuccess(r)},function(t){ds&&ds.track&&ds.track.activity("registration-failure",location.pathname||"","account.js.register.error",{response:t,userName:n}),$("input[type=submit]",r).val("Join"),r.find("form").data("submitting",!1),t.Errors.UserName&&t.Errors.UserName.length>0&&i.showErrors(u,t.Errors.UserName),t.Errors.Password&&t.Errors.Password.length>0&&i.showErrors(f,t.Errors.Password),t.Errors.Password&&t.Errors.DocstocPurpose&&t.Errors.DocstocPurpose.length>0&&i.showErrors(e,t.Errors.DocstocPurpose),t.Errors.DuplicateEmail&&t.Errors.DuplicateEmail.length>0&&($.isArray(t.Errors.DuplicateEmail)||(t.Errors.DuplicateEmail=[t.Errors.DuplicateEmail]),t.Errors.DuplicateEmail.push("<a href='#' id='reg2login'>Sign In<\/a>"),i.showErrors(u,t.Errors.DuplicateEmail,"#reg2login","click",function(t){ds.track&&ds.track.activity("signin-from-dup-email",window.location.href,"ds.account.registerModal.register.infoMsg",{email:n}),i.signIn(t)})),t.Errors.Register&&t.Errors.Register.length>0&&i.showErrors(u,t.Errors.Register)}):($("input[type=submit]",r).val("Join"),r.find("form").data("submitting",!1))},this.checkEmail=function(){i.currentEmailTimeout&&clearTimeout(i.currentEmailTimeout),i.currentEmailTimeout=setTimeout(function(){var n,r,t;i.emailCheckCancelled=!1,n=i.getUserNameVal(),i.emailValid=!0,s(n)?(r={email:n},$.ajax({url:"/account/checkemail",type:"GET",cache:!1,data:r,dataType:"json",error:function(){i.emailValid=!1},success:function(t){var e,o;i.emailCheckCancelled||(i.resetErrors(),t?(e=[],e.push("Available"),i.showInfo(u,e)):(e=[],e.push("Email is already Registered."),e.push("<a href='#' id='email2login'>Sign In<\/a>"),o="Docstoc is now a part of the Intuit Inc. family, makers of Quickbooks, TurboTax, and other great products. If you already use an Intuit product, you can sign into Docstoc using those existing credentials.",e.push(" or <a href='#' data-toggle='tooltip' data-placement='bottom' title='"+o+"'>Learn More<\/a>"),i.showErrors(u,e,"#email2login","click",function(t){ds.track&&ds.track.activity("signin-from-dup-email",window.location.href,"ds.account.registerModal.checkEmail.infoMsg",{email:n}),i.signIn(t)}),$("body").tooltip({selector:"[data-toggle=tooltip]"})))}})):(i.resetErrors(),t=[],t.push("Not a Valid Email"),i.showErrors(u,t))},1e3)},this.cancelEmailCheck=function(){i.emailCheckCancelled=!0,i.currentEmailTimeout&&(clearTimeout(i.currentEmailTimeout),i.currentEmailTimeout=0)},this.showErrors=function(n,t,i,r,u){this.showHelp(n,t,"error",i,r,u)},this.showInfo=function(n,t,i,r,u){this.showHelp(n,t,"info",i,r,u)},this.showHelp=function(n,t,i,r,u,f){var c=$(n),h=c.closest(".control-group"),o,e,s;for(h.addClass(i),o="",e=0;e<t.length;e++)o+=" "+t[e];if(s=h.find(".help-inline"),s.html(o),typeof r!="undefined"&&r&&f&&typeof f=="function"&&typeof u!="undefined")s.find(r).on(u,f)},this.resetErrors=function(){var n=$(".control-group");n.removeClass("error"),n.removeClass("info"),n.find(".help-inline").html("")},h=ds.utils.oneTimePromise(function(){return ds.apis.MembersApi.bucketUser(t.docId||undefined,"")}),this.getGroupId=function(){return h().then(function(n){return n.SubscriptionGroup.Id},function(){return 0})},this.validate=function(){var o=$("#joinModal .password"),n=!0,h=i.getUserNameVal(),t=[],l,e,r;return(h.length<=0?(n=!1,t.push("Email is required")):s(h)?i.emailValid||(n=!1,t.push("Email is not valid")):(n=!1,t.push("Email is not valid")),l=c(),l||(n=!1),t.length>0&&i.showErrors(u,t),!o.length||!o.is(":hidden"))?(e=i.getPasswordVal(),r=[],e.length<=0?(n=!1,r.push("Password is required")):a(e)||(n=!1,r.push("Password must be 7-32 characters with a mix of letters & numbers")),r.length>0&&i.showErrors(f,r),n):n},l(),$(document).bind("signIn",function(){i.getGroupId().done(function(){$("#joinModal .password").show(),$("#joinModal .join-docstoc").hide(),$(".modal-header .subtitle").removeClass("docfont-18"),$(document).trigger("hideFb"),$("#loginModal").fadeIn(200),$(".modal-backdrop").fadeIn(500),$(document).trigger("signInCalled"),$(document.body).animate({scrollTop:$("#loginModal").offset().top})})})},$(".close, .modal-backdrop, .loader-display").click(function(){$(document).trigger("modal-close")}),$(document).bind("modal-close",function(){$(".modal-backdrop").hide(),$(".modal").hide(),$(".loader-display").hide(),$("#questionnaire").hide()}),ds.account.loginModal=function(n,t){function o(){$("#loginModal",r).find(".joinLink").click(function(n){n.preventDefault(),$("#loginModal").hide(),$(document).trigger("join")}),$("#joinSignInModal").click(function(n){n.preventDefault(),$(document).trigger("modal-close"),$(document).trigger("join"),i.resetErrors()}),$("#joinNav").click(function(n){n.preventDefault(),$(document).trigger("join"),i.resetErrors()}),$("#joinPlansTop").click(function(n){n.preventDefault(),$(document).trigger("join"),i.resetErrors()}),$("#joinPlansBottom").click(function(n){n.preventDefault(),$(document).trigger("join"),i.resetErrors()}),$("#loginForm").submit(function(n){n.preventDefault(),r.find("form").data("submitting")!==!0&&($("input[type=submit]",r).val("Loading..."),r.find("form").data("submitting",!0),i.login())}),$(".facebookBtn",r).unbind("click").click(function(n){n.preventDefault(),ds.account.fbLogin(i.docId,function(n){i.loginSuccess(n)},function(){alert("Error logging into facebook.")})})}var t=$.extend({},ds.account.registerModelOptions,t),i=this,r=n,s,h,u=$("#userName",n),e=$("#password",n),f;this.root=r,this.setDocId=function(n){this.docId=n},this.loginSuccess=function(){$("#joinModal").hide(),$("#loginModal").hide(),$(".modal-backdrop").hide();var n="https://"+location.host+"/account/RedirectBack?next="+encodeURIComponent(location.href);ds.runtime&&ds.runtime.registrationQuestionnaire?ds.runtime.registrationQuestionnaire().always(function(){location.href=n}):location.href=n},this.showErrors=function(n,t){this.showHelp(n,t,"error")},this.showInfo=function(n,t){this.showHelp(n,t,"info")},this.showHelp=function(n,t,i){var e=$(n),f=e.closest(".control-group"),u,r;for(f.addClass(i),u="",r=0;r<t.length;r++)u+=" "+t[r];f.find(".help-inline").html(u)},this.resetErrors=function(){var n=$(".control-group");n.removeClass("error"),n.removeClass("info"),n.find(".help-inline").html("")},f=ds.utils.oneTimePromise(function(){return ds.apis.MembersApi.bucketUser(t.docId||undefined,"")}),this.getGroupId=function(){return f().then(function(n){return console.log("promise returned"),n.SubscriptionGroup.Id},function(){return 0})},this.login=function(){ds.account.login($("#userName",r).val(),$("#password",r).val(),function(n){i.loginSuccess(n),$(document).trigger("LoggedIn",[n.MemId])},function(n){$("input[type=submit]",r).val("Sign In"),r.find("form").data("submitting",!1),n.Errors.UserName&&n.Errors.UserName.length>0&&i.showErrors(u,n.Errors.UserName),n.Errors.Password&&n.Errors.Password.length>0&&i.showErrors(e,n.Errors.Password),n.Errors.Login&&n.Errors.Login.length>0&&i.showErrors(u,n.Errors.Login)})},o(),$(document).bind("join",function(){$("#joinModal .password").show(),$("#joinModal .join-docstoc").hide(),$(".modal-header .subtitle").removeClass("docfont-18"),$(document).trigger("hideFb"),$("#joinModal").fadeIn(200,_kmdoc("Viewed Signup Form")),$(".modal-backdrop").fadeIn(500),$(document.body).animate({scrollTop:$("#joinModal").offset().top})})},$(document).bind("hideFb",function(){$("#joinModal .password").show(),$("#joinModal .facebookBtnWrap").hide(),$("#joinModal .ordivider").hide(),$("#joinModal").addClass("hide-fb-modal"),$("#loginModal .password").show(),$("#loginModal .facebookBtnWrap").hide(),$("#loginModal .ordivider").hide(),$("#loginModal").addClass("hide-fb-modal"),$(".modal-header").addClass("hide-fb")}),$(document).bind("questionnaire",function(){$("#questionnaire").fadeIn(200),$(".modal-backdrop").fadeIn(500)}),$(document).bind("freedocs",function(){$(".modal").hide(),$("#freedocs-content").fadeIn(200)}),$(document).bind("registerModals",function(){modal=new ds.account.registerModal($("#joinModal")),loginModal=new ds.account.loginModal($("#loginModal"))}),docCookies={getItem:function(n){return decodeURIComponent(document.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*"+encodeURIComponent(n).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*([^;]*).*$)|^.*$"),"$1"))||null},setItem:function(n,t,i,r,u,f){if(!n||/^(?:expires|max\-age|path|domain|secure)$/i.test(n))return!1;var e="";if(i)switch(i.constructor){case Number:e=i===Infinity?"; expires=Fri, 31 Dec 9999 23:59:59 GMT":"; max-age="+i;break;case String:e="; expires="+i;break;case Date:e="; expires="+i.toUTCString()}return document.cookie=encodeURIComponent(n)+"="+encodeURIComponent(t)+e+(u?"; domain="+u:"")+(r?"; path="+r:"")+(f?"; secure":""),!0},removeItem:function(n,t,i){return!n||!this.hasItem(n)?!1:(document.cookie=encodeURIComponent(n)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT"+(i?"; domain="+i:"")+(t?"; path="+t:""),!0)},hasItem:function(n){return new RegExp("(?:^|;\\s*)"+encodeURIComponent(n).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(document.cookie)},keys:function(){for(var t=document.cookie.replace(/((?:^|\s*;)[^\=]+)(?=;|$)|^\s*|\s*(?:\=[^;]*)?(?:\1|$)/g,"").split(/\s*(?:\=[^;]*)?;\s*/),n=0;n<t.length;n++)t[n]=decodeURIComponent(t[n]);return t}},window.ds=window.ds||{},function(n,t,i,r){var f=function(n,t,i,r){var u={},h=r||"",f=n||"",e=t||"",o=i||"",s="/semantic";return u.Version="0.1.0-beta",u.UseForwarding=function(){return!!o},u.Host=function(n){if(n)n=n.replace("https://","").replace("http://",""),n[n.length-1]==="/"&&(n=n.substring(0,n.length-1)),f=n;else return h+f},u.HasVersionPath=function(){return!!e},u.VersionPath=function(){return e},u.SemanticLocation=function(){return u.UseForwarding()?o+s:u.Host()+"/"+u.VersionPath()+s},u}("","api","/api/fwd"),u=n!==r,h=function(){function r(n,t,i){this.TopLevelState=n,this.MidLevelState=t,this.LowLevelState=i}function e(n){return new ds.semantic.models.Selection(n.TopLevelState,n.MidLevelState,n.LowLevelState)}var i=function(){};return i.prototype={choices:function(i){var e=null,o;return i&&(e=new r(i.Stage,i.Activity,i.Task)),o={"X-Requested-With":"XMLHttpRequest",Accept:"application/json"},f.UseForwarding()&&(o["ds-send-to-api"]=f.Host()+(f.HasVersionPath()?", "+f.VersionPath():"")),u&&n.log("Sending semantic request: "+(e?t.param(e):"null")),t.ajax(f.SemanticLocation(),{type:"GET",data:e,headers:o})},location:function(){},FromServiceStateModel:e},new i}(),e={Selection:function(n,t,i){var r=this,u=n||"",f=t||"",e=i||"";r.getStage=function(){return u},r.getActivity=function(){return f},r.getTask=function(){return e},r.Stage=u,r.Activity=f,r.Task=e},Choices:function(n,t,i,r){var u=this,f=n||[],o=t||[],s=i||[],h=r?new e.Selection(r.TopLevelState||null,r.MidLevelState||null,r.LowLevelState||null):new e.Selection;u.getStages=function(){return f},u.getActivities=function(){return o},u.getTasks=function(){return s},u.getCurrent=function(){return h},u.Stages=f,u.Activities=o,u.Tasks=s,u.Current=h}},s,o;e.Selection.prototype={Equals:function(n){return n instanceof e.Selection?this.Stage===n.Stage&&this.Activity===n.Activity&&this.Task===n.Task:!1}},e.Choices.prototype={},s=function(){function e(n,t){var r,i;if(!n||!n.length||!t)return"";for(r="",i=0;i<n.length;i++)if(n[i].UriName&&n[i].Name&&n[i].UriName===t){r=n[i].Name;break}return r}var i=function(){},o=function(i,o){function w(){return 7e3}function g(i){if(i===r||i===null||i instanceof ds.semantic.models.Selection){if(i==r||i==null){if(h==null)return;i=new ds.semantic.models.Selection}h!=null&&h.Equals(i)||(nt(),ds.semantic.service.choices(i).done(function(n){var i=h;if(c=new ds.semantic.models.Choices(n.TopLevelAvailable,n.MidLevelAvailable,n.LowLevelAvailable,n.EffectiveState),c.Current.Equals(h)){b(w());return}h=c.Current,s.Selection=h,t('input[type="submit"]',v).fadeOut(),p.each(function(n,i){var r=t(i),u=r.data("sel"),f=r.data("list"),o=r.data("val");o!==h[u]&&r.fadeOut(function(){r.data("val",h[u]),t(this).html(e(c[f],h[u]).toLowerCase()).fadeIn(a.itemFadeIn),t('input[type="submit"]',v).fadeIn(1200)})}),p.promise().done(function(){rt(h,i)})}).fail(function(t,i,r){u&&(n.log("Error getting choices from API"),n.log("Return status: "+t.status+'; status: "'+i+'"; error: "'+r+'"'),n.log("Response text: "+t.responseText)),b(w())}))}}function rt(n,t){l.changed.fire(n,t),b(w())}var s=this,a=t.extend({},{selection:null,placeholder:"xxx-wont-find",doFormGet:!1,randomize:!1,itemFadeIn:1e3},o),l,d;o.host&&f.Host(o.host),l={loaded:t.Callbacks("once","memory"),changed:t.Callbacks(),submitted:t.Callbacks("memory")},s.changed=function(n){return l.changed.add(n),s},s.loaded=function(n){return l.loaded.add(n),s},s.submitted=function(n){return l.submitted.add(n),s};var v=i,tt=t(a.placeholder),p=t("[data-sel]",i),it=t("form",i);s.DoFormGet=a.doFormGet,it.submit(function(n){if(!h)return n.preventDefault(),!1;var i="/"+["topics",h.Stage,h.Activity,h.Task].join("/");return t(this).attr({method:"GET",action:i}),s.DoFormGet||n.preventDefault(),l.submitted.fire(i,n),s.DoFormGet}),s.submit=function(){it.submit()},v.hover(function(){nt()},function(){b(w())});var h=a.selection&&a.selection instanceof ds.semantic.models.Selection?a.selection:null,c=null,y=null,k=!1;if(s.$View=v,s.Selection=h,s.isLoaded=k,s.showView=function(){return v.show(),tt.hide(),s},s.hideView=function(){return v.hide(),tt.show(),s},s.set=function(n){return g(n),s},p.size()===0)l.loaded.fire('No selectables found. Please use the "data-sel" attribute');else{p.click(function(n){nt(!0),n.preventDefault();var i=t(this),f=i.position(),b=i.outerWidth(),e=i.prev().position(),a=i.prev().outerWidth(),v=i.offsetParent(),r=f.left,y=n.pageX-i.offset().left;r<e.left&&f.top==e.top&&y>r+v.outerWidth()/2&&(r=e.left+a);var s=i.data("sel"),o=i.data("list"),p=c[o].length*15,u=t('<div class="semantic-select-box modal"><\/div>').css({position:"absolute",top:f.top-p,left:r,height:"auto",width:"auto",marginLeft:"auto",display:"none"}).appendTo(i.parent()),w=t("<ul><\/ul>").appendTo(u),l=t('<div class="modal-backdrop"><\/div>').css({position:"absolute",width:t(document).width(),height:t(document).height(),display:"none"}).click(function(){t(this).fadeOut(200,function(){t(this).remove()}),u.delay(100).fadeOut(200,function(){t(this).remove()})}).appendTo(t("body"));return t.each(c[o],function(n,i){var r=t('<li class="semantic-choice"><\/li>').appendTo(w);t('<a href="#"><\/a>').data("sel",s).data("val",i.UriName).data("list",o).html(i.Name.toLowerCase()).click(function(n){n.preventDefault();var i=null;switch(s){case"Stage":i=new ds.semantic.models.Selection(t(this).data("val"));break;case"Activity":i=new ds.semantic.models.Selection(h.Stage,t(this).data("val"));break;case"Task":i=new ds.semantic.models.Selection(h.Stage,h.Activity,t(this).data("val"))}return i&&g(i),l.fadeOut(200,function(){t(this).remove()}),u.delay(100).fadeOut(200,function(){t(this).remove()}),!1}).appendTo(r)}),u.fadeIn(200),l.delay(100).fadeIn(200),!1}),s.loaded(function(n){n||b(w())}),d=a.randomize,s.LogRandomizer=!0;function b(t){setTimeout(function(){d&&!y?(u&&s.LogRandomizer&&n.log("Starting Randomizer w/ timeout: "+t),y=setTimeout(ut,t)):u&&s.LogRandomizer&&n.log("Skipping Randomizer Start b/c "+(d?y?"already running":"don't know":"restart disabled"))},0)}function nt(t){y?(u&&s.LogRandomizer&&n.log("Stopping currently running randomizer"),clearTimeout(y)):u&&s.LogRandomizer&&n.log("Can't stop randomizer that is not running"),y=null,t&&(u&&s.LogRandomizer&&n.log("--- STOPPING Randomizer FOR GOOD ---"),d=!1)}function ut(){var r=[],t=null,n=0,i=0;do i++,n=Math.floor(Math.random()*c.Stages.length),c.Stages[n].UriName!==h.Stage&&(t=new ds.semantic.models.Selection(c.Stages[n].UriName)),t||(n=Math.floor(Math.random()*c.Activities.length),c.Activities[n].UriName!==h.Activity&&(t=new ds.semantic.models.Selection(h.Stage,c.Activities[n].UriName))),t||(n=Math.floor(Math.random()*c.Tasks.length),c.Tasks[n].UriName!==h.Task&&(t=new ds.semantic.models.Selection(h.Stage,h.Activity,c.Tasks[n].UriName)));while(!t&&i<20);g(t)}ds.semantic.service.choices(this._current).done(function(n){c=new ds.semantic.models.Choices(n.TopLevelAvailable,n.MidLevelAvailable,n.LowLevelAvailable,n.EffectiveState),h=c.Current,s.Selection=h,p.each(function(n,i){var r=t(i),u=r.data("sel"),f=r.data("list");r.data("val",h[u]),r.html(e(c[f],h[u]).toLowerCase())}),k=!0,s.isLoaded=k,l.loaded.fire()}).fail(function(n,t,i){k=!1,l.loaded.fire(i)})}};return o.prototype={show:function(){throw Error("Currently 'form.show' is not supported. Use 'form.showView' instead");this.showView()},hide:function(){throw Error("Currently 'form.hide' is not supported. Use 'form.hideView' instead");this.hideView()}},i.prototype={create:function(n,i){if(!n)throw Error("cannot create a form without a View");var r=t.extend({},{placeholder:n+".placeholder"},i);return new o(t(n),r)}},new i}(),o=function(){this.service=h,this.models=e,this.form=s},o.prototype={},i.semantic=new o}(window.console,window.jQuery,window.ds),Date.$VERSION=1.02,Date.LZ=function(n){return(n<0||n>9?"":"0")+n},Date.monthNames=["January","February","March","April","May","June","July","August","September","October","November","December"],Date.monthAbbreviations=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Date.dayNames=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],Date.dayAbbreviations=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],Date.preferAmericanFormat=!0,Date.prototype.getFullYear||(Date.prototype.getFullYear=function(){var n=this.getYear();return n<1900?n+1900:n}),Date.parseString=function(n,t){var d,v,g,b,l,o,k;if(typeof t=="undefined"||t==null||t==""){var ut=["y-M-d","MMM d, y","MMM d,y","y-MMM-d","d-MMM-y","MMM d","MMM-d","d-MMM"],nt=["M/d/y","M-d-y","M.d.y","M/d","M-d"],tt=["d/M/y","d-M-y","d.M.y","d/M","d-M"],it=[ut,Date.preferAmericanFormat?nt:tt,Date.preferAmericanFormat?tt:nt];for(o=0;o<it.length;o++)for(d=it[o],v=0;v<d.length;v++)if(g=Date.parseString(n,d[v]),g!=null)return g;return null}this.isInteger=function(n){for(var t=0;t<n.length;t++)if("1234567890".indexOf(n.charAt(t))==-1)return!1;return!0},this.getInt=function(n,t,i,r){for(var f,u=r;u>=i;u--){if(f=n.substring(t,t+u),f.length<i)return null;if(this.isInteger(f))return f}return null},n=n+"",t=t+"";for(var r=0,a=0,rt="",i="",ft="",y,p,e=(new Date).getFullYear(),f=1,s=1,u=0,h=0,c=0,w="";a<t.length;){for(rt=t.charAt(a),i="";t.charAt(a)==rt&&a<t.length;)i+=t.charAt(a++);if(i=="yyyy"||i=="yy"||i=="y"){if(i=="yyyy"&&(y=4,p=4),i=="yy"&&(y=2,p=2),i=="y"&&(y=2,p=4),e=this.getInt(n,r,y,p),e==null)return null;r+=e.length,e.length==2&&(e=e>70?1900+ +e:2e3+ +e)}else if(i=="MMM"||i=="NNN"){for(f=0,l=i=="MMM"?Date.monthNames.concat(Date.monthAbbreviations):Date.monthAbbreviations,o=0;o<l.length;o++)if(b=l[o],n.substring(r,r+b.length).toLowerCase()==b.toLowerCase()){f=o%12+1,r+=b.length;break}if(f<1||f>12)return null}else if(i=="EE"||i=="E"){for(l=i=="EE"?Date.dayNames:Date.dayAbbreviations,o=0;o<l.length;o++)if(k=l[o],n.substring(r,r+k.length).toLowerCase()==k.toLowerCase()){r+=k.length;break}}else if(i=="MM"||i=="M"){if(f=this.getInt(n,r,i.length,2),f==null||f<1||f>12)return null;r+=f.length}else if(i=="dd"||i=="d"){if(s=this.getInt(n,r,i.length,2),s==null||s<1||s>31)return null;r+=s.length}else if(i=="hh"||i=="h"){if(u=this.getInt(n,r,i.length,2),u==null||u<1||u>12)return null;r+=u.length}else if(i=="HH"||i=="H"){if(u=this.getInt(n,r,i.length,2),u==null||u<0||u>23)return null;r+=u.length}else if(i=="KK"||i=="K"){if(u=this.getInt(n,r,i.length,2),u==null||u<0||u>11)return null;r+=u.length,u++}else if(i=="kk"||i=="k"){if(u=this.getInt(n,r,i.length,2),u==null||u<1||u>24)return null;r+=u.length,u--}else if(i=="mm"||i=="m"){if(h=this.getInt(n,r,i.length,2),h==null||h<0||h>59)return null;r+=h.length}else if(i=="ss"||i=="s"){if(c=this.getInt(n,r,i.length,2),c==null||c<0||c>59)return null;r+=c.length}else if(i=="a"){if(n.substring(r,r+2).toLowerCase()=="am")w="AM";else if(n.substring(r,r+2).toLowerCase()=="pm")w="PM";else return null;r+=2}else{if(n.substring(r,r+i.length)!=i)return null;r+=i.length}}if(r!=n.length)return null;if(f==2)if(e%4==0&&e%100!=0||e%400==0){if(s>29)return null}else if(s>28)return null;return(f==4||f==6||f==9||f==11)&&s>30?null:(u<12&&w=="PM"?u=+u+12:u>11&&w=="AM"&&(u-=12),new Date(e,f-1,s,u,h,c))},Date.isValid=function(n,t){return Date.parseString(n,t)!=null},Date.prototype.isBefore=function(n){return n==null?!1:this.getTime()<n.getTime()},Date.prototype.isAfter=function(n){return n==null?!1:this.getTime()>n.getTime()},Date.prototype.equals=function(n){return n==null?!1:this.getTime()==n.getTime()},Date.prototype.equalsIgnoreTime=function(n){if(n==null)return!1;var t=new Date(this.getTime()).clearTime(),i=new Date(n.getTime()).clearTime();return t.getTime()==i.getTime()},Date.prototype.format=function(n){n=n+"";var u="",f=0,s="",e="",r=this.getYear()+"",o=this.getMonth()+1,h=this.getDate(),c=this.getDay(),i=this.getHours(),l=this.getMinutes(),a=this.getSeconds(),v,y,p,w,b,k,d,g,nt,tt,it,rt,ut,ft,et,t={};for(r.length<4&&(r=""+(+r+1900)),t.y=""+r,t.yyyy=r,t.yy=r.substring(2,4),t.M=o,t.MM=Date.LZ(o),t.MMM=Date.monthNames[o-1],t.NNN=Date.monthAbbreviations[o-1],t.d=h,t.dd=Date.LZ(h),t.E=Date.dayAbbreviations[c],t.EE=Date.dayNames[c],t.H=i,t.HH=Date.LZ(i),t.h=i==0?12:i>12?i-12:i,t.hh=Date.LZ(t.h),t.K=t.h-1,t.k=t.H+1,t.KK=Date.LZ(t.K),t.kk=Date.LZ(t.k),t.a=i>11?"PM":"AM",t.m=l,t.mm=Date.LZ(l),t.s=a,t.ss=Date.LZ(a);f<n.length;){for(s=n.charAt(f),e="";n.charAt(f)==s&&f<n.length;)e+=n.charAt(f++);u=typeof t[e]!="undefined"?u+t[e]:u+e}return u},Date.prototype.getDayName=function(){return Date.dayNames[this.getDay()]},Date.prototype.getDayAbbreviation=function(){return Date.dayAbbreviations[this.getDay()]},Date.prototype.getMonthName=function(){return Date.monthNames[this.getMonth()]},Date.prototype.getMonthAbbreviation=function(){return Date.monthAbbreviations[this.getMonth()]},Date.prototype.clearTime=function(){return this.setHours(0),this.setMinutes(0),this.setSeconds(0),this.setMilliseconds(0),this},Date.prototype.add=function(n,t){if(typeof n=="undefined"||n==null||typeof t=="undefined"||t==null)return this;if(t=+t,n=="y")this.setFullYear(this.getFullYear()+t);else if(n=="M")this.setMonth(this.getMonth()+t);else if(n=="d")this.setDate(this.getDate()+t);else if(n=="w")for(var i=t>0?1:-1;t!=0;){for(this.add("d",i);this.getDay()==0||this.getDay()==6;)this.add("d",i);t-=i}else n=="h"?this.setHours(this.getHours()+t):n=="m"?this.setMinutes(this.getMinutes()+t):n=="s"&&this.setSeconds(this.getSeconds()+t);return this},window.ds=window.ds||{},ds.mns=ds.mns||{},ds.foodie=ds.foodie||{},ds.foodie.banner=function(n,t){function u(n){$(t.Exclusion).each(function(n,i){$(i).length>0&&(t.isActive=!1)}),t.isActive&&jQuery.ajax({url:n,type:"GET",cache:!1,dataType:"HTML",error:function(n,t,i){console.log(i)},success:function(n){if(n!=null){var u=0;$(t.InsertAfter).each(function(t,i){var r,t;if($(i).length>0&&u<=0)for($(i).after(n),u++,r=$(".doc-card-img"),t=0;r.length>t;t++){if(t==6)break;r[t].setAttribute("src",r[t].getAttribute("data-src"))}$(".terms .close-terms").on("click",function(){var n=new Date;n.setTime(n.getTime+2592e6),document.cookie="TermsBannerClosed=true; expires"+n.toGMTString()+"; path=/",$(".terms").slideUp("slow")})})}}})}var f={showBanner:!1,isActive:!0,BannerUrl:"/Home/FoodieBannerFull",NotFoodieBannerUrl:"/Home/FoodieBannerUpsell",TermsBannerUrl:"/Home/Terms",IsTermBanner:!1,InsertAfter:[$("[class*='breadcrumbs']"),$("[class*='old-myoffice']"),$(".topic .header-module"),$(".nav-inline + #foodie-banner")],Exclusion:[$("form[action^='/pass']"),$("div.docpage-container"),$("#newsletter-upsell-container")],FirstMemId:50398339,LastMemId:50917996},e,i,r;if(t=$.extend(f,t),e=this,i=$(n),i.length<=0)return null;r=document.cookie,CurrentUserID<t.LastMemId&&CurrentUserID>0&&r.indexOf("; TermsBannerClosed=")==-1&&(t.IsTermBanner=!0,u(t.TermsBannerUrl)),CurrentUserID>=t.FirstMemId&&!t.IsTermBanner&&jQuery.ajax({url:"/account/GetClassifications",type:"GET",cache:!1,dataType:"JSON",error:function(){error()},success:function(n){n.ClassificationList!=null&&n.ClassificationList.length>0&&$.each(n.ClassificationList,function(n,i){switch(i){case 131:t.showBanner=!0,u(t.BannerUrl)}})}})},ds.mns.upsell=function(n,t){function e(){var o,e,f,s,h;if($(n).length===0||(o=!0,$(t.Exclusion).each(function(n,t){$(t).length>0&&(o=!1)}),!o))return null;$(t.InsertAfter).each(function(n,t){$(t).length>0&&(i=$(t))}),e="",r.GetHtml(function(n){e=n},function(){}),e!=null&&(f=e,s=!0,s?r.GetClassifications(function(r){var e,o;if(r.ClassificationList!=null)for(e=0;r.ClassificationList.length>e;e++)switch(r.ClassificationList[e]){case 160:t.Title=t.TitleOptions.Business;break;case 161:t.Title=t.TitleOptions.Personal;break;case 131:f=null}t.Title=t.Title.length===0?t.TitleOptions.Business:t.Title,$(i).length>0?($(i).next().prepend(f),n=$(i).next()):$(n).html(f),o=$("#banner-title-replace"),$(o).text(t.Title),$(n).show(),u()},function(){}):($(i).length>0?($(i).next().prepend(f),n=$(i).next()):$(n).html(f),h=$("#banner-title-replace"),$(h).text(t.Title),$(n).show(),u()))}function u(){function t(n,t,i){var f,u;i?(u=new Date,u.setTime(u.getTime()+i*864e5),f="; expires="+u.toGMTString()):f="",document.cookie=n+"="+t+f+"; path=/"}$(".icon-close",n).click(function(n){n.preventDefault(),t("upsellMNSClosed",JSON.stringify({upsellMNSClosed:!0}),1,null);var i=$(this).closest(".banner-container");$(document).trigger("close-upsell-alert",i),window.dataLayer&&dataLayer.push({event:"upsell.banner.close"})});$("#closeUserSeller",n).on("click",function(n){n.preventDefault(),t("userSellerClosed",JSON.stringify({userSellerClosed:!0}),365,null),ds.track.activity("user-seller-closed",window.location.href,"userSellerClosed",{memid:CurrentUserID});var i=$(this).closest("#userSellerAlert");$(document).trigger("close-upsell-alert",i)});$("a[name='button']",n).click(function(n){n.preventDefault();var r=$(this).attr("href"),u=$(this).attr("data-value"),t=!1,i="";switch(u){case"resources":t=!0,i="learn more";break;case"pass":t=!0,i="plans"}t&&window.dataLayer&&dataLayer.push({event:"upsell.banner.click","banner.label":i}),location.href=r}),$(document).bind("close-upsell-alert",function(n,t){$(t).slideUp("slow")}),window.dataLayer&&dataLayer.push({event:"upsell.banner.loaded"})}var f={CanOpen:!0,IsSeller:!1,TemplateUrl:"/Content/templates/UpsellMNS.html",TemplateSellerUrl:"/Content/templates/UserSellerALert.html",InsertAfter:[],Exclusion:[$("form[action^='/pass']"),$("div.docpage-container"),$("#newsletter-upsell-container"),$("div.upsell-container"),$(".foodie-banner-full")],GoogleAnalytics:{Category:"2014-upsell-test",Value:{ButtonClick:"click-btn",UpsellLoaded:"upsell-loaded"},Label:{LearnMore:"learn more",Plans:"plans",Close:"closed",Loaded:"loaded"}},Title:"",TitleOptions:{Personal:"Invest in your personal and professional future.",Business:"Help your business thrive."}},r,i;t=$.extend(f,t),r=this,i="",n=$(n),this.GetHtml=function(n,i){var r;r=t.IsSeller?$.ajax({url:t.TemplateSellerUrl,async:!1}).responseText:$.ajax({url:t.TemplateUrl,async:!1}).responseText,r!=null?n(r):i()},this.GetClassifications=function(n,t){jQuery.ajax({url:"/account/GetClassifications",type:"GET",cache:!1,dataType:"JSON",error:function(){t()},success:function(t){n(t)}})},e()},ds.mns.getCookie=function(n){for(var r=n+"=",u=document.cookie.split(";"),i,t=0;t<u.length;t++)if(i=u[t].trim(),i.indexOf(r)==0)return i.substring(r.length,i.length);return""},$(document).ready(function(){var i=new ds.foodie.banner($("#terms-banner")),r=new ds.foodie.banner($("#foodie-banner")),n=document.cookie,t;n.indexOf("; userSellerClosed")==-1&&(t=new ds.mns.upsell($("#user-seller-alert"),{InsertAfter:[$("[class*='breadcrumbs']"),$("[class*='old-myoffice']"),$(".topic .header-module")],IsSeller:!0}))}),function(n,t){if(n!==t){n("#email-share").on("click",trackEmail);setTimeout(function(){n(document).trigger("setAffix")},8e3),n(document).ready(function(){typeof twttr=="undefined"?n.getScript("http://platform.twitter.com/widgets.js",registerTW):registerTW()})}}(window.jQuery),fbHandleLogin=function(){setTimeout(function(){},1e3)},window.fbAsyncInit=function(){var n=n||0;FB.init({appId:127594755061,channelUrl:"//www.docstoc.com/channel.html",status:!0,cookie:!0,xfbml:!0}),FB.getLoginStatus(function(t){t.status==="connected"?n<0&&fbHandleLogin():FB.Event.subscribe("auth.authResponseChange",function(n){n.authResponse||(window.location="/logout.ashx")})}),FB.Event.subscribe("xfbml.render",function(){$(document).trigger("setAffix"),console.log("FB: Set Affix")}),FB.Event.subscribe("edge.create",function(n){var t=n.split("/"),i=t[4],r=t[3];ds.track.adapter.socialShare(n,"Facebook like","Facebook","FB Like",i,r)}),FB.Event.subscribe("edge.remove",function(n){var t=n.split("/"),i=t[4],r=t[3];ds.track.adapter.socialShare(n,"Facebook unlike","Facebook","FB Unlike",i,r),console.log("GA: FB-UnLike")}),FB.Event.subscribe("message.send",function(){var t=targetUrl.split("/"),i=t[4],r=t[3];ds.track.adapter.socialShare(targetUrl,"Facebook share","Facebook","FB Share",i,r),console.log("ga: fb-messagesend")})}