;
(self.AMP=self.AMP||[]).push({m:1,v:"2603032146000",n:"amp-mustache",ev:"0.2",l:!0,f:function(t,e){(()=>{function e(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function n(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function r(t){for(var r=1;r<arguments.length;r++){var i=null!=arguments[r]?arguments[r]:{};r%2?n(Object(i),!0).forEach((function(n){e(t,n,i[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var{isArray:i}=Array;function o(t,e){const n=[];let r=0;for(let i=0;i<t.length;i++){const o=t[i];e(o,i,t)?n.push(o):(r<i&&(t[r]=o),r++)}return r<t.length&&(t.length=r),n}var{hasOwnProperty:s,toString:a}=Object.prototype;function l(t){const e=Object.create(null);return t&&Object.assign(e,t),e}function c(t){return 1==(null==t?void 0:t.nodeType)}function u(t){return c(t)?t.tagName.toLowerCase()+(t.id?`#${t.id}`:""):t}function f(t,e,n,r,i,o,s,a,l,c,u){return t}function p(t,e){return t}function m(t,e,n,r,i,s,a,l,c,f,p){return function(t,e,n="Assertion failed",r){var i,s;if(e)return e;t&&-1==n.indexOf(t)&&(n+=t);let a=3;const l=n.split("%s");let c=l.shift();const f=[c];for(;l.length;){const t=arguments[a++],e=l.shift();c+=u(t)+e,f.push(t,e.trim())}const p=new Error(c);throw p.messageArray=o(f,(t=>""!==t)),null===(i=(s=self).__AMP_REPORT_ERROR)||void 0===i||i.call(s,p),p}("​​​",t,e,n,r,i,s,a,l,c,f,p)}var{entries:d,setPrototypeOf:h,isFrozen:g,getPrototypeOf:b,getOwnPropertyDescriptor:y}=Object,{freeze:v,seal:w,create:x}=Object,{apply:A,construct:_}="undefined"!=typeof Reflect&&Reflect;A||(A=function(t,e,n){return t.apply(e,n)}),v||(v=function(t){return t}),w||(w=function(t){return t}),_||(_=function(t,e){return new t(...e)});var E,T=L(Array.prototype.forEach),k=L(Array.prototype.pop),R=L(Array.prototype.push),S=L(String.prototype.toLowerCase),O=L(String.prototype.toString),j=L(String.prototype.match),P=L(String.prototype.replace),I=L(String.prototype.indexOf),M=L(String.prototype.trim),D=L(RegExp.prototype.test),z=(E=TypeError,function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return _(E,e)});function L(t){return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return A(t,e,r)}}function F(t,e,n){n=n||S,h&&h(t,null);let r=e.length;for(;r--;){let i=e[r];if("string"==typeof i){const t=n(i);t!==i&&(g(e)||(e[r]=t),i=t)}t[i]=!0}return t}function C(t){const e=x(null);for(const[n,r]of d(t))e[n]=r;return e}function N(t,e){for(;null!==t;){const n=y(t,e);if(n){if(n.get)return L(n.get);if("function"==typeof n.value)return L(n.value)}t=b(t)}return function(t){return console.warn("fallback value for",t),null}}var U=v(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),B=v(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),W=v(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),$=v(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),H=v(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),q=v(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),V=v(["#text"]),G=v(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),X=v(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Y=v(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),K=v(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Z=w(/\{\{[\w\W]*|[\w\W]*\}\}/gm),J=w(/<%[\w\W]*|[\w\W]*%>/gm),Q=w(/\${[\w\W]*}/gm),tt=w(/^data-[\-\w.\u00B7-\uFFFF]/),et=w(/^aria-[\-\w]+$/),nt=w(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),rt=w(/^(?:\w+script|data):/i),it=w(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ot=w(/^html$/i),st=Object.freeze({__proto__:null,MUSTACHE_EXPR:Z,ERB_EXPR:J,TMPLIT_EXPR:Q,DATA_ATTR:tt,ARIA_ATTR:et,IS_ALLOWED_URI:nt,IS_SCRIPT_OR_DATA:rt,ATTR_WHITESPACE:it,DOCTYPE_NAME:ot}),at=()=>"undefined"==typeof window?null:window,lt=function(t,e){if("object"!=typeof t||"function"!=typeof t.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";e.currentScript&&e.currentScript.hasAttribute(r)&&(n=e.currentScript.getAttribute(r));const i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML:t=>t,createScriptURL:t=>t})}catch(t){return console.warn("TrustedTypes policy "+i+" could not be created."),null}},ct=function t(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:at();const n=e=>t(e);if(n.version="3.0.2",n.removed=[],!e||!e.document||9!==e.document.nodeType)return n.isSupported=!1,n;const r=e.document;let{document:i}=e;const{DocumentFragment:o,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:c,NamedNodeMap:u=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:f,DOMParser:p,trustedTypes:m}=e,h=l.prototype,g=N(h,"cloneNode"),b=N(h,"nextSibling"),y=N(h,"childNodes"),w=N(h,"parentNode");if("function"==typeof s){const t=i.createElement("template");t.content&&t.content.ownerDocument&&(i=t.content.ownerDocument)}const x=lt(m,r),A=x?x.createHTML(""):"",{implementation:_,createNodeIterator:E,createDocumentFragment:L,getElementsByTagName:Z}=i,{importNode:J}=r;let Q={};n.isSupported="function"==typeof d&&"function"==typeof w&&_&&void 0!==_.createHTMLDocument;const{MUSTACHE_EXPR:tt,ERB_EXPR:et,TMPLIT_EXPR:rt,DATA_ATTR:it,ARIA_ATTR:ct,IS_SCRIPT_OR_DATA:ut,ATTR_WHITESPACE:ft}=st;let{IS_ALLOWED_URI:pt}=st,mt=null;const dt=F({},[...U,...B,...W,...H,...V]);let ht=null;const gt=F({},[...G,...X,...Y,...K]);let bt=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),yt=null,vt=null,wt=!0,xt=!0,At=!1,_t=!0,Et=!1,Tt=!1,kt=!1,Rt=!1,St=!1,Ot=!1,jt=!1,Pt=!0,It=!1;const Mt="user-content-";let Dt=!0,zt=!1,Lt={},Ft=null;const Ct=F({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Nt=null;const Ut=F({},["audio","video","img","source","image","track"]);let Bt=null;const Wt=F({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),$t="http://www.w3.org/1998/Math/MathML",Ht="http://www.w3.org/2000/svg",qt="http://www.w3.org/1999/xhtml";let Vt=qt,Gt=!1,Xt=null;const Yt=F({},[$t,Ht,qt],O);let Kt;const Zt=["application/xhtml+xml","text/html"],Jt="text/html";let Qt,te=null;const ee=i.createElement("form"),ne=function(t){return t instanceof RegExp||t instanceof Function},re=function(t){te&&te===t||(t&&"object"==typeof t||(t={}),t=C(t),Kt=Kt=-1===Zt.indexOf(t.PARSER_MEDIA_TYPE)?Jt:t.PARSER_MEDIA_TYPE,Qt="application/xhtml+xml"===Kt?O:S,mt="ALLOWED_TAGS"in t?F({},t.ALLOWED_TAGS,Qt):dt,ht="ALLOWED_ATTR"in t?F({},t.ALLOWED_ATTR,Qt):gt,Xt="ALLOWED_NAMESPACES"in t?F({},t.ALLOWED_NAMESPACES,O):Yt,Bt="ADD_URI_SAFE_ATTR"in t?F(C(Wt),t.ADD_URI_SAFE_ATTR,Qt):Wt,Nt="ADD_DATA_URI_TAGS"in t?F(C(Ut),t.ADD_DATA_URI_TAGS,Qt):Ut,Ft="FORBID_CONTENTS"in t?F({},t.FORBID_CONTENTS,Qt):Ct,yt="FORBID_TAGS"in t?F({},t.FORBID_TAGS,Qt):{},vt="FORBID_ATTR"in t?F({},t.FORBID_ATTR,Qt):{},Lt="USE_PROFILES"in t&&t.USE_PROFILES,wt=!1!==t.ALLOW_ARIA_ATTR,xt=!1!==t.ALLOW_DATA_ATTR,At=t.ALLOW_UNKNOWN_PROTOCOLS||!1,_t=!1!==t.ALLOW_SELF_CLOSE_IN_ATTR,Et=t.SAFE_FOR_TEMPLATES||!1,Tt=t.WHOLE_DOCUMENT||!1,St=t.RETURN_DOM||!1,Ot=t.RETURN_DOM_FRAGMENT||!1,jt=t.RETURN_TRUSTED_TYPE||!1,Rt=t.FORCE_BODY||!1,Pt=!1!==t.SANITIZE_DOM,It=t.SANITIZE_NAMED_PROPS||!1,Dt=!1!==t.KEEP_CONTENT,zt=t.IN_PLACE||!1,pt=t.ALLOWED_URI_REGEXP||nt,Vt=t.NAMESPACE||qt,bt=t.CUSTOM_ELEMENT_HANDLING||{},t.CUSTOM_ELEMENT_HANDLING&&ne(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(bt.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&ne(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(bt.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(bt.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Et&&(xt=!1),Ot&&(St=!0),Lt&&(mt=F({},[...V]),ht=[],!0===Lt.html&&(F(mt,U),F(ht,G)),!0===Lt.svg&&(F(mt,B),F(ht,X),F(ht,K)),!0===Lt.svgFilters&&(F(mt,W),F(ht,X),F(ht,K)),!0===Lt.mathMl&&(F(mt,H),F(ht,Y),F(ht,K))),t.ADD_TAGS&&(mt===dt&&(mt=C(mt)),F(mt,t.ADD_TAGS,Qt)),t.ADD_ATTR&&(ht===gt&&(ht=C(ht)),F(ht,t.ADD_ATTR,Qt)),t.ADD_URI_SAFE_ATTR&&F(Bt,t.ADD_URI_SAFE_ATTR,Qt),t.FORBID_CONTENTS&&(Ft===Ct&&(Ft=C(Ft)),F(Ft,t.FORBID_CONTENTS,Qt)),Dt&&(mt["#text"]=!0),Tt&&F(mt,["html","head","body"]),mt.table&&(F(mt,["tbody"]),delete yt.tbody),v&&v(t),te=t)},ie=F({},["mi","mo","mn","ms","mtext"]),oe=F({},["foreignobject","desc","title","annotation-xml"]),se=F({},["title","style","font","a","script"]),ae=F({},B);F(ae,W),F(ae,$);const le=F({},H);F(le,q);const ce=function(t){let e=w(t);e&&e.tagName||(e={namespaceURI:Vt,tagName:"template"});const n=S(t.tagName),r=S(e.tagName);return!!Xt[t.namespaceURI]&&(t.namespaceURI===Ht?e.namespaceURI===qt?"svg"===n:e.namespaceURI===$t?"svg"===n&&("annotation-xml"===r||ie[r]):Boolean(ae[n]):t.namespaceURI===$t?e.namespaceURI===qt?"math"===n:e.namespaceURI===Ht?"math"===n&&oe[r]:Boolean(le[n]):t.namespaceURI===qt?!(e.namespaceURI===Ht&&!oe[r])&&!(e.namespaceURI===$t&&!ie[r])&&!le[n]&&(se[n]||!ae[n]):!("application/xhtml+xml"!==Kt||!Xt[t.namespaceURI]))},ue=function(t){R(n.removed,{element:t});try{t.parentNode.removeChild(t)}catch(e){t.remove()}},fe=function(t,e){try{R(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(t){R(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t&&!ht[t])if(St||Ot)try{ue(e)}catch(t){}else try{e.setAttribute(t,"")}catch(t){}},pe=function(t){let e,n;if(Rt)t="<remove></remove>"+t;else{const e=j(t,/^[\r\n\t ]+/);n=e&&e[0]}"application/xhtml+xml"===Kt&&Vt===qt&&(t='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+t+"</body></html>");const r=x?x.createHTML(t):t;if(Vt===qt)try{e=(new p).parseFromString(r,Kt)}catch(t){}if(!e||!e.documentElement){e=_.createDocument(Vt,"template",null);try{e.documentElement.innerHTML=Gt?A:r}catch(t){}}const o=e.body||e.documentElement;return t&&n&&o.insertBefore(i.createTextNode(n),o.childNodes[0]||null),Vt===qt?Z.call(e,Tt?"html":"body")[0]:Tt?e.documentElement:o},me=function(t){return E.call(t.ownerDocument||t,t,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null,!1)},de=function(t){return t instanceof f&&("string"!=typeof t.nodeName||"string"!=typeof t.textContent||"function"!=typeof t.removeChild||!(t.attributes instanceof u)||"function"!=typeof t.removeAttribute||"function"!=typeof t.setAttribute||"string"!=typeof t.namespaceURI||"function"!=typeof t.insertBefore||"function"!=typeof t.hasChildNodes)},he=function(t){return"object"==typeof a?t instanceof a:t&&"object"==typeof t&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},ge=function(t,e,r){Q[t]&&T(Q[t],(t=>{t.call(n,e,r,te)}))},be=function(t){let e;if(ge("beforeSanitizeElements",t,null),de(t))return ue(t),!0;const r=Qt(t.nodeName);if(ge("uponSanitizeElement",t,{tagName:r,allowedTags:mt}),t.hasChildNodes()&&!he(t.firstElementChild)&&(!he(t.content)||!he(t.content.firstElementChild))&&D(/<[/\w]/g,t.innerHTML)&&D(/<[/\w]/g,t.textContent))return ue(t),!0;if(!mt[r]||yt[r]){if(!yt[r]&&ve(r)){if(bt.tagNameCheck instanceof RegExp&&D(bt.tagNameCheck,r))return!1;if(bt.tagNameCheck instanceof Function&&bt.tagNameCheck(r))return!1}if(Dt&&!Ft[r]){const e=w(t)||t.parentNode,n=y(t)||t.childNodes;if(n&&e)for(let r=n.length-1;r>=0;--r)e.insertBefore(g(n[r],!0),b(t))}return ue(t),!0}return t instanceof l&&!ce(t)?(ue(t),!0):"noscript"!==r&&"noembed"!==r||!D(/<\/no(script|embed)/i,t.innerHTML)?(Et&&3===t.nodeType&&(e=t.textContent,e=P(e,tt," "),e=P(e,et," "),e=P(e,rt," "),t.textContent!==e&&(R(n.removed,{element:t.cloneNode()}),t.textContent=e)),ge("afterSanitizeElements",t,null),!1):(ue(t),!0)},ye=function(t,e,n){if(Pt&&("id"===e||"name"===e)&&(n in i||n in ee))return!1;if(xt&&!vt[e]&&D(it,e));else if(wt&&D(ct,e));else if(!ht[e]||vt[e]){if(!(ve(t)&&(bt.tagNameCheck instanceof RegExp&&D(bt.tagNameCheck,t)||bt.tagNameCheck instanceof Function&&bt.tagNameCheck(t))&&(bt.attributeNameCheck instanceof RegExp&&D(bt.attributeNameCheck,e)||bt.attributeNameCheck instanceof Function&&bt.attributeNameCheck(e))||"is"===e&&bt.allowCustomizedBuiltInElements&&(bt.tagNameCheck instanceof RegExp&&D(bt.tagNameCheck,n)||bt.tagNameCheck instanceof Function&&bt.tagNameCheck(n))))return!1}else if(Bt[e]);else if(D(pt,P(n,ft,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==I(n,"data:")||!Nt[t])if(At&&!D(ut,P(n,ft,"")));else if(n)return!1;return!0},ve=function(t){return t.indexOf("-")>0},we=function(t){let e,r,i,o;ge("beforeSanitizeAttributes",t,null);const{attributes:s}=t;if(!s)return;const a={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:ht};for(o=s.length;o--;){e=s[o];const{name:l,namespaceURI:c}=e;if(r="value"===l?e.value:M(e.value),i=Qt(l),a.attrName=i,a.attrValue=r,a.keepAttr=!0,a.forceKeepAttr=void 0,ge("uponSanitizeAttribute",t,a),r=a.attrValue,a.forceKeepAttr)continue;if(fe(l,t),!a.keepAttr)continue;if(!_t&&D(/\/>/i,r)){fe(l,t);continue}Et&&(r=P(r,tt," "),r=P(r,et," "),r=P(r,rt," "));const u=Qt(t.nodeName);if(ye(u,i,r)){if(!It||"id"!==i&&"name"!==i||(fe(l,t),r=Mt+r),x&&"object"==typeof m&&"function"==typeof m.getAttributeType)if(c);else switch(m.getAttributeType(u,i)){case"TrustedHTML":r=x.createHTML(r);break;case"TrustedScriptURL":r=x.createScriptURL(r)}try{c?t.setAttributeNS(c,l,r):t.setAttribute(l,r),k(n.removed)}catch(t){}}}ge("afterSanitizeAttributes",t,null)},xe=function t(e){let n;const r=me(e);for(ge("beforeSanitizeShadowDOM",e,null);n=r.nextNode();)ge("uponSanitizeShadowNode",n,null),be(n)||(n.content instanceof o&&t(n.content),we(n));ge("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(t){let e,i,s,l,c=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(Gt=!t,Gt&&(t="\x3c!--\x3e"),"string"!=typeof t&&!he(t)){if("function"!=typeof t.toString)throw z("toString is not a function");if("string"!=typeof(t=t.toString()))throw z("dirty is not a string, aborting")}if(!n.isSupported)return t;if(kt||re(c),n.removed=[],"string"==typeof t&&(zt=!1),zt){if(t.nodeName){const e=Qt(t.nodeName);if(!mt[e]||yt[e])throw z("root node is forbidden and cannot be sanitized in-place")}}else if(t instanceof a)e=pe("\x3c!----\x3e"),i=e.ownerDocument.importNode(t,!0),1===i.nodeType&&"BODY"===i.nodeName||"HTML"===i.nodeName?e=i:e.appendChild(i);else{if(!St&&!Et&&!Tt&&-1===t.indexOf("<"))return x&&jt?x.createHTML(t):t;if(e=pe(t),!e)return St?null:jt?A:""}e&&Rt&&ue(e.firstChild);const u=me(zt?t:e);for(;s=u.nextNode();)be(s)||(s.content instanceof o&&xe(s.content),we(s));if(zt)return t;if(St){if(Ot)for(l=L.call(e.ownerDocument);e.firstChild;)l.appendChild(e.firstChild);else l=e;return(ht.shadowroot||ht.shadowrootmod)&&(l=J.call(r,l,!0)),l}let f=Tt?e.outerHTML:e.innerHTML;return Tt&&mt["!doctype"]&&e.ownerDocument&&e.ownerDocument.doctype&&e.ownerDocument.doctype.name&&D(ot,e.ownerDocument.doctype.name)&&(f="<!DOCTYPE "+e.ownerDocument.doctype.name+">\n"+f),Et&&(f=P(f,tt," "),f=P(f,et," "),f=P(f,rt," ")),x&&jt?x.createHTML(f):f},n.setConfig=function(t){re(t),kt=!0},n.clearConfig=function(){te=null,kt=!1},n.isValidAttribute=function(t,e,n){te||re({});const r=Qt(t),i=Qt(e);return ye(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&(Q[t]=Q[t]||[],R(Q[t],e))},n.removeHook=function(t){if(Q[t])return k(Q[t])},n.removeHooks=function(t){Q[t]&&(Q[t]=[])},n.removeAllHooks=function(){Q={}},n}();function ut(t){return function(t,e){const n=e.documentElement;return["⚡4email","amp4email"].some((t=>n.hasAttribute(t)))}(0,t)}var ft=/(?:^[#?]?|&)([^=&]+)(?:=([^&]*))?/g;function pt(t,e=""){try{return decodeURIComponent(t)}catch(t){return e}}self.__AMP_LOG=self.__AMP_LOG||{user:null,dev:null,userForEmbed:null};var mt=self.__AMP_LOG;function dt(t){return mt.user||(mt.user=ht()),function(t,e){return e&&e.ownerDocument.defaultView!=t}(mt.user.win,t)?mt.userForEmbed||(mt.userForEmbed=ht()):mt.user}function ht(t){return function(t,e){throw new Error("failed to call initLogConstructor")}()}function gt(t,e,n,r,i,o,s,a,l,c,u){return t}function bt(t,e,n,r,i,o,s,a,l,c,u){return dt().assert(t,e,n,r,i,o,s,a,l,c,u)}var yt=/(\S+)(?:\s+(?:(-?\d+(?:\.\d+)?)([a-zA-Z]*)))?\s*(?:,|$)/g;function vt(t,e){return m(t.width!=e.width,"Duplicate width: %s",t.width),t.width-e.width}function wt(t,e){return m(t.dpr!=e.dpr,"Duplicate dpr: %s",t.dpr),t.dpr-e.dpr}function xt(t,e){return Et(t=At(t),e)}function At(t){return t.__AMP_TOP||(t.__AMP_TOP=t)}function _t(t){return t.nodeType?(n=t,e=(n.ownerDocument||n).defaultView,xt(e,"ampdoc")).getAmpDoc(t):t;var e,n}function Et(t,e){gt(function(t,e){const n=t.__AMP_SERVICES&&t.__AMP_SERVICES[e];return!(!n||!n.ctor)}(t,e));const n=Tt(t)[e];return n.obj||(gt(n.ctor),gt(n.context),n.obj=new n.ctor(n.context),gt(n.obj),n.context=null,n.resolve&&n.resolve(n.obj)),n.obj}function Tt(t){let e=t.__AMP_SERVICES;return e||(e=t.__AMP_SERVICES={}),e}var kt,Rt=(()=>self.AMP.config.urls)(),St=new Set(["c","v","a","ad"]),Ot=t=>"string"==typeof t?jt(t):t;function jt(t,e){return kt||(kt=self.document.createElement("a")),function(t,e,n){return t.href="",new URL(e,t.href)}(kt,t)}function Pt(t){return Rt.cdnProxyRegex.test(Ot(t).origin)}function It(t,e){return e=Ot(e),new URL(t,e.href).toString()}var Mt=(()=>self.AMP.config.urls)();function Dt(t,e,n){return zt(e)?function(t,e,n,r){var i;bt(!("__amp_source_origin"in function(t){const e=l();if(!t)return e;let n;for(;n=ft.exec(t);){const t=pt(n[1],n[1]),r=n[2]?pt(n[2].replace(/\+/g," "),n[2]):"";e[t]=r}return e}(jt(i=n).search)),"Source origin is not allowed in %s",i);const o=Pt(r),s=jt(function(t){if(!Pt(t=Ot(t)))return t.href;const e=t.pathname.split("/"),n=e[1];bt(St.has(n),"Unknown path prefix in url %s",t.href);const r=e[2],i="s"==r?"https://"+decodeURIComponent(e[3]):"http://"+decodeURIComponent(r);return bt(i.indexOf(".")>0,"Expected a . in origin %s",i),e.splice(1,"s"==r?3:2),i+e.join("/")+function(t,e){if(!t||"?"==t)return"";const n=new RegExp("[?&](amp_(js[^&=]*|gsa|r|kit)|usqp)\\b[^&]*","g"),r=t.replace(n,"").replace(/^[?&]/,"");return r?"?"+r:""}(t.search)+(t.hash||"")}(r));if("href"==e&&!n.startsWith("#"))return It(n,s);if("src"==e)return"amp-img"==t?Lt(n,s,o):It(n,s);if("srcset"==e){let t;try{t=function(t){const e=[];let n;for(;n=yt.exec(t);){const t=n[1];let r,i;if(n[2]){const t=n[3].toLowerCase();if("w"==t)r=parseInt(n[2],10);else{if("x"!=t)continue;i=parseFloat(n[2])}}else i=1;e.push({url:t,width:r,dpr:i})}return new class{constructor(t){m(t.length>0,"Srcset must have at least one source"),this.Lb=t;let e=!1,n=!1;for(let r=0;r<t.length;r++){const i=t[r];e=e||!!i.width,n=n||!!i.dpr}m(!(e===n),"Srcset must have width or dpr sources, but not both"),t.sort(e?vt:wt),this.Hb=e}select(t,e){f(t),f(e);let n=0;return n=this.Hb?this.Ub(t*e):this.Db(e),this.Lb[n].url}Ub(t){const e=this.Lb;let n=0,r=1/0,i=1/0;for(let s=0;s<e.length;s++){var o;const a=null!==(o=e[s].width)&&void 0!==o?o:0,l=Math.abs(a-t);if(!(l<=1.1*r||t/i>1.2))break;n=s,r=l,i=a}return n}Db(t){const e=this.Lb;let n=0,r=1/0;for(let i=0;i<e.length;i++){const o=Math.abs(e[i].dpr-t);if(!(o<=r))break;n=i,r=o}return n}getUrls(){return this.Lb.map((t=>t.url))}stringify(t){const e=[],n=this.Lb;for(let r=0;r<n.length;r++){const i=n[r];let o=i.url;t&&(o=t(o)),this.Hb?o+=` ${i.width}w`:o+=` ${i.dpr}x`,e.push(o)}return e.join(", ")}}(e)}(n)}catch(t){return dt().error("URL-REWRITE","Failed to parse srcset: ",t),n}return t.stringify((t=>Lt(t,s,o)))}return n}(t,e,n,self.location):n}function zt(t){return"src"==t||"href"==t||"xlink:href"==t||"srcset"==t}function Lt(t,e,n){const r=jt(It(t,e));return"data:"==r.protocol||Pt(r)||!n?r.href:`${Mt.cdn}/i/`+("https:"==r.protocol?"s/":"")+encodeURIComponent(r.host)+r.pathname+(r.search||"")+(r.hash||"")}var Ft="data-amp-bind-",Ct="i-amphtml-key",Nt={"AMP-IMG":["src","srcset","layout","width","height"]},Ut={"applet":!0,"audio":!0,"base":!0,"embed":!0,"frame":!0,"frameset":!0,"iframe":!0,"img":!0,"link":!0,"meta":!0,"object":!0,"style":!0,"video":!0},Bt={"amp-accordion":!0,"amp-anim":!0,"amp-bind-macro":!0,"amp-carousel":!0,"amp-fit-text":!0,"amp-img":!0,"amp-layout":!0,"amp-selector":!0,"amp-sidebar":!0,"amp-timeago":!0},Wt=["a","amp-img","article","aside","b","blockquote","br","caption","code","col","colgroup","dd","del","details","div","dl","dt","em","figcaption","figure","footer","h1","h2","h3","header","hr","i","ins","li","main","mark","nav","ol","p","pre","q","s","section","small","span","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","time","tr","u","ul"],$t=["a","article","aside","b","blockquote","br","caption","code","col","colgroup","dd","del","details","div","dl","dt","em","figcaption","figure","footer","h1","h2","h3","header","hr","i","ins","li","main","mark","nav","ol","p","pre","q","s","section","small","span","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","time","tr","u","ul"],Ht=["amp-fx","fallback","heights","layout","min-font-size","max-font-size","on","option","placeholder","submitting","submit-success","submit-error","validation-for","verify-error","visible-when-invalid","href","style","text","subscriptions-action","subscriptions-actions","subscriptions-decorate","subscriptions-dialog","subscriptions-display","subscriptions-section","subscriptions-service","subscriptions-google-rtc","amp-nested-submenu","amp-nested-submenu-open","amp-nested-submenu-close","itemprop"],qt={"a":["rel","target"],"div":["template"],"form":["action-xhr","verify-xhr","custom-validation-reporting","target"],"input":["mask-output"],"template":["type"],"textarea":["autoexpand"]},Vt=["_top","_blank"],Gt=/^(?:\w+script|data|blob):/i,Xt=/^(?:blob):/i,Yt=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205f\u3000]/g,Kt=Object.freeze({"input":{"type":/(?:image|button)/i}}),Zt=Object.freeze({"input":{"type":/(?:button|file|image|password)/i}}),Jt=Object.freeze(["form","formaction","formmethod","formtarget","formnovalidate","formenctype"]),Qt=Object.freeze({"input":Jt,"textarea":Jt,"select":Jt}),te=Object.freeze({"amp-anim":["controls"],"form":["name"]}),ee=/!important|position\s*:\s*fixed|position\s*:\s*sticky/i;function ne(t,e,n,r,i=!1){const o=n?n.replace(Yt,""):"";if(!i){if(e.startsWith("on")&&"on"!=e)return!1;const t=o.toLowerCase();if(t.indexOf("<script")>=0||t.indexOf("</script")>=0)return!1;if(Gt.test(o))return!1}if(Xt.test(o))return!1;if("style"==e)return!ee.test(n);if("class"==e&&n&&/(^|\W)i-amphtml-/i.test(n))return!1;if(zt(e)&&/__amp_source_origin/.test(n))return!1;const s=ut(r),a=Object.assign(l(),Qt,s?te:{})[t];if(a&&-1!=a.indexOf(e))return!1;const c=Object.assign(l(),Kt,s?Zt:{})[t];if(c){const t=c[e];if(t&&-1!=n.search(t))return!1}return!0}var re="purifier",ie={"script":{"attribute":"type","values":["application/json","application/ld+json"]}},oe={USE_PROFILES:{html:!0,svg:!0,svgFilters:!0}};function se(t){return"["==t[0]&&"]"==t[t.length-1]?1:t.startsWith(Ft)?2:0}var ae={};!function(t){var e=Object.prototype.toString,n=Array.isArray||function(t){return"[object Array]"===e.call(t)};function r(t){return"function"==typeof t}function i(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function o(t,e){return null!=t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,e)}var s=RegExp.prototype.test,a=/\S/,l={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;","`":"&#x60;","=":"&#x3D;"},c=/\s*/,u=/\s+/,f=/\s*=/,p=/\s*\}/,m=/#|\^|\/|>|\{|&|=|!/;function d(t){this.string=t,this.tail=t,this.pos=0}function h(t,e){this.view=t,this.cache={".":this.view},this.parent=e}function g(){this.cache={}}d.prototype.eos=function(){return""===this.tail},d.prototype.scan=function(t){var e=this.tail.match(t);if(!e||0!==e.index)return"";var n=e[0];return this.tail=this.tail.substring(n.length),this.pos+=n.length,n},d.prototype.scanUntil=function(t){var e,n=this.tail.search(t);switch(n){case-1:e=this.tail,this.tail="";break;case 0:e="";break;default:e=this.tail.substring(0,n),this.tail=this.tail.substring(n)}return this.pos+=e.length,e},h.prototype.push=function(t){return new h(t,this)},h.prototype.lookup=function(t){var e,n=this.cache;if(n.hasOwnProperty(t))e=n[t];else{for(var i,s,a=this,l=!1;a;){if(t.indexOf(".")>0)for(e=a.view,i=t.split("."),s=0;null!=e&&s<i.length;){if(!o(e,i[s])){e=null;break}s===i.length-1&&(l=!0),e=e[i[s++]]}else o(a.view,t)?(e=a.view[t],l=!0):e=null;if(l)break;a=a.parent}n[t]=e}return r(e)&&(e=e.call(this.view)),e},g.prototype.clearCache=function(){this.cache={}},g.prototype.parse=function(e,r){var o=this.cache,l=o[e];return null==l&&(l=o[e]=function(e,r){if(!e)return[];var o,l,h,g,b=[],y=[],v=[],w=!1,x=!1;function A(){if(w&&!x)for(;v.length;)delete y[v.pop()];else v=[];w=!1,x=!1}!function(t){if("string"==typeof t&&(t=t.split(u,2)),!n(t)||2!==t.length)throw new Error("Invalid tags: "+t);o=new RegExp(i(t[0])+"\\s*"),l=new RegExp("\\s*"+i(t[1])),h=new RegExp("\\s*"+i("}"+t[1]))}(r||t.tags);for(var _,E,T,k,R,S,O=new d(e);!O.eos();){if(_=O.pos,T=O.scanUntil(o))for(var j=0,P=T.length;j<P;++j)g=k=T.charAt(j),function(t,e){return s.call(t,e)}(a,g)?x=!0:v.push(y.length),y.push(["text",k,_,_+1]),_+=1,"\n"===k&&A();if(!O.scan(o))break;if(w=!0,E=O.scan(m)||"name",O.scan(c),"="===E?(T=O.scanUntil(f),O.scan(f),O.scanUntil(l)):"{"===E?(T=O.scanUntil(h),O.scan(p),O.scanUntil(l),E="&"):T=O.scanUntil(l),!O.scan(l))throw new Error("Unclosed tag at "+O.pos);if(R=[E,T,_,O.pos],y.push(R),"#"===E||"^"===E)b.push(R);else if("/"===E){if(!(S=b.pop()))throw new Error('Unopened section "'+T+'" at '+_);if(S[1]!==T)throw new Error('Unclosed section "'+S[1]+'" at '+_)}else"name"!==E&&"{"!==E&&"&"!==E||(x=!0)}if(S=b.pop())throw new Error('Unclosed section "'+S[1]+'" at '+O.pos);return function(t){for(var e,n=[],r=n,i=[],o=0,s=t.length;o<s;++o)switch((e=t[o])[0]){case"#":case"^":r.push(e),i.push(e),r=e[4]=[];break;case"/":i.pop()[5]=e[2],r=i.length>0?i[i.length-1][4]:n;break;default:r.push(e)}return n}(function(t){for(var e,n,r=[],i=0,o=t.length;i<o;++i)(e=t[i])&&("text"===e[0]&&n&&"text"===n[0]?(n[1]+=e[1],n[3]=e[3]):(r.push(e),n=e));return r}(y))}(e,r)),l},g.prototype.render=function(t,e,n){var r=this.parse(t),i=e instanceof h?e:new h(e);return this.renderTokens(r,i,n,t)},g.prototype.renderTokens=function(t,e,n,r){for(var i,o,s,a="",l=0,c=t.length;l<c;++l)s=void 0,"#"===(o=(i=t[l])[0])?s=this.renderSection(i,e,n,r):"^"===o?s=this.renderInverted(i,e,n,r):">"===o?s=this.renderPartial(i,e,n,r):"&"===o?s=this.unescapedValue(i,e):"name"===o?s=this.escapedValue(i,e):"text"===o&&(s=this.rawValue(i)),void 0!==s&&(a+=s);return a},g.prototype.renderSection=function(t,e,i,o){var s=this,a="",l=e.lookup(t[1]);if(l){if(n(l))for(var c=0,u=l.length;c<u;++c)a+=this.renderTokens(t[4],e.push(l[c]),i,o);else if("object"==typeof l||"string"==typeof l||"number"==typeof l)a+=this.renderTokens(t[4],e.push(l),i,o);else if(r(l)){if("string"!=typeof o)throw new Error("Cannot use higher-order sections without the original template");null!=(l=l.call(e.view,o.slice(t[3],t[5]),(function(t){return s.render(t,e,i)})))&&(a+=l)}else a+=this.renderTokens(t[4],e,i,o);return a}},g.prototype.renderInverted=function(t,e,r,i){var o=e.lookup(t[1]);if(!o||n(o)&&0===o.length)return this.renderTokens(t[4],e,r,i)},g.prototype.renderPartial=function(t,e,n){if(n){var i=r(n)?n(t[1]):n[t[1]];return null!=i?this.renderTokens(this.parse(i),e,n,i):void 0}},g.prototype.unescapedValue=function(e,n){var r=n.lookup(e[1]);if(null!=r)return t.sanitizeUnescaped?t.sanitizeUnescaped(r):r},g.prototype.escapedValue=function(e,n){var r=n.lookup(e[1]);if(null!=r)return t.escape(r)},g.prototype.rawValue=function(t){return t[1]},t.name="mustache.js",t.version="2.2.0",t.tags=["{{","}}"];var b=new g;t.clearCache=function(){return b.clearCache()},t.parse=function(t,e){return b.parse(t,e)},t.render=function(t,e,r){if("string"!=typeof t)throw new TypeError('Invalid template! Template should be a "string" but "'+(n(i=t)?"array":typeof i)+'" was given as the first argument for mustache#render(template, view, partials)');var i;return b.render(t,e,r)},t.to_html=function(e,n,i,o){var s=t.render(e,n,i);if(!r(o))return s;o(s)},t.escape=function(t){return String(t).replace(/[&<>"'`=\/]/g,(function(t){return l[t]}))},t.sanitizeUnescaped=null,t.setUnescapedSanitizer=function(e){t.sanitizeUnescaped=e},t.Scanner=d,t.Context=h,t.Writer=g}(ae);var le=ae,ce="amp-mustache";t.registerTemplate(ce,class extends class{constructor(t,e){var n,r;this.element=t,this.win=t.ownerDocument.defaultView||e,this.Qe=(n=this.element,r="viewer",Et(function(t){const e=_t(t);return e.isSingleDoc()?e.win:e}(_t(n)),r)),this.compileCallback()}compileCallback(){}setHtml(t){}render(t){}renderAsString(t){}$b(t,e){for(let n=t.firstChild;null!=n;n=n.nextSibling)if(3==n.nodeType){const t=n.textContent.trim();t&&e(t)}else 8==n.nodeType||c(n)&&e(n)}tryUnwrap(t){let e;return this.$b(t,(t=>{e=void 0===e&&t.nodeType?t:null})),e||t}unwrapChildren(t){const e=[];return this.$b(t,(t=>{if("string"==typeof t){const n=this.win.document.createElement("div");n.textContent=t,e.push(n)}else e.push(t)})),e}viewerCanRenderTemplates(){return this.Qe.hasCapability("viewerRenderTemplate")}}{constructor(t,e){super(t,e),function(t,e,n,r){!function(t,e,n,r,i,o){const s=Tt(t);let a=s[n];a||(a=s[n]={obj:null,promise:null,resolve:null,reject:null,context:null,ctor:null,sharedInstance:!1}),a.ctor||(a.ctor=r,a.context=e,a.sharedInstance=!1,a.resolve&&Et(t,n))}(t=At(t),t,e,n)}(e,"purifier",(function(){return new class{constructor(t,e,n){this.hf=t,this.Xk=1,this.Qk=ct(self),this.gS=ct(self);const i=Object.assign(e||{},r(r({},oe),{},{ADD_ATTR:Ht,ADD_TAGS:["use"],FORBID_TAGS:Object.keys(Ut),FORCE_BODY:!0,RETURN_DOM:!0,ALLOW_UNKNOWN_PROTOCOLS:!0}));this.Qk.setConfig(i),this.yS(this.Qk,n),this.vS(this.gS)}purifyHtml(t){return this.Qk.sanitize(t)}purifyTagsForTripleMustache(t){const e=this.gS.sanitize(t,{"ALLOWED_TAGS":ut(this.hf)?$t:Wt,"FORCE_BODY":!0,"RETURN_DOM_FRAGMENT":!0}),n=this.hf.createElement("div");return n.appendChild(e),n.innerHTML}getAllowedTags(){const t={};this.Qk.addHook("uponSanitizeElement",((e,n)=>{Object.assign(t,n.allowedTags)}));const e=this.hf.createElement("p");return this.Qk.sanitize(e),Object.keys(Ut).forEach((e=>{t[e]=!1})),this.Qk.removeHook("uponSanitizeElement"),t}validateAttributeChange(t,e,n){const r=t.nodeName.toLowerCase(),i=ie[r];if(i){const{attribute:t,values:r}=i;if(t===e&&(null==n||!r.includes(n)))return!1}if("a"===r&&"target"===e&&(null==n||!Vt.includes(n)))return!1;if(null==n)return!0;if(0!==se(e))return!1;if(!this.Qk.isValidAttribute(r,e,n)){const t=qt[r];if(!(t&&t.includes(e)||r.startsWith("amp-")))return!1}const o=t.ownerDocument?t.ownerDocument:t;return!(n&&!ne(r,e,n,o,!0))}yS(t,e){const n=ut(this.hf);let r;const i=[];let o;const s=[];t.addHook("uponSanitizeElement",((t,e)=>{const{tagName:o}=e;if(r=e.allowedTags,o.startsWith("amp-")&&(r[o]=!n||Bt[o]),"a"===o){const e=p(t);e.hasAttribute("href")&&!e.hasAttribute("target")&&e.setAttribute("target","_top")}const s=ie[o];if(s){const{attribute:e,values:n}=s,a=p(t);a.hasAttribute(e)&&n.includes(a.getAttribute(e))&&(r[o]=!0,i.push(o))}})),t.addHook("afterSanitizeElements",(t=>{i.forEach((t=>{delete r[t]})),i.length=0})),t.addHook("uponSanitizeAttribute",((t,n)=>{const r=t.nodeName.toLowerCase(),{attrName:i}=n;let{attrValue:a}=n;o=n.allowedAttributes;const l=()=>{o[i]||(o[i]=!0,s.push(i))};if(r.startsWith("amp-"))l();else{if("a"==r&&"target"==i){const t=a.toLowerCase();a=Vt.includes(t)?t:"_top"}const t=qt[r];t&&t.includes(i)&&l()}const c=se(i);if(1===c){const e=i.substring(1,i.length-1);t.setAttribute(`data-amp-bind-${e}`,a)}0!==c&&t.setAttribute("i-amphtml-binding",""),ne(r,i,a,this.hf,!0)?e&&a&&!i.startsWith(Ft)&&(a=e(r,i,a)):(n.keepAttr=!1,dt().error(re,'Removed invalid attribute %s[%s="%s"].',r,i,a)),n.attrValue=a})),t.addHook("afterSanitizeAttributes",(t=>{!function(t,e){const n=t.tagName.startsWith("AMP-"),r=t.hasAttribute("i-amphtml-binding");!r&&Nt[t.tagName]?t.setAttribute("i-amphtml-ignore",""):(r||n)&&(t.hasAttribute(Ct)||t.setAttribute(Ct,e()))}(t,(()=>String(this.Xk++))),s.forEach((t=>{delete o[t]})),s.length=0,"use"===t.nodeName.toLowerCase()&&["href","xlink:href"].forEach((e=>{t.hasAttribute(e)&&!t.getAttribute(e).startsWith("#")&&(function(t){var e;null===(e=t.parentElement)||void 0===e||e.removeChild(t)}(t),dt().error(re,'Removed invalid <use>. use[href] must start with "#".'))}))}))}vS(t){let e;t.addHook("uponSanitizeElement",((t,n)=>{const{tagName:r}=n;if(e=n.allowedTags,"template"===r){const n=t.getAttribute("type");n&&"amp-mustache"===n.toLowerCase()&&(e.template=!0)}})),t.addHook("afterSanitizeElements",(t=>{e.template=!1}))}}(e.document,{},Dt)})),this.wS=xt(e,"purifier"),le.setUnescapedSanitizer((t=>this.wS.purifyTagsForTripleMustache(t)))}compileCallback(){if(!this.viewerCanRenderTemplates()){this.Nb={},this.Fb=this.zb();try{le.parse(this.Fb,void 0)}catch(t){dt().error(ce,t.message,this.element)}}}zb(){if("TEMPLATE"==this.element.tagName){const t=function(t){if("content"in t)return t.content.cloneNode(!0);{const e=t.ownerDocument.createDocumentFragment();return function(t,e){const n=e.ownerDocument.createDocumentFragment();for(let e=t.firstChild;e;e=e.nextSibling)n.appendChild(e.cloneNode(!0));e.appendChild(n)}(t,e),e}}(this.element);this.Bb(t);const e=this.element.ownerDocument.createElement("div");return e.appendChild(t),e.innerHTML}return"SCRIPT"==this.element.tagName?this.element.textContent:""}Bb(t){t.querySelectorAll("template").forEach(((t,e)=>{const n=`__AMP_NESTED_TEMPLATE_${e}`;this.Nb[n]=t.outerHTML;const r=this.element.ownerDocument.createTextNode(`{{{${n}}}}`);t.parentNode.replaceChild(r,t)}))}setHtml(t){const e=`<div>${t}</div>`,n=this.tryUnwrap(this.xS(e));return this.unwrapChildren(n)}render(t){return this.tryUnwrap(this.Ko(t))}renderAsString(t){return this.Ko(t).innerHTML}Ko(t){let e=t;"object"==typeof t&&(e=r(r({},t),this.Nb));const n=le.render(this.Fb,e,void 0);return this.xS(n)}xS(t){return this.wS.purifyHtml(`<div>${t}</div>`).firstElementChild}})})();
/*! https://mths.be/cssescape v1.5.1 by @mathias | MIT license */
/*!
 * mustache.js - Logic-less {{mustache}} templates with JavaScript
 * http://github.com/janl/mustache.js
 */
/*! Bundled license information:

dompurify/dist/purify.es.js:
  (*! @license DOMPurify 3.0.2 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.2/LICENSE *)
*/}});
//# sourceMappingURL=amp-mustache-0.2.mjs.map