whatmore-react-assets 1.0.1830 → 1.0.1832

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,2 +1,2 @@
1
- /*! For license information please see main.91c7b967.js.LICENSE.txt */
2
- !function(){"use strict";var e,t={964:function(e,t,n){n.d(t,{$$:function(){return o},DK:function(){return u},Dk:function(){return s},K1:function(){return c},MT:function(){return a},OL:function(){return h},Sx:function(){return g},TB:function(){return m},YZ:function(){return i},aD:function(){return r},mM:function(){return l},qW:function(){return d},rz:function(){return p}});const i="58669793418",o="https://consumer.whatmore.live",r="https://whatmore-api-cdn-cache.azureedge.net",a="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"},1578:function(e,t,n){n.d(t,{S:function(){return d}});var i=n(2089),o=n(4533),r=n(7714),a=n(9211);const d=function(){const e=(0,o.wm)(),t=(0,o.zv)(),n=navigator.userAgent,d=(0,r.R)();let l;const s=localStorage.getItem("wht_show_carousel");var c;"75310563627"===d&&null!==s?l="true"===s?"jockey-test-group":"jockey-control-group":l=null!==(c=localStorage.getItem("wht_user_group"))&&void 0!==c?c:"";return{user_id:e,session_id:t,user_group:l,user_agent:n,store_id:d,hostname:window.location.hostname,page_path:window.location.pathname,event_id:(0,i.Ak)(),event_timestamp:Math.round((new Date).getTime()/1e3),shopify_session_id:function(){var e;return null!==(e=a.A.get("_shopify_s"))&&void 0!==e?e:""}(),shopify_user_id:function(){var e;return null!==(e=a.A.get("_shopify_y"))&&void 0!==e?e:""}()}}},2089:function(e,t,n){n.d(t,{Ak:function(){return i}});let i=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce((e,t)=>e+=(t&=63)<36?t.toString(36):t<62?(t-26).toString(36).toUpperCase():t>62?"-":"_","")},3782:function(e,t,n){n.d(t,{A:function(){return i},H:function(){return o}});const i=n(964).mM?4:null;function o(e){if(!e||0===e.length)return e;if(null!==i){return e.slice(0,i)}return e}},3924:function(e,t,n){n.d(t,{Z:function(){return m},$:function(){return p}});var i=n(4901);const o=function(e,t){const n={metric_event_list:e},o=void 0!==t?t:e.length<10;return(0,i.d)(n,o)},r="_whatmore_bulk_events",a=9,d=9e3;let l=null,s=!1;function c(){try{return JSON.parse(localStorage.getItem(r))||[]}catch(e){return[]}}function h(){null===l&&0!==c().length&&(l=setTimeout(()=>{l=null,p()},d))}function p(e){if(s&&!e)return Promise.resolve();const t=c();if(0===t.length)return Promise.resolve();s=!0,null!==l&&(clearTimeout(l),l=null);const n=new Set(t.map(e=>e.event_id));return o(t,e).then(()=>{const e=c().filter(e=>!n.has(e.event_id));e.length>0?localStorage.setItem(r,JSON.stringify(e)):localStorage.removeItem(r)}).catch(()=>{}).finally(()=>{s=!1,h()})}function m(e){const t=c();t.push(e),localStorage.setItem(r,JSON.stringify(t)),t.length>=a?p():h()}},4533:function(e,t,n){n.d(t,{CK:function(){return S},Ch:function(){return P},Fu:function(){return y},Hm:function(){return T},NF:function(){return $},d3:function(){return z},wm:function(){return _},zv:function(){return b}});var i=n(2089),o=n(7714),r=n(3924);const a="_whatmore_user_id",d="_whatmore_session_id",l="_whatmore_viewed_products",s="_whatmore_add_to_cart_products",c="_whatmore_session_time",h="_whatmore_store_id",p="_whatmore_qview_index",m="_whatmore_brand_questions",u="_whatmore_seen_questions",g="w_user_type",v=(0,o.R)(),w=18e5,f=2592e5,x=6e5;function _(){localStorage.getItem(h)!=v&&localStorage.setItem(h,v),null==localStorage.getItem(a)&&function(){new Date;const e=(0,i.Ak)();localStorage.setItem(a,e)}();const e=new Date,t=localStorage.getItem(c);return null==t?localStorage.setItem(g,"newuser"):null!==t&&e.getTime()>t&&localStorage.setItem(g,"olduser"),localStorage.getItem(a)}function b(){const e=new Date,t=localStorage.getItem(c);return(null==localStorage.getItem(d)||null==t||e.getTime()>t)&&(localStorage.removeItem(d),localStorage.removeItem(c),function(){const e=(0,i.Ak)(),t=(new Date).getTime()+w;localStorage.setItem(d,e),localStorage.setItem(c,t)}(),(0,r.$)()),localStorage.getItem(d)}function y(e,t,n,i,o){const r=(new Date).getTime(),a={event_id:e.event_id,product_id:t.client_product_id,product_title:t.title,price:t.price,timestamp:r,widget_info:n,location:i,user_type:o?"olduser":"newuser",variants:[]};if(null===localStorage.getItem(s))localStorage.setItem(s,JSON.stringify([a]));else{let e=JSON.parse(localStorage.getItem(s)).filter(e=>e.timestamp+f>r);localStorage.setItem(s,JSON.stringify([...e,a]))}}function P(e,t,n,i,o,r="default",a){const d=[],s=(new Date).getTime();if(localStorage.setItem("_whatmore_last_video_view_session",b()),t.map(t=>{const l={event_id:e,product_id:t.client_product_id,product_title:t.title,price:t.price,timestamp:s,variants:[],page:n,widget_type:i,widget_info:o,location:r,user_type:a?"olduser":"newuser"};d.push(l)}),null===localStorage.getItem(l))console.debug("viewed Products",JSON.stringify(d)),localStorage.setItem(l,JSON.stringify(d));else{let t=JSON.parse(localStorage.getItem(l)),n=!1;t.map(t=>{let i=Object.assign({},t);return t.event_id===e&&(t.timestamp=s,n=!0),i}),n?localStorage.setItem(l,JSON.stringify(t)):localStorage.setItem(l,JSON.stringify([...t,...d]))}}function S(){const e=(new Date).getTime();let t=JSON.parse(localStorage.getItem(l));if(!t)return[];let n=t.filter(t=>t.timestamp+f>e);return localStorage.setItem(l,JSON.stringify(n)),n}function T(){if(null!=localStorage.getItem(p)){const e=parseInt(localStorage.getItem(p))+1;localStorage.setItem(p,e)}}function I(){const e=localStorage.getItem(u);return new Set(e?JSON.parse(e):[])}function $(e){const t=I();t.add(e),localStorage.setItem(u,JSON.stringify([...t]))}function z(e){const t=(new Date).getTime(),n=JSON.parse(localStorage.getItem(m));if(!n||(null===n||void 0===n?void 0:n.timestamp)+x<t){const n=null===e||void 0===e?void 0:e.filter(e=>!0===(null===e||void 0===e?void 0:e.is_active)),i=I(),o={questionList:n.filter(e=>!i.has(e.id)),timestamp:t};localStorage.setItem(m,JSON.stringify(o)),localStorage.setItem(p,"0")}}},4901:function(e,t,n){n.d(t,{d:function(){return r}});var i=n(964),o=n(6641);const r=function(e,t){const n="ingesting analytis-event";return(0,o.gv)(n),fetch(i.qW+"/event_metrics/bulk",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e),keepalive:t}).then(e=>{if(!e.ok)throw new Error(n+" failed: HTTP "+e.status);return e}).catch(e=>{throw console.error("error "+n,e),e})}},6005:function(e,t,n){n.d(t,{A:function(){return i}});const i=function(e,t,n,i){var o;return{landing_location_type:t.landingLocationType,template_type:t.templateType,whatmore_event:{id:e.event_id,eventset_id:null!==(o=e.eventset_id)&&void 0!==o?o:null,cta_list:i.map(e=>e.cta_id),product_list:n.map(e=>e.product_id)}}}},6157:function(e,t,n){n.d(t,{O:function(){return i},l:function(){return o}});const i=Object.freeze({EVENT_VIEW:"event-view",PRODUCT_CTA_VIEW:"product-cta-view",SHOPNOW_ATC_CLICKED:"shop-now-atc-clicked",SHOPNOW_BUYNOW_CLICKED:"shop-now-buy-now-clicked",SHOPNOW_VIEWMORE_CLICKED:"shop-now-view-more-clicked",SHOPNOW_PRODUCT_TITLE_CLICKED:"shop-now-product-title-clicked",VIDEO_TILE_PRODUCT_THUMBNAIL_CLICKED:"video-tile-product-thumbnail-clicked",PRODUCT_TILE_ATC_CLICKED:"product-tile-atc-clicked",PRODUCT_TILE_SHOPNOW_CLICKED:"product-tile-shopnow-clicked",VIDEO_LIKED:"video-liked",VIDEO_UNLIKED:"video-unliked",VIDEO_SHARE_CTA_CLICKED:"video-share-cta-clicked",VIDEO_MUTED:"video-muted",HOMEPAGE_CAROUSEL_SWIPED:"homepage-carousel-swiped",HOMEPAGE_VISITED:"homepage-visited",COLLECTION_PAGE_VISITED:"collection-page-visited",PDP_VISITED:"product-page-visited",PAGE_VISITED:"page-visited",HOMEPAGE_CAROUSEL_WIDGET_VIEW:"homepage-carousel-widget-view",BANNER_WIDGET_VIEW:"banner-widget-view",STORIES_WIDGET_VIEW:"stories-widget-view",COLLECTION_WIDGET_VIEW:"collection-widget-view",SPOTLIGHT_WIDGET_VIEW:"spotlight-widget-view",PDP_POPUP_WIDGET_VIEW:"pdp-popup-widget-view",PDP_POPUP_CLOSED:"pdp-popup-closed",VIDEO_PLAYBACK:"video-watched",SHOPNOW_CLICKED:"shopnow-clicked",WHATSAPP_ICON_CLICKED:"whatsapp-icon-clicked",BANNER_WIDGET_CLICKED:"banner-widget-clicked",QUESTION_VIEWED:"question-viewed",QUESTION_ANSWERED:"question-answered",QUESTION_CLOSED:"question-closed",PRODUCT_TILE_ALL_ATC_CLICKED:"product-tile-all-atc"}),o=function(e,t){return{name:e,metadata:t}}},6641:function(e,t,n){n.d(t,{Fk:function(){return s},gv:function(){return l},xv:function(){return d}});var i=n(7714);const o="Whatmore : ",r=(0,i.R)();function a(e){console.debug(o+e)}function d(e,t="200"){var n;null!==(n="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==n&&n&&(a("total events received : "+(e&&e.length)),a("events data : "+JSON.stringify(e)))}function l(e){var t;null!==(t="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==t&&t&&a(e)}const s=e=>{"STR60LW4WMA"!=r&&"77604192550"!=r&&"80856187185"!=r&&"86486974743"!=r&&console.log(`%c ${e}`,"background: #D53F8C; color: white; font-size: 19px; padding: 5px; font-weight: semibold;","\n\nFind us here -> https://www.whatmore.ai/shoppable-videos/")}},7714:function(e,t,n){n.d(t,{R:function(){return r},y:function(){return a}});var i=n(964);function o(e,t){const n=document.getElementById(e);return n&&(n.getAttribute("data-wh")||n.getAttribute("data"))||t}function r(){return o("whatmoreShopId",i.YZ)}function a(){return o("whatmoreExtensionType","index")}},9211:function(e,t,n){function i(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)e[i]=n[i]}return e}n.d(t,{A:function(){return o}});var o=function e(t,n){function o(e,o,r){if("undefined"!==typeof document){"number"===typeof(r=i({},n,r)).expires&&(r.expires=new Date(Date.now()+864e5*r.expires)),r.expires&&(r.expires=r.expires.toUTCString()),e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var d in r)r[d]&&(a+="; "+d,!0!==r[d]&&(a+="="+r[d].split(";")[0]));return document.cookie=e+"="+t.write(o,e)+a}}return Object.create({set:o,get:function(e){if("undefined"!==typeof document&&(!arguments.length||e)){for(var n=document.cookie?document.cookie.split("; "):[],i={},o=0;o<n.length;o++){var r=n[o].split("="),a=r.slice(1).join("=");try{var d=decodeURIComponent(r[0]);if(i[d]=t.read(a,d),e===d)break}catch(l){}}return e?i[e]:i}},remove:function(e,t){o(e,"",i({},t,{expires:-1}))},withAttributes:function(t){return e(this.converter,i({},this.attributes,t))},withConverter:function(t){return e(i({},this.converter,t),this.attributes)}},{attributes:{value:Object.freeze(n)},converter:{value:Object.freeze(t)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"})}},n={};function i(e){var o=n[e];if(void 0!==o)return o.exports;var r=n[e]={id:e,loaded:!1,exports:{}};return t[e](r,r.exports,i),r.loaded=!0,r.exports}i.m=t,i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};i.t=function(n,o){if(1&o&&(n=this(n)),8&o)return n;if("object"===typeof n&&n){if(4&o&&n.__esModule)return n;if(16&o&&"function"===typeof n.then)return n}var r=Object.create(null);i.r(r);var a={};e=e||[null,t({}),t([]),t(t)];for(var d=2&o&&n;("object"==typeof d||"function"==typeof d)&&!~e.indexOf(d);d=t(d))Object.getOwnPropertyNames(d).forEach(function(e){a[e]=function(){return n[e]}});return a.default=function(){return n},i.d(r,a),r}}(),i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=function(e){return Promise.all(Object.keys(i.f).reduce(function(t,n){return i.f[n](e,t),t},[]))},i.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)+"."+{254:"dac254f0",259:"74afe936",260:"2930df22",268:"eed8743b",323:"88610351",609:"cbc87aba",760:"c5d22c24",939:"63aa381a",942:"69c4e83e"}[e]+".chunk.js"},i.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"},i.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={},t="whatmorelive-react:";i.l=function(n,o,r,a){if(e[n])e[n].push(o);else{var d,l;if(void 0!==r)for(var s=document.getElementsByTagName("script"),c=0;c<s.length;c++){var h=s[c];if(h.getAttribute("src")==n||h.getAttribute("data-webpack")==t+r){d=h;break}}d||(l=!0,(d=document.createElement("script")).charset="utf-8",d.timeout=120,i.nc&&d.setAttribute("nonce",i.nc),d.setAttribute("data-webpack",t+r),d.src=n),e[n]=[o];var p=function(t,i){d.onerror=d.onload=null,clearTimeout(m);var o=e[n];if(delete e[n],d.parentNode&&d.parentNode.removeChild(d),o&&o.forEach(function(e){return e(i)}),t)return t(i)},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)}}}(),i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},i.p="https://cdn.jsdelivr.net/npm/whatmore-react-assets@latest/",function(){if("undefined"!==typeof document){var e=function(e){return new Promise(function(t,n){var o=i.miniCssF(e),r=i.p+o;if(function(e,t){for(var n=document.getElementsByTagName("link"),i=0;i<n.length;i++){var o=(a=n[i]).getAttribute("data-href")||a.getAttribute("href");if("stylesheet"===a.rel&&(o===e||o===t))return a}var r=document.getElementsByTagName("style");for(i=0;i<r.length;i++){var a;if((o=(a=r[i]).getAttribute("data-href"))===e||o===t)return a}}(o,r))return t();!function(e,t,n,o,r){var a=document.createElement("link");a.rel="stylesheet",a.type="text/css",i.nc&&(a.nonce=i.nc),a.onerror=a.onload=function(n){if(a.onerror=a.onload=null,"load"===n.type)o();else{var i=n&&n.type,d=n&&n.target&&n.target.href||t,l=new Error("Loading CSS chunk "+e+" failed.\n("+i+": "+d+")");l.name="ChunkLoadError",l.code="CSS_CHUNK_LOAD_FAILED",l.type=i,l.request=d,a.parentNode&&a.parentNode.removeChild(a),r(l)}},a.href=t,n?n.parentNode.insertBefore(a,n.nextSibling):document.head.appendChild(a)}(e,r,null,t,n)})},t={792:0};i.f.miniCss=function(n,i){t[n]?i.push(t[n]):0!==t[n]&&{260:1,268:1,760:1}[n]&&i.push(t[n]=e(n).then(function(){t[n]=0},function(e){throw delete t[n],e}))}}}(),function(){var e={792:0};i.f.j=function(t,n){var o=i.o(e,t)?e[t]:void 0;if(0!==o)if(o)n.push(o[2]);else{var r=new Promise(function(n,i){o=e[t]=[n,i]});n.push(o[2]=r);var a=i.p+i.u(t),d=new Error;i.l(a,function(n){if(i.o(e,t)&&(0!==(o=e[t])&&(e[t]=void 0),o)){var r=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;d.message="Loading chunk "+t+" failed.\n("+r+": "+a+")",d.name="ChunkLoadError",d.type=r,d.request=a,o[1](d)}},"chunk-"+t,t)}};var t=function(t,n){var o,r,a=n[0],d=n[1],l=n[2],s=0;if(a.some(function(t){return 0!==e[t]})){for(o in d)i.o(d,o)&&(i.m[o]=d[o]);if(l)l(i)}for(t&&t(n);s<a.length;s++)r=a[s],i.o(e,r)&&e[r]&&e[r][0](),e[r]=0},n=self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))}(),i.nc=void 0;const o="whatmore_brand_customizations",r=null!==(e="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==e&&e;function a(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)),r&&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 n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}async function s(e){var t,n;if(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd0d Getting customizations...`),null!==(t=window)&&void 0!==t&&null!==(n=t.whatmore)&&void 0!==n&&n.frontendCustomizations&&"object"===typeof window.whatmore.frontendCustomizations){r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from window.whatmore.frontendCustomizations`);const e=window.whatmore.frontendCustomizations;return d(e),e}const i=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(i)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from cache`),i;r&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No cached customizations, fetching from backend...`);const a=await async function(e){try{r&&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 n=await t.json();return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations fetched from backend`),d(n),n}catch(t){return console.error("Whatmore: Error fetching customizations from backend:",t),null}}(e);return a}function c(e,t,n,i,o){if(n)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udccc Shared link detected - immediate load`),!1;if("template-embed"===i)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udecd\ufe0f Embed widget - immediate load on every page`),!1;if(!e)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No customizations - defaulting to immediate load`),!1;const a=l(e,"lazy_load_config->block_widgets"),d=l(e,"collections_config->show_popup_out_of_view");return t&&d?(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udce6 Collections with showPopupOutOfView=true - immediate load`),!1):a?(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd04 lazyloadConfig_blockWidget=true - lazy load enabled`),!0):(r&&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,n)=>{const i=e.querySelector(`#${t}`);if(!i)return n;return i.getAttribute("data-wh")||i.getAttribute("data")||n}}function v(e,t){if(!e)return null;const n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}function w(e,t){const n=e>t,i=e>=481;return n&&i?"desktop":!n&&i?"tablet":n&&!i?"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 _(e,t){if(!t.startsWith("product"))return 0;const n=.055*e;return Math.round(12+1.2*n*2)}function b(e){var t,n;const{widgetContainer:i,customizations:o,windowWidth:r,windowHeight:a,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"))}}(i),s=w(r,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,i=d*m*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:r,windowHeight:a,liquidVars:l,customizations:o}),_=Math.ceil(c.slidesPerView),b=void 0!==d?d:_,y=null!==(t=v(o,"event_tile_config->show_product_thumbnail"))&&void 0!==t&&t,P=function(e){var t,n,i;const{width:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_config->show_product_thumbnail"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=null!==(n=v(a,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==n?n:1,s=null!==(i=v(a,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==i?i: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}),S=x(l.heading,l.titleFontSize),T=null!==(n=v(o,"carousel_config->width_multiplier"))&&void 0!==n?n:1.1,I=l.topBottomPadding+S+25+c.height+P+25+l.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,showProductInfo:o,productInfoHeight:r,headingHeight:a,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%;">`;a>0&&(v+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <p style="\n height: ${a}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?i: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: ${n}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:b,showProductInfo:y,productInfoHeight:P,headingHeight:S,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:r,windowHeight:a,slidesPerView:c.slidesPerView,widthMultiplier:T});return{totalHeight:Math.round(I),shimmerHTML:$,topBottomPadding:l.topBottomPadding}}function y(e,t){var n,i,o;const r=(null===(n=e.querySelector("#whatmoreShopId"))||void 0===n?void 0:n.getAttribute("data-wh"))||(null===(i=e.querySelector("#whatmoreShopId"))||void 0===i?void 0:i.getAttribute("data"));if("51273072796"==r||"64967540952"==r)return[document.documentElement.clientHeight,document.documentElement.clientWidth];const a=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"),a&&console.log("Set currElement width to 100% !important"))}return[window.innerHeight,l]}function P(e){var t,n;const{widgetContainer:i,customizations:o,eventCount:r}=e,[a,d]=y(i),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"))}}(i),s=w(d,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){var g;const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;const a=null!==(g=v(r,"event_tile_config->space_between_tiles"))&&void 0!==g?g:1;s=f(n/(1.15*t))*a,c=0,d=i,l=t}else if("tablet"===t){var w;const e=o.videoTileSizePortrait/100;let t=l*m*e,i=d*m*e;const a=null!==(w=v(r,"event_tile_config->space_between_tiles"))&&void 0!==w?w:1;s=f(n/(1.2*t))*a,c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:1.2*d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:a,liquidVars:l,customizations:o}),_=Math.ceil(c.slidesPerView),b=void 0!==r?r:_,P=x(l.heading,l.titleFontSize),S=null!==(t=v(o,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,T=("desktop"===s||"mobileLandscape"===s)&&null!==(n=v(o,"event_tile_config->gap_between_tiles"))&&void 0!==n?n:0,I=l.topBottomPadding+P+25+c.height+25+l.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,headingHeight:o,topBottomPadding:r,landscapePadding:a,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: ${r}px; margin-bottom: ${r}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: ${a}px; padding-right: ${a}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<i;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: ${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 </div>\n `}else{const e=l/s;m+=`<div style="display: flex; transform: translate3d(${l/2-1.5*e}px, 0px, 0px);">`;for(let i=0;i<3;i++)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: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n transform: ${1===i?"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:b,headingHeight:P,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:c.slidesPerView,widthMultiplier:S,spaceBetween:T});return{totalHeight:I,shimmerHTML:$}}function S(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=a*p;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:a*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s=a.collectionsTilesSpacing,c=_(l.width,a.extensionType),v="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,f=l.width+10,x=Math.ceil(v/(f+s))+1,b=void 0!==i?i:x,P=a.topBottomPadding+l.height+10+c+a.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${i}px; margin-bottom: ${i}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: ${n}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,numberOfTiles:b});return{totalHeight:P,shimmerHTML:S}}function T(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=a*p;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:a*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s=a.collectionsTilesSpacing,c=_(l.width,a.extensionType),v="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,f=l.width+4,x=Math.ceil(v/(f+s))+1,b=void 0!==i?i:x,P=a.topBottomPadding+l.height+4+c+a.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${i}px; margin-bottom: ${i}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: ${n}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,numberOfTiles:b});return{totalHeight:P,shimmerHTML:S}}function I(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreExtensionType","index"),landingLocationType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*m*e,d=d*m*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*p,t=a*p;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,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)*a*s*.01,width:d*s*.01,landscapePadding:l,unscaledWidth:d}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s="68304765103"===a.shopId?"mobilePortrait"===d||"tablet"===d?6:20:a.collectionsTilesSpacing,c=x(a.heading,a.titleFontSize),f=("mobilePortrait"===d||"tablet"===d?a.videoTileSizePortrait:a.videoTileSize,function(e,t,n,i,o){var r,a,d,l,s;if(i.startsWith("product"))return 0;const c="mobilePortrait"===t||"tablet"===t,h=null!==(r=v(o,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==r?r:.022,p=null!==(a=v(o,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==a?a:.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,_=w&&f?Math.ceil(1.2*x):0,b=null!==(s=v(o,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==s&&s,y=c?10:12,P=Math.max(9,.75*m),S=b?y+Math.ceil(P):0;let T=0;return _>0&&T++,S>0&&T++,12+g+_+2+S+4*T}(l.unscaledWidth,d,a.shopId,a.landingLocationType,n)),_="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,b=l.width+4,P=Math.ceil(_/(b+s))+1,S=void 0!==i?i:P,T=a.topBottomPadding+c+l.height+4+f+a.topBottomPadding,I=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,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: ${i}px; margin-bottom: ${i}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: ${n}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"===r||"tablet"===r,t=null!==(f=v(m,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==f?f:.022,n=null!==(x=v(m,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==x?x:.015,i=e?1.076*p*t:p*n,o=e?4:8,a=6,d=4,l=.9*i,s=Math.ceil(1.15*l),c=null===(_=v(m,"product_config->show_product_price"))||void 0===_||_,h=null===(b=v(m,"event_tile_with_product_info->show_price_info"))||void 0===b||b,u=.9*i,g=Math.ceil(1.2*u),P=null!==(y=v(m,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==y&&y,S=e?10:12,T=Math.max(9,.75*i),I=2,$=S+Math.ceil(T);w+=`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${a}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: ${$}px;\n height: ${$}px;\n width: 100%;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: ${I}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,headingHeight:c,numberOfTiles:S,shopId:a.shopId,landingLocationType:a.landingLocationType,unscaledWidth:l.unscaledWidth,customizations:n});return{totalHeight:T,shimmerHTML:I}}const $=function(e,t){return e<=768?t>e?"mobilePortrait":"mobileLandscape":e<=1024?"tablet":"desktop"};function z({tileWidth:e,tileHeight:t,numberOfTiles:n,headingHeight:i,topBottomPadding:o,landscapePadding:r,deviceMode:a,windowWidth:d,gap:l,productInfoHeight:s,customizations:c,liquidVars:h}){const p="mobilePortrait"===a||"tablet"===a;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%;">`;i>0&&(m+=`\n <div style="display: flex; justify-content: center; align-items: center; margin-bottom: 16px;">\n <div style="\n width: 200px;\n height: ${i-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,n,i,o){var r,a,d;const l="mobilePortrait"===t||"tablet"===t,s=null===(r=v(i,"product_config->show_product_price"))||void 0===r||r,c=null===(a=v(i,"event_tile_with_product_info->show_price_info"))||void 0===a||a,h=null!==(d=v(i,"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,a,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: ${r}px; padding-right: ${r}px;`}\n position: relative;\n overflow: hidden;\n ">`,p||(m+=`\n \x3c!-- Left navigation button --\x3e\n <div style="\n position: absolute;\n left: ${r}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: ${r}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<n;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 k(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),a=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=$(r,o),l=function({deviceMode:e,windowWidth:t,windowHeight:n,liquidVars:i,customizations:o}){var r;const a="mobilePortrait"===e||"tablet"===e?i.tileSizePortrait:i.tileSize,d=t>n,l="mobilePortrait"===e&&t>=481,s=a/100*1.3*.5,c=a/100,g=Math.min(t,n);let w=g*h*u,x=g*h,_=0,b=1.4;const y=null!==(r=v(o,"carousel_config->theme_margin"))&&void 0!==r?r:0;if(d){const e=x*s,n=w*s,o=i.landscapePadding||0;x=e,w=n,_=o,b=(t-2*o-2*y)/(1.1*e)}else if(l){let n=x*m,o=w*m;if("mobilePortrait"===e)n*=c,o*=c,x=n,w=o,_=0,b=f(t/(1.2*n));else{const e=i.landscapePadding||0;x=n,w=o,_=e,b=(t-2*e)/(1.1*n)}}else{let n=x,o=w;if("mobilePortrait"===e)n=n*c*.9,o=o*c*.9,x=n,w=o,_=0,b=f(t/(1.15*n));else{n=x*p,o=w*p;const e=i.landscapePadding||0;x=n,w=o,_=e,b=(t-2*e)/(1.1*n)}}return{height:w,width:x,landscapePadding:_,slidesPerView:b}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a,customizations:n}),s=Math.ceil(l.slidesPerView),c=void 0!==i?i:s,w=x(a.heading,a.titleFontSize),_=function(e,t=24){const n=v(e,"event_tile_config->gap_between_tiles");return null!==n&&void 0!==n?0===n?24:n:t}(n),b=function({tileWidth:e,deviceMode:t,customizations:n}){var i,o,r;if(!v(n,"event_tile_with_product_info->show_product_info"))return 0;const a="mobilePortrait"===t||"tablet"===t,d=null!==(i=v(n,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==i&&i,l=a?1.076*e*.04:.04*e,s=1.2*l+(null===(o=v(n,"product_config->show_product_price"))||void 0===o||o?1.2*l+5:0)+(null===(r=v(n,"event_tile_with_product_info->show_price_info"))||void 0===r||r?1.2*l+5:0)+(d?8+(a?36:44):0),c=d?110:s;return Math.round(Math.max(c,s+24))}({tileWidth:l.width,deviceMode:d,customizations:n}),P=a.topBottomPadding+w+25+l.height+b+10+a.topBottomPadding,S=z({tileWidth:l.width,tileHeight:l.height,numberOfTiles:c,headingHeight:w,topBottomPadding:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,windowHeight:o,gap:_,productInfoHeight:b,customizations:n,liquidVars:a});return{totalHeight:Math.round(P),shimmerHTML:S}}function M(e){const{customizations:t,widgetContainer:n,eventCount:i}=e,[o,r]=y(n),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")),extensionType:t("whatmoreExtensionType","index")}}(n),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;a=a*m*e,d=d*m*e}else if("mobileLandscape"===t)o.videoTileSize,a*=p,d*=p;else{const e=o.videoTileSize/100*1.3*.5;a*=e,d*=e}return{height:a,width:d}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a});function s(e){return Math.round(10*e)/10}let c;c="mobilePortrait"===d?s(r/(1.15*l.width)):"tablet"===d?s(r/(1.2*l.width)):r/(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 n=.07*e;return 46+Math.ceil(2.5*n)}(l.width,t),_=.2*l.height,b=20+(3+l.height+3)+x,P=Math.ceil(i/f),S=a.topBottomPadding+P*b+(P-1)*_+a.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,eventCount:o,slidesPerView:r,atcButtonHeight:a,rowSpacing:d}=e,l=r,s=Math.ceil(o/l);let c=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${i}px;\n margin-bottom: ${i}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 i=0;i<e;i++)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: ${n}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>`,a>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:a.topBottomPadding,eventCount:i,slidesPerView:f,atcButtonHeight:x,rowSpacing:_});return{totalHeight:Math.round(S),shimmerHTML:T}}function H(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,[r,a]=y(n),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"))}}(n),l=w(a,r),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*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,i=d*m*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:a,windowHeight:r,liquidVars:d,customizations:i}),c=Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(d.heading,d.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=d.topBottomPadding+b+25+s.height+25+d.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,headingHeight:o,topBottomPadding:r,landscapePadding:a,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: ${r}px; margin-bottom: ${r}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: ${a}px; padding-right: ${a}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<i;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: ${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 </div>\n `}else{const e=l/s;p+='<div style="display: flex;">';for(let o=0;o<i;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: ${n}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:_,headingHeight:b,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:a,slidesPerView:s.slidesPerView,widthMultiplier:P});return{totalHeight:Math.round(S),shimmerHTML:T}}function E(e){var t,n;const{widgetContainer:i,customizations:o,eventCount:r}=e,[a,d]=y(i),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"))}}(i),s=w(d,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,i=d*m*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:a,liquidVars:l,customizations:o}),_=null!==(t=v(o,"event_tile_config->space_between_tiles"))&&void 0!==t?t:1,b=c.slidesPerView*_,P=Math.ceil(b),S=void 0!==r?r:P,T=x(l.heading,l.titleFontSize),I=null!==(n=v(o,"carousel_config->width_multiplier"))&&void 0!==n?n:1.1,$=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e,d=null!==(t=v(a,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,l="mobilePortrait"===r||"tablet"===r,s=.25*o*1.25,c=v(a,"event_tile_with_product_info->portrait_font_multiplier"),h=v(a,"event_tile_with_product_info->landscape_font_multiplier"),p=l?1.076*o*c:o*h,m=Math.ceil(1.2*p),u=null===(n=v(a,"product_config->show_product_price"))||void 0===n||n,g=u?Math.ceil(1.2*p):0,w=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,f=l?.965*o*c:.859*o*h;let x=0;u&&x++,w&&x++;const _=m+g+(w?Math.ceil(f)+6:0)+5*x,b=d?Math.max(s,_):_;return Math.round(24+b)}({tileWidth:c.width,deviceMode:s,customizations:o}),z="mobilePortrait"===s||"tablet"===s?c.height*I:c.height,k=l.topBottomPadding+T+12+z+$+12+l.topBottomPadding,M=function(e){var t,n,i;const{tileWidth:o,tileHeight:r,numberOfTiles:a,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,_="mobilePortrait"===c||"tablet"===c,b=.25*o,y=null===(n=v(g,"product_config->show_product_price"))||void 0===n||n,P=null===(i=v(g,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,S=v(g,"event_tile_with_product_info->portrait_font_multiplier"),T=v(g,"event_tile_with_product_info->landscape_font_multiplier"),I=_?1.076*o*S:o*T,$=Math.ceil(1.2*I),z=Math.ceil(1.2*I),k=_?.965*o*S:.859*o*T,M=Math.ceil(k)+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: ${b}px;\n height: ${1.25*b}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: ${$}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 ${y?`\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: ${z}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: ${z}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: ${M}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 `,E=o,C=r*m,L=o,W=r;let O="";w||(O=`transform: translate3d(${-h/p/2}px, 0px, 0px);`);f+=`<div style="display: flex; gap: 0px; ${w?"margin: 0 auto; width: max-content;":O}">`;const B=w?a:3;for(let v=0;v<B;v++){const e=!w&&(0===v||2===v),t=!w&&1===v,n=t?E:e?L:o,i=t?C:e?W:r;f+=w?`\n <div style="flex-shrink: 0; width: ${o*p*m/p}px;">\n <div style="width: ${n}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${n}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 ${H}\n </div>\n </div>\n `:`\n <div style="flex-shrink: 0; width: ${h/p}px;">\n <div style="width: ${n}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${n}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 ${H}\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:S,headingHeight:T,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:b,widthMultiplier:I,productInfoHeight:$,customizations:o});return{totalHeight:Math.round(k),shimmerHTML:M}}function C(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,[r,a]=y(n),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"))}}(n),l=w(a,r),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,i=d*m*e;s=f(n/(1.2*t)),c=0,d=i,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,n=d*e*1.3;c=o.landscapePadding,s=5,d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:a,windowHeight:r,liquidVars:d,customizations:i}),c="desktop"===l||"mobileLandscape"===l?5:Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(d.heading,d.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_with_product_info->show_thumbnail_image"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=.25*o,s=v(a,"event_tile_with_product_info->portrait_font_multiplier"),c=v(a,"event_tile_with_product_info->landscape_font_multiplier"),h=d?1.076*o*s:o*c,p=Math.ceil(1.2*h),m=null===(n=v(a,"product_config->show_product_price"))||void 0===n||n,u=m?Math.ceil(1.2*h):0,g=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,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,_=Math.max(l,x);return Math.round(24+_)}({tileWidth:"mobilePortrait"===l||"tablet"===l?s.width*P:s.width,deviceMode:l,customizations:i}),T="desktop"===l||"mobileLandscape"===l?24:12,I="mobilePortrait"===l||"tablet"===l?s.height*P:s.height,$=d.topBottomPadding+b+T+I+S+12+d.topBottomPadding,z=function(e){var t;const{tileWidth:n,tileHeight:i,numberOfTiles:o,headingHeight:r,topBottomPadding:a,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: ${a}px;\n margin-bottom: ${a}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;r>0&&(g+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${r-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,_;const e=.25*n;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===(_=v(m,"event_tile_with_product_info->show_discount_label"))||void 0===_||_?'\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*n,o=s/2,r=(i+p)/2;g+=`<div style="display: flex; justify-content: center; align-items: center; position: relative; height: ${i+w+12+p}px;">`;for(let a=0;a<5;a++){const d=a-2,l=0===d,s=e[a],c=n*s,h=i*s;g+=`\n <div style="\n position: absolute;\n left: ${o+d*t-c/2}px;\n bottom: ${r-(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=n,t=i,o=i*h;let r="";const a=s/c;r=`transform: translate3d(${-a/2}px, 0px, 0px);`,g+=`<div style="display: flex; gap: 0px; ${r}">`;const d=3;for(let n=0;n<d;n++)g+=`\n <div style="flex-shrink: 0; width: ${a}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===n?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:_,headingHeight:b,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:a,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:S,customizations:i});return{totalHeight:Math.round($),shimmerHTML:z}}function L(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,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")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),[a,d]=y(n),l=w(d,a),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*m*e,i=d*m*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*p,t=d*p;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:d,windowHeight:a,liquidVars:r,customizations:i}),c=Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(r.heading,r.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_config->show_product_tile"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=v(a,"event_tile_with_product_info->portrait_font_multiplier"),s=v(a,"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===(n=v(a,"product_config->show_product_price"))||void 0===n||n,u=m?Math.ceil(1.2*p):0,g=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,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:i}),T="mobilePortrait"===l||"tablet"===l,I=T?16:32,$=b>0?T?12:16:0,z=T?16:0,k=s.height,M=r.topBottomPadding+I+b+$+z+0+0+k+S+0+r.topBottomPadding,H=function(e){var t;const{tileWidth:n,tileHeight:i,numberOfTiles:o,headingHeight:r,topBottomPadding:a,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: ${a}px;\n margin-bottom: ${a}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"};">`;r>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: ${r-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?n*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;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===(_=v(m,"product_config->show_product_price"))||void 0===_||_?'\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===(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: 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 y;const e=s-48,t=12,o=c*(null!==(y=v(m,"event_tile_config->space_between_tiles"))&&void 0!==y?y:1),r=(e-(o-1)*t)/o;f+=`<div style="display: flex; transform: translate3d(${e/2-(r+t+r/2)}px, 0px, 0px);">`;const a=3,d=1.02,l=.98;for(let s=0;s<a;s++){const e=0===s||2===s;f+=`\n <div style="\n width: ${r}px;\n flex-shrink: 0;\n margin-right: ${s<a-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: ${n}px;\n height: ${i}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=n*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: ${n}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: ${n}px;\n height: ${i}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:_,headingHeight:b,topBottomPadding:r.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:d,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:S,customizations:i});return{totalHeight:Math.round(M),shimmerHTML:H}}function W(e,t){if(!e)return null;const n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}function O(e){var t;const{customizations:n,widgetContainer:i,eventCount:o}=e,[r,a]=y(i),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"))}}(i),l=r>a?"portrait":"landscape",s="portrait"===l?d.videoTileSizePortrait:d.videoTileSize,{WIDTH:c,HEIGHT:h,isPortrait:p}=function(e,t,n){const i=e>t,o=t>e,r=!(!o||!(e>=481)),a=.8,d=n/100*1.3*.5,l=n/100,s=Math.min(e,t);let c=.6*s,h=.6*s*(16/9);return i?(c*=d,h*=d):r?o?(c=c*a*l,h=h*a*l):(c*=a,h*=a):o?(c=c*l*.9,h=h*l*.9):(c*=.7,h*=.7),{WIDTH:c,HEIGHT:h,isPortrait:o}}(a,r,s),m="portrait"===l?0:d.landscapePadding,u=d.collectionsTilesSpacing,v=c*s*.01,w=W(n,"collections_config->story_tile_size_factor")||1,f=null!==(t=W(n,"collections_config->story_tile_shape"))&&void 0!==t?t:"circle",x=W(n,"collections_config->remove_borders"),_=parseInt(W(n,"collections_config->tile_margin_right"))||0,b=x?2:_||0,P=x?2:5,S=x?2:5,T="circle"===f?"50%":"6%",I=v*w,$="rectangle"===f?1.5*I:I,z=I,k=.8*(.055*c),M=P+$+10+S,H=2*d.topBottomPadding+M,E=a-2*m,C=z+b,L=Math.min(Math.ceil((E+u)/(C+u)),8),O=void 0!==o?o:L,B="landscape"===l?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let V=`<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="${B}" 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<O;g++)V+=`\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: ${b}px;\n margin-top: ${P}px;\n margin-bottom: ${S}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: ${$}px;\n width: ${I}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: ${z}px;\n padding-top: 10px;\n font-size: ${k}px;\n ">\n <p style="margin: 0; padding: 0; line-height: 0; height: 0;"></p>\n </div>\n </div>\n `;return V+="\n </div>\n </div>\n </div>\n </div>",{totalHeight:Math.round(H),shimmerHTML:V}}var B;const V=null!==(B="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==B&&B;function D(e,t,n,i){var o,r;const a=e<=t,d=parseInt(((e,t)=>{const n=document.querySelector(`#${e}`);return n&&(n.getAttribute("data-wh")||n.getAttribute("data"))||t})("whatmoreVideoTileSize","60")),l=v(n,"banner_config->portrait_multiplier"),s=v(n,"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=a?null!==(o=v(n,"banner_config->portrait_aspect_ratio"))&&void 0!==o?o:1:null!==(r=v(n,"banner_config->landscape_aspect_ratio"))&&void 0!==r?r:.5625,m=a?e*c:e*h,u=v(n,"banner_config->is_full_screen")||!1,g=u?e*p:m*p;return{width:u?"100%":`${m}px`,height:`${g}px`,borderWidth:v(n,"theme_config->event_tile->border_width")||"0px",borderColor:v(n,"theme_config->event_tile->border_color")||"transparent",borderStyle:"solid",totalHeight:g}}function A(e){const{windowWidth:t,windowHeight:n,customizations:i,widgetContainer:o,widgetIdentity:r}=e,a=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const n=t[e];return n?n.tc:null}return t.tc||null}(r);if(null===a||void 0===a||0===a)return V&&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 n=t[e];return n?{landscape:n.landscape_poster||null,portrait:n.portrait_poster||null}:null}return{landscape:t.landscape_poster||null,portrait:t.portrait_poster||null}}(r);if(!d||!d.landscape&&!d.portrait)return V&&console.log("[Banner Shimmer] No poster URLs found"),null;const l=D(t,n,i),s=t<=n?d.portrait:d.landscape;if(!s)return V&&console.log("[Banner Shimmer] No poster URL for current orientation"),null;v(i,"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 j(e){return g(e)("whatmoreShopId",null)}function N(){return window.location.href.split(/[?#]/)[0]}function R(e,t,n,i){const o=j(e);if("index"===t&&"carousel"===n)return"homepage";if(t&&t.startsWith("product")){return v(i,"show_homepage_videos_in_pdp")?"homepage":function(e){return g(e)("whatmoreProductId",null)}(e)}if("collection"===n){let t;return"19506115"===o?t="343270603":v(i,"collections_config->use_page_link_as_collection_id")?t=v(i,"collections_config->multi_carousel_enabled")?function(e){return g(e)("whatmoreCollectionUrl",null)}(e):N():(t=function(e){return g(e)("whatmoreCollectionId",null)}(e),"0"===t&&(t=function(e){return g(e)("whatmorePageId",null)}(e)),t&&"0"!==t||(t=N())),t}return"carousel"===n?"homepage":null}function q(e,t){const n=j(e),i=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),r=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 n of t)if(e.querySelector(`.whatmore-template-type[data-wh="${n}"]`)||e.querySelector(`.whatmore-template-type[data="${n}"]`))return n;return null}(e),a=R(e,i,o,t),d=function(e){return g(e)("whatmoreWidgetIdentity","wgt_default")}(e);return{shopId:n,landingLocationType:i,widgetType:o,templateType:r,actualId:a,widgetIdentity:d,isValidId:(l=a,!(!l||null===l||"null"===l||""===l)&&/^\d+$/.test(String(l))||"homepage"===a)};var l}var F,U=i(3782);const G=null!==(F="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==F&&F;function J(e,t,n){const i=window.whatmorePdpCarouselEvents;if(!i)return null;if(t&&"wgt_default"!==t){var o;const r=t.split("_");if(r.length<2||!r[1])return null;const a=null===(o=i[`w_${r[1][0]}`])||void 0===o?void 0:o[t];if(!a)return null;const d=a.scope_mode||"all",l=a.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(n,"show_out_of_stock_videos")?a.etc:a.esc}{var r;const t=function(e){return"p_"+parseInt(e)%127}(e),o=null===(r=i[t])||void 0===r?void 0:r[e];if(!o)return null;return v(n,"show_out_of_stock_videos")?o.etc:o.esc}}function K(e,t,n){var i,o;const r=null===(i=window.whatmore)||void 0===i?void 0:i.collectionMetafields;if(!r)return null;const a=function(e){return"c_"+parseInt(e)%63}(e);let d=e;t&&"wgt_default"!==t&&(d=`${e}_${t}`);const l=null===(o=r[a])||void 0===o?void 0:o[d];if(!l)return null;return v(n,"show_out_of_stock_videos")?l.tc:l.sc}function Y(e,t,n,i,o,r){var a;if(!(null===(a=v(r,"shimmer_config->enable_shimmer"))||void 0===a||a))return G&&console.log("[Shimmer] Disabled via customization"),null;if(null!==U.A)return G&&console.log(`[Shimmer] TEST MODE: Using hardcoded count ${U.A}`),U.A;if(!n||""===n||"undefined"===n||"null"===n)return G&&console.log("[Shimmer] No valid ID provided"),null;let d=null;return"homepage"===n?d=function(e,t){const n=window.whatmoreHomepageCarouselEvents;if(!n)return null;if(e&&"wgt_default"!==e){const i=n[e];return i?v(t,"show_out_of_stock_videos")?i.tc:i.sc||i.tc:null}return v(t,"show_out_of_stock_videos")?n.tc:n.sc}(i,r):t&&t.startsWith("product")?d=J(n,i,r):"collection"===e&&(d=K(n,i,r)),null===d||void 0===d||0===d?(G&&console.log(`[Shimmer] Event count is ${d}, skipping shimmer`),null):(G&&console.log(`[Shimmer] Found event count: ${d} for ${e}/${t}/${n}/${i}`),d)}var Z=i(964),Q=i(1578),X=i(6157),ee=i(6005),te=i(4901),ne=i(7714);let ie=!1;function oe(){if(ie)return;const e=(0,ne.y)(),t=function(e){return null!==e&&void 0!==e&&e.startsWith("collection")?X.O.COLLECTION_PAGE_VISITED:null!==e&&void 0!==e&&e.startsWith("product")?X.O.PDP_VISITED:null!==e&&void 0!==e&&e.startsWith("index")?X.O.HOMEPAGE_VISITED:null!==e&&void 0!==e&&e.startsWith("page")?X.O.PAGE_VISITED:null}(e);if(!t)return;ie=!0;const n={...(0,Q.S)(),interaction_data:(0,X.l)(t,{user_type:null!=localStorage.getItem("w_user_type")?"olduser":"newuser"}),data:(0,ee.A)("",{landingLocationType:e,templateType:""},[],[])};(0,te.d)({metric_event_list:[n]},!0)}var re=i(3924);let ae=!1;var de,le,se,ce,he,pe,me,ue;const ge=Array.from(document.getElementsByClassName("whatmore-base")),ve=null!==(de="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==de&&de,we=function(e){return"template-banner-a"===e},fe=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},xe=function(e){return"template-stories-a"===e||"template-stories-b"===e};function _e(e,t){const n=document.getElementById(e);if(!n)return t;return n.getAttribute("data-wh")||n.getAttribute("data")||t}function be(e,t,n,i,o){var r;if("template-embed"===n)return;if("60595503283"===Pe)return;if(!(null===(r=l(i,"shimmer_config->enable_shimmer"))||void 0===r||r))return;const a=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}(n),[d,s]=y(t);try{const r=function(e){const{templateType:t,widgetContainer:n,customizations:i}=e,o=q(n,i);if("template-banner-a"===t)return e.widgetIdentity=o.widgetIdentity,A(e);const r=Y(o.widgetType,o.landingLocationType,o.actualId,o.widgetIdentity,0,i);return null===r?null:(e.eventCount=r,"template-a"===t?b(e):"template-b"===t?P(e):"template-c"===t?S(e):"template-d"===t?T(e):"template-e"===t?I(e):"template-f"===t?k(e):"template-feed-a"===t?M(e):"template-g"===t?H(e):"template-h"===t?E(e):"template-i"===t?C(e):"template-j"===t?L(e):"template-stories"===t?O(e):null)}({templateType:a,widgetContainer:t,customizations:i,windowWidth:s,windowHeight:d});if(r&&r.totalHeight&&r.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=r.totalHeight+"px";const i=document.createElement("div");i.className="whatmore-shimmer-container",i.setAttribute("data-template",n),i.setAttribute("data-widget-id",o),i.style.cssText="position: absolute; top: 0; left: 0; width: 100%; height: auto; z-index: 2; transition: opacity 0.1s ease;",i.innerHTML=r.shimmerHTML,t.insertBefore(i,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 ${n}:`,c)}}const ye=null!==document.getElementById("whatmoreRoot"),Pe=_e("whatmoreShopId",Z.YZ),Se=_e("whatmoreExtensionType","index"),Te=null!==(le=(null===(se=window)||void 0===se||null===(ce=se.Shopify)||void 0===ce||null===(he=ce.theme)||void 0===he?void 0:he.role)&&"main"!==(null===(pe=window)||void 0===pe||null===(me=pe.Shopify)||void 0===me||null===(ue=me.theme)||void 0===ue?void 0:ue.role))&&void 0!==le&&le,Ie=("2665447536"==Pe||"72201044272"==Pe)&&null!=localStorage.getItem("w_user_type"),$e=function(){const e=a("wtt"),t=a("weid");return null!=e&&null!=t}();!async function(){const e=await s(Pe);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((ye||ge&&ge.length>0)&&Pe!==Z.YZ&&l(e,"event_tracking->is_enabled")&&(oe(),function(){if(ae||"undefined"===typeof document)return;ae=!0;const e=()=>{(0,re.$)(!0)};document.addEventListener("visibilitychange",()=>{"hidden"===document.visibilityState&&e()}),window.addEventListener("pagehide",e)}()),"75310563627"===Pe){const e=localStorage.getItem("_whatmore_session_id"),t=localStorage.getItem("_whatmore_user_id"),n=localStorage.getItem("wht_user_group"),i=localStorage.getItem("wht_ab_test_id"),o=localStorage.getItem("_whatmore_last_video_view_session");null!=e&&null!=t&&fetch("/cart.js").then(e=>e.ok?e.json():null).then(r=>{if(!r)return;const a={wht_user_attributes:{wht_session_id:null!==o&&void 0!==o?o:e,wht_user_id:t,...n&&{wht_user_group:n},...i&&{wht_ab_test_id:i}}};return fetch("/cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:a})})}).catch(e=>console.error("Whatmore :: eager cart-attribute write failed",e))}if(!ye&&ge&&ge.length>0)for(let l=0;l<ge.length;l++){var t,n,o,r,a,d,h,p,m,u;const s=ge[l],I=s.querySelector(".whatmore-render-root"),$=s.querySelector(".whatmore-template-type");let z=!1,k=!1,M=!1;const H=null!==(t=null!==(n=null===$||void 0===$?void 0:$.getAttribute("data-wh"))&&void 0!==n?n:null===$||void 0===$?void 0:$.getAttribute("data"))&&void 0!==t?t:"template-embed";xe(H)?z=!0:fe(H)?k=!0:we(H)&&(M=!0);let E="",C="";var g,v,w,f,x,_,b,y,P,S,T;if(k)if(E=null!==(g=null!==(v=null===(w=s.querySelector("#whatmoreCollectionId"))||void 0===w?void 0:w.getAttribute("data-wh"))&&void 0!==v?v:null===(f=s.querySelector("#whatmoreCollectionId"))||void 0===f?void 0:f.getAttribute("data"))&&void 0!==g?g:"",C=null!==(x=null!==(_=null===(b=s.querySelector("#whatmoreCollectionHeading"))||void 0===b?void 0:b.getAttribute("data-wh"))&&void 0!==_?_:null===(y=s.querySelector("#whatmoreCollectionHeading"))||void 0===y?void 0:y.getAttribute("data"))&&void 0!==x?x:"","0"==E)E=null!==(P=null===(S=s.querySelector("#whatmorePageId"))||void 0===S?void 0:S.getAttribute("data-wh"))&&void 0!==P?P:null===(T=s.querySelector("#whatmorePageId"))||void 0===T?void 0:T.getAttribute("data");const L=null!==(o=null!==(r=null===(a=s.querySelector("#whatmoreHeading"))||void 0===a?void 0:a.getAttribute("data-wh"))&&void 0!==r?r:null===(d=s.querySelector("#whatmoreHeading"))||void 0===d?void 0:d.getAttribute("data"))&&void 0!==o?o:"",W=null!==(h=null!==(p=null===(m=s.querySelector("#whatmoreWidgetIdentity"))||void 0===m?void 0:m.getAttribute("data-wh"))&&void 0!==p?p:null===(u=s.querySelector("#whatmoreWidgetIdentity"))||void 0===u?void 0:u.getAttribute("data"))&&void 0!==h?h:"wgt_default",O="whatmoreRoot"+l;be(I,s,H,e,O);const B=c(e,k,$e,H),V=()=>{Promise.all([i.e(609),i.e(268)]).then(i.bind(i,1592)).then(e=>{e.initializeReactApp({rootElement:I,templateType:H,isStoriesTemplate:z,isCollectionsTemplate:k,_isTemplateTypeBanner:M,whatmoreCollectionId:E,whatmoreCollectionHeading:C,whatmoreHeadingCarousel:L,whatmoreWidgetIdentity:W,whatmoreRootId:O,landingLocationType:Se,isInPreviewMode:Te,userType:Ie})}).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(),ve&&console.log(`[Chunk Error] Removed shimmer for widget ${O}`)),s&&(s.style.minHeight="0px",ve&&console.log(`[Chunk Error] Reset minHeight to 0px for widget ${O}`)),I&&(I.style.opacity="0",I.removeAttribute("data-shimmer-active"))})};if(B){let e=!1;const t=()=>{e||(e=!0,V())},n=new IntersectionObserver(e=>{e.forEach(e=>{if(ve&&console.log(`[OBSERVER] Widget ${l}: isIntersecting=${e.isIntersecting}, top=${e.boundingClientRect.top}, bottom=${e.boundingClientRect.bottom}, viewportHeight=${window.innerHeight}, layoutHeight=${document.documentElement.clientHeight}`),e.isIntersecting){if("67841720509"===Pe){const e=s.getBoundingClientRect();if(e.top>=document.documentElement.clientHeight||e.bottom<=0)return void(ve&&console.log(`[OBSERVER] Widget ${l}: Rejected \u2014 outside layout viewport (iOS rescale guard)`))}ve&&console.log(`[OBSERVER] Widget ${l}: Loading React chunk`),t(),n.disconnect()}})},{threshold:0,rootMargin:"0px 0px 0px 0px"});n.observe(s);const i=s.getBoundingClientRect();ve&&console.log(`[SETUP] Widget ${l}: Observer attached, position top=${i.top}, bottom=${i.bottom}, viewportHeight=${window.innerHeight}, margin=500px`);const o=10;let r=window.pageYOffset;ve&&console.log(`[SCROLL LISTENER] Widget ${l}: Initial scroll position=${r}`);const a=()=>{const e=window.pageYOffset,n=Math.abs(e-r);ve&&console.log(`[SCROLL LISTENER] Widget ${l}: Scroll event fired, scrollY=${e}, lastScrollY=${r}, delta=${n}`),n>o&&(ve&&console.log(`[SCROLL LISTENER] Widget ${l}: Delta > ${o}, triggering load`),t(),window.removeEventListener("scroll",a))};window.addEventListener("scroll",a,{passive:!0})}else V()}else if(ye){const e=document.getElementById("whatmoreRoot"),t="whatmoreRoot",n=_e("whatmoreTemplateType","invalid-template"),o=xe(n),r=fe(n),a=we(n);Promise.all([i.e(609),i.e(268)]).then(i.bind(i,1592)).then(i=>{i.initializeReactApp({rootElement:e,templateType:n,isStoriesTemplate:o,isCollectionsTemplate:r,_isTemplateTypeBanner:a,whatmoreCollectionId:"",whatmoreCollectionHeading:"",whatmoreHeadingCarousel:"",whatmoreWidgetIdentity:"wgt_default",whatmoreRootId:t,landingLocationType:Se,isInPreviewMode:Te,userType:Ie})}).catch(e=>{console.error("Whatmore: Failed to load React chunk for legacy store:",e)})}}()}();
1
+ /*! For license information please see main.520d08ef.js.LICENSE.txt */
2
+ !function(){"use strict";var e,t={964:function(e,t,n){n.d(t,{$$:function(){return o},DK:function(){return u},Dk:function(){return s},K1:function(){return c},MT:function(){return a},OL:function(){return h},Sx:function(){return g},TB:function(){return p},YZ:function(){return i},aD:function(){return r},mM:function(){return l},qW:function(){return d},rz:function(){return m}});const i="58669793418",o="https://consumer.whatmore.live",r="https://whatmore-api-cdn-cache.azureedge.net",a="https://cdn-consumer.whatmore.live",d="https://analytics.whatmore.live",l=!1,s="carousel",c="video_popup",h="stories",m="collections",p="homepage",u="product_page",g="collection_page"},1578:function(e,t,n){n.d(t,{S:function(){return d}});var i=n(2089),o=n(4533),r=n(7714),a=n(9211);const d=function(){const e=(0,o.wm)(),t=(0,o.zv)(),n=navigator.userAgent,d=(0,r.R)();let l;const s=localStorage.getItem("wht_show_carousel");var c;"75310563627"===d&&null!==s?l="true"===s?"jockey-test-group":"jockey-control-group":l=null!==(c=localStorage.getItem("wht_user_group"))&&void 0!==c?c:"";const h=window.location.hostname,m=window.location.pathname,p=(0,i.Ak)(),u=Math.round((new Date).getTime()/1e3),g=function(){var e;return null!==(e=a.A.get("_shopify_s"))&&void 0!==e?e:""}(),v=function(){var e;return null!==(e=a.A.get("_shopify_y"))&&void 0!==e?e:""}(),w="undefined"!==typeof window&&window.whatmore&&window.whatmore.abTestConfig||null;return{user_id:e,session_id:t,user_group:l,ab_test_id:w&&null!=w.ab_test_id?w.ab_test_id:null,ab_test_version:w&&null!=w.version?w.version:null,user_agent:n,store_id:d,hostname:h,page_path:m,event_id:p,event_timestamp:u,shopify_session_id:g,shopify_user_id:v}}},2089:function(e,t,n){n.d(t,{Ak:function(){return i}});let i=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce((e,t)=>e+=(t&=63)<36?t.toString(36):t<62?(t-26).toString(36).toUpperCase():t>62?"-":"_","")},3782:function(e,t,n){n.d(t,{A:function(){return i},H:function(){return o}});const i=n(964).mM?4:null;function o(e){if(!e||0===e.length)return e;if(null!==i){return e.slice(0,i)}return e}},3924:function(e,t,n){n.d(t,{Z:function(){return p},$:function(){return m}});var i=n(4901);const o=function(e,t){const n={metric_event_list:e},o=void 0!==t?t:e.length<10;return(0,i.d)(n,o)},r="_whatmore_bulk_events",a=9,d=9e3;let l=null,s=!1;function c(){try{return JSON.parse(localStorage.getItem(r))||[]}catch(e){return[]}}function h(){null===l&&0!==c().length&&(l=setTimeout(()=>{l=null,m()},d))}function m(e){if(s&&!e)return Promise.resolve();const t=c();if(0===t.length)return Promise.resolve();s=!0,null!==l&&(clearTimeout(l),l=null);const n=new Set(t.map(e=>e.event_id));return o(t,e).then(()=>{const e=c().filter(e=>!n.has(e.event_id));e.length>0?localStorage.setItem(r,JSON.stringify(e)):localStorage.removeItem(r)}).catch(()=>{}).finally(()=>{s=!1,h()})}function p(e){const t=c();t.push(e),localStorage.setItem(r,JSON.stringify(t)),t.length>=a?m():h()}},4533:function(e,t,n){n.d(t,{CK:function(){return S},Ch:function(){return P},Fu:function(){return y},Hm:function(){return T},NF:function(){return $},d3:function(){return z},wm:function(){return _},zv:function(){return b}});var i=n(2089),o=n(7714),r=n(3924);const a="_whatmore_user_id",d="_whatmore_session_id",l="_whatmore_viewed_products",s="_whatmore_add_to_cart_products",c="_whatmore_session_time",h="_whatmore_store_id",m="_whatmore_qview_index",p="_whatmore_brand_questions",u="_whatmore_seen_questions",g="w_user_type",v=(0,o.R)(),w=18e5,f=2592e5,x=6e5;function _(){localStorage.getItem(h)!=v&&localStorage.setItem(h,v),null==localStorage.getItem(a)&&function(){new Date;const e=(0,i.Ak)();localStorage.setItem(a,e)}();const e=new Date,t=localStorage.getItem(c);return null==t?localStorage.setItem(g,"newuser"):null!==t&&e.getTime()>t&&localStorage.setItem(g,"olduser"),localStorage.getItem(a)}function b(){const e=new Date,t=localStorage.getItem(c);return(null==localStorage.getItem(d)||null==t||e.getTime()>t)&&(localStorage.removeItem(d),localStorage.removeItem(c),function(){const e=(0,i.Ak)(),t=(new Date).getTime()+w;localStorage.setItem(d,e),localStorage.setItem(c,t)}(),(0,r.$)()),localStorage.getItem(d)}function y(e,t,n,i,o){const r=(new Date).getTime(),a={event_id:e.event_id,product_id:t.client_product_id,product_title:t.title,price:t.price,timestamp:r,widget_info:n,location:i,user_type:o?"olduser":"newuser",variants:[]};if(null===localStorage.getItem(s))localStorage.setItem(s,JSON.stringify([a]));else{let e=JSON.parse(localStorage.getItem(s)).filter(e=>e.timestamp+f>r);localStorage.setItem(s,JSON.stringify([...e,a]))}}function P(e,t,n,i,o,r="default",a){const d=[],s=(new Date).getTime();if(localStorage.setItem("_whatmore_last_video_view_session",b()),t.map(t=>{const l={event_id:e,product_id:t.client_product_id,product_title:t.title,price:t.price,timestamp:s,variants:[],page:n,widget_type:i,widget_info:o,location:r,user_type:a?"olduser":"newuser"};d.push(l)}),null===localStorage.getItem(l))console.debug("viewed Products",JSON.stringify(d)),localStorage.setItem(l,JSON.stringify(d));else{let t=JSON.parse(localStorage.getItem(l)),n=!1;t.map(t=>{let i=Object.assign({},t);return t.event_id===e&&(t.timestamp=s,n=!0),i}),n?localStorage.setItem(l,JSON.stringify(t)):localStorage.setItem(l,JSON.stringify([...t,...d]))}}function S(){const e=(new Date).getTime();let t=JSON.parse(localStorage.getItem(l));if(!t)return[];let n=t.filter(t=>t.timestamp+f>e);return localStorage.setItem(l,JSON.stringify(n)),n}function T(){if(null!=localStorage.getItem(m)){const e=parseInt(localStorage.getItem(m))+1;localStorage.setItem(m,e)}}function I(){const e=localStorage.getItem(u);return new Set(e?JSON.parse(e):[])}function $(e){const t=I();t.add(e),localStorage.setItem(u,JSON.stringify([...t]))}function z(e){const t=(new Date).getTime(),n=JSON.parse(localStorage.getItem(p));if(!n||(null===n||void 0===n?void 0:n.timestamp)+x<t){const n=null===e||void 0===e?void 0:e.filter(e=>!0===(null===e||void 0===e?void 0:e.is_active)),i=I(),o={questionList:n.filter(e=>!i.has(e.id)),timestamp:t};localStorage.setItem(p,JSON.stringify(o)),localStorage.setItem(m,"0")}}},4901:function(e,t,n){n.d(t,{d:function(){return r}});var i=n(964),o=n(6641);const r=function(e,t){const n="ingesting analytis-event";return(0,o.gv)(n),fetch(i.qW+"/event_metrics/bulk",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e),keepalive:t}).then(e=>{if(!e.ok)throw new Error(n+" failed: HTTP "+e.status);return e}).catch(e=>{throw console.error("error "+n,e),e})}},6005:function(e,t,n){n.d(t,{A:function(){return i}});const i=function(e,t,n,i){var o,r;return{landing_location_type:t.landingLocationType,template_type:t.templateType,whatmore_event:{id:e.event_id,event_type:null!==(o=null===e||void 0===e?void 0:e.event_type)&&void 0!==o?o:null,eventset_id:null!==(r=e.eventset_id)&&void 0!==r?r:null,cta_list:i.map(e=>e.cta_id),product_list:n.map(e=>e.product_id)}}}},6157:function(e,t,n){n.d(t,{O:function(){return i},l:function(){return o}});const i=Object.freeze({EVENT_VIEW:"event-view",PRODUCT_CTA_VIEW:"product-cta-view",SHOPNOW_ATC_CLICKED:"shop-now-atc-clicked",SHOPNOW_BUYNOW_CLICKED:"shop-now-buy-now-clicked",SHOPNOW_VIEWMORE_CLICKED:"shop-now-view-more-clicked",SHOPNOW_PRODUCT_TITLE_CLICKED:"shop-now-product-title-clicked",VIDEO_TILE_PRODUCT_THUMBNAIL_CLICKED:"video-tile-product-thumbnail-clicked",PRODUCT_TILE_ATC_CLICKED:"product-tile-atc-clicked",PRODUCT_TILE_SHOPNOW_CLICKED:"product-tile-shopnow-clicked",VIDEO_LIKED:"video-liked",VIDEO_UNLIKED:"video-unliked",VIDEO_SHARE_CTA_CLICKED:"video-share-cta-clicked",VIDEO_MUTED:"video-muted",HOMEPAGE_CAROUSEL_SWIPED:"homepage-carousel-swiped",HOMEPAGE_VISITED:"homepage-visited",COLLECTION_PAGE_VISITED:"collection-page-visited",PDP_VISITED:"product-page-visited",PAGE_VISITED:"page-visited",FIRST_TOUCH:"first-touch",HOMEPAGE_CAROUSEL_WIDGET_VIEW:"homepage-carousel-widget-view",BANNER_WIDGET_VIEW:"banner-widget-view",STORIES_WIDGET_VIEW:"stories-widget-view",COLLECTION_WIDGET_VIEW:"collection-widget-view",SPOTLIGHT_WIDGET_VIEW:"spotlight-widget-view",PDP_POPUP_WIDGET_VIEW:"pdp-popup-widget-view",PDP_POPUP_CLOSED:"pdp-popup-closed",VIDEO_PLAYBACK:"video-watched",SHOPNOW_CLICKED:"shopnow-clicked",WHATSAPP_ICON_CLICKED:"whatsapp-icon-clicked",BANNER_WIDGET_CLICKED:"banner-widget-clicked",QUESTION_VIEWED:"question-viewed",QUESTION_ANSWERED:"question-answered",QUESTION_CLOSED:"question-closed",PRODUCT_TILE_ALL_ATC_CLICKED:"product-tile-all-atc"}),o=function(e,t){return{name:e,metadata:t}}},6641:function(e,t,n){n.d(t,{Fk:function(){return s},gv:function(){return l},xv:function(){return d}});var i=n(7714);const o="Whatmore : ",r=(0,i.R)();function a(e){console.debug(o+e)}function d(e,t="200"){var n;null!==(n="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==n&&n&&(a("total events received : "+(e&&e.length)),a("events data : "+JSON.stringify(e)))}function l(e){var t;null!==(t="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==t&&t&&a(e)}const s=e=>{"STR60LW4WMA"!=r&&"77604192550"!=r&&"80856187185"!=r&&"86486974743"!=r&&console.log(`%c ${e}`,"background: #D53F8C; color: white; font-size: 19px; padding: 5px; font-weight: semibold;","\n\nFind us here -> https://www.whatmore.ai/shoppable-videos/")}},7714:function(e,t,n){n.d(t,{R:function(){return r},y:function(){return a}});var i=n(964);function o(e,t){const n=document.getElementById(e);return n&&(n.getAttribute("data-wh")||n.getAttribute("data"))||t}function r(){return o("whatmoreShopId",i.YZ)}function a(){return o("whatmoreExtensionType","index")}},9211:function(e,t,n){function i(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)e[i]=n[i]}return e}n.d(t,{A:function(){return o}});var o=function e(t,n){function o(e,o,r){if("undefined"!==typeof document){"number"===typeof(r=i({},n,r)).expires&&(r.expires=new Date(Date.now()+864e5*r.expires)),r.expires&&(r.expires=r.expires.toUTCString()),e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var d in r)r[d]&&(a+="; "+d,!0!==r[d]&&(a+="="+r[d].split(";")[0]));return document.cookie=e+"="+t.write(o,e)+a}}return Object.create({set:o,get:function(e){if("undefined"!==typeof document&&(!arguments.length||e)){for(var n=document.cookie?document.cookie.split("; "):[],i={},o=0;o<n.length;o++){var r=n[o].split("="),a=r.slice(1).join("=");try{var d=decodeURIComponent(r[0]);if(i[d]=t.read(a,d),e===d)break}catch(l){}}return e?i[e]:i}},remove:function(e,t){o(e,"",i({},t,{expires:-1}))},withAttributes:function(t){return e(this.converter,i({},this.attributes,t))},withConverter:function(t){return e(i({},this.converter,t),this.attributes)}},{attributes:{value:Object.freeze(n)},converter:{value:Object.freeze(t)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"})}},n={};function i(e){var o=n[e];if(void 0!==o)return o.exports;var r=n[e]={id:e,loaded:!1,exports:{}};return t[e](r,r.exports,i),r.loaded=!0,r.exports}i.m=t,i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};i.t=function(n,o){if(1&o&&(n=this(n)),8&o)return n;if("object"===typeof n&&n){if(4&o&&n.__esModule)return n;if(16&o&&"function"===typeof n.then)return n}var r=Object.create(null);i.r(r);var a={};e=e||[null,t({}),t([]),t(t)];for(var d=2&o&&n;("object"==typeof d||"function"==typeof d)&&!~e.indexOf(d);d=t(d))Object.getOwnPropertyNames(d).forEach(function(e){a[e]=function(){return n[e]}});return a.default=function(){return n},i.d(r,a),r}}(),i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=function(e){return Promise.all(Object.keys(i.f).reduce(function(t,n){return i.f[n](e,t),t},[]))},i.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)+"."+{254:"8f875a40",259:"74afe936",260:"1f2eaea7",268:"cc28aec5",323:"88610351",609:"cbc87aba",760:"4fc9dda6",939:"2bfaec5c",942:"69c4e83e"}[e]+".chunk.js"},i.miniCssF=function(e){return"static/css/"+{260:"event-click-component",268:"react-main-app",760:"homepage-carousel-view"}[e]+"."+{260:"f4759a24",268:"ab25aace",760:"522128da"}[e]+".chunk.css"},i.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={},t="whatmorelive-react:";i.l=function(n,o,r,a){if(e[n])e[n].push(o);else{var d,l;if(void 0!==r)for(var s=document.getElementsByTagName("script"),c=0;c<s.length;c++){var h=s[c];if(h.getAttribute("src")==n||h.getAttribute("data-webpack")==t+r){d=h;break}}d||(l=!0,(d=document.createElement("script")).charset="utf-8",d.timeout=120,i.nc&&d.setAttribute("nonce",i.nc),d.setAttribute("data-webpack",t+r),d.src=n),e[n]=[o];var m=function(t,i){d.onerror=d.onload=null,clearTimeout(p);var o=e[n];if(delete e[n],d.parentNode&&d.parentNode.removeChild(d),o&&o.forEach(function(e){return e(i)}),t)return t(i)},p=setTimeout(m.bind(null,void 0,{type:"timeout",target:d}),12e4);d.onerror=m.bind(null,d.onerror),d.onload=m.bind(null,d.onload),l&&document.head.appendChild(d)}}}(),i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},i.p="https://cdn.jsdelivr.net/npm/whatmore-react-assets@latest/",function(){if("undefined"!==typeof document){var e=function(e){return new Promise(function(t,n){var o=i.miniCssF(e),r=i.p+o;if(function(e,t){for(var n=document.getElementsByTagName("link"),i=0;i<n.length;i++){var o=(a=n[i]).getAttribute("data-href")||a.getAttribute("href");if("stylesheet"===a.rel&&(o===e||o===t))return a}var r=document.getElementsByTagName("style");for(i=0;i<r.length;i++){var a;if((o=(a=r[i]).getAttribute("data-href"))===e||o===t)return a}}(o,r))return t();!function(e,t,n,o,r){var a=document.createElement("link");a.rel="stylesheet",a.type="text/css",i.nc&&(a.nonce=i.nc),a.onerror=a.onload=function(n){if(a.onerror=a.onload=null,"load"===n.type)o();else{var i=n&&n.type,d=n&&n.target&&n.target.href||t,l=new Error("Loading CSS chunk "+e+" failed.\n("+i+": "+d+")");l.name="ChunkLoadError",l.code="CSS_CHUNK_LOAD_FAILED",l.type=i,l.request=d,a.parentNode&&a.parentNode.removeChild(a),r(l)}},a.href=t,n?n.parentNode.insertBefore(a,n.nextSibling):document.head.appendChild(a)}(e,r,null,t,n)})},t={792:0};i.f.miniCss=function(n,i){t[n]?i.push(t[n]):0!==t[n]&&{260:1,268:1,760:1}[n]&&i.push(t[n]=e(n).then(function(){t[n]=0},function(e){throw delete t[n],e}))}}}(),function(){var e={792:0};i.f.j=function(t,n){var o=i.o(e,t)?e[t]:void 0;if(0!==o)if(o)n.push(o[2]);else{var r=new Promise(function(n,i){o=e[t]=[n,i]});n.push(o[2]=r);var a=i.p+i.u(t),d=new Error;i.l(a,function(n){if(i.o(e,t)&&(0!==(o=e[t])&&(e[t]=void 0),o)){var r=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;d.message="Loading chunk "+t+" failed.\n("+r+": "+a+")",d.name="ChunkLoadError",d.type=r,d.request=a,o[1](d)}},"chunk-"+t,t)}};var t=function(t,n){var o,r,a=n[0],d=n[1],l=n[2],s=0;if(a.some(function(t){return 0!==e[t]})){for(o in d)i.o(d,o)&&(i.m[o]=d[o]);if(l)l(i)}for(t&&t(n);s<a.length;s++)r=a[s],i.o(e,r)&&e[r]&&e[r][0](),e[r]=0},n=self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))}(),i.nc=void 0;const o="whatmore_brand_customizations",r=null!==(e="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==e&&e;function a(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)),r&&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 n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}async function s(e){var t,n;if(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd0d Getting customizations...`),null!==(t=window)&&void 0!==t&&null!==(n=t.whatmore)&&void 0!==n&&n.frontendCustomizations&&"object"===typeof window.whatmore.frontendCustomizations){r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from window.whatmore.frontendCustomizations`);const e=window.whatmore.frontendCustomizations;return d(e),e}const i=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(i)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Using customizations from cache`),i;r&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No cached customizations, fetching from backend...`);const a=await async function(e){try{r&&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 n=await t.json();return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u2705 Customizations fetched from backend`),d(n),n}catch(t){return console.error("Whatmore: Error fetching customizations from backend:",t),null}}(e);return a}function c(e,t,n,i,o){if(n)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udccc Shared link detected - immediate load`),!1;if("template-embed"===i)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udecd\ufe0f Embed widget - immediate load on every page`),!1;if(!e)return r&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a0\ufe0f No customizations - defaulting to immediate load`),!1;const a=l(e,"lazy_load_config->block_widgets"),d=l(e,"collections_config->show_popup_out_of_view");return t&&d?(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udce6 Collections with showPopupOutOfView=true - immediate load`),!1):a?(r&&console.log(`[${(new Date).toLocaleTimeString()}] \ud83d\udd04 lazyloadConfig_blockWidget=true - lazy load enabled`),!0):(r&&console.log(`[${(new Date).toLocaleTimeString()}] \u26a1 lazyloadConfig_blockWidget=false - immediate load`),!1)}const h=.6,m=.7,p=.8,u=16/9;function g(e){return(t,n)=>{const i=e.querySelector(`#${t}`);if(!i)return n;return i.getAttribute("data-wh")||i.getAttribute("data")||n}}function v(e,t){if(!e)return null;const n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}function w(e,t){const n=e>t,i=e>=481;return n&&i?"desktop":!n&&i?"tablet":n&&!i?"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 _(e,t){if(!t.startsWith("product"))return 0;const n=.055*e;return Math.round(12+1.2*n*2)}function b(e){var t,n;const{widgetContainer:i,customizations:o,windowWidth:r,windowHeight:a,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"))}}(i),s=w(r,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*p*e,i=d*p*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:r,windowHeight:a,liquidVars:l,customizations:o}),_=Math.ceil(c.slidesPerView),b=void 0!==d?d:_,y=null!==(t=v(o,"event_tile_config->show_product_thumbnail"))&&void 0!==t&&t,P=function(e){var t,n,i;const{width:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_config->show_product_thumbnail"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=null!==(n=v(a,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==n?n:1,s=null!==(i=v(a,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==i?i:1,c=d?l:s,h=d?1.076*o*c:o*c,m=1.2*h,p=1.2*h,u=h;return Math.round(24+m+5+p+5+u)}({width:c.width,deviceMode:s,customizations:o}),S=x(l.heading,l.titleFontSize),T=null!==(n=v(o,"carousel_config->width_multiplier"))&&void 0!==n?n:1.1,I=l.topBottomPadding+S+25+c.height+P+25+l.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,showProductInfo:o,productInfoHeight:r,headingHeight:a,topBottomPadding:d,landscapePadding:l,deviceMode:s,windowWidth:c,windowHeight:h,slidesPerView:m,widthMultiplier:p}=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%;">`;a>0&&(v+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <p style="\n height: ${a}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*m*p)}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?i: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*p)}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: ${n}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:b,showProductInfo:y,productInfoHeight:P,headingHeight:S,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:r,windowHeight:a,slidesPerView:c.slidesPerView,widthMultiplier:T});return{totalHeight:Math.round(I),shimmerHTML:$,topBottomPadding:l.topBottomPadding}}function y(e,t){var n,i,o;const r=(null===(n=e.querySelector("#whatmoreShopId"))||void 0===n?void 0:n.getAttribute("data-wh"))||(null===(i=e.querySelector("#whatmoreShopId"))||void 0===i?void 0:i.getAttribute("data"));if("51273072796"==r||"64967540952"==r)return[document.documentElement.clientHeight,document.documentElement.clientWidth];const a=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"),a&&console.log("Set currElement width to 100% !important"))}return[window.innerHeight,l]}function P(e){var t,n;const{widgetContainer:i,customizations:o,eventCount:r}=e,[a,d]=y(i),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"))}}(i),s=w(d,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){var g;const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;const a=null!==(g=v(r,"event_tile_config->space_between_tiles"))&&void 0!==g?g:1;s=f(n/(1.15*t))*a,c=0,d=i,l=t}else if("tablet"===t){var w;const e=o.videoTileSizePortrait/100;let t=l*p*e,i=d*p*e;const a=null!==(w=v(r,"event_tile_config->space_between_tiles"))&&void 0!==w?w:1;s=f(n/(1.2*t))*a,c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:1.2*d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:a,liquidVars:l,customizations:o}),_=Math.ceil(c.slidesPerView),b=void 0!==r?r:_,P=x(l.heading,l.titleFontSize),S=null!==(t=v(o,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,T=("desktop"===s||"mobileLandscape"===s)&&null!==(n=v(o,"event_tile_config->gap_between_tiles"))&&void 0!==n?n:0,I=l.topBottomPadding+P+25+c.height+25+l.topBottomPadding,$=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,headingHeight:o,topBottomPadding:r,landscapePadding:a,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c,spaceBetween:h}=e,m="desktop"===d||"mobileLandscape"===d;let p=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${r}px; margin-bottom: ${r}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="${m?"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 ${m?`padding-left: ${a}px; padding-right: ${a}px;`:""}\n ">`,p+=`\n <div style="\n width: ${m?t*s*c+"px":l+"px"};\n height: 100%;\n overflow: hidden;\n ">`,m){p+=`<div style="margin: 0 auto; display: flex; gap: ${h}px; align-items: center; width: max-content;">`;for(let e=0;e<i;e++)p+=`\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: ${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 </div>\n `}else{const e=l/s;p+=`<div style="display: flex; transform: translate3d(${l/2-1.5*e}px, 0px, 0px);">`;for(let i=0;i<3;i++)p+=`\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: ${n}px;\n background: #e0e0e0;\n border-radius: 5px;\n position: relative;\n overflow: hidden;\n transform: ${1===i?"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 p+="\n </div>",p+="\n </div>",p+="\n</div>",p+="\n</div>",p+="\n</div>",p}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:b,headingHeight:P,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:c.slidesPerView,widthMultiplier:S,spaceBetween:T});return{totalHeight:I,shimmerHTML:$}}function S(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*p*e,d=d*p*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*m,t=a*m;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:a*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s=a.collectionsTilesSpacing,c=_(l.width,a.extensionType),v="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,f=l.width+10,x=Math.ceil(v/(f+s))+1,b=void 0!==i?i:x,P=a.topBottomPadding+l.height+10+c+a.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${i}px; margin-bottom: ${i}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: ${n}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,numberOfTiles:b});return{totalHeight:P,shimmerHTML:S}}function T(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),extensionType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*p*e,d=d*p*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*m,t=a*m;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,d=t}const s="mobilePortrait"===t||"tablet"===t?o.videoTileSizePortrait:o.videoTileSize;return{height:a*s*.01,width:d*s*.01,landscapePadding:l}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s=a.collectionsTilesSpacing,c=_(l.width,a.extensionType),v="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,f=l.width+4,x=Math.ceil(v/(f+s))+1,b=void 0!==i?i:x,P=a.topBottomPadding+l.height+4+c+a.topBottomPadding,S=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,tilesSpacing:d,numberOfTiles:l}=e;let s=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${i}px; margin-bottom: ${i}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: ${n}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,numberOfTiles:b});return{totalHeight:P,shimmerHTML:S}}function I(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),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")),collectionsTilesSpacing:parseInt(t("whatmoreCollectionsTilesSpacing","3")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24")),extensionType:t("whatmoreExtensionType","index"),landingLocationType:t("whatmoreExtensionType","index")}}(t),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d,l;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;l=0,a=a*p*e,d=d*p*e}else if("mobileLandscape"===t){o.videoTileSize;let e=d*m,t=a*m;l=o.landscapePadding,a=t,d=e}else{const e=o.videoTileSize/100*1.3*.5;let t=d*e,n=a*e;l=o.landscapePadding,a=n,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)*a*s*.01,width:d*s*.01,landscapePadding:l,unscaledWidth:d}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a}),s="68304765103"===a.shopId?"mobilePortrait"===d||"tablet"===d?6:20:a.collectionsTilesSpacing,c=x(a.heading,a.titleFontSize),f=("mobilePortrait"===d||"tablet"===d?a.videoTileSizePortrait:a.videoTileSize,function(e,t,n,i,o){var r,a,d,l,s;if(i.startsWith("product"))return 0;const c="mobilePortrait"===t||"tablet"===t,h=null!==(r=v(o,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==r?r:.022,m=null!==(a=v(o,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==a?a:.015,p=c?1.076*e*h:e*m,u=.9*p,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*p,_=w&&f?Math.ceil(1.2*x):0,b=null!==(s=v(o,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==s&&s,y=c?10:12,P=Math.max(9,.75*p),S=b?y+Math.ceil(P):0;let T=0;return _>0&&T++,S>0&&T++,12+g+_+2+S+4*T}(l.unscaledWidth,d,a.shopId,a.landingLocationType,n)),_="desktop"===d||"mobileLandscape"===d?r-2*l.landscapePadding:r,b=l.width+4,P=Math.ceil(_/(b+s))+1,S=void 0!==i?i:P,T=a.topBottomPadding+c+l.height+4+f+a.topBottomPadding,I=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,landscapePadding:o,deviceMode:r,windowWidth:a,tilesSpacing:d,headingHeight:l,numberOfTiles:s,shopId:c,landingLocationType:h,unscaledWidth:m,customizations:p}=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: ${i}px; margin-bottom: ${i}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: ${n}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"===r||"tablet"===r,t=null!==(f=v(p,"event_tile_with_product_info->portrait_font_multiplier"))&&void 0!==f?f:.022,n=null!==(x=v(p,"event_tile_with_product_info->landscape_font_multiplier"))&&void 0!==x?x:.015,i=e?1.076*m*t:m*n,o=e?4:8,a=6,d=4,l=.9*i,s=Math.ceil(1.15*l),c=null===(_=v(p,"product_config->show_product_price"))||void 0===_||_,h=null===(b=v(p,"event_tile_with_product_info->show_price_info"))||void 0===b||b,u=.9*i,g=Math.ceil(1.2*u),P=null!==(y=v(p,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==y&&y,S=e?10:12,T=Math.max(9,.75*i),I=2,$=S+Math.ceil(T);w+=`\n <div style="\n display: flex;\n flex-direction: row;\n padding: ${a}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: ${$}px;\n height: ${$}px;\n width: 100%;\n background: #e0e0e0;\n border-radius: 4px;\n margin-top: ${I}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:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,tilesSpacing:s,headingHeight:c,numberOfTiles:S,shopId:a.shopId,landingLocationType:a.landingLocationType,unscaledWidth:l.unscaledWidth,customizations:n});return{totalHeight:T,shimmerHTML:I}}const $=function(e,t){return e<=768?t>e?"mobilePortrait":"mobileLandscape":e<=1024?"tablet":"desktop"};function z({tileWidth:e,tileHeight:t,numberOfTiles:n,headingHeight:i,topBottomPadding:o,landscapePadding:r,deviceMode:a,windowWidth:d,gap:l,productInfoHeight:s,customizations:c,liquidVars:h}){const m="mobilePortrait"===a||"tablet"===a;let p=`<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%;">`;i>0&&(p+=`\n <div style="display: flex; justify-content: center; align-items: center; margin-bottom: 16px;">\n <div style="\n width: 200px;\n height: ${i-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,n,i,o){var r,a,d;const l="mobilePortrait"===t||"tablet"===t,s=null===(r=v(i,"product_config->show_product_price"))||void 0===r||r,c=null===(a=v(i,"event_tile_with_product_info->show_price_info"))||void 0===a||a,h=null!==(d=v(i,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==d&&d,m="76767920441"===o.shopId||"55840899223"===o.shopId,p=l?1.076*e*.04:.04*e;let u=null;if(m)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*p}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*p}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*p+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: ${m&&l?"6px 4px":"12px 4px"};\n gap: ${m&&l?"4px":"12px"};\n align-items: stretch;\n ">\n ${m&&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: ${m&&l?"2px":"5px"};\n flex: 1;\n min-width: 0;\n ">\n ${g}\n ${w}\n ${f}\n </div>\n </div>\n `}(e,a,0,c,h):"";p+=`\n <div class="${m?"whatmore-shimmer-events-carousel-portrait":"whatmore-shimmer-events-carousel-landscape"}" style="\n display: flex;\n justify-content: ${m?"flex-start":"center"};\n align-items: center;\n ${m?"padding-left: 12px;":`padding-left: ${r}px; padding-right: ${r}px;`}\n position: relative;\n overflow: hidden;\n ">`,m||(p+=`\n \x3c!-- Left navigation button --\x3e\n <div style="\n position: absolute;\n left: ${r}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: ${r}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 `),p+=`\n <div style="display: flex; gap: ${l}px; overflow: hidden;">`;for(let g=0;g<n;g++)p+=`\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 p+="\n </div>",p+="\n </div>",p+="\n </div>",p+="\n</div>",p}function k(e){const{widgetContainer:t,customizations:n,eventCount:i}=e,[o,r]=y(t),a=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=$(r,o),l=function({deviceMode:e,windowWidth:t,windowHeight:n,liquidVars:i,customizations:o}){var r;const a="mobilePortrait"===e||"tablet"===e?i.tileSizePortrait:i.tileSize,d=t>n,l="mobilePortrait"===e&&t>=481,s=a/100*1.3*.5,c=a/100,g=Math.min(t,n);let w=g*h*u,x=g*h,_=0,b=1.4;const y=null!==(r=v(o,"carousel_config->theme_margin"))&&void 0!==r?r:0;if(d){const e=x*s,n=w*s,o=i.landscapePadding||0;x=e,w=n,_=o,b=(t-2*o-2*y)/(1.1*e)}else if(l){let n=x*p,o=w*p;if("mobilePortrait"===e)n*=c,o*=c,x=n,w=o,_=0,b=f(t/(1.2*n));else{const e=i.landscapePadding||0;x=n,w=o,_=e,b=(t-2*e)/(1.1*n)}}else{let n=x,o=w;if("mobilePortrait"===e)n=n*c*.9,o=o*c*.9,x=n,w=o,_=0,b=f(t/(1.15*n));else{n=x*m,o=w*m;const e=i.landscapePadding||0;x=n,w=o,_=e,b=(t-2*e)/(1.1*n)}}return{height:w,width:x,landscapePadding:_,slidesPerView:b}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a,customizations:n}),s=Math.ceil(l.slidesPerView),c=void 0!==i?i:s,w=x(a.heading,a.titleFontSize),_=function(e,t=24){const n=v(e,"event_tile_config->gap_between_tiles");return null!==n&&void 0!==n?0===n?24:n:t}(n),b=function({tileWidth:e,deviceMode:t,customizations:n}){var i,o,r;if(!v(n,"event_tile_with_product_info->show_product_info"))return 0;const a="mobilePortrait"===t||"tablet"===t,d=null!==(i=v(n,"event_tile_with_product_info->show_atc_button_outside_tile"))&&void 0!==i&&i,l=a?1.076*e*.04:.04*e,s=1.2*l+(null===(o=v(n,"product_config->show_product_price"))||void 0===o||o?1.2*l+5:0)+(null===(r=v(n,"event_tile_with_product_info->show_price_info"))||void 0===r||r?1.2*l+5:0)+(d?8+(a?36:44):0),c=d?110:s;return Math.round(Math.max(c,s+24))}({tileWidth:l.width,deviceMode:d,customizations:n}),P=a.topBottomPadding+w+25+l.height+b+10+a.topBottomPadding,S=z({tileWidth:l.width,tileHeight:l.height,numberOfTiles:c,headingHeight:w,topBottomPadding:a.topBottomPadding,landscapePadding:l.landscapePadding,deviceMode:d,windowWidth:r,windowHeight:o,gap:_,productInfoHeight:b,customizations:n,liquidVars:a});return{totalHeight:Math.round(P),shimmerHTML:S}}function M(e){const{customizations:t,widgetContainer:n,eventCount:i}=e,[o,r]=y(n),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")),extensionType:t("whatmoreExtensionType","index")}}(n),d=w(r,o),l=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o}=e,r=Math.min(n,i);let a,d;if(a=r*h*u,d=r*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;a=a*e*.9,d=d*e*.9}else if("tablet"===t){const e=o.videoTileSizePortrait/100;a=a*p*e,d=d*p*e}else if("mobileLandscape"===t)o.videoTileSize,a*=m,d*=m;else{const e=o.videoTileSize/100*1.3*.5;a*=e,d*=e}return{height:a,width:d}}({deviceMode:d,windowWidth:r,windowHeight:o,liquidVars:a});function s(e){return Math.round(10*e)/10}let c;c="mobilePortrait"===d?s(r/(1.15*l.width)):"tablet"===d?s(r/(1.2*l.width)):r/(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 n=.07*e;return 46+Math.ceil(2.5*n)}(l.width,t),_=.2*l.height,b=20+(3+l.height+3)+x,P=Math.ceil(i/f),S=a.topBottomPadding+P*b+(P-1)*_+a.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:n,topBottomPadding:i,eventCount:o,slidesPerView:r,atcButtonHeight:a,rowSpacing:d}=e,l=r,s=Math.ceil(o/l);let c=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${i}px;\n margin-bottom: ${i}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 i=0;i<e;i++)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: ${n}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>`,a>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:a.topBottomPadding,eventCount:i,slidesPerView:f,atcButtonHeight:x,rowSpacing:_});return{totalHeight:Math.round(S),shimmerHTML:T}}function H(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,[r,a]=y(n),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"))}}(n),l=w(a,r),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*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*p*e,i=d*p*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:a,windowHeight:r,liquidVars:d,customizations:i}),c=Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(d.heading,d.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=d.topBottomPadding+b+25+s.height+25+d.topBottomPadding,T=function(e){const{tileWidth:t,tileHeight:n,numberOfTiles:i,headingHeight:o,topBottomPadding:r,landscapePadding:a,deviceMode:d,windowWidth:l,slidesPerView:s,widthMultiplier:c}=e,h="desktop"===d||"mobileLandscape"===d;let m=`<div class="whatmore-shimmer-widget-container" style="height: 100%; margin-top: ${r}px; margin-bottom: ${r}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="${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: ${a}px; padding-right: ${a}px;`:""}\n ">`,m+=`<div style="\n width: ${h?t*s*c+"px":l+"px"};\n height: fit-content;\n overflow: hidden;\n ">`,h){m+=`<div style="display: flex; gap: ${Math.round(t*c-t-20)}px; margin: 0 auto; width: max-content;">`;for(let e=0;e<i;e++)m+=`\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: ${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 </div>\n `}else{const e=l/s;m+='<div style="display: flex;">';for(let o=0;o<i;o++)m+=`\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: ${n}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 m+="\n </div>",m+="\n </div>",m+="\n </div>",m+="\n </div>",m+="\n</div>",m}({tileWidth:s.width,tileHeight:s.height,numberOfTiles:_,headingHeight:b,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:a,slidesPerView:s.slidesPerView,widthMultiplier:P});return{totalHeight:Math.round(S),shimmerHTML:T}}function C(e){var t,n;const{widgetContainer:i,customizations:o,eventCount:r}=e,[a,d]=y(i),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"))}}(i),s=w(d,a),c=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*p*e,i=d*p*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:s,windowWidth:d,windowHeight:a,liquidVars:l,customizations:o}),_=null!==(t=v(o,"event_tile_config->space_between_tiles"))&&void 0!==t?t:1,b=c.slidesPerView*_,P=Math.ceil(b),S=void 0!==r?r:P,T=x(l.heading,l.titleFontSize),I=null!==(n=v(o,"carousel_config->width_multiplier"))&&void 0!==n?n:1.1,$=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e,d=null!==(t=v(a,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t,l="mobilePortrait"===r||"tablet"===r,s=.25*o*1.25,c=v(a,"event_tile_with_product_info->portrait_font_multiplier"),h=v(a,"event_tile_with_product_info->landscape_font_multiplier"),m=l?1.076*o*c:o*h,p=Math.ceil(1.2*m),u=null===(n=v(a,"product_config->show_product_price"))||void 0===n||n,g=u?Math.ceil(1.2*m):0,w=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,f=l?.965*o*c:.859*o*h;let x=0;u&&x++,w&&x++;const _=p+g+(w?Math.ceil(f)+6:0)+5*x,b=d?Math.max(s,_):_;return Math.round(24+b)}({tileWidth:c.width,deviceMode:s,customizations:o}),z="mobilePortrait"===s||"tablet"===s?c.height*I:c.height,k=l.topBottomPadding+T+12+z+$+12+l.topBottomPadding,M=function(e){var t,n,i;const{tileWidth:o,tileHeight:r,numberOfTiles:a,headingHeight:d,topBottomPadding:l,landscapePadding:s,deviceMode:c,windowWidth:h,slidesPerView:m,widthMultiplier:p,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*m*p+"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,_="mobilePortrait"===c||"tablet"===c,b=.25*o,y=null===(n=v(g,"product_config->show_product_price"))||void 0===n||n,P=null===(i=v(g,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,S=v(g,"event_tile_with_product_info->portrait_font_multiplier"),T=v(g,"event_tile_with_product_info->landscape_font_multiplier"),I=_?1.076*o*S:o*T,$=Math.ceil(1.2*I),z=Math.ceil(1.2*I),k=_?.965*o*S:.859*o*T,M=Math.ceil(k)+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: ${b}px;\n height: ${1.25*b}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: ${$}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 ${y?`\n \x3c!-- Price row --\x3e\n <div style="display: flex; gap: 12px; align-items: center;">\n <div style="width: 60px; height: ${z}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: ${z}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: ${M}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 `,C=o,E=r*p,L=o,W=r;let O="";w||(O=`transform: translate3d(${-h/m/2}px, 0px, 0px);`);f+=`<div style="display: flex; gap: 0px; ${w?"margin: 0 auto; width: max-content;":O}">`;const B=w?a:3;for(let v=0;v<B;v++){const e=!w&&(0===v||2===v),t=!w&&1===v,n=t?C:e?L:o,i=t?E:e?W:r;f+=w?`\n <div style="flex-shrink: 0; width: ${o*m*p/m}px;">\n <div style="width: ${n}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${n}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 ${H}\n </div>\n </div>\n `:`\n <div style="flex-shrink: 0; width: ${h/m}px;">\n <div style="width: ${n}px; margin: 12px auto 12px auto; cursor: pointer;">\n \x3c!-- Template-H tile shimmer --\x3e\n <div style="\n width: ${n}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 ${H}\n </div>\n </div>\n `}return f+="</div>",f+="</div>",f+="</div>",f+="</div>",f}({tileWidth:c.width,tileHeight:c.height,numberOfTiles:S,headingHeight:T,topBottomPadding:l.topBottomPadding,landscapePadding:c.landscapePadding,deviceMode:s,windowWidth:d,slidesPerView:b,widthMultiplier:I,productInfoHeight:$,customizations:o});return{totalHeight:Math.round(k),shimmerHTML:M}}function E(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,[r,a]=y(n),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"))}}(n),l=w(a,r),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*p*e,i=d*p*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;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,n=d*e*1.3;c=o.landscapePadding,s=5,d=n,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:a,windowHeight:r,liquidVars:d,customizations:i}),c="desktop"===l||"mobileLandscape"===l?5:Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(d.heading,d.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_with_product_info->show_thumbnail_image"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=.25*o,s=v(a,"event_tile_with_product_info->portrait_font_multiplier"),c=v(a,"event_tile_with_product_info->landscape_font_multiplier"),h=d?1.076*o*s:o*c,m=Math.ceil(1.2*h),p=null===(n=v(a,"product_config->show_product_price"))||void 0===n||n,u=p?Math.ceil(1.2*h):0,g=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,w=d?.965*o*s:.859*o*c;let f=0;p&&f++,g&&f++;const x=m+u+(g?Math.ceil(w)+6:0)+5*f,_=Math.max(l,x);return Math.round(24+_)}({tileWidth:"mobilePortrait"===l||"tablet"===l?s.width*P:s.width,deviceMode:l,customizations:i}),T="desktop"===l||"mobileLandscape"===l?24:12,I="mobilePortrait"===l||"tablet"===l?s.height*P:s.height,$=d.topBottomPadding+b+T+I+S+12+d.topBottomPadding,z=function(e){var t;const{tileWidth:n,tileHeight:i,numberOfTiles:o,headingHeight:r,topBottomPadding:a,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:m,customizations:p}=e,u="desktop"===l||"mobileLandscape"===l;let g=`<div class="whatmore-shimmer-widget-container" style="\n height: 100%;\n margin-top: ${a}px;\n margin-bottom: ${a}px;\n overflow: hidden;\n ">\n <div class="whatmore-shimmer-carousel-events" style="height: 100%; overflow: hidden;">`;r>0&&(g+=`\n <div style="display: flex; flex-direction: column; justify-content: center; align-items: center;">\n <div style="\n height: ${r-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(p,"event_tile_with_product_info->show_thumbnail_image"))&&void 0!==t&&t&&m>0){var x,_;const e=.25*n;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(p,"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===(_=v(p,"event_tile_with_product_info->show_discount_label"))||void 0===_||_?'\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*n,o=s/2,r=(i+m)/2;g+=`<div style="display: flex; justify-content: center; align-items: center; position: relative; height: ${i+w+12+m}px;">`;for(let a=0;a<5;a++){const d=a-2,l=0===d,s=e[a],c=n*s,h=i*s;g+=`\n <div style="\n position: absolute;\n left: ${o+d*t-c/2}px;\n bottom: ${r-(h+(l?m: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=n,t=i,o=i*h;let r="";const a=s/c;r=`transform: translate3d(${-a/2}px, 0px, 0px);`,g+=`<div style="display: flex; gap: 0px; ${r}">`;const d=3;for(let n=0;n<d;n++)g+=`\n <div style="flex-shrink: 0; width: ${a}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===n?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:_,headingHeight:b,topBottomPadding:d.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:a,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:S,customizations:i});return{totalHeight:Math.round($),shimmerHTML:z}}function L(e){var t;const{widgetContainer:n,customizations:i,eventCount:o}=e,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")),heading:t("whatmoreHeading",""),titleFontSize:parseInt(t("whatmoreTitleFontSize","24"))}}(n),[a,d]=y(n),l=w(d,a),s=function(e){const{deviceMode:t,windowWidth:n,windowHeight:i,liquidVars:o,customizations:r}=e,a=Math.min(n,i);let d,l,s,c;if(d=a*h*u,l=a*h,"mobilePortrait"===t){const e=o.videoTileSizePortrait/100;let t=l*e*.9,i=d*e*.9;s=f(n/(1.15*t)),c=0,d=i,l=t}else if("tablet"===t){const e=o.videoTileSizePortrait/100;let t=l*p*e,i=d*p*e;s=f(n/(1.2*t)),c=0,d=i,l=t}else if("mobileLandscape"===t){let e=l*m,t=d*m;c=o.landscapePadding,s=(n-2*c)/(1.1*e),d=t,l=e}else{const e=o.videoTileSize/100*1.3*.5,t=l*e,i=d*e;c=o.landscapePadding,s=(n-2*c-0)/(1.1*t),d=i,l=t}return{height:d,width:l,slidesPerView:s,landscapePadding:c}}({deviceMode:l,windowWidth:d,windowHeight:a,liquidVars:r,customizations:i}),c=Math.ceil(s.slidesPerView),_=void 0!==o?o:c,b=x(r.heading,r.titleFontSize),P=null!==(t=v(i,"carousel_config->width_multiplier"))&&void 0!==t?t:1.1,S=function(e){var t,n,i;const{tileWidth:o,deviceMode:r,customizations:a}=e;if(null===(t=v(a,"event_tile_config->show_product_tile"))||void 0===t||!t)return 0;const d="mobilePortrait"===r||"tablet"===r,l=v(a,"event_tile_with_product_info->portrait_font_multiplier"),s=v(a,"event_tile_with_product_info->landscape_font_multiplier"),c=d?1.15*o*l:1.05*o*s,h=Math.ceil(1.2*c),m=d?1.2*o*l:1.1*o*s,p=null===(n=v(a,"product_config->show_product_price"))||void 0===n||n,u=p?Math.ceil(1.2*m):0,g=null===(i=v(a,"event_tile_with_product_info->show_discount_label"))||void 0===i||i,w=d?.8*o*l:.7*o*s;let f=0;f++,p&&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:i}),T="mobilePortrait"===l||"tablet"===l,I=T?16:32,$=b>0?T?12:16:0,z=T?16:0,k=s.height,M=r.topBottomPadding+I+b+$+z+0+0+k+S+0+r.topBottomPadding,H=function(e){var t;const{tileWidth:n,tileHeight:i,numberOfTiles:o,headingHeight:r,topBottomPadding:a,landscapePadding:d,deviceMode:l,windowWidth:s,slidesPerView:c,widthMultiplier:h,productInfoHeight:m,customizations:p}=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: ${a}px;\n margin-bottom: ${a}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"};">`;r>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: ${r-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?n*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;null!==(t=v(p,"event_tile_config->show_product_tile"))&&void 0!==t&&t&&m>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===(_=v(p,"product_config->show_product_price"))||void 0===_||_?'\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===(b=v(p,"event_tile_with_product_info->show_discount_label"))||void 0===b||b?'\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 y;const e=s-48,t=12,o=c*(null!==(y=v(p,"event_tile_config->space_between_tiles"))&&void 0!==y?y:1),r=(e-(o-1)*t)/o;f+=`<div style="display: flex; transform: translate3d(${e/2-(r+t+r/2)}px, 0px, 0px);">`;const a=3,d=1.02,l=.98;for(let s=0;s<a;s++){const e=0===s||2===s;f+=`\n <div style="\n width: ${r}px;\n flex-shrink: 0;\n margin-right: ${s<a-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: ${n}px;\n height: ${i}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=n*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: ${n}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: ${n}px;\n height: ${i}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:_,headingHeight:b,topBottomPadding:r.topBottomPadding,landscapePadding:s.landscapePadding,deviceMode:l,windowWidth:d,slidesPerView:s.slidesPerView,widthMultiplier:P,productInfoHeight:S,customizations:i});return{totalHeight:Math.round(M),shimmerHTML:H}}function W(e,t){if(!e)return null;const n=t.split("->");let i=e;for(const o of n){if(!i||"object"!==typeof i||!(o in i))return null;i=i[o]}return i}function O(e){var t;const{customizations:n,widgetContainer:i,eventCount:o}=e,[r,a]=y(i),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"))}}(i),l=r>a?"portrait":"landscape",s="portrait"===l?d.videoTileSizePortrait:d.videoTileSize,{WIDTH:c,HEIGHT:h,isPortrait:m}=function(e,t,n){const i=e>t,o=t>e,r=!(!o||!(e>=481)),a=.8,d=n/100*1.3*.5,l=n/100,s=Math.min(e,t);let c=.6*s,h=.6*s*(16/9);return i?(c*=d,h*=d):r?o?(c=c*a*l,h=h*a*l):(c*=a,h*=a):o?(c=c*l*.9,h=h*l*.9):(c*=.7,h*=.7),{WIDTH:c,HEIGHT:h,isPortrait:o}}(a,r,s),p="portrait"===l?0:d.landscapePadding,u=d.collectionsTilesSpacing,v=c*s*.01,w=W(n,"collections_config->story_tile_size_factor")||1,f=null!==(t=W(n,"collections_config->story_tile_shape"))&&void 0!==t?t:"circle",x=W(n,"collections_config->remove_borders"),_=parseInt(W(n,"collections_config->tile_margin_right"))||0,b=x?2:_||0,P=x?2:5,S=x?2:5,T="circle"===f?"50%":"6%",I=v*w,$="rectangle"===f?1.5*I:I,z=I,k=.8*(.055*c),M=P+$+10+S,H=2*d.topBottomPadding+M,C=a-2*p,E=z+b,L=Math.min(Math.ceil((C+u)/(E+u)),8),O=void 0!==o?o:L,B="landscape"===l?"whatmore-shimmer-events-carousel-landscape":"whatmore-shimmer-events-carousel-portrait";let V=`<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="${B}" style="\n margin-left: ${p}px;\n margin-right: ${p}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<O;g++)V+=`\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: ${b}px;\n margin-top: ${P}px;\n margin-bottom: ${S}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: ${$}px;\n width: ${I}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: ${z}px;\n padding-top: 10px;\n font-size: ${k}px;\n ">\n <p style="margin: 0; padding: 0; line-height: 0; height: 0;"></p>\n </div>\n </div>\n `;return V+="\n </div>\n </div>\n </div>\n </div>",{totalHeight:Math.round(H),shimmerHTML:V}}var B;const V=null!==(B="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==B&&B;function A(e,t,n,i){var o,r;const a=e<=t,d=parseInt(((e,t)=>{const n=document.querySelector(`#${e}`);return n&&(n.getAttribute("data-wh")||n.getAttribute("data"))||t})("whatmoreVideoTileSize","60")),l=v(n,"banner_config->portrait_multiplier"),s=v(n,"banner_config->landscape_multiplier"),c=d/100*(null!==l&&void 0!==l?l:1),h=d/100*(null!==s&&void 0!==s?s:1),m=a?null!==(o=v(n,"banner_config->portrait_aspect_ratio"))&&void 0!==o?o:1:null!==(r=v(n,"banner_config->landscape_aspect_ratio"))&&void 0!==r?r:.5625,p=a?e*c:e*h,u=v(n,"banner_config->is_full_screen")||!1,g=u?e*m:p*m;return{width:u?"100%":`${p}px`,height:`${g}px`,borderWidth:v(n,"theme_config->event_tile->border_width")||"0px",borderColor:v(n,"theme_config->event_tile->border_color")||"transparent",borderStyle:"solid",totalHeight:g}}function D(e){const{windowWidth:t,windowHeight:n,customizations:i,widgetContainer:o,widgetIdentity:r}=e,a=function(e){const t=window.whatmoreHpBannerEventCounts;if(!t)return null;if(e&&"wgt_default"!==e){const n=t[e];return n?n.tc:null}return t.tc||null}(r);if(null===a||void 0===a||0===a)return V&&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 n=t[e];return n?{landscape:n.landscape_poster||null,portrait:n.portrait_poster||null}:null}return{landscape:t.landscape_poster||null,portrait:t.portrait_poster||null}}(r);if(!d||!d.landscape&&!d.portrait)return V&&console.log("[Banner Shimmer] No poster URLs found"),null;const l=A(t,n,i),s=t<=n?d.portrait:d.landscape;if(!s)return V&&console.log("[Banner Shimmer] No poster URL for current orientation"),null;v(i,"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 q(e){return g(e)("whatmoreShopId",null)}function R(){return window.location.href.split(/[?#]/)[0]}function j(e,t,n,i){const o=q(e);if("index"===t&&"carousel"===n)return"homepage";if(t&&t.startsWith("product")){return v(i,"show_homepage_videos_in_pdp")?"homepage":function(e){return g(e)("whatmoreProductId",null)}(e)}if("collection"===n){let t;return"19506115"===o?t="343270603":v(i,"collections_config->use_page_link_as_collection_id")?t=v(i,"collections_config->multi_carousel_enabled")?function(e){return g(e)("whatmoreCollectionUrl",null)}(e):R():(t=function(e){return g(e)("whatmoreCollectionId",null)}(e),"0"===t&&(t=function(e){return g(e)("whatmorePageId",null)}(e)),t&&"0"!==t||(t=R())),t}return"carousel"===n?"homepage":null}function N(e,t){const n=q(e),i=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),r=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 n of t)if(e.querySelector(`.whatmore-template-type[data-wh="${n}"]`)||e.querySelector(`.whatmore-template-type[data="${n}"]`))return n;return null}(e),a=j(e,i,o,t),d=function(e){return g(e)("whatmoreWidgetIdentity","wgt_default")}(e);return{shopId:n,landingLocationType:i,widgetType:o,templateType:r,actualId:a,widgetIdentity:d,isValidId:(l=a,!(!l||null===l||"null"===l||""===l)&&/^\d+$/.test(String(l))||"homepage"===a)};var l}var F,U=i(3782);const G=null!==(F="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==F&&F;function J(e,t,n){const i=window.whatmorePdpCarouselEvents;if(!i)return null;if(t&&"wgt_default"!==t){var o;const r=t.split("_");if(r.length<2||!r[1])return null;const a=null===(o=i[`w_${r[1][0]}`])||void 0===o?void 0:o[t];if(!a)return null;const d=a.scope_mode||"all",l=a.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(n,"show_out_of_stock_videos")?a.etc:a.esc}{var r;const t=function(e){return"p_"+parseInt(e)%127}(e),o=null===(r=i[t])||void 0===r?void 0:r[e];if(!o)return null;return v(n,"show_out_of_stock_videos")?o.etc:o.esc}}function K(e,t,n){var i,o;const r=null===(i=window.whatmore)||void 0===i?void 0:i.collectionMetafields;if(!r)return null;const a=function(e){return"c_"+parseInt(e)%63}(e);let d=e;t&&"wgt_default"!==t&&(d=`${e}_${t}`);const l=null===(o=r[a])||void 0===o?void 0:o[d];if(!l)return null;return v(n,"show_out_of_stock_videos")?l.tc:l.sc}function Y(e,t,n,i,o,r){var a;if(!(null===(a=v(r,"shimmer_config->enable_shimmer"))||void 0===a||a))return G&&console.log("[Shimmer] Disabled via customization"),null;if(null!==U.A)return G&&console.log(`[Shimmer] TEST MODE: Using hardcoded count ${U.A}`),U.A;if(!n||""===n||"undefined"===n||"null"===n)return G&&console.log("[Shimmer] No valid ID provided"),null;let d=null;return"homepage"===n?d=function(e,t){const n=window.whatmoreHomepageCarouselEvents;if(!n)return null;if(e&&"wgt_default"!==e){const i=n[e];return i?v(t,"show_out_of_stock_videos")?i.tc:i.sc||i.tc:null}return v(t,"show_out_of_stock_videos")?n.tc:n.sc}(i,r):t&&t.startsWith("product")?d=J(n,i,r):"collection"===e&&(d=K(n,i,r)),null===d||void 0===d||0===d?(G&&console.log(`[Shimmer] Event count is ${d}, skipping shimmer`),null):(G&&console.log(`[Shimmer] Found event count: ${d} for ${e}/${t}/${n}/${i}`),d)}var Z=i(964),Q=i(1578),X=i(6157),ee=i(6005),te=i(4901),ne=i(7714);let ie=!1;const oe="_whatmore_first_touch_sent";function re(){if(ie)return;const e=(0,ne.y)(),t=function(e){return null!==e&&void 0!==e&&e.startsWith("collection")?X.O.COLLECTION_PAGE_VISITED:null!==e&&void 0!==e&&e.startsWith("product")?X.O.PDP_VISITED:null!==e&&void 0!==e&&e.startsWith("index")?X.O.HOMEPAGE_VISITED:null!==e&&void 0!==e&&e.startsWith("page")?X.O.PAGE_VISITED:null}(e);if(null==localStorage.getItem(oe)&&(localStorage.setItem(oe,"1"),function(e){const t=(0,Q.S)(),n=(0,X.l)(X.O.FIRST_TOUCH,{path:window.location.pathname,landing_location_type:e}),i=(0,ee.A)("",{landingLocationType:e,templateType:""},[],[]),o={...t,interaction_data:n,data:i};(0,te.d)({metric_event_list:[o]},!0)}(e)),!t)return;ie=!0;const n={...(0,Q.S)(),interaction_data:(0,X.l)(t,{user_type:null!=localStorage.getItem("w_user_type")?"olduser":"newuser"}),data:(0,ee.A)("",{landingLocationType:e,templateType:""},[],[])};(0,te.d)({metric_event_list:[n]},!0)}var ae=i(3924);let de=!1;var le,se,ce,he,me,pe,ue,ge;const ve=Array.from(document.getElementsByClassName("whatmore-base")),we=null!==(le="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==le&&le,fe=function(e){return"template-banner-a"===e},xe=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},_e=function(e){return"template-stories-a"===e||"template-stories-b"===e};function be(e,t){const n=document.getElementById(e);if(!n)return t;return n.getAttribute("data-wh")||n.getAttribute("data")||t}function ye(e,t,n,i,o){var r;if("template-embed"===n)return;if("60595503283"===Se)return;if(!(null===(r=l(i,"shimmer_config->enable_shimmer"))||void 0===r||r))return;const a=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}(n),[d,s]=y(t);try{const r=function(e){const{templateType:t,widgetContainer:n,customizations:i}=e,o=N(n,i);if("template-banner-a"===t)return e.widgetIdentity=o.widgetIdentity,D(e);const r=Y(o.widgetType,o.landingLocationType,o.actualId,o.widgetIdentity,0,i);return null===r?null:(e.eventCount=r,"template-a"===t?b(e):"template-b"===t?P(e):"template-c"===t?S(e):"template-d"===t?T(e):"template-e"===t?I(e):"template-f"===t?k(e):"template-feed-a"===t?M(e):"template-g"===t?H(e):"template-h"===t?C(e):"template-i"===t?E(e):"template-j"===t?L(e):"template-stories"===t?O(e):null)}({templateType:a,widgetContainer:t,customizations:i,windowWidth:s,windowHeight:d});if(r&&r.totalHeight&&r.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=r.totalHeight+"px";const i=document.createElement("div");i.className="whatmore-shimmer-container",i.setAttribute("data-template",n),i.setAttribute("data-widget-id",o),i.style.cssText="position: absolute; top: 0; left: 0; width: 100%; height: auto; z-index: 2; transition: opacity 0.1s ease;",i.innerHTML=r.shimmerHTML,t.insertBefore(i,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 ${n}:`,c)}}const Pe=null!==document.getElementById("whatmoreRoot"),Se=be("whatmoreShopId",Z.YZ),Te=be("whatmoreExtensionType","index"),Ie=null!==(se=(null===(ce=window)||void 0===ce||null===(he=ce.Shopify)||void 0===he||null===(me=he.theme)||void 0===me?void 0:me.role)&&"main"!==(null===(pe=window)||void 0===pe||null===(ue=pe.Shopify)||void 0===ue||null===(ge=ue.theme)||void 0===ge?void 0:ge.role))&&void 0!==se&&se,$e=("2665447536"==Se||"72201044272"==Se)&&null!=localStorage.getItem("w_user_type"),ze=function(){const e=a("wtt"),t=a("weid");return null!=e&&null!=t}();function ke(e){try{if(window.Shopify&&window.Shopify.designMode)return!1;let t=localStorage.getItem("wht_user_group");if("qa_preview"===t&&(t=sessionStorage.getItem("wht_ab_preview")||t),!t||"default_group"===t)return!1;const n=window.whatmore&&window.whatmore.abTestConfig;if(!n||!n.groups||!n.groups[t])return!1;const i=e.getAttribute("data-wht-surface")+":"+e.getAttribute("data-wht-type")+":"+e.getAttribute("data-wht-widget");return!(n.groups[t].widget_ids||[]).includes(i)}catch(t){return!1}}!async function(){const e=await s(Se);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(!(Pe||ve&&ve.length>0)||Se===Z.YZ||window.Shopify&&window.Shopify.designMode||!l(e,"event_tracking->is_enabled")||(re(),function(){if(de||"undefined"===typeof document)return;de=!0;const e=()=>{(0,ae.$)(!0)};document.addEventListener("visibilitychange",()=>{"hidden"===document.visibilityState&&e()}),window.addEventListener("pagehide",e)}()),l(e,"order_tracking->add_whatmore_attribute")&&"shopify"===l(e,"brand_metadata->domain_context")){const e=localStorage.getItem("_whatmore_session_id"),t=localStorage.getItem("_whatmore_user_id"),n=localStorage.getItem("wht_user_group"),o=localStorage.getItem("wht_ab_test_id"),r=localStorage.getItem("wht_ab_test_version"),a=localStorage.getItem("_whatmore_last_video_view_session");if(null!=e&&null!=t&&fetch("/cart.js").then(e=>e.ok?e.json():null).then(i=>{if(!i)return;const d={wht_user_attributes:{wht_session_id:null!==a&&void 0!==a?a:e,wht_user_id:t,...n&&{wht_user_group:n},...o&&{wht_ab_test_id:o},...r&&{wht_ab_test_version:r}}};return fetch("/cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({attributes:d})})}).catch(e=>console.error("Whatmore :: eager cart-attribute write failed",e)),"undefined"!==typeof PerformanceObserver){const e="true"===be("whatmoreEmbedAppUseVariant","false"),t=1e3,n=[`${window.location.origin}/cart/add.js`,`${window.location.origin}/cart/add`];new PerformanceObserver(o=>{for(const r of o.getEntries())n.includes(r.name)&&setTimeout(()=>{Promise.all([i.e(609),i.e(268)]).then(i.bind(i,1745)).then(t=>t.addWhatmoreAttributeToCart(e)).catch(e=>console.error("Whatmore :: ATC attribute write failed",e))},t)}).observe({entryTypes:["resource"]})}}if(!Pe&&ve&&ve.length>0)for(let l=0;l<ve.length;l++){var t,n,o,r,a,d,h,m,p,u;const s=ve[l];if(ke(s))continue;const I=s.querySelector(".whatmore-render-root"),$=s.querySelector(".whatmore-template-type");let z=!1,k=!1,M=!1;const H=null!==(t=null!==(n=null===$||void 0===$?void 0:$.getAttribute("data-wh"))&&void 0!==n?n:null===$||void 0===$?void 0:$.getAttribute("data"))&&void 0!==t?t:"template-embed";_e(H)?z=!0:xe(H)?k=!0:fe(H)&&(M=!0);let C="",E="";var g,v,w,f,x,_,b,y,P,S,T;if(k)if(C=null!==(g=null!==(v=null===(w=s.querySelector("#whatmoreCollectionId"))||void 0===w?void 0:w.getAttribute("data-wh"))&&void 0!==v?v:null===(f=s.querySelector("#whatmoreCollectionId"))||void 0===f?void 0:f.getAttribute("data"))&&void 0!==g?g:"",E=null!==(x=null!==(_=null===(b=s.querySelector("#whatmoreCollectionHeading"))||void 0===b?void 0:b.getAttribute("data-wh"))&&void 0!==_?_:null===(y=s.querySelector("#whatmoreCollectionHeading"))||void 0===y?void 0:y.getAttribute("data"))&&void 0!==x?x:"","0"==C)C=null!==(P=null===(S=s.querySelector("#whatmorePageId"))||void 0===S?void 0:S.getAttribute("data-wh"))&&void 0!==P?P:null===(T=s.querySelector("#whatmorePageId"))||void 0===T?void 0:T.getAttribute("data");const L=null!==(o=null!==(r=null===(a=s.querySelector("#whatmoreHeading"))||void 0===a?void 0:a.getAttribute("data-wh"))&&void 0!==r?r:null===(d=s.querySelector("#whatmoreHeading"))||void 0===d?void 0:d.getAttribute("data"))&&void 0!==o?o:"",W=null!==(h=null!==(m=null===(p=s.querySelector("#whatmoreWidgetIdentity"))||void 0===p?void 0:p.getAttribute("data-wh"))&&void 0!==m?m:null===(u=s.querySelector("#whatmoreWidgetIdentity"))||void 0===u?void 0:u.getAttribute("data"))&&void 0!==h?h:"wgt_default",O="whatmoreRoot"+l;ye(I,s,H,e,O);const B=c(e,k,ze,H),V=()=>{Promise.all([i.e(609),i.e(268)]).then(i.bind(i,8784)).then(e=>{e.initializeReactApp({rootElement:I,templateType:H,isStoriesTemplate:z,isCollectionsTemplate:k,_isTemplateTypeBanner:M,whatmoreCollectionId:C,whatmoreCollectionHeading:E,whatmoreHeadingCarousel:L,whatmoreWidgetIdentity:W,whatmoreRootId:O,landingLocationType:Te,isInPreviewMode:Ie,userType:$e})}).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(),we&&console.log(`[Chunk Error] Removed shimmer for widget ${O}`)),s&&(s.style.minHeight="0px",we&&console.log(`[Chunk Error] Reset minHeight to 0px for widget ${O}`)),I&&(I.style.opacity="0",I.removeAttribute("data-shimmer-active"))})};if(B){let e=!1;const t=()=>{e||(e=!0,V())},n=new IntersectionObserver(e=>{e.forEach(e=>{if(we&&console.log(`[OBSERVER] Widget ${l}: isIntersecting=${e.isIntersecting}, top=${e.boundingClientRect.top}, bottom=${e.boundingClientRect.bottom}, viewportHeight=${window.innerHeight}, layoutHeight=${document.documentElement.clientHeight}`),e.isIntersecting){if("67841720509"===Se){const e=s.getBoundingClientRect();if(e.top>=document.documentElement.clientHeight||e.bottom<=0)return void(we&&console.log(`[OBSERVER] Widget ${l}: Rejected \u2014 outside layout viewport (iOS rescale guard)`))}we&&console.log(`[OBSERVER] Widget ${l}: Loading React chunk`),t(),n.disconnect()}})},{threshold:0,rootMargin:"0px 0px 0px 0px"});n.observe(s);const i=s.getBoundingClientRect();we&&console.log(`[SETUP] Widget ${l}: Observer attached, position top=${i.top}, bottom=${i.bottom}, viewportHeight=${window.innerHeight}, margin=500px`);const o=10;let r=window.pageYOffset;we&&console.log(`[SCROLL LISTENER] Widget ${l}: Initial scroll position=${r}`);const a=()=>{const e=window.pageYOffset,n=Math.abs(e-r);we&&console.log(`[SCROLL LISTENER] Widget ${l}: Scroll event fired, scrollY=${e}, lastScrollY=${r}, delta=${n}`),n>o&&(we&&console.log(`[SCROLL LISTENER] Widget ${l}: Delta > ${o}, triggering load`),t(),window.removeEventListener("scroll",a))};window.addEventListener("scroll",a,{passive:!0})}else V()}else if(Pe){const e=document.getElementById("whatmoreRoot"),t="whatmoreRoot",n=be("whatmoreTemplateType","invalid-template"),o=_e(n),r=xe(n),a=fe(n);Promise.all([i.e(609),i.e(268)]).then(i.bind(i,8784)).then(i=>{i.initializeReactApp({rootElement:e,templateType:n,isStoriesTemplate:o,isCollectionsTemplate:r,_isTemplateTypeBanner:a,whatmoreCollectionId:"",whatmoreCollectionHeading:"",whatmoreHeadingCarousel:"",whatmoreWidgetIdentity:"wgt_default",whatmoreRootId:t,landingLocationType:Te,isInPreviewMode:Ie,userType:$e})}).catch(e=>{console.error("Whatmore: Failed to load React chunk for legacy store:",e)})}if("75310563627"===Se&&!Pe&&"undefined"!==typeof MutationObserver){const e=document.querySelectorAll(".whatmore-base");e.forEach(e=>e.setAttribute("data-wht-mounted","true")),we&&console.log(`[Rehydrate] installed for shop ${Se}; marked ${e.length} load-time host(s) as mounted, watching document.body`);let t=0;const n=e=>{var t,n;const i=e.querySelector(".whatmore-template-type");return null!==(t=null!==(n=null===i||void 0===i?void 0:i.getAttribute("data-wh"))&&void 0!==n?n:null===i||void 0===i?void 0:i.getAttribute("data"))&&void 0!==t?t:"template-embed"},o=()=>[...document.querySelectorAll(".whatmore-base:not([data-wht-mounted])")].filter(e=>xe(n(e))),r=e=>{var o,r,a,d,l,s,c,h,m,p,u,g,v,w,f,x,_,b,y;const P=n(e);if(!xe(P))return void(we&&console.log(`[Rehydrate] skip host: not a collection template (${P})`,e));const S=e.querySelector(".whatmore-render-root");if(!S)return void(we&&console.log("[Rehydrate] skip host: .whatmore-render-root not present yet (will retry on next mutation)",e));e.setAttribute("data-wht-mounted","true");let T=null!==(o=null!==(r=null===(a=e.querySelector("#whatmoreCollectionId"))||void 0===a?void 0:a.getAttribute("data-wh"))&&void 0!==r?r:null===(d=e.querySelector("#whatmoreCollectionId"))||void 0===d?void 0:d.getAttribute("data"))&&void 0!==o?o:"";const I=null!==(l=null!==(s=null===(c=e.querySelector("#whatmoreCollectionHeading"))||void 0===c?void 0:c.getAttribute("data-wh"))&&void 0!==s?s:null===(h=e.querySelector("#whatmoreCollectionHeading"))||void 0===h?void 0:h.getAttribute("data"))&&void 0!==l?l:"";"0"===T&&(T=null!==(m=null===(p=e.querySelector("#whatmorePageId"))||void 0===p?void 0:p.getAttribute("data-wh"))&&void 0!==m?m:null===(u=e.querySelector("#whatmorePageId"))||void 0===u?void 0:u.getAttribute("data"));const $=null!==(g=null!==(v=null===(w=e.querySelector("#whatmoreHeading"))||void 0===w?void 0:w.getAttribute("data-wh"))&&void 0!==v?v:null===(f=e.querySelector("#whatmoreHeading"))||void 0===f?void 0:f.getAttribute("data"))&&void 0!==g?g:"",z=null!==(x=null!==(_=null===(b=e.querySelector("#whatmoreWidgetIdentity"))||void 0===b?void 0:b.getAttribute("data-wh"))&&void 0!==_?_:null===(y=e.querySelector("#whatmoreWidgetIdentity"))||void 0===y?void 0:y.getAttribute("data"))&&void 0!==x?x:"wgt_default",k="whatmoreRootRehydrate"+t++;we&&console.log("[Rehydrate] mounting fresh collection host ->",k,e),Promise.all([i.e(609),i.e(268)]).then(i.bind(i,8784)).then(e=>e.initializeReactApp({rootElement:S,templateType:P,isStoriesTemplate:!1,isCollectionsTemplate:!0,_isTemplateTypeBanner:!1,whatmoreCollectionId:T,whatmoreCollectionHeading:I,whatmoreHeadingCarousel:$,whatmoreWidgetIdentity:z,whatmoreRootId:k,landingLocationType:Te,isInPreviewMode:Ie,userType:$e})).catch(e=>console.error("Whatmore: rehydrate mount failed",e))};let a=!1;const d=()=>{a=!1;const e=o();we&&console.log(`[Rehydrate] rescan: ${e.length} fresh collection host(s) to mount`),e.forEach(r)};new MutationObserver(e=>{if(a)return;let t=!1;for(const i of e)if(i.addedNodes&&i.addedNodes.length){t=!0;break}if(!t)return;const n=o();0!==n.length&&(we&&console.log(`[Rehydrate] DOM mutation: ${n.length} freshly-added collection host(s) need mounting (re-render, not a removal), scheduling in 50ms`),a=!0,setTimeout(d,50))}).observe(document.body,{childList:!0,subtree:!0})}}()}();