import{f as Ye,g as ze,h as Xe}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-D7BLS3P5.js";import{a as Ge,b as Ke,c as _t}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-BO3DOKGY.js";import{a as he}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-L2RNFW2O.js";import{e as Ee}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-LMJVQM5Q.js";import{a as ve}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-MEFRPCES.js";import{a as Vt}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-WKT7CPBF.js";import{a as oe}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-722DUSLT.js";import{a as qe}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-7MZ5ZFIB.js";import{b as kt,d as z}from"https://cdn.shopify.com/oxygen-v2/26324/10616/21935/1653405/build/_shared/chunk-SFLZO754.js";var Je=kt((Te,xe)=>{(function(e,t){typeof Te=="object"&&typeof xe<"u"?xe.exports=t():typeof define=="function"&&define.amd?define(t):(e=e||self,e.SanityImageUrlBuilder=t())})(Te,function(){function e(){return e=Object.assign||function(a){for(var s=1;sa.length)&&(s=a.length);for(var u=0,r=new Array(s);u=a.length?{done:!0}:{done:!1,value:a[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var v="image-Tb9Ew8CXIwaY6R1kjMvI0uRR-2000x3000-jpg";function h(a){var s=a.split("-"),u=s[1],r=s[2],l=s[3];if(!u||!r||!l)throw new Error("Malformed asset _ref '"+a+`'. Expected an id like "`+v+'".');var f=r.split("x"),y=f[0],w=f[1],g=+y,E=+w,P=isFinite(g)&&isFinite(E);if(!P)throw new Error("Malformed asset _ref '"+a+`'. Expected an id like "`+v+'".');return{id:u,width:g,height:E,format:l}}var b=function(s){var u=s;return u?typeof u._ref=="string":!1},x=function(s){var u=s;return u?typeof u._id=="string":!1},S=function(s){var u=s;return u&&u.asset?typeof u.asset.url=="string":!1};function I(a){if(!a)return null;var s;if(typeof a=="string"&&D(a))s={asset:{_ref:k(a)}};else if(typeof a=="string")s={asset:{_ref:a}};else if(b(a))s={asset:a};else if(x(a))s={asset:{_ref:a._id||""}};else if(S(a))s={asset:{_ref:k(a.asset.url)}};else if(typeof a.asset=="object")s=e({},a);else return null;var u=a;return u.crop&&(s.crop=u.crop),u.hotspot&&(s.hotspot=u.hotspot),$(s)}function D(a){return/^https?:\/\//.test(""+a)}function k(a){var s=a.split("/").slice(-1);return("image-"+s[0]).replace(/\.([a-z]+)$/,"-$1")}function $(a){if(a.crop&&a.hotspot)return a;var s=e({},a);return s.crop||(s.crop={left:0,top:0,bottom:0,right:0}),s.hotspot||(s.hotspot={x:.5,y:.5,height:1,width:1}),s}var V=[["width","w"],["height","h"],["format","fm"],["download","dl"],["blur","blur"],["sharpen","sharp"],["invert","invert"],["orientation","or"],["minHeight","min-h"],["maxHeight","max-h"],["minWidth","min-w"],["maxWidth","max-w"],["quality","q"],["fit","fit"],["crop","crop"],["saturation","sat"],["auto","auto"],["dpr","dpr"],["pad","pad"]];function N(a){var s=e({},a||{}),u=s.source;delete s.source;var r=I(u);if(!r)throw new Error("Unable to resolve image URL from source ("+JSON.stringify(u)+")");var l=r.asset._ref||r.asset._id||"",f=h(l),y=Math.round(r.crop.left*f.width),w=Math.round(r.crop.top*f.height),g={left:y,top:w,width:Math.round(f.width-r.crop.right*f.width-y),height:Math.round(f.height-r.crop.bottom*f.height-w)},E=r.hotspot.height*f.height/2,P=r.hotspot.width*f.width/2,A=r.hotspot.x*f.width,j=r.hotspot.y*f.height,C={left:A-P,top:j-E,right:A+P,bottom:j+E};return s.rect||s.focalPoint||s.ignoreImageParams||s.crop||(s=e({},s,q({crop:g,hotspot:C},s))),H(e({},s,{asset:f}))}function H(a){var s=(a.baseUrl||"https://cdn.sanity.io").replace(/\/+$/,""),u=a.asset.id+"-"+a.asset.width+"x"+a.asset.height+"."+a.asset.format,r=s+"/images/"+a.projectId+"/"+a.dataset+"/"+u,l=[];if(a.rect){var f=a.rect,y=f.left,w=f.top,g=f.width,E=f.height,P=y!==0||w!==0||E!==a.asset.height||g!==a.asset.width;P&&l.push("rect="+y+","+w+","+g+","+E)}a.bg&&l.push("bg="+a.bg),a.focalPoint&&(l.push("fp-x="+a.focalPoint.x),l.push("fp-y="+a.focalPoint.y));var A=[a.flipHorizontal&&"h",a.flipVertical&&"v"].filter(Boolean).join("");return A&&l.push("flip="+A),V.forEach(function(j){var C=j[0],Y=j[1];typeof a[C]<"u"?l.push(Y+"="+encodeURIComponent(a[C])):typeof a[Y]<"u"&&l.push(Y+"="+encodeURIComponent(a[Y]))}),l.length===0?r:r+"?"+l.join("&")}function q(a,s){var u,r=s.width,l=s.height;if(!(r&&l))return{width:r,height:l,rect:a.crop};var f=a.crop,y=a.hotspot,w=r/l,g=f.width/f.height;if(g>w){var E=Math.round(f.height),P=Math.round(E*w),A=Math.max(0,Math.round(f.top)),j=Math.round((y.right-y.left)/2+y.left),C=Math.max(0,Math.round(j-P/2));Cf.left+f.width&&(C=f.left+f.width-P),u={left:C,top:A,width:P,height:E}}else{var Y=f.width,J=Math.round(Y/w),ce=Math.max(0,Math.round(f.left)),se=Math.round((y.bottom-y.top)/2+y.top),Q=Math.max(0,Math.round(se-J/2));Qf.top+f.height&&(Q=f.top+f.height-J),u={left:ce,top:Q,width:Y,height:J}}return{width:r,height:l,rect:u}}var _=["clip","crop","fill","fillmax","max","scale","min"],U=["top","bottom","left","right","center","focalpoint","entropy"],B=["format"];function n(a){return a&&"config"in a?typeof a.config=="function":!1}function G(a){return a&&"clientConfig"in a?typeof a.clientConfig=="object":!1}function m(a){for(var s=V,u=p(s),r;!(r=u()).done;){var l=r.value,f=l[0],y=l[1];if(a===f||a===y)return f}return a}function te(a){if(n(a)){var s=a.config(),u=s.apiHost,r=s.projectId,l=s.dataset,f=u||"https://api.sanity.io";return new K(null,{baseUrl:f.replace(/^https:\/\/api\./,"https://cdn."),projectId:r,dataset:l})}var y=a;if(G(y)){var w=y.clientConfig,g=w.apiHost,E=w.projectId,P=w.dataset,A=g||"https://api.sanity.io";return new K(null,{baseUrl:A.replace(/^https:\/\/api\./,"https://cdn."),projectId:E,dataset:P})}return new K(null,a)}var K=function(){function a(u,r){this.options=void 0,this.options=u?e({},u.options||{},r||{}):e({},r||{})}var s=a.prototype;return s.withOptions=function(r){var l=r.baseUrl||this.options.baseUrl,f={baseUrl:l};for(var y in r)if(r.hasOwnProperty(y)){var w=m(y);f[w]=r[y]}return new a(this,e({baseUrl:l},f))},s.image=function(r){return this.withOptions({source:r})},s.dataset=function(r){return this.withOptions({dataset:r})},s.projectId=function(r){return this.withOptions({projectId:r})},s.bg=function(r){return this.withOptions({bg:r})},s.dpr=function(r){return this.withOptions(r&&r!==1?{dpr:r}:{})},s.width=function(r){return this.withOptions({width:r})},s.height=function(r){return this.withOptions({height:r})},s.focalPoint=function(r,l){return this.withOptions({focalPoint:{x:r,y:l}})},s.maxWidth=function(r){return this.withOptions({maxWidth:r})},s.minWidth=function(r){return this.withOptions({minWidth:r})},s.maxHeight=function(r){return this.withOptions({maxHeight:r})},s.minHeight=function(r){return this.withOptions({minHeight:r})},s.size=function(r,l){return this.withOptions({width:r,height:l})},s.blur=function(r){return this.withOptions({blur:r})},s.sharpen=function(r){return this.withOptions({sharpen:r})},s.rect=function(r,l,f,y){return this.withOptions({rect:{left:r,top:l,width:f,height:y}})},s.format=function(r){return this.withOptions({format:r})},s.invert=function(r){return this.withOptions({invert:r})},s.orientation=function(r){return this.withOptions({orientation:r})},s.quality=function(r){return this.withOptions({quality:r})},s.forceDownload=function(r){return this.withOptions({download:r})},s.flipHorizontal=function(){return this.withOptions({flipHorizontal:!0})},s.flipVertical=function(){return this.withOptions({flipVertical:!0})},s.ignoreImageParams=function(){return this.withOptions({ignoreImageParams:!0})},s.fit=function(r){if(_.indexOf(r)===-1)throw new Error('Invalid fit mode "'+r+'"');return this.withOptions({fit:r})},s.crop=function(r){if(U.indexOf(r)===-1)throw new Error('Invalid crop mode "'+r+'"');return this.withOptions({crop:r})},s.saturation=function(r){return this.withOptions({saturation:r})},s.auto=function(r){if(B.indexOf(r)===-1)throw new Error('Invalid auto mode "'+r+'"');return this.withOptions({auto:r})},s.pad=function(r){return this.withOptions({pad:r})},s.url=function(){return N(this.options)},s.toString=function(){return this.url()},a}();return te})});var me=z(qe()),Qe=(0,me.createContext)(null),Sn=Qe.Provider,Cn=()=>(0,me.useContext)(Qe);var et=z(Je()),tt=z(oe()),Ze=[640,768,1024,1280,1536],Ut=(e,t)=>e.slice(0,t).filter(p=>p!==null).pop(),Wt=(e,t,{quality:o})=>t.map(p=>`${e.width(p).auto("format").quality(o)} ${p}w`).join(", "),$t=(e,t)=>{if(t)return typeof t=="string"?t:t.length===1&&t[0]!==null?t[0]:t.map((o,p)=>{if(p===t.length-1)return t[p];let v=o;return o===null&&(v=Ut(t,p)),`(max-width: ${e?.[p]}px) ${v}`}).join(", ")};function Ht(e){let{crop:t,dataset:o,height:p,hotspot:v,layout:h,objectFit:b,options:x,projectId:S,quality:I=80,sizes:D,src:k,width:$,fullWidth:V,...N}=e;if(!o)throw new Error('SanityImage is missing required "dataset" property.');if(!S)throw new Error('SanityImage is missing required "projectId" property.');if(!k)return null;delete N?.decoding,delete N?.ref,delete N?.srcSet,delete N?.style;let H=(0,et.default)({projectId:S,dataset:o}).image({_ref:k,crop:t,hotspot:v}),q=$t(Ze,D),_=Wt(H,Ze,{quality:I}),U;if(p&&$){let n=1-(t?.left||0)-(t?.right||0),G=1-(t?.bottom||0)-(t?.top||0);U=$*n/(p*G)}let B=H;return x?.blur&&(B=B.blur(x.blur)),B=B.url(),(0,tt.jsx)("img",{...N,decoding:"async",sizes:q,src:B,srcSet:_,style:{...h==="fill"&&{bottom:0,height:"100%",left:0,objectFit:b,position:"absolute",right:0,top:0,width:V?"100%":"auto"},...h==="responsive"&&{aspectRatio:U,width:V?"100%":"auto"}}})}_t();var Bt="tippy-content",Ft="tippy-backdrop",qt="tippy-arrow",Yt="tippy-svg-arrow",ee={passive:!0,capture:!0},ct=function(){return document.body};function Se(e,t,o){if(Array.isArray(e)){var p=e[t];return p??(Array.isArray(o)?o[t]:o)}return e}function Ae(e,t){var o={}.toString.call(e);return o.indexOf("[object")===0&&o.indexOf(t+"]")>-1}function ft(e,t){return typeof e=="function"?e.apply(void 0,t):e}function nt(e,t){if(t===0)return e;var o;return function(p){clearTimeout(o),o=setTimeout(function(){e(p)},t)}}function zt(e){return e.split(/\s+/).filter(Boolean)}function ae(e){return[].concat(e)}function rt(e,t){e.indexOf(t)===-1&&e.push(t)}function Xt(e){return e.filter(function(t,o){return e.indexOf(t)===o})}function Gt(e){return e.split("-")[0]}function ye(e){return[].slice.call(e)}function it(e){return Object.keys(e).reduce(function(t,o){return e[o]!==void 0&&(t[o]=e[o]),t},{})}function Kt(){return document.createElement("div")}function lt(e){return["Element","Fragment"].some(function(t){return Ae(e,t)})}function Jt(e){return Ae(e,"NodeList")}function Qt(e){return Ae(e,"MouseEvent")}function Zt(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function en(e){return lt(e)?[e]:Jt(e)?ye(e):Array.isArray(e)?e:ye(document.querySelectorAll(e))}function Ce(e,t){e.forEach(function(o){o&&(o.style.transitionDuration=t+"ms")})}function ot(e,t){e.forEach(function(o){o&&o.setAttribute("data-state",t)})}function tn(e){var t,o=ae(e),p=o[0];return p!=null&&(t=p.ownerDocument)!=null&&t.body?p.ownerDocument:document}function nn(e,t){var o=t.clientX,p=t.clientY;return e.every(function(v){var h=v.popperRect,b=v.popperState,x=v.props,S=x.interactiveBorder,I=Gt(b.placement),D=b.modifiersData.offset;if(!D)return!0;var k=I==="bottom"?D.top.y:0,$=I==="top"?D.bottom.y:0,V=I==="right"?D.left.x:0,N=I==="left"?D.right.x:0,H=h.top-p+k>S,q=p-h.bottom-$>S,_=h.left-o+V>S,U=o-h.right-N>S;return H||q||_||U})}function Pe(e,t,o){var p=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(v){e[p](v,o)})}function at(e,t){for(var o=t;o;){var p;if(e.contains(o))return!0;o=o.getRootNode==null||(p=o.getRootNode())==null?void 0:p.host}return!1}var X={isTouch:!1},st=0;function rn(){X.isTouch||(X.isTouch=!0,window.performance&&document.addEventListener("mousemove",dt))}function dt(){var e=performance.now();e-st<20&&(X.isTouch=!1,document.removeEventListener("mousemove",dt)),st=e}function on(){var e=document.activeElement;if(Zt(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function an(){document.addEventListener("touchstart",rn,ee),window.addEventListener("blur",on)}var sn=typeof window<"u"&&typeof document<"u",un=sn?!!window.msCrypto:!1;var pn={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},cn={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},F=Object.assign({appendTo:ct,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},pn,cn),fn=Object.keys(F),ln=function(t){var o=Object.keys(t);o.forEach(function(p){F[p]=t[p]})};function vt(e){var t=e.plugins||[],o=t.reduce(function(p,v){var h=v.name,b=v.defaultValue;if(h){var x;p[h]=e[h]!==void 0?e[h]:(x=F[h])!=null?x:b}return p},{});return Object.assign({},e,o)}function dn(e,t){var o=t?Object.keys(vt(Object.assign({},F,{plugins:t}))):fn,p=o.reduce(function(v,h){var b=(e.getAttribute("data-tippy-"+h)||"").trim();if(!b)return v;if(h==="content")v[h]=b;else try{v[h]=JSON.parse(b)}catch{v[h]=b}return v},{});return p}function ut(e,t){var o=Object.assign({},t,{content:ft(t.content,[e])},t.ignoreAttributes?{}:dn(e,t.plugins));return o.aria=Object.assign({},F.aria,o.aria),o.aria={expanded:o.aria.expanded==="auto"?t.interactive:o.aria.expanded,content:o.aria.content==="auto"?t.interactive?null:"describedby":o.aria.content},o}function pt(e){var t=e.firstElementChild,o=ye(t.children);return{box:t,content:o.find(function(p){return p.classList.contains(Bt)}),arrow:o.find(function(p){return p.classList.contains(qt)||p.classList.contains(Yt)}),backdrop:o.find(function(p){return p.classList.contains(Ft)})}}var vn=1,ge=[],De=[];function hn(e,t){var o=ut(e,Object.assign({},F,vt(it(t)))),p,v,h,b=!1,x=!1,S=!1,I=!1,D,k,$,V=[],N=nt(Ve,o.interactiveDebounce),H,q=vn++,_=null,U=Xt(o.plugins),B={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},n={id:q,reference:e,popper:Kt(),popperInstance:_,props:o,state:B,plugins:U,clearDelayTimeouts:Pt,setProps:Dt,setContent:At,show:Mt,hide:It,hideWithInteractivity:Nt,enable:St,disable:Ct,unmount:jt,destroy:Lt};if(!o.render)return n;var G=o.render(n),m=G.popper,te=G.onUpdate;m.setAttribute("data-tippy-root",""),m.id="tippy-"+n.id,n.popper=m,e._tippy=n,m._tippy=n;var K=U.map(function(i){return i.fn(n)}),a=e.hasAttribute("aria-expanded");return Le(),A(),g(),E("onCreate",[n]),o.showOnCreate&&Be(),m.addEventListener("mouseenter",function(){n.props.interactive&&n.state.isVisible&&n.clearDelayTimeouts()}),m.addEventListener("mouseleave",function(){n.props.interactive&&n.props.trigger.indexOf("mouseenter")>=0&&f().addEventListener("mousemove",N)}),n;function s(){var i=n.props.touch;return Array.isArray(i)?i:[i,0]}function u(){return s()[0]==="hold"}function r(){var i;return!!((i=n.props.render)!=null&&i.$$tippy)}function l(){return H||e}function f(){var i=l().parentNode;return i?tn(i):document}function y(){return pt(m)}function w(i){return n.state.isMounted&&!n.state.isVisible||X.isTouch||D&&D.type==="focus"?0:Se(n.props.delay,i?0:1,F.delay)}function g(i){i===void 0&&(i=!1),m.style.pointerEvents=n.props.interactive&&!i?"":"none",m.style.zIndex=""+n.props.zIndex}function E(i,c,d){if(d===void 0&&(d=!0),K.forEach(function(O){O[i]&&O[i].apply(O,c)}),d){var T;(T=n.props)[i].apply(T,c)}}function P(){var i=n.props.aria;if(i.content){var c="aria-"+i.content,d=m.id,T=ae(n.props.triggerTarget||e);T.forEach(function(O){var L=O.getAttribute(c);if(n.state.isVisible)O.setAttribute(c,L?L+" "+d:d);else{var W=L&&L.replace(d,"").trim();W?O.setAttribute(c,W):O.removeAttribute(c)}})}}function A(){if(!(a||!n.props.aria.expanded)){var i=ae(n.props.triggerTarget||e);i.forEach(function(c){n.props.interactive?c.setAttribute("aria-expanded",n.state.isVisible&&c===l()?"true":"false"):c.removeAttribute("aria-expanded")})}}function j(){f().removeEventListener("mousemove",N),ge=ge.filter(function(i){return i!==N})}function C(i){if(!(X.isTouch&&(S||i.type==="mousedown"))){var c=i.composedPath&&i.composedPath()[0]||i.target;if(!(n.props.interactive&&at(m,c))){if(ae(n.props.triggerTarget||e).some(function(d){return at(d,c)})){if(X.isTouch||n.state.isVisible&&n.props.trigger.indexOf("click")>=0)return}else E("onClickOutside",[n,i]);n.props.hideOnClick===!0&&(n.clearDelayTimeouts(),n.hide(),x=!0,setTimeout(function(){x=!1}),n.state.isMounted||se())}}}function Y(){S=!0}function J(){S=!1}function ce(){var i=f();i.addEventListener("mousedown",C,!0),i.addEventListener("touchend",C,ee),i.addEventListener("touchstart",J,ee),i.addEventListener("touchmove",Y,ee)}function se(){var i=f();i.removeEventListener("mousedown",C,!0),i.removeEventListener("touchend",C,ee),i.removeEventListener("touchstart",J,ee),i.removeEventListener("touchmove",Y,ee)}function Q(i,c){je(i,function(){!n.state.isVisible&&m.parentNode&&m.parentNode.contains(m)&&c()})}function Tt(i,c){je(i,c)}function je(i,c){var d=y().box;function T(O){O.target===d&&(Pe(d,"remove",T),c())}if(i===0)return c();Pe(d,"remove",k),Pe(d,"add",T),k=T}function ne(i,c,d){d===void 0&&(d=!1);var T=ae(n.props.triggerTarget||e);T.forEach(function(O){O.addEventListener(i,c,d),V.push({node:O,eventType:i,handler:c,options:d})})}function Le(){u()&&(ne("touchstart",ke,{passive:!0}),ne("touchend",_e,{passive:!0})),zt(n.props.trigger).forEach(function(i){if(i!=="manual")switch(ne(i,ke),i){case"mouseenter":ne("mouseleave",_e);break;case"focus":ne(un?"focusout":"blur",Ue);break;case"focusin":ne("focusout",Ue);break}})}function Re(){V.forEach(function(i){var c=i.node,d=i.eventType,T=i.handler,O=i.options;c.removeEventListener(d,T,O)}),V=[]}function ke(i){var c,d=!1;if(!(!n.state.isEnabled||We(i)||x)){var T=((c=D)==null?void 0:c.type)==="focus";D=i,H=i.currentTarget,A(),!n.state.isVisible&&Qt(i)&&ge.forEach(function(O){return O(i)}),i.type==="click"&&(n.props.trigger.indexOf("mouseenter")<0||b)&&n.props.hideOnClick!==!1&&n.state.isVisible?d=!0:Be(i),i.type==="click"&&(b=!d),d&&!T&&fe(i)}}function Ve(i){var c=i.target,d=l().contains(c)||m.contains(c);if(!(i.type==="mousemove"&&d)){var T=be().concat(m).map(function(O){var L,W=O._tippy,re=(L=W.popperInstance)==null?void 0:L.state;return re?{popperRect:O.getBoundingClientRect(),popperState:re,props:o}:null}).filter(Boolean);nn(T,i)&&(j(),fe(i))}}function _e(i){var c=We(i)||n.props.trigger.indexOf("click")>=0&&b;if(!c){if(n.props.interactive){n.hideWithInteractivity(i);return}fe(i)}}function Ue(i){n.props.trigger.indexOf("focusin")<0&&i.target!==l()||n.props.interactive&&i.relatedTarget&&m.contains(i.relatedTarget)||fe(i)}function We(i){return X.isTouch?u()!==i.type.indexOf("touch")>=0:!1}function $e(){He();var i=n.props,c=i.popperOptions,d=i.placement,T=i.offset,O=i.getReferenceClientRect,L=i.moveTransition,W=r()?pt(m).arrow:null,re=O?{getBoundingClientRect:O,contextElement:O.contextElement||l()}:e,Fe={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(le){var ie=le.state;if(r()){var Rt=y(),Oe=Rt.box;["placement","reference-hidden","escaped"].forEach(function(de){de==="placement"?Oe.setAttribute("data-placement",ie.placement):ie.attributes.popper["data-popper-"+de]?Oe.setAttribute("data-"+de,""):Oe.removeAttribute("data-"+de)}),ie.attributes.popper={}}}},Z=[{name:"offset",options:{offset:T}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!L}},Fe];r()&&W&&Z.push({name:"arrow",options:{element:W,padding:3}}),Z.push.apply(Z,c?.modifiers||[]),n.popperInstance=Ke(re,m,Object.assign({},c,{placement:d,onFirstUpdate:$,modifiers:Z}))}function He(){n.popperInstance&&(n.popperInstance.destroy(),n.popperInstance=null)}function xt(){var i=n.props.appendTo,c,d=l();n.props.interactive&&i===ct||i==="parent"?c=d.parentNode:c=ft(i,[d]),c.contains(m)||c.appendChild(m),n.state.isMounted=!0,$e()}function be(){return ye(m.querySelectorAll("[data-tippy-root]"))}function Be(i){n.clearDelayTimeouts(),i&&E("onTrigger",[n,i]),ce();var c=w(!0),d=s(),T=d[0],O=d[1];X.isTouch&&T==="hold"&&O&&(c=O),c?p=setTimeout(function(){n.show()},c):n.show()}function fe(i){if(n.clearDelayTimeouts(),E("onUntrigger",[n,i]),!n.state.isVisible){se();return}if(!(n.props.trigger.indexOf("mouseenter")>=0&&n.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(i.type)>=0&&b)){var c=w(!1);c?v=setTimeout(function(){n.state.isVisible&&n.hide()},c):h=requestAnimationFrame(function(){n.hide()})}}function St(){n.state.isEnabled=!0}function Ct(){n.hide(),n.state.isEnabled=!1}function Pt(){clearTimeout(p),clearTimeout(v),cancelAnimationFrame(h)}function Dt(i){if(!n.state.isDestroyed){E("onBeforeUpdate",[n,i]),Re();var c=n.props,d=ut(e,Object.assign({},c,it(i),{ignoreAttributes:!0}));n.props=d,Le(),c.interactiveDebounce!==d.interactiveDebounce&&(j(),N=nt(Ve,d.interactiveDebounce)),c.triggerTarget&&!d.triggerTarget?ae(c.triggerTarget).forEach(function(T){T.removeAttribute("aria-expanded")}):d.triggerTarget&&e.removeAttribute("aria-expanded"),A(),g(),te&&te(c,d),n.popperInstance&&($e(),be().forEach(function(T){requestAnimationFrame(T._tippy.popperInstance.forceUpdate)})),E("onAfterUpdate",[n,i])}}function At(i){n.setProps({content:i})}function Mt(){var i=n.state.isVisible,c=n.state.isDestroyed,d=!n.state.isEnabled,T=X.isTouch&&!n.props.touch,O=Se(n.props.duration,0,F.duration);if(!(i||c||d||T)&&!l().hasAttribute("disabled")&&(E("onShow",[n],!1),n.props.onShow(n)!==!1)){if(n.state.isVisible=!0,r()&&(m.style.visibility="visible"),g(),ce(),n.state.isMounted||(m.style.transition="none"),r()){var L=y(),W=L.box,re=L.content;Ce([W,re],0)}$=function(){var Z;if(!(!n.state.isVisible||I)){if(I=!0,m.offsetHeight,m.style.transition=n.props.moveTransition,r()&&n.props.animation){var we=y(),le=we.box,ie=we.content;Ce([le,ie],O),ot([le,ie],"visible")}P(),A(),rt(De,n),(Z=n.popperInstance)==null||Z.forceUpdate(),E("onMount",[n]),n.props.animation&&r()&&Tt(O,function(){n.state.isShown=!0,E("onShown",[n])})}},xt()}}function It(){var i=!n.state.isVisible,c=n.state.isDestroyed,d=!n.state.isEnabled,T=Se(n.props.duration,1,F.duration);if(!(i||c||d)&&(E("onHide",[n],!1),n.props.onHide(n)!==!1)){if(n.state.isVisible=!1,n.state.isShown=!1,I=!1,b=!1,r()&&(m.style.visibility="hidden"),j(),se(),g(!0),r()){var O=y(),L=O.box,W=O.content;n.props.animation&&(Ce([L,W],T),ot([L,W],"hidden"))}P(),A(),n.props.animation?r()&&Q(T,n.unmount):n.unmount()}}function Nt(i){f().addEventListener("mousemove",N),rt(ge,N),N(i)}function jt(){n.state.isVisible&&n.hide(),n.state.isMounted&&(He(),be().forEach(function(i){i._tippy.unmount()}),m.parentNode&&m.parentNode.removeChild(m),De=De.filter(function(i){return i!==n}),n.state.isMounted=!1,E("onHidden",[n]))}function Lt(){n.state.isDestroyed||(n.clearDelayTimeouts(),n.unmount(),Re(),delete e._tippy,n.state.isDestroyed=!0,E("onDestroy",[n]))}}function ue(e,t){t===void 0&&(t={});var o=F.plugins.concat(t.plugins||[]);an();var p=Object.assign({},t,{plugins:o}),v=en(e);if(!1)var h,b;var x=v.reduce(function(S,I){var D=I&&hn(I,p);return D&&S.push(D),S},[]);return lt(e)?x[0]:x}ue.defaultProps=F;ue.setDefaultProps=ln;ue.currentInput=X;var Mn=Object.assign({},Ge,{effect:function(t){var o=t.state,p={popper:{position:o.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(o.elements.popper.style,p.popper),o.styles=p,o.elements.arrow&&Object.assign(o.elements.arrow.style,p.arrow)}});ue.setDefaultProps({animation:!1});var ht=ue;var M=z(qe()),yt=z(Vt());function bt(e,t){if(e==null)return{};var o={},p=Object.keys(e),v,h;for(h=0;h=0)&&(o[v]=e[v]);return o}var wt=typeof window<"u"&&typeof document<"u";function Ie(e,t){e&&(typeof e=="function"&&e(t),{}.hasOwnProperty.call(e,"current")&&(e.current=t))}function mt(){return wt&&document.createElement("div")}function mn(e){var t={"data-placement":e.placement};return e.referenceHidden&&(t["data-reference-hidden"]=""),e.escaped&&(t["data-escaped"]=""),t}function Ot(e,t){if(e===t)return!0;if(typeof e=="object"&&e!=null&&typeof t=="object"&&t!=null){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var o in e)if(t.hasOwnProperty(o)){if(!Ot(e[o],t[o]))return!1}else return!1;return!0}else return!1}function gn(e){var t=[];return e.forEach(function(o){t.find(function(p){return Ot(o,p)})||t.push(o)}),t}function yn(e,t){var o,p;return Object.assign({},t,{popperOptions:Object.assign({},e.popperOptions,t.popperOptions,{modifiers:gn([].concat(((o=e.popperOptions)==null?void 0:o.modifiers)||[],((p=t.popperOptions)==null?void 0:p.modifiers)||[]))})})}var Me=wt?M.useLayoutEffect:M.useEffect;function bn(e){var t=(0,M.useRef)();return t.current||(t.current=typeof e=="function"?e():e),t.current}function gt(e,t,o){o.split(/\s+/).forEach(function(p){p&&e.classList[t](p)})}var wn={name:"className",defaultValue:"",fn:function(t){var o=t.popper.firstElementChild,p=function(){var x;return!!((x=t.props.render)!=null&&x.$$tippy)};function v(){t.props.className&&!p()||gt(o,"add",t.props.className)}function h(){p()&>(o,"remove",t.props.className)}return{onCreate:v,onBeforeUpdate:h,onAfterUpdate:v}}};function On(e){function t(o){var p=o.children,v=o.content,h=o.visible,b=o.singleton,x=o.render,S=o.reference,I=o.disabled,D=I===void 0?!1:I,k=o.ignoreAttributes,$=k===void 0?!0:k,V=o.__source,N=o.__self,H=bt(o,["children","content","visible","singleton","render","reference","disabled","ignoreAttributes","__source","__self"]),q=h!==void 0,_=b!==void 0,U=(0,M.useState)(!1),B=U[0],n=U[1],G=(0,M.useState)({}),m=G[0],te=G[1],K=(0,M.useState)(),a=K[0],s=K[1],u=bn(function(){return{container:mt(),renders:1}}),r=Object.assign({ignoreAttributes:$},H,{content:u.container});q&&(r.trigger="manual",r.hideOnClick=!1),_&&(D=!0);var l=r,f=r.plugins||[];x&&(l=Object.assign({},r,{plugins:_&&b.data!=null?[].concat(f,[{fn:function(){return{onTrigger:function(E,P){var A=b.data.children.find(function(j){var C=j.instance;return C.reference===P.currentTarget});E.state.$$activeSingletonInstance=A.instance,s(A.content)}}}}]):f,render:function(){return{popper:u.container}}}));var y=[S].concat(p?[p.type]:[]);return Me(function(){var w=S;S&&S.hasOwnProperty("current")&&(w=S.current);var g=e(w||u.ref||mt(),Object.assign({},l,{plugins:[wn].concat(r.plugins||[])}));return u.instance=g,D&&g.disable(),h&&g.show(),_&&b.hook({instance:g,content:v,props:l,setSingletonContent:s}),n(!0),function(){g.destroy(),b?.cleanup(g)}},y),Me(function(){var w;if(u.renders===1){u.renders++;return}var g=u.instance;g.setProps(yn(g.props,l)),(w=g.popperInstance)==null||w.forceUpdate(),D?g.disable():g.enable(),q&&(h?g.show():g.hide()),_&&b.hook({instance:g,content:v,props:l,setSingletonContent:s})}),Me(function(){var w;if(x){var g=u.instance;g.setProps({popperOptions:Object.assign({},g.props.popperOptions,{modifiers:[].concat((((w=g.props.popperOptions)==null?void 0:w.modifiers)||[]).filter(function(E){var P=E.name;return P!=="$$tippyReact"}),[{name:"$$tippyReact",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(P){var A,j=P.state,C=(A=j.modifiersData)==null?void 0:A.hide;(m.placement!==j.placement||m.referenceHidden!==C?.isReferenceHidden||m.escaped!==C?.hasPopperEscaped)&&te({placement:j.placement,referenceHidden:C?.isReferenceHidden,escaped:C?.hasPopperEscaped}),j.attributes.popper={}}}])})})}},[m.placement,m.referenceHidden,m.escaped].concat(y)),M.default.createElement(M.default.Fragment,null,p?(0,M.cloneElement)(p,{ref:function(g){u.ref=g,Ie(p.ref,g)}}):null,B&&(0,yt.createPortal)(x?x(mn(m),a,u.instance):v,u.container))}return t}var En=function(e,t){return(0,M.forwardRef)(function(p,v){var h=p.children,b=bt(p,["children"]);return M.default.createElement(e,Object.assign({},t,b),h?(0,M.cloneElement)(h,{ref:function(S){Ie(v,S),Ie(h.ref,S)}}):null)})};var Tn=En(On(ht),{render:function(){return""}}),Et=Tn;var R=z(oe());function Ne({storefrontProduct:e,variantGid:t}){let o=Xe(t)??e.variants.nodes.find(S=>S.id==t)??e.variants.nodes[0];if(!(e&&o))return null;let{availableForSale:p,compareAtPrice:v,price:h}=o,b=Ye(e.options),x=ze(e.options);return(0,R.jsx)(he,{to:`/products/${e.handle}`,children:(0,R.jsxs)("div",{className:ve("group min-w-[12.5em] rounded-md bg-white p-5 transition-[border-radius] duration-500 ease-out","hover:rounded-xl"),role:"row",children:[(0,R.jsxs)("div",{className:"overflow-hidden",children:[!p&&(0,R.jsx)("div",{className:"mb-2 text-xs font-bold uppercase text-darkGray",children:"Sold out"}),p&&v&&(0,R.jsx)("div",{className:"mb-2 text-xs font-bold uppercase text-red",children:"Sale"}),(0,R.jsx)("div",{className:"truncate text-lg font-bold group-hover:underline",children:e.title}),e.vendor&&(0,R.jsx)("div",{className:"mt-1 truncate text-sm text-darkGray",children:e.vendor}),b&&(0,R.jsx)("div",{className:"mt-1 truncate text-sm text-darkGray",children:x})]}),(0,R.jsxs)("div",{className:"mt-2 flex text-sm font-bold",children:[v&&(0,R.jsx)("span",{className:"text-darkGray",children:(0,R.jsx)(Ee,{data:v,className:"mr-2.5 line-through decoration-red"})}),h&&(0,R.jsx)(Ee,{data:h})]})]})})}var pe=z(oe());function xn({storefrontProduct:e,variantGid:t,x:o,y:p}){return e?(0,pe.jsx)(Et,{placement:"top",render:()=>(0,pe.jsx)(Ne,{storefrontProduct:e,variantGid:t}),children:(0,pe.jsx)(he,{className:ve("absolute left-[50%] top-[50%] flex h-[26px] w-[26px] -translate-x-1/2 -translate-y-1/2 animate-pulse items-center justify-center rounded-full bg-offBlack duration-300 ease-out","hover:scale-125 hover:animate-none"),style:{left:`${o}%`,top:`${p}%`},to:`/products/${e.handle}`,children:(0,pe.jsx)("div",{className:"relative h-[4px] w-[4px] rounded-full bg-white"})})}):null}export{Je as a,Et as b,Sn as c,Cn as d,Ht as e,Ne as f,xn as g};