@soma-vertical-web/multi-lib 0.0.40 → 0.0.41

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/index.js CHANGED
@@ -1,44 +1,4 @@
1
- "use strict";var Vu=Object.defineProperty;var Ku=(e,t,r)=>t in e?Vu(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var tr=(e,t,r)=>Ku(e,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),E=require("react"),Ye=require("idb-keyval"),ot=require("zustand"),zn=require("js-cookie"),v=require("@soma-vertical-web/core-components"),Te=require("./__vite-browser-external-B8mGO3z6.js"),Xu=require("jose"),et=require("@soma-vertical-web/foundations"),Mo=require("axios"),Ks=require("react-dom"),De=require("draft-js"),ko=require("@date-fns/tz"),so=E.createContext({}),Qu=({data:e,children:t})=>s.jsx(so.Provider,{value:{tags:e==null?void 0:e.config},children:t}),ao=()=>{const{tags:e}=E.useContext(so),t=E.useCallback(r=>{var a,c,u,l;const n=(c=(a=e==null?void 0:e.commercial)==null?void 0:a.items)==null?void 0:c.find(f=>{var p;return(p=r??[])==null?void 0:p.find(d=>d.id===f.key)}),o=(l=(u=e==null?void 0:e.institucional)==null?void 0:u.items)==null?void 0:l.find(f=>{var p;return(p=r??[])==null?void 0:p.find(d=>d.id===f.key)}),i=e==null?void 0:e.flagPdp;return{commercial:n,institucional:o,flagPdp:i}},[e]);return{tags:e,getAvailableProductTag:t}},Xs=({gridScrollBack:e})=>{E.useEffect(()=>{typeof window<"u"&&(e!=null&&e.refer)&&sessionStorage.setItem(e==null?void 0:e.refer,"true")},[])},Qs=E.createContext({}),Yu=({children:e,gridScrollBack:t})=>{const r=E.useRef(null);return Xs({gridScrollBack:t}),s.jsx(Qs.Provider,{value:{sizesContainerRef:r},children:e})},Zu=()=>{const e=E.useContext(Qs);if(e===void 0)throw new Error("useContext(PDPContext) must be used within a PDPProvider");return e},Me=(e,t=!0)=>Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL",minimumFractionDigits:t?2:0}).format(e),co=({valueInCents:e,hasFree:t,freeTaxMessage:r})=>e===0?t?r:Me(0):Me(e/100),uo=(e,t)=>{const[r,n]=e.split(t);return{name:r.trim(),size:n?n.trim():""}},Gt=(e,t)=>{if(!e)return{};const[r,n]=e.split(t);return{color:r==null?void 0:r.trim(),size:n==null?void 0:n.trim()}},Ys=(e,t="tamanho")=>{if(e.additionalProperty){const[r]=e.additionalProperty;return r!=null&&r.name?r.name.toLocaleLowerCase()===t?r.value:e.name:""}return e.name},Ju=(e,t)=>e.replace(t,"").trim(),el=e=>e.replace(/\//g,""),Zs=({items:e,NAME_SPLIT_SYMBOL:t})=>{const r={price:0,listPrice:0,installments:{count:0,value:0}},n=(a,c)=>{var d;c&&(c.sellerId=a.sellerId,c.sellerName=a.sellerName,c.available=!0,c.isSellerDefault=a.sellerDefault);const{Price:u,ListPrice:l,PaymentOptions:{installmentOptions:f}}=a.commertialOffer;r.price=u,r.listPrice=l;const p=(d=f==null?void 0:f[0])==null?void 0:d.installments;if(p){const{count:m,value:h}=p[p.length-1];r.installments={count:m,value:h/100}}};let o=!0;const i=e.reduce((a,c)=>{var f;const u={name:c.name,sku:c.itemId,value:((f=c.Tamanho)==null?void 0:f[0])??uo(c.nameComplete??c.name,t).size,available:!1,sellerId:"",sellerName:"",isSellerDefault:!1},l=c.sellers.filter(p=>(p.sellerDefault&&p.commertialOffer.IsAvailable&&(u.available=!0,n(p,u)),p.commertialOffer.IsAvailable));return!u.isSellerDefault&&l.length>0&&(u.available=!0,n(l[0],{...u,sellerId:l[0].sellerId,sellerName:l[0].sellerName})),u.available===!1&&(o=!1),a.push(u),a},[]);return{...r,sizes:i,allSizesAvailable:o}},Js=e=>e?!e.offers.offers.find(({quantity:t=0})=>t>0):!1,lo=(e,t)=>{const r=e.find(n=>n.availability.includes("InStock")&&n.quantity&&n.listPrice>0&&n.seller.identifier===t);return r||e.find(n=>n.availability.includes("InStock")&&n.quantity&&n.listPrice>0)},ea=e=>e.find(t=>t.imageLabel==="10"),ta=(e,t)=>{const r=/\/ids\/(\d+)\//,n=e.match(r);return n?e.replace(`/${n[1]}/`,`/${n[1]}-${t.width}-${t.height}/`):e},ra=(e,t)=>{const r=/\/ids\/(\d+)-(\d+)-(\d+)\//,n=e.match(r);return n?e.replace(`/${n[1]}-${n[2]}-${n[3]}/`,`/${n[1]}-${t.width}-${t.height}/`):e},na=({images:e,label:t})=>{const r=e.filter(n=>n.keywords===t.first||n.keywords===t.second||n.alternateName===t.first||n.alternateName===t.second);return r.length===0?[e[0]]:r},tl=e=>{const[t,r]=e.split("/").map(Number);if(Number.isNaN(t)||Number.isNaN(r))throw new Error("[ERROR ASPECT RATIO IMAGE]: Invalid aspect ratio format");return r/t},oa=(e,t,r)=>{t&&(e?(t.getAttribute("src")||(t.src=r??""),t.play()):t.pause())},rl=Object.freeze(Object.defineProperty({__proto__:null,disableSKU:Js,formatPriceToCurrency:Me,freightParsePrice:co,getAspectRatio:tl,getColorAndSizeFromSkuName:Gt,getFirstImages:na,getProductNameWithoutSku:Ju,getSKUName:Ys,getSkuInfos:Zs,getThumbImage:ea,getValidOffer:lo,removeSlashes:el,resizingImg:ta,setVideoPlay:oa,splitNameAndSizeFromFullName:uo,updatedResizedImg:ra},Symbol.toStringTag,{value:"Module"})),He=({event:e,data:t})=>{const r=(window==null?void 0:window.dataLayer)||[];t.ecommerce&&r.push({ecommerce:null}),r.push({...e&&{event:`custom_${e}`},...t})},be={configs:{PLP_FILTERS:[{key:"",label:"",eventLabel:"",order:0}],currency:"BRL",categoryOff:"bazar",storeUrl:"https://www.example.com",MAIN_IMAGE:"1",NAME_SPLIT_SYMBOL:"-"},productEvents:(e,t)=>{const{event:r,commonData:n,customData:o,promotionInfo:i,itemList:a,outsideEcommerceData:c}=e,{availableSizes:u,sizes:l,price:f}=n,p={...r==="view_item"?{currency:be.configs.currency,value:f,grade_disponivel:u??(l?ia(l):"")}:{},...r==="add_to_wishlist"||r==="remove_from_wishlist"?{value:f,currency:be.configs.currency}:{}},d=At({data:n,customData:{...o,...a,...i},configs:be.configs});He({event:r,data:{...c,ecommerce:{...a,...p,items:[d]}}}),typeof t=="function"&&t(d,p)},productListEvent:e=>{const{commonData:{products:t},promotionInfo:r,itemList:n,outsideEcommerceData:o,customData:i}=e;if(t.length===0)return;const a=t.map(({node:c},u)=>At({data:{...c},customData:{...r,index:u,...i!=null&&i.item_list_name?{item_list_name:i==null?void 0:i.item_list_name}:n},configs:be.configs}));He({event:"view_item_list",data:{...o,ecommerce:{...i!=null&&i.item_list_name?{item_list_name:i==null?void 0:i.item_list_name}:n,items:a}}})},skuEvents:e=>{const{event:t,commonData:{products:r},customData:n,supportData:{selectedSkus:o,price:i},promotionInfo:a,itemList:c,outsideEcommerceData:u}=e;let l=0;const f=r.map(p=>{var y,g,b,A,_,C,x,P,S;const d=o==null?void 0:o.find(I=>(p.productId??p.id)===I.productId);let m={...a,...c};if(d){const I=aa(),$=ca(I,d);$&&(m={...m,...$}),t==="add_to_cart"&&(a||c)&&Un({persistedData:I,type:"add",sku:(d==null?void 0:d.id)??(d==null?void 0:d.sku),newData:{promotionInfo:a,itemList:c}}),t==="remove_from_cart"&&Un({persistedData:I,type:"remove",sku:(d==null?void 0:d.id)??(d==null?void 0:d.sku)})}l+=p.price??((b=(g=(y=d==null?void 0:d.offers)==null?void 0:y.offers)==null?void 0:g[0])==null?void 0:b.price)??0;const h=(d==null?void 0:d.size)??Gt((d==null?void 0:d.skuName)??(d==null?void 0:d.name)??((A=p.itemOffered)==null?void 0:A.skuName),be.configs.NAME_SPLIT_SYMBOL).size;return At({data:p,customData:{...n,...m??{...a,...c},item_sku:(d==null?void 0:d.id)??(d==null?void 0:d.sku)??((_=p.itemOffered)==null?void 0:_.sku),quantity:(n==null?void 0:n.quantity)??p.quantity??1,item_variant2:h,seller_id:(d==null?void 0:d.sellerId)??(d==null?void 0:d.seller)??((S=(P=(x=(C=d==null?void 0:d.offers)==null?void 0:C.offers)==null?void 0:x[0])==null?void 0:P.seller)==null?void 0:S.identifier)??p.seller},configs:be.configs})});He({event:t,data:{...u,ecommerce:{value:i??l,currency:be.configs.currency,items:f}}})},filterEvent:e=>{var a;const{commonData:t,customData:r,outsideEcommerceData:n}=e,o={},i={};Array.isArray(t==null?void 0:t.selectedFacets)&&((a=t==null?void 0:t.selectedFacets)!=null&&a.length)&&((t==null?void 0:t.selectedFacets).forEach(({key:c,value:u})=>{var p;const l=((p=be.configs.PLP_FILTERS.find(d=>d.key===c))==null?void 0:p.eventLabel)??c,f=(o==null?void 0:o[l])||[];l==="price_range"&&u.replace(":","-"),o[l]=[...f,u]}),Object.keys(o).forEach(c=>i[c]=o[c].join(", "))),He({event:"filter",data:{...n,...i,...r}})},viewCartEvent:e=>{var f,p,d,m,h,y,g,b,A,_;const{commonData:t,outsideEcommerceData:r}=e,{cartStore:n}=t;if(!n)return;const o=window.localStorage.getItem("persistedCartEventsData"),i=o?JSON.parse(o):{},a=n.items.map(C=>{const{promotionInfo:x,itemList:P}=i[C.id]??{};return At({data:{...C,price:C.price/100,listPrice:C.listPrice/100},customData:{...x,...P,item_sku:C.id??C.itemOffered.sku,quantity:C.quantity??1},configs:be.configs})}),c=(((f=n.totalizers.find(C=>C.name==="Total dos Itens"))==null?void 0:f.value)??0)/100,u=(((p=n.totalizers.find(C=>C.name==="Total dos Descontos"))==null?void 0:p.value)??0)/100,l=((d=n.marketingData)==null?void 0:d.utmiCampaign)==="codigodavendedora"?(m=n.marketingData)==null?void 0:m.utmCampaign:(y=String((h=n.openTextField)==null?void 0:h.value))==null?void 0:y.split(" - ")[0];He({event:"view_cart",data:{...r,ecommerce:{currency:be.configs.currency,value:c+u,total_discount:Math.abs(u),cep_preenchido:!!((b=(g=n.shippingData)==null?void 0:g.address)!=null&&b.postalCode),...l?{seller_coupon_name:l}:{},...((A=n.marketingData)==null?void 0:A.coupon)&&{sale_coupon_name:(_=n.marketingData)==null?void 0:_.coupon},subtotal:c,items:a}}})},readyEvents:e=>{const{event:t,readyData:r}=e;He({event:t,data:{...r}})}},ia=e=>e.reduce((t,r)=>(r.available&&t.push(r.value),t),[]).toString(),nl=e=>{const t=e.length;return{...e&&e.length>0?{item_category:e[0].includes(be.configs.categoryOff)?"Bazar":"Coleção",...e[1]?{item_category2:e[1]}:{},...t>2?{item_category3:e[t-1]}:{}}:{}}},At=({data:e,customData:t,configs:r})=>({...ol(e,r==null?void 0:r.MAIN_IMAGE),...il(e),...sl(e),...al(e),...t}),sa=()=>{var e,t;return document?((t=(e=window.document.head.querySelector('meta[name="category"]'))==null?void 0:e.getAttribute("content"))==null?void 0:t.split("_"))??[]:[]},aa=()=>{const e=window.localStorage.getItem("persistedCartEventsData");return e?JSON.parse(e):null},ca=(e,t)=>e==null?void 0:e[t],Un=({persistedData:e,type:t,sku:r,newData:n})=>{if(!e&&t==="add"){window.localStorage.setItem("persistedCartEventsData",JSON.stringify({[r]:n}));return}if(e&&t==="add"){window.localStorage.setItem("persistedCartEventsData",JSON.stringify({...e,[r]:n}));return}e&&t==="remove"&&(delete e[r],window.localStorage.setItem("persistedCartEventsData",JSON.stringify(e)))},ol=(e,t="1")=>{var i,a,c,u,l,f,p,d,m,h,y;const r=e.productReference??e.gtin??e.productRefId,n=e.image??((a=(i=e.items)==null?void 0:i[0])==null?void 0:a.images)??((c=e.itemOffered)==null?void 0:c.image),o=n==null?void 0:n.find(g=>g.alternateName===t||g.imageLabel===t||g.keywords===t);return{item_id:e.productId??((u=e.isVariantOf)==null?void 0:u.productGroupID)??((l=e.isVariationOf)==null?void 0:l.productGroupID)??((p=(f=e.itemOffered)==null?void 0:f.isVariationOf)==null?void 0:p.productGroupID),item_ref:/_\d$/.test(r)?r.slice(0,-2):r,item_name:e.productTitle??e.productName??e.name??uo((d=e.itemOffered)==null?void 0:d.name,be.configs.NAME_SPLIT_SYMBOL).name,item_brand:((m=e.brand)==null?void 0:m.brandName)??((h=e.brand)==null?void 0:h.name)??e.brand??((y=e.itemOffered)==null?void 0:y.brand.name),item_url:`${be.configs.storeUrl}${e.linkText}/p`,item_image:(o==null?void 0:o.url)??(o==null?void 0:o.imageUrl)}},Lo=e=>Array.isArray(e)?e.reduce((t,r)=>(r.length>t.length&&(t=r),t),""):e,il=e=>{var l,f;const{categories:t,categoriesIds:r}=e,n=t??((l=e.itemOffered)==null?void 0:l.categories),o=r??((f=e.itemOffered)==null?void 0:f.categoriesIds),i=Lo(n),a=Lo(o),c=i.slice(1,-1).split("/"),u=a.slice(1,-1).split("/");return{item_category:c[0].toLowerCase().includes(be.configs.categoryOff)?"Bazar":"Coleção",...c[1]&&{item_category2:c[1]},...c.length>2&&{item_category3:c[c.length-1]},item_category_id:u[u.length-1],...u.length>1&&{item_parent_category_id:u[u.length-2]}}},sl=e=>{var o,i,a,c,u,l;const t=((o=e.itemOffered)==null?void 0:o.skuName)??((c=(a=(i=e.isVariantOf)==null?void 0:i.hasVariant)==null?void 0:a[0])==null?void 0:c.name)??((l=(u=e.items)==null?void 0:u[0])==null?void 0:l.name),{color:r,size:n}=Gt(t,be.configs.NAME_SPLIT_SYMBOL);return{item_variant:r,...e.itemOffered&&{item_variant2:n}}},al=e=>{var u,l;const{price:t,listPrice:r,installments:n}=e,o=t??((u=e.offers)==null?void 0:u.lowPrice)??0,i=r??((l=e.offers)==null?void 0:l.highPrice)??0,a=i?i-o:0,c=a%1===0?a:Number(a.toFixed(2));return{...t&&{price:o??i},...i&&{list_price:i,discount:c},...n&&{installments:n==null?void 0:n.count,installment_value:n==null?void 0:n.value},item_currency:be.configs.currency}},ua=()=>{const[e,t]=sa(),[r,n]=e.split("-"),o=r.includes("shop")||r.includes("sale")?r:"";return{page_category:o&&n?n:"",page_departament:o,id:t,name:e}},cl=Object.freeze(Object.defineProperty({__proto__:null,eventsFunctions:be,findDataInPersistedData:ca,getAvailablesSizes:ia,getCategories:nl,getPageCategoryAndDepartmentFromSlug:ua,getPersistedData:aa,getProductListInfoFromHead:sa,pushDatalayer:He,updatePersistedData:Un},Symbol.toStringTag,{value:"Module"})),la=E.createContext({}),ul=({children:e,evtFunctionsConfigs:t})=>{const r=E.useRef({}),n=E.useRef(null),o=E.useRef(null),i=E.useRef({}),a=E.useRef({trigger:!1,index:0}),c=({functionKey:f,data:p,callBack:d,timeout:m=100})=>{window.dataLayer||(window.dataLayer=[]),be.configs=t;try{typeof be[f]=="function"&&setTimeout(()=>{var h;p.promotionInfo=r.current,(h=o.current)!=null&&h.item_list_name&&(p.itemList=o.current),be[f](p,d)},m)}catch(h){He({event:"error_event",data:{error_message:(h==null?void 0:h.message)??h}})}},u=({content:f})=>{c({functionKey:"readyEvents",data:{event:"select_content",readyData:{content_type:f.replace("::",":")}}})},l=({updatePromotionRef:f,promotion:p,index:d})=>{f&&(r.current={...p}),c({functionKey:"readyEvents",data:{event:"select_promotion",readyData:{ecommerce:{...p,...d!==void 0&&{index:d}}}}})};return s.jsx(la.Provider,{value:{sendDataLayerEvent:c,triggerSelectItemEventRef:a,promotionEventRef:r,currentLocalRef:n,itemListRef:o,cartProductsFullDataRef:i,handleSelectContent:u,handleSelectPromotionEvent:l},children:e})},ge=()=>E.useContext(la),da=E.createContext({}),ll=({children:e,productData:t,isKit:r,PDP_INFO:n,NAME_SPLIT_SYMBOL:o})=>{var B,R;const{sendDataLayerEvent:i,triggerSelectItemEventRef:a}=ge(),{productId:c,productName:u,items:l,items:[{images:f,Videos:p}],description:d,["Composição"]:m="",productReference:h,categories:[y]}=t,{getAvailableProductTag:g}=ao(),b=g(Object.entries(t.clusterHighlights).map(q=>({id:q[0],name:q[1]}))),A=y.slice(1,-1).split("/"),{installments:_,price:C,listPrice:x,sizes:P,allSizesAvailable:S}=Zs({items:l,NAME_SPLIT_SYMBOL:o}),I=ea(f),$=[{label:`${n.product.description}`,value:"description",content:d},{label:`${n.product.materiais}`,value:"composition",content:m}],w=((R=Gt((B=t.items)==null?void 0:B[0].name,o))==null?void 0:R.color)??t["Cores Filtráveis"][0]??"",N=()=>({commonData:{...t,sizes:P,price:C,listPrice:x,installments:_},customData:{installments:_==null?void 0:_.count,installment_value:Number(_==null?void 0:_.value).toFixed(2)}}),k=({sku:q,size:z})=>{const{commonData:U,customData:K}=N();i({functionKey:"productEvents",data:{event:"view_item",commonData:U,customData:{...K,...q&&{item_sku:q},...z&&{item_variant2:z}}}})};return E.useEffect(()=>{if(a.current.trigger){const{commonData:q,customData:z}=N();i({functionKey:"productEvents",data:{event:"select_item",commonData:q,customData:{...z,index:a.current.index}}}),a.current.trigger=!1}k({})},[]),s.jsx(da.Provider,{value:{productData:t,productId:c,productName:u,productReference:h,tag:b,items:l,sizes:P,allSizesAvailable:S,installments:_,price:C,listPrice:x,thumbImage:I,images:f,video:p[0],descriptionContent:$,breadcrumbList:A,isKit:r,colorName:w,handleViewItemEvent:k},children:e})},fo=()=>{const e=E.useContext(da);if(e===void 0)throw new Error("useContext(PDPDataContext) must be used within a PDPDataProvider");return e},dl={attachment:"ATTACHMENT",specification:"SPECIFICATION",attribute:"ATTRIBUTE"},Oe=Promise.resolve(!1),Gn={id:"",isOpen:!1,items:[],loading:!1,marketingData:null,messages:[],openTextField:{},paymentData:null,shippingData:null,totalizers:[],itemMetadata:[],recentlyAddedProducts:[],addCoupon:()=>Oe,addItem:()=>Oe,addSellerCode:()=>Oe,addMarketingData:()=>Oe,emptyCart:()=>{},removeItem:()=>Oe,setIsOpen:()=>{},shipping:()=>Oe,shippingUpdate:()=>Oe,toggleServiceToProduct:()=>Oe,updateItemQuantity:()=>Oe,insertProfileEmail:()=>Oe,setRecentlyAddedProducts:()=>{}},po=e=>e===0,fa=(e,t)=>{if(!e||e.length===0)return[];let r="";const n=[],o=e.match(/\d+/g)??[];for(const i of o){const a=t[Number(i)];a&&(r+=(r?"/":"")+a,n.push(r))}return n},pa=(e,t)=>{const{availability:r,additionalInfo:{brandName:n},bundleItems:o,id:i,uniqueId:a,detailUrl:c,ean:u,imageUrl:l,name:f,listPrice:p,quantity:d,price:m,priceDefinition:h,productCategories:y,productCategoryIds:g,productId:b,refId:A,seller:_,referenceId:C,offerings:x,productRefId:P,skuName:S,sellingPrice:I}=e;return{availability:r,bundleItems:o,referenceId:C,productRefId:P,id:i,ean:u,uniqueId:a,itemOffered:{additionalProperty:[],brand:{name:n},categories:fa(g,y),categoriesIds:g,gtin:A,image:[{alternateName:(t==null?void 0:t.MAIN_IMAGE)??"1",url:l}],name:f,isVariationOf:{name:f,productGroupID:b},sku:i,slug:c,skuName:S},listPrice:p,quantity:d,offerings:x,price:m,priceDefinition:h,sellingPrice:I,seller:_}},ma=(e,t)=>{const r=e.map(n=>({id:n.id,quantity:n.quantity,seller:n.seller}));return Array.isArray(t)?[...r,...t]:[...r,t]},ha=(e,t)=>{const r=e.find(n=>n.id===t);if(r){const n=e.map((o,i)=>{var a,c;return{id:((a=o.itemOffered)==null?void 0:a.sku)??"",index:i,quantity:(r==null?void 0:r.id)===((c=o.itemOffered)==null?void 0:c.sku)?0:o.quantity,seller:o.seller??""}});return{updateItems:n,filterItems:n.filter(o=>o.id!==t)}}return{updateItems:[],filterItems:[]}},ga=(e,t,r)=>e.filter(n=>n.availability!=="withoutStock"&&n.availability!=="https://schema.org/OutOfStock").map((n,o)=>{var i,a;return n.id===t?{id:n.id,index:o,quantity:r,seller:n.seller,sku:((i=n.itemOffered)==null?void 0:i.sku)??""}:{id:n.id,index:o,quantity:n.quantity,seller:n.seller,sku:((a=n.itemOffered)==null?void 0:a.sku)??""}}),Wn=(e,t)=>e.filter(r=>r.availability!=="withoutStock").findIndex(({id:r})=>r===t),fl=(e,t)=>{var r;return Array.isArray(e)?(((r=e==null?void 0:e.find(n=>{var o;return((o=n==null?void 0:n.id)==null?void 0:o.toLowerCase())===t}))==null?void 0:r.value)??0)/100:0},pl=e=>{const t=e.reduce((o,i)=>{const a=po(i.price)?0:i.quantity;return o+a},0),r=e.reduce((o,i)=>o+i.price*i.quantity,0),n=e.reduce((o,i)=>o+i.listPrice*i.quantity,0);return{totalItems:t,total:r,subTotal:n}},ml=e=>Array.isArray(e)?e.filter(t=>t.availability!=="withoutStock").reduce((t,r)=>t+(po(r==null?void 0:r.price)?0:r.quantity),0):0,ya=(e,t)=>{const{items:r,itemMetadata:n,marketingData:o,messages:i,orderFormId:a,openTextField:c,paymentData:u,shippingData:l,totalizers:f}=e;return{id:a,itemMetadata:n,items:Array.isArray(r)?r.map(p=>pa(p,t)):[],marketingData:o,messages:i,openTextField:c,paymentData:u,shippingData:l,totalizers:f}},_a=(e,t)=>{const r=e.find(n=>n.id===t);return r?r.availability==="unavailableItemFulfillment":!1},hl=(e,t)=>{const r=e.sku,n=e.isVariantOf.hasVariant.find(o=>o.sku===r);return n?n.name.split(t)[1]:"--"},Je=(e,t,r=!1)=>!e&&t!==""?{code:300,value:t,statusOk:r}:e===t?{code:200,value:t,statusOk:r}:{code:400,value:t,statusOk:r},gl=(e,t)=>{const r=new Set;return[e,...t].filter(n=>!r.has(n)&&r.add(n),r)},va=(e,t)=>t&&Array.isArray(t)&&t.find(n=>n.id===e)?Promise.resolve(e):Promise.resolve(!1),ba=(e,t)=>t?Promise.resolve(e[t]):Promise.resolve(!1),xa=async e=>{try{const t=await e();if(typeof t!="boolean")return t}catch(t){console.error(`[Error orderForm]: ${t}`)}return!1},Ca=(e,t)=>{if(t!==-1){const r=Number(e);return r?r+1:1}return e??1},Sa=(e,t)=>Array.isArray(e)?e.filter(r=>t==null?void 0:t.some(n=>n.id===r.id)):[],Aa=async(e,t)=>e.then(r=>[...r??[],...t??[]]),we=async(e,t,r,n)=>{const{priority:o="auto",body:i}=t;return fetch(e,{headers:{"Content-Type":"application/json"},priority:o,method:"POST",body:JSON.stringify(i)}).then(async a=>{const c=await a.json();return r?c:ya(c,n)})},Ea=(e,t,r)=>({notifications:[...e.notifications,{id:Date.now(),message:t,callback:r}]}),yl=e=>[...Array.isArray(e)?e:[e],"faststore"],wa=e=>{const t=e.get("utm_source")||Ge("utm_source"),r=e.get("utm_campaign")||Ge("utm_campaign"),n=e.get("utm_medium")||Ge("utm_medium"),o=e.get("utmi_cp")||Ge("utmi_cp"),i=e.get("utmi_pc")||Ge("utmi_pc"),a=e.get("utmi_p")||Ge("utmi_p");return{...t&&{utmSource:t},...n&&{utmMedium:n},...r&&{utmCampaign:r},...o&&{utmiCampaign:o},...i&&{utmiPart:i},...a&&{utmipage:a}}},Ge=e=>{if(!e||typeof window>"u")return;const t=window.location.href;e=e.replace(/[[\]]/g,"\\$&");const r=new RegExp("[?&]"+e+"(=([^&#]*)|&|#|$)"),n=r.exec(t);return n?n[2]?decodeURIComponent(n[2].replace(/\+/g," ")):"":null},_l=Object.freeze(Object.defineProperty({__proto__:null,VALUE_REFERENCES:dl,addItemOrder:ma,addNotification:Ea,createItemOrder:pa,fetchCartAPI:we,findItemIndex:Wn,findOptions:Sa,findTotalizerValue:fl,getCategories:fa,getCode:Je,getQuantity:Ca,getRemoveId:va,getSize:hl,getTotalItems:ml,getTotalizer:pl,getUrlParameter:Ge,getValue:ba,initialState:Gn,isGift:po,marketingTagsBuilder:yl,mergeOptionsPromise:Aa,mountMarketingData:wa,orderFormValues:ya,promiseDefault:Oe,removeQuantity:ha,updateItemSellerExternal:_a,updateOrderFormPromise:xa,updateQuantity:ga,wishlistArray:gl},Symbol.toStringTag,{value:"Module"})),vl=()=>{const e=async(m,h)=>we("/api/checkout/order-form/coupon",{body:{orderFormId:m,coupon:h}}),t=async(m,h)=>{if(h){const y=h.includes(" - ")?h.split(" - ")[0]:h,g=await we("/api/checkout/order-form/seller-code",{body:{orderFormId:m,sellerCode:y}},!0);return we("/api/checkout/order-form/attachments",{body:{orderFormId:m,sellerCode:y,sellerName:g instanceof Object&&"name"in g?g==null?void 0:g.name:""}}).then(b=>({...b,openTextField:{...(b==null?void 0:b.openTextField)??{},statusOk:(g==null?void 0:g.ativo)??!1}}))}else return we("/api/checkout/order-form/attachments",{body:{orderFormId:m,sellerCode:"",sellerName:""}})},r=async(m,h)=>we("/api/checkout/order-form/attachments/marketing-data",{body:{orderFormId:m,marketingData:h}}),n=async(m,h,y)=>we("/api/checkout/order-form/items",{body:{orderFormId:m,orderItems:ma(h,y)}}),o=async(m,h,y,g)=>we("/api/checkout/order-form/offerings",{body:{id:h,itemIndex:y,orderFormId:m,remove:g}}),i=async m=>we("/api/checkout/order-form/items/remove-all",{body:{orderFormId:m}}),a=async(m,h="low")=>we("/api/checkout/order-form",{priority:h,body:{orderFormId:m??""}}),c=async(m,h)=>we("/api/checkout/order-form/profile",{body:{orderFormId:m,email:h}}),u=async(m,h,y)=>{const g=ha(h,y);return we("/api/checkout/order-form/items/update",{body:{orderItems:g.updateItems,orderFormId:m}})},l=async(m,h,y)=>we("/api/checkout/order-form/shipping",{body:{orderFormId:m,country:y,postalCode:h}}),f=async(m,h,y)=>we("/api/checkout/order-form/shipping/update",{body:{orderFormId:m,options:h,selectedAddresses:y}}),p=async(m,h,y,g)=>{const b=ga(h,y,g);return we("/api/checkout/order-form/items/update",{body:{orderFormId:m,orderItems:b}})};return{addCoupon:e,addItem:n,addSellerCode:t,addMarketingData:r,giftItem:o,emptyCart:i,getOrderForm:a,insertProfileEmail:c,removeItem:u,shipping:l,shippingUpdate:f,updateItemQuantity:async(m,h,y,g,b)=>p(m,h,y,g).then(A=>A&&Array.isArray(A.items)?_a(A.items,y)?p(m,h,y,b):A:!1)}},Vn="soma::cart",ct="soma::options",tt=ot.create((e,t)=>{const r=vl(),n=async(o,i,a)=>{e({loading:!0});const c=await xa(o);if(typeof c!="boolean"){e({...c});const u=await Aa(Ye.get(ct),a);return Ye.set(ct,u),ba(c,i).finally(()=>e({loading:!1,options:u}))}return Oe};if(typeof window<"u"){const o=async i=>{if(i){const a=await Ye.get(ct).then(l=>Sa(l,i.items));Ye.set(Vn,i),Ye.set(ct,a),e({...i,options:a});const c=new URLSearchParams(window.location.search),u=c.get("utm_campaign")||c.get("utmi_campaign")||"";u&&n(()=>r.addSellerCode(t().id,u.toUpperCase()),"openTextField")}};return Ye.get(Vn).then(i=>r.getOrderForm(i?i.id:"").then(o)),{...Gn,addCoupon:async i=>n(()=>r.addCoupon(t().id,i),"marketingData"),addItem:(i,a)=>{n(()=>r.addItem(t().id,t().items,i),"items",a)},addSellerCode:async i=>n(()=>r.addSellerCode(t().id,i),"openTextField"),addMarketingData:async i=>n(()=>r.addMarketingData(t().id,i),"marketingData"),emptyCart:()=>{n(()=>r.emptyCart(t().id))},removeItem:async i=>{const a=await n(()=>r.removeItem(t().id,t().items,i),"items");return va(i,a)},shipping:async(i,a="BR")=>n(()=>r.shipping(t().id,i??"",a),"shippingData"),shippingUpdate:async i=>n(()=>{var a;return r.shippingUpdate(t().id,i,(a=t().shippingData)==null?void 0:a.selectedAddresses)},"shippingData"),toggleServiceToProduct:async(i,a,c)=>n(()=>r.giftItem(t().id,i,a,c),"items"),updateItemQuantity:async(i,a,c)=>{const{id:u,items:l}=t();return n(()=>{var f;return r.updateItemQuantity(u,l,i,a,((f=l.find(p=>p.id===i))==null?void 0:f.quantity)??1)},"items",c?[c]:void 0)},insertProfileEmail:async i=>n(()=>r.insertProfileEmail(t().id,i),"clientProfileData"),setIsOpen:i=>e({isOpen:i})}}return Gn}),bl=()=>tt(e=>e),Ra=ot.create(e=>({notifications:[],actions:{addNotification:(t,r)=>e(n=>Ea(n,t,r)),removeNotification:t=>e(r=>({notifications:r.notifications.filter(n=>n.id!==t)}))}})),ja=()=>Ra(e=>e.notifications),Pa=()=>Ra(e=>e.actions),xl=Object.freeze(Object.defineProperty({__proto__:null,KEY_INDEXED_OPTIONS:ct,KEY_INDEXED_STORE:Vn,useCartStore:tt,useGetCartStoreState:bl,useGetNotificationActions:Pa,useGetNotificationsStore:ja},Symbol.toStringTag,{value:"Module"})),Cl=6e3,Ia=E.createContext({}),Na=({children:e,...t})=>{const{items:r}=tt(),[n,o]=E.useState([]),i=E.useRef(null),a=E.useMemo(()=>Array.isArray(n)&&n.length>0?n.map(c=>r.find(u=>u.id===c.id)).filter(c=>c!==void 0):[],[r,n]);return E.useEffect(()=>{n.length&&(clearTimeout(i.current??0),i.current=setTimeout(()=>{o([])},Cl))},[n]),s.jsx(Ia.Provider,{value:E.useMemo(()=>({...t,setRecentlyAdded:o,recentlyAddedProducts:a}),[t,o,a]),children:e})},pt=()=>{const e=E.useContext(Ia);if(e===void 0)throw new Error("useUIContext must be used within a UIProvider");return e};class Oa{constructor(){tr(this,"events",{});tr(this,"prevData",{})}subscribe(t,r){return this.events[t]||(this.events[t]=[]),this.events[t].push(r),()=>{this.events[t]=this.events[t].filter(n=>n!==r)}}publish(t,r){this.events[t]&&this.events[t].forEach(n=>{this.prevData[t]=r,n(r)})}}const Ta=E.createContext({}),Sl=({children:e,headerConfigs:t,pathname:r,...n})=>{const[o,i]=E.useState(!0),a=r==="/",c=E.useRef(new Oa),u=p=>p?{headerVariant:t.home_default_variant,bannerVariant:t.home_default_variant,position:t.home_default_position}:{headerVariant:t.default_variant,bannerVariant:t.default_variant,position:t.default_position},l=u(a),f=E.useRef(l);return E.useEffect(()=>{var m;const p=((m=new URLSearchParams(window.location.search))==null?void 0:m.toString())??"";(p.includes("utm_")||p.includes("gclid"))&&(zn.get("lastMedias")||zn.set("lastMedias",`${p}`,{expires:1/24}));const d=()=>{const h=typeof(window==null?void 0:window.navigator)>"u"?"":navigator==null?void 0:navigator.userAgent,y=/iPad|iPhone|iPod/.test(h),g=window.innerWidth<1024||!!h.match(/Android|BlackBerry|iPhone|iPad|iPod|Opera Mini|IEMobile|WPDesktop/i);if(y){const b=document.querySelector('meta[name="viewport"]');b&&b.setAttribute("content","width=device-width, initial-scale=1, maximum-scale=1")}o!==g&&i(g)};return d(),window.addEventListener("resize",d,{passive:!0}),()=>window.removeEventListener("resize",d)},[o]),E.useEffect(()=>{const p=u(a);c.current.publish("header:change_variant",p.headerVariant),c.current.publish("header:change_position",p.position),f.current=p},[a]),s.jsx(Ta.Provider,{value:{isMobile:o,mediatorRef:c,currentHeaderConfigsRef:f,...n},children:s.jsx(Na,{children:e})})},Ae=()=>E.useContext(Ta),Ma=E.createContext({}),Al=({children:e,...t})=>s.jsx(Ma.Provider,{value:{...t},children:e}),je=()=>E.useContext(Ma),Ke=(e,t)=>ot.create(r=>{const n=()=>r({value:e});return t&&t instanceof Set&&t.add(n),{value:e,actions:{setValue:o=>r({value:o}),reset:n}}}),ft={category:null,menuMobileIsOpen:!1,searchModalIsOpen:!1,userMenuIsOpen:!1},mt=new Set,El=()=>{mt.forEach(e=>{e()})},ka=ot.create((e,t)=>{const r=()=>e({value:ft.category});return mt.add(r),{value:ft.category,actions:{reset:r,setValue:n=>e(()=>({value:n})),updateValue:n=>{t().value!==n&&e({value:n})}}}}),Wt=()=>ka(e=>e.value),Ue=()=>ka(e=>e.actions),La=Ke(ft.menuMobileIsOpen,mt),mo=()=>La(e=>e.value),Xe=()=>La(e=>e.actions),Da=Ke(ft.searchModalIsOpen,mt),wl=()=>Da(e=>e.value),ho=()=>Da(e=>e.actions),$a=Ke(ft.userMenuIsOpen,mt),Ba=()=>$a(e=>e.value),ht=()=>$a(e=>e.actions),Rl=Object.freeze(Object.defineProperty({__proto__:null,resetAllHeaderStores:El,useActionsHeaderCategory:Ue,useActionsMenuMobileIsOpen:Xe,useActionsSearchModalIsOpen:ho,useActionsUserMenuIsOpen:ht,useGetHeaderCategoryStore:Wt,useGetMenuMobileIsOpen:mo,useGetSearchModalIsOpen:wl,useGetUserMenuIsOpen:Ba},Symbol.toStringTag,{value:"Module"})),rt={selectedSkuInfo:{productId:"",name:"",size:"",sku:"",sellerId:"",sellerName:"",available:!1,quantity:1},openLetMeKnow:!1,openMeasurements:!1,showBottomNavigation:!1,showNotify:!1},it=new Set,jl=()=>{it.forEach(e=>{e()})},qa=ot.create(e=>{const t=()=>e({value:rt.selectedSkuInfo});return it.add(t),{value:rt.selectedSkuInfo,actions:{setValue:r=>e(n=>({value:{...n,...r}})),reset:t}}}),Pl=()=>qa(e=>e.value),Il=()=>qa(e=>e.actions),Ha=Ke(rt.openLetMeKnow,it),Nl=()=>Ha(e=>e.value),Ol=()=>Ha(e=>e.actions),Fa=Ke(rt.showNotify,it),Tl=()=>Fa(e=>e.value),Ml=()=>Fa(e=>e.actions),za=Ke(rt.showBottomNavigation,it),kl=()=>za(e=>e.value),Ll=()=>za(e=>e.actions),Ua=Ke(rt.openMeasurements,it),Dl=()=>Ua(e=>e.value),$l=()=>Ua(e=>e.actions),Bl=Object.freeze(Object.defineProperty({__proto__:null,resetAllPDPStores:jl,useActionsPDPOpenLetMeKnow:Ol,useActionsPDPOpenMeasurements:$l,useActionsPDPSelectedSkuInfo:Il,useActionsPDPShowBottomNavigation:Ll,useActionsPDPShowNotify:Ml,useGetPDPOpenLetMeKnow:Nl,useGetPDPOpenMeasurements:Dl,useGetPDPSelectedSkuInfo:Pl,useGetPDPShowBottomNavigation:kl,useGetPDPShowNotify:Tl},Symbol.toStringTag,{value:"Module"})),Ga=E.createContext({}),ql=({children:e,headerData:t,...r})=>{var f,p;const n=E.useRef(null),o=E.useRef(null),i=E.useRef(null),a=E.useRef(null),c=E.useRef(null),{mediatorRef:u,currentHeaderConfigsRef:l}=Ae();return(f=u.current)==null||f.subscribe("header:change_variant",d=>{var b,A,_;if(d&&l.current&&(l.current.bannerVariant=d),!n.current)return;const h=document.body.scrollTop>0,y=n.current.getAttribute("data-interactiveVariant"),g=h?y:d??((b=l.current)==null?void 0:b.bannerVariant)??"default";g!==((A=l.current)==null?void 0:A.headerVariant)&&(n.current.setAttribute("data-bottomdivider",String(h)),n.current.setAttribute("data-variant",String(g)),(_=u.current)==null||_.publish("herobanner:change_controllers_variant",g),l.current&&(l.current.headerVariant=g))}),(p=u.current)==null||p.subscribe("header:change_position",d=>{n.current&&(n.current.style.position=d)}),E.useEffect(()=>{const d=new AbortController,m=v.helpers.throttle(()=>{var y;return(y=u.current)==null?void 0:y.publish("header:change_variant",null)},200);document.body.addEventListener("scroll",m,{passive:!0,signal:d.signal});const h=y=>{var b;(b=y.target.closest("a"))==null||b.blur()};return n.current&&(n.current.addEventListener("click",h,{signal:d.signal}),n.current.addEventListener("touchend",h,{signal:d.signal})),()=>{d.abort()}},[]),s.jsx(Ga.Provider,{value:{headerData:t,structureRef:o,rootRef:n,tipbarRef:i,userMenuMobileRef:a,userMenuDesktopRef:c,...r},children:e})},ve=()=>E.useContext(Ga),Wa=E.createContext({}),Va=({children:e})=>{const t=E.useRef(null),r=E.useRef(null),n=mo(),o=E.useCallback(()=>{var i;{const a=(i=t.current)==null?void 0:i.querySelector("dialog");if(a){a.dataset.animation="out";const c=a.children[0];c.dataset.animation="out"}}},[]);return E.useEffect(()=>{var i;if(n)document.body.dataset.modalopen="true";else{document.body.dataset.modalopen="false";const a=(i=r.current)==null?void 0:i.querySelector("dialog");if(a){a.dataset.animation="out";const c=a.children[0];c.dataset.animation="out"}}},[n]),E.useEffect(()=>{r.current=document.body},[]),s.jsx(Wa.Provider,{value:{bodyRef:t,handleCloseSubMenu:o,documentBodyRef:r},children:e})},gt=()=>E.useContext(Wa),Hl=e=>{if(!e||typeof window>"u")return 0;const t=window.getComputedStyle(e);return parseInt(t.padding,10)},Fl=(e,t,r)=>{if(!(e instanceof HTMLElement)||!(t instanceof HTMLElement))return{left:0,top:0};const n=t.getBoundingClientRect(),o=e.getBoundingClientRect(),i=e!=null&&e.parentElement?Hl(e==null?void 0:e.parentElement):0;return{left:n.left+n.width/2-(o.width+i),top:n.top+n.height+r}},Ka=E.createContext({}),Xa=({children:e,delay:t=600,gap:r=20,...n})=>{const[o,i]=E.useState(!1),a=E.useRef(null),[c,u]=E.useState(!1),[l,f]=E.useState({left:0,top:0}),p=E.useCallback(()=>{u(!0),typeof window<"u"&&(a.current=window.setTimeout(()=>{i(!1),u(!1)},t))},[u,i,t]);return E.useEffect(()=>{if(typeof window>"u")return;const d=window.document.querySelector("#cart-button"),m=window.document.querySelector("#add-to-cart--tooltip");if(d&&m){const{left:h,top:y}=Fl(m,d,r??0);f({left:h,top:y}),u(!1)}},[r,o]),s.jsx(Ka.Provider,{value:E.useMemo(()=>({...n,...l,handleClose:p,isLeaving:c,isOpen:o,setIsOpen:i,setIsLeaving:u}),[n,l,p,c,o,i,u]),children:e})},Qe=()=>{const e=E.useContext(Ka);if(e===void 0)throw new Error("useAddToCartContext must be used within a AddToCartProvider");return e},Qa=E.createContext({}),zl=({children:e,CARTPROVIDER_MESSAGE_PRODUCT_REMOVE:t,...r})=>{const n=tt(),{setRecentlyAdded:o}=pt(),i=E.useRef(""),a=ja(),{addNotification:c,removeNotification:u}=Pa(),{addCoupon:l,addItem:f,addSellerCode:p,addMarketingData:d,emptyCart:m,isOpen:h,removeItem:y,shipping:g,shippingUpdate:b,toggleServiceToProduct:A,updateItemQuantity:_}=n;E.useEffect(()=>{const R=zn.get("lastMedias");if(n.id&&R&&i.current!==R){i.current=R;const q=new URLSearchParams(R),z=wa(q);d(z)}},[n,d]);const C=E.useCallback(async(R,q)=>(q==="coupon"?l(R):p(R)).then(U=>{if(typeof U!="boolean"&&U instanceof Object){if(q==="seller"&&"value"in U){const{statusOk:K,value:W}=U,F=String(W??"").split(" - ");return Je((F==null?void 0:F[0])??"",R,!!K)}return Je(String(U.coupon),R,!0)}return Je("","")}).catch(()=>Promise.resolve({code:400})),[l,p]),x=E.useCallback((R,q,z)=>{const{id:U}=R;_(U,q,z)},[_]),P=E.useCallback((R,q,z=!1)=>{if(!R)return;const{id:U}=R,K=Wn(n.items,U);if(K!==-1&&!z){const W=Number(n.items[K].quantity),F=n.items[K]?W+1:1;x(R,F,q)}else f({id:U,quantity:(R==null?void 0:R.quantity)??1,seller:R.seller});h||o(W=>[...W,R])},[f,x,n.items,h,o]),S=E.useCallback((R,q)=>{if(!R||!Array.isArray(R))return;o(U=>[...U,...R]);const z=R.map(U=>{const{id:K,quantity:W,seller:F}=U,ne=Wn(n.items,K),j=Ca(W??1,ne);return{id:K,quantity:j,seller:F}});f(z,q)},[f,n.items,o]),I=E.useCallback(async(R,q,z)=>R?y(R).then(()=>(c(q??`${t}`,z),Je(R,R))):Promise.resolve(Je("","Product id required")),[c,y]),$=E.useCallback(()=>{n.items.length>0&&m()},[m,n.items]),w=E.useCallback((R,q="BRA")=>g(R,q),[g]),N=E.useCallback(R=>{R&&b(R)},[b]),k=E.useCallback(async(R,q,z)=>{const U=n.items.findIndex(W=>W.id===R);return n.items[U]&&U>=0?A(q,U,z??!1):!1},[n.items,A]),B=E.useCallback(async(R,q)=>_(R,q).then(z=>{if(Array.isArray(z)){const U=z.find(K=>K.id===R);if(U&&(U==null?void 0:U.quantity)<q)return String(U.quantity)}return!1}),[_]);return s.jsx(Qa.Provider,{value:E.useMemo(()=>({...r,addCouponSeller:C,addToCart:P,addItemsToCart:S,cartStore:n,notifications:a,clearCart:$,addNotification:c,isOpen:n.isOpen,removeNotification:u,removeToCart:I,setIsOpen:n.setIsOpen,shipping:w,shippingUpdateOption:N,toggleGiftItemCart:k,updateItemQuantity:B}),[r,C,P,S,a,$,c,n,u,I,w,N,k,B]),children:e})},Be=()=>{const e=E.useContext(Qa);if(e===void 0)throw new Error("useCartContext must be used within a CartProvider");return e},Ya=E.createContext({}),go=({children:e,fetch:t})=>{const r=E.useRef(!0),[n,o]=E.useState(null),[i,a]=E.useState(!1);return E.useEffect(()=>{(async()=>{r.current=!0;try{const u=await t();if(!u.ok)throw new Error("Failed to fetch data");const l=await u.json();o(l.data),r.current=!1}catch{r.current=!0,a(!0)}})()},[t]),s.jsx(Ya.Provider,{value:E.useMemo(()=>({data:n,isLoading:r.current??!1,isError:i}),[n,i,r]),children:e})},yo=()=>{const e=E.useContext(Ya);if(e===void 0)throw new Error("useProductsContext must be used within a useRootContext");return e},Za=E.createContext({}),Ja=({children:e,sort:t,state:r,count:n,collectionId:o,CONSTANTS:i})=>{const a=E.useMemo(()=>{var c;return o?[{key:"productclusterids",value:o.toString()}]:(c=r.base)!=null&&c.length?r.base.slice(1).split("/").map((u,l)=>({key:`category-${l+1}`,value:u})):[]},[r.base,o]);return s.jsx(Za.Provider,{value:E.useMemo(()=>({state:{...r,facets:[...a,...r.facets??[]]},sort:t,count:n??i.ITEMS_PER_PAGE}),[a,n,t,r]),children:e})},_o=()=>{const e=E.useContext(Za);if(e===void 0)throw new Error("useSearchContext must be used within a SearchProvider");return e},ec={default_option:"score:desc"},Ul={nextPage:!1,previousPage:!1,startCursor:"0",endCursor:"0",count:0,total:0},Gl="Imagem do produto",Wl="Sair",Vl=e=>e.exit,Kl=({ICONS:e,storeConfig:t})=>[{icon:e.person,label:"Minha conta",href:`${t.secureSubdomain}/api/io/account#/profile`,needToBeAuth:!1,deviceShown:"both"},{icon:e.delivery_truck,label:"Meus pedidos",href:`${t.secureSubdomain}/api/io/account#/orders`,needToBeAuth:!1,deviceShown:"both"},{icon:e.favorite_false,label:t.wishlistConfig.label,href:t.wishlistConfig.path,needToBeAuth:!1,deviceShown:"mobile"},{icon:e.help,label:t.termsConfig.label,href:t.termsConfig.path,needToBeAuth:!1,deviceShown:"mobile"}],Xl=(e,t)=>{const r=(t??"").split("@")[0];return e?`Olá${r.length?", ":" "}${r}!`:"Olá!"},Ql=e=>"Seja bem vindo!",tc=E.createContext({}),Yl=({children:e,searchParams:t,selectedFacets:r})=>{const{data:n,...o}=yo(),{router:i}=je(),a=E.useCallback((p,d)=>{if(d){if(p.key.toLocaleLowerCase()==="price"){const m=d.getAll("facets");d.delete("facets"),m.forEach(h=>{const[y]=h.split("/");y!==p.key&&d.append("facets",h)})}d.set("page","1"),d.append("facets",`${p.key}/${p.value}`),i.push(`?${d.toString()}`)}},[i]),c=E.useCallback(()=>{const p=new URLSearchParams;p.set("sort",ec.default_option),p.set("page","1"),i.push(`?${p.toString()}`)},[i]),u=E.useCallback((p,d)=>{if(!d||!d.has&&!d.has("facets"))return;const m=d.getAll("facets");d.delete("facets"),d.set("page","1"),m.forEach(h=>{const[y,g]=h.split("/");(y!==p.key||g!==p.value)&&d.append("facets",h)}),i.push(`?${d.toString()}`)},[i]),l=E.useCallback(p=>{const d=new URLSearchParams(Te.convertSearchParams(t));for(const[,m]of d.entries()){const[h,y]=m.split("/");if(h===p.key&&y===p.value)return u(p,d)}return a(p,d)},[a,u,t]),f=E.useCallback(p=>{const d=new URLSearchParams(Te.convertSearchParams(t));d.set("sort",p.replace("_",":")),i.push(`?${d.toString()}`)},[i,t]);return s.jsx(tc.Provider,{value:E.useMemo(()=>({...o,breadcrumb:n&&"breadcrumb"in n?n==null?void 0:n.breadcrumb:[],deleteAllFacets:c,facets:n&&"facets"in n?n==null?void 0:n.facets:[],selectedFacets:r,onToggleFacet:l,onSort:f,searchParams:t}),[n,c,f,l,o,r,t]),children:e})},Zl=({children:e,searchParams:t,forceUpdate:r})=>{const{state:n}=_o();return s.jsx(go,{fetch:()=>fetch("/api/search/facets",{method:"POST",body:JSON.stringify({...n,forceUpdate:r}),priority:"low"}),children:s.jsx(Yl,{selectedFacets:(n==null?void 0:n.facets)??[],searchParams:t,children:e})})},Jl=()=>{const e=E.useContext(tc);if(e===void 0)throw new Error("useFacetsContext must be used within a FacetsProvider");return e},rc=E.createContext({}),ed=({children:e})=>{const{data:t,...r}=yo(),[n,o]=E.useState(0),{sendDataLayerEvent:i}=ge();return E.useEffect(()=>{if(t&&"pagination"in t&&t.products.length>0){i({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:t.products}}});const a=t.pagination.count;a&&Number.isInteger(a)&&o(a)}},[t,i,o]),s.jsx(rc.Provider,{value:E.useMemo(()=>({...r,products:t&&"products"in t?t==null?void 0:t.products:[],pagination:t&&"pagination"in t?t==null?void 0:t.pagination:Ul,total:n}),[t,r,n]),children:e})},td=({children:e,query:t,state:r,selectedFacets:n,forceUpdate:o})=>s.jsx(go,{fetch:()=>fetch("/api/search/product",{method:"POST",body:JSON.stringify({...r,query:t,forceUpdate:o,facets:n??[]})}),children:s.jsx(ed,{state:r,children:e})}),rd=()=>{const e=E.useContext(rc);if(e===void 0)throw new Error("useProductsContext must be used within a ProductsProvider");return e},nc=E.createContext({}),nd=({children:e,term:t})=>{const[r,n]=E.useState([]),[o,i]=E.useState(!1);return E.useEffect(()=>{if(!t){n([]);return}(async()=>{i(!0);try{const c=await fetch("/api/search/suggestedTerms",{method:"POST",body:JSON.stringify({query:t,locale:"pt-BR"})}),{data:u}=await c.json();n((u==null?void 0:u.searches)||[])}catch(c){console.error("Erro ao buscar sugestões:",c)}})()},[t]),s.jsx(nc.Provider,{value:E.useMemo(()=>({suggestedTerms:r,loading:o,setLoading:i}),[r,o]),children:e})},od=({children:e,...t})=>s.jsx(nd,{...t,children:e}),id=()=>{const e=E.useContext(nc);if(!e)throw new Error("useSuggestedTermsContext must be used within a SuggestedTermsProvider");return e},oc=E.createContext({searches:[],isLoading:!1,error:null}),sd=({children:e})=>{const[t,r]=E.useState([]),[n,o]=E.useState(!0),[i,a]=E.useState(null);return E.useEffect(()=>{(async()=>{try{o(!0);const u=await fetch("/api/search/topSearch");if(!u.ok)throw new Error(`Erro ao buscar os dados: ${u.status}`);const l=await u.json();r(l.data.searches||[])}catch(u){a(u instanceof Error?u.message:"Erro desconhecido")}finally{o(!1)}})()},[]),s.jsx(oc.Provider,{value:E.useMemo(()=>({searches:t,isLoading:n,error:i}),[t,n,i]),children:e})},ad=()=>{const e=E.useContext(oc);if(!e)throw new Error("useTopSearches must be used within a TopSearchesProvider");return e},ic=E.createContext({}),cd=({children:e,slug:t,searchParams:r,collectionId:n,itemsPerPage:o=24})=>{const{pathname:i}=je(),[a,c]=E.useState(!1),u=E.useMemo(()=>{const f=new URL(i,"http://localhost"),p=Array.isArray(r==null?void 0:r.facets)?r.facets:[(r==null?void 0:r.facets)??""],d=(r==null?void 0:r.page)??"1",m=(r==null?void 0:r.sort)??(n?"":ec.default_option);return f.searchParams.set("page",String(d)),f.searchParams.set("sort",String(m)),r!=null&&r.query?(f.searchParams.set("query",r.query),f):(f.searchParams.set("base",Array.isArray(t)?t.join("/"):t),f.searchParams.set("facets",p.join(",")),f)},[n,i,r,t]),l=E.useMemo(()=>{if(Array.isArray(r==null?void 0:r.facets))return Te.parseSearchState(u,r.facets);const f=r!=null&&r.facets?[r==null?void 0:r.facets]:[];return Te.parseSearchState(u,f)},[u,r]);return s.jsx(ic.Provider,{value:E.useMemo(()=>({openFilters:a,setOpenFilters:c}),[a,c]),children:s.jsx(Ja,{CONSTANTS:{ITEMS_PER_PAGE:o},state:E.useMemo(()=>({...l}),[l]),collectionId:n,children:e})})},ud=()=>{const e=E.useContext(ic);if(e===void 0)throw new Error("usePLPContext must be used within a PLPProvider");return e},Kn=(e,t)=>{if(e===t)return!0;if(e==null||t==null||typeof e!="object"||typeof t!="object")return!1;if(Array.isArray(e))return!Array.isArray(t)||e.length!==t.length?!1:e.every((o,i)=>Kn(o,t[i]));if(Array.isArray(t))return!1;const r=Object.keys(e),n=Object.keys(t);return r.length!==n.length?!1:r.every(o=>Object.prototype.hasOwnProperty.call(t,o)&&Kn(e[o],t[o]))},ld=(e,t,r="page")=>Object.keys(t).some(n=>n===r?!1:!Kn(t[n],e[n])),Do=async e=>{const t=await fetch("/api/search/product",{method:"POST",body:JSON.stringify(e),priority:"high"});if(!t.ok)throw new Error("[FAILED TO FETCH DATA]");const r=await t.json();return r==null?void 0:r.data},dd=()=>({node:{sku:"",gtin:"",name:"...",description:"",releaseDate:"",slug:"",video:null,categories:[],categoryId:"",categoriesIds:[],id:"skeleton",brand:{name:""},seo:{title:"",description:"",canonical:""},cluster:{generals:[],highlights:[]},availability:{status:!0},breadcrumbList:{itemListElement:[]},image:[{alternateName:"1",url:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR4nGNgYAAAAAMAAWgmWQ0AAAAASUVORK5CYII=",keywords:"1"},{alternateName:"10",url:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR4nGMAAQAABQABDQottgAAAABJRU5ErkJggg==",keywords:"10"}],offers:{lowPrice:1,highPrice:0,offers:[{availability:"true",listPrice:0,price:0,priceValidUntil:"",priceCurrency:"BRL",itemCondition:"",quantity:1,seller:{identifier:"1"}}],priceCurrency:"BRL"},isVariantOf:{productGroupID:"",hasVariant:[{additionalProperty:[{name:"Tamanho",value:"...",valueReference:"SPECIFICATION",propertyID:""}],name:"...",offers:{offers:[{availability:"https://schema.org/InStock",listPrice:0,price:0,quantity:1,seller:{identifier:"1"}}]},sku:"1",slug:"1",productId:"1"}],name:"",additionalProperty:[],skuVariants:null},installments:{count:2,value:1}}}),fd=(e,t,r,n=24)=>{const o=new Set,i=[];if(!Array.isArray(e)||e.length===0)return{taken:o,placedBanners:i};const a=t*n*r;for(const c of e){let u=Number(c.position_grid),l=!1;for(;u<a;){const f=u%r;if(f+c.columns>r){u+=r-f;continue}if(!Array.from({length:c.columns}).some((m,h)=>o.has(u+h))){for(let m=0;m<c.columns;m++)o.add(u+m);i.push(u),l=!0;break}u++}l||console.info(`[PLP INFINITE FAILED BANNER POSITION]: pos=${c.position_grid}, cols=${c.columns}`)}return{taken:o,placedBanners:i}},$o=(e,t,r,n=24)=>{const{placedBanners:o,taken:i}=fd(e??[],t,r),a=[];let c=0;try{for(;a.length<t*n;)i.has(c)||a.push(c),c++;return{banners:o,products:a}}catch(u){console.info(`[PLP INFINITE FAILED TO GEN POSITIONS]: page=${t}`,u)}return{banners:[],products:a}},rr=(e,t,r=24)=>Array.from({length:e},(n,o)=>{const i=o+1;return{loading:e===i,page:i,pagination:t!=null&&t.products.length&&e===i?t==null?void 0:t.pagination:sc(),products:t!=null&&t.products.length&&e===i?t==null?void 0:t.products:Array.from({length:r},()=>dd())}}),pd=(e,t)=>[...e,{loading:!1,page:t,pagination:sc(),products:[]}],sc=()=>({nextPage:!1,previousPage:!1,startCursor:"0",endCursor:"1",count:1,total:1}),md=50,hd=ot.create((e,t)=>{const r=a=>Math.min(a,md),n=async(a,c)=>{const u=r(a.page);try{const l=await Do({...a,page:u});o(u,f=>c?c(f,l):{...f,...l})}catch(l){console.error(`[PDC - SCROLL INFINITE FAILED TO FETCH PAGE ${u}]: ${l}`),o(u,f=>({...f,loading:!1}))}},o=(a,c)=>{e({load:!0,pages:t().pages.map(u=>u.page===a?c(u):u)})},i=async(a,c)=>{await n(a,(u,l)=>(typeof c=="function"&&c(l),{...u,...l,loading:!0}))};return{banners:[],load:!1,pages:[],total:0,positions:[],products:[],createPages:async(a,c,u,l)=>{var p,d,m;const f=r(Number(a==null?void 0:a.page));e({...c,pages:rr(f,void 0,l)});try{const h=await Do({...a,page:f});if(h){if(!h.products.length&&((p=h==null?void 0:h.pagination)==null?void 0:p.total)<f){i({...a,page:(d=h==null?void 0:h.pagination)==null?void 0:d.total},u),e({pages:rr((m=h==null?void 0:h.pagination)==null?void 0:m.total)});return}typeof u=="function"&&u(h),e({load:!0,pages:rr(f,h),total:Number(h.pagination.count)})}}catch(h){console.error(`[PDC - SCROLL INFINITE TO CREATE PAGES]: page ${f} ${h}`)}},addPage:(a,c,u)=>{const{pages:l}=t(),f=r(a==null?void 0:a.page);l.some(p=>p.page===f)||(e({...c,pages:pd(l,f)}),i(a,u))},updateProducts:(a,c)=>{const u=t().pages.find(l=>l.page===r(a==null?void 0:a.page));u!=null&&u.loading||i(a,c)}}}),ac=E.createContext({}),gd=({banners:e,children:t,itemsPerPage:r=24,searchParams:n})=>{const{router:o}=je(),{sendDataLayerEvent:i}=ge(),{isMobile:a}=Ae(),{state:c}=_o(),{addPage:u,createPages:l,updateProducts:f,...p}=hd(),d=a?8:16,m=a?2:4,h=E.useRef(!1),y=E.useRef(c),g=E.useCallback(C=>{C&&"pagination"in C&&i({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:C.products}}})},[i]),b=E.useCallback(C=>{if(C.pagination.nextPage===!0){const x=C.page+1,P=$o(e,x,m,r);u({...c,page:x},P,g)}},[u,e,g,m,r,c]),A=E.useCallback(C=>{C.loading===!1&&f({...c,page:C.page},g)},[g,f,c]),_=E.useCallback(C=>{const x=new URLSearchParams(n);C.page!==Number(x.get("page")??1)&&(x.set("page",String(C.page)),o.replace(`?${x.toString()}`,{scroll:!1}))},[o,n]);return E.useEffect(()=>{const C=!h.current,x=ld(y.current,c),P=$o(e,c.page,m);C?l(c,P,g,r):x&&(l(c,P,g,r),y.current=c),h.current=!0},[e,l,g,m,r,c]),s.jsx(ac.Provider,{value:E.useMemo(()=>({...p,addPage:u,addNewPage:b,createPages:l,gap:d,columns:m,updatePage:A,updateProducts:f,updateParamPage:_}),[u,b,l,d,m,p,A,f,_]),children:t})},yd=()=>{const e=E.useContext(ac);if(e===void 0)throw new Error("PLPInfiniteScrollContext must be used within a ScrollInfiniteProvider");return e};function cc(e){const r=decodeURIComponent(window.document.cookie).split(";");for(const n of r){const[o,i]=n.trim().split("=");if(o===e)return i}}function vo(e,t,r={}){const o={...{path:"/",expires:new Date(Date.now()+36e5)},...r};let i=`${encodeURIComponent(e)}=${encodeURIComponent(t??"")}`;for(const a in o)o[a]!==void 0&&(i+=`; ${a}`,a==="expires"?i+=`=${o[a].toUTCString()}`:typeof o[a]=="boolean"?i+=`; ${o[a]?"true":"false"}`:i+=`=${o[a]}`);window.document.cookie=i}const _d=()=>{const{sendDataLayerEvent:e}=ge(),{user:t}=bo(),{cartStore:r}=Be();return E.useEffect(()=>{if(!t)return;(async()=>{const{userId:o,email:i,firstName:a,lastName:c,phone:u,homePhone:l,postalCode:f,street:p,number:d,city:m,gender:h}=t,y=new TextEncoder().encode(o),g=await crypto.subtle.digest("SHA-256",y),A=Array.from(new Uint8Array(g)).map(_=>_.toString(16).padStart(2,"0")).join("");e({functionKey:"readyEvents",data:{readyData:{user_id:A,email:i,first_name:a,last_name:c,phone:u||l,zip:f,street:p,street_number:d,city:m,gender:h,orderform_id:r==null?void 0:r.id}}})})()},[t,r.id]),null},uc=E.createContext({amount:null,boxes:null,toExpire:null,loading:!0,logout:()=>null,getCurrentCredits:()=>({credits:0,cashback:0})}),vd=({children:e,AUTH_TOKEN_COOKIE:t})=>{const[r,n]=E.useState({amount:null,boxes:null,toExpire:null,loading:!0}),o=E.useCallback(async()=>{try{await fetch("/api/user",{priority:"low"}).then(c=>c.json()).then(c=>{const{userCredits:u,...l}=c;n({amount:u==null?void 0:u.amount,boxes:u==null?void 0:u.boxes,toExpire:u==null?void 0:u.toExpire,user:l,loading:!1})})}catch(c){console.error("my credits request",c),n({...r,loading:!1})}},[n]),i=E.useCallback(()=>{vo(t),o()},[o]),a=E.useCallback(()=>r.boxes?r.boxes.reduce((c,u)=>u.gift_card_box.refid==="C1643"?(c.cashback+=u.amount,c):(c.credits+=u.amount,c),{cashback:0,credits:0}):{cashback:0,credits:0},[r]);return E.useEffect(()=>{o()},[o]),s.jsxs(uc.Provider,{value:E.useMemo(()=>({...r,getCurrentCredits:a,logout:i}),[r,a,i]),children:[s.jsx(_d,{}),e]})},bo=()=>{const e=E.useContext(uc);if(e===void 0)throw new Error("useContext(SessionContext) must be used within a SessionProvider");return e},bd={contexts:{addToCart:{hook:Qe,provider:Xa},cart:{hook:Be,provider:zl},cms:{FlagsAndTags:{context:so,hook:ao,provider:Qu}},events:{hook:ge,provider:ul},global:{hook:Ae,provider:Sl,mediator:Oa},header:{hook:ve,provider:ql},menuMobile:{hook:gt,provider:Va},next:{hook:je,provider:Al},pdp:{provider:Yu,hook:Zu},plp:{provider:cd,hook:ud},plpInfinite:{provider:gd,hook:yd},pdpdata:{hook:fo,provider:ll},searchFacets:{hook:Jl,provider:Zl},searchProducts:{hook:rd,provider:td},searchRoot:{hook:yo,provider:go},searchSearch:{hook:_o,provider:Ja},searchSuggestedTerms:{hook:id,provider:od},searchTopSearchs:{hook:ad,provider:sd},session:{hook:bo,provider:vd},ui:{hook:pt,provider:Na}},hooks:{useBackPDC:Xs},stores:{cart:xl,header:Rl,pdp:Bl}},xd=e=>e.normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\s+/g,"-").toLowerCase().trim();function Cd(e,t=1e3){let r=!1;return(...n)=>{r||(e(...n),r=!0,setTimeout(()=>{r=!1},t))}}function Sd(e,t=1e3){let r;return(...n)=>{clearTimeout(r),r=setTimeout(()=>{e(...n)},t)}}const lc=(e,t)=>t.getTime()>e.getTime()?Math.abs(t.getTime()-e.getTime()):0,ut=(e,t)=>Math.floor(t==="days"?e/(1e3*60*60*24):t==="hours"?e%(1e3*60*60*24)/(1e3*60*60):t==="minutes"?e%(1e3*60*60)/(1e3*60):e%(1e3*60)/1e3),Ad=e=>{const t=Xu.decodeJwt(e??"");return{email:t.sub,userId:t.userId}},Ed=["name","email","phone","date","cpf","cep"],Bo={email:/\S+@\S+\.\S+/,name:new RegExp("^\\p{L}+( \\p{L}+)*$","u"),phone:/^\d{10,11}|\(\d{2}\)\s?\d{4,5}-\d{4}$/,date:/^\d{6,8}|^\d{2}\/\d{2}\/\d{2,4}$/,cep:/^\d{5}[-]?\d{3}$/,cpf:/^\d{11}|\d{3}\.\d{3}\.?\d{3,5}\-[\d]{2}$/},wd=({type:e,input:t,required:r=!1})=>{if(typeof t!="string"||!r&&t===""||!Bo[e])return!0;const n=t.trim();return Bo[e].test(n)},Rd=e=>{const t=/\/(\d+)-\d+-\d+\/(.+?)\./,r=typeof e=="string"?e.match(t):null;return r?r[2].replace(/-/g," "):Gl},jd=Object.freeze(Object.defineProperty({__proto__:null,FieldTypes:Ed,debounce:Sd,getAltTextFromUrl:Rd,getAuthenticatedUser:Ad,getCookie:cc,getDaysHoursMinutesSeconds:ut,getMilliSeconds:lc,removeAccentsAndReplaceSpaces:xd,setCookie:vo,throttle:Cd,validateInput:wd},Symbol.toStringTag,{value:"Module"})),Pd={cart:_l,events:cl,product:rl,utils:jd},xo={helpers:Pd},Ie={"add-to-cart--card":"_add-to-cart--card_4v41y_1","add-to-cart--card--content":"_add-to-cart--card--content_4v41y_7","add-to-cart--card--name":"_add-to-cart--card--name_4v41y_16","add-to-cart--card--price-quantity":"_add-to-cart--card--price-quantity_4v41y_46","add-to-cart--card--style-size":"_add-to-cart--card--style-size_4v41y_53","add-to-cart--content":"_add-to-cart--content_4v41y_71","add-to-cart--content--title":"_add-to-cart--content--title_4v41y_78","add-to-cart--footer":"_add-to-cart--footer_4v41y_102","add-to-cart--footer--total":"_add-to-cart--footer--total_4v41y_108","add-to-cart--items":"_add-to-cart--items_4v41y_148","add-to-cart--tooltip":"_add-to-cart--tooltip_4v41y_198","add-to-cart__modal":"_add-to-cart__modal_4v41y_211"},dc=({brand:e,className:t,name:r,...n})=>s.jsxs("div",{...n,className:v.helpers.classNameConcat(Ie["add-to-cart--card--name"],t),children:[s.jsx(v.Tag,{style:{textTransform:"uppercase"},size:"small",variant:"quaternary",title:e,children:e}),s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{alignContent:"flex-start",alignItems:"flex-start",children:s.jsx("p",{className:"typography-style-body-md",children:r})})})]});dc.displayName="AddToCart.Card.Name";const fc=({className:e,listPrice:t,price:r,quantity:n,productId:o,...i})=>{const a=Me(r/100),c=Me(t/100);return s.jsx("div",{...i,className:v.helpers.classNameConcat(Ie["add-to-cart--card--price-quantity"],e),children:s.jsx(v.ProductInfo.Root,{size:"small",layout:"vertical",children:s.jsx(v.ProductInfo.Wrapper,{size:"small",layout:"vertical",children:s.jsx(v.ProductInfo.ValuesWrapper,{children:r!==t?s.jsxs(s.Fragment,{children:[s.jsx(v.ProductInfo.Price,{label:"originalPrice",value:a,size:"small"},"price-list"),s.jsx(v.ProductInfo.Price,{label:"discountPrice",value:c,size:"small"},"price-low")]}):s.jsx(v.ProductInfo.Price,{label:"defaultPrice",value:c,size:"small"},"price-low")})})})})};fc.displayName="AddToCart.Card.PriceQuantity";const Id="_skeleton_12b79_1",Nd={skeleton:Id},Od=({style:e})=>s.jsx("div",{style:e,className:Nd.skeleton}),Td="_image_lypfr_1",Md={image:Td},kd=({alt:e,className:t,objectFit:r,...n})=>{const{nextimage:o}=je();return s.jsx(o,{quality:90,...n,alt:e??"",className:v.helpers.classNameConcat(Md.image,t),"data-object-fit":r??"cover"})},Ld=({videoRef:e,...t})=>s.jsx("video",{...t,ref:e,children:s.jsx("track",{kind:"captions"})}),$e={Image:kd,Video:Ld},pc=({className:e,productGroupID:t,size:r,texture:n,...o})=>{const{CONSTANTS:{TEXTURE_IMAGE:i,TOGGLE_STYLE_MODIFIER:a}}=Qe(),[c,u]=E.useState(n??"");return E.useEffect(()=>{c||fetch("/api/catalog/product/info",{method:"POST",priority:"low",body:JSON.stringify({ids:[t]})}).then(l=>l.json()).then(l=>{const f=l.data[0].items[0];if(f){const p=f.images.find(d=>i.includes(d.imageLabel));p!=null&&p.imageUrl?u(p.imageUrl):u(f.images[0].imageUrl)}}).catch(l=>{console.error(l)})},[c,t]),s.jsxs("div",{...o,className:v.helpers.classNameConcat(Ie["add-to-cart--card--style-size"],e),children:[s.jsx(v.ToggleStyle.Wrapper,{size:"x-small",style:a,children:s.jsx(v.ToggleStyle.Texture,{children:c?s.jsx($e.Image,{alt:"",src:c??"",width:164,height:164,style:a}):s.jsx(Od,{})})}),s.jsx(v.Utils.Divider,{direction:"vertical",size:"medium",style:{height:24}}),r&&s.jsxs(v.ToggleSize.Wrapper,{size:"small",title:"wrapper-texture",children:[s.jsx(v.ToggleSize.DisabledAdornment,{title:"disabled-adornment-texture"}),s.jsx(v.ToggleSize.Text,{children:r})]})]})};pc.displayName="AddToCart.Card.StyleSize";const{helpers:Dd}=xo,mc=({className:e,item:t,texture:r,...n})=>{const{itemOffered:{name:o,brand:i,skuName:a,isVariationOf:{productGroupID:c}},quantity:u,price:l,sellingPrice:f}=t,{CONSTANTS:{NAME_SPLIT_SYMBOL:p}}=Qe(),{size:d}=Dd.product.getColorAndSizeFromSkuName(a??o,p);return s.jsxs("div",{...n,className:v.helpers.classNameConcat(Ie["add-to-cart--card--content"],e),children:[s.jsx(dc,{brand:i.name,name:o}),s.jsx(fc,{price:l,listPrice:f,quantity:u,productId:t.id}),s.jsx(pc,{size:d,texture:r,productGroupID:c})]})};mc.displayName="AddToCart.Card.Content";const hc=({image:e,thumbnail:t=!1})=>s.jsx($e.Image,{alt:e.alternateName??"image","data-thumbnail":t,height:t?152:120,src:e.url,width:t?152:94});hc.displayName="AddToCart.Card";const gc=({className:e,item:t,texture:r,thumbnail:n,...o})=>{const{itemOffered:{image:[i]}}=t,a=ra(i.url,{width:200,height:300});return s.jsxs("div",{...o,className:v.helpers.classNameConcat(Ie["add-to-cart--card"],e),children:[s.jsx(hc,{image:{alternateName:i.alternateName||"Produto",url:a||""},thumbnail:n}),!n&&s.jsx(mc,{item:t,texture:r})]})};gc.displayName="AddToCart.Card";const yc=({className:e,children:t,title:r,...n})=>s.jsxs("div",{...n,className:v.helpers.classNameConcat(Ie["add-to-cart--content"],e),children:[s.jsx("div",{className:Ie["add-to-cart--content--title"],children:r&&s.jsx("h2",{children:r})}),t,s.jsx(Ve.Footer,{})]});yc.displayName="AddToCart.Layout.Content";const _c=({className:e,...t})=>{var m,h;const{isMobile:r,handleClose:n,CONSTANTS:{ADD_TO_CART:o}}=Qe(),{cartStore:{totalizers:i},setIsOpen:a}=Be(),c=(m=i.find(y=>y.id==="Discounts"))==null?void 0:m.value,u=((h=i.find(y=>y.id==="Items"))==null?void 0:h.value)??0,l=i.find(y=>y.id==="Shipping"),p=(u-Math.abs(c??0)+((l==null?void 0:l.value)??0))/100,d=Me(p??0);return s.jsxs("div",{...t,className:v.helpers.classNameConcat(Ie["add-to-cart--footer"],e),children:[s.jsxs("div",{className:Ie["add-to-cart--footer--total"],children:[s.jsx("span",{children:"Subtotal:"}),s.jsx("span",{children:d})]}),s.jsx(v.Button,{size:"medium",variant:"primary","data-close":!0,onClick:()=>a(!0),children:o.footer.bag}),r?s.jsx(v.Button,{"data-close":!0,size:"medium",variant:"tertiary",children:o.footer.keep_buying}):s.jsx(v.Button,{onClick:()=>n(),size:"medium",variant:"tertiary",children:o.footer.keep_buying})]})};_c.displayName="AddToCart.Layout.Footer";const vc=({children:e,className:t,thumbnail:r=!1,...n})=>{const{cartStore:{options:o}}=Be(),{recentlyAddedProducts:i}=pt(),a=i.length>3?4:i.length;return s.jsxs("div",{...n,className:Ie["add-to-cart--items"],"data-thumbnail":r,children:[Array.isArray(i)&&i.filter((c,u)=>u<a).map(c=>{var l;const u=(l=o==null?void 0:o.find(f=>f.id===c.itemOffered.isVariationOf.productGroupID))==null?void 0:l.texture;return s.jsx(Ve.Card,{item:c,thumbnail:r,texture:u},c.itemOffered.sku)}),e]})};vc.displayName="AddToCart.Layout.Items";const bc=({children:e,Z_INDEX_WAR:t})=>{const{isOpen:r,setIsOpen:n}=Qe(),{isMobile:o}=Ae();return s.jsxs(v.Modal.Root,{"data-modal":"add-to-cart--modal",className:Ie["add-to-cart__modal"],isMobile:o??!1,isOpen:r,setIsOpen:n,variant:"sideBottom",style:{zIndex:t.modal},children:[s.jsx(v.Modal.Header,{navigation:"top",children:s.jsx(v.Modal.Controls,{navigation:"top",isMobile:!0})}),s.jsx(v.Modal.Body,{children:e})]})};bc.displayName="AddToCart.Modal";const $d=({children:e})=>{const{count:t,handleClose:r,setIsOpen:n}=Qe(),o=E.useRef(t);return E.useEffect(()=>{t>o.current&&n(!0),t<o.current&&o.current>=1&&r(),o.current=t},[t,r,n]),s.jsx(s.Fragment,{children:e})},xc=({children:e,component:t,CONSTANTS:r,...n})=>{const{recentlyAddedProducts:o}=pt(),{isMobile:i}=Ae(),a=o.length>3?4:o.length;return s.jsx(Xa,{...n,count:a,isMobile:i,CONSTANTS:r,children:s.jsx($d,{children:i?s.jsxs(s.Fragment,{children:[s.jsx(Ve.Modal,{Z_INDEX_WAR:r.Z_INDEX_WAR,children:t}),e]}):s.jsx(Ve.Tooltip,{component:t,style:{width:350},Z_INDEX_WAR:r.Z_INDEX_WAR,children:e})})})};xc.displayName="AddToCart.Root";const Cc=({children:e,component:t,Z_INDEX_WAR:r,...n})=>{const{contentRef:o,left:i,isLeaving:a,target:c,isOpen:u,top:l}=Qe();return s.jsx(v.Tooltip.Root,{arrow:"top-right",component:s.jsx("div",{...n,ref:o,children:t}),id:"add-to-cart--tooltip",className:Ie["add-to-cart--tooltip"],style:{zIndex:r.modal},isLeaving:a,isOpen:u,left:i,size:"medium",position:"top",top:l,children:s.jsx("div",{className:Ie["add-to-cart--tooltip"],ref:c,children:e})})};Cc.displayName="AddToCart.Tooltip";const Ve={Card:gc,Content:yc,Footer:_c,Items:vc,Modal:bc,Root:xc,Tooltip:Cc},Co=({title:e,...t})=>{const{recentlyAddedProducts:r}=pt(),{isMobile:n}=Ae(),o=r.length>3?4:r.length,i=r.length>(o??1),a=r.length>1;return s.jsx(Ve.Root,{isMobile:n,count:r.length,component:s.jsx(Ve.Content,{title:e,children:s.jsx(Ve.Items,{thumbnail:a,children:i&&s.jsx(v.Badge.Count,{count:r.length-o,size:"medium",variant:"secondary"})})}),...t})};Co.displayName="AddToCart";const qo={"backtotop-btn":"_backtotop-btn_1shb6_1","card-modifier":"_card-modifier_1shb6_27"},Bd=({children:e,className:t,adornment:r,iconPosition:n,scrollToOptions:o,style:i,...a})=>{const c={top:(o==null?void 0:o.top)??0,left:(o==null?void 0:o.left)??0,behavior:(o==null?void 0:o.behavior)??"smooth"},l=n&&r?{flexDirection:{top:"column",bottom:"column-reverse",left:"row",right:"row-reverse"}[n]}:{},f=()=>{window&&window.document.body.scrollTo({...c})};return s.jsx(v.Card,{...a,shadow:!0,padding:"small",className:v.helpers.classNameConcat(qo["card-modifier"],t),style:{...i,padding:0},children:s.jsxs("button",{className:qo["backtotop-btn"],onClick:f,style:{...l},"data-orientation":n,children:[r,e]})})};var Sc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Vt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function qd(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,o.get?o:{enumerable:!0,get:function(){return e[n]}})}),r}var Xn={exports:{}},Re={};Re._=Re._interop_require_default=Hd;function Hd(e){return e&&e.__esModule?e:{default:e}}var Et={exports:{}},nr={},Ho;function Ac(){return Ho||(Ho=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(a,c){for(var u in c)Object.defineProperty(a,u,{enumerable:!0,get:c[u]})}t(e,{searchParamsToUrlQuery:function(){return r},urlQueryToSearchParams:function(){return o},assign:function(){return i}});function r(a){const c={};return a.forEach((u,l)=>{typeof c[l]>"u"?c[l]=u:Array.isArray(c[l])?c[l].push(u):c[l]=[c[l],u]}),c}function n(a){return typeof a=="string"||typeof a=="number"&&!isNaN(a)||typeof a=="boolean"?String(a):""}function o(a){const c=new URLSearchParams;return Object.entries(a).forEach(u=>{let[l,f]=u;Array.isArray(f)?f.forEach(p=>c.append(l,n(p))):c.set(l,n(f))}),c}function i(a){for(var c=arguments.length,u=new Array(c>1?c-1:0),l=1;l<c;l++)u[l-1]=arguments[l];return u.forEach(f=>{Array.from(f.keys()).forEach(p=>a.delete(p)),f.forEach((p,d)=>a.append(d,p))}),a}}(nr)),nr}var or={},nt={};function Ec(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,r=new WeakMap;return(Ec=function(n){return n?r:t})(e)}nt._=nt._interop_require_wildcard=Fd;function Fd(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var r=Ec(t);if(r&&r.has(e))return r.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(i!=="default"&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(n,i,a):n[i]=e[i]}return n.default=e,r&&r.set(e,n),n}var Fo;function wc(){return Fo||(Fo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(u,l){for(var f in l)Object.defineProperty(u,f,{enumerable:!0,get:l[f]})}t(e,{formatUrl:function(){return i},urlObjectKeys:function(){return a},formatWithValidation:function(){return c}});const n=nt._(Ac()),o=/https?|ftp|gopher|file/;function i(u){let{auth:l,hostname:f}=u,p=u.protocol||"",d=u.pathname||"",m=u.hash||"",h=u.query||"",y=!1;l=l?encodeURIComponent(l).replace(/%3A/i,":")+"@":"",u.host?y=l+u.host:f&&(y=l+(~f.indexOf(":")?"["+f+"]":f),u.port&&(y+=":"+u.port)),h&&typeof h=="object"&&(h=String(n.urlQueryToSearchParams(h)));let g=u.search||h&&"?"+h||"";return p&&!p.endsWith(":")&&(p+=":"),u.slashes||(!p||o.test(p))&&y!==!1?(y="//"+(y||""),d&&d[0]!=="/"&&(d="/"+d)):y||(y=""),m&&m[0]!=="#"&&(m="#"+m),g&&g[0]!=="?"&&(g="?"+g),d=d.replace(/[?#]/g,encodeURIComponent),g=g.replace("#","%23"),""+p+y+d+g+m}const a=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function c(u){return process.env.NODE_ENV==="development"&&u!==null&&typeof u=="object"&&Object.keys(u).forEach(l=>{a.includes(l)||console.warn("Unknown key passed via urlObject into url.format: "+l)}),i(u)}}(or)),or}var ir={},zo;function zd(){return zo||(zo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"omit",{enumerable:!0,get:function(){return t}});function t(r,n){const o={};return Object.keys(r).forEach(i=>{n.includes(i)||(o[i]=r[i])}),o}}(ir)),ir}var sr={},Uo;function Kt(){return Uo||(Uo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(C,x){for(var P in x)Object.defineProperty(C,P,{enumerable:!0,get:x[P]})}t(e,{WEB_VITALS:function(){return r},execOnce:function(){return n},isAbsoluteUrl:function(){return i},getLocationOrigin:function(){return a},getURL:function(){return c},getDisplayName:function(){return u},isResSent:function(){return l},normalizeRepeatedSlashes:function(){return f},loadGetInitialProps:function(){return p},SP:function(){return d},ST:function(){return m},DecodeError:function(){return h},NormalizeError:function(){return y},PageNotFoundError:function(){return g},MissingStaticPage:function(){return b},MiddlewareNotFoundError:function(){return A},stringifyError:function(){return _}});const r=["CLS","FCP","FID","INP","LCP","TTFB"];function n(C){let x=!1,P;return function(){for(var S=arguments.length,I=new Array(S),$=0;$<S;$++)I[$]=arguments[$];return x||(x=!0,P=C(...I)),P}}const o=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,i=C=>o.test(C);function a(){const{protocol:C,hostname:x,port:P}=window.location;return C+"//"+x+(P?":"+P:"")}function c(){const{href:C}=window.location,x=a();return C.substring(x.length)}function u(C){return typeof C=="string"?C:C.displayName||C.name||"Unknown"}function l(C){return C.finished||C.headersSent}function f(C){const x=C.split("?");return x[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(x[1]?"?"+x.slice(1).join("?"):"")}async function p(C,x){if(process.env.NODE_ENV!=="production"){var P;if((P=C.prototype)!=null&&P.getInitialProps){const $='"'+u(C)+'.getInitialProps()" is defined as an instance method - visit https://nextjs.org/docs/messages/get-initial-props-as-an-instance-method for more information.';throw new Error($)}}const S=x.res||x.ctx&&x.ctx.res;if(!C.getInitialProps)return x.ctx&&x.Component?{pageProps:await p(x.Component,x.ctx)}:{};const I=await C.getInitialProps(x);if(S&&l(S))return I;if(!I){const $='"'+u(C)+'.getInitialProps()" should resolve to an object. But found "'+I+'" instead.';throw new Error($)}return process.env.NODE_ENV!=="production"&&Object.keys(I).length===0&&!x.ctx&&console.warn(""+u(C)+" returned an empty object from `getInitialProps`. This de-optimizes and prevents automatic static optimization. https://nextjs.org/docs/messages/empty-object-getInitialProps"),I}const d=typeof performance<"u",m=d&&["mark","measure","getEntriesByName"].every(C=>typeof performance[C]=="function");class h extends Error{}class y extends Error{}class g extends Error{constructor(x){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message="Cannot find module for page: "+x}}class b extends Error{constructor(x,P){super(),this.message="Failed to load static file for page: "+x+" "+P}}class A extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function _(C){return JSON.stringify({message:C.message,stack:C.stack})}}(sr)),sr}var wt={exports:{}},ar={},Go;function Rc(){return Go||(Go=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"removeTrailingSlash",{enumerable:!0,get:function(){return t}});function t(r){return r.replace(/\/$/,"")||"/"}}(ar)),ar}var cr={},Wo;function So(){return Wo||(Wo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"parsePath",{enumerable:!0,get:function(){return t}});function t(r){const n=r.indexOf("#"),o=r.indexOf("?"),i=o>-1&&(n<0||o<n);return i||n>-1?{pathname:r.substring(0,i?o:n),query:i?r.substring(o,n>-1?n:void 0):"",hash:n>-1?r.slice(n):""}:{pathname:r,query:"",hash:""}}}(cr)),cr}var Vo;function Xt(){return Vo||(Vo=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"normalizePathTrailingSlash",{enumerable:!0,get:function(){return o}});const r=Rc(),n=So(),o=i=>{if(!i.startsWith("/")||process.env.__NEXT_MANUAL_TRAILING_SLASH)return i;const{pathname:a,query:c,hash:u}=(0,n.parsePath)(i);return process.env.__NEXT_TRAILING_SLASH?/\.[^/]+\/?$/.test(a)?""+(0,r.removeTrailingSlash)(a)+c+u:a.endsWith("/")?""+a+c+u:a+"/"+c+u:""+(0,r.removeTrailingSlash)(a)+c+u};(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(wt,wt.exports)),wt.exports}var ur={},Rt={exports:{}},lr={},Ko;function jc(){return Ko||(Ko=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"pathHasPrefix",{enumerable:!0,get:function(){return r}});const t=So();function r(n,o){if(typeof n!="string")return!1;const{pathname:i}=(0,t.parsePath)(n);return i===o||i.startsWith(o+"/")}}(lr)),lr}var Xo;function Ud(){return Xo||(Xo=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"hasBasePath",{enumerable:!0,get:function(){return o}});const r=jc(),n=process.env.__NEXT_ROUTER_BASEPATH||"";function o(i){return(0,r.pathHasPrefix)(i,n)}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Rt,Rt.exports)),Rt.exports}var Qo;function Pc(){return Qo||(Qo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isLocalURL",{enumerable:!0,get:function(){return n}});const t=Kt(),r=Ud();function n(o){if(!(0,t.isAbsoluteUrl)(o))return!0;try{const i=(0,t.getLocationOrigin)(),a=new URL(o,i);return a.origin===i&&(0,r.hasBasePath)(a.pathname)}catch{return!1}}}(ur)),ur}var dr={},fr={},Yo;function Gd(){return Yo||(Yo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getSortedRoutes",{enumerable:!0,get:function(){return r}});class t{insert(o){this._insert(o.split("/").filter(Boolean),[],!1)}smoosh(){return this._smoosh()}_smoosh(o){o===void 0&&(o="/");const i=[...this.children.keys()].sort();this.slugName!==null&&i.splice(i.indexOf("[]"),1),this.restSlugName!==null&&i.splice(i.indexOf("[...]"),1),this.optionalRestSlugName!==null&&i.splice(i.indexOf("[[...]]"),1);const a=i.map(c=>this.children.get(c)._smoosh(""+o+c+"/")).reduce((c,u)=>[...c,...u],[]);if(this.slugName!==null&&a.push(...this.children.get("[]")._smoosh(o+"["+this.slugName+"]/")),!this.placeholder){const c=o==="/"?"/":o.slice(0,-1);if(this.optionalRestSlugName!=null)throw new Error('You cannot define a route with the same specificity as a optional catch-all route ("'+c+'" and "'+c+"[[..."+this.optionalRestSlugName+']]").');a.unshift(c)}return this.restSlugName!==null&&a.push(...this.children.get("[...]")._smoosh(o+"[..."+this.restSlugName+"]/")),this.optionalRestSlugName!==null&&a.push(...this.children.get("[[...]]")._smoosh(o+"[[..."+this.optionalRestSlugName+"]]/")),a}_insert(o,i,a){if(o.length===0){this.placeholder=!1;return}if(a)throw new Error("Catch-all must be the last part of the URL.");let c=o[0];if(c.startsWith("[")&&c.endsWith("]")){let f=function(p,d){if(p!==null&&p!==d)throw new Error("You cannot use different slug names for the same dynamic path ('"+p+"' !== '"+d+"').");i.forEach(m=>{if(m===d)throw new Error('You cannot have the same slug name "'+d+'" repeat within a single dynamic path');if(m.replace(/\W/g,"")===c.replace(/\W/g,""))throw new Error('You cannot have the slug names "'+m+'" and "'+d+'" differ only by non-word symbols within a single dynamic path')}),i.push(d)},u=c.slice(1,-1),l=!1;if(u.startsWith("[")&&u.endsWith("]")&&(u=u.slice(1,-1),l=!0),u.startsWith("...")&&(u=u.substring(3),a=!0),u.startsWith("[")||u.endsWith("]"))throw new Error("Segment names may not start or end with extra brackets ('"+u+"').");if(u.startsWith("."))throw new Error("Segment names may not start with erroneous periods ('"+u+"').");if(a)if(l){if(this.restSlugName!=null)throw new Error('You cannot use both an required and optional catch-all route at the same level ("[...'+this.restSlugName+']" and "'+o[0]+'" ).');f(this.optionalRestSlugName,u),this.optionalRestSlugName=u,c="[[...]]"}else{if(this.optionalRestSlugName!=null)throw new Error('You cannot use both an optional and required catch-all route at the same level ("[[...'+this.optionalRestSlugName+']]" and "'+o[0]+'").');f(this.restSlugName,u),this.restSlugName=u,c="[...]"}else{if(l)throw new Error('Optional route parameters are not yet supported ("'+o[0]+'").');f(this.slugName,u),this.slugName=u,c="[]"}}this.children.has(c)||this.children.set(c,new t),this.children.get(c)._insert(o.slice(1),i,a)}constructor(){this.placeholder=!0,this.children=new Map,this.slugName=null,this.restSlugName=null,this.optionalRestSlugName=null}}function r(n){const o=new t;return n.forEach(i=>o.insert(i)),o.smoosh()}}(fr)),fr}var pr={},Zo;function Wd(){return Zo||(Zo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isDynamicRoute",{enumerable:!0,get:function(){return r}});const t=/\/\[[^/]+?\](?=\/|$)/;function r(n){return t.test(n)}}(pr)),pr}var Jo;function Vd(){return Jo||(Jo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(o,i){for(var a in i)Object.defineProperty(o,a,{enumerable:!0,get:i[a]})}t(e,{getSortedRoutes:function(){return r.getSortedRoutes},isDynamicRoute:function(){return n.isDynamicRoute}});const r=Gd(),n=Wd()}(dr)),dr}var mr={},hr={},ei;function Kd(){return ei||(ei=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getRouteMatcher",{enumerable:!0,get:function(){return r}});const t=Kt();function r(n){let{re:o,groups:i}=n;return a=>{const c=o.exec(a);if(!c)return!1;const u=f=>{try{return decodeURIComponent(f)}catch{throw new t.DecodeError("failed to decode param")}},l={};return Object.keys(i).forEach(f=>{const p=i[f],d=c[p.pos];d!==void 0&&(l[f]=~d.indexOf("/")?d.split("/").map(m=>u(m)):p.repeat?[u(d)]:u(d))}),l}}}(hr)),hr}var gr={},yr={},_r={},vr={},ti;function Xd(){return ti||(ti=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"ensureLeadingSlash",{enumerable:!0,get:function(){return t}});function t(r){return r.startsWith("/")?r:"/"+r}}(vr)),vr}var br={},ri;function Qd(){return ri||(ri=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isGroupSegment",{enumerable:!0,get:function(){return t}});function t(r){return r[0]==="("&&r.endsWith(")")}}(br)),br}var ni;function Yd(){return ni||(ni=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(a,c){for(var u in c)Object.defineProperty(a,u,{enumerable:!0,get:c[u]})}t(e,{normalizeAppPath:function(){return o},normalizeRscPath:function(){return i}});const r=Xd(),n=Qd();function o(a){return(0,r.ensureLeadingSlash)(a.split("/").reduce((c,u,l,f)=>!u||(0,n.isGroupSegment)(u)||u[0]==="@"||(u==="page"||u==="route")&&l===f.length-1?c:c+"/"+u,""))}function i(a,c){return c?a.replace(/\.rsc($|\?)/,"$1"):a}}(_r)),_r}var oi;function Zd(){return oi||(oi=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(a,c){for(var u in c)Object.defineProperty(a,u,{enumerable:!0,get:c[u]})}t(e,{INTERCEPTION_ROUTE_MARKERS:function(){return n},isInterceptionRouteAppPath:function(){return o},extractInterceptionRouteInformation:function(){return i}});const r=Yd(),n=["(..)(..)","(.)","(..)","(...)"];function o(a){return a.split("/").find(c=>n.find(u=>c.startsWith(u)))!==void 0}function i(a){let c,u,l;for(const f of a.split("/"))if(u=n.find(p=>f.startsWith(p)),u){[c,l]=a.split(u,2);break}if(!c||!u||!l)throw new Error(`Invalid interception route: ${a}. Must be in the format /<intercepting route>/(..|...|..)(..)/<intercepted route>`);switch(c=(0,r.normalizeAppPath)(c),u){case"(.)":c==="/"?l=`/${l}`:l=c+"/"+l;break;case"(..)":if(c==="/")throw new Error(`Invalid interception route: ${a}. Cannot use (..) marker at the root level, use (.) instead.`);l=c.split("/").slice(0,-1).concat(l).join("/");break;case"(...)":l="/"+l;break;case"(..)(..)":const f=c.split("/");if(f.length<=2)throw new Error(`Invalid interception route: ${a}. Cannot use (..)(..) marker at the root level or one level up.`);l=f.slice(0,-2).concat(l).join("/");break;default:throw new Error("Invariant: unexpected marker")}return{interceptingRoute:c,interceptedRoute:l}}}(yr)),yr}var xr={},ii;function Jd(){return ii||(ii=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"escapeStringRegexp",{enumerable:!0,get:function(){return n}});const t=/[|\\{}()[\]^$+*?.-]/,r=/[|\\{}()[\]^$+*?.-]/g;function n(o){return t.test(o)?o.replace(r,"\\$&"):o}}(xr)),xr}var si;function ef(){return si||(si=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(y,g){for(var b in g)Object.defineProperty(y,b,{enumerable:!0,get:g[b]})}t(e,{getRouteRegex:function(){return l},getNamedRouteRegex:function(){return m},getNamedMiddlewareRegex:function(){return h}});const r=Zd(),n=Jd(),o=Rc(),i="nxtP",a="nxtI";function c(y){const g=y.startsWith("[")&&y.endsWith("]");g&&(y=y.slice(1,-1));const b=y.startsWith("...");return b&&(y=y.slice(3)),{key:y,repeat:b,optional:g}}function u(y){const g=(0,o.removeTrailingSlash)(y).slice(1).split("/"),b={};let A=1;return{parameterizedRoute:g.map(_=>{const C=r.INTERCEPTION_ROUTE_MARKERS.find(P=>_.startsWith(P)),x=_.match(/\[((?:\[.*\])|.+)\]/);if(C&&x){const{key:P,optional:S,repeat:I}=c(x[1]);return b[P]={pos:A++,repeat:I,optional:S},"/"+(0,n.escapeStringRegexp)(C)+"([^/]+?)"}else if(x){const{key:P,repeat:S,optional:I}=c(x[1]);return b[P]={pos:A++,repeat:S,optional:I},S?I?"(?:/(.+?))?":"/(.+?)":"/([^/]+?)"}else return"/"+(0,n.escapeStringRegexp)(_)}).join(""),groups:b}}function l(y){const{parameterizedRoute:g,groups:b}=u(y);return{re:new RegExp("^"+g+"(?:/)?$"),groups:b}}function f(){let y=0;return()=>{let g="",b=++y;for(;b>0;)g+=String.fromCharCode(97+(b-1)%26),b=Math.floor((b-1)/26);return g}}function p(y){let{getSafeRouteKey:g,segment:b,routeKeys:A,keyPrefix:_}=y;const{key:C,optional:x,repeat:P}=c(b);let S=C.replace(/\W/g,"");_&&(S=""+_+S);let I=!1;return(S.length===0||S.length>30)&&(I=!0),isNaN(parseInt(S.slice(0,1)))||(I=!0),I&&(S=g()),_?A[S]=""+_+C:A[S]=""+C,P?x?"(?:/(?<"+S+">.+?))?":"/(?<"+S+">.+?)":"/(?<"+S+">[^/]+?)"}function d(y,g){const b=(0,o.removeTrailingSlash)(y).slice(1).split("/"),A=f(),_={};return{namedParameterizedRoute:b.map(C=>{const x=r.INTERCEPTION_ROUTE_MARKERS.some(S=>C.startsWith(S)),P=C.match(/\[((?:\[.*\])|.+)\]/);return x&&P?p({getSafeRouteKey:A,segment:P[1],routeKeys:_,keyPrefix:g?a:void 0}):P?p({getSafeRouteKey:A,segment:P[1],routeKeys:_,keyPrefix:g?i:void 0}):"/"+(0,n.escapeStringRegexp)(C)}).join(""),routeKeys:_}}function m(y,g){const b=d(y,g);return{...l(y),namedRegex:"^"+b.namedParameterizedRoute+"(?:/)?$",routeKeys:b.routeKeys}}function h(y,g){const{parameterizedRoute:b}=u(y),{catchAll:A=!0}=g;if(b==="/")return{namedRegex:"^/"+(A?".*":"")+"$"};const{namedParameterizedRoute:_}=d(y,!1);let C=A?"(?:(/.*)?)":"";return{namedRegex:"^"+_+C+"$"}}}(gr)),gr}var ai;function tf(){return ai||(ai=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"interpolateAs",{enumerable:!0,get:function(){return n}});const t=Kd(),r=ef();function n(o,i,a){let c="";const u=(0,r.getRouteRegex)(o),l=u.groups,f=(i!==o?(0,t.getRouteMatcher)(u)(i):"")||a;c=o;const p=Object.keys(l);return p.every(d=>{let m=f[d]||"";const{repeat:h,optional:y}=l[d];let g="["+(h?"...":"")+d+"]";return y&&(g=(m?"":"/")+"["+g+"]"),h&&!Array.isArray(m)&&(m=[m]),(y||d in f)&&(c=c.replace(g,h?m.map(b=>encodeURIComponent(b)).join("/"):encodeURIComponent(m))||"/")})||(c=""),{params:p,result:c}}}(mr)),mr}var ci;function rf(){return ci||(ci=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"resolveHref",{enumerable:!0,get:function(){return f}});const r=Ac(),n=wc(),o=zd(),i=Kt(),a=Xt(),c=Pc(),u=Vd(),l=tf();function f(p,d,m){let h,y=typeof d=="string"?d:(0,n.formatWithValidation)(d);const g=y.match(/^[a-zA-Z]{1,}:\/\//),b=g?y.slice(g[0].length):y;if((b.split("?")[0]||"").match(/(\/\/|\\)/)){console.error("Invalid href '"+y+"' passed to next/router in page: '"+p.pathname+"'. Repeated forward-slashes (//) or backslashes \\ are not valid in the href.");const _=(0,i.normalizeRepeatedSlashes)(b);y=(g?g[0]:"")+_}if(!(0,c.isLocalURL)(y))return m?[y]:y;try{h=new URL(y.startsWith("#")?p.asPath:p.pathname,"http://n")}catch{h=new URL("/","http://n")}try{const _=new URL(y,h);_.pathname=(0,a.normalizePathTrailingSlash)(_.pathname);let C="";if((0,u.isDynamicRoute)(_.pathname)&&_.searchParams&&m){const P=(0,r.searchParamsToUrlQuery)(_.searchParams),{result:S,params:I}=(0,l.interpolateAs)(_.pathname,_.pathname,P);S&&(C=(0,n.formatWithValidation)({pathname:S,hash:_.hash,query:(0,o.omit)(P,I)}))}const x=_.origin===h.origin?_.href.slice(_.origin.length):_.href;return m?[x,C||x]:x}catch{return m?[y]:y}}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Et,Et.exports)),Et.exports}var jt={exports:{}},Cr={},Sr={},ui;function Ic(){return ui||(ui=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"addPathPrefix",{enumerable:!0,get:function(){return r}});const t=So();function r(n,o){if(!n.startsWith("/")||!o)return n;const{pathname:i,query:a,hash:c}=(0,t.parsePath)(n);return""+o+i+a+c}}(Sr)),Sr}var li;function nf(){return li||(li=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"addLocale",{enumerable:!0,get:function(){return n}});const t=Ic(),r=jc();function n(o,i,a,c){if(!i||i===a)return o;const u=o.toLowerCase();return!c&&((0,r.pathHasPrefix)(u,"/api")||(0,r.pathHasPrefix)(u,"/"+i.toLowerCase()))?o:(0,t.addPathPrefix)(o,"/"+i)}}(Cr)),Cr}var di;function of(){return di||(di=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"addLocale",{enumerable:!0,get:function(){return n}});const r=Xt(),n=function(o){for(var i=arguments.length,a=new Array(i>1?i-1:0),c=1;c<i;c++)a[c-1]=arguments[c];return process.env.__NEXT_I18N_SUPPORT?(0,r.normalizePathTrailingSlash)(nf().addLocale(o,...a)):o};(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(jt,jt.exports)),jt.exports}var Ar={},fi;function Nc(){return fi||(fi=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"RouterContext",{enumerable:!0,get:function(){return n}});const n=Re._(E).default.createContext(null);process.env.NODE_ENV!=="production"&&(n.displayName="RouterContext")}(Ar)),Ar}var Er={},pi;function sf(){return pi||(pi=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0});function t(l,f){for(var p in f)Object.defineProperty(l,p,{enumerable:!0,get:f[p]})}t(e,{CacheStates:function(){return o},AppRouterContext:function(){return i},LayoutRouterContext:function(){return a},GlobalLayoutRouterContext:function(){return c},TemplateContext:function(){return u}});const n=Re._(E);var o;(function(l){l.LAZY_INITIALIZED="LAZYINITIALIZED",l.DATA_FETCH="DATAFETCH",l.READY="READY"})(o||(o={}));const i=n.default.createContext(null),a=n.default.createContext(null),c=n.default.createContext(null),u=n.default.createContext(null);process.env.NODE_ENV!=="production"&&(i.displayName="AppRouterContext",a.displayName="LayoutRouterContext",c.displayName="GlobalLayoutRouterContext",u.displayName="TemplateContext")}(Er)),Er}var Pt={exports:{}},It={exports:{}},mi;function Oc(){return mi||(mi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(i,a){for(var c in a)Object.defineProperty(i,c,{enumerable:!0,get:a[c]})}r(t,{requestIdleCallback:function(){return n},cancelIdleCallback:function(){return o}});const n=typeof self<"u"&&self.requestIdleCallback&&self.requestIdleCallback.bind(window)||function(i){let a=Date.now();return self.setTimeout(function(){i({didTimeout:!1,timeRemaining:function(){return Math.max(0,50-(Date.now()-a))}})},1)},o=typeof self<"u"&&self.cancelIdleCallback&&self.cancelIdleCallback.bind(window)||function(i){return clearTimeout(i)};(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(It,It.exports)),It.exports}var hi;function af(){return hi||(hi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useIntersection",{enumerable:!0,get:function(){return l}});const r=E,n=Oc(),o=typeof IntersectionObserver=="function",i=new Map,a=[];function c(f){const p={root:f.root||null,margin:f.rootMargin||""},d=a.find(g=>g.root===p.root&&g.margin===p.margin);let m;if(d&&(m=i.get(d),m))return m;const h=new Map,y=new IntersectionObserver(g=>{g.forEach(b=>{const A=h.get(b.target),_=b.isIntersecting||b.intersectionRatio>0;A&&_&&A(_)})},f);return m={id:p,observer:y,elements:h},a.push(p),i.set(p,m),m}function u(f,p,d){const{id:m,observer:h,elements:y}=c(d);return y.set(f,p),h.observe(f),function(){if(y.delete(f),h.unobserve(f),y.size===0){h.disconnect(),i.delete(m);const b=a.findIndex(A=>A.root===m.root&&A.margin===m.margin);b>-1&&a.splice(b,1)}}}function l(f){let{rootRef:p,rootMargin:d,disabled:m}=f;const h=m||!o,[y,g]=(0,r.useState)(!1),b=(0,r.useRef)(null),A=(0,r.useCallback)(C=>{b.current=C},[]);(0,r.useEffect)(()=>{if(o){if(h||y)return;const C=b.current;if(C&&C.tagName)return u(C,P=>P&&g(P),{root:p==null?void 0:p.current,rootMargin:d})}else if(!y){const C=(0,n.requestIdleCallback)(()=>g(!0));return()=>(0,n.cancelIdleCallback)(C)}},[h,d,p,y,b.current]);const _=(0,r.useCallback)(()=>{g(!1)},[]);return[A,y,_]}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Pt,Pt.exports)),Pt.exports}var Nt={exports:{}},Ot={exports:{}},wr={},gi;function cf(){return gi||(gi=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"normalizeLocalePath",{enumerable:!0,get:function(){return t}});function t(r,n){let o;const i=r.split("/");return(n||[]).some(a=>i[1]&&i[1].toLowerCase()===a.toLowerCase()?(o=a,i.splice(1,1),r=i.join("/")||"/",!0):!1),{pathname:r,detectedLocale:o}}}(wr)),wr}var yi;function uf(){return yi||(yi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"normalizeLocalePath",{enumerable:!0,get:function(){return r}});const r=(n,o)=>process.env.__NEXT_I18N_SUPPORT?cf().normalizeLocalePath(n,o):{pathname:n,detectedLocale:void 0};(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Ot,Ot.exports)),Ot.exports}var Tt={exports:{}},Rr={},_i;function lf(){return _i||(_i=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"detectDomainLocale",{enumerable:!0,get:function(){return t}});function t(r,n,o){if(r){o&&(o=o.toLowerCase());for(const c of r){var i,a;const u=(i=c.domain)==null?void 0:i.split(":")[0].toLowerCase();if(n===u||o===c.defaultLocale.toLowerCase()||(a=c.locales)!=null&&a.some(l=>l.toLowerCase()===o))return c}}}}(Rr)),Rr}var vi;function df(){return vi||(vi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"detectDomainLocale",{enumerable:!0,get:function(){return r}});const r=function(){for(var n=arguments.length,o=new Array(n),i=0;i<n;i++)o[i]=arguments[i];if(process.env.__NEXT_I18N_SUPPORT)return lf().detectDomainLocale(...o)};(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Tt,Tt.exports)),Tt.exports}var bi;function ff(){return bi||(bi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getDomainLocale",{enumerable:!0,get:function(){return o}});const r=Xt(),n=process.env.__NEXT_ROUTER_BASEPATH||"";function o(i,a,c,u){if(process.env.__NEXT_I18N_SUPPORT){const l=uf().normalizeLocalePath,f=df().detectDomainLocale,p=a||l(i,c).detectedLocale,d=f(u,void 0,p);if(d){const m="http"+(d.http?"":"s")+"://",h=p===d.defaultLocale?"":"/"+p;return""+m+d.domain+(0,r.normalizePathTrailingSlash)(""+n+h+i)}return!1}else return!1}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Nt,Nt.exports)),Nt.exports}var Mt={exports:{}},xi;function pf(){return xi||(xi=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"addBasePath",{enumerable:!0,get:function(){return i}});const r=Ic(),n=Xt(),o=process.env.__NEXT_ROUTER_BASEPATH||"";function i(a,c){return(0,n.normalizePathTrailingSlash)(process.env.__NEXT_MANUAL_CLIENT_BASE_PATH&&!c?a:(0,r.addPathPrefix)(a,o))}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Mt,Mt.exports)),Mt.exports}var kt={exports:{}},Ci;function mf(){return Ci||(Ci=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(p,d){for(var m in d)Object.defineProperty(p,m,{enumerable:!0,get:d[m]})}r(t,{PrefetchKind:function(){return f},ACTION_REFRESH:function(){return n},ACTION_NAVIGATE:function(){return o},ACTION_RESTORE:function(){return i},ACTION_SERVER_PATCH:function(){return a},ACTION_PREFETCH:function(){return c},ACTION_FAST_REFRESH:function(){return u},ACTION_SERVER_ACTION:function(){return l}});const n="refresh",o="navigate",i="restore",a="server-patch",c="prefetch",u="fast-refresh",l="server-action";var f;(function(p){p.AUTO="auto",p.FULL="full",p.TEMPORARY="temporary"})(f||(f={})),(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(kt,kt.exports)),kt.exports}(function(e,t){"use client";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return x}});const n=Re._(E),o=rf(),i=Pc(),a=wc(),c=Kt(),u=of(),l=Nc(),f=sf(),p=af(),d=ff(),m=pf(),h=mf(),y=new Set;function g(P,S,I,$,w,N){if(typeof window>"u"||!N&&!(0,i.isLocalURL)(S))return;if(!$.bypassPrefetchedCheck){const B=typeof $.locale<"u"?$.locale:"locale"in P?P.locale:void 0,R=S+"%"+I+"%"+B;if(y.has(R))return;y.add(R)}const k=N?P.prefetch(S,w):P.prefetch(S,I,$);Promise.resolve(k).catch(B=>{if(process.env.NODE_ENV!=="production")throw B})}function b(P){const I=P.currentTarget.getAttribute("target");return I&&I!=="_self"||P.metaKey||P.ctrlKey||P.shiftKey||P.altKey||P.nativeEvent&&P.nativeEvent.which===2}function A(P,S,I,$,w,N,k,B,R,q){const{nodeName:z}=P.currentTarget;if(z.toUpperCase()==="A"&&(b(P)||!R&&!(0,i.isLocalURL)(I)))return;P.preventDefault();const K=()=>{const W=k??!0;"beforePopState"in S?S[w?"replace":"push"](I,$,{shallow:N,locale:B,scroll:W}):S[w?"replace":"push"]($||I,{forceOptimisticNavigation:!q,scroll:W})};R?n.default.startTransition(K):K()}function _(P){return typeof P=="string"?P:(0,a.formatUrl)(P)}const x=n.default.forwardRef(function(S,I){let $;const{href:w,as:N,children:k,prefetch:B=null,passHref:R,replace:q,shallow:z,scroll:U,locale:K,onClick:W,onMouseEnter:F,onTouchStart:ne,legacyBehavior:j=!1,...T}=S;$=k,j&&(typeof $=="string"||typeof $=="number")&&($=n.default.createElement("a",null,$));const D=n.default.useContext(l.RouterContext),X=n.default.useContext(f.AppRouterContext),te=D??X,Z=!D,M=B!==!1,J=B===null?h.PrefetchKind.AUTO:h.PrefetchKind.FULL;if(process.env.NODE_ENV!=="production"){let ie=function(oe){return new Error("Failed prop type: The prop `"+oe.key+"` expects a "+oe.expected+" in `<Link>`, but got `"+oe.actual+"` instead."+(typeof window<"u"?`
2
- Open your browser's console to view the Component stack trace.`:""))};Object.keys({href:!0}).forEach(oe=>{if(oe==="href"&&(S[oe]==null||typeof S[oe]!="string"&&typeof S[oe]!="object"))throw ie({key:oe,expected:"`string` or `object`",actual:S[oe]===null?"null":typeof S[oe]})}),Object.keys({as:!0,replace:!0,scroll:!0,shallow:!0,passHref:!0,prefetch:!0,locale:!0,onClick:!0,onMouseEnter:!0,onTouchStart:!0,legacyBehavior:!0}).forEach(oe=>{const V=typeof S[oe];if(oe==="as"){if(S[oe]&&V!=="string"&&V!=="object")throw ie({key:oe,expected:"`string` or `object`",actual:V})}else if(oe==="locale"){if(S[oe]&&V!=="string")throw ie({key:oe,expected:"`string`",actual:V})}else if(oe==="onClick"||oe==="onMouseEnter"||oe==="onTouchStart"){if(S[oe]&&V!=="function")throw ie({key:oe,expected:"`function`",actual:V})}else if((oe==="replace"||oe==="scroll"||oe==="shallow"||oe==="passHref"||oe==="prefetch"||oe==="legacyBehavior")&&S[oe]!=null&&V!=="boolean")throw ie({key:oe,expected:"`boolean`",actual:V})});const Q=n.default.useRef(!1);S.prefetch&&!Q.current&&!Z&&(Q.current=!0,console.warn("Next.js auto-prefetches automatically based on viewport. The prefetch attribute is no longer needed. More: https://nextjs.org/docs/messages/prefetch-true-deprecated"))}if(process.env.NODE_ENV!=="production"&&Z&&!N){let ie;if(typeof w=="string"?ie=w:typeof w=="object"&&typeof w.pathname=="string"&&(ie=w.pathname),ie&&ie.split("/").some(G=>G.startsWith("[")&&G.endsWith("]")))throw new Error("Dynamic href `"+ie+"` found in <Link> while using the `/app` router, this is not supported. Read more: https://nextjs.org/docs/messages/app-dir-dynamic-href")}const{href:Y,as:ee}=n.default.useMemo(()=>{if(!D){const G=_(w);return{href:G,as:N?_(N):G}}const[ie,me]=(0,o.resolveHref)(D,w,!0);return{href:ie,as:N?(0,o.resolveHref)(D,N):me||ie}},[D,w,N]),L=n.default.useRef(Y),O=n.default.useRef(ee);let re;if(j)if(process.env.NODE_ENV==="development"){W&&console.warn('"onClick" was passed to <Link> with `href` of `'+w+'` but "legacyBehavior" was set. The legacy behavior requires onClick be set on the child of next/link'),F&&console.warn('"onMouseEnter" was passed to <Link> with `href` of `'+w+'` but "legacyBehavior" was set. The legacy behavior requires onMouseEnter be set on the child of next/link');try{re=n.default.Children.only($)}catch{throw $?new Error("Multiple children were passed to <Link> with `href` of `"+w+"` but only one child is supported https://nextjs.org/docs/messages/link-multiple-children"+(typeof window<"u"?`
3
- Open your browser's console to view the Component stack trace.`:"")):new Error("No children were passed to <Link> with `href` of `"+w+"` but one child is required https://nextjs.org/docs/messages/link-no-children")}}else re=n.default.Children.only($);else if(process.env.NODE_ENV==="development"&&($==null?void 0:$.type)==="a")throw new Error(`Invalid <Link> with <a> child. Please remove <a> or use <Link legacyBehavior>.
4
- Learn more: https://nextjs.org/docs/messages/invalid-new-link-with-extra-anchor`);const se=j?re&&typeof re=="object"&&re.ref:I,[ce,ue,ae]=(0,p.useIntersection)({rootMargin:"200px"}),H=n.default.useCallback(ie=>{(O.current!==ee||L.current!==Y)&&(ae(),O.current=ee,L.current=Y),ce(ie),se&&(typeof se=="function"?se(ie):typeof se=="object"&&(se.current=ie))},[ee,se,Y,ae,ce]);n.default.useEffect(()=>{process.env.NODE_ENV==="production"&&te&&(!ue||!M||g(te,Y,ee,{locale:K},{kind:J},Z))},[ee,Y,ue,K,M,D==null?void 0:D.locale,te,Z,J]);const he={ref:H,onClick(ie){if(process.env.NODE_ENV!=="production"&&!ie)throw new Error('Component rendered inside next/link has to pass click event to "onClick" prop.');!j&&typeof W=="function"&&W(ie),j&&re.props&&typeof re.props.onClick=="function"&&re.props.onClick(ie),te&&(ie.defaultPrevented||A(ie,te,Y,ee,q,z,U,K,Z,M))},onMouseEnter(ie){!j&&typeof F=="function"&&F(ie),j&&re.props&&typeof re.props.onMouseEnter=="function"&&re.props.onMouseEnter(ie),te&&((!M||process.env.NODE_ENV==="development")&&Z||g(te,Y,ee,{locale:K,priority:!0,bypassPrefetchedCheck:!0},{kind:J},Z))},onTouchStart(ie){!j&&typeof ne=="function"&&ne(ie),j&&re.props&&typeof re.props.onTouchStart=="function"&&re.props.onTouchStart(ie),te&&(!M&&Z||g(te,Y,ee,{locale:K,priority:!0,bypassPrefetchedCheck:!0},{kind:J},Z))}};if((0,c.isAbsoluteUrl)(ee))he.href=ee;else if(!j||R||re.type==="a"&&!("href"in re.props)){const ie=typeof K<"u"?K:D==null?void 0:D.locale,me=(D==null?void 0:D.isLocaleDomain)&&(0,d.getDomainLocale)(ee,ie,D==null?void 0:D.locales,D==null?void 0:D.domainLocales);he.href=me||(0,m.addBasePath)((0,u.addLocale)(ee,ie,D==null?void 0:D.defaultLocale))}return j?n.default.cloneElement(re,he):n.default.createElement("a",{...T,...he},$)});(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)})(Xn,Xn.exports);var hf=Xn.exports,gf=hf;const Ne=Vt(gf),Ao={"btn-login":"_btn-login_yas63_12","btn-header":"_btn-header_yas63_22","header-animation":"_header-animation_yas63_35"},Eo=({id:e})=>{const{setIsOpen:t,cartStore:{items:r}}=Be(),{handleSelectContent:n}=ge(),{CONSTANTS:o}=ve(),i=r.reduce((a,c)=>a+(c.quantity??0),0);return s.jsx(v.Header.SupportItem,{onClick:()=>{t(!0),n({content:"header:minicart"})},id:e,children:s.jsxs(v.Badge.AutoPositioner,{children:[s.jsx(v.Badge.Count,{count:i,size:"medium",variant:"primary",style:{backgroundColor:"black",display:i>0?"flex":"none"}}),s.jsx(v.Icon,{name:o.header.ICONS.bag,size:"medium"})]})})};Eo.displayName="Header.Bag";const yt=({children:e,href:t,...r})=>t&&t!=="#"?s.jsx(Ne,{href:t.startsWith("/")?t:`/${t}`,...r,children:e}):e,Tc=()=>{const{headerData:e}=ve(),{handleSelectContent:t}=ge(),{reset:r,updateValue:n}=Ue(),o=i=>{i?n(i):r()};return s.jsx(v.Header.Categories,{children:Array.isArray(e.categories)&&e.categories.map((i,a)=>s.jsx(yt,{href:i.link,onMouseEnter:()=>o(i.submenuId),onFocus:()=>o(i.submenuId),children:s.jsx(v.Header.CategoryItem,{className:Ao["btn-header"],value:i.submenuId??null,adornment:{start:s.jsx(v.Icon,{name:i.iconStart}),end:s.jsx(v.Icon,{name:i.iconEnd})},style:{textWrap:"nowrap",gap:"0"},onClick:()=>{t({content:`header:${i.label}`})},children:i.label})},`category-${i.label}-${a}`))})};Tc.displayName="Header.Categories";function yf({SearchModal:e}){const{handleSelectContent:t}=ge(),{CONSTANTS:r}=ve(),{setValue:n}=ho();return s.jsxs(s.Fragment,{children:[s.jsx(v.Header.SupportItem,{onClick:()=>{n(!0),t({content:"header:search"})},children:s.jsx(v.Icon,{name:r.header.ICONS.search,size:"medium"})}),s.jsx(e,{recommendations:!1,trends:!0})]})}const _f={"menu-subcategories-container":"_menu-subcategories-container_a93cr_1"},vf={"observer-wrapper":"_observer-wrapper_r43gk_1"};function bf(e,t,r){const[n,o]=E.useState(!1),{threshold:i}=r||{};return E.useEffect(()=>{if(!e.current)return()=>null;let a=null;const c=new IntersectionObserver(([u])=>{if(r!=null&&r.delay){a&&clearTimeout(a),a=setTimeout(()=>{o(u.isIntersecting),t&&u.isIntersecting&&c.unobserve(e.current)},r.delay);return}o(u.isIntersecting),t&&u.isIntersecting&&c.unobserve(e.current)},{threshold:i||1});return c.observe(e.current),()=>{c.disconnect()}},[e]),n}const Qt=({children:e,eventData:t,observerOptions:r,callBackWhenVisible:n,stopOnIntersection:o=!0,className:i,...a})=>{const c=E.useRef(null),u=bf(c,o,r),{sendDataLayerEvent:l}=ge();return E.useEffect(()=>{u&&(typeof n=="function"&&n(),t&&l({...t}))},[u]),s.jsx("div",{...a,ref:c,className:v.helpers.classNameConcat(vf["observer-wrapper"],i),children:e})},wo=({thumbnails:e,category:t,isMobile:r=!0,callBack:n})=>{const{handleSelectPromotionEvent:o}=ge(),i=50/e.length;return s.jsx("div",{className:_f["menu-subcategories-container"],children:e.map((a,c)=>{const u=r?a.srcMobile:a.srcDesk;if(!u)return null;const l={creative_name:"banner-menu",creative_slot:`banner-menu:${t}:${c+1}`,promotion_id:u,promotion_name:a.promotion_name};return s.jsx(Qt,{eventData:{functionKey:"readyEvents",data:{event:"view_promotion",readyData:{ecommerce:{...l}}}},observerOptions:{delay:1e3},children:s.jsxs(Ne,{href:a.link??"#",onClick:()=>{typeof n=="function"&&n(),o({updatePromotionRef:!0,promotion:l})},children:[s.jsx($e.Image,{src:u,alt:a.label??u,width:500,height:500,sizes:`(max-width: 768px) 100vw, (max-width: 1023px) 75vw, ${i}vw`}),a.label&&s.jsx("p",{children:a.label})]})},`thumb-${a.label}-${c}`)})})};wo.displayName="Menu.Thumbnail";const Qn={"menu-desktop":"_menu-desktop_1b799_1","menu-categories":"_menu-categories_1b799_12"},xf="_link_w24h0_1",Cf="_wrapper_w24h0_98",Sf="_text_w24h0_106",jr={link:xf,wrapper:Cf,text:Sf},ze=({children:e,adornments:t,className:r,disableUnderline:n,href:o,mode:i,size:a,title:c,onClick:u,disablePadding:l,...f})=>{const p=v.helpers.ValidateProp({fieldTypes:et.SizesSmallExtended,property:a,fallback:"medium"}),d=v.helpers.ValidateProp({fieldTypes:et.Mode,property:i,fallback:"default"});return s.jsx(Ne,{...f,className:v.helpers.classNameConcat(jr.link,r),href:o&&o.length>0?o:"#","data-size":p,"data-variant":d,title:c||"NextLink","data-disable-underline":n??!1,"data-disable-padding":l??!0,children:s.jsxs("div",{className:jr.wrapper,onClick:u,children:[t==null?void 0:t.start,s.jsx("p",{className:jr.text,"data-size":p,children:e}),t==null?void 0:t.end]})})},Mc=({children:e,dividerOnRight:t=!0,subMenu:r,...n})=>{var u;const{router:o}=je(),{reset:i}=Ue(),{handleSelectContent:a}=ge(),{CONSTANTS:c}=ve();return s.jsxs("div",{...n,className:Qn["menu-categories"],children:[(u=r==null?void 0:r.subCategories)==null?void 0:u.map((l,f)=>{var m,h,y;const p=l.listCollapseDesk&&!((m=l.see_all)!=null&&m.link)?{expandAfterRowsQty:l.rowsToShowDesk}:{},d=l.listCollapseDesk&&!((h=l.see_all)!=null&&h.link)?{expansivesAdornments:{open:c.header.ICONS.add,close:c.header.ICONS.minus},expansivesLabels:{open:c.header.COMPONENT_LIST.listExpandLabel,close:c.header.COMPONENT_LIST.listCollapseLabel},iconSize:"x-small"}:{adornment:{end:s.jsx(v.Icon,{name:c.header.ICONS.arrow_right,size:"small"})}};return s.jsxs(v.ComponentList.Structure,{children:[s.jsx(yt,{href:l.linkLabel,title:l.label,onClick:()=>{l.linkLabel&&(i(),a({content:`menu:${l.label??""}:${r.label??""}`}))},children:s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{children:s.jsx("h2",{children:l.label})})})}),s.jsx(v.ComponentList.List,{columns:1,...p,className:Qn["submenu-categories"],children:l.items.map((g,b)=>s.jsx(v.ComponentList.ListItem,{id:`list-item-${g.label}-${b}`,children:s.jsx(ze,{href:g.link??"#",size:"x-small",title:g.label??"",disableUnderline:!0,disablePadding:!0,onClick:()=>{i(),a({content:`menu:${l.label??""}:${g.label??""}:${r.label??""}`})},children:g.label})},`list-item-${g.label}-${b}`))}),((y=l.see_all)==null?void 0:y.link)&&s.jsx(v.ComponentList.Support,{...d,size:"small",onClick:()=>{var g;(g=l.see_all)!=null&&g.link&&(i(),a({content:`menu:${l.label??""}:${r.label}`}),o.push(l.see_all.link))},children:l.see_all.link&&l.see_all.label})]},`list-${l.label}-${f}`)}),t&&s.jsx(v.Utils.Divider,{size:"small",direction:"vertical"})]})};Mc.displayName="Menu.Categories";const kc=({children:e,dividerOnBottom:t=!0,...r})=>{const{CONSTANTS:n}=ve();return s.jsxs(s.Fragment,{children:[s.jsx("div",{...r,className:Qn["menu-desktop"],style:{...r.style,justifyContent:n.header.ALIGNMENT_MENU},children:e}),t&&s.jsx(v.Utils.Divider,{size:"small"})]})};kc.displayName="Menu.MenuRoot";const Pr={Root:kc,Categories:Mc,Thumbnail:wo},Lc=()=>{const{headerData:e,CONSTANTS:t}=ve(),r=Wt(),{reset:n}=Ue();return s.jsx(v.Header.SubMenu,{children:Array.isArray(e.subMenus)&&e.subMenus.map((o,i)=>{const{thumbnails:a,label:c,id:u}=o,l=u===r,f=a==null?void 0:a.some(p=>!!p.srcDesk);return s.jsxs(Pr.Root,{id:u,style:l?{display:"flex",zIndex:t.header.Z_INDEX_WAR.menu_desktop}:{display:"none"},dividerOnBottom:l,children:[s.jsx(Pr.Categories,{dividerOnRight:!!f,subMenu:o}),Array.isArray(a)&&s.jsx(Pr.Thumbnail,{thumbnails:a,isMobile:!1,category:c,callBack:n})]},`submenu-${u}-${i}`)})})};Lc.displayName="Header.SubMenu";const Dc=()=>{const{handleSelectContent:e}=ge(),{CONSTANTS:t}=ve();return s.jsx(Ne,{href:"/favoritos",children:s.jsx(v.Header.SupportItem,{onClick:()=>e({content:"header:wishlist"}),children:s.jsx(v.Icon,{name:t.header.ICONS.favorite_false,size:"medium"})})})};Dc.displayName="Header.WishList";const $c=({SearchModal:e})=>{const{CONSTANTS:t,userMenuDesktopRef:r}=ve(),{handleSelectContent:n}=ge(),{reset:o}=Ue(),{setValue:i}=ht();return s.jsxs(s.Fragment,{children:[s.jsxs(v.Header.Wrapper,{children:[s.jsx(v.Header.Logo,{style:{width:"100%"},children:s.jsx(Ne,{href:"/",onMouseEnter:o,children:s.jsx(v.Icon,{name:t.header.ICONS.logo,size:"x-large",onClick:()=>{n({content:"header:logo"})}})})}),s.jsx(Tc,{}),s.jsxs(v.Header.Support,{onMouseEnter:o,style:{justifyContent:"flex-end"},children:[s.jsx(yf,{SearchModal:e}),s.jsx(v.Header.SupportItem,{onClick:()=>{i(!0),n({content:"header:user_menu"})},className:Ao["btn-login"],innerRef:r,children:s.jsx(v.Icon,{name:t.header.ICONS.person,size:"medium"})}),s.jsx(Dc,{}),s.jsx(Eo,{id:"cart-button"})]})]}),s.jsx(Lc,{})]})};$c.displayName="Header.HeaderDesktopWrapper";const Af="_divider_1lexj_199",_e={"modal-modifier":"_modal-modifier_1lexj_1","menu-mobile":"_menu-mobile_1lexj_11","menu-header-container":"_menu-header-container_1lexj_26","menu-header-wrapper":"_menu-header-wrapper_1lexj_35","menu-header-navlinks":"_menu-header-navlinks_1lexj_41","menu-body":"_menu-body_1lexj_57","menu-categories-container":"_menu-categories-container_1lexj_74","menu-categories-btn":"_menu-categories-btn_1lexj_108","menu-body-banner-container-modifier":"_menu-body-banner-container-modifier_1lexj_121","menu-categories__banner":"_menu-categories__banner_1lexj_130","menu-submenu-modal-modifiier":"_menu-submenu-modal-modifiier_1lexj_135","menu-submenu":"_menu-submenu_1lexj_135","menu-submenu--item":"_menu-submenu--item_1lexj_150","menu-submenu--thumbnails":"_menu-submenu--thumbnails_1lexj_156","menu-submenu--component-list-modifier":"_menu-submenu--component-list-modifier_1lexj_184","submenu-categories":"_submenu-categories_1lexj_187","menu-navigationbar":"_menu-navigationbar_1lexj_191",divider:Af,"menu-navigationbar-item":"_menu-navigationbar-item_1lexj_206","menu-categories-textstructure-modifier":"_menu-categories-textstructure-modifier_1lexj_210"},Bc=({children:e,mobileBannerAlt:t,mobileBannerSrc:r,onClick:n,textColor:o,...i})=>s.jsx("button",{onClick:n,className:_e["menu-categories-btn"],children:r?s.jsxs(v.Banner.Container,{...i,className:_e["menu-body-banner-container-modifier"],children:[s.jsx(v.Banner.ImageWrapper,{style:{width:"100%"},children:s.jsx($e.Image,{src:r,alt:t??r,className:_e["menu-categories__banner"],width:343,height:128,unoptimized:!0})}),s.jsx(v.Banner.Slot,{verticalAlignment:"center",horizontalAlignment:"start",children:s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{className:_e["menu-categories-textstructure-modifier"],children:s.jsx("h2",{className:"typography-style-body-xs",style:o?{color:o}:{},children:e})})})})]}):s.jsx("h2",{...i,children:e})});Bc.displayName="Menu.MenuCategories";const qc=({children:e,link:t})=>{const{reset:r}=Xe();return t?s.jsx(Ne,{href:t??"#",onClick:r,children:e}):e};qc.displayName="Menu.MenuCategoriesWrapper";const Hc=({subcategory:e,submenuLabel:t})=>{var u,l,f;const{router:r}=je(),{reset:n}=Xe(),{handleSelectContent:o}=ge(),{CONSTANTS:i}=ve(),a=e.listCollapseMobile&&!((u=e.see_all)!=null&&u.link)?{expandAfterRowsQty:e.rowsToShowMobile}:{},c=e.listCollapseMobile&&!((l=e.see_all)!=null&&l.link)?{expansivesAdornments:{open:i.header.ICONS.add,close:i.header.ICONS.minus},expansivesLabels:{open:i.header.COMPONENT_LIST.listExpandLabel,close:i.header.COMPONENT_LIST.listCollapseLabel},iconSize:"x-small"}:{adornment:{end:s.jsx(v.Icon,{name:i.header.ICONS.arrow_right,size:"small"})}};return s.jsxs(v.ComponentList.Structure,{className:_e["menu-submenu--component-list-modifier"],children:[s.jsx(yt,{href:e.linkLabel,title:e.label,onClick:()=>{n(),o({content:`menu:${e.label??""}:${t}`})},children:s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{children:s.jsx("h2",{className:"typography-style-body-sm-strong",children:e.label})})})}),s.jsx(v.ComponentList.List,{columns:1,...a,className:_e["submenu-categories"],children:e.items.map((p,d)=>s.jsx(v.ComponentList.ListItem,{id:`list-item-${p.label}-${d}`,divider:!0,children:s.jsx(ze,{href:p.link??"#",size:"x-small",title:p.label??"",disableUnderline:!0,onClick:()=>{n(),o({content:`menu:${e.label??""}:${p.label}:${t}`})},children:p.label})},`list-item-${p.label}-${d}`))}),((f=e.see_all)==null?void 0:f.link)&&s.jsx(v.ComponentList.Support,{...c,size:"small",onClick:()=>{var p;n(),o({content:`menu:${e.label??""}:${t}`}),(p=e.see_all)!=null&&p.link&&r.push(e.see_all.link)},children:e.see_all.link&&e.see_all.label})]})};Hc.displayName="Menu.SubMenuSubCategory";const Fc=({submenu:e})=>{var i;const t=Wt(),{handleCloseSubMenu:r}=gt(),{reset:n}=Ue(),{CONSTANTS:o}=ve();return s.jsxs("div",{className:_e["menu-submenu--item"],style:{display:t===e.id?"flex":"none"},children:[s.jsx(v.TextStructure.Root,{adornment:{start:s.jsx(v.Icon,{name:o.header.ICONS.arrow_back,size:"medium",onClick:r})},layoutProps:{textRow:{alignItems:"center",style:{width:"100%",position:"relative"}},columnWrapper:{alignContent:"center",style:{width:"100%"}}},children:e.label&&s.jsx(v.TextStructure.DivWrapper,{style:{position:"absolute",left:"50%",transform:"translate(-50%)"},children:s.jsx("h2",{className:"typography-style-body-md-strong",children:e.label})})}),s.jsx("div",{className:_e["menu-submenu--thumbnails"],children:Array.isArray(e.thumbnails)&&s.jsx(wo,{thumbnails:e.thumbnails,isMobile:!0,category:e.label,callBack:n})}),(i=e==null?void 0:e.subCategories)==null?void 0:i.map((a,c)=>s.jsx(Hc,{subcategory:a,submenuLabel:e.label},`list-${a.label}-${c}`))]})};Fc.displayName="Menu.SubMenuItem";const zc=()=>{const{headerData:e}=ve(),t=Wt(),{reset:r}=Ue(),{bodyRef:n}=gt();return s.jsx(v.Modal.RootWithoutPortal,{isOpen:!!t,setIsOpen:r,parent:n.current,variant:"sideLeft",style:{position:"absolute",width:"100%"},className:_e["menu-submenu-modal-modifiier"],children:s.jsx("div",{className:_e["menu-submenu"],children:e.subMenus.map((o,i)=>s.jsx(Fc,{submenu:o},`submenu-${o.id}-${i}`))})})};zc.displayName="Menu.SubMenu";const Uc=({className:e,...t})=>{const{headerData:r}=ve(),{setValue:n}=Ue(),{bodyRef:o}=gt(),{handleSelectContent:i}=ge();return s.jsxs("div",{...t,ref:o,id:"menu-body",className:_e["menu-body"],children:[s.jsx("div",{className:_e["menu-categories-container"],children:r.categories.map((a,c)=>{const u=a.submenuId?{}:{"data-close":!0};return s.jsx(qc,{link:a.submenuId?null:a.link,children:s.jsx(Bc,{onClick:()=>{n(a.submenuId??null),i({content:`menu:${a.label}`})},mobileBannerSrc:a.mobileBannerSrc,mobileBannerAlt:a.mobileBannerAlt,textColor:a.textColor,...u,children:a.mobileBannerAlt})},`menu-categories-${c}`)})}),s.jsx(zc,{})]})};Uc.displayName="Menu.MenuBody";const Gc=({title:e,subtitle:t})=>{const{CONSTANTS:r}=ve();return s.jsxs("div",{className:_e["menu-header-wrapper"],style:t?{alignItems:"start"}:{alignItems:"center"},children:[(e||t)&&s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{children:[e&&s.jsx("h2",{className:"typography-style-body-md",children:e}),t&&s.jsx("h3",{children:t})]})}),s.jsx(v.Button,{adornment:{end:s.jsx(v.Icon,{name:r.header.ICONS.close})},variant:"tertiary",className:_e["menu-close"],"data-close":!0})]})};Gc.displayName="Menu.MenuHeaderWrapper";const Wc=({navigationLinks:e})=>{const{reset:t}=Xe(),{handleSelectContent:r}=ge();return e?s.jsx("nav",{className:_e["menu-header-navlinks"],children:e.map((n,o)=>s.jsx(ze,{href:n.link??"#",adornments:{start:n.iconStart&&s.jsx(v.Icon,{name:n.iconStart}),end:n.iconEnd&&s.jsx(v.Icon,{name:n.iconEnd})},onClick:()=>{t(),r({content:`menu:navigationlinks-${n.label}`})},children:n.label},o))}):null};Wc.displayName="Menu.MenuHeaderNavLinks";const Vc=()=>{const{headerData:e}=ve();return s.jsxs("div",{className:_e["menu-header-container"],children:[s.jsx(Gc,{title:e.title,subtitle:e.subtitle}),s.jsx(Wc,{navigationLinks:e.navigationLinks})]})};Vc.displayName="Menu.MenuHeaderContainer";const Kc=({children:e})=>{const{documentBodyRef:t}=gt(),{CONSTANTS:r}=ve(),n=mo(),{setValue:o}=Xe();return s.jsx(v.Modal.RootWithoutPortal,{isOpen:n,setIsOpen:o,parent:t.current,variant:"sideLeft",style:{position:"fixed",zIndex:r.header.Z_INDEX_WAR.menu_mobile,bottom:"unset",top:0,overflowY:"hidden"},className:_e["modal-modifier"],children:s.jsx("div",{className:_e["menu-mobile"],children:e})})};Kc.displayName="Menu.MenuRoot";const Ft=({children:e,...t})=>s.jsxs(s.Fragment,{children:[s.jsx(v.Button,{...t,className:_e["menu-navigationbar-item"],children:e}),s.jsx(v.Utils.Divider,{direction:"vertical",size:"small",className:_e.divider})]});Ft.displayName="Menu.NavigationBarItem";const Xc=()=>{const{setIsOpen:e}=Be(),{reset:t}=Xe(),{setValue:r}=ht(),{handleSelectContent:n}=ge(),{CONSTANTS:o}=ve(),{router:i}=je();return s.jsxs(v.Card,{id:"menu-navigationbar",shadow:!0,className:_e["menu-navigationbar"],style:{zIndex:o.header.Z_INDEX_WAR.menu_mobile_navigation_bar},children:[s.jsx(Ft,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.login.button_icon,onClick:()=>{t(),r(!0),n({content:"menu:user_menu"})},children:o.header.MENU_INFO.login.button_text}),s.jsx(Ft,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.bag.button_icon,onClick:()=>{t(),e(!0),n({content:"menu:minicart"})},children:o.header.MENU_INFO.bag.button_text}),s.jsx(Ft,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.store.button_icon,onClick:()=>{i.push("/institucional/lojas"),t(),n({content:"menu:store"})},children:o.header.MENU_INFO.store.button_text})]})};Xc.displayName="Menu.NavigationBar";const Lt={Root:Kc,NavigationBar:Xc,Header:Vc,Body:Uc},Qc=({SearchModal:e})=>{const t=E.useRef(null),{CONSTANTS:r,userMenuMobileRef:n}=ve(),{MENU_NAVIGATION_BAR_ALLOWED:o,ICONS:i,MENU_MOB_BTN_SIDE:a="right"}=r.header,{handleSelectContent:c}=ge(),{setValue:u}=ho(),{setValue:l}=Xe(),{setValue:f}=ht();return s.jsxs(s.Fragment,{children:[s.jsxs(v.Header.Wrapper,{children:[a==="left"&&s.jsx(v.Header.SupportItem,{onClick:()=>l(!0),innerRef:t,children:s.jsx(v.Icon,{name:i.menu,size:"medium"})}),s.jsx(v.Header.Logo,{style:{width:"100%",justifyContent:"center"},children:s.jsx(Ne,{href:"/",children:s.jsx(v.Icon,{name:i.logo,size:"x-large",onClick:()=>{c({content:"header:logo"})}})})}),s.jsxs(v.Header.Support,{children:[s.jsx(v.Header.SupportItem,{onClick:()=>{u(!0),c({content:"header:search"})},children:s.jsx(v.Icon,{name:i.search,size:"medium"})}),s.jsx(v.Header.SupportItem,{onClick:()=>{f(!0),c({content:"header:user_menu"})},innerRef:n,children:s.jsx(v.Icon,{name:i.person,size:"medium"})}),s.jsx(Eo,{}),a==="right"&&s.jsx(v.Header.SupportItem,{onClick:()=>l(!0),innerRef:t,children:s.jsx(v.Icon,{name:i.menu,size:"medium"})})]})]}),s.jsx(e,{recommendations:!1,trends:!0}),s.jsx(Va,{children:s.jsxs(Lt.Root,{children:[s.jsx(Lt.Header,{}),s.jsx(Lt.Body,{}),o?s.jsx(Lt.NavigationBar,{}):s.jsx(s.Fragment,{})]})})]})};Qc.displayName="Header.HeaderMobileWrapper";const Ef="_root_wvekm_126",ke={"user-menu--credits":"_user-menu--credits_wvekm_1","user-menu--content":"_user-menu--content_wvekm_10","user-menu--login":"_user-menu--login_wvekm_30","user-menu--login--content":"_user-menu--login--content_wvekm_37","user-menu--menu":"_user-menu--menu_wvekm_64","user-menu--tooltip":"_user-menu--tooltip_wvekm_93","tooltip-modifier":"_tooltip-modifier_wvekm_104","modal-controls-modifier":"_modal-controls-modifier_wvekm_109","modal-header-modifier":"_modal-header-modifier_wvekm_117",root:Ef},Yc=({className:e,children:t,...r})=>s.jsx("div",{...r,className:v.helpers.classNameConcat(ke["user-menu--content"],e),children:t});Yc.displayName="UserMenu.Content";var Zc=(e=>(e.Account="account",e))(Zc||{});const Jc=({className:e,cashBack:t,credits:r,link:n,total:o,...i})=>{const a=t?Me(t):void 0,c=r?Me(r):void 0,u=o?Me(o):void 0;return s.jsx(v.Credits.Account,{...i,className:v.helpers.classNameConcat(ke["user-menu--credits"],e),icon:"wallet",showIcon:!0,cashBackValue:a,creditsValue:c,linkMore:n,totalValue:u,type:Zc.Account})};Jc.displayName="UserMenu.Credits";const eu=({className:e,children:t,description:r,text:n,...o})=>{const{isMobile:i}=Ae();return s.jsx("div",{...o,className:v.helpers.classNameConcat(ke["user-menu--login"],e),"data-mobile":i,children:s.jsxs("div",{className:ke["user-menu--login--content"],children:[s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{alignContent:"flex-start",alignItems:"flex-start",children:[s.jsx("h3",{className:"typography-style-body-lg-strong",children:n}),s.jsx("p",{children:r})]})}),t]})})};eu.displayName="UserMenu.Login";const tu=({className:e,isLogged:t,onLogoutClick:r,ICONS:n,storeConfig:o})=>{const{isMobile:i}=Ae(),a=Kl({ICONS:n,storeConfig:o}).filter(c=>c.deviceShown==="both"||c.deviceShown===(i?"mobile":"desktop"));return s.jsxs("ul",{className:v.helpers.classNameConcat(ke["user-menu--menu"],e),children:[Array.isArray(a)&&a.map((c,u)=>s.jsx("li",{children:s.jsx(ze,{href:c.href??"#",size:"small",disableUnderline:!0,adornments:{start:s.jsx(v.Icon,{name:c.icon??"delete"})},children:c.label})},u)),t?s.jsx("li",{children:s.jsx(ze,{href:`${o.secureSubdomain}/api/vtexid/pub/logout?scope=mariafilo&returnUrl=${encodeURIComponent(`${o.storeUrl}`)}`,size:"small",disableUnderline:!0,onClick:r,adornments:{start:s.jsx(v.Icon,{name:Vl(n)})},children:Wl})}):s.jsx(s.Fragment,{})]})};tu.displayName="UserMenu.Menu";const wf=e=>{const t=E.useRef(null),r=E.useCallback(i=>{t.current&&!t.current.contains(i.target)&&e()},[e]),n=E.useCallback(i=>{t.current&&!t.current.contains(i.target)&&e()},[e]),o=E.useCallback(i=>{i.key==="Escape"&&e()},[e]);return E.useEffect(()=>(document.addEventListener("mousedown",r),document.addEventListener("keydown",o),document.addEventListener("touchstart",n),()=>{document.removeEventListener("mousedown",r),document.removeEventListener("keydown",o),document.removeEventListener("touchstart",n)}),[r,o,n]),{ref:t}},Rf=e=>{if(!e||typeof window>"u")return 0;const t=window.getComputedStyle(e);return parseInt(t.padding,10)},jf=(e,t,r)=>{if(!(e instanceof HTMLElement)||!(t instanceof HTMLElement))return{left:0,top:0};const{height:n,left:o,top:i,width:a}=t.getBoundingClientRect(),c=e.getBoundingClientRect(),u=e!=null&&e.parentElement?Rf(e==null?void 0:e.parentElement):0;return{left:o+a/2-(c.width+u*2),top:i+n+r}},ru=E.createContext({}),Pf=({children:e,delay:t=600,gap:r=20,isOpen:n,setIsOpen:o,target:i,...a})=>{const c=E.useRef(null),[u,l]=E.useState(!1),[f,p]=E.useState({left:0,top:0}),{ref:d}=wf(()=>{l(!0),typeof window<"u"&&(c.current=window.setTimeout(()=>{o(!1),l(!1)},t))});return E.useEffect(()=>{if(i&&(d!=null&&d.current)){const{left:m,top:h}=jf(d.current,i,r??0);p({left:m,top:h}),l(!1)}},[r,n,i,d]),s.jsx(ru.Provider,{value:E.useMemo(()=>({...a,...f,contentRef:d,isLeaving:u,isOpen:n,setIsOpen:o,setIsLeaving:l,target:i}),[a,f,d,u,n,o,l,i]),children:e})},nu=()=>{const e=E.useContext(ru);if(e===void 0)throw new Error("useUserMenuContext must be used within a UserMenuProvider");return e},ou=({children:e,isMobile:t=!1,Z_INDEX_WAR:r})=>{const{isOpen:n,setIsOpen:o}=nu();return s.jsxs(v.Modal.Root,{"data-user":"user-menu--modal",isMobile:t??!1,isOpen:n,setIsOpen:o,variant:"sideBottom",className:ke["modal-root-modifier"],style:{zIndex:r.user_menu_mobile},children:[s.jsx(v.Modal.Header,{navigation:"top",className:ke["modal-header-modifier"],children:s.jsx(v.Modal.Controls,{navigation:"top",isMobile:!0,className:ke["modal-controls-modifier"]})}),s.jsx(v.Modal.Body,{children:e})]})};ou.displayName="UserMenu.Modal";const iu=({children:e,component:t,Z_INDEX_WAR:r,isMobile:n,...o})=>s.jsx(Pf,{...o,className:ke.root,children:n?s.jsxs(s.Fragment,{children:[s.jsx(We.Modal,{Z_INDEX_WAR:r,children:t}),e]}):s.jsx(We.Tooltip,{component:t,style:{width:304,zIndex:r.user_menu},Z_INDEX_WAR:r,children:e})});iu.displayName="UserMenu.Root";const su=({children:e,component:t,Z_INDEX_WAR:r,...n})=>{const{contentRef:o,left:i,isLeaving:a,isOpen:c,top:u}=nu();return s.jsx(v.Tooltip.Root,{arrow:"top-right",component:s.jsx("div",{...n,ref:o,children:t}),className:v.helpers.classNameConcat(ke["user-menu--tooltip"],ke["tooltip-modifier"]),isLeaving:a,isOpen:c,left:i,size:"medium",position:"top",top:u,style:{zIndex:r.user_menu},children:s.jsx("div",{className:ke["user-menu--tooltip"],children:e})})};su.displayName="UserMenu.Tooltip";const We={Credits:Jc,Content:Yc,Login:eu,Menu:tu,Modal:ou,Root:iu,Tooltip:su},Ro=()=>{var y,g,b;const e=bo(),{isMobile:t}=Ae(),{userMenuMobileRef:r,userMenuDesktopRef:n,CONSTANTS:{header:o},storeConfig:i}=ve(),{ICONS:a,Z_INDEX_WAR:c,MENU_INFO:u}=o,l=Ba(),{setValue:f}=ht(),p=()=>{window.location.href=`${i.secureSubdomain}/api/io/login?returnUrl=${encodeURIComponent(`${i.storeUrl}`)}`},d=!!((y=e.user)!=null&&y.userId),{cashback:m,credits:h}=E.useMemo(()=>{var A,_;return{credits:((A=e==null?void 0:e.getCurrentCredits())==null?void 0:A.credits)??0,cashback:((_=e==null?void 0:e.getCurrentCredits())==null?void 0:_.cashback)??0}},[e]);return s.jsx(We.Root,{component:s.jsxs(We.Content,{children:[s.jsx(We.Login,{description:Ql(d),text:Xl(d,((g=e==null?void 0:e.user)==null?void 0:g.firstName)??((b=e==null?void 0:e.user)==null?void 0:b.email)),children:!d&&s.jsx(v.Button,{size:"medium",variant:"quaternary",onClick:()=>p(),children:u.login.button_text})}),h+m&&d?s.jsx(We.Credits,{credits:h,cashBack:m,link:`${i.secureSubdomain}/account#/meus-creditos`,total:h+m}):s.jsx(s.Fragment,{}),s.jsx(v.Utils.Divider,{}),s.jsx(We.Menu,{isLogged:d,onLogoutClick:()=>e.logout(),ICONS:a,storeConfig:i})]}),target:t?r.current:n.current,isOpen:l,isMobile:t,setIsOpen:f,Z_INDEX_WAR:c})};Ro.displayName="UserMenu";const au=({tipBar:e,miniCart:t,SearchModal:r})=>{const{structureRef:n,rootRef:o,CONSTANTS:i}=ve(),{header:{HEADER_CONFIGS:a,Z_INDEX_WAR:c}}=i;return s.jsx(v.Header.Structure,{innerRef:n,adornment:{start:e},style:{position:"sticky",top:0,zIndex:c.header},className:Ao["header-animation"],children:s.jsxs(v.Header.Root,{innerRef:o,style:{zIndex:c.header},variant:a.default_variant,interactiveVariant:a.interactive_variant,children:[s.jsx("div",{className:Te.responsive["responsive-mobile-block"],style:{height:"100%",width:"100%",zIndex:c.header_mobile},children:s.jsx(Qc,{SearchModal:r})}),s.jsx("div",{className:Te.responsive["responsive-desktop-block"],style:{height:"100%",width:"100%",zIndex:c.header_desktop},children:s.jsx($c,{SearchModal:r})}),t,s.jsx(Co,{title:"Produto adicionado à sua sacola!",CONSTANTS:i.addToCart}),s.jsx(Ro,{})]})})};au.displayName="Header";const If="_shippingFreight_6z8rf_6",Nf="_shippingFreight__postalCodeGrid_6z8rf_10",Of="_shippingFreight__grid_6z8rf_14",Tf="_shippingFreight__grid__title_6z8rf_18",Mf="_shippingFreight__grid__remember_6z8rf_29",kf="_postalCodeContainer_6z8rf_44",Lf="_deliveryStatusBar__tag_6z8rf_49",Df="_deliveryStatusBarError__tag_6z8rf_66",$f="_deliveryInfo_6z8rf_74",Bf="_deliveryInfo__content_6z8rf_78",qf="_deliveryInfo__text_6z8rf_84",Hf="_deliveryInfo__title_6z8rf_89",Ff="_deliveryInfo__subtitle_6z8rf_99",zf="_deliveryInfo__tooltipIcon_6z8rf_109",Uf="_deliveryInfo__tooltip_6z8rf_109",Gf="_freightGrid_6z8rf_148",Wf="_freightContainer_6z8rf_155",Vf="_freightOption__content_6z8rf_160",Kf="_freightOption__value_6z8rf_166",Xf="_freightOption__title_6z8rf_177",Qf="_freightOption__title_item_6z8rf_181",Yf="_freightOption__paragraph_6z8rf_192",fe={shippingFreight:If,shippingFreight__postalCodeGrid:Nf,shippingFreight__grid:Of,shippingFreight__grid__title:Tf,shippingFreight__grid__remember:Mf,postalCodeContainer:kf,deliveryStatusBar__tag:Lf,deliveryStatusBarError__tag:Df,deliveryInfo:$f,deliveryInfo__content:Bf,deliveryInfo__text:qf,deliveryInfo__title:Hf,deliveryInfo__subtitle:Ff,deliveryInfo__tooltipIcon:zf,deliveryInfo__tooltip:Uf,freightGrid:Gf,freightContainer:Wf,freightOption__content:Vf,freightOption__value:Kf,freightOption__title:Xf,freightOption__title_item:Qf,freightOption__paragraph:Yf,"input-modifier":"_input-modifier_6z8rf_207","freight--tooltip":"_freight--tooltip_6z8rf_227"},Zf=({icon:e,title:t,subtitle:r,packageCount:n,packageUnit:o="",labelDescription:i,freightConfig:a,toolTipZIndex:c})=>{const[u,l]=E.useState(!1),f=E.useRef(null),p=()=>l(d=>!d);return s.jsxs("div",{className:fe.deliveryInfo,ref:f,children:[s.jsx(v.Tooltip.Root,{arrow:"bottom",component:s.jsx("div",{children:s.jsx("p",{children:a.messages.select_size_tag})}),id:"freight--tooltip",className:fe["freight--tooltip"],style:{zIndex:c},isOpen:!0,size:"medium",position:"top",top:"-170%",left:"4%",parent:f.current}),s.jsxs("div",{className:fe.deliveryInfo__content,children:[s.jsx("div",{className:fe.deliveryInfo__icon,children:s.jsx(v.Icon,{name:e,size:"medium"})}),s.jsxs("div",{className:fe.deliveryInfo__text,children:[s.jsxs("span",{className:fe.deliveryInfo__title,children:[t," ",n," ",o]}),r&&s.jsx("span",{className:fe.deliveryInfo__subtitle,children:r})]}),i&&s.jsxs("div",{className:fe.deliveryInfo__tooltipIcon,onMouseEnter:p,onMouseLeave:p,"aria-label":"Mostrar descrição",children:[s.jsx("span",{children:s.jsx(v.Icon,{name:a.icons.feedback_help,size:"small"})}),u&&s.jsx("div",{className:fe.deliveryInfo__tooltip,children:i})]})]})]})},Jf=({value:e,title:t,paragraph:r})=>s.jsx("div",{className:fe.freightOption,children:s.jsxs("div",{className:fe.freightOption__content,children:[s.jsx("span",{className:fe.freightOption__value,children:e}),s.jsx("span",{className:fe.freightOption__title,children:s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{className:fe.footer__item,children:[s.jsx("span",{className:fe.freightOption__title_item,children:t}),r&&s.jsx("span",{className:fe.freightOption__paragraph,children:r})]})})})]})}),ep=({children:e})=>s.jsx("div",{className:fe.freightContainer,children:e}),tp=({children:e})=>s.jsx("div",{className:fe.freightGrid,children:e}),rp=({children:e})=>s.jsx("div",{className:fe.postalCodeContainer,children:e}),Si=({message:e,seller:t="",size:r="small",setError:n})=>s.jsx("div",{className:n?fe.deliveryStatusBarError:fe.deliveryStatusBar,children:s.jsxs(v.Tag,{title:e,className:n?fe.deliveryStatusBarError__tag:fe.deliveryStatusBar__tag,size:r,children:[e," ",!n&&t]})}),np=e=>{const t=parseInt(e,10);return t===1?`${t} dia`:`${t} dias`},op=e=>{var r,n,o;const t=[];return(o=(n=(r=e==null?void 0:e.logisticsInfo)==null?void 0:r[0])==null?void 0:n.slas)==null||o.forEach(i=>{t.push({id:i.id,name:i.name,price:i.price,shippingEstimate:i.shippingEstimate})}),t},ip=({component:e,parent:t,top:r,left:n,target:o,contentRef:i,freightConfig:a,toolTipZIndex:c=999,...u})=>{const{isMobile:l}=Ae();return s.jsx(s.Fragment,{children:l?s.jsx(v.Tooltip.Root,{arrow:"bottom",component:s.jsxs("div",{...u,ref:i,children:[e,s.jsx("p",{children:a.messages.select_size_tag})]}),id:"freight--tooltip",className:fe["freight--tooltip"],style:{zIndex:c},isOpen:!0,size:"medium",position:"top",top:"-170%",left:"4%",parent:t}):s.jsx(v.Tooltip.Root,{arrow:"bottom",component:s.jsxs("div",{...u,ref:i,children:[e,s.jsx("p",{children:a.messages.select_size_tag})]}),id:"freight--tooltip",className:fe["freight--tooltip"],style:{zIndex:c},isOpen:!0,size:"medium",position:"top",top:"-110%",left:"3%",parent:t})})},sp=({onUpdateFreightItems:e,sellerId:t,size:r,skuId:n,quantity:o,setError:i,setIsButtonClicked:a,component:c,freightConfig:u,toolTipZIndex:l})=>{var N,k,B,R;const f=tt(),p=tt(q=>q.shipping),[d,m]=E.useState(),[h,y]=E.useState(!1),[g,b]=E.useState(!1),[A,_]=E.useState(!1),C=(k=(N=f.shippingData)==null?void 0:N.address)==null?void 0:k.postalCode,x=!(d!=null&&d.length)&&C?C:d,P=E.useRef(null),S=async q=>{const U=q.target.value.replace(/\D/g,"").slice(0,8);U.length>5?m(U.replace(/^(\d{5})(\d{1,3})/,"$1-$2")):m(U)},I=async q=>{const z=q.target.value.replace(/\D/g,"");try{if((await Mo.get(`https://viacep.com.br/ws/${z}/json/`)).data.erro){i&&i(u.messages.cep_not_found),a(!1),b(!0);return}i&&i(""),b(!1)}catch{console.log("Erro ao validar o CEP. Tente novamente mais tarde.")}},$=async()=>{y(!0);try{const q=await Mo.post("/api/checkout/simulation",{items:[{id:n,quantity:o,seller:t}],country:"BRA",postalCode:x});e(op(q.data))}catch(q){console.error("Erro ao atualizar o documento:",q)}finally{y(!1),p(x,"BRA")}},w=async()=>{if(!n){_(!0),setTimeout(()=>_(!1),1500);return}await I({target:{value:x}}),h||($(),a(!0))};return s.jsxs("div",{ref:P,style:{position:"relative"},children:[!n&&A?s.jsx(ip,{component:c,isOpen:A,parent:P.current,toolTipZIndex:l,freightConfig:u}):s.jsx(s.Fragment,{}),s.jsx("div",{style:{position:"relative"},children:s.jsx(v.TextField.Structure,{title:"structure",style:{width:"100%"},input:s.jsx(v.TextField.Input,{defaultValue:(R=(B=f.shippingData)==null?void 0:B.address)==null?void 0:R.postalCode,label:u.messages.text_input_label,title:"textfield",value:d,sizeVariant:r,onMouseOver:()=>n?null:_(!0),onMouseOut:()=>n?null:_(!1),mode:"simple",onChange:S,onKeyDown:q=>{q.key==="Enter"&&w()},className:fe["input-modifier"],feedback:g?"error":"none"}),right:s.jsx(v.Button,{onClick:w,size:r,title:"button",children:h?s.jsx(v.Spinner,{size:"small",indicatorColor:"#ffffff"}):u.messages.text_input_btn})})})]})},ap=({children:e,freightConfig:t})=>s.jsxs("div",{className:fe.shippingFreight,children:[s.jsxs("div",{className:fe.shippingFreight__grid,children:[s.jsx("span",{className:fe.shippingFreight__grid__title,children:t.messages.title}),s.jsx("span",{className:fe.shippingFreight__grid__remember,children:s.jsx(ze,{href:"https://buscacepinter.correios.com.br/app/endereco/index.php",passHref:!0,target:"_blank",rel:"noopener noreferrer",size:"x-small",disablePadding:!1,title:t.messages.remember_cep,children:t.messages.remember_cep})})]}),s.jsx("div",{className:fe.shippingFreight__postalCodeGrid,children:e})]}),cp=({children:e})=>s.jsx("div",{className:fe.freightContainer,children:e}),up=({className:e,sellerId:t,skuId:r,quantity:n,size:o,seller:i,local:a,CONSTANTS_PROPS:c})=>{const{sendDataLayerEvent:u}=ge(),[l,f]=E.useState(""),[p,d]=E.useState([]),[m,h]=E.useState(""),[y,g]=E.useState(!1),b=_=>f(_),A=_=>{d(_),u({functionKey:"readyEvents",data:{event:"search_zipcode",readyData:{shippings:_.map(C=>({shipping_tier:C.id,delivery_time:C.shippingEstimate.replace("bd",""),flag_pickup:C.name.toLowerCase().includes("retirada")?"true":"false",shipping:C.price,currency:c.currency||"BRL"}))}}})};return s.jsxs(cp,{className:e,children:[s.jsxs(ap,{freightConfig:c.freightConfig,children:[s.jsx(rp,{children:s.jsx(sp,{onUpdateFreightItems:A,skuId:r,quantity:n,size:o,sellerId:t,local:a,setError:h,setIsButtonClicked:g,freightConfig:c.freightConfig,toolTipZIndex:c.toolTipZIndex})}),m?s.jsx(Si,{size:o,message:m,setError:h}):p.length>0&&s.jsx(Si,{size:o,message:c.freightConfig.messages.delivered_by,seller:i})]}),y&&!m?p.length>0&&s.jsxs(ep,{children:[s.jsx(tp,{children:p.filter(({id:_})=>!_.includes("Retirada")).map(_=>s.jsx(Jf,{id:_.id,value:co({valueInCents:_.price,hasFree:!1,freeTaxMessage:c.freightConfig.messages.free_tax}),title:_.name,paragraph:`${c.freightConfig.messages.prefix_days}${np(_.shippingEstimate)}`,radioValue:l,changeValue:b},_.id))}),c.deliveryInfoBoxesAllowed?s.jsx(Zf,{icon:c.freightConfig.icons.delivery_truck,packageUnit:c.freightConfig.messages.unit_amout,title:c.freightConfig.messages.delivered_amount_packages,subtitle:"",packageCount:1,labelDescription:"Label",freightConfig:c.freightConfig,toolTipZIndex:c.toolTipZIndex??999}):s.jsx(s.Fragment,{})]}):null]})},cu=E.createContext({}),lp=({children:e,item:t,index:r,shelfTitle:n,...o})=>{const[i,a]=E.useState(null),c=E.useRef(null),u=E.useRef({availableSkus:[],priceInfo:{price:0,listPrice:0}}),{sendDataLayerEvent:l,itemListRef:f}=ge(),p=y=>{l({functionKey:"productEvents",data:{commonData:{...t,availableSizes:u.current.availableSkus,...u.current.priceInfo},customData:{index:r+1},event:y}})},d=()=>{p("add_to_wishlist")},m=()=>{l({functionKey:"skuEvents",data:{event:"add_to_cart",commonData:{products:[{...t,...u.current.priceInfo}]},supportData:{selectedSku:i,selectedSkus:[i]},customData:{index:r}}})},h=()=>{n&&(f.current={item_list_name:n}),p("select_item")};return s.jsx(cu.Provider,{value:E.useMemo(()=>({...o,index:r,item:t,element:c,selectedSku:i,setSelectedSku:a,eventDataRef:u,sendAddToWishlistEvent:d,sendSelectItemEvent:h,sendAddToCartEvent:m}),[o,t,c,i]),children:e})},Le=()=>{const e=E.useContext(cu);if(e===void 0)throw new Error("useProductCardContext must be used within a ProductCardProvider");return e},Se={"product-card--actions":"_product-card--actions_nmzk4_1","product-card--actions--group":"_product-card--actions--group_nmzk4_9","product-card--actions--selectors":"_product-card--actions--selectors_nmzk4_21","product-card--body":"_product-card--body_nmzk4_33","product-card--header":"_product-card--header_nmzk4_47","product-card--footer":"_product-card--footer_nmzk4_67","product-card--image":"_product-card--image_nmzk4_90","product-card--image--container":"_product-card--image--container_nmzk4_97","product-card--outstock":"_product-card--outstock_nmzk4_133","product-card--price":"_product-card--price_nmzk4_155","product-card--title":"_product-card--title_nmzk4_177","product-card--title--tag":"_product-card--title--tag_nmzk4_183","product-card--title--content":"_product-card--title--content_nmzk4_200","product-card--selectors--size":"_product-card--selectors--size_nmzk4_240","product-card--selectors--size--button":"_product-card--selectors--size--button_nmzk4_266","product-card--selectors--size--skus":"_product-card--selectors--size--skus_nmzk4_275","product-card--selectors--style":"_product-card--selectors--style_nmzk4_289","product-card--selectors--style--more":"_product-card--selectors--style--more_nmzk4_299","product-card--video":"_product-card--video_nmzk4_316","product-card--wrapper":"_product-card--wrapper_nmzk4_342"},uu=({callback:e,children:t,className:r,data:n,isKit:o,...i})=>{const{item:{availability:{status:a},image:c}}=Le();return a?s.jsxs("div",{...i,className:v.helpers.classNameConcat(Se["product-card--actions"],r),children:[s.jsxs(Pe.Wrapper,{type:"actions--group",children:[s.jsx(Pe.Price,{}),s.jsx("div",{className:Se["product-card--actions--selectors"],children:!o&&s.jsx(Pe.StyleSelector,{data:n,images:c,callback:e})})]}),t]}):null};uu.displayName="ProductCard.Actions";const lu=({className:e,isKit:t,...r})=>{const{addToCart:n}=Be(),{isMobile:o=!1,selectedSku:i,outStock:a,item:c,sendAddToCartEvent:u,CONSTANTS:l}=Le(),f=()=>{var m;if(!i)return;const d=lo(i.offers.offers,l.StoreConfig_MainSellerId);d&&n({id:i==null?void 0:i.sku,quantity:1,seller:d.seller.identifier},{id:c.id,texture:(m=c==null?void 0:c.image.find(h=>l.TEXTURE_IMAGE.includes(h.alternateName)))==null?void 0:m.url}),u()},p=i?l.BUY_BUTTON_LABELS.add_to_cart:l.BUY_BUTTON_LABELS.select_size;return s.jsx(v.Button,{...r,className:v.helpers.classNameConcat(e,"buy-button"),disabled:!t&&!i&&!a,size:o?"medium":"large",variant:a?"secondary":"primary",onClick:a?r.onClick:f,children:a?"Avise-me quando chegar":p})};lu.displayName="ProductCard.Actions.BuyButton";const du=({product:e,tag:t,size:r="small"})=>{const n=e.offers.offers[0],{CONSTANTS:o,WishListToggle:i}=Le();return s.jsxs(Pe.Wrapper,{type:"header",style:{zIndex:o.Z_INDEX_WAR.product_card_header},children:[t?s.jsx(v.Tag,{title:t.value,adornment:{start:t.enableIcon&&t.icon?s.jsx(v.Icon,{name:t.icon,size:"small",style:{color:t.iconColor}}):null},size:r,variant:"quaternary",style:{background:t.tagColor,color:t.textColor},children:t.value}):null,o.PRODUCT_CARD_TOP_WISHLIST_TOGGLE&&s.jsx(i,{product:e,priceInfo:{price:n.price,listPrice:n.listPrice},variant:"card"})]})};du.displayName="ProductCard.Actions.Header";const fu=({className:e,children:t,hasPriority:r=!1,showVideo:n=!1,...o})=>{const{element:i,index:a,item:{image:c,slug:u,video:l},sendSelectItemEvent:f,order:p,CONSTANTS:d}=Le(),m=na({images:c,label:{first:d.MAIN_IMAGE,second:d.SECOND_IMAGE}});return s.jsxs("div",{...o,className:v.helpers.classNameConcat(Se["product-card--image"],e),ref:i,style:{aspectRatio:d.PRODUCT_CARD_IMAGE_ASPECT_RATIO},children:[s.jsx(Ne,{href:`/${u}/p`,onClick:f,onMouseUp:h=>{h.button===1&&f(),d.PLP_INFINITE_SCROLL&&sessionStorage.setItem(d.PLP_GRID_SCROLL_BACK.order,String(p))},children:s.jsx("div",{className:Se["product-card--image--container"],children:Array.isArray(m)&&m.map(({url:h,alternateName:y},g)=>E.createElement($e.Image,{...d.PRODUCT_IMAGE_DIMENSIONS.product_card,style:d.PRODUCT_IMAGE_DIMENSIONS.product_card,alt:y??"product image",key:g,...r&&{priority:g===0&&a<4},objectFit:"cover",src:h}))})}),d.PLP_SHOW_VIDEO_ON_PRODUCT_CARD&&n&&l&&s.jsx(Pe.Video,{url:l,poster:m[0].url}),t]})};fu.displayName="ProductCard.Media.Media";const pu=({className:e,callback:t,children:r,...n})=>{const{isMobile:o,item:i,CONSTANTS:{PRODUCT_CARD_TEXTS:a}}=Le(),{availability:{status:c}}=i;return c?null:s.jsxs("div",{...n,className:v.helpers.classNameConcat(Se["product-card--outstock"],e),children:[s.jsx(v.Tag,{size:"small",variant:"secondary",title:a.disabled,children:a.disabled}),s.jsx(v.Button,{className:v.helpers.classNameConcat(e,"buy-button"),size:o?"medium":"large",variant:"quaternary",onClick:()=>{typeof t=="function"&&t(i)},children:a.notify})]})};pu.displayName="ProductCard.OutStock";const mu=({children:e,className:t="",index:r,isMobile:n=!1,item:o,size:i,order:a,outStock:c,shelfTitle:u,CONSTANTS:l,WishListToggle:f,...p})=>s.jsx(lp,{item:o,isMobile:n,outStock:c,order:a,size:i,index:r,shelfTitle:u,CONSTANTS:l,WishListToggle:f,children:s.jsx("div",{...p,className:v.helpers.classNameConcat(Se["product-card--wrapper"],t),"data-size":i,children:e})});mu.displayName="ProductCard.Root";const hu=({disabled:e,label:t,size:r,value:n,onClick:o,...i})=>s.jsxs(v.ToggleSize.Wrapper,{...i,disabled:!1,outOfStock:e,size:r,onClick:o,children:[s.jsx(v.ToggleSize.DisabledAdornment,{}),s.jsx(v.ToggleSize.Text,{children:t})]});hu.displayName="ProductCard.SizeSelector.Item";const gu=({active:e=!1,callback:t,selectedSku:r=null,item:n,setNotify:o})=>{const{item:i,isMobile:a,setSelectedSku:c,eventDataRef:u}=Le();n.productId=i.id;const l=Js(n),f=Ys(n,"tamanho");!l&&!u.current.availableSkus.includes(f)&&u.current.availableSkus.push(f);const p=E.useCallback(m=>{const h=r===m?null:m;typeof c=="function"&&c(h),typeof t=="function"&&t(h)},[t,c,r]),d=E.useCallback(()=>{if(l&&typeof o=="function"){o(i,n);return}p(n)},[n,o,p,l,i]);return s.jsx(hu,{active:e,disabled:l,label:f,onClick:()=>d(),size:a?"x-small":"small",value:n})};gu.displayName="ProductCard.SizeSelector.SkuItem";const yu=({callback:e,className:t="",children:r,setNotify:n,...o})=>{const{isMobile:i,item:{isVariantOf:{hasVariant:a}},selectedSku:c}=Le();return s.jsxs("div",{...o,className:v.helpers.classNameConcat(Se["product-card--selectors--size"],t),"data-mobile":i,children:[s.jsx("div",{className:Se["product-card--selectors--size--skus"],children:Array.isArray(a)&&a.map((u,l)=>s.jsx(gu,{active:c===u,callback:e,item:u,selectedSku:c,setNotify:n},`size--${l}--${u.sku}`))}),s.jsx("div",{className:Se["product-card--selectors--size--button"],children:r})]})};yu.displayName="ProductCard.SizeSelector";const Yn=({alt:e="",callback:t,more:r,total:n=4,src:o,url:i,...a})=>s.jsxs(v.ToggleStyle.Wrapper,{...a,onClick:()=>{typeof t=="function"&&t(i)},children:[s.jsx(v.ToggleStyle.DisabledAdornment,{}),s.jsxs(v.ToggleStyle.Texture,{children:[o&&s.jsx($e.Image,{alt:e??o,src:o,height:34,width:34}),r&&s.jsx(v.TextStructure.DivWrapper,{className:Se["product-card--selectors--style--more"],children:s.jsxs("p",{children:["+ ",n]})})]})]}),dp=({children:e,callback:t,data:r,total:n=4,size:o,...i})=>{const{index:a}=Le(),{triggerSelectItemEventRef:c}=ge();return s.jsxs("div",{...i,children:[e,Array.isArray(r)&&r.slice(0,n).map((u,l)=>s.jsx(Yn,{callback:f=>{c.current.trigger=!0,c.current.index=a,typeof t=="function"&&t(f)},src:(u==null?void 0:u.textureImage)??"",alt:u==null?void 0:u.textureAlt,url:u==null?void 0:u.slug,size:o},l)),Array.isArray(r)&&(r==null?void 0:r.length)>n&&s.jsx(Yn,{size:o,total:r.length-n,more:!0})]})},_u=({callback:e,className:t,data:r,images:n=[],findTexture:o,...i})=>{const{CONSTANTS:a}=Le(),c=o||a.TEXTURE_IMAGE,u=n==null?void 0:n.find(l=>c.includes(l.alternateName));return s.jsx(dp,{...i,callback:e,className:v.helpers.classNameConcat(Se["product-card--selectors--style"],t),data:r,size:"x-small",children:u&&s.jsx(Yn,{active:!0,size:"x-small",src:u.url})})};_u.displayName="ProductCard.StyleSelector";const vu=({className:e,hasDecimal:t,...r})=>{const{isMobile:n,item:{offers:{lowPrice:o,highPrice:i},installments:{count:a,value:c}},eventDataRef:u}=Le();u.current.priceInfo={price:o,listPrice:i};const l=Me(i,t),f=Me(o,t),p=Me(c??0),d=n?"horizontal":"stacked";return s.jsx("div",{...r,className:v.helpers.classNameConcat(Se["product-card--price"],e),"data-mobile":n,children:s.jsx(v.ProductInfo.Root,{size:"small",layout:d,children:s.jsxs(v.ProductInfo.Wrapper,{size:"small",layout:d,children:[s.jsx(v.ProductInfo.ValuesWrapper,{children:f!==l?s.jsxs(s.Fragment,{children:[s.jsx(v.ProductInfo.Price,{label:"originalPrice",value:l,size:"small"}),s.jsx(v.ProductInfo.Price,{label:"discountPrice",value:f,size:"small"})]}):s.jsx(v.ProductInfo.Price,{label:"defaultPrice",value:f,size:"small"})}),a&&a>1&&c?s.jsx(v.ProductInfo.Price,{label:"installment",value:`${a}x ${p}`,size:"small"}):null]})})})};vu.displayName="ProductCard.Price";const bu=({tag:e,className:t})=>{const{item:{name:r}}=Le();return s.jsxs("div",{className:v.helpers.classNameConcat(Se["product-card--title"],t),children:[s.jsx("div",{className:Se["product-card--title--tag"],children:e?s.jsx(v.Tag,{size:"small",title:e.value,variant:"quaternary",adornment:{start:e.enableIcon&&e.icon?s.jsx(v.Icon,{name:e.icon,style:{color:e.iconColor}}):null},style:{background:e.tagColor,color:e.textColor},children:e.value}):s.jsx("div",{})}),s.jsx("div",{className:Se["product-card--title--content"],children:r&&s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{children:s.jsx("h3",{children:r})})})})]})};bu.displayName="ProductCard.Title";const xu=({className:e,url:t,poster:r,...n})=>{const{element:o}=Le();return E.useEffect(()=>{if(!(o!=null&&o.current))return;const i=o.current,a=i.querySelector("video");if(a){const c=new IntersectionObserver(f=>{f.forEach(p=>{oa(p.isIntersecting,a,t)})},{root:null,rootMargin:"0px",threshold:.5}),u=()=>{a.setAttribute("data-loaded","true")},l=()=>{i&&(c.observe(i),a.addEventListener("loadeddata",u))};return document.readyState==="complete"?l():window.addEventListener("load",l),()=>{c.disconnect(),window.removeEventListener("load",l)}}return()=>null},[t,o]),s.jsx("div",{...n,className:v.helpers.classNameConcat(Se["product-card--video"],e),children:t&&s.jsx($e.Video,{autoPlay:!1,muted:!0,loop:!0,preload:"none",playsInline:!0,poster:r})})};xu.displayName="ProductCard.Media.Video";const Cu=({children:e,className:t,type:r,...n})=>s.jsx("div",{...n,className:v.helpers.classNameConcat(Se[`product-card--${r}`],t),children:e});Cu.displayName="ProductCard.Wrapper";const Pe={Actions:uu,BuyButton:lu,Header:du,Media:fu,Root:mu,OutStock:pu,Price:vu,SizeSelector:yu,StyleSelector:_u,Title:bu,Video:xu,Wrapper:Cu},fp="_footer__bottom_1o9af_2",pp="_footer__wrapper_1o9af_10",mp="_footer__main_1o9af_39",hp="_footer__legalInformation_1o9af_55",gp="_footer__column_1o9af_77",yp="_footer__columnContent_1o9af_87",_p="_footer__item_1o9af_91",vp="_footer__itemLink_1o9af_107",bp="_footer__columnTitle_1o9af_122",xp="_footer__columnTitleIcon_1o9af_134",Cp="_footer__iconList_1o9af_147",Sp="_footer__itemSmallText_1o9af_157",Ap="_payment_1o9af_168",Ep="_footer__iconContainer_1o9af_173",wp="_footer__iconListSubHeader_1o9af_178",Rp="_accordionWrapper_1o9af_200",jp="_accordionHeader_1o9af_204",Pp="_accordionTextWrapper_1o9af_208",pe={footer__bottom:fp,footer__wrapper:pp,footer__main:mp,footer__legalInformation:hp,footer__column:gp,footer__columnContent:yp,footer__item:_p,footer__itemLink:vp,footer__columnTitle:bp,footer__columnTitleIcon:xp,footer__iconList:Cp,footer__itemSmallText:Sp,payment:Ap,footer__iconContainer:Ep,footer__iconListSubHeader:wp,accordionWrapper:Rp,accordionHeader:jp,accordionTextWrapper:Pp,"footer--stamps":"_footer--stamps_1o9af_247","footer--stamps--company":"_footer--stamps--company_1o9af_254","support-container":"_support-container_1o9af_258","support-section":"_support-section_1o9af_277","support-text":"_support-text_1o9af_319","support-items":"_support-items_1o9af_329","support-item":"_support-item_1o9af_329"};var Su={},jo={},_t={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"warnOnce",{enumerable:!0,get:function(){return t}});let t=r=>{};if(process.env.NODE_ENV!=="production"){const r=new Set;t=n=>{r.has(n)||console.warn(n),r.add(n)}}})(_t);var Au={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getImageBlurSvg",{enumerable:!0,get:function(){return t}});function t(r){let{widthInt:n,heightInt:o,blurWidth:i,blurHeight:a,blurDataURL:c,objectFit:u}=r;const l=20,f=i?i*40:n,p=a?a*40:o,d=f&&p?"viewBox='0 0 "+f+" "+p+"'":"",m=d?"none":u==="contain"?"xMidYMid":u==="cover"?"xMidYMid slice":"none";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+d+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='"+l+"'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='"+l+"'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+m+"' style='filter: url(%23b);' href='"+c+"'/%3E%3C/svg%3E"}})(Au);var Yt={};(function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(o,i){for(var a in i)Object.defineProperty(o,a,{enumerable:!0,get:i[a]})}t(e,{VALID_LOADERS:function(){return r},imageConfigDefault:function(){return n}});const r=["default","imgix","cloudinary","akamai","custom"],n={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:60,formats:["image/webp"],dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"inline",remotePatterns:[],unoptimized:!1}})(Yt);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getImgProps",{enumerable:!0,get:function(){return m}});const t=_t,r=Au,n=Yt,o=["lazy","eager",void 0];function i(h){return h.default!==void 0}function a(h){return h.src!==void 0}function c(h){return typeof h=="object"&&(i(h)||a(h))}const u=new Map;let l;function f(h){return typeof h>"u"?h:typeof h=="number"?Number.isFinite(h)?h:NaN:typeof h=="string"&&/^[0-9]+$/.test(h)?parseInt(h,10):NaN}function p(h,y,g){let{deviceSizes:b,allSizes:A}=h;if(g){const C=/(^|\s)(1?\d?\d)vw/g,x=[];for(let P;P=C.exec(g);P)x.push(parseInt(P[2]));if(x.length){const P=Math.min(...x)*.01;return{widths:A.filter(S=>S>=b[0]*P),kind:"w"}}return{widths:A,kind:"w"}}return typeof y!="number"?{widths:b,kind:"w"}:{widths:[...new Set([y,y*2].map(C=>A.find(x=>x>=C)||A[A.length-1]))],kind:"x"}}function d(h){let{config:y,src:g,unoptimized:b,width:A,quality:_,sizes:C,loader:x}=h;if(b)return{src:g,srcSet:void 0,sizes:void 0};const{widths:P,kind:S}=p(y,A,C),I=P.length-1;return{sizes:!C&&S==="w"?"100vw":C,srcSet:P.map(($,w)=>x({config:y,src:g,quality:_,width:$})+" "+(S==="w"?$:w+1)+S).join(", "),src:x({config:y,src:g,quality:_,width:P[I]})}}function m(h,y){let{src:g,sizes:b,unoptimized:A=!1,priority:_=!1,loading:C,className:x,quality:P,width:S,height:I,fill:$=!1,style:w,onLoad:N,onLoadingComplete:k,placeholder:B="empty",blurDataURL:R,fetchPriority:q,layout:z,objectFit:U,objectPosition:K,lazyBoundary:W,lazyRoot:F,...ne}=h;const{imgConf:j,showAltText:T,blurComplete:D,defaultLoader:X}=y;let te,Z=j||n.imageConfigDefault;if("allSizes"in Z)te=Z;else{const G=[...Z.deviceSizes,...Z.imageSizes].sort((Ce,Q)=>Ce-Q),le=Z.deviceSizes.sort((Ce,Q)=>Ce-Q);te={...Z,allSizes:G,deviceSizes:le}}let M=ne.loader||X;delete ne.loader,delete ne.srcSet;const J="__next_img_default"in M;if(J){if(te.loader==="custom")throw new Error('Image with src "'+g+`" is missing "loader" prop.
5
- Read more: https://nextjs.org/docs/messages/next-image-missing-loader`)}else{const G=M;M=le=>{const{config:Ce,...Q}=le;return G(Q)}}if(z){z==="fill"&&($=!0);const G={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}},le={responsive:"100vw",fill:"100vw"},Ce=G[z];Ce&&(w={...w,...Ce});const Q=le[z];Q&&!b&&(b=Q)}let Y="",ee=f(S),L=f(I),O,re;if(c(g)){const G=i(g)?g.default:g;if(!G.src)throw new Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(G));if(!G.height||!G.width)throw new Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(G));if(O=G.blurWidth,re=G.blurHeight,R=R||G.blurDataURL,Y=G.src,!$){if(!ee&&!L)ee=G.width,L=G.height;else if(ee&&!L){const le=ee/G.width;L=Math.round(G.height*le)}else if(!ee&&L){const le=L/G.height;ee=Math.round(G.width*le)}}}g=typeof g=="string"?g:Y;let se=!_&&(C==="lazy"||typeof C>"u");(!g||g.startsWith("data:")||g.startsWith("blob:"))&&(A=!0,se=!1),te.unoptimized&&(A=!0),J&&g.endsWith(".svg")&&!te.dangerouslyAllowSVG&&(A=!0),_&&(q="high");const ce=f(P);if(process.env.NODE_ENV!=="production"){if(te.output==="export"&&J&&!A)throw new Error("Image Optimization using the default loader is not compatible with `{ output: 'export' }`.\n Possible solutions:\n - Remove `{ output: 'export' }` and run \"next start\" to run server mode including the Image Optimization API.\n - Configure `{ images: { unoptimized: true } }` in `next.config.js` to disable the Image Optimization API.\n Read more: https://nextjs.org/docs/messages/export-image-api");if(!g)A=!0;else if($){if(S)throw new Error('Image with src "'+g+'" has both "width" and "fill" properties. Only one should be used.');if(I)throw new Error('Image with src "'+g+'" has both "height" and "fill" properties. Only one should be used.');if(w!=null&&w.position&&w.position!=="absolute")throw new Error('Image with src "'+g+'" has both "fill" and "style.position" properties. Images with "fill" always use position absolute - it cannot be modified.');if(w!=null&&w.width&&w.width!=="100%")throw new Error('Image with src "'+g+'" has both "fill" and "style.width" properties. Images with "fill" always use width 100% - it cannot be modified.');if(w!=null&&w.height&&w.height!=="100%")throw new Error('Image with src "'+g+'" has both "fill" and "style.height" properties. Images with "fill" always use height 100% - it cannot be modified.')}else{if(typeof ee>"u")throw new Error('Image with src "'+g+'" is missing required "width" property.');if(isNaN(ee))throw new Error('Image with src "'+g+'" has invalid "width" property. Expected a numeric value in pixels but received "'+S+'".');if(typeof L>"u")throw new Error('Image with src "'+g+'" is missing required "height" property.');if(isNaN(L))throw new Error('Image with src "'+g+'" has invalid "height" property. Expected a numeric value in pixels but received "'+I+'".')}if(!o.includes(C))throw new Error('Image with src "'+g+'" has invalid "loading" property. Provided "'+C+'" should be one of '+o.map(String).join(",")+".");if(_&&C==="lazy")throw new Error('Image with src "'+g+`" has both "priority" and "loading='lazy'" properties. Only one should be used.`);if(B!=="empty"&&B!=="blur"&&!B.startsWith("data:image/"))throw new Error('Image with src "'+g+'" has invalid "placeholder" property "'+B+'".');if(B!=="empty"&&ee&&L&&ee*L<1600&&(0,t.warnOnce)('Image with src "'+g+'" is smaller than 40x40. Consider removing the "placeholder" property to improve performance.'),B==="blur"&&!R){const G=["jpeg","png","webp","avif"];throw new Error('Image with src "'+g+`" has "placeholder='blur'" property but is missing the "blurDataURL" property.
6
- Possible solutions:
7
- - Add a "blurDataURL" property, the contents should be a small Data URL to represent the image
8
- - Change the "src" property to a static import with one of the supported file types: `+G.join(",")+` (animated images not supported)
9
- - Remove the "placeholder" property, effectively no blur effect
10
- Read more: https://nextjs.org/docs/messages/placeholder-blur-data-url`)}if("ref"in ne&&(0,t.warnOnce)('Image with src "'+g+'" is using unsupported "ref" property. Consider using the "onLoadingComplete" property instead.'),!A&&!J){const G=M({config:te,src:g,width:ee||400,quality:ce||75});let le;try{le=new URL(G)}catch{}(G===g||le&&le.pathname===g&&!le.search)&&(0,t.warnOnce)('Image with src "'+g+`" has a "loader" property that does not implement width. Please implement it or use the "unoptimized" property instead.
11
- Read more: https://nextjs.org/docs/messages/next-image-missing-loader-width`)}for(const[G,le]of Object.entries({layout:z,objectFit:U,objectPosition:K,lazyBoundary:W,lazyRoot:F}))le&&(0,t.warnOnce)('Image with src "'+g+'" has legacy prop "'+G+`". Did you forget to run the codemod?
12
- Read more: https://nextjs.org/docs/messages/next-image-upgrade-to-13`);if(typeof window<"u"&&!l&&window.PerformanceObserver){l=new PerformanceObserver(G=>{for(const Ce of G.getEntries()){var le;const Q=(Ce==null||(le=Ce.element)==null?void 0:le.src)||"",oe=u.get(Q);oe&&!oe.priority&&oe.placeholder==="empty"&&!oe.src.startsWith("data:")&&!oe.src.startsWith("blob:")&&(0,t.warnOnce)('Image with src "'+oe.src+`" was detected as the Largest Contentful Paint (LCP). Please add the "priority" property if this image is above the fold.
13
- Read more: https://nextjs.org/docs/api-reference/next/image#priority`)}});try{l.observe({type:"largest-contentful-paint",buffered:!0})}catch(G){console.error(G)}}}const ue=Object.assign($?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:U,objectPosition:K}:{},T?{}:{color:"transparent"},w),ae=!D&&B!=="empty"?B==="blur"?'url("data:image/svg+xml;charset=utf-8,'+(0,r.getImageBlurSvg)({widthInt:ee,heightInt:L,blurWidth:O,blurHeight:re,blurDataURL:R||"",objectFit:ue.objectFit})+'")':'url("'+B+'")':null;let H=ae?{backgroundSize:ue.objectFit||"cover",backgroundPosition:ue.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:ae}:{};process.env.NODE_ENV==="development"&&H.backgroundImage&&B==="blur"&&R!=null&&R.startsWith("/")&&(H.backgroundImage='url("'+R+'")');const he=d({config:te,src:g,unoptimized:A,width:ee,quality:ce,sizes:b,loader:M});if(process.env.NODE_ENV!=="production"&&typeof window<"u"){let G;try{G=new URL(he.src)}catch{G=new URL(he.src,window.location.href)}u.set(G.href,{src:g,priority:_,placeholder:B})}return{props:{...ne,loading:se?"lazy":C,fetchPriority:q,width:ee,height:L,decoding:"async",className:x,style:{...ue,...H},sizes:he.sizes,srcSet:he.srcSet,src:he.src},meta:{unoptimized:A,priority:_,placeholder:B,fill:$}}}})(jo);var Zn={exports:{}},Dt={exports:{}},Ir={},Ai;function Ip(){return Ai||(Ai=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return i}});const t=E,r=typeof window>"u",n=r?()=>{}:t.useLayoutEffect,o=r?()=>{}:t.useEffect;function i(a){const{headManager:c,reduceComponentsToState:u}=a;function l(){if(c&&c.mountedInstances){const p=t.Children.toArray(Array.from(c.mountedInstances).filter(Boolean));c.updateHead(u(p,a))}}if(r){var f;c==null||(f=c.mountedInstances)==null||f.add(a.children),l()}return n(()=>{var p;return c==null||(p=c.mountedInstances)==null||p.add(a.children),()=>{var d;c==null||(d=c.mountedInstances)==null||d.delete(a.children)}}),n(()=>(c&&(c._pendingUpdate=l),()=>{c&&(c._pendingUpdate=l)})),o(()=>(c&&c._pendingUpdate&&(c._pendingUpdate(),c._pendingUpdate=null),()=>{c&&c._pendingUpdate&&(c._pendingUpdate(),c._pendingUpdate=null)})),null}}(Ir)),Ir}var Nr={},Ei;function Np(){return Ei||(Ei=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"AmpStateContext",{enumerable:!0,get:function(){return n}});const n=Re._(E).default.createContext({});process.env.NODE_ENV!=="production"&&(n.displayName="AmpStateContext")}(Nr)),Nr}var Or={},wi;function Eu(){return wi||(wi=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"HeadManagerContext",{enumerable:!0,get:function(){return n}});const n=Re._(E).default.createContext({});process.env.NODE_ENV!=="production"&&(n.displayName="HeadManagerContext")}(Or)),Or}var Tr={},Ri;function Op(){return Ri||(Ri=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isInAmpMode",{enumerable:!0,get:function(){return t}});function t(r){let{ampFirst:n=!1,hybrid:o=!1,hasQuery:i=!1}=r===void 0?{}:r;return n||o&&i}}(Tr)),Tr}var ji;function Tp(){return ji||(ji=1,function(e,t){"use client";Object.defineProperty(t,"__esModule",{value:!0});function r(A,_){for(var C in _)Object.defineProperty(A,C,{enumerable:!0,get:_[C]})}r(t,{defaultHead:function(){return p},default:function(){return b}});const n=Re,i=nt._(E),a=n._(Ip()),c=Np(),u=Eu(),l=Op(),f=_t;function p(A){A===void 0&&(A=!1);const _=[i.default.createElement("meta",{charSet:"utf-8"})];return A||_.push(i.default.createElement("meta",{name:"viewport",content:"width=device-width"})),_}function d(A,_){return typeof _=="string"||typeof _=="number"?A:_.type===i.default.Fragment?A.concat(i.default.Children.toArray(_.props.children).reduce((C,x)=>typeof x=="string"||typeof x=="number"?C:C.concat(x),[])):A.concat(_)}const m=["name","httpEquiv","charSet","itemProp"];function h(){const A=new Set,_=new Set,C=new Set,x={};return P=>{let S=!0,I=!1;if(P.key&&typeof P.key!="number"&&P.key.indexOf("$")>0){I=!0;const $=P.key.slice(P.key.indexOf("$")+1);A.has($)?S=!1:A.add($)}switch(P.type){case"title":case"base":_.has(P.type)?S=!1:_.add(P.type);break;case"meta":for(let $=0,w=m.length;$<w;$++){const N=m[$];if(P.props.hasOwnProperty(N))if(N==="charSet")C.has(N)?S=!1:C.add(N);else{const k=P.props[N],B=x[N]||new Set;(N!=="name"||!I)&&B.has(k)?S=!1:(B.add(k),x[N]=B)}}break}return S}}function y(A,_){const{inAmpMode:C}=_;return A.reduce(d,[]).reverse().concat(p(C).reverse()).filter(h()).reverse().map((x,P)=>{const S=x.key||P;if(process.env.NODE_ENV!=="development"&&process.env.__NEXT_OPTIMIZE_FONTS&&!C&&x.type==="link"&&x.props.href&&["https://fonts.googleapis.com/css","https://use.typekit.net/"].some(I=>x.props.href.startsWith(I))){const I={...x.props||{}};return I["data-href"]=I.href,I.href=void 0,I["data-optimized-fonts"]=!0,i.default.cloneElement(x,I)}if(process.env.NODE_ENV==="development")if(x.type==="script"&&x.props.type!=="application/ld+json"){const I=x.props.src?'<script> tag with src="'+x.props.src+'"':"inline <script>";(0,f.warnOnce)("Do not add <script> tags using next/head (see "+I+`). Use next/script instead.
14
- See more info here: https://nextjs.org/docs/messages/no-script-tags-in-head-component`)}else x.type==="link"&&x.props.rel==="stylesheet"&&(0,f.warnOnce)('Do not add stylesheets using next/head (see <link rel="stylesheet"> tag with href="'+x.props.href+`"). Use Document instead.
15
- See more info here: https://nextjs.org/docs/messages/no-stylesheets-in-head-component`);return i.default.cloneElement(x,{key:S})})}function g(A){let{children:_}=A;const C=(0,i.useContext)(c.AmpStateContext),x=(0,i.useContext)(u.HeadManagerContext);return i.default.createElement(a.default,{reduceComponentsToState:y,headManager:x,inAmpMode:(0,l.isInAmpMode)(C)},_)}const b=g;(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(Dt,Dt.exports)),Dt.exports}var Mr={},Pi;function Mp(){return Pi||(Pi=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"ImageConfigContext",{enumerable:!0,get:function(){return o}});const r=Re._(E),n=Yt,o=r.default.createContext(n.imageConfigDefault);process.env.NODE_ENV!=="production"&&(o.displayName="ImageConfigContext")}(Mr)),Mr}var kr={},Lr={},Dr={exports:{}};const kp=qd(Te.__viteBrowserExternal);var $r={},Br={},qr,Ii;function wu(){return Ii||(Ii=1,qr=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;t[r]=o;for(var i in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var a=Object.getOwnPropertySymbols(t);if(a.length!==1||a[0]!==r||!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var c=Object.getOwnPropertyDescriptor(t,r);if(c.value!==o||c.enumerable!==!0)return!1}return!0}),qr}var Hr,Ni;function Zt(){if(Ni)return Hr;Ni=1;var e=wu();return Hr=function(){return e()&&!!Symbol.toStringTag},Hr}var Fr,Oi;function Ru(){return Oi||(Oi=1,Fr=Object),Fr}var zr,Ti;function Lp(){return Ti||(Ti=1,zr=Error),zr}var Ur,Mi;function Dp(){return Mi||(Mi=1,Ur=EvalError),Ur}var Gr,ki;function $p(){return ki||(ki=1,Gr=RangeError),Gr}var Wr,Li;function Bp(){return Li||(Li=1,Wr=ReferenceError),Wr}var Vr,Di;function ju(){return Di||(Di=1,Vr=SyntaxError),Vr}var Kr,$i;function vt(){return $i||($i=1,Kr=TypeError),Kr}var Xr,Bi;function qp(){return Bi||(Bi=1,Xr=URIError),Xr}var Qr,qi;function Hp(){return qi||(qi=1,Qr=Math.abs),Qr}var Yr,Hi;function Fp(){return Hi||(Hi=1,Yr=Math.floor),Yr}var Zr,Fi;function zp(){return Fi||(Fi=1,Zr=Math.max),Zr}var Jr,zi;function Up(){return zi||(zi=1,Jr=Math.min),Jr}var en,Ui;function Gp(){return Ui||(Ui=1,en=Math.pow),en}var tn,Gi;function Wp(){return Gi||(Gi=1,tn=Math.round),tn}var rn,Wi;function Vp(){return Wi||(Wi=1,rn=Number.isNaN||function(t){return t!==t}),rn}var nn,Vi;function Kp(){if(Vi)return nn;Vi=1;var e=Vp();return nn=function(r){return e(r)||r===0?r:r<0?-1:1},nn}var on,Ki;function Xp(){return Ki||(Ki=1,on=Object.getOwnPropertyDescriptor),on}var sn,Xi;function st(){if(Xi)return sn;Xi=1;var e=Xp();if(e)try{e([],"length")}catch{e=null}return sn=e,sn}var an,Qi;function Jt(){if(Qi)return an;Qi=1;var e=Object.defineProperty||!1;if(e)try{e({},"a",{value:1})}catch{e=!1}return an=e,an}var cn,Yi;function Qp(){if(Yi)return cn;Yi=1;var e=typeof Symbol<"u"&&Symbol,t=wu();return cn=function(){return typeof e!="function"||typeof Symbol!="function"||typeof e("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:t()},cn}var un,Zi;function Pu(){return Zi||(Zi=1,un=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),un}var ln,Ji;function Iu(){if(Ji)return ln;Ji=1;var e=Ru();return ln=e.getPrototypeOf||null,ln}var dn,es;function Yp(){if(es)return dn;es=1;var e="Function.prototype.bind called on incompatible ",t=Object.prototype.toString,r=Math.max,n="[object Function]",o=function(u,l){for(var f=[],p=0;p<u.length;p+=1)f[p]=u[p];for(var d=0;d<l.length;d+=1)f[d+u.length]=l[d];return f},i=function(u,l){for(var f=[],p=l,d=0;p<u.length;p+=1,d+=1)f[d]=u[p];return f},a=function(c,u){for(var l="",f=0;f<c.length;f+=1)l+=c[f],f+1<c.length&&(l+=u);return l};return dn=function(u){var l=this;if(typeof l!="function"||t.apply(l)!==n)throw new TypeError(e+l);for(var f=i(arguments,1),p,d=function(){if(this instanceof p){var b=l.apply(this,o(f,arguments));return Object(b)===b?b:this}return l.apply(u,o(f,arguments))},m=r(0,l.length-f.length),h=[],y=0;y<m;y++)h[y]="$"+y;if(p=Function("binder","return function ("+a(h,",")+"){ return binder.apply(this,arguments); }")(d),l.prototype){var g=function(){};g.prototype=l.prototype,p.prototype=new g,g.prototype=null}return p},dn}var fn,ts;function bt(){if(ts)return fn;ts=1;var e=Yp();return fn=Function.prototype.bind||e,fn}var pn,rs;function Po(){return rs||(rs=1,pn=Function.prototype.call),pn}var mn,ns;function Io(){return ns||(ns=1,mn=Function.prototype.apply),mn}var hn,os;function Zp(){return os||(os=1,hn=typeof Reflect<"u"&&Reflect&&Reflect.apply),hn}var gn,is;function Nu(){if(is)return gn;is=1;var e=bt(),t=Io(),r=Po(),n=Zp();return gn=n||e.call(r,t),gn}var yn,ss;function No(){if(ss)return yn;ss=1;var e=bt(),t=vt(),r=Po(),n=Nu();return yn=function(i){if(i.length<1||typeof i[0]!="function")throw new t("a function is required");return n(e,r,i)},yn}var _n,as;function Jp(){if(as)return _n;as=1;var e=No(),t=st(),r;try{r=[].__proto__===Array.prototype}catch(a){if(!a||typeof a!="object"||!("code"in a)||a.code!=="ERR_PROTO_ACCESS")throw a}var n=!!r&&t&&t(Object.prototype,"__proto__"),o=Object,i=o.getPrototypeOf;return _n=n&&typeof n.get=="function"?e([n.get]):typeof i=="function"?function(c){return i(c==null?c:o(c))}:!1,_n}var vn,cs;function Oo(){if(cs)return vn;cs=1;var e=Pu(),t=Iu(),r=Jp();return vn=e?function(o){return e(o)}:t?function(o){if(!o||typeof o!="object"&&typeof o!="function")throw new TypeError("getProto: not an object");return t(o)}:r?function(o){return r(o)}:null,vn}var bn,us;function Ou(){if(us)return bn;us=1;var e=Function.prototype.call,t=Object.prototype.hasOwnProperty,r=bt();return bn=r.call(e,t),bn}var xn,ls;function Tu(){if(ls)return xn;ls=1;var e,t=Ru(),r=Lp(),n=Dp(),o=$p(),i=Bp(),a=ju(),c=vt(),u=qp(),l=Hp(),f=Fp(),p=zp(),d=Up(),m=Gp(),h=Wp(),y=Kp(),g=Function,b=function(J){try{return g('"use strict"; return ('+J+").constructor;")()}catch{}},A=st(),_=Jt(),C=function(){throw new c},x=A?function(){try{return arguments.callee,C}catch{try{return A(arguments,"callee").get}catch{return C}}}():C,P=Qp()(),S=Oo(),I=Iu(),$=Pu(),w=Io(),N=Po(),k={},B=typeof Uint8Array>"u"||!S?e:S(Uint8Array),R={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?e:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?e:ArrayBuffer,"%ArrayIteratorPrototype%":P&&S?S([][Symbol.iterator]()):e,"%AsyncFromSyncIteratorPrototype%":e,"%AsyncFunction%":k,"%AsyncGenerator%":k,"%AsyncGeneratorFunction%":k,"%AsyncIteratorPrototype%":k,"%Atomics%":typeof Atomics>"u"?e:Atomics,"%BigInt%":typeof BigInt>"u"?e:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?e:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?e:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?e:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":r,"%eval%":eval,"%EvalError%":n,"%Float16Array%":typeof Float16Array>"u"?e:Float16Array,"%Float32Array%":typeof Float32Array>"u"?e:Float32Array,"%Float64Array%":typeof Float64Array>"u"?e:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?e:FinalizationRegistry,"%Function%":g,"%GeneratorFunction%":k,"%Int8Array%":typeof Int8Array>"u"?e:Int8Array,"%Int16Array%":typeof Int16Array>"u"?e:Int16Array,"%Int32Array%":typeof Int32Array>"u"?e:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":P&&S?S(S([][Symbol.iterator]())):e,"%JSON%":typeof JSON=="object"?JSON:e,"%Map%":typeof Map>"u"?e:Map,"%MapIteratorPrototype%":typeof Map>"u"||!P||!S?e:S(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":t,"%Object.getOwnPropertyDescriptor%":A,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?e:Promise,"%Proxy%":typeof Proxy>"u"?e:Proxy,"%RangeError%":o,"%ReferenceError%":i,"%Reflect%":typeof Reflect>"u"?e:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?e:Set,"%SetIteratorPrototype%":typeof Set>"u"||!P||!S?e:S(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?e:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":P&&S?S(""[Symbol.iterator]()):e,"%Symbol%":P?Symbol:e,"%SyntaxError%":a,"%ThrowTypeError%":x,"%TypedArray%":B,"%TypeError%":c,"%Uint8Array%":typeof Uint8Array>"u"?e:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?e:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?e:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?e:Uint32Array,"%URIError%":u,"%WeakMap%":typeof WeakMap>"u"?e:WeakMap,"%WeakRef%":typeof WeakRef>"u"?e:WeakRef,"%WeakSet%":typeof WeakSet>"u"?e:WeakSet,"%Function.prototype.call%":N,"%Function.prototype.apply%":w,"%Object.defineProperty%":_,"%Object.getPrototypeOf%":I,"%Math.abs%":l,"%Math.floor%":f,"%Math.max%":p,"%Math.min%":d,"%Math.pow%":m,"%Math.round%":h,"%Math.sign%":y,"%Reflect.getPrototypeOf%":$};if(S)try{null.error}catch(J){var q=S(S(J));R["%Error.prototype%"]=q}var z=function J(Y){var ee;if(Y==="%AsyncFunction%")ee=b("async function () {}");else if(Y==="%GeneratorFunction%")ee=b("function* () {}");else if(Y==="%AsyncGeneratorFunction%")ee=b("async function* () {}");else if(Y==="%AsyncGenerator%"){var L=J("%AsyncGeneratorFunction%");L&&(ee=L.prototype)}else if(Y==="%AsyncIteratorPrototype%"){var O=J("%AsyncGenerator%");O&&S&&(ee=S(O.prototype))}return R[Y]=ee,ee},U={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},K=bt(),W=Ou(),F=K.call(N,Array.prototype.concat),ne=K.call(w,Array.prototype.splice),j=K.call(N,String.prototype.replace),T=K.call(N,String.prototype.slice),D=K.call(N,RegExp.prototype.exec),X=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,te=/\\(\\)?/g,Z=function(Y){var ee=T(Y,0,1),L=T(Y,-1);if(ee==="%"&&L!=="%")throw new a("invalid intrinsic syntax, expected closing `%`");if(L==="%"&&ee!=="%")throw new a("invalid intrinsic syntax, expected opening `%`");var O=[];return j(Y,X,function(re,se,ce,ue){O[O.length]=ce?j(ue,te,"$1"):se||re}),O},M=function(Y,ee){var L=Y,O;if(W(U,L)&&(O=U[L],L="%"+O[0]+"%"),W(R,L)){var re=R[L];if(re===k&&(re=z(L)),typeof re>"u"&&!ee)throw new c("intrinsic "+Y+" exists, but is not available. Please file an issue!");return{alias:O,name:L,value:re}}throw new a("intrinsic "+Y+" does not exist!")};return xn=function(Y,ee){if(typeof Y!="string"||Y.length===0)throw new c("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof ee!="boolean")throw new c('"allowMissing" argument must be a boolean');if(D(/^%?[^%]*%?$/,Y)===null)throw new a("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var L=Z(Y),O=L.length>0?L[0]:"",re=M("%"+O+"%",ee),se=re.name,ce=re.value,ue=!1,ae=re.alias;ae&&(O=ae[0],ne(L,F([0,1],ae)));for(var H=1,he=!0;H<L.length;H+=1){var ie=L[H],me=T(ie,0,1),G=T(ie,-1);if((me==='"'||me==="'"||me==="`"||G==='"'||G==="'"||G==="`")&&me!==G)throw new a("property names with quotes must have matching quotes");if((ie==="constructor"||!he)&&(ue=!0),O+="."+ie,se="%"+O+"%",W(R,se))ce=R[se];else if(ce!=null){if(!(ie in ce)){if(!ee)throw new c("base intrinsic for "+Y+" exists, but the property is not available.");return}if(A&&H+1>=L.length){var le=A(ce,ie);he=!!le,he&&"get"in le&&!("originalValue"in le.get)?ce=le.get:ce=ce[ie]}else he=W(ce,ie),ce=ce[ie];he&&!ue&&(R[se]=ce)}}return ce},xn}var Cn,ds;function xt(){if(ds)return Cn;ds=1;var e=Tu(),t=No(),r=t([e("%String.prototype.indexOf%")]);return Cn=function(o,i){var a=e(o,!!i);return typeof a=="function"&&r(o,".prototype.")>-1?t([a]):a},Cn}var Sn,fs;function em(){if(fs)return Sn;fs=1;var e=Zt()(),t=xt(),r=t("Object.prototype.toString"),n=function(c){return e&&c&&typeof c=="object"&&Symbol.toStringTag in c?!1:r(c)==="[object Arguments]"},o=function(c){return n(c)?!0:c!==null&&typeof c=="object"&&"length"in c&&typeof c.length=="number"&&c.length>=0&&r(c)!=="[object Array]"&&"callee"in c&&r(c.callee)==="[object Function]"},i=function(){return n(arguments)}();return n.isLegacyArguments=o,Sn=i?n:o,Sn}var An,ps;function tm(){if(ps)return An;ps=1;var e=xt(),t=Zt()(),r=Ou(),n=st(),o;if(t){var i=e("RegExp.prototype.exec"),a={},c=function(){throw a},u={toString:c,valueOf:c};typeof Symbol.toPrimitive=="symbol"&&(u[Symbol.toPrimitive]=c),o=function(d){if(!d||typeof d!="object")return!1;var m=n(d,"lastIndex"),h=m&&r(m,"value");if(!h)return!1;try{i(d,u)}catch(y){return y===a}}}else{var l=e("Object.prototype.toString"),f="[object RegExp]";o=function(d){return!d||typeof d!="object"&&typeof d!="function"?!1:l(d)===f}}return An=o,An}var En,ms;function rm(){if(ms)return En;ms=1;var e=xt(),t=tm(),r=e("RegExp.prototype.exec"),n=vt();return En=function(i){if(!t(i))throw new n("`regex` must be a RegExp");return function(c){return r(i,c)!==null}},En}var wn,hs;function nm(){if(hs)return wn;hs=1;var e=xt(),t=rm(),r=t(/^\s*(?:function)?\*/),n=Zt()(),o=Oo(),i=e("Object.prototype.toString"),a=e("Function.prototype.toString"),c=function(){if(!n)return!1;try{return Function("return function*() {}")()}catch{}},u;return wn=function(f){if(typeof f!="function")return!1;if(r(a(f)))return!0;if(!n){var p=i(f);return p==="[object GeneratorFunction]"}if(!o)return!1;if(typeof u>"u"){var d=c();u=d?o(d):!1}return o(f)===u},wn}var Rn,gs;function om(){if(gs)return Rn;gs=1;var e=Function.prototype.toString,t=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,r,n;if(typeof t=="function"&&typeof Object.defineProperty=="function")try{r=Object.defineProperty({},"length",{get:function(){throw n}}),n={},t(function(){throw 42},null,r)}catch(A){A!==n&&(t=null)}else t=null;var o=/^\s*class\b/,i=function(_){try{var C=e.call(_);return o.test(C)}catch{return!1}},a=function(_){try{return i(_)?!1:(e.call(_),!0)}catch{return!1}},c=Object.prototype.toString,u="[object Object]",l="[object Function]",f="[object GeneratorFunction]",p="[object HTMLAllCollection]",d="[object HTML document.all class]",m="[object HTMLCollection]",h=typeof Symbol=="function"&&!!Symbol.toStringTag,y=!(0 in[,]),g=function(){return!1};if(typeof document=="object"){var b=document.all;c.call(b)===c.call(document.all)&&(g=function(_){if((y||!_)&&(typeof _>"u"||typeof _=="object"))try{var C=c.call(_);return(C===p||C===d||C===m||C===u)&&_("")==null}catch{}return!1})}return Rn=t?function(_){if(g(_))return!0;if(!_||typeof _!="function"&&typeof _!="object")return!1;try{t(_,null,r)}catch(C){if(C!==n)return!1}return!i(_)&&a(_)}:function(_){if(g(_))return!0;if(!_||typeof _!="function"&&typeof _!="object")return!1;if(h)return a(_);if(i(_))return!1;var C=c.call(_);return C!==l&&C!==f&&!/^\[object HTML/.test(C)?!1:a(_)},Rn}var jn,ys;function im(){if(ys)return jn;ys=1;var e=om(),t=Object.prototype.toString,r=Object.prototype.hasOwnProperty,n=function(u,l,f){for(var p=0,d=u.length;p<d;p++)r.call(u,p)&&(f==null?l(u[p],p,u):l.call(f,u[p],p,u))},o=function(u,l,f){for(var p=0,d=u.length;p<d;p++)f==null?l(u.charAt(p),p,u):l.call(f,u.charAt(p),p,u)},i=function(u,l,f){for(var p in u)r.call(u,p)&&(f==null?l(u[p],p,u):l.call(f,u[p],p,u))};function a(c){return t.call(c)==="[object Array]"}return jn=function(u,l,f){if(!e(l))throw new TypeError("iterator must be a function");var p;arguments.length>=3&&(p=f),a(u)?n(u,l,p):typeof u=="string"?o(u,l,p):i(u,l,p)},jn}var Pn,_s;function sm(){return _s||(_s=1,Pn=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]),Pn}var In,vs;function am(){if(vs)return In;vs=1;var e=sm(),t=typeof globalThis>"u"?Sc:globalThis;return In=function(){for(var n=[],o=0;o<e.length;o++)typeof t[e[o]]=="function"&&(n[n.length]=e[o]);return n},In}var Nn={exports:{}},On,bs;function cm(){if(bs)return On;bs=1;var e=Jt(),t=ju(),r=vt(),n=st();return On=function(i,a,c){if(!i||typeof i!="object"&&typeof i!="function")throw new r("`obj` must be an object or a function`");if(typeof a!="string"&&typeof a!="symbol")throw new r("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new r("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new r("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new r("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new r("`loose`, if provided, must be a boolean");var u=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,f=arguments.length>5?arguments[5]:null,p=arguments.length>6?arguments[6]:!1,d=!!n&&n(i,a);if(e)e(i,a,{configurable:f===null&&d?d.configurable:!f,enumerable:u===null&&d?d.enumerable:!u,value:c,writable:l===null&&d?d.writable:!l});else if(p||!u&&!l&&!f)i[a]=c;else throw new t("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},On}var Tn,xs;function um(){if(xs)return Tn;xs=1;var e=Jt(),t=function(){return!!e};return t.hasArrayLengthDefineBug=function(){if(!e)return null;try{return e([],"length",{value:1}).length!==1}catch{return!0}},Tn=t,Tn}var Mn,Cs;function lm(){if(Cs)return Mn;Cs=1;var e=Tu(),t=cm(),r=um()(),n=st(),o=vt(),i=e("%Math.floor%");return Mn=function(c,u){if(typeof c!="function")throw new o("`fn` is not a function");if(typeof u!="number"||u<0||u>4294967295||i(u)!==u)throw new o("`length` must be a positive 32-bit integer");var l=arguments.length>2&&!!arguments[2],f=!0,p=!0;if("length"in c&&n){var d=n(c,"length");d&&!d.configurable&&(f=!1),d&&!d.writable&&(p=!1)}return(f||p||!l)&&(r?t(c,"length",u,!0,!0):t(c,"length",u)),c},Mn}var kn,Ss;function dm(){if(Ss)return kn;Ss=1;var e=bt(),t=Io(),r=Nu();return kn=function(){return r(e,t,arguments)},kn}var As;function fm(){return As||(As=1,function(e){var t=lm(),r=Jt(),n=No(),o=dm();e.exports=function(a){var c=n(arguments),u=a.length-(arguments.length-1);return t(c,1+(u>0?u:0),!0)},r?r(e.exports,"apply",{value:o}):e.exports.apply=o}(Nn)),Nn.exports}var Ln,Es;function Mu(){if(Es)return Ln;Es=1;var e=im(),t=am(),r=fm(),n=xt(),o=st(),i=Oo(),a=n("Object.prototype.toString"),c=Zt()(),u=typeof globalThis>"u"?Sc:globalThis,l=t(),f=n("String.prototype.slice"),p=n("Array.prototype.indexOf",!0)||function(g,b){for(var A=0;A<g.length;A+=1)if(g[A]===b)return A;return-1},d={__proto__:null};c&&o&&i?e(l,function(y){var g=new u[y];if(Symbol.toStringTag in g&&i){var b=i(g),A=o(b,Symbol.toStringTag);if(!A&&b){var _=i(b);A=o(_,Symbol.toStringTag)}d["$"+y]=r(A.get)}}):e(l,function(y){var g=new u[y],b=g.slice||g.set;b&&(d["$"+y]=r(b))});var m=function(g){var b=!1;return e(d,function(A,_){if(!b)try{"$"+A(g)===_&&(b=f(_,1))}catch{}}),b},h=function(g){var b=!1;return e(d,function(A,_){if(!b)try{A(g),b=f(_,1)}catch{}}),b};return Ln=function(g){if(!g||typeof g!="object")return!1;if(!c){var b=f(a(g),8,-1);return p(l,b)>-1?b:b!=="Object"?!1:h(g)}return o?m(g):null},Ln}var Dn,ws;function pm(){if(ws)return Dn;ws=1;var e=Mu();return Dn=function(r){return!!e(r)},Dn}var Rs;function mm(){return Rs||(Rs=1,function(e){var t=em(),r=nm(),n=Mu(),o=pm();function i(H){return H.call.bind(H)}var a=typeof BigInt<"u",c=typeof Symbol<"u",u=i(Object.prototype.toString),l=i(Number.prototype.valueOf),f=i(String.prototype.valueOf),p=i(Boolean.prototype.valueOf);if(a)var d=i(BigInt.prototype.valueOf);if(c)var m=i(Symbol.prototype.valueOf);function h(H,he){if(typeof H!="object")return!1;try{return he(H),!0}catch{return!1}}e.isArgumentsObject=t,e.isGeneratorFunction=r,e.isTypedArray=o;function y(H){return typeof Promise<"u"&&H instanceof Promise||H!==null&&typeof H=="object"&&typeof H.then=="function"&&typeof H.catch=="function"}e.isPromise=y;function g(H){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(H):o(H)||T(H)}e.isArrayBufferView=g;function b(H){return n(H)==="Uint8Array"}e.isUint8Array=b;function A(H){return n(H)==="Uint8ClampedArray"}e.isUint8ClampedArray=A;function _(H){return n(H)==="Uint16Array"}e.isUint16Array=_;function C(H){return n(H)==="Uint32Array"}e.isUint32Array=C;function x(H){return n(H)==="Int8Array"}e.isInt8Array=x;function P(H){return n(H)==="Int16Array"}e.isInt16Array=P;function S(H){return n(H)==="Int32Array"}e.isInt32Array=S;function I(H){return n(H)==="Float32Array"}e.isFloat32Array=I;function $(H){return n(H)==="Float64Array"}e.isFloat64Array=$;function w(H){return n(H)==="BigInt64Array"}e.isBigInt64Array=w;function N(H){return n(H)==="BigUint64Array"}e.isBigUint64Array=N;function k(H){return u(H)==="[object Map]"}k.working=typeof Map<"u"&&k(new Map);function B(H){return typeof Map>"u"?!1:k.working?k(H):H instanceof Map}e.isMap=B;function R(H){return u(H)==="[object Set]"}R.working=typeof Set<"u"&&R(new Set);function q(H){return typeof Set>"u"?!1:R.working?R(H):H instanceof Set}e.isSet=q;function z(H){return u(H)==="[object WeakMap]"}z.working=typeof WeakMap<"u"&&z(new WeakMap);function U(H){return typeof WeakMap>"u"?!1:z.working?z(H):H instanceof WeakMap}e.isWeakMap=U;function K(H){return u(H)==="[object WeakSet]"}K.working=typeof WeakSet<"u"&&K(new WeakSet);function W(H){return K(H)}e.isWeakSet=W;function F(H){return u(H)==="[object ArrayBuffer]"}F.working=typeof ArrayBuffer<"u"&&F(new ArrayBuffer);function ne(H){return typeof ArrayBuffer>"u"?!1:F.working?F(H):H instanceof ArrayBuffer}e.isArrayBuffer=ne;function j(H){return u(H)==="[object DataView]"}j.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&j(new DataView(new ArrayBuffer(1),0,1));function T(H){return typeof DataView>"u"?!1:j.working?j(H):H instanceof DataView}e.isDataView=T;var D=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function X(H){return u(H)==="[object SharedArrayBuffer]"}function te(H){return typeof D>"u"?!1:(typeof X.working>"u"&&(X.working=X(new D)),X.working?X(H):H instanceof D)}e.isSharedArrayBuffer=te;function Z(H){return u(H)==="[object AsyncFunction]"}e.isAsyncFunction=Z;function M(H){return u(H)==="[object Map Iterator]"}e.isMapIterator=M;function J(H){return u(H)==="[object Set Iterator]"}e.isSetIterator=J;function Y(H){return u(H)==="[object Generator]"}e.isGeneratorObject=Y;function ee(H){return u(H)==="[object WebAssembly.Module]"}e.isWebAssemblyCompiledModule=ee;function L(H){return h(H,l)}e.isNumberObject=L;function O(H){return h(H,f)}e.isStringObject=O;function re(H){return h(H,p)}e.isBooleanObject=re;function se(H){return a&&h(H,d)}e.isBigIntObject=se;function ce(H){return c&&h(H,m)}e.isSymbolObject=ce;function ue(H){return L(H)||O(H)||re(H)||se(H)||ce(H)}e.isBoxedPrimitive=ue;function ae(H){return typeof Uint8Array<"u"&&(ne(H)||te(H))}e.isAnyArrayBuffer=ae,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(H){Object.defineProperty(e,H,{enumerable:!1,value:function(){throw new Error(H+" is not supported in userland")}})})}(Br)),Br}var $n,js;function hm(){return js||(js=1,$n=function(t){return t&&typeof t=="object"&&typeof t.copy=="function"&&typeof t.fill=="function"&&typeof t.readUInt8=="function"}),$n}var $t={exports:{}},Ps;function gm(){return Ps||(Ps=1,typeof Object.create=="function"?$t.exports=function(t,r){r&&(t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:$t.exports=function(t,r){if(r){t.super_=r;var n=function(){};n.prototype=r.prototype,t.prototype=new n,t.prototype.constructor=t}}),$t.exports}var Is;function ym(){return Is||(Is=1,function(e){var t=Object.getOwnPropertyDescriptors||function(T){for(var D=Object.keys(T),X={},te=0;te<D.length;te++)X[D[te]]=Object.getOwnPropertyDescriptor(T,D[te]);return X},r=/%[sdj%]/g;e.format=function(j){if(!x(j)){for(var T=[],D=0;D<arguments.length;D++)T.push(a(arguments[D]));return T.join(" ")}for(var D=1,X=arguments,te=X.length,Z=String(j).replace(r,function(J){if(J==="%%")return"%";if(D>=te)return J;switch(J){case"%s":return String(X[D++]);case"%d":return Number(X[D++]);case"%j":try{return JSON.stringify(X[D++])}catch{return"[Circular]"}default:return J}}),M=X[D];D<te;M=X[++D])A(M)||!$(M)?Z+=" "+M:Z+=" "+a(M);return Z},e.deprecate=function(j,T){if(typeof process<"u"&&process.noDeprecation===!0)return j;if(typeof process>"u")return function(){return e.deprecate(j,T).apply(this,arguments)};var D=!1;function X(){if(!D){if(process.throwDeprecation)throw new Error(T);process.traceDeprecation?console.trace(T):console.error(T),D=!0}return j.apply(this,arguments)}return X};var n={},o=/^$/;if(process.env.NODE_DEBUG){var i=process.env.NODE_DEBUG;i=i.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),o=new RegExp("^"+i+"$","i")}e.debuglog=function(j){if(j=j.toUpperCase(),!n[j])if(o.test(j)){var T=process.pid;n[j]=function(){var D=e.format.apply(e,arguments);console.error("%s %d: %s",j,T,D)}}else n[j]=function(){};return n[j]};function a(j,T){var D={seen:[],stylize:u};return arguments.length>=3&&(D.depth=arguments[2]),arguments.length>=4&&(D.colors=arguments[3]),b(T)?D.showHidden=T:T&&e._extend(D,T),S(D.showHidden)&&(D.showHidden=!1),S(D.depth)&&(D.depth=2),S(D.colors)&&(D.colors=!1),S(D.customInspect)&&(D.customInspect=!0),D.colors&&(D.stylize=c),f(D,j,D.depth)}e.inspect=a,a.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},a.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function c(j,T){var D=a.styles[T];return D?"\x1B["+a.colors[D][0]+"m"+j+"\x1B["+a.colors[D][1]+"m":j}function u(j,T){return j}function l(j){var T={};return j.forEach(function(D,X){T[D]=!0}),T}function f(j,T,D){if(j.customInspect&&T&&k(T.inspect)&&T.inspect!==e.inspect&&!(T.constructor&&T.constructor.prototype===T)){var X=T.inspect(D,j);return x(X)||(X=f(j,X,D)),X}var te=p(j,T);if(te)return te;var Z=Object.keys(T),M=l(Z);if(j.showHidden&&(Z=Object.getOwnPropertyNames(T)),N(T)&&(Z.indexOf("message")>=0||Z.indexOf("description")>=0))return d(T);if(Z.length===0){if(k(T)){var J=T.name?": "+T.name:"";return j.stylize("[Function"+J+"]","special")}if(I(T))return j.stylize(RegExp.prototype.toString.call(T),"regexp");if(w(T))return j.stylize(Date.prototype.toString.call(T),"date");if(N(T))return d(T)}var Y="",ee=!1,L=["{","}"];if(g(T)&&(ee=!0,L=["[","]"]),k(T)){var O=T.name?": "+T.name:"";Y=" [Function"+O+"]"}if(I(T)&&(Y=" "+RegExp.prototype.toString.call(T)),w(T)&&(Y=" "+Date.prototype.toUTCString.call(T)),N(T)&&(Y=" "+d(T)),Z.length===0&&(!ee||T.length==0))return L[0]+Y+L[1];if(D<0)return I(T)?j.stylize(RegExp.prototype.toString.call(T),"regexp"):j.stylize("[Object]","special");j.seen.push(T);var re;return ee?re=m(j,T,D,M,Z):re=Z.map(function(se){return h(j,T,D,M,se,ee)}),j.seen.pop(),y(re,Y,L)}function p(j,T){if(S(T))return j.stylize("undefined","undefined");if(x(T)){var D="'"+JSON.stringify(T).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return j.stylize(D,"string")}if(C(T))return j.stylize(""+T,"number");if(b(T))return j.stylize(""+T,"boolean");if(A(T))return j.stylize("null","null")}function d(j){return"["+Error.prototype.toString.call(j)+"]"}function m(j,T,D,X,te){for(var Z=[],M=0,J=T.length;M<J;++M)K(T,String(M))?Z.push(h(j,T,D,X,String(M),!0)):Z.push("");return te.forEach(function(Y){Y.match(/^\d+$/)||Z.push(h(j,T,D,X,Y,!0))}),Z}function h(j,T,D,X,te,Z){var M,J,Y;if(Y=Object.getOwnPropertyDescriptor(T,te)||{value:T[te]},Y.get?Y.set?J=j.stylize("[Getter/Setter]","special"):J=j.stylize("[Getter]","special"):Y.set&&(J=j.stylize("[Setter]","special")),K(X,te)||(M="["+te+"]"),J||(j.seen.indexOf(Y.value)<0?(A(D)?J=f(j,Y.value,null):J=f(j,Y.value,D-1),J.indexOf(`
16
- `)>-1&&(Z?J=J.split(`
17
- `).map(function(ee){return" "+ee}).join(`
18
- `).slice(2):J=`
19
- `+J.split(`
20
- `).map(function(ee){return" "+ee}).join(`
21
- `))):J=j.stylize("[Circular]","special")),S(M)){if(Z&&te.match(/^\d+$/))return J;M=JSON.stringify(""+te),M.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(M=M.slice(1,-1),M=j.stylize(M,"name")):(M=M.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),M=j.stylize(M,"string"))}return M+": "+J}function y(j,T,D){var X=j.reduce(function(te,Z){return Z.indexOf(`
22
- `)>=0,te+Z.replace(/\u001b\[\d\d?m/g,"").length+1},0);return X>60?D[0]+(T===""?"":T+`
23
- `)+" "+j.join(`,
24
- `)+" "+D[1]:D[0]+T+" "+j.join(", ")+" "+D[1]}e.types=mm();function g(j){return Array.isArray(j)}e.isArray=g;function b(j){return typeof j=="boolean"}e.isBoolean=b;function A(j){return j===null}e.isNull=A;function _(j){return j==null}e.isNullOrUndefined=_;function C(j){return typeof j=="number"}e.isNumber=C;function x(j){return typeof j=="string"}e.isString=x;function P(j){return typeof j=="symbol"}e.isSymbol=P;function S(j){return j===void 0}e.isUndefined=S;function I(j){return $(j)&&R(j)==="[object RegExp]"}e.isRegExp=I,e.types.isRegExp=I;function $(j){return typeof j=="object"&&j!==null}e.isObject=$;function w(j){return $(j)&&R(j)==="[object Date]"}e.isDate=w,e.types.isDate=w;function N(j){return $(j)&&(R(j)==="[object Error]"||j instanceof Error)}e.isError=N,e.types.isNativeError=N;function k(j){return typeof j=="function"}e.isFunction=k;function B(j){return j===null||typeof j=="boolean"||typeof j=="number"||typeof j=="string"||typeof j=="symbol"||typeof j>"u"}e.isPrimitive=B,e.isBuffer=hm();function R(j){return Object.prototype.toString.call(j)}function q(j){return j<10?"0"+j.toString(10):j.toString(10)}var z=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function U(){var j=new Date,T=[q(j.getHours()),q(j.getMinutes()),q(j.getSeconds())].join(":");return[j.getDate(),z[j.getMonth()],T].join(" ")}e.log=function(){console.log("%s - %s",U(),e.format.apply(e,arguments))},e.inherits=gm(),e._extend=function(j,T){if(!T||!$(T))return j;for(var D=Object.keys(T),X=D.length;X--;)j[D[X]]=T[D[X]];return j};function K(j,T){return Object.prototype.hasOwnProperty.call(j,T)}var W=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;e.promisify=function(T){if(typeof T!="function")throw new TypeError('The "original" argument must be of type Function');if(W&&T[W]){var D=T[W];if(typeof D!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(D,W,{value:D,enumerable:!1,writable:!1,configurable:!0}),D}function D(){for(var X,te,Z=new Promise(function(Y,ee){X=Y,te=ee}),M=[],J=0;J<arguments.length;J++)M.push(arguments[J]);M.push(function(Y,ee){Y?te(Y):X(ee)});try{T.apply(this,M)}catch(Y){te(Y)}return Z}return Object.setPrototypeOf(D,Object.getPrototypeOf(T)),W&&Object.defineProperty(D,W,{value:D,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(D,t(T))},e.promisify.custom=W;function F(j,T){if(!j){var D=new Error("Promise was rejected with a falsy value");D.reason=j,j=D}return T(j)}function ne(j){if(typeof j!="function")throw new TypeError('The "original" argument must be of type Function');function T(){for(var D=[],X=0;X<arguments.length;X++)D.push(arguments[X]);var te=D.pop();if(typeof te!="function")throw new TypeError("The last argument must be of type Function");var Z=this,M=function(){return te.apply(Z,arguments)};j.apply(this,D).then(function(J){process.nextTick(M.bind(null,null,J))},function(J){process.nextTick(F.bind(null,J,M))})}return Object.setPrototypeOf(T,Object.getPrototypeOf(j)),Object.defineProperties(T,t(j)),T}e.callbackify=ne}($r)),$r}var Ns;function _m(){return Ns||(Ns=1,(()=>{var e={333:(o,i,a)=>{const c=a(137),u=a(179),l=a(13),f=a(719),p=(d,m={})=>{let h=[];if(Array.isArray(d))for(let y of d){let g=p.create(y,m);Array.isArray(g)?h.push(...g):h.push(g)}else h=[].concat(p.create(d,m));return m&&m.expand===!0&&m.nodupes===!0&&(h=[...new Set(h)]),h};p.parse=(d,m={})=>f(d,m),p.stringify=(d,m={})=>c(typeof d=="string"?p.parse(d,m):d,m),p.compile=(d,m={})=>(typeof d=="string"&&(d=p.parse(d,m)),u(d,m)),p.expand=(d,m={})=>{typeof d=="string"&&(d=p.parse(d,m));let h=l(d,m);return m.noempty===!0&&(h=h.filter(Boolean)),m.nodupes===!0&&(h=[...new Set(h)]),h},p.create=(d,m={})=>d===""||d.length<3?[d]:m.expand!==!0?p.compile(d,m):p.expand(d,m),o.exports=p},179:(o,i,a)=>{const c=a(783),u=a(617),l=(f,p={})=>{let d=(m,h={})=>{let y=u.isInvalidBrace(h),g=m.invalid===!0&&p.escapeInvalid===!0,b=y===!0||g===!0,A=p.escapeInvalid===!0?"\\":"",_="";if(m.isOpen===!0||m.isClose===!0)return A+m.value;if(m.type==="open")return b?A+m.value:"(";if(m.type==="close")return b?A+m.value:")";if(m.type==="comma")return m.prev.type==="comma"?"":b?m.value:"|";if(m.value)return m.value;if(m.nodes&&m.ranges>0){let C=u.reduce(m.nodes),x=c(...C,{...p,wrap:!1,toRegex:!0});if(x.length!==0)return C.length>1&&x.length>1?`(${x})`:x}if(m.nodes)for(let C of m.nodes)_+=d(C,m);return _};return d(f)};o.exports=l},457:o=>{o.exports={MAX_LENGTH:65536,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:`
25
- `,CHAR_NO_BREAK_SPACE:" ",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}},13:(o,i,a)=>{const c=a(783),u=a(137),l=a(617),f=(d="",m="",h=!1)=>{let y=[];if(d=[].concat(d),m=[].concat(m),!m.length)return d;if(!d.length)return h?l.flatten(m).map(g=>`{${g}}`):m;for(let g of d)if(Array.isArray(g))for(let b of g)y.push(f(b,m,h));else for(let b of m)h===!0&&typeof b=="string"&&(b=`{${b}}`),y.push(Array.isArray(b)?f(g,b,h):g+b);return l.flatten(y)},p=(d,m={})=>{let h=m.rangeLimit===void 0?1e3:m.rangeLimit,y=(g,b={})=>{g.queue=[];let A=b,_=b.queue;for(;A.type!=="brace"&&A.type!=="root"&&A.parent;)A=A.parent,_=A.queue;if(g.invalid||g.dollar){_.push(f(_.pop(),u(g,m)));return}if(g.type==="brace"&&g.invalid!==!0&&g.nodes.length===2){_.push(f(_.pop(),["{}"]));return}if(g.nodes&&g.ranges>0){let S=l.reduce(g.nodes);if(l.exceedsLimit(...S,m.step,h))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let I=c(...S,m);I.length===0&&(I=u(g,m)),_.push(f(_.pop(),I)),g.nodes=[];return}let C=l.encloseBrace(g),x=g.queue,P=g;for(;P.type!=="brace"&&P.type!=="root"&&P.parent;)P=P.parent,x=P.queue;for(let S=0;S<g.nodes.length;S++){let I=g.nodes[S];if(I.type==="comma"&&g.type==="brace"){S===1&&x.push(""),x.push("");continue}if(I.type==="close"){_.push(f(_.pop(),x,C));continue}if(I.value&&I.type!=="open"){x.push(f(x.pop(),I.value));continue}I.nodes&&y(I,g)}return x};return l.flatten(y(d))};o.exports=p},719:(o,i,a)=>{const c=a(137),{MAX_LENGTH:u,CHAR_BACKSLASH:l,CHAR_BACKTICK:f,CHAR_COMMA:p,CHAR_DOT:d,CHAR_LEFT_PARENTHESES:m,CHAR_RIGHT_PARENTHESES:h,CHAR_LEFT_CURLY_BRACE:y,CHAR_RIGHT_CURLY_BRACE:g,CHAR_LEFT_SQUARE_BRACKET:b,CHAR_RIGHT_SQUARE_BRACKET:A,CHAR_DOUBLE_QUOTE:_,CHAR_SINGLE_QUOTE:C,CHAR_NO_BREAK_SPACE:x,CHAR_ZERO_WIDTH_NOBREAK_SPACE:P}=a(457),S=(I,$={})=>{if(typeof I!="string")throw new TypeError("Expected a string");let w=$||{},N=typeof w.maxLength=="number"?Math.min(u,w.maxLength):u;if(I.length>N)throw new SyntaxError(`Input length (${I.length}), exceeds max characters (${N})`);let k={type:"root",input:I,nodes:[]},B=[k],R=k,q=k,z=0,U=I.length,K=0,W=0,F;const ne=()=>I[K++],j=T=>{if(T.type==="text"&&q.type==="dot"&&(q.type="text"),q&&q.type==="text"&&T.type==="text"){q.value+=T.value;return}return R.nodes.push(T),T.parent=R,T.prev=q,q=T,T};for(j({type:"bos"});K<U;)if(R=B[B.length-1],F=ne(),!(F===P||F===x)){if(F===l){j({type:"text",value:($.keepEscaping?F:"")+ne()});continue}if(F===A){j({type:"text",value:"\\"+F});continue}if(F===b){z++;let T;for(;K<U&&(T=ne());){if(F+=T,T===b){z++;continue}if(T===l){F+=ne();continue}if(T===A&&(z--,z===0))break}j({type:"text",value:F});continue}if(F===m){R=j({type:"paren",nodes:[]}),B.push(R),j({type:"text",value:F});continue}if(F===h){if(R.type!=="paren"){j({type:"text",value:F});continue}R=B.pop(),j({type:"text",value:F}),R=B[B.length-1];continue}if(F===_||F===C||F===f){let T=F,D;for($.keepQuotes!==!0&&(F="");K<U&&(D=ne());){if(D===l){F+=D+ne();continue}if(D===T){$.keepQuotes===!0&&(F+=D);break}F+=D}j({type:"text",value:F});continue}if(F===y){W++;let D={type:"brace",open:!0,close:!1,dollar:q.value&&q.value.slice(-1)==="$"||R.dollar===!0,depth:W,commas:0,ranges:0,nodes:[]};R=j(D),B.push(R),j({type:"open",value:F});continue}if(F===g){if(R.type!=="brace"){j({type:"text",value:F});continue}let T="close";R=B.pop(),R.close=!0,j({type:T,value:F}),W--,R=B[B.length-1];continue}if(F===p&&W>0){if(R.ranges>0){R.ranges=0;let T=R.nodes.shift();R.nodes=[T,{type:"text",value:c(R)}]}j({type:"comma",value:F}),R.commas++;continue}if(F===d&&W>0&&R.commas===0){let T=R.nodes;if(W===0||T.length===0){j({type:"text",value:F});continue}if(q.type==="dot"){if(R.range=[],q.value+=F,q.type="range",R.nodes.length!==3&&R.nodes.length!==5){R.invalid=!0,R.ranges=0,q.type="text";continue}R.ranges++,R.args=[];continue}if(q.type==="range"){T.pop();let D=T[T.length-1];D.value+=q.value+F,q=D,R.ranges--;continue}j({type:"dot",value:F});continue}j({type:"text",value:F})}do if(R=B.pop(),R.type!=="root"){R.nodes.forEach(X=>{X.nodes||(X.type==="open"&&(X.isOpen=!0),X.type==="close"&&(X.isClose=!0),X.nodes||(X.type="text"),X.invalid=!0)});let T=B[B.length-1],D=T.nodes.indexOf(R);T.nodes.splice(D,1,...R.nodes)}while(B.length>0);return j({type:"eos"}),k};o.exports=S},137:(o,i,a)=>{const c=a(617);o.exports=(u,l={})=>{let f=(p,d={})=>{let m=l.escapeInvalid&&c.isInvalidBrace(d),h=p.invalid===!0&&l.escapeInvalid===!0,y="";if(p.value)return(m||h)&&c.isOpenOrClose(p)?"\\"+p.value:p.value;if(p.value)return p.value;if(p.nodes)for(let g of p.nodes)y+=f(g);return y};return f(u)}},617:(o,i)=>{i.isInteger=a=>typeof a=="number"?Number.isInteger(a):typeof a=="string"&&a.trim()!==""?Number.isInteger(Number(a)):!1,i.find=(a,c)=>a.nodes.find(u=>u.type===c),i.exceedsLimit=(a,c,u=1,l)=>l===!1||!i.isInteger(a)||!i.isInteger(c)?!1:(Number(c)-Number(a))/Number(u)>=l,i.escapeNode=(a,c=0,u)=>{let l=a.nodes[c];l&&(u&&l.type===u||l.type==="open"||l.type==="close")&&l.escaped!==!0&&(l.value="\\"+l.value,l.escaped=!0)},i.encloseBrace=a=>a.type!=="brace"||a.commas>>0+a.ranges>>0?!1:(a.invalid=!0,!0),i.isInvalidBrace=a=>a.type!=="brace"?!1:a.invalid===!0||a.dollar?!0:!(a.commas>>0+a.ranges>>0)||a.open!==!0||a.close!==!0?(a.invalid=!0,!0):!1,i.isOpenOrClose=a=>a.type==="open"||a.type==="close"?!0:a.open===!0||a.close===!0,i.reduce=a=>a.reduce((c,u)=>(u.type==="text"&&c.push(u.value),u.type==="range"&&(u.type="text"),c),[]),i.flatten=(...a)=>{const c=[],u=l=>{for(let f=0;f<l.length;f++){let p=l[f];Array.isArray(p)?u(p):p!==void 0&&c.push(p)}return c};return u(a),c}},783:(o,i,a)=>{/*!
26
- * fill-range <https://github.com/jonschlinkert/fill-range>
27
- *
28
- * Copyright (c) 2014-present, Jon Schlinkert.
29
- * Licensed under the MIT License.
30
- */const c=a(837),u=a(492),l=w=>w!==null&&typeof w=="object"&&!Array.isArray(w),f=w=>N=>w===!0?Number(N):String(N),p=w=>typeof w=="number"||typeof w=="string"&&w!=="",d=w=>Number.isInteger(+w),m=w=>{let N=`${w}`,k=-1;if(N[0]==="-"&&(N=N.slice(1)),N==="0")return!1;for(;N[++k]==="0";);return k>0},h=(w,N,k)=>typeof w=="string"||typeof N=="string"?!0:k.stringify===!0,y=(w,N,k)=>{if(N>0){let B=w[0]==="-"?"-":"";B&&(w=w.slice(1)),w=B+w.padStart(B?N-1:N,"0")}return k===!1?String(w):w},g=(w,N)=>{let k=w[0]==="-"?"-":"";for(k&&(w=w.slice(1),N--);w.length<N;)w="0"+w;return k?"-"+w:w},b=(w,N)=>{w.negatives.sort((z,U)=>z<U?-1:z>U?1:0),w.positives.sort((z,U)=>z<U?-1:z>U?1:0);let k=N.capture?"":"?:",B="",R="",q;return w.positives.length&&(B=w.positives.join("|")),w.negatives.length&&(R=`-(${k}${w.negatives.join("|")})`),B&&R?q=`${B}|${R}`:q=B||R,N.wrap?`(${k}${q})`:q},A=(w,N,k,B)=>{if(k)return u(w,N,{wrap:!1,...B});let R=String.fromCharCode(w);if(w===N)return R;let q=String.fromCharCode(N);return`[${R}-${q}]`},_=(w,N,k)=>{if(Array.isArray(w)){let B=k.wrap===!0,R=k.capture?"":"?:";return B?`(${R}${w.join("|")})`:w.join("|")}return u(w,N,k)},C=(...w)=>new RangeError("Invalid range arguments: "+c.inspect(...w)),x=(w,N,k)=>{if(k.strictRanges===!0)throw C([w,N]);return[]},P=(w,N)=>{if(N.strictRanges===!0)throw new TypeError(`Expected step "${w}" to be a number`);return[]},S=(w,N,k=1,B={})=>{let R=Number(w),q=Number(N);if(!Number.isInteger(R)||!Number.isInteger(q)){if(B.strictRanges===!0)throw C([w,N]);return[]}R===0&&(R=0),q===0&&(q=0);let z=R>q,U=String(w),K=String(N),W=String(k);k=Math.max(Math.abs(k),1);let F=m(U)||m(K)||m(W),ne=F?Math.max(U.length,K.length,W.length):0,j=F===!1&&h(w,N,B)===!1,T=B.transform||f(j);if(B.toRegex&&k===1)return A(g(w,ne),g(N,ne),!0,B);let D={negatives:[],positives:[]},X=M=>D[M<0?"negatives":"positives"].push(Math.abs(M)),te=[],Z=0;for(;z?R>=q:R<=q;)B.toRegex===!0&&k>1?X(R):te.push(y(T(R,Z),ne,j)),R=z?R-k:R+k,Z++;return B.toRegex===!0?k>1?b(D,B):_(te,null,{wrap:!1,...B}):te},I=(w,N,k=1,B={})=>{if(!d(w)&&w.length>1||!d(N)&&N.length>1)return x(w,N,B);let R=B.transform||(j=>String.fromCharCode(j)),q=`${w}`.charCodeAt(0),z=`${N}`.charCodeAt(0),U=q>z,K=Math.min(q,z),W=Math.max(q,z);if(B.toRegex&&k===1)return A(K,W,!1,B);let F=[],ne=0;for(;U?q>=z:q<=z;)F.push(R(q,ne)),q=U?q-k:q+k,ne++;return B.toRegex===!0?_(F,null,{wrap:!1,options:B}):F},$=(w,N,k,B={})=>{if(N==null&&p(w))return[w];if(!p(w)||!p(N))return x(w,N,B);if(typeof k=="function")return $(w,N,1,{transform:k});if(l(k))return $(w,N,0,k);let R={...B};return R.capture===!0&&(R.wrap=!0),k=k||R.step||1,d(k)?d(w)&&d(N)?S(w,N,k,R):I(w,N,Math.max(Math.abs(k),1),R):k!=null&&!l(k)?P(k,R):$(w,N,1,k)};o.exports=$},357:o=>{/*!
31
- * is-number <https://github.com/jonschlinkert/is-number>
32
- *
33
- * Copyright (c) 2014-present, Jon Schlinkert.
34
- * Released under the MIT License.
35
- */o.exports=function(i){return typeof i=="number"?i-i===0:typeof i=="string"&&i.trim()!==""?Number.isFinite?Number.isFinite(+i):isFinite(+i):!1}},971:(o,i,a)=>{const c=a(837),u=a(333),l=a(251),f=a(513),p=m=>m===""||m==="./",d=(m,h,y)=>{h=[].concat(h),m=[].concat(m);let g=new Set,b=new Set,A=new Set,_=0,C=S=>{A.add(S.output),y&&y.onResult&&y.onResult(S)};for(let S=0;S<h.length;S++){let I=l(String(h[S]),{...y,onResult:C},!0),$=I.state.negated||I.state.negatedExtglob;$&&_++;for(let w of m){let N=I(w,!0);($?!N.isMatch:N.isMatch)&&($?g.add(N.output):(g.delete(N.output),b.add(N.output)))}}let P=(_===h.length?[...A]:[...b]).filter(S=>!g.has(S));if(y&&P.length===0){if(y.failglob===!0)throw new Error(`No matches found for "${h.join(", ")}"`);if(y.nonull===!0||y.nullglob===!0)return y.unescape?h.map(S=>S.replace(/\\/g,"")):h}return P};d.match=d,d.matcher=(m,h)=>l(m,h),d.isMatch=(m,h,y)=>l(h,y)(m),d.any=d.isMatch,d.not=(m,h,y={})=>{h=[].concat(h).map(String);let g=new Set,b=[],_=d(m,h,{...y,onResult:C=>{y.onResult&&y.onResult(C),b.push(C.output)}});for(let C of b)_.includes(C)||g.add(C);return[...g]},d.contains=(m,h,y)=>{if(typeof m!="string")throw new TypeError(`Expected a string: "${c.inspect(m)}"`);if(Array.isArray(h))return h.some(g=>d.contains(m,g,y));if(typeof h=="string"){if(p(m)||p(h))return!1;if(m.includes(h)||m.startsWith("./")&&m.slice(2).includes(h))return!0}return d.isMatch(m,h,{...y,contains:!0})},d.matchKeys=(m,h,y)=>{if(!f.isObject(m))throw new TypeError("Expected the first argument to be an object");let g=d(Object.keys(m),h,y),b={};for(let A of g)b[A]=m[A];return b},d.some=(m,h,y)=>{let g=[].concat(m);for(let b of[].concat(h)){let A=l(String(b),y);if(g.some(_=>A(_)))return!0}return!1},d.every=(m,h,y)=>{let g=[].concat(m);for(let b of[].concat(h)){let A=l(String(b),y);if(!g.every(_=>A(_)))return!1}return!0},d.all=(m,h,y)=>{if(typeof m!="string")throw new TypeError(`Expected a string: "${c.inspect(m)}"`);return[].concat(h).every(g=>l(g,y)(m))},d.capture=(m,h,y)=>{let g=f.isWindows(y),A=l.makeRe(String(m),{...y,capture:!0}).exec(g?f.toPosixSlashes(h):h);if(A)return A.slice(1).map(_=>_===void 0?"":_)},d.makeRe=(...m)=>l.makeRe(...m),d.scan=(...m)=>l.scan(...m),d.parse=(m,h)=>{let y=[];for(let g of[].concat(m||[]))for(let b of u(String(g),h))y.push(l.parse(b,h));return y},d.braces=(m,h)=>{if(typeof m!="string")throw new TypeError("Expected a string");return h&&h.nobrace===!0||!/\{.*\}/.test(m)?[m]:u(m,h)},d.braceExpand=(m,h)=>{if(typeof m!="string")throw new TypeError("Expected a string");return d.braces(m,{...h,expand:!0})},o.exports=d},251:(o,i,a)=>{o.exports=a(683)},356:(o,i,a)=>{const c=a(17),u="\\\\/",l=`[^${u}]`,f="\\.",p="\\+",d="\\?",m="\\/",h="(?=.)",y="[^/]",g=`(?:${m}|$)`,b=`(?:^|${m})`,A=`${f}{1,2}${g}`,_=`(?!${f})`,C=`(?!${b}${A})`,x=`(?!${f}{0,1}${g})`,P=`(?!${A})`,S=`[^.${m}]`,I=`${y}*?`,$={DOT_LITERAL:f,PLUS_LITERAL:p,QMARK_LITERAL:d,SLASH_LITERAL:m,ONE_CHAR:h,QMARK:y,END_ANCHOR:g,DOTS_SLASH:A,NO_DOT:_,NO_DOTS:C,NO_DOT_SLASH:x,NO_DOTS_SLASH:P,QMARK_NO_DOT:S,STAR:I,START_ANCHOR:b},w={...$,SLASH_LITERAL:`[${u}]`,QMARK:l,STAR:`${l}*?`,DOTS_SLASH:`${f}{1,2}(?:[${u}]|$)`,NO_DOT:`(?!${f})`,NO_DOTS:`(?!(?:^|[${u}])${f}{1,2}(?:[${u}]|$))`,NO_DOT_SLASH:`(?!${f}{0,1}(?:[${u}]|$))`,NO_DOTS_SLASH:`(?!${f}{1,2}(?:[${u}]|$))`,QMARK_NO_DOT:`[^.${u}]`,START_ANCHOR:`(?:^|[${u}])`,END_ANCHOR:`(?:[${u}]|$)`},N={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};o.exports={MAX_LENGTH:65536,POSIX_REGEX_SOURCE:N,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:c.sep,extglobChars(k){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${k.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(k){return k===!0?w:$}}},754:(o,i,a)=>{const c=a(356),u=a(513),{MAX_LENGTH:l,POSIX_REGEX_SOURCE:f,REGEX_NON_SPECIAL_CHARS:p,REGEX_SPECIAL_CHARS_BACKREF:d,REPLACEMENTS:m}=c,h=(b,A)=>{if(typeof A.expandRange=="function")return A.expandRange(...b,A);b.sort();const _=`[${b.join("-")}]`;try{new RegExp(_)}catch{return b.map(x=>u.escapeRegex(x)).join("..")}return _},y=(b,A)=>`Missing ${b}: "${A}" - use "\\\\${A}" to match literal characters`,g=(b,A)=>{if(typeof b!="string")throw new TypeError("Expected a string");b=m[b]||b;const _={...A},C=typeof _.maxLength=="number"?Math.min(l,_.maxLength):l;let x=b.length;if(x>C)throw new SyntaxError(`Input length: ${x}, exceeds maximum allowed length: ${C}`);const P={type:"bos",value:"",output:_.prepend||""},S=[P],I=_.capture?"":"?:",$=u.isWindows(A),w=c.globChars($),N=c.extglobChars(w),{DOT_LITERAL:k,PLUS_LITERAL:B,SLASH_LITERAL:R,ONE_CHAR:q,DOTS_SLASH:z,NO_DOT:U,NO_DOT_SLASH:K,NO_DOTS_SLASH:W,QMARK:F,QMARK_NO_DOT:ne,STAR:j,START_ANCHOR:T}=w,D=Q=>`(${I}(?:(?!${T}${Q.dot?z:k}).)*?)`,X=_.dot?"":U,te=_.dot?F:ne;let Z=_.bash===!0?D(_):j;_.capture&&(Z=`(${Z})`),typeof _.noext=="boolean"&&(_.noextglob=_.noext);const M={input:b,index:-1,start:0,dot:_.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:S};b=u.removePrefix(b,M),x=b.length;const J=[],Y=[],ee=[];let L=P,O;const re=()=>M.index===x-1,se=M.peek=(Q=1)=>b[M.index+Q],ce=M.advance=()=>b[++M.index],ue=()=>b.slice(M.index+1),ae=(Q="",oe=0)=>{M.consumed+=Q,M.index+=oe},H=Q=>{M.output+=Q.output!=null?Q.output:Q.value,ae(Q.value)},he=()=>{let Q=1;for(;se()==="!"&&(se(2)!=="("||se(3)==="?");)ce(),M.start++,Q++;return Q%2===0?!1:(M.negated=!0,M.start++,!0)},ie=Q=>{M[Q]++,ee.push(Q)},me=Q=>{M[Q]--,ee.pop()},G=Q=>{if(L.type==="globstar"){const oe=M.braces>0&&(Q.type==="comma"||Q.type==="brace"),V=Q.extglob===!0||J.length&&(Q.type==="pipe"||Q.type==="paren");Q.type!=="slash"&&Q.type!=="paren"&&!oe&&!V&&(M.output=M.output.slice(0,-L.output.length),L.type="star",L.value="*",L.output=Z,M.output+=L.output)}if(J.length&&Q.type!=="paren"&&!N[Q.value]&&(J[J.length-1].inner+=Q.value),(Q.value||Q.output)&&H(Q),L&&L.type==="text"&&Q.type==="text"){L.value+=Q.value,L.output=(L.output||"")+Q.value;return}Q.prev=L,S.push(Q),L=Q},le=(Q,oe)=>{const V={...N[oe],conditions:1,inner:""};V.prev=L,V.parens=M.parens,V.output=M.output;const de=(_.capture?"(":"")+V.open;ie("parens"),G({type:Q,value:oe,output:M.output?"":q}),G({type:"paren",extglob:!0,value:ce(),output:de}),J.push(V)},Ce=Q=>{let oe=Q.close+(_.capture?")":"");if(Q.type==="negate"){let V=Z;Q.inner&&Q.inner.length>1&&Q.inner.includes("/")&&(V=D(_)),(V!==Z||re()||/^\)+$/.test(ue()))&&(oe=Q.close=`)$))${V}`),Q.prev.type==="bos"&&(M.negatedExtglob=!0)}G({type:"paren",extglob:!0,value:O,output:oe}),me("parens")};if(_.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(b)){let Q=!1,oe=b.replace(d,(V,de,ye,Ee,xe,er)=>Ee==="\\"?(Q=!0,V):Ee==="?"?de?de+Ee+(xe?F.repeat(xe.length):""):er===0?te+(xe?F.repeat(xe.length):""):F.repeat(ye.length):Ee==="."?k.repeat(ye.length):Ee==="*"?de?de+Ee+(xe?Z:""):Z:de?V:`\\${V}`);return Q===!0&&(_.unescape===!0?oe=oe.replace(/\\/g,""):oe=oe.replace(/\\+/g,V=>V.length%2===0?"\\\\":V?"\\":"")),oe===b&&_.contains===!0?(M.output=b,M):(M.output=u.wrapOutput(oe,M,A),M)}for(;!re();){if(O=ce(),O==="\0")continue;if(O==="\\"){const V=se();if(V==="/"&&_.bash!==!0||V==="."||V===";")continue;if(!V){O+="\\",G({type:"text",value:O});continue}const de=/^\\+/.exec(ue());let ye=0;if(de&&de[0].length>2&&(ye=de[0].length,M.index+=ye,ye%2!==0&&(O+="\\")),_.unescape===!0?O=ce()||"":O+=ce()||"",M.brackets===0){G({type:"text",value:O});continue}}if(M.brackets>0&&(O!=="]"||L.value==="["||L.value==="[^")){if(_.posix!==!1&&O===":"){const V=L.value.slice(1);if(V.includes("[")&&(L.posix=!0,V.includes(":"))){const de=L.value.lastIndexOf("["),ye=L.value.slice(0,de),Ee=L.value.slice(de+2),xe=f[Ee];if(xe){L.value=ye+xe,M.backtrack=!0,ce(),!P.output&&S.indexOf(L)===1&&(P.output=q);continue}}}(O==="["&&se()!==":"||O==="-"&&se()==="]")&&(O=`\\${O}`),O==="]"&&(L.value==="["||L.value==="[^")&&(O=`\\${O}`),_.posix===!0&&O==="!"&&L.value==="["&&(O="^"),L.value+=O,H({value:O});continue}if(M.quotes===1&&O!=='"'){O=u.escapeRegex(O),L.value+=O,H({value:O});continue}if(O==='"'){M.quotes=M.quotes===1?0:1,_.keepQuotes===!0&&G({type:"text",value:O});continue}if(O==="("){ie("parens"),G({type:"paren",value:O});continue}if(O===")"){if(M.parens===0&&_.strictBrackets===!0)throw new SyntaxError(y("opening","("));const V=J[J.length-1];if(V&&M.parens===V.parens+1){Ce(J.pop());continue}G({type:"paren",value:O,output:M.parens?")":"\\)"}),me("parens");continue}if(O==="["){if(_.nobracket===!0||!ue().includes("]")){if(_.nobracket!==!0&&_.strictBrackets===!0)throw new SyntaxError(y("closing","]"));O=`\\${O}`}else ie("brackets");G({type:"bracket",value:O});continue}if(O==="]"){if(_.nobracket===!0||L&&L.type==="bracket"&&L.value.length===1){G({type:"text",value:O,output:`\\${O}`});continue}if(M.brackets===0){if(_.strictBrackets===!0)throw new SyntaxError(y("opening","["));G({type:"text",value:O,output:`\\${O}`});continue}me("brackets");const V=L.value.slice(1);if(L.posix!==!0&&V[0]==="^"&&!V.includes("/")&&(O=`/${O}`),L.value+=O,H({value:O}),_.literalBrackets===!1||u.hasRegexChars(V))continue;const de=u.escapeRegex(L.value);if(M.output=M.output.slice(0,-L.value.length),_.literalBrackets===!0){M.output+=de,L.value=de;continue}L.value=`(${I}${de}|${L.value})`,M.output+=L.value;continue}if(O==="{"&&_.nobrace!==!0){ie("braces");const V={type:"brace",value:O,output:"(",outputIndex:M.output.length,tokensIndex:M.tokens.length};Y.push(V),G(V);continue}if(O==="}"){const V=Y[Y.length-1];if(_.nobrace===!0||!V){G({type:"text",value:O,output:O});continue}let de=")";if(V.dots===!0){const ye=S.slice(),Ee=[];for(let xe=ye.length-1;xe>=0&&(S.pop(),ye[xe].type!=="brace");xe--)ye[xe].type!=="dots"&&Ee.unshift(ye[xe].value);de=h(Ee,_),M.backtrack=!0}if(V.comma!==!0&&V.dots!==!0){const ye=M.output.slice(0,V.outputIndex),Ee=M.tokens.slice(V.tokensIndex);V.value=V.output="\\{",O=de="\\}",M.output=ye;for(const xe of Ee)M.output+=xe.output||xe.value}G({type:"brace",value:O,output:de}),me("braces"),Y.pop();continue}if(O==="|"){J.length>0&&J[J.length-1].conditions++,G({type:"text",value:O});continue}if(O===","){let V=O;const de=Y[Y.length-1];de&&ee[ee.length-1]==="braces"&&(de.comma=!0,V="|"),G({type:"comma",value:O,output:V});continue}if(O==="/"){if(L.type==="dot"&&M.index===M.start+1){M.start=M.index+1,M.consumed="",M.output="",S.pop(),L=P;continue}G({type:"slash",value:O,output:R});continue}if(O==="."){if(M.braces>0&&L.type==="dot"){L.value==="."&&(L.output=k);const V=Y[Y.length-1];L.type="dots",L.output+=O,L.value+=O,V.dots=!0;continue}if(M.braces+M.parens===0&&L.type!=="bos"&&L.type!=="slash"){G({type:"text",value:O,output:k});continue}G({type:"dot",value:O,output:k});continue}if(O==="?"){if(!(L&&L.value==="(")&&_.noextglob!==!0&&se()==="("&&se(2)!=="?"){le("qmark",O);continue}if(L&&L.type==="paren"){const de=se();let ye=O;if(de==="<"&&!u.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(L.value==="("&&!/[!=<:]/.test(de)||de==="<"&&!/<([!=]|\w+>)/.test(ue()))&&(ye=`\\${O}`),G({type:"text",value:O,output:ye});continue}if(_.dot!==!0&&(L.type==="slash"||L.type==="bos")){G({type:"qmark",value:O,output:ne});continue}G({type:"qmark",value:O,output:F});continue}if(O==="!"){if(_.noextglob!==!0&&se()==="("&&(se(2)!=="?"||!/[!=<:]/.test(se(3)))){le("negate",O);continue}if(_.nonegate!==!0&&M.index===0){he();continue}}if(O==="+"){if(_.noextglob!==!0&&se()==="("&&se(2)!=="?"){le("plus",O);continue}if(L&&L.value==="("||_.regex===!1){G({type:"plus",value:O,output:B});continue}if(L&&(L.type==="bracket"||L.type==="paren"||L.type==="brace")||M.parens>0){G({type:"plus",value:O});continue}G({type:"plus",value:B});continue}if(O==="@"){if(_.noextglob!==!0&&se()==="("&&se(2)!=="?"){G({type:"at",extglob:!0,value:O,output:""});continue}G({type:"text",value:O});continue}if(O!=="*"){(O==="$"||O==="^")&&(O=`\\${O}`);const V=p.exec(ue());V&&(O+=V[0],M.index+=V[0].length),G({type:"text",value:O});continue}if(L&&(L.type==="globstar"||L.star===!0)){L.type="star",L.star=!0,L.value+=O,L.output=Z,M.backtrack=!0,M.globstar=!0,ae(O);continue}let Q=ue();if(_.noextglob!==!0&&/^\([^?]/.test(Q)){le("star",O);continue}if(L.type==="star"){if(_.noglobstar===!0){ae(O);continue}const V=L.prev,de=V.prev,ye=V.type==="slash"||V.type==="bos",Ee=de&&(de.type==="star"||de.type==="globstar");if(_.bash===!0&&(!ye||Q[0]&&Q[0]!=="/")){G({type:"star",value:O,output:""});continue}const xe=M.braces>0&&(V.type==="comma"||V.type==="brace"),er=J.length&&(V.type==="pipe"||V.type==="paren");if(!ye&&V.type!=="paren"&&!xe&&!er){G({type:"star",value:O,output:""});continue}for(;Q.slice(0,3)==="/**";){const St=b[M.index+4];if(St&&St!=="/")break;Q=Q.slice(3),ae("/**",3)}if(V.type==="bos"&&re()){L.type="globstar",L.value+=O,L.output=D(_),M.output=L.output,M.globstar=!0,ae(O);continue}if(V.type==="slash"&&V.prev.type!=="bos"&&!Ee&&re()){M.output=M.output.slice(0,-(V.output+L.output).length),V.output=`(?:${V.output}`,L.type="globstar",L.output=D(_)+(_.strictSlashes?")":"|$)"),L.value+=O,M.globstar=!0,M.output+=V.output+L.output,ae(O);continue}if(V.type==="slash"&&V.prev.type!=="bos"&&Q[0]==="/"){const St=Q[1]!==void 0?"|$":"";M.output=M.output.slice(0,-(V.output+L.output).length),V.output=`(?:${V.output}`,L.type="globstar",L.output=`${D(_)}${R}|${R}${St})`,L.value+=O,M.output+=V.output+L.output,M.globstar=!0,ae(O+ce()),G({type:"slash",value:"/",output:""});continue}if(V.type==="bos"&&Q[0]==="/"){L.type="globstar",L.value+=O,L.output=`(?:^|${R}|${D(_)}${R})`,M.output=L.output,M.globstar=!0,ae(O+ce()),G({type:"slash",value:"/",output:""});continue}M.output=M.output.slice(0,-L.output.length),L.type="globstar",L.output=D(_),L.value+=O,M.output+=L.output,M.globstar=!0,ae(O);continue}const oe={type:"star",value:O,output:Z};if(_.bash===!0){oe.output=".*?",(L.type==="bos"||L.type==="slash")&&(oe.output=X+oe.output),G(oe);continue}if(L&&(L.type==="bracket"||L.type==="paren")&&_.regex===!0){oe.output=O,G(oe);continue}(M.index===M.start||L.type==="slash"||L.type==="dot")&&(L.type==="dot"?(M.output+=K,L.output+=K):_.dot===!0?(M.output+=W,L.output+=W):(M.output+=X,L.output+=X),se()!=="*"&&(M.output+=q,L.output+=q)),G(oe)}for(;M.brackets>0;){if(_.strictBrackets===!0)throw new SyntaxError(y("closing","]"));M.output=u.escapeLast(M.output,"["),me("brackets")}for(;M.parens>0;){if(_.strictBrackets===!0)throw new SyntaxError(y("closing",")"));M.output=u.escapeLast(M.output,"("),me("parens")}for(;M.braces>0;){if(_.strictBrackets===!0)throw new SyntaxError(y("closing","}"));M.output=u.escapeLast(M.output,"{"),me("braces")}if(_.strictSlashes!==!0&&(L.type==="star"||L.type==="bracket")&&G({type:"maybe_slash",value:"",output:`${R}?`}),M.backtrack===!0){M.output="";for(const Q of M.tokens)M.output+=Q.output!=null?Q.output:Q.value,Q.suffix&&(M.output+=Q.suffix)}return M};g.fastpaths=(b,A)=>{const _={...A},C=typeof _.maxLength=="number"?Math.min(l,_.maxLength):l,x=b.length;if(x>C)throw new SyntaxError(`Input length: ${x}, exceeds maximum allowed length: ${C}`);b=m[b]||b;const P=u.isWindows(A),{DOT_LITERAL:S,SLASH_LITERAL:I,ONE_CHAR:$,DOTS_SLASH:w,NO_DOT:N,NO_DOTS:k,NO_DOTS_SLASH:B,STAR:R,START_ANCHOR:q}=c.globChars(P),z=_.dot?k:N,U=_.dot?B:N,K=_.capture?"":"?:",W={negated:!1,prefix:""};let F=_.bash===!0?".*?":R;_.capture&&(F=`(${F})`);const ne=X=>X.noglobstar===!0?F:`(${K}(?:(?!${q}${X.dot?w:S}).)*?)`,j=X=>{switch(X){case"*":return`${z}${$}${F}`;case".*":return`${S}${$}${F}`;case"*.*":return`${z}${F}${S}${$}${F}`;case"*/*":return`${z}${F}${I}${$}${U}${F}`;case"**":return z+ne(_);case"**/*":return`(?:${z}${ne(_)}${I})?${U}${$}${F}`;case"**/*.*":return`(?:${z}${ne(_)}${I})?${U}${F}${S}${$}${F}`;case"**/.*":return`(?:${z}${ne(_)}${I})?${S}${$}${F}`;default:{const te=/^(.*?)\.(\w+)$/.exec(X);if(!te)return;const Z=j(te[1]);return Z?Z+S+te[2]:void 0}}},T=u.removePrefix(b,W);let D=j(T);return D&&_.strictSlashes!==!0&&(D+=`${I}?`),D},o.exports=g},683:(o,i,a)=>{const c=a(17),u=a(700),l=a(754),f=a(513),p=a(356),d=h=>h&&typeof h=="object"&&!Array.isArray(h),m=(h,y,g=!1)=>{if(Array.isArray(h)){const I=h.map(w=>m(w,y,g));return w=>{for(const N of I){const k=N(w);if(k)return k}return!1}}const b=d(h)&&h.tokens&&h.input;if(h===""||typeof h!="string"&&!b)throw new TypeError("Expected pattern to be a non-empty string");const A=y||{},_=f.isWindows(y),C=b?m.compileRe(h,y):m.makeRe(h,y,!1,!0),x=C.state;delete C.state;let P=()=>!1;if(A.ignore){const I={...y,ignore:null,onMatch:null,onResult:null};P=m(A.ignore,I,g)}const S=(I,$=!1)=>{const{isMatch:w,match:N,output:k}=m.test(I,C,y,{glob:h,posix:_}),B={glob:h,state:x,regex:C,posix:_,input:I,output:k,match:N,isMatch:w};return typeof A.onResult=="function"&&A.onResult(B),w===!1?(B.isMatch=!1,$?B:!1):P(I)?(typeof A.onIgnore=="function"&&A.onIgnore(B),B.isMatch=!1,$?B:!1):(typeof A.onMatch=="function"&&A.onMatch(B),$?B:!0)};return g&&(S.state=x),S};m.test=(h,y,g,{glob:b,posix:A}={})=>{if(typeof h!="string")throw new TypeError("Expected input to be a string");if(h==="")return{isMatch:!1,output:""};const _=g||{},C=_.format||(A?f.toPosixSlashes:null);let x=h===b,P=x&&C?C(h):h;return x===!1&&(P=C?C(h):h,x=P===b),(x===!1||_.capture===!0)&&(_.matchBase===!0||_.basename===!0?x=m.matchBase(h,y,g,A):x=y.exec(P)),{isMatch:!!x,match:x,output:P}},m.matchBase=(h,y,g,b=f.isWindows(g))=>(y instanceof RegExp?y:m.makeRe(y,g)).test(c.basename(h)),m.isMatch=(h,y,g)=>m(y,g)(h),m.parse=(h,y)=>Array.isArray(h)?h.map(g=>m.parse(g,y)):l(h,{...y,fastpaths:!1}),m.scan=(h,y)=>u(h,y),m.compileRe=(h,y,g=!1,b=!1)=>{if(g===!0)return h.output;const A=y||{},_=A.contains?"":"^",C=A.contains?"":"$";let x=`${_}(?:${h.output})${C}`;h&&h.negated===!0&&(x=`^(?!${x}).*$`);const P=m.toRegex(x,y);return b===!0&&(P.state=h),P},m.makeRe=(h,y,g=!1,b=!1)=>{if(!h||typeof h!="string")throw new TypeError("Expected a non-empty string");const A=y||{};let _={negated:!1,fastpaths:!0},C="",x;return h.startsWith("./")&&(h=h.slice(2),C=_.prefix="./"),A.fastpaths!==!1&&(h[0]==="."||h[0]==="*")&&(x=l.fastpaths(h,y)),x===void 0?(_=l(h,y),_.prefix=C+(_.prefix||"")):_.output=x,m.compileRe(_,y,g,b)},m.toRegex=(h,y)=>{try{const g=y||{};return new RegExp(h,g.flags||(g.nocase?"i":""))}catch(g){if(y&&y.debug===!0)throw g;return/$^/}},m.constants=p,o.exports=m},700:(o,i,a)=>{const c=a(513),{CHAR_ASTERISK:u,CHAR_AT:l,CHAR_BACKWARD_SLASH:f,CHAR_COMMA:p,CHAR_DOT:d,CHAR_EXCLAMATION_MARK:m,CHAR_FORWARD_SLASH:h,CHAR_LEFT_CURLY_BRACE:y,CHAR_LEFT_PARENTHESES:g,CHAR_LEFT_SQUARE_BRACKET:b,CHAR_PLUS:A,CHAR_QUESTION_MARK:_,CHAR_RIGHT_CURLY_BRACE:C,CHAR_RIGHT_PARENTHESES:x,CHAR_RIGHT_SQUARE_BRACKET:P}=a(356),S=w=>w===h||w===f,I=w=>{w.isPrefix!==!0&&(w.depth=w.isGlobstar?1/0:1)},$=(w,N)=>{const k=N||{},B=w.length-1,R=k.parts===!0||k.scanToEnd===!0,q=[],z=[],U=[];let K=w,W=-1,F=0,ne=0,j=!1,T=!1,D=!1,X=!1,te=!1,Z=!1,M=!1,J=!1,Y=!1,ee=0,L,O,re={value:"",depth:0,isGlob:!1};const se=()=>W>=B,ce=()=>K.charCodeAt(W+1),ue=()=>(L=O,K.charCodeAt(++W));for(;W<B;){O=ue();let me;if(O===f){M=re.backslashes=!0,O=ue(),O===y&&(Z=!0);continue}if(Z===!0||O===y){for(ee++;se()!==!0&&(O=ue());){if(O===f){M=re.backslashes=!0,ue();continue}if(O===y){ee++;continue}if(Z!==!0&&O===d&&(O=ue())===d){if(j=re.isBrace=!0,D=re.isGlob=!0,Y=!0,R===!0)continue;break}if(Z!==!0&&O===p){if(j=re.isBrace=!0,D=re.isGlob=!0,Y=!0,R===!0)continue;break}if(O===C&&(ee--,ee===0)){Z=!1,j=re.isBrace=!0,Y=!0;break}}if(R===!0)continue;break}if(O===h){if(q.push(W),z.push(re),re={value:"",depth:0,isGlob:!1},Y===!0)continue;if(L===d&&W===F+1){F+=2;continue}ne=W+1;continue}if(k.noext!==!0&&(O===A||O===l||O===u||O===_||O===m)===!0&&ce()===g){if(D=re.isGlob=!0,X=re.isExtglob=!0,Y=!0,R===!0){for(;se()!==!0&&(O=ue());){if(O===f){M=re.backslashes=!0,O=ue();continue}if(O===x){D=re.isGlob=!0,Y=!0;break}}continue}break}if(O===u){if(L===u&&(te=re.isGlobstar=!0),D=re.isGlob=!0,Y=!0,R===!0)continue;break}if(O===_){if(D=re.isGlob=!0,Y=!0,R===!0)continue;break}if(O===b){for(;se()!==!0&&(me=ue());){if(me===f){M=re.backslashes=!0,ue();continue}if(me===P){T=re.isBracket=!0,D=re.isGlob=!0,Y=!0;break}}if(R===!0)continue;break}if(k.nonegate!==!0&&O===m&&W===F){J=re.negated=!0,F++;continue}if(k.noparen!==!0&&O===g){if(D=re.isGlob=!0,R===!0){for(;se()!==!0&&(O=ue());){if(O===g){M=re.backslashes=!0,O=ue();continue}if(O===x){Y=!0;break}}continue}break}if(D===!0){if(Y=!0,R===!0)continue;break}}k.noext===!0&&(X=!1,D=!1);let ae=K,H="",he="";F>0&&(H=K.slice(0,F),K=K.slice(F),ne-=F),ae&&D===!0&&ne>0?(ae=K.slice(0,ne),he=K.slice(ne)):D===!0?(ae="",he=K):ae=K,ae&&ae!==""&&ae!=="/"&&ae!==K&&S(ae.charCodeAt(ae.length-1))&&(ae=ae.slice(0,-1)),k.unescape===!0&&(he&&(he=c.removeBackslashes(he)),ae&&M===!0&&(ae=c.removeBackslashes(ae)));const ie={prefix:H,input:w,start:F,base:ae,glob:he,isBrace:j,isBracket:T,isGlob:D,isExtglob:X,isGlobstar:te,negated:J};if(k.tokens===!0&&(ie.maxDepth=0,S(O)||z.push(re),ie.tokens=z),k.parts===!0||k.tokens===!0){let me;for(let G=0;G<q.length;G++){const le=me?me+1:F,Ce=q[G],Q=w.slice(le,Ce);k.tokens&&(G===0&&F!==0?(z[G].isPrefix=!0,z[G].value=H):z[G].value=Q,I(z[G]),ie.maxDepth+=z[G].depth),(G!==0||Q!=="")&&U.push(Q),me=Ce}if(me&&me+1<w.length){const G=w.slice(me+1);U.push(G),k.tokens&&(z[z.length-1].value=G,I(z[z.length-1]),ie.maxDepth+=z[z.length-1].depth)}ie.slashes=q,ie.parts=U}return ie};o.exports=$},513:(o,i,a)=>{const c=a(17),u=process.platform==="win32",{REGEX_BACKSLASH:l,REGEX_REMOVE_BACKSLASH:f,REGEX_SPECIAL_CHARS:p,REGEX_SPECIAL_CHARS_GLOBAL:d}=a(356);i.isObject=m=>m!==null&&typeof m=="object"&&!Array.isArray(m),i.hasRegexChars=m=>p.test(m),i.isRegexChar=m=>m.length===1&&i.hasRegexChars(m),i.escapeRegex=m=>m.replace(d,"\\$1"),i.toPosixSlashes=m=>m.replace(l,"/"),i.removeBackslashes=m=>m.replace(f,h=>h==="\\"?"":h),i.supportsLookbehinds=()=>{const m=process.version.slice(1).split(".").map(Number);return m.length===3&&m[0]>=9||m[0]===8&&m[1]>=10},i.isWindows=m=>m&&typeof m.windows=="boolean"?m.windows:u===!0||c.sep==="\\",i.escapeLast=(m,h,y)=>{const g=m.lastIndexOf(h,y);return g===-1?m:m[g-1]==="\\"?i.escapeLast(m,h,g-1):`${m.slice(0,g)}\\${m.slice(g)}`},i.removePrefix=(m,h={})=>{let y=m;return y.startsWith("./")&&(y=y.slice(2),h.prefix="./"),y},i.wrapOutput=(m,h={},y={})=>{const g=y.contains?"":"^",b=y.contains?"":"$";let A=`${g}(?:${m})${b}`;return h.negated===!0&&(A=`(?:^(?!${A}).*$)`),A}},492:(o,i,a)=>{/*!
36
- * to-regex-range <https://github.com/micromatch/to-regex-range>
37
- *
38
- * Copyright (c) 2015-present, Jon Schlinkert.
39
- * Released under the MIT License.
40
- */const c=a(357),u=(S,I,$)=>{if(c(S)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(I===void 0||S===I)return String(S);if(c(I)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let w={relaxZeros:!0,...$};typeof w.strictZeros=="boolean"&&(w.relaxZeros=w.strictZeros===!1);let N=String(w.relaxZeros),k=String(w.shorthand),B=String(w.capture),R=String(w.wrap),q=S+":"+I+"="+N+k+B+R;if(u.cache.hasOwnProperty(q))return u.cache[q].result;let z=Math.min(S,I),U=Math.max(S,I);if(Math.abs(z-U)===1){let j=S+"|"+I;return w.capture?`(${j})`:w.wrap===!1?j:`(?:${j})`}let K=x(S)||x(I),W={min:S,max:I,a:z,b:U},F=[],ne=[];if(K&&(W.isPadded=K,W.maxLen=String(W.max).length),z<0){let j=U<0?Math.abs(U):1;ne=d(j,Math.abs(z),W,w),z=W.a=0}return U>=0&&(F=d(z,U,W,w)),W.negatives=ne,W.positives=F,W.result=l(ne,F),w.capture===!0?W.result=`(${W.result})`:w.wrap!==!1&&F.length+ne.length>1&&(W.result=`(?:${W.result})`),u.cache[q]=W,W.result};function l(S,I,$){let w=m(S,I,"-",!1)||[],N=m(I,S,"",!1)||[],k=m(S,I,"-?",!0)||[];return w.concat(k).concat(N).join("|")}function f(S,I){let $=1,w=1,N=b(S,$),k=new Set([I]);for(;S<=N&&N<=I;)k.add(N),$+=1,N=b(S,$);for(N=A(I+1,w)-1;S<N&&N<=I;)k.add(N),w+=1,N=A(I+1,w)-1;return k=[...k],k.sort(y),k}function p(S,I,$){if(S===I)return{pattern:S,count:[],digits:0};let w=h(S,I),N=w.length,k="",B=0;for(let R=0;R<N;R++){let[q,z]=w[R];q===z?k+=q:q!=="0"||z!=="9"?k+=C(q,z):B++}return B&&(k+=$.shorthand===!0?"\\d":"[0-9]"),{pattern:k,count:[B],digits:N}}function d(S,I,$,w){let N=f(S,I),k=[],B=S,R;for(let q=0;q<N.length;q++){let z=N[q],U=p(String(B),String(z),w),K="";if(!$.isPadded&&R&&R.pattern===U.pattern){R.count.length>1&&R.count.pop(),R.count.push(U.count[0]),R.string=R.pattern+_(R.count),B=z+1;continue}$.isPadded&&(K=P(z,$,w)),U.string=K+U.pattern+_(U.count),k.push(U),B=z+1,R=U}return k}function m(S,I,$,w,N){let k=[];for(let B of S){let{string:R}=B;!w&&!g(I,"string",R)&&k.push($+R),w&&g(I,"string",R)&&k.push($+R)}return k}function h(S,I){let $=[];for(let w=0;w<S.length;w++)$.push([S[w],I[w]]);return $}function y(S,I){return S>I?1:I>S?-1:0}function g(S,I,$){return S.some(w=>w[I]===$)}function b(S,I){return Number(String(S).slice(0,-I)+"9".repeat(I))}function A(S,I){return S-S%Math.pow(10,I)}function _(S){let[I=0,$=""]=S;return $||I>1?`{${I+($?","+$:"")}}`:""}function C(S,I,$){return`[${S}${I-S===1?"":"-"}${I}]`}function x(S){return/^-?(0+)\d/.test(S)}function P(S,I,$){if(!I.isPadded)return S;let w=Math.abs(I.maxLen-String(S).length),N=$.relaxZeros!==!1;switch(w){case 0:return"";case 1:return N?"0?":"0";case 2:return N?"0{0,2}":"00";default:return N?`0{0,${w}}`:`0{${w}}`}}u.cache={},u.clearCache=()=>u.cache={},o.exports=u},17:o=>{o.exports=kp},837:o=>{o.exports=ym()}},t={};function r(o){var i=t[o];if(i!==void 0)return i.exports;var a=t[o]={exports:{}},c=!0;try{e[o](a,a.exports,r),c=!1}finally{c&&delete t[o]}return a.exports}typeof r<"u"&&(r.ab=__dirname+"/");var n=r(971);Dr.exports=n})()),Dr.exports}var Os;function vm(){return Os||(Os=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(i,a){for(var c in a)Object.defineProperty(i,c,{enumerable:!0,get:a[c]})}t(e,{matchRemotePattern:function(){return n},hasMatch:function(){return o}});const r=_m();function n(i,a){if(i.protocol!==void 0){const u=a.protocol.slice(0,-1);if(i.protocol!==u)return!1}if(i.port!==void 0&&i.port!==a.port)return!1;if(i.hostname===void 0)throw new Error(`Pattern should define hostname but found
41
- `+JSON.stringify(i));if(!(0,r.makeRe)(i.hostname).test(a.hostname))return!1;var c;return!!(0,r.makeRe)((c=i.pathname)!=null?c:"**").test(a.pathname)}function o(i,a,c){return i.some(u=>c.hostname===u)||a.some(u=>n(u,c))}}(Lr)),Lr}var Ts;function ku(){return Ts||(Ts=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return r}});function t(n){let{config:o,src:i,width:a,quality:c}=n;if(process.env.NODE_ENV!=="production"){const u=[];if(i||u.push("src"),a||u.push("width"),u.length>0)throw new Error("Next Image Optimization requires "+u.join(", ")+" to be provided. Make sure you pass them as props to the `next/image` component. Received: "+JSON.stringify({src:i,width:a,quality:c}));if(i.startsWith("//"))throw new Error('Failed to parse src "'+i+'" on `next/image`, protocol-relative URL (//) must be changed to an absolute URL (http:// or https://)');if(!i.startsWith("/")&&(o.domains||o.remotePatterns)){let l;try{l=new URL(i)}catch(f){throw console.error(f),new Error('Failed to parse src "'+i+'" on `next/image`, if using relative image it must start with a leading slash "/" or be an absolute URL (http:// or https://)')}if(process.env.NODE_ENV!=="test"&&process.env.NEXT_RUNTIME!=="edge"){const{hasMatch:f}=vm();if(!f(o.domains,o.remotePatterns,l))throw new Error("Invalid src prop ("+i+') on `next/image`, hostname "'+l.hostname+'" is not configured under images in your `next.config.js`\nSee more info: https://nextjs.org/docs/messages/next-image-unconfigured-host')}}}return o.path+"?url="+encodeURIComponent(i)+"&w="+a+"&q="+(c||75)+(process.env.NEXT_DEPLOYMENT_ID?"&dpl="+process.env.NEXT_DEPLOYMENT_ID:"")}t.__next_img_default=!0;const r=t}(kr)),kr}(function(e,t){"use client";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return A}});const r=Re,o=nt._(E),i=r._(Ks),a=r._(Tp()),c=jo,u=Yt,l=Mp(),f=_t,p=Nc(),d=r._(ku()),m=process.env.__NEXT_IMAGE_OPTS;typeof window>"u"&&(globalThis.__NEXT_IMAGE_IMPORTED=!0);function h(_,C,x,P,S,I){const $=_==null?void 0:_.src;if(!_||_["data-loaded-src"]===$)return;_["data-loaded-src"]=$,("decode"in _?_.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(!(!_.parentElement||!_.isConnected)){if(C!=="empty"&&S(!0),x!=null&&x.current){const N=new Event("load");Object.defineProperty(N,"target",{writable:!1,value:_});let k=!1,B=!1;x.current({...N,nativeEvent:N,currentTarget:_,target:_,isDefaultPrevented:()=>k,isPropagationStopped:()=>B,persist:()=>{},preventDefault:()=>{k=!0,N.preventDefault()},stopPropagation:()=>{B=!0,N.stopPropagation()}})}if(P!=null&&P.current&&P.current(_),process.env.NODE_ENV!=="production"){const N=new URL($,"http://n").searchParams.get("url")||$;if(_.getAttribute("data-nimg")==="fill"){if(!I&&(!_.getAttribute("sizes")||_.getAttribute("sizes")==="100vw")&&_.getBoundingClientRect().width/window.innerWidth<.6&&(0,f.warnOnce)('Image with src "'+N+'" has "fill" but is missing "sizes" prop. Please add it to improve page performance. Read more: https://nextjs.org/docs/api-reference/next/image#sizes'),_.parentElement){const{position:R}=window.getComputedStyle(_.parentElement),q=["absolute","fixed","relative"];q.includes(R)||(0,f.warnOnce)('Image with src "'+N+'" has "fill" and parent element with invalid "position". Provided "'+R+'" should be one of '+q.map(String).join(",")+".")}_.height===0&&(0,f.warnOnce)('Image with src "'+N+'" has "fill" and a height value of 0. This is likely because the parent element of the image has not been styled to have a set height.')}const k=_.height.toString()!==_.getAttribute("height"),B=_.width.toString()!==_.getAttribute("width");(k&&!B||!k&&B)&&(0,f.warnOnce)('Image with src "'+N+`" has either width or height modified, but not the other. If you use CSS to change the size of your image, also include the styles 'width: "auto"' or 'height: "auto"' to maintain the aspect ratio.`)}}})}function y(_){const[C,x]=o.version.split("."),P=parseInt(C,10),S=parseInt(x,10);return P>18||P===18&&S>=3?{fetchPriority:_}:{fetchpriority:_}}const g=(0,o.forwardRef)((_,C)=>{let{src:x,srcSet:P,sizes:S,height:I,width:$,decoding:w,className:N,style:k,fetchPriority:B,placeholder:R,loading:q,unoptimized:z,fill:U,onLoadRef:K,onLoadingCompleteRef:W,setBlurComplete:F,setShowAltText:ne,onLoad:j,onError:T,...D}=_;return o.default.createElement("img",{...D,...y(B),loading:q,width:$,height:I,decoding:w,"data-nimg":U?"fill":"1",className:N,style:k,sizes:S,srcSet:P,src:x,ref:(0,o.useCallback)(X=>{C&&(typeof C=="function"?C(X):typeof C=="object"&&(C.current=X)),X&&(T&&(X.src=X.src),process.env.NODE_ENV!=="production"&&(x||console.error('Image is missing required "src" property:',X),X.getAttribute("alt")===null&&console.error('Image is missing required "alt" property. Please add Alternative Text to describe the image for screen readers and search engines.')),X.complete&&h(X,R,K,W,F,z))},[x,R,K,W,F,T,z,C]),onLoad:X=>{const te=X.currentTarget;h(te,R,K,W,F,z)},onError:X=>{ne(!0),R!=="empty"&&F(!0),T&&T(X)}})});function b(_){let{isAppRouter:C,imgAttributes:x}=_;const P={as:"image",imageSrcSet:x.srcSet,imageSizes:x.sizes,crossOrigin:x.crossOrigin,referrerPolicy:x.referrerPolicy,...y(x.fetchPriority)};return C&&i.default.preload?(i.default.preload(x.src,P),null):o.default.createElement(a.default,null,o.default.createElement("link",{key:"__nimg-"+x.src+x.srcSet+x.sizes,rel:"preload",href:x.srcSet?void 0:x.src,...P}))}const A=(0,o.forwardRef)((_,C)=>{const P=!(0,o.useContext)(p.RouterContext),S=(0,o.useContext)(l.ImageConfigContext),I=(0,o.useMemo)(()=>{const W=m||S||u.imageConfigDefault,F=[...W.deviceSizes,...W.imageSizes].sort((j,T)=>j-T),ne=W.deviceSizes.sort((j,T)=>j-T);return{...W,allSizes:F,deviceSizes:ne}},[S]),{onLoad:$,onLoadingComplete:w}=_,N=(0,o.useRef)($);(0,o.useEffect)(()=>{N.current=$},[$]);const k=(0,o.useRef)(w);(0,o.useEffect)(()=>{k.current=w},[w]);const[B,R]=(0,o.useState)(!1),[q,z]=(0,o.useState)(!1),{props:U,meta:K}=(0,c.getImgProps)(_,{defaultLoader:d.default,imgConf:I,blurComplete:B,showAltText:q});return o.default.createElement(o.default.Fragment,null,o.default.createElement(g,{...U,unoptimized:K.unoptimized,placeholder:K.placeholder,fill:K.fill,onLoadRef:N,onLoadingCompleteRef:k,setBlurComplete:R,setShowAltText:z,ref:C}),K.priority?o.default.createElement(b,{isAppRouter:P,imgAttributes:U}):null)});(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)})(Zn,Zn.exports);var bm=Zn.exports;(function(e){Object.defineProperty(e,"__esModule",{value:!0});function t(l,f){for(var p in f)Object.defineProperty(l,p,{enumerable:!0,get:f[p]})}t(e,{unstable_getImgProps:function(){return c},default:function(){return u}});const r=Re,n=jo,o=_t,i=bm,a=r._(ku()),c=l=>{(0,o.warnOnce)("Warning: unstable_getImgProps() is experimental and may change or be removed at any time. Use at your own risk.");const{props:f}=(0,n.getImgProps)(l,{defaultLoader:a.default,imgConf:process.env.__NEXT_IMAGE_OPTS});for(const[p,d]of Object.entries(f))d===void 0&&delete f[p];return{props:f}},u=i.Image})(Su);var xm=Su;const Ms=Vt(xm),Cm=({item:e,CONSTANTS:t})=>{const r=e.icon?t.PAYMENT_FLAGS.includes(e.icon)?"payment":"social":null,n=r==="payment"?t.PAYMENT_FLAGS_DICTIONARY[e.icon]:e.icon;return e.link?s.jsxs(Ne,{href:e.link,target:"_blank",rel:"noopener noreferrer",className:pe["support-item"],children:[e.image&&s.jsx("img",{src:e.image,alt:"",loading:"lazy"}),r==="payment"?s.jsx(Ms,{alt:n,src:`/assets/${n}.svg`,width:20,height:20}):s.jsx(v.Icon,{size:"small",name:n})]}):s.jsxs("div",{className:pe["support-item"],children:[e.image&&s.jsx("img",{src:e.image,alt:"",loading:"lazy"}),r==="payment"?s.jsx(Ms,{alt:n,src:`/assets/${n}.svg`,width:20,height:20}):s.jsx(v.Icon,{size:"small",name:n})]})},Sm=({content:e,CONSTANTS:t})=>s.jsx("div",{className:pe["support-container"],children:e==null?void 0:e.map((r,n)=>s.jsxs("div",{"data-device":r.device,className:pe["support-section"],children:[s.jsxs("div",{className:pe["support-text"],children:[r.title&&s.jsx("h3",{children:r.title}),r.description&&s.jsx("p",{children:r.description})]}),r.items.length&&s.jsx("div",{className:pe["support-items"],"data-gap":r.gap,children:r.items.map((o,i)=>s.jsx(Cm,{item:o,CONSTANTS:t},`footer-support-item-${i}`))})]},`footer-support-${n}`))}),Am=({name:e,nameIcon:t,maxWidth:r,rowAlignContent:n,columnAlignContent:o,columnAlignItems:i,textAlignContent:a,textAlignItems:c,children:u})=>s.jsx(v.TextStructure.Root,{layoutProps:{textRow:{alignContent:n,alignItems:n},columnWrapper:{alignContent:o,alignItems:i}},children:s.jsxs(v.TextStructure.DivWrapper,{alignContent:a,alignItems:c,className:pe.footer__column,children:[s.jsxs("div",{className:t?pe.footer__columnTitleIcon:pe.footer__columnTitle,children:[s.jsx(v.Icon,{name:`${t}`,size:"small"}),e&&s.jsx("div",{children:e})]}),s.jsx("div",{className:pe.footer__columnContent,style:{maxWidth:`${r}px`},children:u})]})}),Em=({name:e,nameIcon:t,maxWidth:r,children:n,ICONS:o,...i})=>s.jsxs(v.Accordion.Wrapper,{className:pe.accordionWrapper,title:"accordion-wrapper",...i,children:[s.jsx(v.Accordion.Header,{id:(i==null?void 0:i.id)??"",className:pe.accordionHeader,closeIndicator:s.jsx(v.Icon,{name:o.arrow_up,size:"medium"}),openIndicator:s.jsx(v.Icon,{name:o.arrow_down,size:"medium"}),title:"accordion-header",children:s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{className:t?pe.accordionTextWrapper:"",children:[s.jsx(v.Icon,{name:`${t}`,size:"medium"}),s.jsx("h2",{className:"typography-style-body-md",children:e})]})})}),s.jsx(v.Accordion.Body,{title:"accordion-body",children:s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{className:pe.footer__columnContent,style:{maxWidth:`${r}px`},children:n})})})]}),Bn=e=>{const{isMobile:t}=Ae();return t?s.jsx(Em,{...e}):s.jsx(Am,{...e})},Bt=({type:e,children:t,className:r,collumnName:n,collumnNameIcon:o,icons:i,iconLink:a,iconSize:c,link:u,paymentDisclaimer:l,paymentTitle:f,rowAlignContent:p,columnAlignContent:d,columnAlignItems:m,textAlignContent:h,textAlignItems:y,...g})=>{let b;const{handleSelectContent:A}=ge(),{nextimage:_}=je();switch(e){case"menu":b=s.jsx(Ne,{className:pe.footer__itemLink,href:u??"#",prefetch:!1,children:s.jsx("span",{onClick:()=>{A({content:`footer:${n}:${t}`})},children:t})});break;case"payment":b=s.jsxs("div",{className:v.helpers.classNameConcat(pe.payment,pe.footer__itemSmallText),...g,children:[l,s.jsxs("div",{className:v.helpers.classNameConcat(pe.footer__iconContainer,pe.footer__iconListSubHeader),children:[f,s.jsx("div",{className:pe.footer__iconList,children:i==null?void 0:i.map((C,x)=>s.jsx(_,{alt:C,src:`/assets/${C}.svg`,width:c??20,height:c??20},x))})]})]});break;case"social-media":b=s.jsx("div",{className:pe.footer__iconContainer,...g,children:s.jsx("div",{className:pe.footer__iconList,children:a==null?void 0:a.map((C,x)=>s.jsx(Ne,{prefetch:!1,href:C.link??"#",target:"_blank",children:s.jsx(v.Icon,{size:"medium",name:C.icon,onClick:()=>A({content:`footer:redes-sociais:${C.icon}`})})},x))})});break;default:b=s.jsx("div",{className:r,...g,children:t})}return s.jsx(v.TextStructure.Root,{layoutProps:{textRow:{alignContent:p,alignItems:p},columnWrapper:{alignContent:d,alignItems:m}},...g,children:s.jsx(v.TextStructure.DivWrapper,{alignContent:h,alignItems:y,className:v.helpers.classNameConcat(pe.footer__item,r),children:b})})},wm=({className:e,text:t,...r})=>s.jsx("div",{...r,className:v.helpers.classNameConcat(pe.footer__legalInformation,e),children:s.jsx("span",{children:t})}),Lu=()=>{const{nextimage:e}=je();return s.jsx("div",{className:pe["footer--stamps"],children:s.jsx(e,{alt:"Empresa B",className:pe["footer--stamps--company"],src:"/images/Footer/new_certfB.png",width:56,height:64})})};Lu.displayName="Footer.Stamps";const Du=({children:e,legalTextSlot:t,adornment:r,className:n,...o})=>{const{isMobile:i}=Ae(),a=E.Children.toArray(e).filter(Boolean),c=a.length;return s.jsxs("div",{className:pe.footer__main,children:[(r==null?void 0:r.top)&&s.jsx("div",{className:pe.footer__top,children:r==null?void 0:r.top}),c>0&&s.jsx("div",{...o,className:v.helpers.classNameConcat(pe.footer__wrapper,n),children:a.map((u,l)=>s.jsx("div",{style:{flexGrow:1,maxWidth:`calc(100% / ${i?1:"fit-content"})`},children:u},l))}),(r==null?void 0:r.bottom)&&s.jsx("div",{className:pe.footer__bottom,children:r.bottom}),t&&s.jsx("div",{className:pe.footer__legalText,children:t})]})};Du.displayName="Footer.Wrapper";const $u=({data:{links:{links:e}},payments:t,socialInfo:r,socialMedias:n,adornment:o,LEGAL_INFORMATION_TEXT:i,ICONS:a})=>{var c;return s.jsxs(Du,{adornment:o,legalTextSlot:s.jsx(wm,{text:i}),children:[Array.isArray(e.column)&&e.column.map((u,l)=>s.jsx(Bn,{id:`${l}column-menu`,name:u.name,nameIcon:u.nameIcon,ICONS:a,children:u.items.map((f,p)=>s.jsx(Bt,{type:"menu",link:f.link,collumnName:u.name,collumnNameIcon:u.nameIcon,children:f.text},p))},l)),t&&((c=t.acceptedFlags)==null?void 0:c.length)>0&&s.jsx(Bn,{id:"payment-column",name:t==null?void 0:t.title,nameIcon:t==null?void 0:t.titleIcon,maxWidth:150,ICONS:a,children:s.jsx(Bt,{type:"payment",paymentDisclaimer:t==null?void 0:t.text,paymentTitle:t==null?void 0:t.flagsTitle,iconSize:16,icons:t==null?void 0:t.acceptedFlags})}),s.jsxs(Bn,{id:"social-media-column",name:r==null?void 0:r.title,ICONS:a,children:[r!=null&&r.subTitle?s.jsx(Bt,{children:r==null?void 0:r.subTitle}):null,s.jsx(Bt,{type:"social-media",iconSize:24,iconLink:n}),s.jsx(Lu,{})]})]})};$u.displayName="Footer";const Rm=Object.freeze(Object.defineProperty({__proto__:null,Footer:$u,FooterSupport:Sm},Symbol.toStringTag,{value:"Module"})),ks=({image:e,index:t,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:n})=>{const o=ta(e.imageUrl,n.pdp),{nextimage:i}=je();return s.jsx(i,{src:o,alt:e.imageLabel,objectFit:"contain",...n.pdp,...t<=1&&{priority:!0,loading:"eager"},onClick:()=>{r(t)}},t)},jm=({video:e,productName:t,poster:r})=>{const{sendDataLayerEvent:n}=ge(),o=E.useRef(!1);return s.jsx($e.Video,{src:e,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{zIndex:-1,aspectRatio:"2/3"},onPlaying:()=>{o.current||(o.current=!0,n({functionKey:"readyEvents",data:{event:"video_start",readyData:{product:t}}}))},poster:r})},Pm={"gallery-carousel-modifier":"_gallery-carousel-modifier_1dxfy_92"},Bu=({images:e,video:t,handleZoom:r,productName:n,PRODUCT_IMAGE_DIMENSIONS:o})=>{var l,f;const{initialize:i,pagination:a,controller:c,itemsStyles:u}=v.Carousel.useCarousel({gap:0,itemsPerPage:1,loop:!1,direction:"row"});return s.jsxs(v.Carousel.Root,{innerRef:p=>{i(p)},className:Pm["gallery-carousel-modifier"],children:[s.jsx(v.Carousel.Controller,{position:"absolute",top:"24px",bottom:"unset",left:"16px",children:s.jsx(v.Carousel.Bullets,{page:a.currentPage,total:e.length,onBulletClick:p=>c==null?void 0:c.navigateTo(p)})}),s.jsxs(v.Carousel.Body,{children:[s.jsx(v.Carousel.Item,{style:u,children:s.jsx(ks,{image:e[0],index:0,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:o})},"PDP_gallery_0"),t&&s.jsx(v.Carousel.Item,{style:u,children:s.jsx(jm,{video:t,productName:n,...((l=e[1])==null?void 0:l.imageUrl)&&{poster:(f=e[1])==null?void 0:f.imageUrl}})},"PDP_gallery_video"),e.map((p,d)=>d===0?null:s.jsx(v.Carousel.Item,{style:u,children:s.jsx(ks,{image:p,index:d,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:o})},`PDP_gallery_${d}`))]})]})};Bu.displayName="PDP.Carousel";const Im=({productImgs:e,PRODUCT_IMAGE_DIMENSIONS:t})=>{const{video:r,productName:n}=fo(),[o,i]=E.useState({show:!1,initialIndex:0});E.useEffect(()=>(o.show?document.body.classList.add("no-scroll"):document.body.classList.remove("no-scroll"),()=>{document.body.classList.remove("no-scroll")}),[o]);const a=c=>{i({show:!0,initialIndex:c})};return s.jsx(s.Fragment,{children:s.jsx(Bu,{images:e,video:r,handleZoom:a,productName:n,PRODUCT_IMAGE_DIMENSIONS:t})})},qu=({TEXTURE_IMAGE:e,PRODUCT_IMAGE_DIMENSIONS:t})=>{const{images:r}=fo(),n=E.useMemo(()=>{const o=r.filter(i=>!e.includes(i.imageLabel));return o.length>0?o:r},[]);return s.jsx(Im,{productImgs:n,PRODUCT_IMAGE_DIMENSIONS:t})};qu.displayName="PDP.Gallery";const Nm=Object.freeze(Object.defineProperty({__proto__:null,Gallery:qu},Symbol.toStringTag,{value:"Module"})),Om="_container_1sy8s_16",Fe={"carousel-container":"_carousel-container_1sy8s_1","add-cart-container":"_add-cart-container_1sy8s_8",container:Om,"add-itens-to-cart-container":"_add-itens-to-cart-container_1sy8s_38","add-itens-to-cart-container-values":"_add-itens-to-cart-container-values_1sy8s_45","add-itens-to-cart-qty-products":"_add-itens-to-cart-qty-products_1sy8s_50","add-itens-to-cart-total":"_add-itens-to-cart-total_1sy8s_60","add-button":"_add-button_1sy8s_70"},Tm=({selectedProducts:e,handleAddAllToCart:t,CONSTANTS:r})=>{const n=Object.values(e.products).length;return s.jsxs("div",{className:Fe["add-itens-to-cart-container"],children:[s.jsxs("div",{className:Fe["add-itens-to-cart-container-values"],children:[s.jsx("div",{className:Fe["add-itens-to-cart-qty-products"],children:s.jsx("span",{children:n===0?r.BUY_PACKAGE.group_cart.select_all_product:`${n} ${n===1?r.BUY_PACKAGE.group_cart.select_product:r.BUY_PACKAGE.group_cart.select_product+"s"}`})}),s.jsx("div",{className:Fe["add-itens-to-cart-total"],children:s.jsx("span",{children:co({valueInCents:e.totalPrice*100,hasFree:!1,freeTaxMessage:r.FREIGHT_CALCULATION.messages.free_tax})})})]}),s.jsx(v.Button,{onClick:t,className:Fe["add-button"],size:"large",disabled:n===0,variant:"primary",children:r.BUY_BUTTON_LABELS.add_to_cart})]})},Mm=e=>e.reduce((t,r)=>{var o;const n=t.find(i=>i.node.id===r.node.id);if(!n)return[...t,r];if((o=n==null?void 0:n.node.isVariantOf)!=null&&o.hasVariant){const i=n.node.isVariantOf.hasVariant,a=r.node.isVariantOf.hasVariant;i&&a&&(n.node.isVariantOf.hasVariant=[...i,...a])}return t},[]),km=({selectedProduct:e,productId:t,prevState:r,mainSellerId:n})=>{const{products:o,totalPrice:i}=r;try{if(!e){const{[t]:l,...f}=o;return{...r,totalPrice:i-l.price,products:f}}const a=lo(e.offers.offers,n);if(!a)return r;const c=a.seller.identifier,u=a.price;if(o[t]){const{price:l}=o[t];return o[t]={...o[t],price:u,id:e.sku,seller:c},{totalPrice:i+u-l,products:{...o}}}return{totalPrice:i+u,products:{...o,[t]:{id:e.sku,price:u,seller:c,productId:t}}}}catch(a){return console.error("Error handling SKU selection:",a),r}},Lm="_carousel_245ib_1",Dm="_shelf__container_245ib_14",$m="_shelf_without_carousel_245ib_34",lt={carousel:Lm,"custom-controllers":"_custom-controllers_245ib_5",shelf__container:Dm,"controllers-arrows-bullets":"_controllers-arrows-bullets_245ib_23",shelf_without_carousel:$m},Ls=({title:e})=>s.jsx("div",{className:lt.shelf__container,children:e&&s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{children:[s.jsx("h2",{className:v.helpers.classNameConcat("typography-style-body-md",Te.responsive["responsive-mobile-flex"]),children:e}),s.jsx("h2",{className:v.helpers.classNameConcat("typography-style-heading-md",Te.responsive["responsive-desktop-flex"]),children:e})]})})}),Bm=({children:e,ICONS:t,itemsPerPage:r,title:n})=>{const{isMobile:o}=Ae(),i=r[o?"mobile":"desktop"],{initialize:a,controller:c,itemsStyles:u,pagination:l}=v.Carousel.useCarousel({itemsPerPage:i,gap:10,loop:!0,direction:"row"}),f=E.Children.toArray(e).length;return o||f>=4?s.jsxs(v.Carousel.Root,{innerRef:d=>{a(d)},className:lt.carousel,children:[s.jsxs("div",{className:lt["custom-controllers"],children:[n&&s.jsx(Ls,{title:n}),i<f&&s.jsxs(v.Carousel.Controller,{className:lt["controllers-arrows-bullets"],children:[s.jsxs(v.Carousel.Arrows,{children:[s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.prevPage(),adornment:{start:s.jsx(v.Icon,{name:t.arrow_left})}}),s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.nextPage(),adornment:{start:s.jsx(v.Icon,{name:t.arrow_right})}})]}),!o&&i>2&&s.jsx(v.Carousel.Bullets,{page:l.currentPage,total:l.totalPages,onBulletClick:d=>c==null?void 0:c.navigateTo(d)})]})]}),s.jsx(v.Carousel.Body,{children:E.Children.map(e,(d,m)=>s.jsx(v.Carousel.Item,{style:{...u,overflow:"hidden"},children:d},`${n}_${m}`))})]}):s.jsxs(s.Fragment,{children:[n&&s.jsx(Ls,{title:n}),s.jsx("div",{className:lt.shelf_without_carousel,children:e})]})},qm={Shelf:Bm},Hm=({CONSTANTS:e,inView:t,products:r,innerRef:n,WishListToggle:o})=>{const i=E.useMemo(()=>Mm(r),[r]),{isMobile:a}=Ae(),{addItemsToCart:c}=Be(),{sendDataLayerEvent:u}=ge(),{getAvailableProductTag:l}=ao(),[f,p]=E.useState({totalPrice:0,products:{}}),d=()=>{const h=Object.values(f.products);c(h),u({functionKey:"skuEvents",data:{event:"add_to_cart",commonData:{products:h.map(y=>{const g=i.find(b=>b.node.id===y.productId);return g==null?void 0:g.node})},supportData:{selectedSkus:h,price:f.totalPrice}}})},m=({selectedProduct:h,productId:y})=>{const g=km({selectedProduct:h,productId:y,prevState:f,mainSellerId:e.StoreConfig_MainSellerId});p(g)};return E.useEffect(()=>{if(!t||i.length===0)return;const h=e.BUY_PACKAGE.header.title;u({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:i},customData:{item_list_name:h},outsideEcommerceData:{item_list_name:h}}})},[t]),s.jsxs("div",{className:Fe.container,ref:n,children:[s.jsx("div",{className:Fe["carousel-container"],style:{width:i.length<=3?"max-content":"75%"},children:s.jsx(qm.Shelf,{title:e.BUY_PACKAGE.header.title,itemsPerPage:{desktop:3,mobile:i.length>=3?2.2:i.length},ICONS:e.ICONS,children:Array.isArray(i)&&i.map(({node:h},y)=>{var A,_,C;const g=l(h.cluster.highlights),{availability:{status:b}}=h;return b?s.jsxs(Pe.Root,{item:{...h,image:xo.helpers.product.getFirstImages({images:h.image,label:{first:e.MAIN_IMAGE,second:e.SECOND_IMAGE}})},isMobile:a,size:"medium",index:y,shelfTitle:e.BUY_PACKAGE.header.title,CONSTANTS:e,WishListToggle:o,children:[s.jsx(Pe.Header,{product:h,tag:g.commercial}),s.jsx(Pe.Media,{}),s.jsxs(Pe.Wrapper,{type:"body",children:[s.jsx(Pe.Title,{tag:{value:(A=g.institucional)==null?void 0:A.value,enableIcon:(_=g.institucional)==null?void 0:_.enableIcon,icon:(C=g.institucional)==null?void 0:C.icon}}),s.jsx(Pe.Actions,{children:s.jsx(Pe.SizeSelector,{callback:x=>m({selectedProduct:x,productId:h.id})})})]})]},h.id):null})})}),s.jsx("div",{className:Fe["add-cart-container"],children:s.jsx(Tm,{handleAddAllToCart:d,selectedProducts:f,CONSTANTS:{BUY_BUTTON_LABELS:e.BUY_BUTTON_LABELS,BUY_PACKAGE:e.BUY_PACKAGE,FREIGHT_CALCULATION:e.FREIGHT_CALCULATION}})})]})},Fm=({page:e,data:t})=>{const{pathname:r}=je(),n=E.useRef(null),{sendDataLayerEvent:o,currentLocalRef:i,itemListRef:a,promotionEventRef:c}=ge();return E.useEffect(()=>{const u=cc("login_event")||"{}",l=JSON.parse(u);if(l.name||l.method){const f=new Date(0);o({functionKey:"readyEvents",data:{event:l.name,readyData:{method:l.method}}}),vo("login_event","",{expires:f})}},[]),E.useEffect(()=>{if(n.current===r)return;n.current=r;let u={};switch(e){case"PDP":{const f=t,p={};if(!f){u={page_category:"pdp"};break}f.items.forEach(({itemId:d,sellers:m})=>p[d]=m[0].commertialOffer.AvailableQuantity),u={page_category:"pdp",seller_ids:f.items.map(({sellers:d})=>d[0].sellerId).join(),skuStocks:p,product_reference_id:f.productReference};break}case"PDC":{const{page_category:f,page_departament:p,id:d,name:m}=ua(),h=m,y=d;u={page_category:"lista_produtos",...p&&{page_departament:p}},a.current={item_list_name:r==="/search"?"busca":h??void 0,item_list_id:r==="/search"?void 0:y??void 0},p&&o({functionKey:"readyEvents",data:{event:"view_category",readyData:{page_category:f,page_departament:p}}});break}default:u={page_category:e},c.current={},a.current={};break}const l={region:e,...u};i.current=e,o({functionKey:"readyEvents",data:{readyData:{vtex_version:"fast",...l}},timeout:0})},[r]),null};var Jn={exports:{}};function zm(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var qn={},Hn={},Ds;function Um(){return Ds||(Ds=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"LoadableContext",{enumerable:!0,get:function(){return n}});const n=Re._(E).default.createContext(null);process.env.NODE_ENV!=="production"&&(n.displayName="LoadableContext")}(Hn)),Hn}var $s;function Gm(){return $s||($s=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return m}});const r=Re._(E),n=Um();function o(h){return h&&h.default?h.default:h}const i=[],a=[];let c=!1;function u(h){let y=h(),g={loading:!0,loaded:null,error:null};return g.promise=y.then(b=>(g.loading=!1,g.loaded=b,b)).catch(b=>{throw g.loading=!1,g.error=b,b}),g}function l(h,y){let g=Object.assign({loader:null,loading:null,delay:200,timeout:null,webpack:null,modules:null},y),b=null;function A(){if(!b){const x=new f(h,g);b={getCurrentValue:x.getCurrentValue.bind(x),subscribe:x.subscribe.bind(x),retry:x.retry.bind(x),promise:x.promise.bind(x)}}return b.promise()}if(typeof window>"u"&&i.push(A),!c&&typeof window<"u"){const x=g.webpack&&typeof zm.resolveWeak=="function"?g.webpack():g.modules;x&&a.push(P=>{for(const S of x)if(P.includes(S))return A()})}function _(){A();const x=r.default.useContext(n.LoadableContext);x&&Array.isArray(g.modules)&&g.modules.forEach(P=>{x(P)})}function C(x,P){_();const S=r.default.useSyncExternalStore(b.subscribe,b.getCurrentValue,b.getCurrentValue);return r.default.useImperativeHandle(P,()=>({retry:b.retry}),[]),r.default.useMemo(()=>S.loading||S.error?r.default.createElement(g.loading,{isLoading:S.loading,pastDelay:S.pastDelay,timedOut:S.timedOut,error:S.error,retry:b.retry}):S.loaded?r.default.createElement(o(S.loaded),x):null,[x,S])}return C.preload=()=>A(),C.displayName="LoadableComponent",r.default.forwardRef(C)}class f{promise(){return this._res.promise}retry(){this._clearTimeouts(),this._res=this._loadFn(this._opts.loader),this._state={pastDelay:!1,timedOut:!1};const{_res:y,_opts:g}=this;y.loading&&(typeof g.delay=="number"&&(g.delay===0?this._state.pastDelay=!0:this._delay=setTimeout(()=>{this._update({pastDelay:!0})},g.delay)),typeof g.timeout=="number"&&(this._timeout=setTimeout(()=>{this._update({timedOut:!0})},g.timeout))),this._res.promise.then(()=>{this._update({}),this._clearTimeouts()}).catch(b=>{this._update({}),this._clearTimeouts()}),this._update({})}_update(y){this._state={...this._state,error:this._res.error,loaded:this._res.loaded,loading:this._res.loading,...y},this._callbacks.forEach(g=>g())}_clearTimeouts(){clearTimeout(this._delay),clearTimeout(this._timeout)}getCurrentValue(){return this._state}subscribe(y){return this._callbacks.add(y),()=>{this._callbacks.delete(y)}}constructor(y,g){this._loadFn=y,this._opts=g,this._callbacks=new Set,this._delay=null,this._timeout=null,this.retry()}}function p(h){return l(u,h)}function d(h,y){let g=[];for(;h.length;){let b=h.pop();g.push(b(y))}return Promise.all(g).then(()=>{if(h.length)return d(h,y)})}p.preloadAll=()=>new Promise((h,y)=>{d(i).then(h,y)}),p.preloadReady=h=>(h===void 0&&(h=[]),new Promise(y=>{const g=()=>(c=!0,y());d(a,h).then(g,g)})),typeof window<"u"&&(window.__NEXT_PRELOADREADY=p.preloadReady);const m=p}(qn)),qn}(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(f,p){for(var d in p)Object.defineProperty(f,d,{enumerable:!0,get:p[d]})}r(t,{noSSR:function(){return u},default:function(){return l}});const n=Re,o=n._(E),i=n._(Gm()),a=typeof window>"u";function c(f){return{default:(f==null?void 0:f.default)||f}}function u(f,p){if(delete p.webpack,delete p.modules,!a)return f(p);const d=p.loading;return()=>o.default.createElement(d,{error:null,isLoading:!0,pastDelay:!1,timedOut:!1})}function l(f,p){let d=i.default,m={loading:g=>{let{error:b,isLoading:A,pastDelay:_}=g;if(!_)return null;if(process.env.NODE_ENV!=="production"){if(A)return null;if(b)return o.default.createElement("p",null,b.message,o.default.createElement("br",null),b.stack)}return null}};f instanceof Promise?m.loader=()=>f:typeof f=="function"?m.loader=f:typeof f=="object"&&(m={...m,...f}),m={...m,...p};const h=m.loader,y=()=>h!=null?h().then(c):Promise.resolve(c(()=>null));return m.loadableGenerated&&(m={...m,...m.loadableGenerated},delete m.loadableGenerated),typeof m.ssr=="boolean"&&!m.ssr?(delete m.webpack,delete m.modules,u(d,m)):d({...m,loader:y})}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)})(Jn,Jn.exports);var Wm=Jn.exports,Vm=Wm;const Km=Vt(Vm);var eo={exports:{}},qt={exports:{}},Bs;function Xm(){return Bs||(Bs=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(u,l){for(var f in l)Object.defineProperty(u,f,{enumerable:!0,get:l[f]})}r(t,{DOMAttributeNames:function(){return n},isEqualNode:function(){return i},default:function(){return c}});const n={acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv",noModule:"noModule"};function o(u){let{type:l,props:f}=u;const p=document.createElement(l);for(const h in f){if(!f.hasOwnProperty(h)||h==="children"||h==="dangerouslySetInnerHTML"||f[h]===void 0)continue;const y=n[h]||h.toLowerCase();l==="script"&&(y==="async"||y==="defer"||y==="noModule")?p[y]=!!f[h]:p.setAttribute(y,f[h])}const{children:d,dangerouslySetInnerHTML:m}=f;return m?p.innerHTML=m.__html||"":d&&(p.textContent=typeof d=="string"?d:Array.isArray(d)?d.join(""):""),p}function i(u,l){if(u instanceof HTMLElement&&l instanceof HTMLElement){const f=l.getAttribute("nonce");if(f&&!u.getAttribute("nonce")){const p=l.cloneNode(!0);return p.setAttribute("nonce",""),p.nonce=f,f===u.nonce&&u.isEqualNode(p)}}return u.isEqualNode(l)}let a;process.env.__NEXT_STRICT_NEXT_HEAD?a=(u,l)=>{const f=document.querySelector("head");if(!f)return;const p=f.querySelectorAll('meta[name="next-head"]')||[],d=[];if(u==="meta"){const y=f.querySelector("meta[charset]");y&&d.push(y)}for(let y=0;y<p.length;y++){var m;const b=p[y].nextSibling;(b==null||(m=b.tagName)==null?void 0:m.toLowerCase())===u&&d.push(b)}const h=l.map(o).filter(y=>{for(let g=0,b=d.length;g<b;g++){const A=d[g];if(i(A,y))return d.splice(g,1),!1}return!0});d.forEach(y=>{var g;const b=y.previousSibling;if(b&&b.getAttribute("name")==="next-head"){var A;(A=y.parentNode)==null||A.removeChild(b)}(g=y.parentNode)==null||g.removeChild(y)}),h.forEach(y=>{var g;const b=document.createElement("meta");b.name="next-head",b.content="1",((g=y.tagName)==null?void 0:g.toLowerCase())==="meta"&&y.getAttribute("charset")||f.appendChild(b),f.appendChild(y)})}:a=(u,l)=>{const f=document.getElementsByTagName("head")[0],p=f.querySelector("meta[name=next-head-count]");if(process.env.NODE_ENV!=="production"&&!p){console.error("Warning: next-head-count is missing. https://nextjs.org/docs/messages/next-head-count-missing");return}const d=Number(p.content),m=[];for(let g=0,b=p.previousElementSibling;g<d;g++,b=(b==null?void 0:b.previousElementSibling)||null){var h;(b==null||(h=b.tagName)==null?void 0:h.toLowerCase())===u&&m.push(b)}const y=l.map(o).filter(g=>{for(let b=0,A=m.length;b<A;b++){const _=m[b];if(i(_,g))return m.splice(b,1),!1}return!0});m.forEach(g=>{var b;return(b=g.parentNode)==null?void 0:b.removeChild(g)}),y.forEach(g=>f.insertBefore(g,p)),p.content=(d-m.length+y.length).toString()};function c(){return{mountedInstances:new Set,updateHead:u=>{const l={};u.forEach(d=>{if(d.type==="link"&&d.props["data-optimized-fonts"]){if(document.querySelector('style[data-href="'+d.props["data-href"]+'"]'))return;d.props.href=d.props["data-href"],d.props["data-href"]=void 0}const m=l[d.type]||[];m.push(d),l[d.type]=m});const f=l.title?l.title[0]:null;let p="";if(f){const{children:d}=f.props;p=typeof d=="string"?d:Array.isArray(d)?d.join(""):""}p!==document.title&&(document.title=p),["meta","base","link","style","script"].forEach(d=>{a(d,l[d]||[])})}}}(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}(qt,qt.exports)),qt.exports}(function(e,t){"use client";Object.defineProperty(t,"__esModule",{value:!0});function r(x,P){for(var S in P)Object.defineProperty(x,S,{enumerable:!0,get:P[S]})}r(t,{handleClientScriptLoad:function(){return y},initScriptLoader:function(){return A},default:function(){return C}});const n=Re,o=nt,i=n._(Ks),a=o._(E),c=Eu(),u=Xm(),l=Oc(),f=new Map,p=new Set,d=["onLoad","onReady","dangerouslySetInnerHTML","children","onError","strategy","stylesheets"],m=x=>{if(i.default.preinit){x.forEach(P=>{i.default.preinit(P,{as:"style"})});return}if(typeof window<"u"){let P=document.head;x.forEach(S=>{let I=document.createElement("link");I.type="text/css",I.rel="stylesheet",I.href=S,P.appendChild(I)})}},h=x=>{const{src:P,id:S,onLoad:I=()=>{},onReady:$=null,dangerouslySetInnerHTML:w,children:N="",strategy:k="afterInteractive",onError:B,stylesheets:R}=x,q=S||P;if(q&&p.has(q))return;if(f.has(P)){p.add(q),f.get(P).then(I,B);return}const z=()=>{$&&$(),p.add(q)},U=document.createElement("script"),K=new Promise((W,F)=>{U.addEventListener("load",function(ne){W(),I&&I.call(this,ne),z()}),U.addEventListener("error",function(ne){F(ne)})}).catch(function(W){B&&B(W)});w?(U.innerHTML=w.__html||"",z()):N?(U.textContent=typeof N=="string"?N:Array.isArray(N)?N.join(""):"",z()):P&&(U.src=P,f.set(P,K));for(const[W,F]of Object.entries(x)){if(F===void 0||d.includes(W))continue;const ne=u.DOMAttributeNames[W]||W.toLowerCase();U.setAttribute(ne,F)}k==="worker"&&U.setAttribute("type","text/partytown"),U.setAttribute("data-nscript",k),R&&m(R),document.body.appendChild(U)};function y(x){const{strategy:P="afterInteractive"}=x;P==="lazyOnload"?window.addEventListener("load",()=>{(0,l.requestIdleCallback)(()=>h(x))}):h(x)}function g(x){document.readyState==="complete"?(0,l.requestIdleCallback)(()=>h(x)):window.addEventListener("load",()=>{(0,l.requestIdleCallback)(()=>h(x))})}function b(){[...document.querySelectorAll('[data-nscript="beforeInteractive"]'),...document.querySelectorAll('[data-nscript="beforePageRender"]')].forEach(P=>{const S=P.id||P.getAttribute("src");p.add(S)})}function A(x){x.forEach(y),b()}function _(x){const{id:P,src:S="",onLoad:I=()=>{},onReady:$=null,strategy:w="afterInteractive",onError:N,stylesheets:k,...B}=x,{updateScripts:R,scripts:q,getIsSsr:z,appDir:U,nonce:K}=(0,a.useContext)(c.HeadManagerContext),W=(0,a.useRef)(!1);(0,a.useEffect)(()=>{const ne=P||S;W.current||($&&ne&&p.has(ne)&&$(),W.current=!0)},[$,P,S]);const F=(0,a.useRef)(!1);if((0,a.useEffect)(()=>{F.current||(w==="afterInteractive"?h(x):w==="lazyOnload"&&g(x),F.current=!0)},[x,w]),(w==="beforeInteractive"||w==="worker")&&(R?(q[w]=(q[w]||[]).concat([{id:P,src:S,onLoad:I,onReady:$,onError:N,...B}]),R(q)):z&&z()?p.add(P||S):z&&!z()&&h(x)),U){if(k&&k.forEach(ne=>{i.default.preinit(ne,{as:"style"})}),w==="beforeInteractive")return S?(i.default.preload(S,B.integrity?{as:"script",integrity:B.integrity}:{as:"script"}),a.default.createElement("script",{nonce:K,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([S])+")"}})):(B.dangerouslySetInnerHTML&&(B.children=B.dangerouslySetInnerHTML.__html,delete B.dangerouslySetInnerHTML),a.default.createElement("script",{nonce:K,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([0,{...B}])+")"}}));w==="afterInteractive"&&S&&i.default.preload(S,B.integrity?{as:"script",integrity:B.integrity}:{as:"script"})}return null}Object.defineProperty(_,"__nextScript",{value:!0});const C=_;(typeof t.default=="function"||typeof t.default=="object"&&t.default!==null)&&typeof t.default.__esModule>"u"&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)})(eo,eo.exports);var Qm=eo.exports,Ym=Qm;const Zm=Vt(Ym),Jm=({children:e,ONE_TRUST:t})=>s.jsxs(s.Fragment,{children:[s.jsx(Zm,{src:"https://cdn.cookielaw.org/scripttemplates/otSDKStub.js",defer:!0,strategy:"afterInteractive","data-domain-script":t.siteId,type:"text/javascript"}),e]}),eh=Km(()=>Promise.resolve(Jm),{ssr:!1}),th={"snackbar-modifier":"_snackbar-modifier_1va2l_1"},dt=({size:e,adornment:t,title:r,subtitle:n,supportChildren:o,className:i,Z_INDEX_WAR:a,...c})=>s.jsxs(v.SnackBar.Structure,{...c,size:e,className:v.helpers.classNameConcat(th["snackbar-modifier"],i),width:360,style:{zIndex:a.snackbar},children:[s.jsx(v.SnackBar.Content,{adornment:t,title:r,subtitle:n}),o&&s.jsx(v.SnackBar.Support,{children:o})]});dt.displayName="SnackBar";const Hu=({children:e,contentState:t,entityKey:r})=>{const{url:n}=t.getEntity(r).getData();return n?s.jsx(Ne,{href:n,children:e}):e},rh={teamComponents:{AddToCart:Co,BackToTop:Bd,BuyPackage:Hm,...Rm,FreightCalculation:up,Header:au,Link:ze,Media:$e,ProductCard:Pe,UserMenu:Ro},template:{pdp:Nm},utils:{EventCollector:Fm,ExternalScripts:eh,LinkOrNotLink:yt,ObserverWrapper:Qt,SnackBarComponent:dt,DraftJsLinkWrapper:Hu}},nh=(e,t)=>{const r=e.map(o=>`'${o.source}'`).join(`,
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),f=require("react"),x=require("./Footer-okPVOqRy.js"),Pe=require("zustand"),d=require("@soma-vertical-web/core-components"),kr=require("js-cookie"),Ar=require("jose"),de=require("@soma-vertical-web/foundations"),pt=require("axios"),Tr=require("react-dom"),Q=require("draft-js"),ft=require("@date-fns/tz"),Ke=f.createContext({}),Mr=({data:e,children:n})=>t.jsx(Ke.Provider,{value:{tags:e==null?void 0:e.config},children:n}),Xe=()=>{const{tags:e}=f.useContext(Ke),n=f.useCallback(r=>{var l,i,c,u;const s=(i=(l=e==null?void 0:e.commercial)==null?void 0:l.items)==null?void 0:i.find(m=>{var h;return(h=r??[])==null?void 0:h.find(p=>p.id===m.key)}),o=(u=(c=e==null?void 0:e.institucional)==null?void 0:c.items)==null?void 0:u.find(m=>{var h;return(h=r??[])==null?void 0:h.find(p=>p.id===m.key)}),a=e==null?void 0:e.flagPdp;return{commercial:s,institucional:o,flagPdp:a}},[e]);return{tags:e,getAvailableProductTag:n}},Mt=({gridScrollBack:e})=>{f.useEffect(()=>{typeof window<"u"&&(e!=null&&e.refer)&&sessionStorage.setItem(e==null?void 0:e.refer,"true")},[])},Rt=f.createContext({}),Rr=({children:e,gridScrollBack:n})=>{const r=f.useRef(null);return Mt({gridScrollBack:n}),t.jsx(Rt.Provider,{value:{sizesContainerRef:r},children:e})},Or=()=>{const e=f.useContext(Rt);if(e===void 0)throw new Error("useContext(PDPContext) must be used within a PDPProvider");return e},K=(e,n=!0)=>Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL",minimumFractionDigits:n?2:0}).format(e),Ye=({valueInCents:e,hasFree:n,freeTaxMessage:r})=>e===0?n?r:K(0):K(e/100),Ot=({items:e,NAME_SPLIT_SYMBOL:n})=>{const r={price:0,listPrice:0,installments:{count:0,value:0}},s=(l,i)=>{var p;i&&(i.sellerId=l.sellerId,i.sellerName=l.sellerName,i.available=!0,i.isSellerDefault=l.sellerDefault);const{Price:c,ListPrice:u,PaymentOptions:{installmentOptions:m}}=l.commertialOffer;r.price=c,r.listPrice=u;const h=(p=m==null?void 0:m[0])==null?void 0:p.installments;if(h){const{count:_,value:g}=h[h.length-1];r.installments={count:_,value:g/100}}};let o=!0;const a=e.reduce((l,i)=>{var m;const c={name:i.name,sku:i.itemId,value:((m=i.Tamanho)==null?void 0:m[0])??x.splitNameAndSizeFromFullName(i.nameComplete??i.name,n).size,available:!1,sellerId:"",sellerName:"",isSellerDefault:!1},u=i.sellers.filter(h=>(h.sellerDefault&&h.commertialOffer.IsAvailable&&(c.available=!0,s(h,c)),h.commertialOffer.IsAvailable));return!c.isSellerDefault&&u.length>0&&(c.available=!0,s(u[0],{...c,sellerId:u[0].sellerId,sellerName:u[0].sellerName})),c.available===!1&&(o=!1),l.push(c),l},[]);return{...r,sizes:a,allSizesAvailable:o}},Lt=e=>e?!e.offers.offers.find(({quantity:n=0})=>n>0):!1,Qe=(e,n)=>{const r=e.find(s=>s.availability.includes("InStock")&&s.quantity&&s.listPrice>0&&s.seller.identifier===n);return r||e.find(s=>s.availability.includes("InStock")&&s.quantity&&s.listPrice>0)},Dt=e=>e.find(n=>n.imageLabel==="10"),zt=(e,n)=>{const r=/\/ids\/(\d+)\//,s=e.match(r);return s?e.replace(`/${s[1]}/`,`/${s[1]}-${n.width}-${n.height}/`):e},Bt=(e,n)=>{const r=/\/ids\/(\d+)-(\d+)-(\d+)\//,s=e.match(r);return s?e.replace(`/${s[1]}-${s[2]}-${s[3]}/`,`/${s[1]}-${n.width}-${n.height}/`):e},$t=({images:e,label:n})=>{const r=e.filter(s=>s.keywords===n.first||s.keywords===n.second||s.alternateName===n.first||s.alternateName===n.second);return r.length===0?[e[0]]:r},Lr=e=>{const[n,r]=e.split("/").map(Number);if(Number.isNaN(n)||Number.isNaN(r))throw new Error("[ERROR ASPECT RATIO IMAGE]: Invalid aspect ratio format");return r/n},Ft=(e,n,r)=>{n&&(e?(n.getAttribute("src")||(n.src=r??""),n.play()):n.pause())},Dr=Object.freeze(Object.defineProperty({__proto__:null,disableSKU:Lt,formatPriceToCurrency:K,freightParsePrice:Ye,getAspectRatio:Lr,getColorAndSizeFromSkuName:x.getColorAndSizeFromSkuName,getFirstImages:$t,getProductNameWithoutSku:x.getProductNameWithoutSku,getSKUName:x.getSKUName,getSkuInfos:Ot,getThumbImage:Dt,getValidOffer:Qe,removeSlashes:x.removeSlashes,resizingImg:zt,setVideoPlay:Ft,splitNameAndSizeFromFullName:x.splitNameAndSizeFromFullName,updatedResizedImg:Bt},Symbol.toStringTag,{value:"Module"})),Ut=f.createContext({}),zr=({children:e,productData:n,isKit:r,PDP_INFO:s,NAME_SPLIT_SYMBOL:o})=>{var R,S;const{sendDataLayerEvent:a,triggerSelectItemEventRef:l}=x.useEventContext(),{productId:i,productName:c,items:u,items:[{images:m,Videos:h}],description:p,["Composição"]:_="",productReference:g,categories:[C]}=n,{getAvailableProductTag:y}=Xe(),v=y(Object.entries(n.clusterHighlights).map(E=>({id:E[0],name:E[1]}))),N=C.slice(1,-1).split("/"),{installments:j,price:w,listPrice:b,sizes:I,allSizesAvailable:k}=Ot({items:u,NAME_SPLIT_SYMBOL:o}),D=Dt(m),F=[{label:`${s.product.description}`,value:"description",content:p},{label:`${s.product.materiais}`,value:"composition",content:_}],M=((S=x.getColorAndSizeFromSkuName((R=n.items)==null?void 0:R[0].name,o))==null?void 0:S.color)??n["Cores Filtráveis"][0]??"",B=()=>({commonData:{...n,sizes:I,price:w,listPrice:b,installments:j},customData:{installments:j==null?void 0:j.count,installment_value:Number(j==null?void 0:j.value).toFixed(2)}}),V=({sku:E,size:A})=>{const{commonData:P,customData:$}=B();a({functionKey:"productEvents",data:{event:"view_item",commonData:P,customData:{...$,...E&&{item_sku:E},...A&&{item_variant2:A}}}})};return f.useEffect(()=>{if(l.current.trigger){const{commonData:E,customData:A}=B();a({functionKey:"productEvents",data:{event:"select_item",commonData:E,customData:{...A,index:l.current.index}}}),l.current.trigger=!1}V({})},[]),t.jsx(Ut.Provider,{value:{productData:n,productId:i,productName:c,productReference:g,tag:v,items:u,sizes:I,allSizesAvailable:k,installments:j,price:w,listPrice:b,thumbImage:D,images:m,video:h[0],descriptionContent:F,breadcrumbList:N,isKit:r,colorName:M,handleViewItemEvent:V},children:e})},Je=()=>{const e=f.useContext(Ut);if(e===void 0)throw new Error("useContext(PDPDataContext) must be used within a PDPDataProvider");return e},ae=(e,n)=>Pe.create(r=>{const s=()=>r({value:e});return n&&n instanceof Set&&n.add(s),{value:e,actions:{setValue:o=>r({value:o}),reset:s}}}),_e={category:null,menuMobileIsOpen:!1,searchModalIsOpen:!1,userMenuIsOpen:!1},xe=new Set,Br=()=>{xe.forEach(e=>{e()})},qt=Pe.create((e,n)=>{const r=()=>e({value:_e.category});return xe.add(r),{value:_e.category,actions:{reset:r,setValue:s=>e(()=>({value:s})),updateValue:s=>{n().value!==s&&e({value:s})}}}}),ke=()=>qt(e=>e.value),re=()=>qt(e=>e.actions),Vt=ae(_e.menuMobileIsOpen,xe),Ze=()=>Vt(e=>e.value),ie=()=>Vt(e=>e.actions),Gt=ae(_e.searchModalIsOpen,xe),$r=()=>Gt(e=>e.value),et=()=>Gt(e=>e.actions),Ht=ae(_e.userMenuIsOpen,xe),Wt=()=>Ht(e=>e.value),ye=()=>Ht(e=>e.actions),Fr=Object.freeze(Object.defineProperty({__proto__:null,resetAllHeaderStores:Br,useActionsHeaderCategory:re,useActionsMenuMobileIsOpen:ie,useActionsSearchModalIsOpen:et,useActionsUserMenuIsOpen:ye,useGetHeaderCategoryStore:ke,useGetMenuMobileIsOpen:Ze,useGetSearchModalIsOpen:$r,useGetUserMenuIsOpen:Wt},Symbol.toStringTag,{value:"Module"})),ue={selectedSkuInfo:{productId:"",name:"",size:"",sku:"",sellerId:"",sellerName:"",available:!1,quantity:1},openLetMeKnow:!1,openMeasurements:!1,showBottomNavigation:!1,showNotify:!1},me=new Set,Ur=()=>{me.forEach(e=>{e()})},Kt=Pe.create(e=>{const n=()=>e({value:ue.selectedSkuInfo});return me.add(n),{value:ue.selectedSkuInfo,actions:{setValue:r=>e(s=>({value:{...s,...r}})),reset:n}}}),qr=()=>Kt(e=>e.value),Vr=()=>Kt(e=>e.actions),Xt=ae(ue.openLetMeKnow,me),Gr=()=>Xt(e=>e.value),Hr=()=>Xt(e=>e.actions),Yt=ae(ue.showNotify,me),Wr=()=>Yt(e=>e.value),Kr=()=>Yt(e=>e.actions),Qt=ae(ue.showBottomNavigation,me),Xr=()=>Qt(e=>e.value),Yr=()=>Qt(e=>e.actions),Jt=ae(ue.openMeasurements,me),Qr=()=>Jt(e=>e.value),Jr=()=>Jt(e=>e.actions),Zr=Object.freeze(Object.defineProperty({__proto__:null,resetAllPDPStores:Ur,useActionsPDPOpenLetMeKnow:Hr,useActionsPDPOpenMeasurements:Jr,useActionsPDPSelectedSkuInfo:Vr,useActionsPDPShowBottomNavigation:Yr,useActionsPDPShowNotify:Kr,useGetPDPOpenLetMeKnow:Gr,useGetPDPOpenMeasurements:Qr,useGetPDPSelectedSkuInfo:qr,useGetPDPShowBottomNavigation:Xr,useGetPDPShowNotify:Wr},Symbol.toStringTag,{value:"Module"})),Zt=f.createContext({}),es=({children:e,headerData:n,...r})=>{var m,h;const s=f.useRef(null),o=f.useRef(null),a=f.useRef(null),l=f.useRef(null),i=f.useRef(null),{mediatorRef:c,currentHeaderConfigsRef:u}=x.useGlobalContext();return(m=c.current)==null||m.subscribe("header:change_variant",p=>{var v,N,j;if(p&&u.current&&(u.current.bannerVariant=p),!s.current)return;const g=document.body.scrollTop>0,C=s.current.getAttribute("data-interactiveVariant"),y=g?C:p??((v=u.current)==null?void 0:v.bannerVariant)??"default";y!==((N=u.current)==null?void 0:N.headerVariant)&&(s.current.setAttribute("data-bottomdivider",String(g)),s.current.setAttribute("data-variant",String(y)),(j=c.current)==null||j.publish("herobanner:change_controllers_variant",y),u.current&&(u.current.headerVariant=y))}),(h=c.current)==null||h.subscribe("header:change_position",p=>{s.current&&(s.current.style.position=p)}),f.useEffect(()=>{const p=new AbortController,_=d.helpers.throttle(()=>{var C;return(C=c.current)==null?void 0:C.publish("header:change_variant",null)},200);document.body.addEventListener("scroll",_,{passive:!0,signal:p.signal});const g=C=>{var v;(v=C.target.closest("a"))==null||v.blur()};return s.current&&(s.current.addEventListener("click",g,{signal:p.signal}),s.current.addEventListener("touchend",g,{signal:p.signal})),()=>{p.abort()}},[]),t.jsx(Zt.Provider,{value:{headerData:n,structureRef:o,rootRef:s,tipbarRef:a,userMenuMobileRef:l,userMenuDesktopRef:i,...r},children:e})},L=()=>f.useContext(Zt),en=f.createContext({}),tn=({children:e})=>{const n=f.useRef(null),r=f.useRef(null),s=Ze(),o=f.useCallback(()=>{var a;{const l=(a=n.current)==null?void 0:a.querySelector("dialog");if(l){l.dataset.animation="out";const i=l.children[0];i.dataset.animation="out"}}},[]);return f.useEffect(()=>{var a;if(s)document.body.dataset.modalopen="true";else{document.body.dataset.modalopen="false";const l=(a=r.current)==null?void 0:a.querySelector("dialog");if(l){l.dataset.animation="out";const i=l.children[0];i.dataset.animation="out"}}},[s]),f.useEffect(()=>{r.current=document.body},[]),t.jsx(en.Provider,{value:{bodyRef:n,handleCloseSubMenu:o,documentBodyRef:r},children:e})},Ce=()=>f.useContext(en),ts=e=>{if(!e||typeof window>"u")return 0;const n=window.getComputedStyle(e);return parseInt(n.padding,10)},ns=(e,n,r)=>{if(!(e instanceof HTMLElement)||!(n instanceof HTMLElement))return{left:0,top:0};const s=n.getBoundingClientRect(),o=e.getBoundingClientRect(),a=e!=null&&e.parentElement?ts(e==null?void 0:e.parentElement):0;return{left:s.left+s.width/2-(o.width+a),top:s.top+s.height+r}},nn=f.createContext({}),rn=({children:e,delay:n=600,gap:r=20,...s})=>{const[o,a]=f.useState(!1),l=f.useRef(null),[i,c]=f.useState(!1),[u,m]=f.useState({left:0,top:0}),h=f.useCallback(()=>{c(!0),typeof window<"u"&&(l.current=window.setTimeout(()=>{a(!1),c(!1)},n))},[c,a,n]);return f.useEffect(()=>{if(typeof window>"u")return;const p=window.document.querySelector("#cart-button"),_=window.document.querySelector("#add-to-cart--tooltip");if(p&&_){const{left:g,top:C}=ns(_,p,r??0);m({left:g,top:C}),c(!1)}},[r,o]),t.jsx(nn.Provider,{value:f.useMemo(()=>({...s,...u,handleClose:h,isLeaving:i,isOpen:o,setIsOpen:a,setIsLeaving:c}),[s,u,h,i,o,a,c]),children:e})},le=()=>{const e=f.useContext(nn);if(e===void 0)throw new Error("useAddToCartContext must be used within a AddToCartProvider");return e},sn=f.createContext({}),rs=({children:e,CARTPROVIDER_MESSAGE_PRODUCT_REMOVE:n,...r})=>{const s=x.useCartStore(),{setRecentlyAdded:o}=x.useUIContext(),a=f.useRef(""),l=x.useGetNotificationsStore(),{addNotification:i,removeNotification:c}=x.useGetNotificationActions(),{addCoupon:u,addItem:m,addSellerCode:h,addMarketingData:p,emptyCart:_,isOpen:g,removeItem:C,shipping:y,shippingUpdate:v,toggleServiceToProduct:N,updateItemQuantity:j}=s;f.useEffect(()=>{const S=kr.get("lastMedias");if(s.id&&S&&a.current!==S){a.current=S;const E=new URLSearchParams(S),A=x.mountMarketingData(E);p(A)}},[s,p]);const w=f.useCallback(async(S,E)=>(E==="coupon"?u(S):h(S)).then(P=>{if(typeof P!="boolean"&&P instanceof Object){if(E==="seller"&&"value"in P){const{statusOk:$,value:z}=P,q=String(z??"").split(" - ");return x.getCode((q==null?void 0:q[0])??"",S,!!$)}return x.getCode(String(P.coupon),S,!0)}return x.getCode("","")}).catch(()=>Promise.resolve({code:400})),[u,h]),b=f.useCallback((S,E,A)=>{const{id:P}=S;j(P,E,A)},[j]),I=f.useCallback((S,E,A=!1)=>{if(!S)return;const{id:P}=S,$=x.findItemIndex(s.items,P);if($!==-1&&!A){const z=Number(s.items[$].quantity),q=s.items[$]?z+1:1;b(S,q,E)}else m({id:P,quantity:(S==null?void 0:S.quantity)??1,seller:S.seller});g||o(z=>[...z,S])},[m,b,s.items,g,o]),k=f.useCallback((S,E)=>{if(!S||!Array.isArray(S))return;o(P=>[...P,...S]);const A=S.map(P=>{const{id:$,quantity:z,seller:q}=P,W=x.findItemIndex(s.items,$),Pr=x.getQuantity(z??1,W);return{id:$,quantity:Pr,seller:q}});m(A,E)},[m,s.items,o]),D=f.useCallback(async(S,E,A)=>S?C(S).then(()=>(i(E??`${n}`,A),x.getCode(S,S))):Promise.resolve(x.getCode("","Product id required")),[i,C]),F=f.useCallback(()=>{s.items.length>0&&_()},[_,s.items]),M=f.useCallback((S,E="BRA")=>y(S,E),[y]),B=f.useCallback(S=>{S&&v(S)},[v]),V=f.useCallback(async(S,E,A)=>{const P=s.items.findIndex(z=>z.id===S);return s.items[P]&&P>=0?N(E,P,A??!1):!1},[s.items,N]),R=f.useCallback(async(S,E)=>j(S,E).then(A=>{if(Array.isArray(A)){const P=A.find($=>$.id===S);if(P&&(P==null?void 0:P.quantity)<E)return String(P.quantity)}return!1}),[j]);return t.jsx(sn.Provider,{value:f.useMemo(()=>({...r,addCouponSeller:w,addToCart:I,addItemsToCart:k,cartStore:s,notifications:l,clearCart:F,addNotification:i,isOpen:s.isOpen,removeNotification:c,removeToCart:D,setIsOpen:s.setIsOpen,shipping:M,shippingUpdateOption:B,toggleGiftItemCart:V,updateItemQuantity:R}),[r,w,I,k,l,F,i,s,c,D,M,B,V,R]),children:e})},Z=()=>{const e=f.useContext(sn);if(e===void 0)throw new Error("useCartContext must be used within a CartProvider");return e},on=f.createContext({}),tt=({children:e,fetch:n})=>{const r=f.useRef(!0),[s,o]=f.useState(null),[a,l]=f.useState(!1);return f.useEffect(()=>{(async()=>{r.current=!0;try{const c=await n();if(!c.ok)throw new Error("Failed to fetch data");const u=await c.json();o(u.data),r.current=!1}catch{r.current=!0,l(!0)}})()},[n]),t.jsx(on.Provider,{value:f.useMemo(()=>({data:s,isLoading:r.current??!1,isError:a}),[s,a,r]),children:e})},nt=()=>{const e=f.useContext(on);if(e===void 0)throw new Error("useProductsContext must be used within a useRootContext");return e},an=f.createContext({}),ln=({children:e,sort:n,state:r,count:s,collectionId:o,CONSTANTS:a})=>{const l=f.useMemo(()=>{var i;return o?[{key:"productclusterids",value:o.toString()}]:(i=r.base)!=null&&i.length?r.base.slice(1).split("/").map((c,u)=>({key:`category-${u+1}`,value:c})):[]},[r.base,o]);return t.jsx(an.Provider,{value:f.useMemo(()=>({state:{...r,facets:[...l,...r.facets??[]]},sort:n,count:s??a.ITEMS_PER_PAGE}),[l,s,n,r]),children:e})},rt=()=>{const e=f.useContext(an);if(e===void 0)throw new Error("useSearchContext must be used within a SearchProvider");return e},cn=f.createContext({}),ss=({children:e,searchParams:n,selectedFacets:r})=>{const{data:s,...o}=nt(),{router:a}=x.useNextContext(),l=f.useCallback((h,p)=>{if(p){if(h.key.toLocaleLowerCase()==="price"){const _=p.getAll("facets");p.delete("facets"),_.forEach(g=>{const[C]=g.split("/");C!==h.key&&p.append("facets",g)})}p.set("page","1"),p.append("facets",`${h.key}/${h.value}`),a.push(`?${p.toString()}`)}},[a]),i=f.useCallback(()=>{const h=new URLSearchParams;h.set("sort",x.PLP_FILTERS_SORT.default_option),h.set("page","1"),a.push(`?${h.toString()}`)},[a]),c=f.useCallback((h,p)=>{if(!p||!p.has&&!p.has("facets"))return;const _=p.getAll("facets");p.delete("facets"),p.set("page","1"),_.forEach(g=>{const[C,y]=g.split("/");(C!==h.key||y!==h.value)&&p.append("facets",g)}),a.push(`?${p.toString()}`)},[a]),u=f.useCallback(h=>{const p=new URLSearchParams(x.convertSearchParams(n));for(const[,_]of p.entries()){const[g,C]=_.split("/");if(g===h.key&&C===h.value)return c(h,p)}return l(h,p)},[l,c,n]),m=f.useCallback(h=>{const p=new URLSearchParams(x.convertSearchParams(n));p.set("sort",h.replace("_",":")),a.push(`?${p.toString()}`)},[a,n]);return t.jsx(cn.Provider,{value:f.useMemo(()=>({...o,breadcrumb:s&&"breadcrumb"in s?s==null?void 0:s.breadcrumb:[],deleteAllFacets:i,facets:s&&"facets"in s?s==null?void 0:s.facets:[],selectedFacets:r,onToggleFacet:u,onSort:m,searchParams:n}),[s,i,m,u,o,r,n]),children:e})},os=({children:e,searchParams:n,forceUpdate:r})=>{const{state:s}=rt();return t.jsx(tt,{fetch:()=>fetch("/api/search/facets",{method:"POST",body:JSON.stringify({...s,forceUpdate:r}),priority:"low"}),children:t.jsx(ss,{selectedFacets:(s==null?void 0:s.facets)??[],searchParams:n,children:e})})},as=()=>{const e=f.useContext(cn);if(e===void 0)throw new Error("useFacetsContext must be used within a FacetsProvider");return e},dn=f.createContext({}),is=({children:e})=>{const{data:n,...r}=nt(),[s,o]=f.useState(0),{sendDataLayerEvent:a}=x.useEventContext();return f.useEffect(()=>{if(n&&"pagination"in n&&n.products.length>0){a({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:n.products}}});const l=n.pagination.count;l&&Number.isInteger(l)&&o(l)}},[n,a,o]),t.jsx(dn.Provider,{value:f.useMemo(()=>({...r,products:n&&"products"in n?n==null?void 0:n.products:[],pagination:n&&"pagination"in n?n==null?void 0:n.pagination:x.SEARCH_PAGE_DEFAULT_PAGINATION,total:s}),[n,r,s]),children:e})},ls=({children:e,query:n,state:r,selectedFacets:s,forceUpdate:o})=>t.jsx(tt,{fetch:()=>fetch("/api/search/product",{method:"POST",body:JSON.stringify({...r,query:n,forceUpdate:o,facets:s??[]})}),children:t.jsx(is,{state:r,children:e})}),cs=()=>{const e=f.useContext(dn);if(e===void 0)throw new Error("useProductsContext must be used within a ProductsProvider");return e},un=f.createContext({}),ds=({children:e,term:n})=>{const[r,s]=f.useState([]),[o,a]=f.useState(!1);return f.useEffect(()=>{if(!n){s([]);return}(async()=>{a(!0);try{const i=await fetch("/api/search/suggestedTerms",{method:"POST",body:JSON.stringify({query:n,locale:"pt-BR"})}),{data:c}=await i.json();s((c==null?void 0:c.searches)||[])}catch(i){console.error("Erro ao buscar sugestões:",i)}})()},[n]),t.jsx(un.Provider,{value:f.useMemo(()=>({suggestedTerms:r,loading:o,setLoading:a}),[r,o]),children:e})},us=({children:e,...n})=>t.jsx(ds,{...n,children:e}),ms=()=>{const e=f.useContext(un);if(!e)throw new Error("useSuggestedTermsContext must be used within a SuggestedTermsProvider");return e},mn=f.createContext({searches:[],isLoading:!1,error:null}),ps=({children:e})=>{const[n,r]=f.useState([]),[s,o]=f.useState(!0),[a,l]=f.useState(null);return f.useEffect(()=>{(async()=>{try{o(!0);const c=await fetch("/api/search/topSearch");if(!c.ok)throw new Error(`Erro ao buscar os dados: ${c.status}`);const u=await c.json();r(u.data.searches||[])}catch(c){l(c instanceof Error?c.message:"Erro desconhecido")}finally{o(!1)}})()},[]),t.jsx(mn.Provider,{value:f.useMemo(()=>({searches:n,isLoading:s,error:a}),[n,s,a]),children:e})},fs=()=>{const e=f.useContext(mn);if(!e)throw new Error("useTopSearches must be used within a TopSearchesProvider");return e},pn=f.createContext({}),hs=({children:e,slug:n,searchParams:r,collectionId:s,itemsPerPage:o=24})=>{const{pathname:a}=x.useNextContext(),[l,i]=f.useState(!1),c=f.useMemo(()=>{const m=new URL(a,"http://localhost"),h=Array.isArray(r==null?void 0:r.facets)?r.facets:[(r==null?void 0:r.facets)??""],p=(r==null?void 0:r.page)??"1",_=(r==null?void 0:r.sort)??(s?"":x.PLP_FILTERS_SORT.default_option);return m.searchParams.set("page",String(p)),m.searchParams.set("sort",String(_)),r!=null&&r.query?(m.searchParams.set("query",r.query),m):(m.searchParams.set("base",Array.isArray(n)?n.join("/"):n),m.searchParams.set("facets",h.join(",")),m)},[s,a,r,n]),u=f.useMemo(()=>{if(Array.isArray(r==null?void 0:r.facets))return x.parseSearchState(c,r.facets);const m=r!=null&&r.facets?[r==null?void 0:r.facets]:[];return x.parseSearchState(c,m)},[c,r]);return t.jsx(pn.Provider,{value:f.useMemo(()=>({openFilters:l,setOpenFilters:i}),[l,i]),children:t.jsx(ln,{CONSTANTS:{ITEMS_PER_PAGE:o},state:f.useMemo(()=>({...u}),[u]),collectionId:s,children:e})})},gs=()=>{const e=f.useContext(pn);if(e===void 0)throw new Error("usePLPContext must be used within a PLPProvider");return e},ze=(e,n)=>{if(e===n)return!0;if(e==null||n==null||typeof e!="object"||typeof n!="object")return!1;if(Array.isArray(e))return!Array.isArray(n)||e.length!==n.length?!1:e.every((o,a)=>ze(o,n[a]));if(Array.isArray(n))return!1;const r=Object.keys(e),s=Object.keys(n);return r.length!==s.length?!1:r.every(o=>Object.prototype.hasOwnProperty.call(n,o)&&ze(e[o],n[o]))},_s=(e,n,r="page")=>Object.keys(n).some(s=>s===r?!1:!ze(n[s],e[s])),ht=async e=>{const n=await fetch("/api/search/product",{method:"POST",body:JSON.stringify(e),priority:"high"});if(!n.ok)throw new Error("[FAILED TO FETCH DATA]");const r=await n.json();return r==null?void 0:r.data},xs=()=>({node:{sku:"",gtin:"",name:"...",description:"",releaseDate:"",slug:"",video:null,categories:[],categoryId:"",categoriesIds:[],id:"skeleton",brand:{name:""},seo:{title:"",description:"",canonical:""},cluster:{generals:[],highlights:[]},availability:{status:!0},breadcrumbList:{itemListElement:[]},image:[{alternateName:"1",url:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR4nGNgYAAAAAMAAWgmWQ0AAAAASUVORK5CYII=",keywords:"1"},{alternateName:"10",url:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR4nGMAAQAABQABDQottgAAAABJRU5ErkJggg==",keywords:"10"}],offers:{lowPrice:1,highPrice:0,offers:[{availability:"true",listPrice:0,price:0,priceValidUntil:"",priceCurrency:"BRL",itemCondition:"",quantity:1,seller:{identifier:"1"}}],priceCurrency:"BRL"},isVariantOf:{productGroupID:"",hasVariant:[{additionalProperty:[{name:"Tamanho",value:"...",valueReference:"SPECIFICATION",propertyID:""}],name:"...",offers:{offers:[{availability:"https://schema.org/InStock",listPrice:0,price:0,quantity:1,seller:{identifier:"1"}}]},sku:"1",slug:"1",productId:"1"}],name:"",additionalProperty:[],skuVariants:null},installments:{count:2,value:1}}}),ys=(e,n,r,s=24)=>{const o=new Set,a=[];if(!Array.isArray(e)||e.length===0)return{taken:o,placedBanners:a};const l=n*s*r;for(const i of e){let c=Number(i.position_grid),u=!1;for(;c<l;){const m=c%r;if(m+i.columns>r){c+=r-m;continue}if(!Array.from({length:i.columns}).some((_,g)=>o.has(c+g))){for(let _=0;_<i.columns;_++)o.add(c+_);a.push(c),u=!0;break}c++}u||console.info(`[PLP INFINITE FAILED BANNER POSITION]: pos=${i.position_grid}, cols=${i.columns}`)}return{taken:o,placedBanners:a}},gt=(e,n,r,s=24)=>{const{placedBanners:o,taken:a}=ys(e??[],n,r),l=[];let i=0;try{for(;l.length<n*s;)a.has(i)||l.push(i),i++;return{banners:o,products:l}}catch(c){console.info(`[PLP INFINITE FAILED TO GEN POSITIONS]: page=${n}`,c)}return{banners:[],products:l}},Te=(e,n,r=24)=>Array.from({length:e},(s,o)=>{const a=o+1;return{loading:e===a,page:a,pagination:n!=null&&n.products.length&&e===a?n==null?void 0:n.pagination:fn(),products:n!=null&&n.products.length&&e===a?n==null?void 0:n.products:Array.from({length:r},()=>xs())}}),Cs=(e,n)=>[...e,{loading:!1,page:n,pagination:fn(),products:[]}],fn=()=>({nextPage:!1,previousPage:!1,startCursor:"0",endCursor:"1",count:1,total:1}),vs=50,bs=Pe.create((e,n)=>{const r=l=>Math.min(l,vs),s=async(l,i)=>{const c=r(l.page);try{const u=await ht({...l,page:c});o(c,m=>i?i(m,u):{...m,...u})}catch(u){console.error(`[PDC - SCROLL INFINITE FAILED TO FETCH PAGE ${c}]: ${u}`),o(c,m=>({...m,loading:!1}))}},o=(l,i)=>{e({load:!0,pages:n().pages.map(c=>c.page===l?i(c):c)})},a=async(l,i)=>{await s(l,(c,u)=>(typeof i=="function"&&i(u),{...c,...u,loading:!0}))};return{banners:[],load:!1,pages:[],total:0,positions:[],products:[],createPages:async(l,i,c,u)=>{var h,p,_;const m=r(Number(l==null?void 0:l.page));e({...i,pages:Te(m,void 0,u)});try{const g=await ht({...l,page:m});if(g){if(!g.products.length&&((h=g==null?void 0:g.pagination)==null?void 0:h.total)<m){a({...l,page:(p=g==null?void 0:g.pagination)==null?void 0:p.total},c),e({pages:Te((_=g==null?void 0:g.pagination)==null?void 0:_.total)});return}typeof c=="function"&&c(g),e({load:!0,pages:Te(m,g),total:Number(g.pagination.count)})}}catch(g){console.error(`[PDC - SCROLL INFINITE TO CREATE PAGES]: page ${m} ${g}`)}},addPage:(l,i,c)=>{const{pages:u}=n(),m=r(l==null?void 0:l.page);u.some(h=>h.page===m)||(e({...i,pages:Cs(u,m)}),a(l,c))},updateProducts:(l,i)=>{const c=n().pages.find(u=>u.page===r(l==null?void 0:l.page));c!=null&&c.loading||a(l,i)}}}),hn=f.createContext({}),js=({banners:e,children:n,itemsPerPage:r=24,searchParams:s})=>{const{router:o}=x.useNextContext(),{sendDataLayerEvent:a}=x.useEventContext(),{isMobile:l}=x.useGlobalContext(),{state:i}=rt(),{addPage:c,createPages:u,updateProducts:m,...h}=bs(),p=l?8:16,_=l?2:4,g=f.useRef(!1),C=f.useRef(i),y=f.useCallback(w=>{w&&"pagination"in w&&a({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:w.products}}})},[a]),v=f.useCallback(w=>{if(w.pagination.nextPage===!0){const b=w.page+1,I=gt(e,b,_,r);c({...i,page:b},I,y)}},[c,e,y,_,r,i]),N=f.useCallback(w=>{w.loading===!1&&m({...i,page:w.page},y)},[y,m,i]),j=f.useCallback(w=>{const b=new URLSearchParams(s);w.page!==Number(b.get("page")??1)&&(b.set("page",String(w.page)),o.replace(`?${b.toString()}`,{scroll:!1}))},[o,s]);return f.useEffect(()=>{const w=!g.current,b=_s(C.current,i),I=gt(e,i.page,_);w?u(i,I,y,r):b&&(u(i,I,y,r),C.current=i),g.current=!0},[e,u,y,_,r,i]),t.jsx(hn.Provider,{value:f.useMemo(()=>({...h,addPage:c,addNewPage:v,createPages:u,gap:p,columns:_,updatePage:N,updateProducts:m,updateParamPage:j}),[c,v,u,p,_,h,N,m,j]),children:n})},Ss=()=>{const e=f.useContext(hn);if(e===void 0)throw new Error("PLPInfiniteScrollContext must be used within a ScrollInfiniteProvider");return e};function gn(e){const r=decodeURIComponent(window.document.cookie).split(";");for(const s of r){const[o,a]=s.trim().split("=");if(o===e)return a}}function st(e,n,r={}){const o={...{path:"/",expires:new Date(Date.now()+36e5)},...r};let a=`${encodeURIComponent(e)}=${encodeURIComponent(n??"")}`;for(const l in o)o[l]!==void 0&&(a+=`; ${l}`,l==="expires"?a+=`=${o[l].toUTCString()}`:typeof o[l]=="boolean"?a+=`; ${o[l]?"true":"false"}`:a+=`=${o[l]}`);window.document.cookie=a}const Ns=()=>{const{sendDataLayerEvent:e}=x.useEventContext(),{user:n}=ot(),{cartStore:r}=Z();return f.useEffect(()=>{if(!n)return;(async()=>{const{userId:o,email:a,firstName:l,lastName:i,phone:c,homePhone:u,postalCode:m,street:h,number:p,city:_,gender:g}=n,C=new TextEncoder().encode(o),y=await crypto.subtle.digest("SHA-256",C),N=Array.from(new Uint8Array(y)).map(j=>j.toString(16).padStart(2,"0")).join("");e({functionKey:"readyEvents",data:{readyData:{user_id:N,email:a,first_name:l,last_name:i,phone:c||u,zip:m,street:h,street_number:p,city:_,gender:g,orderform_id:r==null?void 0:r.id}}})})()},[n,r.id]),null},_n=f.createContext({amount:null,boxes:null,toExpire:null,loading:!0,logout:()=>null,getCurrentCredits:()=>({credits:0,cashback:0})}),Is=({children:e,AUTH_TOKEN_COOKIE:n})=>{const[r,s]=f.useState({amount:null,boxes:null,toExpire:null,loading:!0}),o=f.useCallback(async()=>{try{await fetch("/api/user",{priority:"low"}).then(i=>i.json()).then(i=>{const{userCredits:c,...u}=i;s({amount:c==null?void 0:c.amount,boxes:c==null?void 0:c.boxes,toExpire:c==null?void 0:c.toExpire,user:u,loading:!1})})}catch(i){console.error("my credits request",i),s({...r,loading:!1})}},[s]),a=f.useCallback(()=>{st(n),o()},[o]),l=f.useCallback(()=>r.boxes?r.boxes.reduce((i,c)=>c.gift_card_box.refid==="C1643"?(i.cashback+=c.amount,i):(i.credits+=c.amount,i),{cashback:0,credits:0}):{cashback:0,credits:0},[r]);return f.useEffect(()=>{o()},[o]),t.jsxs(_n.Provider,{value:f.useMemo(()=>({...r,getCurrentCredits:l,logout:a}),[r,l,a]),children:[t.jsx(Ns,{}),e]})},ot=()=>{const e=f.useContext(_n);if(e===void 0)throw new Error("useContext(SessionContext) must be used within a SessionProvider");return e},Es={contexts:{addToCart:{hook:le,provider:rn},cart:{hook:Z,provider:rs},cms:{FlagsAndTags:{context:Ke,hook:Xe,provider:Mr}},events:{hook:x.useEventContext,provider:x.EventProvider},global:{hook:x.useGlobalContext,provider:x.GlobalProvider,mediator:x.Mediator},header:{hook:L,provider:es},menuMobile:{hook:Ce,provider:tn},next:{hook:x.useNextContext,provider:x.NextProvider},pdp:{provider:Rr,hook:Or},plp:{provider:hs,hook:gs},PLPContent:{provider:x.PLPContentProvider,hook:x.usePLPContent},plpInfinite:{provider:js,hook:Ss},pdpdata:{hook:Je,provider:zr},searchFacets:{hook:as,provider:os},searchProducts:{hook:cs,provider:ls},searchRoot:{hook:nt,provider:tt},searchSearch:{hook:rt,provider:ln},searchSuggestedTerms:{hook:ms,provider:us},searchTopSearchs:{hook:fs,provider:ps},session:{hook:ot,provider:Is},ui:{hook:x.useUIContext,provider:x.UIProvider}},hooks:{useBackPDC:Mt},stores:{cart:x.cart,header:Fr,pdp:Zr}},ws=e=>e.normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\s+/g,"-").toLowerCase().trim();function Ps(e,n=1e3){let r=!1;return(...s)=>{r||(e(...s),r=!0,setTimeout(()=>{r=!1},n))}}function ks(e,n=1e3){let r;return(...s)=>{clearTimeout(r),r=setTimeout(()=>{e(...s)},n)}}const xn=(e,n)=>n.getTime()>e.getTime()?Math.abs(n.getTime()-e.getTime()):0,fe=(e,n)=>Math.floor(n==="days"?e/(1e3*60*60*24):n==="hours"?e%(1e3*60*60*24)/(1e3*60*60):n==="minutes"?e%(1e3*60*60)/(1e3*60):e%(1e3*60)/1e3),As=e=>{const n=Ar.decodeJwt(e??"");return{email:n.sub,userId:n.userId}},Ts=["name","email","phone","date","cpf","cep"],_t={email:/\S+@\S+\.\S+/,name:new RegExp("^\\p{L}+( \\p{L}+)*$","u"),phone:/^\d{10,11}|\(\d{2}\)\s?\d{4,5}-\d{4}$/,date:/^\d{6,8}|^\d{2}\/\d{2}\/\d{2,4}$/,cep:/^\d{5}[-]?\d{3}$/,cpf:/^\d{11}|\d{3}\.\d{3}\.?\d{3,5}\-[\d]{2}$/},Ms=({type:e,input:n,required:r=!1})=>{if(typeof n!="string"||!r&&n===""||!_t[e])return!0;const s=n.trim();return _t[e].test(s)},Rs=e=>{const n=/\/(\d+)-\d+-\d+\/(.+?)\./,r=typeof e=="string"?e.match(n):null;return r?r[2].replace(/-/g," "):x.DEFAULT_IMAGE_ALT_TEXT},Os=Object.freeze(Object.defineProperty({__proto__:null,FieldTypes:Ts,debounce:ks,getAltTextFromUrl:Rs,getAuthenticatedUser:As,getCookie:gn,getDaysHoursMinutesSeconds:fe,getMilliSeconds:xn,removeAccentsAndReplaceSpaces:ws,setCookie:st,throttle:Ps,validateInput:Ms},Symbol.toStringTag,{value:"Module"})),Ls={cart:x.cart$1,events:x.events,product:Dr,utils:Os},at={helpers:Ls},H={"add-to-cart--card":"_add-to-cart--card_4v41y_1","add-to-cart--card--content":"_add-to-cart--card--content_4v41y_7","add-to-cart--card--name":"_add-to-cart--card--name_4v41y_16","add-to-cart--card--price-quantity":"_add-to-cart--card--price-quantity_4v41y_46","add-to-cart--card--style-size":"_add-to-cart--card--style-size_4v41y_53","add-to-cart--content":"_add-to-cart--content_4v41y_71","add-to-cart--content--title":"_add-to-cart--content--title_4v41y_78","add-to-cart--footer":"_add-to-cart--footer_4v41y_102","add-to-cart--footer--total":"_add-to-cart--footer--total_4v41y_108","add-to-cart--items":"_add-to-cart--items_4v41y_148","add-to-cart--tooltip":"_add-to-cart--tooltip_4v41y_198","add-to-cart__modal":"_add-to-cart__modal_4v41y_211"},yn=({brand:e,className:n,name:r,...s})=>t.jsxs("div",{...s,className:d.helpers.classNameConcat(H["add-to-cart--card--name"],n),children:[t.jsx(d.Tag,{style:{textTransform:"uppercase"},size:"small",variant:"quaternary",title:e,children:e}),t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{alignContent:"flex-start",alignItems:"flex-start",children:t.jsx("p",{className:"typography-style-body-md",children:r})})})]});yn.displayName="AddToCart.Card.Name";const Cn=({className:e,listPrice:n,price:r,quantity:s,productId:o,...a})=>{const l=K(r/100),i=K(n/100);return t.jsx("div",{...a,className:d.helpers.classNameConcat(H["add-to-cart--card--price-quantity"],e),children:t.jsx(d.ProductInfo.Root,{size:"small",layout:"vertical",children:t.jsx(d.ProductInfo.Wrapper,{size:"small",layout:"vertical",children:t.jsx(d.ProductInfo.ValuesWrapper,{children:r!==n?t.jsxs(t.Fragment,{children:[t.jsx(d.ProductInfo.Price,{label:"originalPrice",value:l,size:"small"},"price-list"),t.jsx(d.ProductInfo.Price,{label:"discountPrice",value:i,size:"small"},"price-low")]}):t.jsx(d.ProductInfo.Price,{label:"defaultPrice",value:i,size:"small"},"price-low")})})})})};Cn.displayName="AddToCart.Card.PriceQuantity";const Ds="_skeleton_12b79_1",zs={skeleton:Ds},Bs=({style:e})=>t.jsx("div",{style:e,className:zs.skeleton}),$s="_image_lypfr_1",Fs={image:$s},Us=({alt:e,className:n,objectFit:r,...s})=>{const{nextimage:o}=x.useNextContext();return t.jsx(o,{quality:90,...s,alt:e??"",className:d.helpers.classNameConcat(Fs.image,n),"data-object-fit":r??"cover"})},qs=({videoRef:e,...n})=>t.jsx("video",{...n,ref:e,children:t.jsx("track",{kind:"captions"})}),J={Image:Us,Video:qs},vn=({className:e,productGroupID:n,size:r,texture:s,...o})=>{const{CONSTANTS:{TEXTURE_IMAGE:a,TOGGLE_STYLE_MODIFIER:l}}=le(),[i,c]=f.useState(s??"");return f.useEffect(()=>{i||fetch("/api/catalog/product/info",{method:"POST",priority:"low",body:JSON.stringify({ids:[n]})}).then(u=>u.json()).then(u=>{const m=u.data[0].items[0];if(m){const h=m.images.find(p=>a.includes(p.imageLabel));h!=null&&h.imageUrl?c(h.imageUrl):c(m.images[0].imageUrl)}}).catch(u=>{console.error(u)})},[i,n]),t.jsxs("div",{...o,className:d.helpers.classNameConcat(H["add-to-cart--card--style-size"],e),children:[t.jsx(d.ToggleStyle.Wrapper,{size:"x-small",style:l,children:t.jsx(d.ToggleStyle.Texture,{children:i?t.jsx(J.Image,{alt:"",src:i??"",width:164,height:164,style:l}):t.jsx(Bs,{})})}),t.jsx(d.Utils.Divider,{direction:"vertical",size:"medium",style:{height:24}}),r&&t.jsxs(d.ToggleSize.Wrapper,{size:"small",title:"wrapper-texture",children:[t.jsx(d.ToggleSize.DisabledAdornment,{title:"disabled-adornment-texture"}),t.jsx(d.ToggleSize.Text,{children:r})]})]})};vn.displayName="AddToCart.Card.StyleSize";const{helpers:Vs}=at,bn=({className:e,item:n,texture:r,...s})=>{const{itemOffered:{name:o,brand:a,skuName:l,isVariationOf:{productGroupID:i}},quantity:c,price:u,sellingPrice:m}=n,{CONSTANTS:{NAME_SPLIT_SYMBOL:h}}=le(),{size:p}=Vs.product.getColorAndSizeFromSkuName(l??o,h);return t.jsxs("div",{...s,className:d.helpers.classNameConcat(H["add-to-cart--card--content"],e),children:[t.jsx(yn,{brand:a.name,name:o}),t.jsx(Cn,{price:u,listPrice:m,quantity:c,productId:n.id}),t.jsx(vn,{size:p,texture:r,productGroupID:i})]})};bn.displayName="AddToCart.Card.Content";const jn=({image:e,thumbnail:n=!1})=>t.jsx(J.Image,{alt:e.alternateName??"image","data-thumbnail":n,height:n?152:120,src:e.url,width:n?152:94});jn.displayName="AddToCart.Card";const Sn=({className:e,item:n,texture:r,thumbnail:s,...o})=>{const{itemOffered:{image:[a]}}=n,l=Bt(a.url,{width:200,height:300});return t.jsxs("div",{...o,className:d.helpers.classNameConcat(H["add-to-cart--card"],e),children:[t.jsx(jn,{image:{alternateName:a.alternateName||"Produto",url:l||""},thumbnail:s}),!s&&t.jsx(bn,{item:n,texture:r})]})};Sn.displayName="AddToCart.Card";const Nn=({className:e,children:n,title:r,...s})=>t.jsxs("div",{...s,className:d.helpers.classNameConcat(H["add-to-cart--content"],e),children:[t.jsx("div",{className:H["add-to-cart--content--title"],children:r&&t.jsx("h2",{children:r})}),n,t.jsx(oe.Footer,{})]});Nn.displayName="AddToCart.Layout.Content";const In=({className:e,...n})=>{var _,g;const{isMobile:r,handleClose:s,CONSTANTS:{ADD_TO_CART:o}}=le(),{cartStore:{totalizers:a},setIsOpen:l}=Z(),i=(_=a.find(C=>C.id==="Discounts"))==null?void 0:_.value,c=((g=a.find(C=>C.id==="Items"))==null?void 0:g.value)??0,u=a.find(C=>C.id==="Shipping"),h=(c-Math.abs(i??0)+((u==null?void 0:u.value)??0))/100,p=K(h??0);return t.jsxs("div",{...n,className:d.helpers.classNameConcat(H["add-to-cart--footer"],e),children:[t.jsxs("div",{className:H["add-to-cart--footer--total"],children:[t.jsx("span",{children:"Subtotal:"}),t.jsx("span",{children:p})]}),t.jsx(d.Button,{size:"medium",variant:"primary","data-close":!0,onClick:()=>l(!0),children:o.footer.bag}),r?t.jsx(d.Button,{"data-close":!0,size:"medium",variant:"tertiary",children:o.footer.keep_buying}):t.jsx(d.Button,{onClick:()=>s(),size:"medium",variant:"tertiary",children:o.footer.keep_buying})]})};In.displayName="AddToCart.Layout.Footer";const En=({children:e,className:n,thumbnail:r=!1,...s})=>{const{cartStore:{options:o}}=Z(),{recentlyAddedProducts:a}=x.useUIContext(),l=a.length>3?4:a.length;return t.jsxs("div",{...s,className:H["add-to-cart--items"],"data-thumbnail":r,children:[Array.isArray(a)&&a.filter((i,c)=>c<l).map(i=>{var u;const c=(u=o==null?void 0:o.find(m=>m.id===i.itemOffered.isVariationOf.productGroupID))==null?void 0:u.texture;return t.jsx(oe.Card,{item:i,thumbnail:r,texture:c},i.itemOffered.sku)}),e]})};En.displayName="AddToCart.Layout.Items";const wn=({children:e,Z_INDEX_WAR:n})=>{const{isOpen:r,setIsOpen:s}=le(),{isMobile:o}=x.useGlobalContext();return t.jsxs(d.Modal.Root,{"data-modal":"add-to-cart--modal",className:H["add-to-cart__modal"],isMobile:o??!1,isOpen:r,setIsOpen:s,variant:"sideBottom",style:{zIndex:n.modal},children:[t.jsx(d.Modal.Header,{navigation:"top",children:t.jsx(d.Modal.Controls,{navigation:"top",isMobile:!0})}),t.jsx(d.Modal.Body,{children:e})]})};wn.displayName="AddToCart.Modal";const Gs=({children:e})=>{const{count:n,handleClose:r,setIsOpen:s}=le(),o=f.useRef(n);return f.useEffect(()=>{n>o.current&&s(!0),n<o.current&&o.current>=1&&r(),o.current=n},[n,r,s]),t.jsx(t.Fragment,{children:e})},Pn=({children:e,component:n,CONSTANTS:r,...s})=>{const{recentlyAddedProducts:o}=x.useUIContext(),{isMobile:a}=x.useGlobalContext(),l=o.length>3?4:o.length;return t.jsx(rn,{...s,count:l,isMobile:a,CONSTANTS:r,children:t.jsx(Gs,{children:a?t.jsxs(t.Fragment,{children:[t.jsx(oe.Modal,{Z_INDEX_WAR:r.Z_INDEX_WAR,children:n}),e]}):t.jsx(oe.Tooltip,{component:n,style:{width:350},Z_INDEX_WAR:r.Z_INDEX_WAR,children:e})})})};Pn.displayName="AddToCart.Root";const kn=({children:e,component:n,Z_INDEX_WAR:r,...s})=>{const{contentRef:o,left:a,isLeaving:l,target:i,isOpen:c,top:u}=le();return t.jsx(d.Tooltip.Root,{arrow:"top-right",component:t.jsx("div",{...s,ref:o,children:n}),id:"add-to-cart--tooltip",className:H["add-to-cart--tooltip"],style:{zIndex:r.modal},isLeaving:l,isOpen:c,left:a,size:"medium",position:"top",top:u,children:t.jsx("div",{className:H["add-to-cart--tooltip"],ref:i,children:e})})};kn.displayName="AddToCart.Tooltip";const oe={Card:Sn,Content:Nn,Footer:In,Items:En,Modal:wn,Root:Pn,Tooltip:kn},it=({title:e,...n})=>{const{recentlyAddedProducts:r}=x.useUIContext(),{isMobile:s}=x.useGlobalContext(),o=r.length>3?4:r.length,a=r.length>(o??1),l=r.length>1;return t.jsx(oe.Root,{isMobile:s,count:r.length,component:t.jsx(oe.Content,{title:e,children:t.jsx(oe.Items,{thumbnail:l,children:a&&t.jsx(d.Badge.Count,{count:r.length-o,size:"medium",variant:"secondary"})})}),...n})};it.displayName="AddToCart";const xt={"backtotop-btn":"_backtotop-btn_1shb6_1","card-modifier":"_card-modifier_1shb6_27"},Hs=({children:e,className:n,adornment:r,iconPosition:s,scrollToOptions:o,style:a,...l})=>{const i={top:(o==null?void 0:o.top)??0,left:(o==null?void 0:o.left)??0,behavior:(o==null?void 0:o.behavior)??"smooth"},u=s&&r?{flexDirection:{top:"column",bottom:"column-reverse",left:"row",right:"row-reverse"}[s]}:{},m=()=>{window&&window.document.body.scrollTo({...i})};return t.jsx(d.Card,{...l,shadow:!0,padding:"small",className:d.helpers.classNameConcat(xt["card-modifier"],n),style:{...a,padding:0},children:t.jsxs("button",{className:xt["backtotop-btn"],onClick:m,style:{...u},"data-orientation":s,children:[r,e]})})},lt={"btn-login":"_btn-login_yas63_12","btn-header":"_btn-header_yas63_22","header-animation":"_header-animation_yas63_35"},ct=({id:e})=>{const{setIsOpen:n,cartStore:{items:r}}=Z(),{handleSelectContent:s}=x.useEventContext(),{CONSTANTS:o}=L(),a=r.reduce((l,i)=>l+(i.quantity??0),0);return t.jsx(d.Header.SupportItem,{onClick:()=>{n(!0),s({content:"header:minicart"})},id:e,children:t.jsxs(d.Badge.AutoPositioner,{children:[t.jsx(d.Badge.Count,{count:a,size:"medium",variant:"primary",style:{backgroundColor:"black",display:a>0?"flex":"none"}}),t.jsx(d.Icon,{name:o.header.ICONS.bag,size:"medium"})]})})};ct.displayName="Header.Bag";const ve=({children:e,href:n,...r})=>n&&n!=="#"?t.jsx(x.NextLink,{href:n.startsWith("/")?n:`/${n}`,...r,children:e}):e,An=()=>{const{headerData:e}=L(),{handleSelectContent:n}=x.useEventContext(),{reset:r,updateValue:s}=re(),o=a=>{a?s(a):r()};return t.jsx(d.Header.Categories,{children:Array.isArray(e.categories)&&e.categories.map((a,l)=>t.jsx(ve,{href:a.link,onMouseEnter:()=>o(a.submenuId),onFocus:()=>o(a.submenuId),children:t.jsx(d.Header.CategoryItem,{className:lt["btn-header"],value:a.submenuId??null,adornment:{start:t.jsx(d.Icon,{name:a.iconStart}),end:t.jsx(d.Icon,{name:a.iconEnd})},style:{textWrap:"nowrap",gap:"0"},onClick:()=>{n({content:`header:${a.label}`})},children:a.label})},`category-${a.label}-${l}`))})};An.displayName="Header.Categories";function Ws({SearchModal:e}){const{handleSelectContent:n}=x.useEventContext(),{CONSTANTS:r}=L(),{setValue:s}=et();return t.jsxs(t.Fragment,{children:[t.jsx(d.Header.SupportItem,{onClick:()=>{s(!0),n({content:"header:search"})},children:t.jsx(d.Icon,{name:r.header.ICONS.search,size:"medium"})}),t.jsx(e,{recommendations:!1,trends:!0})]})}const Ks={"menu-subcategories-container":"_menu-subcategories-container_a93cr_1"},Xs={"observer-wrapper":"_observer-wrapper_r43gk_1"};function Ys(e,n,r){const[s,o]=f.useState(!1),{threshold:a}=r||{};return f.useEffect(()=>{if(!e.current)return()=>null;let l=null;const i=new IntersectionObserver(([c])=>{if(r!=null&&r.delay){l&&clearTimeout(l),l=setTimeout(()=>{o(c.isIntersecting),n&&c.isIntersecting&&i.unobserve(e.current)},r.delay);return}o(c.isIntersecting),n&&c.isIntersecting&&i.unobserve(e.current)},{threshold:a||1});return i.observe(e.current),()=>{i.disconnect()}},[e]),s}const Ae=({children:e,eventData:n,observerOptions:r,callBackWhenVisible:s,stopOnIntersection:o=!0,className:a,...l})=>{const i=f.useRef(null),c=Ys(i,o,r),{sendDataLayerEvent:u}=x.useEventContext();return f.useEffect(()=>{c&&(typeof s=="function"&&s(),n&&u({...n}))},[c]),t.jsx("div",{...l,ref:i,className:d.helpers.classNameConcat(Xs["observer-wrapper"],a),children:e})},dt=({thumbnails:e,category:n,isMobile:r=!0,callBack:s})=>{const{handleSelectPromotionEvent:o}=x.useEventContext(),a=50/e.length;return t.jsx("div",{className:Ks["menu-subcategories-container"],children:e.map((l,i)=>{const c=r?l.srcMobile:l.srcDesk;if(!c)return null;const u={creative_name:"banner-menu",creative_slot:`banner-menu:${n}:${i+1}`,promotion_id:c,promotion_name:l.promotion_name};return t.jsx(Ae,{eventData:{functionKey:"readyEvents",data:{event:"view_promotion",readyData:{ecommerce:{...u}}}},observerOptions:{delay:1e3},children:t.jsxs(x.NextLink,{href:l.link??"#",onClick:()=>{typeof s=="function"&&s(),o({updatePromotionRef:!0,promotion:u})},children:[t.jsx(J.Image,{src:c,alt:l.label??c,width:500,height:500,sizes:`(max-width: 768px) 100vw, (max-width: 1023px) 75vw, ${a}vw`}),l.label&&t.jsx("p",{children:l.label})]})},`thumb-${l.label}-${i}`)})})};dt.displayName="Menu.Thumbnail";const Be={"menu-desktop":"_menu-desktop_1b799_1","menu-categories":"_menu-categories_1b799_12"},Qs="_link_w24h0_1",Js="_wrapper_w24h0_98",Zs="_text_w24h0_106",Me={link:Qs,wrapper:Js,text:Zs},ne=({children:e,adornments:n,className:r,disableUnderline:s,href:o,mode:a,size:l,title:i,onClick:c,disablePadding:u,...m})=>{const h=d.helpers.ValidateProp({fieldTypes:de.SizesSmallExtended,property:l,fallback:"medium"}),p=d.helpers.ValidateProp({fieldTypes:de.Mode,property:a,fallback:"default"});return t.jsx(x.NextLink,{...m,className:d.helpers.classNameConcat(Me.link,r),href:o&&o.length>0?o:"#","data-size":h,"data-variant":p,title:i||"NextLink","data-disable-underline":s??!1,"data-disable-padding":u??!0,children:t.jsxs("div",{className:Me.wrapper,onClick:c,children:[n==null?void 0:n.start,t.jsx("p",{className:Me.text,"data-size":h,children:e}),n==null?void 0:n.end]})})},Tn=({children:e,dividerOnRight:n=!0,subMenu:r,...s})=>{var c;const{router:o}=x.useNextContext(),{reset:a}=re(),{handleSelectContent:l}=x.useEventContext(),{CONSTANTS:i}=L();return t.jsxs("div",{...s,className:Be["menu-categories"],children:[(c=r==null?void 0:r.subCategories)==null?void 0:c.map((u,m)=>{var _,g,C;const h=u.listCollapseDesk&&!((_=u.see_all)!=null&&_.link)?{expandAfterRowsQty:u.rowsToShowDesk}:{},p=u.listCollapseDesk&&!((g=u.see_all)!=null&&g.link)?{expansivesAdornments:{open:i.header.ICONS.add,close:i.header.ICONS.minus},expansivesLabels:{open:i.header.COMPONENT_LIST.listExpandLabel,close:i.header.COMPONENT_LIST.listCollapseLabel},iconSize:"x-small"}:{adornment:{end:t.jsx(d.Icon,{name:i.header.ICONS.arrow_right,size:"small"})}};return t.jsxs(d.ComponentList.Structure,{children:[t.jsx(ve,{href:u.linkLabel,title:u.label,onClick:()=>{u.linkLabel&&(a(),l({content:`menu:${u.label??""}:${r.label??""}`}))},children:t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{children:t.jsx("h2",{children:u.label})})})}),t.jsx(d.ComponentList.List,{columns:1,...h,className:Be["submenu-categories"],children:u.items.map((y,v)=>t.jsx(d.ComponentList.ListItem,{id:`list-item-${y.label}-${v}`,children:t.jsx(ne,{href:y.link??"#",size:"x-small",title:y.label??"",disableUnderline:!0,disablePadding:!0,onClick:()=>{a(),l({content:`menu:${u.label??""}:${y.label??""}:${r.label??""}`})},children:y.label})},`list-item-${y.label}-${v}`))}),((C=u.see_all)==null?void 0:C.link)&&t.jsx(d.ComponentList.Support,{...p,size:"small",onClick:()=>{var y;(y=u.see_all)!=null&&y.link&&(a(),l({content:`menu:${u.label??""}:${r.label}`}),o.push(u.see_all.link))},children:u.see_all.link&&u.see_all.label})]},`list-${u.label}-${m}`)}),n&&t.jsx(d.Utils.Divider,{size:"small",direction:"vertical"})]})};Tn.displayName="Menu.Categories";const Mn=({children:e,dividerOnBottom:n=!0,...r})=>{const{CONSTANTS:s}=L();return t.jsxs(t.Fragment,{children:[t.jsx("div",{...r,className:Be["menu-desktop"],style:{...r.style,justifyContent:s.header.ALIGNMENT_MENU},children:e}),n&&t.jsx(d.Utils.Divider,{size:"small"})]})};Mn.displayName="Menu.MenuRoot";const Re={Root:Mn,Categories:Tn,Thumbnail:dt},Rn=()=>{const{headerData:e,CONSTANTS:n}=L(),r=ke(),{reset:s}=re();return t.jsx(d.Header.SubMenu,{children:Array.isArray(e.subMenus)&&e.subMenus.map((o,a)=>{const{thumbnails:l,label:i,id:c}=o,u=c===r,m=l==null?void 0:l.some(h=>!!h.srcDesk);return t.jsxs(Re.Root,{id:c,style:u?{display:"flex",zIndex:n.header.Z_INDEX_WAR.menu_desktop}:{display:"none"},dividerOnBottom:u,children:[t.jsx(Re.Categories,{dividerOnRight:!!m,subMenu:o}),Array.isArray(l)&&t.jsx(Re.Thumbnail,{thumbnails:l,isMobile:!1,category:i,callBack:s})]},`submenu-${c}-${a}`)})})};Rn.displayName="Header.SubMenu";const On=()=>{const{handleSelectContent:e}=x.useEventContext(),{CONSTANTS:n}=L();return t.jsx(x.NextLink,{href:"/favoritos",children:t.jsx(d.Header.SupportItem,{onClick:()=>e({content:"header:wishlist"}),children:t.jsx(d.Icon,{name:n.header.ICONS.favorite_false,size:"medium"})})})};On.displayName="Header.WishList";const Ln=({SearchModal:e})=>{const{CONSTANTS:n,userMenuDesktopRef:r}=L(),{handleSelectContent:s}=x.useEventContext(),{reset:o}=re(),{setValue:a}=ye();return t.jsxs(t.Fragment,{children:[t.jsxs(d.Header.Wrapper,{children:[t.jsx(d.Header.Logo,{style:{width:"100%"},children:t.jsx(x.NextLink,{href:"/",onMouseEnter:o,children:t.jsx(d.Icon,{name:n.header.ICONS.logo,size:"x-large",onClick:()=>{s({content:"header:logo"})}})})}),t.jsx(An,{}),t.jsxs(d.Header.Support,{onMouseEnter:o,style:{justifyContent:"flex-end"},children:[t.jsx(Ws,{SearchModal:e}),t.jsx(d.Header.SupportItem,{onClick:()=>{a(!0),s({content:"header:user_menu"})},className:lt["btn-login"],innerRef:r,children:t.jsx(d.Icon,{name:n.header.ICONS.person,size:"medium"})}),t.jsx(On,{}),t.jsx(ct,{id:"cart-button"})]})]}),t.jsx(Rn,{})]})};Ln.displayName="Header.HeaderDesktopWrapper";const eo="_divider_1lexj_199",O={"modal-modifier":"_modal-modifier_1lexj_1","menu-mobile":"_menu-mobile_1lexj_11","menu-header-container":"_menu-header-container_1lexj_26","menu-header-wrapper":"_menu-header-wrapper_1lexj_35","menu-header-navlinks":"_menu-header-navlinks_1lexj_41","menu-body":"_menu-body_1lexj_57","menu-categories-container":"_menu-categories-container_1lexj_74","menu-categories-btn":"_menu-categories-btn_1lexj_108","menu-body-banner-container-modifier":"_menu-body-banner-container-modifier_1lexj_121","menu-categories__banner":"_menu-categories__banner_1lexj_130","menu-submenu-modal-modifiier":"_menu-submenu-modal-modifiier_1lexj_135","menu-submenu":"_menu-submenu_1lexj_135","menu-submenu--item":"_menu-submenu--item_1lexj_150","menu-submenu--thumbnails":"_menu-submenu--thumbnails_1lexj_156","menu-submenu--component-list-modifier":"_menu-submenu--component-list-modifier_1lexj_184","submenu-categories":"_submenu-categories_1lexj_187","menu-navigationbar":"_menu-navigationbar_1lexj_191",divider:eo,"menu-navigationbar-item":"_menu-navigationbar-item_1lexj_206","menu-categories-textstructure-modifier":"_menu-categories-textstructure-modifier_1lexj_210"},Dn=({children:e,mobileBannerAlt:n,mobileBannerSrc:r,onClick:s,textColor:o,...a})=>t.jsx("button",{onClick:s,className:O["menu-categories-btn"],children:r?t.jsxs(d.Banner.Container,{...a,className:O["menu-body-banner-container-modifier"],children:[t.jsx(d.Banner.ImageWrapper,{style:{width:"100%"},children:t.jsx(J.Image,{src:r,alt:n??r,className:O["menu-categories__banner"],width:343,height:128,unoptimized:!0})}),t.jsx(d.Banner.Slot,{verticalAlignment:"center",horizontalAlignment:"start",children:t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{className:O["menu-categories-textstructure-modifier"],children:t.jsx("h2",{className:"typography-style-body-xs",style:o?{color:o}:{},children:e})})})})]}):t.jsx("h2",{...a,children:e})});Dn.displayName="Menu.MenuCategories";const zn=({children:e,link:n})=>{const{reset:r}=ie();return n?t.jsx(x.NextLink,{href:n??"#",onClick:r,children:e}):e};zn.displayName="Menu.MenuCategoriesWrapper";const Bn=({subcategory:e,submenuLabel:n})=>{var c,u,m;const{router:r}=x.useNextContext(),{reset:s}=ie(),{handleSelectContent:o}=x.useEventContext(),{CONSTANTS:a}=L(),l=e.listCollapseMobile&&!((c=e.see_all)!=null&&c.link)?{expandAfterRowsQty:e.rowsToShowMobile}:{},i=e.listCollapseMobile&&!((u=e.see_all)!=null&&u.link)?{expansivesAdornments:{open:a.header.ICONS.add,close:a.header.ICONS.minus},expansivesLabels:{open:a.header.COMPONENT_LIST.listExpandLabel,close:a.header.COMPONENT_LIST.listCollapseLabel},iconSize:"x-small"}:{adornment:{end:t.jsx(d.Icon,{name:a.header.ICONS.arrow_right,size:"small"})}};return t.jsxs(d.ComponentList.Structure,{className:O["menu-submenu--component-list-modifier"],children:[t.jsx(ve,{href:e.linkLabel,title:e.label,onClick:()=>{s(),o({content:`menu:${e.label??""}:${n}`})},children:t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{children:t.jsx("h2",{className:"typography-style-body-sm-strong",children:e.label})})})}),t.jsx(d.ComponentList.List,{columns:1,...l,className:O["submenu-categories"],children:e.items.map((h,p)=>t.jsx(d.ComponentList.ListItem,{id:`list-item-${h.label}-${p}`,divider:!0,children:t.jsx(ne,{href:h.link??"#",size:"x-small",title:h.label??"",disableUnderline:!0,onClick:()=>{s(),o({content:`menu:${e.label??""}:${h.label}:${n}`})},children:h.label})},`list-item-${h.label}-${p}`))}),((m=e.see_all)==null?void 0:m.link)&&t.jsx(d.ComponentList.Support,{...i,size:"small",onClick:()=>{var h;s(),o({content:`menu:${e.label??""}:${n}`}),(h=e.see_all)!=null&&h.link&&r.push(e.see_all.link)},children:e.see_all.link&&e.see_all.label})]})};Bn.displayName="Menu.SubMenuSubCategory";const $n=({submenu:e})=>{var a;const n=ke(),{handleCloseSubMenu:r}=Ce(),{reset:s}=re(),{CONSTANTS:o}=L();return t.jsxs("div",{className:O["menu-submenu--item"],style:{display:n===e.id?"flex":"none"},children:[t.jsx(d.TextStructure.Root,{adornment:{start:t.jsx(d.Icon,{name:o.header.ICONS.arrow_back,size:"medium",onClick:r})},layoutProps:{textRow:{alignItems:"center",style:{width:"100%",position:"relative"}},columnWrapper:{alignContent:"center",style:{width:"100%"}}},children:e.label&&t.jsx(d.TextStructure.DivWrapper,{style:{position:"absolute",left:"50%",transform:"translate(-50%)"},children:t.jsx("h2",{className:"typography-style-body-md-strong",children:e.label})})}),t.jsx("div",{className:O["menu-submenu--thumbnails"],children:Array.isArray(e.thumbnails)&&t.jsx(dt,{thumbnails:e.thumbnails,isMobile:!0,category:e.label,callBack:s})}),(a=e==null?void 0:e.subCategories)==null?void 0:a.map((l,i)=>t.jsx(Bn,{subcategory:l,submenuLabel:e.label},`list-${l.label}-${i}`))]})};$n.displayName="Menu.SubMenuItem";const Fn=()=>{const{headerData:e}=L(),n=ke(),{reset:r}=re(),{bodyRef:s}=Ce();return t.jsx(d.Modal.RootWithoutPortal,{isOpen:!!n,setIsOpen:r,parent:s.current,variant:"sideLeft",style:{position:"absolute",width:"100%"},className:O["menu-submenu-modal-modifiier"],children:t.jsx("div",{className:O["menu-submenu"],children:e.subMenus.map((o,a)=>t.jsx($n,{submenu:o},`submenu-${o.id}-${a}`))})})};Fn.displayName="Menu.SubMenu";const Un=({className:e,...n})=>{const{headerData:r}=L(),{setValue:s}=re(),{bodyRef:o}=Ce(),{handleSelectContent:a}=x.useEventContext();return t.jsxs("div",{...n,ref:o,id:"menu-body",className:O["menu-body"],children:[t.jsx("div",{className:O["menu-categories-container"],children:r.categories.map((l,i)=>{const c=l.submenuId?{}:{"data-close":!0};return t.jsx(zn,{link:l.submenuId?null:l.link,children:t.jsx(Dn,{onClick:()=>{s(l.submenuId??null),a({content:`menu:${l.label}`})},mobileBannerSrc:l.mobileBannerSrc,mobileBannerAlt:l.mobileBannerAlt,textColor:l.textColor,...c,children:l.mobileBannerAlt})},`menu-categories-${i}`)})}),t.jsx(Fn,{})]})};Un.displayName="Menu.MenuBody";const qn=({title:e,subtitle:n})=>{const{CONSTANTS:r}=L();return t.jsxs("div",{className:O["menu-header-wrapper"],style:n?{alignItems:"start"}:{alignItems:"center"},children:[(e||n)&&t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{children:[e&&t.jsx("h2",{className:"typography-style-body-md",children:e}),n&&t.jsx("h3",{children:n})]})}),t.jsx(d.Button,{adornment:{end:t.jsx(d.Icon,{name:r.header.ICONS.close})},variant:"tertiary",className:O["menu-close"],"data-close":!0})]})};qn.displayName="Menu.MenuHeaderWrapper";const Vn=({navigationLinks:e})=>{const{reset:n}=ie(),{handleSelectContent:r}=x.useEventContext();return e?t.jsx("nav",{className:O["menu-header-navlinks"],children:e.map((s,o)=>t.jsx(ne,{href:s.link??"#",adornments:{start:s.iconStart&&t.jsx(d.Icon,{name:s.iconStart}),end:s.iconEnd&&t.jsx(d.Icon,{name:s.iconEnd})},onClick:()=>{n(),r({content:`menu:navigationlinks-${s.label}`})},children:s.label},o))}):null};Vn.displayName="Menu.MenuHeaderNavLinks";const Gn=()=>{const{headerData:e}=L();return t.jsxs("div",{className:O["menu-header-container"],children:[t.jsx(qn,{title:e.title,subtitle:e.subtitle}),t.jsx(Vn,{navigationLinks:e.navigationLinks})]})};Gn.displayName="Menu.MenuHeaderContainer";const Hn=({children:e})=>{const{documentBodyRef:n}=Ce(),{CONSTANTS:r}=L(),s=Ze(),{setValue:o}=ie();return t.jsx(d.Modal.RootWithoutPortal,{isOpen:s,setIsOpen:o,parent:n.current,variant:"sideLeft",style:{position:"fixed",zIndex:r.header.Z_INDEX_WAR.menu_mobile,bottom:"unset",top:0,overflowY:"hidden"},className:O["modal-modifier"],children:t.jsx("div",{className:O["menu-mobile"],children:e})})};Hn.displayName="Menu.MenuRoot";const Ie=({children:e,...n})=>t.jsxs(t.Fragment,{children:[t.jsx(d.Button,{...n,className:O["menu-navigationbar-item"],children:e}),t.jsx(d.Utils.Divider,{direction:"vertical",size:"small",className:O.divider})]});Ie.displayName="Menu.NavigationBarItem";const Wn=()=>{const{setIsOpen:e}=Z(),{reset:n}=ie(),{setValue:r}=ye(),{handleSelectContent:s}=x.useEventContext(),{CONSTANTS:o}=L(),{router:a}=x.useNextContext();return t.jsxs(d.Card,{id:"menu-navigationbar",shadow:!0,className:O["menu-navigationbar"],style:{zIndex:o.header.Z_INDEX_WAR.menu_mobile_navigation_bar},children:[t.jsx(Ie,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.login.button_icon,onClick:()=>{n(),r(!0),s({content:"menu:user_menu"})},children:o.header.MENU_INFO.login.button_text}),t.jsx(Ie,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.bag.button_icon,onClick:()=>{n(),e(!0),s({content:"menu:minicart"})},children:o.header.MENU_INFO.bag.button_text}),t.jsx(Ie,{size:"small",variant:"tertiary",iconNameStart:o.header.MENU_INFO.store.button_icon,onClick:()=>{a.push("/institucional/lojas"),n(),s({content:"menu:store"})},children:o.header.MENU_INFO.store.button_text})]})};Wn.displayName="Menu.NavigationBar";const je={Root:Hn,NavigationBar:Wn,Header:Gn,Body:Un},Kn=({SearchModal:e})=>{const n=f.useRef(null),{CONSTANTS:r,userMenuMobileRef:s}=L(),{MENU_NAVIGATION_BAR_ALLOWED:o,ICONS:a,MENU_MOB_BTN_SIDE:l="right"}=r.header,{handleSelectContent:i}=x.useEventContext(),{setValue:c}=et(),{setValue:u}=ie(),{setValue:m}=ye();return t.jsxs(t.Fragment,{children:[t.jsxs(d.Header.Wrapper,{children:[l==="left"&&t.jsx(d.Header.SupportItem,{onClick:()=>u(!0),innerRef:n,children:t.jsx(d.Icon,{name:a.menu,size:"medium"})}),t.jsx(d.Header.Logo,{style:{width:"100%",justifyContent:"center"},children:t.jsx(x.NextLink,{href:"/",children:t.jsx(d.Icon,{name:a.logo,size:"x-large",onClick:()=>{i({content:"header:logo"})}})})}),t.jsxs(d.Header.Support,{children:[t.jsx(d.Header.SupportItem,{onClick:()=>{c(!0),i({content:"header:search"})},children:t.jsx(d.Icon,{name:a.search,size:"medium"})}),t.jsx(d.Header.SupportItem,{onClick:()=>{m(!0),i({content:"header:user_menu"})},innerRef:s,children:t.jsx(d.Icon,{name:a.person,size:"medium"})}),t.jsx(ct,{}),l==="right"&&t.jsx(d.Header.SupportItem,{onClick:()=>u(!0),innerRef:n,children:t.jsx(d.Icon,{name:a.menu,size:"medium"})})]})]}),t.jsx(e,{recommendations:!1,trends:!0}),t.jsx(tn,{children:t.jsxs(je.Root,{children:[t.jsx(je.Header,{}),t.jsx(je.Body,{}),o?t.jsx(je.NavigationBar,{}):t.jsx(t.Fragment,{})]})})]})};Kn.displayName="Header.HeaderMobileWrapper";const to="_root_wvekm_126",X={"user-menu--credits":"_user-menu--credits_wvekm_1","user-menu--content":"_user-menu--content_wvekm_10","user-menu--login":"_user-menu--login_wvekm_30","user-menu--login--content":"_user-menu--login--content_wvekm_37","user-menu--menu":"_user-menu--menu_wvekm_64","user-menu--tooltip":"_user-menu--tooltip_wvekm_93","tooltip-modifier":"_tooltip-modifier_wvekm_104","modal-controls-modifier":"_modal-controls-modifier_wvekm_109","modal-header-modifier":"_modal-header-modifier_wvekm_117",root:to},Xn=({className:e,children:n,...r})=>t.jsx("div",{...r,className:d.helpers.classNameConcat(X["user-menu--content"],e),children:n});Xn.displayName="UserMenu.Content";var Yn=(e=>(e.Account="account",e))(Yn||{});const Qn=({className:e,cashBack:n,credits:r,link:s,total:o,...a})=>{const l=n?K(n):void 0,i=r?K(r):void 0,c=o?K(o):void 0;return t.jsx(d.Credits.Account,{...a,className:d.helpers.classNameConcat(X["user-menu--credits"],e),icon:"wallet",showIcon:!0,cashBackValue:l,creditsValue:i,linkMore:s,totalValue:c,type:Yn.Account})};Qn.displayName="UserMenu.Credits";const Jn=({className:e,children:n,description:r,text:s,...o})=>{const{isMobile:a}=x.useGlobalContext();return t.jsx("div",{...o,className:d.helpers.classNameConcat(X["user-menu--login"],e),"data-mobile":a,children:t.jsxs("div",{className:X["user-menu--login--content"],children:[t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{alignContent:"flex-start",alignItems:"flex-start",children:[t.jsx("h3",{className:"typography-style-body-lg-strong",children:s}),t.jsx("p",{children:r})]})}),n]})})};Jn.displayName="UserMenu.Login";const Zn=({className:e,isLogged:n,onLogoutClick:r,ICONS:s,storeConfig:o})=>{const{isMobile:a}=x.useGlobalContext(),l=x.LOGIN_MENU_OPTIONS_ARRAY({ICONS:s,storeConfig:o}).filter(i=>i.deviceShown==="both"||i.deviceShown===(a?"mobile":"desktop"));return t.jsxs("ul",{className:d.helpers.classNameConcat(X["user-menu--menu"],e),children:[Array.isArray(l)&&l.map((i,c)=>t.jsx("li",{children:t.jsx(ne,{href:i.href??"#",size:"small",disableUnderline:!0,adornments:{start:t.jsx(d.Icon,{name:i.icon??"delete"})},children:i.label})},c)),n?t.jsx("li",{children:t.jsx(ne,{href:`${o.secureSubdomain}/api/vtexid/pub/logout?scope=mariafilo&returnUrl=${encodeURIComponent(`${o.storeUrl}`)}`,size:"small",disableUnderline:!0,onClick:r,adornments:{start:t.jsx(d.Icon,{name:x.LOGOUT_ICON(s)})},children:x.LOGOUT_TEXT})}):t.jsx(t.Fragment,{})]})};Zn.displayName="UserMenu.Menu";const no=e=>{const n=f.useRef(null),r=f.useCallback(a=>{n.current&&!n.current.contains(a.target)&&e()},[e]),s=f.useCallback(a=>{n.current&&!n.current.contains(a.target)&&e()},[e]),o=f.useCallback(a=>{a.key==="Escape"&&e()},[e]);return f.useEffect(()=>(document.addEventListener("mousedown",r),document.addEventListener("keydown",o),document.addEventListener("touchstart",s),()=>{document.removeEventListener("mousedown",r),document.removeEventListener("keydown",o),document.removeEventListener("touchstart",s)}),[r,o,s]),{ref:n}},ro=e=>{if(!e||typeof window>"u")return 0;const n=window.getComputedStyle(e);return parseInt(n.padding,10)},so=(e,n,r)=>{if(!(e instanceof HTMLElement)||!(n instanceof HTMLElement))return{left:0,top:0};const{height:s,left:o,top:a,width:l}=n.getBoundingClientRect(),i=e.getBoundingClientRect(),c=e!=null&&e.parentElement?ro(e==null?void 0:e.parentElement):0;return{left:o+l/2-(i.width+c*2),top:a+s+r}},er=f.createContext({}),oo=({children:e,delay:n=600,gap:r=20,isOpen:s,setIsOpen:o,target:a,...l})=>{const i=f.useRef(null),[c,u]=f.useState(!1),[m,h]=f.useState({left:0,top:0}),{ref:p}=no(()=>{u(!0),typeof window<"u"&&(i.current=window.setTimeout(()=>{o(!1),u(!1)},n))});return f.useEffect(()=>{if(a&&(p!=null&&p.current)){const{left:_,top:g}=so(p.current,a,r??0);h({left:_,top:g}),u(!1)}},[r,s,a,p]),t.jsx(er.Provider,{value:f.useMemo(()=>({...l,...m,contentRef:p,isLeaving:c,isOpen:s,setIsOpen:o,setIsLeaving:u,target:a}),[l,m,p,c,s,o,u,a]),children:e})},tr=()=>{const e=f.useContext(er);if(e===void 0)throw new Error("useUserMenuContext must be used within a UserMenuProvider");return e},nr=({children:e,isMobile:n=!1,Z_INDEX_WAR:r})=>{const{isOpen:s,setIsOpen:o}=tr();return t.jsxs(d.Modal.Root,{"data-user":"user-menu--modal",isMobile:n??!1,isOpen:s,setIsOpen:o,variant:"sideBottom",className:X["modal-root-modifier"],style:{zIndex:r.user_menu_mobile},children:[t.jsx(d.Modal.Header,{navigation:"top",className:X["modal-header-modifier"],children:t.jsx(d.Modal.Controls,{navigation:"top",isMobile:!0,className:X["modal-controls-modifier"]})}),t.jsx(d.Modal.Body,{children:e})]})};nr.displayName="UserMenu.Modal";const rr=({children:e,component:n,Z_INDEX_WAR:r,isMobile:s,...o})=>t.jsx(oo,{...o,className:X.root,children:s?t.jsxs(t.Fragment,{children:[t.jsx(se.Modal,{Z_INDEX_WAR:r,children:n}),e]}):t.jsx(se.Tooltip,{component:n,style:{width:304,zIndex:r.user_menu},Z_INDEX_WAR:r,children:e})});rr.displayName="UserMenu.Root";const sr=({children:e,component:n,Z_INDEX_WAR:r,...s})=>{const{contentRef:o,left:a,isLeaving:l,isOpen:i,top:c}=tr();return t.jsx(d.Tooltip.Root,{arrow:"top-right",component:t.jsx("div",{...s,ref:o,children:n}),className:d.helpers.classNameConcat(X["user-menu--tooltip"],X["tooltip-modifier"]),isLeaving:l,isOpen:i,left:a,size:"medium",position:"top",top:c,style:{zIndex:r.user_menu},children:t.jsx("div",{className:X["user-menu--tooltip"],children:e})})};sr.displayName="UserMenu.Tooltip";const se={Credits:Qn,Content:Xn,Login:Jn,Menu:Zn,Modal:nr,Root:rr,Tooltip:sr},ut=()=>{var C,y,v;const e=ot(),{isMobile:n}=x.useGlobalContext(),{userMenuMobileRef:r,userMenuDesktopRef:s,CONSTANTS:{header:o},storeConfig:a}=L(),{ICONS:l,Z_INDEX_WAR:i,MENU_INFO:c}=o,u=Wt(),{setValue:m}=ye(),h=()=>{window.location.href=`${a.secureSubdomain}/api/io/login?returnUrl=${encodeURIComponent(`${a.storeUrl}`)}`},p=!!((C=e.user)!=null&&C.userId),{cashback:_,credits:g}=f.useMemo(()=>{var N,j;return{credits:((N=e==null?void 0:e.getCurrentCredits())==null?void 0:N.credits)??0,cashback:((j=e==null?void 0:e.getCurrentCredits())==null?void 0:j.cashback)??0}},[e]);return t.jsx(se.Root,{component:t.jsxs(se.Content,{children:[t.jsx(se.Login,{description:x.LOGIN_MENU_DESCRIPTION(p),text:x.LOGIN_MENU_TITLE(p,((y=e==null?void 0:e.user)==null?void 0:y.firstName)??((v=e==null?void 0:e.user)==null?void 0:v.email)),children:!p&&t.jsx(d.Button,{size:"medium",variant:"quaternary",onClick:()=>h(),children:c.login.button_text})}),g+_&&p?t.jsx(se.Credits,{credits:g,cashBack:_,link:`${a.secureSubdomain}/account#/meus-creditos`,total:g+_}):t.jsx(t.Fragment,{}),t.jsx(d.Utils.Divider,{}),t.jsx(se.Menu,{isLogged:p,onLogoutClick:()=>e.logout(),ICONS:l,storeConfig:a})]}),target:n?r.current:s.current,isOpen:u,isMobile:n,setIsOpen:m,Z_INDEX_WAR:i})};ut.displayName="UserMenu";const or=({tipBar:e,miniCart:n,SearchModal:r})=>{const{structureRef:s,rootRef:o,CONSTANTS:a}=L(),{header:{HEADER_CONFIGS:l,Z_INDEX_WAR:i}}=a;return t.jsx(d.Header.Structure,{innerRef:s,adornment:{start:e},style:{position:"sticky",top:0,zIndex:i.header},className:lt["header-animation"],children:t.jsxs(d.Header.Root,{innerRef:o,style:{zIndex:i.header},variant:l.default_variant,interactiveVariant:l.interactive_variant,children:[t.jsx("div",{className:x.responsive["responsive-mobile-block"],style:{height:"100%",width:"100%",zIndex:i.header_mobile},children:t.jsx(Kn,{SearchModal:r})}),t.jsx("div",{className:x.responsive["responsive-desktop-block"],style:{height:"100%",width:"100%",zIndex:i.header_desktop},children:t.jsx(Ln,{SearchModal:r})}),n,t.jsx(it,{title:"Produto adicionado à sua sacola!",CONSTANTS:a.addToCart}),t.jsx(ut,{})]})})};or.displayName="Header";const ao="_shippingFreight_6z8rf_6",io="_shippingFreight__postalCodeGrid_6z8rf_10",lo="_shippingFreight__grid_6z8rf_14",co="_shippingFreight__grid__title_6z8rf_18",uo="_shippingFreight__grid__remember_6z8rf_29",mo="_postalCodeContainer_6z8rf_44",po="_deliveryStatusBar__tag_6z8rf_49",fo="_deliveryStatusBarError__tag_6z8rf_66",ho="_deliveryInfo_6z8rf_74",go="_deliveryInfo__content_6z8rf_78",_o="_deliveryInfo__text_6z8rf_84",xo="_deliveryInfo__title_6z8rf_89",yo="_deliveryInfo__subtitle_6z8rf_99",Co="_deliveryInfo__tooltipIcon_6z8rf_109",vo="_deliveryInfo__tooltip_6z8rf_109",bo="_freightGrid_6z8rf_148",jo="_freightContainer_6z8rf_155",So="_freightOption__content_6z8rf_160",No="_freightOption__value_6z8rf_166",Io="_freightOption__title_6z8rf_177",Eo="_freightOption__title_item_6z8rf_181",wo="_freightOption__paragraph_6z8rf_192",T={shippingFreight:ao,shippingFreight__postalCodeGrid:io,shippingFreight__grid:lo,shippingFreight__grid__title:co,shippingFreight__grid__remember:uo,postalCodeContainer:mo,deliveryStatusBar__tag:po,deliveryStatusBarError__tag:fo,deliveryInfo:ho,deliveryInfo__content:go,deliveryInfo__text:_o,deliveryInfo__title:xo,deliveryInfo__subtitle:yo,deliveryInfo__tooltipIcon:Co,deliveryInfo__tooltip:vo,freightGrid:bo,freightContainer:jo,freightOption__content:So,freightOption__value:No,freightOption__title:Io,freightOption__title_item:Eo,freightOption__paragraph:wo,"input-modifier":"_input-modifier_6z8rf_207","freight--tooltip":"_freight--tooltip_6z8rf_227"},Po=({icon:e,title:n,subtitle:r,packageCount:s,packageUnit:o="",labelDescription:a,freightConfig:l,toolTipZIndex:i})=>{const[c,u]=f.useState(!1),m=f.useRef(null),h=()=>u(p=>!p);return t.jsxs("div",{className:T.deliveryInfo,ref:m,children:[t.jsx(d.Tooltip.Root,{arrow:"bottom",component:t.jsx("div",{children:t.jsx("p",{children:l.messages.select_size_tag})}),id:"freight--tooltip",className:T["freight--tooltip"],style:{zIndex:i},isOpen:!0,size:"medium",position:"top",top:"-170%",left:"4%",parent:m.current}),t.jsxs("div",{className:T.deliveryInfo__content,children:[t.jsx("div",{className:T.deliveryInfo__icon,children:t.jsx(d.Icon,{name:e,size:"medium"})}),t.jsxs("div",{className:T.deliveryInfo__text,children:[t.jsxs("span",{className:T.deliveryInfo__title,children:[n," ",s," ",o]}),r&&t.jsx("span",{className:T.deliveryInfo__subtitle,children:r})]}),a&&t.jsxs("div",{className:T.deliveryInfo__tooltipIcon,onMouseEnter:h,onMouseLeave:h,"aria-label":"Mostrar descrição",children:[t.jsx("span",{children:t.jsx(d.Icon,{name:l.icons.feedback_help,size:"small"})}),c&&t.jsx("div",{className:T.deliveryInfo__tooltip,children:a})]})]})]})},ko=({value:e,title:n,paragraph:r})=>t.jsx("div",{className:T.freightOption,children:t.jsxs("div",{className:T.freightOption__content,children:[t.jsx("span",{className:T.freightOption__value,children:e}),t.jsx("span",{className:T.freightOption__title,children:t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{className:T.footer__item,children:[t.jsx("span",{className:T.freightOption__title_item,children:n}),r&&t.jsx("span",{className:T.freightOption__paragraph,children:r})]})})})]})}),Ao=({children:e})=>t.jsx("div",{className:T.freightContainer,children:e}),To=({children:e})=>t.jsx("div",{className:T.freightGrid,children:e}),Mo=({children:e})=>t.jsx("div",{className:T.postalCodeContainer,children:e}),yt=({message:e,seller:n="",size:r="small",setError:s})=>t.jsx("div",{className:s?T.deliveryStatusBarError:T.deliveryStatusBar,children:t.jsxs(d.Tag,{title:e,className:s?T.deliveryStatusBarError__tag:T.deliveryStatusBar__tag,size:r,children:[e," ",!s&&n]})}),Ro=e=>{const n=parseInt(e,10);return n===1?`${n} dia`:`${n} dias`},Oo=e=>{var r,s,o;const n=[];return(o=(s=(r=e==null?void 0:e.logisticsInfo)==null?void 0:r[0])==null?void 0:s.slas)==null||o.forEach(a=>{n.push({id:a.id,name:a.name,price:a.price,shippingEstimate:a.shippingEstimate})}),n},Lo=({component:e,parent:n,top:r,left:s,target:o,contentRef:a,freightConfig:l,toolTipZIndex:i=999,...c})=>{const{isMobile:u}=x.useGlobalContext();return t.jsx(t.Fragment,{children:u?t.jsx(d.Tooltip.Root,{arrow:"bottom",component:t.jsxs("div",{...c,ref:a,children:[e,t.jsx("p",{children:l.messages.select_size_tag})]}),id:"freight--tooltip",className:T["freight--tooltip"],style:{zIndex:i},isOpen:!0,size:"medium",position:"top",top:"-170%",left:"4%",parent:n}):t.jsx(d.Tooltip.Root,{arrow:"bottom",component:t.jsxs("div",{...c,ref:a,children:[e,t.jsx("p",{children:l.messages.select_size_tag})]}),id:"freight--tooltip",className:T["freight--tooltip"],style:{zIndex:i},isOpen:!0,size:"medium",position:"top",top:"-110%",left:"3%",parent:n})})},Do=({onUpdateFreightItems:e,sellerId:n,size:r,skuId:s,quantity:o,setError:a,setIsButtonClicked:l,component:i,freightConfig:c,toolTipZIndex:u})=>{var B,V,R,S;const m=x.useCartStore(),h=x.useCartStore(E=>E.shipping),[p,_]=f.useState(),[g,C]=f.useState(!1),[y,v]=f.useState(!1),[N,j]=f.useState(!1),w=(V=(B=m.shippingData)==null?void 0:B.address)==null?void 0:V.postalCode,b=!(p!=null&&p.length)&&w?w:p,I=f.useRef(null),k=async E=>{const P=E.target.value.replace(/\D/g,"").slice(0,8);P.length>5?_(P.replace(/^(\d{5})(\d{1,3})/,"$1-$2")):_(P)},D=async E=>{const A=E.target.value.replace(/\D/g,"");try{if((await pt.get(`https://viacep.com.br/ws/${A}/json/`)).data.erro){a&&a(c.messages.cep_not_found),l(!1),v(!0);return}a&&a(""),v(!1)}catch{console.log("Erro ao validar o CEP. Tente novamente mais tarde.")}},F=async()=>{C(!0);try{const E=await pt.post("/api/checkout/simulation",{items:[{id:s,quantity:o,seller:n}],country:"BRA",postalCode:b});e(Oo(E.data))}catch(E){console.error("Erro ao atualizar o documento:",E)}finally{C(!1),h(b,"BRA")}},M=async()=>{if(!s){j(!0),setTimeout(()=>j(!1),1500);return}await D({target:{value:b}}),g||(F(),l(!0))};return t.jsxs("div",{ref:I,style:{position:"relative"},children:[!s&&N?t.jsx(Lo,{component:i,isOpen:N,parent:I.current,toolTipZIndex:u,freightConfig:c}):t.jsx(t.Fragment,{}),t.jsx("div",{style:{position:"relative"},children:t.jsx(d.TextField.Structure,{title:"structure",style:{width:"100%"},input:t.jsx(d.TextField.Input,{defaultValue:(S=(R=m.shippingData)==null?void 0:R.address)==null?void 0:S.postalCode,label:c.messages.text_input_label,title:"textfield",value:p,sizeVariant:r,onMouseOver:()=>s?null:j(!0),onMouseOut:()=>s?null:j(!1),mode:"simple",onChange:k,onKeyDown:E=>{E.key==="Enter"&&M()},className:T["input-modifier"],feedback:y?"error":"none"}),right:t.jsx(d.Button,{onClick:M,size:r,title:"button",children:g?t.jsx(d.Spinner,{size:"small",indicatorColor:"#ffffff"}):c.messages.text_input_btn})})})]})},zo=({children:e,freightConfig:n})=>t.jsxs("div",{className:T.shippingFreight,children:[t.jsxs("div",{className:T.shippingFreight__grid,children:[t.jsx("span",{className:T.shippingFreight__grid__title,children:n.messages.title}),t.jsx("span",{className:T.shippingFreight__grid__remember,children:t.jsx(ne,{href:"https://buscacepinter.correios.com.br/app/endereco/index.php",passHref:!0,target:"_blank",rel:"noopener noreferrer",size:"x-small",disablePadding:!1,title:n.messages.remember_cep,children:n.messages.remember_cep})})]}),t.jsx("div",{className:T.shippingFreight__postalCodeGrid,children:e})]}),Bo=({children:e})=>t.jsx("div",{className:T.freightContainer,children:e}),$o=({className:e,sellerId:n,skuId:r,quantity:s,size:o,seller:a,local:l,CONSTANTS_PROPS:i})=>{const{sendDataLayerEvent:c}=x.useEventContext(),[u,m]=f.useState(""),[h,p]=f.useState([]),[_,g]=f.useState(""),[C,y]=f.useState(!1),v=j=>m(j),N=j=>{p(j),c({functionKey:"readyEvents",data:{event:"search_zipcode",readyData:{shippings:j.map(w=>({shipping_tier:w.id,delivery_time:w.shippingEstimate.replace("bd",""),flag_pickup:w.name.toLowerCase().includes("retirada")?"true":"false",shipping:w.price,currency:i.currency||"BRL"}))}}})};return t.jsxs(Bo,{className:e,children:[t.jsxs(zo,{freightConfig:i.freightConfig,children:[t.jsx(Mo,{children:t.jsx(Do,{onUpdateFreightItems:N,skuId:r,quantity:s,size:o,sellerId:n,local:l,setError:g,setIsButtonClicked:y,freightConfig:i.freightConfig,toolTipZIndex:i.toolTipZIndex})}),_?t.jsx(yt,{size:o,message:_,setError:g}):h.length>0&&t.jsx(yt,{size:o,message:i.freightConfig.messages.delivered_by,seller:a})]}),C&&!_?h.length>0&&t.jsxs(Ao,{children:[t.jsx(To,{children:h.filter(({id:j})=>!j.includes("Retirada")).map(j=>t.jsx(ko,{id:j.id,value:Ye({valueInCents:j.price,hasFree:!1,freeTaxMessage:i.freightConfig.messages.free_tax}),title:j.name,paragraph:`${i.freightConfig.messages.prefix_days}${Ro(j.shippingEstimate)}`,radioValue:u,changeValue:v},j.id))}),i.deliveryInfoBoxesAllowed?t.jsx(Po,{icon:i.freightConfig.icons.delivery_truck,packageUnit:i.freightConfig.messages.unit_amout,title:i.freightConfig.messages.delivered_amount_packages,subtitle:"",packageCount:1,labelDescription:"Label",freightConfig:i.freightConfig,toolTipZIndex:i.toolTipZIndex??999}):t.jsx(t.Fragment,{})]}):null]})},ar=f.createContext({}),Fo=({children:e,item:n,index:r,shelfTitle:s,...o})=>{const[a,l]=f.useState(null),i=f.useRef(null),c=f.useRef({availableSkus:[],priceInfo:{price:0,listPrice:0}}),{sendDataLayerEvent:u,itemListRef:m}=x.useEventContext(),h=C=>{u({functionKey:"productEvents",data:{commonData:{...n,availableSizes:c.current.availableSkus,...c.current.priceInfo},customData:{index:r+1},event:C}})},p=()=>{h("add_to_wishlist")},_=()=>{u({functionKey:"skuEvents",data:{event:"add_to_cart",commonData:{products:[{...n,...c.current.priceInfo}]},supportData:{selectedSku:a,selectedSkus:[a]},customData:{index:r}}})},g=()=>{s&&(m.current={item_list_name:s}),h("select_item")};return t.jsx(ar.Provider,{value:f.useMemo(()=>({...o,index:r,item:n,element:i,selectedSku:a,setSelectedSku:l,eventDataRef:c,sendAddToWishlistEvent:p,sendSelectItemEvent:g,sendAddToCartEvent:_}),[o,n,i,a]),children:e})},Y=()=>{const e=f.useContext(ar);if(e===void 0)throw new Error("useProductCardContext must be used within a ProductCardProvider");return e},U={"product-card--actions":"_product-card--actions_nmzk4_1","product-card--actions--group":"_product-card--actions--group_nmzk4_9","product-card--actions--selectors":"_product-card--actions--selectors_nmzk4_21","product-card--body":"_product-card--body_nmzk4_33","product-card--header":"_product-card--header_nmzk4_47","product-card--footer":"_product-card--footer_nmzk4_67","product-card--image":"_product-card--image_nmzk4_90","product-card--image--container":"_product-card--image--container_nmzk4_97","product-card--outstock":"_product-card--outstock_nmzk4_133","product-card--price":"_product-card--price_nmzk4_155","product-card--title":"_product-card--title_nmzk4_177","product-card--title--tag":"_product-card--title--tag_nmzk4_183","product-card--title--content":"_product-card--title--content_nmzk4_200","product-card--selectors--size":"_product-card--selectors--size_nmzk4_240","product-card--selectors--size--button":"_product-card--selectors--size--button_nmzk4_266","product-card--selectors--size--skus":"_product-card--selectors--size--skus_nmzk4_275","product-card--selectors--style":"_product-card--selectors--style_nmzk4_289","product-card--selectors--style--more":"_product-card--selectors--style--more_nmzk4_299","product-card--video":"_product-card--video_nmzk4_316","product-card--wrapper":"_product-card--wrapper_nmzk4_342"},ir=({callback:e,children:n,className:r,data:s,isKit:o,...a})=>{const{item:{availability:{status:l},image:i}}=Y();return l?t.jsxs("div",{...a,className:d.helpers.classNameConcat(U["product-card--actions"],r),children:[t.jsxs(G.Wrapper,{type:"actions--group",children:[t.jsx(G.Price,{}),t.jsx("div",{className:U["product-card--actions--selectors"],children:!o&&t.jsx(G.StyleSelector,{data:s,images:i,callback:e})})]}),n]}):null};ir.displayName="ProductCard.Actions";const lr=({className:e,isKit:n,...r})=>{const{addToCart:s}=Z(),{isMobile:o=!1,selectedSku:a,outStock:l,item:i,sendAddToCartEvent:c,CONSTANTS:u}=Y(),m=()=>{var _;if(!a)return;const p=Qe(a.offers.offers,u.StoreConfig_MainSellerId);p&&s({id:a==null?void 0:a.sku,quantity:1,seller:p.seller.identifier},{id:i.id,texture:(_=i==null?void 0:i.image.find(g=>u.TEXTURE_IMAGE.includes(g.alternateName)))==null?void 0:_.url}),c()},h=a?u.BUY_BUTTON_LABELS.add_to_cart:u.BUY_BUTTON_LABELS.select_size;return t.jsx(d.Button,{...r,className:d.helpers.classNameConcat(e,"buy-button"),disabled:!n&&!a&&!l,size:o?"medium":"large",variant:l?"secondary":"primary",onClick:l?r.onClick:m,children:l?"Avise-me quando chegar":h})};lr.displayName="ProductCard.Actions.BuyButton";const cr=({product:e,tag:n,size:r="small"})=>{const s=e.offers.offers[0],{CONSTANTS:o,WishListToggle:a}=Y();return t.jsxs(G.Wrapper,{type:"header",style:{zIndex:o.Z_INDEX_WAR.product_card_header},children:[n?t.jsx(d.Tag,{title:n.value,adornment:{start:n.enableIcon&&n.icon?t.jsx(d.Icon,{name:n.icon,size:"small",style:{color:n.iconColor}}):null},size:r,variant:"quaternary",style:{background:n.tagColor,color:n.textColor},children:n.value}):null,o.PRODUCT_CARD_TOP_WISHLIST_TOGGLE&&t.jsx(a,{product:e,priceInfo:{price:s.price,listPrice:s.listPrice},variant:"card"})]})};cr.displayName="ProductCard.Actions.Header";const dr=({className:e,children:n,hasPriority:r=!1,showVideo:s=!1,...o})=>{const{element:a,index:l,item:{image:i,slug:c,video:u},sendSelectItemEvent:m,order:h,CONSTANTS:p}=Y(),_=$t({images:i,label:{first:p.MAIN_IMAGE,second:p.SECOND_IMAGE}});return t.jsxs("div",{...o,className:d.helpers.classNameConcat(U["product-card--image"],e),ref:a,style:{aspectRatio:p.PRODUCT_CARD_IMAGE_ASPECT_RATIO},children:[t.jsx(x.NextLink,{href:`/${c}/p`,onClick:m,onMouseUp:g=>{g.button===1&&m(),p.PLP_INFINITE_SCROLL&&sessionStorage.setItem(p.PLP_GRID_SCROLL_BACK.order,String(h))},children:t.jsx("div",{className:U["product-card--image--container"],children:Array.isArray(_)&&_.map(({url:g,alternateName:C},y)=>f.createElement(J.Image,{...p.PRODUCT_IMAGE_DIMENSIONS.product_card,style:p.PRODUCT_IMAGE_DIMENSIONS.product_card,alt:C??"product image",key:y,...r&&{priority:y===0&&l<4},objectFit:"cover",src:g}))})}),p.PLP_SHOW_VIDEO_ON_PRODUCT_CARD&&s&&u&&t.jsx(G.Video,{url:u,poster:_[0].url}),n]})};dr.displayName="ProductCard.Media.Media";const ur=({className:e,callback:n,children:r,...s})=>{const{isMobile:o,item:a,CONSTANTS:{PRODUCT_CARD_TEXTS:l}}=Y(),{availability:{status:i}}=a;return i?null:t.jsxs("div",{...s,className:d.helpers.classNameConcat(U["product-card--outstock"],e),children:[t.jsx(d.Tag,{size:"small",variant:"secondary",title:l.disabled,children:l.disabled}),t.jsx(d.Button,{className:d.helpers.classNameConcat(e,"buy-button"),size:o?"medium":"large",variant:"quaternary",onClick:()=>{typeof n=="function"&&n(a)},children:l.notify})]})};ur.displayName="ProductCard.OutStock";const mr=({children:e,className:n="",index:r,isMobile:s=!1,item:o,size:a,order:l,outStock:i,shelfTitle:c,CONSTANTS:u,WishListToggle:m,...h})=>t.jsx(Fo,{item:o,isMobile:s,outStock:i,order:l,size:a,index:r,shelfTitle:c,CONSTANTS:u,WishListToggle:m,children:t.jsx("div",{...h,className:d.helpers.classNameConcat(U["product-card--wrapper"],n),"data-size":a,children:e})});mr.displayName="ProductCard.Root";const pr=({disabled:e,label:n,size:r,value:s,onClick:o,...a})=>t.jsxs(d.ToggleSize.Wrapper,{...a,disabled:!1,outOfStock:e,size:r,onClick:o,children:[t.jsx(d.ToggleSize.DisabledAdornment,{}),t.jsx(d.ToggleSize.Text,{children:n})]});pr.displayName="ProductCard.SizeSelector.Item";const fr=({active:e=!1,callback:n,selectedSku:r=null,item:s,setNotify:o})=>{const{item:a,isMobile:l,setSelectedSku:i,eventDataRef:c}=Y();s.productId=a.id;const u=Lt(s),m=x.getSKUName(s,"tamanho");!u&&!c.current.availableSkus.includes(m)&&c.current.availableSkus.push(m);const h=f.useCallback(_=>{const g=r===_?null:_;typeof i=="function"&&i(g),typeof n=="function"&&n(g)},[n,i,r]),p=f.useCallback(()=>{if(u&&typeof o=="function"){o(a,s);return}h(s)},[s,o,h,u,a]);return t.jsx(pr,{active:e,disabled:u,label:m,onClick:()=>p(),size:l?"x-small":"small",value:s})};fr.displayName="ProductCard.SizeSelector.SkuItem";const hr=({callback:e,className:n="",children:r,setNotify:s,...o})=>{const{isMobile:a,item:{isVariantOf:{hasVariant:l}},selectedSku:i}=Y();return t.jsxs("div",{...o,className:d.helpers.classNameConcat(U["product-card--selectors--size"],n),"data-mobile":a,children:[t.jsx("div",{className:U["product-card--selectors--size--skus"],children:Array.isArray(l)&&l.map((c,u)=>t.jsx(fr,{active:i===c,callback:e,item:c,selectedSku:i,setNotify:s},`size--${u}--${c.sku}`))}),t.jsx("div",{className:U["product-card--selectors--size--button"],children:r})]})};hr.displayName="ProductCard.SizeSelector";const $e=({alt:e="",callback:n,more:r,total:s=4,src:o,url:a,...l})=>t.jsxs(d.ToggleStyle.Wrapper,{...l,onClick:()=>{typeof n=="function"&&n(a)},children:[t.jsx(d.ToggleStyle.DisabledAdornment,{}),t.jsxs(d.ToggleStyle.Texture,{children:[o&&t.jsx(J.Image,{alt:e??o,src:o,height:34,width:34}),r&&t.jsx(d.TextStructure.DivWrapper,{className:U["product-card--selectors--style--more"],children:t.jsxs("p",{children:["+ ",s]})})]})]}),Uo=({children:e,callback:n,data:r,total:s=4,size:o,...a})=>{const{index:l}=Y(),{triggerSelectItemEventRef:i}=x.useEventContext();return t.jsxs("div",{...a,children:[e,Array.isArray(r)&&r.slice(0,s).map((c,u)=>t.jsx($e,{callback:m=>{i.current.trigger=!0,i.current.index=l,typeof n=="function"&&n(m)},src:(c==null?void 0:c.textureImage)??"",alt:c==null?void 0:c.textureAlt,url:c==null?void 0:c.slug,size:o},u)),Array.isArray(r)&&(r==null?void 0:r.length)>s&&t.jsx($e,{size:o,total:r.length-s,more:!0})]})},gr=({callback:e,className:n,data:r,images:s=[],findTexture:o,...a})=>{const{CONSTANTS:l}=Y(),i=o||l.TEXTURE_IMAGE,c=s==null?void 0:s.find(u=>i.includes(u.alternateName));return t.jsx(Uo,{...a,callback:e,className:d.helpers.classNameConcat(U["product-card--selectors--style"],n),data:r,size:"x-small",children:c&&t.jsx($e,{active:!0,size:"x-small",src:c.url})})};gr.displayName="ProductCard.StyleSelector";const _r=({className:e,hasDecimal:n,...r})=>{const{isMobile:s,item:{offers:{lowPrice:o,highPrice:a},installments:{count:l,value:i}},eventDataRef:c}=Y();c.current.priceInfo={price:o,listPrice:a};const u=K(a,n),m=K(o,n),h=K(i??0),p=s?"horizontal":"stacked";return t.jsx("div",{...r,className:d.helpers.classNameConcat(U["product-card--price"],e),"data-mobile":s,children:t.jsx(d.ProductInfo.Root,{size:"small",layout:p,children:t.jsxs(d.ProductInfo.Wrapper,{size:"small",layout:p,children:[t.jsx(d.ProductInfo.ValuesWrapper,{children:m!==u?t.jsxs(t.Fragment,{children:[t.jsx(d.ProductInfo.Price,{label:"originalPrice",value:u,size:"small"}),t.jsx(d.ProductInfo.Price,{label:"discountPrice",value:m,size:"small"})]}):t.jsx(d.ProductInfo.Price,{label:"defaultPrice",value:m,size:"small"})}),l&&l>1&&i?t.jsx(d.ProductInfo.Price,{label:"installment",value:`${l}x ${h}`,size:"small"}):null]})})})};_r.displayName="ProductCard.Price";const xr=({tag:e,className:n})=>{const{item:{name:r}}=Y();return t.jsxs("div",{className:d.helpers.classNameConcat(U["product-card--title"],n),children:[t.jsx("div",{className:U["product-card--title--tag"],children:e?t.jsx(d.Tag,{size:"small",title:e.value,variant:"quaternary",adornment:{start:e.enableIcon&&e.icon?t.jsx(d.Icon,{name:e.icon,style:{color:e.iconColor}}):null},style:{background:e.tagColor,color:e.textColor},children:e.value}):t.jsx("div",{})}),t.jsx("div",{className:U["product-card--title--content"],children:r&&t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{children:t.jsx("h3",{children:r})})})})]})};xr.displayName="ProductCard.Title";const yr=({className:e,url:n,poster:r,...s})=>{const{element:o}=Y();return f.useEffect(()=>{if(!(o!=null&&o.current))return;const a=o.current,l=a.querySelector("video");if(l){const i=new IntersectionObserver(m=>{m.forEach(h=>{Ft(h.isIntersecting,l,n)})},{root:null,rootMargin:"0px",threshold:.5}),c=()=>{l.setAttribute("data-loaded","true")},u=()=>{a&&(i.observe(a),l.addEventListener("loadeddata",c))};return document.readyState==="complete"?u():window.addEventListener("load",u),()=>{i.disconnect(),window.removeEventListener("load",u)}}return()=>null},[n,o]),t.jsx("div",{...s,className:d.helpers.classNameConcat(U["product-card--video"],e),children:n&&t.jsx(J.Video,{autoPlay:!1,muted:!0,loop:!0,preload:"none",playsInline:!0,poster:r})})};yr.displayName="ProductCard.Media.Video";const Cr=({children:e,className:n,type:r,...s})=>t.jsx("div",{...s,className:d.helpers.classNameConcat(U[`product-card--${r}`],n),children:e});Cr.displayName="ProductCard.Wrapper";const G={Actions:ir,BuyButton:lr,Header:cr,Media:dr,Root:mr,OutStock:ur,Price:_r,SizeSelector:hr,StyleSelector:gr,Title:xr,Video:yr,Wrapper:Cr},qo=Object.freeze(Object.defineProperty({__proto__:null,Footer:x.Footer,FooterSupport:x.FooterSupport},Symbol.toStringTag,{value:"Module"})),Ct=({image:e,index:n,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:s})=>{const o=zt(e.imageUrl,s.pdp),{nextimage:a}=x.useNextContext();return t.jsx(a,{src:o,alt:e.imageLabel,objectFit:"contain",...s.pdp,...n<=1&&{priority:!0,loading:"eager"},onClick:()=>{r(n)}},n)},Vo=({video:e,productName:n,poster:r})=>{const{sendDataLayerEvent:s}=x.useEventContext(),o=f.useRef(!1);return t.jsx(J.Video,{src:e,autoPlay:!0,muted:!0,loop:!0,playsInline:!0,style:{zIndex:-1,aspectRatio:"2/3"},onPlaying:()=>{o.current||(o.current=!0,s({functionKey:"readyEvents",data:{event:"video_start",readyData:{product:n}}}))},poster:r})},Go={"gallery-carousel-modifier":"_gallery-carousel-modifier_1dxfy_92"},vr=({images:e,video:n,handleZoom:r,productName:s,PRODUCT_IMAGE_DIMENSIONS:o})=>{var u,m;const{initialize:a,pagination:l,controller:i,itemsStyles:c}=d.Carousel.useCarousel({gap:0,itemsPerPage:1,loop:!1,direction:"row"});return t.jsxs(d.Carousel.Root,{innerRef:h=>{a(h)},className:Go["gallery-carousel-modifier"],children:[t.jsx(d.Carousel.Controller,{position:"absolute",top:"24px",bottom:"unset",left:"16px",children:t.jsx(d.Carousel.Bullets,{page:l.currentPage,total:e.length,onBulletClick:h=>i==null?void 0:i.navigateTo(h)})}),t.jsxs(d.Carousel.Body,{children:[t.jsx(d.Carousel.Item,{style:c,children:t.jsx(Ct,{image:e[0],index:0,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:o})},"PDP_gallery_0"),n&&t.jsx(d.Carousel.Item,{style:c,children:t.jsx(Vo,{video:n,productName:s,...((u=e[1])==null?void 0:u.imageUrl)&&{poster:(m=e[1])==null?void 0:m.imageUrl}})},"PDP_gallery_video"),e.map((h,p)=>p===0?null:t.jsx(d.Carousel.Item,{style:c,children:t.jsx(Ct,{image:h,index:p,handleZoom:r,PRODUCT_IMAGE_DIMENSIONS:o})},`PDP_gallery_${p}`))]})]})};vr.displayName="PDP.Carousel";const Ho=({productImgs:e,PRODUCT_IMAGE_DIMENSIONS:n})=>{const{video:r,productName:s}=Je(),[o,a]=f.useState({show:!1,initialIndex:0});f.useEffect(()=>(o.show?document.body.classList.add("no-scroll"):document.body.classList.remove("no-scroll"),()=>{document.body.classList.remove("no-scroll")}),[o]);const l=i=>{a({show:!0,initialIndex:i})};return t.jsx(t.Fragment,{children:t.jsx(vr,{images:e,video:r,handleZoom:l,productName:s,PRODUCT_IMAGE_DIMENSIONS:n})})},br=({TEXTURE_IMAGE:e,PRODUCT_IMAGE_DIMENSIONS:n})=>{const{images:r}=Je(),s=f.useMemo(()=>{const o=r.filter(a=>!e.includes(a.imageLabel));return o.length>0?o:r},[]);return t.jsx(Ho,{productImgs:s,PRODUCT_IMAGE_DIMENSIONS:n})};br.displayName="PDP.Gallery";const Wo=Object.freeze(Object.defineProperty({__proto__:null,Gallery:br},Symbol.toStringTag,{value:"Module"})),Ko="_container_1sy8s_16",te={"carousel-container":"_carousel-container_1sy8s_1","add-cart-container":"_add-cart-container_1sy8s_8",container:Ko,"add-itens-to-cart-container":"_add-itens-to-cart-container_1sy8s_38","add-itens-to-cart-container-values":"_add-itens-to-cart-container-values_1sy8s_45","add-itens-to-cart-qty-products":"_add-itens-to-cart-qty-products_1sy8s_50","add-itens-to-cart-total":"_add-itens-to-cart-total_1sy8s_60","add-button":"_add-button_1sy8s_70"},Xo=({selectedProducts:e,handleAddAllToCart:n,CONSTANTS:r})=>{const s=Object.values(e.products).length;return t.jsxs("div",{className:te["add-itens-to-cart-container"],children:[t.jsxs("div",{className:te["add-itens-to-cart-container-values"],children:[t.jsx("div",{className:te["add-itens-to-cart-qty-products"],children:t.jsx("span",{children:s===0?r.BUY_PACKAGE.group_cart.select_all_product:`${s} ${s===1?r.BUY_PACKAGE.group_cart.select_product:r.BUY_PACKAGE.group_cart.select_product+"s"}`})}),t.jsx("div",{className:te["add-itens-to-cart-total"],children:t.jsx("span",{children:Ye({valueInCents:e.totalPrice*100,hasFree:!1,freeTaxMessage:r.FREIGHT_CALCULATION.messages.free_tax})})})]}),t.jsx(d.Button,{onClick:n,className:te["add-button"],size:"large",disabled:s===0,variant:"primary",children:r.BUY_BUTTON_LABELS.add_to_cart})]})},Yo=e=>e.reduce((n,r)=>{var o;const s=n.find(a=>a.node.id===r.node.id);if(!s)return[...n,r];if((o=s==null?void 0:s.node.isVariantOf)!=null&&o.hasVariant){const a=s.node.isVariantOf.hasVariant,l=r.node.isVariantOf.hasVariant;a&&l&&(s.node.isVariantOf.hasVariant=[...a,...l])}return n},[]),Qo=({selectedProduct:e,productId:n,prevState:r,mainSellerId:s})=>{const{products:o,totalPrice:a}=r;try{if(!e){const{[n]:u,...m}=o;return{...r,totalPrice:a-u.price,products:m}}const l=Qe(e.offers.offers,s);if(!l)return r;const i=l.seller.identifier,c=l.price;if(o[n]){const{price:u}=o[n];return o[n]={...o[n],price:c,id:e.sku,seller:i},{totalPrice:a+c-u,products:{...o}}}return{totalPrice:a+c,products:{...o,[n]:{id:e.sku,price:c,seller:i,productId:n}}}}catch(l){return console.error("Error handling SKU selection:",l),r}},Jo="_carousel_245ib_1",Zo="_shelf__container_245ib_14",ea="_shelf_without_carousel_245ib_34",he={carousel:Jo,"custom-controllers":"_custom-controllers_245ib_5",shelf__container:Zo,"controllers-arrows-bullets":"_controllers-arrows-bullets_245ib_23",shelf_without_carousel:ea},vt=({title:e})=>t.jsx("div",{className:he.shelf__container,children:e&&t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{children:[t.jsx("h2",{className:d.helpers.classNameConcat("typography-style-body-md",x.responsive["responsive-mobile-flex"]),children:e}),t.jsx("h2",{className:d.helpers.classNameConcat("typography-style-heading-md",x.responsive["responsive-desktop-flex"]),children:e})]})})}),ta=({children:e,ICONS:n,itemsPerPage:r,title:s})=>{const{isMobile:o}=x.useGlobalContext(),a=r[o?"mobile":"desktop"],{initialize:l,controller:i,itemsStyles:c,pagination:u}=d.Carousel.useCarousel({itemsPerPage:a,gap:10,loop:!0,direction:"row"}),m=f.Children.toArray(e).length;return o||m>=4?t.jsxs(d.Carousel.Root,{innerRef:p=>{l(p)},className:he.carousel,children:[t.jsxs("div",{className:he["custom-controllers"],children:[s&&t.jsx(vt,{title:s}),a<m&&t.jsxs(d.Carousel.Controller,{className:he["controllers-arrows-bullets"],children:[t.jsxs(d.Carousel.Arrows,{children:[t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.prevPage(),adornment:{start:t.jsx(d.Icon,{name:n.arrow_left})}}),t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.nextPage(),adornment:{start:t.jsx(d.Icon,{name:n.arrow_right})}})]}),!o&&a>2&&t.jsx(d.Carousel.Bullets,{page:u.currentPage,total:u.totalPages,onBulletClick:p=>i==null?void 0:i.navigateTo(p)})]})]}),t.jsx(d.Carousel.Body,{children:f.Children.map(e,(p,_)=>t.jsx(d.Carousel.Item,{style:{...c,overflow:"hidden"},children:p},`${s}_${_}`))})]}):t.jsxs(t.Fragment,{children:[s&&t.jsx(vt,{title:s}),t.jsx("div",{className:he.shelf_without_carousel,children:e})]})},na={Shelf:ta},ra=({CONSTANTS:e,inView:n,products:r,innerRef:s,WishListToggle:o})=>{const a=f.useMemo(()=>Yo(r),[r]),{isMobile:l}=x.useGlobalContext(),{addItemsToCart:i}=Z(),{sendDataLayerEvent:c}=x.useEventContext(),{getAvailableProductTag:u}=Xe(),[m,h]=f.useState({totalPrice:0,products:{}}),p=()=>{const g=Object.values(m.products);i(g),c({functionKey:"skuEvents",data:{event:"add_to_cart",commonData:{products:g.map(C=>{const y=a.find(v=>v.node.id===C.productId);return y==null?void 0:y.node})},supportData:{selectedSkus:g,price:m.totalPrice}}})},_=({selectedProduct:g,productId:C})=>{const y=Qo({selectedProduct:g,productId:C,prevState:m,mainSellerId:e.StoreConfig_MainSellerId});h(y)};return f.useEffect(()=>{if(!n||a.length===0)return;const g=e.BUY_PACKAGE.header.title;c({functionKey:"productListEvent",data:{event:"view_item_list",commonData:{products:a},customData:{item_list_name:g},outsideEcommerceData:{item_list_name:g}}})},[n]),t.jsxs("div",{className:te.container,ref:s,children:[t.jsx("div",{className:te["carousel-container"],style:{width:a.length<=3?"max-content":"75%"},children:t.jsx(na.Shelf,{title:e.BUY_PACKAGE.header.title,itemsPerPage:{desktop:3,mobile:a.length>=3?2.2:a.length},ICONS:e.ICONS,children:Array.isArray(a)&&a.map(({node:g},C)=>{var N,j,w;const y=u(g.cluster.highlights),{availability:{status:v}}=g;return v?t.jsxs(G.Root,{item:{...g,image:at.helpers.product.getFirstImages({images:g.image,label:{first:e.MAIN_IMAGE,second:e.SECOND_IMAGE}})},isMobile:l,size:"medium",index:C,shelfTitle:e.BUY_PACKAGE.header.title,CONSTANTS:e,WishListToggle:o,children:[t.jsx(G.Header,{product:g,tag:y.commercial}),t.jsx(G.Media,{}),t.jsxs(G.Wrapper,{type:"body",children:[t.jsx(G.Title,{tag:{value:(N=y.institucional)==null?void 0:N.value,enableIcon:(j=y.institucional)==null?void 0:j.enableIcon,icon:(w=y.institucional)==null?void 0:w.icon}}),t.jsx(G.Actions,{children:t.jsx(G.SizeSelector,{callback:b=>_({selectedProduct:b,productId:g.id})})})]})]},g.id):null})})}),t.jsx("div",{className:te["add-cart-container"],children:t.jsx(Xo,{handleAddAllToCart:p,selectedProducts:m,CONSTANTS:{BUY_BUTTON_LABELS:e.BUY_BUTTON_LABELS,BUY_PACKAGE:e.BUY_PACKAGE,FREIGHT_CALCULATION:e.FREIGHT_CALCULATION}})})]})},sa=({page:e,data:n})=>{const{pathname:r}=x.useNextContext(),s=f.useRef(null),{sendDataLayerEvent:o,currentLocalRef:a,itemListRef:l,promotionEventRef:i}=x.useEventContext();return f.useEffect(()=>{const c=gn("login_event")||"{}",u=JSON.parse(c);if(u.name||u.method){const m=new Date(0);o({functionKey:"readyEvents",data:{event:u.name,readyData:{method:u.method}}}),st("login_event","",{expires:m})}},[]),f.useEffect(()=>{if(s.current===r)return;s.current=r;let c={};switch(e){case"PDP":{const m=n,h={};if(!m){c={page_category:"pdp"};break}m.items.forEach(({itemId:p,sellers:_})=>h[p]=_[0].commertialOffer.AvailableQuantity),c={page_category:"pdp",seller_ids:m.items.map(({sellers:p})=>p[0].sellerId).join(),skuStocks:h,product_reference_id:m.productReference};break}case"PDC":{const{page_category:m,page_departament:h,id:p,name:_}=x.getPageCategoryAndDepartmentFromSlug(),g=_,C=p;c={page_category:"lista_produtos",...h&&{page_departament:h}},l.current={item_list_name:r==="/search"?"busca":g??void 0,item_list_id:r==="/search"?void 0:C??void 0},h&&o({functionKey:"readyEvents",data:{event:"view_category",readyData:{page_category:m,page_departament:h}}});break}default:c={page_category:e},i.current={},l.current={};break}const u={region:e,...c};a.current=e,o({functionKey:"readyEvents",data:{readyData:{vtex_version:"fast",...u}},timeout:0})},[r]),null};var Fe={exports:{}};function oa(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Oe={},Le={},bt;function aa(){return bt||(bt=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"LoadableContext",{enumerable:!0,get:function(){return s}});const s=x._interop_require_default._(f).default.createContext(null);process.env.NODE_ENV!=="production"&&(s.displayName="LoadableContext")}(Le)),Le}var jt;function ia(){return jt||(jt=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return _}});const r=x._interop_require_default._(f),s=aa();function o(g){return g&&g.default?g.default:g}const a=[],l=[];let i=!1;function c(g){let C=g(),y={loading:!0,loaded:null,error:null};return y.promise=C.then(v=>(y.loading=!1,y.loaded=v,v)).catch(v=>{throw y.loading=!1,y.error=v,v}),y}function u(g,C){let y=Object.assign({loader:null,loading:null,delay:200,timeout:null,webpack:null,modules:null},C),v=null;function N(){if(!v){const b=new m(g,y);v={getCurrentValue:b.getCurrentValue.bind(b),subscribe:b.subscribe.bind(b),retry:b.retry.bind(b),promise:b.promise.bind(b)}}return v.promise()}if(typeof window>"u"&&a.push(N),!i&&typeof window<"u"){const b=y.webpack&&typeof oa.resolveWeak=="function"?y.webpack():y.modules;b&&l.push(I=>{for(const k of b)if(I.includes(k))return N()})}function j(){N();const b=r.default.useContext(s.LoadableContext);b&&Array.isArray(y.modules)&&y.modules.forEach(I=>{b(I)})}function w(b,I){j();const k=r.default.useSyncExternalStore(v.subscribe,v.getCurrentValue,v.getCurrentValue);return r.default.useImperativeHandle(I,()=>({retry:v.retry}),[]),r.default.useMemo(()=>k.loading||k.error?r.default.createElement(y.loading,{isLoading:k.loading,pastDelay:k.pastDelay,timedOut:k.timedOut,error:k.error,retry:v.retry}):k.loaded?r.default.createElement(o(k.loaded),b):null,[b,k])}return w.preload=()=>N(),w.displayName="LoadableComponent",r.default.forwardRef(w)}class m{promise(){return this._res.promise}retry(){this._clearTimeouts(),this._res=this._loadFn(this._opts.loader),this._state={pastDelay:!1,timedOut:!1};const{_res:C,_opts:y}=this;C.loading&&(typeof y.delay=="number"&&(y.delay===0?this._state.pastDelay=!0:this._delay=setTimeout(()=>{this._update({pastDelay:!0})},y.delay)),typeof y.timeout=="number"&&(this._timeout=setTimeout(()=>{this._update({timedOut:!0})},y.timeout))),this._res.promise.then(()=>{this._update({}),this._clearTimeouts()}).catch(v=>{this._update({}),this._clearTimeouts()}),this._update({})}_update(C){this._state={...this._state,error:this._res.error,loaded:this._res.loaded,loading:this._res.loading,...C},this._callbacks.forEach(y=>y())}_clearTimeouts(){clearTimeout(this._delay),clearTimeout(this._timeout)}getCurrentValue(){return this._state}subscribe(C){return this._callbacks.add(C),()=>{this._callbacks.delete(C)}}constructor(C,y){this._loadFn=C,this._opts=y,this._callbacks=new Set,this._delay=null,this._timeout=null,this.retry()}}function h(g){return u(c,g)}function p(g,C){let y=[];for(;g.length;){let v=g.pop();y.push(v(C))}return Promise.all(y).then(()=>{if(g.length)return p(g,C)})}h.preloadAll=()=>new Promise((g,C)=>{p(a).then(g,C)}),h.preloadReady=g=>(g===void 0&&(g=[]),new Promise(C=>{const y=()=>(i=!0,C());p(l,g).then(y,y)})),typeof window<"u"&&(window.__NEXT_PRELOADREADY=h.preloadReady);const _=h}(Oe)),Oe}(function(e,n){Object.defineProperty(n,"__esModule",{value:!0});function r(m,h){for(var p in h)Object.defineProperty(m,p,{enumerable:!0,get:h[p]})}r(n,{noSSR:function(){return c},default:function(){return u}});const s=x._interop_require_default,o=s._(f),a=s._(ia()),l=typeof window>"u";function i(m){return{default:(m==null?void 0:m.default)||m}}function c(m,h){if(delete h.webpack,delete h.modules,!l)return m(h);const p=h.loading;return()=>o.default.createElement(p,{error:null,isLoading:!0,pastDelay:!1,timedOut:!1})}function u(m,h){let p=a.default,_={loading:y=>{let{error:v,isLoading:N,pastDelay:j}=y;if(!j)return null;if(process.env.NODE_ENV!=="production"){if(N)return null;if(v)return o.default.createElement("p",null,v.message,o.default.createElement("br",null),v.stack)}return null}};m instanceof Promise?_.loader=()=>m:typeof m=="function"?_.loader=m:typeof m=="object"&&(_={..._,...m}),_={..._,...h};const g=_.loader,C=()=>g!=null?g().then(i):Promise.resolve(i(()=>null));return _.loadableGenerated&&(_={..._,..._.loadableGenerated},delete _.loadableGenerated),typeof _.ssr=="boolean"&&!_.ssr?(delete _.webpack,delete _.modules,c(p,_)):p({..._,loader:C})}(typeof n.default=="function"||typeof n.default=="object"&&n.default!==null)&&typeof n.default.__esModule>"u"&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),e.exports=n.default)})(Fe,Fe.exports);var la=Fe.exports,ca=la;const da=x.getDefaultExportFromCjs(ca);var Ue={exports:{}},Se={exports:{}},St;function ua(){return St||(St=1,function(e,n){Object.defineProperty(n,"__esModule",{value:!0});function r(c,u){for(var m in u)Object.defineProperty(c,m,{enumerable:!0,get:u[m]})}r(n,{DOMAttributeNames:function(){return s},isEqualNode:function(){return a},default:function(){return i}});const s={acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv",noModule:"noModule"};function o(c){let{type:u,props:m}=c;const h=document.createElement(u);for(const g in m){if(!m.hasOwnProperty(g)||g==="children"||g==="dangerouslySetInnerHTML"||m[g]===void 0)continue;const C=s[g]||g.toLowerCase();u==="script"&&(C==="async"||C==="defer"||C==="noModule")?h[C]=!!m[g]:h.setAttribute(C,m[g])}const{children:p,dangerouslySetInnerHTML:_}=m;return _?h.innerHTML=_.__html||"":p&&(h.textContent=typeof p=="string"?p:Array.isArray(p)?p.join(""):""),h}function a(c,u){if(c instanceof HTMLElement&&u instanceof HTMLElement){const m=u.getAttribute("nonce");if(m&&!c.getAttribute("nonce")){const h=u.cloneNode(!0);return h.setAttribute("nonce",""),h.nonce=m,m===c.nonce&&c.isEqualNode(h)}}return c.isEqualNode(u)}let l;process.env.__NEXT_STRICT_NEXT_HEAD?l=(c,u)=>{const m=document.querySelector("head");if(!m)return;const h=m.querySelectorAll('meta[name="next-head"]')||[],p=[];if(c==="meta"){const C=m.querySelector("meta[charset]");C&&p.push(C)}for(let C=0;C<h.length;C++){var _;const v=h[C].nextSibling;(v==null||(_=v.tagName)==null?void 0:_.toLowerCase())===c&&p.push(v)}const g=u.map(o).filter(C=>{for(let y=0,v=p.length;y<v;y++){const N=p[y];if(a(N,C))return p.splice(y,1),!1}return!0});p.forEach(C=>{var y;const v=C.previousSibling;if(v&&v.getAttribute("name")==="next-head"){var N;(N=C.parentNode)==null||N.removeChild(v)}(y=C.parentNode)==null||y.removeChild(C)}),g.forEach(C=>{var y;const v=document.createElement("meta");v.name="next-head",v.content="1",((y=C.tagName)==null?void 0:y.toLowerCase())==="meta"&&C.getAttribute("charset")||m.appendChild(v),m.appendChild(C)})}:l=(c,u)=>{const m=document.getElementsByTagName("head")[0],h=m.querySelector("meta[name=next-head-count]");if(process.env.NODE_ENV!=="production"&&!h){console.error("Warning: next-head-count is missing. https://nextjs.org/docs/messages/next-head-count-missing");return}const p=Number(h.content),_=[];for(let y=0,v=h.previousElementSibling;y<p;y++,v=(v==null?void 0:v.previousElementSibling)||null){var g;(v==null||(g=v.tagName)==null?void 0:g.toLowerCase())===c&&_.push(v)}const C=u.map(o).filter(y=>{for(let v=0,N=_.length;v<N;v++){const j=_[v];if(a(j,y))return _.splice(v,1),!1}return!0});_.forEach(y=>{var v;return(v=y.parentNode)==null?void 0:v.removeChild(y)}),C.forEach(y=>m.insertBefore(y,h)),h.content=(p-_.length+C.length).toString()};function i(){return{mountedInstances:new Set,updateHead:c=>{const u={};c.forEach(p=>{if(p.type==="link"&&p.props["data-optimized-fonts"]){if(document.querySelector('style[data-href="'+p.props["data-href"]+'"]'))return;p.props.href=p.props["data-href"],p.props["data-href"]=void 0}const _=u[p.type]||[];_.push(p),u[p.type]=_});const m=u.title?u.title[0]:null;let h="";if(m){const{children:p}=m.props;h=typeof p=="string"?p:Array.isArray(p)?p.join(""):""}h!==document.title&&(document.title=h),["meta","base","link","style","script"].forEach(p=>{l(p,u[p]||[])})}}}(typeof n.default=="function"||typeof n.default=="object"&&n.default!==null)&&typeof n.default.__esModule>"u"&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),e.exports=n.default)}(Se,Se.exports)),Se.exports}(function(e,n){"use client";Object.defineProperty(n,"__esModule",{value:!0});function r(b,I){for(var k in I)Object.defineProperty(b,k,{enumerable:!0,get:I[k]})}r(n,{handleClientScriptLoad:function(){return C},initScriptLoader:function(){return N},default:function(){return w}});const s=x._interop_require_default,o=x._interop_require_wildcard,a=s._(Tr),l=o._(f),i=x.requireHeadManagerContext_sharedRuntime(),c=ua(),u=x.requireRequestIdleCallback(),m=new Map,h=new Set,p=["onLoad","onReady","dangerouslySetInnerHTML","children","onError","strategy","stylesheets"],_=b=>{if(a.default.preinit){b.forEach(I=>{a.default.preinit(I,{as:"style"})});return}if(typeof window<"u"){let I=document.head;b.forEach(k=>{let D=document.createElement("link");D.type="text/css",D.rel="stylesheet",D.href=k,I.appendChild(D)})}},g=b=>{const{src:I,id:k,onLoad:D=()=>{},onReady:F=null,dangerouslySetInnerHTML:M,children:B="",strategy:V="afterInteractive",onError:R,stylesheets:S}=b,E=k||I;if(E&&h.has(E))return;if(m.has(I)){h.add(E),m.get(I).then(D,R);return}const A=()=>{F&&F(),h.add(E)},P=document.createElement("script"),$=new Promise((z,q)=>{P.addEventListener("load",function(W){z(),D&&D.call(this,W),A()}),P.addEventListener("error",function(W){q(W)})}).catch(function(z){R&&R(z)});M?(P.innerHTML=M.__html||"",A()):B?(P.textContent=typeof B=="string"?B:Array.isArray(B)?B.join(""):"",A()):I&&(P.src=I,m.set(I,$));for(const[z,q]of Object.entries(b)){if(q===void 0||p.includes(z))continue;const W=c.DOMAttributeNames[z]||z.toLowerCase();P.setAttribute(W,q)}V==="worker"&&P.setAttribute("type","text/partytown"),P.setAttribute("data-nscript",V),S&&_(S),document.body.appendChild(P)};function C(b){const{strategy:I="afterInteractive"}=b;I==="lazyOnload"?window.addEventListener("load",()=>{(0,u.requestIdleCallback)(()=>g(b))}):g(b)}function y(b){document.readyState==="complete"?(0,u.requestIdleCallback)(()=>g(b)):window.addEventListener("load",()=>{(0,u.requestIdleCallback)(()=>g(b))})}function v(){[...document.querySelectorAll('[data-nscript="beforeInteractive"]'),...document.querySelectorAll('[data-nscript="beforePageRender"]')].forEach(I=>{const k=I.id||I.getAttribute("src");h.add(k)})}function N(b){b.forEach(C),v()}function j(b){const{id:I,src:k="",onLoad:D=()=>{},onReady:F=null,strategy:M="afterInteractive",onError:B,stylesheets:V,...R}=b,{updateScripts:S,scripts:E,getIsSsr:A,appDir:P,nonce:$}=(0,l.useContext)(i.HeadManagerContext),z=(0,l.useRef)(!1);(0,l.useEffect)(()=>{const W=I||k;z.current||(F&&W&&h.has(W)&&F(),z.current=!0)},[F,I,k]);const q=(0,l.useRef)(!1);if((0,l.useEffect)(()=>{q.current||(M==="afterInteractive"?g(b):M==="lazyOnload"&&y(b),q.current=!0)},[b,M]),(M==="beforeInteractive"||M==="worker")&&(S?(E[M]=(E[M]||[]).concat([{id:I,src:k,onLoad:D,onReady:F,onError:B,...R}]),S(E)):A&&A()?h.add(I||k):A&&!A()&&g(b)),P){if(V&&V.forEach(W=>{a.default.preinit(W,{as:"style"})}),M==="beforeInteractive")return k?(a.default.preload(k,R.integrity?{as:"script",integrity:R.integrity}:{as:"script"}),l.default.createElement("script",{nonce:$,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([k])+")"}})):(R.dangerouslySetInnerHTML&&(R.children=R.dangerouslySetInnerHTML.__html,delete R.dangerouslySetInnerHTML),l.default.createElement("script",{nonce:$,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([0,{...R}])+")"}}));M==="afterInteractive"&&k&&a.default.preload(k,R.integrity?{as:"script",integrity:R.integrity}:{as:"script"})}return null}Object.defineProperty(j,"__nextScript",{value:!0});const w=j;(typeof n.default=="function"||typeof n.default=="object"&&n.default!==null)&&typeof n.default.__esModule>"u"&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),e.exports=n.default)})(Ue,Ue.exports);var ma=Ue.exports,pa=ma;const fa=x.getDefaultExportFromCjs(pa),ha=({children:e,ONE_TRUST:n})=>t.jsxs(t.Fragment,{children:[t.jsx(fa,{src:"https://cdn.cookielaw.org/scripttemplates/otSDKStub.js",defer:!0,strategy:"afterInteractive","data-domain-script":n.siteId,type:"text/javascript"}),e]}),ga=da(()=>Promise.resolve(ha),{ssr:!1}),_a={"snackbar-modifier":"_snackbar-modifier_1va2l_1"},ge=({size:e,adornment:n,title:r,subtitle:s,supportChildren:o,className:a,Z_INDEX_WAR:l,...i})=>t.jsxs(d.SnackBar.Structure,{...i,size:e,className:d.helpers.classNameConcat(_a["snackbar-modifier"],a),width:360,style:{zIndex:l.snackbar},children:[t.jsx(d.SnackBar.Content,{adornment:n,title:r,subtitle:s}),o&&t.jsx(d.SnackBar.Support,{children:o})]});ge.displayName="SnackBar";const jr=({children:e,contentState:n,entityKey:r})=>{const{url:s}=n.getEntity(r).getData();return s?t.jsx(x.NextLink,{href:s,children:e}):e},xa={teamComponents:{AddToCart:it,BackToTop:Hs,BuyPackage:ra,...qo,FreightCalculation:$o,Header:or,Link:ne,Media:J,ProductCard:G,UserMenu:ut},template:{pdp:Wo},utils:{EventCollector:sa,ExternalScripts:ga,LinkOrNotLink:ve,ObserverWrapper:Ae,SnackBarComponent:ge,DraftJsLinkWrapper:jr}},ya=(e,n)=>{const r=e.map(o=>`'${o.source}'`).join(`,
42
2
  `);return`
43
3
  import type { NextRequest } from 'next/server'
44
4
  import { NextResponse } from 'next/server'
@@ -58,7 +18,7 @@ See more info here: https://nextjs.org/docs/messages/no-stylesheets-in-head-comp
58
18
 
59
19
  if (redirect?.destination) {
60
20
  try {
61
- const redirectUrl = new URL(redirect.destination, '${t}')
21
+ const redirectUrl = new URL(redirect.destination, '${n}')
62
22
  return NextResponse.redirect(redirectUrl, 301)
63
23
  } catch (e) {
64
24
  console.error('[ERROR INVALID URL]:', redirect.destination)
@@ -78,4 +38,4 @@ See more info here: https://nextjs.org/docs/messages/no-stylesheets-in-head-comp
78
38
  ${r}
79
39
  ]
80
40
  }
81
- `},oh=Object.freeze(Object.defineProperty({__proto__:null,generateMiddleware:nh},Symbol.toStringTag,{value:"Module"})),ih={helpers:oh},sh=(e,t,r)=>{e.findEntityRanges(n=>{const o=n.getEntity();return o===null?!1:r.getEntity(o).getType()==="LINK"},t)},zt=e=>{const t=new De.CompositeDecorator([{strategy:sh,component:Hu}]),r=De.convertFromRaw(e);return De.EditorState.createWithContent(r,t)},ah=e=>De.convertFromRaw(e),Ut=De.DefaultDraftBlockRenderMap.set("unstyled",{element:"div",aliasedElements:["div"]}),qs="superior-direita",Ht="dentro-inferior-centro",ch="inferior-direita",Fn="dentro-inferior-esquerda",Fu=e=>({position:e===Ht||e===Fn?"absolute":"default",shouldRender:[qs,Ht,Fn].includes(e)?"top":"bottom",alignItems:[Ht].includes(e)?"center":[qs,ch].includes(e)?"flex-end":"flex-start",left:e===Fn?"16px":e===Ht?"45%":"unset"}),uh=Object.freeze(Object.defineProperty({__proto__:null,CREATE_CONTENT:zt,EXTENDED_BLOCK_RENDER_MAP:Ut,GET_CONTENT_STATE:ah,controllersPositionsAdapter:Fu},Symbol.toStringTag,{value:"Module"})),Ze=e=>({centro:"center",esquerda:"start",direita:"end"})[e],lh=({expanded:e,content:t})=>s.jsxs("details",{open:e,children:[t.textStructureReduced?s.jsx("summary",{onClick:r=>r.preventDefault(),children:s.jsx(De.Editor,{editorKey:"draft-editor-1",blockRenderMap:Ut,editorState:t!=null&&t.textStructureReduced?zt(JSON.parse(t.textStructureReduced)):De.EditorState.createEmpty(),onChange:()=>null,readOnly:!0})}):s.jsx(s.Fragment,{}),t.showTextStructureExpander&&t.textStructure?s.jsx(s.Fragment,{children:s.jsx(De.Editor,{editorKey:"draft-editor-1",blockRenderMap:Ut,editorState:t.textStructure?zt(JSON.parse(t.textStructure)):De.EditorState.createEmpty(),onChange:()=>null,readOnly:!0})}):s.jsx(s.Fragment,{})]}),to={"draftjs-text-modifier":"_draftjs-text-modifier_1itwm_2"},dh="_textContentWrapper_1bigo_5",fh="_textContentSection_1bigo_13",ro={"link-modifier":"_link-modifier_1bigo_1",textContentWrapper:dh,textContentSection:fh},zu=({data:e,ICONS:t})=>{var o;const[r,n]=E.useState(!1);return s.jsx(v.TextStructure.Root,{layoutProps:{textRow:{alignContent:Ze(e.textStructureAlignment),alignItems:Ze(e.textStructureAlignment)},columnWrapper:{alignContent:Ze(e.textStructureAlignment),alignItems:Ze(e.textStructureAlignment)}},adornment:{bottom:e.showTextStructureExpander&&e.textStructure?s.jsx(v.Button,{variant:"tertiary",adornment:{end:s.jsx(v.Icon,{name:r?`${t.arrow_up}`:`${t.arrow_down}`})},onClick:()=>n(i=>!i),size:"small",children:r?"Ver Menos":"Ver Mais"}):s.jsx(s.Fragment,{})},children:s.jsxs(v.Utils.Column,{className:ro.textContentWrapper,style:{alignItems:Ze(e.textStructureAlignment)},children:[s.jsx(v.TextStructure.DivWrapper,{style:{textAlign:Ze(e.textStructureAlignment)},mode:e.textStructureMode??"default",className:to["draftjs-text-modifier"],children:e.textStructureReduced?s.jsx(lh,{content:e,expanded:r}):s.jsx(s.Fragment,{})}),e.textStructureButtonLabel?s.jsx(ze,{mode:e.textStructureMode??"default",href:e.textStructureButtonHref??"#",size:e.textStructureButtonSize,className:ro["link-modifier"],adornments:(o=e.textStructureButtonIcon)!=null&&o.length&&e.enableIcon?{end:s.jsx(v.Icon,{name:e.textStructureButtonIcon})}:void 0,children:e.textStructureButtonLabel}):s.jsx(s.Fragment,{})]})})},ph=e=>({centro:{verticalAlignment:"center",horizontalAlignment:"center"},"centro-esquerda":{verticalAlignment:"center",horizontalAlignment:"start"},"centro-direita":{verticalAlignment:"center",horizontalAlignment:"end"},"superior-centro":{verticalAlignment:"start",horizontalAlignment:"center"},"superior-esquerda":{verticalAlignment:"start",horizontalAlignment:"start"},"superior-direita":{verticalAlignment:"start",horizontalAlignment:"end"},"inferior-centro":{verticalAlignment:"end",horizontalAlignment:"center"},"inferior-esquerda":{verticalAlignment:"end",horizontalAlignment:"start"},"inferior-direita":{verticalAlignment:"end",horizontalAlignment:"end"}})[e],Hs=e=>({centro:"center",esquerda:"start",direita:"end"})[e],no=({dateEnd:e,dateInit:t,TIME_ZONE:r="America/Sao_Paulo",...n})=>{const[o,i]=E.useState(lc(new ko.TZDate(Date.now(),r),new ko.TZDate(e,r))),[a,c]=E.useState(!1);E.useEffect(()=>{a||c(!0);const l=setInterval(()=>{if(o<=0){clearInterval(l);return}i(o-1e3)},1e3);return()=>{clearInterval(l)}},[o,i,a]);const u=ut(o,"days");return a&&o>0?s.jsxs(v.Timer.Root,{...n,children:[u?s.jsxs(s.Fragment,{children:[s.jsx(v.Timer.Digit,{label:"dias",value:u}),s.jsx(v.Timer.Separator,{})]}):null,s.jsx(v.Timer.Digit,{label:"horas",value:ut(o,"hours")}),s.jsx(v.Timer.Separator,{}),s.jsx(v.Timer.Digit,{label:"min",value:ut(o,"minutes")}),s.jsx(v.Timer.Separator,{}),s.jsx(v.Timer.Digit,{label:"segs",value:ut(o),suppressHydrationWarning:!0})]}):s.jsx(s.Fragment,{})},Fs={"content-modifier":"_content-modifier_16y4u_5","banner-image-wrapper-modifier":"_banner-image-wrapper-modifier_16y4u_13"},zs=({data:e,videoUrl:t,priority:r,videoRef:n,ICONS:o,...i})=>{const{video:a,image:c,imageHref:u,imageOpacity:l,altImage:f,backgroundColor:p,position:d,contentAlignment:m,showTimer:h,contentOrder:y,timerMode:g,timerEnd:b,timerInit:A,textStructure:_,textStructureReduced:C}=e.banner,x=(u==null?void 0:u.trim())||(c==null?void 0:c.trim())||null,{nextimage:P}=je();return s.jsxs(v.Banner.Container,{...i,children:[s.jsxs(v.Banner.ImageWrapper,{className:Fs["banner-image-wrapper-modifier"],style:l?{background:p}:void 0,children:[a&&s.jsx($e.Video,{videoRef:n,src:t,autoPlay:r,loop:!0,playsInline:!0,muted:!0}),x&&!(a!=null&&a.length)&&s.jsx(P,{src:x,width:"1920",height:"1080",alt:f??c??"",...r?{priority:r}:{},style:l?{opacity:"0"}:void 0}),!c&&!(a!=null&&a.length)&&s.jsx("div",{style:{background:p}})]}),h||C||_?s.jsx(v.Banner.Slot,{...ph(d??"centro"),className:Fs["content-modifier"],style:{textAlign:Hs(m)},children:s.jsxs(v.Utils.Column,{gap:"16px",alignItems:Hs(m),children:[h&&y==="timer-first"&&s.jsx(no,{mode:g??"default",size:"small",dateEnd:b?new Date(b):new Date,dateInit:A?new Date(A):new Date}),s.jsx(zu,{data:e.banner,ICONS:o}),h&&y!=="timer-first"&&s.jsx(no,{mode:g??"default",size:"small",dateEnd:b?new Date(b):new Date,dateInit:A?new Date(A):new Date})]})}):s.jsx(s.Fragment,{})]})},To=({data:e,className:t,priority:r,creative:n,...o})=>{const{handleSelectPromotionEvent:i,currentLocalRef:a}=ge(),{banner:{promotion_name:c},index:u,componentIndex:l}=e,f=typeof u=="number"?`:${u+1}`:"",p={creative_name:n,creative_slot:`${n}-${a.current}:${l+1}${f}`,promotion_id:e.banner.href,promotion_name:c},d=E.useRef(null),m=E.useMemo(()=>{var y;if((y=e.banner.video)!=null&&y.includes("player.vimeo")){const g=e.banner.video.split("?")[1],b=g==null?void 0:g.split("&"),A=b==null?void 0:b.filter(C=>C.includes("loc")||C.includes("signature")||C.includes("user_id")),_=A==null?void 0:A.join("&");return`${e.banner.video.split("?")[0]}?${_}`}return e.banner.video},[e]),h=()=>{var y;(y=d.current)!=null&&y.paused&&d.current.play()};return s.jsx(Qt,{eventData:{functionKey:"readyEvents",data:{event:"view_promotion",readyData:{ecommerce:{...p,index:u}}}},observerOptions:{delay:100,...m&&{threshold:.1}},...m&&{callBackWhenVisible:h},children:e.banner.href?s.jsx(Ne,{href:e.banner.href,onClick:()=>{i({updatePromotionRef:!0,promotion:p,index:u})},children:s.jsx(zs,{data:e,videoUrl:m,priority:r,videoRef:d,...o})}):s.jsx(zs,{data:e,videoUrl:m,priority:r,videoRef:d,...o})})},Uu=e=>s.jsx(To,{...e}),oo={"custom-carousel":"_custom-carousel_t5fgp_1","carrousel-arrows-display-controller":"_carrousel-arrows-display-controller_t5fgp_10","carousel-controllers-modifier":"_carousel-controllers-modifier_t5fgp_19"};function mh(e,t){const{mediatorRef:r}=Ae();E.useEffect(()=>r.current.subscribe(e,t),[e,t])}const Us=({prevOnClick:e,nextOnClick:t,onBulletClick:r,currentPage:n,totalPages:o,position:i,hideControllers:a,left:c,isFirst:u,ICONS:l})=>{const[f,p]=E.useState("default");return mh("herobanner:change_controllers_variant",d=>{u&&p(d.includes("white")?"inverse":"default")}),s.jsxs(v.Carousel.Controller,{className:oo["carousel-controllers-modifier"],position:i??"absolute","data-hide-controllers":a,bottom:"16px",top:"unset",left:c,children:[s.jsxs(v.Carousel.Arrows,{className:oo["carrousel-arrows-display-controller"],children:[s.jsx(v.Button,{variant:"tertiary",onClick:e,adornment:{start:s.jsx(v.Icon,{name:l.arrow_left})},mode:f}),s.jsx(v.Button,{variant:"tertiary",onClick:t,adornment:{start:s.jsx(v.Icon,{name:l.arrow_right})},mode:f})]}),s.jsx(v.Carousel.Bullets,{page:n,total:o,onBulletClick:r,mode:f})]})},hh=({children:e,data:t,banner:r,...n})=>{const{mediatorRef:o}=Ae();return t.data.first?s.jsx(Qt,{observerOptions:{threshold:.51},stopOnIntersection:!1,callBackWhenVisible:()=>{o.current.publish("header:change_variant",r.headerVariant)},...n,children:e}):s.jsx(s.Fragment,{children:e})},gh=({data:e,ICONS:t})=>{var p;const{initialize:r,pagination:n,controller:o,itemsStyles:i}=v.Carousel.useCarousel({gap:e.data.config.gap,itemsPerPage:e.data.config.slidesPerView,direction:"row"}),a=E.useRef(void 0),c=E.useMemo(()=>Fu(e.data.config.controllerPosition??"dentro-inferior-centro"),[e]),u=E.useCallback(()=>{e.data.config.slideDuration&&n.totalPages>1&&(a.current=setInterval(()=>{o==null||o.nextPage()},e.data.config.slideDuration*1e3))},[o,e.data.config.slideDuration,n.totalPages]),l=E.useCallback(d=>{clearInterval(a.current),u(),d()},[u]),f=E.useMemo(()=>{var d;return{nextOnClick:()=>l(()=>o==null?void 0:o.nextPage()),prevOnClick:()=>l(()=>o==null?void 0:o.prevPage()),onBulletClick:m=>l(()=>o==null?void 0:o.navigateTo(m)),currentPage:n.currentPage,totalPages:n.totalPages,position:c.position,hideControllers:((d=e.data.config)==null?void 0:d.hideControllers)??!1,left:c.left}},[n.currentPage,n.totalPages,c.position,e.data.config.hideControllers,l,o]);return E.useEffect(()=>(u(),()=>clearInterval(a.current)),[u]),s.jsxs(v.Carousel.Root,{innerRef:d=>{r(d)},className:v.helpers.classNameConcat(oo["custom-carousel"],e.data.config.fullWidth?"":"common-section"),"data-infinity-border":!0,style:{...e.data.config.marginTop!=="0px"&&{marginTop:`-${e.data.config.marginTop}`},...e.data.config.marginBottom!=="0px"&&{marginBottom:`-${e.data.config.marginBottom}`}},children:[c.shouldRender==="top"&&n.totalPages>1?s.jsx(Us,{ICONS:t,...f,isFirst:e.data.first}):s.jsx(s.Fragment,{}),s.jsx(v.Carousel.Body,{children:(p=e==null?void 0:e.data)==null?void 0:p.banners.map((d,m)=>s.jsx(v.Carousel.Item,{style:i,children:s.jsx(hh,{data:e,banner:d,children:s.jsx(To,{ICONS:t,suppressContentEditableWarning:!0,suppressHydrationWarning:!0,data:{banner:d,index:m,componentIndex:e.data.componentIndex},creative:"banner-carousel",...e.data.first&&m===0&&{priority:!0}})})},`hero-banner-item-${m}`))}),c.shouldRender==="bottom"&&n.totalPages>1?s.jsx(Us,{ICONS:t,...f}):s.jsx(s.Fragment,{})]})},yh={Banner:Uu},at={"row-controller-modifier":"_row-controller-modifier_co4wb_1","carousel-title-modifier":"_carousel-title-modifier_co4wb_18","carousel-modifier":"_carousel-modifier_co4wb_22","card-modifier":"_card-modifier_co4wb_26"},_h=({data:e,CONSTANTS:t})=>{var l;const{isMobile:r}=Ae(),n=e.config.size??"medium",o=e.config.disableCarouselMobile??!1,{initialize:i,pagination:a,controller:c,itemsStyles:u}=v.Carousel.useCarousel({itemsPerPage:r?e==null?void 0:e.config.slidesPerViewMobile:(l=e==null?void 0:e.config)==null?void 0:l.slidesPerView,gap:r?e.config.gapMobile:e.config.gap,direction:r&&o?"column":"row"});return s.jsx(v.Utils.Column,{style:{width:n==="small"?"70%":"100%"},alignContent:"center",justifyContent:"center",alignItems:"center",children:s.jsxs(v.Carousel.Root,{innerRef:f=>{i(f)},className:v.helpers.classNameConcat(at["carousel-modifier"],"common-section"),children:[n==="medium"?s.jsxs(v.TextStructure.Root,{children:[s.jsx(v.TextStructure.DivWrapper,{className:at["carousel-title-modifier"],children:s.jsx("h2",{className:"typography-style-body-lg",children:t.BENNEFITS_BAR_TITLE})}),r&&a.totalPages>1?s.jsx(v.Carousel.Controller,{className:at["row-controller-modifier"],children:s.jsxs(v.Carousel.Arrows,{children:[s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.prevPage(),adornment:{start:s.jsx(v.Icon,{name:t.ICONS.arrow_left})}}),s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.nextPage(),adornment:{start:s.jsx(v.Icon,{name:t.ICONS.arrow_right})}})]})}):s.jsx(s.Fragment,{})]}):s.jsx(s.Fragment,{}),s.jsx(v.Carousel.Body,{children:e.bennefit.map((f,p)=>s.jsx(v.Carousel.Item,{className:at["card-modifier"],style:u,children:s.jsx(v.Card,{stroke:!0,padding:"small",children:s.jsx(v.TextStructure.Root,{layoutProps:{columnWrapper:{alignContent:"start",alignItems:"start",justifyContent:"start"},textRow:{alignContent:"center",alignItems:"center",justifyContent:"center"}},adornment:{[n==="medium"?"top":"start"]:s.jsx(v.Icon,{name:f.icon,size:n==="medium"?"medium":"small"})},children:s.jsxs(v.TextStructure.DivWrapper,{alignItems:"start",children:[s.jsx("h3",{className:"typography-style-body-md",children:f.title}),f.subtitle&&f.subtitle.length?s.jsx("p",{className:"typography-style-body-xs",children:f.subtitle}):s.jsx(s.Fragment,{})]})})})},`bennefit=${p}`))}),!r&&a.totalPages>1?s.jsxs(v.Carousel.Controller,{className:at["row-controller-modifier"],children:[s.jsxs(v.Carousel.Arrows,{children:[s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.prevPage(),adornment:{start:s.jsx(v.Icon,{name:t.ICONS.arrow_left})}}),s.jsx(v.Button,{variant:"tertiary",onClick:()=>c==null?void 0:c.nextPage(),adornment:{start:s.jsx(v.Icon,{name:t.ICONS.arrow_right})}})]}),s.jsx(v.Carousel.Bullets,{page:a.currentPage,total:a.totalPages,onBulletClick:f=>c==null?void 0:c.navigateTo(f)})]}):s.jsx(s.Fragment,{})]})})},vh=({data:e,ICONS:t})=>s.jsx("div",{className:v.helpers.classNameConcat(ro.textContentSection),style:e.borderTop?{borderTop:"none"}:void 0,children:s.jsx(zu,{data:e,ICONS:t})}),Gs={"accordion-modifier":"_accordion-modifier_1we16_1","accordion-body-modifier":"_accordion-body-modifier_1we16_7"},bh=({data:e,id:t,ICONS:r})=>{var i;const[n,o]=E.useState([]);return s.jsxs(v.Utils.Column,{gap:"var(--gap-vertical-sm)",children:[e.titleAccordion?s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{children:s.jsx("h2",{className:v.helpers.classNameConcat("typography-style-heading-sm","common-section"),style:{fontWeight:500},children:e.titleAccordion})})}):s.jsx(s.Fragment,{}),(i=e.accordions)==null?void 0:i.map((a,c)=>s.jsxs(v.Accordion.Wrapper,{className:Gs["accordion-modifier"],children:[s.jsx(v.Accordion.Header,{id:`${t}-text-accordion-${c}`,openIndicator:s.jsx(v.Icon,{name:r.arrow_down}),closeIndicator:s.jsx(v.Icon,{name:r.arrow_up}),startOpen:n.includes(c),onClick:()=>o(u=>u.includes(c)?u.filter(l=>l!==c):[...u,c]),children:s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{className:to["draftjs-text-modifier"],children:[s.jsx("h3",{className:"typography-style-body-md-strong",children:a.title}),a.subtitle&&a.subtitle.length?s.jsx("h2",{children:a.subtitle}):s.jsx(s.Fragment,{})]})})}),s.jsx(v.Accordion.Body,{children:s.jsx(v.TextStructure.Root,{children:s.jsx(v.TextStructure.DivWrapper,{className:v.helpers.classNameConcat(Gs["accordion-body-modifier"],to["draftjs-text-modifier"]),children:s.jsx(De.Editor,{editorKey:`${t}-editor-${c}`,blockRenderMap:Ut,editorState:a.text?zt(JSON.parse(a.text)):De.EditorState.createEmpty(),onChange:()=>null})})})})]},`${t}-accordion-${c}-${n.includes(c)}`))]})},Gu=E.createContext({}),xh=({data:e,children:t,...r})=>{var h,y,g,b,A,_,C,x,P,S,I,$,w;const[n,o]=E.useState(!0),{initialize:i,controller:a,itemsStyles:c}=v.Carousel.useCarousel({gap:0,itemsPerPage:1}),u={slideTranstionTimer:(y=(h=e==null?void 0:e.staticConfig)==null?void 0:h.staticConfig)==null?void 0:y.slideTranstionTimer,showCarouselArrows:(b=(g=e==null?void 0:e.staticConfig)==null?void 0:g.staticConfig)==null?void 0:b.showCarouselArrows,hasCloseBtn:(_=(A=e==null?void 0:e.staticConfig)==null?void 0:A.staticConfig)==null?void 0:_.hasCloseBtn,backgroundColor:(x=(C=e==null?void 0:e.staticConfig)==null?void 0:C.staticConfig)==null?void 0:x.backgroundColor,textColorVariant:(S=(P=e==null?void 0:e.staticConfig)==null?void 0:P.staticConfig)==null?void 0:S.textColorVariant,content:(($=(I=e==null?void 0:e.content)==null?void 0:I.content)==null?void 0:$.items)??[]},l=(w=u.content)==null?void 0:w.filter(N=>!N.countDownEndDate||new Date(N.countDownEndDate)>new Date),f=l.length>1,p={...u.backgroundColor?{backgroundColor:u.backgroundColor}:{}},d=()=>{o(!1)},m=v.helpers.ValidateProp({fieldTypes:et.Mode,property:u.textColorVariant,fallback:"default"});return s.jsx(Gu.Provider,{value:{isOpen:n,setIsOpen:o,hasCarousel:f,backgroundStyle:p,handleCloseTipbar:d,mode:m,slideTranstionTimer:u.slideTranstionTimer,showCarouselArrows:u.showCarouselArrows,hasCloseBtn:u.hasCloseBtn,slices:l,carouselProps:{initialize:i,controller:a,itemsStyles:c},...r},children:t})},qe=()=>E.useContext(Gu),Ch=({dateEnd:e,...t})=>{const{CONSTANTS:{TIME_ZONE:r}}=qe();return s.jsx(no,{dateEnd:new Date(e),TIME_ZONE:r,...t})},Sh="_tipbar_bt3p0_1",Ah="_tipbar__carousel_bt3p0_15",Ct={tipbar:Sh,tipbar__carousel:Ah,"tipbar__close-btn":"_tipbar__close-btn_bt3p0_29","tipbar-item":"_tipbar-item_bt3p0_37","tipbar-item__coupon":"_tipbar-item__coupon_bt3p0_45"},Eh=({coupon:e,feedbackTitle:t,feedbackDescription:r,...n})=>{const{CONSTANTS:o}=qe(),{addCouponSeller:i,cartStore:a}=Be(),[c,u]=E.useState({status:!1,showSnackBar:!1}),[l,f]=E.useState(!1),[p,d]=E.useState(!1),m=async()=>{if(!a.items.length){d(!0);return}(await i(e,"coupon")).code===200?u({status:!0,showSnackBar:!0}):f(!0)};return E.useEffect(()=>{c.showSnackBar&&setTimeout(()=>{u(h=>({...h,showSnackBar:!1}))},o.TIPBAR_CONFIGS.snackbar_timeout)},[c.showSnackBar]),E.useEffect(()=>{l&&setTimeout(()=>{f(!1)},o.TIPBAR_CONFIGS.snackbar_timeout)},[l]),E.useEffect(()=>{p&&setTimeout(()=>{d(!1)},o.TIPBAR_CONFIGS.snackbar_timeout)},[p]),s.jsxs(s.Fragment,{children:[s.jsx(v.Button,{...n,onClick:m,disabled:c.status,className:Ct["tipbar-item__coupon"],children:c.status?`${o.TIPBAR_CONFIGS.coupon_applied_message}`:`${o.TIPBAR_CONFIGS.coupon_default_message}`}),c.showSnackBar&&(t||r)&&s.jsx(dt,{title:t,subtitle:r,Z_INDEX_WAR:o.Z_INDEX_WAR},`feedback-coupon-${e}`),l&&s.jsx(dt,{title:o.TIPBAR_CONFIGS.coupon_error_title,subtitle:o.TIPBAR_CONFIGS.coupon_error_message,Z_INDEX_WAR:o.Z_INDEX_WAR},`error-coupon-${e}`),p&&s.jsx(dt,{title:o.TIPBAR_CONFIGS.coupon_cart_empty_title,subtitle:o.TIPBAR_CONFIGS.coupon_cart_empty_message,Z_INDEX_WAR:o.Z_INDEX_WAR},`error-cart-empty-${e}`)]})},wh=({title:e,description:t,style:r,mode:n,className:o})=>s.jsx(v.TextStructure.Root,{children:s.jsxs(v.TextStructure.DivWrapper,{mode:n,className:o,children:[e&&s.jsx("h3",{className:"typography-style-body-sm",style:r,children:e}),t&&s.jsx("p",{className:"typography-style-caption",style:r,children:t})]})}),Rh=({coupon:e,...t})=>{const{CONSTANTS:r}=qe();return s.jsx(v.Copy,{...t,iconCopy:r.ICONS.copy,iconSuccess:r.ICONS.check,children:e})},jh=({staticZone:e,type:t,className:r,description:n,title:o})=>{const{mode:i}=qe();if(t==="countdown")return s.jsx(Ch,{dateEnd:e.countDownEndDate,size:"x-small",mode:i});if(t==="coupon"){const a=v.helpers.ValidateProp({fieldTypes:et.Mode,property:e.couponButtonMode,fallback:"default"}),c=v.helpers.ValidateProp({fieldTypes:et.VariantsExtended,property:e.couponButtonVariant,fallback:"primary"});return e.coupon?s.jsx(Eh,{coupon:e.coupon,mode:a,variant:c,feedbackTitle:e.couponFeedbackTitle,feedbackDescription:e.couponFeedbackDescription}):null}if(t==="copy"){const a=v.helpers.ValidateProp({fieldTypes:et.Mode,property:e.couponButtonMode,fallback:"default"});return e.coupon?s.jsx(Rh,{coupon:e.coupon,mode:a}):null}return s.jsx(wh,{title:o,description:n,mode:i,className:r})},Ws=({handleCloseTipbar:e,mode:t})=>{const{CONSTANTS:r}=qe();return s.jsx(v.Button,{title:"fechar tipbar",className:Ct["tipbar__close-btn"],onClick:e,variant:"tertiary",mode:t,adornment:{start:s.jsx(v.Icon,{name:r.ICONS.close})}})},Ph=({children:e,mode:t="default",showCarouselArrows:r=!0,slideTranstionTimer:n})=>{const{carouselProps:o,CONSTANTS:i}=qe(),a=E.useRef(null),c=(l,f)=>{var p,d;l.stopPropagation(),l.preventDefault(),f==="prev"?(p=o.controller)==null||p.prevPage():(d=o.controller)==null||d.nextPage(),a.current&&(clearInterval(a.current),u())},u=E.useCallback(()=>{if(n&&o.controller){const l=setInterval(()=>{var f;(f=o.controller)==null||f.nextPage()},n);a.current=l}},[n,o]);return E.useEffect(()=>(u(),()=>{a.current&&clearInterval(a.current)}),[n,u]),s.jsxs(v.Carousel.Root,{innerRef:l=>{o.initialize(l)},className:Ct.tipbar__carousel,style:{flexDirection:"row",alignItems:"center"},children:[r&&s.jsx(v.Button,{variant:"tertiary",mode:t,onClick:l=>c(l,"prev"),adornment:{start:s.jsx(v.Icon,{name:i.ICONS.arrow_left})}}),s.jsx(v.Carousel.Body,{children:e}),r&&s.jsx(v.Button,{variant:"tertiary",mode:t,onClick:l=>c(l,"next"),adornment:{start:s.jsx(v.Icon,{name:i.ICONS.arrow_right})}})]})},Ih=({children:e,className:t})=>{const{hasCarousel:r,mode:n,hasCloseBtn:o,backgroundStyle:i,showCarouselArrows:a,slideTranstionTimer:c,handleCloseTipbar:u}=qe(),l=r&&a;return s.jsx("div",{style:i,"data-hasclosebtn":o,className:v.helpers.classNameConcat(Ct.tipbar,t),children:r?s.jsxs(s.Fragment,{children:[s.jsx(Ph,{mode:n,showCarouselArrows:l,slideTranstionTimer:c,children:e}),o&&s.jsx(Ws,{handleCloseTipbar:u,showCarouselArrows:l,mode:n})]}):s.jsxs(s.Fragment,{children:[e,o&&s.jsx(Ws,{handleCloseTipbar:u,mode:n})]})})},Nh=({children:e,highlightFirstSection:t,...r})=>{const{hasCarousel:n,carouselProps:o}=qe(),i=s.jsx("div",{...r,className:Ct["tipbar-item"],children:e});return n?s.jsx(v.Carousel.Item,{style:o.itemsStyles,children:i}):i},Wu=({className:e})=>{const{isOpen:t,slices:r}=qe();return r.length&&t?s.jsx(Ih,{children:r.map((n,o)=>{var i;return s.jsx(s.Fragment,{children:s.jsx(yt,{href:n.link,children:s.jsx(Nh,{highlightFirstSection:n.highlightFirstSection,"data-justifyhighlightedsection":n.horizontalAlignHighlightedSection?n.horizontalAlignHighlightedSection:"center",children:n&&((i=n==null?void 0:n.items)!=null&&i.length)?n.items.map((a,c)=>s.jsx(jh,{staticZone:n,type:a.type,title:a.title,description:a.description,className:e},`tipbar-slice-field-${c}`)):null})})},`tipbar-slice-${o}`)})}):null};Wu.displayName="TipBar.Root";const io=({className:e,...t})=>s.jsx(xh,{...t,children:s.jsx(Wu,{className:e})});io.displayName="TipBar";const Oh=({CONSTANTS:e,data:t})=>{const{tipbarRef:r}=ve(),n=t==null?void 0:t.find(i=>{var a,c;return((c=(a=i.staticConfig)==null?void 0:a.staticConfig)==null?void 0:c.deviceType)==="desktop"}),o=t==null?void 0:t.find(i=>{var a,c;return((c=(a=i.staticConfig)==null?void 0:a.staticConfig)==null?void 0:c.deviceType)==="mobile"});return s.jsxs("div",{ref:r,className:Te.responsive["responsive-flex"],children:[o?s.jsx("div",{className:Te.responsive["responsive-mobile-flex"],children:s.jsx(io,{data:o,CONSTANTS:e})}):null,n?s.jsx("div",{className:Te.responsive["responsive-desktop-flex"],children:s.jsx(io,{data:n,CONSTANTS:e})}):null]})},Vs={"card-image-wrapper":"_card-image-wrapper_10mul_1","card-image-container":"_card-image-container_10mul_9"},Th=e=>{const{nextimage:t}=je();return s.jsx(s.Fragment,{children:e.data.banners.map((r,n)=>s.jsx("div",{className:Vs["card-image-wrapper"],children:s.jsx("div",{className:Vs["card-image-container"],children:s.jsx(t,{src:r.image,alt:r.altImage?r.altImage:"Banner Coleção",width:500,height:600})})},n))})},Mh={Banner:yh,BannerSection:To,BennefitsBarSection:_h,SingleBannerSection:Uu,TextContentSection:vh,BannerCarousel:gh,TextAccordionSection:bh,TipbarScreening:Oh,ImageGrid:Th},kh={Components:Mh,helpers:uh};exports.cms=kh;exports.contexts=bd;exports.data=xo;exports.layout=rh;exports.scripts=ih;
41
+ `},Ca=Object.freeze(Object.defineProperty({__proto__:null,generateMiddleware:ya},Symbol.toStringTag,{value:"Module"})),va={helpers:Ca},ba=(e,n,r)=>{e.findEntityRanges(s=>{const o=s.getEntity();return o===null?!1:r.getEntity(o).getType()==="LINK"},n)},Ee=e=>{const n=new Q.CompositeDecorator([{strategy:ba,component:jr}]),r=Q.convertFromRaw(e);return Q.EditorState.createWithContent(r,n)},ja=e=>Q.convertFromRaw(e),we=Q.DefaultDraftBlockRenderMap.set("unstyled",{element:"div",aliasedElements:["div"]}),Nt="superior-direita",Ne="dentro-inferior-centro",Sa="inferior-direita",De="dentro-inferior-esquerda",Sr=e=>({position:e===Ne||e===De?"absolute":"default",shouldRender:[Nt,Ne,De].includes(e)?"top":"bottom",alignItems:[Ne].includes(e)?"center":[Nt,Sa].includes(e)?"flex-end":"flex-start",left:e===De?"16px":e===Ne?"45%":"unset"}),Na=Object.freeze(Object.defineProperty({__proto__:null,CREATE_CONTENT:Ee,EXTENDED_BLOCK_RENDER_MAP:we,GET_CONTENT_STATE:ja,controllersPositionsAdapter:Sr},Symbol.toStringTag,{value:"Module"})),ce=e=>({centro:"center",esquerda:"start",direita:"end"})[e],Ia=({expanded:e,content:n})=>t.jsxs("details",{open:e,children:[n.textStructureReduced?t.jsx("summary",{onClick:r=>r.preventDefault(),children:t.jsx(Q.Editor,{editorKey:"draft-editor-1",blockRenderMap:we,editorState:n!=null&&n.textStructureReduced?Ee(JSON.parse(n.textStructureReduced)):Q.EditorState.createEmpty(),onChange:()=>null,readOnly:!0})}):t.jsx(t.Fragment,{}),n.showTextStructureExpander&&n.textStructure?t.jsx(t.Fragment,{children:t.jsx(Q.Editor,{editorKey:"draft-editor-1",blockRenderMap:we,editorState:n.textStructure?Ee(JSON.parse(n.textStructure)):Q.EditorState.createEmpty(),onChange:()=>null,readOnly:!0})}):t.jsx(t.Fragment,{})]}),qe={"draftjs-text-modifier":"_draftjs-text-modifier_1itwm_2"},Ea="_textContentWrapper_1bigo_5",wa="_textContentSection_1bigo_13",Ve={"link-modifier":"_link-modifier_1bigo_1",textContentWrapper:Ea,textContentSection:wa},Nr=({data:e,ICONS:n})=>{var o;const[r,s]=f.useState(!1);return t.jsx(d.TextStructure.Root,{layoutProps:{textRow:{alignContent:ce(e.textStructureAlignment),alignItems:ce(e.textStructureAlignment)},columnWrapper:{alignContent:ce(e.textStructureAlignment),alignItems:ce(e.textStructureAlignment)}},adornment:{bottom:e.showTextStructureExpander&&e.textStructure?t.jsx(d.Button,{variant:"tertiary",adornment:{end:t.jsx(d.Icon,{name:r?`${n.arrow_up}`:`${n.arrow_down}`})},onClick:()=>s(a=>!a),size:"small",children:r?"Ver Menos":"Ver Mais"}):t.jsx(t.Fragment,{})},children:t.jsxs(d.Utils.Column,{className:Ve.textContentWrapper,style:{alignItems:ce(e.textStructureAlignment)},children:[t.jsx(d.TextStructure.DivWrapper,{style:{textAlign:ce(e.textStructureAlignment)},mode:e.textStructureMode??"default",className:qe["draftjs-text-modifier"],children:e.textStructureReduced?t.jsx(Ia,{content:e,expanded:r}):t.jsx(t.Fragment,{})}),e.textStructureButtonLabel?t.jsx(ne,{mode:e.textStructureMode??"default",href:e.textStructureButtonHref??"#",size:e.textStructureButtonSize,className:Ve["link-modifier"],adornments:(o=e.textStructureButtonIcon)!=null&&o.length&&e.enableIcon?{end:t.jsx(d.Icon,{name:e.textStructureButtonIcon})}:void 0,children:e.textStructureButtonLabel}):t.jsx(t.Fragment,{})]})})},Pa=e=>({centro:{verticalAlignment:"center",horizontalAlignment:"center"},"centro-esquerda":{verticalAlignment:"center",horizontalAlignment:"start"},"centro-direita":{verticalAlignment:"center",horizontalAlignment:"end"},"superior-centro":{verticalAlignment:"start",horizontalAlignment:"center"},"superior-esquerda":{verticalAlignment:"start",horizontalAlignment:"start"},"superior-direita":{verticalAlignment:"start",horizontalAlignment:"end"},"inferior-centro":{verticalAlignment:"end",horizontalAlignment:"center"},"inferior-esquerda":{verticalAlignment:"end",horizontalAlignment:"start"},"inferior-direita":{verticalAlignment:"end",horizontalAlignment:"end"}})[e],It=e=>({centro:"center",esquerda:"start",direita:"end"})[e],Ge=({dateEnd:e,dateInit:n,TIME_ZONE:r="America/Sao_Paulo",...s})=>{const[o,a]=f.useState(xn(new ft.TZDate(Date.now(),r),new ft.TZDate(e,r))),[l,i]=f.useState(!1);f.useEffect(()=>{l||i(!0);const u=setInterval(()=>{if(o<=0){clearInterval(u);return}a(o-1e3)},1e3);return()=>{clearInterval(u)}},[o,a,l]);const c=fe(o,"days");return l&&o>0?t.jsxs(d.Timer.Root,{...s,children:[c?t.jsxs(t.Fragment,{children:[t.jsx(d.Timer.Digit,{label:"dias",value:c}),t.jsx(d.Timer.Separator,{})]}):null,t.jsx(d.Timer.Digit,{label:"horas",value:fe(o,"hours")}),t.jsx(d.Timer.Separator,{}),t.jsx(d.Timer.Digit,{label:"min",value:fe(o,"minutes")}),t.jsx(d.Timer.Separator,{}),t.jsx(d.Timer.Digit,{label:"segs",value:fe(o),suppressHydrationWarning:!0})]}):t.jsx(t.Fragment,{})},Et={"content-modifier":"_content-modifier_16y4u_5","banner-image-wrapper-modifier":"_banner-image-wrapper-modifier_16y4u_13"},wt=({data:e,videoUrl:n,priority:r,videoRef:s,ICONS:o,...a})=>{const{video:l,image:i,imageHref:c,imageOpacity:u,altImage:m,backgroundColor:h,position:p,contentAlignment:_,showTimer:g,contentOrder:C,timerMode:y,timerEnd:v,timerInit:N,textStructure:j,textStructureReduced:w}=e.banner,b=(c==null?void 0:c.trim())||(i==null?void 0:i.trim())||null,{nextimage:I}=x.useNextContext();return t.jsxs(d.Banner.Container,{...a,children:[t.jsxs(d.Banner.ImageWrapper,{className:Et["banner-image-wrapper-modifier"],style:u?{background:h}:void 0,children:[l&&t.jsx(J.Video,{videoRef:s,src:n,autoPlay:r,loop:!0,playsInline:!0,muted:!0}),b&&!(l!=null&&l.length)&&t.jsx(I,{src:b,width:"1920",height:"1080",alt:m??i??"",...r?{priority:r}:{},style:u?{opacity:"0"}:void 0}),!i&&!(l!=null&&l.length)&&t.jsx("div",{style:{background:h}})]}),g||w||j?t.jsx(d.Banner.Slot,{...Pa(p??"centro"),className:Et["content-modifier"],style:{textAlign:It(_)},children:t.jsxs(d.Utils.Column,{gap:"16px",alignItems:It(_),children:[g&&C==="timer-first"&&t.jsx(Ge,{mode:y??"default",size:"small",dateEnd:v?new Date(v):new Date,dateInit:N?new Date(N):new Date}),t.jsx(Nr,{data:e.banner,ICONS:o}),g&&C!=="timer-first"&&t.jsx(Ge,{mode:y??"default",size:"small",dateEnd:v?new Date(v):new Date,dateInit:N?new Date(N):new Date})]})}):t.jsx(t.Fragment,{})]})},mt=({data:e,className:n,priority:r,creative:s,...o})=>{const{handleSelectPromotionEvent:a,currentLocalRef:l}=x.useEventContext(),{banner:{promotion_name:i},index:c,componentIndex:u}=e,m=typeof c=="number"?`:${c+1}`:"",h={creative_name:s,creative_slot:`${s}-${l.current}:${u+1}${m}`,promotion_id:e.banner.href,promotion_name:i},p=f.useRef(null),_=f.useMemo(()=>{var C;if((C=e.banner.video)!=null&&C.includes("player.vimeo")){const y=e.banner.video.split("?")[1],v=y==null?void 0:y.split("&"),N=v==null?void 0:v.filter(w=>w.includes("loc")||w.includes("signature")||w.includes("user_id")),j=N==null?void 0:N.join("&");return`${e.banner.video.split("?")[0]}?${j}`}return e.banner.video},[e]),g=()=>{var C;(C=p.current)!=null&&C.paused&&p.current.play()};return t.jsx(Ae,{eventData:{functionKey:"readyEvents",data:{event:"view_promotion",readyData:{ecommerce:{...h,index:c}}}},observerOptions:{delay:100,..._&&{threshold:.1}},..._&&{callBackWhenVisible:g},children:e.banner.href?t.jsx(x.NextLink,{href:e.banner.href,onClick:()=>{a({updatePromotionRef:!0,promotion:h,index:c})},children:t.jsx(wt,{data:e,videoUrl:_,priority:r,videoRef:p,...o})}):t.jsx(wt,{data:e,videoUrl:_,priority:r,videoRef:p,...o})})},Ir=e=>t.jsx(mt,{...e}),He={"custom-carousel":"_custom-carousel_t5fgp_1","carrousel-arrows-display-controller":"_carrousel-arrows-display-controller_t5fgp_10","carousel-controllers-modifier":"_carousel-controllers-modifier_t5fgp_19"};function ka(e,n){const{mediatorRef:r}=x.useGlobalContext();f.useEffect(()=>r.current.subscribe(e,n),[e,n])}const Pt=({prevOnClick:e,nextOnClick:n,onBulletClick:r,currentPage:s,totalPages:o,position:a,hideControllers:l,left:i,isFirst:c,ICONS:u})=>{const[m,h]=f.useState("default");return ka("herobanner:change_controllers_variant",p=>{c&&h(p.includes("white")?"inverse":"default")}),t.jsxs(d.Carousel.Controller,{className:He["carousel-controllers-modifier"],position:a??"absolute","data-hide-controllers":l,bottom:"16px",top:"unset",left:i,children:[t.jsxs(d.Carousel.Arrows,{className:He["carrousel-arrows-display-controller"],children:[t.jsx(d.Button,{variant:"tertiary",onClick:e,adornment:{start:t.jsx(d.Icon,{name:u.arrow_left})},mode:m}),t.jsx(d.Button,{variant:"tertiary",onClick:n,adornment:{start:t.jsx(d.Icon,{name:u.arrow_right})},mode:m})]}),t.jsx(d.Carousel.Bullets,{page:s,total:o,onBulletClick:r,mode:m})]})},Aa=({children:e,data:n,banner:r,...s})=>{const{mediatorRef:o}=x.useGlobalContext();return n.data.first?t.jsx(Ae,{observerOptions:{threshold:.51},stopOnIntersection:!1,callBackWhenVisible:()=>{o.current.publish("header:change_variant",r.headerVariant)},...s,children:e}):t.jsx(t.Fragment,{children:e})},Ta=({data:e,ICONS:n})=>{var h;const{initialize:r,pagination:s,controller:o,itemsStyles:a}=d.Carousel.useCarousel({gap:e.data.config.gap,itemsPerPage:e.data.config.slidesPerView,direction:"row"}),l=f.useRef(void 0),i=f.useMemo(()=>Sr(e.data.config.controllerPosition??"dentro-inferior-centro"),[e]),c=f.useCallback(()=>{e.data.config.slideDuration&&s.totalPages>1&&(l.current=setInterval(()=>{o==null||o.nextPage()},e.data.config.slideDuration*1e3))},[o,e.data.config.slideDuration,s.totalPages]),u=f.useCallback(p=>{clearInterval(l.current),c(),p()},[c]),m=f.useMemo(()=>{var p;return{nextOnClick:()=>u(()=>o==null?void 0:o.nextPage()),prevOnClick:()=>u(()=>o==null?void 0:o.prevPage()),onBulletClick:_=>u(()=>o==null?void 0:o.navigateTo(_)),currentPage:s.currentPage,totalPages:s.totalPages,position:i.position,hideControllers:((p=e.data.config)==null?void 0:p.hideControllers)??!1,left:i.left}},[s.currentPage,s.totalPages,i.position,e.data.config.hideControllers,u,o]);return f.useEffect(()=>(c(),()=>clearInterval(l.current)),[c]),t.jsxs(d.Carousel.Root,{innerRef:p=>{r(p)},className:d.helpers.classNameConcat(He["custom-carousel"],e.data.config.fullWidth?"":"common-section"),"data-infinity-border":!0,style:{...e.data.config.marginTop!=="0px"&&{marginTop:`-${e.data.config.marginTop}`},...e.data.config.marginBottom!=="0px"&&{marginBottom:`-${e.data.config.marginBottom}`}},children:[i.shouldRender==="top"&&s.totalPages>1?t.jsx(Pt,{ICONS:n,...m,isFirst:e.data.first}):t.jsx(t.Fragment,{}),t.jsx(d.Carousel.Body,{children:(h=e==null?void 0:e.data)==null?void 0:h.banners.map((p,_)=>t.jsx(d.Carousel.Item,{style:a,children:t.jsx(Aa,{data:e,banner:p,children:t.jsx(mt,{ICONS:n,suppressContentEditableWarning:!0,suppressHydrationWarning:!0,data:{banner:p,index:_,componentIndex:e.data.componentIndex},creative:"banner-carousel",...e.data.first&&_===0&&{priority:!0}})})},`hero-banner-item-${_}`))}),i.shouldRender==="bottom"&&s.totalPages>1?t.jsx(Pt,{ICONS:n,...m}):t.jsx(t.Fragment,{})]})},Ma={Banner:Ir},pe={"row-controller-modifier":"_row-controller-modifier_co4wb_1","carousel-title-modifier":"_carousel-title-modifier_co4wb_18","carousel-modifier":"_carousel-modifier_co4wb_22","card-modifier":"_card-modifier_co4wb_26"},Ra=({data:e,CONSTANTS:n})=>{var u;const{isMobile:r}=x.useGlobalContext(),s=e.config.size??"medium",o=e.config.disableCarouselMobile??!1,{initialize:a,pagination:l,controller:i,itemsStyles:c}=d.Carousel.useCarousel({itemsPerPage:r?e==null?void 0:e.config.slidesPerViewMobile:(u=e==null?void 0:e.config)==null?void 0:u.slidesPerView,gap:r?e.config.gapMobile:e.config.gap,direction:r&&o?"column":"row"});return t.jsx(d.Utils.Column,{style:{width:s==="small"?"70%":"100%"},alignContent:"center",justifyContent:"center",alignItems:"center",children:t.jsxs(d.Carousel.Root,{innerRef:m=>{a(m)},className:d.helpers.classNameConcat(pe["carousel-modifier"],"common-section"),children:[s==="medium"?t.jsxs(d.TextStructure.Root,{children:[t.jsx(d.TextStructure.DivWrapper,{className:pe["carousel-title-modifier"],children:t.jsx("h2",{className:"typography-style-body-lg",children:n.BENNEFITS_BAR_TITLE})}),r&&l.totalPages>1?t.jsx(d.Carousel.Controller,{className:pe["row-controller-modifier"],children:t.jsxs(d.Carousel.Arrows,{children:[t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.prevPage(),adornment:{start:t.jsx(d.Icon,{name:n.ICONS.arrow_left})}}),t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.nextPage(),adornment:{start:t.jsx(d.Icon,{name:n.ICONS.arrow_right})}})]})}):t.jsx(t.Fragment,{})]}):t.jsx(t.Fragment,{}),t.jsx(d.Carousel.Body,{children:e.bennefit.map((m,h)=>t.jsx(d.Carousel.Item,{className:pe["card-modifier"],style:c,children:t.jsx(d.Card,{stroke:!0,padding:"small",children:t.jsx(d.TextStructure.Root,{layoutProps:{columnWrapper:{alignContent:"start",alignItems:"start",justifyContent:"start"},textRow:{alignContent:"center",alignItems:"center",justifyContent:"center"}},adornment:{[s==="medium"?"top":"start"]:t.jsx(d.Icon,{name:m.icon,size:s==="medium"?"medium":"small"})},children:t.jsxs(d.TextStructure.DivWrapper,{alignItems:"start",children:[t.jsx("h3",{className:"typography-style-body-md",children:m.title}),m.subtitle&&m.subtitle.length?t.jsx("p",{className:"typography-style-body-xs",children:m.subtitle}):t.jsx(t.Fragment,{})]})})})},`bennefit=${h}`))}),!r&&l.totalPages>1?t.jsxs(d.Carousel.Controller,{className:pe["row-controller-modifier"],children:[t.jsxs(d.Carousel.Arrows,{children:[t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.prevPage(),adornment:{start:t.jsx(d.Icon,{name:n.ICONS.arrow_left})}}),t.jsx(d.Button,{variant:"tertiary",onClick:()=>i==null?void 0:i.nextPage(),adornment:{start:t.jsx(d.Icon,{name:n.ICONS.arrow_right})}})]}),t.jsx(d.Carousel.Bullets,{page:l.currentPage,total:l.totalPages,onBulletClick:m=>i==null?void 0:i.navigateTo(m)})]}):t.jsx(t.Fragment,{})]})})},Oa=({data:e,ICONS:n})=>t.jsx("div",{className:d.helpers.classNameConcat(Ve.textContentSection),style:e.borderTop?{borderTop:"none"}:void 0,children:t.jsx(Nr,{data:e,ICONS:n})}),kt={"accordion-modifier":"_accordion-modifier_1we16_1","accordion-body-modifier":"_accordion-body-modifier_1we16_7"},La=({data:e,id:n,ICONS:r})=>{var a;const[s,o]=f.useState([]);return t.jsxs(d.Utils.Column,{gap:"var(--gap-vertical-sm)",children:[e.titleAccordion?t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{children:t.jsx("h2",{className:d.helpers.classNameConcat("typography-style-heading-sm","common-section"),style:{fontWeight:500},children:e.titleAccordion})})}):t.jsx(t.Fragment,{}),(a=e.accordions)==null?void 0:a.map((l,i)=>t.jsxs(d.Accordion.Wrapper,{className:kt["accordion-modifier"],children:[t.jsx(d.Accordion.Header,{id:`${n}-text-accordion-${i}`,openIndicator:t.jsx(d.Icon,{name:r.arrow_down}),closeIndicator:t.jsx(d.Icon,{name:r.arrow_up}),startOpen:s.includes(i),onClick:()=>o(c=>c.includes(i)?c.filter(u=>u!==i):[...c,i]),children:t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{className:qe["draftjs-text-modifier"],children:[t.jsx("h3",{className:"typography-style-body-md-strong",children:l.title}),l.subtitle&&l.subtitle.length?t.jsx("h2",{children:l.subtitle}):t.jsx(t.Fragment,{})]})})}),t.jsx(d.Accordion.Body,{children:t.jsx(d.TextStructure.Root,{children:t.jsx(d.TextStructure.DivWrapper,{className:d.helpers.classNameConcat(kt["accordion-body-modifier"],qe["draftjs-text-modifier"]),children:t.jsx(Q.Editor,{editorKey:`${n}-editor-${i}`,blockRenderMap:we,editorState:l.text?Ee(JSON.parse(l.text)):Q.EditorState.createEmpty(),onChange:()=>null})})})})]},`${n}-accordion-${i}-${s.includes(i)}`))]})},Er=f.createContext({}),Da=({data:e,children:n,...r})=>{var g,C,y,v,N,j,w,b,I,k,D,F,M;const[s,o]=f.useState(!0),{initialize:a,controller:l,itemsStyles:i}=d.Carousel.useCarousel({gap:0,itemsPerPage:1}),c={slideTranstionTimer:(C=(g=e==null?void 0:e.staticConfig)==null?void 0:g.staticConfig)==null?void 0:C.slideTranstionTimer,showCarouselArrows:(v=(y=e==null?void 0:e.staticConfig)==null?void 0:y.staticConfig)==null?void 0:v.showCarouselArrows,hasCloseBtn:(j=(N=e==null?void 0:e.staticConfig)==null?void 0:N.staticConfig)==null?void 0:j.hasCloseBtn,backgroundColor:(b=(w=e==null?void 0:e.staticConfig)==null?void 0:w.staticConfig)==null?void 0:b.backgroundColor,textColorVariant:(k=(I=e==null?void 0:e.staticConfig)==null?void 0:I.staticConfig)==null?void 0:k.textColorVariant,content:((F=(D=e==null?void 0:e.content)==null?void 0:D.content)==null?void 0:F.items)??[]},u=(M=c.content)==null?void 0:M.filter(B=>!B.countDownEndDate||new Date(B.countDownEndDate)>new Date),m=u.length>1,h={...c.backgroundColor?{backgroundColor:c.backgroundColor}:{}},p=()=>{o(!1)},_=d.helpers.ValidateProp({fieldTypes:de.Mode,property:c.textColorVariant,fallback:"default"});return t.jsx(Er.Provider,{value:{isOpen:s,setIsOpen:o,hasCarousel:m,backgroundStyle:h,handleCloseTipbar:p,mode:_,slideTranstionTimer:c.slideTranstionTimer,showCarouselArrows:c.showCarouselArrows,hasCloseBtn:c.hasCloseBtn,slices:u,carouselProps:{initialize:a,controller:l,itemsStyles:i},...r},children:n})},ee=()=>f.useContext(Er),za=({dateEnd:e,...n})=>{const{CONSTANTS:{TIME_ZONE:r}}=ee();return t.jsx(Ge,{dateEnd:new Date(e),TIME_ZONE:r,...n})},Ba="_tipbar_bt3p0_1",$a="_tipbar__carousel_bt3p0_15",be={tipbar:Ba,tipbar__carousel:$a,"tipbar__close-btn":"_tipbar__close-btn_bt3p0_29","tipbar-item":"_tipbar-item_bt3p0_37","tipbar-item__coupon":"_tipbar-item__coupon_bt3p0_45"},Fa=({coupon:e,feedbackTitle:n,feedbackDescription:r,...s})=>{const{CONSTANTS:o}=ee(),{addCouponSeller:a,cartStore:l}=Z(),[i,c]=f.useState({status:!1,showSnackBar:!1}),[u,m]=f.useState(!1),[h,p]=f.useState(!1),_=async()=>{if(!l.items.length){p(!0);return}(await a(e,"coupon")).code===200?c({status:!0,showSnackBar:!0}):m(!0)};return f.useEffect(()=>{i.showSnackBar&&setTimeout(()=>{c(g=>({...g,showSnackBar:!1}))},o.TIPBAR_CONFIGS.snackbar_timeout)},[i.showSnackBar]),f.useEffect(()=>{u&&setTimeout(()=>{m(!1)},o.TIPBAR_CONFIGS.snackbar_timeout)},[u]),f.useEffect(()=>{h&&setTimeout(()=>{p(!1)},o.TIPBAR_CONFIGS.snackbar_timeout)},[h]),t.jsxs(t.Fragment,{children:[t.jsx(d.Button,{...s,onClick:_,disabled:i.status,className:be["tipbar-item__coupon"],children:i.status?`${o.TIPBAR_CONFIGS.coupon_applied_message}`:`${o.TIPBAR_CONFIGS.coupon_default_message}`}),i.showSnackBar&&(n||r)&&t.jsx(ge,{title:n,subtitle:r,Z_INDEX_WAR:o.Z_INDEX_WAR},`feedback-coupon-${e}`),u&&t.jsx(ge,{title:o.TIPBAR_CONFIGS.coupon_error_title,subtitle:o.TIPBAR_CONFIGS.coupon_error_message,Z_INDEX_WAR:o.Z_INDEX_WAR},`error-coupon-${e}`),h&&t.jsx(ge,{title:o.TIPBAR_CONFIGS.coupon_cart_empty_title,subtitle:o.TIPBAR_CONFIGS.coupon_cart_empty_message,Z_INDEX_WAR:o.Z_INDEX_WAR},`error-cart-empty-${e}`)]})},Ua=({title:e,description:n,style:r,mode:s,className:o})=>t.jsx(d.TextStructure.Root,{children:t.jsxs(d.TextStructure.DivWrapper,{mode:s,className:o,children:[e&&t.jsx("h3",{className:"typography-style-body-sm",style:r,children:e}),n&&t.jsx("p",{className:"typography-style-caption",style:r,children:n})]})}),qa=({coupon:e,...n})=>{const{CONSTANTS:r}=ee();return t.jsx(d.Copy,{...n,iconCopy:r.ICONS.copy,iconSuccess:r.ICONS.check,children:e})},Va=({staticZone:e,type:n,className:r,description:s,title:o})=>{const{mode:a}=ee();if(n==="countdown")return t.jsx(za,{dateEnd:e.countDownEndDate,size:"x-small",mode:a});if(n==="coupon"){const l=d.helpers.ValidateProp({fieldTypes:de.Mode,property:e.couponButtonMode,fallback:"default"}),i=d.helpers.ValidateProp({fieldTypes:de.VariantsExtended,property:e.couponButtonVariant,fallback:"primary"});return e.coupon?t.jsx(Fa,{coupon:e.coupon,mode:l,variant:i,feedbackTitle:e.couponFeedbackTitle,feedbackDescription:e.couponFeedbackDescription}):null}if(n==="copy"){const l=d.helpers.ValidateProp({fieldTypes:de.Mode,property:e.couponButtonMode,fallback:"default"});return e.coupon?t.jsx(qa,{coupon:e.coupon,mode:l}):null}return t.jsx(Ua,{title:o,description:s,mode:a,className:r})},At=({handleCloseTipbar:e,mode:n})=>{const{CONSTANTS:r}=ee();return t.jsx(d.Button,{title:"fechar tipbar",className:be["tipbar__close-btn"],onClick:e,variant:"tertiary",mode:n,adornment:{start:t.jsx(d.Icon,{name:r.ICONS.close})}})},Ga=({children:e,mode:n="default",showCarouselArrows:r=!0,slideTranstionTimer:s})=>{const{carouselProps:o,CONSTANTS:a}=ee(),l=f.useRef(null),i=(u,m)=>{var h,p;u.stopPropagation(),u.preventDefault(),m==="prev"?(h=o.controller)==null||h.prevPage():(p=o.controller)==null||p.nextPage(),l.current&&(clearInterval(l.current),c())},c=f.useCallback(()=>{if(s&&o.controller){const u=setInterval(()=>{var m;(m=o.controller)==null||m.nextPage()},s);l.current=u}},[s,o]);return f.useEffect(()=>(c(),()=>{l.current&&clearInterval(l.current)}),[s,c]),t.jsxs(d.Carousel.Root,{innerRef:u=>{o.initialize(u)},className:be.tipbar__carousel,style:{flexDirection:"row",alignItems:"center"},children:[r&&t.jsx(d.Button,{variant:"tertiary",mode:n,onClick:u=>i(u,"prev"),adornment:{start:t.jsx(d.Icon,{name:a.ICONS.arrow_left})}}),t.jsx(d.Carousel.Body,{children:e}),r&&t.jsx(d.Button,{variant:"tertiary",mode:n,onClick:u=>i(u,"next"),adornment:{start:t.jsx(d.Icon,{name:a.ICONS.arrow_right})}})]})},Ha=({children:e,className:n})=>{const{hasCarousel:r,mode:s,hasCloseBtn:o,backgroundStyle:a,showCarouselArrows:l,slideTranstionTimer:i,handleCloseTipbar:c}=ee(),u=r&&l;return t.jsx("div",{style:a,"data-hasclosebtn":o,className:d.helpers.classNameConcat(be.tipbar,n),children:r?t.jsxs(t.Fragment,{children:[t.jsx(Ga,{mode:s,showCarouselArrows:u,slideTranstionTimer:i,children:e}),o&&t.jsx(At,{handleCloseTipbar:c,showCarouselArrows:u,mode:s})]}):t.jsxs(t.Fragment,{children:[e,o&&t.jsx(At,{handleCloseTipbar:c,mode:s})]})})},Wa=({children:e,highlightFirstSection:n,...r})=>{const{hasCarousel:s,carouselProps:o}=ee(),a=t.jsx("div",{...r,className:be["tipbar-item"],children:e});return s?t.jsx(d.Carousel.Item,{style:o.itemsStyles,children:a}):a},wr=({className:e})=>{const{isOpen:n,slices:r}=ee();return r.length&&n?t.jsx(Ha,{children:r.map((s,o)=>{var a;return t.jsx(t.Fragment,{children:t.jsx(ve,{href:s.link,children:t.jsx(Wa,{highlightFirstSection:s.highlightFirstSection,"data-justifyhighlightedsection":s.horizontalAlignHighlightedSection?s.horizontalAlignHighlightedSection:"center",children:s&&((a=s==null?void 0:s.items)!=null&&a.length)?s.items.map((l,i)=>t.jsx(Va,{staticZone:s,type:l.type,title:l.title,description:l.description,className:e},`tipbar-slice-field-${i}`)):null})})},`tipbar-slice-${o}`)})}):null};wr.displayName="TipBar.Root";const We=({className:e,...n})=>t.jsx(Da,{...n,children:t.jsx(wr,{className:e})});We.displayName="TipBar";const Ka=({CONSTANTS:e,data:n})=>{const{tipbarRef:r}=L(),s=n==null?void 0:n.find(a=>{var l,i;return((i=(l=a.staticConfig)==null?void 0:l.staticConfig)==null?void 0:i.deviceType)==="desktop"}),o=n==null?void 0:n.find(a=>{var l,i;return((i=(l=a.staticConfig)==null?void 0:l.staticConfig)==null?void 0:i.deviceType)==="mobile"});return t.jsxs("div",{ref:r,className:x.responsive["responsive-flex"],children:[o?t.jsx("div",{className:x.responsive["responsive-mobile-flex"],children:t.jsx(We,{data:o,CONSTANTS:e})}):null,s?t.jsx("div",{className:x.responsive["responsive-desktop-flex"],children:t.jsx(We,{data:s,CONSTANTS:e})}):null]})},Tt={"card-image-wrapper":"_card-image-wrapper_10mul_1","card-image-container":"_card-image-container_10mul_9"},Xa=e=>{const{nextimage:n}=x.useNextContext();return t.jsx(t.Fragment,{children:e.data.banners.map((r,s)=>t.jsx("div",{className:Tt["card-image-wrapper"],children:t.jsx("div",{className:Tt["card-image-container"],children:t.jsx(n,{src:r.image,alt:r.altImage?r.altImage:"Banner Coleção",width:500,height:600})})},s))})},Ya={Banner:Ma,BannerSection:mt,BennefitsBarSection:Ra,SingleBannerSection:Ir,TextContentSection:Oa,BannerCarousel:Ta,TextAccordionSection:La,TipbarScreening:Ka,ImageGrid:Xa,PLPContentProvider:x.PLPContentProvider},Qa={Components:Ya,helpers:Na};exports.cms=Qa;exports.contexts=Es;exports.data=at;exports.layout=xa;exports.scripts=va;