(()=>{"use strict";var t={946:t=>{function e(t){return/[A-Z]/.test(t)?t.charCodeAt(0)-"A".charCodeAt(0):/[a-z]/.test(t)?t.charCodeAt(0)-"a".charCodeAt(0)+26:/[0-9]/.test(t)?t.charCodeAt(0)-"0".charCodeAt(0)+52:"+"===t?62:"/"===t?63:void 0}t.exports=function(t){if((t=(t=`${t}`).replace(/[ \t\n\f\r]/g,"")).length%4==0&&(t=t.replace(/==?$/,"")),t.length%4==1||/[^+/0-9A-Za-z]/.test(t))return null;let n="",r=0,i=0;for(let o=0;o>16),n+=String.fromCharCode((65280&r)>>8),n+=String.fromCharCode(255&r),r=i=0);return 12===i?(r>>=4,n+=String.fromCharCode(r)):18===i&&(r>>=2,n+=String.fromCharCode((65280&r)>>8),n+=String.fromCharCode(255&r)),n}},952:t=>{function e(t){return t<26?String.fromCharCode(t+"A".charCodeAt(0)):t<52?String.fromCharCode(t-26+"a".charCodeAt(0)):t<62?String.fromCharCode(t-52+"0".charCodeAt(0)):62===t?"+":63===t?"/":void 0}t.exports=function(t){let n;for(t=`${t}`,n=0;n255)return null;let r="";for(n=0;n>2,i[1]=(3&t.charCodeAt(n))<<4,t.length>n+1&&(i[1]|=t.charCodeAt(n+1)>>4,i[2]=(15&t.charCodeAt(n+1))<<2),t.length>n+2&&(i[2]|=t.charCodeAt(n+2)>>6,i[3]=63&t.charCodeAt(n+2));for(let t=0;t{function r(t,e,n={},r={}){const i=t.createElement(e);return Object.keys(n).forEach((t=>i[t]=n[t])),Object.keys(r).forEach((t=>i.style[t]=r[t])),i}function i(t){t?.parentNode?.removeChild(t)}function o(t){const e=[];for(;t.parentNode;)e.push(t),t=t.parentNode;return e}function a(t,e){return t?[].slice.call(t.getElementsByClassName(e)):[]}function s(t){if(t.defaultView&&t.defaultView.innerWidth>t.documentElement.clientWidth){const e=t.defaultView.innerWidth-t.documentElement.clientWidth,{overflow:n,paddingRight:r}=t.documentElement.style;return t.documentElement.style.overflow="hidden",t.documentElement.style.paddingRight=`${e}px`,{overflow:n,paddingRight:r}}return{}}function c(t,e){t.documentElement.style.overflow=e.overflow??"",t.documentElement.style.paddingRight=e.paddingRight??""}function l(t,e,n){const i=t.getElementById(e);if(i)return i;const o=r(t,"style",{id:e,type:"text/css"});return o.appendChild(document.createTextNode(n)),t.head.appendChild(o),o}function u(t,e,n){return"function"!=typeof window.CustomEvent||!t||t.dispatchEvent(new window.CustomEvent(e,{detail:n}))}function d(t,e){const n=Array.from(e.getElementsByTagName("script"));for(const e of n){const n=t.createElement("script");for(const t of Array.from(e.attributes))n.setAttribute(t.name,t.value);n.appendChild(t.createTextNode(e.innerHTML)),e.parentNode&&e.parentNode.replaceChild(n,e)}}n.r(e),n.d(e,{addStyle:()=>l,createTag:()=>r,disableScroll:()=>s,getAllAncestorsFromElement:()=>o,listByClass:()=>a,removeElement:()=>i,replaceScriptTags:()=>d,restoreScroll:()=>c,triggerEvent:()=>u})},403:t=>{t.exports="@keyframes cn_fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n\n@keyframes cn_fadeInLeft {\n from {\n opacity: 0;\n transform: translate3d(-100%, 0, 0);\n }\n to {\n opacity: 1;\n transform: none;\n }\n}\n\n@keyframes cn_fadeInDown {\n from {\n opacity: 0;\n transform: translate3d(0, -100%, 0);\n }\n to {\n opacity: 1;\n transform: none;\n }\n}\n\n@keyframes cn_fadeInRight {\n from {\n opacity: 0;\n transform: translate3d(100%, 0, 0);\n }\n to {\n opacity: 1;\n transform: none;\n }\n}\n\n@keyframes cn_fadeInUp {\n from {\n opacity: 0;\n transform: translate3d(0, 100%, 0);\n }\n to {\n opacity: 1;\n transform: none;\n }\n}\n\n@keyframes cn_zoomIn {\n from {\n opacity: 0;\n transform: scale3d(0.3, 0.3, 0.3);\n }\n 50% {\n opacity: 1;\n }\n}\n\n@keyframes cn_bounceIn {\n from,\n 20%,\n 40%,\n 60%,\n 80%,\n to {\n animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);\n }\n 0% {\n opacity: 0;\n transform: scale3d(0.3, 0.3, 0.3);\n }\n 20% {\n transform: scale3d(1.1, 1.1, 1.1);\n }\n 40% {\n transform: scale3d(0.9, 0.9, 0.9);\n }\n 60% {\n opacity: 1;\n transform: scale3d(1.03, 1.03, 1.03);\n }\n 80% {\n transform: scale3d(0.97, 0.97, 0.97);\n }\n to {\n opacity: 1;\n transform: scale3d(1, 1, 1);\n }\n}\n\n@keyframes cn_fadeOut {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n}\n\n@keyframes cn_fadeOutLeft {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n transform: translate3d(-100%, 0, 0);\n }\n}\n\n@keyframes cn_fadeOutDown {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n transform: translate3d(0, 100%, 0);\n }\n}\n\n@keyframes cn_fadeOutRight {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n transform: translate3d(100%, 0, 0);\n }\n}\n\n@keyframes cn_fadeOutUp {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n transform: translate3d(0, -100%, 0);\n }\n}\n\n@keyframes cn_zoomOut {\n from {\n opacity: 1;\n }\n 50% {\n opacity: 0;\n transform: scale3d(0.3, 0.3, 0.3);\n }\n to {\n opacity: 0;\n }\n}\n\n@keyframes cn_bounceOut {\n 20% {\n transform: scale3d(0.9, 0.9, 0.9);\n }\n 50%,\n 55% {\n opacity: 1;\n transform: scale3d(1.1, 1.1, 1.1);\n }\n to {\n opacity: 0;\n transform: scale3d(0.3, 0.3, 0.3);\n }\n}\n\n.cn__slider {\n position: relative;\n overflow: hidden;\n}\n\n.cn__frame {\n width: 100%;\n position: relative;\n overflow: hidden;\n white-space: nowrap;\n}\n\nul.cn__slides.js_slides {\n display: block;\n margin: 0;\n padding: 0;\n font-size: 0;\n line-height: 0;\n}\n\nli.cn__li {\n position: relative;\n display: inline-block;\n overflow: hidden;\n font-size: 14px;\n line-height: 14px;\n vertical-align: top;\n}\n\n.cn__prev,\n.cn__next {\n position: absolute;\n top: 50%;\n margin-top: -25px;\n display: block;\n cursor: pointer;\n}\n\n.cn__next {\n right: 0;\n}\n\n.cn__prev {\n left: 0;\n}\n\n.cn__next svg,\n.cn__prev svg {\n width: 25px;\n}\n\n[data-cn-required-message-for]:not(.visible) {\n display: none;\n}\n\n.cn_product {\n float: left;\n}\n\n.cn_rating {\n --star-size: 20px;\n --star-color: #fc0;\n --star-background: #ccc;\n --percent: calc(var(--rating) / 5 * 100%);\n font-size: var(--star-size);\n font-family: Times;\n line-height: 1;\n}\n\n.cn_rating::before {\n content: '★★★★★';\n letter-spacing: 3px;\n background: linear-gradient(\n 90deg,\n var(--star-color) var(--percent),\n var(--star-background) var(--percent)\n );\n -webkit-background-clip: text;\n background-clip: text;\n -webkit-text-fill-color: transparent;\n}\n\n.cn_countdown {\n line-height: 3em;\n}\n\n.cn_countdown .cn_numbers {\n text-align: center;\n display: inline-block;\n font-weight: bold;\n padding: 0 10px;\n}\n\n.cn_countdown .cn_time-labels {\n font-weight: bold;\n text-align: center;\n}\n"}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var o=e[r]={exports:{}};return t[r](o,o.exports,n),o.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r=n(703);function i(){return"_"+Math.random().toString(36).substr(2,9)}function o(t,e,n){return t.replace(/]*href\s*=\s*(["'])(.*?)\1[^<>]*>/gi,((t,r,i)=>{const o=function(t,e){const[n,r]=t.split("?"),i=(t,n)=>Object.entries(e).reduce(((t,[e,r])=>t.replace(new RegExp(`{{${e}}}`,"g"),n(r))),t);return i(n,(t=>t))+(r?"?"+i(r,encodeURIComponent):"")}(i,e),a=t.match(/data-cn-alias\s*=\s*(["'])(.*?)\1/i)?.[2],s=`data-cn-alias="${a??i.replace(/{{/g,"{%{").replace(/}}/g,"}%}")}"`+(n?` data-cn-element-id="${n}"`:"");return t.replace(/\s*data-cn-alias\s*=\s*(["'])(.*?)\1\s*/gi," ").replace(/href\s*=\s*(["'])(.*?)\1/i,`href="${o}" ${s}`)}))}function a(t,e){return Object.entries(e).reduce(((t,[e,n])=>t.replace(new RegExp(`{{${e}}}`,"g"),(()=>n))),t)}function s(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 c(t){for(var e=1;e`${t}="${e}"`)).join(" "):"";return`
${t}
`}(e,c(c({class:[i,...t.classes].join(" ")},r),{},{style:d(t,r?.style)}));return a(o(s,n.variableValues),n.variableValues).replace(/{%{/g,"{{").replace(/}%}/g,"}}")}function d(t,e){return(t.backgroundColor?`background-color: ${t.backgroundColor};`:"")+f(t.paddingTop,t.paddingRight,t.paddingBottom,t.paddingLeft)+(e??"")}function f(t,e,n,r){return(t?`padding-top: ${t};`:"")+(e?`padding-right: ${e};`:"")+(n?`padding-bottom: ${n};`:"")+(r?`padding-left: ${r};`:"")}function p(t,e,n,r){return(t?`border-top-left-radius: ${t};`:"")+(e?`border-top-right-radius: ${e};`:"")+(n?`border-bottom-left-radius: ${n};`:"")+(r?`border-bottom-right-radius: ${r};`:"")}function m(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 b(t){for(var e=1;e`
=s?" cn__mobile-hidden":""}">`+a(r,t)+"
",f=n.slice(0,l).map(d).join("");return u(t,f,e)}(t,e,n):function(t,e,n){const r=o(t.templateHtml,e.variableValues,t.id),i=t=>`
  • ${a(r,t)}
  • `,s=b(b({},t),{},{classes:[...t.classes,"cn__slider","js_slide"]}),c=`
      ${n.map(i).join("")}
    ${t.carouselLeftArrowHtml}${t.carouselRightArrowHtml}`,l={"data-column-quantity":t.columnQuantity.toString(),"data-carousel-interval":t.carouselInterval.toString(),"data-responsive-column-quantity":t.responsiveColumnQuantity.toString(),"data-content-responsive-breakpoint":e.responsiveBreakpoint,style:"opacity: 0;"};return u(s,c,e,l)}(t,e,n)}function h(t){return"products"===t.elementTypeId}function v(t){return`
    `}function w(t){const e=k(t,"minutes",t.minutesLabel),n=k(t,"seconds",t.secondsLabel);let r="";["untilDays","untilHours"].includes(t.format)&&(r=k(t,"hours",t.hoursLabel));let i="";"untilDays"===t.format&&(i=k(t,"days",t.daysLabel));const o=`${i}${r}${e}${n}`;return`
    ${o}
    `}function _(t){return t?`;font-family: ${t}`:""}function k(t,e,n){return`
    ${n}
    `}function C(t){const e=function(t){const{variableValues:e,products:n,webContent:r}=t;return{variableValues:e,products:n,responsiveBreakpoint:r.responsiveBreakpoint}}(t),n=t.webContent.sections.map((t=>function(t,e){const n=t.blocks.map((t=>function(t,e){const n=t.cells.map((t=>function(t,e){const n=t.elements.map((t=>function(t,e){switch(t.elementTypeId){case"broke":case"button-link":case"image":case"text":case"button-submit":case"divider":case"html":case"checkbox":case"radio-button":case"input-text":case"input-number":case"input-email":case"select":case"input-date":case"textarea":case"whatsapp":case"countdown":case"video":{const{html:n,attributes:r}=function(t){switch(t.elementTypeId){case"broke":return{html:" ",attributes:{style:`line-height: ${t.distance};`}};case"button-link":return{html:`
    ${t.html}
    `,attributes:{style:`text-align: ${t.buttonAlign};`}};case"divider":return{html:`
     
    `};case"html":return{html:t.html};case"image":return{html:S(t),attributes:{style:`text-align: ${t.imageAlign};`}};case"text":return{html:t.html,attributes:{style:" word-wrap: break-word;"}};case"checkbox":return{html:A(t)};case"radio-button":return{html:O(t)};case"button-submit":return{html:``,attributes:{style:`text-align: ${t.buttonAlign};`}};case"input-text":return{html:$(t,"text")};case"input-date":return{html:$(t,"date")};case"input-number":return{html:$(t,"number")};case"input-email":return{html:$(t,"email")};case"select":return{html:x(t)};case"textarea":return{html:E(t)};case"whatsapp":return{html:T(t),attributes:{style:`text-align: ${t.buttonAlign};`}};case"video":return{html:v(t)};case"countdown":return{html:w(t)};default:return{html:""}}}(t);return u(t,n,e,r)}case"products":return y(t,e);default:return""}}(t,e))).join(" ");return`
    ${n}
    `}(t,e))).join(" ");return`
    ${n}
    `}(t,e))).join("");return`
    ${n}
    `}(t,e))).join(""),{form:r}=t.webContent;return r?`
    ${n}
    `:n}function E(t){const e=i();return P(e,t.labelHtml,t.labelAlign,t.labelPaddingTop,t.labelPaddingRight,t.labelPaddingBottom,t.labelPaddingLeft)+"`+(t.isRequired?j(t):"")}function S(t){const{imageUrl:e,imageAlt:n,imageTitle:r,imageLink:i,imageTarget:o}=t,a=`${n}`;return t.imageLink?`${a}`:a}function $(t,e){const n=i();return P(n,t.labelHtml,t.labelAlign,t.labelPaddingTop,t.labelPaddingRight,t.labelPaddingBottom,t.labelPaddingLeft)+``+(t.isRequired?j(t):"")}function P(t,e,n,r,i,o,a){return``}function A(t){return`
    ${t.labelHtml}
    `+t.options.map(((e,n)=>`")).join("")+"
    "+(t.areRequired?j(t):"")}function x(t){const e=i();return P(e,t.labelHtml,t.labelAlign,t.labelPaddingTop,t.labelPaddingRight,t.labelPaddingBottom,t.labelPaddingLeft)+""+(t.isRequired?j(t):"")}function O(t){return`
    ${t.labelHtml}
    `+t.options.map(((e,n)=>`")).join("")+"
    "+(t.isRequired?j(t):"")}function T(t){const e=!!t.contactNumber,n=!!t.message;return`{const r=e.exec(t);return r?encodeURIComponent(n).concat(r[0]):encodeURIComponent(n)})).join("")}(t.message)}`:"")}" title="${t.buttonTitle}" target="${t.linkTarget??"_self"}">
    ${t.html}
    `}function I(t){return"display: inline-block;word-wrap: break-word;min-height: 18px;min-width: 18px;cursor: pointer;box-sizing: border-box;"+(t.buttonTextColor?`color: ${t.buttonTextColor};`:"")+(t.buttonAdjustToWidth?"width: 100%;":"")+p(t.borderTopLeftRadius,t.borderTopRightRadius,t.borderBottomLeftRadius,t.borderBottomRightRadius)+(t.buttonBackgroundColor?`background-color: ${t.buttonBackgroundColor};`:"")+(t.borderWidth?`border-width: ${t.borderWidth};`:"")+(t.borderWidth?`border-style: ${t.borderStyle};`:"")+(t.borderColor?`border-color: ${t.borderColor};`:"")+f(t.buttonPaddingTop,t.buttonPaddingRight,t.buttonPaddingBottom,t.buttonPaddingLeft)}function j(t){return t.validationRequiredMessageHtml?`
    ${t.validationRequiredMessageHtml}
    `:""}const{listByClass:L}=n(703);let B;function N(t){const e=L(t,"cn__slider");e&&e.forEach((function(e){!function(e){e.style.opacity=1;var n=Array.prototype.slice.call(e.querySelectorAll(".js_slide"));if(0===n.length)return;var r,i=Math.min(n.length,parseInt(e.getAttribute("data-column-quantity"),10)),o=parseInt(e.getAttribute("data-carousel-interval"),10),a=Math.min(n.length,parseInt(e.getAttribute("data-responsive-column-quantity"),10)),s=parseInt(e.getAttribute("data-content-responsive-breakpoint"),10),c=100/i,l=100/a,u={infinite:i},d=!1,f=B(e,u),p=!1;y(),Array.prototype.slice.call(e.querySelectorAll(".cn__prev, .cn__next")).forEach((function(t,e){t.setAttribute("data-cn-original-display",t.style.display)})),window.addEventListener("resize",(function(t){y(t.target)})),e.querySelector(".js_prev").addEventListener("click",g),e.querySelector(".js_next").addEventListener("click",g),e.addEventListener("mouseleave",g),e.addEventListener("touchend",g),e.addEventListener("mouseover",w),u.infinite=s&&p&&(p=!1,u.infinite=i),u.infinite===n.length?k():C(),f.destroy(),v(),h(p),f.setup()}function h(t){Array.prototype.slice.call(e.querySelectorAll(".js_slide")).forEach((function(e){e.style.width=(t?l:c)+"%"}))}function v(){var t=e.querySelector(".js_slides");t.innerHtml="",n.forEach((function(e){t.appendChild(e)}))}function w(){clearTimeout(r)}function _(){o<=0||(r=setTimeout((function(){d||f.isTouching()||f.next(),_()}),1e3*o))}function k(){d=!0,Array.prototype.slice.call(e.querySelectorAll(".cn__prev, .cn__next")).forEach((function(t){t.style.display="none"}))}function C(){d=!1,Array.prototype.slice.call(e.querySelectorAll(".cn__prev, .cn__next")).forEach((function(t){t.style.display=t.getAttribute("data-cn-original-display")}))}}(e)}))}var R,D,M,q,W;function H(t){const e=(0,r.listByClass)(t,"cn_countdown"),n=1e3,i=60;e&&e.forEach((function(t){!function(t){const e=t.childNodes[0],r=new Date(e.getAttribute("data-expiration-date")??""),o=e.getAttribute("data-format")??"";let a,s,c="00",l="00",u="00",d="00";"untilDays"===o&&(a=t.querySelector(".cn_number-days"));"untilDays"!==o&&"untilHours"!==o||(s=t.querySelector(".cn_number-hours"));const f=t.querySelector(".cn_number-minutes"),p=t.querySelector(".cn_number-seconds");let m;b(),"untilDays"===o&&(a.innerHTML=`${c}`);"untilDays"!==o&&"untilHours"!==o||(s.innerHTML=`${l}`);function b(){m=r.getTime()-(new Date).getTime(),y(m),p.innerHTML=`${d}`,f.innerHTML=`${u}`,"untilDays"!==o&&"untilHours"!==o||(s.innerHTML=`${l}`),"untilDays"===o&&(a.innerHTML=`${c}`)}function g(t){return Math.floor(t).toString().padStart(2,"0")}function y(t){t>0&&(d=g(t/n%i),"untilDays"===o?(u=g(t/6e4%i),l=g(t/36e5%24),c=g(t/864e5)):"untilHours"===o?(u=g(t/6e4%i),l=g(t/36e5),c="00"):"untilMinutes"===o&&(u=g(t/6e4),l="00",c="00"))}f.innerHTML=`${u}`,p.innerHTML=`${d}`,setInterval((()=>{b()}),1e3)}(t)}))}function z(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 U(t){for(var e=1;e{if(!(t.currentTarget instanceof HTMLAnchorElement))return;const r=t.currentTarget,i=r.getAttribute("href")??"",o=r.getAttribute("data-cn-track-click");switch("#__cn_ask_for_push_subscription"===i&&e.subscribeToPushNotifications(),o){case"async":e.sendEvents([U({type:"web-link-clicked"},V(r,n))],{entityInfo:{}});break;case"sync":t.preventDefault(),e.sendEvents([U({type:"web-link-clicked"},V(r,n))],{onResponded:()=>window.location.assign(i),entityInfo:{}}),setTimeout((()=>window.location.assign(i)),1e3);break;case"track-click":navigator.sendBeacon(`${e.apiBaseUrl}t/w`,JSON.stringify(U({token:e.token,entityId:e.tracker},V(r,n))))}},i=n?"a":"a[data-cn-track-click]",o=t.querySelectorAll(i);return Array.from(o).forEach((t=>{const i=t.getAttribute("href");if(!i)return;if(!n&&i.startsWith("javascript:")&&!t.getAttribute("data-cn-alias"))return;const o=function(t,e,n){if("none"===n||t.startsWith(e.apiBaseUrl+"t/c"))return"none";const r=new URL(t,window.location.origin);if(r.hash||r.href===`${window.location.origin}/#`)return"sync"===n||"track-click"===n?n:"async";if(r.toString().startsWith(window.location.origin))return"sync"===n||"async"===n||"track-click"===n?n:"after-redirect";if("http:"===r.protocol||"https:"===r.protocol)return"sync"===n||"async"===n?n:"track-click";if("javascript:"===r.protocol)return"async";return"async"}(i,e,t.getAttribute("data-cn-track-click")??void 0);switch(o){case"none":break;case"after-redirect":t.setAttribute("data-cn-track-click",o),t.setAttribute("href",function(t,e,n){const r=new URL(e,"https://x.x"),i="https://x.x"===r.origin,o=new URLSearchParams(r.search);o.delete("cnWebLinkClicked"),r.search=o.toString();const a=i?J(e)+r.toString().replace(/^https:\/\/x.x\//,""):r.toString(),s=U(U({},V(t,n)),{},{linkUrl:a});return o.set("cnWebLinkClicked",JSON.stringify(s)),r.search=o.toString(),i?J(e)+r.toString().replace(/^https:\/\/x.x\//,""):r.toString()}(t,i,n));break;case"track-click":case"async":case"sync":t.setAttribute("data-cn-track-click",o),t.onclick=r}})),!0}function J(t){const e=t.match(/^(\.\.\/|\.\/|\/)+/);return e?e[0]:""}function Q(t){return t.form?.querySelector(`[data-cn-required-message-for="${t.name}"]`)??void 0}function Y(t){switch(t.type){case"text":case"email":case"number":case"textarea":case"date":return function(t){return t.hasAttribute("data-cn-required")?()=>""===t.value.trim()?(Q(t)?.classList.add("visible"),!1):(Q(t)?.classList.remove("visible"),!0):()=>!0}(t);case"checkbox":return function(t){const e=t.form?.querySelector(`input[type="checkbox"][name="${t.name}"][data-cn-required]`);if(!e)return()=>!0;const n=e.getAttribute("data-cn-required")?Number(e.getAttribute("data-cn-required")):1;return()=>{const e=t.form?.querySelectorAll(`input[type="checkbox"][name="${t.getAttribute("name")}"]`),r=Array.from(e).reduce(((t,e)=>t+(e.checked?1:0)),0);return r{const e=t.form?.querySelectorAll(`input[type="radio"][name="${t.getAttribute("name")}"]`),n=Array.from(e).some((t=>t.checked));return n?(Q(t)?.classList.remove("visible"),!0):(Q(t)?.classList.add("visible"),!1)}:()=>!0}(t);case"select-one":return function(t){return t.hasAttribute("data-cn-required")?()=>t.value?(Q(t)?.classList.remove("visible"),!0):(Q(t)?.classList.add("visible"),!1):()=>!0}(t);default:return()=>!0}}function X(t){return Array.from(t.querySelectorAll("input,textarea,select"))}function Z(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 G(t){for(var e=1;et.onchange=Y(t)))}(o),function(t,e){e.fields.forEach((e=>{if("date"===e.type){const n=t.querySelector(`input[name="${e.name}"]`);n instanceof HTMLInputElement&&"date"!==n.type&&(n.setAttribute("pattern","[0-9]{4}-(0[1-9]|1[012])-(0[1-9]|1[0-9]|2[0-9]|3[01])"),n.setAttribute("placeholder","YYYY-MM-DD"),n.setAttribute("maxLength","10"))}}))}(o,i),o.onsubmit=function(e){e.preventDefault();const o=e.target;if(!function(t){return X(t).map(Y).map((t=>t())).every((t=>t))}(o))return;const a=function(t,e){const n=(e,n)=>{switch(n.type){case"text":case"email":case"number":{const r=t.querySelector(`input[name="${n.name}"]`);return r instanceof HTMLInputElement?G(G({},e),{},{[n.name]:r.value}):e}case"select":{const r=t.querySelector(`select[name="${n.name}"]`);return r instanceof HTMLSelectElement?G(G({},e),{},{[n.name]:r.value}):e}case"textarea":{const r=t.querySelector(`textarea[name="${n.name}"]`);return r instanceof HTMLTextAreaElement?G(G({},e),{},{[n.name]:r.value}):e}case"submit":{const r=t.querySelector(`button[name="${n.name}"]`);return r instanceof HTMLButtonElement?G(G({},e),{},{[n.name]:r.value}):e}case"checkbox":{const r=t.querySelectorAll(`input[type="checkbox"][name="${n.name}"]:checked`),i=Array.from(r).filter((t=>n.values.some((e=>e.id===t.value)))).map((t=>t.value));return G(G({},e),{},{[n.name]:1===r.length?i[0]:i})}case"radio-button":{const r=t.querySelector(`input[type="radio"][name="${n.name}"]:checked`);return r instanceof HTMLInputElement?G(G({},e),{},{[n.name]:r.value}):e}case"date":{const r=t.querySelector(`input[name="${n.name}"]`);if(r instanceof HTMLInputElement){const t=r.value.split("-");return G(G({},e),{},{[n.name]:new Date(+t[0],+t[1]-1,+t[2])})}return e}default:return e}};return e.fields.reduce(n,{})}(o,i);"add"===i.type&&i.identifiedByFieldName&&r?.setLastSubmittedFormPk(a[i.identifiedByFieldName].toString()),r?.sendEvents([{type:"form-submitted",formId:i.formId,contentId:t.webContent.id,workflowDefinitionId:t.workflowDefinitionId,payload:a,sendUuid:t.sendUuid}],{onResponded:()=>{i.redirectUrl&&window.location.assign(i.redirectUrl)}}),i.closeOnSubmit&&n()})}function nt(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 rt(t){for(var e=1;e25||Math.abs(S.x)>i/3,s=!f&&S.x>0||f===o.length-1&&S.x<0,c=S.x<0;$||(r&&!s?v(!1,c):h(n.x,p.snapBackSpeed)),E=void 0,b=!1,a.removeEventListener("touchmove",x),a.removeEventListener("touchend",O),a.removeEventListener("mousemove",x),a.removeEventListener("mouseup",O),a.removeEventListener("mouseleave",O),y("on","touchend",{event:t})}function T(t){S.x&&t.preventDefault()}function I(t){_(),y("on","resize",{event:t})}return w(),{setup:w,reset:_,slideTo:function(t){v(t)},returnIndex:function(){return f-p.infinite||0},prev:k,next:C,destroy:function(){y("before","destroy"),a.removeEventListener(u.transitionEnd,P),a.removeEventListener("touchstart",A,m),a.removeEventListener("touchmove",x,m),a.removeEventListener("touchend",O),a.removeEventListener("mousemove",x),a.removeEventListener("mousedown",A),a.removeEventListener("mouseup",O),a.removeEventListener("mouseleave",O),a.removeEventListener("click",T),p.window.removeEventListener("resize",I),c&&c.removeEventListener("click",k),l&&l.removeEventListener("click",C),p.infinite&&Array.apply(null,Array(p.infinite)).forEach((function(){s.removeChild(s.firstChild),s.removeChild(s.lastChild)})),y("after","destroy")},isTouching:function(){return b}}};const ot=n(403);function at(t,e,n){const i=function(t,e,n,i){switch(e.webContent.webContentTypeId){case"popup":return function(t,e,n,i){const{webContent:o}=e;st(t);const a=ct(t,o);function s({backdropBlur:t,backdropSaturate:e,backdropBrightness:n,backdropContrast:r}){return!!ht(t,e,n,r).backdropFilter}const{uuid:c,backdropColor:l,backgroundColor:u,borderBottomLeftRadius:d,borderBottomRightRadius:f,borderTopLeftRadius:p,borderTopRightRadius:m,width:b,position:g,distanceToWindow:y}=o,h=s(o),v=(0,r.createTag)(t,"div",{className:`cn_content_backdrop-${c}`},rt(rt({},!h&&{backgroundColor:l,animationName:"cn_fadeIn",animationDuration:`${o.entranceAnimationDuration}ms`}),{},{overflow:"auto",display:"flex",justifyContent:"center",alignItems:_(g),position:"fixed",top:"0",bottom:"0",left:"0",right:"0"},bt(o.zIndex)));if(h){const e=(0,r.createTag)(t,"div",{className:`cn_content_backdrop_filter-${c}`},rt(rt({backgroundColor:l,position:"absolute",width:"100%",height:"100%"},w(o)),{},{animationName:"cn_fadeIn",animationDuration:`${o.entranceAnimationDuration}ms`,pointerEvents:"none"}));v.appendChild(e)}function w({backdropBlur:t,backdropSaturate:e,backdropBrightness:n,backdropContrast:r}){return ht(t,e,n,r)}function _(t){switch(t){case"center":case"left":case"right":return"center";case"bottom":case"bottom-left":case"bottom-right":return"flex-end";default:return"flex-start"}}const k=(0,r.createTag)(t,"div",{className:`cn_content_popup-${c}`},rt(rt({position:"relative",margin:C(g,y),maxWidth:"100%",borderBottomLeftRadius:d,borderBottomRightRadius:f,borderTopLeftRadius:p,borderTopRightRadius:m},yt(o)),mt(o)));function C(t,e){switch(t){case"center":return"auto";case"left":return`auto auto auto ${e}`;case"right":return`auto ${e} auto auto`;case"bottom":return`auto auto ${e} auto`;case"bottom-left":return`auto auto ${e} ${e}`;case"bottom-right":return`auto ${e} ${e} auto`;case"top":return`${e} auto auto auto`;case"top-left":return`${e} auto auto ${e}`;case"top-right":return`${e} ${e} auto auto`}}"none"!==o.entranceAnimation&&o.entranceAnimationDuration>0?k.addEventListener("animationend",(()=>{n(E)}),{once:!0}):setTimeout((()=>n(E)));v.appendChild(k);const E=ut(t,e,rt(rt(rt({backgroundColor:u,borderBottomLeftRadius:d,borderBottomRightRadius:f,borderTopLeftRadius:p,borderTopRightRadius:m},pt(o)),gt(e)),{},{width:b,maxWidth:"100%",overflow:"hidden"}));k.appendChild(E),k.appendChild(lt(t,o));const S=()=>ft(k,o,(()=>{(0,r.removeElement)(v),(0,r.removeElement)(a),(0,r.restoreScroll)(t,$)}));v.onclick=t=>{(t.target===v&&o.backdropClosePopupOnClick||dt(t))&&(t.preventDefault(),S())},e.webContent.form&&et(e,E,S,i);const $=(0,r.disableScroll)(t);return t.body.appendChild(v),E}(t,e,n,i);case"full-screen":return function(t,e,n,i){const{webContent:o}=e;st(t);const a=ct(t,o),{uuid:s,backgroundColor:c,width:l}=o,u=(0,r.createTag)(t,"div",{className:`cn_content_backdrop-${s}`},rt(rt(rt(rt({backgroundColor:c},mt(o)),{},{display:"flex",overflow:"auto",justifyContent:"center",alignItems:"center",position:"fixed",top:"0",bottom:"0",left:"0",right:"0"},pt(o)),bt(o.zIndex)),yt(o))),d=ut(t,e,{maxWidth:"100%",width:l,margin:"auto"});u.appendChild(d),u.appendChild(lt(t,o));const f=()=>{ft(u,o,(()=>{(0,r.restoreScroll)(t,p),(0,r.removeElement)(u),(0,r.removeElement)(a)}))};u.onclick=t=>{dt(t)&&(t.preventDefault(),f())},e.webContent.form&&et(e,d,f,i);"none"!==o.entranceAnimation&&o.entranceAnimationDuration>0?u.addEventListener("animationend",(()=>{n(d)}),{once:!0}):setTimeout((()=>n(d)));const p=(0,r.disableScroll)(t);return t.body.appendChild(u),d}(t,e,n,i);case"slide-in":return function(t,e,n,i){const{webContent:o}=e;st(t);const a=ct(t,o),{uuid:s,backgroundColor:c,borderBottomLeftRadius:l,borderBottomRightRadius:u,borderTopLeftRadius:d,borderTopRightRadius:f,position:p,distanceToWindow:m,width:b}=o,g=(0,r.createTag)(t,"div",{className:`cn_content_slide_in-${s}`},rt(rt(rt(rt({position:"fixed",width:b,borderBottomLeftRadius:l,borderBottomRightRadius:u,borderTopLeftRadius:d,borderTopRightRadius:f,maxWidth:`calc(100% - ${m})`,maxHeight:`calc(100% - ${m})`},function(t,e){switch(t){case"bottom-left":return{bottom:e,left:e};case"bottom-right":return{bottom:e,right:e};default:return{}}}(p,m)),mt(o)),bt(o.zIndex)),yt(o))),y=ut(t,e,rt(rt(rt({display:"flex",backgroundColor:c,borderBottomLeftRadius:l,borderBottomRightRadius:u,borderTopLeftRadius:d,borderTopRightRadius:f},pt(o)),gt(e)),{},{overflow:"hidden"})),h=()=>{ft(g,o,(()=>{(0,r.removeElement)(g),(0,r.removeElement)(a)}))};g.appendChild(y),g.appendChild(lt(t,o)),g.onclick=t=>{dt(t)&&(t.preventDefault(),h())},e.webContent.form&&et(e,y,h,i);"none"!==o.entranceAnimation&&o.entranceAnimationDuration>0?g.addEventListener("animationend",(()=>{n(y)}),{once:!0}):setTimeout((()=>n(y)));return t.body.appendChild(g),y}(t,e,n,i);case"floating-bar":return function(t,e,n,i){const{webContent:o}=e;st(t);const a=ct(t,o),{backgroundColor:s,position:c}=o,l=ut(t,e,rt(rt(rt(rt(rt({display:"flex",backgroundColor:s},function(t){switch(t){case"top":return{top:"0",left:"0",right:"0"};case"bottom":return{bottom:"0",left:"0",right:"0"};default:return{}}}(c)),{},{position:"fixed"},pt(o)),bt(o.zIndex)),gt(e)),yt(o))),u=()=>{ft(l,o,(()=>{(0,r.removeElement)(l),(0,r.removeElement)(a)}))};l.onclick=t=>{dt(t)&&(t.preventDefault(),u())},e.webContent.form&&et(e,l,u,i);return setTimeout((()=>n(l))),t.body.appendChild(l),l}(t,e,n,i);case"inline":return function(t,e,n,i){const{webContent:o,selector:a,position:s}=e;st(t);const c=ct(t,o),l=t.querySelector(a);if(!l)return;const{backgroundColor:u}=o,d=ut(t,e,rt(rt(rt(rt({display:"flex",backgroundColor:u},pt(o)),bt(o.zIndex)),gt(e)),yt(o)));switch(s){case"before":l.parentNode?.insertBefore(d,l);break;case"after":l.parentNode?.insertBefore(d,l.nextSibling);break;case"append":l.appendChild(d);break;default:l.innerHTML="",l.appendChild(d)}const f=()=>{ft(d,o,(()=>{(0,r.removeElement)(d),(0,r.removeElement)(c)}))};d.onclick=t=>{dt(t)&&(t.preventDefault(),f())},e.webContent.form&&et(e,d,f,i);return setTimeout((()=>n(d))),d}(t,e,n,i)}}(t,e,(t=>{N(t)}),n);return i&&(H(i),n&&K(i,n,e),(0,r.replaceScriptTags)(t,i)),i}function st(t){(0,r.addStyle)(t,"cn_style",ot)}function ct(t,{uuid:e,responsiveBreakpoint:n,sections:i}){return(0,r.addStyle)(t,`cn_style_${e}`,`.cn_content.id-${e} .cn_button_link p{margin: 0; line-height: 1em;}`+function(t,e,n){const r=n.flatMap((t=>t.blocks.flatMap((t=>t.cells.flatMap((t=>t.elements.filter(h)))))));return 0===r.length?"":`@media (min-width: ${t}) {.id-${e} .cn__desktop-hidden { display: none !important; }}`+r.map((t=>{const n=100/t.columnQuantity;return`.id-${e} .cn_product { width: ${n}%; }`})).join("")+`@media (max-width: ${parseInt(t,10)-1}px) {`+`.id-${e} .cn__mobile-hidden { display: none !important; }`+r.map((t=>{const n=100/t.responsiveColumnQuantity;return`.id-${e} .cn_product { max-width: ${n}% !important; width: ${n}% !important; }`})).join("")+"}"}(n,e,i))}function lt(t,e){const{uuid:n,closeButtonHtml:i}=e,o=(0,r.createTag)(t,"div",{className:`cn_content_close-${n}`});return o.innerHTML=i,o}function ut(t,e,n){const{uuid:i,classes:o,webContentTypeId:a}=e.webContent,s=(0,r.createTag)(t,"div",{className:["cn_content",`cn_content_type_${a}`,`id-${i}`,...o].join(" ")},n);return s.innerHTML=function(t){return``}(e)+C(e),s}function dt(t){return(0,r.getAllAncestorsFromElement)(t.target).some((t=>["#__cn_close_content","#__cn_ask_for_push_subscription"].includes(t.getAttribute?.("href"))))}function ft(t,e,n){const i=()=>{n(),(0,r.triggerEvent)(t.ownerDocument,"connectif.webContent.afterClose",{webContent:e})};if((0,r.triggerEvent)(t.ownerDocument,"connectif.webContent.beforeClose",{webContent:e}))if("popup"===e.webContentTypeId||"full-screen"===e.webContentTypeId||"slide-in"===e.webContentTypeId)switch(e.exitAnimation){case"fadeOut":case"fadeOutLeft":case"fadeOutDown":case"fadeOutRight":case"fadeOutUp":case"zoomOut":case"bounceOut":if("popup"===e.webContentTypeId&&t.parentElement){const n=t.previousSibling?t.previousSibling:t.parentElement;n.style.animationName="cn_fadeOut",n.style.animationDuration=`${e.exitAnimationDuration}ms`}t.style.animationName=`cn_${e.exitAnimation}`,t.style.animationDuration=`${e.exitAnimationDuration}ms`,t.addEventListener("animationend",i);break;default:i()}else i()}function pt({borderWidth:t,borderStyle:e,borderColor:n}){return t&&e?{borderWidth:t,borderStyle:e,borderColor:n||"transparent"}:{}}function mt(t){return{animationName:`cn_${t.entranceAnimation}`,animationDuration:`${t.entranceAnimationDuration}ms`}}function bt(t){return"number"==typeof t?{zIndex:t.toString()}:{}}function gt(t){const{webContent:{boxShadowHorizontal:e,boxShadowVertical:n,boxShadowBlur:r,boxShadowSpread:i,boxShadowColor:o}}=t;function a(t){return!!t}if(!a(e)&&!a(n)&&!a(r)&&!a(i)||!o)return{};return{boxShadow:`${e||0}px ${n||0}px ${r||0}px ${i||0}px ${o||"transparent"}`}}function yt({backgroundBlur:t,backgroundSaturate:e,backgroundBrightness:n,backgroundContrast:r}){return ht(t,e,n,r)}function ht(t,e,n,r){if("number"!=typeof t&&"number"!=typeof e&&"number"!=typeof n&&"number"!=typeof r)return{};return{backdropFilter:`blur(${t??0}px) saturate(${e??1}) brightness(${n??1}) contrast(${r??1})`}}var vt=n(946),wt=n.n(vt),_t=n(952),kt=n.n(_t);function Ct(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 Et(t){for(var e=1;e{if(xt&&At&&"serviceWorker"in navigator&&"PushManager"in window)return navigator.serviceWorker.register(At).then((function(e){Ot=e,t()}),t);t()}))}function Dt(){return new Promise((t=>{if(!jt)return void t();window.addEventListener("message",(function(e){if("ready"===e.data.id)return clearTimeout(Lt),void t();if("connectif.3PCookiesNotAllowed"===e.data.id)return jt=null,void t();const n=It[e.data.id];n&&(delete It[e.data.id],n(e.data.value))}));const e=document.getElementById("connectif-iframe");if(e)Tt=e.contentWindow,Mt();else{const t=document.createElement("iframe");t.setAttribute("src",jt),t.setAttribute("style","display: none;"),t.setAttribute("width","0"),t.setAttribute("height","0"),document.body.appendChild(t),Tt=t.contentWindow}}))}function Mt(){Tt.postMessage({method:"check-ready"},jt),Lt=setTimeout(Mt,100)}function qt(t,e){return(0,r.triggerEvent)(Bt,t,e)}function Wt(t,e){window.localStorage.setItem(t,e),jt&&Tt.postMessage({method:"set",key:Ut(t),value:e},jt)}function Ht(t,e){return new Promise((function(n){if(window.localStorage.setItem(t,e),jt){const r=Math.random().toString(36).substr(2,9);It[r]=n,Tt.postMessage({method:"set",key:Ut(t),value:e,id:r},jt)}else n()}))}function zt(t){return jt?new Promise((function(e){const n=Math.random().toString(36).substr(2,9);It[n]=e,Tt.postMessage({method:"get",key:Ut(t),id:n},jt)})).then((e=>(null===e&&null!==(e=window.localStorage.getItem(t))&&(Wt(t,e),Tt.postMessage({method:"set",key:Ut(t),value:e},jt)),e))):Promise.resolve(window.localStorage.getItem(t))}function Ut(t){return Pt+"_"+t}function Ft(t){if(t)return"true"===t.getAttribute("data-field-list")?[...t.children||[]].map((t=>Zt(t))):Zt(t)}function Vt(){let t,e=[];const n=document.querySelector("meta[name='keywords']");return n&&(t=n.getAttribute("content")),t&&(e=t.split(",")),e.filter(re).map((t=>t.trim().substring(0,25))).slice(0,10)}function Kt(t){if(!t||"function"!=typeof t.toJSON)return!1;const e=t.toJSON();return"string"==typeof e.endpoint&&e.keys&&"string"==typeof e.keys.p256dh&&e.keys.p256dh.length>0&&"string"==typeof e.keys.auth&&e.keys.auth.length>0}function Jt(t){console.error(`connectif.${t}() should not be used`)}function Qt(t,e){return(0,r.listByClass)(t,e).map((function(t){return Xt(t)})).filter((function(t){return t.name&&t.productDetailUrl&&t.productId&&void 0!==t.unitPrice&&t.unitPrice>=0}))}function Yt(t,e){return(0,r.listByClass)(t,e).map((function(t){return function(t){return Et(Et({},Xt(t)),{},{quantity:ee((0,r.listByClass)(t,"quantity")[0]),price:te((0,r.listByClass)(t,"price")[0])})}(t)})).filter((function(t){return t.name&&t.productDetailUrl&&t.productId&&void 0!==t.unitPrice&&t.unitPrice>=0}))}function Xt(t){return{name:Zt((0,r.listByClass)(t,"name")[0]),productDetailUrl:Zt((0,r.listByClass)(t,"url")[0]),productId:Zt((0,r.listByClass)(t,"product_id")[0]),unitPrice:te((0,r.listByClass)(t,"unit_price")[0]),availability:Zt((0,r.listByClass)(t,"availability")[0]),imageUrl:Zt((0,r.listByClass)(t,"image_url")[0]),description:Zt((0,r.listByClass)(t,"description")[0]),thumbnailUrl:Zt((0,r.listByClass)(t,"thumbnail_url")[0]),priority:ee((0,r.listByClass)(t,"priority")[0]),rating:te((0,r.listByClass)(t,"rating_value")[0]),reviewCount:ee((0,r.listByClass)(t,"review_count")[0]),categories:(0,r.listByClass)(t,"category").map(Zt).filter(re).slice(0,200),tags:(0,r.listByClass)(t,"tag").map(Zt).filter(re).slice(0,200),relatedExternalProductIds:(0,r.listByClass)(t,"related_external_product_id").map(Zt).filter(re).slice(0,200),unitPriceOriginal:te((0,r.listByClass)(t,"unit_price_original")[0]),unitPriceWithoutVAT:te((0,r.listByClass)(t,"unit_price_without_vat")[0]),discountedAmount:te((0,r.listByClass)(t,"discounted_amount")[0]),discountedPercentage:te((0,r.listByClass)(t,"discounted_percentage")[0]),ratingCount:ee((0,r.listByClass)(t,"rating_count")[0]),brand:Zt((0,r.listByClass)(t,"brand")[0]),publishedAt:Gt(Zt((0,r.listByClass)(t,"published_at")[0])),customField1:Zt((0,r.listByClass)(t,"custom_field_1")[0]),customField2:Zt((0,r.listByClass)(t,"custom_field_2")[0]),customField3:Zt((0,r.listByClass)(t,"custom_field_3")[0])}}function Zt(t){if(t)return ne(t).trim()}function Gt(t){if(t)return isNaN(t)?t:new Date(Number(t)).toISOString()}function te(t){if(!t)return;const e=ne(t).trim(),n=parseFloat(e);return!isNaN(n)&&isFinite(n)?n:void 0}function ee(t){if(!t)return;const e=ne(t).trim(),n=parseInt(e,10);return!isNaN(n)&&isFinite(n)?n:void 0}function ne(t){return t.innerText||t.textContent}function re(t){return!function(t){return null==t||""===t}(t)}function ie(t){var e,n;const r=(t+(e="=",n=(4-t.length%4)%4,new Array(n+1).join(e))).replace(/-/g,"+").replace(/_/g,"/"),i=wt()(r);if(!i)return[];const o=new Uint8Array(i.length);for(let t=0;t({type:"product-searched",product:t})))},getProductsNotFoundEvents:function(){return(0,r.listByClass)(Bt,"cn_product_not_found").map((t=>Xt(t))).filter((t=>!!t.productId)).map((t=>({type:"product-not-found",productId:t.productId})))},getLoginEvent:function(){return(0,r.listByClass)(Bt,"cn_login")[0]?{type:"login"}:void 0},getRegisterEvent:function(){return(0,r.listByClass)(Bt,"cn_register")[0]?{type:"register"}:void 0},getSearchEvent:function(){const t=(0,r.listByClass)(Bt,"cn_search")[0],e=Zt((0,r.listByClass)(t,"search_text")[0]);return e?{type:"search",searchText:e}:void 0},getNewsletterSubscribeEvent:function(){const t=(0,r.listByClass)(Bt,"cn_newsletter_subscribe")[0],e=Zt((0,r.listByClass)(t,"email")[0]);return t?{type:"newsletter-subscribe",email:e}:void 0},getPurchaseEvents:function(){return(0,r.listByClass)(Bt,"cn_purchase").map((function(t){return function(t){return{cartId:Zt((0,r.listByClass)(t,"cart_id")[0]),totalQuantity:ee((0,r.listByClass)(t,"total_quantity")[0]),totalPrice:te((0,r.listByClass)(t,"total_price")[0]),products:Yt(t,"product_basket_item"),purchaseId:Zt((0,r.listByClass)(t,"purchase_id")[0]),paymentMethod:Zt((0,r.listByClass)(t,"payment_method")[0]),purchaseDate:Zt((0,r.listByClass)(t,"purchase_date")[0])}}(t)})).filter((function(t){return t.purchaseId&&void 0!==t.totalQuantity&&t.totalQuantity>=0&&void 0!==t.totalPrice&&t.totalPrice>=0})).map((function(t){return{type:"purchase",purchase:t}}))},getCartModel:function(){const t=(e=(0,r.listByClass)(Bt,"cn_cart")[0],{cartId:Zt((0,r.listByClass)(e,"cart_id")[0]),totalQuantity:ee((0,r.listByClass)(e,"total_quantity")[0]),totalPrice:te((0,r.listByClass)(e,"total_price")[0]),cartRecoveryUrl:Zt((0,r.listByClass)(e,"cart_recovery_url")[0]),products:Yt(e,"product_basket_item")});var e;return t.cartId&&void 0!==t.totalQuantity&&t.totalQuantity>=0&&void 0!==t.totalPrice&&t.totalPrice>=0?t:void 0},getEmbeddedBlockPlaceholderIds:()=>(Jt("getEmbeddedBlockPlaceholderIds"),[]),getPushSubscription:function(){if(!Pt)throw Error("Connectif: cannot getSubscription before initialize");return Ot?Ot.pushManager.getSubscription().then((t=>Kt(t)?t:void 0)):Promise.resolve()},getPageInfo:function(){return{categories:(0,r.listByClass)(Bt,"cn_page_category").map(Zt).filter(re).slice(0,10).map((t=>t.trim().substring(0,256))),title:document.title.substring(0,50),keywords:Vt(),tags:(0,r.listByClass)(Bt,"cn_page_tag").map(Zt).filter(re).slice(0,10).map((t=>t.trim().substring(0,25)))}},sendData:function(t,e){if(!Pt)throw Error("Connectif: cannot sendData before initialize");if("object"!=typeof t||null===t)throw Error("Connectif: invalid data to send: "+t);t.browserInfo=t.browserInfo||{windowWidth:window.outerWidth,windowHeight:window.outerHeight,screenHeight:window.screen.height,screenWidth:window.screen.width,colorDepth:screen.colorDepth,cookieEnabled:navigator.cookieEnabled,language:navigator.language,platform:navigator.platform,url:encodeURIComponent(window.location.href),referer:document.referrer,device:"function"==typeof window.matchMedia&&window.matchMedia("only screen and (max-width: 760px)").matches?"mobile":"desktop"},function(t,e,n){if(!(t in Nt)||0===Nt[t].length)return void n(e);const r=Nt[t].slice();function i(t,e){if(r.length===e)return void n(t);(0,r[e])(t,(function(t,n){t&&console.error(t),i(n,e+=1)}))}i(e,0)}("before-send-data",t,(function(t){const n=new XMLHttpRequest;n.open("POST",$t+"integration-type/system/scrippet-notification/"+Pt,!0),n.setRequestHeader("Content-type","text/plain"),n.onreadystatechange=function(){n.readyState>3&&200===n.status&&e&&e(JSON.parse(n.responseText),n)},n.send(JSON.stringify(t))}))},isSomeModalOpened:()=>(Jt("isSomeModalOpened"),!1),hideModal:()=>Jt("hideModal"),showModal:()=>Jt("showModal"),showBanner:()=>Jt("showBanner"),showWebContent:(t,e)=>at(Bt,t,e),isSomeWebContentOpened:function(t,e=["popup","full-screen","slide-in","floating-bar","inline"]){return!!t.querySelector(e.map((t=>`.cn_content_type_${t}`)).join(", "))},subscribeToPushNotifications:function(t){"function"!=typeof t&&(t=function(){});if(!Ot)return void t(null,null);return Ot.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:ie(xt)}).then((function(e){Kt(e)?t(null,e.toJSON()):t(Error("Connectif: The subscription is not valid"))}),t)},unsubscribeFromPushNotification:function(t){return t.unsubscribe()},doesPushSubscriptionPublicKeyMatch:function(t){const e=t.options.applicationServerKey;return kt()(new Uint8Array(e))===kt()(ie(xt))},onEmbeddedFormSubmit:null,onAskForPushNotifications:null,initializeCarousels:()=>Jt("initializeCarousels"),addHookHandler:function(t,e){if("function"!=typeof e)throw new Error("handler must be a function");if("string"!=typeof t)throw new Error("hook must be a string");t in Nt||(Nt[t]=[]);Nt[t].push(e)},removeHookHandler:function(t,e){if("function"!=typeof e)throw new Error("handler must be a function");if("string"!=typeof t)throw new Error("hook must be a string");if(Array.isArray(Nt[t])){const n=Nt[t].indexOf(e);n>=0&&Nt[t].splice(n,1)}},getTrackerId:function(){return zt("cn_tracker").then((t=>t?JSON.parse(t).id:void 0))},setTrackerId:function(t){return Ht("cn_tracker",JSON.stringify({id:t}))}},setTimeout((()=>{qt("connectif.loaded")}),1)),window.initializeConnectif=function(t){Array.isArray(t.forms)||(t.forms=[]),Array.isArray(t.webEventPayloadDefinitions)||(t.webEventPayloadDefinitions=[]);let e=!1;const n=window.connectif,r={sendEvents:k,getAllEvents:function(){return B({lastSubmittedFormEvent:W([n.get("cn_last_submitted_form_id"),n.get("cn_last_submitted_form_data"),n.get("cn_last_submitted_form_primary_key_field")]),lastCustomEvents:H([n.get("cn_last_custom_event_id"),n.get("cn_last_custom_event_payloads")]),webClickEvent:n.getWebLinkClickedEvent()})},getAllEventsAsync:L,deepEquals:E,isExcludedPage:Q,getSamplingValue:function(){return l},isAllowedDomain:J,setLastSubmittedFormPk:Y,getAllConnectifEventsAsync:function(){return j().then((t=>[].concat(t.lastSubmittedFormEvent?[t.lastSubmittedFormEvent]:[]).concat(t.lastCustomEvents).concat(t.webClickEvent?[t.webClickEvent]:[])))},onNewWebContainer:function(t){const e=s;s=[];for(let n=0;nfunction(t,e){const n={};return e.forEach((function(e){const r=z(e.metadata),i=function(t,e){for(let n=0;n{m=K(document,d),y()}))}else y();t.autoSendEventsOnInit&&L().then(k),function(t){t||(t=document);const e=Array.prototype.slice.call(t.querySelectorAll("[data-cn-embedded-form]:not(.cn__initialized)")),r=n.getClientInfo();$({trackerId:r.trackerId,primaryKey:r.primaryKey}).then((t=>{e.forEach((function(e){Object.keys(r).forEach((function(t){"trackerId"!==t&&"primaryKey"!==t&&v(e,t,r[t])})),v(e,"eventType","form-submitted"),v(e,"formId",e.getAttribute("data-form-id")),v(e,"contentId",e.getAttribute("data-cn-content-id")),v(e,"workflowDefinitionId",e.getAttribute("data-cn-workflow-definition-id")),v(e,"sendUuid",e.getAttribute("data-cn-send-uuid")),v(e,"redirectUrl",e.getAttribute("data-cn-redirect-url")),v(e,"primaryKeyFieldName",e.getAttribute("data-cn-primary-key-field-name")),v(e,"primaryKey",t.primaryKey),v(e,"trackerId",t.trackerId),e.classList.add("cn__initialized")}))}))}()}))}function y(){e=!0,n.triggerEvent("connectif.managed.initialized")}function h(e){return $({trackerId:e}).then((({trackerId:e})=>{e&&(d={sendEvents:k,apiBaseUrl:t.baseUrl,token:t.token,tracker:e,subscribeToPushNotifications:()=>{n.subscribeToPushNotifications((function(t){t||k([])}))},setLastSubmittedFormPk:Y})}))}function v(t,e,n){const r=document.createElement("input");n&&(r.setAttribute("type","hidden"),r.setAttribute("name","cn__"+e),r.setAttribute("value",n),t.appendChild(r))}function w(t){return t.some((t=>"page-visit"===t.type))}function _(t){return w(t)?j().then((function(e){return e.lastCustomEvents.concat(e.lastSubmittedFormEvent?[e.lastSubmittedFormEvent]:[]).concat(t).concat(e.webClickEvent?[e.webClickEvent]:[])})):Promise.resolve(t)}function k(e,r){return"object"==typeof r&&null!==r||(r={}),!r||r.entityInfo&&"object"==typeof r.entityInfo&&!Array.isArray(r.entityInfo)||(r.entityInfo=void 0),e=Array.isArray(e)?e:[],J()&&!Q()&&t.webTrackingEnabled?(w(e)&&(o=[],a=[],s=[],c={}),Promise.all([_(e),n.getPushSubscription()]).then((function(t){const e=t[0];let i=t[1];if("Notification"in window&&"granted"===Notification.permission){if(i&&!n.doesPushSubscriptionPublicKeyMatch(i))return n.unsubscribeFromPushNotification(i).then((()=>s())).catch((()=>s()));if(!i)return s()}return p();function s(){return new Promise((t=>{n.subscribeToPushNotifications((function(e,n){return i=n,p().then(t)}))}))}function l(){if(!r.pageInfo)return;f=r.pageInfo.id;const{tags:t,categories:e,keywords:n,title:i}=r.pageInfo;return ae(ae(ae(ae({},u(t)?{tags:t.filter((t=>t)).slice(0,10).map((t=>t.trim().substring(0,25)))}:{}),u(e)?{categories:e.filter((t=>t)).slice(0,10).map((t=>t.trim().substring(0,256)))}:{}),u(n)?{keywords:n.filter((t=>t)).slice(0,10).map((t=>t.trim().substring(0,25)))}:{}),"string"==typeof i?{title:i.substring(0,50)}:{})}function u(t){return Array.isArray(t)&&t.every((t=>"string"==typeof t))}function p(){const t={entityPrivateInfo:r.privateInfo||n.getClientPrivateInfo(),entityInfo:r.entityInfo||n.getClientInfo(),cart:r.cart||n.getCartModel(),pushSubscription:i,events:e,pageInfo:ae(ae({},n.getPageInfo()),l())};return $(t.entityInfo).then((e=>{return t.entityInfo.trackerId=e.trackerId,t.entityInfo.primaryKey=e.primaryKey,Promise.all([(i=t.entityInfo,n.getAsync("cn_previous_entity_info").then((t=>{if(t){const e=JSON.parse(t);return!E(i,e)}return!0})).catch((()=>(n.unset("cn_previous_entity_info"),!0)))),C(t.pushSubscription),S(t)]).then((([e,i])=>{e||t.cart||t.events.length>0||i?(n.set("cn_previous_entity_info",JSON.stringify(t.entityInfo)),t.pushSubscription?n.set("cn_previous_push_subscription",t.pushSubscription.endpoint):n.unset("cn_previous_push_subscription"),n.sendData(t,(function(t,e){!function(t,e){new Promise((function(e,n){t?.trackerId?P(t.trackerId).then(e,n):e()})).then((()=>{h().then((()=>{m||(m=K(document,d));const e=t.sharedData;e&&Object.keys(e).length>0&&(c=ae(ae({},c),e),Object.entries(e).forEach((([t,e])=>{n.triggerEvent("connectif.managed.shared_data_received",ae({id:t},e))}))),n.getPushSubscription().then((function(e){let r=!0;"Notification"in window&&"denied"!==Notification.permission?"default"===Notification.permission||"granted"===Notification.permission&&(r=!1,e||n.subscribeToPushNotifications()):r=!1,Array.isArray(t.webContents)&&t.webContents.filter((t=>r||!t.onlyShowIfPushUnsubscribed)).forEach((t=>{switch(t.showOn){case"immediate":o.push(t);break;case"on-leave-page":case"on-scroll":case"on-activity-timeout":a.push(t);break;case"on-timeout":a.push(t),function(t){setTimeout((function(){I(t),A()}),t.milliseconds)}(t)}})),A()}))}))}))}(t),"function"==typeof r.onResponded&&r.onResponded()}))):"function"==typeof r.onResponded&&r.onResponded()}));var i}))}}))):("function"==typeof r.onResponded&&setTimeout(r.onResponded,0),Promise.resolve())}function C(t){return n.getAsync("cn_previous_push_subscription").then((e=>!(t||!e)||(!(!t||e)||!(!t&&!e)&&(t&&e?t.endpoint!==e:void 0))))}function E(t,e){return typeof t==typeof e&&(Array.isArray(t)?!!Array.isArray(e)&&(t.length===e.length&&t.every((function(t,n){return E(t,e[n])}))):!Array.isArray(e)&&("object"==typeof t?null===t?null===e:Object.keys(t).every((function(n){return E(t[n],e[n])}))&&Object.keys(e).every((function(n){return E(t[n],e[n])})):t===e))}function S(t){const e=t.cart;if("object"==typeof e)return n.getAsync("cn_previous_cart").then((r=>{if(r){const n=JSON.parse(r);o=n,(i=e).cartId===o.cartId&&i.totalPrice===o.totalPrice&&i.totalQuantity===o.totalQuantity&&i.cartRecoveryUrl===o.cartRecoveryUrl&&Array.isArray(i.products)&&Array.isArray(o.products)&&i.products.length===o.products.length&&i.products.every((function(t){return o.products.some((function(e){return t.quantity===e.quantity&&t.price===e.price&&t.productId===e.productId}))}))&&delete t.cart}var i,o;n.set("cn_previous_cart",JSON.stringify(e))})).catch((()=>{n.unset("cn_previous_cart")}))}function $(t){return n.getTrackerId().then((e=>{const n=t.trackerId||e||function(t){const e=window.location.href;t=t.replace(/[[\]]/g,"\\$&");const n=new RegExp("[?&]"+t+"(=([^&#]*)|&|#|$)").exec(e);if(!n)return null;if(!n[2])return"";return decodeURIComponent(n[2].replace(/\+/g," "))}("__cn_tracker");return{trackerId:n?n.substring(0,24):void 0,primaryKey:u||t.primaryKey}}))}function P(t){return new Promise((function(e,r){try{n.getTrackerId().then((i=>{n.setTrackerId(t).then((()=>{t!==i&&n.triggerEvent("connectif.managed.tracker_changed",{oldTrackerId:i,newTrackerId:t}),e()})).catch(r)})).catch(r)}catch(t){r(t)}}))}function A(){const t=[];n.isSomeWebContentOpened(i,["popup","full-screen"])||t.push(...O(["popup","full-screen"])),n.isSomeWebContentOpened(i,["slide-in"])||t.push(...O(["slide-in"])),n.isSomeWebContentOpened(i,["floating-bar"])||t.push(...O(["floating-bar"])),x(["inline"]).forEach(T),t.length>0&&k(t,{entityInfo:{}})}function x(t){const e="default"===window.Notification?.permission;return o.filter((e=>t.includes(e.webContent.webContentTypeId))).filter((t=>e||!t.onlyShowIfPushUnsubscribed))}function O(t){const e=x(t);return e.length>0?T(e[0]):[]}function T(t){o=o.filter((e=>e!==t));var e;n.showWebContent(t,d)||"inline"!==t.webContent.webContentTypeId||(e=t,s.push(e));const{workflowDefinitionId:r,webContent:{id:i,webContentTypeId:a},sendUuid:c}=t;return"inline"!==t.webContent.webContentTypeId?[{type:"web-content-opened",contentId:i,webContentTypeId:a,workflowDefinitionId:r,sendUuid:c}]:[]}function I(t){a=a.filter((e=>e!==t)),o.push(t)}function j(){return Promise.all([Promise.all([n.getAsync("cn_last_submitted_form_id"),n.getAsync("cn_last_submitted_form_data"),n.getAsync("cn_last_submitted_form_primary_key_field")]).then(W),Promise.all([n.getAsync("cn_last_custom_event_id"),n.getAsync("cn_last_custom_event_payloads")]).then(H)]).then((([t,e])=>({lastSubmittedFormEvent:t,lastCustomEvents:e,webClickEvent:n.getWebLinkClickedEvent()})))}function L(){return j().then(B)}function B(t){return t.lastCustomEvents.concat([t.lastSubmittedFormEvent]).concat(n.getVisitedProductEvents()).concat(n.getSearchedProductEvents()).concat(n.getProductsNotFoundEvents()).concat([n.getLoginEvent()]).concat([n.getRegisterEvent()]).concat([n.getSearchEvent()]).concat([n.getNewsletterSubscribeEvent()]).concat(n.getPurchaseEvents()).concat([n.getPageVisitEvent()]).concat([t.webClickEvent]).filter((t=>!!t))}function N(){p=new Date}function R(){A()}function D(){n.subscribeToPushNotifications((function(t){t||k([])}))}function M(t){if(t.preventDefault(),!function(t){const e="cn__validateForm",n=window.document.querySelector("iframe.cn_modal_iframe");if(n&&n.contentWindow){const r=n.contentWindow[e];if("function"==typeof r)return r(t)}const r=window[e];if("function"==typeof r)return r(t);return!0}(t.target))return;const e=q(t.target,!1),n=t.target.getAttribute("data-cn-primary-key-field-name");n&&(u=e[n]),k([{type:"form-submitted",formId:t.target.getAttribute("data-form-id"),contentId:t.target.getAttribute("data-cn-content-id"),workflowDefinitionId:t.target.getAttribute("data-cn-workflow-definition-id"),sendUuid:t.target.getAttribute("data-cn-send-uuid"),payload:e}],{onResponded:function(){let e=t.target.getAttribute("data-cn-redirect-url");if(e){/^https?:\/\//i.test(e)||(e="//"+e),window.location.href=e}}})}function q(e,r){const i={},o=n.get("cn_last_submitted_form_id"),a=t.forms.find((t=>t.id===o)).fields;for(let t=0;tt===n))||("checkbox"===e.elements[t].getAttribute("type")?e.elements[t].checked?("string"==typeof i[n]&&(i[n]=[i[n]]),"object"==typeof i[n]&&i[n].length>=0?i[n].push(o):i[n]=o):i[n]=i[n]||[]:"radio"===e.elements[t].getAttribute("type")?e.elements[t].checked&&(i[n]=o):i[n]="text"!==s?o:o.trim())}return i}function W([t,e,r]){if(!t)return null;n.unset("cn_last_submitted_form_id"),n.unset("cn_last_submitted_form_data"),n.unset("cn_last_submitted_form_primary_key_field");const i={type:"form-submitted",formId:t,payload:JSON.parse(e)};return r&&(i.primaryKeyField=r),i}function H([t,e]){if(!t)return[];n.unset("cn_last_custom_event_id"),n.unset("cn_last_custom_event_payloads");return JSON.parse(e).map((function(e){return{type:"custom",eventId:t,payload:e}}))}function z(t){return Array.prototype.slice.call(i.getElementsByTagName(t.nodeName)).filter((function(e){return function(t,e){const n=function(t){return{nodeName:t.nodeName,treeDepth:U(i,t),childNodes:t.childNodes.length,children:t.children.length,parent:t.parentElement.nodeName,className:t.className,nodeAttributes:Array.prototype.slice.call(t.attributes).filter((t=>"class"!==t.name)).map((t=>({name:t.name,value:t.value})))}}(t),r=e.className.split(" "),o=n.className.split(" ");return n.nodeName===e.nodeName&&n.treeDepth===e.treeDepth&&n.childNodes===e.childNodes&&n.children===e.children&&0===n.parent.localeCompare(e.parent)&&(a=r,s=o,a.every((t=>s.includes(t))))&&function(t,e){if(!Array.isArray(t.nodeAttributes)||0===t.nodeAttributes.length)return!0;if(!Array.isArray(e.nodeAttributes)||0===e.nodeAttributes.length)return!1;const n=Array.isArray(t.ignoreNodeAttributes)?t.ignoreNodeAttributes:[];return t.nodeAttributes.filter((t=>!n.some((e=>e===t.name)))).every((t=>e.nodeAttributes.some((e=>t.name===e.name&&t.value===e.value))))}(e,n);var a,s}(e,t)}))}function U(t,e){let n=0;for(;e!==t;)n+=1,e=e.parentNode;return n}function F(t,e){for(e=e.parentNode;e.parentNode;){if(e===t)return!0;e=e.parentNode}return!1}function V(t,e){for(let n=0;nfunction(t){const e=window.location.href,n=window.location.hostname,r=0===t.indexOf("*");if(0===t.indexOf("http://")||0===t.indexOf("https://"))return 0===e.indexOf(t);if(!r)return t===n;return n.endsWith(t.replace("*",""))}(t)))}function Q(){return t.trackAllByDefault?!(!Array.isArray(t.excludeTracking)||!t.excludeTracking.some(e))||!!t.samplingTrackingPercent&&l>t.samplingTrackingPercent:(!Array.isArray(t.includeTracking)||!t.includeTracking.some(e))&&(!t.samplingTrackingPercent||l>t.samplingTrackingPercent);function e(t){return"string"==typeof t&&new RegExp(t).test(window.location.href)}}function Y(t){u=t}window.addEventListener("scroll",(function(){const t=window.pageYOffset||document.documentElement.scrollTop,e=window.innerHeight,n=document.documentElement.scrollHeight,r=100*t/(n-e);a.filter((t=>"on-scroll"===t.showOn&&t.scrollPercentage<=r)).forEach(I),A()})),i.addEventListener("mouseout",(function(t){if(null!==t.relatedTarget)return;a.filter((t=>"on-leave-page"===t.showOn)).forEach(I),A()})),["mousemove","click","keydown","change","wheel","scroll"].forEach((function(t){window.addEventListener(t,N)})),setInterval((function(){const t=(new Date).getTime()-p.getTime();a.filter((e=>"on-activity-timeout"===e.showOn&&e.milliseconds