(function(){function q(){function q(){if(!document.querySelector("a.skip-link")){var a=document.createElement("a");a.className="skip-link";a.href="#maincontent";a.textContent="Skip to main content";document.body.insertBefore(a,document.body.firstChild);a.addEventListener("click",function(){setTimeout(function(){var a=document.getElementById("maincontent");a&&(a.setAttribute("tabindex","-1"),a.focus({preventScroll:!1}))},0)})}}function r(){q();a:{var a=document.querySelector('[role="main"]');if(!a){a=
document.querySelector(".td-main-content-wrap")||null;if(!a)break a;a.hasAttribute("role")||a.setAttribute("role","main")}a.id="maincontent";a.hasAttribute("tabindex")||a.setAttribute("tabindex","-1")}}function u(a){function c(a){return a.querySelector(":scope > a, :scope > button")}function b(a){return a.querySelector(":scope > .sub-menu")}function f(a,c){a&&(c?(a.style.setProperty("display","block","important"),a.style.setProperty("opacity","1","important"),a.style.setProperty("visibility","visible",
"important"),a.style.pointerEvents="auto"):(a.style.removeProperty("display"),a.style.removeProperty("opacity"),a.style.removeProperty("visibility"),a.style.removeProperty("pointer-events")),c?(a.setAttribute("aria-hidden","false"),m&&(a.inert=!1)):(m&&(a.inert=!0),a.setAttribute("aria-hidden","true")))}function d(a){return a.classList.contains("is-open")||a.classList.contains("tdb-hover")}function g(e,d){d=!1!==(d||{}).moveFocus;var k=c(e),h=b(e);k&&h&&(l.forEach(function(c){c!==e&&a.contains(c)&&
p(c,{returnFocus:!1})}),e.classList.add("is-open","tdb-hover"),k.setAttribute("aria-expanded","true"),h.id||(h.id="mm-"+Math.random().toString(36).slice(2)),k.setAttribute("aria-controls",h.id),h.setAttribute("role","group"),f(h,!0),d&&(d=h.querySelector('a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])'))&&d.focus())}function p(a,d){d=!1!==(d||{}).returnFocus;var e=c(a),h=b(a);e&&h&&(d&&h.contains(document.activeElement)&&
e.focus(),a.classList.remove("is-open","tdb-hover"),e.setAttribute("aria-expanded","false"),f(h,!1))}if(a&&!a.hasAttribute("data-a11y-menu")){a.setAttribute("data-a11y-menu","1");a.querySelectorAll(".tdb-sub-menu-icon").forEach(function(a){a.setAttribute("aria-hidden","true")});var n=Array.prototype.slice.call(a.querySelectorAll(":scope > li")),l=n.filter(function(a){return a.classList.contains("tdb-mega-menu")||a.classList.contains("menu-item-has-children")});l.forEach(function(a){var e=c(a),k=b(a);
e&&k&&(e.setAttribute("aria-haspopup","true"),e.setAttribute("aria-expanded","false"),k.id||(k.id="mm-"+Math.random().toString(36).slice(2)),e.setAttribute("aria-controls",k.id),f(k,!1),a.addEventListener("mouseenter",function(){g(a,{moveFocus:!1})}),a.addEventListener("mouseleave",function(){p(a,{returnFocus:!1})}),e.addEventListener("keydown",function(b){if("Enter"===b.key||" "===b.key)b.preventDefault(),d(a)?p(a):g(a);else if("ArrowDown"===b.key)b.preventDefault(),d(a)||g(a),b=a.querySelectorAll(':scope > .sub-menu a[href], :scope > .sub-menu button:not([disabled]), :scope > .sub-menu [tabindex]:not([tabindex="-1"])'),
b.length&&b[0].focus();else if("ArrowUp"===b.key)b.preventDefault(),d(a)||g(a,{moveFocus:!1}),b=a.querySelectorAll(':scope > .sub-menu a[href], :scope > .sub-menu button:not([disabled]), :scope > .sub-menu [tabindex]:not([tabindex="-1"])'),b.length&&b[b.length-1].focus();else if("ArrowRight"===b.key||"ArrowLeft"===b.key){b.preventDefault();var e=n.indexOf(a);-1<e&&(b=c(n["ArrowRight"===b.key?(e+1)%n.length:(e-1+n.length)%n.length]))&&b.focus()}}),k.addEventListener("keydown",function(b){"Escape"===
b.key&&(b.preventDefault(),p(a))}),a.addEventListener("focusout",function(){setTimeout(function(){a.contains(document.activeElement)||p(a,{returnFocus:!1})},0)}))});Array.prototype.slice.call(a.querySelectorAll("li.menu-item-has-children")).filter(function(a){return-1===n.indexOf(a)}).forEach(function(a){var b=a.querySelector(":scope > a, :scope > button"),c=a.querySelector(":scope > .sub-menu");c&&b&&(b.hasAttribute("aria-haspopup")||b.setAttribute("aria-haspopup","true"),b.hasAttribute("aria-expanded")||
b.setAttribute("aria-expanded","false"),c.id||(c.id="mm-"+Math.random().toString(36).slice(2)),b.setAttribute("aria-controls",c.id),c.setAttribute("aria-hidden","true"),a.addEventListener("mouseenter",function(){a.classList.add("is-open","tdb-hover");c.style.setProperty("display","block","important");c.style.setProperty("opacity","1","important");c.style.setProperty("visibility","visible","important");c.style.pointerEvents="auto";c.setAttribute("aria-hidden","false");m&&(c.inert=!1);b.setAttribute("aria-expanded",
"true")}),a.addEventListener("mouseleave",function(){c.contains(document.activeElement)||(a.classList.remove("is-open","tdb-hover"),c.style.removeProperty("display"),c.style.removeProperty("opacity"),c.style.removeProperty("visibility"),c.style.removeProperty("pointer-events"),c.setAttribute("aria-hidden","true"),m&&(c.inert=!0),b.setAttribute("aria-expanded","false"))}))});a.addEventListener("focusin",function(b){if(b=b.target.closest(".sub-menu")){for(b=b.closest("li");b&&b.parentElement!==a;)b=
b.parentElement&&b.parentElement.closest?b.parentElement.closest("li"):null;b&&(-1===l.indexOf(b)||d(b)||g(b,{moveFocus:!1}))}});a.addEventListener("keydown",function(a){var b=a.target.closest(".td-next-prev-wrap a");!b||"Enter"!==a.key&&" "!==a.key||(a.preventDefault(),b.click())})}}if(document.body&&document.body.classList.contains("a11y-enabled")&&!document.documentElement.hasAttribute("data-a11y-initialized")){document.documentElement.setAttribute("data-a11y-initialized","true");var m="inert"in
HTMLElement.prototype;"loading"===document.readyState?document.addEventListener("DOMContentLoaded",r,{once:!0}):r();setTimeout(r,500);(new MutationObserver(r)).observe(document.body,{childList:!0,subtree:!0});document.querySelectorAll(".tdb-block-menu").forEach(u);(new MutationObserver(function(a){a.forEach(function(a){a.addedNodes&&a.addedNodes.forEach(function(a){a instanceof HTMLElement&&(a.matches&&a.matches(".tdb-block-menu")&&u(a),a.querySelectorAll&&a.querySelectorAll(".tdb-block-menu").forEach(u))})})})).observe(document.body,
{childList:!0,subtree:!0});document.addEventListener("keydown",function(a){function c(a){(a=a&&a.querySelector('a[href], button:not([disabled]), [tabindex]:not([tabindex="-1"])'))&&a.focus()}if(-1!=="ArrowDown ArrowUp Home End ArrowLeft ArrowRight".split(" ").indexOf(a.key)){var b=a.target,f=b.closest&&b.closest(".tdb-block-menu");if(f){var d=b.closest("ul.sub-menu");if(d&&f.contains(d)&&(b=b.closest("li"))&&(f=Array.prototype.slice.call(d.children).filter(function(a){return a.matches("li")}).filter(function(a){return a.querySelector('a[href], button:not([disabled]), [tabindex]:not([tabindex="-1"])')}),
f.length)){var g=f.indexOf(b);if(-1!==g)if(a.stopPropagation(),"ArrowRight"===a.key){if(d=b.querySelector(":scope > ul.sub-menu")){a.preventDefault();b.classList.add("is-open","tdb-hover");if(a=b.querySelector(":scope > a, :scope > button"))a.setAttribute("aria-expanded","true"),d.id||(d.id="mm-"+Math.random().toString(36).slice(2)),a.setAttribute("aria-controls",d.id);d.style.setProperty("display","block","important");d.style.setProperty("opacity","1","important");d.style.setProperty("visibility",
"visible","important");d.style.pointerEvents="auto";d.setAttribute("aria-hidden","false");m&&(d.inert=!1);(a=d.querySelector("li"))&&c(a)}}else if("ArrowLeft"===a.key){if(b=d.parentElement&&d.parentElement.closest("li"))if(a.preventDefault(),b.classList.remove("is-open","tdb-hover"),d.style.removeProperty("display"),d.style.removeProperty("opacity"),d.style.removeProperty("visibility"),d.style.removeProperty("pointer-events"),d.setAttribute("aria-hidden","true"),m&&(d.inert=!0),a=b.querySelector(":scope > a, :scope > button"))a.setAttribute("aria-expanded",
"false"),a.focus()}else{d=g;switch(a.key){case "ArrowDown":a.preventDefault();d=(g+1)%f.length;break;case "ArrowUp":a.preventDefault();d=(g-1+f.length)%f.length;break;case "Home":a.preventDefault();d=0;break;case "End":a.preventDefault(),d=f.length-1}d!==g&&(a=f[d])&&c(a)}}}}},!0);var l=document.querySelectorAll(".td-icon-search, .td-header-search-button, .td-search-btn"),t=document.querySelectorAll(".td-search-wrap, .td-search-box, .td-drop-down-search");if(l.length&&t.length){var v=function(a,c){a.classList.remove("is-open");
a.setAttribute("aria-hidden","true");a._untrap&&a._untrap();a._untrap=null;w(a,!1);var b=c||a._trigger;b&&"function"===typeof b.focus&&setTimeout(function(){b.focus()},0)},x=function(a,c){a.classList.add("is-open");a.setAttribute("aria-hidden","false");var b=a.querySelector('input[type="search"], input[type="text"]')||a.querySelector('a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])');b&&b.focus();w(a,!0);a._untrap&&a._untrap();a._untrap=z(a,function(){v(a,c)});
a._trigger=c||a._trigger},y=function(){return Array.prototype.slice.call(t).find(function(a){return a.classList.contains("is-open")||"false"===a.getAttribute("aria-hidden")})||t[0]},w=function(a,c){Array.prototype.slice.call(document.body.children).forEach(function(b){b===a||b.contains(a)||(c?(m&&(b.inert=!0),b.setAttribute("aria-hidden","true")):(m&&(b.inert=!1),b.removeAttribute("aria-hidden")))})},z=function(a,c){function b(b){if("Escape"===b.key)b.preventDefault(),c&&c();else if("Tab"===b.key){var d=
Array.prototype.slice.call(a.querySelectorAll('a[href], area[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])')).filter(function(a){return null!==a.offsetParent||a===document.activeElement});if(d.length){var f=d[0];d=d[d.length-1];b.shiftKey&&document.activeElement===f?(b.preventDefault(),d.focus()):b.shiftKey||document.activeElement!==d||(b.preventDefault(),f.focus())}}}a.addEventListener("keydown",b);return function(){a.removeEventListener("keydown",
b)}};t.forEach(function(a,c){a.setAttribute("role","dialog");a.setAttribute("aria-modal","true");a.setAttribute("aria-hidden",a.classList.contains("is-open")?"false":"true");a.id||(a.id="search-dialog-"+(c+1));a.hasAttribute("aria-labelledby")||a.hasAttribute("aria-label")||((c=a.querySelector("h1, h2, h3, [data-dialog-title]"))&&!c.id&&(c.id=a.id+"-title"),c?a.setAttribute("aria-labelledby",c.id):a.setAttribute("aria-label","Search"))});l.forEach(function(a){a.closest('[data-toggle="dropdown"]')||
(a.setAttribute("aria-haspopup","dialog"),a.setAttribute("aria-expanded","false"),a.addEventListener("click",function(c){c.preventDefault();c=y();a.setAttribute("aria-expanded","true");x(c,a)}),a.addEventListener("keydown",function(c){if("Enter"===c.key||" "===c.key)c.preventDefault(),a.click()}))});document.addEventListener("click",function(a){if(a=a.target.closest(".td-search-close, .td-icon-close, .td-icon-search-close, .js-search-close"))if(a=a.closest(".td-search-wrap, .td-search-box, .td-drop-down-search")){var c=
a._trigger||Array.prototype.slice.call(l).find(function(a){return null!==a.offsetParent});v(a,c);c&&c.setAttribute("aria-expanded","false")}});document.addEventListener("keydown",function(a){if("Escape"===a.key){var c=y();c&&(c.classList.contains("is-open")||"false"===c.getAttribute("aria-hidden"))&&(a.preventDefault(),a=c._trigger||Array.prototype.slice.call(l).find(function(a){return"true"===a.getAttribute("aria-expanded")}),v(c,a),a&&a.setAttribute("aria-expanded","false"))}});document.addEventListener("focusin",
function(a){if((a=a.target.closest(".td-search-wrap, .td-search-box, .td-drop-down-search"))&&("true"===a.getAttribute("aria-hidden")||!a.classList.contains("is-open"))){var c=a._trigger||Array.prototype.slice.call(l)[0];x(a,c);c&&c.setAttribute("aria-expanded","true")}})}}}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",q,{once:!0}):q()})();
