whatmore-react-assets 1.0.1827 → 1.0.1828

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/whatmore.js CHANGED
@@ -1 +1 @@
1
- !function(){"use strict";var e,t={964:function(e,t,i){i.d(t,{$$:function(){return o},DK:function(){return u},Dk:function(){return s},K1:function(){return c},MT:function(){return r},OL:function(){return h},Sx:function(){return g},TB:function(){return m},YZ:function(){return n},aD:function(){return a},mM:function(){return l},qW:function(){return d},rz:function(){return p}});const n="58669793418",o="https://consumer.whatmore.live",a="https://whatmore-api-cdn-cache.azureedge.net",r="https://cdn-consumer.whatmore.live",d="https://analytics.whatmore.live",l=!1,s="carousel",c="video_popup",h="stories",p="collections",m="homepage",u="product_page",g="collection_page"},3782:function(e,t,i){i.d(t,{A:function(){return n},H:function(){return o}});const n=i(964).mM?4:null;function o(e){if(!e||0===e.length)return e;if(null!==n){return e.slice(0,n)}return e}}},i={};function n(e){var o=i[e];if(void 0!==o)return o.exports;var a=i[e]={id:e,loaded:!1,exports:{}};return t[e](a,a.exports,n),a.loaded=!0,a.exports}n.m=t,n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};n.t=function(i,o){if(1&o&&(i=this(i)),8&o)return i;if("object"===typeof i&&i){if(4&o&&i.__esModule)return i;if(16&o&&"function"===typeof i.then)return i}var a=Object.create(null);n.r(a);var r={};e=e||[null,t({}),t([]),t(t)];for(var d=2&o&&i;("object"==typeof d||"function"==typeof d)&&!~e.indexOf(d);d=t(d))Object.getOwnPropertyNames(d).forEach(function(e){r[e]=function(){return i[e]}});return r.default=function(){return i},n.d(a,r),a}}(),n.d=function(e,t){for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.f={},n.e=function(e){return Promise.all(Object.keys(n.f).reduce(function(t,i){return n.f[i](e,t),t},[]))},n.u=function(e){return"static/js/"+({259:"location-details",260:"event-click-component",268:"react-main-app",760:"homepage-carousel-view",939:"atc-with-form"}[e]||e)+"."+{259:"74afe936",260:"d9e3c981",264:"305fc5ba",268:"10a10ba6",305:"56d2f88f",323:"88610351",760:"d8416d4f",844:"d124e3d5",939:"63aa381a"}[e]+".chunk.js"},n.miniCssF=function(e){return"static/css/"+{260:"event-click-component",268:"react-main-app",760:"homepage-carousel-view"}[e]+"."+{260:"f4759a24",268:"f2c2ed61",760:"522128da"}[e]+".chunk.css"},n.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={},t="whatmorelive-react:";n.l=function(i,o,a,r){if(e[i])e[i].push(o);else{var d,l;if(void 0!==a)for(var s=document.getElementsByTagName("script"),c=0;c<s.length;c++){var h=s[c];if(h.getAttribute("src")==i||h.getAttribute("data-webpack")==t+a){d=h;break}}d||(l=!0,(d=document.createElement("script")).charset="utf-8",d.timeout=120,n.nc&&d.setAttribute("nonce",n.nc),d.setAttribute("data-webpack",t+a),d.src=i),e[i]=[o];var p=function(t,n){d.onerror=d.onload=null,clearTimeout(m);var o=e[i];if(delete e[i],d.parentNode&&d.parentNode.removeChild(d),o&&o.forEach(function(e){return e(n)}),t)return t(n)},m=setTimeout(p.bind(null,void 0,{type:"timeout",target:d}),12e4);d.onerror=p.bind(null,d.onerror),d.onload=p.bind(null,d.onload),l&&document.head.appendChild(d)}}}(),n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},n.p="https://cdn.jsdelivr.net/npm/whatmore-react-assets@latest/",function(){if("undefined"!==typeof document){var e=function(e){return new Promise(function(t,i){var o=n.miniCssF(e),a=n.p+o;if(function(e,t){for(var i=document.getElementsByTagName("link"),n=0;n<i.length;n++){var o=(r=i[n]).getAttribute("data-href")||r.getAttribute("href");if("stylesheet"===r.rel&&(o===e||o===t))return r}var a=document.getElementsByTagName("style");for(n=0;n<a.length;n++){var r;if((o=(r=a[n]).getAttribute("data-href"))===e||o===t)return r}}(o,a))return t();!function(e,t,i,o,a){var r=document.createElement("link");r.rel="stylesheet",r.type="text/css",n.nc&&(r.nonce=n.nc),r.onerror=r.onload=function(i){if(r.onerror=r.onload=null,"load"===i.type)o();else{var n=i&&i.type,d=i&&i.target&&i.target.href||t,l=new Error("Loading CSS chunk "+e+" failed.\n("+n+": "+d+")");l.name="ChunkLoadError",l.code="CSS_CHUNK_LOAD_FAILED",l.type=n,l.request=d,r.parentNode&&r.parentNode.removeChild(r),a(l)}},r.href=t,i?i.parentNode.insertBefore(r,i.nextSibling):document.head.appendChild(r)}(e,a,null,t,i)})},t={792:0};n.f.miniCss=function(i,n){t[i]?n.push(t[i]):0!==t[i]&&{260:1,268:1,760:1}[i]&&n.push(t[i]=e(i).then(function(){t[i]=0},function(e){throw delete t[i],e}))}}}(),function(){var e={792:0};n.f.j=function(t,i){var o=n.o(e,t)?e[t]:void 0;if(0!==o)if(o)i.push(o[2]);else{var a=new Promise(function(i,n){o=e[t]=[i,n]});i.push(o[2]=a);var r=n.p+n.u(t),d=new Error;n.l(r,function(i){if(n.o(e,t)&&(0!==(o=e[t])&&(e[t]=void 0),o)){var a=i&&("load"===i.type?"missing":i.type),r=i&&i.target&&i.target.src;d.message="Loading chunk "+t+" failed.\n("+a+": "+r+")",d.name="ChunkLoadError",d.type=a,d.request=r,o[1](d)}},"chunk-"+t,t)}};var t=function(t,i){var o,a,r=i[0],d=i[1],l=i[2],s=0;if(r.some(function(t){return 0!==e[t]})){for(o in d)n.o(d,o)&&(n.m[o]=d[o]);if(l)l(n)}for(t&&t(i);s<r.length;s++)a=r[s],n.o(e,a)&&e[a]&&e[a][0](),e[a]=0},i=self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))}(),n.nc=void 0;const o="whatmore_brand_customizations",a=null!==(e="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==e&&e;function r(e){return new URLSearchParams(window.location.search).get(e)}function d(e){try{const t={customizations:e,timestamp:(new Date).getTime()};localStorage.setItem(o,JSON.stringify(t)),a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations saved to cache`)}catch(t){console.error("Whatmore: Error saving customizations to cache:",t)}}function l(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}async function s(e){var t,i;if(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd0d Getting customizations...`),null!==(t=window)&&void 0!==t&&null!==(i=t.whatmore)&&void 0!==i&&i.frontendCustomizations&&"object"===typeof window.whatmore.frontendCustomizations){a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from window.whatmore.frontendCustomizations`);const e=window.whatmore.frontendCustomizations;return d(e),e}const n=function(){try{const e=localStorage.getItem(o);if(!e)return null;const t=JSON.parse(e);return t.timestamp+3e5>=(new Date).getTime()?t.customizations:null}catch(e){return console.error("Whatmore: Error reading customizations cache:",e),null}}();if(n)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from cache`),n;a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No cached customizations, fetching from backend...`);const r=await async function(e){try{a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83c\udf10 Fetching customizations from backend for shopId: ${e}`);const t=await fetch(`https://api.whatmore.live/customization/frontend/${e}`);if(!t.ok)throw new Error(`HTTP error! status: ${t.status}`);const i=await t.json();return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations fetched from backend`),d(i),i}catch(t){return console.error("Whatmore: Error fetching customizations from backend:",t),null}}(e);return r}function c(e,t,i,n,o){if(i)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udccc Shared link detected - immediate load`),!1;if("template-embed"===n&&null!==o&&void 0!==o&&o.startsWith("product"))return a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udecd\ufe0f Product page popup detected - immediate load`),!1;if(!e)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No customizations - defaulting to immediate load`),!1;const r=l(e,"lazy_load_config->block_widgets"),d=l(e,"collections_config->show_popup_out_of_view");return t&&d?(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udce6 Collections with showPopupOutOfView=true - immediate load`),!1):r?(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd04 lazyloadConfig_blockWidget=true - lazy load enabled`),!0):(a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a1 lazyloadConfig_blockWidget=false - immediate load`),!1)}const h=.6,p=.7,m=.8,u=16/9;function g(e){return(t,i)=>{const n=e.querySelector(`#${t}`);if(!n)return i;return n.getAttribute("data-wh")||n.getAttribute("data")||i}}function v(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}function w(e,t){const i=e>t,n=e>=481;return i&&n?"desktop":!i&&n?"tablet":i&&!n?"mobileLandscape":"mobilePortrait"}function f(e){return Math.round(10*e)/10}function x(e,t){if(!(e&&""!==e.trim()))return 0;return Math.round(1.5*t+16)}function b(e,t){if(!t.startsWith("product"))return 0;const i=.055*e;return Math.round(12+1.2*i*2)}function y(e){var t,i;const{widgetContainer:n,customizations:o,windowWidth:a,windowHeight:r,eventCount:d}=e,l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(a,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:a,windowHeight:r,liquidVars:l,customizations:o}),b=Math.ceil(c.slidesPerView),y=void 0!==d?d:b,_=null!==(t=v(o,"event_tile_config->show_product_thumbnail"))&&void 0!==t&&t,P=function(e){var t,i,n;const{width:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_config->show_product_thumbnail"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=null!==(i=v(r,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==i?i:1,s=null!==(n=v(r,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==n?n:1,c=d?l:s,h=d?1.076*o*c:o*c,p=1.2*h,m=1.2*h,u=h;return Math.round(24+p+5+m+5+u)}({width:c.width,deviceMode:s,customizations:o}),$=x(l.heading,l.titleFontSize),T=null!==(i=v(o,"carousel_config->width_multiplier"))&&void 0!==i?i:1.1,S=l.topBottomPadding+$+25+c.height+P+25+l.topBottomPadding,z=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,showProductInfo:o,productInfoHeight:a,headingHeight:r,topBottomPadding:d,landscapePadding:l,deviceMode:s,windowWidth:c,windowHeight:h,slidesPerView:p,widthMultiplier:m}=e,u="desktop"===s||"mobileLandscape"===s,g=u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let v=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${d}px; margin-bottom: ${d}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;r>0&&(v+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <p style="\n height: ${r}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin: 0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </p>\n </div>\n `),u?(v+=`\n <div class="${g}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n height: 100%;\n padding-left: ${l}px;\n padding-right: ${l}px;\n ">`,v+=`\n <div style="\n width: ${Math.floor(t*p*m)}px;\n height: 100%;\n overflow: hidden;\n ">`):(v+=`\n <div class="${g}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n overflow: hidden;\n ">`,v+=`\n <div style="\n width: ${c}px;\n height: fit-content;\n ">`);const w=u?n:3;let f="";u||(f=`transform: translate3d(${c/2-1.5*(t+10+10)}px, 0px, 0px);`);v+=`\n <div style="display: flex; ${u?"margin: 0 auto; width: max-content;":f}">`;for(let x=0;x<w;x++){const e=!u&&1===x;u&&(v+=`\n <div style="\n flex-shrink: 0;\n width: ${Math.floor(t*m)}px;\n display: flex;\n justify-content: center;\n align-items: center;\n ">`),v+=`\n <div style="\n ${u?"":"flex-shrink: 0;"}\n margin: 25px 10px 25px 10px;\n width: ${t}px;\n height: ${i}px;\n border-radius: 5px;\n overflow: hidden;\n position: relative;\n transform: ${e?"scale(1.05)":"scale(1)"};\n transition: transform 0.3s ease-out;\n ">\n \x3c!-- Video tile shimmer --\x3e\n <div style="\n width: 100%;\n height: 100%;\n background: #e0e0e0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `,o&&(v+='\n <div style="padding: 12px 4px; display: flex; gap: 6px;">\n <div style="flex: 1; display: flex; flex-direction: column; gap: 5px;">\n <div style="\n height: 14px;\n width: 90%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n height: 12px;\n width: 60%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n height: 10px;\n width: 40%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n '),v+=" </div>",u&&(v+=" </div>")}return v+="\n </div>",v+="\n </div>",v+="\n</div>",v+="\n</div>",v+="\n</div>",v}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:y,showProductInfo:_,productInfoHeight:P,headingHeight:$,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:a,windowHeight:r,slidesPerView:c.slidesPerView,widthMultiplier:T});return{totalHeight:Math.round(S),shimmerHTML:z,topBottomPadding:l.topBottomPadding}}function _(e,t){var i,n,o;const a=(null===(i=e.querySelector("#whatmoreShopId"))||void 0===i?void 0:i.getAttribute("data-wh"))||(null===(n=e.querySelector("#whatmoreShopId"))||void 0===n?void 0:n.getAttribute("data"));if("51273072796"==a||"64967540952"==a)return[document.documentElement.clientHeight,document.documentElement.clientWidth];const r=null!==(o="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==o&&o;let d=e;for(;d&&d!==document&&(d=d.parentElement,!d||d.classList.contains("whatmore-base")););let l=window.innerWidth;if(d){const e=d.getBoundingClientRect().width;if(e>0){const t=window.getComputedStyle(d);l=e-(parseFloat(t.paddingLeft)||0)-(parseFloat(t.paddingRight)||0)}d&&0==e&&(d.style.setProperty("width","100%","important"),r&&console.log("Set currElement width to 100% !important"))}return[window.innerHeight,l]}function P(e){var t,i;const{widgetContainer:n,customizations:o,eventCount:a}=e,[r,d]=_(n),l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(d,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){var g;const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;const r=null!==(g=v(a,"event_tile_config->space_between_tiles"))&&void 0!==g?g:1;s=f(i/(1.15*t))*r,c=0,d=n,l=t}else if("tablet"===t){var w;const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;const r=null!==(w=v(a,"event_tile_config->space_between_tiles"))&&void 0!==w?w:1;s=f(i/(1.2*t))*r,c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:1.2*d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:r,liquidVars:l,customizations:o}),b=Math.ceil(c.slidesPerView),y=void 0!==a?a:b,P=x(l.heading,l.titleFontSize),$=null!==(t=v(o,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,T=("desktop"===s||"mobileLandscape"===s)&&null!==(i=v(o,"event_tile_config->gap_between_tiles"))&&void 0!==i?i:0,S=l.topBottomPadding+P+25+c.height+25+l.topBottomPadding,z=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,headingHeight:o,topBottomPadding:a,landscapePadding:r,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c,spaceBetween:h}=e,p="desktop"===d||"mobileLandscape"===d;let m=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${a}px; margin-bottom: ${a}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;if(o>0&&(m+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${o-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),m+=`\n <div class="${p?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n height: 100%;\n ${p?`padding-left: ${r}px; padding-right: ${r}px;`:""}\n ">`,m+=`\n <div style="\n width: ${p?t*s*c+"px":l+"px"};\n height: 100%;\n overflow: hidden;\n ">`,p){m+=`<div style="margin: 0 auto; display: flex; gap: ${h}px; align-items: center; width: max-content;">`;for(let e=0;e<n;e++)m+=`\n <div style="flex-shrink: 0; width: ${t*c}px; display: flex; justify-content: center; align-items: center;">\n \x3c!-- Template-B tile shimmer: single rectangle with HEIGHT * 1.2 --\x3e\n <div style="\n margin: 25px auto;\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}else{const e=l/s;m+=`<div style="display: flex; transform: translate3d(${l/2-1.5*e}px, 0px, 0px);">`;for(let n=0;n<3;n++)m+=`\n <div style="flex-shrink: 0; width: ${e}px; display: flex; justify-content: center; align-items: center;">\n \x3c!-- Template-B tile shimmer: single rectangle with HEIGHT * 1.2 --\x3e\n <div style="\n margin: 25px auto;\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n transform: ${1===n?"scale(1.05)":"scale(1)"};\n transition: transform 0.3s ease-out;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}return m+="\n </div>",m+="\n </div>",m+="\n</div>",m+="\n</div>",m+="\n</div>",m}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:y,headingHeight:P,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:c.slidesPerView,widthMultiplier:$,spaceBetween:T});return{totalHeight:S,shimmerHTML:z}}function $(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:r*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s=r.collectionsTilesSpacing,c=b(l.width,r.extensionType),v="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,f=l.width+10,x=Math.ceil(v/(f+s))+1,y=void 0!==n?n:x,P=r.topBottomPadding+l.height+10+c+r.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;s+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,s+=`\n <div class="whatmore-shimmer-collections-flex-c" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-c::before,\n .whatmore-shimmer-collections-flex-c::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let c=0;c<l;c++)s+=`\n <div style="\n flex-shrink: 0;\n margin: 5px;\n ">\n <div style="\n width: fit-content;\n height: fit-content;\n border-radius: 10%;\n overflow: hidden;\n box-shadow: 0px 1px 1px 0px rgba(0, 0, 0, 0.1),\n 0px -1px 1px 0px rgba(0, 0, 0, 0.1),\n 1px 0px 1px 0px rgba(0, 0, 0, 0.1),\n -1px 0px 1px 0px rgba(0, 0, 0, 0.1),\n 1px -1px 1px 0px rgba(0, 0, 0, 0.1),\n -1px 1px 1px 0px rgba(0, 0, 0, 0.1),\n 1px 1px 1px 0px rgba(0, 0, 0, 0.1),\n -1px -1px 1px 0px rgba(0, 0, 0, 0.1);\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 10%;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `;return s+="\n </div>",s+="\n </div>",s+="\n </div>",s+="\n</div>",s}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,numberOfTiles:y});return{totalHeight:P,shimmerHTML:$}}function T(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:r*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s=r.collectionsTilesSpacing,c=b(l.width,r.extensionType),v="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,f=l.width+4,x=Math.ceil(v/(f+s))+1,y=void 0!==n?n:x,P=r.topBottomPadding+l.height+4+c+r.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;s+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,s+=`\n <div class="whatmore-shimmer-collections-flex-d" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-d::before,\n .whatmore-shimmer-collections-flex-d::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let c=0;c<l;c++)s+=`\n <div style="\n flex-shrink: 0;\n margin: 2px;\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 0%;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `;return s+="\n </div>",s+="\n </div>",s+="\n </div>",s+="\n</div>",s}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,numberOfTiles:y});return{totalHeight:P,shimmerHTML:$}}function S(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreExtensionType","index"),landingLocationType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize,c="mobilePortrait"===t||"tablet"===t;return{height:("22907887"===o.shopId||"79550939348"===o.shopId?c?.9:.83:1)*r*s*.01,width:d*s*.01,landscapePadding:l,unscaledWidth:d}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s="68304765103"===r.shopId?"mobilePortrait"===d||"tablet"===d?6:20:r.collectionsTilesSpacing,c=x(r.heading,r.titleFontSize),f=("mobilePortrait"===d||"tablet"===d?r.videoTileSizePortrait:r.videoTileSize,function(e,t,i,n,o){var a,r,d,l,s;if(n.startsWith("product"))return 0;const c="mobilePortrait"===t||"tablet"===t,h=null!==(a=v(o,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==a?a:.022,p=null!==(r=v(o,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==r?r:.015,m=c?1.076*e*h:e*p,u=.9*m,g=Math.ceil(1.15*u),w=null===(d=v(o,"product_config->show_product_price"))||void 0===d||d,f=null===(l=v(o,"event_tile_with_product_info->show_price_info"))||void 0===l||l,x=.9*m,b=w&&f?Math.ceil(1.2*x):0,y=null!==(s=v(o,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==s&&s,_=c?10:12,P=Math.max(9,.75*m),$=y?_+Math.ceil(P):0;let T=0;return b>0&&T++,$>0&&T++,12+g+b+2+$+4*T}(l.unscaledWidth,d,r.shopId,r.landingLocationType,i)),b="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,y=l.width+4,P=Math.ceil(b/(y+s))+1,$=void 0!==n?n:P,T=r.topBottomPadding+c+l.height+4+f+r.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,headingHeight:l,numberOfTiles:s,shopId:c,landingLocationType:h,unscaledWidth:p,customizations:m}=e,u=("73817522453"===c||"68304765103"===c||"16957273"===c)&&!h.startsWith("product"),g="68304765103"===c?"0px":"5%";let w=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;l>0&&(w+=`\n <div style="display: flex; justify-content: center; align-items: center;">\n <div style="\n height: ${l-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),w+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,w+=`\n <div class="whatmore-shimmer-collections-flex-e" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-e::before,\n .whatmore-shimmer-collections-flex-e::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let P=0;P<s;P++){if(w+=`\n <div style="\n flex-shrink: 0;\n margin: 2px;\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: ${g};\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,u){var f,x,b,y,_;const e="mobilePortrait"===a||"tablet"===a,t=null!==(f=v(m,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==f?f:.022,i=null!==(x=v(m,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==x?x:.015,n=e?1.076*p*t:p*i,o=e?4:8,r=6,d=4,l=.9*n,s=Math.ceil(1.15*l),c=null===(b=v(m,"product_config->show_product_price"))||void 0===b||b,h=null===(y=v(m,"event_tile_with_product_info->show_price_info"))||void 0===y||y,u=.9*n,g=Math.ceil(1.2*u),P=null!==(_=v(m,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==_&&_,$=e?10:12,T=Math.max(9,.75*n),S=2,z=$+Math.ceil(T);w+=`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${r}px ${o}px;\n gap: ${e?8:6}px;\n align-items: stretch;\n ">\n <div style="\n display: flex;\n flex-direction: column;\n gap: ${d}px;\n flex: 1;\n min-width: 0;\n ">\n \x3c!-- Title shimmer --\x3e\n <div style="\n min-height: ${s}px;\n height: ${s}px;\n width: 88%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,c&&h&&(w+=`\n \x3c!-- Price row shimmer --\x3e\n <div style="\n display: flex;\n gap: 8px;\n align-items: center;\n min-height: ${g}px;\n height: ${g}px;\n ">\n <div style="\n min-height: ${g}px;\n height: ${g}px;\n width: 35%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n min-height: ${g}px;\n height: ${g}px;\n width: 28%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>`),P&&(w+=`\n \x3c!-- Button shimmer --\x3e\n <div style="\n min-height: ${z}px;\n height: ${z}px;\n width: 100%;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: ${S}px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`),w+="\n </div>\n </div>"}w+="\n </div>\n "}return w+="\n </div>",w+="\n </div>",w+="\n </div>",w+="\n</div>",w}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,headingHeight:c,numberOfTiles:$,shopId:r.shopId,landingLocationType:r.landingLocationType,unscaledWidth:l.unscaledWidth,customizations:i});return{totalHeight:T,shimmerHTML:S}}const z=function(e,t){return e<=768?t>e?"mobilePortrait":"mobileLandscape":e<=1024?"tablet":"desktop"};function I({tileWidth:e,tileHeight:t,numberOfTiles:i,headingHeight:n,topBottomPadding:o,landscapePadding:a,deviceMode:r,windowWidth:d,gap:l,productInfoHeight:s,customizations:c,liquidVars:h}){const p="mobilePortrait"===r||"tablet"===r;let m=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${o}px; margin-bottom: ${o}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;n>0&&(m+=`\n <div style="display: flex; justify-content: center; align-items: center; margin-bottom: 16px;">\n <div style="\n width: 200px;\n height: ${n-16}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n </div>\n `);const u=s>0?function(e,t,i,n,o){var a,r,d;const l="mobilePortrait"===t||"tablet"===t,s=null===(a=v(n,"product_config->show_product_price"))||void 0===a||a,c=null===(r=v(n,"event_tile_with_product_info->show_price_info"))||void 0===r||r,h=null!==(d=v(n,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==d&&d,p="76767920441"===o.shopId||"55840899223"===o.shopId,m=l?1.076*e*.04:.04*e;let u=null;if(p)if(l)u={width:.22*e,height:.29*e};else{const t=.25*e;u={width:1.2*t,height:1.6*t}}const g=`\n <div style="\n width: 85%;\n height: ${1.2*(l?1.076*e*.04:.04*e)}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `,w=s?`\n <div style="display: flex; gap: 8px; align-items: center; margin-top: 5px; flex-wrap: wrap;">\n \x3c!-- Price --\x3e\n <div style="\n width: 60px;\n height: ${1.2*m}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n \x3c!-- Compare Price --\x3e\n <div style="\n width: 50px;\n height: ${1.2*m}px;\n background: #e0e0e0;\n border-radius: 3px;\n opacity: 0.7;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n ${c?`\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 45px;\n height: ${1.2*m+6}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `:""}\n </div>\n `:"",f=h?`\n <div style="\n width: 90%;\n height: ${l?"36":"44"}px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: 8px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `:"";return`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${p&&l?"6px 4px":"12px 4px"};\n gap: ${p&&l?"4px":"12px"};\n align-items: stretch;\n ">\n ${p&&u?`\n <div style="\n flex-shrink: 0;\n display: flex;\n align-items: stretch;\n ">\n <div style="\n width: ${u.width}px;\n height: ${u.height}px;\n background: #e0e0e0;\n border-radius: 5px;\n margin-left: ${l?"0px":"-3px"};\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n </div>\n `:""}\n <div style="\n display: flex;\n flex-direction: column;\n gap: ${p&&l?"2px":"5px"};\n flex: 1;\n min-width: 0;\n ">\n ${g}\n ${w}\n ${f}\n </div>\n </div>\n `}(e,r,0,c,h):"";m+=`\n <div class="${p?"whatmore-shimmer-events-carousel-portrait":"whatmore-shimmer-events-carousel-landscape"}" style="\n display: flex;\n justify-content: ${p?"flex-start":"center"};\n align-items: center;\n ${p?"padding-left: 12px;":`padding-left: ${a}px; padding-right: ${a}px;`}\n position: relative;\n overflow: hidden;\n ">`,p||(m+=`\n \x3c!-- Left navigation button --\x3e\n <div style="\n position: absolute;\n left: ${a}px;\n top: 50%;\n transform: translateY(-50%);\n width: 50px;\n height: 100px;\n background: #e0e0e0;\n border-radius: 6px;\n z-index: 1;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n\n \x3c!-- Right navigation button --\x3e\n <div style="\n position: absolute;\n right: ${a}px;\n top: 50%;\n transform: translateY(-50%);\n width: 50px;\n height: 100px;\n background: #e0e0e0;\n border-radius: 6px;\n z-index: 1;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `),m+=`\n <div style="display: flex; gap: ${l}px; overflow: hidden;">`;for(let g=0;g<i;g++)m+=`\n <div style="\n margin-top: 25px;\n margin-bottom: 10px;\n flex-shrink: 0;\n ">\n <div style="\n min-width: ${e}px;\n height: ${t}px;\n background: #e0e0e0;\n border-radius: 8px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n ${u}\n </div>\n `;return m+="\n </div>",m+="\n </div>",m+="\n </div>",m+="\n</div>",m}function M(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),tileSize:parseInt(t("whatmoreVideoTileSize","100")),tileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","100")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreLandingLocationType","index")}}(t),d=z(a,o),l=function({deviceMode:e,windowWidth:t,windowHeight:i,liquidVars:n,customizations:o}){var a;const r="mobilePortrait"===e||"tablet"===e?n.tileSizePortrait:n.tileSize,d=t>i,l="mobilePortrait"===e&&t>=481,s=r/100*1.3*.5,c=r/100,g=Math.min(t,i);let w=g*h*u,x=g*h,b=0,y=1.4;const _=null!==(a=v(o,"carousel_config->theme_margin"))&&void 0!==a?a:0;if(d){const e=x*s,i=w*s,o=n.landscapePadding||0;x=e,w=i,b=o,y=(t-2*o-2*_)/(1.1*e)}else if(l){let i=x*m,o=w*m;if("mobilePortrait"===e)i*=c,o*=c,x=i,w=o,b=0,y=f(t/(1.2*i));else{const e=n.landscapePadding||0;x=i,w=o,b=e,y=(t-2*e)/(1.1*i)}}else{let i=x,o=w;if("mobilePortrait"===e)i=i*c*.9,o=o*c*.9,x=i,w=o,b=0,y=f(t/(1.15*i));else{i=x*p,o=w*p;const e=n.landscapePadding||0;x=i,w=o,b=e,y=(t-2*e)/(1.1*i)}}return{height:w,width:x,landscapePadding:b,slidesPerView:y}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r,customizations:i}),s=Math.ceil(l.slidesPerView),c=void 0!==n?n:s,w=x(r.heading,r.titleFontSize),b=function(e,t=24){const i=v(e,"event_tile_config->gap_between_tiles");return null!==i&&void 0!==i?0===i?24:i:t}(i),y=function({tileWidth:e,deviceMode:t,customizations:i}){var n,o,a;if(!v(i,"event_tile_with_product_info->show_product_info"))return 0;const r="mobilePortrait"===t||"tablet"===t,d=null!==(n=v(i,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==n&&n,l=r?1.076*e*.04:.04*e,s=1.2*l+(null===(o=v(i,"product_config->show_product_price"))||void 0===o||o?1.2*l+5:0)+(null===(a=v(i,"event_tile_with_product_info->show_price_info"))||void 0===a||a?1.2*l+5:0)+(d?8+(r?36:44):0),c=d?110:s;return Math.round(Math.max(c,s+24))}({tileWidth:l.width,deviceMode:d,customizations:i}),P=r.topBottomPadding+w+25+l.height+y+10+r.topBottomPadding,$=I({tileWidth:l.width,tileHeight:l.height,numberOfTiles:c,headingHeight:w,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,windowHeight:o,gap:b,productInfoHeight:y,customizations:i,liquidVars:r});return{totalHeight:Math.round(P),shimmerHTML:$}}function k(e){const{customizations:t,widgetContainer:i,eventCount:n}=e,[o,a]=_(i),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),extensionType:t("whatmoreExtensionType","index")}}(i),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;r=r*m*e,d=d*m*e}else if("mobileLandscape"===t)o.videoTileSize,r*=p,d*=p;else{const e=o.videoTileSize/100*1.3*.5;r*=e,d*=e}return{height:r,width:d}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r});function s(e){return Math.round(10*e)/10}let c;c="mobilePortrait"===d?s(a/(1.15*l.width)):"tablet"===d?s(a/(1.2*l.width)):a/(1.1*l.width);const f=parseInt(Math.floor(c)),x=function(e,t){if(!v(t,"event_tile_with_product_info->show_atc_button_template_feed"))return 0;const i=.07*e;return 46+Math.ceil(2.5*i)}(l.width,t),b=.2*l.height,y=20+(3+l.height+3)+x,P=Math.ceil(n/f),$=r.topBottomPadding+P*y+(P-1)*b+r.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,eventCount:o,slidesPerView:a,atcButtonHeight:r,rowSpacing:d}=e,l=a,s=Math.ceil(o/l);let c=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${n}px;\n margin-bottom: ${n}px;\n ">\n <div class="whatmore-carousel-events-feed" style="\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 100%;\n gap: ${d}px;\n ">`;for(let h=0;h<s;h++){const e=Math.min(l,o-h*l);c+='\n <div class="whatmore-shimmer-feed-row" style="\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: flex-start;\n width: 100%;\n height: fit-content;\n gap: 0px;\n ">';for(let n=0;n<e;n++)c+=`\n <div style="margin: 10px;">\n <div class="whatmore-shimmer-tile-wrapper" style="\n display: flex;\n flex-direction: column;\n ">\n \x3c!-- Video tile --\x3e\n <div style="\n margin-top: 3px;\n margin-bottom: 3px;\n width: ${t}px;\n height: ${i}px;\n border-radius: 12px;\n background-color: #e0e0e0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,r>0&&(c+=`\n <div style="\n width: ${t}px;\n padding: 15px 0;\n ">\n <div style="\n width: 100%;\n height: ${16+Math.ceil(.07*t)}px;\n background-color: #e0e0e0;\n border-radius: 12px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>`),c+="\n </div>\n </div>";c+="\n </div>"}return c+="\n </div>\n </div>",c}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,eventCount:n,slidesPerView:f,atcButtonHeight:x,rowSpacing:b});return{totalHeight:Math.round($),shimmerHTML:T}}function H(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,[a,r]=_(i),d=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),l=w(r,a),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;s=2,c=0,d=d*e*.9,l=l*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:r,windowHeight:a,liquidVars:d,customizations:n}),c=Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(d.heading,d.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=d.topBottomPadding+y+25+s.height+25+d.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,headingHeight:o,topBottomPadding:a,landscapePadding:r,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c}=e,h="desktop"===d||"mobileLandscape"===d;let p=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${a}px; margin-bottom: ${a}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;if(o>0&&(p+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${o-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),p+=`\n <div class="${h?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ${h?`padding-left: ${r}px; padding-right: ${r}px;`:""}\n ">`,p+=`<div style="\n width: ${h?t*s*c+"px":l+"px"};\n height: fit-content;\n overflow: hidden;\n ">`,h){p+=`<div style="display: flex; gap: ${Math.round(t*c-t-20)}px; margin: 0 auto; width: max-content;">`;for(let e=0;e<n;e++)p+=`\n <div style="flex-shrink: 0; margin: 25px 10px 25px 10px;">\n \x3c!-- Template-G tile shimmer --\x3e\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}else{const e=l/s;p+='<div style="display: flex;">';for(let o=0;o<n;o++)p+=`\n <div style="flex-shrink: 0; width: ${e}px;">\n <div style="margin: 25px 10px 25px 10px;">\n \x3c!-- Template-G tile shimmer --\x3e\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ${o<s?"transform: scale(1.05);":""}\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `}return p+="\n </div>",p+="\n </div>",p+="\n </div>",p+="\n </div>",p+="\n</div>",p}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:r,slidesPerView:s.slidesPerView,widthMultiplier:P});return{totalHeight:Math.round($),shimmerHTML:T}}function B(e){var t,i;const{widgetContainer:n,customizations:o,eventCount:a}=e,[r,d]=_(n),l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(d,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:r,liquidVars:l,customizations:o}),b=null!==(t=v(o,"event_tile_config->space_between_tiles"))&&void 0!==t?t:1,y=c.slidesPerView*b,P=Math.ceil(y),$=void 0!==a?a:P,T=x(l.heading,l.titleFontSize),S=null!==(i=v(o,"carousel_config->width_multiplier"))&&void 0!==i?i:1.1,z=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e,d=null!==(t=v(r,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,l="mobilePortrait"===a||"tablet"===a,s=.25*o*1.25,c=v(r,"event_tile_with_product_info->portrait_font_multiplier"),h=v(r,"event_tile_with_product_info->landscape_font_multiplier"),p=l?1.076*o*c:o*h,m=Math.ceil(1.2*p),u=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,g=u?Math.ceil(1.2*p):0,w=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,f=l?.965*o*c:.859*o*h;let x=0;u&&x++,w&&x++;const b=m+g+(w?Math.ceil(f)+6:0)+5*x,y=d?Math.max(s,b):b;return Math.round(24+y)}({tileWidth:c.width,deviceMode:s,customizations:o}),I="mobilePortrait"===s||"tablet"===s?c.height*S:c.height,M=l.topBottomPadding+T+12+I+z+12+l.topBottomPadding,k=function(e){var t,i,n;const{tileWidth:o,tileHeight:a,numberOfTiles:r,headingHeight:d,topBottomPadding:l,landscapePadding:s,deviceMode:c,windowWidth:h,slidesPerView:p,widthMultiplier:m,productInfoHeight:u,customizations:g}=e,w="desktop"===c||"mobileLandscape"===c;let f=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${l}px; margin-bottom: ${l}px; overflow: hidden;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;d>0&&(f+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${d-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),f+=`\n <div class="${w?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ${w?`padding-left: ${s}px; padding-right: ${s}px;`:""}\n ">`,f+=`<div style="\n width: ${w?o*p*m+"px":h+"px"};\n max-width: 100%;\n height: fit-content;\n ${w?"overflow: hidden;":""}\n ">`;const x=null!==(t=v(g,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,b="mobilePortrait"===c||"tablet"===c,y=.25*o,_=null===(i=v(g,"product_config->show_product_price"))||void 0===i||i,P=null===(n=v(g,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,$=v(g,"event_tile_with_product_info->portrait_font_multiplier"),T=v(g,"event_tile_with_product_info->landscape_font_multiplier"),S=b?1.076*o*$:o*T,z=Math.ceil(1.2*S),I=Math.ceil(1.2*S),M=b?.965*o*$:.859*o*T,k=Math.ceil(M)+6,H=`\n <div style="cursor: pointer; display: flex; gap: 6px; padding: 12px 4px; width: 100%; box-sizing: border-box;">\n ${x?`\n \x3c!-- Thumbnail (conditional) --\x3e\n <div style="\n width: ${y}px;\n height: ${1.25*y}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n flex-shrink: 0;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `:""}\n \x3c!-- Product info (always shows) --\x3e\n <div style="display: flex; flex-direction: column; gap: 5px; flex: 1;">\n \x3c!-- Title --\x3e\n <div style="\n width: 85%;\n height: ${z}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${_?`\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: ${I}px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 50px; height: ${I}px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `:""}\n ${P?`\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 50px;\n height: ${k}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `:""}\n </div>\n </div>\n `,B=o,W=a*m,L=o,C=a;let V="";w||(V=`transform: translate3d(${-h/p/2}px, 0px, 0px);`);f+=`<div style="display: flex; gap: 0px; ${w?"margin: 0 auto; width: max-content;":V}">`;const E=w?r:3;for(let v=0;v<E;v++){const e=!w&&(0===v||2===v),t=!w&&1===v,i=t?B:e?L:o,n=t?W:e?C:a;f+=w?`\n <div style="flex-shrink: 0; width: ${o*p*m/p}px;">\n <div style="width: ${i}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${H}\n </div>\n </div>\n `:`\n <div style="flex-shrink: 0; width: ${h/p}px;">\n <div style="width: ${i}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${H}\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:$,headingHeight:T,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:y,widthMultiplier:S,productInfoHeight:z,customizations:o});return{totalHeight:Math.round(M),shimmerHTML:k}}function W(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,[a,r]=_(i),d=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),l=w(r,a),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;e*=1.3,t*=1.3,c=o.landscapePadding,s=5,d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e*1.3,i=d*e*1.3;c=o.landscapePadding,s=5,d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:r,windowHeight:a,liquidVars:d,customizations:n}),c="desktop"===l||"mobileLandscape"===l?5:Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(d.heading,d.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_with_product_info->show_thumbnail_image"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=.25*o,s=v(r,"event_tile_with_product_info->portrait_font_multiplier"),c=v(r,"event_tile_with_product_info->landscape_font_multiplier"),h=d?1.076*o*s:o*c,p=Math.ceil(1.2*h),m=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,u=m?Math.ceil(1.2*h):0,g=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,w=d?.965*o*s:.859*o*c;let f=0;m&&f++,g&&f++;const x=p+u+(g?Math.ceil(w)+6:0)+5*f,b=Math.max(l,x);return Math.round(24+b)}({tileWidth:"mobilePortrait"===l||"tablet"===l?s.width*P:s.width,deviceMode:l,customizations:n}),T="desktop"===l||"mobileLandscape"===l?24:12,S="mobilePortrait"===l||"tablet"===l?s.height*P:s.height,z=d.topBottomPadding+y+T+S+$+12+d.topBottomPadding,I=function(e){var t;const{tileWidth:i,tileHeight:n,numberOfTiles:o,headingHeight:a,topBottomPadding:r,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:p,customizations:m}=e,u="desktop"===l||"mobileLandscape"===l;let g=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${r}px;\n margin-bottom: ${r}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;a>0&&(g+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${a-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),g+=`<div class="${u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ">`,g+=`<div style="\n width: ${s+"px"};\n height: fit-content;\n overflow: hidden;\n ">`;const w=u?24:12;let f="";if(null!==(t=v(m,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t&&p>0){var x,b;const e=.25*i;f=`\n <div style="display: flex; gap: 6px; padding: 12px 4px;">\n \x3c!-- Thumbnail --\x3e\n <div style="\n width: ${e}px;\n height: ${e}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n flex-shrink: 0;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n \x3c!-- Product info --\x3e\n <div style="display: flex; flex-direction: column; gap: 5px; flex: 1;">\n \x3c!-- Title --\x3e\n <div style="\n width: 85%;\n height: 14px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${null===(x=v(m,"product_config->show_product_price"))||void 0===x||x?'\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: 14px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 50px; height: 14px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n ':""}\n ${null===(b=v(m,"event_tile_with_product_info->show_discount_label"))||void 0===b||b?'\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 50px;\n height: 18px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ':""}\n </div>\n </div>\n `}if(u){const e=[.6,.8,1,.8,.6],t=.65*i,o=s/2,a=(n+p)/2;g+=`<div style="display: flex; justify-content: center; align-items: center; position: relative; height: ${n+w+12+p}px;">`;for(let r=0;r<5;r++){const d=r-2,l=0===d,s=e[r],c=i*s,h=n*s;g+=`\n <div style="\n position: absolute;\n left: ${o+d*t-c/2}px;\n bottom: ${a-(h+(l?p:0))/2+12}px;\n z-index: ${5-Math.abs(d)};\n ${l?"":"filter: blur(2.5px) opacity(0.6);"}\n ">\n \x3c!-- Template-I tile shimmer --\x3e\n <div style="\n width: ${c}px;\n height: ${h}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${l?f:""}\n </div>\n `}g+="</div>"}else{const e=i,t=n,o=n*h;let a="";const r=s/c;a=`transform: translate3d(${-r/2}px, 0px, 0px);`,g+=`<div style="display: flex; gap: 0px; ${a}">`;const d=3;for(let i=0;i<d;i++)g+=`\n <div style="flex-shrink: 0; width: ${r}px;">\n <div style="width: ${e}px; margin: ${w}px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-I tile shimmer --\x3e\n <div style="\n width: ${e}px;\n height: ${1===i?o:t}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${f}\n </div>\n </div>\n `;g+="</div>"}return g+="</div>",g+="</div>",g+="</div>",g+="</div>",g}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:r,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:$,customizations:n});return{totalHeight:Math.round(z),shimmerHTML:I}}function L(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,a=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),[r,d]=_(i),l=w(d,r),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:d,windowHeight:r,liquidVars:a,customizations:n}),c=Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(a.heading,a.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_config->show_product_tile"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=v(r,"event_tile_with_product_info->portrait_font_multiplier"),s=v(r,"event_tile_with_product_info->landscape_font_multiplier"),c=d?1.15*o*l:1.05*o*s,h=Math.ceil(1.2*c),p=d?1.2*o*l:1.1*o*s,m=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,u=m?Math.ceil(1.2*p):0,g=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,w=d?.8*o*l:.7*o*s;let f=0;f++,m&&f++,g&&f++;const x=9+h+u+(g?Math.ceil(w)+6:0)+4*f;return Math.round(20+x)}({tileWidth:s.width,deviceMode:l,customizations:n}),T="mobilePortrait"===l||"tablet"===l,S=T?16:32,z=y>0?T?12:16:0,I=T?16:0,M=s.height,k=a.topBottomPadding+S+y+z+I+0+0+M+$+0+a.topBottomPadding,H=function(e){var t;const{tileWidth:i,tileHeight:n,numberOfTiles:o,headingHeight:a,topBottomPadding:r,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:p,customizations:m}=e,u="desktop"===l||"mobileLandscape"===l,g="mobilePortrait"===l||"tablet"===l,w=u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let f=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${r}px;\n margin-bottom: ${r}px;\n overflow: hidden;\n background: transparent;\n position: relative;\n padding: ${g?"8px 0":"16px 0"};\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: ${g?"visible":"hidden"};">`;a>0&&(f+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center; margin-bottom: ${g?12:16}px; position: relative; z-index: 1;">\n <div style="background: transparent; padding: 8px 24px; position: relative;">\n <div style="\n height: ${a-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `);f+=g?`<div class="${w}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 0 24px;\n background: transparent;\n margin: 8px 0;\n position: relative;\n ">`:`<div class="${w}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n padding-left: ${d}px;\n padding-right: ${d}px;\n ">`,f+=`<div style="\n width: ${u?i*Math.min(c,o)*h+"px":s-48+"px"};\n height: fit-content;\n overflow: ${g?"visible":"hidden"};\n position: relative;\n z-index: 1;\n ">`;let x="";var b,y;null!==(t=v(m,"event_tile_config->show_product_tile"))&&void 0!==t&&t&&p>0&&(x=`\n <div style="cursor: pointer; display: flex; flex-direction: column; gap: 4px; padding: 12px 0 8px 0; width: 100%; background: transparent;">\n \x3c!-- Product type label --\x3e\n <div style="\n width: 60%;\n height: 9px;\n background: #e0e0e0;\n border-radius: 2px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n \x3c!-- Title --\x3e\n <div style="\n width: 90%;\n height: 14px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${null===(b=v(m,"product_config->show_product_price"))||void 0===b||b?'\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 8px; align-items: center;">\n <div style="width: 70px; height: 16px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 60px; height: 16px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n ':""}\n ${null===(y=v(m,"event_tile_with_product_info->show_discount_label"))||void 0===y||y?'\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 55px;\n height: 20px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ':""}\n </div>\n `);if(g){var _;const e=s-48,t=12,o=c*(null!==(_=v(m,"event_tile_config->space_between_tiles"))&&void 0!==_?_:1),a=(e-(o-1)*t)/o;f+=`<div style="display: flex; transform: translate3d(${e/2-(a+t+a/2)}px, 0px, 0px);">`;const r=3,d=1.02,l=.98;for(let s=0;s<r;s++){const e=0===s||2===s;f+=`\n <div style="\n width: ${a}px;\n flex-shrink: 0;\n margin-right: ${s<r-1?t:0}px;\n display: flex;\n justify-content: flex-start;\n ">\n <div style="\n margin: 0px 0 0px 0;\n transform: scale(${1===s?d:l});\n transition: transform 0.3s ease-out;\n filter: ${e?"brightness(0.9)":"none"};\n opacity: ${e?"0.85":"1"};\n ">\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 0px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${x}\n </div>\n </div>\n `}}else{const e=i*h;f+='<div style="display: flex;">';for(let t=0;t<o;t++)f+=`\n <div style="\n width: ${e}px;\n flex-shrink: 0;\n display: flex;\n justify-content: flex-start;\n height: 100%;\n ">\n <div style="\n height: 100%;\n transform: translate3d(0px, 0px, 0px);\n transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 0.3s ease-out, opacity 0.3s ease-out;\n filter: none;\n opacity: 0.98;\n will-change: transform, filter, opacity;\n ">\n <div style="\n width: ${i}px;\n margin: 0px 0 0px 0;\n cursor: pointer;\n display: flex;\n flex-direction: column;\n align-items: stretch;\n justify-content: flex-start;\n background: transparent;\n position: relative;\n ">\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 0px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${x}\n </div>\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:a.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:d,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:$,customizations:n});return{totalHeight:Math.round(k),shimmerHTML:H}}function C(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}function V(e){var t;const{customizations:i,widgetContainer:n,eventCount:o}=e,[a,r]=_(n),d=function(e){const t=g(e);return{videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),landscapePadding:parseInt(t("whatmoreLandscapePadding","0")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20"))}}(n),l=a>r?"portrait":"landscape",s="portrait"===l?d.videoTileSizePortrait:d.videoTileSize,{WIDTH:c,HEIGHT:h,isPortrait:p}=function(e,t,i){const n=e>t,o=t>e,a=!(!o||!(e>=481)),r=.8,d=i/100*1.3*.5,l=i/100,s=Math.min(e,t);let c=.6*s,h=.6*s*(16/9);return n?(c*=d,h*=d):a?o?(c=c*r*l,h=h*r*l):(c*=r,h*=r):o?(c=c*l*.9,h=h*l*.9):(c*=.7,h*=.7),{WIDTH:c,HEIGHT:h,isPortrait:o}}(r,a,s),m="portrait"===l?0:d.landscapePadding,u=d.collectionsTilesSpacing,v=c*s*.01,w=C(i,"collections_config->story_tile_size_factor")||1,f=null!==(t=C(i,"collections_config->story_tile_shape"))&&void 0!==t?t:"circle",x=C(i,"collections_config->remove_borders"),b=parseInt(C(i,"collections_config->tile_margin_right"))||0,y=x?2:b||0,P=x?2:5,$=x?2:5,T="circle"===f?"50%":"6%",S=v*w,z="rectangle"===f?1.5*S:S,I=S,M=.8*(.055*c),k=P+z+10+$,H=2*d.topBottomPadding+k,B=r-2*m,W=I+y,L=Math.min(Math.ceil((B+u)/(W+u)),8),V=void 0!==o?o:L,E="landscape"===l?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let j=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${d.topBottomPadding}px;\n margin-bottom: ${d.topBottomPadding}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">\n <div class="${E}" style="\n margin-left: ${m}px;\n margin-right: ${m}px;\n ">\n <div class="whatmore-shimmer-collections-flex-stories" style="\n display: flex;\n flex-direction: row;\n gap: ${u}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-stories::before,\n .whatmore-shimmer-collections-flex-stories::after {\n content: '';\n margin: auto;\n }\n </style>\n `;for(let g=0;g<V;g++)j+=`\n <div style="\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n flex-shrink: 0;\n margin-right: ${y}px;\n margin-top: ${P}px;\n margin-bottom: ${$}px;\n ">\n \x3c!-- Border/shadow wrapper --\x3e\n <div class="whatmore-story-tile-border-wrapper" style="\n display: flex;\n flex-direction: column;\n justify-content: center;\n flex-shrink: 0;\n border-radius: ${T};\n overflow: hidden;\n ">\n \x3c!-- Tile with visible border --\x3e\n <div class="whatmore-shimmer-tile whatmore-story-tile-inner" style="\n flex-shrink: 0;\n height: ${z}px;\n width: ${S}px;\n border-radius: ${T};\n background-color: #e0e0e0;\n overflow: hidden;\n border: 3px solid #d0d0d0;\n box-sizing: border-box;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n \x3c!-- Empty title div --\x3e\n <div style="\n display: flex;\n justify-content: center;\n width: ${I}px;\n padding-top: 10px;\n font-size: ${M}px;\n ">\n <p style="margin: 0; padding: 0; line-height: 0; height: 0;"></p>\n </div>\n </div>\n `;return j+="\n </div>\n </div>\n </div>\n </div>",{totalHeight:Math.round(H),shimmerHTML:j}}var E;const j=null!==(E="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==E&&E;function q(e,t,i,n){var o,a;const r=e<=t,d=parseInt(((e,t)=>{const i=document.querySelector(`#${e}`);return i&&(i.getAttribute("data-wh")||i.getAttribute("data"))||t})("whatmoreVideoTileSize","60")),l=v(i,"banner_config->portrait_multiplier"),s=v(i,"banner_config->landscape_multiplier"),c=d/100*(null!==l&&void 0!==l?l:1),h=d/100*(null!==s&&void 0!==s?s:1),p=r?null!==(o=v(i,"banner_config->portrait_aspect_ratio"))&&void 0!==o?o:1:null!==(a=v(i,"banner_config->landscape_aspect_ratio"))&&void 0!==a?a:.5625,m=r?e*c:e*h,u=v(i,"banner_config->is_full_screen")||!1,g=u?e*p:m*p;return{width:u?"100%":`${m}px`,height:`${g}px`,borderWidth:v(i,"theme_config->event_tile->border_width")||"0px",borderColor:v(i,"theme_config->event_tile->border_color")||"transparent",borderStyle:"solid",totalHeight:g}}function O(e){const{windowWidth:t,windowHeight:i,customizations:n,widgetContainer:o,widgetIdentity:a}=e,r=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const i=t[e];return i?i.tc:null}return t.tc||null}(a);if(null===r||void 0===r||0===r)return j&&console.log("[Banner Shimmer] No event count found, returning null"),null;const d=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const i=t[e];return i?{landscape:i.landscape_poster||null,portrait:i.portrait_poster||null}:null}return{landscape:t.landscape_poster||null,portrait:t.portrait_poster||null}}(a);if(!d||!d.landscape&&!d.portrait)return j&&console.log("[Banner Shimmer] No poster URLs found"),null;const l=q(t,i,n),s=t<=i?d.portrait:d.landscape;if(!s)return j&&console.log("[Banner Shimmer] No poster URL for current orientation"),null;v(n,"banner_config->is_full_screen");const c=`\n <div class="whatmore-banner-shimmer-wrapper" style="\n position: relative;\n margin: 0 auto;\n width: ${l.width};\n height: ${l.height};\n border-width: ${l.borderWidth};\n border-color: ${l.borderColor};\n border-style: ${l.borderStyle};\n overflow: hidden;\n background: linear-gradient(135deg, #c0c0c0 0%, #d0d0d0 25%, #e0e0e0 50%, #d0d0d0 75%, #c0c0c0 100%);\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);\n ">\n <img\n src="${s}"\n alt="Loading preview"\n class="whatmore-banner-shimmer-poster"\n style="\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n opacity: 1;\n "\n />\n <div class="whatmore-banner-shimmer-overlay" style="\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.05) 100%);\n background-size: 200% 100%;\n animation: whatmore-banner-shimmer-wave 2.5s ease-in-out infinite;\n "></div>\n </div>\n `;return{totalHeight:l.totalHeight,shimmerHTML:c}}function A(e){return g(e)("whatmoreShopId",null)}function F(){return window.location.href.split(/[?#]/)[0]}function R(e,t,i,n){const o=A(e);if("index"===t&&"carousel"===i)return"homepage";if(t&&t.startsWith("product")){return v(n,"show_homepage_videos_in_pdp")?"homepage":function(e){return g(e)("whatmoreProductId",null)}(e)}if("collection"===i){let t;return"19506115"===o?t="343270603":v(n,"collections_config->use_page_link_as_collection_id")?t=v(n,"collections_config->multi_carousel_enabled")?function(e){return g(e)("whatmoreCollectionUrl",null)}(e):F():(t=function(e){return g(e)("whatmoreCollectionId",null)}(e),"0"===t&&(t=function(e){return g(e)("whatmorePageId",null)}(e)),t&&"0"!==t||(t=F())),t}return"carousel"===i?"homepage":null}function D(e,t){const i=A(e),n=function(e){return g(e)("whatmoreExtensionType",null)}(e),o=function(e){return e.querySelector('.whatmore-template-type[data-wh="template-banner-a"]')||e.querySelector('.whatmore-template-type[data="template-banner-a"]')?"banner":e.querySelector('[data-wh="collection"]')||e.querySelector('[data="collection"]')?"collection":e.querySelector('[data-wh="carousel"]')||e.querySelector('[data="carousel"]')?"carousel":null}(e),a=function(e){const t=["template-a","template-b","template-c","template-d","template-e","template-f","template-g","template-h","template-i","template-j","template-feed-a","template-a-1","template-stories","template-collections-a","template-collections-b","template-collections-c","template-collections-d","template-collections-e","template-collections-f","template-collections-g","template-collections-h","template-collections-i","template-collections-j","template-collections-stories","template-banner-a"];for(const i of t)if(e.querySelector(`.whatmore-template-type[data-wh="${i}"]`)||e.querySelector(`.whatmore-template-type[data="${i}"]`))return i;return null}(e),r=R(e,n,o,t),d=function(e){return g(e)("whatmoreWidgetIdentity","wgt_default")}(e);return{shopId:i,landingLocationType:n,widgetType:o,templateType:a,actualId:r,widgetIdentity:d,isValidId:(l=r,!(!l||null===l||"null"===l||""===l)&&/^\d+$/.test(String(l))||"homepage"===r)};var l}var N,U=n(3782);const Y=null!==(N="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==N&&N;function G(e,t,i){const n=window.whatmorePdpCarouselEvents;if(!n)return null;if(t&&"wgt_default"!==t){var o;const a=t.split("_");if(a.length<2||!a[1])return null;const r=null===(o=n[`w_${a[1][0]}`])||void 0===o?void 0:o[t];if(!r)return null;const d=r.scope_mode||"all",l=r.scope_targets||[],s=String(e);let c=!1;if("all"===d?c=!0:"include"===d?c=l.includes(s):"exclude"===d&&(c=!l.includes(s)),!c)return null;return v(i,"show_out_of_stock_videos")?r.etc:r.esc}{var a;const t=function(e){return"p_"+parseInt(e)%127}(e),o=null===(a=n[t])||void 0===a?void 0:a[e];if(!o)return null;return v(i,"show_out_of_stock_videos")?o.etc:o.esc}}function K(e,t,i){var n,o;const a=null===(n=window.whatmore)||void 0===n?void 0:n.collectionMetafields;if(!a)return null;const r=function(e){return"c_"+parseInt(e)%63}(e);let d=e;t&&"wgt_default"!==t&&(d=`${e}_${t}`);const l=null===(o=a[r])||void 0===o?void 0:o[d];if(!l)return null;return v(i,"show_out_of_stock_videos")?l.tc:l.sc}function J(e,t,i,n,o,a){var r;if(!(null===(r=v(a,"shimmer_config->enable_shimmer"))||void 0===r||r))return Y&&console.log("[Shimmer] Disabled via customization"),null;if(null!==U.A)return Y&&console.log(`[Shimmer] TEST MODE: Using hardcoded count ${U.A}`),U.A;if(!i||""===i||"undefined"===i||"null"===i)return Y&&console.log("[Shimmer] No valid ID provided"),null;let d=null;return"homepage"===i?d=function(e,t){const i=window.whatmoreHomepageCarouselEvents;if(!i)return null;if(e&&"wgt_default"!==e){const n=i[e];return n?v(t,"show_out_of_stock_videos")?n.tc:n.sc||n.tc:null}return v(t,"show_out_of_stock_videos")?i.tc:i.sc}(n,a):t&&t.startsWith("product")?d=G(i,n,a):"collection"===e&&(d=K(i,n,a)),null===d||void 0===d||0===d?(Y&&console.log(`[Shimmer] Event count is ${d}, skipping shimmer`),null):(Y&&console.log(`[Shimmer] Found event count: ${d} for ${e}/${t}/${i}/${n}`),d)}var X,Z,Q,ee,te,ie,ne,oe,ae=n(964);const re=Array.from(document.getElementsByClassName("whatmore-base")),de=null!==(X="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==X&&X,le=function(e){return"template-banner-a"===e},se=function(e){return"template-collections-a"==e||"template-collections-b"==e||"template-collections-c"==e||"template-collections-d"==e||"template-collections-e"==e||"template-collections-stories"==e||"template-collections-f"==e||"template-collections-g"==e||"template-collections-h"==e||"template-collections-i"==e||"template-collections-feed-a"==e||"template-collections-j"==e||"template-collections-a-1"==e},ce=function(e){return"template-stories-a"===e||"template-stories-b"===e};function he(e,t){const i=document.getElementById(e);if(!i)return t;return i.getAttribute("data-wh")||i.getAttribute("data")||t}function pe(e,t,i,n,o){var a;if("template-embed"===i)return;if("60595503283"===ue)return;if(!(null===(a=l(n,"shimmer_config->enable_shimmer"))||void 0===a||a))return;const r=function(e){return{"template-collections-a":"template-c","template-collections-b":"template-d","template-collections-c":"template-e","template-collections-d":"template-b","template-collections-e":"template-a","template-collections-f":"template-f","template-collections-feed-a":"template-feed-a","template-collections-g":"template-g","template-collections-h":"template-h","template-collections-i":"template-i","template-collections-j":"template-j","template-collections-stories":"template-stories"}[e]||e}(i),[d,s]=_(t);try{const a=function(e){const{templateType:t,widgetContainer:i,customizations:n}=e,o=D(i,n);if("template-banner-a"===t)return e.widgetIdentity=o.widgetIdentity,O(e);const a=J(o.widgetType,o.landingLocationType,o.actualId,o.widgetIdentity,0,n);return null===a?null:(e.eventCount=a,"template-a"===t?y(e):"template-b"===t?P(e):"template-c"===t?$(e):"template-d"===t?T(e):"template-e"===t?S(e):"template-f"===t?M(e):"template-feed-a"===t?k(e):"template-g"===t?H(e):"template-h"===t?B(e):"template-i"===t?W(e):"template-j"===t?L(e):"template-stories"===t?V(e):null)}({templateType:r,widgetContainer:t,customizations:n,windowWidth:s,windowHeight:d});if(a&&a.totalHeight&&a.shimmerHTML){if(!document.getElementById("whatmore-shimmer-styles")){const e=document.createElement("style");e.id="whatmore-shimmer-styles",e.textContent="\n@keyframes whatmore-shimmer-wave {\n 0% { transform: translateX(-100%); }\n 100% { transform: translateX(100%); }\n}\n\n@keyframes whatmore-banner-shimmer-wave {\n 0% { background-position: 200% 0; }\n 100% { background-position: -200% 0; }\n}\n\n@keyframes whatmore-banner-shimmer-pulse {\n 0%, 100% { opacity: 0.3; }\n 50% { opacity: 0.5; }\n}\n\n/* Pixel-accurate shimmer */\n.whatmore-pixel-shimmer-container {\n width: 100%;\n overflow: hidden;\n}\n\n.whatmore-shimmer-heading {\n position: relative;\n overflow: hidden;\n}\n\n.whatmore-shimmer-tiles-row {\n display: flex;\n gap: 12px;\n overflow: hidden;\n}\n\n.whatmore-shimmer-tile-wrapper {\n flex-shrink: 0;\n}\n\n.whatmore-shimmer-tile {\n position: relative;\n overflow: hidden;\n}\n\n.whatmore-shimmer-product-info {\n margin-top: 8px;\n}\n\n.whatmore-shimmer-animation {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);\n animation: whatmore-shimmer-wave 1.5s infinite;\n}\n",document.head.appendChild(e)}t.style.setProperty("position","relative","important"),t.style.setProperty("height","auto","important"),t.style.setProperty("border-top","0.1px solid transparent","important"),t.style.minHeight=a.totalHeight+"px";const n=document.createElement("div");n.className="whatmore-shimmer-container",n.setAttribute("data-template",i),n.setAttribute("data-widget-id",o),n.style.cssText="position: absolute; top: 0; left: 0; width: 100%; height: auto; z-index: 2; transition: opacity 0.1s ease;",n.innerHTML=a.shimmerHTML,t.insertBefore(n,e),e.style.cssText="opacity: 0; z-index: 1; transition: opacity 0.3s ease;",e.setAttribute("data-shimmer-active","true"),e.setAttribute("data-widget-id",o)}}catch(c){console.error(`[${(new Date).toLocaleTimeString()}] Error calculating shimmer for ${i}:`,c)}}const me=null!==document.getElementById("whatmoreRoot"),ue=he("whatmoreShopId",ae.YZ),ge=he("whatmoreExtensionType","index"),ve=null!==(Z=(null===(Q=window)||void 0===Q||null===(ee=Q.Shopify)||void 0===ee||null===(te=ee.theme)||void 0===te?void 0:te.role)&&"main"!==(null===(ie=window)||void 0===ie||null===(ne=ie.Shopify)||void 0===ne||null===(oe=ne.theme)||void 0===oe?void 0:oe.role))&&void 0!==Z&&Z,we=("2665447536"==ue||"72201044272"==ue)&&null!=localStorage.getItem("w_user_type"),fe=function(){const e=r("wtt"),t=r("weid");return null!=e&&null!=t}();!async function(){const e=await s(ue);if(null!==e&&void 0!==e&&e.brand_custom_css){const t=document.createElement("style");t.innerHTML=e.brand_custom_css,document.head.appendChild(t)}if(!me&&re&&re.length>0)for(let s=0;s<re.length;s++){var t,i,o,a,r,d,l,h,p,m;const M=re[s],k=M.querySelector(".whatmore-render-root"),H=M.querySelector(".whatmore-template-type");let B=!1,W=!1,L=!1;const C=null!==(t=null!==(i=null===H||void 0===H?void 0:H.getAttribute("data-wh"))&&void 0!==i?i:null===H||void 0===H?void 0:H.getAttribute("data"))&&void 0!==t?t:"template-embed";ce(C)?B=!0:se(C)?W=!0:le(C)&&(L=!0);let V="",E="";var u,g,v,w,f,x,b,y,_,P,$;if(W)if(V=null!==(u=null!==(g=null===(v=M.querySelector("#whatmoreCollectionId"))||void 0===v?void 0:v.getAttribute("data-wh"))&&void 0!==g?g:null===(w=M.querySelector("#whatmoreCollectionId"))||void 0===w?void 0:w.getAttribute("data"))&&void 0!==u?u:"",E=null!==(f=null!==(x=null===(b=M.querySelector("#whatmoreCollectionHeading"))||void 0===b?void 0:b.getAttribute("data-wh"))&&void 0!==x?x:null===(y=M.querySelector("#whatmoreCollectionHeading"))||void 0===y?void 0:y.getAttribute("data"))&&void 0!==f?f:"","0"==V)V=null!==(_=null===(P=M.querySelector("#whatmorePageId"))||void 0===P?void 0:P.getAttribute("data-wh"))&&void 0!==_?_:null===($=M.querySelector("#whatmorePageId"))||void 0===$?void 0:$.getAttribute("data");const j=null!==(o=null!==(a=null===(r=M.querySelector("#whatmoreHeading"))||void 0===r?void 0:r.getAttribute("data-wh"))&&void 0!==a?a:null===(d=M.querySelector("#whatmoreHeading"))||void 0===d?void 0:d.getAttribute("data"))&&void 0!==o?o:"",q=null!==(l=null!==(h=null===(p=M.querySelector("#whatmoreWidgetIdentity"))||void 0===p?void 0:p.getAttribute("data-wh"))&&void 0!==h?h:null===(m=M.querySelector("#whatmoreWidgetIdentity"))||void 0===m?void 0:m.getAttribute("data"))&&void 0!==l?l:"wgt_default",O="whatmoreRoot"+s;if("template-embed"===C&&(null===ge||void 0===ge||!ge.startsWith("product"))&&(null===ge||void 0===ge||!ge.startsWith("collection"))){var T,S,z,I;const t=null===e||void 0===e||null===(T=e.spotlight_config)||void 0===T?void 0:T.enable_spotlight,i=null===e||void 0===e||null===(S=e.spotlight_config)||void 0===S?void 0:S.enable_in_homepage,n=null===e||void 0===e||null===(z=e.spotlight_config)||void 0===z?void 0:z.enable_all_pages,o=(null===e||void 0===e||null===(I=e.spotlight_config)||void 0===I?void 0:I.enable_page_id_set)||[];if(!(t&&(i&&ge.includes("index")||V&&o.includes(V)||n)))continue}pe(k,M,C,e,O);const A=c(e,W,fe,C,ge),F=()=>{Promise.all([n.e(305),n.e(268)]).then(n.bind(n,1592)).then(e=>{e.initializeReactApp({rootElement:k,templateType:C,isStoriesTemplate:B,isCollectionsTemplate:W,_isTemplateTypeBanner:L,whatmoreCollectionId:V,whatmoreCollectionHeading:E,whatmoreHeadingCarousel:j,whatmoreWidgetIdentity:q,whatmoreRootId:O,landingLocationType:ge,isInPreviewMode:ve,userType:we})}).catch(e=>{console.error("Whatmore: Failed to load React chunk:",e);const t=document.querySelector(`.whatmore-shimmer-container[data-widget-id="${O}"]`);t&&(t.remove(),de&&console.log(`[Chunk Error] Removed shimmer for widget ${O}`)),M&&(M.style.minHeight="0px",de&&console.log(`[Chunk Error] Reset minHeight to 0px for widget ${O}`)),k&&(k.style.opacity="0",k.removeAttribute("data-shimmer-active"))})};if(A){let e=!1;const t=()=>{e||(e=!0,F())},i=new IntersectionObserver(e=>{e.forEach(e=>{de&&console.log(`[OBSERVER] Widget ${s}: isIntersecting=${e.isIntersecting}, top=${e.boundingClientRect.top}, bottom=${e.boundingClientRect.bottom}, viewportHeight=${window.innerHeight}`),e.isIntersecting&&(de&&console.log(`[OBSERVER] Widget ${s}: Loading React chunk`),t(),i.disconnect())})},{threshold:0,rootMargin:"0px 0px 0px 0px"});i.observe(M);const n=M.getBoundingClientRect();de&&console.log(`[SETUP] Widget ${s}: Observer attached, position top=${n.top}, bottom=${n.bottom}, viewportHeight=${window.innerHeight}, margin=500px`);const o=10;let a=window.pageYOffset;de&&console.log(`[SCROLL LISTENER] Widget ${s}: Initial scroll position=${a}`);const r=()=>{const e=window.pageYOffset,i=Math.abs(e-a);de&&console.log(`[SCROLL LISTENER] Widget ${s}: Scroll event fired, scrollY=${e}, lastScrollY=${a}, delta=${i}`),i>o&&(de&&console.log(`[SCROLL LISTENER] Widget ${s}: Delta > ${o}, triggering load`),t(),window.removeEventListener("scroll",r))};window.addEventListener("scroll",r,{passive:!0})}else F()}else if(me){const e=document.getElementById("whatmoreRoot"),t="whatmoreRoot",i=he("whatmoreTemplateType","invalid-template"),o=ce(i),a=se(i),r=le(i);Promise.all([n.e(305),n.e(268)]).then(n.bind(n,1592)).then(n=>{n.initializeReactApp({rootElement:e,templateType:i,isStoriesTemplate:o,isCollectionsTemplate:a,_isTemplateTypeBanner:r,whatmoreCollectionId:"",whatmoreCollectionHeading:"",whatmoreHeadingCarousel:"",whatmoreWidgetIdentity:"wgt_default",whatmoreRootId:t,landingLocationType:ge,isInPreviewMode:ve,userType:we})}).catch(e=>{console.error("Whatmore: Failed to load React chunk for legacy store:",e)})}}()}();
1
+ !function(){"use strict";var e,t={964:function(e,t,i){i.d(t,{$$:function(){return o},DK:function(){return u},Dk:function(){return s},K1:function(){return c},MT:function(){return r},OL:function(){return h},Sx:function(){return g},TB:function(){return m},YZ:function(){return n},aD:function(){return a},mM:function(){return l},qW:function(){return d},rz:function(){return p}});const n="58669793418",o="https://consumer.whatmore.live",a="https://whatmore-api-cdn-cache.azureedge.net",r="https://cdn-consumer.whatmore.live",d="https://analytics.whatmore.live",l=!1,s="carousel",c="video_popup",h="stories",p="collections",m="homepage",u="product_page",g="collection_page"},3782:function(e,t,i){i.d(t,{A:function(){return n},H:function(){return o}});const n=i(964).mM?4:null;function o(e){if(!e||0===e.length)return e;if(null!==n){return e.slice(0,n)}return e}}},i={};function n(e){var o=i[e];if(void 0!==o)return o.exports;var a=i[e]={id:e,loaded:!1,exports:{}};return t[e](a,a.exports,n),a.loaded=!0,a.exports}n.m=t,n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};n.t=function(i,o){if(1&o&&(i=this(i)),8&o)return i;if("object"===typeof i&&i){if(4&o&&i.__esModule)return i;if(16&o&&"function"===typeof i.then)return i}var a=Object.create(null);n.r(a);var r={};e=e||[null,t({}),t([]),t(t)];for(var d=2&o&&i;("object"==typeof d||"function"==typeof d)&&!~e.indexOf(d);d=t(d))Object.getOwnPropertyNames(d).forEach(function(e){r[e]=function(){return i[e]}});return r.default=function(){return i},n.d(a,r),a}}(),n.d=function(e,t){for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.f={},n.e=function(e){return Promise.all(Object.keys(n.f).reduce(function(t,i){return n.f[i](e,t),t},[]))},n.u=function(e){return"static/js/"+({259:"location-details",260:"event-click-component",268:"react-main-app",760:"homepage-carousel-view",939:"atc-with-form"}[e]||e)+"."+{259:"74afe936",260:"d9e3c981",264:"305fc5ba",268:"10a10ba6",305:"56d2f88f",323:"88610351",760:"d32a1761",844:"d124e3d5",939:"63aa381a"}[e]+".chunk.js"},n.miniCssF=function(e){return"static/css/"+{260:"event-click-component",268:"react-main-app",760:"homepage-carousel-view"}[e]+"."+{260:"f4759a24",268:"f2c2ed61",760:"522128da"}[e]+".chunk.css"},n.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={},t="whatmorelive-react:";n.l=function(i,o,a,r){if(e[i])e[i].push(o);else{var d,l;if(void 0!==a)for(var s=document.getElementsByTagName("script"),c=0;c<s.length;c++){var h=s[c];if(h.getAttribute("src")==i||h.getAttribute("data-webpack")==t+a){d=h;break}}d||(l=!0,(d=document.createElement("script")).charset="utf-8",d.timeout=120,n.nc&&d.setAttribute("nonce",n.nc),d.setAttribute("data-webpack",t+a),d.src=i),e[i]=[o];var p=function(t,n){d.onerror=d.onload=null,clearTimeout(m);var o=e[i];if(delete e[i],d.parentNode&&d.parentNode.removeChild(d),o&&o.forEach(function(e){return e(n)}),t)return t(n)},m=setTimeout(p.bind(null,void 0,{type:"timeout",target:d}),12e4);d.onerror=p.bind(null,d.onerror),d.onload=p.bind(null,d.onload),l&&document.head.appendChild(d)}}}(),n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},n.p="https://cdn.jsdelivr.net/npm/whatmore-react-assets@latest/",function(){if("undefined"!==typeof document){var e=function(e){return new Promise(function(t,i){var o=n.miniCssF(e),a=n.p+o;if(function(e,t){for(var i=document.getElementsByTagName("link"),n=0;n<i.length;n++){var o=(r=i[n]).getAttribute("data-href")||r.getAttribute("href");if("stylesheet"===r.rel&&(o===e||o===t))return r}var a=document.getElementsByTagName("style");for(n=0;n<a.length;n++){var r;if((o=(r=a[n]).getAttribute("data-href"))===e||o===t)return r}}(o,a))return t();!function(e,t,i,o,a){var r=document.createElement("link");r.rel="stylesheet",r.type="text/css",n.nc&&(r.nonce=n.nc),r.onerror=r.onload=function(i){if(r.onerror=r.onload=null,"load"===i.type)o();else{var n=i&&i.type,d=i&&i.target&&i.target.href||t,l=new Error("Loading CSS chunk "+e+" failed.\n("+n+": "+d+")");l.name="ChunkLoadError",l.code="CSS_CHUNK_LOAD_FAILED",l.type=n,l.request=d,r.parentNode&&r.parentNode.removeChild(r),a(l)}},r.href=t,i?i.parentNode.insertBefore(r,i.nextSibling):document.head.appendChild(r)}(e,a,null,t,i)})},t={792:0};n.f.miniCss=function(i,n){t[i]?n.push(t[i]):0!==t[i]&&{260:1,268:1,760:1}[i]&&n.push(t[i]=e(i).then(function(){t[i]=0},function(e){throw delete t[i],e}))}}}(),function(){var e={792:0};n.f.j=function(t,i){var o=n.o(e,t)?e[t]:void 0;if(0!==o)if(o)i.push(o[2]);else{var a=new Promise(function(i,n){o=e[t]=[i,n]});i.push(o[2]=a);var r=n.p+n.u(t),d=new Error;n.l(r,function(i){if(n.o(e,t)&&(0!==(o=e[t])&&(e[t]=void 0),o)){var a=i&&("load"===i.type?"missing":i.type),r=i&&i.target&&i.target.src;d.message="Loading chunk "+t+" failed.\n("+a+": "+r+")",d.name="ChunkLoadError",d.type=a,d.request=r,o[1](d)}},"chunk-"+t,t)}};var t=function(t,i){var o,a,r=i[0],d=i[1],l=i[2],s=0;if(r.some(function(t){return 0!==e[t]})){for(o in d)n.o(d,o)&&(n.m[o]=d[o]);if(l)l(n)}for(t&&t(i);s<r.length;s++)a=r[s],n.o(e,a)&&e[a]&&e[a][0](),e[a]=0},i=self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))}(),n.nc=void 0;const o="whatmore_brand_customizations",a=null!==(e="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==e&&e;function r(e){return new URLSearchParams(window.location.search).get(e)}function d(e){try{const t={customizations:e,timestamp:(new Date).getTime()};localStorage.setItem(o,JSON.stringify(t)),a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations saved to cache`)}catch(t){console.error("Whatmore: Error saving customizations to cache:",t)}}function l(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}async function s(e){var t,i;if(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd0d Getting customizations...`),null!==(t=window)&&void 0!==t&&null!==(i=t.whatmore)&&void 0!==i&&i.frontendCustomizations&&"object"===typeof window.whatmore.frontendCustomizations){a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from window.whatmore.frontendCustomizations`);const e=window.whatmore.frontendCustomizations;return d(e),e}const n=function(){try{const e=localStorage.getItem(o);if(!e)return null;const t=JSON.parse(e);return t.timestamp+3e5>=(new Date).getTime()?t.customizations:null}catch(e){return console.error("Whatmore: Error reading customizations cache:",e),null}}();if(n)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from cache`),n;a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No cached customizations, fetching from backend...`);const r=await async function(e){try{a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83c\udf10 Fetching customizations from backend for shopId: ${e}`);const t=await fetch(`https://api.whatmore.live/customization/frontend/${e}`);if(!t.ok)throw new Error(`HTTP error! status: ${t.status}`);const i=await t.json();return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations fetched from backend`),d(i),i}catch(t){return console.error("Whatmore: Error fetching customizations from backend:",t),null}}(e);return r}function c(e,t,i,n,o){if(i)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udccc Shared link detected - immediate load`),!1;if("template-embed"===n&&null!==o&&void 0!==o&&o.startsWith("product"))return a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udecd\ufe0f Product page popup detected - immediate load`),!1;if(!e)return a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No customizations - defaulting to immediate load`),!1;const r=l(e,"lazy_load_config->block_widgets"),d=l(e,"collections_config->show_popup_out_of_view");return t&&d?(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udce6 Collections with showPopupOutOfView=true - immediate load`),!1):r?(a&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd04 lazyloadConfig_blockWidget=true - lazy load enabled`),!0):(a&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a1 lazyloadConfig_blockWidget=false - immediate load`),!1)}const h=.6,p=.7,m=.8,u=16/9;function g(e){return(t,i)=>{const n=e.querySelector(`#${t}`);if(!n)return i;return n.getAttribute("data-wh")||n.getAttribute("data")||i}}function v(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}function w(e,t){const i=e>t,n=e>=481;return i&&n?"desktop":!i&&n?"tablet":i&&!n?"mobileLandscape":"mobilePortrait"}function f(e){return Math.round(10*e)/10}function x(e,t){if(!(e&&""!==e.trim()))return 0;return Math.round(1.5*t+16)}function b(e,t){if(!t.startsWith("product"))return 0;const i=.055*e;return Math.round(12+1.2*i*2)}function y(e){var t,i;const{widgetContainer:n,customizations:o,windowWidth:a,windowHeight:r,eventCount:d}=e,l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(a,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:a,windowHeight:r,liquidVars:l,customizations:o}),b=Math.ceil(c.slidesPerView),y=void 0!==d?d:b,_=null!==(t=v(o,"event_tile_config->show_product_thumbnail"))&&void 0!==t&&t,P=function(e){var t,i,n;const{width:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_config->show_product_thumbnail"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=null!==(i=v(r,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==i?i:1,s=null!==(n=v(r,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==n?n:1,c=d?l:s,h=d?1.076*o*c:o*c,p=1.2*h,m=1.2*h,u=h;return Math.round(24+p+5+m+5+u)}({width:c.width,deviceMode:s,customizations:o}),$=x(l.heading,l.titleFontSize),T=null!==(i=v(o,"carousel_config->width_multiplier"))&&void 0!==i?i:1.1,S=l.topBottomPadding+$+25+c.height+P+25+l.topBottomPadding,z=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,showProductInfo:o,productInfoHeight:a,headingHeight:r,topBottomPadding:d,landscapePadding:l,deviceMode:s,windowWidth:c,windowHeight:h,slidesPerView:p,widthMultiplier:m}=e,u="desktop"===s||"mobileLandscape"===s,g=u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let v=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${d}px; margin-bottom: ${d}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;r>0&&(v+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <p style="\n height: ${r}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin: 0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </p>\n </div>\n `),u?(v+=`\n <div class="${g}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n height: 100%;\n padding-left: ${l}px;\n padding-right: ${l}px;\n ">`,v+=`\n <div style="\n width: ${Math.floor(t*p*m)}px;\n height: 100%;\n overflow: hidden;\n ">`):(v+=`\n <div class="${g}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n overflow: hidden;\n ">`,v+=`\n <div style="\n width: ${c}px;\n height: fit-content;\n ">`);const w=u?n:3;let f="";u||(f=`transform: translate3d(${c/2-1.5*(t+10+10)}px, 0px, 0px);`);v+=`\n <div style="display: flex; ${u?"margin: 0 auto; width: max-content;":f}">`;for(let x=0;x<w;x++){const e=!u&&1===x;u&&(v+=`\n <div style="\n flex-shrink: 0;\n width: ${Math.floor(t*m)}px;\n display: flex;\n justify-content: center;\n align-items: center;\n ">`),v+=`\n <div style="\n ${u?"":"flex-shrink: 0;"}\n margin: 25px 10px 25px 10px;\n width: ${t}px;\n height: ${i}px;\n border-radius: 5px;\n overflow: hidden;\n position: relative;\n transform: ${e?"scale(1.05)":"scale(1)"};\n transition: transform 0.3s ease-out;\n ">\n \x3c!-- Video tile shimmer --\x3e\n <div style="\n width: 100%;\n height: 100%;\n background: #e0e0e0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `,o&&(v+='\n <div style="padding: 12px 4px; display: flex; gap: 6px;">\n <div style="flex: 1; display: flex; flex-direction: column; gap: 5px;">\n <div style="\n height: 14px;\n width: 90%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n height: 12px;\n width: 60%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n height: 10px;\n width: 40%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n '),v+=" </div>",u&&(v+=" </div>")}return v+="\n </div>",v+="\n </div>",v+="\n</div>",v+="\n</div>",v+="\n</div>",v}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:y,showProductInfo:_,productInfoHeight:P,headingHeight:$,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:a,windowHeight:r,slidesPerView:c.slidesPerView,widthMultiplier:T});return{totalHeight:Math.round(S),shimmerHTML:z,topBottomPadding:l.topBottomPadding}}function _(e,t){var i,n,o;const a=(null===(i=e.querySelector("#whatmoreShopId"))||void 0===i?void 0:i.getAttribute("data-wh"))||(null===(n=e.querySelector("#whatmoreShopId"))||void 0===n?void 0:n.getAttribute("data"));if("51273072796"==a||"64967540952"==a)return[document.documentElement.clientHeight,document.documentElement.clientWidth];const r=null!==(o="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==o&&o;let d=e;for(;d&&d!==document&&(d=d.parentElement,!d||d.classList.contains("whatmore-base")););let l=window.innerWidth;if(d){const e=d.getBoundingClientRect().width;if(e>0){const t=window.getComputedStyle(d);l=e-(parseFloat(t.paddingLeft)||0)-(parseFloat(t.paddingRight)||0)}d&&0==e&&(d.style.setProperty("width","100%","important"),r&&console.log("Set currElement width to 100% !important"))}return[window.innerHeight,l]}function P(e){var t,i;const{widgetContainer:n,customizations:o,eventCount:a}=e,[r,d]=_(n),l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(d,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){var g;const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;const r=null!==(g=v(a,"event_tile_config->space_between_tiles"))&&void 0!==g?g:1;s=f(i/(1.15*t))*r,c=0,d=n,l=t}else if("tablet"===t){var w;const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;const r=null!==(w=v(a,"event_tile_config->space_between_tiles"))&&void 0!==w?w:1;s=f(i/(1.2*t))*r,c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:1.2*d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:r,liquidVars:l,customizations:o}),b=Math.ceil(c.slidesPerView),y=void 0!==a?a:b,P=x(l.heading,l.titleFontSize),$=null!==(t=v(o,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,T=("desktop"===s||"mobileLandscape"===s)&&null!==(i=v(o,"event_tile_config->gap_between_tiles"))&&void 0!==i?i:0,S=l.topBottomPadding+P+25+c.height+25+l.topBottomPadding,z=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,headingHeight:o,topBottomPadding:a,landscapePadding:r,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c,spaceBetween:h}=e,p="desktop"===d||"mobileLandscape"===d;let m=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${a}px; margin-bottom: ${a}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;if(o>0&&(m+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${o-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),m+=`\n <div class="${p?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n height: 100%;\n ${p?`padding-left: ${r}px; padding-right: ${r}px;`:""}\n ">`,m+=`\n <div style="\n width: ${p?t*s*c+"px":l+"px"};\n height: 100%;\n overflow: hidden;\n ">`,p){m+=`<div style="margin: 0 auto; display: flex; gap: ${h}px; align-items: center; width: max-content;">`;for(let e=0;e<n;e++)m+=`\n <div style="flex-shrink: 0; width: ${t*c}px; display: flex; justify-content: center; align-items: center;">\n \x3c!-- Template-B tile shimmer: single rectangle with HEIGHT * 1.2 --\x3e\n <div style="\n margin: 25px auto;\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}else{const e=l/s;m+=`<div style="display: flex; transform: translate3d(${l/2-1.5*e}px, 0px, 0px);">`;for(let n=0;n<3;n++)m+=`\n <div style="flex-shrink: 0; width: ${e}px; display: flex; justify-content: center; align-items: center;">\n \x3c!-- Template-B tile shimmer: single rectangle with HEIGHT * 1.2 --\x3e\n <div style="\n margin: 25px auto;\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n transform: ${1===n?"scale(1.05)":"scale(1)"};\n transition: transform 0.3s ease-out;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}return m+="\n </div>",m+="\n </div>",m+="\n</div>",m+="\n</div>",m+="\n</div>",m}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:y,headingHeight:P,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:c.slidesPerView,widthMultiplier:$,spaceBetween:T});return{totalHeight:S,shimmerHTML:z}}function $(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:r*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s=r.collectionsTilesSpacing,c=b(l.width,r.extensionType),v="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,f=l.width+10,x=Math.ceil(v/(f+s))+1,y=void 0!==n?n:x,P=r.topBottomPadding+l.height+10+c+r.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;s+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,s+=`\n <div class="whatmore-shimmer-collections-flex-c" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-c::before,\n .whatmore-shimmer-collections-flex-c::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let c=0;c<l;c++)s+=`\n <div style="\n flex-shrink: 0;\n margin: 5px;\n ">\n <div style="\n width: fit-content;\n height: fit-content;\n border-radius: 10%;\n overflow: hidden;\n box-shadow: 0px 1px 1px 0px rgba(0, 0, 0, 0.1),\n 0px -1px 1px 0px rgba(0, 0, 0, 0.1),\n 1px 0px 1px 0px rgba(0, 0, 0, 0.1),\n -1px 0px 1px 0px rgba(0, 0, 0, 0.1),\n 1px -1px 1px 0px rgba(0, 0, 0, 0.1),\n -1px 1px 1px 0px rgba(0, 0, 0, 0.1),\n 1px 1px 1px 0px rgba(0, 0, 0, 0.1),\n -1px -1px 1px 0px rgba(0, 0, 0, 0.1);\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 10%;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `;return s+="\n </div>",s+="\n </div>",s+="\n </div>",s+="\n</div>",s}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,numberOfTiles:y});return{totalHeight:P,shimmerHTML:$}}function T(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:r*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s=r.collectionsTilesSpacing,c=b(l.width,r.extensionType),v="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,f=l.width+4,x=Math.ceil(v/(f+s))+1,y=void 0!==n?n:x,P=r.topBottomPadding+l.height+4+c+r.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;s+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,s+=`\n <div class="whatmore-shimmer-collections-flex-d" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-d::before,\n .whatmore-shimmer-collections-flex-d::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let c=0;c<l;c++)s+=`\n <div style="\n flex-shrink: 0;\n margin: 2px;\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 0%;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `;return s+="\n </div>",s+="\n </div>",s+="\n </div>",s+="\n</div>",s}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,numberOfTiles:y});return{totalHeight:P,shimmerHTML:$}}function S(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreExtensionType","index"),landingLocationType:t("whatmoreExtensionType","index")}}(t),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d,l;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,r=r*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=r*p;l=o.landscapePadding,r=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,i=r*e;l=o.landscapePadding,r=i,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize,c="mobilePortrait"===t||"tablet"===t;return{height:("22907887"===o.shopId||"79550939348"===o.shopId?c?.9:.83:1)*r*s*.01,width:d*s*.01,landscapePadding:l,unscaledWidth:d}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r}),s="68304765103"===r.shopId?"mobilePortrait"===d||"tablet"===d?6:20:r.collectionsTilesSpacing,c=x(r.heading,r.titleFontSize),f=("mobilePortrait"===d||"tablet"===d?r.videoTileSizePortrait:r.videoTileSize,function(e,t,i,n,o){var a,r,d,l,s;if(n.startsWith("product"))return 0;const c="mobilePortrait"===t||"tablet"===t,h=null!==(a=v(o,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==a?a:.022,p=null!==(r=v(o,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==r?r:.015,m=c?1.076*e*h:e*p,u=.9*m,g=Math.ceil(1.15*u),w=null===(d=v(o,"product_config->show_product_price"))||void 0===d||d,f=null===(l=v(o,"event_tile_with_product_info->show_price_info"))||void 0===l||l,x=.9*m,b=w&&f?Math.ceil(1.2*x):0,y=null!==(s=v(o,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==s&&s,_=c?10:12,P=Math.max(9,.75*m),$=y?_+Math.ceil(P):0;let T=0;return b>0&&T++,$>0&&T++,12+g+b+2+$+4*T}(l.unscaledWidth,d,r.shopId,r.landingLocationType,i)),b="desktop"===d||"mobileLandscape"===d?a-2*l.landscapePadding:a,y=l.width+4,P=Math.ceil(b/(y+s))+1,$=void 0!==n?n:P,T=r.topBottomPadding+c+l.height+4+f+r.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,landscapePadding:o,deviceMode:a,windowWidth:r,tilesSpacing:d,headingHeight:l,numberOfTiles:s,shopId:c,landingLocationType:h,unscaledWidth:p,customizations:m}=e,u=("73817522453"===c||"68304765103"===c||"16957273"===c)&&!h.startsWith("product"),g="68304765103"===c?"0px":"5%";let w=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${n}px; margin-bottom: ${n}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;l>0&&(w+=`\n <div style="display: flex; justify-content: center; align-items: center;">\n <div style="\n height: ${l-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),w+=`\n <div class="whatmore-shimmer-collections-grid" style="\n margin-left: ${o}px;\n margin-right: ${o}px;\n ">`,w+=`\n <div class="whatmore-shimmer-collections-flex-e" style="\n display: flex;\n gap: ${d}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-e::before,\n .whatmore-shimmer-collections-flex-e::after {\n content: '';\n margin: auto;\n }\n </style>`;for(let P=0;P<s;P++){if(w+=`\n <div style="\n flex-shrink: 0;\n margin: 2px;\n ">\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: ${g};\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,u){var f,x,b,y,_;const e="mobilePortrait"===a||"tablet"===a,t=null!==(f=v(m,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==f?f:.022,i=null!==(x=v(m,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==x?x:.015,n=e?1.076*p*t:p*i,o=e?4:8,r=6,d=4,l=.9*n,s=Math.ceil(1.15*l),c=null===(b=v(m,"product_config->show_product_price"))||void 0===b||b,h=null===(y=v(m,"event_tile_with_product_info->show_price_info"))||void 0===y||y,u=.9*n,g=Math.ceil(1.2*u),P=null!==(_=v(m,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==_&&_,$=e?10:12,T=Math.max(9,.75*n),S=2,z=$+Math.ceil(T);w+=`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${r}px ${o}px;\n gap: ${e?8:6}px;\n align-items: stretch;\n ">\n <div style="\n display: flex;\n flex-direction: column;\n gap: ${d}px;\n flex: 1;\n min-width: 0;\n ">\n \x3c!-- Title shimmer --\x3e\n <div style="\n min-height: ${s}px;\n height: ${s}px;\n width: 88%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,c&&h&&(w+=`\n \x3c!-- Price row shimmer --\x3e\n <div style="\n display: flex;\n gap: 8px;\n align-items: center;\n min-height: ${g}px;\n height: ${g}px;\n ">\n <div style="\n min-height: ${g}px;\n height: ${g}px;\n width: 35%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="\n min-height: ${g}px;\n height: ${g}px;\n width: 28%;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>`),P&&(w+=`\n \x3c!-- Button shimmer --\x3e\n <div style="\n min-height: ${z}px;\n height: ${z}px;\n width: 100%;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: ${S}px;\n position: relative;\n overflow: hidden;\n display: block;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`),w+="\n </div>\n </div>"}w+="\n </div>\n "}return w+="\n </div>",w+="\n </div>",w+="\n </div>",w+="\n</div>",w}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,tilesSpacing:s,headingHeight:c,numberOfTiles:$,shopId:r.shopId,landingLocationType:r.landingLocationType,unscaledWidth:l.unscaledWidth,customizations:i});return{totalHeight:T,shimmerHTML:S}}const z=function(e,t){return e<=768?t>e?"mobilePortrait":"mobileLandscape":e<=1024?"tablet":"desktop"};function I({tileWidth:e,tileHeight:t,numberOfTiles:i,headingHeight:n,topBottomPadding:o,landscapePadding:a,deviceMode:r,windowWidth:d,gap:l,productInfoHeight:s,customizations:c,liquidVars:h}){const p="mobilePortrait"===r||"tablet"===r;let m=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${o}px; margin-bottom: ${o}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;n>0&&(m+=`\n <div style="display: flex; justify-content: center; align-items: center; margin-bottom: 16px;">\n <div style="\n width: 200px;\n height: ${n-16}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n </div>\n `);const u=s>0?function(e,t,i,n,o){var a,r,d;const l="mobilePortrait"===t||"tablet"===t,s=null===(a=v(n,"product_config->show_product_price"))||void 0===a||a,c=null===(r=v(n,"event_tile_with_product_info->show_price_info"))||void 0===r||r,h=null!==(d=v(n,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==d&&d,p="76767920441"===o.shopId||"55840899223"===o.shopId,m=l?1.076*e*.04:.04*e;let u=null;if(p)if(l)u={width:.22*e,height:.29*e};else{const t=.25*e;u={width:1.2*t,height:1.6*t}}const g=`\n <div style="\n width: 85%;\n height: ${1.2*(l?1.076*e*.04:.04*e)}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `,w=s?`\n <div style="display: flex; gap: 8px; align-items: center; margin-top: 5px; flex-wrap: wrap;">\n \x3c!-- Price --\x3e\n <div style="\n width: 60px;\n height: ${1.2*m}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n \x3c!-- Compare Price --\x3e\n <div style="\n width: 50px;\n height: ${1.2*m}px;\n background: #e0e0e0;\n border-radius: 3px;\n opacity: 0.7;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n ${c?`\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 45px;\n height: ${1.2*m+6}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `:""}\n </div>\n `:"",f=h?`\n <div style="\n width: 90%;\n height: ${l?"36":"44"}px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: 8px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `:"";return`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${p&&l?"6px 4px":"12px 4px"};\n gap: ${p&&l?"4px":"12px"};\n align-items: stretch;\n ">\n ${p&&u?`\n <div style="\n flex-shrink: 0;\n display: flex;\n align-items: stretch;\n ">\n <div style="\n width: ${u.width}px;\n height: ${u.height}px;\n background: #e0e0e0;\n border-radius: 5px;\n margin-left: ${l?"0px":"-3px"};\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n </div>\n `:""}\n <div style="\n display: flex;\n flex-direction: column;\n gap: ${p&&l?"2px":"5px"};\n flex: 1;\n min-width: 0;\n ">\n ${g}\n ${w}\n ${f}\n </div>\n </div>\n `}(e,r,0,c,h):"";m+=`\n <div class="${p?"whatmore-shimmer-events-carousel-portrait":"whatmore-shimmer-events-carousel-landscape"}" style="\n display: flex;\n justify-content: ${p?"flex-start":"center"};\n align-items: center;\n ${p?"padding-left: 12px;":`padding-left: ${a}px; padding-right: ${a}px;`}\n position: relative;\n overflow: hidden;\n ">`,p||(m+=`\n \x3c!-- Left navigation button --\x3e\n <div style="\n position: absolute;\n left: ${a}px;\n top: 50%;\n transform: translateY(-50%);\n width: 50px;\n height: 100px;\n background: #e0e0e0;\n border-radius: 6px;\n z-index: 1;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n\n \x3c!-- Right navigation button --\x3e\n <div style="\n position: absolute;\n right: ${a}px;\n top: 50%;\n transform: translateY(-50%);\n width: 50px;\n height: 100px;\n background: #e0e0e0;\n border-radius: 6px;\n z-index: 1;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n `),m+=`\n <div style="display: flex; gap: ${l}px; overflow: hidden;">`;for(let g=0;g<i;g++)m+=`\n <div style="\n margin-top: 25px;\n margin-bottom: 10px;\n flex-shrink: 0;\n ">\n <div style="\n min-width: ${e}px;\n height: ${t}px;\n background: #e0e0e0;\n border-radius: 8px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation" style="background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent) !important;"></div>\n </div>\n ${u}\n </div>\n `;return m+="\n </div>",m+="\n </div>",m+="\n </div>",m+="\n</div>",m}function M(e){const{widgetContainer:t,customizations:i,eventCount:n}=e,[o,a]=_(t),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),tileSize:parseInt(t("whatmoreVideoTileSize","100")),tileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","100")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreLandingLocationType","index")}}(t),d=z(a,o),l=function({deviceMode:e,windowWidth:t,windowHeight:i,liquidVars:n,customizations:o}){var a;const r="mobilePortrait"===e||"tablet"===e?n.tileSizePortrait:n.tileSize,d=t>i,l="mobilePortrait"===e&&t>=481,s=r/100*1.3*.5,c=r/100,g=Math.min(t,i);let w=g*h*u,x=g*h,b=0,y=1.4;const _=null!==(a=v(o,"carousel_config->theme_margin"))&&void 0!==a?a:0;if(d){const e=x*s,i=w*s,o=n.landscapePadding||0;x=e,w=i,b=o,y=(t-2*o-2*_)/(1.1*e)}else if(l){let i=x*m,o=w*m;if("mobilePortrait"===e)i*=c,o*=c,x=i,w=o,b=0,y=f(t/(1.2*i));else{const e=n.landscapePadding||0;x=i,w=o,b=e,y=(t-2*e)/(1.1*i)}}else{let i=x,o=w;if("mobilePortrait"===e)i=i*c*.9,o=o*c*.9,x=i,w=o,b=0,y=f(t/(1.15*i));else{i=x*p,o=w*p;const e=n.landscapePadding||0;x=i,w=o,b=e,y=(t-2*e)/(1.1*i)}}return{height:w,width:x,landscapePadding:b,slidesPerView:y}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r,customizations:i}),s=Math.ceil(l.slidesPerView),c=void 0!==n?n:s,w=x(r.heading,r.titleFontSize),b=function(e,t=24){const i=v(e,"event_tile_config->gap_between_tiles");return null!==i&&void 0!==i?0===i?24:i:t}(i),y=function({tileWidth:e,deviceMode:t,customizations:i}){var n,o,a;if(!v(i,"event_tile_with_product_info->show_product_info"))return 0;const r="mobilePortrait"===t||"tablet"===t,d=null!==(n=v(i,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==n&&n,l=r?1.076*e*.04:.04*e,s=1.2*l+(null===(o=v(i,"product_config->show_product_price"))||void 0===o||o?1.2*l+5:0)+(null===(a=v(i,"event_tile_with_product_info->show_price_info"))||void 0===a||a?1.2*l+5:0)+(d?8+(r?36:44):0),c=d?110:s;return Math.round(Math.max(c,s+24))}({tileWidth:l.width,deviceMode:d,customizations:i}),P=r.topBottomPadding+w+25+l.height+y+10+r.topBottomPadding,$=I({tileWidth:l.width,tileHeight:l.height,numberOfTiles:c,headingHeight:w,topBottomPadding:r.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:a,windowHeight:o,gap:b,productInfoHeight:y,customizations:i,liquidVars:r});return{totalHeight:Math.round(P),shimmerHTML:$}}function k(e){const{customizations:t,widgetContainer:i,eventCount:n}=e,[o,a]=_(i),r=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),extensionType:t("whatmoreExtensionType","index")}}(i),d=w(a,o),l=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o}=e,a=Math.min(i,n);let r,d;if(r=a*h*u,d=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;r=r*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;r=r*m*e,d=d*m*e}else if("mobileLandscape"===t)o.videoTileSize,r*=p,d*=p;else{const e=o.videoTileSize/100*1.3*.5;r*=e,d*=e}return{height:r,width:d}}({deviceMode:d,windowWidth:a,windowHeight:o,liquidVars:r});function s(e){return Math.round(10*e)/10}let c;c="mobilePortrait"===d?s(a/(1.15*l.width)):"tablet"===d?s(a/(1.2*l.width)):a/(1.1*l.width);const f=parseInt(Math.floor(c)),x=function(e,t){if(!v(t,"event_tile_with_product_info->show_atc_button_template_feed"))return 0;const i=.07*e;return 46+Math.ceil(2.5*i)}(l.width,t),b=.2*l.height,y=20+(3+l.height+3)+x,P=Math.ceil(n/f),$=r.topBottomPadding+P*y+(P-1)*b+r.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:i,topBottomPadding:n,eventCount:o,slidesPerView:a,atcButtonHeight:r,rowSpacing:d}=e,l=a,s=Math.ceil(o/l);let c=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${n}px;\n margin-bottom: ${n}px;\n ">\n <div class="whatmore-carousel-events-feed" style="\n display: flex;\n flex-direction: column;\n align-items: center;\n width: 100%;\n gap: ${d}px;\n ">`;for(let h=0;h<s;h++){const e=Math.min(l,o-h*l);c+='\n <div class="whatmore-shimmer-feed-row" style="\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: flex-start;\n width: 100%;\n height: fit-content;\n gap: 0px;\n ">';for(let n=0;n<e;n++)c+=`\n <div style="margin: 10px;">\n <div class="whatmore-shimmer-tile-wrapper" style="\n display: flex;\n flex-direction: column;\n ">\n \x3c!-- Video tile --\x3e\n <div style="\n margin-top: 3px;\n margin-bottom: 3px;\n width: ${t}px;\n height: ${i}px;\n border-radius: 12px;\n background-color: #e0e0e0;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>`,r>0&&(c+=`\n <div style="\n width: ${t}px;\n padding: 15px 0;\n ">\n <div style="\n width: 100%;\n height: ${16+Math.ceil(.07*t)}px;\n background-color: #e0e0e0;\n border-radius: 12px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>`),c+="\n </div>\n </div>";c+="\n </div>"}return c+="\n </div>\n </div>",c}({tileWidth:l.width,tileHeight:l.height,topBottomPadding:r.topBottomPadding,eventCount:n,slidesPerView:f,atcButtonHeight:x,rowSpacing:b});return{totalHeight:Math.round($),shimmerHTML:T}}function H(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,[a,r]=_(i),d=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),l=w(r,a),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;s=2,c=0,d=d*e*.9,l=l*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:r,windowHeight:a,liquidVars:d,customizations:n}),c=Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(d.heading,d.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=d.topBottomPadding+y+25+s.height+25+d.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:i,numberOfTiles:n,headingHeight:o,topBottomPadding:a,landscapePadding:r,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c}=e,h="desktop"===d||"mobileLandscape"===d;let p=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${a}px; margin-bottom: ${a}px;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%;">`;if(o>0&&(p+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${o-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),p+=`\n <div class="${h?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ${h?`padding-left: ${r}px; padding-right: ${r}px;`:""}\n ">`,p+=`<div style="\n width: ${h?t*s*c+"px":l+"px"};\n height: fit-content;\n overflow: hidden;\n ">`,h){p+=`<div style="display: flex; gap: ${Math.round(t*c-t-20)}px; margin: 0 auto; width: max-content;">`;for(let e=0;e<n;e++)p+=`\n <div style="flex-shrink: 0; margin: 25px 10px 25px 10px;">\n \x3c!-- Template-G tile shimmer --\x3e\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `}else{const e=l/s;p+='<div style="display: flex;">';for(let o=0;o<n;o++)p+=`\n <div style="flex-shrink: 0; width: ${e}px;">\n <div style="margin: 25px 10px 25px 10px;">\n \x3c!-- Template-G tile shimmer --\x3e\n <div style="\n width: ${t}px;\n height: ${i}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ${o<s?"transform: scale(1.05);":""}\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `}return p+="\n </div>",p+="\n </div>",p+="\n </div>",p+="\n </div>",p+="\n</div>",p}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:r,slidesPerView:s.slidesPerView,widthMultiplier:P});return{totalHeight:Math.round($),shimmerHTML:T}}function B(e){var t,i;const{widgetContainer:n,customizations:o,eventCount:a}=e,[r,d]=_(n),l=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),s=w(d,r),c=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:r,liquidVars:l,customizations:o}),b=null!==(t=v(o,"event_tile_config->space_between_tiles"))&&void 0!==t?t:1,y=c.slidesPerView*b,P=Math.ceil(y),$=void 0!==a?a:P,T=x(l.heading,l.titleFontSize),S=null!==(i=v(o,"carousel_config->width_multiplier"))&&void 0!==i?i:1.1,z=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e,d=null!==(t=v(r,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,l="mobilePortrait"===a||"tablet"===a,s=.25*o*1.25,c=v(r,"event_tile_with_product_info->portrait_font_multiplier"),h=v(r,"event_tile_with_product_info->landscape_font_multiplier"),p=l?1.076*o*c:o*h,m=Math.ceil(1.2*p),u=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,g=u?Math.ceil(1.2*p):0,w=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,f=l?.965*o*c:.859*o*h;let x=0;u&&x++,w&&x++;const b=m+g+(w?Math.ceil(f)+6:0)+5*x,y=d?Math.max(s,b):b;return Math.round(24+y)}({tileWidth:c.width,deviceMode:s,customizations:o}),I="mobilePortrait"===s||"tablet"===s?c.height*S:c.height,M=l.topBottomPadding+T+12+I+z+12+l.topBottomPadding,k=function(e){var t,i,n;const{tileWidth:o,tileHeight:a,numberOfTiles:r,headingHeight:d,topBottomPadding:l,landscapePadding:s,deviceMode:c,windowWidth:h,slidesPerView:p,widthMultiplier:m,productInfoHeight:u,customizations:g}=e,w="desktop"===c||"mobileLandscape"===c;let f=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${l}px; margin-bottom: ${l}px; overflow: hidden;">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;d>0&&(f+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${d-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),f+=`\n <div class="${w?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ${w?`padding-left: ${s}px; padding-right: ${s}px;`:""}\n ">`,f+=`<div style="\n width: ${w?o*p*m+"px":h+"px"};\n max-width: 100%;\n height: fit-content;\n ${w?"overflow: hidden;":""}\n ">`;const x=null!==(t=v(g,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,b="mobilePortrait"===c||"tablet"===c,y=.25*o,_=null===(i=v(g,"product_config->show_product_price"))||void 0===i||i,P=null===(n=v(g,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,$=v(g,"event_tile_with_product_info->portrait_font_multiplier"),T=v(g,"event_tile_with_product_info->landscape_font_multiplier"),S=b?1.076*o*$:o*T,z=Math.ceil(1.2*S),I=Math.ceil(1.2*S),M=b?.965*o*$:.859*o*T,k=Math.ceil(M)+6,H=`\n <div style="cursor: pointer; display: flex; gap: 6px; padding: 12px 4px; width: 100%; box-sizing: border-box;">\n ${x?`\n \x3c!-- Thumbnail (conditional) --\x3e\n <div style="\n width: ${y}px;\n height: ${1.25*y}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n flex-shrink: 0;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `:""}\n \x3c!-- Product info (always shows) --\x3e\n <div style="display: flex; flex-direction: column; gap: 5px; flex: 1;">\n \x3c!-- Title --\x3e\n <div style="\n width: 85%;\n height: ${z}px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${_?`\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: ${I}px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 50px; height: ${I}px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `:""}\n ${P?`\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 50px;\n height: ${k}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n `:""}\n </div>\n </div>\n `,B=o,W=a*m,L=o,C=a;let V="";w||(V=`transform: translate3d(${-h/p/2}px, 0px, 0px);`);f+=`<div style="display: flex; gap: 0px; ${w?"margin: 0 auto; width: max-content;":V}">`;const E=w?r:3;for(let v=0;v<E;v++){const e=!w&&(0===v||2===v),t=!w&&1===v,i=t?B:e?L:o,n=t?W:e?C:a;f+=w?`\n <div style="flex-shrink: 0; width: ${o*p*m/p}px;">\n <div style="width: ${i}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${H}\n </div>\n </div>\n `:`\n <div style="flex-shrink: 0; width: ${h/p}px;">\n <div style="width: ${i}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${H}\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:$,headingHeight:T,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:y,widthMultiplier:S,productInfoHeight:z,customizations:o});return{totalHeight:Math.round(M),shimmerHTML:k}}function W(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,[a,r]=_(i),d=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),l=w(r,a),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;e*=1.3,t*=1.3,c=o.landscapePadding,s=5,d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e*1.3,i=d*e*1.3;c=o.landscapePadding,s=5,d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:r,windowHeight:a,liquidVars:d,customizations:n}),c="desktop"===l||"mobileLandscape"===l?5:Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(d.heading,d.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_with_product_info->show_thumbnail_image"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=.25*o,s=v(r,"event_tile_with_product_info->portrait_font_multiplier"),c=v(r,"event_tile_with_product_info->landscape_font_multiplier"),h=d?1.076*o*s:o*c,p=Math.ceil(1.2*h),m=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,u=m?Math.ceil(1.2*h):0,g=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,w=d?.965*o*s:.859*o*c;let f=0;m&&f++,g&&f++;const x=p+u+(g?Math.ceil(w)+6:0)+5*f,b=Math.max(l,x);return Math.round(24+b)}({tileWidth:"mobilePortrait"===l||"tablet"===l?s.width*P:s.width,deviceMode:l,customizations:n}),T="desktop"===l||"mobileLandscape"===l?24:12,S="mobilePortrait"===l||"tablet"===l?s.height*P:s.height,z=d.topBottomPadding+y+T+S+$+12+d.topBottomPadding,I=function(e){var t;const{tileWidth:i,tileHeight:n,numberOfTiles:o,headingHeight:a,topBottomPadding:r,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:p,customizations:m}=e,u="desktop"===l||"mobileLandscape"===l;let g=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${r}px;\n margin-bottom: ${r}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;a>0&&(g+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${a-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n margin-bottom: 16px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n `),g+=`<div class="${u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait"}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n ">`,g+=`<div style="\n width: ${s+"px"};\n height: fit-content;\n overflow: hidden;\n ">`;const w=u?24:12;let f="";if(null!==(t=v(m,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t&&p>0){var x,b;const e=.25*i;f=`\n <div style="display: flex; gap: 6px; padding: 12px 4px;">\n \x3c!-- Thumbnail --\x3e\n <div style="\n width: ${e}px;\n height: ${e}px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n flex-shrink: 0;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n \x3c!-- Product info --\x3e\n <div style="display: flex; flex-direction: column; gap: 5px; flex: 1;">\n \x3c!-- Title --\x3e\n <div style="\n width: 85%;\n height: 14px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${null===(x=v(m,"product_config->show_product_price"))||void 0===x||x?'\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: 14px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 50px; height: 14px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n ':""}\n ${null===(b=v(m,"event_tile_with_product_info->show_discount_label"))||void 0===b||b?'\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 50px;\n height: 18px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ':""}\n </div>\n </div>\n `}if(u){const e=[.6,.8,1,.8,.6],t=.65*i,o=s/2,a=(n+p)/2;g+=`<div style="display: flex; justify-content: center; align-items: center; position: relative; height: ${n+w+12+p}px;">`;for(let r=0;r<5;r++){const d=r-2,l=0===d,s=e[r],c=i*s,h=n*s;g+=`\n <div style="\n position: absolute;\n left: ${o+d*t-c/2}px;\n bottom: ${a-(h+(l?p:0))/2+12}px;\n z-index: ${5-Math.abs(d)};\n ${l?"":"filter: blur(2.5px) opacity(0.6);"}\n ">\n \x3c!-- Template-I tile shimmer --\x3e\n <div style="\n width: ${c}px;\n height: ${h}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${l?f:""}\n </div>\n `}g+="</div>"}else{const e=i,t=n,o=n*h;let a="";const r=s/c;a=`transform: translate3d(${-r/2}px, 0px, 0px);`,g+=`<div style="display: flex; gap: 0px; ${a}">`;const d=3;for(let i=0;i<d;i++)g+=`\n <div style="flex-shrink: 0; width: ${r}px;">\n <div style="width: ${e}px; margin: ${w}px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-I tile shimmer --\x3e\n <div style="\n width: ${e}px;\n height: ${1===i?o:t}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${f}\n </div>\n </div>\n `;g+="</div>"}return g+="</div>",g+="</div>",g+="</div>",g+="</div>",g}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:r,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:$,customizations:n});return{totalHeight:Math.round(z),shimmerHTML:I}}function L(e){var t;const{widgetContainer:i,customizations:n,eventCount:o}=e,a=function(e){const t=g(e);return{shopId:t("whatmoreShopId","demo-brand"),videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20")),landscapePadding:parseInt(t("whatmoreLandscapePadding","40")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(i),[r,d]=_(i),l=w(d,r),s=function(e){const{deviceMode:t,windowWidth:i,windowHeight:n,liquidVars:o,customizations:a}=e,r=Math.min(i,n);let d,l,s,c;if(d=r*h*u,l=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,n=d*e*.9;s=f(i/(1.15*t)),c=0,d=n,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,n=d*m*e;s=f(i/(1.2*t)),c=0,d=n,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(i-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,n=d*e;c=o.landscapePadding,s=(i-2*c-0)/(1.1*t),d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:d,windowHeight:r,liquidVars:a,customizations:n}),c=Math.ceil(s.slidesPerView),b=void 0!==o?o:c,y=x(a.heading,a.titleFontSize),P=null!==(t=v(n,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,$=function(e){var t,i,n;const{tileWidth:o,deviceMode:a,customizations:r}=e;if(null===(t=v(r,"event_tile_config->show_product_tile"))||void 0===t||!t)return 0;const d="mobilePortrait"===a||"tablet"===a,l=v(r,"event_tile_with_product_info->portrait_font_multiplier"),s=v(r,"event_tile_with_product_info->landscape_font_multiplier"),c=d?1.15*o*l:1.05*o*s,h=Math.ceil(1.2*c),p=d?1.2*o*l:1.1*o*s,m=null===(i=v(r,"product_config->show_product_price"))||void 0===i||i,u=m?Math.ceil(1.2*p):0,g=null===(n=v(r,"event_tile_with_product_info->show_discount_label"))||void 0===n||n,w=d?.8*o*l:.7*o*s;let f=0;f++,m&&f++,g&&f++;const x=9+h+u+(g?Math.ceil(w)+6:0)+4*f;return Math.round(20+x)}({tileWidth:s.width,deviceMode:l,customizations:n}),T="mobilePortrait"===l||"tablet"===l,S=T?16:32,z=y>0?T?12:16:0,I=T?16:0,M=s.height,k=a.topBottomPadding+S+y+z+I+0+0+M+$+0+a.topBottomPadding,H=function(e){var t;const{tileWidth:i,tileHeight:n,numberOfTiles:o,headingHeight:a,topBottomPadding:r,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:p,customizations:m}=e,u="desktop"===l||"mobileLandscape"===l,g="mobilePortrait"===l||"tablet"===l,w=u?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let f=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${r}px;\n margin-bottom: ${r}px;\n overflow: hidden;\n background: transparent;\n position: relative;\n padding: ${g?"8px 0":"16px 0"};\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: ${g?"visible":"hidden"};">`;a>0&&(f+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center; margin-bottom: ${g?12:16}px; position: relative; z-index: 1;">\n <div style="background: transparent; padding: 8px 24px; position: relative;">\n <div style="\n height: ${a-16}px;\n width: 200px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n </div>\n `);f+=g?`<div class="${w}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 0 24px;\n background: transparent;\n margin: 8px 0;\n position: relative;\n ">`:`<div class="${w}" style="\n display: flex;\n justify-content: center;\n align-items: center;\n padding-left: ${d}px;\n padding-right: ${d}px;\n ">`,f+=`<div style="\n width: ${u?i*Math.min(c,o)*h+"px":s-48+"px"};\n height: fit-content;\n overflow: ${g?"visible":"hidden"};\n position: relative;\n z-index: 1;\n ">`;let x="";var b,y;null!==(t=v(m,"event_tile_config->show_product_tile"))&&void 0!==t&&t&&p>0&&(x=`\n <div style="cursor: pointer; display: flex; flex-direction: column; gap: 4px; padding: 12px 0 8px 0; width: 100%; background: transparent;">\n \x3c!-- Product type label --\x3e\n <div style="\n width: 60%;\n height: 9px;\n background: #e0e0e0;\n border-radius: 2px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n \x3c!-- Title --\x3e\n <div style="\n width: 90%;\n height: 14px;\n background: #e0e0e0;\n border-radius: 3px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${null===(b=v(m,"product_config->show_product_price"))||void 0===b||b?'\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 8px; align-items: center;">\n <div style="width: 70px; height: 16px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n <div style="width: 60px; height: 16px; background: #e0e0e0; border-radius: 3px; position: relative; overflow: hidden; opacity: 0.7;">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n ':""}\n ${null===(y=v(m,"event_tile_with_product_info->show_discount_label"))||void 0===y||y?'\n \x3c!-- Discount badge --\x3e\n <div style="\n width: 55px;\n height: 20px;\n background: #e0e0e0;\n border-radius: 4px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ':""}\n </div>\n `);if(g){var _;const e=s-48,t=12,o=c*(null!==(_=v(m,"event_tile_config->space_between_tiles"))&&void 0!==_?_:1),a=(e-(o-1)*t)/o;f+=`<div style="display: flex; transform: translate3d(${e/2-(a+t+a/2)}px, 0px, 0px);">`;const r=3,d=1.02,l=.98;for(let s=0;s<r;s++){const e=0===s||2===s;f+=`\n <div style="\n width: ${a}px;\n flex-shrink: 0;\n margin-right: ${s<r-1?t:0}px;\n display: flex;\n justify-content: flex-start;\n ">\n <div style="\n margin: 0px 0 0px 0;\n transform: scale(${1===s?d:l});\n transition: transform 0.3s ease-out;\n filter: ${e?"brightness(0.9)":"none"};\n opacity: ${e?"0.85":"1"};\n ">\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 0px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${x}\n </div>\n </div>\n `}}else{const e=i*h;f+='<div style="display: flex;">';for(let t=0;t<o;t++)f+=`\n <div style="\n width: ${e}px;\n flex-shrink: 0;\n display: flex;\n justify-content: flex-start;\n height: 100%;\n ">\n <div style="\n height: 100%;\n transform: translate3d(0px, 0px, 0px);\n transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 0.3s ease-out, opacity 0.3s ease-out;\n filter: none;\n opacity: 0.98;\n will-change: transform, filter, opacity;\n ">\n <div style="\n width: ${i}px;\n margin: 0px 0 0px 0;\n cursor: pointer;\n display: flex;\n flex-direction: column;\n align-items: stretch;\n justify-content: flex-start;\n background: transparent;\n position: relative;\n ">\n <div style="\n width: ${i}px;\n height: ${n}px;\n background: #e0e0e0;\n border-radius: 0px;\n position: relative;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n ${x}\n </div>\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:b,headingHeight:y,topBottomPadding:a.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:d,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:$,customizations:n});return{totalHeight:Math.round(k),shimmerHTML:H}}function C(e,t){if(!e)return null;const i=t.split("->");let n=e;for(const o of i){if(!n||"object"!==typeof n||!(o in n))return null;n=n[o]}return n}function V(e){var t;const{customizations:i,widgetContainer:n,eventCount:o}=e,[a,r]=_(n),d=function(e){const t=g(e);return{videoTileSize:parseInt(t("whatmoreVideoTileSize","60")),videoTileSizePortrait:parseInt(t("whatmoreVideoTileSizePortrait","60")),landscapePadding:parseInt(t("whatmoreLandscapePadding","0")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),topBottomPadding:parseInt(t("whatmoreTopBottomPadding","20"))}}(n),l=a>r?"portrait":"landscape",s="portrait"===l?d.videoTileSizePortrait:d.videoTileSize,{WIDTH:c,HEIGHT:h,isPortrait:p}=function(e,t,i){const n=e>t,o=t>e,a=!(!o||!(e>=481)),r=.8,d=i/100*1.3*.5,l=i/100,s=Math.min(e,t);let c=.6*s,h=.6*s*(16/9);return n?(c*=d,h*=d):a?o?(c=c*r*l,h=h*r*l):(c*=r,h*=r):o?(c=c*l*.9,h=h*l*.9):(c*=.7,h*=.7),{WIDTH:c,HEIGHT:h,isPortrait:o}}(r,a,s),m="portrait"===l?0:d.landscapePadding,u=d.collectionsTilesSpacing,v=c*s*.01,w=C(i,"collections_config->story_tile_size_factor")||1,f=null!==(t=C(i,"collections_config->story_tile_shape"))&&void 0!==t?t:"circle",x=C(i,"collections_config->remove_borders"),b=parseInt(C(i,"collections_config->tile_margin_right"))||0,y=x?2:b||0,P=x?2:5,$=x?2:5,T="circle"===f?"50%":"6%",S=v*w,z="rectangle"===f?1.5*S:S,I=S,M=.8*(.055*c),k=P+z+10+$,H=2*d.topBottomPadding+k,B=r-2*m,W=I+y,L=Math.min(Math.ceil((B+u)/(W+u)),8),V=void 0!==o?o:L,E="landscape"===l?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let j=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${d.topBottomPadding}px;\n margin-bottom: ${d.topBottomPadding}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">\n <div class="${E}" style="\n margin-left: ${m}px;\n margin-right: ${m}px;\n ">\n <div class="whatmore-shimmer-collections-flex-stories" style="\n display: flex;\n flex-direction: row;\n gap: ${u}px;\n overflow: hidden;\n ">\n <style>\n .whatmore-shimmer-collections-flex-stories::before,\n .whatmore-shimmer-collections-flex-stories::after {\n content: '';\n margin: auto;\n }\n </style>\n `;for(let g=0;g<V;g++)j+=`\n <div style="\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n flex-shrink: 0;\n margin-right: ${y}px;\n margin-top: ${P}px;\n margin-bottom: ${$}px;\n ">\n \x3c!-- Border/shadow wrapper --\x3e\n <div class="whatmore-story-tile-border-wrapper" style="\n display: flex;\n flex-direction: column;\n justify-content: center;\n flex-shrink: 0;\n border-radius: ${T};\n overflow: hidden;\n ">\n \x3c!-- Tile with visible border --\x3e\n <div class="whatmore-shimmer-tile whatmore-story-tile-inner" style="\n flex-shrink: 0;\n height: ${z}px;\n width: ${S}px;\n border-radius: ${T};\n background-color: #e0e0e0;\n overflow: hidden;\n border: 3px solid #d0d0d0;\n box-sizing: border-box;\n ">\n <div class="whatmore-shimmer-animation"></div>\n </div>\n </div>\n \x3c!-- Empty title div --\x3e\n <div style="\n display: flex;\n justify-content: center;\n width: ${I}px;\n padding-top: 10px;\n font-size: ${M}px;\n ">\n <p style="margin: 0; padding: 0; line-height: 0; height: 0;"></p>\n </div>\n </div>\n `;return j+="\n </div>\n </div>\n </div>\n </div>",{totalHeight:Math.round(H),shimmerHTML:j}}var E;const j=null!==(E="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==E&&E;function q(e,t,i,n){var o,a;const r=e<=t,d=parseInt(((e,t)=>{const i=document.querySelector(`#${e}`);return i&&(i.getAttribute("data-wh")||i.getAttribute("data"))||t})("whatmoreVideoTileSize","60")),l=v(i,"banner_config->portrait_multiplier"),s=v(i,"banner_config->landscape_multiplier"),c=d/100*(null!==l&&void 0!==l?l:1),h=d/100*(null!==s&&void 0!==s?s:1),p=r?null!==(o=v(i,"banner_config->portrait_aspect_ratio"))&&void 0!==o?o:1:null!==(a=v(i,"banner_config->landscape_aspect_ratio"))&&void 0!==a?a:.5625,m=r?e*c:e*h,u=v(i,"banner_config->is_full_screen")||!1,g=u?e*p:m*p;return{width:u?"100%":`${m}px`,height:`${g}px`,borderWidth:v(i,"theme_config->event_tile->border_width")||"0px",borderColor:v(i,"theme_config->event_tile->border_color")||"transparent",borderStyle:"solid",totalHeight:g}}function O(e){const{windowWidth:t,windowHeight:i,customizations:n,widgetContainer:o,widgetIdentity:a}=e,r=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const i=t[e];return i?i.tc:null}return t.tc||null}(a);if(null===r||void 0===r||0===r)return j&&console.log("[Banner Shimmer] No event count found, returning null"),null;const d=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const i=t[e];return i?{landscape:i.landscape_poster||null,portrait:i.portrait_poster||null}:null}return{landscape:t.landscape_poster||null,portrait:t.portrait_poster||null}}(a);if(!d||!d.landscape&&!d.portrait)return j&&console.log("[Banner Shimmer] No poster URLs found"),null;const l=q(t,i,n),s=t<=i?d.portrait:d.landscape;if(!s)return j&&console.log("[Banner Shimmer] No poster URL for current orientation"),null;v(n,"banner_config->is_full_screen");const c=`\n <div class="whatmore-banner-shimmer-wrapper" style="\n position: relative;\n margin: 0 auto;\n width: ${l.width};\n height: ${l.height};\n border-width: ${l.borderWidth};\n border-color: ${l.borderColor};\n border-style: ${l.borderStyle};\n overflow: hidden;\n background: linear-gradient(135deg, #c0c0c0 0%, #d0d0d0 25%, #e0e0e0 50%, #d0d0d0 75%, #c0c0c0 100%);\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);\n ">\n <img\n src="${s}"\n alt="Loading preview"\n class="whatmore-banner-shimmer-poster"\n style="\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n opacity: 1;\n "\n />\n <div class="whatmore-banner-shimmer-overlay" style="\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.05) 100%);\n background-size: 200% 100%;\n animation: whatmore-banner-shimmer-wave 2.5s ease-in-out infinite;\n "></div>\n </div>\n `;return{totalHeight:l.totalHeight,shimmerHTML:c}}function A(e){return g(e)("whatmoreShopId",null)}function F(){return window.location.href.split(/[?#]/)[0]}function R(e,t,i,n){const o=A(e);if("index"===t&&"carousel"===i)return"homepage";if(t&&t.startsWith("product")){return v(n,"show_homepage_videos_in_pdp")?"homepage":function(e){return g(e)("whatmoreProductId",null)}(e)}if("collection"===i){let t;return"19506115"===o?t="343270603":v(n,"collections_config->use_page_link_as_collection_id")?t=v(n,"collections_config->multi_carousel_enabled")?function(e){return g(e)("whatmoreCollectionUrl",null)}(e):F():(t=function(e){return g(e)("whatmoreCollectionId",null)}(e),"0"===t&&(t=function(e){return g(e)("whatmorePageId",null)}(e)),t&&"0"!==t||(t=F())),t}return"carousel"===i?"homepage":null}function D(e,t){const i=A(e),n=function(e){return g(e)("whatmoreExtensionType",null)}(e),o=function(e){return e.querySelector('.whatmore-template-type[data-wh="template-banner-a"]')||e.querySelector('.whatmore-template-type[data="template-banner-a"]')?"banner":e.querySelector('[data-wh="collection"]')||e.querySelector('[data="collection"]')?"collection":e.querySelector('[data-wh="carousel"]')||e.querySelector('[data="carousel"]')?"carousel":null}(e),a=function(e){const t=["template-a","template-b","template-c","template-d","template-e","template-f","template-g","template-h","template-i","template-j","template-feed-a","template-a-1","template-stories","template-collections-a","template-collections-b","template-collections-c","template-collections-d","template-collections-e","template-collections-f","template-collections-g","template-collections-h","template-collections-i","template-collections-j","template-collections-stories","template-banner-a"];for(const i of t)if(e.querySelector(`.whatmore-template-type[data-wh="${i}"]`)||e.querySelector(`.whatmore-template-type[data="${i}"]`))return i;return null}(e),r=R(e,n,o,t),d=function(e){return g(e)("whatmoreWidgetIdentity","wgt_default")}(e);return{shopId:i,landingLocationType:n,widgetType:o,templateType:a,actualId:r,widgetIdentity:d,isValidId:(l=r,!(!l||null===l||"null"===l||""===l)&&/^\d+$/.test(String(l))||"homepage"===r)};var l}var N,U=n(3782);const Y=null!==(N="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==N&&N;function G(e,t,i){const n=window.whatmorePdpCarouselEvents;if(!n)return null;if(t&&"wgt_default"!==t){var o;const a=t.split("_");if(a.length<2||!a[1])return null;const r=null===(o=n[`w_${a[1][0]}`])||void 0===o?void 0:o[t];if(!r)return null;const d=r.scope_mode||"all",l=r.scope_targets||[],s=String(e);let c=!1;if("all"===d?c=!0:"include"===d?c=l.includes(s):"exclude"===d&&(c=!l.includes(s)),!c)return null;return v(i,"show_out_of_stock_videos")?r.etc:r.esc}{var a;const t=function(e){return"p_"+parseInt(e)%127}(e),o=null===(a=n[t])||void 0===a?void 0:a[e];if(!o)return null;return v(i,"show_out_of_stock_videos")?o.etc:o.esc}}function K(e,t,i){var n,o;const a=null===(n=window.whatmore)||void 0===n?void 0:n.collectionMetafields;if(!a)return null;const r=function(e){return"c_"+parseInt(e)%63}(e);let d=e;t&&"wgt_default"!==t&&(d=`${e}_${t}`);const l=null===(o=a[r])||void 0===o?void 0:o[d];if(!l)return null;return v(i,"show_out_of_stock_videos")?l.tc:l.sc}function J(e,t,i,n,o,a){var r;if(!(null===(r=v(a,"shimmer_config->enable_shimmer"))||void 0===r||r))return Y&&console.log("[Shimmer] Disabled via customization"),null;if(null!==U.A)return Y&&console.log(`[Shimmer] TEST MODE: Using hardcoded count ${U.A}`),U.A;if(!i||""===i||"undefined"===i||"null"===i)return Y&&console.log("[Shimmer] No valid ID provided"),null;let d=null;return"homepage"===i?d=function(e,t){const i=window.whatmoreHomepageCarouselEvents;if(!i)return null;if(e&&"wgt_default"!==e){const n=i[e];return n?v(t,"show_out_of_stock_videos")?n.tc:n.sc||n.tc:null}return v(t,"show_out_of_stock_videos")?i.tc:i.sc}(n,a):t&&t.startsWith("product")?d=G(i,n,a):"collection"===e&&(d=K(i,n,a)),null===d||void 0===d||0===d?(Y&&console.log(`[Shimmer] Event count is ${d}, skipping shimmer`),null):(Y&&console.log(`[Shimmer] Found event count: ${d} for ${e}/${t}/${i}/${n}`),d)}var X,Z,Q,ee,te,ie,ne,oe,ae=n(964);const re=Array.from(document.getElementsByClassName("whatmore-base")),de=null!==(X="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==X&&X,le=function(e){return"template-banner-a"===e},se=function(e){return"template-collections-a"==e||"template-collections-b"==e||"template-collections-c"==e||"template-collections-d"==e||"template-collections-e"==e||"template-collections-stories"==e||"template-collections-f"==e||"template-collections-g"==e||"template-collections-h"==e||"template-collections-i"==e||"template-collections-feed-a"==e||"template-collections-j"==e||"template-collections-a-1"==e},ce=function(e){return"template-stories-a"===e||"template-stories-b"===e};function he(e,t){const i=document.getElementById(e);if(!i)return t;return i.getAttribute("data-wh")||i.getAttribute("data")||t}function pe(e,t,i,n,o){var a;if("template-embed"===i)return;if("60595503283"===ue)return;if(!(null===(a=l(n,"shimmer_config->enable_shimmer"))||void 0===a||a))return;const r=function(e){return{"template-collections-a":"template-c","template-collections-b":"template-d","template-collections-c":"template-e","template-collections-d":"template-b","template-collections-e":"template-a","template-collections-f":"template-f","template-collections-feed-a":"template-feed-a","template-collections-g":"template-g","template-collections-h":"template-h","template-collections-i":"template-i","template-collections-j":"template-j","template-collections-stories":"template-stories"}[e]||e}(i),[d,s]=_(t);try{const a=function(e){const{templateType:t,widgetContainer:i,customizations:n}=e,o=D(i,n);if("template-banner-a"===t)return e.widgetIdentity=o.widgetIdentity,O(e);const a=J(o.widgetType,o.landingLocationType,o.actualId,o.widgetIdentity,0,n);return null===a?null:(e.eventCount=a,"template-a"===t?y(e):"template-b"===t?P(e):"template-c"===t?$(e):"template-d"===t?T(e):"template-e"===t?S(e):"template-f"===t?M(e):"template-feed-a"===t?k(e):"template-g"===t?H(e):"template-h"===t?B(e):"template-i"===t?W(e):"template-j"===t?L(e):"template-stories"===t?V(e):null)}({templateType:r,widgetContainer:t,customizations:n,windowWidth:s,windowHeight:d});if(a&&a.totalHeight&&a.shimmerHTML){if(!document.getElementById("whatmore-shimmer-styles")){const e=document.createElement("style");e.id="whatmore-shimmer-styles",e.textContent="\n@keyframes whatmore-shimmer-wave {\n 0% { transform: translateX(-100%); }\n 100% { transform: translateX(100%); }\n}\n\n@keyframes whatmore-banner-shimmer-wave {\n 0% { background-position: 200% 0; }\n 100% { background-position: -200% 0; }\n}\n\n@keyframes whatmore-banner-shimmer-pulse {\n 0%, 100% { opacity: 0.3; }\n 50% { opacity: 0.5; }\n}\n\n/* Pixel-accurate shimmer */\n.whatmore-pixel-shimmer-container {\n width: 100%;\n overflow: hidden;\n}\n\n.whatmore-shimmer-heading {\n position: relative;\n overflow: hidden;\n}\n\n.whatmore-shimmer-tiles-row {\n display: flex;\n gap: 12px;\n overflow: hidden;\n}\n\n.whatmore-shimmer-tile-wrapper {\n flex-shrink: 0;\n}\n\n.whatmore-shimmer-tile {\n position: relative;\n overflow: hidden;\n}\n\n.whatmore-shimmer-product-info {\n margin-top: 8px;\n}\n\n.whatmore-shimmer-animation {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);\n animation: whatmore-shimmer-wave 1.5s infinite;\n}\n",document.head.appendChild(e)}t.style.setProperty("position","relative","important"),t.style.setProperty("height","auto","important"),t.style.setProperty("border-top","0.1px solid transparent","important"),t.style.minHeight=a.totalHeight+"px";const n=document.createElement("div");n.className="whatmore-shimmer-container",n.setAttribute("data-template",i),n.setAttribute("data-widget-id",o),n.style.cssText="position: absolute; top: 0; left: 0; width: 100%; height: auto; z-index: 2; transition: opacity 0.1s ease;",n.innerHTML=a.shimmerHTML,t.insertBefore(n,e),e.style.cssText="opacity: 0; z-index: 1; transition: opacity 0.3s ease;",e.setAttribute("data-shimmer-active","true"),e.setAttribute("data-widget-id",o)}}catch(c){console.error(`[${(new Date).toLocaleTimeString()}] Error calculating shimmer for ${i}:`,c)}}const me=null!==document.getElementById("whatmoreRoot"),ue=he("whatmoreShopId",ae.YZ),ge=he("whatmoreExtensionType","index"),ve=null!==(Z=(null===(Q=window)||void 0===Q||null===(ee=Q.Shopify)||void 0===ee||null===(te=ee.theme)||void 0===te?void 0:te.role)&&"main"!==(null===(ie=window)||void 0===ie||null===(ne=ie.Shopify)||void 0===ne||null===(oe=ne.theme)||void 0===oe?void 0:oe.role))&&void 0!==Z&&Z,we=("2665447536"==ue||"72201044272"==ue)&&null!=localStorage.getItem("w_user_type"),fe=function(){const e=r("wtt"),t=r("weid");return null!=e&&null!=t}();!async function(){const e=await s(ue);if(null!==e&&void 0!==e&&e.brand_custom_css){const t=document.createElement("style");t.innerHTML=e.brand_custom_css,document.head.appendChild(t)}if(!me&&re&&re.length>0)for(let s=0;s<re.length;s++){var t,i,o,a,r,d,l,h,p,m;const M=re[s],k=M.querySelector(".whatmore-render-root"),H=M.querySelector(".whatmore-template-type");let B=!1,W=!1,L=!1;const C=null!==(t=null!==(i=null===H||void 0===H?void 0:H.getAttribute("data-wh"))&&void 0!==i?i:null===H||void 0===H?void 0:H.getAttribute("data"))&&void 0!==t?t:"template-embed";ce(C)?B=!0:se(C)?W=!0:le(C)&&(L=!0);let V="",E="";var u,g,v,w,f,x,b,y,_,P,$;if(W)if(V=null!==(u=null!==(g=null===(v=M.querySelector("#whatmoreCollectionId"))||void 0===v?void 0:v.getAttribute("data-wh"))&&void 0!==g?g:null===(w=M.querySelector("#whatmoreCollectionId"))||void 0===w?void 0:w.getAttribute("data"))&&void 0!==u?u:"",E=null!==(f=null!==(x=null===(b=M.querySelector("#whatmoreCollectionHeading"))||void 0===b?void 0:b.getAttribute("data-wh"))&&void 0!==x?x:null===(y=M.querySelector("#whatmoreCollectionHeading"))||void 0===y?void 0:y.getAttribute("data"))&&void 0!==f?f:"","0"==V)V=null!==(_=null===(P=M.querySelector("#whatmorePageId"))||void 0===P?void 0:P.getAttribute("data-wh"))&&void 0!==_?_:null===($=M.querySelector("#whatmorePageId"))||void 0===$?void 0:$.getAttribute("data");const j=null!==(o=null!==(a=null===(r=M.querySelector("#whatmoreHeading"))||void 0===r?void 0:r.getAttribute("data-wh"))&&void 0!==a?a:null===(d=M.querySelector("#whatmoreHeading"))||void 0===d?void 0:d.getAttribute("data"))&&void 0!==o?o:"",q=null!==(l=null!==(h=null===(p=M.querySelector("#whatmoreWidgetIdentity"))||void 0===p?void 0:p.getAttribute("data-wh"))&&void 0!==h?h:null===(m=M.querySelector("#whatmoreWidgetIdentity"))||void 0===m?void 0:m.getAttribute("data"))&&void 0!==l?l:"wgt_default",O="whatmoreRoot"+s;if("template-embed"===C&&(null===ge||void 0===ge||!ge.startsWith("product"))&&(null===ge||void 0===ge||!ge.startsWith("collection"))){var T,S,z,I;const t=null===e||void 0===e||null===(T=e.spotlight_config)||void 0===T?void 0:T.enable_spotlight,i=null===e||void 0===e||null===(S=e.spotlight_config)||void 0===S?void 0:S.enable_in_homepage,n=null===e||void 0===e||null===(z=e.spotlight_config)||void 0===z?void 0:z.enable_all_pages,o=(null===e||void 0===e||null===(I=e.spotlight_config)||void 0===I?void 0:I.enable_page_id_set)||[];if(!(t&&(i&&ge.includes("index")||V&&o.includes(V)||n)))continue}pe(k,M,C,e,O);const A=c(e,W,fe,C,ge),F=()=>{Promise.all([n.e(305),n.e(268)]).then(n.bind(n,1592)).then(e=>{e.initializeReactApp({rootElement:k,templateType:C,isStoriesTemplate:B,isCollectionsTemplate:W,_isTemplateTypeBanner:L,whatmoreCollectionId:V,whatmoreCollectionHeading:E,whatmoreHeadingCarousel:j,whatmoreWidgetIdentity:q,whatmoreRootId:O,landingLocationType:ge,isInPreviewMode:ve,userType:we})}).catch(e=>{console.error("Whatmore: Failed to load React chunk:",e);const t=document.querySelector(`.whatmore-shimmer-container[data-widget-id="${O}"]`);t&&(t.remove(),de&&console.log(`[Chunk Error] Removed shimmer for widget ${O}`)),M&&(M.style.minHeight="0px",de&&console.log(`[Chunk Error] Reset minHeight to 0px for widget ${O}`)),k&&(k.style.opacity="0",k.removeAttribute("data-shimmer-active"))})};if(A){let e=!1;const t=()=>{e||(e=!0,F())},i=new IntersectionObserver(e=>{e.forEach(e=>{de&&console.log(`[OBSERVER] Widget ${s}: isIntersecting=${e.isIntersecting}, top=${e.boundingClientRect.top}, bottom=${e.boundingClientRect.bottom}, viewportHeight=${window.innerHeight}`),e.isIntersecting&&(de&&console.log(`[OBSERVER] Widget ${s}: Loading React chunk`),t(),i.disconnect())})},{threshold:0,rootMargin:"0px 0px 0px 0px"});i.observe(M);const n=M.getBoundingClientRect();de&&console.log(`[SETUP] Widget ${s}: Observer attached, position top=${n.top}, bottom=${n.bottom}, viewportHeight=${window.innerHeight}, margin=500px`);const o=10;let a=window.pageYOffset;de&&console.log(`[SCROLL LISTENER] Widget ${s}: Initial scroll position=${a}`);const r=()=>{const e=window.pageYOffset,i=Math.abs(e-a);de&&console.log(`[SCROLL LISTENER] Widget ${s}: Scroll event fired, scrollY=${e}, lastScrollY=${a}, delta=${i}`),i>o&&(de&&console.log(`[SCROLL LISTENER] Widget ${s}: Delta > ${o}, triggering load`),t(),window.removeEventListener("scroll",r))};window.addEventListener("scroll",r,{passive:!0})}else F()}else if(me){const e=document.getElementById("whatmoreRoot"),t="whatmoreRoot",i=he("whatmoreTemplateType","invalid-template"),o=ce(i),a=se(i),r=le(i);Promise.all([n.e(305),n.e(268)]).then(n.bind(n,1592)).then(n=>{n.initializeReactApp({rootElement:e,templateType:i,isStoriesTemplate:o,isCollectionsTemplate:a,_isTemplateTypeBanner:r,whatmoreCollectionId:"",whatmoreCollectionHeading:"",whatmoreHeadingCarousel:"",whatmoreWidgetIdentity:"wgt_default",whatmoreRootId:t,landingLocationType:ge,isInPreviewMode:ve,userType:we})}).catch(e=>{console.error("Whatmore: Failed to load React chunk for legacy store:",e)})}}()}();