!function(){"use strict";window.addEventListener("DOMContentLoaded",(function(){const e=document.getElementById("srgdev-appt-cncf_action_btn");let t="";if(null!==e&&e.hasAttribute("data-t1")){e.disabled=!0;const n=document.getElementById("srgdev-ncfp_fbtn-spinner");n&&(n.style.display="inline-block");let a=e.getAttribute("data-t1");async function o(e){const t=e=>e.toString().includes("[native code]")?1:0,n=!navigator.webdriver+(navigator.hardwareConcurrency>1)+await(async()=>new Promise((e=>{try{const t=new Worker(URL.createObjectURL(new Blob(["self.onmessage=()=>{self.postMessage({w:navigator.webdriver||false,c:navigator.hardwareConcurrency})};"],{type:"application/javascript"})));t.onmessage=n=>{t.terminate(),e(n.data.w===(navigator.webdriver||!1)&&n.data.c===navigator.hardwareConcurrency?1:0)},t.postMessage("_")}catch(t){e(0)}})))()+e.isTrusted+(()=>{const e=document.createElement("canvas").getContext("webgl",{failIfMajorPerformanceCaveat:!0});if(e){const t=e.getParameter(e.RENDERER)||"";return/llvmpipe|softpipe|swiftshader/i.test(t)?0:1}return 0})()+!window.__puppeteer_evaluation_script__+(navigator.languages&&navigator.languages.length>0)+t(Function.prototype.toString)+t(navigator.mediaDevices.getUserMedia);return n<5?a.slice(n+5)+a.slice(0,n+5):a}const r=t=>{e.disabled||(e.disabled=!0,n&&(n.style.display="inline-block"),o(t).then((e=>{const t=new FormData;t.append("t1",e),fetch(window.location.href,{method:"POST",body:t,signal:AbortSignal.timeout(4e3)}).then((e=>{if(!e.ok||!e.headers.has("X-Appt-Token"))throw Error("bad response");return e.text()})).then((e=>{const t=new URL(window.location.href);t.searchParams.set("t3",e),document.cookie="appt_cncf_t1="+e.substring(0,16)+"; path=/; max-age=30",window.location.replace(t.href)})).catch((e=>{console.error("fetchPost error:",e);const t=new URL(window.location.href);t.searchParams.set("err","2"),window.location.replace(t.href)}))})))},s=document.getElementById("srgdev-ncfp_fbtn-text"),i=s.textContent,c=document.getElementById("srgdev-appt-cncf_action_frm");s.textContent=atob(c.getAttribute("data-lbl"));let d=!1;const l=()=>{if(!d)if("visible"===document.visibilityState&&document.hasFocus()){d=!0,window.removeEventListener("focus",l);const t=new FormData;t.append("t1",a),fetch(window.location.href,{method:"POST",body:t,signal:AbortSignal.timeout(4e3)}).then((e=>e.text())).then((t=>{a=t,e.addEventListener("click",r),e.disabled=!1,s.textContent=i,n&&(n.style.display="none")})).catch((e=>{console.error("fetch error:",e);const t=new URL(window.location.href);t.searchParams.set("err","1"),window.location.replace(t.href)}))}else window.addEventListener("focus",(()=>{setTimeout(l,500)}))};setTimeout(l,1250),setTimeout((()=>{e.disabled=!0,e.textContent="Session Timeout. Please Reload."}),9e5),t="appt:action_needed"}else if("cncf"===window.location.pathname.slice(-4))t="appt:all_done";else{const p=window.location.search.substring(0,6);""!==p&&("?sts=0"===p?t="appt:almost_done":"?sts=1"!==p&&"?sts=2"!==p||(t="appt:error_page"))}window.parent&&""!==t&&window.parent.postMessage(t,"*")}))}();